/* Design-system base and text roles, shared by every page on the system
   (D25). Load order: css/tokens.css, this file, then the page stylesheet.
   Moved here from css/work-gemstones.css on 2026-10-21 without changes. */
* { box-sizing: border-box; }
html { -webkit-tap-highlight-color: transparent; } /* no tap flash on any element; the chips have a pressed state instead */

body {
  margin: 0;
  background: var(--surface-page);
  color: var(--text-body);
  font-family: var(--font-funnel-sans);
  -webkit-font-smoothing: antialiased;
}

p { margin: 0; }

/* ---------- type ---------- */
/* Text roles, named by the job the text does (D34; final names D69). One class per Figma text style, same name: text/display = .display.
   Each class takes its whole style from one --type-<role> token (css/tokens.css), so the size follows the mode (54/32, 36/32 and
   26/22 switch at 780/781; the rest are one size). The HTML element is chosen by the page outline, not by the role.
   Literata (display voice), Funnel Sans (reading), Martian Mono (labels and captions, tracked 0.5). */
/* display: the biggest line of a page or section (page title, home section titles, the emoji line above them, the next-case title, phone menu links) */
.display { font: var(--type-display); color: var(--text-secondary); margin: 0; }
/* heading: a section heading inside a page (a case study's "The ask."), and headline stat numbers */
.heading { font: var(--type-heading); color: var(--text-secondary); margin: 0; }
/* statement: a highlighted statement (takeaway, pull-quote, callout, closing line, cover and CV role titles); accent unless a context sets the colour */
.statement { font: var(--type-statement); color: var(--text-accent); margin: 0; }
/* body-highlight: the paragraph that leads a page or block (the home tagline, a case study's summary and outcomes, the CV summary) */
.body-highlight { font: var(--type-body-highlight); color: var(--text-body); margin: 0; }
/* body-default: running text */
.body-default { font: var(--type-body-default); color: var(--text-body); margin: 0; }
/* label-section: a small uppercase label that names a section, a value or a block (WORK, ROLE, ROUND 1, SOLUTION A), buttons and hints */
.label-section { font: var(--type-label-section); letter-spacing: var(--letter-spacing-0-5); text-transform: uppercase; color: var(--text-accent); margin: 0; }
/* caption: small mono text (values, results, chart caption, colophon, dates) */
.caption { font: var(--type-caption); letter-spacing: var(--letter-spacing-0-5); margin: 0; }
/* label-nav: the label of a nav control, SemiBold (nav pills, the ToC, the copy chip, the Before/After pills, CV links) */
.label-nav { font: var(--type-label-nav); letter-spacing: var(--letter-spacing-0-5); text-transform: uppercase; margin: 0; }
/* Screen-reader-only text: in the accessibility tree, not on screen. */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; /* @raw-ok idiom: the standard visually-hidden pattern */ overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
/* One focus indicator for every control on the page (a11y A1, I14).
   Neutral passes 3:1 on every backdrop it can sit on: surface 14.2:1,
   accent 4.45:1. Section blocks receive focus only programmatically (ToC
   jumps), so they don't draw a ring around the whole section. */
:focus-visible { outline: var(--border-2) solid var(--focus-ring); outline-offset: var(--focus-offset); }

/* Nav pill (Figma Resume nav 1835:4292, Home 1843:6613, section pill 1861:8936; D64): the header's frosted control, 56px high, Martian Mono
   SemiBold 10 uppercase on the glass. Two variations by where the icon sits: trailing (the default: 20 before the label, 12 after the
   icon: View resume, the phone section pill) and --lead (12 before the icon, 20 after the label: Home). Each icon is a mask of a Bold
   glyph, so it takes the label colour. */
