/* Vitrine OCD Live (/) : mise en page et composants propres à l'accueil.
   Les jetons et composants partagés sont dans base.css. */

/* Encoches en paysage (viewport-fit=cover) : la marge latérale ne passe jamais sous
   l'encoche. Mêmes valeurs que base.css quand l'écran n'a pas d'encoche. */
:root {
  --encoche: max(env(safe-area-inset-left, 0px), env(safe-area-inset-right, 0px));
  --marge: max(20px, var(--encoche));
}
@media (max-width: 374.98px) {
  :root { --marge: max(16px, var(--encoche)); }
}
@media (min-width: 768px) {
  :root { --marge: max(32px, var(--encoche)); }
}
@media (min-width: 1024px) {
  :root { --marge: max(40px, var(--encoche)); }
}

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.contenu {
  width: 100%;
  max-width: calc(var(--largeur) + 2 * var(--marge));
  margin-inline: auto;
  padding-inline: var(--marge);
}

.section {
  padding-block: var(--section);
}

.tete {
  display: grid;
  gap: 12px;
  margin-bottom: var(--apres-titre);
}
.tete .t-intro,
.t-intro {
  max-width: 36rem;
}

section[id],
.programme {
  scroll-margin-top: 16px;
}
@media (min-width: 1024px) {
  section[id],
  .programme { scroll-margin-top: 88px; }
}

/* ---------- En-tête ---------- */

.entete {
  position: relative;
  z-index: 10;
  height: 56px;
}
.entete-pilule {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 56px;
  padding-inline: var(--marge);
}
.marque {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  color: var(--creme);
  text-decoration: none;
}
.marque img {
  width: auto;
  height: 22px;
}
.marque span {
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1;
}
.entete-nav,
.entete-actions {
  display: none;
}

@media (min-width: 1024px) {
  .entete {
    position: fixed;
    top: 12px;
    left: var(--marge);
    right: var(--marge);
    height: 60px;
  }
  .entete-pilule {
    max-width: var(--largeur-hero);
    height: 60px;
    margin-inline: auto;
    padding: 0 10px 0 24px;
    border-radius: var(--r-pilule);
    border: 1px solid transparent;
    background: rgb(29 22 18 / 0);
    transition:
      background-color 200ms ease,
      border-color 200ms ease,
      box-shadow 200ms ease;
  }
  .entete.defile .entete-pilule {
    background: rgb(29 22 18 / 0.72);
    border-color: var(--filet);
    box-shadow: var(--ombre-flottante);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
  }
  .marque img { height: 26px; }
  .entete-nav {
    display: flex;
    gap: 4px;
  }
  .entete-nav a,
  .entete-ecrire {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 0 14px;
    border-radius: var(--r-pilule);
    color: var(--creme);
    font-size: 0.9375rem;
    font-weight: 500;
    text-decoration: none;
    transition: color var(--d-survol) ease;
  }
  .entete-actions {
    display: flex;
    align-items: center;
    gap: 8px;
  }
  .bouton-entete {
    min-height: 40px;
    padding: 0 20px;
    font-size: 0.9375rem;
  }
  .pastille-entete { display: none !important; }
}
@media (hover: hover) and (pointer: fine) {
  .entete-nav a:hover,
  .entete-ecrire:hover { color: var(--lueur); }
}

/* ---------- Hero ---------- */

.hero {
  --scene: clamp(220px, calc(100svh - 330px), min(440px, 84.7vw));
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: calc(100svh - 56px);
  padding-bottom: 16px;
  overflow: hidden;
  text-align: center;
}
@media (max-width: 374.98px) {
  .hero { --scene: clamp(200px, calc(100svh - 360px), min(300px, 84.7vw)); }
}
@media (min-width: 768px) and (max-width: 1023.98px) {
  .hero { --scene: clamp(300px, calc(100svh - 420px), 520px); }
}

