@font-face { font-family: "Geist"; src: url("/fonts/geist.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Geist Mono"; src: url("/fonts/geist-mono.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }

/* Palette « Granit et braise » : granit, ardoise, pierre, craie, et l'orange du tracé comme accent */
:root {
  --granit: #1b2128;
  --ardoise: #3d4752;
  --pierre: #a8a297;
  --craie: #f4f2ee;
  --braise: #e8571f;
  --braise-texte: #b9441a;      /* braise assombrie : liens et petits textes lisibles sur fond clair */
  --sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --gutter: clamp(20px, 5vw, 80px);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}
[data-theme="light"]  { --bg: var(--craie);   --fg: var(--granit); --soft: #3d4752; --muted: #5b6570; --line: rgba(27, 33, 40, 0.14); --plate: var(--pierre); --accent: var(--braise); --btn-bg: var(--braise); --btn-fg: var(--granit); }
[data-theme="forest"] { --bg: var(--granit);  --fg: var(--craie);  --soft: #d9dbdc; --muted: #a7adb3; --line: rgba(244, 242, 238, 0.18); --plate: var(--craie); --accent: var(--braise); --btn-bg: var(--braise); --btn-fg: var(--granit); }
[data-theme="sand"]   { --bg: var(--pierre);  --fg: var(--granit); --soft: #262c33; --muted: #3a4048; --line: rgba(27, 33, 40, 0.22); --plate: var(--craie); --accent: var(--granit); --btn-bg: var(--granit); --btn-fg: var(--craie); }
[data-theme="green"]  { --bg: var(--ardoise); --fg: var(--craie);  --soft: #e1e3e5; --muted: #c3c8cd; --line: rgba(244, 242, 238, 0.22); --plate: var(--craie); --accent: var(--braise); --btn-bg: var(--braise); --btn-fg: var(--granit); }

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scrollbar-color: var(--braise) var(--craie); scroll-padding-top: 64px; }
body { margin: 0; background: var(--craie); color: var(--granit); font-family: var(--sans); font-size: 17px; line-height: 1.5; -webkit-font-smoothing: antialiased; overflow-x: hidden; caret-color: var(--braise); }
::selection { background: var(--braise); color: var(--granit); }
h1, h2, h3, p, ol, ul, dl, dd, dt, figure { margin: 0; padding: 0; }
ol, ul { list-style: none; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; color: inherit; }
img, canvas { display: block; max-width: 100%; }
:focus-visible { outline: 2px solid var(--accent, var(--braise)); outline-offset: 3px; border-radius: 4px; }
.skip { position: absolute; left: -9999px; top: 8px; z-index: 10; background: var(--granit); color: var(--craie); padding: 10px 16px; border-radius: 8px; }
.skip:focus { left: 8px; }

/* ---------------------------------------------------------------- navbar */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 5; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 24px; padding: 14px var(--gutter); color: var(--granit); border-bottom: 1px solid transparent; transition: background-color .4s var(--ease), border-color .4s var(--ease), padding .4s var(--ease); --btn-bg: var(--braise); --btn-fg: var(--granit); }
.nav.scrolled { background: var(--craie); border-color: rgba(27, 33, 40, 0.14); padding-top: 9px; padding-bottom: 9px; }
.brand { font-weight: 700; letter-spacing: 0.2em; font-size: 14px; justify-self: start; }
.nav nav { display: flex; gap: clamp(18px, 2.4vw, 34px); font-size: 15px; }
.nav nav a, .footer nav a { position: relative; padding: 6px 0; }
.nav nav a::after, .footer nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--braise); transform: scaleX(0); transform-origin: left; transition: transform .4s var(--ease); }
.footer nav a::after { background: var(--pierre); }
.nav nav a:hover::after, .nav nav a.current::after, .footer nav a:hover::after { transform: scaleX(1); }
.nav .btn { justify-self: end; }

.btn { display: inline-flex; align-items: center; gap: 10px; padding: 15px 24px; border-radius: 999px; background: var(--btn-bg); color: var(--btn-fg); font-weight: 500; font-size: 16px; border: 1px solid var(--btn-bg); transition: transform .3s var(--ease), filter .3s var(--ease), border-color .3s var(--ease), background-color .3s var(--ease); }
.btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; transition: transform .3s var(--ease); }
.btn:hover { filter: brightness(1.12); }
.btn:hover svg { transform: translateX(4px); }
.btn:active { transform: scale(0.98); }
.btn--ghost { background: transparent; color: var(--fg); border-color: var(--line); }
.btn--ghost:hover { filter: none; border-color: var(--fg); }
.btn--small { padding: 10px 18px; font-size: 14px; }

/* --------------------------------------------------------------- sections */
.section { background: var(--bg); color: var(--fg); min-height: 100vh; min-height: 100svh; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); align-items: center; gap: clamp(28px, 5vw, 88px); padding: 112px var(--gutter) 88px; position: relative; }
.section > .plate:first-child { order: 0; }
#concept, #etapes .sticky, #personnalisation { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); }
.section--tall { display: block; min-height: 380vh; padding: 0; }
.section--tall .sticky { position: sticky; top: 0; height: 100vh; height: 100svh; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); align-items: center; gap: clamp(28px, 5vw, 88px); padding: 96px var(--gutter) 48px; }

