/* Landing Karthos — scène cinématographique (17/10/2026). Voir assets/landing/scene.js et docs/landing-README.md.
   Tokens du site (index.html :root) : --bg, --text, --muted, --accent (cuivre), --accent-2, polices Sora / Inter / JetBrains Mono. */

/* ─── Défilement : Lenis remplace le défilement doux natif ─── */
html.js.scene-video, html.js.scene-posters { scroll-behavior: auto; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

/* ─── En-tête posé sur la scène ─── */
.js:not(.scene-off) header {
  position: fixed; left: 0; right: 0; top: 0;
  background: linear-gradient(180deg, rgba(6, 10, 18, .74), rgba(6, 10, 18, .18) 70%, rgba(6, 10, 18, 0)) no-repeat;
  backdrop-filter: none; -webkit-backdrop-filter: none; border-bottom: 0;
}
.js:not(.scene-off) nav.links a { color: rgba(237, 239, 243, .84); text-shadow: 0 1px 10px rgba(0, 0, 0, .55); }
.js:not(.scene-off) nav.links a:hover { color: #fff; }
.js:not(.scene-off) .brand { text-shadow: 0 1px 10px rgba(0, 0, 0, .45); }
.js:not(.scene-off) header:has(.mobile-menu:not([hidden])) { background: var(--bg); }

/* ─── Scène fixe (jamais cliquable) ─── */
.scene { display: none; }
.js:not(.scene-off) .scene {
  display: block; position: fixed; inset: 0; height: 100svh; z-index: 0; overflow: hidden;
  pointer-events: none; background: #05070b; transition: opacity .4s ease-out;
}
.scene-poster, .scene-layer, .scene-layer > img, .scene-layer > video {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%;
}
.scene-layer { opacity: 0; will-change: opacity, transform; }
.scene-layer > img { z-index: 0; }
.scene-layer > video { z-index: 1; opacity: 0; }
.scene-layer.has-video > video { opacity: 1; }
/* Respiration retirée (21/10/2026) : agrandir la vidéo en continu faisait scintiller les détails pendant la lecture. */

/* Éclat cuivré des raccords macro (une seule animation par raccord), orienté sur l'arête diagonale du K. */
.scene-flash {
  position: absolute; inset: -20%; z-index: 20; opacity: 0; mix-blend-mode: screen;
  background:
    radial-gradient(ellipse 34% 22% at 50% 50%, rgba(255, 196, 132, .95), rgba(224, 153, 90, .45) 45%, rgba(168, 98, 31, 0) 75%),
    linear-gradient(135deg, rgba(168, 98, 31, 0) 38%, rgba(224, 153, 90, .55) 50%, rgba(168, 98, 31, 0) 62%);
  transform: rotate(-8deg);
}
/* Dégradé de lisibilité, visible pendant les arrêts de texte ; plus fort sur l'époque romaine (--shade). */
.scene-shade {
  position: absolute; inset: 0; z-index: 21; opacity: 0; transition: opacity .6s ease-out; --shade: .55;
  background: linear-gradient(90deg, rgba(6, 10, 18, var(--shade)) 0%, rgba(6, 10, 18, calc(var(--shade) * .45)) 35%, rgba(6, 10, 18, 0) 55%);
}
.scene-vignette {
  position: absolute; inset: 0; z-index: 22;
  background: radial-gradient(ellipse 80% 75% at 55% 50%, rgba(0, 0, 0, 0) 55%, rgba(0, 0, 0, .42) 100%);
}
.scene-grain {
  position: absolute; inset: -50%; z-index: 23; opacity: .07; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  animation: sceneGrain 1.2s steps(6) infinite;
}
@keyframes sceneGrain {
  0% { transform: translate(0, 0); } 20% { transform: translate(-3%, 2%); } 40% { transform: translate(2%, -3%); }
  60% { transform: translate(-2%, -1%); } 80% { transform: translate(3%, 3%); } 100% { transform: translate(0, 0); }
}
.scene-cut { position: absolute; inset: 0; z-index: 30; background: #05070b; opacity: 0; }
.scene-posters .scene-layer { transition: opacity .9s ease-out; }
.scene-posters .scene-layer.is-on > img { animation: posterDrift 14s ease-in-out infinite alternate; }
@keyframes posterDrift { from { transform: scale(1); } to { transform: scale(1.04); } }
@media (prefers-reduced-motion: reduce) {
  .scene-grain, .scene-layer.breathe, .scene-posters .scene-layer.is-on > img { animation: none; }
}

/* ─── Chapitres : la hauteur porte le parcours, le texte reste épinglé (sticky) dans la zone de sécurité ─── */
.js:not(.scene-off) main { position: relative; z-index: 1; }
.js:not(.scene-off) .chapter { position: relative; padding: 0; height: var(--len, 300vh); background: none; border: 0; }
.chapter-anchor { position: absolute; left: 0; top: 0; width: 1px; height: 1px; pointer-events: none; }
/* Le texte de chaque chapitre est fixé à l'écran (jamais entraîné par le défilement, même à la fin d'une section) ;
   seul le chapitre actif est visible et cliquable. */
.js:not(.scene-off) .chapter-stage { position: fixed; top: 0; left: 0; right: 0; height: 100svh; overflow: hidden; pointer-events: none; }
.js:not(.scene-off) .chapter.is-active .chapter-text, .js:not(.scene-off) .chapter-final.is-active .final-inner { pointer-events: auto; }
.js:not(.scene-off) .chapter-text {
  position: absolute; left: 4%; top: max(10%, 96px); width: 36%; min-width: 360px; max-width: 620px;
  opacity: 0; visibility: hidden; transition: opacity .5s ease-out, visibility 0s linear .5s;
}
.js:not(.scene-off) .chapter.is-active .chapter-text { opacity: 1; visibility: visible; transition: opacity .5s ease-out; }
.js:not(.scene-off) .chapter.is-active.is-out .chapter-text { opacity: 0; }

/* Étapes : superposées au même endroit, une seule visible ; l'en-tête (.keep) reste pendant tout l'arrêt. */
.js:not(.scene-off) .beats { display: grid; margin-top: 18px; }
.js:not(.scene-off) .beat { grid-area: 1 / 1; align-self: start; opacity: 0; visibility: hidden; transition: opacity .35s ease-out, visibility 0s linear .35s; }
.js:not(.scene-off) .beat.is-in { opacity: 1; visibility: visible; transition: opacity .35s ease-out .12s; }

/* Apparition par ligne : chaque ligne glisse hors d'un masque, avec un léger décalage. */
.chapter [data-lines] .w { white-space: nowrap; } /* mot insécable : les lignes mesurées sont celles affichées */
.ln { display: block; overflow: hidden; padding-bottom: .06em; margin-bottom: -.06em; }
.ln-i { display: block; transform: translateY(108%); transition: transform .9s cubic-bezier(.16, 1, .3, 1) calc(var(--i, 0) * 80ms + 80ms); }
.chapter.is-active .keep .ln-i, .beat.is-in .ln-i { transform: none; }
.js:not(.scene-off) .reveal-up { opacity: 0; transform: translateY(12px); transition: opacity .6s ease-out .35s, transform .8s cubic-bezier(.16, 1, .3, 1) .35s; }
.js:not(.scene-off) .beat.is-in .reveal-up, .js:not(.scene-off) .chapter.is-active .keep .reveal-up { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .ln-i { transform: none !important; transition: none; } }

/* Typographie dans la zone de texte (36 % de large) */
.js:not(.scene-off) .chapter h1 { font-size: clamp(30px, 3.5vw, 58px); line-height: 1.04; }
.js:not(.scene-off) .chapter h2 { font-size: clamp(26px, 2.5vw, 42px); line-height: 1.1; margin-top: 12px; }
.js:not(.scene-off) .chapter .hero-sub, .js:not(.scene-off) .chapter .beat > p { font-size: clamp(15px, 1.1vw, 18px); color: #C9CEDA; margin-top: 18px; max-width: 46ch; }
.js:not(.scene-off) .chapter .hero-ctas { margin-top: 26px; }
.js:not(.scene-off) .chapter .hero-status { margin-top: 26px; color: #9AA2B6; }
.js:not(.scene-off) .chapter .pillar { padding: 0; border: 0; background: none; }
.js:not(.scene-off) .chapter .pillar h3 { font-size: clamp(20px, 1.6vw, 26px); margin-top: 8px; }
.js:not(.scene-off) .chapter .pillar p { color: #C9CEDA; margin-top: 10px; font-size: clamp(15px, 1.05vw, 17px); max-width: 44ch; }
.js:not(.scene-off) .chapter .idx { color: var(--accent-2); font-size: 13px; }
.chapter .eyebrow { text-shadow: 0 1px 12px rgba(0, 0, 0, .5); }
.chapter h1, .chapter h2, .chapter h3 { text-shadow: 0 2px 24px rgba(0, 0, 0, .35); }

.js:not(.scene-off) .hero .beats { margin-top: 0; }

/* Hero, étape d'ouverture : la ligne de récit de Qart-Hadasht, en grand. */
.story-lead, .js:not(.scene-off) .chapter .beat > p.story-lead { font-family: var(--font-display); font-weight: 600; font-size: clamp(26px, 2.7vw, 46px); line-height: 1.16; letter-spacing: -.01em; color: var(--text); max-width: 20ch; text-shadow: 0 2px 24px rgba(0, 0, 0, .4); }

/* Fonctionnement et Agences : une étape à la fois dans la zone de texte. */
.js:not(.scene-off) .chapter .step { display: block; padding: 0; border: 0; }
.js:not(.scene-off) .chapter .step .num { color: var(--accent-2); font-size: 13px; padding: 0; }
.js:not(.scene-off) .chapter .step h3 { font-size: clamp(20px, 1.6vw, 26px); margin-top: 8px; }
.js:not(.scene-off) .chapter .step p, .js:not(.scene-off) .chapter .feature p { color: #C9CEDA; font-size: clamp(15px, 1.05vw, 17px); max-width: 44ch; margin-top: 10px; }
.js:not(.scene-off) .chapter .feature { display: flex; gap: 14px; padding: 0; border: 0; }
.js:not(.scene-off) .chapter .feature h3 { font-size: clamp(19px, 1.5vw, 24px); }
.js:not(.scene-off) .chapter .agency-panel { background: rgba(10, 14, 22, .62); border-color: rgba(237, 239, 243, .14); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); padding: 22px; }
.js:not(.scene-off) .chapter .brand-chip { background: rgba(23, 28, 39, .7); }

/* ─── Label d'époque et ligne de récit, dans chaque chapitre (texte réel de la page) ─── */
.chapter-era { margin-top: 28px; }
.chapter-era .era { display: block; font-family: var(--font-mono); font-size: 12px; letter-spacing: .18em; text-transform: uppercase; color: rgba(237, 239, 243, .78); }
.js:not(.scene-off) .chapter-era {
  position: absolute; left: 4%; bottom: 30px; margin: 0; max-width: min(40%, 600px); pointer-events: none;
  text-shadow: 0 1px 14px rgba(0, 0, 0, .6);
  opacity: 0; transform: translateY(8px); transition: opacity .6s ease-out, transform .6s ease-out;
}
.js:not(.scene-off) .chapter.is-active .chapter-era { opacity: 1; transform: none; transition-delay: .35s; }
.js:not(.scene-off) .chapter.is-active.is-out .chapter-era { opacity: 0; transition-delay: 0s; }

/* ─── Rail de progression, boutons « Passer l'animation » et « Son » ─── */
.era-rail, .scene-sound, .scroll-hint { display: none; }
.js:not(.scene-off) .era-rail {
  display: block; position: fixed; right: 28px; top: 50%; height: 56vh; width: 24px; transform: translateY(-50%); z-index: 30;
  pointer-events: none; transition: opacity .5s ease-out;
}
.era-rail.is-hidden { opacity: 0; }
/* Piste restante (claire), partie parcourue (cuivre), un repère par chapitre, le K à l'endroit atteint. */
.rail-line { position: absolute; left: 50%; top: 0; bottom: 0; width: 2px; margin-left: -1px; border-radius: 2px; background: rgba(237, 239, 243, .2); box-shadow: 0 0 10px rgba(0, 0, 0, .35); }
.rail-fill { position: absolute; left: 50%; top: 0; height: 100%; width: 2px; margin-left: -1px; border-radius: 2px; transform-origin: top; transform: scaleY(0);
  background: linear-gradient(180deg, var(--accent), var(--accent-2)); box-shadow: 0 0 8px rgba(224, 153, 90, .45); }
.rail-mark { position: absolute; left: 50%; top: calc(var(--at) * 100%); width: 7px; height: 7px; margin: -3.5px 0 0 -3.5px; background: rgba(237, 239, 243, .45); transform: rotate(45deg); transition: background .4s ease-out, transform .4s ease-out, box-shadow .4s ease-out; }
.rail-mark.is-past { background: var(--accent-2); }
.rail-mark.is-on { transform: rotate(45deg) scale(1.45); box-shadow: 0 0 10px rgba(224, 153, 90, .7); }
.rail-mark.rail-end { border-radius: 50%; transform: none; background: transparent; border: 1.5px solid rgba(237, 239, 243, .6); width: 10px; height: 10px; margin: -5px 0 0 -5px; }
.rail-mark.rail-end.is-past { border-color: var(--accent-2); background: rgba(224, 153, 90, .35); }
.rail-k {
  position: absolute; left: 50%; top: calc(var(--at, 0) * 100%); width: 22px; height: 22px; margin: -11px 0 0 -11px;
  background: url("../logo-karthos.png") center / contain no-repeat; filter: drop-shadow(0 0 8px rgba(224, 153, 90, .7));
  cursor: grab; transition: transform .2s ease-out, filter .2s ease-out;
}
/* Le rail se manipule : le K se fait glisser, la ligne et les points se cliquent (zone de prise élargie). */
.js:not(.scene-off) .era-rail { pointer-events: auto; cursor: pointer; touch-action: none; -webkit-user-select: none; user-select: none; }
.js:not(.scene-off) .era-rail::before { content: ""; position: absolute; left: -12px; right: -10px; top: -16px; bottom: -16px; }
.js:not(.scene-off) .era-rail.is-hidden { pointer-events: none; }
.era-rail:hover .rail-k, .era-rail:focus-visible .rail-k, .era-rail.is-dragging .rail-k { transform: scale(1.4); filter: drop-shadow(0 0 12px rgba(224, 153, 90, .95)); }
.era-rail.is-dragging, .era-rail.is-dragging .rail-k, html.rail-dragging, html.rail-dragging * { cursor: grabbing !important; }
html.rail-dragging { -webkit-user-select: none; user-select: none; }
.era-rail:focus-visible { outline: none; }
.era-rail:focus-visible .rail-line { box-shadow: 0 0 0 3px rgba(224, 153, 90, .45); }
.rail-label {
  position: absolute; right: 30px; top: calc(var(--at, 0) * 100%); transform: translate(8px, -50%); opacity: 0; pointer-events: none;
  white-space: nowrap; font-family: var(--font-mono); font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: #EDEFF3;
  padding: 6px 11px; border-radius: 999px; background: rgba(8, 12, 20, .78); border: 1px solid rgba(224, 153, 90, .55);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); transition: opacity .25s ease-out, transform .25s ease-out;
}
.rail-label:empty { display: none; }
.era-rail:hover .rail-label, .era-rail:focus-visible .rail-label, .era-rail.is-dragging .rail-label { opacity: 1; transform: translate(0, -50%); }

/* Indicateur « Faites défiler » : discret, en bas au centre ; souris (ordinateur) ou chevron (écran tactile). */
/* Capsule de verre sombre au filet cuivre, en bas au centre : souris (ordinateur), libellé, deux flèches qui descendent ;
   un halo cuivré pulse autour pour attirer l'œil. */
.js:not(.scene-off) .scroll-hint {
  display: flex; flex-direction: row; align-items: center; gap: 12px; position: fixed; left: 50%; bottom: 28px; z-index: 31;
  padding: 10px 18px 10px 14px; border-radius: 999px; background: rgba(8, 12, 20, .66); border: 1px solid rgba(224, 153, 90, .7);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  transform: translate(-50%, 14px); opacity: 0; pointer-events: none; transition: opacity .6s ease-out, transform .6s cubic-bezier(.16, 1, .3, 1);
}
.js:not(.scene-off) .scroll-hint.is-on { opacity: 1; transform: translate(-50%, 0); animation: sh-pulse 2.4s ease-out .4s infinite; }
.sh-mouse { position: relative; flex: none; width: 18px; height: 28px; border: 1.5px solid rgba(237, 239, 243, .92); border-radius: 10px; }
.sh-wheel { position: absolute; left: 50%; top: 5px; width: 3px; height: 7px; margin-left: -1.5px; border-radius: 2px; background: var(--accent-2); animation: sh-wheel 1.9s cubic-bezier(.45, 0, .55, 1) infinite; }
.sh-label { font-family: var(--font-mono); font-size: 12px; font-weight: 500; letter-spacing: .2em; text-transform: uppercase; color: #EDEFF3; white-space: nowrap; }
.sh-arrows { display: flex; flex-direction: column; align-items: center; height: 22px; justify-content: center; }
.sh-arrows i { display: block; width: 9px; height: 9px; margin-top: -3px; border-right: 2px solid var(--accent-2); border-bottom: 2px solid var(--accent-2); transform: rotate(45deg); animation: sh-arrow 1.6s ease-in-out infinite; }
.sh-arrows i + i { animation-delay: .2s; }
@keyframes sh-wheel { 0% { transform: translateY(0); opacity: 0; } 18% { opacity: 1; } 70% { transform: translateY(9px); opacity: 0; } 100% { transform: translateY(9px); opacity: 0; } }
@keyframes sh-arrow { 0%, 100% { opacity: .2; transform: translateY(-2px) rotate(45deg); } 50% { opacity: 1; transform: translateY(2px) rotate(45deg); } }
@keyframes sh-pulse { 0% { box-shadow: 0 0 0 0 rgba(224, 153, 90, .55); } 70% { box-shadow: 0 0 0 16px rgba(224, 153, 90, 0); } 100% { box-shadow: 0 0 0 0 rgba(224, 153, 90, 0); } }
@media (pointer: coarse) { .sh-mouse { display: none; } .js:not(.scene-off) .scroll-hint { padding-left: 18px; } }
@media (prefers-reduced-motion: reduce) { .sh-wheel, .sh-arrows i, .js:not(.scene-off) .scroll-hint.is-on { animation: none; } }
.js .scene-sound:not([hidden]) {
  display: inline-flex; position: fixed; bottom: 20px; z-index: 31; pointer-events: auto;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase;
  color: rgba(237, 239, 243, .7); background: rgba(6, 10, 18, .45); border: 1px solid rgba(237, 239, 243, .16);
  padding: 8px 12px; border-radius: var(--radius); cursor: pointer;
}
.js .scene-sound { right: 210px; } /* à gauche de « Passer l'animation » */
.js .scene-sound[aria-pressed="true"] { color: var(--accent-2); border-color: var(--accent); }
.js .scene-sound:hover { color: var(--text); border-color: var(--accent); }
.js .scene-sound:focus-visible, .js:not(.scene-off) .chapter a:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 3px; }

/* « Passer l'animation » (remis le 24/10/2026, demande de Chacala) : mène au site classique, sans vidéo ; « Revoir
   l'animation » y ramène. Le choix est retenu sur ce navigateur. Masqué pendant le choix de la langue. */
.scene-skip { display: none; }
.js .scene-skip {
  display: inline-flex; align-items: center; position: fixed; right: 20px; bottom: 20px; z-index: 31; pointer-events: auto;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase;
  color: rgba(237, 239, 243, .78); background: rgba(6, 10, 18, .5); border: 1px solid rgba(237, 239, 243, .18);
  padding: 9px 14px; border-radius: var(--radius); cursor: pointer;
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); transition: color .2s, border-color .2s;
}
.js .scene-skip:hover { color: var(--text); border-color: var(--accent); }
.js .scene-skip:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 3px; }
.scene-skip .skip-replay, .scene-off .scene-skip .skip-play { display: none; }
.scene-off .scene-skip .skip-replay { display: inline; }
.js.lang-pending .scene-skip { display: none; }
.js.scene-off .scene-skip { position: absolute; top: 88px; bottom: auto; } /* site classique : en haut de page, il ne suit pas la lecture */
.lang-ar .scene-skip { letter-spacing: 0; text-transform: none; }

/* Panneau de débogage (?debug=1) */
.scene-debug {
  position: fixed; right: 56px; top: 84px; z-index: 60; margin: 0; padding: 10px 12px; max-width: 520px; white-space: pre-wrap;
  font: 11px/1.5 var(--font-mono); color: #9ef0c0; background: rgba(0, 0, 0, .72); border: 1px solid rgba(158, 240, 192, .25); pointer-events: none;
}

/* ─── Forfaits : les 3 cartes sur le ciel étoilé (boucle 06_fin_pose), voile sur la moitié haute ─── */
.scene.is-final .scene-shade { background: linear-gradient(180deg, rgba(6, 10, 18, .62) 0%, rgba(6, 10, 18, .3) 32%, rgba(6, 10, 18, 0) 50%); }
.js:not(.scene-off) .chapter-final { height: 260svh; padding: 0; }
.js:not(.scene-off) .chapter-final .chapter-stage { display: flex; align-items: center; }
.js:not(.scene-off) .chapter-final .final-inner { width: 100%; padding-top: 72px; }
.js:not(.scene-off) .chapter-final .plans, .js:not(.scene-off) .chapter-final .plans-note {
  opacity: 0; transform: translateY(36px); transition: opacity .7s ease-out, transform .9s cubic-bezier(.16, 1, .3, 1);
}
.js:not(.scene-off) .chapter-final.is-active .plans, .js:not(.scene-off) .chapter-final.is-active .plans-note { opacity: 1; transform: none; }
.js:not(.scene-off) .chapter-final.is-active .plans-note { transition-delay: .2s; }

/* ─── Révélation (pendant 06_fin_montee) : composition centrée, le K du logo, le nom, la promesse ─── */
.scene.is-signature .scene-shade { background: radial-gradient(ellipse 60% 54% at 50% 46%, rgba(6, 10, 18, .72), rgba(6, 10, 18, .3) 62%, rgba(6, 10, 18, 0) 86%); }
.chapter-signature .eyebrow { justify-content: center; color: var(--accent-2); text-shadow: 0 1px 14px rgba(0, 0, 0, .8); }
.chapter-signature .eyebrow::after { content: ""; width: 18px; height: 1px; background: var(--accent-2); }
.js:not(.scene-off) .chapter-final .plans { background: transparent; border: 0; gap: 18px; }
.js:not(.scene-off) .chapter-final .plan {
  background: rgba(8, 12, 20, .58); border: 1px solid rgba(168, 98, 31, .55);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.js:not(.scene-off) .chapter-final .plan.is-highlight { background: rgba(14, 18, 28, .72); border-color: var(--accent-2); box-shadow: 0 0 0 1px rgba(224, 153, 90, .25), 0 24px 60px -24px rgba(168, 98, 31, .55); }
.js:not(.scene-off) .chapter-final .plan-desc, .js:not(.scene-off) .chapter-final .plans-note { color: #B9C0CF; }
.js:not(.scene-off) .chapter-final .plans-note { padding: 12px 14px; background: rgba(8, 12, 20, .5); border: 1px solid rgba(237, 239, 243, .1); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.js:not(.scene-off) footer { position: relative; z-index: 2; background-color: var(--bg); }

/* ─── Mobile portrait : K gardé visible, texte dans un panneau de verre sombre en bas ─── */
@media (max-width: 767px) {
  .scene-poster, .scene-layer > img, .scene-layer > video { object-position: 70% 50%; }
  .js:not(.scene-off) .chapter-text {
    left: 16px; right: 16px; top: auto; bottom: 16px; width: auto; min-width: 0; max-width: none;
    padding: 18px 18px 20px; background: rgba(6, 10, 18, .58); border: 1px solid rgba(237, 239, 243, .1);
    backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  }
  .scene-shade { display: none; }
  .scene.is-final .scene-shade, .scene.is-signature .scene-shade { display: block; }
  .js:not(.scene-off) .chapter-final { height: auto; padding: 24svh 0 32svh; }
  .js:not(.scene-off) .chapter-final .chapter-stage { position: relative; height: auto; overflow: visible; display: block; pointer-events: auto; }
  /* Le panneau de verre suit la hauteur de l'étape affichée (les autres sortent du flux). */
  .js:not(.scene-off) .beats { display: block; position: relative; }
  .js:not(.scene-off) .beat { position: absolute; left: 0; right: 0; top: 0; }
  .js:not(.scene-off) .beat.is-in { position: relative; }
  .js:not(.scene-off) .chapter h1 { font-size: clamp(28px, 8vw, 38px); }
  .js:not(.scene-off) .chapter h2 { font-size: clamp(22px, 6.4vw, 30px); }
  .story-lead, .js:not(.scene-off) .chapter .beat > p.story-lead { font-size: clamp(22px, 6.4vw, 30px); }
  .js:not(.scene-off) .chapter-era { left: 16px; right: 52px; bottom: auto; top: 124px; max-width: none; }
  .chapter-era .era { font-size: 11px; }
  .js:not(.scene-off) .era-rail { right: 8px; height: 40vh; width: 18px; }
  .js:not(.scene-off) .era-rail.is-cards { opacity: 0; pointer-events: none; }
  .rail-label { right: 26px; font-size: 10px; padding: 5px 9px; }
  .rail-k { width: 18px; height: 18px; margin: -9px 0 0 -9px; }
  .js:not(.scene-off) .scroll-hint { bottom: 22px; }
  .js .scene-sound:not([hidden]) { bottom: auto; top: 84px; right: 12px; font-size: 10px; padding: 6px 10px; }
  .js .scene-skip { left: 12px; right: auto; bottom: auto; top: 84px; font-size: 10px; padding: 6px 10px; }
}

/* ─── Sans animation (« Passer l'animation ») ou sans JavaScript : sections empilées, image de l'époque en fond ─── */
.no-js .chapter, .scene-off .chapter {
  position: relative; min-height: 100svh; display: flex; align-items: center;
  background: linear-gradient(90deg, rgba(6, 10, 18, .78), rgba(6, 10, 18, .35) 60%, rgba(6, 10, 18, .2)), var(--poster) center / cover no-repeat;
}
.no-js .chapter-stage, .scene-off .chapter-stage { width: 100%; max-width: 1180px; margin: 0 auto; padding: 120px var(--gutter) 80px; }
.no-js .hero h1.recit-promise, .scene-off .hero h1.recit-promise { font-size: clamp(28px, 2.9vw, 48px); line-height: 1.08; max-width: 19ch; }
.no-js .chapter-text, .scene-off .chapter-text { max-width: 640px; }
.no-js .beat, .scene-off .beat { margin-top: 22px; }
.no-js .chapter-final, .scene-off .chapter-final { display: block; padding-block: 120px; background: linear-gradient(180deg, rgba(6, 10, 18, .55), rgba(6, 10, 18, .85)), var(--poster) center / cover no-repeat; }
.no-js .chapter-final .plan, .scene-off .chapter-final .plan { background: rgba(8, 12, 20, .78); }

/* ─── Le livre du K (20/10/2026) : le récit en évidence, la déclinaison pour l'agence juste en dessous ─── */
.chapter h2.chapter-title, .js:not(.scene-off) .chapter h2.chapter-title {
  font-family: var(--font-mono); font-size: 12px; font-weight: 500; letter-spacing: .18em; text-transform: uppercase;
  line-height: 1.4; margin: 0; color: var(--accent-2); text-shadow: 0 1px 12px rgba(0, 0, 0, .5);
}
.recit, .js:not(.scene-off) .chapter .beat > p.recit, .js:not(.scene-off) .chapter .beat > h1.recit {
  font-family: var(--font-display); font-weight: 600; font-size: clamp(24px, 2.35vw, 40px); line-height: 1.18; letter-spacing: -.01em;
  color: var(--text); margin: 14px 0 0; max-width: 24ch; text-shadow: 0 2px 26px rgba(0, 0, 0, .45);
}
.js:not(.scene-off) .chapter .beat > h1.recit-promise { font-size: clamp(28px, 2.9vw, 48px); line-height: 1.08; max-width: 19ch; }
.decl, .js:not(.scene-off) .chapter .beat > p.decl {
  margin: 22px 0 0; padding-left: 14px; border-left: 1px solid rgba(224, 153, 90, .6);
  font-family: var(--font-ui); font-size: clamp(15px, 1.08vw, 17.5px); line-height: 1.6; color: #D3D8E3; max-width: 46ch;
}
.decl-label { display: block; margin-bottom: 6px; font-family: var(--font-mono); font-size: 11px; font-weight: 500; letter-spacing: .16em; text-transform: uppercase; color: var(--accent-2); }
.js:not(.scene-off) .chapter .decl { opacity: 0; transform: translateY(10px); transition: opacity .7s ease-out .45s, transform .9s cubic-bezier(.16, 1, .3, 1) .45s; }
.js:not(.scene-off) .chapter .beat.is-in .decl { opacity: 1; transform: none; }
.offer-title, .js:not(.scene-off) .chapter h3.offer-title { font-family: var(--font-display); font-weight: 700; font-size: clamp(26px, 2.5vw, 42px); line-height: 1.1; margin-top: 12px; }
.chapter-era .era { font-size: 12px; }
@media (max-width: 767px) {
  .recit, .js:not(.scene-off) .chapter .beat > p.recit, .js:not(.scene-off) .chapter .beat > h1.recit { font-size: clamp(20px, 5.8vw, 26px); max-width: none; }
  .js:not(.scene-off) .chapter .beat > h1.recit-promise { font-size: clamp(26px, 7.6vw, 34px); }
  .decl, .js:not(.scene-off) .chapter .beat > p.decl { font-size: 14px; margin-top: 14px; }
  .offer-title, .js:not(.scene-off) .chapter h3.offer-title { font-size: clamp(22px, 6.4vw, 30px); }
}

/* ─── Dernier écran (21/10/2026) ─── */
.js:not(.scene-off) .chapter-outro .chapter-text { left: 50%; top: 38%; width: min(560px, 80vw); min-width: 0; max-width: none; transform: translate(-50%, -50%); text-align: center; }
.no-js .chapter-outro, .scene-off .chapter-outro { justify-content: center; }
@media (max-width: 767px) {
  .js:not(.scene-off) .chapter-outro .chapter-text { top: 34%; bottom: auto; left: 50%; right: auto; width: 82vw; background: none; border: 0; backdrop-filter: none; -webkit-backdrop-filter: none; padding: 0; transform: translate(-50%, -50%); }
}
/* Texte réservé aux lecteurs d'écran (titre de la révélation, porté par le logo à l'écran). */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* ─── TEXTES_V2 (21/10/2026) ─── */
/* Narration sur toute la largeur de la zone de texte (36 %) ; apparition en deux temps : la première phrase, puis la
   suite (paragraphe de continuation, décalé), puis la note « Pour votre agence ». */
.js:not(.scene-off) .chapter .beat > p.recit, .js:not(.scene-off) .chapter .beat > h1.recit, .js:not(.scene-off) .chapter .beat > h1.recit-promise,
.js:not(.scene-off) .chapter .beat > p.story-lead { max-width: none; }
.js:not(.scene-off) .chapter .beat > p.recit-cont { margin-top: .22em; }
.js:not(.scene-off) .beat.is-in .recit-cont .ln-i { transition-delay: calc(var(--i, 0) * 80ms + 700ms); }
.js:not(.scene-off) .chapter .beat.is-in .decl, .js:not(.scene-off) .chapter .beat.is-in > p.sig-sub { transition-delay: 1.15s, 1.15s; }
.chapter-subtitle { margin-top: 8px; font-family: var(--font-display); font-style: italic; font-size: clamp(15px, 1.1vw, 18px); color: rgba(237, 239, 243, .88); text-shadow: 0 1px 12px rgba(0, 0, 0, .55); }
.js:not(.scene-off) .chapter .beat > p.offer-hook { font-family: var(--font-display); font-style: italic; font-weight: 500; font-size: clamp(19px, 1.6vw, 27px); line-height: 1.3; color: var(--text); margin: 14px 0 0; max-width: none; }
.js:not(.scene-off) .chapter .beat > p.offer-note { font-size: clamp(14px, 1vw, 16px); color: #C9CEDA; margin-top: 14px; }

/* VI, VII et VIII : au milieu de l'écran, sous un voile centré. */
.js:not(.scene-off) .chapter-signature .chapter-text { left: 0; right: 0; top: 0; bottom: 0; width: auto; min-width: 0; max-width: none; transform: none; text-align: left; padding: 0; background: none; border: 0; backdrop-filter: none; -webkit-backdrop-filter: none; }
.js:not(.scene-off) .chapter-signature .beats { position: absolute; inset: 0; display: block; margin: 0; }
.js:not(.scene-off) .chapter-signature .beat, .js:not(.scene-off) .chapter-signature .beat.is-in { position: absolute; grid-area: auto; }
.js:not(.scene-off) .chapter-signature .beat-center { left: 50%; right: auto; top: 44%; width: min(1040px, 92vw); transform: translate(-50%, -50%); text-align: center; }
.js:not(.scene-off) .chapter .beat > h2.sig-title, .js:not(.scene-off) .chapter .beat > p.sig-title {
  font-family: var(--font-display); font-weight: 600; font-size: clamp(28px, 2.9vw, 48px); line-height: 1.08; letter-spacing: -.01em;
  color: var(--text); margin: 12px 0 0; max-width: none; text-shadow: 0 2px 28px rgba(0, 0, 0, .45);
}
.js:not(.scene-off) .chapter .beat > p.sig-title.recit-cont { margin-top: .12em; }
/* Titre plus grand ; largeur en em : les coupures restent celles du texte fourni (« Pas une ville. / Une nouvelle forme /
   d'organisation. », « Pas une intelligence / qui répond. / Une intelligence qui fait / fonctionner le travail. »). */
.js:not(.scene-off) .chapter-signature .beat.beat-statement > h2.sig-title, .js:not(.scene-off) .chapter-signature .beat.beat-statement > p.sig-title { font-size: clamp(32px, 3.5vw, 60px); width: 12.4em; max-width: 100%; margin-left: auto; margin-right: auto; text-shadow: 0 2px 34px rgba(0, 0, 0, .6); }
.js:not(.scene-off) .chapter-signature .beat.beat-statement > h2.sig-title { margin-top: 16px; }
.js:not(.scene-off) .chapter-signature .beat.beat-statement > p.sig-sub { margin: 26px auto 0; max-width: 50ch; font-size: clamp(16px, 1.22vw, 19.5px); color: #DDE1EA; text-shadow: 0 1px 16px rgba(0, 0, 0, .7); text-wrap: balance; }
.js:not(.scene-off) .chapter .beat-statement > p.sig-sub::before { content: ""; display: block; width: 40px; height: 1px; margin: 0 auto 20px; background: var(--accent-2); }
.js:not(.scene-off) .chapter .beat > p.sig-sub { margin: 20px 0 0; font-size: clamp(15px, 1.08vw, 17.5px); line-height: 1.6; color: #D3D8E3; max-width: 46ch; opacity: 0; transform: translateY(10px); transition: opacity .7s ease-out, transform .9s cubic-bezier(.16, 1, .3, 1); }
.js:not(.scene-off) .chapter .beat.is-in > p.sig-sub { opacity: 1; transform: none; }

/* VIII : les cinq noms, un par un, la première lettre en cuivre ; puis la phrase. */
.names { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: nowrap; white-space: nowrap; justify-content: center; align-items: baseline; gap: .15em .45em;
  font-family: var(--font-display); font-weight: 600; font-size: clamp(22px, 2.5vw, 46px); line-height: 1.15; color: var(--text); text-shadow: 0 2px 26px rgba(0, 0, 0, .5); }
.names .initial { color: var(--accent-2); }
.names .sep { color: rgba(237, 239, 243, .35); }
.js:not(.scene-off) .names li { opacity: 0; transform: translateY(14px); transition: opacity .4s ease-out, transform .8s cubic-bezier(.16, 1, .3, 1); }
.js:not(.scene-off) .beat-names.is-in .names li { transition-delay: calc(var(--n) * .38s + .1s); }
.js:not(.scene-off) .beat-names.is-in .names li { opacity: 1; transform: none; }
.js:not(.scene-off) .chapter-signature .beat-names { width: min(1400px, 94vw); }
.js:not(.scene-off) .chapter .beat > p.names-phrase { margin: 28px auto 0; font-family: var(--font-display); font-style: italic; font-size: clamp(17px, 1.5vw, 24px); line-height: 1.4; color: #D3D8E3; max-width: 62ch; opacity: 0; transition: opacity .5s ease-out; }
.js:not(.scene-off) .chapter .beat-names.is-in > p.names-phrase { opacity: 1; transition: opacity .8s ease-out 2.2s; }

/* Logo en deux temps : d'abord le K seul, puis KARTHOS et la promesse (révélation VIII et final X). */
.lockup { width: min(600px, 72vw, 66vh); margin: 0 auto; }
.lockup img { display: block; width: 100%; height: auto; }
.js:not(.scene-off) .lockup img { transition: opacity .5s ease-out, transform .8s cubic-bezier(.16, 1, .3, 1); }
.js:not(.scene-off) .lockup .lockup-k { opacity: 0; transform: scale(.94); }
.js:not(.scene-off) .lockup .lockup-texte { opacity: 0; transform: translateY(10px); }
.js:not(.scene-off) .beat.is-in .lockup img { opacity: 1; transform: none; }
.js:not(.scene-off) .beat.is-in .lockup .lockup-k { transition: opacity .9s ease-out .1s, transform 1.2s cubic-bezier(.16, 1, .3, 1) .1s; }
.js:not(.scene-off) .beat.is-in .lockup .lockup-texte { transition: opacity .9s ease-out 1.1s, transform 1s cubic-bezier(.16, 1, .3, 1) 1.1s; }

/* X : titre et bouton d'accès, puis le logo. */
.js:not(.scene-off) .chapter-outro .chapter-text { width: min(760px, 88vw); }
.js:not(.scene-off) .chapter-outro .lockup { width: min(520px, 76vw, 58vh); }
.js:not(.scene-off) .chapter .beat > h2.final-title { font-family: var(--font-display); font-weight: 700; font-size: clamp(30px, 3.4vw, 56px); line-height: 1.08; margin: 0; }
/* Une phrase par ligne : « Karthos » ouvre la seconde, mis en valeur (22/10/2026). */
.final-title .ft-line { display: block; white-space: nowrap; }
.final-title .ft-line + .ft-line { margin-top: .06em; }
.final-ctas { justify-content: center; margin-top: 30px; }

@media (max-width: 767px) {
  .js:not(.scene-off) .chapter-signature .beat-center { top: 46%; width: 90vw; }
  .js:not(.scene-off) .chapter .beat > h2.sig-title, .js:not(.scene-off) .chapter .beat > p.sig-title { font-size: clamp(24px, 7vw, 32px); }
  .js:not(.scene-off) .chapter-signature .beat-statement { width: calc(100vw - 32px); }
  .js:not(.scene-off) .chapter-signature .beat.beat-statement > h2.sig-title, .js:not(.scene-off) .chapter-signature .beat.beat-statement > p.sig-title { font-size: clamp(24px, 7vw, 32px); }
  .js:not(.scene-off) .chapter-signature .beat.beat-statement > p.sig-sub { font-size: 15px; margin-top: 18px; }
  .js:not(.scene-off) .chapter .beat > p.sig-sub { font-size: 14px; margin-top: 14px; }
  .names { flex-direction: column; align-items: center; gap: .1em; font-size: clamp(24px, 7.4vw, 32px); }
  .js:not(.scene-off) .chapter-signature .beat-names { width: 90vw; }
  .names .sep { display: none; }
  .lockup { width: 78vw; }
  /* Dernier écran : chaque phrase tient sur sa ligne (« Karthos exécute le travail. » ≈ 13 em). */
  .js:not(.scene-off) .chapter .beat > h2.final-title { font-size: min(32px, 6.7vw); margin-left: -4vw; margin-right: -4vw; }
}

/* Écrans peu hauts (portable avec zoom, fenêtre réduite) : le récit suit aussi la hauteur, pour ne pas descendre jusqu'au
   label d'époque. Tailles inchangées en 1440×900, 1280×720 et 1920×1080 (la largeur reste la limite). */
@media (min-width: 768px) {
  .js:not(.scene-off) .chapter .beat > p.story-lead { font-size: clamp(22px, min(2.7vw, 4.9vh), 46px); }
  .js:not(.scene-off) .chapter .beat > p.recit, .js:not(.scene-off) .chapter .beat > h1.recit { font-size: clamp(20px, min(2.35vw, 4.2vh), 40px); }
  .js:not(.scene-off) .chapter .beat > h1.recit-promise { font-size: clamp(24px, min(2.9vw, 5.2vh), 48px); }
  .js:not(.scene-off) .chapter .beat > p.decl { font-size: clamp(14px, min(1.08vw, 2vh), 17.5px); }
}
/* Filet de sécurité : si le texte touche encore le label d'époque, le label s'efface pendant cette étape. */
.js:not(.scene-off) .chapter.is-active.era-clash .chapter-era { opacity: 0; transition-delay: 0s; }

/* ─── Attirer l'œil sur le texte (21/10/2026) : chaque section se distingue, chaque nouveau texte se remarque ─── */
/* Carte de chapitre : pendant la transition qui mène à une section, son numéro, son nom et son époque au centre. */
.chapter-card { display: none; }
.js:not(.scene-off) .chapter-card {
  display: flex; flex-direction: column; align-items: center; position: absolute; left: 50%; top: 46%; z-index: 25;
  transform: translate(-50%, -50%); opacity: 0; transition: opacity .25s linear; pointer-events: none; text-align: center;
  text-shadow: 0 4px 40px rgba(0, 0, 0, .55);
}
.cc-num { font-family: "Cormorant Garamond", Georgia, "Times New Roman", serif; font-weight: 600; font-size: clamp(96px, 11vw, 184px); line-height: .9; color: var(--accent-2); letter-spacing: .04em; }
.js:not(.scene-off) .chapter-card::before { content: ""; position: absolute; inset: -70px -160px; z-index: -1; background: radial-gradient(closest-side, rgba(6, 10, 18, .6), rgba(6, 10, 18, .28) 60%, rgba(6, 10, 18, 0)); }
.cc-name { margin-top: 10px; font-family: var(--font-display); font-weight: 600; font-size: clamp(26px, 2.6vw, 42px); color: #EDEFF3; }
.cc-era { display: flex; align-items: center; gap: 14px; margin-top: 14px; font-family: var(--font-mono); font-size: 12px; letter-spacing: .24em; text-transform: uppercase; color: rgba(237, 239, 243, .82); }
.cc-era::before, .cc-era::after { content: ""; width: 28px; height: 1px; background: var(--accent-2); }

/* En-tête de section façon chapitre de livre : grand chiffre romain cuivré, nom, points d'étape. */
.js:not(.scene-off) .chapter h2.chapter-title.has-num { display: flex; align-items: center; gap: 12px; }
.ct-num { font-family: "Cormorant Garamond", Georgia, "Times New Roman", serif; font-weight: 600; font-size: clamp(38px, 3.4vw, 54px); line-height: .9; letter-spacing: .04em; color: var(--accent-2); text-shadow: 0 2px 18px rgba(0, 0, 0, .55); }
.ct-sep { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); }
.ct-name { padding-left: 12px; border-left: 1px solid rgba(224, 153, 90, .55); }
.js:not(.scene-off) .chapter-title.has-num .ct-num { transition: transform 1s cubic-bezier(.16, 1, .3, 1) .3s, opacity .8s ease-out .3s; transform: translateY(10px) scale(.92); opacity: 0; }
.js:not(.scene-off) .chapter.is-active .chapter-title.has-num .ct-num { transform: none; opacity: 1; }

/* Points d'étape à côté du titre : combien de textes dans la section, lequel est affiché. */
.beat-dots { display: inline-flex; align-items: center; gap: 6px; margin-left: 4px; }
.beat-dots i { display: block; width: 6px; height: 6px; border-radius: 3px; background: rgba(237, 239, 243, .35); transition: width .45s cubic-bezier(.16, 1, .3, 1), background .45s ease-out, box-shadow .45s ease-out; }
.beat-dots i.is-on { width: 22px; background: var(--accent-2); box-shadow: 0 0 8px rgba(224, 153, 90, .65); }

/* Mise en lumière : à chaque nouveau texte, la vidéo s'assombrit doucement derrière le bloc pendant 2,6 s. */
.scene-focus { position: absolute; inset: 0; z-index: 21; pointer-events: none; opacity: 0;
  background: radial-gradient(ellipse 50% 64% at 24% 42%, rgba(6, 10, 18, .62), rgba(6, 10, 18, .26) 55%, rgba(6, 10, 18, 0) 82%); }
.scene-focus.is-pulse { animation: focus-pulse 2.6s ease-out; }
@keyframes focus-pulse { 0% { opacity: 0; } 18% { opacity: 1; } 55% { opacity: .85; } 100% { opacity: 0; } }

@media (max-width: 767px) {
  .ct-num { font-size: 32px; }
  .js:not(.scene-off) .chapter h2.chapter-title.has-num { gap: 10px; }
  .ct-name { padding-left: 10px; }
  .js:not(.scene-off) .chapter-card { top: 40%; }
  .cc-era { white-space: nowrap; gap: 10px; font-size: 11px; letter-spacing: .16em; }
  .cc-era::before, .cc-era::after { width: 16px; }
  .scene-focus { display: none; }
  .js:not(.scene-off) .scroll-hint { gap: 10px; padding: 8px 14px; }
  .sh-label { font-size: 11px; letter-spacing: .16em; }
}
@media (prefers-reduced-motion: reduce) { .scene-focus.is-pulse { animation: none; } }

/* ─── Langues : fenêtre de choix, bouton de l'en-tête, arabe de droite à gauche (22/10/2026) ─── */
html.lang-wait main, html.lang-wait header, html.lang-wait footer { visibility: hidden; }
html.lang-pending { overflow: hidden; }
.js.lang-pending .chapter-stage, .js.lang-pending .scroll-hint, .js.lang-pending .era-rail, .js.lang-pending .chapter-card { visibility: hidden !important; }
.lang-gate {
  position: fixed; inset: 0; z-index: 200; display: flex; align-items: center; justify-content: center; padding: 16px;
  background: radial-gradient(ellipse 70% 60% at 50% 45%, rgba(6, 10, 18, .45), rgba(6, 10, 18, .86));
  backdrop-filter: blur(5px); -webkit-backdrop-filter: blur(5px); opacity: 0; transition: opacity .5s ease-out;
}
.lang-gate[hidden] { display: none; }
.lang-gate.is-open { opacity: 1; }
.lg-card {
  width: min(540px, 100%); text-align: center; padding: 34px 28px 24px; border-radius: 18px;
  background: rgba(10, 14, 22, .74); border: 1px solid rgba(224, 153, 90, .45);
  box-shadow: 0 30px 80px -30px rgba(0, 0, 0, .85); transform: translateY(14px) scale(.98); transition: transform .7s cubic-bezier(.16, 1, .3, 1);
}
.lang-gate.is-open .lg-card { transform: none; }
.lg-k { display: block; width: 58px; height: 58px; margin: 0 auto; filter: drop-shadow(0 0 16px rgba(224, 153, 90, .65)); }
.lg-title { display: flex; flex-direction: column; gap: 4px; margin: 16px 0 22px; }
.lg-title span:first-child { font-family: var(--font-display); font-size: 22px; font-weight: 600; color: #EDEFF3; }
.lg-title span + span { font-size: 14px; color: rgba(237, 239, 243, .66); }
.lg-options { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.lg-opt {
  display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 16px 8px; border-radius: 12px; cursor: pointer;
  border: 1px solid rgba(237, 239, 243, .16); background: rgba(255, 255, 255, .03); color: #EDEFF3; font: inherit;
  transition: border-color .2s ease-out, background .2s ease-out, transform .2s ease-out;
}
.lg-opt:hover, .lg-opt:focus-visible { border-color: var(--accent-2); background: rgba(224, 153, 90, .12); transform: translateY(-2px); outline: none; }
.lg-opt.is-current { border-color: rgba(224, 153, 90, .7); }
.lg-code { font-family: var(--font-mono); font-size: 12px; letter-spacing: .2em; color: var(--accent-2); }
.lg-name { font-family: var(--font-display); font-size: 17px; font-weight: 600; }
.lg-foot { display: flex; flex-direction: column; gap: 2px; margin-top: 18px; font-size: 11.5px; color: rgba(237, 239, 243, .5); }
.lang-gate [lang="ar"], .lang-gate [lang="ar"] * { font-family: "Readex Pro", "Segoe UI", Tahoma, "Geeza Pro", sans-serif; letter-spacing: normal; }
.lg-opt[lang="ar"] .lg-code { font-size: 15px; }
@media (max-width: 480px) {
  .lg-card { padding: 28px 18px 20px; }
  .lg-options { grid-template-columns: 1fr; }
  .lg-opt { flex-direction: row; justify-content: center; gap: 12px; padding: 13px; }
}
.lang-switch {
  font-family: var(--font-mono); font-size: 12px; letter-spacing: .12em; color: #EDEFF3; background: transparent; cursor: pointer;
  border: 1px solid rgba(237, 239, 243, .22); border-radius: 999px; min-width: 40px; height: 32px; padding: 0 10px;
  transition: border-color .2s ease-out, color .2s ease-out;
}
.lang-switch:hover, .lang-switch:focus-visible { border-color: var(--accent-2); color: var(--accent-2); outline: none; }
.lang-switch[hidden] { display: none; }

/* Arabe : police Readex Pro (lettres arabes et latines), aucun espacement de lettres (il casserait les liaisons), lignes
   plus hautes (signes au-dessus et au-dessous des lettres), lecture de droite à gauche. Les chiffres romains, les cinq noms
   latins et le slogan anglais gardent leur dessin. Le bloc de texte reste à gauche de l'écran (le K est à droite). */
html[lang="ar"] { --font-display: "Readex Pro", "Segoe UI", Tahoma, sans-serif; --font-ui: "Readex Pro", "Segoe UI", Tahoma, sans-serif; --font-mono: "Readex Pro", "Segoe UI", Tahoma, sans-serif; }
html[lang="ar"] body *:not(.footer-baseline):not(.ct-num):not(.cc-num) { letter-spacing: normal !important; }
html[lang="ar"] .ln { padding-top: .14em; margin-top: -.14em; padding-bottom: .26em; margin-bottom: -.26em; }
html[lang="ar"] .chapter :is(.recit, .story-lead, .sig-title, .offer-hook, .offer-title, .final-title, .names-phrase, .chapter-subtitle) { line-height: 1.42 !important; }
html[lang="ar"] .chapter :is(.decl, .sig-sub, .offer-note) { line-height: 1.85 !important; }
html[lang="ar"] .decl-label { font-size: 13px; }
html[dir="rtl"] .decl, html[dir="rtl"] .js:not(.scene-off) .chapter .beat > p.decl { padding-left: 0; padding-right: 14px; border-left: 0; border-right: 1px solid rgba(224, 153, 90, .6); }
html[dir="rtl"] .ct-name { padding-left: 0; padding-right: 12px; border-left: 0; border-right: 1px solid rgba(224, 153, 90, .55); }
html[dir="rtl"] .beat-dots { margin-left: 0; margin-right: 4px; }
html[dir="rtl"] .names { direction: ltr; }
/* Badge de la carte mise en avant (écrit en CSS dans index.html) : traduit. */
html[lang="en"] .plan.is-highlight::after { content: "Recommended"; }
html[lang="ar"] .plan.is-highlight::after { content: "موصى بها"; }
html[dir="rtl"] .plan.is-highlight::after { right: auto; left: 0; }
