/* ==========================================================================
   The Convergence — global stylesheet
   Aesthetic: "the ReThink observatory at night" — the warm-broadsheet system
   from The ReThink (cream paper, warm ink, ONE dawn-amber accent, Fraunces +
   Newsreader) inverted to its warm-night dark mode as the DEFAULT, because
   this property is an instrument panel you read after dark. Light mode is the
   toggle, not the home. Components consume ONLY tier-2 semantic tokens.
   ========================================================================== */

/* --------------------------------------------------------------------------
   0 · Self-hosted variable fonts (same faces as The ReThink)
   -------------------------------------------------------------------------- */
@font-face {
  font-family: 'Fraunces Variable';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('./fonts/fraunces-wght.woff2') format('woff2-variations');
}
@font-face {
  font-family: 'Fraunces Variable';
  font-style: italic;
  font-weight: 100 900;
  font-display: swap;
  src: url('./fonts/fraunces-wght-italic.woff2') format('woff2-variations');
}
@font-face {
  font-family: 'Newsreader Variable';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('./fonts/newsreader-wght.woff2') format('woff2-variations');
}
@font-face {
  font-family: 'Newsreader Variable';
  font-style: italic;
  font-weight: 100 900;
  font-display: swap;
  src: url('./fonts/newsreader-wght-italic.woff2') format('woff2-variations');
}

/* --------------------------------------------------------------------------
   1 · Tokens — Tier 1 primitives (identical to The ReThink) + Tier 2 semantic
       (DARK default — the observatory; light is the visitor)
   -------------------------------------------------------------------------- */
:root {
  color-scheme: dark;

  /* Tier 1 — Paper: warm cream family */
  --paper-50:  oklch(0.977 0.009 85);
  --paper-100: oklch(0.955 0.013 84);
  --paper-200: oklch(0.925 0.017 82);
  --paper-300: oklch(0.880 0.020 80);

  /* Tier 1 — Ink: warm brown-charcoal family */
  --ink-950: oklch(0.215 0.016 60);
  --ink-800: oklch(0.320 0.020 58);
  --ink-600: oklch(0.455 0.022 57);
  --ink-400: oklch(0.610 0.020 60);
  --ink-300: oklch(0.700 0.016 62);

  /* Tier 1 — Night: warm dark surfaces */
  --night-975: oklch(0.160 0.012 66);
  --night-950: oklch(0.185 0.014 65);
  --night-900: oklch(0.225 0.016 63);
  --night-800: oklch(0.275 0.018 62);

  /* Tier 1 — Dawn: the ONE accent, amber first-light */
  --dawn-200: oklch(0.880 0.085 80);
  --dawn-300: oklch(0.840 0.110 75);
  --dawn-500: oklch(0.720 0.140 65);
  --dawn-600: oklch(0.620 0.130 55);
  --dawn-700: oklch(0.505 0.110 50);

  /* Tier 2 — semantic (DARK default) */
  --surface:        var(--night-950);
  --surface-deep:   var(--night-975);
  --surface-raised: var(--night-900);
  --surface-inset:  var(--night-800);

  --ink:       var(--paper-100);
  --ink-muted: var(--ink-300);
  --ink-faint: oklch(0.520 0.018 62);

  --accent:        var(--dawn-300);
  --accent-strong: var(--dawn-200);
  --accent-soft:   var(--dawn-500);

  --rule:        color-mix(in oklch, var(--paper-100) 15%, transparent);
  --rule-strong: color-mix(in oklch, var(--paper-100) 42%, transparent);
  --highlight:   color-mix(in oklch, var(--dawn-500) 28%, transparent);
  --focus:       var(--dawn-300);

  /* Chart tokens */
  --chart-line:   var(--dawn-300);
  --chart-fill:   color-mix(in oklch, var(--dawn-500) 14%, transparent);
  --chart-grid:   color-mix(in oklch, var(--paper-100) 9%, transparent);
  --chart-axis:   var(--ink-faint);
  --chart-dot:    var(--dawn-200);

  /* Typography */
  --font-display: 'Fraunces Variable', Georgia, 'Times New Roman', serif;
  --font-body:    'Newsreader Variable', Georgia, 'Times New Roman', serif;
  --font-figures: 'Fraunces Variable', Georgia, serif;

  /* Modular scale — ratio 1.25, base 1.125rem (same as The ReThink) */
  --text-xs:   0.72rem;
  --text-sm:   0.9rem;
  --text-base: 1.125rem;
  --text-md:   1.406rem;
  --text-lg:   1.758rem;
  --text-xl:   2.197rem;
  --text-2xl:  2.747rem;
  --text-3xl:  clamp(2.5rem, 1.6rem + 3.5vw, 3.433rem);
  --text-4xl:  clamp(2.75rem, 1.5rem + 5vw, 4.292rem);

  /* Spacing (4px grid) */
  --space-1: 0.25rem;  --space-2: 0.5rem;  --space-3: 0.75rem;  --space-4: 1rem;
  --space-6: 1.5rem;   --space-8: 2rem;    --space-12: 3rem;    --space-16: 4rem;
  --space-24: 6rem;    --space-32: 8rem;

  /* Radii — editorial = mostly square */
  --radius-xs: 2px;
  --radius-sm: 4px;
  --radius-md: 8px;

  --shadow-1: 0 1px 2px oklch(0.1 0.01 60 / 0.25);
  --shadow-2: 0 2px 10px oklch(0.1 0.01 60 / 0.35), 0 1px 2px oklch(0.1 0.01 60 / 0.25);
}

