/* ═══ Case study type system — REUSABLE ═══════════════════════════════
   Carries the homepage rules into the case studies:
     · Hedvig Letters Serif names things: hero and section titles,
       block heads, statements. Regular only, so weight is locked to 400.
     · Satoshi explains things: card titles, body 400, emphasis and
       numbers 500, and labels 600 uppercase at +0.14em. No other weights.
   One scale (--fs-* below): five serif sizes, five text sizes and a
   label. Each style owns its line-height and tracking, so a component
   only picks a style. Numbers keep their component sizes (impact
   48–72px, inline 32–44px).
   Titles already use var(--serif); this points it at Hedvig.
   Used on: every case study.

   To add to a page: <link rel="stylesheet" href="components/type.css" />
   as the last stylesheet in <head>, so it follows the page's own styles.
═══════════════════════════════════════════════════════════════════ */
@font-face {
  font-family: 'Hedvig Letters Serif';
  src: url('../Fonts/HedvigLetters/HedvigLettersSerif-opsz.woff2') format('woff2-variations'),
       url('../Fonts/HedvigLetters/HedvigLettersSerif-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --serif: 'Hedvig Letters Serif', Georgia, 'Times New Roman', serif;
  /* Hedvig ships Regular only: never fake a bold from it. */
  font-synthesis-weight: none;
  /* One secondary grey: the two were too close to read as different. */
  --ink-light: var(--ink-mid);

  /* Serif */
  --fs-display: clamp(40px, 5.4vw, 88px);  /* hero title, next case */
  --fs-h1:      clamp(28px, 4vw, 60px);    /* section headings */
  --fs-h2:      clamp(26px, 2.8vw, 44px);  /* statements, drawer titles */
  --fs-h3:      clamp(22px, 2vw, 32px);    /* block heads */
  --fs-h4:      clamp(18px, 1.35vw, 20px); /* side nav */
  /* Satoshi */
  --fs-intro:   clamp(19px, 2.1vw, 28px);  /* hero description */
  --fs-title:   clamp(20px, 1.5vw, 24px);  /* card titles, as on the homepage */
  --fs-body-l:  clamp(16px, 1.25vw, 18px); /* narrative paragraphs */
  --fs-body:    16px;                      /* cards, lists, drawers */
  --fs-small:   14px;                      /* notes, meta, captions */
  --fs-label:   12px;                      /* uppercase labels */
}

/* ─── Serif titles ─────────────────────────────────────────── */
:root .case-hero-brand,
:root .my-role-heading,
:root .cs-feature-title,
:root .overview-statement,
:root .pull-quote-text,
:root .cs-facts-title,
:root .cs-compare-eyebrow,
:root .cs-compare-title,
:root .cs-block-head,
:root .cs-scroll-item,
:root .cs-scroll-title,
:root .cs-nav-btn,
:root .cs-impact-title,
:root .cs-impact-claim,
:root .cs-impact-sheet-title,
:root .next-case__name {
  font-family: var(--serif);
  font-weight: 400;
}
/* Serif reads looser than Satoshi, so tracking eases off as titles get smaller. */
:root .case-hero-brand,
:root .next-case__name { font-size: var(--fs-display); line-height: 0.98; letter-spacing: -0.025em; }
:root .my-role-heading,
:root .cs-impact-title,
:root .cs-scroll-title { font-size: var(--fs-h1); line-height: 1.14; letter-spacing: -0.015em; }
:root .cs-feature-title,
:root .cs-impact-cover .cs-impact-claim,
:root .cs-scroll-item,
:root .cs-impact-sheet-title { font-size: var(--fs-h2); line-height: 1.15; letter-spacing: -0.015em; }
/* More features names stay on one line: cs-scroll.js lowers --cs-fit when the longest would wrap. */
:root .cs-scroll-item { font-size: calc(var(--fs-h2) * var(--cs-fit, 1)); }
:root .cs-block-head,
:root .cs-feature--quote .cs-feature-title { font-size: var(--fs-h3); line-height: 1.15; letter-spacing: -0.01em; }
:root .cs-nav-btn { font-size: var(--fs-h4); line-height: 1.2; letter-spacing: -0.01em; }
/* Phones: the feature statement runs the full text width (components/cs-feature.css), so it
   drops a step in size and opens up its leading to stay easy to read over six or seven lines.
   Section headings further down the page (Product Opportunity, Impact, More features) sit
   left, on the same edge as the copy under them; the hero and the feature stay centred. */
@media (max-width: 767px) {
  :root .cs-feature-title { font-size: 24px; line-height: 1.35; }
  :root .cs-feature--quote .cs-feature-title { font-size: 21px; line-height: 1.4; }
  :root .my-role-heading,
  :root .cs-impact-title,
  :root .cs-scroll-title,
  :root .cs-scroll-note { text-align: left; }
  /* The Impact block takes only the gutter (its cards run wider), so its title steps in by the
     page padding to land on the same edge as the other headings and the card copy. */
  :root .cs-impact-title { padding-inline: var(--pad, 20px); }
}
/* Narrow phones: a smaller name and arrow leave room for two-word names on one line. */
@media (max-width: 560px) {
  :root .next-case__name { font-size: min(36px, 9.6vw); line-height: 1.02; }
}
/* Not on the scale yet: these only appear on other case studies. */
:root .overview-statement,
:root .cs-compare-eyebrow,
:root .cs-compare-title { letter-spacing: -0.015em; }
:root .pull-quote-text,
:root .cs-facts-title { letter-spacing: -0.01em; }

/* ─── Satoshi text ─────────────────────────────────────────── */
:root .case-hero-desc { font-size: var(--fs-intro); line-height: 1.32; letter-spacing: -0.01em; }
/* Same as the homepage highlight cards (.hl-title). */
:root .role-card-title { font-family: var(--sans); font-size: var(--fs-title); font-weight: 500; line-height: 1.15; letter-spacing: -0.02em; }
:root .cs-compare-body,
:root .next-case__desc { font-size: var(--fs-body-l); line-height: 1.55; letter-spacing: -0.01em; }
/* Titles and their descriptions share a size: weight and colour tell them apart. */
:root .cs-fix-title,
:root .cs-fix-body,
:root .cs-insights-intro,
:root .cs-insight-label,
:root .cs-insight-context,
:root .cs-impact-q,
:root .cs-impact-label,
:root .cs-impact-lead,
:root .cs-credits-item { font-size: var(--fs-body); line-height: 1.45; letter-spacing: 0; }
/* Two lines reserved at 1.45, so the numbers line up across the row. */
:root .cs-impact-q { min-height: 2.9em; }
:root .cs-market-name,
:root .cs-stat-label,
:root .cs-insights-note,
:root .cs-impact-meta,
:root .cs-impact-bar-cap,
:root .cs-impact-callout { font-size: var(--fs-small); line-height: 1.45; letter-spacing: 0; }
:root .cs-panel-btn { font-size: var(--fs-small); letter-spacing: 0; }

/* ─── Satoshi labels ───────────────────────────────────────── */
:root .case-hero-role,
:root .role-card-eyebrow,
:root .cs-feature-eyebrow,
:root .cs-feature-cite,
:root .cs-compare-lead,
:root .cs-scroll-eyebrow,
:root .cs-impact-kind,
:root .cs-impact-drawer-count,
:root .cs-credits-label {
  font-family: var(--sans);
  font-size: var(--fs-label);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-light);
}
/* A toggletip inside a label reads as Small text, not as part of the label. */
:root .cs-compare-lead .cs-info-tip { font-size: var(--fs-small); text-transform: none; }
:root .cs-compare-lead .cs-info { vertical-align: -4px; } /* centres the icon on the caps */
/* The feature pins its own palette, so its eyebrow and cite follow that. */
:root .cs-feature-eyebrow,
:root .cs-feature-cite { color: var(--cf-ink-muted); }
:root .cs-feature--dark { --cf-ink-muted: #B5B2AC; }
