/* ============================================================
   Konsult — système de design partagé
   ============================================================ */

:root {
  /* Couleurs — clair */
  --bg:           oklch(0.99 0.004 160);
  --surface:      oklch(1 0 0);
  --surface-2:    oklch(0.975 0.006 160);
  --ink:          oklch(0.22 0.015 175);
  --muted:        oklch(0.52 0.013 175);
  --line:         oklch(0.91 0.006 175);
  --line-strong:  oklch(0.85 0.008 175);

  /* Couleurs — sombre (carte data / footer uniquement) */
  --dark:         oklch(0.175 0.014 168);
  --dark-2:       oklch(0.222 0.016 168);
  --dark-line:    oklch(0.31 0.018 168);
  --on-dark:      oklch(0.97 0.005 160);
  --on-dark-mut:  oklch(0.72 0.012 165);

  /* Accent — vert (data / croissance) */
  --accent:       oklch(0.78 0.16 153);
  --accent-2:     oklch(0.72 0.17 153);
  --accent-ink:   oklch(0.20 0.04 158);   /* texte sur bouton vert */
  --accent-soft:  oklch(0.95 0.04 153);

  /* Typo */
  --font-display: "Space Grotesk", system-ui, sans-serif;
  --font-body:    "Hanken Grotesk", system-ui, sans-serif;
  --font-mono:    "JetBrains Mono", ui-monospace, monospace;

  /* Forme */
  --radius:   14px;
  --radius-sm: 9px;
  --maxw: 1180px;
  --pad: clamp(20px, 5vw, 64px);

  --shadow-sm: 0 1px 2px oklch(0.2 0.02 170 / 0.06), 0 2px 8px oklch(0.2 0.02 170 / 0.05);
  --shadow-md: 0 18px 50px oklch(0.2 0.02 170 / 0.10);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--ink);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0;
  text-wrap: balance;
}

p { margin: 0; text-wrap: pretty; }
a { color: inherit; text-decoration: none; }

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

/* ---------- Eyebrow / labels mono ---------- */
.eyebrow {
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-2);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 1px;
  background: var(--accent-2);
  display: inline-block;
}
.eyebrow--ondark { color: var(--accent-2); }
.eyebrow--ondark::before { background: var(--accent-2); }

/* ---------- Boutons ---------- */
.btn {
  font-family: var(--font-body);
  font-size: 15.5px;
  font-weight: 600;
  letter-spacing: -0.01em;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 14px 24px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  transition: transform .18s ease, background .18s ease, border-color .18s ease, color .18s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }

.btn--primary {
  background: var(--accent);
  color: var(--accent-ink);
}
.btn--primary:hover { background: var(--accent-2); transform: translateY(-2px); }

.btn--ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn--ghost:hover { border-color: var(--ink); transform: translateY(-2px); }

.btn--ghost-dark {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn--ghost-dark:hover { border-color: var(--ink); background: var(--surface-2); transform: translateY(-2px); }

.btn .arrow { transition: transform .2s ease; }
.btn:hover .arrow { transform: translate(3px, -3px); }

/* ---------- Nav ---------- */
.nav {
  position: relative;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 22px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 21px;
  letter-spacing: -0.03em;
  color: var(--ink);
}
.brand .dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px color-mix(in oklch, var(--accent) 20%, transparent);
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 34px;
  list-style: none;
  margin: 0; padding: 0;
}
.nav-links a {
  font-size: 15.5px;
  font-weight: 500;
  color: var(--ink);
  transition: color .15s ease;
  position: relative;
  padding-block: 4px;
}
.nav-links a::after {
  content: ""; position: absolute; left: 0; right: 100%; bottom: -2px; height: 2px;
  background: var(--accent-2); border-radius: 2px; transition: right .22s ease;
}
.nav-links a:hover { color: var(--accent-2); }
.nav-links a:hover::after { right: 0; }
.nav-links a.active { color: var(--ink); }
.nav-links a.active::after { right: 0; }
.nav-right { display: flex; align-items: center; gap: 20px; }

.mobile-menu { display: none; }

.nav-toggle {
  display: none;
  background: none; border: none; cursor: pointer;
  width: 40px; height: 40px;
  flex-direction: column; justify-content: center; gap: 5px;
}
.nav-toggle span {
  display: block; height: 2px; width: 24px;
  background: var(--ink); border-radius: 2px;
  transition: transform .25s ease, opacity .2s ease;
}

