/* Website appearance layer; the frozen presentations remain unchanged. */
@media screen {
  html[data-study-theme] {
    --bg: var(--theme-bg); --bg-elev: var(--theme-panel); --bg-elev-2: var(--theme-raised);
    --elev: var(--theme-panel); --elev2: var(--theme-raised);
    --panel: var(--theme-panel); --panel2: var(--theme-raised);
    --fg: var(--theme-text); --fg-muted: var(--theme-muted); --fg-dim: var(--theme-meta);
    --muted: var(--theme-muted); --dim: var(--theme-meta); --mute: var(--theme-meta);
    --border: var(--theme-line); --border2: var(--theme-line-strong); --border-strong: var(--theme-line-strong);
    --line: var(--theme-line); --line-strong: var(--theme-line-strong);
    --gold: var(--theme-gold); --gold-dark: var(--theme-gold-soft); --gold-light: var(--theme-gold-bright);
    --blue: var(--theme-gold-soft); --cyan: var(--theme-gold);
    --accent: var(--theme-gold); --a1: var(--theme-gold-soft); --a2: var(--theme-gold);
    --a3: var(--theme-gold); --a4: var(--theme-gold-bright);
    --grad: linear-gradient(105deg, var(--a1), var(--a2) 55%, var(--a4));
    --ink: var(--theme-bg); --ink-soft: var(--theme-panel); --ink-raised: var(--theme-raised);
    --white: var(--theme-heading); --paper: var(--theme-text); --muted-meta: var(--theme-meta);
    background: var(--theme-bg); color: var(--theme-text);
  }
  html[data-study-theme="the-terminal-experiment"] {
    --accent: var(--theme-pink); --a1: light-dark(#8b1676, #b00096);
    --a2: light-dark(#9e1f75, #bd0e8d); --a3: var(--theme-pink); --a4: var(--theme-pink);
    --accent-1: var(--a1); --accent-2: var(--a2); --accent-3: var(--a3); --accent-4: var(--a4);
  }
  html[data-study-theme="unconscious-bias-in-law-enforcement-technology"] {
    --plane: var(--theme-bg); --surface: var(--theme-panel); --ink: var(--theme-text);
    --ink2: var(--theme-muted); --rule: var(--theme-line-strong); --ring: var(--theme-line);
    --s1: var(--theme-gold); --s2: light-dark(#526a89, #9daec5);
    --flag: var(--theme-gold-bright); --flagbg: var(--theme-highlight);
  }
  [data-study-theme] body { background: var(--theme-bg); color: var(--theme-text); }
  [data-study-theme] .topbar { background: var(--theme-header); }
  [data-study-theme] :is(.nav button, .nav a, .btn, .chip, .gcard, #plain, #dock, #reader, #tip) {
    background-color: var(--theme-panel); color: var(--theme-text); border-color: var(--theme-line-strong);
  }
  [data-study-theme] .sir-study-return { background: var(--theme-panel); color: var(--theme-muted) !important; border-color: var(--theme-line-strong); }
  [data-study-theme] .sir-study-return:hover { color: var(--accent) !important; }
  [data-study-theme] .sir-mobile-study-nav { background: var(--theme-header); color: var(--theme-text); border-color: var(--theme-line-strong); }
  [data-study-theme] .btn-primary { background: var(--accent); color: var(--theme-bg); }
  [data-study-theme] :is(a.skip, .button.primary) { background: var(--accent); color: var(--theme-bg); }
  [data-study-theme] #gate { background: var(--theme-bg); }
  [data-study-theme] .gcard input { background: var(--theme-bg); color: var(--theme-text); border-color: var(--theme-line-strong); }
  [data-study-theme] :is(.gcard p, .gcard label, .fine, .note, .cite) { color: var(--theme-muted); }
  [data-study-theme] audio { color-scheme: inherit; }
  [data-study-theme] #sir-cite-panel {
    --muted-meta: var(--theme-line-strong); --muted-dark: var(--theme-muted);
    background: var(--theme-panel); color: var(--theme-text); border-color: var(--theme-line-strong); color-scheme: inherit;
  }
  [data-study-theme] .sir-cite-header { background: var(--theme-panel); }
  [data-study-theme] #sir-cite-panel :is(.citation-help, .citation-intro) { color: var(--theme-muted); }
  [data-study-theme] #sir-cite-panel button, [data-study-theme] .sir-cite-presentation,
  [data-study-theme] .sir-study-reference { border-color: var(--theme-line-strong); }
  [data-study-theme="advancing-us-cyberspace-policies"] :is(.illustration, .example-step, article, .chain > div) { background: var(--theme-panel); border-color: var(--theme-line-strong); }
  [data-study-theme="advancing-us-cyberspace-policies"] :is(.comparison, .callout) { background: var(--theme-panel); }
  [data-study-theme="advancing-us-cyberspace-policies"] :is(.shared-questions, .theme-tab[aria-selected="true"], .example-step[aria-pressed="true"], .chain .selected) { background: var(--theme-highlight); border-color: var(--accent); }
  [data-study-theme="advancing-us-cyberspace-policies"] :is(a, .eyebrow, summary, .chain b) { color: var(--accent); }
  [data-study-theme="advancing-us-cyberspace-policies"] :is(.chain span, main > p, article > p) { color: var(--theme-muted); }
  [data-study-theme="advancing-us-cyberspace-policies"] details p { color: var(--theme-muted); }
  .sir-presentation .sector-explorer .sector-grid button.connected:not([aria-pressed="true"]):not(.preset-focus) { background: var(--theme-raised); color: var(--theme-text); }
  .sir-presentation .dependency-arrow > span { color: var(--theme-muted); background: var(--theme-panel); }
  [data-study-theme="advancing-us-cyberspace-policies"] .theme-panel li::before { background: var(--theme-highlight); }
  [data-study-theme="advancing-us-cyberspace-policies"] :is(.country, .illustration .badge, .checks .check, .ai-account, .limits .card, details) { border-color: var(--theme-line-strong); }
  [data-study-theme="unconscious-bias-in-law-enforcement-technology"] .topbar { pointer-events: auto; }
  [data-study-theme="unconscious-bias-in-law-enforcement-technology"] .method-cta { background: var(--accent); color: var(--theme-bg); }
  @media (max-width: 700px) {
    [data-study-theme] .sir-mobile-study-nav { flex-wrap: wrap; }
    [data-study-theme] .theme-utility { position: static; }
  }
}