.copy { max-width: 520px; }
h1 { font-size: clamp(44px, 5.6vw, 88px); line-height: 0.97; letter-spacing: -0.04em; font-weight: 600; }
h2 { font-size: clamp(32px, 3.7vw, 54px); line-height: 1.03; letter-spacing: -0.035em; font-weight: 600; text-wrap: balance; }
.lead { margin-top: 26px; font-size: clamp(17px, 1.3vw, 19px); color: var(--soft); max-width: 42ch; text-wrap: pretty; }
.note { margin-top: 18px; font-size: 14px; color: var(--muted); }
.actions { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 12px; }

/* le visuel : une « planche » de couleur sur laquelle le produit est posé */
.plate { position: relative; background: var(--plate); border-radius: 28px; aspect-ratio: 5 / 4; overflow: hidden; width: 100%; max-height: 78svh; justify-self: center; }
.plate { --zoom: 1.3; }
.plate > img, .plate > canvas { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; transform: translate3d(0, var(--py, 0px), 0) scale(calc(var(--zoom, 1) * var(--pop, 1))); will-change: transform; }
.plate--bleed { --zoom: 1.08; }
.plate--bleed > img { object-fit: cover; }
.plate--sequence { --zoom: 1.12; }
.plate--viewer { --zoom: 1; }
.plate--square { aspect-ratio: 1; max-height: 76svh; width: auto; height: min(76svh, 100%); max-width: 100%; }
.plate--stack > img { opacity: 0; transition: opacity .7s var(--ease), transform .9s var(--ease); --pop: 0.96; }
.plate--stack > img.on { opacity: 1; --pop: 1; }
.plate--hero { --zoom: 1.38; }
.plate--hero > img { transform: perspective(1400px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) scale(var(--zoom)); transition: transform .9s var(--ease); }
.plate--viewer > canvas { cursor: grab; touch-action: pan-y; }
.plate--viewer > canvas:active { cursor: grabbing; }
.plate figcaption { position: absolute; left: 20px; bottom: 16px; font-size: 13px; color: #4d545b; }

/* entrée du premier écran : le seul moment animé à l'arrivée */
.hero .copy > *, .hero .plate { opacity: 0; transform: translateY(20px); filter: blur(8px); }
.hero.in .copy > *, .hero.in .plate { opacity: 1; transform: none; filter: none; transition: opacity 1.1s var(--ease), transform 1.1s var(--ease), filter 1.1s var(--ease); }
.hero.in .copy > *:nth-child(2) { transition-delay: .08s; }
.hero.in .copy > *:nth-child(3) { transition-delay: .16s; }
.hero.in .copy > *:nth-child(4) { transition-delay: .24s; }
.hero.in .plate { transition-delay: .12s; }

.specs { margin-top: 56px; display: flex; gap: clamp(20px, 3vw, 48px); border-top: 1px solid var(--line); padding-top: 16px; }
.specs dt { font-size: 13px; color: var(--muted); }
.specs dd { margin-top: 2px; font-family: var(--mono); font-size: 13px; font-variant-numeric: tabular-nums; }

.dataline { margin-top: 34px; padding-top: 20px; border-top: 1px solid var(--line); font-family: var(--mono); font-size: 15px; font-variant-numeric: tabular-nums; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; }
.dataline i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }

