/* TaraLumi design system: Nocturne tokens, fonts, base type and the shared components.
   Rewritten for this site from the design handoff (_ds/nocturne, tl-fonts.css, README "Design tokens"); no runtime.
   Every page links this file first, then site.css (the site shell, layout helpers and page classes).

   THEMES. Dark is the default. A matching light theme applies under <html data-theme="light">, which
   assets/js/theme.js sets from the device's setting or the visitor's pick (the header button). Both themes define the same tokens, and the ramps are mirrored in the
   light theme: a step keeps its distance from the ground, not its absolute lightness. So the design's rules
   (body copy neutral-300, meta neutral-400, small accent text accent-300, selected fill accent-900, tag fill
   accent-800 with accent-100 text) read correctly in both. Never write a literal colour in a component: use a
   token. The one exception is the gold of the brand-mark star (--gold-*), which is the same in both themes.

   CONTRAST (WCAG 2 ratios, checked 2 Dec 2026):
                                       dark (on #161826 / surface #232532)   light (on #f3f4f9 / surface #fcfdff)
     --color-text, headings            14.5                                  15.8
     body copy  (neutral-300)          11.8 / 10.2                           10.4 / 11.2
     meta text  (neutral-400)           8.8 /  7.6                            6.5 /  7.0   (6.1 on an accent-900 fill)
     small accent text (accent-300)    11.7 / 10.1                            9.0 /  9.7
     accent: links, icons, focus ring   5.5 /  4.7                            5.8 /  6.3   (5.4 on an accent-900 fill)
     footer kicker (accent-200 on --color-section) 10.8                      10.6
   The focus ring (2px --color-accent) needs 3:1 against the ground; it has at least 4.7 in both themes. */

/* ---- Fonts: self-hosted, SIL Open Font License 1.1 (assets/fonts/OFL-*.txt). Variable woff2 (weight axis) from the
   Fontsource packages @fontsource-variable/sora 5.3.0, dm-sans 5.3.0 and newsreader 5.3.0, plus
   noto-serif-devanagari 5.3.0 and noto-sans-devanagari 5.3.0 for Hindi. Split by script, so a browser downloads
   only what a page uses. ---- */
