/* ── base.css — Reset, typographie, layout ─────────────────────────────── */

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font: var(--text-body);
  color: var(--ink);
  background: var(--canvas);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, video, svg { display: block; max-width: 100%; }
a { color: var(--teal); text-decoration: none; }
a:hover { color: var(--teal-strong); }

/* ── Focus visible ── */
:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 2px;
  border-radius: 2px;
}

/* ── Conteneur ── */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* ── Grille ── */
.grid-2 { display: grid; grid-template-columns: repeat(2,1fr); gap: var(--space-8); }
.grid-3 { display: grid; grid-template-columns: repeat(3,1fr); gap: var(--space-8); }
.grid-4 { display: grid; grid-template-columns: repeat(4,1fr); gap: var(--space-6); }

@media(max-width:900px) { .grid-3,.grid-4 { grid-template-columns: repeat(2,1fr); } }
@media(max-width:640px) { .grid-2,.grid-3,.grid-4 { grid-template-columns: 1fr; } }

/* ── Typographie ── */
h1 { font: var(--text-h1); letter-spacing: -0.02em; color: var(--ink); }
h2 { font: var(--text-h2); letter-spacing: -0.015em; color: var(--ink); }
h3 { font: var(--text-h3); color: var(--ink); }
p  { font: var(--text-body); color: var(--ink-muted); }
p + p { margin-top: var(--space-4); }

.text-lead { font: var(--text-lead); color: var(--ink-muted); }
.text-small { font: var(--text-small); color: var(--ink-muted); }

.eyebrow {
  font: var(--text-eyebrow);
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--teal);
  display: block;
  margin-bottom: var(--space-3);
}

/* ── Sections ── */
.section {
  padding-block: var(--space-24);
}
.section--sm { padding-block: var(--space-16); }
.section--surface { background: var(--surface); }
.section--dark {
  background: #071E1C;
  color: #fff;
}
.section--dark h1,
.section--dark h2,
.section--dark h3 { color: #fff; }
.section--dark p { color: rgba(255,255,255,.65); }
.section--dark .eyebrow { color: var(--teal-soft); opacity: .8; }

.section-header { margin-bottom: var(--space-12); }
.section-header h2 { margin-bottom: var(--space-3); }
.section-header .text-lead { max-width: 540px; }

@media(max-width:640px) {
  .section { padding-block: var(--space-16); }
}

/* ── Divider ── */
hr { border: none; border-top: 1px solid var(--line); }

/* ── Scroll reveal classes (appliquées par scroll.js) ── */
[data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity var(--dur-slow) var(--ease-out),
              transform var(--dur-slow) var(--ease-out);
}
[data-reveal].revealed {
  opacity: 1;
  transform: none;
}
[data-reveal-delay="1"] { transition-delay: 80ms; }
[data-reveal-delay="2"] { transition-delay: 160ms; }
[data-reveal-delay="3"] { transition-delay: 240ms; }
[data-reveal-delay="4"] { transition-delay: 320ms; }
[data-reveal-delay="5"] { transition-delay: 400ms; }

/* ── Utilitaires ── */
.text-teal { color: var(--teal); }
.text-coral { color: var(--coral); }
.text-muted { color: var(--ink-muted); }
.text-center { text-align: center; }
.max-560 { max-width: 560px; }
.max-720 { max-width: 720px; }
.mt-2 { margin-top: var(--space-2); }
.mt-4 { margin-top: var(--space-4); }
.mt-6 { margin-top: var(--space-6); }
.mt-8 { margin-top: var(--space-8); }
.mt-12 { margin-top: var(--space-12); }
.flex-center { display: flex; align-items: center; justify-content: center; gap: var(--space-4); flex-wrap: wrap; }
.flex-start  { display: flex; align-items: center; gap: var(--space-4); flex-wrap: wrap; }
