/* =========================================================================
   YH DIGITAL — système visuel — « Rupture Éditoriale »
   Direction : rythme asymétrique concentré sur "friction" (pull-quote
   éditorial full-bleed) et "outils" (rail resserré), reste de la page
   volontairement sobre. Tokens (encre + rouge rationné) et polices
   inchangés depuis l'origine du site.
   ========================================================================= */

/* ---------- Polices auto-hébergées (aucune dépendance tierce) ---------- */

@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 400 800;
  font-stretch: 100% 125%;
  font-display: swap;
  src: url("assets/fonts/archivo-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6,
    U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
    U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: url("assets/fonts/plex-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6,
    U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
    U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Tokens (identiques à la version live) ---------- */

:root {
  --ink-950: #0e0c0c;
  --ink-900: #151212;
  --ink-800: #1b1717;
  --ink-700: #251f1d;
  --ink-500: #3e3532;
  --ink-300: #a9a09b;
  --ink-050: #f2eeec;

  --rouge: #d6402d;
  --rouge-oxyde: #7e4038;

  --color-bg: var(--ink-950);
  --color-bg-alt: var(--ink-900);
  --color-text: var(--ink-050);
  --color-text-muted: var(--ink-300);
  --color-accent: var(--rouge);
  --color-rule: var(--ink-500);

  --veil-950: rgb(14 12 12 / 0.58);
  --veil-900: rgb(21 18 18 / 0.58);

  --font-display: "Archivo", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-text: "IBM Plex Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-main: var(--font-text);

  --sp-1: 4px;
  --sp-2: 8px;
  --sp-3: 12px;
  --sp-4: 16px;
  --sp-5: 24px;
  --sp-6: 32px;
  --sp-7: 48px;
  --sp-8: 64px;
  --sp-9: 96px;
  --sp-10: 128px;

  --gutter: clamp(24px, 5vw, 64px);
  --measure: 1180px;
  --rail: 190px;
  --section-y: clamp(88px, 11vh, 152px);

  --ease-out: cubic-bezier(0.16, 0.84, 0.32, 1);
  --ease-snap: cubic-bezier(0.2, 0.9, 0.25, 1.08);
  --dur: 0.5s;
}

/* ---------- Reset ---------- */

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scrollbar-gutter: stable both-edges;
  -webkit-text-size-adjust: 100%;
}

::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--ink-900);
}

::-webkit-scrollbar-thumb {
  background: var(--ink-500);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--ink-300);
}

::selection {
  background: var(--rouge);
  color: #fff;
}

body {
  background: var(--ink-950);
  color: var(--ink-050);
  font-family: var(--font-text);
  font-size: 1rem;
  line-height: 1.65;
  font-weight: 400;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img,
svg {
  max-width: 100%;
}

/* =========================================================================
   Scène 3D — V3 : un nuage de particules (WebGL, voir scene3d.js) qui se
   cristallise au scroll, plan fixe derrière toute la page, révélé par les
   voiles de section. Toujours purement décorative — aria-hidden.
   ========================================================================= */

.scene-3d {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.scene-3d canvas {
  display: block;
}

@media (prefers-reduced-motion: reduce) {
  .scene-3d {
    display: none;
  }
}

/* ---------- Échelle typographique ---------- */

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 7vw, 5.75rem);
  font-weight: 800;
  font-stretch: 125%;
  line-height: 0.95;
  letter-spacing: -0.03em;
}

h2 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.9rem);
  font-weight: 700;
  font-stretch: 115%;
  line-height: 1.06;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.section-eyebrow {
  display: block;
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  font-stretch: 110%;
  letter-spacing: 0.22em;
  line-height: 1.4;
  text-transform: uppercase;
  color: var(--ink-300);
}

.section-eyebrow::before {
  content: "";
  display: inline-block;
  width: 0.5em;
  height: 0.5em;
  background: var(--rouge);
  margin-right: 0.75em;
  vertical-align: 0.04em;
}

.section-lead {
  color: var(--ink-300);
  font-size: clamp(1.05rem, 1.4vw, 1.2rem);
  line-height: 1.6;
  max-width: 62ch;
}

/* ---------- Sections : rythme par le padding, plus par 100vh ---------- */

.section {
  position: relative;
  padding: var(--section-y) var(--gutter);
  scroll-margin-top: 88px;
  background: var(--veil-950);
}

