/**
 * Base : reset, typographie, mise en page et primitives (boutons, badges, avatars)
 * partagées par toutes les pages. Mêmes primitives que l'application.
 */

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

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font: 400 16px/1.6 var(--font);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1, h2, h3, h4, p, ul, ol, figure { margin: 0; padding: 0; }
ul, ol { list-style: none; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; background: none; border: 0; padding: 0; margin: 0; }

:where(a, button, [tabindex]):focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 8px; }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.container { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 24px; }
.section { padding: 96px 0; position: relative; }

/* ---- icônes (SVG en ligne, trait 1.8, même jeu que l'application) ---- */
.ic { flex: none; width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ic-16 { width: 16px; height: 16px; }
.ic-18 { width: 18px; height: 18px; }
.ic-22 { width: 22px; height: 22px; }

/* ---- marque ---- */
.brand { display: inline-flex; align-items: center; gap: 10px; }
.logo-tile { flex: none; width: 36px; height: 36px; border-radius: 11px; background: #fff; display: grid; place-items: center; box-shadow: 0 0 0 1px rgba(98, 0, 234, .14), 0 3px 8px -2px rgba(98, 0, 234, .25); overflow: hidden; }
.logo-tile img { width: 26px; height: 26px; object-fit: contain; }
.wordmark { font: 800 18px/20px var(--font); letter-spacing: -.03em; color: var(--text); }
.wordmark span { color: var(--brand-text); margin-left: 3px; }

/* ---- boutons ---- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: var(--r-md); border: 1px solid transparent; font: 600 14px/20px var(--font); white-space: nowrap; transition: transform .12s, box-shadow .15s, background-color .15s, border-color .15s; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--grad); color: var(--on-brand); box-shadow: var(--glow), 0 1px 0 rgba(255, 255, 255, .22) inset; }
.btn-primary:hover { box-shadow: 0 10px 24px -6px rgba(98, 0, 234, .65), 0 1px 0 rgba(255, 255, 255, .22) inset; transform: translateY(-1px); }
.btn-secondary { background: var(--surface); color: var(--text); border-color: var(--line-strong); box-shadow: var(--sh-1); }
.btn-secondary:hover { background: var(--surface-2); border-color: var(--text-3); }
.btn-lg { min-height: 52px; font-size: 15px; padding: 0 22px; border-radius: 14px; }
.btn-icon { width: 44px; padding: 0; }
.btn-icon.is-round { border-radius: var(--r-pill); }
.btn-light { background: #fff; color: #38009a; box-shadow: 0 10px 24px -8px rgba(10, 0, 60, .5); }
.btn-light:hover { transform: translateY(-1px); box-shadow: 0 14px 28px -8px rgba(10, 0, 60, .6); }
.btn-outline-light { color: #fff; border-color: rgba(255, 255, 255, .45); background: rgba(255, 255, 255, .08); }
.btn-outline-light:hover { background: rgba(255, 255, 255, .18); }

/* ---- badges de statut ---- */
.badge { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px 0 8px; border-radius: var(--r-pill); border: 1px solid transparent; font: 600 12px/16px var(--font); white-space: nowrap; }
.tone-info { background: var(--info-bg); color: var(--info-fg); border-color: var(--info-bd); }
.tone-warn { background: var(--warn-bg); color: var(--warn-fg); border-color: var(--warn-bd); }
.tone-ok { background: var(--ok-bg); color: var(--ok-fg); border-color: var(--ok-bd); }
.tone-bad { background: var(--bad-bg); color: var(--bad-fg); border-color: var(--bad-bd); }
.tone-brand { background: var(--brand-soft); color: var(--brand-text); border-color: var(--brand-soft-2); }
.badge.is-dashed { border-style: dashed; }

/* ---- avatars ---- */
.avatar { flex: none; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font: 700 13px/1 var(--font); letter-spacing: .02em; }
.av-0 { background: var(--brand-soft); color: var(--brand-text); }
.av-1 { background: var(--teal-bg); color: var(--teal-fg); }
.av-2 { background: var(--info-bg); color: var(--info-fg); }
.av-3 { background: var(--warn-bg); color: var(--warn-fg); }

/* ---- titres de section ---- */
.eyebrow { display: block; font: 700 12px/16px var(--font); letter-spacing: .08em; text-transform: uppercase; color: var(--brand-text); }
.section-head { max-width: 680px; margin-bottom: 48px; }
.section-head.is-center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head h2 { margin-top: 12px; font: 800 clamp(28px, 4vw, 40px)/1.12 var(--font); letter-spacing: -.03em; }
.section-head p { margin-top: 14px; color: var(--text-2); font-size: 17px; line-height: 1.65; }

/* ---- apparition au défilement (activée uniquement si le JS tourne) ---- */
.reveal-ready [data-reveal]:not(.is-in) { opacity: 0; transform: translateY(20px); }
[data-reveal] { transition: opacity .55s ease-out, transform .55s ease-out; }

@media (max-width: 720px) {
    .section { padding: 72px 0; }
    .container { padding: 0 18px; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation: none !important; transition: none !important; }
    .reveal-ready [data-reveal]:not(.is-in) { opacity: 1; transform: none; }
}
