/* =========================================================
   LA SAUCE MAGIQUE DE L'ANALYSTE NBA — Feuille de style
   ---------------------------------------------------------
   Pour changer les couleurs du site, modifiez les variables
   ci-dessous (section :root).
   ========================================================= */

:root {
  --bg: #0a0a0c;            /* fond principal */
  --bg-2: #131317;          /* fond des cartes */
  --bg-3: #1b1b21;
  --line: rgba(255, 255, 255, 0.09);
  --text: #f3f1ec;          /* texte principal */
  --muted: #c9c9d1;         /* texte secondaire (plus clair, choix du 2026-10-31) */
  --accent: #ff5a1f;        /* orange basket (boutons, titres) */
  --accent-2: #ff8a3d;
  --data-orange: #f05a14;   /* couleur des données (graphiques) */
  --data-blue: #1a98c8;     /* 2e couleur des données */

  --font-title: "Anton", "Impact", "Arial Narrow", sans-serif;
  --font-label: "Barlow Condensed", "Arial Narrow", sans-serif;
  --font-body: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --radius: 14px;
  --gutter: clamp(16px, 4vw, 48px);
  color-scheme: dark;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 400; }
p { margin: 0 0 1em; }
::selection { background: var(--accent); color: #000; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

/* ---------- Toile 3D + vignette ---------- */
#scene3d {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  display: block;
  pointer-events: none;
}
.vignette {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(120% 90% at 50% 40%, transparent 55%, rgba(0,0,0,.55) 100%),
    repeating-linear-gradient(0deg, rgba(255,255,255,.012) 0 1px, transparent 1px 3px);
}
/* Si la 3D ne peut pas s'afficher : un dégradé orange en fond */
.no-webgl .vignette {
  background:
    radial-gradient(40% 45% at 75% 35%, rgba(255,90,31,.28), transparent 70%),
    radial-gradient(120% 90% at 50% 40%, transparent 55%, rgba(0,0,0,.55) 100%);
}

main, .footer, .topbar { position: relative; z-index: 2; }
/* Empêche tout élément animé de créer un défilement horizontal */
main { overflow-x: hidden; }
@supports (overflow: clip) { main { overflow-x: clip; } }

.container { width: 100%; max-width: 1180px; margin: 0 auto; padding-inline: var(--gutter); }
.container.narrow { max-width: 860px; }