/* ------------------------------------------------------------- assemblage */
.steps { margin-top: 34px; }
.steps li { display: grid; grid-template-columns: 30px 1fr; gap: 12px; padding: 13px 0; border-top: 1px solid var(--line); color: var(--muted); transition: color .5s var(--ease); }
.steps li:last-child { border-bottom: 1px solid var(--line); }
.steps li.on { color: var(--fg); }
.steps h3 { font-size: 18px; font-weight: 600; letter-spacing: -0.01em; }
.steps p { font-size: 15px; color: var(--soft); overflow: hidden; max-height: 0; transition: max-height .6s var(--ease), margin-top .6s var(--ease); }
.steps li.on p { max-height: 4.8em; margin-top: 4px; }
.n { font-family: var(--mono); font-size: 13px; padding-top: 3px; font-variant-numeric: tabular-nums; }
.steps li.on .n, .tabs button[aria-selected="true"] .n { color: var(--accent); }

/* ------------------------------------------------------------------ tabs */
.tabs { margin-top: 34px; display: grid; }
.tabs button { all: unset; cursor: pointer; display: flex; gap: 14px; align-items: baseline; padding: 14px 0; border-top: 1px solid var(--line); font-size: 18px; font-weight: 500; letter-spacing: -0.01em; color: var(--muted); position: relative; transition: color .35s var(--ease), padding-left .35s var(--ease); }
.tabs button:last-child { border-bottom: 1px solid var(--line); }
.tabs button:hover { color: var(--fg); }
.tabs button[aria-selected="true"] { color: var(--fg); padding-left: 10px; }
.tabs button::before { content: ""; position: absolute; left: 0; top: -1px; height: 2px; width: 100%; background: var(--fg); transform: scaleX(0); transform-origin: left; transition: transform .7s var(--ease); }
.tabs button[aria-selected="true"]::before { transform: scaleX(1); }
.tabs button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.tabpanels { margin-top: 22px; min-height: 5.2em; color: var(--soft); }
.tabpanels p { animation: swap .55s var(--ease); max-width: 42ch; }
@keyframes swap { from { opacity: 0; clip-path: inset(0 0 100% 0); } to { opacity: 1; clip-path: inset(0); } }

/* ---------------------------------------------------------------- atouts */
.atouts { margin-top: 32px; }
.atouts div { display: grid; grid-template-columns: 1fr auto; column-gap: 20px; row-gap: 4px; padding: 15px 0; border-top: 1px solid var(--line); }
.atouts div:last-child { border-bottom: 1px solid var(--line); }
.atouts dt { grid-row: 1; grid-column: 1; font-size: 18px; font-weight: 600; letter-spacing: -0.01em; }
.atouts span { grid-row: 1; grid-column: 2; font-family: var(--mono); font-size: 13px; color: var(--accent); align-self: baseline; font-variant-numeric: tabular-nums; }
.atouts dd { grid-row: 2; grid-column: 1 / -1; font-size: 15px; color: var(--soft); max-width: 46ch; }

