/*
 * alpha & omédia · site.css
 * DA fondation CLAIRE · version 2026-06-23 rebrand alpha-omédia
 * Territoire : Corporate cinematique clair · fond blanc casse, dominante carmin, accent orange brule
 * Reference DA : brand board V2 alpha-omédia
 * Stack : PHP + CDN + CSS vanilla · ZERO build/npm/framework
 * Polices : Hanken Grotesk (titres 600/700/800 display) + Inter (corps) Google Fonts CDN
 * --------------------------------------------------------
 * IMPORT dans chaque public/*.php :
 *   <link rel="preconnect" href="https://fonts.googleapis.com">
 *   <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
 *   <link href="https://fonts.googleapis.com/css2?family=Hanken+Grotesk:wght@600;700;800;900&family=Inter:wght@300;400;500&display=swap" rel="stylesheet">
 *   <link rel="stylesheet" href="/assets/site.css">
 *   <link rel="stylesheet" href="/assets/identity.css">
 */

/* ================================================================
   1. TOKENS :root · Yanaweb sur fond CLAIR
   Tokens canoniques transmis par Nicolas (a utiliser tels quels).
   Les autres sheets consomment via var() sans redefinir.
   ================================================================ */

:root {
  /* --- Fond et surfaces (brand board V2 alpha-omédia) --- */
  --bg: #f2f2f0; /* blanc casse, fond principal */
  --bg-alt: #e9e9e7; /* blanc casse soutenu, sections alternees */

  /* --- Encre (noir graphique brand board) --- */
  --ink: #111111; /* noir graphique titres/corps fort */
  --ink-2: oklch(0.38 0.008 250); /* encre secondaire */

  /* --- Couleurs marque alpha-omédia --- */
  --carmin: #8b0628; /* carmin : couleur de BASE, dominante marque */
  --carmin-l: oklch(
    0.75 0.14 10
  ); /* carmin clair : sur fond sombre (ex-terra-l) */
  --carmin-d: oklch(0.28 0.16 10); /* carmin sombre : hover CTA */
  --carmin-bg: oklch(
    0.97 0.018 10
  ); /* teinté carmin leger : badge, fond highlight */
  --carmin-border: oklch(0.82 0.09 10); /* bordure teintee carmin */

  --orange: #ff6b1a; /* orange brule : ACCENT (CTA, hover, highlights) */
  --orange-l: oklch(0.8 0.13 45); /* orange clair : variante douce */
  --orange-d: oklch(0.5 0.18 40); /* orange sombre : hover accent */
  --orange-bg: oklch(0.97 0.022 55); /* teinté orange leger */
  --orange-border: oklch(0.85 0.1 50); /* bordure teintee orange */

  /* Aliases semantiques (les composants utilisent --terra/* pour la couleur marque
     et --accent/* pour le punch interactif) */
  --terra: var(--carmin);
  --terra-l: var(--orange);
  --terra-d: var(--carmin-d);
  --terra-bg: var(--carmin-bg);
  --terra-border: var(--carmin-border);
  /* teal supprime : remonte sur carmin */
  --teal: var(--carmin);
  --teal-l: var(--carmin-l);

  /* --- Filets / bordures --- */
  --line: oklch(0.9 0.004 60);

  /* --- Tokens complementaires (computed) --- */
  --ink-3: #5f6368; /* muted : legendes, labels (RGAA 3.2 : 4.98:1 sur --bg-alt, etait oklch 0.6 = 3.25:1) */
  --ink-4: #62666b; /* tres muted : placeholders, petits textes (RGAA 3.2 : 4.76:1 sur --bg-alt, etait oklch 0.74 = 2.05:1) */
  --accent-text: #ad3f0e; /* orange brule fonce : orange en TEXTE sur fond clair (RGAA 3.2 : 4.94:1), l'orange vif reste pour les fonds et le sombre */
  --ink-inv: oklch(0.96 0.003 60); /* texte sur fond sombre */
  --ink-inv-2: oklch(0.72 0.006 240); /* secondaire sur fond sombre */
  --bg-dark: #111111; /* footer / blocs sombres (noir graphique) */
  --bg-card: #ffffff; /* cartes : blanc pur */
  --line-m: oklch(0.83 0.006 60); /* bordures cartes */
  --line-dark: oklch(0.22 0.008 250); /* hairline sur fond sombre */

  /* Alias --accent -> orange brule (CTA, punch interactif) */
  --accent: var(--orange);
  --accent-bg: var(--orange-bg);
  --accent-border: var(--orange-border);

  /* Alias --r-md : entre --r et --r-lg (20px) */
  --r-md: 20px;

  /* Ombres douces */
  --shadow-xs: 0 1px 3px oklch(0.11 0.006 250 / 0.06);
  --shadow-sm: 0 2px 8px oklch(0.11 0.006 250 / 0.08);
  --shadow-md: 0 6px 24px oklch(0.11 0.006 250 / 0.1);
  --shadow-lg: 0 16px 48px oklch(0.11 0.006 250 / 0.12);
  --shadow-card:
    0 2px 12px oklch(0.11 0.006 250 / 0.07),
    0 1px 3px oklch(0.11 0.006 250 / 0.05);

  /* --- Typographie --- */
  --ff-title:
    "Hanken Grotesk", "Arial Black", sans-serif; /* titrage : humaniste geometrique, proche Agenda */
  --ff-body: "Inter", "Arial", sans-serif; /* corps 300/400/500 */

  /* Echelle (clamp mobile -> desktop) */
  --t-display: clamp(44px, 6vw, 88px);
  --t-h1: clamp(34px, 4.5vw, 64px);
  --t-h2: clamp(28px, 3.2vw, 48px);
  --t-h3: clamp(20px, 2.2vw, 30px);
  --t-h4: clamp(16px, 1.4vw, 20px);
  --t-body: clamp(15px, 1vw, 17px);
  --t-small: 14px;
  --t-label: 12px;
  --t-micro: 11px;

  /* --- Layout --- */
  --pad-x: clamp(20px, 6vw, 100px);
  --max-w: 1200px;
  --nav-h: 72px;

  /* --- Radius Yanaweb (DA arrondie generreuse) --- */
  --r-none: 0px;
  --r-xs: 4px; /* reserve : micro-details */
  --r-sm: 10px; /* petits elements */
  --r: 16px; /* elements standards */
  --r-lg: 24px; /* cartes, encarts, panneaux */
  --r-xl: 32px; /* hero visuels, grandes sections */
  --r-pill: 999px; /* boutons, chips, nav, badges, inputs */

  /* --- Transitions 300ms (facon yalp) --- */
  --ease: cubic-bezier(0.25, 0.1, 0.25, 1);
  --ease-out: cubic-bezier(0, 0, 0.2, 1);
  --dur: 0.3s;

  /* --- Z-index --- */
  --z-nav: 100;
  --z-modal: 200;
  --z-toast: 300;
}

