/* ==========================================================================
   fonts.css — self-hosted brand fonts (rebrand token migration)
   Spec: docs/shared/superpowers/specs/2026-08-11-rebrand-token-migration.md

   Sources: OnPoint Digital Brand Kit / 2. Brand Fonts / {Anton,Aptos}.zip
   Files placed in: vercel/assets/fonts/ (woff2, converted via fontTools)

   LICENSING — READ BEFORE SHIPPING TO PRODUCTION
   --------------------------------------------------------------------------
   Anton  — SIL Open Font License 1.1 (verified in the font's own name table,
            matches the bundled OFL.txt). Free to self-host, no restriction.

   Aptos  — Microsoft-supplied font (name table copyright: "(c) 2023 Microsoft
            Corporation. All Rights Reserved"). The embedded license
            description reads: "Microsoft supplied font. You may use this
            font to create, display, and print content as permitted by the
            license terms ... of the Microsoft product, service, or content
            in which this font was included. You may only (i) embed this
            font in content as permitted by the embedding restrictions
            included in this font ... Any other use is prohibited."
            This does NOT clear self-hosted web embedding on a public
            portal. The source zip's provenance is also a third-party
            "Viet-hoa" repack site (dafontvn.com), not an official Microsoft
            distribution. TREAT AS A SHIP BLOCKER, not a blocker for this
            file existing — get proper Microsoft licensing confirmation (or
            swap in a licensed substitute) before this ships to production.
   -------------------------------------------------------------------------- */

/* ---- Anton (display/brand headline face) — OFL, cleared to ship ---- */

@font-face {
  font-family: 'Anton';
  src: url('../assets/fonts/Anton-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* ---- Aptos (body/UI + heading face) — LOCAL INSTALL ONLY, no @font-face ----
   DECISION (controller, 2026-08-11): Aptos binaries are NOT self-hosted.
   Two independent reasons, either sufficient:
     1. The font's embedded Microsoft license does not clear self-hosted web
        embedding ("Any other use is prohibited").
     2. The brand kit's Aptos.zip is a third-party repack (dafontvn.com link
        inside the archive), not an official Microsoft distribution — the
        binaries cannot be trusted regardless of licensing.
   Instead the tokens below reference 'Aptos' / 'Aptos Display' by NAME: the
   portal is internal (SAML, @onpoint.vn) and the org runs M365, so Aptos is
   locally installed + licensed on effectively every client. Non-M365 devices
   degrade to the system stack — same metrics class, no visual collapse.
   TO REVERSE (only if IT confirms official web-embedding rights AND supplies
   official binaries): restore the @font-face blocks from git history of this
   file (pre-2026-08-11-quarantine revision) with the official woff2 files. */

/* ==========================================================================
   Font tokens — reference these, never set font-family directly on elements.
   Fallback stacks are full real system stacks on purpose: if Aptos has to be
   pulled for licensing, deleting the @font-face blocks above degrades
   cleanly to system UI fonts with no visual collapse.
   ========================================================================== */

/* NAMING NOTE: --ff-* (font-family), NOT --font-* — styles.css already uses
   --font-body / --font-display etc. as SIZE tokens; reusing those names here
   would make `font-size: var(--font-body)` resolve to a family list and
   silently break body sizing (invalid-at-computed-value → inherit). */
:root {
  --ff-heading: 'Aptos Display', 'Aptos', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --ff-body: 'Aptos', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --ff-brand-display: 'Anton', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;

  /* Data/mono face — kept from the old system (kit has no mono; tabular numerals
     are non-negotiable). ALSO fixes a latent pre-rebrand bug: var(--font-mono)
     was consumed in ~10 places across styles.css but never defined anywhere —
     those sites silently inherited the body face. Defined here, once. */
  --font-mono: 'Geist Mono', ui-monospace, SFMono-Regular, monospace;
}
