/* =====================================================================
   SHUJAA ESPADA — v2 cinématique
   ===================================================================== */

:root {
  --bg: #0a0708;
  --bg-2: #160b0d;
  --ink: #f3ebe0;
  --mute: #a8969a;
  --dim: #6f5f63;
  --gold: #c4314b;
  --gold-2: #f08c9b;
  --red: #8e1428;
  --ember: #e2405a;
  --line: rgba(243, 235, 224, 0.12);
  --glass: rgba(20, 11, 13, 0.62);
  --tank: #e2b04a;
  --dps: #e5583b;
  --support: #efe2c8;
  --sans: "Archivo", system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: "Instrument Serif", Georgia, "Times New Roman", serif;
  --mono: "JetBrains Mono", ui-monospace, Consolas, monospace;
  --gutter: clamp(16px, 4vw, 56px);
  --nav-h: 56px;
}

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--bg); color-scheme: dark; -webkit-text-size-adjust: 100%; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.55;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
button { font: inherit; color: inherit; }
::selection { background: var(--gold); color: #fff1f3; }

/* ------------------------------------------------------------ fond -- */
#gl {
  position: fixed; inset: 0;
  width: 100%; height: 100%;
  z-index: 1;
  pointer-events: none;
  display: block;
}
.glow {
  position: fixed; inset: -10%;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(48% 42% at 72% 18%, rgba(140, 16, 38, 0.09), transparent 70%),
    radial-gradient(40% 38% at 18% 82%, rgba(196, 49, 75, 0.05), transparent 70%),
    radial-gradient(120% 90% at 50% 50%, transparent 55%, rgba(0, 0, 0, 0.55) 100%);
}
.grain {
  position: fixed; inset: -100px;
  z-index: 40;
  pointer-events: none;
  opacity: 0.075;
  background-image: var(--grain, none); /* fabriqué une fois par ambient.js */
  animation: grain 0.9s steps(5) infinite;
}
@keyframes grain {
  0% { transform: translate(0, 0); }
  20% { transform: translate(-37px, 22px); }
  40% { transform: translate(18px, -41px); }
  60% { transform: translate(-12px, 33px); }
  80% { transform: translate(41px, 9px); }
  100% { transform: translate(0, 0); }
}
.lite .grain { animation: none; }
.flash {
  position: fixed; inset: 0;
  z-index: 45;
  pointer-events: none;
  opacity: 0;
  background: radial-gradient(circle at 50% 50%, #ffe3e8 0%, rgba(240, 140, 155, 0.85) 30%, rgba(140, 16, 38, 0.25) 70%, transparent 100%);
  mix-blend-mode: screen;
}

/* ------------------------------------------------------------- nav -- */
.nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 50;
  height: var(--nav-h);
  display: flex; align-items: center; gap: 24px;
  padding: 0 var(--gutter);
  border-bottom: 1px solid var(--line);
  background: linear-gradient(to bottom, rgba(11, 6, 7, 0.82), rgba(11, 6, 7, 0.45));
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.lite .nav { backdrop-filter: none; -webkit-backdrop-filter: none; background: rgba(11, 6, 7, 0.9); }
.brand {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none;
  font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; font-size: 13px;
}
.brand-logo { width: 26px; height: 26px; color: var(--gold); }
.nav-links { display: flex; gap: 28px; margin-left: auto; }
.nav-links a {
  text-decoration: none; font-size: 14px; color: var(--mute);
  transition: color 0.2s;
}
.nav-links a:hover, .nav-links a:focus-visible { color: var(--ink); }

.btn-gold, .btn-ghost {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 26px;
  border-radius: 999px;
  font-weight: 700; font-size: 15px; letter-spacing: 0.01em;
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.25s, background 0.2s;
}
.btn-gold {
  color: #fff1f3;
  background: linear-gradient(180deg, #cf3a55, #96162d 60%, #6a0c1c);
  box-shadow: 0 0 0 1px rgba(240, 140, 155, 0.35) inset, 0 8px 22px -10px rgba(0, 0, 0, 0.8);
}
.btn-gold:hover, .btn-gold:focus-visible { transform: translateY(-1px); box-shadow: 0 0 0 1px rgba(255, 215, 222, 0.6) inset, 0 10px 26px -10px rgba(0, 0, 0, 0.9); }
.btn-ghost { border: 1px solid var(--line); color: var(--ink); background: rgba(243, 235, 224, 0.03); }
.btn-ghost:hover, .btn-ghost:focus-visible { background: rgba(243, 235, 224, 0.08); }
.btn-sm { min-height: 34px; padding: 0 16px; font-size: 13px; }
.nav .btn-sm { margin-left: 4px; }
:focus-visible { outline: 2px solid var(--gold-2); outline-offset: 3px; }

/* ----------------------------------------------------------- titres -- */
.title {
  margin: 0;
  font-family: var(--sans);
  font-weight: 900;
  font-size: clamp(2.5rem, 7.2vw, 7.4rem);
  line-height: 0.94;
  letter-spacing: -0.035em;
  text-wrap: balance;
  position: relative;
}
.title em {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.01em;
  font-size: 1.08em;
  padding: 0 0.04em 0 0.02em;
  background: linear-gradient(100deg, var(--gold-2) 10%, var(--gold) 55%, var(--ember) 110%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.title .t-main { display: block; will-change: transform, opacity; }
.title .ghost {
  position: absolute; left: 0; top: 0; width: 100%;
  pointer-events: none;
  opacity: 0;
  mix-blend-mode: screen;
}
.title .ghost, .title .ghost em { -webkit-text-fill-color: currentColor; background: none; }
.title .g1 { color: var(--red); }
.title .g2 { color: var(--gold); }

.kicker {
  margin: 0 0 18px;
  font-family: var(--mono);
  font-size: 12px; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--gold);
}
.kicker::before { content: ""; display: inline-block; width: 22px; height: 1px; background: currentColor; vertical-align: middle; margin-right: 12px; }
.lede { margin: 22px 0 0; max-width: 34em; color: var(--mute); font-size: clamp(16px, 1.4vw, 19px); }

/* ---------------------------------------------- scènes épinglées -- */
main { position: relative; z-index: 2; }
.scene { position: relative; }
#intro { height: 260vh; }
#chaos { height: 420vh; }
#reponse { height: 280vh; }
#planning { height: 300vh; }
.stage {
  position: sticky; top: 0;
  height: 100vh; height: 100svh;
  overflow: hidden;
  display: flex; flex-direction: column; justify-content: center;
  padding: calc(var(--nav-h) + 24px) var(--gutter) 40px;
}

/* Intro */
.intro-copy { margin-top: auto; max-width: 1100px; }
.intro-copy .title { font-size: clamp(2.6rem, 7.8vw, 8rem); }
.scroll-hint {
  position: absolute; right: var(--gutter); bottom: 34px;
  display: flex; align-items: center; gap: 12px;
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--mute);
}
.scroll-hint span { width: 1px; height: 46px; background: linear-gradient(var(--gold), transparent); animation: hint 1.8s ease-in-out infinite; transform-origin: top; }
@keyframes hint { 0%, 100% { transform: scaleY(0.3); opacity: 0.4; } 50% { transform: scaleY(1); opacity: 1; } }

/* Carte d'équipe en HTML : lue par les lecteurs d'écran, affichée si WebGL manque */
.team-card-fallback {
  position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%);
}
.no-gl .team-card-fallback {
  position: relative; width: auto; height: auto; clip-path: none; overflow: visible;
  order: -1; margin: 0 auto 32px; max-width: 420px; width: 100%;
  padding: 22px 24px; border: 1px solid rgba(196, 49, 75, 0.45); border-radius: 18px;
  background: var(--glass);
}
.team-card-fallback h3 { margin: 0 0 4px; font-size: 20px; letter-spacing: 0.06em; text-transform: uppercase; }
.team-card-fallback ul { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 4px; font-size: 15px; }
.team-card-fallback li span { color: var(--mute); }
.team-card-fallback p { margin: 0; color: var(--gold); font-family: var(--mono); font-size: 13px; }

/* Chaos */
.kicker-center { text-align: center; }
.kicker-center::before { display: none; }
.questions { position: relative; display: grid; place-items: center; text-align: center; }
.questions .q { grid-area: 1 / 1; max-width: 13em; }
.js:not(.rm) .questions .q { opacity: 0; }
.js:not(.rm) #chaos .kicker { opacity: 0; }

/* Réponse */
.answer { text-align: center; max-width: 1100px; margin: 0 auto; }
.answer .lede { margin-left: auto; margin-right: auto; }
.js:not(.rm) .answer { opacity: 0; }

/* -------------------------------------------------- blocs normaux -- */
.block {
  position: relative;
  padding: clamp(84px, 12vh, 140px) var(--gutter);
  max-width: 1320px; margin: 0 auto;
}
.block-head { max-width: 900px; margin-bottom: clamp(36px, 6vh, 72px); }

/* Équipe */
.team-wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: clamp(24px, 4vw, 64px);
  align-items: center;
}
.constellation {
  position: relative;
  width: min(100%, 640px); aspect-ratio: 1;
  margin: 0 auto;
}
.links { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.links .ln { stroke: rgba(196, 49, 75, 0.35); stroke-width: 0.35; fill: none; vector-effect: non-scaling-stroke; }
.links .ln { stroke-width: 1.2px; }
.links .pulse {
  stroke: var(--gold-2); stroke-width: 2.2px; fill: none; vector-effect: non-scaling-stroke;
  stroke-dasharray: 3 18; stroke-linecap: round;
  animation: flow 1.6s linear infinite;
  opacity: 0.85;
  filter: none;
}
.links .pulse.on { stroke: #ffe3e8; stroke-width: 3px; animation-duration: 0.7s; }
@keyframes flow { to { stroke-dashoffset: -21; } }
.lite .links .pulse { filter: none; }
.rm .links .pulse { animation: none; }

.core {
  position: absolute; left: 50%; top: 50%;
  width: 22%; aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: radial-gradient(circle, #ffe3e8 0%, var(--gold-2) 22%, var(--gold) 42%, rgba(140, 16, 38, 0.5) 66%, transparent 72%);
  box-shadow: none;
  animation: beat 2.4s ease-in-out infinite;
}
.core i {
  position: absolute; inset: -30%;
  border: 1px solid rgba(240, 140, 155, 0.35);
  border-radius: 50%;
  animation: ripple 3.6s ease-out infinite;
}
.core i:nth-child(2) { animation-delay: 1.2s; }
.core i:nth-child(3) { animation-delay: 2.4s; }
@keyframes beat { 0%, 100% { transform: translate(-50%, -50%) scale(1); } 14% { transform: translate(-50%, -50%) scale(1.07); } 28% { transform: translate(-50%, -50%) scale(0.98); } 42% { transform: translate(-50%, -50%) scale(1.04); } }
@keyframes ripple { from { transform: scale(0.6); opacity: 0.9; } to { transform: scale(2.1); opacity: 0; } }
.rm .core, .rm .core i { animation: none; }

.node {
  position: absolute;
  transform: translate(-50%, -50%);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 6px; border: 0; background: none; cursor: pointer;
  width: 26%;
}
.node .av {
  position: relative;
  width: clamp(58px, 9vw, 92px); aspect-ratio: 1;
  border-radius: 50%;
  display: grid; place-items: center;
  font-weight: 900; font-size: clamp(18px, 2.4vw, 28px); letter-spacing: -0.02em;
  background: radial-gradient(circle at 35% 30%, #2a201a, #120d0a 70%);
  border: 1.5px solid var(--rc);
  box-shadow: 0 0 0 5px rgba(11, 6, 7, 0.9);
  color: var(--rc);
  overflow: hidden;
  transition: transform 0.35s cubic-bezier(.2, .8, .2, 1.2), box-shadow 0.3s;
}
.node .av img { width: 100%; height: 100%; object-fit: cover; }
.node .nm { font-weight: 800; font-size: clamp(14px, 1.4vw, 17px); }
.node .ps { font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--mute); margin-top: -6px; }
.node:hover .av, .node:focus-visible .av, .node.on .av { transform: scale(1.12); box-shadow: 0 0 0 5px rgba(11, 6, 7, 0.9); }
.node:focus-visible { outline: none; }
.node:focus-visible .av { outline: 2px solid var(--gold-2); outline-offset: 6px; }
.r-tank { --rc: var(--tank); }
.r-dps { --rc: var(--dps); }
.r-support { --rc: var(--support); }

.fiche {
  position: relative;
  min-height: 330px;
  padding: 28px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: linear-gradient(160deg, rgba(40, 28, 20, 0.7), rgba(14, 8, 9, 0.8));
  box-shadow: 0 30px 80px -30px rgba(0, 0, 0, 0.8);
}
.fiche::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px;
  background: linear-gradient(160deg, var(--rc, var(--gold)), transparent 45%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  pointer-events: none; opacity: 0.8;
}
.fiche .f-role { font-family: var(--mono); font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--rc, var(--gold)); }
.fiche h3 { margin: 6px 0 2px; font-size: 40px; font-weight: 900; letter-spacing: -0.03em; line-height: 1; }
.fiche .f-title { margin: 0; font-family: var(--serif); font-style: italic; font-size: 22px; color: var(--gold-2); }
.fiche .f-label { margin: 22px 0 8px; font-family: var(--mono); font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--dim); }
.fiche .heroes { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.fiche .heroes li { padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: rgba(243, 235, 224, 0.04); font-size: 14px; font-weight: 600; }
.fiche .heroes li:first-child { border-color: var(--rc, var(--gold)); color: var(--rc, var(--gold)); }
.fiche .heroes li:first-child::after { content: " · main"; font-weight: 400; color: var(--mute); font-size: 12px; }
.fiche .f-desc { margin: 18px 0 0; color: var(--mute); font-size: 15px; }
.fiche .f-avg { position: absolute; top: 26px; right: 26px; text-align: right; }
.fiche .f-avg b { display: block; font-size: 34px; font-weight: 900; line-height: 1; color: var(--ink); }
.fiche .f-avg span { font-family: var(--mono); font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--dim); }
.fiche .f-empty { color: var(--mute); margin: 0; }
.fiche .f-empty b { display: block; color: var(--ink); font-size: 26px; font-weight: 900; letter-spacing: -0.02em; margin-bottom: 8px; }

/* Stats */
.counters {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  margin-bottom: clamp(48px, 8vh, 96px);
}
.counter { padding: 28px 20px 26px 0; }
.counter + .counter { padding-left: 24px; border-left: 1px solid var(--line); }
.counter b {
  display: block;
  font-size: clamp(3rem, 7.4vw, 7rem); font-weight: 900; line-height: 0.95; letter-spacing: -0.05em;
  font-variant-numeric: tabular-nums;
}
.counter b small { font-size: 0.4em; letter-spacing: -0.02em; color: var(--gold); margin-left: 4px; }
.counter > span { display: block; margin-top: 10px; font-family: var(--mono); font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--mute); }