/* ================================================================
   2. RESET DOUX
   ================================================================ */

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

html {
  scroll-behavior: auto; /* Lenis gere le smooth vertical ; 'smooth' ici se battait avec Lenis et figeait le scroll */
  scroll-padding-top: var(--nav-h);
  -webkit-text-size-adjust: 100%;
}

/* ── Lenis (smooth scroll JS) : neutraliser les conflits qui bloquent le scroll ── */
html.lenis,
html.lenis body {
  height: auto;
}
.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}
.lenis.lenis-stopped {
  overflow: hidden;
}
/* Les iframes (carrousel video du hero) ne doivent pas capter la molette */
.lenis.lenis-smooth iframe {
  pointer-events: none;
}
/* Le fond video du hero est decoratif : la molette/le clic passent a travers (le contenu .hero-copy reste cliquable) */
.hero-visual,
.hero-visual * {
  pointer-events: none;
}

body {
  font-family: var(--ff-body);
  font-size: var(--t-body);
  font-weight: 400;
  line-height: 1.7;
  color: var(--ink-2);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}

img,
video,
svg {
  display: block;
  max-width: 100%;
}
a {
  color: inherit;
  text-decoration: none;
}
ul,
ol {
  list-style: none;
}
button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}
input,
textarea,
select {
  font-family: inherit;
  font-size: inherit;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html {
    scroll-behavior: auto;
  }
}

/* ================================================================
   3. CONTENEUR
   ================================================================ */

.container {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--pad-x);
}

.container--narrow {
  /* Meme boite que .container : le bord gauche s'aligne sur les autres sections.
     La largeur de lecture est limitee sur le contenu (aligne a gauche, pas centre). */
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--pad-x);
}
.container--narrow > * {
  max-width: 780px;
}

/* ================================================================
   4. TYPOGRAPHIE EDITORIALE
   ================================================================ */

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--ff-title);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--ink);
}

h1 {
  font-size: var(--t-h1);
}
h2 {
  font-size: var(--t-h2);
}
h3 {
  font-size: var(--t-h3);
  font-weight: 700;
}
h4 {
  font-size: var(--t-h4);
  font-weight: 700;
}

/* Eyebrow : label uppercase avant un titre, accent terra */
.eyebrow {
  font-family: var(--ff-body);
  font-size: var(--t-label);
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--terra);
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}

.eyebrow::before {
  content: "";
  display: block;
  width: 20px;
  height: 2px;
  background: var(--terra);
  flex-shrink: 0;
}

p {
  margin-bottom: 1em;
}
p:last-child {
  margin-bottom: 0;
}

.lead {
  font-size: var(--t-h4);
  font-weight: 300;
  color: var(--ink-2);
  line-height: 1.65;
}

strong {
  font-weight: 700;
  color: var(--ink);
}

/* ================================================================
   5. SECTIONS · RYTHME VERTICAL (facon yalp 72-96px)
   ================================================================ */

.section {
  padding-block: clamp(72px, 10vw, 120px);
}

.section--sm {
  padding-block: clamp(48px, 6vw, 80px);
}

.section--lg {
  padding-block: clamp(96px, 12vw, 160px);
}

/* Fond alternatif creme soutenu */
.section--alt {
  background: var(--bg-alt);
}

/* Fond sombre : footer, manifeste, CTA final */
.section--dark {
  background: var(--bg-dark);
  color: var(--ink-inv);
  position: relative;
}
.section--dark::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(
      180deg,
      var(--bg-dark) 0%,
      rgba(0, 0, 0, 0) 40%,
      rgba(0, 0, 0, 0) 60%,
      var(--bg-dark) 100%
    ),
    url("/assets/logo/picto-white.svg");
  background-size: 200%;
  background-position: 100% center;
  background-repeat: no-repeat;
  opacity: 0.06;
}
.section--dark > * {
  position: relative;
  z-index: 1;
}
.section--dark h1,
.section--dark h2,
.section--dark h3,
.section--dark h4 {
  color: var(--ink-inv);
}