@font-face { font-family: "Sora"; font-style: normal; font-display: swap; font-weight: 100 800; src: url("../fonts/sora-latin-wght-normal.woff2") format("woff2-variations"), url("../fonts/sora-latin-wght-normal.woff2") format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Sora"; font-style: normal; font-display: swap; font-weight: 100 800; src: url("../fonts/sora-latin-ext-wght-normal.woff2") format("woff2-variations"), url("../fonts/sora-latin-ext-wght-normal.woff2") format("woff2"); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "DM Sans"; font-style: normal; font-display: swap; font-weight: 100 1000; src: url("../fonts/dm-sans-latin-wght-normal.woff2") format("woff2-variations"), url("../fonts/dm-sans-latin-wght-normal.woff2") format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "DM Sans"; font-style: normal; font-display: swap; font-weight: 100 1000; src: url("../fonts/dm-sans-latin-ext-wght-normal.woff2") format("woff2-variations"), url("../fonts/dm-sans-latin-ext-wght-normal.woff2") format("woff2"); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "DM Sans"; font-style: italic; font-display: swap; font-weight: 100 1000; src: url("../fonts/dm-sans-latin-wght-italic.woff2") format("woff2-variations"), url("../fonts/dm-sans-latin-wght-italic.woff2") format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "DM Sans"; font-style: italic; font-display: swap; font-weight: 100 1000; src: url("../fonts/dm-sans-latin-ext-wght-italic.woff2") format("woff2-variations"), url("../fonts/dm-sans-latin-ext-wght-italic.woff2") format("woff2"); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "Newsreader"; font-style: italic; font-display: swap; font-weight: 200 800; src: url("../fonts/newsreader-latin-wght-italic.woff2") format("woff2-variations"), url("../fonts/newsreader-latin-wght-italic.woff2") format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Newsreader"; font-style: italic; font-display: swap; font-weight: 200 800; src: url("../fonts/newsreader-latin-ext-wght-italic.woff2") format("woff2-variations"), url("../fonts/newsreader-latin-ext-wght-italic.woff2") format("woff2"); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "Newsreader"; font-style: normal; font-display: swap; font-weight: 200 800; src: url("../fonts/newsreader-latin-wght-normal.woff2") format("woff2-variations"), url("../fonts/newsreader-latin-wght-normal.woff2") format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Newsreader"; font-style: normal; font-display: swap; font-weight: 200 800; src: url("../fonts/newsreader-latin-ext-wght-normal.woff2") format("woff2-variations"), url("../fonts/newsreader-latin-ext-wght-normal.woff2") format("woff2"); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "Noto Serif Devanagari"; font-style: normal; font-display: swap; font-weight: 100 900; src: url("../fonts/noto-serif-devanagari-devanagari-wght-normal.woff2") format("woff2-variations"), url("../fonts/noto-serif-devanagari-devanagari-wght-normal.woff2") format("woff2"); unicode-range: U+0900-097F,U+1CD0-1CF9,U+200C-200D,U+20A8,U+20B9,U+20F0,U+25CC,U+A830-A839,U+A8E0-A8FF,U+11B00-11B09; }
@font-face { font-family: "Noto Sans Devanagari"; font-style: normal; font-display: swap; font-weight: 100 900; src: url("../fonts/noto-sans-devanagari-devanagari-wght-normal.woff2") format("woff2-variations"), url("../fonts/noto-sans-devanagari-devanagari-wght-normal.woff2") format("woff2"); unicode-range: U+0900-097F,U+1CD0-1CF9,U+200C-200D,U+20A8,U+20B9,U+20F0,U+25CC,U+A830-A839,U+A8E0-A8FF,U+11B00-11B09; }

/* ---- Tokens: dark (default) ---- */
:root {
  color-scheme: dark;

  --color-bg: #161826;
  --color-surface: #232532;
  --color-text: #e9e9ed;
  --color-accent: #9184d9;
  --color-divider: color-mix(in srgb, var(--color-text) 16%, transparent);

  --color-neutral-100: #f3f5fe;
  --color-neutral-200: #e4e7f5;
  --color-neutral-300: #cfd3e5;
  --color-neutral-400: #b2b6ca;
  --color-neutral-500: #9397ab;
  --color-neutral-600: #75798c;
  --color-neutral-700: #595d6c;
  --color-neutral-800: #3f424d;
  --color-neutral-900: #292b31;

  --color-accent-100: #f5f4ff;
  --color-accent-200: #e7e5fe;
  --color-accent-300: #d2cefd;
  --color-accent-400: #b5abfc;
  --color-accent-500: #968ae0;
  --color-accent-600: #796cbf;
  --color-accent-700: #5d5294;
  --color-accent-800: #423a6a;
  --color-accent-900: #2b2741;

  /* The saturated deep-indigo ground: the footer's Calculated / Interpretation band and the app-icon tile only. */
  --color-section: #262a60;
  --color-section-glow: #353b80;
  --color-section-ghost: #4c5397;

  /* Brand-mark star only. The same in both themes; used nowhere else. */
  --gold: oklch(0.84 0.12 85);
  --gold-hi: oklch(0.95 0.07 90);
  --gold-lo: oklch(0.68 0.13 70);

  /* Roles: what pages should reach for first. Each maps onto the ramps above. */
  --text-strong: var(--color-text);          /* headings, values, names */
  --text-body: var(--color-neutral-300);     /* paragraphs */
  --text-meta: var(--color-neutral-400);     /* secondary lines, units, captions */
  --text-faint: var(--color-neutral-500);    /* keyboard hints, disabled; not for reading text */
  --text-accent: var(--color-accent-300);    /* kickers, prices, scores: small accent text */
  --line: var(--color-neutral-800);          /* row dividers and card edges */
  --fill-selected: var(--color-accent-900);  /* a selected card, cell or row */
  --fill-hover: color-mix(in srgb, var(--color-text) 6%, transparent);
  --ink-on-accent: var(--color-bg);          /* text on a solid accent fill (rare: the design outlines instead) */
  --mark-ink: var(--color-neutral-100);      /* horizon and arc of the brand mark */
  --header-bg: color-mix(in srgb, var(--color-bg) 86%, transparent);
  --backdrop: color-mix(in srgb, var(--color-neutral-900) 55%, transparent);
  --page-glow: radial-gradient(1200px 720px at 82% -160px, color-mix(in srgb, var(--color-accent-900) 75%, transparent), transparent 60%);
  --section-glow: radial-gradient(900px 420px at 85% -40%, color-mix(in srgb, var(--color-section-glow) 70%, transparent), transparent 64%);
  /* Status pairs (supportive / demanding), muted, never alarm red. Always paired with a word, never colour alone. */
  --sup-bg: color-mix(in srgb, #5f9a78 22%, var(--color-surface));
  --sup-ink: #b9dcc6;
  --dem-bg: color-mix(in srgb, #b07a6a 24%, var(--color-surface));
  --dem-ink: #ebc3b6;

  /* Type */
  --font-heading: "Sora", "Noto Sans Devanagari", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-heading-weight: 300;
  --font-body: "DM Sans", "Noto Sans Devanagari", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-interp: "Newsreader", "Noto Serif Devanagari", Georgia, serif;
  --fs-h1: clamp(40px, 5.6vw, 72px);
  --fs-h2: clamp(28px, 3.2vw, 40px);
  --fs-h3: 22px;
  --fs-lead: 17px;
  --fs-body: 16px;
  --fs-small: 14px;
  --fs-meta: 13px;
  --fs-label: 12px;
  --fs-interp: clamp(19px, 1.6vw, 23px);

  /* Space (the compact Nocturne scale), layout and shape */
  --space-1: 2.8px;
  --space-2: 5.6px;
  --space-3: 8.4px;
  --space-4: 11.2px;
  --space-6: 16.8px;
  --space-8: 22.4px;
  --container: 1200px;
  --gutter: clamp(20px, 5vw, 72px);
  --section-pad: clamp(40px, 6vw, 64px);
  --hero-pad: clamp(44px, 7vw, 84px);
  --gap-grid: 8px;
  --gap-grid-dense: 6px;
  --gap-split: 32px clamp(32px, 5vw, 64px);
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 14px;

  /* Elevation: an edge plus ambient darkness */
  --shadow-sm: 0 0 0 1px var(--color-neutral-800);
  --shadow-md: 0 0 0 1px var(--color-neutral-700), 0 6px 18px rgb(0 0 0 / 0.55);
  --shadow-lg: 0 0 0 1px var(--color-neutral-500), 0 16px 40px rgb(0 0 0 / 0.65);
  --shadow-feature: 0 0 0 1px var(--color-accent), 0 16px 40px rgb(0 0 0 / 0.45);
  --ring-selected: 0 0 0 1px var(--color-accent);

  /* Rules fade over 48px at both ends */
  --rule: linear-gradient(to right, transparent, var(--line) 48px, var(--line) calc(100% - 48px), transparent);
  --rule-divider: linear-gradient(to right, transparent, var(--color-divider) 48px, var(--color-divider) calc(100% - 48px), transparent);

  /* Motion */
  --ease: cubic-bezier(.2, .7, .2, 1);
  --lift: translateY(-2px);
  --lift-feature: translateY(-3px);
  --dur: 0.22s;
}

/* ---- Tokens: light. Same names; ramps mirrored around the ground. assets/js/theme.js sets data-theme on <html>
   before the page is drawn: the device's setting, or the visitor's own pick from the header button. Without
   JavaScript the site stays dark. ---- */
:root[data-theme="light"] {
  color-scheme: light;
  --color-bg: #f3f4f9;
  --color-surface: #fcfdff;
  --color-text: #181a24;
  --color-accent: #644db6;
  --color-divider: color-mix(in srgb, var(--color-text) 14%, transparent);

  --color-neutral-100: #181a25;
  --color-neutral-200: #252836;
  --color-neutral-300: #36394a;
  --color-neutral-400: #535769;
  --color-neutral-500: #707385;
  --color-neutral-600: #8e91a1;
  --color-neutral-700: #b7bac8;
  --color-neutral-800: #d6d8e3;
  --color-neutral-900: #e7e9f0;

  --color-accent-100: #221649;
  --color-accent-200: #321f67;
  --color-accent-300: #493191;
  --color-accent-400: #5c45aa;
  --color-accent-500: #7463c0;
  --color-accent-600: #9185d7;
  --color-accent-700: #b9b3eb;
  --color-accent-800: #d9d6f7;
  --color-accent-900: #eceafd;

  --color-section: #dce1fb;
  --color-section-glow: #cfd5f9;
  --color-section-ghost: #b8c1f2;

  --mark-ink: var(--color-neutral-200);
  --header-bg: color-mix(in srgb, var(--color-bg) 84%, transparent);
  --backdrop: color-mix(in srgb, var(--color-neutral-200) 28%, transparent);
  --page-glow: radial-gradient(1200px 720px at 82% -160px, color-mix(in srgb, var(--color-accent-800) 70%, transparent), transparent 60%);
  --section-glow: radial-gradient(900px 420px at 85% -40%, color-mix(in srgb, var(--color-section-ghost) 55%, transparent), transparent 64%);
  --sup-bg: #dcebe1;
  --sup-ink: #2c5240;
  --dem-bg: #f2e2db;
  --dem-ink: #74402f;

  --shadow-sm: 0 0 0 1px var(--color-neutral-800);
  --shadow-md: 0 0 0 1px var(--color-neutral-800), 0 6px 18px rgb(24 26 48 / 0.10);
  --shadow-lg: 0 0 0 1px var(--color-neutral-700), 0 16px 40px rgb(24 26 48 / 0.16);
  --shadow-feature: 0 0 0 1px var(--color-accent), 0 16px 40px rgb(60 44 140 / 0.14);
}

/* ---- Base ---- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: 7rem; } /* no background here: body's propagates to the viewport, under the starfield */
body {
  margin: 0; min-height: 100vh;
  background: var(--page-glow), var(--color-bg);
  background-repeat: no-repeat;
  color: var(--text-body);
  font: 400 var(--fs-body)/1.6 var(--font-body);
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
}
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  color: var(--text-strong); letter-spacing: -0.03em; line-height: 1.15; margin: 0;
}
h1 { font-size: var(--fs-h1); line-height: 1.05; }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); letter-spacing: -0.02em; line-height: 1.25; }
h4 { font-size: 18px; letter-spacing: -0.02em; line-height: 1.3; }
p { margin: 0; }
a { color: var(--color-accent); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--color-accent-400); }
strong, b { font-weight: 500; color: var(--text-strong); }
img, svg { max-width: 100%; }
img { display: block; }
figure { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; border-radius: 2px; }
::selection { background: color-mix(in srgb, var(--color-accent) 30%, transparent); }
[hidden] { display: none !important; }