.section--alt {
  background: var(--veil-900);
}

.section-content,
.case-study {
  position: relative;
  max-width: var(--measure);
  margin-inline: auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
}

@media (min-width: 900px) {
  .section-content,
  .case-study {
    grid-template-columns: var(--rail) minmax(0, 1fr);
    column-gap: var(--sp-7);
  }

  .section-content > .section-eyebrow,
  .case-study > .section-eyebrow {
    grid-column: 1;
    grid-row: 1;
    text-align: right;
    padding-top: 0.55em;
  }

  .section-content > *:not(.section-eyebrow),
  .case-study > *:not(.section-eyebrow) {
    grid-column: 2;
  }

  /* V3 — rail resserré : réservé à "friction" et "outils", les deux points
     de rupture de cette version. Le reste de la page garde le rail à
     190px, inchangé, pour que le resserrement se lise comme un choix
     local et non comme un nouveau standard global. */
  .section-content--tight,
  .case-study--tight {
    --rail: 132px;
  }
}

.section-content > .section-eyebrow,
.case-study > .section-eyebrow {
  margin-bottom: var(--sp-4);
}

/* =========================================================================
   V3 — Pull-quote éditorial (section "friction" uniquement)
   La seule rupture assumée de cette version : la citation d'origine sort du
   rail rail/contenu et occupe toute la mesure de section, en beaucoup plus
   grand. Remplace l'encart plein (--ink-800) par un simple filet rouge —
   le rouge reste rationné (un seul trait), mais gagne en présence.
   ========================================================================= */

.pull-quote {
  max-width: var(--measure);
  margin: var(--sp-8) auto;
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.pull-quote-label {
  display: block;
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  font-stretch: 110%;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-300);
  margin-bottom: var(--sp-5);
}

.pull-quote blockquote {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4.2vw, 3.1rem);
  font-weight: 600;
  font-stretch: 110%;
  line-height: 1.14;
  letter-spacing: -0.015em;
  color: var(--ink-050);
  max-width: 30ch;
  border-left: 3px solid var(--rouge);
  padding-left: var(--sp-6);
}

/* ---------- Header ---------- */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-5);
  padding: var(--sp-5) var(--gutter);
  background: linear-gradient(
    to bottom,
    rgb(14 12 12 / 0.94) 0%,
    rgb(14 12 12 / 0.82) 55%,
    rgb(14 12 12 / 0) 100%
  );
}

.logo {
  font-family: var(--font-display);
  font-weight: 700;
  font-stretch: 115%;
  font-size: 1.0625rem;
  letter-spacing: 0.26em;
  line-height: 1;
  color: var(--ink-050);
  text-transform: uppercase;
  white-space: nowrap;
}

.logo-dot {
  display: inline-block;
  width: 0.26em;
  height: 0.26em;
  background: var(--rouge);
  margin-left: 0.14em;
  vertical-align: 0.06em;
}

.logo--small {
  font-size: 0.875rem;
}

.logo--hero {
  display: block;
  font-size: clamp(1.5rem, 3.3vw, 2.75rem);
  margin-bottom: clamp(20px, 5vh, 56px);
}

.nav-shell {
  display: block;
}

.nav-shell > summary {
  display: none;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(var(--sp-4), 2.2vw, var(--sp-6));
}

.site-nav a {
  position: relative;
  color: var(--ink-300);
  text-decoration: none;
  font-size: 0.8125rem;
  letter-spacing: 0.04em;
  padding: var(--sp-1) 0;
  transition: color var(--dur) var(--ease-out);
}

.site-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: var(--rouge);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform var(--dur) var(--ease-out);
}

.site-nav a:hover {
  color: var(--ink-050);
}

.site-nav a:hover::after {
  transform: scaleX(1);
}

/* ---------- Accessibilité : lien d'évitement ---------- */
/* Invisible par défaut, ne déplace rien visuellement — apparaît seulement
   au clavier, pour sauter le header/nav avant le contenu principal. */

.skip-link {
  position: absolute;
  top: -100%;
  left: var(--gutter);
  z-index: 200;
  padding: var(--sp-3) var(--sp-5);
  background: var(--ink-050);
  color: var(--ink-950);
  font-family: var(--font-display);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-decoration: none;
  transition: top 0.2s var(--ease-out);
}

