/* Maquette « L'aller-retour » (10/11) : une seule scène fixe (la carte, puis la salle) et un seul fond ; le site défile par-dessus.
   Chaque section pose son texte à un endroit différent, pour ne jamais lire deux fois la même disposition. */
@font-face { font-family: T; src: url(a/BarlowCondensed-Bold.woff2); font-weight: 700; font-display: swap; }
@font-face { font-family: R; src: url(a/BarlowSemiCondensed-Medium.woff2); font-weight: 500; font-display: swap; }
:root { --fond: #0b0b0e; --papier: #f4f3ef; --gris: #9a9ca4; --doux: #d6d7dc; --or: #c19e4c; --accent: #c19e4c; --eau: #4fb9e6; --trait: #ffffff24; --marge: clamp(20px, 5vw, 88px); }
* { box-sizing: border-box; }
[hidden] { display: none !important; }   /* un bouton masqué le reste, même avec .btn */
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--fond); color: var(--papier); font: 500 20px/1.5 R, system-ui, sans-serif; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img, video { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2 { font-family: T, sans-serif; font-weight: 700; text-transform: uppercase; margin: 0; line-height: .9; letter-spacing: .005em; text-wrap: balance; }
h1 { font-size: clamp(58px, 9.6vw, 156px); }
h2 { font-size: clamp(46px, 6.2vw, 100px); }
p { margin: 0; text-wrap: pretty; }
small { display: block; font-size: 14px; letter-spacing: .04em; color: var(--gris); margin-top: 12px; }
.saut { position: absolute; left: -999px; } .saut:focus { left: 12px; top: 12px; z-index: 99; background: var(--papier); color: #000; padding: 8px 12px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

/* la scène fixe */
#carte, #salle, #voile, #scene { position: fixed; inset: 0; width: 100%; height: 100%; }
#scene { z-index: 2; pointer-events: none; }
#carte { z-index: 0; }
#salle { z-index: 1; opacity: 0; pointer-events: none; overflow: hidden; }
#salle video { width: 100%; height: 100%; object-fit: cover; }
#voile { z-index: 2; pointer-events: none; background: #0b0b0e; opacity: 0; }

header { position: fixed; inset: 0 0 auto 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; padding: 16px var(--marge); background: linear-gradient(#0b0b0ef2, #0b0b0e00); }
header .logo img { height: 34px; }
nav { display: flex; align-items: center; gap: clamp(14px, 2.2vw, 34px); font: 500 15px R; letter-spacing: .2em; text-transform: uppercase; }
nav a { text-decoration: none; color: var(--doux); }
nav a:hover { color: var(--papier); }
nav a.cta { border: 2px solid var(--papier); padding: 10px 18px; color: var(--papier); }
nav a.cta:hover { background: var(--accent); border-color: var(--accent); color: #0b0b0e; }
@media (max-width: 1000px) { nav a:not(.cta) { display: none; } }

main { position: relative; z-index: 3; }
section[data-s] { height: var(--h, 100svh); position: relative; }
.colle { position: sticky; top: 0; height: 100svh; pointer-events: none; overflow: hidden; }
.colle.libre { position: relative; height: auto; min-height: 100svh; display: flex; align-items: center; }
#partenaires { height: auto; }
.pose { position: absolute; pointer-events: auto; }
.sur { display: flex; align-items: center; gap: 14px; font: 500 15px R; letter-spacing: .28em; text-transform: uppercase; color: var(--accent); margin-bottom: 20px; transition: color .5s; }
.sur::before { content: ""; width: 34px; height: 2px; background: currentColor; }
.sur.eau { color: var(--eau); }
.chapo { font-size: clamp(19px, 1.6vw, 24px); color: var(--doux); max-width: 30em; margin-top: 24px; }
.geant { display: block; font: 700 clamp(84px, 13vw, 210px)/.86 T; letter-spacing: -.01em; }
.btn { display: inline-flex; align-items: center; gap: 12px; padding: 16px 26px; font: 700 19px T; letter-spacing: .09em; text-transform: uppercase; text-decoration: none; border: 2px solid var(--papier); cursor: pointer; background: #0b0b0e66; color: var(--papier); transition: background .2s, color .2s, border-color .2s; }
.btn.plein { background: var(--papier); color: #0b0b0e; }
.btn.petit { padding: 10px 16px; font-size: 16px; }
.btn:hover, .btn:focus-visible { background: var(--accent); border-color: var(--accent); color: #0b0b0e; }
/* le contact n'est pas encore ouvert : le bouton est là, inactif, avec sa mention */
.btn.attente, .btn.attente:hover { cursor: default; background: transparent; color: var(--doux); border-color: var(--trait); }
.btn.attente em { font: 500 13px R; font-style: normal; letter-spacing: .2em; color: #0b0b0e; background: var(--accent); padding: 4px 9px; }
.actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }
.jouer { width: 0; height: 0; border-left: 13px solid currentColor; border-top: 8px solid transparent; border-bottom: 8px solid transparent; }

/* 0 · l'accroche : texte en bas à gauche, sur la vidéo de la salle ; un voile sombre à gauche et en bas garde le titre lisible */
#ombre { position: fixed; inset: 0; z-index: 2; pointer-events: none; background: linear-gradient(90deg, #0b0b0ef5 0, #0b0b0ed9 30%, #0b0b0e80 55%, #0b0b0e00 82%), linear-gradient(0deg, #0b0b0ee6 0, #0b0b0e00 40%); }
@media (max-width: 760px) { #ombre { background: linear-gradient(0deg, #0b0b0ef2 0, #0b0b0ecc 55%, #0b0b0e33 100%); } }
.bas-gauche { left: var(--marge); bottom: clamp(70px, 10vh, 120px); max-width: min(92vw, 900px); }
.suite { position: absolute; right: var(--marge); bottom: 34px; pointer-events: auto; font: 500 14px R; letter-spacing: .26em; text-transform: uppercase; text-decoration: none; color: var(--doux); padding-bottom: 26px; }
.suite::after { content: ""; position: absolute; left: 50%; bottom: 0; width: 2px; height: 18px; background: var(--accent); animation: descend 1.8s ease-in-out infinite; }
@keyframes descend { 0%, 100% { transform: translateY(-4px); opacity: .4 } 50% { transform: translateY(4px); opacity: 1 } }

/* 1 · les nations : colonne à droite, la carte à gauche */
.droite { right: var(--marge); top: 50%; transform: translateY(-50%); width: min(520px, 42vw); }
.puces { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-top: 28px; }
.puces button { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 4px 8px; background: #0b0b0ecc; border: 2px solid var(--trait); color: var(--doux); font: 700 15px/1 T; letter-spacing: .08em; text-transform: uppercase; cursor: pointer; transition: border-color .2s, color .2s, transform .2s; }
.puces button img { width: 34px; height: 23px; object-fit: cover; }
.puces button:hover { border-color: var(--papier); color: var(--papier); transform: translateY(-2px); }
.fiche { margin-top: 20px; min-height: 3.2em; color: var(--doux); border-left: 3px solid var(--accent); padding-left: 16px; transition: border-color .5s; }
.fiche:empty { border-color: transparent; }
.fiche b { color: var(--papier); font: 700 1.25em/1.1 T; text-transform: uppercase; letter-spacing: .04em; display: block; }

/* 2 · le voyage : un seul grand chiffre à la fois, en bas à gauche */
.compteur { left: var(--marge); bottom: clamp(50px, 9vh, 110px); width: min(92vw, 760px); }
.pas { position: absolute; left: 0; bottom: 0; width: 100%; opacity: 0; transform: translateY(26px); transition: opacity .65s cubic-bezier(.22, 1, .36, 1), transform .65s cubic-bezier(.22, 1, .36, 1); }
.pas.la { opacity: 1; transform: none; }
.pas p { font-size: clamp(21px, 2vw, 30px); max-width: 22em; margin-top: 12px; }
.compteur .sur { position: absolute; left: 0; bottom: calc(100% + clamp(210px, 30vh, 330px)); white-space: nowrap; }

/* 3 · la soirée : la phrase en haut, la scène en pixels occupe tout le bas */
.lignes { left: var(--marge); right: var(--marge); top: clamp(84px, 11vh, 110px); height: 34vh; }
.ligne { position: absolute; left: 0; top: 44px; font: 700 clamp(34px, 5.2vw, 92px)/.94 T; text-transform: uppercase; opacity: 0; transition: opacity .65s cubic-bezier(.22, 1, .36, 1), transform .65s cubic-bezier(.22, 1, .36, 1); transform: translateY(18px); max-width: 13em; text-shadow: 0 2px 30px #000c; text-wrap: balance; }
.ligne.la { opacity: 1; transform: none; }
.lignes .sur { color: var(--papier); }
.note { position: fixed; right: var(--marge); bottom: 22px; max-width: 30em; color: var(--doux); font-size: 15px; text-align: right; text-shadow: 0 1px 12px #000c; }
@media (max-width: 760px) { .note { left: var(--marge); text-align: left; font-size: 13px; bottom: 14px; } .ligne { top: 36px; } }

/* 4 · le tournoi : le tableau au centre */
.tableau { inset: 92px var(--marge) 34px; display: flex; flex-direction: column; }
.tete { display: flex; justify-content: space-between; align-items: flex-end; gap: 30px; flex-wrap: wrap; }
.serie { color: var(--doux); font-size: clamp(15px, 1.2vw, 18px); max-width: 34em; margin-top: 12px; }
.faits { color: var(--doux); font-size: 18px; letter-spacing: .06em; text-transform: uppercase; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.faits b { color: var(--papier); font: 700 26px/1 T; }
.faits span { width: 22px; height: 2px; background: var(--trait); }
/* le tableau est une grille de huit colonnes : chaque case couvre les deux qui la nourrissent, un trait en fourche les relie */
.tableau { --u: min(1vw, 1.5vh); --lien: calc(var(--u) * 2.8); }
#tirage { display: flex; flex-direction: column; margin-top: calc(var(--u) * 1.2); }
.tour { position: relative; display: grid; grid-template-columns: repeat(8, 1fr); justify-items: center; align-items: end; padding-top: var(--lien); opacity: 0; transform: translateY(-12px); transition: opacity .65s cubic-bezier(.22, 1, .36, 1), transform .65s cubic-bezier(.22, 1, .36, 1); }
.tour[data-r="0"] { padding-top: 0; } .tour[data-r="0"]::before { display: none; }
.tour.la { opacity: 1; transform: none; }
.tour::before { content: attr(data-nom); position: absolute; left: 0; bottom: calc(var(--u) * .9); font: 500 12px R; letter-spacing: .24em; text-transform: uppercase; color: var(--gris); }
.tour[data-r="1"] { grid-template-columns: repeat(4, 1fr); } .tour[data-r="2"] { grid-template-columns: repeat(2, 1fr); } .tour[data-r="3"] { grid-template-columns: 1fr; }
.affiche { display: flex; align-items: center; --c: calc(var(--u) * 6.1); }
.affiche em, .case em { font: 700 calc(var(--u) * 1.05) T; font-style: normal; color: var(--gris); text-transform: uppercase; }
.affiche em { margin: 0 calc(var(--u) * -1.5); position: relative; z-index: 1; }
.tour i { display: block; flex: none; position: relative; width: var(--c); height: var(--c); margin-bottom: calc(var(--c) * .2); }
.tour i s { position: absolute; inset: 0; background: 0 0 / 900% 100% no-repeat; image-rendering: pixelated; animation: garde .68s step-end infinite; }
.tour i s.miroir { transform: scaleX(-1); }
/* de temps en temps, l'un des deux lance un direct */
.affiche:nth-child(3n+1) i:first-child s, .affiche:nth-child(3n) i:last-child s { animation-name: garde-direct; animation-duration: 2.72s; }
.tour i::after { content: ""; position: absolute; left: 36%; top: 100%; width: 34%; aspect-ratio: 3 / 2; transform: translateX(-50%); background: var(--d) center / cover; outline: 1px solid #ffffff40; }
.affiche i:last-child::after { left: 64%; }
@keyframes garde { 0% { background-position: 0 0 } 25% { background-position: 12.5% 0 } 50% { background-position: 25% 0 } 75% { background-position: 37.5% 0 } }
@keyframes garde-direct { 0%, 25%, 50% { background-position: 0 0 } 6%, 31%, 56% { background-position: 12.5% 0 } 12%, 37%, 62% { background-position: 25% 0 } 18%, 43%, 68% { background-position: 37.5% 0 } 75% { background-position: 50% 0 } 88% { background-position: 0 0 } }
.case { position: relative; display: flex; align-items: center; justify-content: center; gap: calc(var(--u) * .9); min-width: calc(var(--u) * 11); padding: calc(var(--u) * .8) calc(var(--u) * 1.4); border: 2px solid #ffffff38; background: #0b0b0ecc; }
.case u { text-decoration: none; font: 700 calc(var(--u) * 2.3)/1 T; color: #ffffff8c; }
/* la fourche : deux descentes depuis les cases du dessus, une barre, une tige vers la case */
.case::before { content: ""; position: absolute; left: 25%; right: 25%; bottom: calc(100% + var(--lien) * .5); height: calc(var(--lien) * .5); border: 2px solid var(--or); border-bottom: 0; margin: 0 -1px; opacity: .75; }
.case::after { content: ""; position: absolute; left: 50%; bottom: 100%; width: 2px; height: calc(var(--lien) * .5); background: var(--or); transform: translateX(-50%); opacity: .75; }
.tour[data-r="1"] .case::before { left: 28%; right: 28%; }
.tour[data-r="3"] .case { border-color: var(--or); } .tour[data-r="3"] .case u { color: var(--or); }
#ceinture { position: relative; align-self: center; width: calc(var(--u) * 20); text-align: center; padding-top: calc(var(--lien) * .7); opacity: 0; transform: translateY(-12px) scale(.94); transition: opacity 1s cubic-bezier(.22, 1, .36, 1), transform 1s cubic-bezier(.22, 1, .36, 1); pointer-events: none; }
#ceinture::before { content: ""; position: absolute; left: 50%; top: 0; width: 2px; height: calc(var(--lien) * .7); background: var(--or); transform: translateX(-50%); }
#ceinture.la { opacity: 1; transform: none; }
#ceinture p { font: 700 calc(var(--u) * 1.7)/1 T; text-transform: uppercase; color: var(--or); margin-top: 4px; letter-spacing: .04em; }
.pied { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; margin-top: auto; }
.pied small { margin: 0; }
@media (max-width: 760px) {
  .tableau { --u: 2.5vw; --lien: 14px; } .tour::before { display: none; } .serie { display: none; }
  .tour[data-r="0"] { grid-template-columns: repeat(4, 1fr); row-gap: 10px; } .affiche { --c: calc(var(--u) * 4.6); } .affiche em { display: none; }
  .tour[data-r="1"] .case::before { display: none; } .case { min-width: 0; padding: 7px 9px; gap: 5px; }
  #ceinture { width: 44vw; } .pied { gap: 8px; } .pied small { font-size: 12px; }
}

/* 5 · le retour : le constat en haut, les quatre actions sur un rail horizontal en bas */
.retour { inset: 96px 0 0 0; }
.retour > .sur, .retour > h2, .constat { margin-left: var(--marge); margin-right: var(--marge); max-width: min(46vw, 640px); }
.constat { display: grid; grid-template-columns: 1fr; gap: 6px; margin-top: clamp(14px, 3vh, 34px); transition: opacity .65s; }
.constat .geant { font-size: clamp(74px, 9vw, 150px); color: var(--eau); }
.constat small { margin-top: 0; }
.retour h2 { font-size: clamp(40px, min(6.2vw, 10.5vh), 100px); }
.constat p, .constat small { transition: opacity .65s cubic-bezier(.22, 1, .36, 1); }
.retour.actions-la .constat p, .retour.actions-la .constat small { opacity: 0; }
.rejoints { margin: 4px var(--marge) 0; color: var(--eau); font: 700 clamp(20px, 1.8vw, 27px)/1 T; text-transform: uppercase; letter-spacing: .04em; opacity: 0; transition: opacity .65s cubic-bezier(.22, 1, .36, 1); }
.rejoints b { font-size: 1.5em; }
.retour.actions-la .rejoints { opacity: 1; }
.retour.actions-la .constat p, .retour.actions-la .constat small { position: absolute; }
.rail { position: absolute; left: 0; right: 0; bottom: clamp(26px, 5vh, 56px); overflow: hidden; opacity: 0; transform: translateY(40px); transition: opacity .65s cubic-bezier(.22, 1, .36, 1), transform .65s cubic-bezier(.22, 1, .36, 1); }
.retour.actions-la .rail { opacity: 1; transform: none; }
.actes { display: flex; gap: 18px; padding: 0 var(--marge); width: max-content; will-change: transform; }
.actes figure { margin: 0; width: clamp(200px, min(21vw, 29vh), 330px); flex: none; }
.actes img, .actes video { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.actes figcaption { display: flex; gap: 12px; align-items: baseline; margin-top: 12px; font: 700 clamp(20px, 1.8vw, 27px)/1.1 T; text-transform: uppercase; }
.actes figcaption b { color: var(--eau); font-size: .7em; }
.actes .mot { width: clamp(280px, 30vw, 460px); flex: none; align-self: center; border-left: 3px solid var(--eau); padding-left: 20px; }
.actes .mot p + p { margin-top: 14px; font: 700 clamp(22px, 2vw, 30px)/1.1 T; text-transform: uppercase; }
@media (max-width: 760px) { .retour > .sur, .retour > h2, .constat { max-width: none; } }
@media (max-height: 760px) { .constat p { font-size: 17px; } .actes figure { width: clamp(200px, 22vw, 320px); } }

/* 6 · partenaires : l'appel, une liste en lignes */
.appel { position: relative; margin: 120px var(--marge) 90px; max-width: min(640px, 100%); }
.temps { list-style: none; padding: 0; margin: 40px 0 0; border-top: 2px solid var(--trait); }
.temps li { display: grid; grid-template-columns: clamp(120px, 14vw, 190px) 1fr; gap: 14px; align-items: baseline; padding: 18px 0; border-bottom: 2px solid var(--trait); color: var(--doux); }
.temps b { font: 700 clamp(28px, 2.8vw, 42px)/1 T; text-transform: uppercase; color: var(--papier); }
@media (max-width: 600px) { .temps li { grid-template-columns: 1fr; gap: 4px; } }

footer { position: relative; z-index: 3; background: var(--fond); padding: 40px var(--marge); display: flex; flex-wrap: wrap; gap: 16px 36px; align-items: center; color: var(--gris); font-size: 15px; letter-spacing: .04em; border-top: 2px solid var(--trait); }
footer img { height: 44px; }
footer span { flex: 1; min-width: 240px; }
footer a { text-underline-offset: 3px; }
.cloche { color: #55575f; display: grid; place-items: center; width: 44px; height: 44px; transition: color .2s, transform .2s; transform-origin: 50% 20%; }
.cloche:hover, .cloche:focus-visible { color: var(--or); animation: ding .5s ease-in-out 2; }
@keyframes ding { 0%, 100% { transform: rotate(0) } 25% { transform: rotate(-14deg) } 75% { transform: rotate(14deg) } }

/* le jeu, ouvert par la cloche */
#jeu { position: fixed; inset: 0; z-index: 50; background: #000; display: none; }
#jeu.ouvert { display: block; }
#jeu iframe { width: 100%; height: 100%; border: 0; }
#jeu button { position: absolute; right: 22px; top: 18px; z-index: 2; width: 48px; height: 48px; border: 0; background: #ffffff22; color: #fff; font: 500 28px/1 R; cursor: pointer; }
#jeu .mot-jeu { display: none; position: absolute; inset: 0; place-content: center; text-align: center; padding: 30px; font: 700 clamp(26px, 4vw, 54px)/1 T; text-transform: uppercase; }
#jeu.hors-ligne .mot-jeu { display: grid; }

#lecteur { position: fixed; inset: 0; z-index: 50; background: #000; display: none; }
#lecteur.ouvert { display: block; }
#lecteur video { width: 100%; height: 100%; object-fit: contain; }
#lecteur button { position: absolute; right: 22px; top: 18px; z-index: 2; width: 48px; height: 48px; border: 0; background: #ffffff22; color: #fff; font: 500 28px/1 R; cursor: pointer; }

/* téléphone : la carte reste au centre, le texte se lit sur un voile */
@media (max-width: 760px) {
  .droite { left: var(--marge); right: var(--marge); width: auto; top: auto; bottom: 22px; transform: none; }
  .droite h2 { font-size: 44px; } .droite .chapo { margin-top: 10px; font-size: 17px; }
  .puces { grid-template-columns: repeat(8, 1fr); gap: 4px; margin-top: 14px; } .puces button { padding: 6px 2px; font-size: 0; gap: 0; } .puces button img { width: 100%; height: auto; aspect-ratio: 3 / 2; }
  .fiche { margin-top: 12px; font-size: 16px; }
  .compteur .sur { bottom: calc(100% + 250px); }
  .retour h2 { font-size: 40px; } .constat .geant { font-size: 72px; } .constat p { font-size: 16px; } .rejoints { font-size: 17px; }
  .actes figure { width: 58vw; } .actes .mot { width: 74vw; }
  .suite { display: none; }
}
@media (prefers-reduced-motion: reduce) { .tour i s { animation: none !important; } html { scroll-behavior: auto; } .suite::after { animation: none; } }