/* Icons from /assets/img/icons.svg and planets from /assets/img/planets.svg */
.icon { width: 1.1em; height: 1.1em; flex: none; display: inline-block; vertical-align: -0.18em; fill: currentColor; color: var(--color-accent); }
.btn .icon, .seg .icon, .tag .icon { color: inherit; }
.planet { width: 40px; height: 40px; flex: none; display: inline-block; overflow: visible; }

/* ---- Type helpers ---- */
.kicker, .eyebrow { font: 400 var(--fs-meta)/1.3 var(--font-body); letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-accent); }
.label { font: 400 var(--fs-label)/1.3 var(--font-body); letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-meta); }
.lead { font-size: var(--fs-lead); line-height: 1.65; color: var(--text-body); }
.meta { font-size: var(--fs-meta); color: var(--text-meta); }
.value { font: var(--font-heading-weight) var(--fs-h3)/1.2 var(--font-heading); letter-spacing: -0.02em; color: var(--text-strong); font-feature-settings: "tnum" 1; }
.num, .tnum { font-feature-settings: "tnum" 1; font-variant-numeric: tabular-nums; }
/* Interpretation, and only interpretation, is set in Newsreader italic. Calculated facts stay in the sans faces. */
.interp-text, .serif { font-family: var(--font-interp); font-style: italic; font-weight: 400; }
.interp-passage { font: italic 400 var(--fs-interp)/1.48 var(--font-interp); color: var(--text-strong); max-width: 62ch; }

