/* =========================================================================
   AB COMMUNICATION — Design system : tokens, reset, typographie, utilitaires
   Palette dérivée du logo officiel (rouge #D10A0F, bleu #14246F, noir)
   et du visuel de marque (or #C8A45D).
   ========================================================================= */

:root {
  /* Couleurs de marque */
  --red: #D10A0F;
  --red-600: #B0080D;
  --red-700: #8E060A;
  --blue: #14246F;
  --blue-500: #2A3F9E;
  --blue-400: #4A63D0;
  --blue-900: #0B1442;
  --gold: #C8A45D;
  --gold-300: #E3C88E;

  /* Neutres */
  --ink: #0A0A0C;
  --ink-2: #111217;
  --ink-3: #1A1C23;
  --ink-4: #262933;
  --paper: #FFFFFF;
  --mist: #F4F4F6;
  --mist-2: #EBECEF;
  --text: #15161B;
  --muted: #565A66;
  --line: rgba(10, 10, 12, .10);
  --line-strong: rgba(10, 10, 12, .18);
  --text-inv: #F5F5F7;
  --muted-inv: #A9ACB8;
  --line-inv: rgba(255, 255, 255, .10);

  /* Typographie */
  --f-display: 'Sora', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --f-body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --f-serif: 'Fraunces', Georgia, 'Times New Roman', serif;

  --fs-xs: .78rem;
  --fs-sm: .9rem;
  --fs-base: 1.0625rem;
  --fs-lead: clamp(1.08rem, .98rem + .45vw, 1.32rem);
  --fs-h4: clamp(1.1rem, 1rem + .4vw, 1.3rem);
  --fs-h3: clamp(1.3rem, 1.12rem + .8vw, 1.75rem);
  --fs-h2: clamp(2rem, 1.4rem + 2.6vw, 3.6rem);
  --fs-display: clamp(2.5rem, 1.5rem + 4.6vw, 5.6rem);

  /* Espacements */
  --gutter: clamp(20px, 5vw, 64px);
  --section: clamp(84px, 11vw, 168px);
  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 22px;
  --header-h: 84px;

  /* Mouvement */
  --ease: cubic-bezier(.22, 1, .36, 1);
  --ease-io: cubic-bezier(.65, 0, .35, 1);
  --dur: .5s;

  --shadow-sm: 0 1px 2px rgba(10, 10, 12, .06), 0 2px 8px rgba(10, 10, 12, .04);
  --shadow: 0 10px 30px -10px rgba(10, 10, 12, .18);
  --shadow-lg: 0 30px 60px -20px rgba(10, 10, 12, .28);
}