/* La scène est la boîte de la carte (960 x 1000), centrée sur l'écran. */
.scene {
  position: relative;
  z-index: 0;
  flex: none;
  width: calc(var(--scene) * 0.96);
  height: var(--scene);
  margin-top: -56px;
  margin-bottom: calc(var(--scene) * -0.05);
  margin-left: calc(50% - var(--scene) * 0.5904);
}
.carte-afrique {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}
.carte-fond {
  fill: rgb(255 154 61 / 0.035);
}
.carte-halo {
  fill: none;
  stroke: var(--orange);
  stroke-width: 12;
  stroke-linejoin: round;
  opacity: 0.55;
}
.carte-trait,
.carte-mada {
  fill: none;
  stroke: var(--lueur);
  stroke-width: 7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.carte-trait .moitie {
  stroke-dasharray: 1 1;
  stroke-dashoffset: 0;
}
.lome-point {
  fill: var(--lueur);
}
.lome-anneau {
  fill: none;
  stroke: var(--lueur);
  stroke-width: 6;
  opacity: 0.35;
}
.lome {
  transform-box: fill-box;
  transform-origin: center;
}
.lome-nom {
  position: absolute;
  right: calc(100% - 25%);
  top: 43%;
  translate: 0 -50%;
  color: var(--sable);
  font-size: var(--t-petit);
  font-weight: 500;
  line-height: 1;
  white-space: nowrap;
}
@media (max-height: 560px), (max-width: 374.98px) {
  .lome-nom { display: none; }
}

.hero-texte {
  position: relative;
  z-index: 2;
  display: grid;
  justify-items: center;
  gap: 12px;
  padding-inline: var(--marge);
}
.pastille-hero {
  display: none;
}
.hero-titre {
  font-size: var(--t-affiche);
  font-weight: 800;
  line-height: 0.95;
  letter-spacing: -0.035em;
  /* Le titre peut passer à la ligne : texte agrandi et très petits écrans (WCAG 1.4.4, 1.4.10). */
  text-wrap: balance;
  overflow-wrap: anywhere;
  hyphens: auto;
}
.hero-texte {
  grid-template-columns: minmax(0, 1fr);
}
@media (max-width: 399.98px) {
  .hero-titre { font-size: 2rem; }
}
.hero-sous {
  max-width: 22rem;
  color: var(--sable);
  font-size: var(--t-intro);
  line-height: 1.45;
  text-wrap: balance;
}

.choix {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  padding: 24px var(--marge) 0;
  text-align: left;
}
.tuile-face {
  gap: 4px;
  min-height: 100%;
  padding: 14px 14px 16px;
}
.tuile-haut {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.tuile-rond {
  display: inline-grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgb(18 13 10 / 0.12);
}
.tuile-titre {
  font-size: var(--t-sous-titre);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.01em;
  text-wrap: balance;
}
.tuile-precision {
  font-size: var(--t-petit);
  font-weight: 500;
  line-height: 1.35;
}
.tuile-texte,
.tuile-action {
  display: none;
}

@media (min-width: 768px) {
  .choix {
    gap: 16px;
    max-width: 760px;
    width: 100%;
    margin-inline: auto;
  }
  .tuile-face { padding: 20px 20px 22px; }
  .tuile-precision { display: none; }
  .tuile-texte {
    display: block;
    margin-top: 6px;
    font-size: 1rem;
    line-height: 1.45;
  }
  .tuile-action {
    display: block;
    margin-top: auto;
    padding-top: 16px;
    font-size: 1rem;
    font-weight: 600;
  }
}

/* Bureau : une seule scène, la carte posée sur le bord bas, les tuiles de chaque côté. */
@media (min-width: 1024px) {
  .hero {
    --tuile: clamp(280px, 22vw, 340px);
    --b: min(calc((100svh - 84px) * 0.625), calc(100svh - 360px), 470px,
      calc((100vw - 2 * var(--tuile) - 96px - 2 * var(--marge)) / 0.896));
    --m: calc(var(--b) / 0.603);
    display: block;
    height: 100svh;
    min-height: 640px;
    max-height: 1000px;
    padding: 0;
  }
  .scene {
    position: absolute;
    left: calc(50% - var(--m) * 0.5904);
    bottom: calc(var(--m) * -0.057);
    width: calc(var(--m) * 0.96);
    height: var(--m);
    margin: 0;
  }
  .carte-trait,
  .carte-mada { stroke-width: 4.5; }
  .hero-texte {
    padding-top: 108px;
    gap: 16px;
  }
  .pastille-hero {
    display: inline-flex;
    margin-bottom: 8px;
  }
  .pastille-hero[hidden] { display: none; }
  .hero-titre,
  .hero-sous { text-shadow: 0 0 28px var(--nuit), 0 0 10px var(--nuit); }
  .hero-sous { max-width: 40rem; }
  .choix {
    position: absolute;
    left: var(--marge);
    right: var(--marge);
    bottom: 32px;
    display: flex;
    justify-content: space-between;
    width: auto;
    max-width: none;
    margin: 0;
    padding: 0;
    pointer-events: none;
  }
  .tuile {
    width: var(--tuile);
    min-height: 200px;
    pointer-events: auto;
  }
  .tuile-titre { font-size: 1.5rem; }
}
@media (min-width: 1440px) {
  .choix {
    left: max(var(--marge), calc(50% - var(--largeur-hero) / 2));
    right: max(var(--marge), calc(50% - var(--largeur-hero) / 2));
  }
}

/* Entrée du hero : une seule fois par session, jouée en CSS même sans JavaScript. */
/* 0.01 et non 0 : invisible à l'oeil, mais le titre compte dès le premier affichage (LCP). */
@keyframes monte {
  from {
    opacity: 0.01;
    transform: translate(var(--dx, 0), var(--dy, 12px));
  }
}
@keyframes apparait {
  from { opacity: 0.01; }
}
@keyframes trace {
  from { stroke-dashoffset: 1; }
}
@keyframes point-lome {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
}
.hero-titre {
  animation: monte 500ms var(--ease-out) both;
}
.hero-sous {
  --dy: 8px;
  animation: monte 480ms var(--ease-out) 90ms both;
}
.tuile {
  --dy: 8px;
  animation: monte 480ms var(--ease-out) 150ms both;
}
@media (min-width: 1024px) {
  .tuile-studio { --dx: -12px; --dy: 0px; }
  .tuile-distance { --dx: 12px; --dy: 0px; }
}
.lome {
  animation: point-lome 300ms var(--ease-out) both;
}
.carte-trait .moitie {
  animation: trace var(--d-trace) var(--ease-in-out) 120ms both;
}
.carte-halo,
.carte-mada,
.lome-nom {
  animation: apparait 500ms var(--ease-out) 1100ms both;
}
.halo-pose .hero-titre,
.halo-pose .hero-sous,
.halo-pose .tuile,
.halo-pose .lome,
.halo-pose .carte-trait .moitie,
.halo-pose .carte-halo,
.halo-pose .carte-mada,
.halo-pose .lome-nom {
  animation: none;
}

@media (prefers-reduced-motion: reduce) {
  .hero-titre,
  .hero-sous,
  .tuile {
    animation: apparait 200ms ease both;
  }
  .lome,
  .carte-trait .moitie,
  .carte-halo,
  .carte-mada,
  .lome-nom {
    animation: none;
  }
  .halo-pose .hero-titre,
  .halo-pose .hero-sous,
  .halo-pose .tuile { animation: none; }
}

/* ---------- Le principe ---------- */

.principe-titre {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
  margin-bottom: 40px;
}
/* Le mot tournant s'aligne sur le titre, sans pilule : la largeur réservée (celle du mot
   le plus long) ne se voit plus. */
.mots {
  display: inline-grid;
  justify-items: start;
  color: var(--lueur);
}
.mot {
  grid-area: 1 / 1;
  white-space: nowrap;
  opacity: 0;
  transform: translateY(0.25em);
  filter: blur(2px);
  transition:
    opacity 260ms var(--ease-out),
    transform 260ms var(--ease-out),
    filter 260ms var(--ease-out);
}
.mot.est-visible {
  opacity: 1;
  transform: none;
  filter: none;
  transition-delay: 60ms;
}
.mot.sort {
  opacity: 0;
  transform: translateY(-0.25em);
  filter: blur(2px);
  transition-duration: 200ms;
  transition-delay: 0ms;
}
@media (prefers-reduced-motion: reduce) {
  .mots { display: none; }
  .principe-titre .phrase-complete { display: inline; }
}
.phrase-complete {
  display: none;
  color: var(--lueur);
}

.citation {
  max-width: 54rem;
}
.citation blockquote {
  margin: 0;
}
.citation p {
  font-size: var(--t-citation);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.015em;
  text-wrap: pretty;
}
.guillemet {
  color: var(--orange);
}
@media (min-width: 1024px) {
  .citation p { text-indent: -0.45em; }
}
.citation figcaption {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
}
.avatar {
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  object-position: 50% 22%;
  box-shadow: 0 0 0 1px var(--filet-fort);
}
@media (min-width: 1024px) {
  .citation .avatar { width: 48px; height: 48px; }
}
.citation figcaption span {
  display: grid;
  gap: 2px;
}
.citation figcaption strong {
  font-size: 1rem;
  font-weight: 600;
}
/* Cible de 44 px ; les marges négatives gardent la mise en page d'une ligne de 24 px. */
.lien-discret {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-block: -10px;
  color: var(--sable);
  font-size: var(--t-petit);
  text-decoration: underline;
  text-decoration-color: var(--cendre);
  text-underline-offset: 3px;
}
@media (hover: hover) and (pointer: fine) {
  .lien-discret:hover { color: var(--lueur); }
}

/* Étapes et règle graduée */
.etapes {
  --gradu: repeating-linear-gradient(to bottom, var(--cendre) 0 1px, transparent 1px 8px);
  position: relative;
  display: grid;
  gap: 32px;
  margin-top: 48px;
  counter-reset: none;
}
.etapes::before {
  content: "";
  position: absolute;
  left: 15px;
  top: 32px;
  bottom: 40px;
  width: 7px;
  background:
    linear-gradient(var(--cendre), var(--cendre)) 0 0 / 1px 100% no-repeat,
    var(--gradu) 1px 4px / 6px 100% no-repeat;
}
.etapes li {
  position: relative;
  display: grid;
  grid-template-columns: 32px 1fr;
  column-gap: 16px;
  row-gap: 6px;
}
.etape-num {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--orange);
  color: var(--nuit);
  font-size: 1rem;
  font-weight: 700;
  box-shadow: 0 0 0 6px var(--nuit);
}
.etapes h3 {
  align-self: center;
  font-size: var(--t-sous-titre);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.01em;
}
.etapes p {
  max-width: 30rem;
  color: var(--sable);
}
@media (min-width: 900px) {
  .etapes {
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 72px;
  }
  .etapes::before {
    left: 0;
    right: 0;
    top: 15px;
    bottom: auto;
    width: auto;
    height: 7px;
    background:
      linear-gradient(var(--cendre), var(--cendre)) 0 0 / 100% 1px no-repeat,
      repeating-linear-gradient(to right, var(--cendre) 0 1px, transparent 1px 8px) 4px 1px / 100% 6px no-repeat;
  }
  .etapes li {
    grid-template-columns: 1fr;
    row-gap: 12px;
  }
  .etape-num { grid-row: auto; margin-bottom: 8px; }
  .etapes p { font-size: 1.125rem; }
}

/* ---------- Studio ou distance ---------- */

.panneaux {
  display: grid;
  gap: 12px;
}
@media (min-width: 900px) {
  .panneaux {
    grid-template-columns: 1fr 1fr;
    gap: 24px;
  }
}
.mode {
  display: flex;
  flex-direction: column;
}
.mode-visuel {
  position: relative;
  margin: 0;
  aspect-ratio: 576 / 470;
  border-radius: var(--r-l);
  overflow: hidden;
  background: var(--nuit);
}
.mode-visuel img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.mode-visuel figcaption {
  position: absolute;
  left: 12px;
  bottom: 12px;
  padding: 6px 12px;
  border-radius: var(--r-pilule);
  background: rgb(18 13 10 / 0.8);
  color: var(--creme);
  font-size: 0.8125rem;
  font-weight: 500;
}
.mode-carte svg {
  width: 100%;
  height: 100%;
}
.trajet-continent {
  fill: rgb(255 244 234 / 0.025);
  stroke: var(--cendre);
  stroke-width: 2.5;
  stroke-linejoin: round;
}
.trajet-arc {
  fill: none;
  stroke: var(--orange);
  stroke-width: 3;
  stroke-dasharray: 8 12;
  stroke-linecap: round;
}
.trajet-lome { fill: var(--orange); }
.trajet-lome-anneau { fill: var(--orange); opacity: 0.25; }
.trajet-toi { fill: var(--creme); }
/* Unités du viewBox (1300 de large) : 48 font environ 12 px affichés sur un téléphone. */
.trajet-nom {
  fill: var(--sable);
  font-family: var(--police);
  font-size: 48px;
  font-weight: 500;
  dominant-baseline: central;
}
@media (min-width: 900px) {
  .trajet-nom { font-size: 34px; }
}
.trajet-nom-toi { fill: var(--creme); }
/* Lomé et le vendeur restent les plus visibles ; les autres villes montrent qu'on peut
   passer en Live de partout. Le contour sombre garde les noms lisibles sur les arcs. */
.trajet-nom {
  paint-order: stroke;
  stroke: var(--plateau);
  stroke-width: 10px;
  stroke-linejoin: round;
}
.trajet-nom-lome { fill: var(--lueur); font-weight: 700; }
.trajet-nom-ville { font-size: 40px; }
@media (min-width: 900px) {
  .trajet-nom-ville { font-size: 30px; }
}
.trajet-ville { fill: var(--lueur); }
.trajet-arc-ville {
  fill: none;
  stroke: var(--orange);
  stroke-width: 2;
  stroke-dasharray: 6 10;
  stroke-linecap: round;
  opacity: 0.5;
}
/* Les traits avancent vers Lomé ; immobiles si le visiteur réduit les animations. */
@media (prefers-reduced-motion: no-preference) {
  .trajet-arc-ville { animation: trajet-flux 1.6s linear infinite; }
}
@keyframes trajet-flux {
  to { stroke-dashoffset: -32; }
}
.mode-corps {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
  padding: 22px 12px 12px;
}
.puces {
  display: grid;
  gap: 10px;
  margin-bottom: 8px;
}
.puces li {
  position: relative;
  padding-left: 18px;
  color: var(--sable);
}
.puces li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.66em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--orange);
}
.mode .bouton {
  width: 100%;
  margin-top: auto;
}
@media (min-width: 900px) {
  .mode-corps { padding: 28px 18px 18px; }
  .mode .bouton { width: auto; }
}
.modes-lien {
  margin-top: 24px;
}
.modes-lien .lien {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

/* ---------- Bandes Plateau et Orange ---------- */

.bande {
  position: relative;
  z-index: 1;
  padding-block: var(--section);
  border-radius: var(--r-xl);
  background: var(--plateau);
}

/* ---------- Créneaux ---------- */

.creneaux-grille {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 32px;
}
.creneaux-tete {
  display: grid;
  gap: 12px;
  align-content: start;
}
.compteur {
  min-height: 1.4em;
  margin-top: 12px;
  color: var(--creme);
  font-size: 1.125rem;
  font-weight: 600;
  line-height: 1.3;
}
.compteur[hidden] { display: none; }
@media (min-width: 1024px) {
  .compteur { font-size: 1.3125rem; }
}
.compteur-chiffres {
  display: inline-flex;
  min-width: 3ch;
  vertical-align: top;
  color: var(--lueur);
  font-variant-numeric: tabular-nums;
}
.compteur-chiffres:not(:empty) { min-width: 0; margin-right: 0.3em; }
.colonne {
  display: inline-block;
  height: 1.3em;
  overflow: hidden;
}
.rouleau {
  display: grid;
  transition: transform 900ms var(--ease-out);
}
.rouleau span {
  height: 1.3em;
}
.creneaux-note {
  color: var(--sable);
}
.creneaux-tete .lien {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

.jours {
  display: flex;
  gap: 8px;
  margin-inline: calc(var(--marge) * -1);
  padding: 4px var(--marge) 8px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--marge);
  overscroll-behavior-x: contain;
  scrollbar-width: none;
}
.jours::-webkit-scrollbar { display: none; }
/* Le bord droit s'efface : la rangée annonce qu'elle continue. */
@media (max-width: 1023.98px) {
  .jours {
    -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 24px), transparent);
    mask-image: linear-gradient(to right, #000 calc(100% - 24px), transparent);
  }
}
.jours .puce-jour {
  flex: none;
  scroll-snap-align: start;
}
.puce-jour.vide {
  pointer-events: none;
}
.heures {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 20px;
}
.heures .pastille-heure {
  width: 100%;
  padding: 0 8px;
}
.heures .pastille-heure.vide {
  border-color: transparent;
  background: var(--coulisse);
}
.heures .prise {
  flex-direction: column;
  gap: 2px;
}
.heures .prise .mention {
  font-weight: 600;
}
.heures-erreur {
  grid-column: 1 / -1;
  display: grid;
  justify-items: start;
  gap: 16px;
  color: var(--sable);
}
@media (min-width: 1024px) {
  .creneaux-grille {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: 24px 64px;
  }
  .jours {
    margin: 0;
    padding: 4px 0 8px;
    overflow: visible;
  }
  .jours .puce-jour {
    flex: 1 1 0;
    width: auto;
    max-width: 88px;
    min-height: 84px;
  }
  .heures {
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
  }
}