/* ---- Buttons: the primary is an accent outline, never a fill ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 40px; padding: 8px 16px; border-radius: var(--radius-md);
  font: 500 14px/1.2 var(--font-body); color: var(--text-strong); text-decoration: none; white-space: nowrap;
  background: transparent; border: 1px solid transparent; cursor: pointer;
  transition: background-color var(--dur) var(--ease), border-color var(--dur) var(--ease), color var(--dur) var(--ease);
}
.btn:hover { color: var(--text-strong); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: 0.45; cursor: not-allowed; }
.btn-primary { color: var(--color-accent); border-color: var(--color-accent); }
.btn-primary:hover { color: var(--color-accent); background: color-mix(in srgb, var(--color-accent) 12%, transparent); }
.btn-primary:active { background: color-mix(in srgb, var(--color-accent) 22%, transparent); }
.btn-secondary { border-color: var(--color-divider); color: var(--text-body); }
.btn-secondary:hover { background: var(--fill-hover); color: var(--text-strong); }
.btn-secondary:active { background: color-mix(in srgb, var(--color-text) 12%, transparent); }
.btn-ghost { color: var(--color-accent); padding-inline: 6px; }
.btn-ghost:hover { color: var(--color-accent); background: color-mix(in srgb, var(--color-accent) 10%, transparent); }
.btn-ghost:active { background: color-mix(in srgb, var(--color-accent) 18%, transparent); }
.btn-icon { width: 40px; padding: 0; }
.btn-block { width: 100%; }
.btn-sm { min-height: 32px; padding: 5px 12px; font-size: 13px; }

/* ---- Tags: small labels tinted from the ramps. A bare .tag is neutral ("Calculated"). ---- */
.tag {
  display: inline-flex; align-items: center; gap: 6px; align-self: flex-start; width: fit-content;
  padding: 3px 10px; border-radius: 6px;
  font: 400 12px/1.4 var(--font-body); letter-spacing: 0.02em; white-space: nowrap;
  background: var(--color-neutral-800); color: var(--color-neutral-100);
}
.tag-accent, .tag.interp { background: var(--color-accent-800); color: var(--color-accent-100); }
.tag-neutral { background: var(--color-neutral-800); color: var(--color-neutral-100); }
.tag-outline { background: transparent; box-shadow: inset 0 0 0 1px var(--color-accent); color: var(--color-accent); }