/* Tier 2 — light remap (the ReThink's paper daylight). Primitives unchanged. */
[data-theme='light'] {
  color-scheme: light;

  --surface:        var(--paper-50);
  --surface-deep:   var(--paper-100);
  --surface-raised: var(--paper-100);
  --surface-inset:  var(--paper-200);

  --ink:       var(--ink-950);
  --ink-muted: var(--ink-600);
  --ink-faint: var(--ink-400);

  --accent:        var(--dawn-600);
  --accent-strong: var(--dawn-700);
  --accent-soft:   var(--dawn-300);

  --rule:        color-mix(in oklch, var(--ink-950) 14%, transparent);
  --rule-strong: color-mix(in oklch, var(--ink-950) 40%, transparent);
  --highlight:   color-mix(in oklch, var(--dawn-300) 30%, transparent);
  --focus:       var(--dawn-600);

  --chart-line:   var(--dawn-600);
  --chart-fill:   color-mix(in oklch, var(--dawn-300) 22%, transparent);
  --chart-grid:   color-mix(in oklch, var(--ink-950) 9%, transparent);
  --chart-axis:   var(--ink-400);
  --chart-dot:    var(--dawn-700);

  --shadow-1: 0 1px 2px oklch(0.215 0.016 60 / 0.05);
  --shadow-2: 0 2px 8px oklch(0.215 0.016 60 / 0.07), 0 1px 2px oklch(0.215 0.016 60 / 0.05);
}

/* --------------------------------------------------------------------------
   2 · Base
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.65;
  font-optical-sizing: auto;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 580;
  font-variation-settings: 'SOFT' 40, 'WONK' 0;
  line-height: 1.2;
  margin: 0 0 var(--space-4);
  text-wrap: balance;
}
h1 { font-size: var(--text-2xl); line-height: 1.12; letter-spacing: -0.01em; }
h2 { font-size: var(--text-xl);  line-height: 1.2;  letter-spacing: -0.01em; }
h3 { font-size: var(--text-lg);  line-height: 1.3; }

p, ul, ol { margin: 0 0 var(--space-4); }
img, svg { max-width: 100%; }

a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 0.15em;
  text-decoration-thickness: 1px;
  transition: color 150ms ease;
}
a:hover { color: var(--accent-strong); text-decoration-thickness: 2px; }

::selection { background: var(--highlight); }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

/* Dawn rule — the family mark. Every <hr> is one. */
hr, .dawn-rule {
  border: 0;
  height: 1px;
  margin: var(--space-16) auto;
  background: linear-gradient(90deg,
    var(--rule) 0%, var(--rule) 38%,
    var(--accent) 50%,
    var(--rule) 62%, var(--rule) 100%);
}

