/*
 * Typography design tokens — single source of truth for the unified type
 * system. Desktop and Tablet share identical values per spec, so only two
 * tiers exist: this base block, and the <=640px mobile override below
 * (640px matches the site's existing mobile breakpoint convention).
 * Consumed by typography.css — do not hardcode font values elsewhere.
 */

:root {
  /* Families */
  --font-ui: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-brand: 'Mokoto', var(--font-ui);
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  /* H1 */
  --h1-size: 3rem;
  --h1-weight: 800;
  --h1-leading: 1.1;
  --h1-tracking: -0.025em;

  /* H2 */
  --h2-size: 2.6rem;
  --h2-weight: 700;
  --h2-leading: 1.2;
  --h2-tracking: -0.02em;

  /* H3 */
  --h3-size: 1.6rem;
  --h3-weight: 700;
  --h3-leading: 1.3;
  --h3-tracking: -0.015em;

  /* H4 */
  --h4-size: 1.1rem;
  --h4-weight: 600;
  --h4-leading: 1.4;
  --h4-tracking: normal;

  /* Card Heading */
  --card-heading-size: 1.3rem;
  --card-heading-weight: 700;
  --card-heading-leading: 1.3;
  --card-heading-tracking: -0.015em;

  /* Body Large */
  --body-lg-size: 1.125rem;
  --body-lg-weight: 400;
  --body-lg-leading: 1.65;
  --body-lg-tracking: normal;

  /* Body */
  --body-size: 1rem;
  --body-weight: 400;
  --body-leading: 1.6;
  --body-tracking: normal;

  /* Body Small */
  --body-sm-size: 0.875rem;
  --body-sm-weight: 400;
  --body-sm-leading: 1.5;
  --body-sm-tracking: normal;

  /* Caption — constant across all breakpoints */
  --caption-size: 0.75rem;
  --caption-weight: 500;
  --caption-leading: 1.4;
  --caption-tracking: 0.06em;

  /* Eyebrow — constant across all breakpoints */
  --eyebrow-size: 0.85rem;
  --eyebrow-weight: 700;
  --eyebrow-leading: 1.4;
  --eyebrow-tracking: 0.08em;

  /* Button */
  --button-size: 1rem;
  --button-weight: 600;
  --button-leading: 1;
  --button-tracking: normal;

  /* Navigation — constant across all breakpoints */
  --nav-size: 1rem;
  --nav-weight: 500;
  --nav-leading: 1;
  --nav-tracking: normal;

  /* CTA Heading */
  --cta-heading-size: 2.2rem;
  --cta-heading-weight: 800;
  --cta-heading-leading: 1.15;
  --cta-heading-tracking: -0.02em;

  /* CTA Description */
  --cta-desc-size: 1.05rem;
  --cta-desc-weight: 400;
  --cta-desc-leading: 1.6;
  --cta-desc-tracking: normal;

  /* Spacing */
  --space-h1-desc: 1.5rem;
  --space-h2-desc: 1.25rem;
  --space-h3-desc: 1rem;
  --space-card-heading-desc: 0.75rem;
  --space-para-btn: 1.5rem;
  --space-cta-heading-desc: 0.75rem;
  --space-section: 4rem;

  /* Content-width constraints (ch units) */
  --measure-h1: 12ch;
  --measure-h2: 15ch;
  --measure-cta-desc: 60ch;
  --measure-body: 65ch;
}

@media (max-width: 640px) {
  :root {
    --h1-size: 2.2rem;
    --h2-size: 2.1rem;
    --h3-size: 1.35rem;
    --h4-size: 1rem;
    --card-heading-size: 1.15rem;
    --body-lg-size: 1rem;
    --body-size: 0.95rem;
    --button-size: 0.95rem;
    --cta-heading-size: 1.5rem;
    --cta-desc-size: 0.95rem;
    --space-section: 3rem;
  }
}