/* ---- Forms ---- */
.field { display: flex; flex-direction: column; gap: 6px; position: relative; min-width: 0; font-size: 13px; color: var(--text-meta); }
.field > label { display: block; font-size: 13px; color: var(--text-meta); }
.input,
.field input:is([type="text"], [type="search"], [type="date"], [type="time"], [type="number"], [type="email"], :not([type])),
.field select, .field textarea {
  width: 100%; min-height: 44px; padding: 8px 12px;
  font: 400 16px/1.3 var(--font-body); color: var(--text-strong); caret-color: var(--color-accent);
  background: var(--color-surface); border: 1px solid var(--color-divider); border-radius: var(--radius-md);
  transition: border-color var(--dur) var(--ease);
}
.input:hover, .field input:hover, .field select:hover, .field textarea:hover { border-color: color-mix(in srgb, var(--color-text) 40%, transparent); }
.input:focus-visible, .field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { border-color: var(--color-accent); outline-offset: 0; }
.input::placeholder, .field input::placeholder { color: var(--text-faint); }
.field input:disabled, .field select:disabled, .input:disabled { opacity: 0.45; }
textarea.input, .field textarea { min-height: 90px; resize: vertical; }
.radio { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-size: 14px; }
.radio input, .seg-opt input { position: absolute; opacity: 0; width: 0; height: 0; pointer-events: none; }
.radio .dot { width: 16px; height: 16px; flex: none; border-radius: 50%; border: 1.5px solid var(--color-divider); }
.radio:hover .dot { border-color: var(--color-accent); }
.radio input:checked + .dot { border-color: var(--color-accent); background: var(--color-accent); box-shadow: inset 0 0 0 4px var(--color-bg); }
.radio input:focus-visible + .dot { outline: 2px solid var(--color-accent); outline-offset: 2px; }