.dawn-text {
  font-style: normal;
  background: linear-gradient(100deg, var(--accent-strong), var(--accent) 55%, var(--accent-soft));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.h-orn { font-size: 0.6em; margin-left: 0.4em; opacity: 0.85; vertical-align: 0.08em; }

/* --------------------------------------------------------------------------
   3 · Utilities & layout
   -------------------------------------------------------------------------- */
.wrap { max-width: 72rem; margin-inline: auto; padding-inline: var(--space-4); }
@media (min-width: 48rem) { .wrap { padding-inline: var(--space-8); } }

.section { padding-block: var(--space-12); }
@media (min-width: 48rem) { .section { padding-block: var(--space-16); } }

.measure { max-width: 42rem; margin-inline: auto; }
.measure h2:not(:first-child) { margin-top: var(--space-12); }
.measure h3:not(:first-child) { margin-top: var(--space-8); }

.band {
  background: var(--surface-raised);
  border-block: 1px solid var(--rule);
  padding-block: var(--space-12);
}
@media (min-width: 48rem) { .band { padding-block: var(--space-16); } }

.kicker {
  font-family: var(--font-display);
  font-weight: 500;
  font-variant-caps: all-small-caps;
  letter-spacing: 0.06em;
  font-size: var(--text-sm);
  color: var(--ink-muted);
  margin: 0 0 var(--space-3);
}

.standfirst { font-size: var(--text-md); line-height: 1.45; color: var(--ink-muted); font-style: italic; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 30;
  background: var(--surface-raised); color: var(--ink);
  padding: var(--space-2) var(--space-4);
  border: 1px solid var(--rule); border-radius: var(--radius-sm);
}
.skip-link:focus { left: var(--space-2); top: var(--space-2); }

/* --------------------------------------------------------------------------
   4 · Header / footer
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in oklch, var(--surface) 88%, transparent);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--rule);
}
.site-header-bar {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: var(--space-2) var(--space-4);
  min-height: 56px; padding-block: var(--space-2);
}
.wordmark {
  font-family: var(--font-display);
  font-weight: 600;
  font-variation-settings: 'SOFT' 40, 'WONK' 1;
  font-size: 1.25rem;
  color: var(--ink);
  text-decoration: none;
}
.wordmark:hover { color: var(--ink); text-decoration: none; }
.site-nav { display: flex; align-items: center; flex-wrap: wrap; gap: var(--space-2) var(--space-4); }
@media (min-width: 48rem) { .site-nav { gap: var(--space-6); } }
.site-nav a {
  font-size: var(--text-sm); letter-spacing: 0.01em;
  color: var(--ink-muted); text-decoration: none;
}
.site-nav a:hover {
  color: var(--accent-strong);
  text-decoration: underline; text-underline-offset: 0.35em; text-decoration-thickness: 1px;
}

.theme-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border: 0; border-radius: 999px;
  background: transparent; color: var(--ink-muted); cursor: pointer;
  transition: background-color 150ms ease, color 150ms ease;
}
.theme-toggle:hover { background: var(--surface-inset); color: var(--ink); }
.theme-toggle .icon-moon { display: none; }
[data-theme='light'] .theme-toggle .icon-moon { display: block; }
[data-theme='light'] .theme-toggle .icon-sun { display: none; }
.no-js .theme-toggle { display: none; }

.site-footer {
  margin-top: var(--space-16);
  background: var(--surface-deep);
  border-top: 1px solid var(--rule);
  font-size: var(--text-sm);
  color: var(--ink-muted);
}
.footer-inner { padding-block: var(--space-8); display: grid; gap: var(--space-3); }
.footer-inner p { margin: 0; }
.footer-links { display: flex; flex-wrap: wrap; gap: var(--space-4); }

/* --------------------------------------------------------------------------
   5 · Hero + the Overturn motif
   -------------------------------------------------------------------------- */
.hero { padding-block: var(--space-16) var(--space-8); }
@media (min-width: 48rem) { .hero { padding-block: var(--space-24) var(--space-12); } }
.hero-sub { max-width: 42rem; font-size: var(--text-md); line-height: 1.5; color: var(--ink-muted); }

.overturn { display: grid; gap: var(--space-3); font-family: var(--font-display); margin: 0; }
.overturn h1, .overturn p { margin: 0; }
.overturn-old {
  position: relative; align-self: start; justify-self: start;
  text-decoration: none; color: var(--ink);
  font-variation-settings: 'SOFT' 40, 'WONK' 1;
  transition: color 900ms ease 300ms;
}
.overturn-old::after {
  /* one bar per wrapped line: a repeating gradient tiled to the line box,
     revealed left-to-right by animating clip-path (scaleX only drew one bar
     across the whole element, so wraps past line 1 went unstruck). */
  content: ""; position: absolute; inset: 0;
  background-image: repeating-linear-gradient(to bottom,
    transparent 0, transparent calc(50% - 0.045em),
    var(--accent) calc(50% - 0.045em), var(--accent) calc(50% + 0.045em),
    transparent calc(50% + 0.045em), transparent 1lh);
  clip-path: inset(0 100% 0 0);
  transition: clip-path 700ms cubic-bezier(0.65, 0, 0.35, 1);
}
.overturn-new {
  opacity: 0; transform: translateY(0.5em);
  font-variation-settings: 'SOFT' 40, 'WONK' 1;
  transition: opacity 800ms ease 750ms, transform 800ms ease 750ms;
}
.overturn.is-turned .overturn-old        { color: var(--ink-faint); }
.overturn.is-turned .overturn-old::after { clip-path: inset(0 0 0 0); }
.overturn.is-turned .overturn-new        { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .overturn-old, .overturn-old::after, .overturn-new { transition: none; }
}
.no-js .overturn .overturn-old        { color: var(--ink-faint); }
.no-js .overturn .overturn-old::after { clip-path: inset(0 0 0 0); }
.no-js .overturn .overturn-new        { opacity: 1; transform: none; }

.hero-overturn { max-width: 52rem; margin-block: var(--space-6) var(--space-8); }
.hero-overturn .overturn-old { font-size: var(--text-xl); font-weight: 500; line-height: 1.2; }
.hero-overturn .overturn-new { font-size: var(--text-3xl); font-weight: 590; line-height: 1.06; letter-spacing: -0.01em; }
@media (min-width: 64rem) {
  .hero-overturn .overturn-new { font-size: var(--text-4xl); line-height: 1.02; }
}

/* --------------------------------------------------------------------------
   6 · The Index panel — the instrument at the top
   -------------------------------------------------------------------------- */
.index-panel {
  background: var(--surface-deep);
  border: 1px solid var(--rule);
  border-radius: var(--radius-md);
  padding: var(--space-8) var(--space-6);
  box-shadow: var(--shadow-2);
}
@media (min-width: 48rem) { .index-panel { padding: var(--space-12) var(--space-8); } }

.index-label {
  display: flex; flex-wrap: wrap; align-items: baseline;
  gap: var(--space-2) var(--space-4);
  margin-bottom: var(--space-6);
}
.index-label .kicker { margin: 0; }

/* The honesty chip — always visible, part of the instrument itself */
.thesis-chip {
  display: inline-block;
  font-family: var(--font-display);
  font-variant-caps: all-small-caps;
  letter-spacing: 0.08em;
  font-size: var(--text-sm);
  color: var(--accent);
  border: 1px solid color-mix(in oklch, var(--accent) 45%, transparent);
  border-radius: 999px;
  padding: 0.1em 0.8em;
}

.index-grid { display: grid; gap: var(--space-8); }
@media (min-width: 56rem) {
  .index-grid { grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: var(--space-12); }
}
.index-bars, .index-bar, .index-bar-head { min-width: 0; }

.index-dial { display: grid; justify-items: center; gap: var(--space-2); }
.index-dial svg { width: min(15rem, 62vw); height: auto; }
.index-reading {
  font-family: var(--font-figures);
  font-weight: 590;
  font-variation-settings: 'SOFT' 40, 'WONK' 0;
  font-size: var(--text-4xl);
  line-height: 1;
  letter-spacing: -0.02em;
}
.index-reading .index-outof { font-size: 0.4em; color: var(--ink-muted); font-weight: 500; letter-spacing: 0; }
.index-dial-caption { font-size: var(--text-sm); color: var(--ink-muted); text-align: center; max-width: 16rem; }

.index-bars { display: grid; gap: var(--space-4); }
.index-bar { display: grid; gap: var(--space-1); }
.index-bar-head {
  display: flex; justify-content: space-between; align-items: baseline; gap: var(--space-4);
  font-size: var(--text-sm);
}
.index-bar-name { color: var(--ink); font-family: var(--font-display); font-weight: 560; }
.index-bar-name a { color: inherit; text-decoration: none; }
.index-bar-name a:hover { color: var(--accent-strong); }
.index-bar-pct { color: var(--ink-muted); font-variant-numeric: tabular-nums; text-align: right; }
.index-bar-track {
  height: 6px; border-radius: 999px;
  background: var(--surface-inset);
  overflow: hidden;
}
.index-bar-fill {
  height: 100%; border-radius: 999px;
  background: linear-gradient(90deg, var(--accent-soft), var(--accent));
  transform-origin: left center;
}
.index-foot {
  margin-top: var(--space-6);
  padding-top: var(--space-4);
  border-top: 1px solid var(--rule);
  font-size: var(--text-sm);
  color: var(--ink-muted);
}
.index-foot p { margin: 0 0 var(--space-2); }
.index-foot p:last-child { margin: 0; }

/* --------------------------------------------------------------------------
   7 · Trend cards — the gauges
   -------------------------------------------------------------------------- */
.gauges { display: grid; gap: var(--space-8); }
@media (min-width: 56rem) { .gauges { grid-template-columns: 1fr 1fr; } }

.gauge {
  background: var(--surface-raised);
  border: 1px solid var(--rule);
  border-radius: var(--radius-md);
  padding: var(--space-6);
  display: grid;
  gap: var(--space-3);
  align-content: start;
}
.gauge-kicker {
  display: flex; justify-content: space-between; align-items: baseline; gap: var(--space-4);
  font-family: var(--font-display);
  font-variant-caps: all-small-caps;
  letter-spacing: 0.06em;
  font-size: var(--text-sm);
  color: var(--ink-muted);
}
.gauge-no { color: var(--accent); white-space: nowrap; }
.gauge h3 { margin: 0; font-size: var(--text-lg); }
.gauge-reading {
  font-family: var(--font-figures);
  font-size: var(--text-md);
  font-weight: 560;
  color: var(--ink);
}
.gauge-reading .gauge-reading-note { font-family: var(--font-body); font-size: var(--text-sm); font-weight: 400; color: var(--ink-muted); }
.gauge-chart svg { display: block; width: 100%; height: auto; }
.gauge-why { font-size: var(--text-base); color: var(--ink-muted); margin: 0; }
.gauge-caveat {
  font-size: var(--text-sm); color: var(--ink-faint); margin: 0;
  border-left: 2px solid var(--rule); padding-left: var(--space-3);
}
.gauge-source {
  font-size: var(--text-sm); color: var(--ink-muted); margin: 0;
  padding-top: var(--space-2); border-top: 1px solid var(--rule);
}

/* Chart text (inside SVG) */
.chart-tick { font-family: var(--font-body); font-size: 12px; fill: var(--chart-axis); }
.chart-annot { font-family: var(--font-display); font-size: 12.5px; font-weight: 560; fill: var(--ink); }
.chart-annot-muted { font-family: var(--font-body); font-size: 11.5px; fill: var(--chart-axis); }

/* --------------------------------------------------------------------------
   8 · Prose + fine print (identical furniture to The ReThink)
   -------------------------------------------------------------------------- */
.prose { max-width: 42rem; margin-inline: auto; }
.prose p, .prose ul, .prose ol { margin: 0 0 var(--space-4); }
.prose li { margin-bottom: var(--space-2); }
.prose strong { font-weight: 650; }
.prose h2 { font-size: var(--text-xl); margin: var(--space-12) 0 var(--space-4); }
.prose h3 { font-size: var(--text-lg); margin: var(--space-8) 0 var(--space-3); }
.prose hr { margin: var(--space-12) auto; }
.prose blockquote {
  margin: var(--space-12) 0;
  padding-left: var(--space-6);
  border-left: 2px solid var(--accent);
  font-family: var(--font-display);
  font-size: var(--text-md);
  font-style: italic;
  line-height: 1.45;
}
.prose blockquote p { margin: 0 0 var(--space-2); }

.fine-print {
  background: var(--surface-inset);
  border: 1px solid var(--rule);
  border-radius: var(--radius-md);
  padding: var(--space-6);
  margin: var(--space-12) 0;
  font-size: var(--text-sm);
}
.fine-print h2, .fine-print h3, .fine-print .fine-print-heading {
  font-family: var(--font-display);
  font-weight: 500;
  font-variant-caps: all-small-caps;
  letter-spacing: 0.06em;
  font-size: var(--text-base);
  margin: 0 0 var(--space-2);
}
.fine-print ul { padding-left: 1.1em; margin: 0; }
.fine-print li { margin-bottom: var(--space-2); }
.fine-print p { margin: 0 0 var(--space-3); }
.fine-print p:last-child { margin: 0; }

/* Methodology table */
.method-table-wrap { overflow-x: auto; margin: var(--space-6) 0; }
.method-table {
  width: 100%; min-width: 40rem;
  border-collapse: collapse;
  font-size: var(--text-sm);
}
.method-table th, .method-table td {
  text-align: left; vertical-align: top;
  padding: var(--space-3) var(--space-4) var(--space-3) 0;
  border-bottom: 1px solid var(--rule);
}
.method-table th {
  font-family: var(--font-display);
  font-variant-caps: all-small-caps;
  letter-spacing: 0.06em;
  font-weight: 500;
  color: var(--ink-muted);
}
.method-table td { color: var(--ink-muted); }
.method-table td:first-child { color: var(--ink); font-family: var(--font-display); font-weight: 560; }
.method-table .num { font-variant-numeric: tabular-nums; white-space: nowrap; }

/* Watch ledger (what to watch) */
.ledger { list-style: none; margin: 0; padding: 0; }
.ledger-row { border-top: 1px solid var(--rule); padding-block: var(--space-6); }
.ledger-row:last-child { border-bottom: 1px solid var(--rule); }
.ledger-row h3 { font-size: var(--text-base); margin: 0 0 var(--space-2); }
.ledger-row p { margin: 0; color: var(--ink-muted); font-size: var(--text-base); }

/* --------------------------------------------------------------------------
   9 · The Ride pillar — constraints backbone + solutions + level tags
   -------------------------------------------------------------------------- */
.pillar-bridge {
  background: var(--surface-deep);
  border: 1px solid var(--rule);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius-md);
  padding: var(--space-8) var(--space-6);
  max-width: 48rem;
  margin-inline: auto;
}
.pillar-bridge h2 { margin-top: 0; }
.pillar-bridge p:last-child { margin-bottom: 0; }

