/* Le calendrier de l'héritier. Charte de la chaîne « Héritage, mode d'emploi ». */

@font-face { font-family: "Archivo"; src: url("/fonts/archivo.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Bebas Neue"; src: url("/fonts/bebas.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("/fonts/mono.woff2") format("woff2"); font-weight: 400 800; font-display: swap; }

:root {
  --nuit: #0d1524;
  --nuit-2: #152036;
  --nuit-3: #22304d;
  --creme: #f6f0e4;
  --papier: #fcf9f3;
  --encre: #1a2232;
  --gris: #4a5366;
  --gris-nuit: #bcc5d6;
  --or: #d9b65c;
  --or-fonce: #7a5c14;
  --brique: #e3695d;
  --brique-fonce: #a63a2f;
  --filet: rgba(13, 21, 36, 0.14);
  --filet-nuit: rgba(246, 240, 228, 0.16);
  --texte: "Archivo", system-ui, -apple-system, "Segoe UI", sans-serif;
  --affiche: "Bebas Neue", "Archivo", sans-serif;
  --chiffres: "JetBrains Mono", ui-monospace, monospace;
  --largeur: 1180px;
  --gouttiere: clamp(1rem, 4vw, 2.5rem);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 1rem; }
body {
  margin: 0;
  background: var(--nuit);
  color: var(--creme);
  font-family: var(--texte);
  font-size: 1.1875rem;
  line-height: 1.62;
  font-weight: 430;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-underline-offset: 0.18em; }
h1, h2, h3, h4 { margin: 0; line-height: 1.15; font-weight: 700; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; }
[hidden] { display: none !important; }

:focus-visible { outline: 3px solid var(--or); outline-offset: 3px; border-radius: 4px; }
.resultat :focus-visible, .questionnaire :focus-visible, .avertissement :focus-visible { outline-color: var(--or-fonce); }

.evitement {
  position: absolute; left: 1rem; top: -4rem; z-index: 10;
  background: var(--or); color: var(--nuit); padding: 0.6rem 1rem; border-radius: 6px; font-weight: 700;
}
.evitement:focus { top: 1rem; }

/* ---------- En-tête ---------- */
.entete {
  max-width: var(--largeur); margin: 0 auto; padding: 1.25rem var(--gouttiere);
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.marque { display: inline-flex; align-items: center; gap: 0.75rem; text-decoration: none; font-weight: 650; font-size: 1.05rem; }
.marque img { width: 40px; height: 40px; border-radius: 50%; border: 2px solid var(--or); }
.entete-lien { font-size: 1rem; color: var(--gris-nuit); }
.entete-lien:hover { color: var(--creme); }

/* ---------- Accueil ---------- */
.accueil {
  max-width: var(--largeur); margin: 0 auto;
  padding: clamp(1.5rem, 5vw, 4rem) var(--gouttiere) clamp(3rem, 7vw, 6rem);
  display: grid; gap: clamp(2rem, 5vw, 4.5rem);
  grid-template-columns: minmax(0, 1fr);
  position: relative;
}
.accueil::before {
  /* la frise de la bannière, en filigrane */
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px;
  background: linear-gradient(90deg, transparent, rgba(217, 182, 92, 0.35), transparent);
}
.accueil { grid-template-areas: "intro" "form" "plus"; }
.accueil-intro { grid-area: intro; }
.questionnaire { grid-area: form; }
.accueil-plus { grid-area: plus; }
@media (min-width: 960px) {
  .accueil {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
    grid-template-rows: auto 1fr;
    grid-template-areas: "intro form" "plus form";
    row-gap: 0; align-items: start;
  }
  .accueil-plus { padding-top: 2.5rem; }
}
@media (max-width: 959px) {
  .accueil { gap: 1.75rem; padding-top: 1rem; }
  .accueil h1 { font-size: clamp(1.95rem, 8.4vw, 2.6rem); max-width: 18ch; }
  .chapo { margin-top: 1rem; font-size: 1.05rem; }
  .garanties { margin-top: 0; }
}
@media (max-width: 480px) {
  .entete { padding-block: 0.9rem; }
  .marque { font-size: 0.98rem; gap: 0.6rem; }
  .marque img { width: 34px; height: 34px; }
  .entete-lien { font-size: 0.95rem; text-align: right; }
}
.produit { color: var(--or); font-weight: 650; font-size: 1.05rem; margin-bottom: 1rem; }
.accueil h1 {
  font-size: clamp(2.2rem, 5.4vw, 3.6rem); letter-spacing: -0.015em; line-height: 1.06;
  font-weight: 760; max-width: 15ch; text-wrap: balance;
}
.chapo { margin-top: 1.5rem; font-size: clamp(1.1rem, 1.8vw, 1.3rem); color: #e4dfd3; max-width: 34em; }
.garanties { list-style: none; margin-top: 1.75rem; display: grid; gap: 0.55rem; color: var(--gris-nuit); font-size: 1rem; }
.garanties li { display: flex; gap: 0.7rem; align-items: baseline; }
.garanties li::before { content: ""; flex: none; width: 0.55rem; height: 0.55rem; border-radius: 50%; border: 2px solid var(--or); transform: translateY(-0.05em); }

.antoine {
  margin: 2.5rem 0 0; display: flex; gap: 1.1rem; align-items: flex-start; max-width: 34em;
}
.antoine img { flex: none; width: 80px; height: 80px; border-radius: 50%; border: 3px solid var(--or); object-fit: cover; }
.antoine blockquote {
  margin: 0; position: relative; background: var(--nuit-2); border: 1px solid var(--filet-nuit);
  border-radius: 4px 18px 18px 18px; padding: 1.05rem 1.25rem; font-size: 1.08rem; line-height: 1.5;
}
.antoine figcaption { margin-top: 0.6rem; font-size: 0.98rem; line-height: 1.45; color: var(--gris-nuit); }

/* ---------- Questionnaire ---------- */
.questionnaire {
  background: var(--creme); color: var(--encre);
  border-radius: 18px; padding: clamp(1.25rem, 3.5vw, 2.25rem);
  box-shadow: 0 30px 80px -30px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(217, 182, 92, 0.35);
  display: grid; gap: 1.5rem;
}
.questionnaire h2 { font-size: 1.35rem; }
.champ { display: grid; gap: 0.45rem; }
.champ label, .choix legend { font-weight: 650; font-size: 1.08rem; }
input[type="date"], input[type="text"], input[type="email"] {
  font: inherit; font-size: 1.15rem; color: var(--encre);
  width: 100%; min-height: 3.25rem; padding: 0.6rem 0.9rem;
  background: var(--papier); border: 2px solid #c9bfa8; border-radius: 10px;
}
input[type="date"] { font-family: var(--texte); appearance: none; -webkit-appearance: none; }
input:hover { border-color: #a99d80; }
input[aria-invalid="true"], fieldset[aria-invalid="true"] .segments span { border-color: var(--brique-fonce); }

.choix { border: 0; margin: 0; padding: 0; min-width: 0; }
.choix legend { padding: 0; margin-bottom: 0.55rem; }
.segments { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.5rem; }
.segments--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.segments label { position: relative; display: block; }
.segments input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.segments span {
  display: flex; align-items: center; justify-content: center; text-align: center;
  min-height: 3.4rem; padding: 0.45rem 0.6rem; line-height: 1.2;
  border: 2px solid #c9bfa8; border-radius: 10px; background: var(--papier);
  font-weight: 580; font-size: 1.06rem; cursor: pointer; transition: background-color 160ms ease, border-color 160ms ease, box-shadow 220ms ease, color 160ms ease;
}
.segments input:hover + span { border-color: var(--nuit); }
.segments input:checked + span { background: var(--nuit); border-color: var(--nuit); color: var(--creme); box-shadow: inset 0 -3px 0 var(--or); }
.segments input:focus-visible + span { outline: 3px solid var(--or-fonce); outline-offset: 2px; }
@media (max-width: 420px) {
  .segments--3 { grid-template-columns: minmax(0, 1fr); }
  .segments--3 span { justify-content: flex-start; padding-left: 1rem; }
}

.erreur { color: var(--brique-fonce); font-size: 1rem; font-weight: 650; margin-top: 0.35rem; }
.note { font-size: 1rem; line-height: 1.5; color: var(--gris); }
.questionnaire .note a { color: var(--encre); }

.bouton {
  font: inherit; font-weight: 700; font-size: 1.08rem; cursor: pointer;
  min-height: 3.4rem; padding: 0.7rem 1.4rem; border-radius: 12px; border: 2px solid transparent;
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; text-align: center;
}
.bouton--or { background: var(--or); color: var(--nuit); border-color: var(--or); }
.bouton--or { transition: background-color 160ms ease, transform 120ms ease, box-shadow 160ms ease; }
.bouton--or:hover { background: #e6c673; box-shadow: 0 6px 18px -8px rgba(217, 182, 92, 0.8); }
.bouton--or:active { transform: translateY(1px); }
.bouton--or[disabled] { opacity: 0.7; cursor: progress; }
.bouton--contour { background: transparent; color: var(--encre); border-color: var(--encre); min-height: 3rem; font-size: 1.04rem; transition: background-color 160ms ease, color 160ms ease; }
.bouton--contour:hover { background: var(--encre); color: var(--creme); }
.bouton--lien { background: none; border: 0; color: var(--encre); text-decoration: underline; padding-inline: 0.4rem; min-height: 3rem; font-size: 1.04rem; font-weight: 600; }

/* ---------- Résultat ---------- */
.resultat {
  background: var(--creme); color: var(--encre);
  padding: clamp(2.5rem, 6vw, 5rem) var(--gouttiere);
}
.resultat > * { max-width: 980px; margin-inline: auto; }
.impression-entete { display: none; }
.resultat-tete { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1.25rem 2rem; }
.resultat h2 { font-size: clamp(1.9rem, 4vw, 2.6rem); letter-spacing: -0.01em; }
.resultat h2:focus { outline: none; }
.resultat-resume { margin-top: 0.5rem; font-size: 1.1rem; color: var(--gris); }
.resultat-resume strong { color: var(--encre); font-weight: 650; }
.resultat-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; }

.prochaine {
  margin-top: 2rem; background: var(--nuit); color: var(--creme);
  border-radius: 16px; padding: 1.4rem 1.6rem; display: grid; gap: 0.3rem;
  border-left: 6px solid var(--or);
}
.prochaine-libelle { color: var(--or); font-weight: 650; font-size: 1.06rem; }
.prochaine-titre { font-size: clamp(1.25rem, 2.6vw, 1.6rem); font-weight: 700; line-height: 1.25; }
.prochaine-titre a { text-decoration: none; }
.prochaine-titre a:hover { text-decoration: underline; }
.prochaine-date { color: var(--gris-nuit); font-size: 1.06rem; }
.prochaine-date::first-letter { text-transform: uppercase; }

/* Frise proportionnelle */
.frise { margin-top: 3rem; padding: 2.4rem 0 0; }
.frise-rail { position: relative; height: 4px; border-radius: 4px; background: rgba(13, 21, 36, 0.14); }
.frise-ecoule { position: absolute; left: 0; top: 0; bottom: 0; background: var(--or); border-radius: 4px; transform-origin: left center; }
.frise-point {
  position: absolute; top: 50%; width: 14px; height: 14px; border-radius: 50%;
  transform: translate(-50%, -50%); background: var(--creme); border: 3px solid var(--or-fonce);
}
.frise-point--passe { background: var(--or); border-color: var(--or); }
.frise-point--alerte { border-color: var(--brique-fonce); }
.frise-auj { position: absolute; bottom: -10px; width: 2px; height: 30px; background: var(--brique-fonce); transform: translateX(-1px); }
.frise-auj span {
  position: absolute; bottom: calc(100% + 4px); white-space: nowrap;
  font-size: 0.95rem; font-weight: 700; color: var(--brique-fonce);
}
.frise-auj--gauche span { left: -2px; }
.frise-auj--droite span { right: -2px; }
.frise-libelles { position: relative; height: 3rem; margin-top: 0.9rem; font-size: 1rem; color: var(--gris); font-weight: 600; }
.frise-libelle { position: absolute; top: 0; transform: translateX(-50%); white-space: nowrap; }
.frise-libelle--debut { transform: none; }
.frise-libelle--fin { transform: translateX(-100%); }
.frise-libelle--un-mois { top: 1.45rem; }
@media (max-width: 560px) { .frise-libelle--debut { font-size: 0; } .frise-libelle--debut::after { content: "J0"; font-size: 1rem; } }

/* La frise détaillée */
.etapes { list-style: none; margin-top: 3rem; }
.etape {
  display: grid; grid-template-columns: 8.5rem minmax(0, 1fr); column-gap: 2.25rem;
  position: relative;
}
.etape-date { text-align: right; padding-top: 0.15rem; color: var(--nuit); }
.etape-sem { display: block; font-size: 1rem; color: var(--gris); font-weight: 580; }
.etape-jour { display: block; font-family: var(--affiche); font-size: 4.2rem; line-height: 0.9; letter-spacing: 0.01em; }
.etape-jour--texte { font-size: 2.4rem; line-height: 1; }
.etape-mois { display: block; font-family: var(--affiche); font-size: 1.45rem; letter-spacing: 0.05em; line-height: 1.1; }

.etape-corps {
  position: relative; padding: 0 0 3.25rem 2.25rem;
  border-left: 2px solid rgba(122, 92, 20, 0.45);
}
.etape-corps::before {
  content: ""; position: absolute; left: -10px; top: 0.6rem;
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--creme); border: 3px solid var(--or-fonce);
}
.etape:last-child .etape-corps { border-left-color: transparent; padding-bottom: 0; }
.etape--passe .etape-date { opacity: 0.5; }
.etape--passe .etape-corps::before { background: var(--or); border-color: var(--or); }
.etape--passe h3 { color: var(--gris); }
.etape--alerte .etape-corps::before { border-color: var(--brique-fonce); }
.etape--prochaine .etape-corps::before { width: 24px; height: 24px; left: -13px; top: 0.45rem; background: var(--or); border: 5px solid var(--nuit); box-shadow: 0 0 0 3px var(--or); }
.etape--annexe .etape-corps::before { border-style: dashed; }

.etape-repere { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.4rem 0.9rem; margin-bottom: 0.4rem; }
.repere { font-weight: 700; color: var(--or-fonce); font-size: 1.06rem; }
.etape--alerte .repere { color: var(--brique-fonce); }
.statut { font-family: var(--chiffres); font-size: 0.95rem; color: var(--gris); }
.etape--prochaine .statut { color: var(--encre); font-weight: 700; }
.etape h3 { font-size: clamp(1.3rem, 2.4vw, 1.6rem); letter-spacing: -0.005em; max-width: 30ch; }
.etape-quand { margin-top: 0.35rem; color: var(--gris); font-size: 1.06rem; }
.etape-intro { margin-top: 1rem; color: var(--gris); font-style: italic; }
.etape-report {
  margin-top: 1rem; padding: 0.8rem 1rem; border-radius: 10px;
  background: rgba(217, 182, 92, 0.18); border: 1px solid rgba(122, 92, 20, 0.35); font-size: 1rem;
}

.sous-titre, .groupe h4, .papiers h4 { font-size: 1.05rem; margin-top: 1.4rem; margin-bottom: 0.5rem; }
.groupe { margin-top: 0.4rem; }
.groupe + .groupe { border-top: 1px solid var(--filet); margin-top: 1.4rem; }
.afaire { list-style: none; display: grid; gap: 0.6rem; max-width: 40em; }
.afaire li { position: relative; padding-left: 1.3rem; }
.afaire li::before { content: ""; position: absolute; left: 0; top: 0.68em; width: 0.5rem; height: 2px; background: var(--or-fonce); }

.papiers {
  margin-top: 1.5rem; padding: 0.2rem 1.25rem 1.1rem; max-width: 40em;
  background: var(--papier); border: 1px solid var(--filet); border-radius: 12px;
}
.papiers h4 { margin-top: 0.9rem; }
.papiers ul { list-style: none; display: grid; gap: 0.5rem; font-size: 1.08rem; }
.papiers li { position: relative; padding-left: 1.85rem; }
.papiers li::before {
  /* une case à cocher, utile une fois imprimé */
  content: ""; position: absolute; left: 0; top: 0.28em; width: 1.05rem; height: 1.05rem;
  border: 2px solid var(--gris); border-radius: 3px;
}

.chapitres { margin-top: 1.25rem; display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 0.75rem; }
.chapitres p { font-size: 1rem; color: var(--gris); width: 100%; }
.chapitre {
  display: inline-flex; align-items: center; gap: 0.55rem; text-decoration: none;
  padding: 0.45rem 0.85rem 0.45rem 0.7rem; border-radius: 999px; min-height: 2.6rem;
  border: 1.5px solid var(--nuit); color: var(--nuit); font-weight: 600; font-size: 1.04rem; line-height: 1.25;
  transition: background-color 160ms ease, color 160ms ease;
}
.chapitre svg { flex: none; color: var(--brique-fonce); }
.chapitre:hover { background: var(--nuit); color: var(--creme); }
.chapitre:hover svg { color: var(--or); }
.chapitre-t { font-family: var(--chiffres); font-size: 0.9rem; opacity: 0.8; }
.groupe .chapitre { margin-top: 0.9rem; }

.replie { margin-top: 0.6rem; }
.replie summary { cursor: pointer; color: var(--gris); font-weight: 600; font-size: 1.04rem; padding: 0.45rem 0; width: fit-content; }
.replie summary:hover { color: var(--encre); }

.aujourdhui {
  display: grid; grid-template-columns: 8.5rem minmax(0, 1fr); column-gap: 2.25rem;
  align-items: center; margin: 0 0 0;
}
.aujourdhui p {
  grid-column: 2; position: relative; padding: 0 0 2.75rem 2.25rem; margin: 0;
  border-left: 2px dashed var(--brique-fonce); color: var(--brique-fonce); font-weight: 700; font-size: 1.08rem;
}
.aujourdhui p::first-letter { text-transform: uppercase; }
.aujourdhui-point { display: none; }
.aujourdhui p::before {
  content: ""; position: absolute; left: -8px; top: 0.3rem; width: 14px; height: 14px; border-radius: 50%;
  background: var(--brique-fonce);
}

.avertissement-court { margin-top: 2.5rem; padding-top: 1.25rem; border-top: 1px solid var(--filet); color: var(--gris); font-size: 1.04rem; }

@media (max-width: 680px) {
  .etape, .aujourdhui { grid-template-columns: minmax(0, 1fr); }
  .etape-date {
    text-align: left; display: flex; align-items: baseline; gap: 0.5rem; flex-wrap: wrap;
    padding: 0 0 0.6rem 1.75rem; border-left: 2px solid rgba(122, 92, 20, 0.45);
  }
  .etape:first-child .etape-date { border-left-color: transparent; }
  .etape-sem { order: 0; font-size: 0.95rem; }
  .etape-jour { font-size: 2.6rem; }
  .etape-jour--texte { font-size: 1.9rem; }
  .etape-mois { font-size: 1.35rem; }
  .etape-corps { padding-left: 1.75rem; padding-bottom: 2.5rem; }
  .etape-corps::before { top: -2.55rem; }
  .etape--prochaine .etape-corps::before { top: -2.75rem; }
  .aujourdhui p { grid-column: 1; padding-left: 1.75rem; padding-bottom: 2rem; }
  .papiers { padding-inline: 1rem; }
}

/* Le seul mouvement de la page : la frise se remplit jusqu'à aujourd'hui. */
@media (prefers-reduced-motion: no-preference) {
  .apparition .frise-ecoule { animation: ecoule 1100ms cubic-bezier(0.2, 0.7, 0.2, 1) both; }
  .apparition .frise-auj { animation: pointer 500ms 900ms ease-out both; }
  @keyframes ecoule { from { transform: scaleX(0); } to { transform: scaleX(1); } }
  @keyframes pointer { from { opacity: 0; transform: translate(-1px, 6px); } to { opacity: 1; transform: translateX(-1px); } }
}

/* ---------- Rappels ---------- */
.rappels {
  max-width: var(--largeur); margin: 0 auto;
  padding: clamp(3rem, 7vw, 5.5rem) var(--gouttiere);
  display: grid; gap: clamp(2rem, 5vw, 4rem); grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 900px) { .rappels { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; } }
.rappels h2 { font-size: clamp(1.8rem, 3.6vw, 2.4rem); letter-spacing: -0.01em; max-width: 18ch; }
.rappels-texte > p { margin-top: 1.1rem; color: #e4dfd3; max-width: 34em; }
.rappels-texte .rappels-intro { color: var(--gris-nuit); }
.rappels-liste { list-style: none; margin-top: 0.9rem; border-left: 2px solid rgba(217, 182, 92, 0.5); display: grid; }
.rappels-liste li { position: relative; padding: 0.35rem 0 0.35rem 1.4rem; display: grid; line-height: 1.35; }
.rappels-liste li::before {
  content: ""; position: absolute; left: -7px; top: 0.75rem; width: 12px; height: 12px; border-radius: 50%;
  background: var(--nuit); border: 2px solid var(--or);
}
.rappel-date { font-weight: 650; }
.rappel-date::first-letter { text-transform: uppercase; }
.rappel-libelle { color: var(--gris-nuit); font-size: 1rem; }

.rappels-bloc { background: var(--nuit-2); border: 1px solid var(--filet-nuit); border-radius: 18px; padding: clamp(1.25rem, 3.5vw, 2.25rem); }
.form-rappels { display: grid; gap: 1.2rem; }
.form-rappels .champ label { color: var(--creme); }
.form-rappels .erreur { color: #ff9d92; }
.form-rappels input[aria-invalid="true"] { border-color: #ff9d92; }
.form-rappels .note { color: var(--gris-nuit); }
.form-rappels .note a { color: var(--creme); }
.champ--piege { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.case { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 0.8rem; align-items: start; font-size: 1.04rem; line-height: 1.45; }
.case input { width: 1.45rem; height: 1.45rem; margin: 0.05rem 0 0; accent-color: var(--or); cursor: pointer; }
.case label { cursor: pointer; }
.case + .erreur { margin-top: -0.6rem; padding-left: 2.25rem; color: #ff9d92; }
.rappels-etat:empty { display: none; }
.rappels-etat { margin-top: 1rem; padding: 1rem 1.2rem; border-radius: 12px; font-weight: 560; line-height: 1.5; }
.rappels-etat--ok { background: rgba(217, 182, 92, 0.16); border: 1px solid var(--or); }
.rappels-etat--info { background: rgba(246, 240, 228, 0.08); border: 1px solid var(--filet-nuit); }
.rappels-etat--erreur { background: rgba(227, 105, 93, 0.14); border: 1px solid var(--brique); }

/* ---------- Avertissement et pied ---------- */
.avertissement { background: var(--papier); color: var(--encre); padding: clamp(2.5rem, 6vw, 4rem) var(--gouttiere); }
.avertissement > * { max-width: 46rem; margin-inline: auto; }
.avertissement h2 { font-size: 1.35rem; }
.avertissement p { margin-top: 0.9rem; color: var(--gris); }
.avertissement p:last-child { color: var(--encre); font-weight: 600; }

.pied {
  max-width: var(--largeur); margin: 0 auto; padding: 2rem var(--gouttiere) 2.5rem;
  display: flex; flex-wrap: wrap; gap: 1rem 2rem; justify-content: space-between; align-items: center;
  color: var(--gris-nuit); font-size: 1rem;
}
.pied nav { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; }
.pied a:hover { color: var(--creme); }

/* ---------- Pages de texte (mentions, confidentialité) ---------- */
.texte-page { background: var(--creme); color: var(--encre); padding: clamp(2rem, 6vw, 4.5rem) var(--gouttiere); }
.texte-page > div { max-width: 44rem; margin: 0 auto; }
.texte-page h1 { font-size: clamp(2rem, 4.5vw, 2.8rem); letter-spacing: -0.01em; }
.texte-page .maj { margin-top: 0.6rem; color: var(--gris); font-size: 1rem; }
.texte-page h2 { font-size: 1.35rem; margin-top: 2.4rem; }
.texte-page p, .texte-page ul { margin-top: 0.9rem; }
.texte-page ul { padding-left: 1.3rem; display: grid; gap: 0.4rem; }
.texte-page a { color: var(--encre); }
.a-completer { background: rgba(227, 105, 93, 0.16); border-bottom: 2px solid var(--brique-fonce); padding: 0 0.2rem; }
.retour { display: inline-block; margin-top: 2.5rem; font-weight: 650; }

/* ---------- Impression ---------- */
@media print {
  @page { margin: 14mm 14mm 16mm; }
  body { background: #fff; color: #000; font-size: 11pt; line-height: 1.45; }
  .entete, .accueil, .rappels, .avertissement, .pied, .resultat-actions, .frise, .evitement, .replie summary { display: none !important; }
  .resultat { background: #fff; color: #000; padding: 0; }
  .resultat > * { max-width: none; }
  .impression-entete { display: block; font-size: 9.5pt; color: #333; border-bottom: 1px solid #999; padding-bottom: 4mm; margin-bottom: 6mm; }
  .resultat h2 { font-size: 20pt; }
  .prochaine { background: #fff; color: #000; border: 1px solid #000; border-left-width: 4px; margin-top: 5mm; padding: 3mm 4mm; }
  .prochaine-libelle, .prochaine-date { color: #000; }
  .etapes { margin-top: 6mm; }
  .etape { grid-template-columns: 30mm minmax(0, 1fr); column-gap: 6mm; break-inside: avoid; page-break-inside: avoid; }
  .etape-jour { font-size: 30pt; }
  .etape-mois { font-size: 12pt; }
  .etape-corps { padding: 0 0 7mm 6mm; border-left: 1px solid #777; }
  .etape-corps::before { background: #fff !important; border: 2px solid #000 !important; width: 10px !important; height: 10px !important; left: -6px !important; top: 2mm !important; box-shadow: none !important; }
  .etape--passe .etape-date, .etape--passe h3 { opacity: 1; color: #000; }
  .repere, .etape--alerte .repere, .statut, .etape-quand, .etape-intro, .chapitres p { color: #000; }
  .papiers { background: #fff; border: 1px solid #999; break-inside: avoid; }
  .papiers li::before { border-color: #000; }
  .chapitre { border: 1px solid #555; color: #000; padding: 1mm 3mm; min-height: 0; font-size: 9.5pt; }
  .aujourdhui p { color: #000; border-left: 1px dashed #000; padding-left: 6mm; }
  .aujourdhui p::before { background: #000; }
  .aujourdhui { grid-template-columns: 30mm minmax(0, 1fr); column-gap: 6mm; }
  .avertissement-court { color: #000; }
  a { text-decoration: none; }
  .etape-report { background: #fff; border: 1px solid #000; }
}

.sans-papiers { margin-top: 1.25rem; color: var(--gris); font-size: 1rem; }

/* ---------- Accueil : ce que vous obtenez, avant et après ---------- */
.questionnaire-tete { display: grid; gap: 0.2rem; }
.questionnaire-tete p { color: var(--gris); font-size: 1.04rem; }
.accueil-sous-titre { font-size: 1.35rem; margin-top: 0.5rem; }
.obtenez { list-style: none; margin-top: 1rem; display: grid; gap: 0.85rem; max-width: 36em; }
.obtenez li { position: relative; padding-left: 2rem; color: #e4dfd3; }
.obtenez li::before {
  content: ""; position: absolute; left: 0; top: 0.42em; width: 1.05rem; height: 1.05rem; border-radius: 50%;
  border: 2px solid var(--or); background: radial-gradient(circle, var(--or) 0 3px, transparent 3.5px);
}
.obtenez strong { color: var(--creme); font-weight: 680; }
.avant-apres { margin-top: 2.25rem; display: grid; gap: 1rem; grid-template-columns: minmax(0, 1fr); max-width: 40em; }
@media (min-width: 640px) { .avant-apres { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.avant-apres > div { border-radius: 14px; padding: 1.1rem 1.25rem 1.2rem; display: grid; gap: 0.65rem; align-content: start; }
.avant-apres h3 { font-size: 1.06rem; margin-bottom: 0.15rem; }
.avant-apres p { font-size: 1.04rem; line-height: 1.45; position: relative; padding-left: 1.4rem; }
.avant { border: 1px solid var(--filet-nuit); color: var(--gris-nuit); }
.avant h3 { color: var(--gris-nuit); }
.avant p::before { content: ""; position: absolute; left: 0; top: 0.68em; width: 0.6rem; height: 2px; background: var(--gris-nuit); }
.apres { background: var(--nuit-2); border: 1px solid rgba(217, 182, 92, 0.45); }
.apres h3 { color: var(--or); }
.apres p::before { content: ""; position: absolute; left: 0.05rem; top: 0.38em; width: 0.42rem; height: 0.75rem; border: solid var(--or); border-width: 0 2px 2px 0; transform: rotate(45deg); }
.sources { margin-top: 1.1rem; font-size: 0.98rem; color: var(--gris-nuit); max-width: 36em; }
.accueil-plus .antoine { margin-top: 2.25rem; }

/* Sur grand écran assez haut, le questionnaire reste à portée pendant la lecture. */
@media (min-width: 960px) and (min-height: 880px) {
  .questionnaire { position: sticky; top: 1.25rem; }
}

/* Micro-animations : elles répondent à un geste, jamais pour décorer. */
.replie summary { list-style: none; display: inline-flex; align-items: center; gap: 0.5rem; }
.replie summary::-webkit-details-marker { display: none; }
.replie summary::before { content: ""; width: 0.5rem; height: 0.5rem; border: solid currentColor; border-width: 0 2px 2px 0; transform: rotate(-45deg); transition: transform 180ms ease; }
.replie[open] summary::before { transform: rotate(45deg); }
@media (prefers-reduced-motion: no-preference) {
  .segments input:checked + span { animation: choisi 260ms ease-out; }
  @keyframes choisi { from { box-shadow: inset 0 0 0 var(--or); } to { box-shadow: inset 0 -3px 0 var(--or); } }
  .apparition .etape--prochaine .etape-corps::before { animation: halo 1400ms 1100ms ease-out 2; }
  @keyframes halo { 0% { box-shadow: 0 0 0 3px var(--or); } 50% { box-shadow: 0 0 0 9px rgba(217, 182, 92, 0.25); } 100% { box-shadow: 0 0 0 3px var(--or); } }
  .replie[open] > :not(summary) { animation: deplie 220ms ease-out; }
  @keyframes deplie { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
  .rappels-etat:not(:empty) { animation: deplie 260ms ease-out; }
}