/* ---------- Qui passe en Live (carrousel) ---------- */

.lives {
  padding-bottom: calc(var(--section) * 0.75);
}
.lives-tete {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}
.lives-tete .tete {
  margin-bottom: 24px;
}
.rail-fleches {
  display: none;
}
@media (hover: hover) and (pointer: fine) {
  .rail-fleches {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
  }
}
.rail-fleche {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--cendre);
  color: var(--creme);
  transition:
    border-color var(--d-survol) ease,
    opacity var(--d-survol) ease,
    transform var(--d-appui) var(--ease-out);
}
.rail-fleche:active { transform: scale(0.97); }
.rail-fleche:disabled {
  border-color: var(--filet);
  color: var(--cendre);
  cursor: default;
}
@media (hover: hover) and (pointer: fine) {
  .rail-fleche:hover:not(:disabled) { border-color: var(--creme); }
}

.onglets {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  width: min(100%, 360px);
  padding: 4px;
  border-radius: var(--r-pilule);
  background: var(--plateau);
  box-shadow: inset 0 0 0 1px var(--filet);
}
.onglet-pastille {
  position: absolute;
  top: 4px;
  bottom: 4px;
  left: 4px;
  width: calc(50% - 4px);
  border-radius: var(--r-pilule);
  background: var(--coulisse);
  box-shadow: inset 0 0 0 1px var(--filet-fort);
  transition: transform var(--duree-deplacement) var(--courbe-deplacement);
}
.onglets.passes .onglet-pastille {
  transform: translateX(100%);
}
.onglets [role="tab"] {
  position: relative;
  min-height: 44px;
  border-radius: var(--r-pilule);
  color: var(--sable);
  font-size: 0.9375rem;
  font-weight: 600;
  transition: color var(--d-survol) ease;
}
.onglets [role="tab"][aria-selected="true"] {
  color: var(--creme);
}