/* ---------- En-tête ---------- */
.topbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: calc(14px + env(safe-area-inset-top, 0px)) var(--gutter) 14px;
  transition: background .3s, border-color .3s, padding .3s;
  border-bottom: 1px solid transparent;
}
.topbar.is-solid {
  background: rgba(10, 10, 12, 0.82);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
  padding-block: 10px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-title);
  font-size: 22px;
  letter-spacing: .02em;
  text-decoration: none;
}
.brand-thin { color: var(--accent); }
.brand-dot {
  width: 12px; height: 12px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #ffb27a, var(--accent) 60%, #a83200);
  box-shadow: 0 0 12px rgba(255, 90, 31, .7);
}
.topnav { display: flex; gap: 28px; }
.topnav a {
  font-family: var(--font-label);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: .12em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--muted);
  transition: color .2s;
}
.topnav a:hover { color: var(--text); }

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--font-label);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: .08em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 999px;
  padding: 16px 34px;
  border: 0;
  cursor: pointer;
  transition: transform .2s, box-shadow .2s, background .2s;
  user-select: none;
}
.btn-primary {
  background: linear-gradient(135deg, var(--accent-2), var(--accent) 55%, #e2410a);
  color: #120500;
  box-shadow: 0 10px 34px -8px rgba(255, 90, 31, .65), inset 0 1px 0 rgba(255,255,255,.35);
}
.btn-primary:not([aria-disabled="true"]):hover { transform: translateY(-2px); box-shadow: 0 16px 40px -8px rgba(255, 90, 31, .8); }
.btn-primary::after {
  content: "";
  width: 18px; height: 18px;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 12h13M13 6l6 6-6 6' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 12h13M13 6l6 6-6 6' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/contain no-repeat;
}
.btn-small {
  font-size: 15px;
  padding: 9px 18px;
  background: rgba(255, 90, 31, .12);
  color: var(--accent-2);
  border: 1px solid rgba(255, 90, 31, .45);
  white-space: nowrap;
}
/* Bouton désactivé (tant que le lien de paiement n'est pas renseigné) */
.btn[aria-disabled="true"] { cursor: not-allowed; filter: saturate(.75); opacity: .78; }

.buy-wrap { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.buy-soon {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
  display: inline-flex; align-items: center; gap: 8px;
}
.buy-soon::before {
  content: ""; width: 7px; height: 7px; border-radius: 50%;
  background: #f5b400; box-shadow: 0 0 8px #f5b400;
}
.is-live .buy-soon { display: none; }

/* ---------- Petits éléments communs ---------- */
.kicker, .section-num, .concept-tag {
  font-family: var(--font-label);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 18px;
}
.kicker { display: inline-flex; align-items: center; gap: 10px; color: var(--text); }
.live-dot {
  position: relative;
  display: inline-block;
  flex: none;
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent);
}
.live-dot::after {
  content: "";
  position: absolute; inset: 0;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 1.8s ease-out infinite;
}
@keyframes pulse {
  0% { transform: scale(1); opacity: .7; }
  100% { transform: scale(3.2); opacity: 0; }
}

.panel {
  background: linear-gradient(180deg, rgba(27, 27, 33, .82), rgba(16, 16, 20, .82));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

/* ---------- 1. Accueil ---------- */
.hero {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  position: relative;
  padding: 120px var(--gutter) 90px;
}
.hero-inner { width: 100%; max-width: 1180px; margin: 0 auto; }
.hero-title {
  font-family: var(--font-title);
  font-size: clamp(54px, 9.2vw, 138px);
  line-height: .9;
  text-transform: uppercase;
  letter-spacing: -.005em;
  margin-bottom: 26px;
  max-width: 11ch;
}
.hero-title .line { display: block; }
.hero-title em {
  font-style: normal;
  -webkit-text-stroke: 1.5px var(--text);
  color: transparent;
}
.hero-title .accent {
  color: var(--accent);
  text-shadow: 0 0 40px rgba(255, 90, 31, .35);
}
.hero-sub {
  max-width: 520px;
  font-size: clamp(16px, 1.4vw, 19px);
  color: #eeede9;
  margin-bottom: 34px;
}
.hero-buy { display: flex; flex-wrap: wrap; align-items: center; gap: 22px 28px; }

/* Étiquette de prix façon "score bug" TV */
.price-tag {
  display: grid;
  grid-template-columns: auto auto;
  grid-template-rows: auto auto;
  column-gap: 14px;
  align-items: center;
  padding: 10px 18px 10px 0;
  border-right: 1px solid var(--line);
}
.price-label {
  grid-row: 1 / 3;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-family: var(--font-label);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: #120500;
  background: var(--accent);
  padding: 8px 4px;
  border-radius: 4px;
}
.price-value { font-family: var(--font-title); font-size: 46px; line-height: 1; }
.price-note { font-size: 13px; color: var(--muted); letter-spacing: .04em; }

.hero-stats {
  list-style: none;
  margin: 46px 0 0;
  padding: 0;
  display: flex;
  gap: 36px;
}
.hero-stats li { display: flex; flex-direction: column; }
.hero-stats strong { font-family: var(--font-title); font-size: 30px; line-height: 1; font-weight: 400; }
.hero-stats span {
  font-family: var(--font-label); font-weight: 600; font-size: 13px;
  letter-spacing: .18em; text-transform: uppercase; color: var(--muted);
}

.scroll-cue {
  position: absolute;
  left: 50%; bottom: 26px;
  transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  text-decoration: none;
  font-family: var(--font-label); font-size: 13px; letter-spacing: .3em; text-transform: uppercase;
  color: var(--muted);
}
.scroll-cue i {
  width: 1px; height: 40px;
  background: linear-gradient(var(--accent), transparent);
  animation: cue 1.8s ease-in-out infinite;
  transform-origin: top;
}
@keyframes cue { 0% { transform: scaleY(0); } 50% { transform: scaleY(1); } 100% { transform: scaleY(1); opacity: 0; } }

/* ---------- Bandeau défilant ---------- */
.ticker-wrap { overflow: hidden; padding-block: 16px; margin-top: -6px; }
.ticker {
  position: relative;
  overflow: hidden;
  background: var(--accent);
  color: #120500;
  transform: rotate(-1.5deg) scale(1.02);
  box-shadow: 0 10px 40px rgba(255, 90, 31, .25);
}
.ticker-track {
  display: flex;
  width: max-content;
  animation: ticker 32s linear infinite;
}
.ticker span {
  font-family: var(--font-title);
  font-size: 22px;
  padding: 10px 26px;
  white-space: nowrap;
  display: inline-flex; align-items: center; gap: 26px;
}
.ticker span::after { content: "◆"; font-size: 10px; opacity: .6; }
@keyframes ticker { to { transform: translateX(-50%); } }

/* ---------- Sections ---------- */
.section { padding: clamp(90px, 13vw, 160px) 0; position: relative; }
.section-head { max-width: 760px; margin-bottom: 56px; }
.section h2 {
  font-family: var(--font-title);
  font-size: clamp(38px, 5.4vw, 72px);
  line-height: .98;
  text-transform: uppercase;
  margin-bottom: 22px;
}
.lead { font-size: clamp(16px, 1.35vw, 19px); color: #eeede9; max-width: 640px; }
.section h3 {
  font-family: var(--font-label);
  font-weight: 700;
  font-size: 25px;
  line-height: 1.1;
  letter-spacing: .01em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

/* ---------- 2. Problème ---------- */
.problem-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.problem-card { padding: 30px 28px 26px; position: relative; overflow: hidden; }
.problem-card p { color: var(--muted); margin: 0; }
.problem-idx {
  display: block;
  font-family: var(--font-title);
  font-size: 64px;
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255, 90, 31, .7);
  margin-bottom: 18px;
}

/* ---------- Interlude 3D ---------- */
.scene-section { height: 280vh; position: relative; }
.scene-sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
}
.scene-captions {
  position: absolute;
  left: var(--gutter);
  bottom: 12vh;
  right: var(--gutter);
  max-width: 820px;
}
.caption {
  position: absolute;
  left: 0; bottom: 0;
  margin: 0;
  font-family: var(--font-title);
  font-size: clamp(36px, 6vw, 84px);
  line-height: .95;
  text-transform: uppercase;
  text-shadow: 0 4px 30px rgba(0,0,0,.6);
}
.caption span { color: var(--accent); display: block; }
.hud {
  position: absolute;
  top: 96px;
  right: var(--gutter);
  width: 230px;
  padding: 14px 16px;
  font-family: var(--font-label);
  background: rgba(10, 10, 12, .72);
  border: 1px solid var(--line);
  border-left: 3px solid var(--accent);
  border-radius: 8px;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
.hud-head {
  display: flex; flex-wrap: wrap; align-items: center; gap: 2px 8px;
  font-weight: 700; font-size: 13px; letter-spacing: .18em; text-transform: uppercase;
  margin-bottom: 10px;
}
.hud-head em { flex-basis: 100%; font-size: 13px; font-style: normal; color: var(--muted); letter-spacing: .05em; font-weight: 500; text-transform: none; }
.hud-row {
  display: flex; justify-content: space-between; align-items: baseline;
  border-top: 1px solid var(--line);
  padding: 6px 0;
  font-size: 15px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted);
}
.hud-row strong { font-family: var(--font-title); font-weight: 400; font-size: 24px; color: var(--text); letter-spacing: 0; font-variant-numeric: tabular-nums; }
.hud-legend { display: flex; gap: 16px; padding-top: 8px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.hud-legend span { display: inline-flex; align-items: center; gap: 6px; }
.sw { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.sw-made { background: var(--data-orange); }
.sw-miss { background: transparent; border: 2px solid var(--data-blue); }

/* ---------- 3. Chapitres ---------- */
.chapters {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  perspective: 1200px;
}
.chapter {
  position: relative;
  padding: 24px 22px 22px;
  border-radius: var(--radius);
  background: linear-gradient(160deg, rgba(34, 34, 41, .9), rgba(14, 14, 18, .92));
  border: 1px solid var(--line);
  overflow: hidden;
  transition: transform .35s cubic-bezier(.2,.8,.2,1), border-color .35s, box-shadow .35s;
  transform-style: preserve-3d;
}
.chapter::before {
  content: "";
  position: absolute; inset: 0 0 auto 0; height: 3px;
  background: linear-gradient(90deg, var(--accent), transparent);
  transform: scaleX(.25);
  transform-origin: left;
  transition: transform .45s ease;
}
.chapter:hover { transform: translateY(-6px); border-color: rgba(255, 90, 31, .45); box-shadow: 0 24px 50px -24px rgba(255, 90, 31, .45); }
.chapter:hover::before { transform: scaleX(1); }
.chapter-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 26px; }
.chapter-n { font-family: var(--font-title); font-size: 48px; line-height: 1; color: var(--accent); }
.chapter-p { font-family: var(--font-label); font-weight: 600; font-size: 13px; letter-spacing: .15em; color: var(--muted); }
.chapter h3 { font-size: 22px; }
.chapter p { margin: 0; color: var(--muted); font-size: 14.5px; line-height: 1.55; }
.chapters-note { margin-top: 26px; color: var(--muted); font-family: var(--font-label); font-size: 17px; letter-spacing: .06em; }

/* ---------- 4. Aperçu (concepts + graphiques) ---------- */
.concept {
  display: grid;
  grid-template-columns: 1fr 1.05fr;
  gap: clamp(26px, 4vw, 60px);
  align-items: center;
  padding: clamp(24px, 4vw, 48px);
  margin-bottom: 24px;
}
.concept-text p { color: #eeede9; }
.concept-text strong { color: var(--text); }
.concept-tag { margin-bottom: 12px; }
.concept h3 { font-size: clamp(26px, 2.6vw, 34px); margin-bottom: 18px; }
.formula {
  font-family: var(--font-label);
  font-weight: 600;
  font-size: 20px;
  letter-spacing: .04em;
  color: var(--text) !important;
  background: rgba(255,255,255,.04);
  border: 1px dashed rgba(255, 90, 31, .45);
  border-radius: 8px;
  padding: 12px 16px;
  display: inline-block;
}
.concept-viz {
  margin: 0;
  background: rgba(8, 8, 10, .6);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 22px;
}
.concept-viz figcaption {
  font-family: var(--font-label);
  font-weight: 600;
  font-size: 14px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 20px;
}

/* Graphique TS% */
.ts-row {
  display: grid;
  grid-template-columns: 150px 1fr 82px;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}
.ts-meta { display: flex; flex-direction: column; line-height: 1.25; }
.ts-meta strong { font-family: var(--font-label); font-size: 18px; text-transform: uppercase; letter-spacing: .05em; }
.ts-meta span { font-size: 13px; color: var(--muted); }
.ts-bar, .ppp-bar {
  height: 16px;
  position: relative;
  background-image: linear-gradient(90deg, rgba(255,255,255,.08) 1px, transparent 1px);
  background-size: 33.333% 100%;
  border-left: 1px solid rgba(255,255,255,.35);
}
.ts-fill, .ppp-fill {
  height: 100%;
  width: calc(var(--v) / 75 * 100%);
  background: var(--data-orange);
  border-radius: 0 4px 4px 0;
  transform-origin: left center;
}
.ts-row:first-child .ts-fill { background: var(--data-blue); }
.ts-val { font-family: var(--font-title); font-size: 22px; text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ts-axis, .ppp-axis {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  color: var(--muted);
  margin: -6px 96px 0 164px;
}
.ts-axis span, .ppp-axis span { width: 0; display: flex; justify-content: center; white-space: nowrap; }

/* Shot chart SVG */
.shot-svg { width: 100%; height: auto; display: block; border-radius: 8px; background: #0c0c0f; }
.zone { fill: var(--data-orange); fill-opacity: calc(.08 + var(--z) * .72); stroke: #0c0c0f; stroke-width: 2; }
.court-lines * { fill: none; stroke: rgba(255,255,255,.55); stroke-width: 1.5; }
.zone-labels text {
  font-family: var(--font-title);
  font-size: 19px;
  fill: #fff;
  text-anchor: middle;
  paint-order: stroke;
  stroke: rgba(0,0,0,.55);
  stroke-width: 3px;
}
.scale-legend { display: flex; align-items: center; gap: 10px; margin-top: 14px; font-size: 13px; color: var(--muted); }
.scale-legend i {
  flex: 1; max-width: 160px; height: 8px; border-radius: 4px;
  background: linear-gradient(90deg, rgba(240,90,20,.15), rgba(240,90,20,.8));
}

/* Graphique PnR */
.ppp-row { display: grid; grid-template-columns: 70px 1fr 50px; align-items: center; gap: 14px; margin-bottom: 14px; }
.ppp-k { font-family: var(--font-label); font-weight: 700; font-size: 17px; text-transform: uppercase; letter-spacing: .05em; }
.ppp-fill { width: calc(var(--v) / 1.2 * 100%); background: var(--data-blue); }
.ppp-fill.is-hi { background: var(--data-orange); }
.ppp-v { font-family: var(--font-title); font-size: 20px; text-align: right; font-variant-numeric: tabular-nums; }
.ppp-axis { margin: 0 64px 0 84px; }

/* ---------- 5. Pour qui ---------- */
.audience { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.aud { padding: 28px 24px; transition: transform .3s, border-color .3s; }
.aud:hover { transform: translateY(-4px); border-color: rgba(255, 90, 31, .4); }
.aud p { color: var(--muted); margin: 0; font-size: 15px; }
.aud-icon {
  display: grid; place-items: center;
  width: 52px; height: 52px; border-radius: 12px;
  background: rgba(255, 90, 31, .1);
  border: 1px solid rgba(255, 90, 31, .35);
  margin-bottom: 22px;
}
.aud-icon svg { width: 26px; height: 26px; fill: none; stroke: var(--accent); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- 6. Auteur ---------- */
.author { display: grid; grid-template-columns: 340px 1fr; gap: clamp(30px, 5vw, 70px); align-items: start; }
.author-card { padding: 28px; position: sticky; top: 100px; }
.author-avatar {
  aspect-ratio: 1;
  border-radius: 12px;
  overflow: hidden;
  background: radial-gradient(circle at 30% 20%, rgba(255,90,31,.25), transparent 60%), #0e0e12;
  border: 1px solid var(--line);
  color: #fff;
  margin-bottom: 22px;
}
.author-avatar svg { width: 100%; height: 100%; display: block; }
.author-name { font-family: var(--font-title); font-size: 34px; line-height: 1; margin-bottom: 6px; text-transform: uppercase; }
.author-role { color: var(--muted); font-size: 14px; }
.author-facts { list-style: none; margin: 20px 0 0; padding: 0; }
.author-facts li { display: flex; gap: 12px; align-items: baseline; padding: 10px 0; border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.author-facts strong { font-family: var(--font-label); font-size: 18px; color: var(--text); text-transform: uppercase; letter-spacing: .04em; min-width: 92px; }
.story p { font-size: 17px; color: #eeede9; max-width: 680px; }
.story p:first-child::first-letter {
  font-family: var(--font-title);
  float: left;
  font-size: 74px;
  line-height: .85;
  padding: 6px 10px 0 0;
  color: var(--accent);
}
.timeline { list-style: none; margin: 40px 0 0; padding: 0; border-left: 2px solid rgba(255, 90, 31, .35); max-width: 680px; }
.timeline li { position: relative; padding: 0 0 22px 26px; color: var(--muted); }
.timeline li::before {
  content: ""; position: absolute; left: -7px; top: 6px;
  width: 12px; height: 12px; border-radius: 50%;
  background: var(--bg); border: 2px solid var(--accent);
}
.timeline li:last-child::before { background: var(--accent); box-shadow: 0 0 12px var(--accent); }
.timeline span {
  display: block;
  font-family: var(--font-label); font-weight: 700; font-size: 16px;
  letter-spacing: .14em; text-transform: uppercase; color: var(--text);
}

/* ---------- 7. FAQ ---------- */
.faq details {
  border-bottom: 1px solid var(--line);
  background: rgba(10, 10, 12, .55);
}
.faq details:first-child { border-top: 1px solid var(--line); }
.faq summary {
  list-style: none;
  cursor: pointer;
  display: flex; justify-content: space-between; align-items: center; gap: 20px;
  padding: 24px 6px;
  font-family: var(--font-label);
  font-weight: 700;
  font-size: clamp(19px, 2vw, 23px);
  text-transform: uppercase;
  letter-spacing: .02em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  flex: none;
  display: grid; place-items: center;
  width: 34px; height: 34px; border-radius: 50%;
  border: 1px solid rgba(255, 90, 31, .5);
  color: var(--accent);
  font-family: var(--font-body); font-size: 20px; font-weight: 400;
  transition: transform .3s, background .3s;
}
.faq details[open] summary::after { transform: rotate(45deg); background: rgba(255, 90, 31, .12); }
.faq details p { padding: 0 6px 24px; margin: 0; color: #eeede9; max-width: 720px; }
.faq details a { color: var(--accent-2); }

/* ---------- 8. Appel final ---------- */
.final { overflow: hidden; }
.final::before {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(60% 70% at 25% 50%, rgba(255, 90, 31, .22), transparent 70%),
    linear-gradient(180deg, transparent, rgba(10,10,12,.85) 30%, rgba(10,10,12,.85) 70%, transparent);
  z-index: -1;
}
.final-inner { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: clamp(30px, 6vw, 90px); align-items: center; }
.book { perspective: 1400px; display: flex; justify-content: center; }
.book img {
  width: min(320px, 70vw);
  height: auto;
  border-radius: 4px 12px 12px 4px;
  transform: rotateY(-22deg) rotateX(6deg);
  box-shadow:
    -2px 0 0 #2a2a30,
    -26px 40px 60px -10px rgba(0,0,0,.7),
    0 0 80px -10px rgba(255, 90, 31, .35);
  transition: transform .6s cubic-bezier(.2,.8,.2,1);
}
.book:hover img { transform: rotateY(-8deg) rotateX(2deg); }
.checklist { list-style: none; padding: 0; margin: 0 0 34px; }
.checklist li { position: relative; padding: 8px 0 8px 34px; color: #eeede9; border-bottom: 1px solid var(--line); }
.checklist li::before {
  content: ""; position: absolute; left: 0; top: 13px;
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4 8-9' fill='none' stroke='%23120500' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/12px no-repeat;
}

/* ---------- 9. Pied de page ---------- */
.footer {
  border-top: 1px solid var(--line);
  background: #070708;
  padding: 44px 0 calc(30px + env(safe-area-inset-bottom, 0px));
}
.footer-inner { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 20px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 10px 28px; }
.footer-links a { color: var(--muted); text-decoration: none; font-size: 15px; display: inline-block; padding-block: 10px; }
.footer-links a:hover { color: var(--text); text-decoration: underline; }
.footer-small { margin-top: 30px; padding-top: 22px; border-top: 1px solid var(--line); }
.footer-small p { font-size: 13px; color: #a9a9b2; margin-bottom: 6px; }

/* =========================================================
   PAGES LÉGALES (mentions légales, CGV, confidentialité)
   ========================================================= */
.legal-page { background: var(--bg); }
.legal-header { position: static; background: rgba(10,10,12,.9); border-bottom: 1px solid var(--line); }
.legal { max-width: 820px; margin: 0 auto; padding: 60px var(--gutter) 100px; }
.legal h1 { font-family: var(--font-title); font-size: clamp(40px, 6vw, 64px); text-transform: uppercase; line-height: 1; margin-bottom: 18px; }
.legal h2 { font-family: var(--font-label); font-weight: 700; font-size: 24px; text-transform: uppercase; letter-spacing: .03em; margin: 44px 0 12px; color: var(--accent); }
.legal p, .legal li { color: #eeede9; }
.legal ul { padding-left: 20px; }
.legal a { color: var(--accent-2); }
.legal .todo { background: rgba(245, 180, 0, .14); color: #ffd24d; padding: 1px 6px; border-radius: 4px; font-weight: 600; }
.legal .notice {
  border: 1px solid rgba(245, 180, 0, .45);
  background: rgba(245, 180, 0, .07);
  border-radius: 10px;
  padding: 16px 18px;
  font-size: 14.5px;
}
.legal .updated { color: var(--muted); font-size: 14px; }
.back-link { display: inline-block; margin-top: 50px; font-family: var(--font-label); font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--accent) !important; text-decoration: none; }

/* =========================================================
   RESPONSIVE (tablettes et téléphones)
   ========================================================= */
@media (max-width: 1080px) {
  .chapters { grid-template-columns: repeat(2, 1fr); }
  .audience { grid-template-columns: repeat(2, 1fr); }
  .concept { grid-template-columns: 1fr; }
  .author { grid-template-columns: 1fr; }
  .author-card { position: static; max-width: 420px; }
}
@media (max-width: 860px) {
  .topnav { display: none; }
  .problem-grid { grid-template-columns: 1fr; }
  .final-inner { grid-template-columns: 1fr; }
  .book img { width: min(240px, 60vw); }
}
@media (max-width: 600px) {
  .brand { font-size: 19px; }
  .author-card { display: grid; grid-template-columns: 96px 1fr; column-gap: 18px; align-items: center; }
  .author-avatar { margin-bottom: 0; grid-row: 1 / 3; }
  .author-name { font-size: 30px; }
  .author-role { margin: 0; }
  .author-facts { grid-column: 1 / -1; }
  .author-facts strong { min-width: 84px; font-size: 16px; }
  .story p { font-size: 16px; }
  .concept-viz { padding: 18px 16px; }
  .ppp-row { grid-template-columns: 62px 1fr 46px; gap: 10px; }
  .ppp-axis { margin: 0 56px 0 72px; }
  .faq summary { padding-block: 20px; }
  .btn-small { font-size: 13px; padding: 8px 14px; }
  /* Sur téléphone, le ballon s'affiche en haut : le texte descend */
  .hero { align-items: flex-end; padding-top: 42vh; padding-bottom: 80px; }
  .hero-stats { gap: 26px; margin-top: 34px; }
  .scroll-cue { display: none; }
  .chapters, .audience { grid-template-columns: 1fr; }
  .btn-primary { width: 100%; }
  .buy-wrap { width: 100%; align-items: stretch; }
  .buy-soon { justify-content: center; }
  .price-tag { border-right: 0; padding-right: 0; }
  .ts-row { grid-template-columns: 1fr 74px; gap: 6px 10px; }
  .ts-meta { grid-column: 1 / -1; flex-direction: row; gap: 10px; align-items: baseline; }
  .ts-axis { margin: -6px 84px 0 0; }
  .hud { top: auto; bottom: 16px; right: 16px; left: auto; width: 190px; padding: 10px 12px; }
  .hud-row strong { font-size: 19px; }
  .scene-captions { bottom: auto; top: 96px; }
  .caption { bottom: auto; top: 0; }
  .scene-section { height: 220vh; }
}

/* =========================================================
   "RÉDUIRE LES ANIMATIONS" activé dans le système
   ========================================================= */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .scene-section { height: auto; padding: 80px 0; }
  .scene-sticky { position: relative; height: auto; overflow: visible; }
  .scene-captions { position: relative; left: auto; right: auto; bottom: auto; top: auto; padding-inline: var(--gutter); max-width: 1180px; margin: 0 auto; }
  .caption { position: relative; top: auto; bottom: auto; margin-bottom: 18px; font-size: clamp(30px, 4.5vw, 56px); }
  .hud { display: none; }
}

/* 3D indisponible (navigateur ancien ou hors connexion) */
.no-webgl #scene3d, .no-webgl .hud { display: none; }
.hud { opacity: 0; }

/* =========================================================
   PERFORMANCES SUR TÉLÉPHONE
   L'effet de flou (backdrop-filter) au-dessus d'une 3D animée
   est très coûteux sur mobile : on le remplace par des fonds
   plus opaques.
   ========================================================= */
@media (max-width: 768px), (pointer: coarse) {
  .panel, .hud, .topbar.is-solid {
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
  .panel { background: linear-gradient(180deg, rgba(27, 27, 33, .95), rgba(16, 16, 20, .95)); }
  .hud { background: rgba(10, 10, 12, .92); }
  .topbar.is-solid { background: rgba(10, 10, 12, .96); }
  .chapter:hover, .aud:hover { transform: none; }
}