/* Level tags — the three-level honesty system */
.tag {
  display: inline-block;
  font-family: var(--font-display);
  font-variant-caps: all-small-caps;
  letter-spacing: 0.05em;
  font-size: var(--text-xs);
  line-height: 1.6;
  border: 1px solid var(--rule-strong);
  border-radius: 999px;
  padding: 0.05em 0.7em;
  white-space: nowrap;
  color: var(--ink-muted);
}
.tag-self      { border-color: color-mix(in oklch, var(--accent) 55%, transparent); color: var(--accent); }
.tag-community { border-color: var(--rule-strong); color: var(--ink); }
.tag-policy    { border-color: var(--rule); color: var(--ink-muted); }

.level-legend {
  display: grid;
  gap: var(--space-3);
  max-width: 42rem;
  margin: var(--space-6) auto;
  font-size: var(--text-sm);
  color: var(--ink-muted);
}
.level-legend p { margin: 0; }

/* Constraint ledger — rank · name · who it hits · why it compounds */
.constraint { border-top: 1px solid var(--rule); padding-block: var(--space-8); }
.constraint:last-of-type { border-bottom: 1px solid var(--rule); }
.constraint-head {
  display: grid;
  grid-template-columns: 3.2rem 1fr;
  gap: var(--space-4);
  align-items: baseline;
}
.constraint-rank {
  font-family: var(--font-display);
  font-weight: 500;
  font-variant-caps: all-small-caps;
  letter-spacing: 0.06em;
  color: var(--accent);
}
.constraint h3 { margin: 0; font-size: var(--text-lg); }
.constraint-body { display: grid; gap: var(--space-3); margin-top: var(--space-3); }
@media (min-width: 48rem) {
  .constraint-body { grid-column: 2; margin-left: 0; }
  .constraint-head + .constraint-body { padding-left: calc(3.2rem + var(--space-4)); }
}
.constraint-body p { margin: 0; }
.constraint-evidence { color: var(--ink-muted); }
.constraint-hits { color: var(--ink-muted); font-size: var(--text-base); }
.constraint-compounds {
  border-left: 2px solid var(--rule);
  padding-left: var(--space-3);
  font-size: var(--text-sm);
  color: var(--ink-faint);
}
.constraint-solutions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  align-items: baseline;
}
.constraint-solutions a {
  font-size: var(--text-sm);
  color: var(--accent);
  text-decoration: none;
  border: 1px solid color-mix(in oklch, var(--accent) 35%, transparent);
  border-radius: 999px;
  padding: 0.05em 0.7em;
}
.constraint-solutions a:hover { border-color: var(--accent); color: var(--accent-strong); }
.constraint-source { font-size: var(--text-sm); color: var(--ink-muted); }

