/* ═══════════════════════════════ type ═══════════════════════════════
   Seven roles (the site refresh, 2026-09-23 — claude/SITE_REFRESH_2026_09_23.md). Every font-size on a
   live website surface is one of these — scripts/check_web_type_tokens.py fails the build on a literal.
   2026-10-14 (claude/WEB_READABLE_2026_10_14.md): the whole scale moved up a step — "the text seems a bit too
   small overall" — and the top of it spread out, so a page's name, a section and a row read as three levels.
   2026-10-23 (simplify §7.3 — "some of the text is still too small"): one more step up across the board:
     Title     30 / 600, −0.02em, lh 1.25 — the page's name, ONE per page          --fs-h1
     Section   24 / 600, −0.01em, lh 1.3  — h2 in the main column; key numbers     --fs-h2
     Headline  20 / 600 (400 for a lead sentence), lh 1.4 — what a card or row is about   --fs-lead
     Read      17 / 400, lh 1.6 — prose: posts, answers, the case, memos, the reader --fs-prose
     UI        16 / 400·500 (600 for a table row's title), lh 1.45 — rail, menus, fields, cells  --fs-body
     Secondary 15 / 400, lh 1.45 — one-liners, snippets, meta sentences, status lines --fs-sm
     Label     13 / 500 (eyebrows 13/600 caps +0.06em), tabular — stamps, counts, badges. Never a sentence  --fs-meta
   Rules: nothing that reads as a sentence below 15; nothing inside content above Section (headings in an
   answer cap at Headline); three weights (400 · 500 · 600); numbers are Geist with tabular figures (Geist
   Mono only for emails and code). 28 (display) is the public pages' and untouched. */
:root {
  --fs-meta:13px; --fs-sm:15px; --fs-body:16px; --fs-prose:17px; --fs-lead:20px;
  --fs-h2:24px; --fs-h1:30px; --fs-display:28px; --fs-wordmark:24px;
  --lh-tight:1.2; --lh-snug:1.4; --lh-body:1.5; --lh-loose:1.65;
  --lh-title:1.25; --lh-ui:1.45; --lh-read:1.6;
  --ls-title:-0.02em; --ls-section:-0.01em; --ls-eyebrow:0.06em;
  --fw-regular:400; --fw-medium:500; --fw-semibold:600;
  --text-base:var(--fs-body); --text-meta:var(--fs-meta);
}
html { font-size:var(--fs-body); }
body, input, textarea, select, button { font-size:var(--fs-body); }
small, sub, sup { font-size:var(--fs-meta); }
b, strong, th, h1, h2, h3, h4, h5, h6 { font-weight:var(--fw-semibold); }   /* three weights: the browser's bold is 700 */
/* Explicit semantic roles for markup that cannot carry its own rule. */
.type-meta { font-size:var(--fs-meta) !important; }
.type-sm { font-size:var(--fs-sm) !important; }
.type-body { font-size:var(--fs-body) !important; }
.type-prose { font-size:var(--fs-prose) !important; }
.type-lead { font-size:var(--fs-lead) !important; }
.type-h2 { font-size:var(--fs-h2) !important; }
.type-h1 { font-size:var(--fs-h1) !important; }
.type-display { font-size:var(--fs-display) !important; }

/* ═══════════════════════════════ tokens ═══════════════════════════════
   The workspace's design tokens — ONE authority (map §10.2, 2026-09-12).

   Before this file, desk.css, workspace.css and workspace-focus.css each
   declared their own :root and the last one loaded won; the values below
   are the ones that actually won, under the map's names. The old names
   (--canvas, --ink, --blue, …) stay as aliases because six stylesheets
   and the templates use them — an alias is the consolidation, a rename
   is not. Public/entrance pages (--lp-*) and the board's paper mode keep
   their own palettes by design (§10.1: three intentional modes).

   Loaded after app.css (whose older names --text / --font-sans / --border it
   overrides, as desk.css's aliases already did) and before every desk sheet.
   Change a colour HERE. Never re-declare one of these in another file. */
