/* ============================================================================
   Clear Tech Guide — tokens + self-hosted faces
   "Manual" (house-design.md override, Stitch direction A; project
   13596015099981852007, design system assets/13227192808970209792, 2026-10-06).
   A calm reference manual: paper ground, white sheets, hairline rules, index
   code boxes, manual blue as the one hue. Loads FIRST, before main.css and
   ctg.css.
   ========================================================================= */

/* --- Faces: Bricolage Grotesque (display, variable 600–800), Atkinson
   Hyperlegible Next (reading text + UI, variable 400–700 + italic 400; built
   for low-vision readers). latin + latin-ext each (italic latin only). */
@font-face {
    font-family: 'Bricolage Grotesque';
    font-style: normal;
    font-weight: 600 800;
    font-display: swap;
    src: url('../fonts/bricolage-grotesque-var-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: 'Bricolage Grotesque';
    font-style: normal;
    font-weight: 600 800;
    font-display: swap;
    src: url('../fonts/bricolage-grotesque-var-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: 'Atkinson Hyperlegible Next';
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
    src: url('../fonts/atkinson-hyperlegible-next-var-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: 'Atkinson Hyperlegible Next';
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
    src: url('../fonts/atkinson-hyperlegible-next-var-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: 'Atkinson Hyperlegible Next';
    font-style: italic;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/atkinson-hyperlegible-next-italic-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
    color-scheme: light;
    /* --- Palette (WCAG contrast, measured 2026-10-06) ------------------------
       blue #0B5E8A on white 7.0 · on paper 6.4 · on start tint 6.0 · white on it 7.0
       ink #1F2933 on paper 13.4 · meta #4A5560 on white 7.6 · on paper 6.9
       The live site's #0EA5E9 was 2.8 on white and is retired. */
    --mn-paper:      #F6F4EF;   /* page ground, strip, footer */
    --mn-sheet:      #FFFFFF;   /* sheets */
    --mn-tint:       #E3EEF4;   /* start-here band, code boxes, callouts */
    --mn-rule:       #D9D4C7;   /* hairlines */
    --mn-rule-soft:  #E8E4DA;
    --mn-ink:        #1F2933;
    --mn-meta:       #4A5560;
    --mn-blue:       #0B5E8A;   /* the one hue: links, buttons, codes */
    --mn-blue-dark:  #084A6C;
    --mn-on-blue:    #FFFFFF;

    /* --- Type ---------------------------------------------------------------- */
    --mn-display: 'Bricolage Grotesque', 'Avenir Next', 'Segoe UI', Roboto, Arial, sans-serif;
    --mn-text:    'Atkinson Hyperlegible Next', 'Atkinson Hyperlegible', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    --mn-size-body: clamp(1.125rem, 1.06rem + 0.3vw, 1.25rem);   /* 18–20px */
    --mn-lh-body:   1.7;
    --mn-lh-head:   1.15;
    --mn-title: clamp(2rem, 1.5rem + 1.6vw, 2.75rem);   /* article + archive H1, capped 44px */
    --mn-h2:    clamp(1.5rem, 1.3rem + 0.7vw, 1.875rem);
    --mn-h3:    clamp(1.2rem, 1.1rem + 0.4vw, 1.4rem);

    /* --- Shape & metrics ------------------------------------------------------ */
    --mn-radius:    4px;
    --mn-page-max:  1320px;
    --mn-sidebar:   320px;
    --mn-side-gap:  2.5rem;
    --mn-gutter:    clamp(1rem, 3vw, 2rem);
    --mn-tap:       48px;

    /* --- Bridge to main.css (do not restyle main.css) ------------------------- */
    --font-size-body-min: 1.125rem;
    --font-size-body-max: 1.25rem;
    --font-size-body-fluid: calc(1.06rem + 0.3vw);
    --font-size-h1-min: 2rem;
    --font-size-h1-max: 2.75rem;
    --font-size-h1-fluid: calc(1.5rem + 1.6vw);
    --font-size-h2-min: 1.5rem;
    --font-size-h2-max: 1.875rem;
    --font-size-h2-fluid: calc(1.3rem + 0.7vw);
    --font-size-h3-min: 1.2rem;
    --font-size-h3-max: 1.4rem;
    --font-size-h3-fluid: calc(1.1rem + 0.4vw);
    --font-size-h4-min: 1.125rem;
    --font-size-h4-max: 1.25rem;
    --font-size-h4-fluid: calc(1.05rem + 0.3vw);
    --font-size-h5-min: 1.0625rem;
    --font-size-h5-max: 1.125rem;
    --font-size-h5-fluid: calc(1rem + 0.2vw);
    --font-size-h6-min: 1rem;
    --font-size-h6-max: 1.0625rem;
    --font-size-h6-fluid: calc(0.96rem + 0.12vw);
    --line-height-body: 1.7;
    --line-height-heading: 1.15;
    --color-primary: #0B5E8A;
    --color-primary-hover: #084A6C;
    --color-heading: #1F2933;
    --color-accent: #0B5E8A;
    --color-text-dark: #1F2933;
    --color-text-medium: #4A5560;
    --color-text-light: #4A5560;
    --color-background: #F6F4EF;
    --color-background-light: #FFFFFF;
    --color-background-tint: #E3EEF4;
    --color-border: #D9D4C7;
    --color-border-soft: #E8E4DA;
    --color-footer-bg: #F6F4EF;
    --color-error: #B42318;
    --color-warning: #8A5A00;
    --font-family-display: 'Bricolage Grotesque', 'Avenir Next', 'Segoe UI', Roboto, Arial, sans-serif;
    --font-family-body: 'Atkinson Hyperlegible Next', 'Atkinson Hyperlegible', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    --font-family: 'Atkinson Hyperlegible Next', 'Atkinson Hyperlegible', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    --radius-sm: 4px;
    --radius-md: 4px;
    --radius-lg: 6px;
    --border-radius: 4px;
    --border-radius-lg: 6px;
    --content-max: 820px;
    --page-max: 1320px;
    --color-border-light: #E8E4DA;
    --color-footer-border: #D9D4C7;
    --color-footer-text: #1F2933;
    --color-copyright: #4A5560;
    --color-facebook: #1F2933; --color-facebook-hover: #0B5E8A;
    --color-twitter: #1F2933; --color-twitter-hover: #0B5E8A;
    --color-pinterest: #1F2933; --color-pinterest-hover: #0B5E8A;
    --color-linkedin: #1F2933; --color-linkedin-hover: #0B5E8A;
    --color-error-bg: #F9E3E8; --color-error-text: #8A1C12;
    --color-warning-bg: #F6EBD2; --color-warning-text: #6B4600;
    --font-primary: 'Atkinson Hyperlegible Next', 'Atkinson Hyperlegible', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    --font-heading: 'Bricolage Grotesque', 'Avenir Next', 'Segoe UI', Roboto, Arial, sans-serif;
}

/* "Larger text" switch in the masthead: one step up for everything in rem. */
html.ctg-large { font-size: 112.5%; }
