/* RoboMark — landing page v2. Direction « One motif » (taste-skill, seed 1812954649), resserrée :
   le triangle ne revient qu'aux moments forts (logo, bouton guidon, ouverture de la photo, schéma, pied de page) ;
   les photos sont en plein cadre, les sections pleine largeur, fonds sombres et clairs en alternance. */

@font-face { font-family: "Jost"; font-weight: 400; font-display: swap; src: url("../fonts/jost-400.woff2") format("woff2"); }
@font-face { font-family: "Jost"; font-weight: 500; font-display: swap; src: url("../fonts/jost-500.woff2") format("woff2"); }
@font-face { font-family: "Jost"; font-weight: 700; font-display: swap; src: url("../fonts/jost-700.woff2") format("woff2"); }

:root {
  --ground: #ffffff;
  --ground-2: #f1f0ec;
  --ink: #1a1a18;
  --muted: #55554f;
  --accent: #ff4438;
  --accent-ink: #1a1a18;
  --deep: #121314;
  --deep-2: #1d1f21;
  --pale: #f2f2f0;
  --pale-muted: #b9b9b3;

  --step-small: clamp(0.875rem, 0.84rem + 0.15vw, 0.9375rem);
  --step-body: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);
  --step-lead: clamp(1.25rem, 1.1rem + 0.7vw, 1.625rem);
  --step-head: clamp(2.25rem, 1.2rem + 4vw, 5rem);
  --step-display: clamp(3.5rem, 1rem + 9vw, 9.5rem);

  --margin: clamp(16px, 3.5vw, 56px);
  --gap-section: clamp(88px, 10vw, 160px);

  --tri: polygon(50% 0, 100% 100%, 0 100%);
  --pennant: polygon(0 0, calc(100% - 22px) 0, 100% 50%, calc(100% - 22px) 100%, 0 100%);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--ground); color: var(--ink);
  font: 400 var(--step-body)/1.5 "Jost", system-ui, sans-serif;
  overflow-x: hidden;
}
img, video, svg { display: block; max-width: 100%; }
h1, h2, h3, p, figure, dl, dd { margin: 0; }
h1, h2, h3 { text-wrap: balance; }
a { color: inherit; }
button { font: inherit; color: inherit; }
a, button, input { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
section[id] { scroll-margin-top: 24px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
::selection { background: var(--accent); color: var(--accent-ink); }

.skip { position: absolute; left: var(--margin); top: -100px; z-index: 20; background: var(--ink); color: var(--ground); padding: 12px 16px; }
.skip:focus { top: 12px; }

.display { font-weight: 700; font-size: var(--step-display); line-height: 0.88; letter-spacing: -0.035em; text-transform: uppercase; }
.head { font-weight: 700; font-size: var(--step-head); line-height: 0.92; letter-spacing: -0.03em; text-transform: uppercase; }

/* Bouton : un guidon de club */
.pennant {
  display: inline-flex; align-items: center; min-height: 56px; padding: 0 44px 0 24px;
  background: var(--accent); color: var(--accent-ink); font-weight: 500; font-size: var(--step-body);
  text-decoration: none; clip-path: var(--pennant);
  transition: background-color 160ms ease, color 160ms ease, transform 160ms var(--ease-out);
}
.pennant:hover, .pennant:focus-visible { background: var(--pale); color: var(--ink); outline: none; }
.pennant:active { transform: translateX(3px); }
.pennant--small { min-height: 44px; padding: 0 36px 0 18px; font-size: var(--step-small); }
.team .pennant:hover, .foot .pennant:hover, .foot .pennant:focus-visible { background: var(--ink); color: var(--ground); }

/* Barre, posée sur la vidéo */
.bar {
  position: absolute; inset: 0 0 auto 0; z-index: 10;
  display: flex; align-items: center; gap: 32px; padding: 24px var(--margin); color: var(--pale);
}
.bar__brand { display: flex; align-items: center; gap: 12px; text-decoration: none; font-weight: 500; font-size: 22px; letter-spacing: 0.02em; }
.bar__brand svg { width: 52px; height: auto; }
.bar__brand path, .foot__mark path { fill: none; stroke: var(--accent); stroke-linejoin: miter; stroke-miterlimit: 20; }
.bar__brand path { stroke-width: 34; }
.bar__nav { display: flex; gap: 28px; margin-left: auto; }
.bar__nav a { text-decoration: none; font-weight: 500; transition: color 160ms ease; }
.bar__nav a:hover { color: var(--accent); }

/* Hero : vidéo plein écran, titre géant */
.hero {
  position: relative; min-height: max(640px, 100svh); overflow: hidden;
  display: flex; flex-direction: column; justify-content: flex-end;
  background: var(--deep); color: var(--pale);
  padding: 140px var(--margin) 32px;
}
.hero__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
/* Voile neutre sous le texte (la seule exception admise aux dégradés : un voile sur une photo) */
.hero__scrim { position: absolute; inset: 0; background: linear-gradient(to top, rgb(0 0 0 / 0.72) 0%, rgb(0 0 0 / 0.35) 45%, rgb(0 0 0 / 0.15) 100%); } /* taste-skill-ignore */
.hero__copy { position: relative; max-width: 1100px; }
.hero__lead { margin-top: 32px; max-width: 40ch; font-size: var(--step-lead); line-height: 1.4; }
.hero__copy .pennant { margin-top: 36px; }
.hero__foot { position: relative; display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-top: 56px; font-size: var(--step-small); color: var(--pale-muted); }
.hero__toggle {
  min-height: 44px; padding: 0 18px; border: 0; cursor: pointer; background: rgb(255 255 255 / 0.14); color: var(--pale);
  font-weight: 500; transition: background-color 160ms ease, color 160ms ease;
}
.hero__toggle:hover { background: var(--pale); color: var(--ink); }

/* Chiffres */
.facts { background: var(--deep); color: var(--pale); padding: 72px var(--margin) 88px; }
.facts dl { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.facts dl > div { display: flex; flex-direction: column-reverse; justify-content: flex-end; gap: 12px; padding-top: 24px; background: var(--deep); }
.facts dd { font-weight: 700; font-size: clamp(3rem, 1.5rem + 4.2vw, 6rem); line-height: 0.9; letter-spacing: -0.04em; color: var(--accent); font-variant-numeric: tabular-nums; }
.facts dt { font-size: var(--step-body); color: var(--pale); max-width: 22ch; }

/* Ouverture : la photo sort du triangle et prend tout l'écran au défilement */
.open { position: relative; background: var(--deep); color: var(--pale); --p: 1; }   /* sans script : photo ouverte */
.js .open { --p: 0; }
.open__sticky { height: 100svh; }
.js .open__sticky { position: sticky; top: 0; }
.js .open__track { height: 240svh; }   /* la course de défilement pendant laquelle la photo reste épinglée */
.open__sticky { overflow: hidden; }
.open__title { padding: 24px var(--margin) 48px; }
.open__frame {
  position: absolute; inset: 0;
  clip-path: polygon(
    calc(50% - 50% * var(--p)) calc(6% - 6% * var(--p)),
    calc(50% + 50% * var(--p)) calc(6% - 6% * var(--p)),
    calc(94% + 6% * var(--p)) 100%,
    calc(6% - 6% * var(--p)) 100%
  );
}
.open__frame img { width: 100%; height: 100%; object-fit: cover; object-position: 66% 50%; transform: scale(calc(1.14 - 0.14 * var(--p))); }
.open__specs {
  position: absolute; left: var(--margin); right: var(--margin); bottom: 32px; z-index: 2;
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0;
  background: var(--deep);
  opacity: clamp(0, calc((var(--p) - 0.75) * 5), 1);
  transform: translateY(calc((1 - clamp(0, calc((var(--p) - 0.75) * 5), 1)) * 24px));
}
.open__specs li { color: var(--pale); padding: 22px 24px 26px; font-size: var(--step-small); line-height: 1.45; }
.open__specs strong { display: block; font-size: var(--step-body); font-weight: 500; margin-bottom: 4px; color: var(--pale); }

/* Pour qui */
.who { padding: var(--gap-section) var(--margin) 0; }
.who__head { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 24px; align-items: end; }
.who__head .head { grid-column: 1 / 9; }
.who__head p { grid-column: 9 / 13; max-width: 34ch; }
.who__cols { list-style: none; margin: 56px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.who__cols img { width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; }
.who__cols h3 { margin-top: 20px; font-size: var(--step-lead); font-weight: 700; line-height: 1.1; }
.who__cols p { margin-top: 8px; max-width: 36ch; }

/* Le vent : section sombre */
.wind {
  margin-top: var(--gap-section); background: var(--deep); color: var(--pale);
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 24px; align-items: center;
  padding: var(--gap-section) var(--margin);
}
.wind__copy { grid-column: 1 / 8; }
.wind__copy > p { margin-top: 32px; max-width: 44ch; }
.wind__control { margin-top: 40px; }
.wind__control label { display: flex; justify-content: space-between; max-width: 440px; font-weight: 500; }
.wind__control output { font-variant-numeric: tabular-nums; color: var(--accent); }
.wind__control input[type="range"] { width: 100%; max-width: 440px; margin: 16px 0 24px; accent-color: var(--accent); height: 32px; }
.wind__presets { display: flex; flex-wrap: wrap; gap: 10px; }
.wind__presets button {
  min-height: 44px; padding: 0 18px; border: 0; cursor: pointer; background: var(--deep-2); color: var(--pale); font-weight: 500;
  transition: background-color 160ms ease, color 160ms ease, transform 120ms ease;
}
.wind__presets button:hover { background: var(--accent); color: var(--accent-ink); }
.wind__presets button:active { transform: translateY(1px); }
.wind__map { grid-column: 8 / 13; }
.wind__map svg { width: 100%; height: auto; }
.wind__map figcaption { margin-top: 16px; color: var(--pale-muted); min-height: 3em; font-size: var(--step-small); }
.map__water { fill: #1f3440; }
.map__wind path { fill: none; stroke: var(--pale); stroke-width: 6; stroke-linecap: square; }
.map__wind, .map__mark, .map__ghost, .map__axis { transition: transform 900ms var(--ease-out); }
.map__axis { stroke: #4d6a78; stroke-width: 4; stroke-dasharray: 2 14; stroke-linecap: round; }
.map__mark { transform: translate(300px, 150px); }
.map__mark path { fill: var(--accent); }
.map__ghost { opacity: 0; transform: translate(300px, 150px); transition: opacity 300ms ease; }
.map__ghost path { fill: #6f8a96; }
.wind.is-shifted .map__ghost { opacity: 1; }
.map__line line { stroke: var(--pale); stroke-width: 4; stroke-dasharray: 12 10; }
.map__boat, .map__pin { fill: var(--pale); }
.wind__map text { font: 500 18px "Jost", sans-serif; fill: var(--pale); }
.map__ghost text { fill: #a9bcc4; }

/* Sur l'eau : mosaïque */
.water { padding: var(--gap-section) var(--margin) 0; }
.water__grid {
  margin-top: 56px; display: grid; gap: 10px;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  grid-template-areas: "a a a a b b b b c c c c" "d d d d d d d d d d d d";
}
.water__a { grid-area: a; } .water__b { grid-area: b; } .water__c { grid-area: c; } .water__d { grid-area: d; }
.water__grid img { width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; }
.water__d img { aspect-ratio: 21 / 8; object-position: 60% 50%; }
.water__grid figcaption { margin-top: 14px; max-width: 46ch; color: var(--muted); }
.water__grid strong { color: var(--ink); font-weight: 700; }

/* Références */
.proof { margin-top: var(--gap-section); background: var(--ground-2); padding: 88px var(--margin); display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 24px; row-gap: 48px; align-items: center; }
.proof__head { grid-column: 1 / 13; display: flex; justify-content: space-between; align-items: end; gap: 32px; flex-wrap: wrap; }
.proof__head p { max-width: 40ch; }
.proof__logos { grid-column: 1 / 13; list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; }
.proof__logos li { aspect-ratio: 3 / 2; background: var(--ground); display: grid; place-items: center; padding: 16px; transition: background-color 160ms ease; }
.proof__logos img { height: 56px; width: auto; max-width: 80%; object-fit: contain; filter: grayscale(1) contrast(1.3); mix-blend-mode: multiply; transition: filter 200ms ease; }
.proof__logos li:hover img { filter: none; }
.proof__logos li:first-child { grid-column: span 2; grid-row: span 2; aspect-ratio: auto; }
.proof__logos li:first-child img { height: 120px; }

/* Équipe : photo pleine hauteur, texte sur fond sombre */
.team { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); background: var(--deep); color: var(--pale); min-height: 100svh; }
.team__photo { position: relative; min-height: 60svh; }
.team__photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; }
.team__text { padding: clamp(48px, 7vw, 120px) var(--margin); display: flex; flex-direction: column; justify-content: center; gap: 20px; align-items: flex-start; }
.team__lead { font-size: var(--step-lead); color: var(--accent); font-weight: 500; margin-top: 12px; }
.team__text p:not(.team__lead) { max-width: 42ch; }
.team__text .pennant { margin-top: 20px; }

/* Appel */
.cta__band {
  position: relative; display: block; min-height: 60svh;
  background: var(--accent); color: var(--accent-ink); text-decoration: none; overflow: hidden;
  transition: background-color 120ms linear, color 120ms linear;
}
.cta__band:hover, .cta__band:focus-visible { background: var(--ink); color: var(--accent); outline: none; }
.cta__note { position: absolute; left: var(--margin); top: 40px; max-width: 26ch; font-size: var(--step-body); font-weight: 500; }
.cta__arrow { position: absolute; right: var(--margin); top: 36px; width: 48px; height: 48px; transition: transform 300ms var(--ease-out); }
.cta__arrow path { fill: none; stroke: currentColor; stroke-width: 5; stroke-linecap: square; }
.cta__band:hover .cta__arrow { transform: translate(6px, -6px); }
.cta__word {
  position: absolute; left: var(--margin); right: var(--margin); bottom: 24px;
  font-weight: 700; text-transform: uppercase; letter-spacing: -0.05em; font-size: min(30vw, 46svh); line-height: 0.74;
  transition: transform 300ms var(--ease-out);
}
.cta__band:hover .cta__word { transform: translateX(1.5vw); }

/* Pied de page */
.foot { background: var(--ground-2); padding: 64px var(--margin) 32px; }
.foot__mark { width: 100%; height: auto; max-height: 40svh; }
.foot__mark path { stroke-width: 14; }
.foot__cols { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 24px; row-gap: 40px; margin-top: 56px; }
.foot__cols nav, .foot__contact { grid-column: span 2; display: flex; flex-direction: column; gap: 8px; }
.foot__contact { grid-column: 9 / 13; }
.foot__cols h2 { font-size: var(--step-body); font-weight: 700; margin-bottom: 4px; }
.foot__cols a { text-decoration: none; transition: color 160ms ease; }
.foot__cols a:hover { color: var(--accent); text-decoration: underline; }
.foot__last { display: flex; justify-content: space-between; align-items: center; margin-top: 56px; font-size: var(--step-small); }

/* Mouvement : entrées (transform/opacity) */
.js .reveal > *, .js .reveal.who__cols > li, .js li.reveal > *, .js figure.reveal > *, .js .proof__logos li {
  opacity: 0; transform: translateY(28px);
  transition: opacity 700ms var(--ease-out), transform 700ms var(--ease-out);
}
.js .reveal.is-in > *, .js .proof__logos.is-in li { opacity: 1; transform: none; }
.js .reveal.is-in > :nth-child(2) { transition-delay: 90ms; }
.js .reveal.is-in > :nth-child(3) { transition-delay: 180ms; }
.js .reveal.is-in > :nth-child(4) { transition-delay: 270ms; }
.js .reveal.is-in > :nth-child(5) { transition-delay: 360ms; }
.js .proof__logos.is-in li:nth-child(n+2) { transition-delay: 60ms; }
.js .proof__logos.is-in li:nth-child(n+4) { transition-delay: 140ms; }
.js .proof__logos.is-in li:nth-child(n+7) { transition-delay: 220ms; }
.js .proof__logos.is-in li:nth-child(n+10) { transition-delay: 300ms; }
.js .hero__copy > * { opacity: 0; transform: translateY(32px); animation: rise 900ms var(--ease-out) forwards; }
.js .hero__copy > :nth-child(2) { animation-delay: 140ms; }
.js .hero__copy > :nth-child(3) { animation-delay: 280ms; }
@keyframes rise { to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 1ms !important; animation-duration: 1ms !important; animation-delay: 0ms !important; }
  .js .open__track { height: auto; }
  .open { --p: 1; }
  .js .open__sticky { position: relative; height: auto; }
  .open__frame { position: relative; aspect-ratio: 21 / 9; clip-path: none; }
  .open__specs { position: relative; left: auto; right: auto; bottom: auto; padding: 8px var(--margin) 0; opacity: 1; transform: none; }
}

/* Tablette */
@media (max-width: 1080px) {
  .facts dl { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 40px; }
  .open__specs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .proof__logos { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .who__head .head, .who__head p { grid-column: 1 / 13; }
  .who__head p { margin-top: 24px; }
  .wind__copy, .wind__map { grid-column: 1 / 13; }
  .wind__map { margin-top: 48px; }
  .proof__head, .proof__logos { grid-column: 1 / 13; }
  .team { grid-template-columns: minmax(0, 1fr); }
  .foot__cols nav { grid-column: span 4; }
  .foot__contact { grid-column: 1 / 13; }
}

/* Téléphone */
@media (max-width: 760px) {
  .bar { padding: 16px; gap: 16px; }
  .bar__brand { font-size: 18px; }
  .bar__brand svg { width: 40px; }
  .bar__nav { display: none; }
  .bar .pennant { margin-left: auto; }
  .hero { padding: 120px 16px 20px; }
  .display { font-size: 13vw; }
  .hero__lead { margin-top: 20px; font-size: 18px; }
  .hero__copy .pennant { margin-top: 24px; }
  .hero__foot { margin-top: 32px; }
  .hero__foot p { max-width: 20ch; }
  .facts { padding: 48px 16px 64px; }
  .facts dl { gap: 32px 16px; }
  .open__specs { bottom: 16px; left: 16px; right: 16px; gap: 6px; }
  .open__specs li { padding: 14px; }
  .open__specs li span { display: none; }
  .open__specs strong { margin: 0; }
  .open__frame img { object-position: 72% 50%; }
  .who__cols { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .who__cols img { aspect-ratio: 5 / 4; }
  .water__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-areas: "a b" "c c" "d d"; }
  .water__c img { aspect-ratio: 5 / 4; }
  .water__d img { aspect-ratio: 16 / 10; }
  .proof { padding: 64px 16px; }
  .proof__logos { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
  .proof__logos img { height: 44px; }
  .proof__logos li:first-child img { height: 88px; }
  .team__text { padding: 56px 16px 72px; }
  .cta__band { min-height: 46svh; }
  .cta__note { top: 24px; font-size: 17px; max-width: 18ch; }
  .cta__arrow { width: 32px; height: 32px; top: 24px; }
  .cta__word { font-size: 31vw; }
  .foot { padding: 40px 16px 24px; }
  .foot__cols nav { grid-column: span 6; }
  .foot__last { margin-top: 40px; }
}