.section--dark .eyebrow {
  color: var(--terra-l);
}

.section--dark .eyebrow::before {
  background: var(--terra-l);
}

/* En-tete de section */
.sec-header {
  margin-bottom: clamp(48px, 6vw, 72px);
}

.sec-header--center {
  text-align: center;
}

.sec-header--center .eyebrow {
  justify-content: center;
}

.sec-header--center .eyebrow::before {
  display: none;
}

/* ================================================================
   6. NAV · fond creme par defaut + variante nav-over-hero (toutes pages)
   .nav-over-hero : nav fixed transparent sur hero sombre -> creme au scroll.
   Mecanique identique home et pages contenu.
   ================================================================ */

.site-nav {
  position: sticky;
  top: 0;
  z-index: var(--z-nav);
  height: var(--nav-h);
  /* Par defaut : fond blanc casse solide (etat scrolle ou sans hero) */
  background: oklch(0.95 0.003 60 / 0.96);
  backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  transition:
    background var(--dur) var(--ease),
    border-color var(--dur) var(--ease),
    box-shadow var(--dur) var(--ease);
}

/* ── nav-over-hero : fixed, transparent, flotte sur le hero sombre ── */
.site-nav.nav-over-hero {
  position: fixed;
  width: 100%;
}

/* Etat initial : transparent, sans fond ni bordure */
.site-nav.nav-over-hero:not(.scrolled) {
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-bottom-color: transparent;
  box-shadow: none;
}

/* Liens clairs sur le hero sombre */
.site-nav.nav-over-hero:not(.scrolled) .nav-list a {
  color: oklch(0.88 0.008 70);
}

.site-nav.nav-over-hero:not(.scrolled) .nav-list a:hover,
.site-nav.nav-over-hero:not(.scrolled) .nav-list a[aria-current="page"] {
  color: oklch(0.99 0.004 70);
}

/* Burger clair sur le hero sombre */
.site-nav.nav-over-hero:not(.scrolled) .nav-burger span {
  background: oklch(0.92 0.005 70);
}

/* Swap logos : inv visible au depart, def cache */
.site-nav.nav-over-hero .nav-logo__def {
  display: none;
}
.site-nav.nav-over-hero .nav-logo__inv {
  display: block;
}

/* Etat scrolle : fond blanc casse solide */
.site-nav.nav-over-hero.scrolled {
  background: oklch(0.95 0.003 60 / 0.97);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border-bottom-color: var(--line);
  box-shadow: var(--shadow-xs);
}

/* Swap logos apres scroll */
.site-nav.nav-over-hero.scrolled .nav-logo__inv {
  display: none;
}
.site-nav.nav-over-hero.scrolled .nav-logo__def {
  display: block;
}

/* Liens sombres quand scrolle */
.site-nav.nav-over-hero.scrolled .nav-list a {
  color: var(--ink-2);
}
.site-nav.nav-over-hero.scrolled .nav-list a:hover,
.site-nav.nav-over-hero.scrolled .nav-list a[aria-current="page"] {
  color: var(--ink);
}

/* Burger sombre quand scrolle */
.site-nav.nav-over-hero.scrolled .nav-burger span {
  background: var(--ink-2);
}

/* ── page-hero des pages contenu : remonte sous le nav fixed ── */
/* Identique au #hero de la home : margin-top negatif + padding compense */
.page-hero {
  margin-top: calc(-1 * var(--nav-h));
  padding-top: calc(clamp(72px, 10vw, 110px) + var(--nav-h));
  /* padding-bottom : le texte du hero ne doit pas coller le bas de la bande sombre (etait absent -> texte colle) */
  padding-bottom: clamp(56px, 7vw, 96px);
  /* Le contenu est dans un .container interne qui gere deja --pad-x.
     On annule le padding-inline inline du <header><meta charset="utf-8"> -> plus de double padding,
     le hero s'aligne sur le bord gauche des sections en dessous. */
  padding-inline: 0 !important;
}

.site-nav .container {
  display: flex;
  align-items: center;
  gap: 24px;
  /* Aligne le nav sur les bords du hero (meme marge laterale que #hero) */
  max-width: none;
  padding-inline: clamp(16px, 2.5vw, 32px);
}

/* Logo image */
.nav-logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  text-decoration: none;
}

.nav-logo img {
  height: 30px; /* ratio 7.44:1 : ~224px de large a 30px de haut */
  width: auto;
  display: block;
  transition: opacity var(--dur) var(--ease);
}

@media (max-width: 600px) {
  .nav-logo img {
    height: 24px; /* mobile : ~179px de large, tient dans le nav burger */
  }
}

/* Liens nav : sombres par defaut */
.nav-list {
  display: flex;
  flex: 1;
  align-items: center;
  justify-content: center;
  gap: clamp(20px, 2.5vw, 36px);
  list-style: none;
}

.nav-list a {
  font-family: var(--ff-body);
  font-size: var(--t-small);
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--ink-2);
  text-decoration: none;
  position: relative;
  padding-bottom: 2px;
  transition: color var(--dur) var(--ease);
}