/* Solution cards */
.solutions { display: grid; gap: var(--space-6); }
@media (min-width: 56rem) { .solutions { grid-template-columns: 1fr 1fr; } }
.solution {
  background: var(--surface-raised);
  border: 1px solid var(--rule);
  border-radius: var(--radius-md);
  padding: var(--space-6);
  display: grid;
  gap: var(--space-3);
  align-content: start;
}
.solution-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--space-3);
  flex-wrap: wrap;
}
.solution h3 { margin: 0; font-size: var(--text-md); }
.solution p { margin: 0; }
.solution-evidence { font-size: var(--text-base); color: var(--ink-muted); }
.solution-honest {
  border-left: 2px solid var(--rule);
  padding-left: var(--space-3);
  font-size: var(--text-sm);
  color: var(--ink-faint);
}
.solution-maps { font-size: var(--text-sm); color: var(--ink-muted); }
.solution-source { font-size: var(--text-sm); color: var(--ink-muted); padding-top: var(--space-2); border-top: 1px solid var(--rule); }

/* Actor panels — "what it means for..." */
.actors { display: grid; gap: var(--space-6); }
@media (min-width: 56rem) { .actors { grid-template-columns: 1fr 1fr; } }
.actor {
  border: 1px solid var(--rule);
  border-radius: var(--radius-md);
  padding: var(--space-6);
}
.actor h3 { font-size: var(--text-md); margin-bottom: var(--space-3); }
.actor p { margin: 0 0 var(--space-3); font-size: var(--text-base); color: var(--ink-muted); }
.actor p:last-child { margin: 0; }
.actor strong { color: var(--ink); }

/* --------------------------------------------------------------------------
   10 · Motion discipline
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