/* ---------------------------------------------------------------- picker */
.picker { margin-top: 34px; display: grid; }
.picker button { all: unset; box-sizing: border-box; cursor: pointer; padding: 14px 0 14px 0; display: grid; gap: 2px; position: relative; border-top: 1px solid var(--line); color: var(--muted); transition: color .35s var(--ease), padding-left .35s var(--ease); }
.picker button:last-child { border-bottom: 1px solid var(--line); }
.picker button::before { content: ""; position: absolute; left: 0; top: 14px; bottom: 14px; width: 3px; border-radius: 2px; background: var(--accent); transform: scaleY(0); transition: transform .5s var(--ease); }
.picker button:hover { color: var(--fg); }
.picker button[aria-checked="true"] { color: var(--fg); padding-left: 16px; }
.picker button[aria-checked="true"]::before { transform: scaleY(1); }
.picker strong { font-weight: 600; font-size: 19px; letter-spacing: -0.01em; }
.picker em { font-style: normal; font-size: 14px; color: var(--muted); }
.picker button:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* ----------------------------------------------------------------- panel */
.panel { margin-top: 30px; display: grid; gap: 18px; padding: 24px; border-radius: 18px; background: var(--craie); box-shadow: 0 22px 44px -26px rgba(27, 33, 40, 0.5); }
.field { display: grid; gap: 6px; }
.field span, .swatches > span { font-size: 13px; color: #5b6570; }
.field input { width: 100%; border: 0; border-bottom: 1px solid rgba(27, 33, 40, 0.3); background: transparent; padding: 4px 0 8px; font-size: 18px; font-weight: 500; text-transform: uppercase; border-radius: 0; color: var(--granit); transition: border-color .25s var(--ease); }
.field input:hover { border-color: rgba(27, 33, 40, 0.6); }
.field input:focus { outline: none; border-color: var(--braise); box-shadow: 0 1px 0 var(--braise); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.swatches { display: flex; align-items: center; gap: 10px; }
.swatches > span { width: 60px; }
.swatches button { all: unset; cursor: pointer; width: 28px; height: 28px; border-radius: 50%; border: 1px solid rgba(27, 33, 40, 0.28); transition: box-shadow .25s var(--ease), transform .25s var(--ease); }
.swatches button:hover { transform: scale(1.08); }
.swatches button[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--craie), 0 0 0 4px var(--braise); }
.swatches button:focus-visible { outline: 2px solid var(--braise); outline-offset: 5px; }
.swatches button[data-color="anthracite"] { background: #2b2d30; }
.swatches button[data-color="blanc"] { background: #eceae6; }
.swatches button[data-color="foret"] { background: #1f3a2a; }
.swatches button[data-color="brun"] { background: #4b3a32; }
.swatches button[data-color="sable"] { background: #c2a878; }
.swatches button[data-color="vert"] { background: #355834; }
.swatches button[data-color="orange"] { background: #f25a1f; }
.swatches button[data-color="rouge"] { background: #c9281c; }

/* ----------------------------------------------------------------- final */
.section--final { grid-template-columns: minmax(0, 1fr); justify-items: center; text-align: center; gap: 0; padding-top: 96px; overflow: hidden; }
.final-visual { width: min(1040px, 100%); height: auto; transform: translate3d(0, var(--py, 0px), 0); }
.section--final .copy { width: 100%; max-width: 760px; margin-top: -2vh; }
.section--final h2 { font-size: clamp(40px, 6vw, 88px); }
.section--final .actions { justify-content: center; }

.footer { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px; padding: 28px var(--gutter); font-size: 14px; background: var(--granit); color: #a7adb3; }
.footer .brand { color: var(--craie); }
.footer nav { display: flex; gap: 26px; color: var(--craie); }
.footer > span:last-child { justify-self: end; }

/* -------------------------------------------------------------- tablette */
@media (max-width: 1020px) {
  .nav { grid-template-columns: 1fr auto; }
  .nav nav { display: none; }
  .footer { grid-template-columns: 1fr; justify-items: start; }
  .footer > span:last-child { justify-self: start; }
}

/* -------------------------------- téléphones et écrans en portrait (empilé) */
@media (max-width: 860px), (max-aspect-ratio: 9/10) {
  body { font-size: 16px; }
  .section, #concept, #personnalisation { grid-template-columns: 1fr; gap: 28px; padding: 96px var(--gutter) 56px; min-height: 0; }
  .section > .plate { order: -1; }
  .hero > .plate { order: 1; }
  .section--tall { min-height: 340vh; padding: 0; }
  .section--tall .sticky, #etapes .sticky { grid-template-columns: 1fr; grid-template-rows: auto 1fr; align-content: start; gap: 20px; padding: 76px var(--gutter) 20px; }
  .section--tall .sticky > .plate { order: -1; max-height: 44svh; aspect-ratio: auto; height: 44svh; }
  .copy { max-width: none; }
  .plate { border-radius: 22px; max-height: 60svh; }
  .plate--square { width: 100%; height: auto; }
  .plate--viewer { aspect-ratio: 1; }
  .plate figcaption { left: 14px; bottom: 10px; font-size: 12px; }
  .specs { margin-top: 36px; gap: 18px; }
  .specs div:nth-child(3) { display: none; }
  .steps { margin-top: 18px; }
  .steps li:not(.on) { display: none; }
  .steps li.on p { max-height: 7em; }
  .tabs { margin-top: 16px; }
  .tabs button { font-size: 16px; padding: 9px 0; }
  .tabpanels { margin-top: 12px; min-height: 5.6em; font-size: 15px; }
  .section--tall h2 { font-size: clamp(26px, 6.4vw, 36px); }
  .atouts div { padding: 12px 0; }
  .panel { padding: 18px; gap: 14px; }
  .btn { padding: 14px 20px; }
  .nav .btn--small { padding: 9px 14px; font-size: 13px; }
  .section--final { padding-top: 72px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  .hero .copy > *, .hero .plate { opacity: 1; transform: none; filter: none; }
}

/* ===================================================================== */
/* PAGE D'ACCUEIL : paysage plein écran, produit qui tourne au centre     */
/* ===================================================================== */
[data-theme="hero"] { --fg: var(--craie); --soft: #f4f2ee; --muted: rgba(244, 242, 238, 0.82); --line: rgba(244, 242, 238, 0.5); --accent: var(--pierre); --btn-bg: var(--craie); --btn-fg: var(--granit); }
.hero { position: relative; height: 100vh; height: 100svh; min-height: 620px; overflow: hidden; color: var(--fg); background: #7fa6dc; display: block; padding: 0; }
.hero-bg { position: absolute; inset: -6% -4%; transform: translate3d(var(--bx, 0px), var(--by, 0px), 0) scale(var(--bz, 1.04)); will-change: transform; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 70%; }
.hero::after { content: ""; position: absolute; inset: auto 0 0 0; height: 46%; background: linear-gradient(to top, rgba(14, 18, 23, 0.62), rgba(14, 18, 23, 0)); pointer-events: none; }

.hero-product { position: absolute; left: 50%; top: 44%; width: min(74vh, 62vw, 820px); aspect-ratio: 1; transform: translate3d(calc(-50% + var(--px, 0px)), calc(-50% + var(--py, 0px)), 0) scale(var(--ps, 1)); will-change: transform; z-index: 1; }
.hero-product canvas { width: 100%; height: 100%; cursor: grab; touch-action: pan-y; animation: float 6s ease-in-out infinite; will-change: transform; }
.hero-product canvas:active { cursor: grabbing; }
.hero-shadow { position: absolute; left: 18%; right: 18%; bottom: -3%; height: 12%; background: radial-gradient(closest-side, rgba(14, 18, 23, 0.6), rgba(14, 18, 23, 0)); animation: shadow 6s ease-in-out infinite; }
@keyframes float { 0%, 100% { transform: translateY(-1.4%); } 50% { transform: translateY(1.4%); } }
@keyframes shadow { 0%, 100% { transform: scale(0.92); opacity: 0.75; } 50% { transform: scale(1.04); opacity: 1; } }

.hero-copy { position: absolute; left: var(--gutter); bottom: clamp(28px, 6vh, 64px); z-index: 2; max-width: min(560px, 46vw); }
.hero-copy h1 { font-size: clamp(40px, 5.2vw, 84px); text-shadow: 0 2px 24px rgba(14, 18, 23, 0.35); }
.hero-copy .lead { margin-top: 18px; color: var(--soft); max-width: 40ch; text-shadow: 0 1px 14px rgba(14, 18, 23, 0.5); }
.hero-copy .actions { margin-top: 26px; }
.hero .btn--ghost { color: var(--craie); border-color: rgba(244, 242, 238, 0.6); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); background: rgba(14, 18, 23, 0.18); }
.hero .specs { position: absolute; right: var(--gutter); bottom: clamp(28px, 6vh, 64px); z-index: 2; margin: 0; border-top-color: var(--line); }
.hero .specs dt { color: var(--muted); }

/* entrée : le paysage se pose, le produit monte, le titre se déroule */
.hero .hero-bg { --bz: 1.16; transition: transform 2.2s var(--ease); }
.hero.in .hero-bg { --bz: 1.04; }
.hero .hero-product { opacity: 0; --ps: 0.82; transition: opacity 1.2s var(--ease) .15s, transform 1.6s var(--ease) .15s; }
.hero.in .hero-product { opacity: 1; --ps: 1; }
.hero.ready .hero-bg, .hero.ready .hero-product { transition: none; }
.hero .lead, .hero .actions, .hero .specs { opacity: 0; transform: translateY(16px); transition: opacity 1s var(--ease) .7s, transform 1s var(--ease) .7s; }
.hero.in .lead, .hero.in .actions, .hero.in .specs { opacity: 1; transform: none; }
.hero.in .actions { transition-delay: .82s; }
.hero.in .specs { transition-delay: .95s; }

.scroll-cue { position: absolute; left: 50%; bottom: 22px; width: 26px; height: 42px; margin-left: -13px; border: 1.5px solid rgba(244, 242, 238, 0.7); border-radius: 14px; z-index: 2; }
.scroll-cue span { position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: var(--craie); animation: cue 1.8s var(--ease) infinite; }
@keyframes cue { 0% { transform: translateY(0); opacity: 1; } 80%, 100% { transform: translateY(14px); opacity: 0; } }

/* navigation posée sur le paysage */
.nav:not(.scrolled) { color: var(--granit); }

/* barre de progression de lecture */
.progress { position: fixed; left: 0; top: 0; height: 3px; width: 100%; z-index: 7; background: linear-gradient(90deg, var(--braise), var(--pierre)); transform: scaleX(var(--p, 0)); transform-origin: left; }

/* ---------------------------------------------------------- bandeau défilant */
.marquee { background: var(--bg); color: var(--fg); overflow: hidden; padding: 22px 0; border-block: 1px solid var(--line); }
.marquee-track { display: flex; align-items: center; gap: 34px; width: max-content; will-change: transform; font-size: clamp(28px, 4vw, 60px); font-weight: 600; letter-spacing: -0.03em; line-height: 1; white-space: nowrap; }
.marquee-track i { width: 14px; height: 14px; border-radius: 50%; background: var(--braise); flex: none; }
.marquee-track span:nth-of-type(even) { color: transparent; -webkit-text-stroke: 1.5px var(--craie); }

/* ------------------------------------------------- titres révélés mot à mot */
[data-split] .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: 0.12em; margin-bottom: -0.12em; }
[data-split] .w > span { display: inline-block; transform: translateY(108%) rotate(4deg); transform-origin: left bottom; transition: transform 1s var(--ease); transition-delay: calc(var(--i) * 55ms + var(--d, 0ms)); }
[data-split].on .w > span { transform: none; }
.hero [data-split] { --d: 350ms; }

/* ------------------------------------------------ planches et listes révélées */
[data-reveal] { clip-path: inset(12% 12% 12% 12% round 28px); opacity: 0; transition: clip-path 1.3s var(--ease), opacity .8s var(--ease); }
[data-reveal] > img, [data-reveal] > canvas { transition: transform 1.6s var(--ease), opacity .7s var(--ease); }
[data-reveal]:not(.on) { --pop: 1.18; }
[data-reveal].on { clip-path: inset(0 round 28px); opacity: 1; }
[data-stagger] > * { opacity: 0; transform: translateY(22px); transition: opacity .8s var(--ease), transform .8s var(--ease), color .5s var(--ease), padding-left .35s var(--ease); transition-delay: calc(var(--i, 0) * 80ms + 120ms), calc(var(--i, 0) * 80ms + 120ms), 0s, 0s; }
[data-stagger].on > * { opacity: 1; transform: none; }
.lead, .note, .dataline, .panel, .gpx-wrap { transition: opacity 1s var(--ease) .25s, transform 1s var(--ease) .25s; }
.section:not(.seen) .lead, .section:not(.seen) .note, .section:not(.seen) .dataline, .section:not(.seen) .panel, .section:not(.seen) .gpx-wrap { opacity: 0; transform: translateY(18px); }

/* ------------------------------------------------- le tracé GPX se dessine */
.gpx-wrap { margin-top: 30px; max-width: 360px; }
.gpx { width: 100%; height: auto; overflow: visible; }
.gpx path { fill: none; stroke: #f25a1f; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; stroke-dashoffset: var(--off, 1); }
.dataline { margin-top: 18px; }
.dataline b { font-weight: 500; }

/* planches : léger basculement sous le pointeur */
.plate { transition: transform .6s var(--ease), clip-path 1.3s var(--ease), opacity .8s var(--ease); transform: perspective(1200px) rotateX(var(--tx, 0deg)) rotateY(var(--ty, 0deg)); }
.final-visual { animation: float 7s ease-in-out infinite; }

@media (max-width: 860px), (max-aspect-ratio: 9/10) {
  .hero { min-height: 560px; }
  .hero-product { top: 34%; width: min(84vw, 46vh); }
  .hero-copy { max-width: none; right: var(--gutter); bottom: 64px; }
  .hero-copy h1 { font-size: clamp(34px, 10vw, 52px); }
  .hero .specs, .scroll-cue { display: none; }
  .hero::after { height: 62%; }
  .marquee { padding: 14px 0; }
  .gpx-wrap { max-width: 260px; }
  [data-reveal], [data-reveal].on { clip-path: none; }
}

@media (prefers-reduced-motion: reduce) {
  .hero .hero-product, .hero .lead, .hero .actions, .hero .specs, [data-reveal], [data-stagger] > *, [data-split] .w > span { opacity: 1 !important; transform: none !important; clip-path: none !important; }
  .section:not(.seen) .lead, .section:not(.seen) .note, .section:not(.seen) .dataline, .section:not(.seen) .panel, .section:not(.seen) .gpx-wrap { opacity: 1; transform: none; }
  .hero-product canvas, .hero-shadow, .final-visual, .scroll-cue span { animation: none; }
  .gpx path { stroke-dashoffset: 0; }
}


/* ===================================================================== */
/* ACCUEIL : trois produits en cercle, vraie profondeur (transformations 3D) */
/* ===================================================================== */
.hero-bg img { object-position: 50% 34%; }
.hero { background: #5d7fb0; }
.hero::after { height: 58%; background: linear-gradient(to top, rgba(6, 14, 22, 0.78), rgba(6, 14, 22, 0)); }
.orbit { position: absolute; left: 71%; top: 54%; width: min(44vh, 27vw, 460px); aspect-ratio: 1; z-index: 1; perspective: 1500px; perspective-origin: 50% 42%; transform: translate3d(calc(-50% + var(--px, 0px)), calc(-50% + var(--py, 0px)), 0) scale(var(--ps, 1)); transform-style: preserve-3d; cursor: grab; touch-action: pan-y; }
.orbit:active { cursor: grabbing; }
.orb { position: absolute; inset: 0; margin: 0; transform-style: preserve-3d; will-change: transform; backface-visibility: hidden; }
.orb img { position: absolute; left: -28%; top: -28%; width: 156%; height: 156%; max-width: none; pointer-events: none; user-select: none; -webkit-user-drag: none; }
.orb i { position: absolute; left: 6%; right: 6%; top: 96%; height: 13%; background: radial-gradient(closest-side, rgba(4, 10, 16, 0.55), rgba(4, 10, 16, 0)); transform: translateZ(-1px); }
.hero .orbit { opacity: 0; --ps: 0.86; transition: opacity 1.2s var(--ease) .15s, transform 1.6s var(--ease) .15s; }
.hero.in .orbit { opacity: 1; --ps: 1; }
.hero.ready .orbit { transition: none; }
.hero-copy { max-width: min(500px, 36vw); bottom: auto; top: 50%; transform: translateY(-42%); }
.hero-copy h1 { font-size: clamp(38px, 4.6vw, 76px); }

@media (max-width: 860px), (max-aspect-ratio: 9/10) {
  .orbit { left: 50%; top: 32%; width: min(44vw, 28vh); }
  .hero-copy { top: auto; bottom: 56px; transform: none; max-width: none; }
}
@media (prefers-reduced-motion: reduce) { .hero .orbit { opacity: 1 !important; } }


/* ===================================================================== */
/* Retouches de contenu : carte du parcours, assemblage sur fond de montagne */
/* ===================================================================== */
.hero-copy h1 { font-size: clamp(34px, 3.9vw, 64px); line-height: 1.02; }
.hero-copy { max-width: min(560px, 40vw); }

.map { position: relative; margin-top: 28px; border-radius: 18px; overflow: hidden; aspect-ratio: 3 / 2; max-width: 520px; box-shadow: 0 24px 50px -28px rgba(0, 0, 0, 0.7); transition: opacity 1s var(--ease) .25s, transform 1s var(--ease) .25s; }
.section:not(.seen) .map { opacity: 0; transform: translateY(18px); }
.map img { width: 100%; height: 100%; object-fit: cover; }
.map svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.map path { fill: none; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; stroke-dashoffset: var(--off, 1); }
.map .casing { stroke: rgba(255, 255, 255, 0.92); stroke-width: 1.5; }
.map .line { stroke: #f25a1f; stroke-width: 0.9; }
.map circle { stroke: #f25a1f; stroke-width: 0.6; }
.map .start { fill: #f1f5f2; }
.map .end { fill: #14281d; opacity: var(--end, 0); }

/* assemblage : le produit, plus grand, devant un pan de montagne */
.plate--photo { background: #5d7fb0; aspect-ratio: auto; height: min(82svh, 760px); max-height: none; --zoom: 1.22; }
.plate--photo > .backdrop { object-fit: cover; object-position: 62% 30%; transform: scale(1.06); filter: saturate(0.9); }
.plate--photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(8, 16, 24, 0.5), rgba(8, 16, 24, 0) 55%); pointer-events: none; }
.plate--photo > canvas { z-index: 1; filter: drop-shadow(0 26px 30px rgba(4, 10, 16, 0.45)); }
#assemblage .sticky { grid-template-columns: minmax(0, 4fr) minmax(0, 6fr); }

.plate--stack > img.cover { object-fit: cover; --zoom: 1; }
.plate--stack > img.cover.on { --pop: 1; }
.atouts div { grid-template-columns: 1fr; }
.field input { text-transform: none; }
#config-continue { margin-top: 4px; }

@media (max-width: 860px), (max-aspect-ratio: 9/10) {
  .hero-copy { max-width: none; }
  .hero-copy h1 { font-size: clamp(30px, 8.4vw, 44px); }
  #assemblage .sticky { grid-template-columns: 1fr; }
  .plate--photo { height: 44svh; }
  .map { max-width: none; }
}
@media (prefers-reduced-motion: reduce) { .map path { stroke-dashoffset: 0; } .map .end { opacity: 1; } .section:not(.seen) .map { opacity: 1; transform: none; } }


/* accueil : les images fixes s'affichent d'abord, puis la scène 3D prend le relais */
#hero3d { position: absolute; left: -75%; top: -32%; width: 250%; max-width: none; height: 164%; pointer-events: none; opacity: 0; transition: opacity .9s var(--ease); }
.orbit.live #hero3d { opacity: 1; }
.orbit.live .orb { opacity: 0; transition: opacity .9s var(--ease); }
/* étape 1 : les quatre modèles tiennent entiers dans la planche */
.plate--stack > img.fit { --zoom: 1; padding: 1.5%; }
#personnalisation .actions { margin-top: 22px; }
#personnalisation .note { margin-top: 14px; }

/* Titres découpés en mots : pas d'équilibrage automatique des lignes. Pendant
   l'apparition, Safari recalculait cet équilibrage mot par mot et empilait
   les mots verticalement. */
[data-split] { text-wrap: wrap; }
/* Faire tourner les produits à la souris ne doit jamais sélectionner la page
   (la sélection, verte, recouvrait tout l'écran). */
.hero-product, .hero-product *, #orbit, .plate--viewer, .plate--viewer * { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }

/* ------------------------------------------------------------ pages légales */
.legal { background: var(--craie); color: var(--granit); max-width: 820px; margin: 0 auto; padding: 136px var(--gutter) 104px; box-sizing: content-box; }
.legal h1 { font-size: clamp(34px, 4.4vw, 58px); line-height: 1.04; letter-spacing: -0.035em; font-weight: 600; text-wrap: balance; }
.legal .updated { margin-top: 14px; font-family: var(--mono); font-size: 13px; color: var(--muted); }
.legal section { margin-top: 48px; padding-top: 28px; border-top: 1px solid var(--line); }
.legal h2 { font-size: 21px; line-height: 1.25; letter-spacing: -0.015em; }
.legal p, .legal li { margin-top: 12px; color: var(--soft); max-width: 68ch; text-wrap: pretty; }
.legal ul { list-style: disc; padding-left: 20px; }
.legal li::marker { color: var(--pierre); }
.legal strong { color: var(--granit); font-weight: 600; }
.legal a { color: var(--braise-texte); text-decoration: underline; text-underline-offset: 3px; }
.legal .facts { margin-top: 16px; display: grid; }
.legal .facts div { display: grid; grid-template-columns: minmax(150px, 0.8fr) 2fr; gap: 16px; padding: 12px 0; border-top: 1px solid var(--line); }
.legal .facts div:last-child { border-bottom: 1px solid var(--line); }
.legal .facts dt { font-size: 14px; color: var(--muted); }
.legal .facts dd { color: var(--granit); }
mark.todo { background: rgba(232, 87, 31, 0.16); color: var(--granit); padding: 1px 5px; border-radius: 4px; font-size: 0.94em; }
.footer .legal-links { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px 24px; padding-top: 18px; border-top: 1px solid rgba(244, 242, 238, 0.14); font-size: 13px; color: #a7adb3; }
.footer .legal-links a:hover, .footer .legal-links a[aria-current="page"] { color: var(--craie); }
@media (max-width: 760px) {
  .legal { padding-top: 104px; }
  .legal .facts div { grid-template-columns: 1fr; gap: 2px; }
  .legal .nav nav, .nav:has(+ .legal) nav { display: none; }
}

/* logo Sportyca : le S et le nom prennent la couleur du texte, le point d'arrivée reste braise */
.brand { display: inline-flex; align-items: center; line-height: 0; letter-spacing: 0; }
.brand .logo { height: 22px; width: auto; display: block; }
.footer .brand .logo { height: 20px; }