.skip-link:focus-visible {
  top: var(--sp-4);
}

/* ---------- Focus clavier ---------- */

:focus-visible {
  outline: 2px solid var(--ink-050);
  outline-offset: 3px;
}

.btn-cta:focus-visible {
  outline-color: var(--ink-050);
  outline-offset: 4px;
}

.contact-form input:focus-visible,
.contact-form textarea:focus-visible {
  outline-offset: 2px;
}

/* ---------- Boutons ---------- */

.btn-cta {
  display: inline-block;
  padding: var(--sp-4) var(--sp-6);
  font-family: var(--font-display);
  font-size: 0.8125rem;
  font-weight: 700;
  font-stretch: 112%;
  letter-spacing: 0.12em;
  line-height: 1;
  text-transform: uppercase;
  text-decoration: none;
  background: var(--ink-050);
  color: var(--ink-950);
  border: 1px solid var(--ink-050);
  cursor: pointer;
  transition: background var(--dur) var(--ease-out),
    color var(--dur) var(--ease-out), border-color var(--dur) var(--ease-out),
    transform 0.25s var(--ease-out);
}

.btn-cta:hover {
  background: transparent;
  color: var(--ink-050);
  border-color: var(--rouge);
}

.btn-cta--ghost {
  background: transparent;
  color: var(--ink-300);
  border-color: var(--ink-500);
}

.btn-cta--ghost:hover {
  background: transparent;
  color: var(--ink-050);
  border-color: var(--ink-050);
}

.hero-cta-group {
  display: flex;
  gap: var(--sp-4);
  flex-wrap: wrap;
  margin-top: var(--sp-7);
}

/* =========================================================================
   HERO — élément signature : les strates de friction (inchangé). Le pin
   GSAP (main.js) anime hero-content en JS (opacity/transform inline),
   aucune règle CSS supplémentaire requise ici.
   ========================================================================= */

.section--hero {
  /* V3 — voile allégé (0.32 au lieu du 0.58 des autres sections) : le hero
     n'a pas de bloc de texte dense à protéger, donc le nuage de particules
     peut se montrer davantage ici, là où sa première impression compte. */
  background: rgb(14 12 12 / 0.32);
  min-height: 100svh;
  display: flex;
  align-items: stretch;
  padding-top: clamp(96px, 12vh, 136px);
  padding-bottom: clamp(72px, 9vh, 112px);
  overflow: hidden;
}

.section--hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    120% 90% at 18% 8%,
    var(--ink-800) 0%,
    transparent 62%
  );
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: var(--measure);
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  flex: 1;
}

.hero-title {
  position: relative;
  max-width: 18ch;
  margin-top: auto;
}

.hero-title:has(.hero-strata) {
  max-width: 10ch;
}

.hero-strata {
  position: absolute;
  inset: 0;
  pointer-events: none;
  user-select: none;
}

.stratum {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  color: var(--rouge-oxyde);
  opacity: 0;
  transform: translate3d(
    calc(var(--i) * -0.15em),
    calc(var(--i) * 0.028em),
    0
  );
}

.hero-line {
  position: relative;
  display: block;
}

.hero-line .tp {
  color: var(--rouge);
  display: inline-block;
}

.hero-subtitle {
  margin-top: var(--sp-6);
  max-width: 54ch;
  color: var(--ink-300);
  font-size: clamp(1.05rem, 1.4vw, 1.2rem);
  line-height: 1.6;
}

.scroll-cue {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  margin-top: auto;
  padding-top: var(--sp-9);
  font-family: var(--font-display);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--ink-300);
}

.scroll-line {
  display: block;
  width: clamp(48px, 8vw, 96px);
  height: 1px;
  background: var(--ink-500);
}

.scroll-cue::after {
  content: "";
  width: 5px;
  height: 5px;
  background: var(--rouge);
  flex-shrink: 0;
  margin-left: calc(var(--sp-3) * -1 + 2px);
}

/* ---------- Le moment orchestré du hero (inchangé) ---------- */