.rail {
  --bord: max(var(--marge), calc((100vw - var(--largeur)) / 2));
  display: flex;
  align-items: stretch;
  gap: 12px;
  margin-top: 24px;
  padding: 4px var(--bord) 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--bord);
  overscroll-behavior-x: contain;
  scrollbar-width: none;
  transition: opacity var(--duree-etat) var(--ease-out);
}
.rail::-webkit-scrollbar { display: none; }
.rail.cache { opacity: 0; }
.rail:focus-visible {
  outline-offset: -2px;
}

.carte-live {
  flex: none;
  display: flex;
  flex-direction: column;
  width: min(82vw, 320px);
  scroll-snap-align: start;
}
@media (min-width: 1024px) {
  .carte-live { width: 300px; }
}
.carte-live.squelette {
  min-height: 340px;
  border-radius: var(--r-m);
  background: var(--plateau);
}
.frise {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  height: 28px;
  margin-right: -12px;
  color: var(--sable);
  font-size: var(--t-petit);
  font-weight: 500;
}
.carte-live:last-child .frise { margin-right: 0; }
.frise::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  border-top: 1px dashed var(--cendre);
}
/* Cartes sans date (lancement, exemples, « Ta place est ici ») : la frise commence
   à la première vraie date. La rangée garde sa hauteur pour aligner les cartes. */
.carte-live.teintee .frise::before,
.carte-demo .frise::before {
  content: none;
}
.frise-point {
  position: relative;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 0 4px var(--nuit);
}
.frise-date {
  position: relative;
  padding-right: 8px;
  background: var(--nuit);
  color: var(--creme);
}
.carte-live-corps {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 12px;
  margin-top: 8px;
  padding: 20px;
  border-radius: var(--r-m);
  border: 1px solid var(--filet);
  background: var(--plateau);
  box-shadow: var(--ombre-carte);
  color: var(--creme);
  text-decoration: none;
}
a.carte-live-corps {
  transition:
    transform var(--d-appui) var(--ease-out),
    border-color var(--d-survol) ease;
}
a.carte-live-corps:active { transform: scale(0.98); }
@media (hover: hover) and (pointer: fine) {
  a.carte-live-corps:hover { border-color: var(--orange); }
}
.carte-live.teintee .carte-live-corps {
  position: relative;
  overflow: hidden;
  background: linear-gradient(var(--voile), var(--voile)), var(--plateau);
  border-color: rgb(240 104 0 / 0.3);
}
/* Les deux cartes teintées reprennent le filigrane OCD de la section finale,
   posé au-dessus du compte à rebours et du bouton (188 px depuis le bas). */