:root {
  /* surfaces */
  --bg: #F8F9F5;                 /* the canvas behind everything */
  --pane: #FFFFFF;               /* the object pane, cards, sheets */
  --list: #F1F3EE;               /* the rail and the list column */
  /* text */
  --text: #222B27;
  --text-body: #3F4C44;
  --text-muted: #617066;
  --text-faint: #657168;
  /* lines */
  --hairline: #E1E6DF;
  --hairline-strong: rgba(34,43,39,.15);
  /* interaction */
  --focus: #315845;              /* the 3px focus ring */
  --accent: #315845;
  --accent-hover: #254734;
  --accent-tint: #EAF0E8;
  --accent-ring: rgba(49,88,69,.22);
  --attention: #855818;          /* needs you · stale · demo */
  --attention-tint: #F8EFDF;
  --success: #3F6B54;
  --success-tint: #ECF3ED;
  --destructive: #B91C1C;
  --destructive-tint: #FDECEC;
  --neutral-tint: rgba(11,18,32,.05);
  /* source / provider colours (CompanySignal.SOURCE_COLORS, the evidence rail) */
  --source-web: #8A94A6;
  --source-pitchbook: #E8743B;
  --source-cbinsights: #12A594;
  --source-dealcloud: #6B5B95;
  --source-company: #855818;     /* "reported by the company" — attention, not a provider */
  /* spacing — ONE scale (2026-09-21 pm): 4 · 8 · 12 · 16 · 20 · 24 · 32 · 40 · 48 · 64.
     Inside a row or card: 4 / 8 / 12. Between blocks: 16 / 24. Between sections: 32 / 40. */
  --s1:4px; --s2:8px; --s3:12px; --s4:16px; --s5:20px; --s6:24px; --s7:32px; --s8:40px; --s9:48px; --s10:64px;
  --space-1: 4px; --space-2: 8px; --space-3: 12px; --space-4: 16px; --space-5: 20px; --space-6: 24px;
  /* the pane's edge: every page's content starts here (rail + --pane-x), phones 16, narrow desks 24 */
  --pane-x: 40px; --pane-y: 28px;
  /* radii */
  --radius: 12px;
  --radius-lg: 16px;             /* = --r-sheet (the refresh: one radius scale, 4 · 8 · 12 · 16 · 999) */
  --radius-round: 999px;        /* (app.css owns --radius-pill) */
  --r-control: 8px; --r-card: 12px;   /* the refresh: 8 for controls, 12 for cards, 999 for pills */
  --r-composer: 22px;
  --r-sm: 4px; --r-sheet: 16px;       /* 4 for marks too small for a control's corner (code, bars); 16 for sheets and the composer */
  /* shadows */
  --shadow-1: 0 1px 2px rgba(11,18,32,.05);
  --shadow-2: 0 1px 2px rgba(11,18,32,.04), 0 6px 18px -6px rgba(11,18,32,.10);
  --shadow-3: 0 12px 40px -8px rgba(11,18,32,.20), 0 1px 2px rgba(11,18,32,.06);
  --shadow-composer: 0 10px 30px -10px rgba(11,18,32,.16), 0 1px 2px rgba(11,18,32,.05);
  --control-line: #D5DBD3;       /* a field's or the composer's edge — a step darker than a hairline */
  /* typography (2026-10-14: 15px UI, 16px prose, 16px controls on mobile, metadata ≥ 12px) */
  --font-sans: 'Geist', 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'Geist Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  --text-base: var(--fs-body);
  --text-meta: var(--fs-meta);
  --reading-width: 720px;        /* deliverables never run wider than this */
  /* A shared content measure for research workspaces and their composers. */
  --workspace-content-width: 840px;
  --workspace-gutter: 24px;
  --conversation-width: 760px;
  --conversation-gutter: 40px;
  /* motion */
  --motion-fast: 120ms;
  --motion-base: 200ms;
  --ease: cubic-bezier(.2,.7,.2,1);
  /* layout */
  --page-max: 1200px;            /* one page width (2026-09-22): every list page's box — content 1120 = page-max − 2 × pane-x */
  --rail-w: 224px; --list-w: 320px; --facts-w: 280px; --row: 44px; --tb-h: 72px; --workspace-bar: 52px; --demo-h: 0px;

  /* ── aliases: the desk's original vocabulary, now pointing at the tokens ── */
  --canvas: var(--bg); --col: var(--list);
  --ink: var(--text); --body: var(--text-body); --quiet: var(--text-muted); --faint: var(--text-faint);
  --hair: var(--hairline); --hair2: var(--hairline-strong);
  --blue: var(--accent); --blue-hover: var(--accent-hover); --blue-tint: var(--accent-tint); --blue-ring: var(--accent-ring);
  --amber: var(--attention); --amber-tint: var(--attention-tint);
  --green: var(--success); --green-tint: var(--success-tint);
  --red: var(--destructive); --red-tint: var(--destructive-tint); --gray-tint: var(--neutral-tint);
  --r: var(--radius); --rf: var(--radius-lg);
  --sans: var(--font-sans); --mono: var(--font-mono);
  /* older surfaces (app.css, the thread page, the retired templates' survivors) */
  --font-primary: var(--sans); --font-family-sans: var(--sans);
  --desk-row: var(--row); --desk-hairline: var(--hair); --desk-label: var(--quiet); --desk-ink: var(--ink);
  --desk-body: var(--body); --desk-quiet: var(--quiet); --desk-accent: var(--blue); --desk-attention: var(--amber);
  --desk-confirmed: var(--green);
  --color-text-primary: var(--ink); --foreground: var(--ink); --card-foreground: var(--ink);
  --surface-50: var(--canvas); --background: var(--canvas);
  --border: var(--hair2); --border-soft: var(--hair); --color-border: var(--hair2); --color-border-light: var(--hair);
  --radius-md: var(--r); --radius-lg: var(--r); --radius-xl: var(--rf); --radius-2xl: var(--rf);
}
/* Breakpoint overrides of the layout tokens (the rail folding, the bar
   shrinking) stay with the layout that needs them: workspace.css and
   workspace-focus.css. Colours and type are never overridden anywhere. */

/* The simple company, memory and conversation surfaces share a reading measure. */
@media (max-width:1100px) { :root { --conversation-gutter:24px; } }
@media (max-width:640px) { :root { --conversation-gutter:16px; } }
