/*
  Démo interactive Nexus : thème sombre, cinématographique, retenu.

  COULEURS, deux seulement, chacune avec un sens (la règle du produit) :
    - bleu froid = les DONNÉES (barres, curseurs, onglet actif) ;
    - ambre = une DÉCISION HUMAINE (portes, bouton « Book a demo »).
  Le reste est noir pur et blanc lunaire à différentes opacités.

  CONTRASTES (fond #000) : --lune 17,9:1 ; --lune-douce 8,6:1 ;
  --lune-pale 5,1:1 (jamais sous 13 px). Le texte posé sur l'ambre est noir.

  POLICES : « Inter Tight » si elle est disponible, sinon Inter, hébergée
  avec la page (licence SIL OFL), resserrée par l'interlettrage.
*/

@font-face { font-family: Inter; src: url(../fonts/inter-latin.woff2) format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Inter Tight"; src: url(../fonts/inter-tight-latin.woff2) format("woff2"); font-weight: 300 500; font-display: swap; }
@font-face { font-family: Unbounded; src: url(../fonts/unbounded-latin.woff2) format("woff2"); font-weight: 500; font-display: swap; }

:root {
  --noir: #000000;
  --releve: #0A0C0F;
  --releve-2: #111419;
  --trait: rgb(237 237 238 / 0.09);
  --trait-fort: rgb(237 237 238 / 0.18);
  --lune: #EDEDEE;
  --lune-douce: #A3A8B0;
  --lune-pale: #7D838C;
  --bleu: #6E9BFF;
  --bleu-voile: rgb(110 155 255 / 0.14);
  --ambre: #E4AE55;
  --ambre-voile: rgb(228 174 85 / 0.10);
  --titre: "Inter Tight", Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  --texte: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  --etiquette: Unbounded, Inter, system-ui, sans-serif;
  --courbe: cubic-bezier(0.2, 0.7, 0.2, 1);
  --large: 1200px;
  --gouttiere: 32px;
}

* { box-sizing: border-box; }
/* Un display posé par une classe (.bouton…) ne doit jamais rendre visible un élément « hidden ». */
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; background: var(--noir); }
body { margin: 0; background: var(--noir); color: var(--lune-douce); font: 400 15.5px/1.6 var(--texte); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
img, video { display: block; max-width: 100%; height: auto; }
a { color: var(--lune); text-underline-offset: 3px; }
:focus-visible { outline: 2px solid var(--lune); outline-offset: 3px; border-radius: 6px; }
p { margin: 0 0 14px; }
.chiffre { font-variant-numeric: tabular-nums; }
.discret { font-size: 14px; color: var(--lune-pale); }
::selection { background: var(--bleu-voile); color: var(--lune); }

/* --- Typographie : titres fins, serrés, grands ----------------------------- */
h1, h2 { font-family: var(--titre); color: #FFFFFF; margin: 0; }
h3, h4 { font-family: var(--texte); color: var(--lune); margin: 0; }
h1 { font-weight: 300; font-size: clamp(42px, 5.4vw, 76px); line-height: 1.02; letter-spacing: -0.035em; max-width: 13em; }
h2 { font-weight: 300; font-size: clamp(32px, 3.6vw, 50px); line-height: 1.04; letter-spacing: -0.032em; max-width: 16em; }
h3 { font-weight: 500; font-size: 16px; }
h4 { font-weight: 500; font-size: 15px; margin-bottom: 8px; }
.intro { font-family: var(--titre); font-weight: 300; font-size: 20px; line-height: 1.4; letter-spacing: -0.015em; color: rgb(237 237 238 / 0.78); max-width: 34em; margin-top: 22px; }

.cadre { max-width: var(--large); margin: 0 auto; padding: 0 var(--gouttiere); }
.bloc { padding: 160px 0 0; }

/* --- Barre du haut ---------------------------------------------------------- */
.barre { position: fixed; inset: 0 0 auto; z-index: 30; height: 64px; display: flex; align-items: center; gap: 20px; padding: 0 var(--gouttiere); border-bottom: 1px solid transparent; transition: background .3s, border-color .3s, backdrop-filter .3s; }
.barre.defile { background: rgb(0 0 0 / 0.72); backdrop-filter: saturate(1.6) blur(18px); -webkit-backdrop-filter: saturate(1.6) blur(18px); border-bottom-color: var(--trait); }
.marque { font: 500 14px/1 var(--etiquette); letter-spacing: 0.16em; text-transform: uppercase; color: var(--lune); text-decoration: none; }
.barre-titre { font-size: 14px; color: var(--lune-pale); padding-left: 20px; border-left: 1px solid var(--trait-fort); }
.barre-actions { margin-left: auto; display: flex; align-items: center; gap: 12px; }

/* Bouton du son : quatre barres immobiles quand il est coupé, qui ondulent
   doucement quand il joue. Le texte dit l'état, pas seulement l'icône. */
.son { all: unset; cursor: pointer; display: inline-flex; align-items: center; gap: 10px; font-size: 14px; color: var(--lune-douce); padding: 8px 12px; border-radius: 2px; border: 1px solid var(--trait); transition: border-color .2s, color .2s; }
.son:hover { border-color: var(--trait-fort); color: var(--lune); }
.son:focus-visible { outline: 2px solid var(--lune); outline-offset: 2px; }
.son-ondes { display: inline-flex; align-items: center; gap: 2px; height: 12px; }
.son-ondes i { width: 2px; height: 4px; border-radius: 1px; background: currentColor; transition: height .3s var(--courbe); }
.son[aria-pressed="true"] { color: var(--lune); border-color: var(--trait-fort); }
.son[aria-pressed="true"] .son-ondes i { animation: onde 1.6s ease-in-out infinite; }
.son[aria-pressed="true"] .son-ondes i:nth-child(2) { animation-delay: -.4s; }
.son[aria-pressed="true"] .son-ondes i:nth-child(3) { animation-delay: -.8s; }
.son[aria-pressed="true"] .son-ondes i:nth-child(4) { animation-delay: -1.2s; }
@keyframes onde { 0%, 100% { height: 3px; } 50% { height: 12px; } }

/* --- Boutons ---------------------------------------------------------------- */
.bouton { display: inline-flex; align-items: center; justify-content: center; gap: 8px; font: 500 14.5px/1 var(--texte); letter-spacing: 0.01em; text-decoration: none; padding: 14px 20px; border-radius: 2px; border: 1px solid transparent; cursor: pointer; transition: background .2s, border-color .2s, color .2s, opacity .2s; white-space: nowrap; }
.bouton-petit { padding: 10px 18px; font-size: 14px; }
.bouton-clair { background: var(--lune); color: var(--noir); }
.bouton-clair:hover { background: #FFFFFF; }
.bouton-trait { background: transparent; color: var(--lune); border-color: var(--trait-fort); }
.bouton-trait:hover { border-color: var(--lune-douce); }
.bouton-decision { background: var(--ambre); color: var(--noir); }
.bouton-decision:hover { background: #EDBE6E; }
.bouton:disabled { cursor: default; opacity: 0.45; }

/* --- Ouverture : un seul moment chorégraphié -------------------------------- */
/* Le halo, plus large que l'écran, est rogné ici (« clip » : pas de zone de
   défilement créée, et le haut du halo reste visible). */
.ouverture { overflow-x: clip; position: relative; padding: 184px var(--gouttiere) 0; max-width: var(--large); margin: 0 auto; }
.ouverture::before { content: ""; position: absolute; z-index: -1; left: 50%; top: 52%; width: min(1400px, 140vw); height: 900px; transform: translateX(-50%); background: radial-gradient(closest-side, rgb(110 155 255 / 0.16), rgb(110 155 255 / 0.05) 55%, transparent 75%); pointer-events: none; }
.mention { font-size: 14px; color: var(--lune-pale); margin-bottom: 28px; }
.chapo { font-family: var(--titre); font-weight: 300; font-size: clamp(19px, 1.6vw, 22px); line-height: 1.32; letter-spacing: -0.02em; color: rgb(237 237 238 / 0.82); max-width: 28em; margin: 28px 0 0; }
.appel { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 40px; }
.ecran-ouverture { margin: 96px 0 0; position: relative; }
.ecran-ouverture img { border-radius: 10px; border: 1px solid var(--trait-fort); box-shadow: 0 0 0 1px rgb(0 0 0), 0 40px 120px -20px rgb(110 155 255 / 0.25); }
/* L'écran se fond dans le noir : il annonce la suite sans la montrer toute. */
.ecran-ouverture::after { content: ""; position: absolute; inset: 40% -1px -1px; background: linear-gradient(to bottom, transparent, var(--noir) 92%); border-radius: 0 0 10px 10px; }

.entree { opacity: 0; transform: translateY(18px); animation: entree 1s var(--courbe) forwards; animation-delay: 120ms; }
/* Ordre d'apparition en classes, pas en attribut style (CSP sans 'unsafe-inline'). */
.ordre-1 { animation-delay: 230ms; } .ordre-2 { animation-delay: 340ms; } .ordre-3 { animation-delay: 450ms; } .ordre-4 { animation-delay: 560ms; }
.ecran-ouverture.entree { transform: translateY(40px) scale(0.985); animation-duration: 1.4s; }
@keyframes entree { to { opacity: 1; transform: none; } }

/* --- Schéma du processus ---------------------------------------------------- */
.schema { position: relative; list-style: none; padding: 0; height: 120px; margin: 72px 0 40px; }
/* La ligne se trace de gauche à droite (échelle horizontale), pendant que
   les étapes s'allument une à une. */
.schema::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1px; background: var(--trait-fort); transform-origin: left; transform: scaleX(0); transition: transform 1.6s var(--courbe); }
.schema.vu::before { transform: none; }
.noeud { position: absolute; top: 50%; width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%; background: var(--noir); border: 1.5px solid var(--lune-pale); opacity: 0; transition: opacity .4s, transform .4s var(--courbe); transform: scale(0.6); }
.noeud.humain { width: 14px; height: 14px; margin: -7px 0 0 -7px; background: var(--ambre); border-color: var(--ambre); box-shadow: 0 0 24px rgb(228 174 85 / 0.45); }
.noeud em { position: absolute; top: 26px; left: 50%; transform: translateX(-50%); font-style: normal; font-size: 13px; color: var(--lune-douce); white-space: nowrap; }
/* Point ambre plus gros de 4 px : on compense pour aligner toutes les étiquettes. */
.noeud.humain em { top: 28px; }
/* Sept étapes réparties de 4 % à 96 % de la largeur. */
.noeud:nth-child(1) { left: 4.00%; } .noeud:nth-child(2) { left: 19.33%; } .noeud:nth-child(3) { left: 34.67%; } .noeud:nth-child(4) { left: 50.00%; } .noeud:nth-child(5) { left: 65.33%; } .noeud:nth-child(6) { left: 80.67%; } .noeud:nth-child(7) { left: 96.00%; }
.schema.vu .noeud { opacity: 1; transform: none; }
.schema.vu .noeud:nth-child(1) { transition-delay: 0.1s; }
.schema.vu .noeud:nth-child(2) { transition-delay: 0.3s; }
.schema.vu .noeud:nth-child(3) { transition-delay: 0.5s; }
.schema.vu .noeud:nth-child(4) { transition-delay: 0.7s; }
.schema.vu .noeud:nth-child(5) { transition-delay: 0.9s; }
.schema.vu .noeud:nth-child(6) { transition-delay: 1.1s; }
.schema.vu .noeud:nth-child(7) { transition-delay: 1.3s; }
.trois { display: grid; grid-template-columns: repeat(3, 1fr); gap: 48px; }
.trois > div { border-top: 1px solid var(--trait); padding-top: 24px; }
.trois h3 { margin-bottom: 10px; }
.trois p { font-size: 15px; }

/* --- Parcours guidé --------------------------------------------------------- */
.parcours { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 56px; margin-top: 64px; align-items: start; }
.etapes { position: sticky; top: 96px; }
.progression { height: 1px; background: var(--trait); margin-bottom: 18px; overflow: hidden; }
.progression span { display: block; height: 100%; background: var(--bleu); transform-origin: left; transform: scaleX(0.14); transition: transform .6s var(--courbe); }
.etapes ol { list-style: none; margin: 0; padding: 0; }
.etapes [role=tab] { all: unset; box-sizing: border-box; cursor: pointer; display: flex; align-items: baseline; gap: 14px; width: 100%; padding: 11px 14px; border-radius: 4px; font-size: 15px; color: var(--lune-pale); transition: color .2s, background .2s; }
.etapes [role=tab] b { font-weight: 500; font-size: 13px; font-variant-numeric: tabular-nums; width: 14px; color: var(--lune-pale); }
.etapes [role=tab]:hover { color: var(--lune); }
.etapes [role=tab].fait { color: var(--lune-douce); }
.etapes [role=tab].fait b { color: var(--bleu); }
.etapes [role=tab][aria-selected="true"] { color: var(--lune); background: var(--releve-2); }
.etapes [role=tab][aria-selected="true"] b { color: var(--lune); }
.etapes [role=tab]:focus-visible { outline: 2px solid var(--lune); outline-offset: -2px; }

.journal-visiteur { margin-top: 32px; padding-top: 22px; border-top: 1px solid var(--trait); }
.journal-visiteur h3 { font-size: 14px; margin-bottom: 8px; }
.journal-visiteur .discret { font-size: 13px; line-height: 1.5; }
#journal { list-style: none; margin: 0; padding: 0; font-size: 13px; line-height: 1.45; color: var(--lune-douce); }
#journal li, .journal-copie li { display: grid; grid-template-columns: 62px 1fr; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--trait); animation: apparait .45s var(--courbe); }
#journal time, .journal-copie time { color: var(--ambre); font-variant-numeric: tabular-nums; }
/* Copie du journal dans l'étape 7 : utile seulement quand la colonne
   latérale est masquée (petits écrans). */
.journal-copie { list-style: none; margin: 12px 0 14px; padding: 0; font-size: 13px; line-height: 1.45; display: none; }
@keyframes apparait { from { opacity: 0; transform: translateY(-4px); } }

.scene { min-width: 0; background: var(--releve); border: 1px solid var(--trait); border-radius: 10px; padding: 40px 44px 28px; }
.tableau { animation: tableau .5s var(--courbe); }
@keyframes tableau { from { opacity: 0; transform: translateY(10px); } }
.tableau-titre { font-weight: 300; font-size: 32px; letter-spacing: -0.03em; margin: 22px 0 26px; display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }
/* Rappel du besoin saisi à l'étape 1 : la saisie du visiteur a un effet visible. */
.rappel-besoin { margin: -10px 0 22px; padding: 12px 16px; border-left: 2px solid var(--bleu); background: var(--bleu-voile); border-radius: 0 10px 10px 0; color: var(--lune); font-size: 15px; }
.rappel-besoin span { display: block; font-size: 12px; color: var(--lune-douce); margin-bottom: 2px; }
/* Étiquettes techniques : Unbounded en capitales, comme les repères de terafab. */
.etiquette { font: 500 10.5px/1 var(--etiquette); letter-spacing: 0.06em; text-transform: uppercase; font-style: normal; color: var(--lune-douce); border: 1px solid var(--trait-fort); padding: 6px 8px 5px; border-radius: 2px; }
.pourquoi, .ensuite { font-size: 15px; line-height: 1.55; margin: 0; }
.pourquoi span, .ensuite span { display: block; font-size: 13px; color: var(--lune-pale); margin-bottom: 4px; }
.pourquoi { color: var(--lune); max-width: 44em; }
.ensuite { margin-top: 30px; padding-top: 20px; border-top: 1px solid var(--trait); color: var(--lune-douce); }

/* Champs de saisie : sobres, lisibles, clairement modifiables. */
.champ { display: block; border: 0; padding: 0; margin: 0 0 20px; min-width: 0; }
.champ > span, .champ > legend { display: flex; justify-content: space-between; font-size: 13px; color: var(--lune-douce); margin-bottom: 8px; padding: 0; }
.champ output { color: var(--lune); }
.champ small { display: block; font-size: 13px; color: var(--lune-pale); margin-top: 8px; line-height: 1.45; }
textarea, input[type=text], input[type=number], select { width: 100%; font: 400 15px/1.5 var(--texte); color: var(--lune); background: var(--noir); border: 1px solid var(--trait-fort); border-radius: 4px; padding: 12px 14px; transition: border-color .2s; }
textarea { resize: vertical; }
textarea:hover, input:hover, select:hover { border-color: rgb(237 237 238 / 0.3); }
textarea:focus, input:focus, select:focus { outline: none; border-color: var(--bleu); box-shadow: 0 0 0 3px var(--bleu-voile); }
select:disabled { opacity: 0.4; }
::placeholder { color: var(--lune-pale); }
input[type=range] { width: 100%; accent-color: var(--bleu); height: 24px; }
.ligne-actions { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 16px; margin-bottom: 26px; }
.ligne-actions .champ { margin: 0; width: 200px; }
/* Même hauteur que le menu voisin, pour une ligne de base commune. */
.ligne-actions .bouton { height: 48px; }
.grille-deux { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

.sortie { background: var(--noir); border-radius: 6px; padding: 20px 22px; margin-bottom: 20px; }
.sortie .discret { margin: 10px 0 0; }
.puces { list-style: none; margin: 0; padding: 0; font-size: 15px; }
.puces li { position: relative; padding: 5px 0 5px 18px; }
.puces li::before { content: ""; position: absolute; left: 0; top: 15px; width: 6px; height: 1px; background: var(--lune-pale); }
.puces-deux { display: grid; grid-template-columns: 1fr 1fr; gap: 0 32px; margin: 24px 0; }

.pastilles { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.pastille { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; color: var(--lune); background: var(--bleu-voile); border: 1px solid rgb(110 155 255 / 0.3); border-radius: 2px; padding: 5px 6px 5px 12px; }
.pastille button { all: unset; cursor: pointer; width: 20px; height: 20px; border-radius: 50%; text-align: center; line-height: 20px; color: var(--lune-douce); }
.pastille button:hover { background: rgb(237 237 238 / 0.12); color: var(--lune); }
.pastille button:focus-visible { outline: 2px solid var(--lune); }

/* Portes : la seule surface ambre de la scène. */
.porte { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin: 26px 0 0; padding: 20px 22px; border-radius: 6px; background: var(--ambre-voile); border: 1px solid rgb(228 174 85 / 0.35); }
.porte h4 { color: var(--lune); }
.porte p { margin: 0; font-size: 14px; }
.porte.validee { background: transparent; border-color: var(--trait); }
.porte + .champ { margin-top: 28px; }
.porte.validee h4::after { content: " · recorded"; color: var(--ambre); font-weight: 400; }

.segments { display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 4px; border-radius: 4px; border: 1px solid var(--trait); background: var(--noir); }
.segments button { all: unset; cursor: pointer; font-size: 14px; padding: 8px 14px; border-radius: 2px; color: var(--lune-douce); transition: background .2s, color .2s; }
.segments button:hover { color: var(--lune); }
.segments [aria-checked="true"], .segments [aria-pressed="true"] { background: var(--releve-2); color: var(--lune); box-shadow: inset 0 0 0 1px var(--trait-fort); }
.segments button:focus-visible { outline: 2px solid var(--lune); }
#note-statut { margin-top: 10px; }
.segments-ecrans { margin-bottom: 18px; }

.capture { margin: 0 0 8px; }
.capture img { border-radius: 6px; border: 1px solid var(--trait-fort); background: var(--releve-2); }
.capture figcaption { font-size: 13px; color: var(--lune-pale); margin-top: 10px; }

/* Pré-tri : trois groupes proportionnels au nombre reçu. */
.pretri { font-size: 15px; margin: 4px 0 0; min-height: 52px; }
.pretri strong { color: var(--lune); font-weight: 500; }
.groupes { display: flex; gap: 4px; margin-top: 14px; }
.groupes > div { min-width: 0; padding: 10px 12px; border-radius: 8px; font-size: 13px; display: flex; flex-direction: column; gap: 2px; overflow: hidden; white-space: nowrap; transition: flex .5s var(--courbe); }
.groupes b { font-size: 18px; font-weight: 500; color: var(--lune); }
.groupe-liste { background: rgb(110 155 255 / 0.24); }
.groupe-reserve { background: rgb(110 155 255 / 0.12); }
.groupe-ecart { background: var(--releve-2); border: 1px solid var(--trait); }

/* Calcul de la note. */
.calcul { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 36px; align-items: start; }
.cases { display: flex; flex-wrap: wrap; gap: 8px; }
.cases label { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--lune); padding: 7px 12px; border: 1px solid var(--trait-fort); border-radius: 8px; cursor: pointer; }
.cases input { accent-color: var(--bleu); margin: 0; }
.resultat { position: sticky; top: 100px; background: var(--noir); border-radius: 8px; padding: 26px; }
.note { font: 300 104px/0.9 var(--titre); letter-spacing: -0.06em; color: var(--lune); }
.note small { font-size: 26px; font-weight: 300; letter-spacing: -0.02em; color: var(--lune-pale); margin-left: 6px; }
.barre-note { display: flex; gap: 3px; height: 10px; margin: 26px 0 22px; }
.barre-note span { position: relative; background: rgb(110 155 255 / 0.13); border-radius: 3px; overflow: hidden; }
.barre-note i { position: absolute; inset: 0; background: var(--bleu); transform-origin: left; transition: transform .5s var(--courbe); }
.barre-note .modele i { background: repeating-linear-gradient(135deg, var(--bleu) 0 4px, rgb(110 155 255 / 0.45) 4px 6px); }
.detail { width: 100%; border-collapse: collapse; font-size: 14px; margin-bottom: 14px; }
.detail th { text-align: left; font-weight: 400; color: var(--lune-pale); font-size: 12px; padding: 0 0 8px; border-bottom: 1px solid var(--trait); }
.detail td { padding: 9px 0; border-bottom: 1px solid var(--trait); color: var(--lune-douce); }
.detail td:first-child { color: var(--lune); }
.nombre { text-align: right; font-variant-numeric: tabular-nums; }
/* Les colonnes chiffrées respirent entre elles (« Weight Score Points »). */
.detail .nombre { padding-left: 14px; white-space: nowrap; }
/* Dans le calculateur, la colonne des saisies est étroite : les menus
   s'empilent plutôt que de tronquer leur texte. */
.calcul .grille-deux { grid-template-columns: 1fr; gap: 0; }
.etiquette-modele { font: 500 9.5px/1 var(--etiquette); letter-spacing: 0.06em; text-transform: uppercase; font-style: normal; color: var(--bleu); border: 1px solid rgb(110 155 255 / 0.4); border-radius: 2px; padding: 3px 5px 2px; margin-left: 6px; vertical-align: 1px; }

.navigation-etapes { display: flex; align-items: center; justify-content: space-between; margin-top: 28px; }

/* --- Film ------------------------------------------------------------------- */
.film { margin-top: 56px; width: 100%; border-radius: 8px; border: 1px solid var(--trait-fort); background: var(--releve); }

/* --- Preuves ---------------------------------------------------------------- */
.mesures { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; margin-top: 64px; border-top: 1px solid var(--trait); }
.mesures > div { padding: 32px 32px 32px 0; }
.mesures > div + div { padding-left: 32px; border-left: 1px solid var(--trait); }
.valeur { display: block; font: 300 72px/1 var(--titre); letter-spacing: -0.05em; color: var(--lune); margin-bottom: 14px; }
.mesures p { font-size: 15px; margin: 0; }
.limites { margin-top: 48px; padding: 28px 32px; border: 1px solid var(--trait); border-radius: 6px; }
.limites .puces-deux { margin: 14px 0 0; }

.fin { padding-bottom: 160px; text-align: left; }
.pied { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 32px; max-width: var(--large); margin: 0 auto; padding: 32px var(--gouttiere) 48px; border-top: 1px solid var(--trait); font-size: 13px; color: var(--lune-pale); }
.pied a { color: var(--lune-pale); }

/* --- Petits écrans ---------------------------------------------------------- */
@media (max-width: 1000px) {
  .parcours { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .etapes { position: sticky; top: 64px; z-index: 10; background: var(--noir); margin: 0 calc(var(--gouttiere) * -1); padding: 10px var(--gouttiere) 8px; border-bottom: 1px solid var(--trait); }
  .etapes ol { display: flex; overflow-x: auto; gap: 4px; scrollbar-width: none; }
  .etapes ol::-webkit-scrollbar { display: none; }
  .etapes [role=tab] { width: auto; white-space: nowrap; padding: 8px 12px; font-size: 14px; }
  .progression { margin-bottom: 8px; }
  .journal-visiteur { display: none; }
  .journal-copie { display: block; }
  .calcul { grid-template-columns: minmax(0, 1fr); }
  .resultat { position: static; }
  .trois { grid-template-columns: 1fr; gap: 28px; }
}
@media (max-width: 640px) {
  :root { --gouttiere: 16px; }
  .barre-titre, .son-texte { display: none; }
  .ouverture { padding-top: 124px; }
  .ecran-ouverture { margin-top: 56px; }
  .bloc { padding-top: 104px; }
  .scene { padding: 24px 18px 18px; border-radius: 8px; margin: 0 -4px; }
  .tableau-titre { font-size: 26px; }
  .grille-deux, .puces-deux { grid-template-columns: 1fr; }
  .porte { flex-direction: column; align-items: stretch; }
  .note { font-size: 84px; }
  .mesures { grid-template-columns: 1fr; }
  .mesures > div, .mesures > div + div { padding: 24px 0; border-left: 0; }
  .mesures > div + div { border-top: 1px solid var(--trait); }
  .limites { padding: 22px 18px; }
  .schema { margin: 48px 0 28px; height: 80px; }
  /* Sept étiquettes ne tiennent pas sur une ligne : une sur deux passe
     au-dessus du trait. */
  .noeud em { font-size: 11px; top: 20px; }
  .noeud:nth-child(even) em { top: -24px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .entree, .tableau, #journal li { animation: none; opacity: 1; transform: none; }
  .schema::before { transform: none; transition: none; }
  .noeud { opacity: 1; transform: none; transition: none; }
  .son[aria-pressed="true"] .son-ondes i { animation: none; height: 8px; }
  * { transition-duration: 0s !important; }
}