.carte-live.teintee .carte-live-corps::after {
  content: "";
  position: absolute;
  right: -32%;
  bottom: 188px;
  width: 100%;
  aspect-ratio: 875.5 / 333.5;
  background: rgb(240 104 0 / 0.1);
  -webkit-mask: url("/img/logo-ocd.svg") center / contain no-repeat;
  mask: url("/img/logo-ocd.svg") center / contain no-repeat;
  pointer-events: none;
}
.carte-live.teintee .carte-live-corps > * {
  position: relative;
  z-index: 1;
}
.cl-haut {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 26px;
}
.cl-heure {
  color: var(--creme);
  font-size: 1rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.cl-etiquette {
  color: var(--sable);
  font-size: var(--t-petit);
  font-weight: 500;
}
.cl-titre {
  font-size: var(--t-sous-titre);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.01em;
}
.cl-grand {
  font-size: clamp(1.75rem, 1.5rem + 1vw, 2rem);
  font-weight: 750;
  line-height: 1.02;
  letter-spacing: -0.025em;
}
.cl-texte {
  color: var(--sable);
  font-size: 0.9375rem;
  line-height: 1.45;
}
.cl-bas {
  margin-top: auto;
  padding-top: 4px;
}
/* Compte à rebours de la carte de lancement, posé au-dessus du bouton. */
.cl-compte {
  display: grid;
  gap: 6px;
  margin-top: auto;
}
.cl-compte strong {
  color: var(--lueur);
  font-size: 5rem;
  font-weight: 800;
  line-height: 0.85;
  letter-spacing: -0.05em;
  font-variant-numeric: tabular-nums;
}
.cl-compte span {
  color: var(--sable);
  font-size: var(--t-petit);
  font-weight: 500;
}
.cl-compte + .cl-bas {
  margin-top: 8px;
}
.cl-bas .bouton {
  width: 100%;
}
/* Cartes d'exemple : une photo en tête de carte, marquée « Exemple ». */
.cl-photo {
  position: relative;
  margin: -20px -20px 0;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: var(--r-m) var(--r-m) 0 0;
  background: var(--coulisse);
}
.cl-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.cl-exemple {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 4px 10px;
  border-radius: var(--r-pilule);
  background: rgb(18 13 10 / 0.78);
  color: var(--creme);
  font-size: var(--t-micro);
  font-weight: 600;
}
.cl-bandeau {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: -8px -8px 0;
  padding: 10px;
  border-radius: 12px;
  background: var(--coulisse);
}
.monogramme {
  display: grid;
  place-items: center;
  flex: none;
  width: 56px;
  height: 56px;
  border-radius: 12px;
  background: var(--nuit);
  color: var(--orange);
  font-size: 2rem;
  font-weight: 800;
  line-height: 1;
}
/* Nom long : 2 lignes au plus, activité sur 1 ligne. Le monogramme reste en haut
   au lieu de flotter au milieu du texte. */
.monogramme {
  align-self: flex-start;
}
.cl-bandeau-texte {
  display: grid;
  gap: 2px;
  min-width: 0;
}
.cl-bandeau .cl-titre {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  overflow-wrap: anywhere;
}
.cl-bandeau .cl-etiquette {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.cl-produit {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
  color: var(--creme);
  font-size: 0.9375rem;
  line-height: 1.45;
}
.cl-infos {
  display: grid;
  gap: 4px;
  color: var(--sable);
  font-size: var(--t-petit);
}
.cl-infos > span {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}
.cl-infos a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-block: -10px;
  color: var(--creme);
  text-decoration: underline;
  text-underline-offset: 3px;
  font-variant-numeric: tabular-nums;
}
.cl-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.cl-heures {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.cl-heures .pastille-heure {
  min-height: 44px;
  padding: 0 4px;
  font-size: 0.9375rem;
}
.cl-ilya {
  color: var(--sable);
  font-size: var(--t-micro);
  font-weight: 500;
}

/* Entrée du carrousel, une fois : les trois premières cartes seulement. */
.rail.a-reveler .carte-live:nth-child(-n + 3) {
  opacity: 0;
  transform: translateY(12px);
}
.rail.revele .carte-live:nth-child(-n + 3) {
  transition:
    opacity 400ms var(--courbe-sortie),
    transform 400ms var(--courbe-sortie);
}
.rail.revele .carte-live:nth-child(2) { transition-delay: 60ms; }
.rail.revele .carte-live:nth-child(3) { transition-delay: 100ms; }

.regle {
  position: relative;
  height: 2px;
  margin-top: 16px;
  border-radius: 2px;
  background: var(--filet);
  overflow: hidden;
}
.regle-repere {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 30%;
  border-radius: 2px;
  background: var(--orange);
  transform-origin: 0 0;
}
.lives-programme {
  margin-top: 16px;
}
.lives-programme .lien {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

/* ---------- Avec Bovann ----------
   Téléphone : titre, photos, puis la formule et les comptes. Bureau (900 px et plus) :
   les photos à gauche, le texte à droite, centré sur elles. Le portrait mène, la scène
   et la communauté l'appuient ; tout part d'une seule grille, sans pile ni rotation. */

.bovann-grille {
  display: grid;
  gap: 28px;
}
.bovann-tete {
  display: grid;
  gap: 12px;
}
.bovann-visuel {
  position: relative;
  max-width: 34rem;
}
/* Le portrait est éclairé par derrière, comme Lomé dans le hero. */
.bovann-visuel::before {
  content: "";
  position: absolute;
  inset: -12% 24% 4% -16%;
  background: radial-gradient(closest-side, rgb(240 104 0 / 0.3), transparent);
  pointer-events: none;
}
/* Le portrait officiel seul : jamais plus large que l'image source (412 px), pour rester net. */
.bovann-photos {
  position: relative;
  max-width: 412px;
}
.bovann-photos img {
  width: 100%;
  border-radius: var(--r-m);
  background: var(--coulisse);
  object-fit: cover;
}
/* La lumière tombe sur le visage et s'éteint vers le bas, dans la lueur orange. */
.bovann-portrait {
  display: block;
  aspect-ratio: 412 / 515;
  border-radius: var(--r-l);
  -webkit-mask-image: linear-gradient(to bottom, #000 58%, rgb(0 0 0 / 0.62));
  mask-image: linear-gradient(to bottom, #000 58%, rgb(0 0 0 / 0.62));
}
.bovann-source {
  position: relative;
  margin-top: 12px;
  color: var(--cendre);
  font-size: var(--t-micro);
  line-height: 1.4;
}
.bovann-annonce {
  display: grid;
  justify-items: start;
  gap: 8px;
  padding: 20px;
  border: 1px solid var(--orange);
  border-radius: var(--r-l);
  background:
    radial-gradient(120% 90% at 0% 0%, rgb(240 104 0 / 0.16), transparent 70%),
    var(--nuit);
  box-shadow: 0 16px 40px -28px rgb(240 104 0 / 0.75);
}
.bovann-annonce-nom {
  font-size: var(--t-sous-titre);
  line-height: 1.1;
  letter-spacing: -0.01em;
}
.bovann-annonce p {
  max-width: 26rem;
  color: var(--sable);
}
.bovann-annonce .bouton {
  width: 100%;
  margin-top: 12px;
}
.bovann-suivre {
  margin-top: 28px;
  color: var(--sable);
  font-size: var(--t-petit);
  font-weight: 600;
}
.bovann-liens {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}
@media (max-width: 374.98px) {
  .bovann-liens .bouton { padding-inline: 14px; }
}
@media (min-width: 900px) {
  .bovann-grille {
    grid-template-columns: minmax(0, 412px) minmax(0, 1fr);
    grid-template-rows: 1fr auto auto 1fr;
    grid-template-areas: "visuel ." "visuel tete" "visuel corps" "visuel .";
    column-gap: clamp(40px, 5vw, 72px);
    row-gap: 32px;
  }
  .bovann-tete { grid-area: tete; }
  .bovann-visuel {
    grid-area: visuel;
    max-width: none;
  }
  .bovann-corps { grid-area: corps; }
  .bovann-annonce { padding: 24px; }
  .bovann-annonce .bouton { width: auto; }
}

/* ---------- Formules ----------
   Téléphone : rail aimanté, une carte entière et le bord de la suivante ; la section reste
   courte et chaque carte garde sa taille. Tablette : 2 colonnes. Bureau : 3 x 2.
   Dès 2 colonnes, les rangées (étiquette, nom, prix, valeur, avantages, bouton) s'alignent
   d'une carte à l'autre : les prix se comparent sur une même ligne. */

.formules-grille {
  display: grid;
  gap: 28px;
}
.formules-tete {
  display: grid;
  gap: 12px;
  align-content: start;
}
.formules-tete .encart {
  max-width: 26rem;
  margin-top: 12px;
}

/* Bande d'ambiance : trois photos en un seul bandeau, au ton chaud de la Nuit de studio
   (traitement appliqué au fichier). Basse, elle annonce les cartes sans les couvrir. */
.ambiance {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr) minmax(0, 1fr);
  gap: 3px;
  height: clamp(128px, 17vw, 208px);
  border-radius: var(--r-l);
  overflow: hidden;
}
.ambiance img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: var(--coulisse);
}
.ambiance img:nth-child(1) { object-position: 55% 30%; }
.ambiance img:nth-child(3) { object-position: 86% 50%; }

.formules-liste {
  --largeur-carte: min(calc(100vw - 2 * var(--marge) - 40px), 340px);
  --ecart-rangee: 20px;
  display: flex;
  align-items: stretch;
  gap: 12px;
  margin-inline: calc(-1 * var(--marge));
  /* 32 px dessous : la lueur de la carte phare n'est pas coupée par le rail. */
  padding: 4px var(--marge) 32px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--marge);
  overscroll-behavior-x: contain;
  scrollbar-width: none;
}
.formules-liste::-webkit-scrollbar { display: none; }

.formule,
.formule-squelette {
  flex: none;
  width: var(--largeur-carte);
  scroll-snap-align: start;
}
/* Hauteurs relevées sur les vraies cartes : la section ne bouge pas quand elles arrivent. */
.formule-squelette {
  min-height: 493px;
  border-radius: var(--r-l);
  border: 1px solid var(--filet);
  background: var(--plateau);
}
@media (max-width: 374.98px) {
  .formule-squelette { min-height: 499px; }
}
@media (max-width: 339.98px) {
  .formule-squelette { min-height: 560px; }
}
@media (min-width: 768px) {
  .formule-squelette { min-height: 450px; }
}
@media (min-width: 1024px) {
  .formule-squelette { min-height: clamp(497px, calc(862px - 28.5vw), 570px); }
}
.formule {
  display: flex;
  flex-direction: column;
  border-radius: var(--r-l);
  /* Le squelette laisse la place aux cartes en fondu (opacité seule, même en mouvement réduit). */
  animation: apparait var(--d-ouverture) var(--ease-out);
  transition: border-color var(--d-survol) ease;
}
/* Rangées partagées : d'une carte à l'autre, au doigt comme à la souris, prix et boutons
   restent à la même hauteur. Sans subgrid, chaque carte garde sa propre colonne. */
@supports (grid-template-rows: subgrid) {
  .formules-liste {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: var(--largeur-carte);
    grid-template-rows: repeat(6, auto);
    column-gap: 12px;
    row-gap: 0;
  }
  .formule,
  .formule-squelette {
    width: auto;
    grid-row: span 6;
  }
  .formule {
    display: grid;
    grid-template-rows: subgrid;
    row-gap: 0;
  }
}

.formule-etiquette {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 32px;
  color: var(--sable);
  font-size: var(--t-petit);
  font-weight: 600;
  line-height: 1.25;
}
.formule-avatar {
  width: 32px;
  height: 32px;
  object-position: 50% 12%;
  box-shadow: 0 0 0 2px var(--plateau), 0 0 0 3px var(--orange);
}
.formule-haut {
  margin-top: 12px;
}
.formule-nom {
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.01em;
}
.formule-duree {
  margin-top: 4px;
  color: var(--sable);
  font-size: 0.9375rem;
  line-height: 1.35;
}
/* Le prix : chiffres serrés et étroits, comme un compteur de régie. */
.formule-prix {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  column-gap: 6px;
  margin-top: 20px;
  line-height: 1;
}
.formule-montant {
  font-size: clamp(2.5rem, 2rem + 1.6vw, 3.25rem);
  font-weight: 800;
  font-stretch: 82%;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.formule-devise {
  font-size: 1rem;
  font-weight: 700;
}
.formule-unite {
  color: var(--sable);
  font-size: 0.9375rem;
}
.formule-valeur {
  display: grid;
  align-content: start;
  justify-items: start;
  gap: 10px;
  margin-top: 12px;
  color: var(--sable);
  font-size: var(--t-petit);
  line-height: 1.4;
  font-variant-numeric: tabular-nums;
}
.formule-meilleur {
  padding: 4px 10px;
  border-radius: var(--r-pilule);
  background: var(--voile);
  color: var(--lueur);
  font-size: 0.8125rem;
  font-weight: 600;
  line-height: 1.3;
}
.formule-avantages {
  display: grid;
  align-content: start;
  gap: 10px;
  margin: 20px 0 24px;
  padding-top: 20px;
  border-top: 1px solid var(--filet);
  font-size: 0.9375rem;
  line-height: 1.35;
}
.formule-avantages li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.formule-coche {
  width: 18px;
  height: 18px;
  margin-top: 1px;
  color: var(--lueur);
  stroke-width: 2.5;
}
.formule-action {
  width: 100%;
  margin-top: auto;
}
/* Petits téléphones : les avantages tiennent sur une ligne dès 360 px. */
@media (max-width: 374.98px) {
  .formule { padding: 18px; }
  .formule-avantages { font-size: 0.875rem; }
}

/* La carte phare est éclairée comme sous un projecteur du studio. */
.formule-phare {
  border-color: var(--orange);
  background:
    radial-gradient(110% 55% at 50% 0%, rgb(240 104 0 / 0.2), transparent 70%),
    var(--plateau);
  box-shadow: var(--ombre-carte), 0 16px 40px -24px rgb(240 104 0 / 0.75);
}
.formule-phare .formule-etiquette {
  color: var(--lueur);
}
@media (hover: hover) and (pointer: fine) {
  .formule:not(.formule-phare):hover { border-color: var(--filet-fort); }
}

/* Points du rail : 44 px de cible, le point actif s'allonge en orange. */
.formules-points {
  display: flex;
  justify-content: center;
  min-height: 44px;
  margin-top: -28px;
}
.formules-point {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
}
.formules-point::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: var(--r-pilule);
  background: var(--cendre);
  transition: background-color var(--d-survol) ease;
}
.formules-point.actif::before {
  width: 22px;
  background: var(--orange);
}
.formules-point:active::before {
  background: var(--sable);
}

@media (min-width: 768px) {
  .formules-liste {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 20px;
    row-gap: var(--ecart-rangee);
    margin-inline: 0;
    padding: 0;
    overflow: visible;
  }
  .formule,
  .formule-squelette {
    width: auto;
  }
  .formules-points {
    display: none;
  }
  @supports (grid-template-rows: subgrid) {
    .formules-liste {
      grid-auto-flow: row;
      grid-template-rows: none;
      row-gap: 0;
    }
    .formule,
    .formule-squelette {
      margin-bottom: var(--ecart-rangee);
    }
  }
}
@media (min-width: 1024px) {
  .formules-grille {
    gap: 48px;
  }
  .formules-tete {
    grid-template-columns: minmax(0, 1fr) minmax(0, 24rem);
    column-gap: 64px;
    align-items: end;
  }
  .formules-tete > * {
    grid-column: 1;
  }
  .formules-tete .encart {
    grid-column: 2;
    grid-row: 1 / span 2;
    margin-top: 0;
  }
  .formules-liste {
    --ecart-rangee: 24px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    column-gap: 24px;
  }
  .formule {
    padding: 28px;
  }
  .formule-nom {
    font-size: 1.375rem;
  }
}

/* ---------- Questions ---------- */

.questions-grille {
  display: grid;
}
@media (min-width: 1024px) {
  .questions-grille {
    grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
    gap: 64px;
    align-items: start;
  }
}
.faq {
  border-top: 1px solid var(--filet);
}
.faq details {
  border-bottom: 1px solid var(--filet);
}
.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 56px;
  padding: 14px 0;
  font-size: 1.125rem;
  font-weight: 600;
  line-height: 1.3;
  list-style: none;
  cursor: pointer;
  transition: color var(--d-survol) ease;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary:focus-visible {
  outline-offset: 2px;
  border-radius: 8px;
}
@media (hover: hover) and (pointer: fine) {
  .faq summary:hover { color: var(--lueur); }
}
.faq-plus {
  flex: none;
  transition: transform 200ms var(--ease-out);
}
.faq details[open] .faq-plus {
  transform: rotate(45deg);
}
.js .faq details[open]:not(.ouvert) .faq-plus {
  transform: none;
}
.faq-reponse {
  display: grid;
  grid-template-rows: 1fr;
}
.js .faq-reponse {
  grid-template-rows: 0fr;
  transition: grid-template-rows 180ms var(--ease-out);
}
.js .faq details.ouvert .faq-reponse {
  grid-template-rows: 1fr;
  transition-duration: 220ms;
}
.faq-reponse > div {
  min-height: 0;
  overflow: hidden;
}
.faq-reponse p {
  max-width: 40rem;
  padding: 0 40px 20px 0;
  color: var(--sable);
}
/* Liens dans le texte : le remplissage d'un élément en ligne agrandit la zone tactile
   à 44 px sans écarter les lignes. */
.t-intro .lien,
.faq-reponse .lien {
  padding-block: 12px;
}
@media (prefers-reduced-motion: reduce) {
  .js .faq-reponse,
  .faq-plus { transition: none; }
}

/* ---------- Section finale orange ---------- */

.finale {
  position: relative;
  z-index: 1;
  overflow: hidden;
  padding-block: 64px 96px;
  border-radius: var(--r-xl);
  background: var(--orange);
  color: var(--nuit);
  text-align: center;
}
@media (min-width: 1024px) {
  .finale { padding-block: 128px 160px; }
}
.filigrane {
  position: absolute;
  right: -38%;
  bottom: -18%;
  width: 140%;
  aspect-ratio: 875.5 / 333.5;
  background: var(--filigrane);
  -webkit-mask: url("/img/logo-ocd.svg") center / contain no-repeat;
  mask: url("/img/logo-ocd.svg") center / contain no-repeat;
  pointer-events: none;
}
@media (min-width: 1024px) {
  .filigrane {
    right: -10%;
    bottom: -22%;
    width: 70%;
  }
}
.finale-contenu {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 16px;
}
.finale-titre {
  font-size: var(--t-final);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.03em;
}
.finale-sous {
  max-width: 34rem;
  font-size: var(--t-intro);
  line-height: 1.45;
}
.finale-boutons {
  display: grid;
  gap: 10px;
  width: 100%;
  max-width: 420px;
  margin-top: 16px;
}
@media (min-width: 768px) {
  .finale-boutons {
    grid-template-columns: 1fr 1fr;
    max-width: 600px;
    gap: 12px;
  }
}
.finale-question {
  margin-top: 8px;
}
.lien-nuit {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--nuit);
  font-weight: 500;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

/* ---------- Pied de page ---------- */

.pied {
  position: relative;
  z-index: 1;
  padding-block: 64px calc(40px + env(safe-area-inset-bottom, 0px));
  background: var(--nuit);
}
.pied-grille {
  display: grid;
  gap: 48px;
}
.pied-marque {
  display: grid;
  gap: 10px;
  align-content: start;
  max-width: 24rem;
}
.pied-marque .marque img { height: 26px; }
.pied-sigle {
  font-size: 1rem;
}
.programme {
  display: grid;
  gap: 12px;
  align-content: start;
}
.programme-titre {
  font-size: 1.125rem;
  font-weight: 700;
  line-height: 1.25;
}
.programme-coches {
  display: grid;
  gap: 8px;
  margin-block: 4px 8px;
}
.programme-coches li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--creme);
  font-size: var(--t-petit);
  line-height: 1.4;
}
.programme-coches .icone {
  color: var(--lueur);
}
.programme-zone {
  position: relative;
}
.programme-form {
  display: grid;
  gap: 4px;
  transition: opacity 150ms var(--ease-out);
}
.programme-form.part {
  opacity: 0;
}
.programme-form > .bouton {
  margin-top: 8px;
}
/* Erreurs : icône et texte, comme dans le parcours. */
.programme-form .erreur {
  display: flex;
  align-items: flex-start;
  gap: 6px;
}
.programme-form .erreur .icone {
  width: 18px;
  height: 18px;
  margin-top: 1px;
}
/* Champ en erreur qui a le focus : l'anneau reste de la couleur de l'erreur. */
.programme-form .champ input[aria-invalid="true"]:focus-visible {
  border-color: var(--alerte);
  box-shadow: 0 0 0 2px rgb(255 122 102 / 0.45);
}
@media (min-width: 768px) {
  .programme-form {
    grid-template-columns: minmax(0, 1fr) auto;
    column-gap: 10px;
  }
  .programme-form > :not(.bouton) { grid-column: 1 / -1; }
  .programme-form > .champ { grid-column: 1; grid-row: 1; }
  .programme-form > .bouton {
    grid-column: 2;
    grid-row: 1;
    align-self: start;
    min-height: 52px;
    margin-top: 26px;
  }
}
.programme-reussite {
  display: none;
}
.programme-reussite.visible {
  display: grid;
  gap: 6px;
  align-content: start;
  padding: 20px;
  border-radius: var(--r-m);
  border: 1px solid var(--filet);
  background: var(--plateau);
  animation: reussite 220ms var(--courbe-sortie) both;
}
.programme-reussite:focus { outline: none; }
.reussite-coche {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  margin-bottom: 6px;
  border-radius: 50%;
  background: var(--orange);
  color: var(--nuit);
  animation: coche 420ms cubic-bezier(0.34, 1.56, 0.64, 1) 80ms both;
}
.reussite-coche .icone {
  stroke-width: 2.5;
}
.programme-reussite strong {
  font-size: 1.125rem;
}
.programme-reussite p {
  color: var(--sable);
  font-size: var(--t-petit);
  overflow-wrap: anywhere;
}
@keyframes reussite {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
}
@keyframes coche {
  from {
    opacity: 0;
    transform: scale(0.5);
  }
}
@media (prefers-reduced-motion: reduce) {
  .programme-reussite.visible { animation: apparait 150ms ease both; }
  .reussite-coche { animation: apparait 150ms ease both; }
}
.programme-whatsapp {
  display: flex;
  align-items: center;
  gap: 12px;
}