/* Segmented control: radios in labels (.seg-opt), or buttons with aria-pressed (the site's switches). */
.seg { display: inline-flex; flex-wrap: nowrap; overflow: hidden; border: 1px solid var(--color-divider); border-radius: var(--radius-md); background: transparent; }
.seg-opt, .seg > button, .seg > a {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 36px; padding: 6px 14px; border: 0; border-radius: 0; background: transparent;
  font: 400 13px/1.2 var(--font-body); color: var(--text-body); text-decoration: none; cursor: pointer; white-space: nowrap;
}
.seg-opt + .seg-opt, .seg > button + button, .seg > a + a { border-left: 1px solid var(--color-divider); }
.seg-opt:has(input:checked), .seg > button[aria-pressed="true"], .seg > a[aria-current="page"] { color: var(--color-accent); box-shadow: inset 0 0 0 1px var(--color-accent); border-radius: calc(var(--radius-md) - 1px); }
.seg-opt:not(:has(input:checked)):hover, .seg > button:not([aria-pressed="true"]):hover, .seg > a:not([aria-current="page"]):hover { background: var(--fill-hover); color: var(--text-strong); }
.seg-opt:has(input:focus-visible) { outline: 2px solid var(--color-accent); outline-offset: -2px; }
.seg > button:focus-visible, .seg > a:focus-visible { outline-offset: -2px; }

/* ---- Cards and panels ---- */
.card {
  display: flex; flex-direction: column; gap: 8px; min-width: 0;
  padding: 16px 18px; border-radius: var(--radius-md);
  background: var(--color-surface); box-shadow: var(--shadow-sm); color: var(--text-body);
}
.card-kicker { font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-accent); }
.card-title { font: 500 16px/1.3 var(--font-body); color: var(--text-strong); }
.card-body { margin: 0; font-size: 14px; color: var(--text-body); flex: 1; }
.card-meta { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--text-meta); }
a.card, .card-link { text-decoration: none; transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), background-color var(--dur) var(--ease); }
a.card:hover, .card-link:hover { transform: var(--lift); color: var(--text-body); }
.card.is-selected, .card[aria-current="true"], .card[aria-pressed="true"] { background: var(--fill-selected); box-shadow: var(--ring-selected); }
.card-feature { border-radius: var(--radius-lg); box-shadow: var(--shadow-feature); padding: clamp(20px, 3vw, 32px); }
.elev-sm { box-shadow: var(--shadow-sm); }
.elev-md { box-shadow: var(--shadow-md); }
.elev-lg { box-shadow: var(--shadow-lg); }

/* ---- Tables ---- */
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th {
  text-align: left; font-weight: 400; font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--text-meta); padding: 10px 12px;
}
.table td { padding: 10px 12px; color: var(--text-body); font-feature-settings: "tnum" 1; }
.table thead tr { background: var(--rule-divider) no-repeat bottom / 100% 1px; }
.table tbody tr { background: var(--rule) no-repeat bottom / 100% 1px; }
.table tbody tr:hover { background: linear-gradient(var(--fill-hover), var(--fill-hover)) no-repeat 0 0 / 100% 100%, var(--rule) no-repeat bottom / 100% 1px; }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* ---- Dialog (also the search palette) ---- */
.dialog-backdrop { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 16px; background: var(--backdrop); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.dialog {
  width: min(440px, 100%); display: flex; flex-direction: column; gap: 12px;
  padding: 20px; border: 0; border-radius: var(--radius-lg);
  background: var(--color-surface); color: var(--text-body); box-shadow: var(--shadow-lg);
}
dialog.dialog { margin: auto; max-height: calc(100vh - 32px); }
dialog.dialog::backdrop { background: var(--backdrop); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.dialog-title { font: 500 20px/1.3 var(--font-body); color: var(--text-strong); }
.dialog-body { font-size: 14px; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 6px; }

/* ---- Rules ---- */
.hr, .rule { height: 1px; border: 0; margin: 0; background: var(--rule); }
