/* ==========================================================
   Base — reset, typographie, layout
   ========================================================== */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; overflow-x: clip; } /* aucun défilement horizontal parasite (bandeaux, parallaxes) */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: var(--fs-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden; /* repli vieux navigateurs */
  overflow-x: clip;   /* "hidden" ferait de body un conteneur de défilement et casserait position: sticky */
}
body.is-loading { overflow: hidden; }

img, svg, canvas { display: block; max-width: 100%; }
img { height: auto; } /* les attributs width/height réservent la place, sans déformer */
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, p, dl, dd, figure { margin: 0; }
strong, b { font-weight: 600; }
::selection { background: var(--rust); color: #fff; }

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

/* pas de mot seul en fin de titre ou de paragraphe */
h1, h2, h3 { text-wrap: balance; }
p, li, dd { text-wrap: pretty; }

/* ---------- Layout ---------- */
.wrap {
  width: 100%;
  max-width: 1440px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.sec { padding-block: var(--sec-y); position: relative; }

[data-theme="dark"] { background: var(--night); color: var(--on-dark); }

/* ---------- Typo ---------- */
.label {
  font-family: var(--f-display);
  font-stretch: 112%;
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  line-height: 1.4;
  display: inline-flex;
  align-items: center;
  gap: .6em;
}
.label--muted { color: var(--ink-3); letter-spacing: .12em; }
[data-theme="dark"] .label--muted { color: var(--on-dark-3); }

.h-display {
  font-family: var(--f-display);
  font-size: var(--fs-display);
  font-weight: 650;
  font-stretch: 100%;
  line-height: .98;
  letter-spacing: -.035em;
}
.h-display--md { font-size: var(--fs-display-md); }
.h-display em,
.hero__title em,
.statement em {
  font-style: normal;
  font-weight: 300;
}

.statement {
  font-family: var(--f-display);
  font-size: var(--fs-statement);
  font-weight: 600;
  line-height: 1.06;
  letter-spacing: -.03em;
}
.statement em { color: var(--ink-2); }
.statement--sm { font-size: clamp(1.5rem, 2.6vw, 2.5rem); }
.statement--light em { color: var(--on-dark-2); }

.lead {
  font-size: var(--fs-lead);
  line-height: 1.45;
  font-weight: 400;
  letter-spacing: -.01em;
}
.lead--light { color: var(--on-dark); }
.body { color: var(--ink-2); max-width: 46ch; }
.body--light { color: var(--on-dark-2); }
.body--muted { color: var(--on-dark-2); }

/* ---------- Section head (ligne + labels) ---------- */
.sec-head {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  align-items: center;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  margin-bottom: clamp(48px, 7vw, 96px);
}
.sec-head--dark { border-color: var(--line-dark); }
.label--right { justify-self: end; text-align: right; color: var(--ink-2); }
.sec-head--dark .label--right { color: var(--on-dark-2); }

/* Texte réservé aux lecteurs d'écran */
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* ---------- Split text (animé en JS) ---------- */
.split-mask { display: inline-block; overflow: hidden; vertical-align: bottom; padding-bottom: .12em; margin-bottom: -.12em; padding-inline: .02em; margin-inline: -.02em; }
.split-word { display: inline-block; will-change: transform; }

/* Si GSAP ne charge pas : tout reste visible */
.no-anim .loader, .no-anim .cursor { display: none !important; }

/* ---------- Mouvement réduit ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}

@media (max-width: 760px) {
  .sec-head { grid-template-columns: auto 1fr; gap: 12px; }
  .sec-head .label--right { display: none; }
}