.stats-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 80px); align-items: center; }
.radar-box { position: relative; max-width: 500px; width: 100%; margin: 0 auto; }
.radar { width: 100%; height: auto; display: block; overflow: visible; }
.radar .ring { fill: none; stroke: var(--line); }
.radar .ring.r100 { stroke: rgba(196, 49, 75, 0.3); }
.radar .axis { stroke: var(--line); }
.radar .shape { fill: rgba(196, 49, 75, 0.2); stroke: var(--gold-2); stroke-width: 1.8; stroke-linejoin: round; filter: none; }
.lite .radar .shape { filter: none; }
.radar .dot { fill: var(--gold-2); }
.radar text { fill: var(--mute); font-family: var(--mono); font-size: 6.5px; letter-spacing: 0.08em; text-transform: uppercase; }

.picker { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 26px; }
.picker button {
  min-height: 40px; padding: 0 16px; border-radius: 999px;
  border: 1px solid var(--line); background: rgba(243, 235, 224, 0.03);
  font-size: 14px; font-weight: 700; cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.picker button:hover { border-color: rgba(196, 49, 75, 0.5); }
.picker button[aria-selected="true"] { background: var(--gold); border-color: var(--gold); color: #fff1f3; }
.stat-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.stat-list li { display: grid; grid-template-columns: 120px minmax(0, 1fr) 40px; align-items: center; gap: 14px; font-size: 14px; }
.stat-list .lb { color: var(--mute); }
.stat-list .bar { height: 4px; border-radius: 4px; background: rgba(243, 235, 224, 0.08); overflow: hidden; }
.stat-list .bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--red), var(--gold), var(--gold-2)); border-radius: inherit; }
.stat-list .vl { font-weight: 800; font-variant-numeric: tabular-nums; text-align: right; }
.stats-note { margin: 22px 0 0; color: var(--dim); font-size: 13px; }