.nav-list a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background: var(--terra);
  transition: width var(--dur) var(--ease);
}

.nav-list a:hover,
.nav-list a[aria-current="page"] {
  color: var(--ink);
}

.nav-list a:hover::after,
.nav-list a[aria-current="page"]::after {
  width: 100%;
}

/* CTA nav terra */
.nav-cta {
  font-family: var(--ff-body);
  font-size: var(--t-small);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--bg) !important;
  background: var(--terra);
  padding: 11px 26px;
  border-radius: var(--r-pill);
  flex-shrink: 0;
  text-decoration: none;
  transition:
    background var(--dur) var(--ease),
    transform var(--dur) var(--ease);
  white-space: nowrap;
}

.nav-cta::after {
  display: none !important;
}

.nav-cta:hover {
  background: var(--terra-d);
  transform: translateY(-1px);
}

/* Burger mobile : sombre par defaut */
.nav-burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  min-width: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
}

.nav-burger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--ink-2);
  transition:
    all 0.25s var(--ease),
    background var(--dur) var(--ease);
}

.nav-burger.open span:nth-child(1) {
  transform: rotate(45deg) translate(4.5px, 4.5px);
}
.nav-burger.open span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}
.nav-burger.open span:nth-child(3) {
  transform: rotate(-45deg) translate(4.5px, -4.5px);
}

@media (max-width: 768px) {
  .nav-list {
    display: none;
    position: fixed;
    top: var(--nav-h);
    left: 0;
    right: 0;
    /* Dropdown mobile : blanc casse solide dans tous les cas */
    background: oklch(0.95 0.003 60 / 0.98);
    backdrop-filter: blur(14px) saturate(1.2);
    -webkit-backdrop-filter: blur(14px) saturate(1.2);
    border-bottom: 1px solid var(--line);
    padding: 20px var(--pad-x) 28px;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    box-shadow: var(--shadow-md);
    border-radius: 0 0 var(--r-lg) var(--r-lg);
  }
  .nav-list.open {
    display: flex;
  }
  /* Liens du menu mobile : sombres */
  .nav-list a {
    font-size: 16px;
    padding: 10px 0;
    width: 100%;
    color: var(--ink-2);
  }
  .nav-list a:hover,
  .nav-list a[aria-current="page"] {
    color: var(--ink);
  }
  .nav-list a::after {
    bottom: 0;
  }
  .nav-cta {
    margin-left: auto;
    margin-right: 4px;
    padding: 8px 15px;
    font-size: 11px;
  }
  .nav-burger {
    display: flex;
  }
}

/* Menu mobile ouvert : le nav passe en SOLIDE sombre (sinon le nav transparent laisse voir le menu derriere = superposition du header) */
.site-nav:has(.nav-burger.open) {
  background: oklch(0.13 0.01 250 / 0.98) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  border-bottom-color: transparent !important;
}
.site-nav:has(.nav-burger.open) .nav-logo__def {
  display: none !important;
}
.site-nav:has(.nav-burger.open) .nav-logo__inv {
  display: block !important;
}
.site-nav:has(.nav-burger.open) .nav-list a {
  color: oklch(0.92 0.005 70) !important;
}
.site-nav:has(.nav-burger.open) .nav-burger span {
  background: oklch(0.92 0.005 70) !important;
}

/* ── OVERLAY MENU MOBILE ──────────────────────────────────────────── */
#mobileMenu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: calc(var(--z-nav) - 1);
  background: oklch(0.13 0.01 250 / 0.97);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  overflow-y: auto;
  padding: var(--nav-h) 0 48px;
}

#mobileMenu.open {
  display: flex;
  align-items: center;
  justify-content: center;
  animation: menuFadeIn 0.22s var(--ease) both;
}