.nav-pill {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--gap-stack);
  height: var(--nav-pill-control); margin: 0;
  padding: var(--inset-tight) var(--inset-compact) var(--inset-tight) var(--inset-card);
  border: 0; border-radius: var(--radius-pill);
  background: var(--nav-pill-glass); -webkit-backdrop-filter: blur(var(--nav-pill-glass-blur)); backdrop-filter: blur(var(--nav-pill-glass-blur));
  font: var(--nav-pill-label); letter-spacing: var(--nav-pill-tracking); text-transform: uppercase; color: var(--text-on-light);
  text-decoration: none; white-space: nowrap; cursor: pointer;
}
.nav-pill[hidden] { display: none; }
@media (hover: hover) { .nav-pill:hover { background: var(--nav-pill-glass-active); } } /* not on touch, where :hover sticks after a tap */
.nav-pill:active { background: var(--nav-pill-glass-active); } /* the press, which lets go with the finger */
.nav-pill:focus-visible { outline-color: var(--focus-ring-on-light); outline-offset: calc(var(--border-2) * -1); } /* indigo, inside the control: the pale page ring vanishes on pale glass (D58 review) */
.nav-pill--lead { justify-content: flex-start; padding: var(--inset-tight) var(--inset-card) var(--inset-tight) var(--inset-compact); min-width: 110px; } /* @raw-ok measure: Figma 1843:6613, Home is 110 wide */
.nav-pill__icon { flex: none; width: var(--size-icon-16); height: var(--size-icon-16); background: currentColor; -webkit-mask: var(--nav-pill-icon) center / contain no-repeat; mask: var(--nav-pill-icon) center / contain no-repeat; }
.nav-pill__icon--file-text { --nav-pill-icon: url(../assets/icons/bold/file-text.svg); }
.nav-pill__icon--arrow-left { --nav-pill-icon: url(../assets/icons/bold/arrow-left.svg); }
.nav-pill__icon--caret-down { --nav-pill-icon: url(../assets/icons/bold/caret-down.svg); }
.nav-pill__icon--download { --nav-pill-icon: url(../assets/icons/bold/download.svg); }
.nav-pill__icon--file-pdf { --nav-pill-icon: url(../assets/icons/bold/file-pdf.svg); }
.nav-pill__icon--file-doc { --nav-pill-icon: url(../assets/icons/bold/file-doc.svg); }
.nav-pill[aria-expanded="true"] .nav-pill__icon--caret-down { transform: rotate(180deg); } /* the same glyph, up, while the list is open (Figma 1861:9090) */

/* Action chip (Foundations 1328:8963): copy (button) or link (anchor), same surface and size. Moved here from css/home.css so the case studies
   Back chip can use it (the Résumé, LinkedIn and copy chips on the home page are the same component). */
.action-chip {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--gap-tight); /* Figma 1328:8962: 8, was 12 */
  height: 36px; /* @raw-ok measure: one-off, the action chip's height (Figma 1328:8962) */
  padding: var(--inset-tight) var(--inset-compact);
  border: 0; border-radius: var(--radius-compact);
  background: var(--surface-shade); color: var(--text-body);
  text-decoration: none; white-space: nowrap; cursor: pointer;
}
@media (hover: hover) { .action-chip:hover { background: var(--surface-tint); } }
.action-chip:active { background: var(--surface-tint); } /* State=Pressed 1778:8602: the tint fill, so a touch is acknowledged without a tap flash */ /* State=Hover 1360:9311; pointer devices only, so a tap never leaves it behind */
/* Touch size (Figma Action chip, Size=Touch): 44px high, no fill and no hover fill; the phone top bar's chips (Ioli, 2026-10-27) */
@media (max-width: 780px) {
  .action-chip--touch, .action-chip--touch:hover { height: var(--size-touch); background: none; }
  /* No fill to change, so pressing dims the chip for a moment instead (Ioli, 2026-10-27) */
  .action-chip--touch { transition: opacity var(--duration-200) var(--ease-fast-out-slow-in); }
  .action-chip--touch:active { background: none; opacity: var(--opacity-60); }
}
@media (max-width: 780px) and (prefers-reduced-motion: reduce) { .action-chip--touch { transition: none; } }
.action-chip__icon { width: var(--size-icon-20); height: var(--size-icon-20); display: block; flex-shrink: 0; }
.action-chip__icon[hidden] { display: none; }

/* ToC panel (Figma 1849:8423, 1914:7511; D72): the frosted panel the phone ToC and the CV's Download pill open: the frosted surface, a label-section title,
   44px rows 20px apart with the label 20px in, and the dark focus ring inside the row (the page's pale ring is 1.3–2.7:1 on the glass). Phones only. */
@media (min-width: 781px) { .wg-toc-panel__list { margin: 0; padding: 0; list-style: none; } } /* hidden then (the phone ToC is phones only); reset as the other lists are */
@media (max-width: 780px) {
  .wg-toc-panel { background: var(--toc-glass); -webkit-backdrop-filter: blur(var(--toc-glass-blur)); backdrop-filter: blur(var(--toc-glass-blur)); color: var(--text-on-light); }
  .wg-toc-panel__title { display: block; margin: 0; padding: var(--inset-card) var(--inset-panel) 0; color: var(--text-on-light); }
  .wg-toc-panel__list { display: flex; flex-direction: column; gap: var(--gap-group); margin: 0; list-style: none; padding: var(--gap-group) var(--inset-panel) var(--inset-card); }
  .wg-toc-panel__link {
    display: flex; align-items: center; min-height: var(--size-touch); padding: var(--spacing-4) var(--inset-card);
    border-radius: var(--radius-12); color: var(--text-on-light); text-decoration: none;
  }
  .wg-toc-panel__link:focus-visible { outline: var(--border-2) solid var(--focus-ring-on-light); outline-offset: calc(var(--border-2) * -1); }
}