.pied-liens {
  display: grid;
  align-content: start;
}
.pied-liens a {
  display: flex;
  align-items: center;
  min-height: 44px;
  color: var(--creme);
  text-decoration: none;
  transition: color var(--d-survol) ease;
}
@media (hover: hover) and (pointer: fine) {
  .pied-liens a:hover { color: var(--lueur); }
}
@media (max-width: 1023.98px) {
  .pied-liens {
    grid-template-columns: 1fr 1fr;
    column-gap: 16px;
  }
  .pied-liens a { font-size: 0.9375rem; }
  .pied-liens a:last-child { grid-column: 1 / -1; }
}
.pied-mentions {
  padding-top: 24px;
  border-top: 1px solid var(--filet);
  color: var(--sable);
  font-size: var(--t-micro);
  font-weight: 500;
}
@media (min-width: 1024px) {
  .pied-grille {
    grid-template-columns: 4fr 5fr 3fr;
    gap: 48px 64px;
  }
  .pied-mentions { grid-column: 1 / -1; }
}

/* ---------- Barre collante mobile ---------- */

.barre {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  /* Même feuille que la barre du parcours : angles du haut arrondis, ombre vers le haut. */
  padding: 14px var(--marge) calc(12px + env(safe-area-inset-bottom, 0px));
  border-radius: var(--r-l) var(--r-l) 0 0;
  border-top: 1px solid var(--filet-fort);
  background: var(--plateau);
  box-shadow: 0 -12px 32px -8px rgb(0 0 0 / 0.6);
  transform: translateY(calc(100% + 40px));
  visibility: hidden;
  transition:
    transform 200ms var(--ease-out),
    visibility 0s linear 200ms;
}
.barre.visible {
  transform: translateY(0);
  visibility: visible;
  transition:
    transform var(--d-barre) var(--ease-tiroir),
    visibility 0s linear 0s;
}
.barre-texte {
  display: grid;
  gap: 2px;
  min-width: 0;
}
.barre-etiquette {
  color: var(--sable);
  font-size: var(--t-micro);
  font-weight: 500;
}
.barre-date,
.barre-seule {
  color: var(--creme);
  font-size: 1rem;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
@media (min-width: 1024px) {
  .barre { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .barre,
  .barre.visible {
    transform: none;
    opacity: 0;
    transition:
      opacity 150ms ease,
      visibility 0s linear 150ms;
  }
  .barre.visible {
    opacity: 1;
    transition:
      opacity 150ms ease,
      visibility 0s linear 0s;
  }
}

/* ==========================================================================
   Hero corrigé après l'audit de direction artistique.
   Placé en fin de fichier : il remplace les réglages hérités du portrait retiré.
   ========================================================================== */

/* ---------- Mobile d'abord (< 1024 px) ---------- */
.hero {
  /* Hauteur de la scène : ce qui reste sous le texte et les tuiles, plafonnée par la largeur utile. */
  --scene: clamp(140px, min(calc(100svh - 448px), calc((100vw - 2 * var(--marge)) / 0.96)), 440px);
  justify-content: flex-start;
  text-align: left;
  padding-top: 8px;
  padding-bottom: max(20px, env(safe-area-inset-bottom));
}
.scene {
  /* Fini le décalage hérité du portrait : la carte est centrée, et ne passe plus sous l'en-tête.
     Les marges automatiques partagent l'espace libre au-dessus et au-dessous de la carte. */
  margin: auto;
  width: calc(var(--scene) * 0.96);
}
.hero-texte {
  justify-items: start;
  gap: 12px;
  margin-top: 20px;
}
.hero-titre {
  font-size: clamp(2.5rem, 1.5rem + 4.6vw, 4rem);
  font-weight: 750;
  line-height: 0.92;
  letter-spacing: -0.03em;
}
.hero-sous {
  max-width: 30ch;
  text-wrap: pretty;
}
.choix {
  margin-top: 0;
  padding-top: 24px;
}
/* Les tuiles s'empilent si leurs mots ne tiennent plus côte à côte (texte agrandi). */
@media (max-width: 767.98px) {
  .choix { grid-template-columns: repeat(auto-fit, minmax(min(100%, 7.5rem), 1fr)); }
}
/* Moins de 360 px de large : titre et carte réduits, les deux choix restent visibles. */
@media (max-width: 359.98px) {
  .hero { --scene: clamp(120px, calc(100svh - 448px), 300px); }
  .hero-titre { font-size: 2.125rem; }
}
/* Pastille de l'en-tête mobile : zone tactile de 44 px sans changer son dessin. */
.pastille-entete { position: relative; }
.pastille-entete::after {
  content: "";
  position: absolute;
  inset: -6px 0;
}

/* ---------- La lumière part de Lomé ---------- */
.carte-fond { fill: url(#mur-lome); }
.carte-trait,
.carte-mada { stroke: url(#trait-lome); }
.carte-halo { stroke: url(#trait-lome); opacity: 0.5; }
.lome-point { fill: var(--creme); }
.lome-anneau { stroke: var(--lueur); stroke-width: 3; opacity: 0.7; }
.lome-eclat { fill: url(#eclat-lome); }
.lome-nom {
  right: auto;
  left: 27%;
  top: calc(43% + 14px);
  translate: -50% 0;
  color: var(--creme);
  font-weight: 600;
}
@media (max-height: 560px), (max-width: 374.98px) {
  .lome-nom { display: block; font-size: 0.75rem; top: calc(43% + 10px); }
}

/* ---------- Tuiles : compactes, même dessin partout ---------- */
.tuile { --relief: 5px; }
.tuile-face {
  box-shadow: inset 0 1px 0 rgb(255 244 234 / 0.28);
}
.tuile-rond {
  background: var(--nuit);
  color: var(--lueur);
}
.tuile-precision { display: block !important; }
.tuile-texte,
.tuile-action { display: none !important; }

/* ---------- Tablette ---------- */
@media (min-width: 768px) and (max-width: 1023.98px) {
  .hero { --scene: clamp(300px, calc(100svh - 520px), 480px); }
  .choix { max-width: none; padding-inline: var(--marge); }
  .tuile-face { padding: 18px 20px 20px; }
}

/* ---------- Bureau : deux colonnes, texte à gauche, carte à droite ---------- */
@media (min-width: 1024px) {
  .hero {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
    /* Rangées vides en haut et en bas : le groupe texte + tuiles est centré
       sans que la carte (plus haute) n'étire les tuiles. */
    grid-template-areas:
      ".     carte"
      "texte carte"
      "choix carte"
      "info  carte"
      ".     carte";
    grid-template-rows: 1fr auto auto auto 1fr;
    column-gap: clamp(32px, 4vw, 80px);
    height: auto;
    min-height: max(100svh, 680px);
    max-height: none;
    /* + 24 px à gauche : le texte s'aligne sur le logo de l'en-tête (marge interne de la pilule). */
    --bord: max(var(--marge), calc(50% - var(--largeur-hero) / 2));
    padding: 108px calc(var(--bord) + 10px) 56px calc(var(--bord) + 24px);
    text-align: left;
  }
  .scene {
    grid-area: carte;
    position: relative;
    left: auto;
    bottom: auto;
    align-self: center;
    justify-self: end;
    width: min(100%, calc((100svh - 180px) * 0.96), 660px);
    height: auto;
    aspect-ratio: 0.96;
    margin: 0;
  }
  .carte-trait,
  .carte-mada { stroke-width: 5; }
  .hero-texte {
    grid-area: texte;
    padding: 0;
    gap: 20px;
  }
  .hero-titre {
    font-size: clamp(4.25rem, 0.5rem + 5.6vw, 6rem);
    letter-spacing: -0.04em;
  }
  .hero-titre,
  .hero-sous { text-shadow: none; }
  .hero-sous { max-width: 34ch; }
  .choix {
    grid-area: choix;
    position: static;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    max-width: 600px;
    margin: 40px 0 0;
    pointer-events: auto;
  }
  .tuile {
    width: auto;
    min-height: 0;
  }
  .tuile-face { padding: 18px 20px 20px; }
  .tuile-titre { font-size: 1.375rem; }
  .tuile-precision { font-size: 0.9375rem; }
  .tuile-studio,
  .tuile-distance { --dx: 0px; --dy: 8px; }
  .pastille-hero {
    grid-area: info;
    justify-self: start;
    margin: 20px 0 0;
    padding: 0;
    min-height: 32px;
    background: none;
    color: var(--sable);
  }
  @media (hover: hover) and (pointer: fine) {
    a.pastille-hero:hover { background: none; color: var(--creme); }
  }
}
@media (min-width: 1440px) {
  .choix { left: auto; right: auto; }
}

/* ---------- Carrousel : règle de position et bouton Pause du défilement ---------- */
.regle-ligne {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
}
.regle-ligne .regle {
  flex: 1;
  margin-top: 0;
}
.rail-pause {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  padding: 0 14px;
  border-radius: var(--r-pilule);
  border: 1px solid var(--filet-fort);
  color: var(--sable);
  font-size: var(--t-petit);
  font-weight: 600;
}
.rail-pause[hidden] { display: none; }
.rail-pause .icone-lecture,
.rail-pause[aria-pressed="true"] .icone-pause { display: none; }
.rail-pause[aria-pressed="true"] .icone-lecture { display: block; }
@media (hover: hover) and (pointer: fine) {
  .rail-pause:hover {
    border-color: var(--lueur);
    color: var(--creme);
  }
}