@keyframes menuFadeIn {
  from {
    opacity: 0;
    transform: translateY(-12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.mobile-menu__inner {
  width: 100%;
  max-width: 420px;
  padding: clamp(32px, 8vw, 64px) clamp(24px, 6vw, 48px);
  display: flex;
  flex-direction: column;
  gap: 40px;
  align-items: flex-start;
}

.mobile-menu__links {
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 100%;
}

.mobile-menu__links a {
  font-family: var(--ff-title);
  font-size: clamp(28px, 8vw, 48px);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: oklch(0.88 0.008 70);
  text-decoration: none;
  padding: 10px 0;
  border-bottom: 1px solid oklch(1 0 0 / 0.08);
  display: block;
  transition:
    color 0.2s var(--ease),
    padding-left 0.2s var(--ease);
}

.mobile-menu__links a:last-child {
  border-bottom: none;
}

.mobile-menu__links a:hover,
.mobile-menu__links a:focus {
  color: var(--terra-l);
  padding-left: 8px;
  outline: none;
}

.mobile-menu__cta {
  display: inline-flex;
  align-items: center;
  font-family: var(--ff-body);
  font-size: var(--t-small);
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: oklch(0.13 0.01 250);
  background: var(--terra-l);
  padding: 14px 32px;
  border-radius: var(--r-pill);
  text-decoration: none;
  transition:
    background 0.2s var(--ease),
    transform 0.2s var(--ease);
}

.mobile-menu__cta:hover {
  background: var(--terra);
  color: #fff;
  transform: translateY(-1px);
}

@media (min-width: 769px) {
  #mobileMenu {
    display: none !important;
  }
}

/* ================================================================
   7. BOUTONS · terra primaire, teal secondaire
   ================================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--ff-body);
  font-size: var(--t-small);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  border: none;
  cursor: pointer;
  border-radius: var(--r-pill);
  padding: 14px 32px;
  min-height: 48px;
  transition:
    background var(--dur) var(--ease),
    color var(--dur) var(--ease),
    border-color var(--dur) var(--ease),
    box-shadow var(--dur) var(--ease),
    transform var(--dur) var(--ease);
  white-space: nowrap;
}

.btn:hover {
  transform: translateY(-1px);
}
.btn:active {
  transform: translateY(0);
}

/* Primaire : fond carmin (terra / couleur marque) ; texte --bg (blanc casse) : contraste WCAG AA */
.btn--primary {
  background: var(--terra);
  color: var(--bg);
  box-shadow: 0 2px 16px oklch(0.35 0.16 10 / 0.3);
}

.btn--primary:hover {
  background: var(--terra-d);
  box-shadow: 0 4px 24px oklch(0.35 0.16 10 / 0.38);
}

/* Secondaire : contour encre */
.btn--outline {
  background: transparent;
  color: var(--ink);
  border: 1.5px solid var(--line-m);
}

.btn--outline:hover {
  border-color: var(--ink);
  background: oklch(0.18 0.012 250 / 0.04);
}

/* Ghost : contour terra */
.btn--ghost {
  background: transparent;
  color: var(--terra);
  border: 1.5px solid var(--terra-border);
}

.btn--ghost:hover {
  background: var(--terra-bg);
  border-color: var(--terra);
}

/* Variante outline sur fond sombre (FAQ cta-block, cta-final) */
.btn--outline-inv {
  border-color: oklch(0.35 0.01 250);
  color: var(--ink-inv);
}

.btn--outline-inv:hover {
  border-color: oklch(0.55 0.01 250);
  background: oklch(1 0 0 / 0.06);
  color: var(--ink-inv);
}

/* Lien texte fleche */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--ff-body);
  font-size: var(--t-small);
  font-weight: 600;
  color: var(--terra);
  text-decoration: none;
  letter-spacing: 0.04em;
  transition: gap var(--dur) var(--ease);
}

.link-arrow:hover {
  gap: 10px;
}

/* ================================================================
   8. CARTES COVER (composant identity.css etend ce systeme)
   Poster-card : vignette 16/9 avec corps sous l'image
   ================================================================ */

.poster-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition:
    box-shadow var(--dur) var(--ease),
    border-color var(--dur) var(--ease),
    transform var(--dur) var(--ease);
  box-shadow: var(--shadow-card);
}

.poster-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--line-m);
  transform: translateY(-2px);
}

.poster-card__img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
  transition: opacity var(--dur) var(--ease);
}

.poster-card:hover .poster-card__img {
  opacity: 0.92;
}

.poster-card__placeholder {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-alt);
  color: var(--ink-4);
}

.poster-card__placeholder svg {
  width: 32px;
  height: 32px;
  opacity: 0.4;
}

.poster-card__body {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  flex: 1;
}

.poster-card__cat {
  font-family: var(--ff-body);
  font-size: var(--t-micro);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--terra);
}

.poster-card__title {
  font-family: var(--ff-title);
  font-size: var(--t-small);
  font-weight: 700;
  color: var(--ink);
  line-height: 1.3;
  letter-spacing: -0.01em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.poster-card__meta {
  font-size: var(--t-micro);
  color: var(--ink-3);
  margin-top: 4px;
}

/* ================================================================
   9. EMBED VIDEO RESPONSIVE
   ================================================================ */

.video-embed {
  position: relative;
  aspect-ratio: 16 / 9;
  width: 100%;
  overflow: hidden;
  border-radius: var(--r-lg);
  background: var(--bg-alt);
}

.video-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

/* ================================================================
   10. GRILLES PORTFOLIO
   ================================================================ */

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(16px, 2vw, 24px);
}

@media (max-width: 1024px) {
  .portfolio-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .portfolio-grid {
    grid-template-columns: 1fr;
  }
}

/* ================================================================
   11. STATS / CHIFFRES CLES · grille diviseur
   ================================================================ */

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.stat-item {
  background: var(--bg);
  padding: clamp(28px, 3.5vw, 48px) 24px;
  text-align: center;
}

.section--alt .stat-item {
  background: var(--bg-alt);
}

.stat-num {
  font-family: var(--ff-title);
  font-size: clamp(38px, 4.5vw, 60px);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 1;
  color: var(--ink);
  margin-bottom: 8px;
}

.stat-num .stat-num__accent {
  color: var(--terra);
}

