/* Le musée en 3D : la salle (canvas) reste fixe, plein écran ; le défilement de la page fait avancer la caméra. */
@font-face { font-family: "Inter"; src: url("/fonts/inter.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }
@font-face { font-family: "Caveat"; src: url("/fonts/caveat.woff2") format("woff2"); font-weight: 500 700; font-display: swap; }
* { box-sizing: border-box; margin: 0; padding: 0; }
html { background: #0d0806; color: #FFF6E8; font-family: Inter, system-ui, sans-serif; -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; }
html:not(.entre), html:not(.entre) body { overflow: hidden; height: 100%; }
body { overscroll-behavior: none; }
button { font: inherit; color: inherit; border: 0; background: none; cursor: pointer; }
[hidden] { display: none !important; }
svg { display: block; }
.musee3d__toile { position: fixed; inset: 0; width: 100vw; height: 100vh; height: 100lvh; display: block; z-index: 0; }
.piste { position: relative; z-index: 1; width: 1px; pointer-events: none; }

/* l'arrivée */
.intro { position: fixed; inset: 0; z-index: 20; display: grid; place-content: center; justify-items: center; gap: 1.2rem; padding: 2rem; text-align: center;
  background: radial-gradient(90% 60% at 50% 40%, rgba(60, 30, 12, .6), rgba(10, 6, 3, .97)), url("/musee/entree.webp") center / cover; transition: opacity 1.1s ease, visibility 0s 1.1s; }
.intro.part { opacity: 0; visibility: hidden; }
.intro__sur { font-size: clamp(.7rem, 2.6vw, .9rem); letter-spacing: .32em; text-transform: uppercase; color: rgba(242, 201, 142, .9); }
.intro__nom { font-family: Caveat, cursive; font-weight: 700; font-size: clamp(3.6rem, 16vw, 7.5rem); line-height: .95; background: linear-gradient(180deg, #FFEBC4, #D9A15A); -webkit-background-clip: text; background-clip: text; color: transparent; }
.intro__texte { max-width: 26rem; font-size: clamp(.95rem, 3.8vw, 1.15rem); line-height: 1.45; color: rgba(255, 246, 232, .86); }
.intro__entrer { display: inline-flex; align-items: center; gap: .8rem; height: 3.6rem; margin-top: .6rem; padding: 0 .55rem 0 1.6rem; border-radius: 99rem; background: #FFF6E8; color: #2a170b; font-size: 1.05rem; font-weight: 600;
  box-shadow: 0 1.4rem 3rem -1rem rgba(0, 0, 0, .7); animation: invite 2.6s ease-in-out infinite; }
.intro__entrer svg { width: 2.5rem; height: 2.5rem; padding: .6rem; border-radius: 50%; background: #2a170b; color: #FFF6E8; }
@keyframes invite { 50% { transform: scale(1.04); } }
.intro__son { font-size: .85rem; color: rgba(255, 246, 232, .6); }

/* par-dessus la salle */
.haut { position: fixed; z-index: 10; left: 0; right: 0; top: 0; display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: calc(.9rem + env(safe-area-inset-top, 0px)) 1.1rem 2rem; background: linear-gradient(180deg, rgba(10, 6, 3, .55), transparent); pointer-events: none; }
.haut > * { pointer-events: auto; }
.haut__titre { font-family: Caveat, cursive; font-size: clamp(1.4rem, 5.4vw, 2rem); color: #FFF0D8; text-shadow: 0 .1rem .8rem rgba(0, 0, 0, .6); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rond { display: grid; place-items: center; flex: none; width: 2.8rem; height: 2.8rem; border-radius: 50%; background: rgba(255, 246, 232, .14); border: 1px solid rgba(255, 246, 232, .26); color: #FFF6E8; -webkit-backdrop-filter: blur(.6rem); backdrop-filter: blur(.6rem); }
.rond svg { width: 1.3rem; height: 1.3rem; }
.barre { position: fixed; z-index: 10; left: 1.2rem; right: 1.2rem; bottom: calc(1rem + env(safe-area-inset-bottom, 0px)); height: 3px; border-radius: 3px; background: rgba(255, 246, 232, .18); overflow: hidden; }
.barre i { display: block; height: 100%; background: linear-gradient(90deg, #F2C98E, #E67A1E); transform-origin: left; transform: scaleX(0); }
.indice { position: fixed; z-index: 10; left: 50%; bottom: calc(2.2rem + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); display: grid; justify-items: center; gap: .3rem; font-size: .85rem; color: rgba(255, 246, 232, .8); transition: opacity .6s; pointer-events: none; }
.indice svg { width: 1.6rem; height: 1.6rem; animation: descend 1.4s ease-in-out infinite; }
.indice.cache { opacity: 0; }
@keyframes descend { 50% { transform: translateY(.4rem); } }
.fin { position: fixed; z-index: 11; left: 0; right: 0; bottom: 0; padding: 4rem 1.2rem calc(2.4rem + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; align-items: center; gap: .5rem; text-align: center; background: linear-gradient(180deg, transparent, rgba(10,6,3,.82) 45%); opacity: 0; transform: translateY(1rem); transition: opacity .8s, transform .8s; pointer-events: none; }
.fin.vue { opacity: 1; transform: none; pointer-events: auto; }
.fin__boutons { display: flex; gap: .6rem; }
.fin__boutons a, .fin__boutons button { display: inline-flex; align-items: center; height: 3rem; padding: 0 1.3rem; border-radius: 99rem; font-size: .92rem; font-weight: 600; text-decoration: none; white-space: nowrap; }
.fin__boutons button { background: rgba(255, 246, 232, .14); border: 1px solid rgba(255, 246, 232, .3); color: #FFF6E8; -webkit-backdrop-filter: blur(.5rem); backdrop-filter: blur(.5rem); }
.fin__boutons a { background: #FFF6E8; color: #2a170b; }
.fin__gratuit { margin-left: .55rem; padding: .18rem .55rem; border-radius: 99rem; background: #E67A1E; color: #2a170b; font-size: .72rem; font-weight: 700; letter-spacing: .02em; }
.loupe { position: fixed; inset: 0; z-index: 30; display: grid; place-items: center; padding: 1.5rem; background: rgba(10, 6, 3, .92); -webkit-backdrop-filter: blur(.5rem); backdrop-filter: blur(.5rem); animation: loupe .3s ease both; cursor: zoom-out; }
@keyframes loupe { from { opacity: 0; } }
.loupe img { max-width: min(100%, 60rem); max-height: 82vh; border: .6rem solid #FFF6E8; border-bottom-width: 2.2rem; box-shadow: 0 2rem 4rem rgba(0, 0, 0, .7); animation: pose .45s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes pose { from { transform: scale(.9) rotate(-2deg); opacity: 0; } }
.etiquette { position: fixed; z-index: 15; left: 50%; top: calc(4.2rem + env(safe-area-inset-top, 0px)); transform: translateX(-50%); padding: .4rem .9rem; border-radius: 99rem; background: rgba(230, 122, 30, .92); color: #2a170b; font-size: .78rem; font-weight: 700; white-space: nowrap; text-decoration: none; }
@media (prefers-reduced-motion: reduce) { .intro__entrer, .indice svg { animation: none; } }

.fin__mot { font-family: Caveat, cursive; font-weight: 700; font-size: clamp(2.2rem, 9vw, 3.6rem); line-height: 1; color: #FFF0D8; text-shadow: 0 .2rem 1.2rem rgba(0,0,0,.6); }
.fin__de { font-size: .95rem; color: rgba(255,240,216,.8); margin-bottom: .6rem; }