/* Planning */
.plan-stage { flex-direction: row; align-items: center; gap: clamp(24px, 5vw, 80px); }
.plan-copy { flex: 1 1 0; max-width: 620px; }
.plan-copy .title { font-size: clamp(2.4rem, 5.6vw, 6rem); }
.best { margin: 26px 0 0; font-family: var(--mono); font-size: 13px; letter-spacing: 0.06em; color: var(--gold-2); min-height: 1.5em; }
.best b { color: var(--ink); }
.phone-wrap { flex: 0 0 auto; perspective: 1400px; display: grid; place-items: center; }
.phone {
  --pw: min(300px, 34vh);
  position: relative;
  width: var(--pw); aspect-ratio: 9 / 19;
  transform-style: preserve-3d;
  transform: rotateY(-28deg) rotateX(10deg) rotateZ(-4deg);
  will-change: transform;
}
.phone-side, .phone-screen {
  position: absolute; inset: 0;
  border-radius: calc(var(--pw) * 0.15);
}
.phone-side {
  transform: translateZ(-14px);
  background: linear-gradient(135deg, #3a2b1d, #120c08 60%, #2b1f15);
  box-shadow: 0 40px 90px -20px rgba(0, 0, 0, 0.9);
}
.phone-screen {
  transform: translateZ(0);
  border: 8px solid #19120d;
  outline: 1.5px solid rgba(196, 49, 75, 0.55);
  background: radial-gradient(120% 70% at 50% 0%, #2a1610, #0d0907 70%);
  padding: 34px 14px 16px;
  display: flex; flex-direction: column;
  overflow: hidden;
}
.notch { position: absolute; top: 9px; left: 50%; width: 30%; height: 16px; transform: translateX(-50%); border-radius: 10px; background: #050403; }
.ph-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 10px; }
.ph-title { font-weight: 900; font-size: calc(var(--pw) * 0.075); letter-spacing: -0.02em; }
.ph-badge { font-family: var(--mono); font-size: 9px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold); border: 1px solid rgba(196, 49, 75, 0.4); padding: 2px 7px; border-radius: 999px; }
.ph-grid { flex: 1; display: grid; grid-template-columns: 1.1fr repeat(3, 1fr); grid-template-rows: auto repeat(7, 1fr); gap: 4px; min-height: 0; }
.ph-grid .h { font-family: var(--mono); font-size: 8.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--dim); text-align: center; align-self: end; padding-bottom: 2px; }
.ph-grid .d { font-weight: 800; font-size: calc(var(--pw) * 0.042); color: var(--mute); align-self: center; }
.ph-grid .c {
  position: relative;
  border-radius: 7px;
  display: grid; place-items: center;
  font-weight: 800; font-size: calc(var(--pw) * 0.042); font-variant-numeric: tabular-nums;
  background: rgba(243, 235, 224, 0.05);
  color: var(--dim);
  transition: background 0.4s, color 0.4s, box-shadow 0.4s;
}
.ph-grid .c.lit { color: var(--ink); }
.ph-grid .c.lit.l1 { background: rgba(140, 16, 38, 0.28); }
.ph-grid .c.lit.l2 { background: rgba(140, 16, 38, 0.45); }
.ph-grid .c.lit.l3 { background: rgba(226, 120, 50, 0.5); }
.ph-grid .c.lit.l4 { background: rgba(196, 49, 75, 0.62); color: #fff1f3; }
.ph-grid .c.lit.l5 { background: #8ee04a; color: #0f1a06; box-shadow: none; }
.ph-grid .c.best-cell { outline: 1.5px solid #ffe3e8; outline-offset: 1px; }
/* personne de dispo : le message passe devant la grille, estompée */
.ph-grid.is-empty { opacity: 0.25; filter: blur(1px); }
.ph-empty { position: absolute; left: 8%; right: 8%; top: 50%; transform: translateY(-50%); display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 18px 14px; border-radius: 14px; background: rgba(12, 6, 8, 0.82); border: 1px solid rgba(243, 235, 224, 0.12); text-align: center; }
.ph-empty[hidden] { display: none; }
.ph-empty b { font-size: calc(var(--pw) * 0.052); line-height: 1.2; color: var(--ink); }
.ph-empty span { font-size: calc(var(--pw) * 0.04); color: var(--mute); line-height: 1.35; }
.ph-empty small { margin-top: 6px; font-family: var(--mono); font-size: 8.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--dim); }
.ph-empty ul { display: flex; flex-wrap: wrap; justify-content: center; gap: 5px; margin: 0; padding: 0; list-style: none; }
.ph-empty li { padding: 3px 8px; border-radius: 999px; font-size: calc(var(--pw) * 0.036); font-weight: 700; color: var(--ink); background: color-mix(in srgb, var(--pc) 30%, transparent); border: 1px solid color-mix(in srgb, var(--pc) 60%, transparent); }
.ph-legend { display: flex; justify-content: space-between; margin-top: 10px; font-family: var(--mono); font-size: 8.5px; color: var(--mute); text-transform: uppercase; letter-spacing: 0.08em; }
.ph-legend span { display: flex; align-items: center; gap: 5px; }
.lv { width: 9px; height: 9px; border-radius: 3px; display: inline-block; }
.lv5 { background: #8ee04a; }
.lv3 { background: rgba(226, 120, 50, 0.7); }
.lv0 { background: rgba(243, 235, 224, 0.1); }

/* Final */
.final { text-align: center; min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.final .title { max-width: 14em; }
.final-logo {
  width: clamp(96px, 12vw, 150px); height: clamp(96px, 12vw, 150px);
  margin: clamp(48px, 8vh, 80px) 0 18px;
  color: var(--gold);
  filter: none;
}
.final-name { margin: 0; font-weight: 900; font-size: 22px; letter-spacing: 0.2em; text-transform: uppercase; }
.final .lede { margin-top: 10px; font-family: var(--serif); font-style: italic; font-size: 22px; color: var(--gold-2); }
.final-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-top: 36px; }
.foot { position: relative; z-index: 2; padding: 28px var(--gutter) 36px; text-align: center; font-family: var(--mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--dim); border-top: 1px solid var(--line); }

/* ------------------------------------------------------- responsive -- */
@media (max-width: 960px) {
  .team-wrap { grid-template-columns: 1fr; }
  .fiche { min-height: 0; }
  .stats-grid { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  body { font-size: 16px; }
  .nav-links { display: none; }
  .nav .btn-sm { margin-left: auto; }
  .brand span { font-size: 12px; }
  #intro { height: 220vh; }
  #chaos { height: 340vh; }
  #reponse { height: 220vh; }
  #planning { height: 240vh; }
  .title { font-size: clamp(2.3rem, 11vw, 4rem); }
  .intro-copy .title { font-size: clamp(2.4rem, 12vw, 4.2rem); }
  .intro-copy { margin-bottom: 40px; }
  .scroll-hint { display: none; }
  .counters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .counter { padding: 22px 12px 20px 0; }
  .counter + .counter { padding-left: 16px; }
  .counter:nth-child(3) { padding-left: 0; border-left: 0; }
  .counter:nth-child(n+3) { border-top: 1px solid var(--line); }
  .stat-list li { grid-template-columns: 92px minmax(0, 1fr) 32px; gap: 10px; }
  .plan-stage { flex-direction: column; justify-content: center; gap: 22px; padding-top: calc(var(--nav-h) + 16px); }
  .plan-copy .title { font-size: clamp(2rem, 9vw, 3rem); }
  .plan-copy .lede { display: none; }
  .best { margin-top: 12px; font-size: 12px; }
  .phone { --pw: min(230px, 26vh); }
  .fiche { padding: 22px; }
  .fiche h3 { font-size: 32px; }
  .node .ps { display: none; }
}

/* ---------------------------------------------- mouvement réduit -- */
.rm .scene { height: auto !important; }
.rm .stage { position: relative; height: auto; min-height: 100vh; min-height: 100svh; }
.rm .questions { gap: 28px; }
.rm .questions .q { grid-area: auto; }
.rm .phone { transform: rotateY(-14deg) rotateX(6deg); }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

/* ------------------------------------------------ v3 : intro plus dense -- */
#intro { height: 320vh; }
#chaos { height: 600vh; }
#reponse { height: 340vh; }
.intro-strip { display: flex; flex-wrap: wrap; gap: 14px 40px; margin: 34px 0 0; }
.intro-strip div { display: flex; flex-direction: column-reverse; }
.intro-strip dt { color: var(--mute); font-size: 15px; }
.intro-strip dd { margin: 0; font-size: clamp(26px, 2.6vw, 38px); font-weight: 900; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.intro-strip dd small { font-size: 0.5em; color: var(--gold); margin-left: 4px; letter-spacing: 0; }

/* Textos de l'équipe dans la scène du chaos */
.chat { position: absolute; inset: 0; pointer-events: none; perspective: 1200px; z-index: 0; }
.msg {
  position: absolute; width: min(390px, 30vw);
  display: grid; grid-template-columns: 40px 1fr; gap: 4px 12px; align-items: start;
  padding: 14px 16px; border-radius: 16px;
  background: rgba(24, 17, 13, 0.92); box-shadow: inset 0 0 0 1px rgba(243, 235, 224, 0.1), 0 24px 50px -20px rgba(0, 0, 0, 0.9);
  transform-style: preserve-3d; will-change: transform, opacity;
}
.js:not(.rm) .msg { opacity: 0; }
.msg .av { grid-row: 1 / 3; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-weight: 900; font-size: 14px; color: #160a0c; background: var(--mc); }
.msg .who { font-weight: 800; font-size: 15px; color: var(--mc); }
.msg .who time { margin-left: 8px; font-weight: 500; font-size: 12px; color: var(--dim); }
.msg .txt { font-size: 16px; line-height: 1.4; color: var(--ink); }
.questions { z-index: 1; }
.rm .chat { position: relative; inset: auto; display: grid; gap: 12px; margin-top: 40px; perspective: none; }
.rm .msg { position: relative; width: auto; max-width: 520px; left: auto !important; top: auto !important; }
@media (max-width: 760px) {
  #intro { height: 260vh; }
  #chaos { height: 520vh; }
  #reponse { height: 260vh; }
  .intro-strip { gap: 10px 22px; margin-top: 22px; }
  .msg { width: calc(100vw - 32px); left: 16px !important; top: auto !important; bottom: 40px; padding: 10px 12px; grid-template-columns: 30px 1fr; }
  .msg .av { width: 30px; height: 30px; font-size: 11px; }
  .msg .txt { font-size: 14px; }
}

/* Lien vers l'espace du joueur depuis sa fiche */
.fiche .f-open { display: inline-flex; margin-top: 22px; }

/* ------------------------------------------- v4 : texture « acier damassé » -- */
/* fond : braise basse et vignette, sans motif (les veines faisaient « zèbre ») */
.tex body::before {
  content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(90% 60% at 50% 115%, rgba(140, 16, 38, 0.16), transparent 70%),
    radial-gradient(140% 100% at 50% 40%, transparent 55%, rgba(0, 0, 0, 0.55) 100%);
}
/* (l'ancienne fumée floutée en CSS, coûteuse à chaque image, est remplacée par ambient.js) */

/* Titres : crème veiné, mot en italique : or veiné */
.tex .title .t-main, .tex .title:not(:has(.t-main)), .tex .f-giant span {
  background: var(--tex-ink) 0 0 / 380px 380px;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}
.tex .title em {
  background-image: linear-gradient(100deg, var(--gold-2) 10%, var(--gold) 55%, var(--ember) 110%), var(--tex-gold);
  background-size: 100% 100%, 300px 300px;
  background-blend-mode: overlay;
}
.tex .title .ghost, .tex .title .ghost em { background: none; -webkit-text-fill-color: currentColor; }

/* Bouton Son */
.snd {
  display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 14px 0 10px;
  border: 1px solid var(--line); border-radius: 999px; background: rgba(243, 235, 224, 0.03);
  color: var(--mute); font-size: 13px; font-weight: 700; cursor: pointer;
}
.snd svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.snd[aria-pressed="true"] { color: var(--gold-2); border-color: rgba(196, 49, 75, 0.45); }
.snd:hover { color: var(--ink); }
@media (max-width: 760px) { .snd span { display: none; } .snd { padding: 0 9px; margin-left: auto; } .nav .btn-sm { margin-left: 8px; } }

/* voile sombre derrière les questions du chaos : le texte reste lisible devant les cartes */
.questions::before {
  content: ""; position: absolute; left: 50%; top: 50%; width: min(1200px, 110vw); height: 420px; transform: translate(-50%, -50%);
  background: radial-gradient(closest-side, rgba(11, 6, 7, 0.82), rgba(11, 6, 7, 0.5) 55%, transparent);
  pointer-events: none; z-index: -1;
}

/* ------------------------------------------- v5 : carte de l'équipe -- */
/* chaque joueur à sa couleur, tracés fins et doux, plus grande */
@media (min-width: 961px) { .team-wrap { grid-template-columns: minmax(0, 1fr) 340px; } }
.constellation { width: min(100%, 780px); }
.links .ring { fill: none; stroke: rgba(243, 235, 224, 0.06); stroke-width: 1px; vector-effect: non-scaling-stroke; }
.links .ring-out { stroke-dasharray: 2 6; stroke: rgba(243, 235, 224, 0.09); }
.links .web { fill: url(#webFill); stroke: rgba(243, 235, 224, 0.1); stroke-width: 1px; vector-effect: non-scaling-stroke; stroke-linejoin: round; }
.links .ln { fill: none; stroke-width: 1.6px; vector-effect: non-scaling-stroke; stroke-linecap: round; }
.links .pulse { fill: none; stroke: var(--pc); stroke-width: 2px; stroke-dasharray: 2 22; opacity: 0.4; animation-duration: 2.4s; }
.links .pulse.on { stroke: var(--pc); stroke-width: 2.6px; opacity: 0.95; animation-duration: 1.1s; }
.links .web-avg { fill: rgba(240, 140, 155, 0.07); stroke: rgba(240, 140, 155, 0.4); stroke-width: 1.4px; vector-effect: non-scaling-stroke; stroke-linejoin: round; }
.links .web-val { font-family: var(--mono); font-size: 2.6px; font-weight: 700; text-anchor: middle; }
.core { width: 17%; background: radial-gradient(circle, rgba(255, 227, 232, 0.95) 0%, rgba(240, 140, 155, 0.75) 26%, rgba(196, 49, 75, 0.55) 48%, rgba(140, 16, 38, 0.18) 66%, transparent 72%); box-shadow: none; display: grid; place-items: center; }
.core i { border-color: rgba(240, 140, 155, 0.18); }
.core-logo { width: 34%; height: 34%; color: #3a0a14; opacity: 0.85; }
.node { width: 24%; gap: 6px; }
.av-wrap { position: relative; display: grid; place-items: center; width: clamp(66px, 9.6vw, 104px); aspect-ratio: 1; }
.av-ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); overflow: visible; }
.av-ring circle { fill: none; stroke-width: 1.6; }
.av-ring .bg { stroke: rgba(243, 235, 224, 0.08); }
.av-ring .fg { stroke: var(--rc); stroke-linecap: round; stroke-dasharray: 100; transition: stroke-width 0.3s; }
.node .av {
  width: 78%; border: 1px solid color-mix(in srgb, var(--rc) 55%, transparent);
  background: radial-gradient(circle at 35% 28%, color-mix(in srgb, var(--rc) 26%, #1e1215), #120a0c 72%);
  box-shadow: 0 10px 26px -12px rgba(0, 0, 0, 0.9); color: var(--rc);
}
.node:hover .av, .node:focus-visible .av, .node.on .av { transform: scale(1.06); box-shadow: 0 0 0 3px color-mix(in srgb, var(--rc) 35%, transparent), 0 12px 30px -12px rgba(0, 0, 0, 0.9); }
.node.on .av-ring .fg { stroke-width: 2.6; }
.node .nm { color: var(--ink); }
.node.on .nm { color: var(--rc); }
.node .ps { margin-top: -4px; }
.node .hm { font-size: 12px; color: var(--mute); white-space: nowrap; }
.const-legend { position: absolute; left: 0; right: 0; bottom: -46px; margin: 0; display: flex; justify-content: center; flex-wrap: wrap; gap: 6px 22px; font-size: 12px; color: var(--dim); }
.const-legend i { display: inline-block; vertical-align: middle; margin-right: 8px; }
.lg-ring { width: 12px; height: 12px; border-radius: 50%; border: 1.6px solid var(--gold-2); }
.lg-web { width: 14px; height: 10px; clip-path: polygon(50% 0, 100% 40%, 80% 100%, 20% 100%, 0 40%); background: rgba(240, 140, 155, 0.45); }
@media (max-width: 760px) { .node .hm { display: none; } .const-legend { bottom: -56px; } .links .web-val { font-size: 3.4px; } }
.constellation { margin-bottom: 56px; } @media (max-width: 760px) { .constellation { margin-bottom: 76px; } }

/* ------------------------------------ v6 : chemins, synergies, conseils -- */
#equipe { max-width: 1600px; }
.tips { grid-area: tips; } .constellation { grid-area: map; } .fiche { grid-area: fiche; } .team-legend { grid-area: legend; }
@media (min-width: 1200px) {
  .team-wrap { grid-template-columns: 300px minmax(0, 1fr) 320px; grid-template-areas: "tips map fiche" "legend legend legend"; align-items: start; }
  .fiche { align-self: center; }
}
@media (min-width: 961px) and (max-width: 1199px) {
  .team-wrap { grid-template-columns: minmax(0, 1fr) 320px; grid-template-areas: "map fiche" "tips tips" "legend legend"; }
}
@media (max-width: 960px) { .team-wrap { grid-template-areas: "map" "fiche" "tips" "legend"; } }
.constellation { width: min(100%, 760px); margin: 70px auto 40px; }

/* joueurs : étiquettes à l'extérieur de la carte (celle du haut passe au-dessus de l'avatar) */
.node .lbl { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.node.lbl-top { flex-direction: column-reverse; }
.av-ring .seg-bg { fill: none; stroke: rgba(243, 235, 224, 0.09); stroke-width: 2.4; }
.av-ring .seg-fg { fill: none; stroke: var(--rc); stroke-width: 2.4; transition: stroke-width 0.3s; }
.node.on .av-ring .seg-fg { stroke-width: 3.2; }
.av-avg {
  position: absolute; right: -2px; bottom: 4px; z-index: 1;
  padding: 2px 7px; border-radius: 999px; background: var(--rc); color: #160a0c;
  font-size: 11px; font-weight: 800; font-variant-numeric: tabular-nums; box-shadow: 0 0 0 3px var(--bg);
}

/* chemins vers le cœur */
.links .trail { fill: none; stroke-width: 1px; stroke-dasharray: 1 5; stroke-linecap: round; opacity: 0.3; vector-effect: non-scaling-stroke; }
.links .ln { stroke-width: 2px; transition: opacity 0.3s, stroke-width 0.3s; }
.has-on .links .ln:not(.on) { opacity: 0.3; }
.links .ln.on { stroke-width: 3px; }
.links .wp circle { fill: #140a0c; stroke: var(--pc); stroke-width: 1.4px; vector-effect: non-scaling-stroke; transition: fill 0.3s; }
.links .wp text { font-family: var(--mono); font-size: 2px; font-weight: 700; fill: var(--pc); paint-order: stroke; stroke: #0b0607; stroke-width: 0.6; opacity: 0; transition: opacity 0.3s; }
.links .wp.on circle { fill: var(--pc); }
.links .wp.on text { opacity: 1; }
/* synergies */
.links .syn path { fill: none; opacity: 0.4; stroke-linecap: round; vector-effect: non-scaling-stroke; transition: opacity 0.3s; }
.links .syn text { font-family: var(--mono); font-size: 1.9px; font-weight: 700; fill: #f3ebe0; text-anchor: middle; paint-order: stroke; stroke: #0b0607; stroke-width: 0.6; opacity: 0; transition: opacity 0.3s; }
.links .syn.on path { opacity: 0.95; }
.links .syn.on text { opacity: 1; }

/* conseils */
.tips { display: flex; flex-direction: column; max-height: 820px; padding: 18px 14px 14px 18px; border-radius: 20px; background: rgba(20, 10, 12, 0.72); box-shadow: inset 0 0 0 1px var(--line); }
.tips-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding-right: 4px; }
.tips-head h3 { margin: 0; font-size: 22px; font-weight: 900; letter-spacing: -0.02em; }
.tips-count { font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; color: var(--dim); }
.tips-filters { display: flex; flex-wrap: wrap; gap: 5px; margin: 12px 0 4px; }
.tips-filters button { --pc: var(--gold); height: 28px; padding: 0 10px; border-radius: 999px; border: 0; cursor: pointer; font-size: 12px; font-weight: 700; color: var(--mute); background: rgba(243, 235, 224, 0.04); box-shadow: inset 0 0 0 1px var(--line); }
.tips-filters button[aria-selected="true"] { color: #fff; background: color-mix(in srgb, var(--pc) 24%, transparent); box-shadow: inset 0 0 0 1.5px var(--pc); }
.tips-list { list-style: none; margin: 10px 0 0; padding: 0 6px 0 0; overflow-y: auto; flex: 1; min-height: 0; display: grid; gap: 8px; align-content: start; scrollbar-width: thin; scrollbar-color: rgba(196, 49, 75, 0.5) transparent; }
.tip { position: relative; padding: 12px 12px 12px 16px; border-radius: 12px; background: rgba(243, 235, 224, 0.035); }
.tip::before { content: ""; position: absolute; left: 0; top: 10px; bottom: 10px; width: 3px; border-radius: 3px; background: var(--bar); }
.tip-top { display: flex; justify-content: space-between; gap: 8px; }
.tip-cat { font-family: var(--mono); font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--dim); }
.tip-who { font-size: 11px; font-weight: 700; color: var(--mute); }
.tip b { display: block; margin-top: 4px; font-size: 14px; line-height: 1.3; }
.tip p { margin: 4px 0 0; font-size: 13.5px; line-height: 1.45; color: var(--mute); }
@media (max-width: 1199px) { .tips { max-height: 560px; } }

/* légende, plus grande */
.team-legend { margin: 10px 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px 32px; padding-top: 26px; border-top: 1px solid var(--line); }
.team-legend dt { display: flex; align-items: center; gap: 12px; font-weight: 800; font-size: 17px; }
.team-legend dd { margin: 6px 0 0; font-size: 14.5px; line-height: 1.5; color: var(--mute); }
.team-legend i { flex: none; display: inline-block; }
.team-legend .lg-ring { width: 20px; height: 20px; border-radius: 50%; border: 2.5px dashed var(--gold-2); }
.team-legend .lg-path { width: 26px; height: 12px; border-top: 3px solid var(--gold-2); border-radius: 50% 50% 0 0; }
.team-legend .lg-trail { width: 26px; height: 12px; border-top: 2px dotted var(--gold-2); border-radius: 50% 50% 0 0; opacity: 0.7; }
.team-legend .lg-syn { width: 26px; height: 5px; border-radius: 3px; background: linear-gradient(90deg, #ff5fa2, #2f86ff); }
.team-legend .lg-web { width: 20px; height: 16px; clip-path: polygon(50% 0, 100% 40%, 80% 100%, 20% 100%, 0 40%); background: rgba(240, 140, 155, 0.5); }
.team-legend .lg-core { width: 18px; height: 18px; border-radius: 50%; background: radial-gradient(circle, #ffe3e8, #c4314b 60%, transparent 72%); }

/* fiche : chemin et synergie */
.fiche .f-path { list-style: none; margin: 0; padding: 2px 0 2px 14px; border-left: 2px dashed var(--rc); display: grid; gap: 4px; }
.fiche .f-path li { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; }
.fiche .f-path li b { color: var(--rc); font-variant-numeric: tabular-nums; }
.fiche .f-path li.end span { color: var(--gold-2); font-weight: 700; }
.fiche .f-syn { margin: 0; font-size: 15px; font-weight: 700; }
.fiche .f-syn b { color: var(--rc); margin-left: 6px; }
@media (max-width: 760px) { .constellation { margin-top: 60px; } .links .wp text { font-size: 2.8px; } .links .syn text { font-size: 2.6px; } }

/* ---------------------------------------- v7 : fiche plus grande, décor -- */
@media (min-width: 1500px) {
  .team-wrap { grid-template-columns: 300px minmax(0, 1fr) 480px; }
}
@media (min-width: 1200px) and (max-width: 1499px) {
  .team-wrap { grid-template-columns: 280px minmax(0, 1fr) 400px; gap: 32px; }
}
@media (min-width: 961px) and (max-width: 1199px) {
  .team-wrap { grid-template-columns: minmax(0, 1fr) 400px; }
}
.fiche { container-type: inline-size; padding: 30px; }
.fiche .f-cols { display: grid; grid-template-columns: 1fr; gap: 0 26px; }
@container (min-width: 400px) { .fiche .f-cols { grid-template-columns: 1fr 1fr; } }
.fiche .f-label small { text-transform: none; letter-spacing: 0; font-family: var(--sans); font-size: 11px; color: var(--dim); }
.fiche .f-stats { list-style: none; margin: 0; padding: 0; display: grid; gap: 7px; }
.fiche .f-stats li { display: grid; grid-template-columns: 72px 1fr 28px; align-items: center; gap: 10px; font-size: 13px; }
.fiche .f-stats span { color: var(--mute); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fiche .f-bar { position: relative; display: block; height: 7px; border-radius: 4px; background: rgba(243, 235, 224, 0.08); }
.fiche .f-bar > i { position: absolute; inset: 0 auto 0 0; border-radius: inherit; background: var(--rc); }
.fiche .f-bar > u { position: absolute; top: -3px; bottom: -3px; width: 2px; margin-left: -1px; border-radius: 1px; background: var(--ink); opacity: 0.75; }
.fiche .f-stats b { text-align: right; font-variant-numeric: tabular-nums; font-size: 13px; }
.fiche .f-stats b.up { color: var(--rc); }
.fiche .f-stats b.down { color: var(--mute); }
.fiche .f-heroes { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.fiche .f-heroes li { display: flex; align-items: center; gap: 8px; padding: 4px 12px 4px 4px; border-radius: 999px; background: rgba(243, 235, 224, 0.05); box-shadow: inset 0 0 0 1px var(--line); font-size: 13.5px; font-weight: 700; }
.fiche .f-heroes li.main { box-shadow: inset 0 0 0 1.5px var(--rc); }
.fiche .f-heroes img { width: 30px; height: 30px; border-radius: 50%; object-fit: cover; background: rgba(243, 235, 224, 0.06); }
.fiche .f-heroes small { margin-left: 5px; font-weight: 500; color: var(--rc); font-size: 11px; }
.fiche .f-meta { margin: 10px 0 0; font-size: 13px; line-height: 1.45; color: var(--mute); }
.fiche .f-meta b { color: var(--ink); }
.fiche .f-meta .t { display: inline-block; min-width: 18px; padding: 0 5px; border-radius: 5px; text-align: center; color: #0b0607; }
.fiche .t-S { background: #3fe07a; } .fiche .t-A { background: #b6e33f; } .fiche .t-B { background: #f4d63a; } .fiche .t-C { background: #ff9a3c; } .fiche .t-D, .fiche .t-F { background: #ef3b3b; color: #fff; }
.fiche .f-goals li { font-size: 14.5px !important; }
.fiche .f-team { margin: 0; padding-left: 16px; display: grid; gap: 4px; font-size: 13.5px; color: var(--ink); }
.fiche .f-team li::marker { color: var(--rc); }
.fiche .f-syns { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.fiche .f-syns li { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; padding: 9px 12px; border-radius: 12px; background: rgba(243, 235, 224, 0.04); box-shadow: inset 3px 0 0 var(--qc); }
.fiche .f-syns b { font-size: 14px; }
.fiche .f-syns em { font-style: normal; font-weight: 800; color: var(--rc); font-size: 13px; }
.fiche .f-syns span { grid-column: 1 / -1; font-size: 12.5px; color: var(--mute); line-height: 1.4; }
.fiche .f-week { margin: 0; display: grid; gap: 2px; padding: 10px 12px; border-radius: 12px; font-size: 13px; }
.fiche .f-week.ok { background: rgba(63, 224, 122, 0.1); box-shadow: inset 0 0 0 1px rgba(63, 224, 122, 0.4); }
.fiche .f-week.todo { background: rgba(229, 88, 59, 0.1); box-shadow: inset 0 0 0 1px rgba(229, 88, 59, 0.45); }
.fiche .f-week span { color: var(--mute); }

/* décor derrière « L'équipe » : anneaux, grille fine et filigrane */
#equipe { position: relative; isolation: isolate; overflow-x: clip; }
#equipe::before {
  content: ""; position: absolute; z-index: -1; inset: -40px -6vw; pointer-events: none;
  background:
    radial-gradient(closest-side at 50% 52%, rgba(196, 49, 75, 0.16), transparent 72%),
    repeating-radial-gradient(circle at 50% 52%, transparent 0 58px, rgba(243, 235, 224, 0.045) 58px 59px),
    linear-gradient(rgba(243, 235, 224, 0.03) 1px, transparent 1px) 0 0 / 46px 46px,
    linear-gradient(90deg, rgba(243, 235, 224, 0.03) 1px, transparent 1px) 0 0 / 46px 46px;
  -webkit-mask-image: radial-gradient(ellipse 70% 65% at 50% 52%, #000 30%, transparent 78%);
  mask-image: radial-gradient(ellipse 70% 65% at 50% 52%, #000 30%, transparent 78%);
}
#equipe::after {
  content: "ESPADA"; position: absolute; z-index: -1; left: 50%; top: 54%; transform: translate(-50%, -50%);
  font-weight: 900; font-size: clamp(120px, 19vw, 340px); letter-spacing: -0.04em; line-height: 1; white-space: nowrap; pointer-events: none;
  color: transparent; -webkit-text-stroke: 1.5px rgba(196, 49, 75, 0.12);
}
/* fiche : stats en deux colonnes de barres, synergies côte à côte, textes plus compacts */
.fiche .f-stats { grid-template-columns: 1fr; column-gap: 22px; }
@container (min-width: 400px) {
  .fiche .f-stats { grid-template-columns: 1fr 1fr; }
  .fiche .f-syns { grid-template-columns: 1fr 1fr; }
}
.fiche .f-stats li { grid-template-columns: 64px 1fr 24px; }
.fiche .f-goals li { font-size: 13.5px !important; line-height: 1.35 !important; }
.fiche .f-label { margin-top: 18px; }
.fiche h3 { font-size: 38px; }
.fiche .f-plus { margin-left: 5px; padding: 0 4px; border-radius: 5px; font-style: normal; font-weight: 800; font-size: 10px; color: #0b0607; background: var(--rc); vertical-align: 1px; }
.fiche .f-stats li { grid-template-columns: 82px 1fr 24px; }
.fiche .f-avis { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
@container (min-width: 400px) { .fiche .f-avis { grid-template-columns: 1fr 1fr; } }
.fiche .f-avis li { position: relative; padding: 10px 12px 10px 28px; border-radius: 10px; font-size: 13px; line-height: 1.4; color: var(--ink); background: color-mix(in srgb, var(--rc) 9%, rgba(243, 235, 224, 0.03)); }
.fiche .f-avis li::before { content: "“"; position: absolute; left: 10px; top: 4px; font-family: var(--serif); font-size: 26px; color: var(--rc); line-height: 1; }

/* L'équipe en un mot */
.mots { list-style: none; margin: 34px 0 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 18px 34px; }
.mot { display: grid; justify-items: center; gap: 6px; padding: 18px 26px; border-radius: 22px; background: radial-gradient(120% 120% at 50% 0%, color-mix(in srgb, var(--pc) 18%, transparent), transparent 70%); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--pc) 35%, transparent); }
.mot:nth-child(odd) { transform: rotate(-2deg); } .mot:nth-child(even) { transform: rotate(2deg) translateY(10px); }
.mot b { font-family: var(--serif); font-style: italic; font-weight: 400; font-size: calc(clamp(40px, 6vw, 84px) * (1 + (var(--n) - 1) * 0.35)); line-height: 1; color: var(--pc); letter-spacing: -0.01em; }
.mot span { font-family: var(--mono); font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--mute); }
.rm .mot { transform: none; }
.fiche .f-avis em { margin-left: 6px; padding: 0 5px; border-radius: 5px; font-style: normal; font-weight: 800; font-size: 11px; color: #0b0607; background: var(--rc); }
.fiche .f-why { list-style: none; grid-column: 1 / -1; margin: 6px 0 0; padding: 0; display: grid; gap: 3px; font-size: 12px; line-height: 1.4; }
.fiche .f-why li { padding-left: 16px; position: relative; color: var(--mute); }
.fiche .f-why.up li::before { content: "+"; position: absolute; left: 2px; font-weight: 900; color: #3fe07a; }
.fiche .f-why.down li::before { content: "−"; position: absolute; left: 2px; font-weight: 900; color: #ef3b3b; }
.fiche .f-weak { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; padding: 10px 12px; border-radius: 12px; background: rgba(239, 59, 59, 0.06); box-shadow: inset 3px 0 0 var(--qc), inset 0 0 0 1px rgba(239, 59, 59, 0.25); }
.fiche .f-weak b { font-size: 14px; }
.fiche .f-weak em { font-style: normal; font-weight: 800; color: #ef8a6a; font-size: 13px; }
.fiche .f-weak > span { grid-column: 1 / -1; font-size: 12.5px; color: var(--mute); }
.fiche .f-motiv { margin: 20px 0 0; padding: 14px 16px; border-radius: 14px; font-family: var(--serif); font-style: italic; font-size: 17px; line-height: 1.45; color: var(--ink); background: color-mix(in srgb, var(--rc) 12%, transparent); box-shadow: inset 3px 0 0 var(--rc); }

/* objectifs perso : l'onde du « boom » à l'arrivée de chaque carte */
.ob-card { position: relative; }
.ob-card.boom::after {
  content: ""; position: absolute; inset: -2px; border-radius: inherit; pointer-events: none;
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--pc) 85%, transparent), 0 0 40px 6px color-mix(in srgb, var(--pc) 60%, transparent);
  animation: ob-boom 0.85s cubic-bezier(.2, .8, .2, 1) forwards;
}
@keyframes ob-boom {
  0% { opacity: 1; box-shadow: 0 0 0 0 color-mix(in srgb, var(--pc) 85%, transparent), 0 0 50px 10px color-mix(in srgb, var(--pc) 70%, transparent); }
  100% { opacity: 0; box-shadow: 0 0 0 26px color-mix(in srgb, var(--pc) 0%, transparent), 0 0 0 0 transparent; }
}
.rm .ob-card.boom::after { animation: none; }

/* L'équipe en un mot : apparition douce (flou → net), lettres qui se posent, reflet de lumière */
.mot b i { font-style: inherit; display: inline-block; }
.mots.armed .mot { opacity: 0; transform: translateY(28px) scale(0.96); filter: blur(12px); }
.mots.armed .mot b i { opacity: 0; transform: translateY(0.45em); filter: blur(6px); }
.mots.armed .mot span { opacity: 0; transform: translateY(6px); }
.mots .mot.in { opacity: 1; filter: blur(0); transition: opacity 1.1s ease, transform 1.4s cubic-bezier(.16, 1, .3, 1), filter 1.1s ease; }
.mots .mot.in:nth-child(odd) { transform: rotate(-2deg); }
.mots .mot.in:nth-child(even) { transform: rotate(2deg) translateY(10px); }
.mots .mot.in b i { opacity: 1; transform: none; filter: blur(0); transition: opacity 0.7s ease, transform 0.9s cubic-bezier(.16, 1, .3, 1), filter 0.7s ease; transition-delay: calc(0.18s + var(--k) * 45ms); }
.mots .mot.in span { opacity: 1; transform: none; transition: opacity 0.8s ease 0.75s, transform 0.8s ease 0.75s; }
.mot { position: relative; overflow: hidden; }
.mot::after { content: ""; position: absolute; inset: -20% auto -20% -60%; width: 45%; pointer-events: none; background: linear-gradient(100deg, transparent, color-mix(in srgb, var(--pc) 35%, rgba(255, 255, 255, 0.35)), transparent); transform: skewX(-18deg) translateX(0); opacity: 0; }
.mots .mot.in::after { animation: mot-shine 1.6s cubic-bezier(.3, .7, .3, 1) 0.35s; }
@keyframes mot-shine { 0% { opacity: 0; transform: skewX(-18deg) translateX(0); } 20% { opacity: 1; } 100% { opacity: 0; transform: skewX(-18deg) translateX(420%); } }
/* une fois toutes posées, les cartes respirent doucement */
.mots.shown .mot { animation: mot-float 6s ease-in-out infinite; animation-delay: calc(var(--i) * -1.1s); }
@keyframes mot-float { 0%, 100% { translate: 0 0; } 50% { translate: 0 -6px; } }
.rm .mots .mot { animation: none !important; }

/* ------------------------------------------------- l'air du site -- */
.ambient { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; display: block; }

/* numéro de section, grand et gravé, à droite du titre : la tête de section n'est plus un bloc vide */
.block-head { position: relative; }
.block-head[data-n]::after {
  content: attr(data-n);
  position: absolute; right: calc(-1 * min(420px, 40vw)); top: -0.18em;
  font: 900 clamp(120px, 17vw, 260px)/0.8 var(--sans); letter-spacing: -0.04em;
  color: transparent; -webkit-text-stroke: 1px rgba(243, 235, 224, 0.15);
  pointer-events: none; user-select: none;
}
.block-head[data-n]::before {
  content: "— " attr(data-n) " / 05";
  position: absolute; right: calc(-1 * min(420px, 40vw)); bottom: -6px;
  font: 500 11px var(--mono); letter-spacing: 0.24em; color: var(--dim);
}
@media (max-width: 900px) { .block-head[data-n]::after, .block-head[data-n]::before { display: none; } }

/* la fiche avant de choisir un joueur : l'équipe en bref */
.f-brief { display: grid; gap: 16px; }
.f-team-k { margin: 0; font: 500 11px var(--mono); letter-spacing: 0.24em; text-transform: uppercase; color: var(--gold-2); }
.f-brief h3 { margin: 0; font: 800 clamp(22px, 2.2vw, 28px)/1.1 var(--sans); letter-spacing: -0.02em; }
.f-brief h3 em { display: block; font: italic 400 1.05em var(--serif); color: var(--mute); letter-spacing: 0; }
.f-team-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.f-chip { display: grid; gap: 1px; padding: 8px 12px; border: 0; border-radius: 10px; background: color-mix(in srgb, var(--pc) 10%, rgba(255, 255, 255, 0.02)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--pc) 35%, transparent); cursor: pointer; text-align: left; transition: background 0.2s, transform 0.2s; }
.f-chip b { font-size: 14px; color: var(--pc); }
.f-chip small { font: 500 10px var(--mono); letter-spacing: 0.08em; color: var(--mute); text-transform: uppercase; }
.f-chip:hover, .f-chip:focus-visible { background: color-mix(in srgb, var(--pc) 20%, transparent); transform: translateY(-2px); }
.f-chip:focus-visible { outline: 2px solid var(--pc); outline-offset: 2px; }
.f-team-bars { list-style: none; margin: 4px 0 0; padding: 0; display: grid; gap: 9px; }
.f-team-bars li { display: grid; grid-template-columns: 92px 1fr 28px; align-items: center; gap: 12px; font-size: 13px; color: var(--mute); }
.f-team-bars i { height: 4px; border-radius: 4px; background: rgba(243, 235, 224, 0.08); position: relative; overflow: hidden; }
.f-team-bars i::after { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--v); background: rgba(243, 235, 224, 0.55); border-radius: inherit; }
.f-team-bars b { font: 600 12px var(--mono); color: var(--ink); text-align: right; }
.f-team-bars li.hi { color: var(--ink); } .f-team-bars li.hi i::after { background: var(--gold-2); }
.f-team-bars li.lo i::after { background: rgba(243, 235, 224, 0.28); }
.f-team-sum { margin: 2px 0 0; display: flex; flex-wrap: wrap; gap: 6px 10px; font-size: 14px; color: var(--mute); }
.f-team-sum b { color: var(--ink); }
.f-team-hint { margin: 0; font: 500 11px var(--mono); color: var(--dim); }

/* onglets de la fiche joueur */
.f-tabs { display: flex; gap: 2px; margin: 18px 0 4px; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.f-tabs::-webkit-scrollbar { display: none; }
.f-tab { flex: 0 0 auto; padding: 9px 12px 10px; border: 0; background: none; cursor: pointer; font: 600 12px var(--mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--dim); position: relative; transition: color 0.2s; }
.f-tab::after { content: ""; position: absolute; left: 10px; right: 10px; bottom: -1px; height: 2px; background: var(--rc, var(--gold)); transform: scaleX(0); transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1); }
.f-tab:hover { color: var(--mute); }
.f-tab[aria-selected="true"] { color: var(--ink); }
.f-tab[aria-selected="true"]::after { transform: scaleX(1); }
.f-tab:focus-visible { outline: 2px solid var(--rc, var(--gold)); outline-offset: -2px; border-radius: 4px; }
.f-panel[hidden] { display: none; }
.f-panel > .f-label:first-child { margin-top: 12px; }

/* l'accueil dessine son grain dans ambient.js ; ailleurs le grain reste, mais fixe (bien moins coûteux) */
.amb-grain .grain { display: none; }
.grain { animation: none; }

/* performances de la carte du cœur : chaque partie animée a sa propre couche, et les traits
   ne coulent que pour le joueur choisi (redessiner tout le SVG à chaque image coûtait cher) */
.constellation { contain: layout paint; }
.links { will-change: transform; }
.core, .core i { will-change: transform, opacity; }
.links .pulse { animation: none; }
.links .pulse.on { animation: flow 0.7s linear infinite; }
.rm .links .pulse.on { animation: none; }