@keyframes stratum-collapse {
  0% {
    opacity: 0;
    transform: translate3d(
      calc(var(--i) * -0.15em),
      calc(var(--i) * 0.028em),
      0
    );
  }
  22% {
    opacity: var(--o);
  }
  100% {
    opacity: 0;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes line-settle {
  from {
    opacity: 0;
    transform: translate3d(0, 0.14em, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes dot-land {
  0% {
    opacity: 0;
    transform: translate3d(0, -0.5em, 0) scale(0.7);
  }
  100% {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
}

@keyframes soft-rise {
  from {
    opacity: 0;
    transform: translate3d(0, 14px, 0);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.js .stratum {
  animation: stratum-collapse 1.05s var(--ease-out) both;
  animation-delay: var(--d);
}

.js .hero-line {
  animation: line-settle 0.9s var(--ease-out) 0.24s both;
}

.js .hero-line .tp {
  animation: dot-land 0.5s var(--ease-snap) 1.02s both;
}

.js .hero-subtitle,
.js .hero-cta-group,
.js .scroll-cue {
  animation: soft-rise 0.7s var(--ease-out) both;
}

.js .hero-subtitle {
  animation-delay: 0.86s;
}

.js .hero-cta-group {
  animation-delay: 0.98s;
}

.js .scroll-cue {
  animation-delay: 1.12s;
}

.js .logo--hero {
  animation: soft-rise 0.6s var(--ease-out) 0.02s both;
}

@keyframes cue-breathe {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.45;
    transform: scale(0.72);
  }
}

.js .scroll-cue::after {
  animation: cue-breathe 2.4s ease-in-out 1.6s infinite;
}

/* ---------- Révélations au scroll : discrètes, jamais spectaculaires ---------- */
/* V3 — pilotées par GSAP ScrollTrigger (main.js) plutôt que par
   IntersectionObserver : un seul système de choreographie au lieu de deux
   qui se chevauchent. Le rendu CSS final (état "is-in") reste identique. */

.js-reveal .reveal {
  opacity: 0;
  transform: translate3d(0, 16px, 0);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
  transition-delay: calc(var(--i, 0) * 70ms);
}

.js-reveal .reveal.is-in {
  opacity: 1;
  transform: none;
}

/* ---------- Titres de section : rideau mot par mot ---------- */

.word-mask {
  display: inline-block;
  overflow: hidden;
  vertical-align: top;
}

.word-inner {
  display: inline-block;
  transform: translate3d(0, 110%, 0);
  transition: transform 0.65s var(--ease-out);
  transition-delay: calc(var(--w, 0) * 55ms);
}

h2.is-in .word-inner {
  transform: none;
}

/* =========================================================================
   SECTION — Qu'est-ce qu'une friction ?
   ========================================================================= */

.section--friction h2 {
  max-width: 22ch;
}

.section--friction .section-lead {
  margin-top: var(--sp-5);
}

.friction-icons {
  display: flex;
  align-items: center;
  gap: clamp(var(--sp-2), 1.4vw, var(--sp-4));
  flex-wrap: wrap;
  margin-top: var(--sp-8);
  margin-bottom: var(--sp-8);
}

.friction-icon-wrap {
  position: relative;
  width: 68px;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: var(--ink-800);
  transition: opacity 0.5s var(--ease-out);
}

.friction-icon-wrap svg {
  width: 30px;
  height: 30px;
  stroke: var(--ink-300);
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.friction-strike {
  position: absolute;
  left: 10px;
  right: 10px;
  top: 50%;
  height: 3px;
  background: var(--rouge);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.42s var(--ease-out);
  transition-delay: calc(var(--i, 0) * 130ms);
}

.friction-icons.is-in .friction-strike {
  transform: scaleX(1);
}

.friction-icons.is-in .friction-icon-wrap {
  opacity: 0.34;
  transition-delay: 0.72s;
}

.friction-arrow {
  color: var(--ink-500);
  font-size: 1.1rem;
  line-height: 1;
  flex-shrink: 0;
}

.friction-check {
  width: 68px;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  opacity: 0;
  transform: scale(0.72);
  transition: opacity 0.45s var(--ease-out), transform 0.45s var(--ease-snap);
  transition-delay: 0.78s;
}

.friction-icons.is-in .friction-check {
  opacity: 1;
  transform: scale(1);
}

.friction-check svg {
  width: 30px;
  height: 30px;
  stroke: var(--rouge);
  fill: none;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.friction-conclusion {
  margin-top: var(--sp-6);
}

/* =========================================================================
   SECTION — Le Manifeste
   ========================================================================= */

/* Panneau de lisibilité : approuvé par le client en prévisualisation live,
   puis étendu à la clôture de #friction (même défaut de contraste
   constaté là aussi). --veil-950 réutilisé plutôt que rgba(8,8,10,.55) —
   même teinte, même usage (glass panel sur la scène 3D), déjà défini
   dans :root. --sp-6 réutilisé pour la moitié verticale du padding
   (32px = 2rem exact) ; 2.5rem gardé littéral, aucun token ne correspond
   à 40px. border-radius n'a pas d'équivalent existant : c'est le premier
   angle arrondi de tout le site, jusqu'ici entièrement à angles droits —
   signalé au client. Le sélecteur :has() cible précisément le second
   bloc .section-content--tight de #friction (celui qui contient les
   paragraphes de clôture), pas le premier (eyebrow + h2 + icônes, déjà
   lisible sans panneau). */
#manifeste .section-content,
#friction .section-content--tight:has(.friction-conclusion) {
  background: var(--veil-950);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 16px;
  padding: var(--sp-6) 2.5rem;
}

.section--problem .section-lead {
  margin-top: var(--sp-5);
}

.pain-points {
  list-style: none;
  margin-top: var(--sp-7);
  display: grid;
  gap: var(--sp-1);
  max-width: 64ch;
}

.pain-points li {
  position: relative;
  padding: var(--sp-4) var(--sp-4) var(--sp-4) var(--sp-7);
  color: var(--ink-300);
  font-size: 1.0625rem;
  background: transparent;
  transition: background var(--dur) var(--ease-out),
    color var(--dur) var(--ease-out);
}

.pain-points li::before {
  content: "";
  position: absolute;
  left: var(--sp-4);
  top: 1.55em;
  width: 10px;
  height: 2px;
  background: var(--rouge);
  transition: width var(--dur) var(--ease-out),
    background var(--dur) var(--ease-out);
}

.pain-points li:hover {
  background: var(--ink-800);
  color: var(--ink-050);
}

.pain-points li:hover::before {
  width: 20px;
}

.manifesto-conclusion {
  margin-top: var(--sp-7);
  color: var(--ink-050);
  font-size: clamp(1.1rem, 1.6vw, 1.3rem);
  max-width: 52ch;
}

/* Le bouton ajouté après la conclusion n'avait ni espacement propre (0px
   mesuré, collé au paragraphe) ni largeur contenue : sans justify-self,
   un enfant de grille s'étire par défaut sur toute la colonne — d'où le
   bouton pleine largeur signalé par le client. #audit définissait déjà
   les deux propriétés pour son propre bouton de clôture ; même valeurs
   ici, pour rester cohérent avec ce pattern plutôt que d'en inventer un. */
#manifeste .btn-cta {
  justify-self: start;
  margin-top: var(--sp-8);
}

/* =========================================================================
   SECTION — L'Arsenal (Pointeuse Pizzamilia)
   V3 — .section--resolved : une lueur rouge très rationnée apparaît en fond
   (échoant le cœur incandescent du nuage de particules qui vient de se
   cristalliser), pilotée par la classe .is-resolved que scene3d.js pose
   quand sa propre progression franchit le seuil.
   ========================================================================= */

.section--resolved {
  position: relative;
}

.section--resolved::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  background: radial-gradient(
    60% 50% at 50% 0%,
    var(--rouge-oxyde) 0%,
    transparent 70%
  );
  transition: opacity 1.4s var(--ease-out);
}

.section--resolved.is-resolved::after {
  opacity: 0.1;
}

.case-study-intro {
  margin-top: var(--sp-5);
  color: var(--ink-300);
  font-size: clamp(1.05rem, 1.4vw, 1.2rem);
  line-height: 1.6;
  max-width: 56ch;
}

.case-study-specs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  margin-top: var(--sp-8);
  background: var(--ink-700);
}

.case-study-specs > div {
  padding: clamp(var(--sp-5), 2.4vw, var(--sp-6));
  background: var(--ink-950);
  transition: background var(--dur) var(--ease-out);
}

.section--alt .case-study-specs > div {
  background: var(--ink-900);
}

.case-study-specs > div:hover {
  background: var(--ink-800);
}

.case-study-specs dt {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  font-stretch: 110%;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-300);
  margin-bottom: var(--sp-3);
}

.case-study-specs:not(.audit-steps) dt::before {
  content: "";
  display: inline-block;
  width: 0.45em;
  height: 0.45em;
  background: var(--rouge);
  margin-right: 0.7em;
  vertical-align: 0.06em;
}

.case-study-specs dd {
  color: var(--ink-050);
  font-size: 1rem;
  line-height: 1.55;
}

/* =========================================================================
   SECTION — L'Audit (seule vraie séquence : la numérotation est légitime)
   ========================================================================= */

.section--audit .section-lead {
  margin-top: var(--sp-5);
}

.audit-steps {
  counter-reset: none;
}

.audit-steps dt {
  display: flex;
  align-items: baseline;
  gap: var(--sp-2);
  color: var(--ink-050);
  letter-spacing: 0.1em;
}

.step-num {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 800;
  font-stretch: 125%;
  letter-spacing: -0.02em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  display: inline-block;
  color: var(--ink-300);
  transition: color var(--dur) var(--ease-out);
}

.audit-steps > div:hover .step-num {
  color: var(--rouge);
}

.section--audit .btn-cta {
  justify-self: start;
  margin-top: var(--sp-8);
}

/* =========================================================================
   SECTION — Contact
   ========================================================================= */

.section--contact h2 {
  max-width: 18ch;
}

.contact-form {
  display: grid;
  gap: var(--sp-5);
  max-width: 520px;
  margin-top: var(--sp-8);
}

@media (min-width: 1040px) {
  .section--contact .section-content {
    grid-template-columns: var(--rail) minmax(0, 1fr) minmax(340px, 420px);
    column-gap: var(--sp-8);
    align-items: start;
  }

  .section--contact .section-content > h2 {
    grid-column: 2;
    max-width: none;
    font-size: clamp(1.5rem, 2.4vw, 2.1rem);
    line-height: 1.14;
  }

  .section--contact .section-content > .contact-form {
    grid-column: 3;
    grid-row: 1;
    margin-top: var(--sp-2);
    max-width: none;
  }
}

.field {
  display: grid;
  gap: var(--sp-2);
}

.field > label {
  font-family: var(--font-display);
  font-size: 0.6875rem;
  font-weight: 600;
  font-stretch: 110%;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-300);
}

.contact-form input,
.contact-form textarea {
  background: var(--ink-800);
  border: 1px solid var(--ink-500);
  color: var(--ink-050);
  font-family: var(--font-text);
  font-size: 1rem;
  line-height: 1.5;
  padding: var(--sp-3) var(--sp-4);
  resize: vertical;
  transition: border-color var(--dur) var(--ease-out),
    background var(--dur) var(--ease-out);
}

.contact-form input:hover,
.contact-form textarea:hover {
  border-color: var(--ink-300);
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--rouge);
  background: var(--ink-700);
}

.contact-form .btn-cta {
  justify-self: start;
  margin-top: var(--sp-2);
}

.contact-form .btn-cta:disabled {
  opacity: 0.55;
  cursor: default;
}

.form-feedback {
  font-size: 0.9375rem;
  line-height: 1.5;
  padding-left: var(--sp-4);
  border-left: 2px solid currentColor;
}

.form-feedback--success {
  color: #7cc196;
}

.form-feedback--error {
  color: var(--rouge);
}

/* =========================================================================
   Footer
   ========================================================================= */

.site-footer {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-5);
  flex-wrap: wrap;
  padding: var(--sp-8) var(--gutter);
  background: var(--veil-950);
  border-top: 1px solid var(--ink-700);
}

.site-footer::before {
  content: "";
  position: absolute;
  top: -1px;
  left: var(--gutter);
  width: 56px;
  height: 1px;
  background: var(--rouge);
}

.footer-tagline {
  display: flex;
  align-items: center;
  gap: var(--sp-5);
  flex-wrap: wrap;
}

.site-footer > p {
  color: var(--ink-300);
  font-size: 0.8125rem;
}

/* Texte en rouge plein sur fond sombre : ~4.3:1, sous le seuil AA (4.5:1)
   pour du texte courant. Même traitement que .section-eyebrow — le rouge
   reste un marqueur ponctuel (le point), pas la couleur du texte. */
.footer-manifesto {
  color: var(--ink-050);
  font-family: var(--font-display);
  font-size: 0.6875rem;
  font-weight: 600;
  font-stretch: 110%;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.footer-manifesto::before {
  content: "";
  display: inline-block;
  width: 0.5em;
  height: 0.5em;
  background: var(--rouge);
  margin-right: 0.75em;
  vertical-align: 0.04em;
}

/* =========================================================================
   Texture — grain seul, sans vignette
   ========================================================================= */

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 9998;
  pointer-events: none;
  opacity: 0.028;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='140' height='140'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}

/* =========================================================================
   Responsive
   ========================================================================= */

@media (max-width: 899px) {
  .section-content > .section-eyebrow,
  .case-study > .section-eyebrow {
    margin-bottom: var(--sp-3);
  }

  .pull-quote blockquote {
    max-width: none;
  }
}

@media (max-width: 768px) {
  :root {
    --section-y: clamp(72px, 9vh, 104px);
  }

  .site-header {
    align-items: flex-start;
    padding: var(--sp-4) var(--gutter);
  }

  .nav-shell > summary {
    display: flex;
    align-items: center;
    gap: var(--sp-2);
    list-style: none;
    cursor: pointer;
    padding: var(--sp-2) 0 var(--sp-2) var(--sp-3);
    font-family: var(--font-display);
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--ink-300);
  }

  .nav-shell > summary::-webkit-details-marker {
    display: none;
  }

  .nav-burger {
    display: block;
    position: relative;
    width: 18px;
    height: 2px;
    background: currentColor;
  }

  .nav-burger::before,
  .nav-burger::after {
    content: "";
    position: absolute;
    left: 0;
    width: 18px;
    height: 2px;
    background: currentColor;
  }

  .nav-burger::before {
    top: -6px;
  }

  .nav-burger::after {
    top: 6px;
  }

  .nav-shell[open] > summary {
    color: var(--ink-050);
  }

  .site-nav {
    position: absolute;
    top: calc(100% + var(--sp-2));
    right: 0;
    flex-direction: column;
    align-items: flex-end;
    gap: 0;
    padding: var(--sp-4) var(--sp-5);
    background: var(--color-bg-alt);
    border: 1px solid var(--color-rule);
    border-radius: 4px;
    box-shadow: 0 12px 32px rgb(0 0 0 / 0.4);
    min-width: 200px;
  }

  .site-nav a {
    /* sp-3 plutôt que sp-2 : sous 8px de padding, la cible tactile du menu
       mobile passait sous les 44px recommandés. */
    padding: var(--sp-3) 0;
    font-size: 0.875rem;
  }

  .section--hero {
    min-height: auto;
  }

  .scroll-cue {
    margin-top: var(--sp-8);
    padding-top: 0;
  }

  .friction-icons {
    gap: var(--sp-2);
    margin-top: var(--sp-7);
    margin-bottom: var(--sp-7);
  }

  .friction-icon-wrap,
  .friction-check {
    width: 48px;
    height: 48px;
  }

  .case-study-specs {
    grid-template-columns: minmax(0, 1fr);
  }

  .pull-quote {
    margin: var(--sp-7) auto;
  }

  .pull-quote blockquote {
    padding-left: var(--sp-5);
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 420px) {
  .friction-icon-wrap,
  .friction-check {
    width: 40px;
    height: 40px;
  }

  .friction-icon-wrap svg {
    width: 20px;
    height: 20px;
  }

  .hero-cta-group .btn-cta {
    width: 100%;
    text-align: center;
  }
}

/* =========================================================================
   prefers-reduced-motion : état final, sans mouvement.
   ========================================================================= */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-delay: 0ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    transition-delay: 0ms !important;
  }

  .js .stratum {
    animation: none;
    opacity: calc(var(--o) * 0.55);
  }

  .js .hero-line,
  .js .hero-line .tp,
  .js .hero-subtitle,
  .js .hero-cta-group,
  .js .scroll-cue {
    animation: none;
    opacity: 1;
    transform: none;
  }

  .js-reveal .reveal {
    opacity: 1;
    transform: none;
  }

  .friction-strike {
    transform: scaleX(1);
  }

  .friction-check {
    opacity: 1;
    transform: none;
  }

  .friction-icon-wrap {
    opacity: 0.34;
  }

  .section--resolved.is-resolved::after {
    opacity: 0.1;
  }
}