.stat-label {
  font-size: var(--t-label);
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* ================================================================
   12. LOGOS CLIENTS · strip + carrousel infini
   ================================================================ */

/* Strip grille classique */
/* Bandeau deroulant des logos (plein largeur, fondu sur les bords) */
.logos-strip {
  overflow: hidden;
  border-top: 1px solid var(--line);
  -webkit-mask-image: linear-gradient(
    to right,
    transparent,
    #000 5%,
    #000 95%,
    transparent
  );
  mask-image: linear-gradient(
    to right,
    transparent,
    #000 5%,
    #000 95%,
    transparent
  );
}

.logos-strip__track {
  display: flex;
  align-items: center;
  width: max-content;
  animation: logosStripScroll 80s linear infinite;
}

.logos-strip:hover .logos-strip__track {
  animation-play-state: paused;
}

/* Moins de 8 logos : bande fixe centree (une boucle animee defile a vide).
   Le defilement reprend automatiquement a partir de 8 logos. */
.logos-strip--static {
  -webkit-mask-image: none;
  mask-image: none;
}

.logos-strip--static .logos-strip__track {
  width: 100%;
  flex-wrap: wrap;
  justify-content: center;
  animation: none;
}

.logo-slot {
  flex: 0 0 auto;
  min-height: 110px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px clamp(18px, 2.5vw, 36px);
  background: var(--bg-alt);
}

.logo-slot img {
  /* hauteur FIXE : reserve l'espace meme avant chargement -> le lazy-load se declenche.
     (sans attribut width/height, height:auto restait a 0 et l'image ne chargeait jamais) */
  height: 100px;
  width: auto;
  max-width: 160px;
  object-fit: contain;
  opacity: 0.45;
  filter: grayscale(1);
  mix-blend-mode: multiply;
  transition:
    opacity var(--dur) var(--ease),
    filter var(--dur) var(--ease);
}

.logo-slot:hover img {
  opacity: 0.85;
  filter: grayscale(0.1);
}

.logo-slot-text {
  font-family: var(--ff-title);
  font-size: var(--t-label);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-4);
  white-space: nowrap;
}

@keyframes logosStripScroll {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .logos-strip__track {
    animation: none;
  }
}

/* ================================================================
   13. FORMULAIRES
   ================================================================ */

.form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

@media (max-width: 600px) {
  .form-row {
    grid-template-columns: 1fr;
  }
}

.field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.field label {
  font-size: var(--t-label);
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.field input,
.field textarea,
.field select {
  background: #fff;
  border: 1.5px solid #7e8287; /* RGAA 3.3 : bordure de champ 3.87:1 sur blanc (etait --line-m, 1.5:1) */
  border-radius: var(--r-pill);
  padding: 13px 20px;
  font-size: var(--t-small);
  color: var(--ink);
  outline: none;
  resize: vertical;
  width: 100%;
  min-height: 48px;
  transition:
    border-color var(--dur) var(--ease),
    box-shadow var(--dur) var(--ease);
}

.field input:focus,
.field textarea:focus,
.field select:focus {
  border-color: var(--terra);
  box-shadow: 0 0 0 3px oklch(0.52 0.22 30 / 0.12);
}

.field textarea {
  min-height: 130px;
  resize: vertical;
  border-radius: var(--r-lg);
}

.field--error input,
.field--error textarea {
  border-color: oklch(0.5 0.22 25);
}

.field-hint {
  font-size: var(--t-micro);
  color: var(--ink-3);
}

/* ================================================================
   14. FOOTER SOMBRE · 3 colonnes + barre legale
   ================================================================ */

.site-footer {
  background: var(--bg-dark);

  color: var(--ink-inv-2);

  position: relative;
}

/* Grille principale : marque / nav / contact */
.site-footer__grid {
  padding-block: clamp(56px, 7vw, 96px);
  display: grid;
  grid-template-columns: 1.6fr 1fr 1.4fr;
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}

/* --- Colonne marque --- */
.site-footer__logo {
  margin-bottom: 20px;
}

.site-footer__logo img {
  height: 38px;
  width: auto;
  opacity: 0.85;
  filter: brightness(0) invert(1);
}

.site-footer__pitch {
  font-size: var(--t-small);
  font-weight: 300;
  color: var(--ink-inv-2);
  line-height: 1.75;
  max-width: 320px;
  margin-bottom: 16px;
}

.site-footer__signature {
  font-size: var(--t-label);
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--terra-l);
}

/* --- Titres de colonne --- */
.site-footer__col-title {
  font-size: var(--t-label);
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #9a9ea4; /* RGAA 3.2 : 7:1 sur #111 (etait 2.88:1) */
  margin-bottom: 20px;
}

/* --- Colonne navigation --- */
.site-footer__nav {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.site-footer__nav a {
  font-size: var(--t-small);
  font-weight: 400;
  color: var(--ink-inv-2);
  text-decoration: none;
  transition: color var(--dur) var(--ease);
  width: fit-content;
}

.site-footer__nav a:hover {
  color: var(--terra-l);
}

/* --- Colonne contact --- */
.site-footer__contact {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.site-footer__contact-line {
  font-size: var(--t-small);
  font-weight: 400;
  color: var(--ink-inv-2);
  line-height: 1.5;
}

.site-footer__contact-line a {
  color: var(--ink-inv-2);
  text-decoration: none;
  transition: color var(--dur) var(--ease);
}

.site-footer__contact-line a:hover {
  color: var(--terra-l);
}

.site-footer__socials {
  display: flex;
  gap: 12px;
  margin-top: 8px;
}

.site-footer__social-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: var(--t-label);
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-inv-2);
  text-decoration: none;
  border: 1px solid oklch(0.3 0.01 250);
  border-radius: var(--r-pill);
  padding: 6px 14px;
  transition:
    color var(--dur) var(--ease),
    border-color var(--dur) var(--ease);
}

