/* ─────────────────────────────────────────────────────────────────────────────
   Hames Sharley brand typeface — TRIAL OVERRIDE
   ─────────────────────────────────────────────────────────────────────────────
   A drop-in swap of the site's UI font from Plus Jakarta Sans to the practice's
   own typeface, kept deliberately separate so it can be switched off or deleted
   without touching the design system.

   How it hooks in
     app.css sets `--font-sans` inside Tailwind's `@theme`, which emits
     `:root { --font-sans: … }` and `--default-font-family: var(--font-sans)`.
     Everything on the site inherits from that one variable, so re-declaring it
     here — in a plain stylesheet loaded AFTER the Vite bundle — repoints every
     page without a rebuild. No @theme edit, no `npm run build`.

   How to switch it off
     Set BRAND_FONT_ENABLED=false in .env (the <link> is gated on it), or delete
     this file plus public/fonts/hames-sharley/. See config/brand-font.php.

   Source
     R:\Design Resources\Fonts\Hames Sharley Fonts\Open Type (2015 OTFs),
     converted to WOFF2 — 10 faces, ~123 KB total, ~12 KB each.

   Coverage caveat
     The family carries only 230 glyphs (Latin-1 plus common punctuation). It
     has no arrows (↑ ↓ →), no €, no ✓ and no prime marks, so Plus Jakarta Sans
     is kept next in the stack — the browser falls back per character for
     anything missing rather than printing tofu. Don't remove it.

   Optical sizing
     Hames Sharley has a smaller x-height (0.492em vs 0.536em) and narrower
     advances (-11%) than Plus Jakarta, so a raw swap reads as "the whole UI got
     smaller". `size-adjust: 108%` matches the x-heights, which keeps the test
     about the typeface rather than the size; it still sets ~4% narrower lines,
     so nothing that fits today will overflow.

     The three metric overrides pin the line box to Plus Jakarta's own metrics
     (ascent 103.8%, descent 22.2%, gap 0) so baselines don't move inside
     fixed-height pills, buttons and rows. They are expressed pre-scale —
     103.8 / 1.08 = 96.1 — because size-adjust multiplies them.

     To see the typeface at its true design size, set size-adjust to 100% and
     the overrides to 103.8% / 22.2% / 0%. If you pick a different size-adjust,
     divide the ascent/descent overrides by the same factor.
   ──────────────────────────────────────────────────────────────────────────── */

/* Light — 100-300 */
@font-face {
    font-family: 'Hames Sharley';
    font-style: normal;
    font-weight: 100 300;
    font-display: swap;
    src: url('../fonts/hames-sharley/HamesSharley-Light.woff2') format('woff2');
    size-adjust: 108%;
    ascent-override: 96.1%;
    descent-override: 20.6%;
    line-gap-override: 0%;
}

@font-face {
    font-family: 'Hames Sharley';
    font-style: italic;
    font-weight: 100 300;
    font-display: swap;
    src: url('../fonts/hames-sharley/HamesSharley-LightItalic.woff2') format('woff2');
    size-adjust: 108%;
    ascent-override: 96.1%;
    descent-override: 20.6%;
    line-gap-override: 0%;
}

/* Regular — 400 */
@font-face {
    font-family: 'Hames Sharley';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/hames-sharley/HamesSharley-Regular.woff2') format('woff2');
    size-adjust: 108%;
    ascent-override: 96.1%;
    descent-override: 20.6%;
    line-gap-override: 0%;
}

@font-face {
    font-family: 'Hames Sharley';
    font-style: italic;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/hames-sharley/HamesSharley-RegularItalic.woff2') format('woff2');
    size-adjust: 108%;
    ascent-override: 96.1%;
    descent-override: 20.6%;
    line-gap-override: 0%;
}

/* Medium — 500 */
@font-face {
    font-family: 'Hames Sharley';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('../fonts/hames-sharley/HamesSharley-Medium.woff2') format('woff2');
    size-adjust: 108%;
    ascent-override: 96.1%;
    descent-override: 20.6%;
    line-gap-override: 0%;
}

@font-face {
    font-family: 'Hames Sharley';
    font-style: italic;
    font-weight: 500;
    font-display: swap;
    src: url('../fonts/hames-sharley/HamesSharley-MediumItalic.woff2') format('woff2');
    size-adjust: 108%;
    ascent-override: 96.1%;
    descent-override: 20.6%;
    line-gap-override: 0%;
}

/* Bold — 600-700. The family has no semibold, and the site leans on 600 heavily
   (Flux headings, buttons, table headers), so Bold covers both rather than
   letting the browser synthesise a fake weight. */
@font-face {
    font-family: 'Hames Sharley';
    font-style: normal;
    font-weight: 600 700;
    font-display: swap;
    src: url('../fonts/hames-sharley/HamesSharley-Bold.woff2') format('woff2');
    size-adjust: 108%;
    ascent-override: 96.1%;
    descent-override: 20.6%;
    line-gap-override: 0%;
}

@font-face {
    font-family: 'Hames Sharley';
    font-style: italic;
    font-weight: 600 700;
    font-display: swap;
    src: url('../fonts/hames-sharley/HamesSharley-BoldItalic.woff2') format('woff2');
    size-adjust: 108%;
    ascent-override: 96.1%;
    descent-override: 20.6%;
    line-gap-override: 0%;
}

/* Black — 800-900 */
@font-face {
    font-family: 'Hames Sharley';
    font-style: normal;
    font-weight: 800 900;
    font-display: swap;
    src: url('../fonts/hames-sharley/HamesSharley-Black.woff2') format('woff2');
    size-adjust: 108%;
    ascent-override: 96.1%;
    descent-override: 20.6%;
    line-gap-override: 0%;
}

@font-face {
    font-family: 'Hames Sharley';
    font-style: italic;
    font-weight: 800 900;
    font-display: swap;
    src: url('../fonts/hames-sharley/HamesSharley-BlackItalic.woff2') format('woff2');
    size-adjust: 108%;
    ascent-override: 96.1%;
    descent-override: 20.6%;
    line-gap-override: 0%;
}

/* ── The swap ──────────────────────────────────────────────────────────────
   Re-declaring --font-sans is enough for the whole app: Tailwind's preflight
   sets `html { font-family: var(--default-font-family, …) }` and that variable
   resolves to var(--font-sans). html/body are restated only as a guard for
   pages that ship their own <style> block ahead of the bundle. --font-mono is
   left alone — code blocks stay monospace. */
:root {
    --font-sans: 'Hames Sharley', 'Plus Jakarta Sans', ui-sans-serif, system-ui, sans-serif,
        'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji';
    --default-font-family: var(--font-sans);
}

html,
body {
    font-family: var(--font-sans);
}
