/* ============================================================
   Volaré — brand tokens (locked: F1 / F5 / F6 / F7)
   Single source of truth for colour + type. Reference these
   variables everywhere; never paste raw hex into components.
   ============================================================ */

/* ---- Self-hosted Poppins (F7 — no Google CDN, COPPA posture) ----
   Files live in ../fonts/. woff2 only (Baseline everywhere).
   font-display:swap = show fallback immediately, swap when Poppins arrives. */
@font-face{
  font-family:"Poppins"; font-style:normal; font-weight:400; font-display:swap;
  src:url("../fonts/poppins-400.woff2") format("woff2");
}
@font-face{
  font-family:"Poppins"; font-style:normal; font-weight:600; font-display:swap;
  src:url("../fonts/poppins-600.woff2") format("woff2");
}
@font-face{
  font-family:"Poppins"; font-style:normal; font-weight:700; font-display:swap;
  src:url("../fonts/poppins-700.woff2") format("woff2");
}

:root{
  /* ---- Palette (locked; exact values from the approved visual direction) ---- */
  --v-navy:#232C6B;      /* primary brand; headings, primary button */
  --v-navy-800:#1A2150;  /* deep navy — hover/press on navy surfaces */
  --v-mint:#3CC9A0;      /* fill only */
  --v-mint-100:#DCF5EC;  /* mint tint — level-stamp bg, soft fills */
  --v-teal:#0F7A5F;      /* text-safe teal (~5:1) — the only mint-family colour legal as text */
  --v-sun:#F5D547;       /* fill only */
  --v-sun-100:#FDF3CE;   /* sun tint — class-code bg */
  --v-sky:#E8F4FC;       /* fill only; page background */
  --v-sky-200:#C7E6F8;   /* sky tint — destination-chip border */
  --v-coral:#F2645C;     /* accent, sparing */
  --v-white:#ffffff;
  --v-paper:#ffffff;     /* card / surface */
  --v-ink:#1C2333;       /* body text — near-black; per the approved visual direction (higher contrast than navy) */
  --v-line:#D5DEE8;      /* hairline borders */
  --v-muted:#5A6478;     /* secondary / supporting text */

  /* ---- Contrast contract (F6) ----
     White text ONLY on navy or deep teal. Navy text on mint, sun, sky.
     Mint (~1.8:1) and sun (~1.4:1) FAIL as text on white — fills only. */
  --v-on-navy:var(--v-white);
  --v-on-teal:var(--v-white);
  --v-on-mint:var(--v-navy);
  --v-on-sun:var(--v-navy);
  --v-on-sky:var(--v-navy);

  /* ---- Type ---- */
  --v-font-sans:"Poppins", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --v-font-mono:ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, monospace;

  /* ---- Radii & layout ---- */
  --v-r:14px;        /* card / panel radius */
  --v-r-sm:9px;      /* small radius */
  --v-maxw:1120px;   /* content max width */
}

/* Apply the brand font + colour. font-size-adjust:from-font keeps the fallback
   at Poppins' x-height so the swap doesn't shift layout (Baseline 2024). */
body{
  font-family:var(--v-font-sans);
  color:var(--v-ink);
  font-size-adjust:from-font;
}

/* ---- Safe fill helpers — encode the contrast contract so a fill always carries legal text.
   Use .v-bg-* on any coloured section; the text colour comes with it. ---- */
.v-bg-navy{background:var(--v-navy);color:var(--v-on-navy);}
.v-bg-teal{background:var(--v-teal);color:var(--v-on-teal);}
.v-bg-mint{background:var(--v-mint);color:var(--v-on-mint);}
.v-bg-sun{background:var(--v-sun);color:var(--v-on-sun);}
.v-bg-sky{background:var(--v-sky);color:var(--v-on-sky);}

/* ============================================================
   Kadence FONT bridge — Kadence's base/heading fonts are "System Default"
   (so the theme makes no Google-Fonts request); point its font variables at
   our self-hosted Poppins. The PALETTE is no longer bridged here: it now lives
   in Kadence's own `kadence_global_palette` option, set to our brand via
   scripts/set-brand-palette.php. That makes the Customizer colour picker the
   single source of truth — so palette edits there actually take effect.
   ============================================================ */
:root{
  --global-body-font-family:var(--v-font-sans);
  --global-heading-font-family:var(--v-font-sans);
  --global-content-font-family:var(--v-font-sans);
}
/* Safety net: headings use Poppins even if the theme sets an explicit
   heading font-family (System Default). */
h1,h2,h3,h4,h5,h6{ font-family:var(--v-font-sans); }

/* Accessibility: honour reduced-motion for the flight-path / progress motif. */
@media (prefers-reduced-motion:reduce){
  *,*::before,*::after{animation-duration:.001ms !important;animation-iteration-count:1 !important;transition-duration:.001ms !important;}
}