.site-footer__social-link:hover {
  color: var(--terra-l);
  border-color: var(--terra-l);
}

/* Liens reseaux sur fond clair (page Contact) : meme densite que le footer */
.contact-socials {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.contact-socials__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: var(--t-label);
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-2);
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  padding: 6px 14px;
  transition:
    color var(--dur) var(--ease),
    border-color var(--dur) var(--ease);
}

.contact-socials__link:hover {
  color: var(--terra);
  border-color: var(--terra);
}

/* --- Bloc CTA interne --- */
.site-footer__cta {
  border-top: 1px solid var(--line-dark);
  padding-block: clamp(28px, 4vw, 40px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.site-footer__cta-label {
  font-family: var(--ff-title);
  font-size: var(--t-h4);
  font-weight: 700;
  color: var(--ink-inv);
  letter-spacing: -0.01em;
}

/* --- Barre legale --- */
.site-footer__bottom {
  border-top: 1px solid var(--line-dark);
  padding-block: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

.site-footer__copy {
  font-size: var(--t-micro);
  color: #9a9ea4; /* RGAA 3.2 (etait 2.05:1) */
  line-height: 1.6;
}

/* Credit du studio dans la barre legale */
.site-footer__copy a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color var(--dur) var(--ease);
}

.site-footer__copy a:hover {
  color: var(--ink-inv-2);
}

.site-footer__legal-links {
  display: flex;
  gap: 16px;
}

.site-footer__legal-links a {
  font-size: var(--t-micro);
  color: #9a9ea4; /* RGAA 3.2 (etait 2.05:1) */
  text-decoration: none;
  transition: color var(--dur) var(--ease);
}

.site-footer__legal-links a:hover {
  color: var(--ink-inv-2);
}

/* Responsive */
@media (max-width: 900px) {
  .site-footer__grid {
    grid-template-columns: 1fr 1fr;
  }
  .site-footer__col--brand {
    grid-column: 1 / -1;
  }
}

@media (max-width: 600px) {
  .site-footer__grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  .site-footer__cta {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
  .site-footer__bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
  .site-footer__legal-links {
    gap: 12px;
  }
}

/* ================================================================
   15. UTILITAIRES
   ================================================================ */

.text-muted {
  color: var(--ink-3);
}

/* Badge accent */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: var(--t-micro);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: var(--r-pill);
  background: var(--terra-bg);
  color: var(--terra-d);
  border: 1px solid var(--terra-border);
}

/* Barre decorative terra */
.accent-bar {
  display: block;
  width: 32px;
  height: 3px;
  background: var(--terra);
  margin-bottom: 20px;
}

/* Overrides mobiles generiques */
@media (max-width: 680px) {
  #main-content article[style*="grid-template-columns"] {
    grid-template-columns: 1fr !important;
  }
}

/* ================================================================
   16. PAGE-HEAD · en-tete uniforme des pages internes (fond clair)
   Structure HTML :
     <header class="page-head [page-head--grid]" role="banner">
       <span class="page-head__watermark" aria-hidden="true"></span>
       <div class="container">
         <p class="eyebrow page-head__eyebrow">Label</p>
         <h1 class="page-head__title">Titre <span class="accent-word">accent</span></h1>
         <p class="page-head__sub">Sous-titre optionnel</p>
         <div class="page-head__stat">43 <span>Productions</span></div>  <!-- page-head--grid -->
       </div>
     </header>
   ================================================================ */

.page-head {
  position: relative;
  overflow: hidden;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  padding: clamp(56px, 8vw, 100px) 0 clamp(40px, 5vw, 64px);
  padding-inline: 0 !important;
  min-height: 500px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Eyebrow : terra + trait */
.page-head .page-head__eyebrow {
  color: var(--terra);
}
.page-head .page-head__eyebrow::before {
  background: var(--terra);
}

/* Titre principal */
.page-head__title {
  font-family: var(--ff-title);
  font-size: clamp(44px, 6vw, 88px);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 0.95;
  color: var(--ink);
  margin-bottom: 16px;
}

.page-head__title .accent-word {
  color: var(--terra);
  display: block;
}

/* Sous-titre / chapeau */
.page-head__sub {
  font-family: var(--ff-body);
  font-size: clamp(15px, 1.4vw, 17px);
  font-weight: 400;
  line-height: 1.65;
  color: var(--ink-3);
  max-width: 680px;
}

/* Caption legale (mentions legales, politique) */
.page-head__caption {
  font-size: var(--t-small);
  color: var(--ink-3);
  margin-top: 10px;
  line-height: 1.5;
}

/* Modificateur grille (portfolio : titre + compteur) */
.page-head--grid > .container {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 32px;
}

.page-head__stat {
  font-family: var(--ff-title);
  font-size: clamp(48px, 6vw, 80px);
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--ink);
  line-height: 1;
  text-align: right;
}

.page-head__stat span {
  display: block;
  font-family: var(--ff-body);
  font-size: var(--t-label);
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-top: 4px;
}

/* ---- Filigrane picto ------------------------------------------- */
.page-head__watermark {
  position: absolute;
  display: block;
  pointer-events: none;
  user-select: none;
  width: 100%;
  height: 100%;
  top: 0;
  background-image: url("/assets/logo/picto-black.svg");
  background-repeat: no-repeat;
  background-size: clamp(1000px, 2000vw, 3000px);
  background-position: center;
  opacity: 0.06;
  z-index: 0;
}

/* Le contenu passe au-dessus du filigrane */
.page-head > .container {
  position: relative;
  z-index: 1;
}

/* ---- Responsive : mobile ---------------------------------------- */
@media (max-width: 768px) {
  .page-head {
    min-height: 400px;
  }
  .page-head__title {
    font-size: clamp(36px, 10vw, 60px);
  }
}

@media (max-width: 640px) {
  .page-head--grid > .container {
    grid-template-columns: 1fr;
  }
  .page-head__stat {
    text-align: left;
  }
}

/* Ligne legale du pied de page (SIRET + declaration d'activite), au-dessus du copyright */
.site-footer__legal-line {
  display: block;
  margin-bottom: 4px;
}

/* Barre legale : le texte legal (long) prend la largeur, les liens passent dessous si besoin */
.site-footer__copy { flex: 1 1 560px; max-width: 980px; }
.site-footer__legal-line { color: #a3a7ac; }


/* ================================================================
   ACCESSIBILITE (RGAA 4.1) · ajoute le 2026-11-05
   Lien d'evitement, focus visible, texte reserve aux lecteurs d'ecran,
   liens reconnaissables dans le texte, contenus replies vraiment masques.
   ================================================================ */
.skip-link {
  position: absolute;
  left: 16px;
  top: -100px;
  z-index: 10000;
  padding: 12px 20px;
  background: #111;
  color: #fff;
  font-family: var(--ff-body);
  font-size: 15px;
  font-weight: 600;
  border-radius: 8px;
  text-decoration: underline;
}
.skip-link:focus { top: 12px; outline: 3px solid var(--orange); outline-offset: 2px; }

/* Focus clavier visible partout (le style natif etait supprime sur les champs et le menu mobile) */
:focus-visible { outline: 3px solid var(--carmin); outline-offset: 3px; }
.site-footer :focus-visible,
.section--dark :focus-visible,
.page-hero :focus-visible,
.contact-aside :focus-visible,
.faq-float-panel :focus-visible,
#mobileMenu :focus-visible,
.retour-bar :focus-visible,
.projet-nav :focus-visible { outline-color: var(--orange); }
.field input:focus-visible,
.field textarea:focus-visible,
.field select:focus-visible { outline: 3px solid var(--carmin); outline-offset: 2px; }
.mobile-menu__links a:focus-visible { outline: 3px solid var(--orange); outline-offset: 4px; }

/* Texte lu par les lecteurs d'ecran, invisible a l'ecran */
.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

/* Liens dans un paragraphe : soulignes (pas seulement la couleur) */
.form p a, .text-link { text-decoration: underline; text-underline-offset: 2px; }

/* Champs : indication d'obligation et messages d'erreur */
.form-required-note { font-size: var(--t-micro); color: var(--ink-3); margin: 0 0 4px; }
.field .req { color: var(--carmin); font-weight: 700; }
.field-error-msg { display: block; margin-top: 6px; font-size: 13px; font-weight: 500; color: #b00020; }
.field [aria-invalid="true"] { border-color: #b00020; }

/* Mouvement reduit : pas d'animation d'entree */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}

/* Grille coordonnees / formulaire de la page Contact (sortie du <style> en body, RGAA 8.2) */
@media (max-width: 768px) {
  .contact-grid { grid-template-columns: 1fr !important; gap: clamp(32px, 6vw, 56px) !important; }
}

/* Menu principal dans un <nav> (RGAA 12.6) : le <nav> prend la place flexible de la liste */
.nav-primary { flex: 1; display: flex; justify-content: center; min-width: 0; }
/* Liens du pied de page en listes (RGAA 9.3) : la liste reprend la mise en page du conteneur */
.site-footer__nav > ul,
.site-footer__legal-links > ul {
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-direction: inherit; flex-wrap: wrap; gap: inherit;
}
.site-footer__legal-links { flex-wrap: wrap; }

/* Pages de texte : declaration d'accessibilite, plan du site */
.doc-h2 { font-family: var(--ff-title); font-size: var(--t-h3); font-weight: 700; color: var(--ink); letter-spacing: -0.02em; margin-top: clamp(32px, 4vw, 48px); margin-bottom: 12px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.doc-h3 { font-family: var(--ff-title); font-size: 1.15rem; font-weight: 700; color: var(--ink); margin: 28px 0 8px; }
.doc-txt { font-size: var(--t-body); color: var(--ink-2); line-height: 1.85; margin-bottom: 1em; }
.doc-txt a, .doc-list a { color: var(--ink); text-decoration: underline; text-underline-offset: 2px; }
.doc-txt a:hover, .doc-list a:hover { color: var(--carmin); }
.doc-list { margin: 0 0 1.2em; padding-left: 1.3em; color: var(--ink-2); line-height: 1.8; font-size: var(--t-body); }
.doc-list li { margin-bottom: 6px; }
.doc-list ul { margin-top: 6px; padding-left: 1.3em; }
.doc-status { display: inline-block; padding: 6px 14px; border-radius: var(--r-pill); background: var(--carmin-bg); border: 1px solid var(--carmin-border); color: var(--carmin); font-weight: 700; }