/* ---------- Bandeau clair (héro / en-têtes) ---------- */
.dark-band {
  background: var(--bg);
  color: var(--ink);
  position: relative;
  overflow: hidden;
}
.dark-band .grid-bg {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(oklch(0.2 0.02 170 / 0.05) 1px, transparent 1px),
    linear-gradient(90deg, oklch(0.2 0.02 170 / 0.05) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: radial-gradient(120% 90% at 72% 8%, #000 22%, transparent 72%);
  pointer-events: none;
}
.dark-band .glow {
  position: absolute;
  width: 640px; height: 640px;
  border-radius: 50%;
  background: radial-gradient(circle, color-mix(in oklch, var(--accent) 34%, transparent), transparent 64%);
  filter: blur(26px);
  top: -260px; right: -140px;
  pointer-events: none;
}

/* ---------- Section générique ---------- */
.section { padding-block: clamp(64px, 9vw, 120px); }
.section-head { max-width: 640px; margin-bottom: 54px; }
.section-head h2 {
  font-size: clamp(30px, 4.4vw, 46px);
  margin-top: 18px;
}
.section-head p { color: var(--muted); margin-top: 16px; font-size: 18px; }

/* ============================================================
   Footer
   ============================================================ */
.footer {
  background: var(--dark);
  color: var(--on-dark);
  padding-top: clamp(56px, 8vw, 84px);
  padding-bottom: 34px;
}
.footer-top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 48px;
  border-bottom: 1px solid var(--dark-line);
}
.footer .brand { margin-bottom: 16px; color: var(--on-dark); }
.footer-blurb { color: var(--on-dark-mut); max-width: 320px; font-size: 15.5px; }
.footer-col h4 {
  font-family: var(--font-mono);
  font-size: 12px; font-weight: 500;
  text-transform: uppercase; letter-spacing: 0.16em;
  color: var(--on-dark-mut);
  margin-bottom: 18px;
}
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.footer-col a { color: var(--on-dark); font-size: 15px; opacity: 0.86; transition: opacity .15s, color .15s; }
.footer-col a:hover { opacity: 1; color: var(--accent); }
.footer-bottom {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 14px;
  padding-top: 26px;
  font-size: 13.5px;
  color: var(--on-dark-mut);
  font-family: var(--font-mono);
  letter-spacing: 0.02em;
}
.footer-legal { display: flex; flex-wrap: wrap; gap: 22px; }
.footer-legal a { color: var(--on-dark-mut); transition: color .15s ease; }
.footer-legal a:hover { color: var(--accent); }

/* ---------- Animations d'entrée ---------- */
/* Le contenu est visible par défaut. On ne le masque (pour l'animer) que si JS
   ajoute .reveal-ready à <html> — sinon (JS off, IO indisponible, print) tout reste visible. */
@media (prefers-reduced-motion: no-preference) {
  .reveal-ready .reveal { opacity: 0; transform: translateY(18px); }
  .reveal-ready .reveal.in { opacity: 1; transform: none; transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.3,1); }
  .reveal.d1 { transition-delay: .08s; }
  .reveal.d2 { transition-delay: .16s; }
  .reveal.d3 { transition-delay: .24s; }
  .reveal.d4 { transition-delay: .32s; }
}
@media print {
  .reveal { opacity: 1 !important; transform: none !important; }
}

/* ---------- Mobile ---------- */
@media (max-width: 860px) {
  .nav-toggle { display: flex; }
  .nav-links, .nav-right .btn { display: none; }
  .mobile-menu {
    display: none;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    margin-top: 10px;
    padding: 16px;
    box-shadow: var(--shadow-md);
  }
  .mobile-menu.open { display: block; }
  .mobile-menu ul { list-style: none; margin: 0 0 14px; padding: 0; display: grid; gap: 6px; }
  .mobile-menu a { display: block; padding: 10px 8px; color: var(--ink); font-size: 16px; }
  .mobile-menu .btn { width: 100%; justify-content: center; }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .footer-brand-col { grid-column: 1 / -1; }
}
@media (max-width: 520px) {
  .footer-top { grid-template-columns: 1fr; }
}