/* ------------------------------------------------------------------ Reset */
*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  /* Garde-fou anti-défilement horizontal */
  overflow-x: hidden;
  scroll-padding-top: calc(var(--header-h) + 16px);
}
/* `clip` ne crée pas de conteneur de défilement : position:sticky et ScrollTrigger restent fiables */
@supports (overflow-x: clip) { body, main, .site-footer { overflow-x: clip; } }
body {
  margin: 0;
  min-width: 320px;
  font-family: var(--f-body);
  font-size: var(--fs-base);
  line-height: 1.65;
  color: var(--text);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
img, svg, video, canvas, iframe { display: block; max-width: 100%; }
img { height: auto; }
h1, h2, h3, h4, h5, p, figure, blockquote, ul, ol, dl, dd { margin: 0; }
ul[class], ol[class] { list-style: none; padding: 0; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
address { font-style: normal; }
[hidden] { display: none !important; }
::selection { background: var(--red); color: #fff; }
main:focus { outline: none; }

/* Focus visible accessible */
:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: fixed; top: 12px; left: 12px; z-index: 1000;
  padding: 12px 18px; background: var(--gold); color: var(--ink);
  font-weight: 600; border-radius: var(--radius-sm);
  transform: translateY(-160%); transition: transform .25s var(--ease);
}
.skip-link:focus { transform: none; }

.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;
}

/* ----------------------------------------------------------- Typographie */
.display, .h2, .h3, .h4, h1, h2, h3 {
  font-family: var(--f-display);
  font-weight: 600;
  letter-spacing: -.025em;
  line-height: 1.08;
  overflow-wrap: break-word;
  hyphens: manual;
}
.display { font-size: var(--fs-display); letter-spacing: -.035em; line-height: 1.02; font-weight: 600; }
.h2 { font-size: var(--fs-h2); }
.h3 { font-size: var(--fs-h3); line-height: 1.2; letter-spacing: -.02em; }
.h4 { font-size: var(--fs-h4); line-height: 1.3; letter-spacing: -.01em; }
.display em, .h2 em, .h3 em {
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 300;
  letter-spacing: -.02em;
  color: var(--gold);
}
.on-light .h2 em, .on-light .display em { color: var(--red); }
.lead { font-size: var(--fs-lead); line-height: 1.6; color: var(--muted); max-width: 62ch; }
.eyebrow {
  display: inline-flex; align-items: center; gap: .7em;
  font-family: var(--f-display); font-size: var(--fs-xs); font-weight: 600;
  letter-spacing: .18em; text-transform: uppercase; color: var(--red);
}
.eyebrow::before { content: ''; width: 28px; height: 1px; background: currentColor; flex: none; }
.eyebrow-gold { color: var(--gold); }
.prose p + p, .prose p + ul, .prose ul + p { margin-top: 1.1em; }
.prose ul { padding-left: 1.2em; }
.prose li + li { margin-top: .4em; }
.prose a { color: var(--red); text-decoration: underline; text-underline-offset: 3px; }
.prose h2 { font-size: var(--fs-h3); margin: 2em 0 .7em; }
.prose h3 { font-size: var(--fs-h4); margin: 1.6em 0 .5em; }
.num-serif { font-family: var(--f-serif); font-style: italic; font-weight: 300; }

/* ---------------------------------------------------------------- Layout */
.container {
  width: 100%;
  max-width: calc(1320px + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.container-narrow { max-width: calc(880px + 2 * var(--gutter)); }
.section { padding-block: var(--section); position: relative; }
.section-tight { padding-block: calc(var(--section) * .6); }
.bg-mist { background: var(--mist); }
.bg-dark { background: var(--ink); color: var(--text-inv); }
.bg-dark-2 { background: var(--ink-2); color: var(--text-inv); }
.bg-blue { background: radial-gradient(120% 120% at 100% 0%, #1D2F8F 0%, var(--blue) 35%, var(--blue-900) 100%); color: var(--text-inv); }
.bg-dark .lead, .bg-dark-2 .lead, .bg-blue .lead { color: var(--muted-inv); }
.clip { overflow: hidden; }

.section-head { display: grid; gap: 22px; margin-bottom: clamp(44px, 6vw, 80px); max-width: 860px; }
.section-head.is-center { margin-inline: auto; text-align: center; justify-items: center; }
.section-head.is-center .lead { margin-inline: auto; }

.grid-2 { display: grid; gap: clamp(32px, 5vw, 96px); grid-template-columns: 1fr; align-items: start; }
@media (min-width: 960px) { .grid-2 { grid-template-columns: 1fr 1fr; } .grid-2.is-55 { grid-template-columns: 5fr 6fr; } .grid-2.is-64 { grid-template-columns: 6fr 4fr; } }

.btn-row { display: flex; flex-wrap: wrap; gap: 14px; }
.btn-row.is-center { justify-content: center; }

/* --------------------------------------------------------------- Boutons */
.btn {
  --bg: var(--red); --fg: #fff; --bd: var(--red);
  position: relative; isolation: isolate; overflow: hidden;
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  min-height: 54px; padding: 0 28px;
  font-family: var(--f-display); font-size: .95rem; font-weight: 600; letter-spacing: -.005em;
  color: var(--fg); background: var(--bg); border: 1px solid var(--bd); border-radius: 999px;
  transition: color .45s var(--ease), border-color .45s var(--ease), transform .45s var(--ease), box-shadow .45s var(--ease);
  white-space: nowrap; max-width: 100%;
}
.btn::before {
  content: ''; position: absolute; inset: 0; z-index: -1;
  background: var(--hover-bg, var(--red-700));
  transform: translateY(101%); border-radius: inherit;
  transition: transform .5s var(--ease);
}
.btn:hover::before, .btn:focus-visible::before { transform: translateY(0); }
.btn .icon { width: 18px; height: 18px; transition: transform .45s var(--ease); flex: none; }
.btn:hover .icon { transform: translateX(4px); }
.btn:active { transform: scale(.98); }
.btn-primary:hover { box-shadow: 0 14px 30px -12px rgba(209, 10, 15, .65); }
.btn-ghost-light { --bg: transparent; --fg: #fff; --bd: rgba(255,255,255,.35); --hover-bg: #fff; }
.btn-ghost-light:hover { --fg: var(--ink); color: var(--ink); border-color: #fff; }
.btn-ghost { --bg: transparent; --fg: var(--ink); --bd: var(--line-strong); --hover-bg: var(--ink); }
.btn-ghost:hover { color: #fff; border-color: var(--ink); }
.btn-dark { --bg: var(--ink); --fg: #fff; --bd: var(--ink); --hover-bg: var(--red); }
.btn-gold { --bg: var(--gold); --fg: var(--ink); --bd: var(--gold); --hover-bg: var(--gold-300); }
.btn-sm { min-height: 44px; padding: 0 20px; font-size: .88rem; }
.btn-block { width: 100%; }
@media (max-width: 480px) { .btn { white-space: normal; text-align: center; padding: 12px 22px; } }

.link-arrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--f-display); font-weight: 600; font-size: .95rem;
  color: inherit; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: background-size .45s var(--ease);
  padding-bottom: 2px;
}
.link-arrow .icon { width: 18px; height: 18px; transition: transform .45s var(--ease); }
.link-arrow:hover { background-size: 100% 1px; }
.link-arrow:hover .icon { transform: translateX(4px); }

.icon { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex: none; }

/* --------------------------------------------- États initiaux d'animation
   Le contenu reste visible sans JS, si GSAP ne se charge pas (motion-timeout)
   ou si l'utilisateur préfère réduire les animations. */
.js:not(.motion-ready):not(.motion-timeout) [data-reveal],
.js:not(.motion-ready):not(.motion-timeout) [data-hero-item],
.js:not(.motion-ready):not(.motion-timeout) [data-split],
.js:not(.motion-ready):not(.motion-timeout) [data-stagger] > * { opacity: 0; }
@media (prefers-reduced-motion: reduce) {
  .js [data-reveal], .js [data-hero-item], .js [data-split], .js [data-stagger] > * { opacity: 1 !important; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
.split-line { display: block; overflow: hidden; padding-bottom: .08em; margin-bottom: -.08em; }
.split-line > span { display: block; will-change: transform; }
