/* ROQYA — Se faire roqia soi-même
   Direction : nuit profonde, or du logo, une couleur vive par étape du parcours. */

:root {
  --bg: #05080a;
  --bg-2: #0a1215;
  --surface: rgba(255, 255, 255, .035);
  --surface-2: rgba(255, 255, 255, .06);
  --line: rgba(255, 255, 255, .09);
  --line-strong: rgba(255, 255, 255, .16);
  --text: #f1ece0;
  --muted: #a9b1b3;
  --gold: #e9c46a;
  --gold-2: #f7e3a8;
  --gold-ink: #1a1405;
  --aqua: #3fe6cf;

  /* une couleur vive par colonne */
  --c-djinns: #9d8cff;
  --c-mal: #ff7a8a;
  --c-diag: #5cb8ff;
  --c-guerison: #46e0a4;
  --c-protection: #f2c45a;
  --c-biblio: #3fe6cf;

  --font-display: "Cormorant Garamond", "Times New Roman", serif;
  --font-body: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-ar: "Amiri", "Traditional Arabic", serif;

  --radius: 18px;
  --radius-sm: 12px;
  --wrap: 1180px;
  --gutter: clamp(16px, 4vw, 40px);
  --header-h: 72px;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
:focus-visible { outline: 2px solid var(--aqua); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 500; line-height: 1.12; margin: 0; text-wrap: balance; letter-spacing: .005em; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 16px; top: -60px; z-index: 200; background: var(--gold); color: var(--gold-ink); padding: 10px 16px; border-radius: 10px; font-weight: 700; }
.skip:focus { top: 12px; }

/* ---------- Fond : aurore lente ---------- */
.aurora { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; background: radial-gradient(120% 80% at 50% 0%, #0b161a 0%, var(--bg) 60%); }
.aurora i { position: absolute; border-radius: 50%; filter: blur(90px); opacity: .5; will-change: transform; }
.aurora i:nth-child(1) { width: 52vw; height: 52vw; left: -14vw; top: -18vw; background: #1fb7a6; opacity: .28; animation: drift-a 38s var(--ease) infinite alternate; }
.aurora i:nth-child(2) { width: 44vw; height: 44vw; right: -12vw; top: 4vw; background: #6f5cf0; opacity: .24; animation: drift-b 46s var(--ease) infinite alternate; }
.aurora i:nth-child(3) { width: 38vw; height: 38vw; left: 30vw; top: 46vh; background: #c9963a; opacity: .13; animation: drift-a 54s var(--ease) infinite alternate-reverse; }
@keyframes drift-a { to { transform: translate3d(8vw, 6vh, 0) scale(1.15); } }
@keyframes drift-b { to { transform: translate3d(-9vw, 9vh, 0) scale(1.1); } }

/* ---------- En-tête ---------- */
.header { position: sticky; top: 0; z-index: 100; height: var(--header-h); border-bottom: 1px solid transparent; transition: background .3s, border-color .3s; }
.header.is-stuck, .header.is-open { background: rgba(5, 8, 10, .82); backdrop-filter: blur(18px) saturate(140%); -webkit-backdrop-filter: blur(18px) saturate(140%); border-bottom-color: var(--line); }
.header .wrap { height: 100%; display: flex; align-items: center; gap: 20px; max-width: 1320px; }
.brand { display: flex; align-items: center; gap: 10px; flex: none; }
.brand img { width: 44px; height: 44px; border-radius: 12px; }
.brand b { font-family: var(--font-display); font-size: 26px; font-weight: 600; letter-spacing: .22em; color: var(--gold-2); }

.nav { flex: 1; display: flex; justify-content: center; }
.nav > ul { display: flex; align-items: center; gap: 2px; }
.nav-btn { display: flex; align-items: center; gap: 6px; height: 44px; padding: 0 12px; border-radius: 999px; font-size: 14.5px; font-weight: 600; color: var(--muted); white-space: nowrap; transition: color .2s, background .2s; }
.nav-btn svg { width: 14px; height: 14px; transition: transform .25s var(--ease); opacity: .7; }
.nav-btn:hover, .nav-item.is-open .nav-btn { color: var(--text); background: var(--surface-2); }
.nav-item.is-open .nav-btn svg { transform: rotate(180deg); }
.nav-item.is-open .nav-btn { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--c) 55%, transparent); }

.drawer { position: absolute; left: 0; right: 0; top: var(--header-h); padding: 0 var(--gutter); visibility: hidden; opacity: 0; transform: translateY(-8px); transition: opacity .22s var(--ease), transform .22s var(--ease), visibility 0s .22s; }
.nav-item.is-open .drawer { visibility: visible; opacity: 1; transform: none; transition-delay: 0s; }
.drawer-in { max-width: 1000px; margin: 10px auto 0; display: grid; grid-template-columns: 280px 1fr; gap: 28px; padding: 26px; border: 1px solid var(--line); border-top: 2px solid var(--c); border-radius: var(--radius); background: rgba(9, 15, 18, .96); backdrop-filter: blur(24px); box-shadow: 0 30px 80px rgba(0, 0, 0, .55), 0 0 60px color-mix(in srgb, var(--c) 10%, transparent); }
.drawer-head h3 { font-size: 30px; color: var(--c); }
.drawer-head p { margin-top: 8px; font-size: 14.5px; color: var(--muted); }
.drawer-head a { display: inline-flex; align-items: center; gap: 6px; margin-top: 16px; font-size: 14px; font-weight: 700; color: var(--text); min-height: 44px; }
.drawer-head a::after { content: "→"; transition: transform .2s; }
.drawer-head a:hover::after { transform: translateX(4px); }
.drawer-links { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 12px; align-content: start; }
.drawer-links a { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 8px 12px; border-radius: 10px; font-size: 15px; transition: background .2s; }
.drawer-links a::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--c); flex: none; box-shadow: 0 0 10px var(--c); }
.drawer-links a:hover { background: var(--surface-2); }
.tag { margin-left: auto; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: 3px 8px; border-radius: 999px; border: 1px solid var(--line-strong); color: var(--muted); }
.tag.free { color: var(--c-guerison); border-color: color-mix(in srgb, var(--c-guerison) 45%, transparent); }
.tag.premium { color: var(--gold); border-color: color-mix(in srgb, var(--gold) 45%, transparent); }

.header-cta { display: flex; align-items: center; gap: 8px; flex: none; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 22px; border-radius: 999px; font-weight: 700; font-size: 15.5px; transition: transform .2s var(--ease), box-shadow .25s, background .2s, border-color .2s; }
.btn:active { transform: scale(.97); }
.btn-gold { background: linear-gradient(135deg, var(--gold-2), var(--gold) 55%, #c99a3b); color: var(--gold-ink); box-shadow: 0 8px 30px rgba(233, 196, 106, .22); }
.btn-gold:hover { box-shadow: 0 10px 40px rgba(233, 196, 106, .4); transform: translateY(-1px); }
.btn-ghost { border: 1px solid var(--line-strong); background: var(--surface); }
.btn-ghost:hover { border-color: var(--aqua); background: rgba(63, 230, 207, .07); }
.btn-sm { min-height: 44px; padding: 0 18px; font-size: 14.5px; }
.burger { display: none; width: 48px; height: 48px; border-radius: 12px; align-items: center; justify-content: center; }
.burger span, .burger span::before, .burger span::after { display: block; width: 22px; height: 2px; background: var(--text); border-radius: 2px; transition: transform .25s var(--ease), opacity .2s; }
.burger span { position: relative; }
.burger span::before, .burger span::after { content: ""; position: absolute; left: 0; }
.burger span::before { top: -7px; } .burger span::after { top: 7px; }
.header.is-open .burger span { background: transparent; }
.header.is-open .burger span::before { transform: translateY(7px) rotate(45deg); }
.header.is-open .burger span::after { transform: translateY(-7px) rotate(-45deg); }
.nav-extra { display: none; }

/* ---------- Hero ---------- */
.hero { position: relative; padding: clamp(40px, 7vw, 96px) 0 clamp(56px, 8vw, 110px); }
.hero .wrap { display: grid; grid-template-columns: 1.1fr .9fr; align-items: center; gap: clamp(24px, 5vw, 72px); }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; color: var(--aqua); }
.eyebrow::before { content: ""; width: 28px; height: 1px; background: currentColor; }
.hero h1 { margin-top: 18px; font-size: clamp(46px, 7.4vw, 96px); font-weight: 500; }
.hero h1 em { font-style: italic; background: linear-gradient(100deg, var(--gold-2), var(--gold) 45%, var(--aqua)); -webkit-background-clip: text; background-clip: text; color: transparent; padding-right: .08em; }
.hero .lead { margin-top: 22px; max-width: 34em; font-size: clamp(17px, 1.6vw, 20px); color: var(--muted); }
.hero-actions { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 12px; }
.hero-facts { margin-top: 40px; display: flex; flex-wrap: wrap; gap: 12px 34px; font-size: 14.5px; color: var(--muted); }
.hero-facts b { display: block; font-family: var(--font-display); font-size: 34px; font-weight: 500; line-height: 1; color: var(--text); font-variant-numeric: lining-nums tabular-nums; }

.orb { position: relative; width: min(100%, 460px); aspect-ratio: 1; margin-inline: auto; display: grid; place-items: center; }
.orb::before { content: ""; position: absolute; inset: 14%; border-radius: 50%; background: radial-gradient(circle, rgba(233, 196, 106, .34), rgba(63, 230, 207, .12) 45%, transparent 70%); filter: blur(26px); animation: breathe 9s ease-in-out infinite; }
.orb .ring { position: absolute; border-radius: 50%; border: 1px solid rgba(233, 196, 106, .2); }
.orb .ring:nth-of-type(1) { inset: 6%; animation: spin 80s linear infinite; border-style: dashed; border-color: rgba(63, 230, 207, .22); }
.orb .ring:nth-of-type(2) { inset: 0; border-color: rgba(255, 255, 255, .07); }
.orb .ring:nth-of-type(1)::after { content: ""; position: absolute; top: -4px; left: 50%; width: 8px; height: 8px; border-radius: 50%; background: var(--aqua); box-shadow: 0 0 18px var(--aqua); }
.orb img { position: relative; width: 74%; animation: float 9s ease-in-out infinite; }
@keyframes breathe { 0%, 100% { transform: scale(.92); opacity: .75; } 50% { transform: scale(1.08); opacity: 1; } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Sections ---------- */
.section { padding: clamp(56px, 8vw, 110px) 0; }
.section-head { max-width: 720px; margin-bottom: clamp(28px, 4vw, 52px); }
.section-head h2 { margin-top: 14px; font-size: clamp(34px, 4.6vw, 58px); }
.section-head p { margin-top: 14px; color: var(--muted); }

/* Parcours : 5 étapes */
.path { display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; counter-reset: step; }
.step { position: relative; display: flex; flex-direction: column; min-height: 300px; padding: 24px 22px; border: 1px solid var(--line); border-radius: var(--radius); background: linear-gradient(180deg, color-mix(in srgb, var(--c) 9%, transparent), var(--surface) 55%); overflow: hidden; transition: transform .35s var(--ease), border-color .3s, box-shadow .35s; }
.step::before { counter-increment: step; content: "0" counter(step); font-family: var(--font-display); font-size: 15px; letter-spacing: .2em; color: var(--c); }
.step::after { content: ""; position: absolute; left: 22px; right: 22px; top: 0; height: 2px; background: linear-gradient(90deg, var(--c), transparent); }
.step:hover { transform: translateY(-6px); border-color: color-mix(in srgb, var(--c) 55%, transparent); box-shadow: 0 24px 60px rgba(0, 0, 0, .4), 0 0 50px color-mix(in srgb, var(--c) 14%, transparent); }
.step .ico { width: 46px; height: 46px; margin-top: 18px; border-radius: 14px; display: grid; place-items: center; color: var(--c); background: color-mix(in srgb, var(--c) 13%, transparent); }
.ico svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.step h3 { margin-top: 18px; font-size: 27px; }
.step p { margin-top: 8px; font-size: 14.5px; color: var(--muted); flex: 1; }
.step .more { margin-top: 18px; font-size: 14px; font-weight: 700; color: var(--c); }
.step .more::after { content: " →"; }

/* Bibliothèque */
.shelf { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.tile { display: flex; flex-direction: column; gap: 10px; padding: 24px 22px; min-height: 210px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); transition: border-color .3s, background .3s, transform .35s var(--ease); }
.tile:hover { border-color: color-mix(in srgb, var(--c-biblio) 50%, transparent); background: rgba(63, 230, 207, .05); transform: translateY(-4px); }
.tile .ico { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; color: var(--c-biblio); background: rgba(63, 230, 207, .1); }
.tile h3 { font-size: 25px; }
.tile p { font-size: 14.5px; color: var(--muted); flex: 1; }
.tile .tags { display: flex; gap: 6px; }
.tile .tag { margin: 0; }

/* Formation + livres */
.duo { display: grid; grid-template-columns: 1.35fr 1fr; gap: 14px; }
.panel { position: relative; padding: clamp(26px, 3.4vw, 44px); border: 1px solid var(--line); border-radius: 24px; background: var(--surface); overflow: hidden; display: flex; flex-direction: column; align-items: flex-start; }
.panel h3 { margin-top: 14px; font-size: clamp(30px, 3.4vw, 44px); }
.panel p { margin-top: 12px; color: var(--muted); max-width: 34em; }
.panel ul { margin-top: 18px; display: grid; gap: 8px; font-size: 15px; }
.panel li { display: flex; gap: 10px; }
.panel li::before { content: ""; flex: none; width: 7px; height: 7px; margin-top: .62em; border-radius: 50%; background: var(--gold); box-shadow: 0 0 10px var(--gold); }
.panel .btn { margin-top: 28px; }
.panel-gold { border-color: rgba(233, 196, 106, .28); background: radial-gradient(120% 120% at 100% 0%, rgba(233, 196, 106, .16), transparent 55%), var(--surface); }
.panel-gold .eyebrow { color: var(--gold); }

/* Articles */
.posts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.post { padding: 24px 22px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); display: flex; flex-direction: column; gap: 12px; min-height: 180px; }
.post span { font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.post h3 { font-size: 25px; }
.post p { font-size: 14.5px; color: var(--muted); }

/* Écosystème */
.eco { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.eco a { display: flex; flex-direction: column; gap: 6px; padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); transition: border-color .3s, background .3s; min-height: 130px; }
.eco a:hover { border-color: var(--gold); background: rgba(233, 196, 106, .05); }
.eco b { font-family: var(--font-display); font-size: 23px; font-weight: 500; }
.eco span { font-size: 14px; color: var(--muted); flex: 1; }
.eco i { font-style: normal; font-size: 13px; color: var(--gold); overflow-wrap: anywhere; }

/* FAQ */
.faq { max-width: 860px; margin-inline: auto; }
.faq .section-head { text-align: center; margin-inline: auto; }
.faq .eyebrow::before { display: none; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: 18px; min-height: 68px; padding: 16px 4px; cursor: pointer; list-style: none; font-family: var(--font-display); font-size: clamp(21px, 2.2vw, 25px); line-height: 1.25; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: none; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line-strong); background: linear-gradient(var(--text), var(--text)) center / 12px 1.5px no-repeat, linear-gradient(var(--text), var(--text)) center / 1.5px 12px no-repeat; transition: transform .3s var(--ease), border-color .3s; }
.faq details[open] summary::after { transform: rotate(45deg); border-color: var(--gold); }
.faq details[open] summary { color: var(--gold-2); }
.faq .answer { padding: 0 4px 24px; color: var(--muted); font-size: 16px; }
.faq .answer strong { color: var(--text); font-weight: 600; }
.faq .answer ul, .faq .answer ol { margin: 10px 0 0; padding-left: 22px; display: grid; gap: 6px; }
.faq .answer ul { list-style: disc; } .faq .answer ol { list-style: decimal; }
.faq-more { margin-top: 32px; text-align: center; }

/* Pied de page */
.footer { margin-top: 40px; border-top: 1px solid var(--line); padding: 56px 0 32px; background: rgba(0, 0, 0, .35); }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 32px; }
.footer .brand b { font-size: 24px; }
.footer p { margin-top: 14px; font-size: 14.5px; color: var(--muted); max-width: 30em; }
.footer h4 { margin: 0 0 12px; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); font-family: var(--font-body); }
.footer li a { display: inline-flex; align-items: center; min-height: 36px; font-size: 15px; color: var(--muted); }
.footer li a:hover { color: var(--text); }
.notice { margin-top: 40px; padding: 18px 20px; border: 1px solid var(--line); border-radius: var(--radius-sm); font-size: 14px; color: var(--muted); }
.notice b { color: var(--text); }
.legal { margin-top: 24px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; font-size: 13.5px; color: var(--muted); }

/* Message « page en préparation » */
.toast { position: fixed; left: 50%; bottom: 24px; z-index: 300; transform: translate(-50%, 20px); padding: 12px 20px; border-radius: 999px; background: rgba(12, 20, 23, .96); border: 1px solid var(--line-strong); font-size: 14.5px; opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s var(--ease); max-width: calc(100vw - 32px); text-align: center; }
.toast.on { opacity: 1; transform: translate(-50%, 0); }

/* Apparition au défilement */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s var(--ease), transform .6s var(--ease); transition-delay: var(--d, 0s); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Adaptation ---------- */
@media (max-width: 1180px) {
  .burger { display: flex; }
  .header .wrap { justify-content: space-between; }
  .header-cta .btn { display: none; }
  .nav { position: absolute; left: 0; right: 0; top: var(--header-h); height: calc(100vh - var(--header-h)); height: calc(100dvh - var(--header-h)); display: block; padding: 12px var(--gutter) 40px; background: rgba(5, 8, 10, .98); overflow-y: auto; visibility: hidden; opacity: 0; transition: opacity .25s, visibility 0s .25s; }
  .header.is-open .nav { visibility: visible; opacity: 1; transition-delay: 0s; }
  .nav > ul { flex-direction: column; align-items: stretch; gap: 0; }
  .nav-item { border-bottom: 1px solid var(--line); }
  .nav-btn { width: 100%; height: 60px; padding: 0 4px; justify-content: space-between; font-size: 18px; color: var(--text); border-radius: 0; }
  .nav-btn:hover, .nav-item.is-open .nav-btn { background: none; box-shadow: none; color: var(--c); }
  .nav-btn svg { width: 18px; height: 18px; }
  .drawer { position: static; padding: 0; visibility: visible; opacity: 1; transform: none; display: none; }
  .nav-item.is-open .drawer { display: block; }
  .drawer-in { display: block; margin: 0 0 16px; padding: 0; border: 0; background: none; box-shadow: none; backdrop-filter: none; }
  .drawer-head h3, .drawer-head p { display: none; }
  .drawer-head a { margin: 0 0 4px; color: var(--c); }
  .drawer-links { grid-template-columns: 1fr; }
  .drawer-links a { padding-inline: 4px; }
  .nav-extra { display: grid; gap: 10px; margin-top: 24px; }
  .path { grid-template-columns: repeat(2, 1fr); }
  .path .step:last-child { grid-column: 1 / -1; min-height: 0; }
  .shelf, .eco { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .cosmos { order: -1; width: min(88vw, 400px); }
  .duo, .posts { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid > :first-child { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  body { font-size: 16.5px; }
  .path, .shelf, .eco { grid-template-columns: 1fr; }
  .step { min-height: 0; }
  .hero-actions .btn { width: 100%; }
  .brand b { font-size: 22px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; }
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; }
  .hero h1 .w { opacity: 1; filter: none; transform: none; }
}

/* =====================================================================
   Mouvement : étoiles, système de planètes, effets de lumière
   ===================================================================== */
@property --ang { syntax: "<angle>"; initial-value: 0deg; inherits: false; }

.stars { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }
body::after { content: ""; position: fixed; inset: 0; z-index: 400; pointer-events: none; opacity: .055; mix-blend-mode: overlay; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
.progress { position: fixed; left: 0; top: 0; z-index: 150; width: 100%; height: 2px; transform-origin: 0 50%; transform: scaleX(0); background: linear-gradient(90deg, var(--gold), var(--aqua), var(--c-djinns)); box-shadow: 0 0 12px var(--aqua); }

/* Titre : les mots se posent un par un */
.hero { overflow: clip; }
.hero .wrap { grid-template-columns: 1fr 1fr; }
.hero h1 .w { display: inline-block; animation: word 1s var(--ease) both; animation-delay: calc(var(--i) * .11s + .15s); }
@keyframes word { from { opacity: 0; filter: blur(14px); transform: translateY(.35em); } }

/* Système de planètes */
.cosmos { position: relative; width: min(100%, 580px); aspect-ratio: 1; margin-inline: auto; }
.cosmos .dial { position: absolute; inset: 20%; border-radius: 50%; opacity: .32; background: repeating-conic-gradient(from 0deg, rgba(255, 255, 255, .55) 0 .5deg, transparent .5deg 5deg); -webkit-mask: radial-gradient(closest-side, transparent calc(100% - 6px), #000 calc(100% - 6px)); mask: radial-gradient(closest-side, transparent calc(100% - 6px), #000 calc(100% - 6px)); animation: spin 140s linear infinite; }
.cosmos .orbits { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; z-index: 1; }
.orbits ellipse { fill: none; stroke-width: 1px; vector-effect: non-scaling-stroke; opacity: .5; }
.orbits ellipse.dash { stroke-dasharray: 3 7; animation: dash 40s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -400; } }
.core { position: absolute; inset: 27%; z-index: 2; display: grid; place-items: center; }
.core::before { content: ""; position: absolute; inset: -18%; border-radius: 50%; background: radial-gradient(circle, rgba(233, 196, 106, .42), rgba(63, 230, 207, .14) 45%, transparent 70%); filter: blur(22px); animation: breathe 9s ease-in-out infinite; }
.core i { position: absolute; inset: 6%; border-radius: 50%; border: 1px solid rgba(233, 196, 106, .55); opacity: 0; animation: ping 6s var(--ease) infinite; }
.core i + i { animation-delay: 3s; }
@keyframes ping { 0% { transform: scale(.7); opacity: 0; } 15% { opacity: .7; } 100% { transform: scale(2.1); opacity: 0; } }
.core img { position: relative; width: 100%; animation: float 9s ease-in-out infinite; filter: drop-shadow(0 0 22px rgba(233, 196, 106, .35)); }
.planet { position: absolute; left: 50%; top: 50%; width: var(--s, 16px); height: var(--s, 16px); border-radius: 50%; background: radial-gradient(circle at 32% 30%, #fff, var(--c) 42%, color-mix(in srgb, var(--c) 35%, #000) 100%); box-shadow: 0 0 16px var(--c), 0 0 44px color-mix(in srgb, var(--c) 50%, transparent); will-change: transform; }
.planet::before { content: ""; position: absolute; inset: -15px; border-radius: 50%; }
.planet::after { content: ""; position: absolute; inset: -5px; border-radius: 50%; border: 1px solid color-mix(in srgb, var(--c) 60%, transparent); opacity: 0; transform: scale(.6); transition: opacity .25s, transform .25s var(--ease); }
.planet:hover::after, .planet:focus-visible::after { opacity: 1; transform: scale(1.5); }
.planet span { position: absolute; left: 50%; bottom: calc(100% + 12px); transform: translate(-50%, 4px); white-space: nowrap; font-size: 12.5px; font-weight: 700; letter-spacing: .02em; padding: 5px 11px; border-radius: 999px; background: rgba(8, 14, 17, .92); border: 1px solid color-mix(in srgb, var(--c) 55%, transparent); color: var(--text); opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s var(--ease); }
.planet:hover span, .planet:focus-visible span { opacity: 1; transform: translate(-50%, 0); }

/* Bandeau défilant */
.marquee { overflow: hidden; padding: 6px 0 10px; border-block: 1px solid var(--line); -webkit-mask: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); mask: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); }
.marquee-track { display: flex; width: max-content; animation: slide 46s linear infinite; }
.marquee span { display: inline-flex; align-items: center; gap: 36px; padding-left: 36px; font-family: var(--font-display); font-style: italic; font-size: clamp(34px, 5vw, 64px); line-height: 1.2; color: transparent; -webkit-text-stroke: 1px rgba(241, 236, 224, .32); white-space: nowrap; }
.marquee span::after { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 14px var(--gold); }
@keyframes slide { to { transform: translateX(-50%); } }

/* Lumière qui suit le curseur sur les cartes */
.tile, .post, .eco a { position: relative; overflow: hidden; }
.step > *, .tile > *, .panel > *, .post > *, .eco a > * { position: relative; }
.step > .spot, .tile > .spot, .panel > .spot, .post > .spot, .eco a > .spot { position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .35s; background: radial-gradient(380px circle at var(--mx, 50%) var(--my, 0%), color-mix(in srgb, var(--c, var(--aqua)) 22%, transparent), transparent 62%); }
:hover > .spot { opacity: 1 !important; }

/* Inclinaison 3D des cartes du parcours */
.step.reveal.in { transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateY(var(--ty, 0)); transition: transform .25s var(--ease), border-color .3s, box-shadow .35s, opacity .6s var(--ease); }
.step.reveal.in:hover { --ty: -6px; }

/* Bordure lumineuse tournante sur la formation */
.panel-gold::after { content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; pointer-events: none; background: conic-gradient(from var(--ang), transparent 0 62%, var(--gold-2) 78%, var(--aqua) 88%, transparent 100%); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0); animation: turn 7s linear infinite; }
@keyframes turn { to { --ang: 360deg; } }
.btn-gold { position: relative; overflow: hidden; }
.btn-gold::after { content: ""; position: absolute; top: 0; bottom: 0; left: -60%; width: 40%; transform: skewX(-20deg); background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .55), transparent); animation: sheen 5.5s var(--ease) infinite; }
@keyframes sheen { 0%, 70% { left: -60%; } 100% { left: 130%; } }

/* Planètes : davantage de cercles, lunes, anneau */
.hero .wrap { grid-template-columns: .85fr 1.15fr; }
.cosmos { width: min(100%, 700px); }
.core { inset: 29%; }
.orbits ellipse.ghost { stroke: rgba(255, 255, 255, .5); opacity: .16; }
.orbits ellipse.far { opacity: .1; stroke-dasharray: 1 9; }
.orbits ellipse.belt { stroke: rgba(247, 227, 168, .9); stroke-width: 2.5px; stroke-dasharray: .6 7; stroke-linecap: round; opacity: .38; animation: dash 90s linear infinite reverse; }
.planet .moon { position: absolute; inset: -9px; border-radius: 50%; animation: spin 5s linear infinite; pointer-events: none; }
.planet .moon::before { content: ""; position: absolute; left: 50%; top: -2px; width: 5px; height: 5px; margin-left: -2.5px; border-radius: 50%; background: #fff; box-shadow: 0 0 8px #fff; }
.planet .saturn { position: absolute; left: 50%; top: 50%; width: 210%; height: 62%; border-radius: 50%; border: 1.5px solid color-mix(in srgb, var(--c) 75%, #fff); transform: translate(-50%, -50%) rotate(-20deg); opacity: .8; pointer-events: none; box-shadow: 0 0 10px color-mix(in srgb, var(--c) 60%, transparent); }
@media (max-width: 860px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .cosmos { width: min(94vw, 430px); }
}

/* Système de planètes : cadre moins haut que large, le centre reste rond */
.cosmos { aspect-ratio: 1 / .74; }
.cosmos .orbits { inset: auto; left: 0; top: 50%; width: 100%; height: auto; aspect-ratio: 1; transform: translateY(-50%); }
.core { inset: auto; left: 50%; top: 50%; width: 42%; aspect-ratio: 1; transform: translate(-50%, -50%); }
.cosmos .dial { inset: auto; left: 50%; top: 50%; width: 58%; aspect-ratio: 1; margin: -29% 0 0 -29%; }
@media (prefers-reduced-motion: reduce) {
  .hero h1 .w { animation: none !important; }
}

/* =====================================================================
   Scène d'ouverture en 3D
   ===================================================================== */
.intro { position: relative; height: 620vh; margin-top: calc(-1 * var(--header-h)); }
.no-intro .intro { display: none; }
.intro-stage { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; background: #020405; -webkit-mask-image: linear-gradient(#000 88%, transparent); mask-image: linear-gradient(#000 88%, transparent); }
#scene { position: absolute; inset: 0; width: 100%; height: 100%; display: block; opacity: 0; transition: opacity 1.2s var(--ease); }
.intro.ready #scene { opacity: 1; }
.intro-ui { position: absolute; inset: 0; pointer-events: none; }
.intro-ui button { pointer-events: auto; }

.intro-start { position: absolute; left: var(--gutter); right: var(--gutter); bottom: 16vh; display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.intro-start .eyebrow::before { display: none; }
.intro-title { font-family: var(--font-display); font-size: clamp(40px, 6.4vw, 92px); line-height: 1.05; text-shadow: 0 0 40px rgba(0, 0, 0, .8); }
.intro-hint { margin-top: 10px; display: inline-flex; flex-direction: column; align-items: center; gap: 10px; font-size: 12.5px; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
.intro-hint i { width: 24px; height: 38px; border: 1.5px solid var(--line-strong); border-radius: 14px; position: relative; }
.intro-hint i::after { content: ""; position: absolute; left: 50%; top: 7px; width: 3px; height: 7px; margin-left: -1.5px; border-radius: 3px; background: var(--gold); animation: wheel 1.8s var(--ease) infinite; }
@keyframes wheel { 0% { transform: translateY(0); opacity: 1; } 100% { transform: translateY(14px); opacity: 0; } }

.intro-cap { position: absolute; left: clamp(16px, 6vw, 90px); bottom: 14vh; display: flex; flex-direction: column; opacity: 0; transform: translateY(18px); filter: blur(8px); transition: opacity .5s var(--ease), transform .5s var(--ease), filter .5s var(--ease); }
.intro-cap.on { opacity: 1; transform: none; filter: none; }
.intro-cap span { font-size: 12.5px; font-weight: 700; letter-spacing: .22em; color: var(--muted); }
.intro-cap b { font-family: var(--font-display); font-style: italic; font-weight: 500; font-size: clamp(64px, 10vw, 150px); line-height: .95; color: var(--c); text-shadow: 0 0 50px color-mix(in srgb, var(--c) 55%, transparent); }
.intro-cap em { font-style: normal; font-size: clamp(15px, 1.5vw, 19px); letter-spacing: .14em; text-transform: uppercase; color: var(--text); }

.intro-end { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; padding: 0 var(--gutter); text-align: center; opacity: 0; visibility: hidden; transform: translateY(20px); transition: opacity .9s var(--ease), transform .9s var(--ease), visibility 0s .9s; }
.intro-end.on { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
.intro-ar { font-family: var(--font-ar); font-size: clamp(26px, 3.6vw, 50px); line-height: 1.9; color: var(--gold-2); text-shadow: 0 0 30px rgba(233, 196, 106, .45), 0 2px 20px rgba(0, 0, 0, .8); }
.intro-fr { max-width: 30em; font-family: var(--font-display); font-style: italic; font-size: clamp(20px, 2.3vw, 30px); line-height: 1.35; text-shadow: 0 2px 20px rgba(0, 0, 0, .9); }
.intro-ref { font-size: 12.5px; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; color: var(--aqua); }
.intro-end .btn { margin-top: 12px; min-width: 180px; }

.intro-dots { position: absolute; right: clamp(16px, 3vw, 40px); top: 50%; transform: translateY(-50%); display: grid; gap: 14px; }
.intro-dots i { width: 8px; height: 8px; border-radius: 50%; border: 1px solid var(--line-strong); transition: background .4s, box-shadow .4s, border-color .4s; }
.intro-dots i.on { background: var(--gold); border-color: var(--gold); box-shadow: 0 0 14px var(--gold); }
.intro-tools { position: absolute; right: clamp(16px, 3vw, 40px); bottom: clamp(18px, 4vh, 40px); display: flex; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line-strong); background: rgba(5, 8, 10, .55); backdrop-filter: blur(10px); font-size: 13.5px; font-weight: 700; color: var(--text); transition: border-color .2s, background .2s, transform .2s var(--ease); }
.chip:hover { border-color: var(--gold); }
.chip:active { transform: scale(.96); }
.chip svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.chip[aria-pressed="true"] { border-color: var(--gold); color: var(--gold-2); background: rgba(233, 196, 106, .12); }
.chip[aria-pressed="false"] svg path + path { opacity: .25; }
@media (max-width: 560px) {
  .intro { height: 520vh; }
  .intro-cap { bottom: 18vh; }
  .intro-tools { left: 16px; right: 16px; justify-content: space-between; }
}

/* Fin de l'introduction : voile sombre derrière le verset pour la lisibilité */
.intro-end::before { content: ""; position: absolute; left: 50%; top: 50%; width: min(1100px, 130vw); height: min(620px, 90vh); transform: translate(-50%, -50%); background: radial-gradient(closest-side, rgba(2, 4, 5, .82), rgba(2, 4, 5, .55) 55%, transparent); pointer-events: none; }
.intro-end > * { position: relative; }
#scene { transition-duration: .6s; }

/* Légende : le mot est dans la scène, la légende donne son sens */
.intro-cap { gap: 8px; }
.intro-cap em { font-family: var(--font-display); font-style: italic; text-transform: none; letter-spacing: 0; font-size: clamp(30px, 4vw, 54px); line-height: 1.05; color: var(--c); text-shadow: 0 0 30px color-mix(in srgb, var(--c) 50%, transparent), 0 2px 18px rgba(0, 0, 0, .8); }

/* =====================================================================
   Parcours d'ouverture : bouteille de lumière, étapes, curseur
   ===================================================================== */
.intro { height: 760vh; }
.intro-stage { cursor: grab; }
.intro-stage:active { cursor: grabbing; }

/* Lettres déstructurées qui se rejoignent */
.split .wd { display: inline-block; white-space: nowrap; }
.split .ch { display: inline-block; opacity: 0; filter: blur(8px); transform: translate(var(--x), var(--y)) rotate(var(--r)) scale(.5); transition: transform 1.15s var(--ease), opacity .7s var(--ease), filter .7s var(--ease); transition-delay: calc(var(--i) * 28ms); will-change: transform; }
.assemble.on .split .ch { opacity: 1; filter: none; transform: none; }
.assemble:not(.on) .split .ch { transition-duration: .5s, .35s, .35s; transition-delay: 0s; }

.intro-start { bottom: 10vh; opacity: 0; visibility: hidden; transition: opacity .6s var(--ease), visibility 0s .6s; }
.intro-start.on { opacity: 1; visibility: visible; transition-delay: 0s; }
.intro-start .intro-title { font-size: clamp(38px, 6vw, 88px); }

/* Les cinq étapes */
.intro-chap { position: absolute; left: clamp(16px, 6vw, 96px); bottom: 13vh; max-width: min(560px, calc(100vw - 32px)); display: flex; flex-direction: column; align-items: flex-start; gap: 14px; opacity: 0; visibility: hidden; transition: opacity .5s var(--ease), visibility 0s .5s; pointer-events: none; }
.intro-chap.on { opacity: 1; visibility: visible; transition-delay: 0s; pointer-events: auto; }
.intro-chap > * { will-change: transform; }
.chap-ghost { position: absolute; left: -.06em; bottom: .1em; z-index: -1; font-family: var(--font-display); font-size: clamp(220px, 34vw, 520px); line-height: .8; color: transparent; -webkit-text-stroke: 1px color-mix(in srgb, var(--c) 34%, transparent); opacity: .5; pointer-events: none; }
.chap-num { font-size: 12.5px; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; color: var(--c); }
.intro-chap h2 { font-size: clamp(46px, 7.2vw, 108px); line-height: .98; text-shadow: 0 2px 30px rgba(0, 0, 0, .7); }
.intro-chap h2 .ch { text-shadow: 0 0 40px color-mix(in srgb, var(--c) 45%, transparent); }
.intro-chap p { font-size: clamp(16px, 1.5vw, 19px); color: var(--text); max-width: 26em; text-shadow: 0 2px 16px rgba(0, 0, 0, .9); opacity: 0; transition: opacity .6s var(--ease) .35s; }
.intro-chap .btn { opacity: 0; transition: opacity .6s var(--ease) .5s, border-color .2s, background .2s; border-color: color-mix(in srgb, var(--c) 60%, transparent); background: rgba(5, 8, 10, .5); backdrop-filter: blur(8px); }
.intro-chap.on p, .intro-chap.on .btn { opacity: 1; }
.intro-dots { gap: 16px; }

/* Curseur en cercle */
.cursor { position: fixed; left: 0; top: 0; z-index: 500; pointer-events: none; display: none; }
.has-cursor .cursor { display: block; }
.has-cursor, .has-cursor a, .has-cursor button, .has-cursor summary, .has-cursor .intro-stage { cursor: none !important; }
.cursor i, .cursor b { position: absolute; left: 0; top: 0; border-radius: 50%; will-change: transform; }
.cursor i { width: 6px; height: 6px; margin: -3px 0 0 -3px; background: var(--gold-2); box-shadow: 0 0 10px var(--gold); }
.cursor b { width: 44px; height: 44px; margin: -22px 0 0 -22px; border: 1px solid rgba(247, 227, 168, .75); transition: width .3s var(--ease), height .3s var(--ease), margin .3s var(--ease), background .3s, border-color .3s, opacity .3s; display: grid; place-items: center; font: 700 9.5px/1 var(--font-body); letter-spacing: .14em; text-transform: uppercase; color: var(--gold-ink); }
.cursor.link b { width: 68px; height: 68px; margin: -34px 0 0 -34px; background: rgba(247, 227, 168, .14); border-color: var(--gold-2); }
.cursor.scene b { width: 84px; height: 84px; margin: -42px 0 0 -42px; border-color: rgba(247, 227, 168, .55); color: var(--gold-2); }
.cursor.scene b::after { content: "Maintenir"; }
.cursor.down b { width: 30px; height: 30px; margin: -15px 0 0 -15px; background: rgba(247, 227, 168, .5); }
.cursor.down b::after { content: ""; }
.cursor.hide { opacity: 0; }

/* Titres du site : mêmes lettres qui se rejoignent, à l'apparition */
.section-head.assemble h2 .ch { transition-delay: calc(var(--i) * 22ms); }

@media (max-width: 560px) {
  .intro { height: 680vh; }
  .intro-chap { bottom: 16vh; }
  .intro-chap h2 { font-size: clamp(40px, 13vw, 64px); }
}
@media (prefers-reduced-motion: reduce) {
  .split .ch { opacity: 1; filter: none; transform: none; }
}

/* ---------- Ouverture « Libération » : neuf photos sur fond uni qui se fondent l'une dans l'autre ---------- */
.lib { position: relative; height: 100vh; height: 100svh; min-height: 420px; margin-top: calc(-1 * var(--header-h)); background: #040708; overflow: hidden; }
.lib-stage { position: absolute; inset: 0; -webkit-mask-image: linear-gradient(#000 82%, transparent); mask-image: linear-gradient(#000 82%, transparent); }
.lib-stage img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 40%; opacity: 0; transition: opacity 1s linear; }
.lib-stage img.on { opacity: 1; }
.lib-tools { position: absolute; right: var(--gutter); bottom: clamp(18px, 5vh, 44px); display: flex; gap: 10px; }
.lib-tools [hidden] { display: none; }
@media (max-aspect-ratio: 1/1) {
  /* Écran en hauteur : l'image entière, pour ne pas couper les bras ni le verre. */
  .lib-stage img { object-fit: contain; object-position: 50% 42%; }
}
@media (prefers-reduced-motion: reduce) { .lib-stage img { transition: none; } }
