/* BlindSpot report UI. Plain CSS, no framework.

   Concept: "Screen off". The interface is the page as it is heard, not seen.
   - Dark first: the black of a powered-down screen (#0d0d0c), warm off-white text. A light theme follows
     prefers-color-scheme, where black text sits on off-white and yellow becomes a highlighter fill.
   - One accent, the yellow of tactile paving and warning strips (#ffd200). It marks barriers ("blind spots"),
     focus, the live / speaking state and primary actions. Yellow is never used as text on a light background.
   - Type: Atkinson Hyperlegible Next and Atkinson Hyperlegible Mono, designed by the Braille Institute for
     readers with low vision. Headings are set like screen reader announcements: a dim role, then the content.
   - Transcripts and other "heard" panels stay dark in both themes: that is the screen switched off.
   Fonts are self-hosted in fonts/ (SIL Open Font License, see the OFL-*.txt files there).

   Contrast (WCAG 2.x ratios, checked with a script):
   dark  #f2efe6 on #0d0d0c 16.9 · #c4c0b5 10.7 · #9a968b 6.6 (5.8 on #1d1c19) · #ffd200 13.4 · #8fd19e 10.9
         #0d0d0c on #ffd200 13.4 · field / control borders #6a675e 3.4
   light #0d0d0c on #f4f2ec 17.4 · #3a3833 10.5 · #625f57 5.7 (5.1 on #e9e6dd) · #2f6b3f 5.7
         control borders #7d796f 3.9 · yellow only as a fill behind black text (13.4). */

/* ------------------------------------------------------------------ fonts */

@font-face {
  font-family: "Atkinson Hyperlegible Next";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(fonts/atkinson-hyperlegible-next-latin-400-normal.woff2) format("woff2");
}

@font-face {
  font-family: "Atkinson Hyperlegible Next";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url(fonts/atkinson-hyperlegible-next-latin-400-italic.woff2) format("woff2");
}

@font-face {
  font-family: "Atkinson Hyperlegible Next";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(fonts/atkinson-hyperlegible-next-latin-600-normal.woff2) format("woff2");
}

@font-face {
  font-family: "Atkinson Hyperlegible Next";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(fonts/atkinson-hyperlegible-next-latin-700-normal.woff2) format("woff2");
}

@font-face {
  font-family: "Atkinson Hyperlegible Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(fonts/atkinson-hyperlegible-mono-latin-400-normal.woff2) format("woff2");
}

@font-face {
  font-family: "Atkinson Hyperlegible Mono";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(fonts/atkinson-hyperlegible-mono-latin-700-normal.woff2) format("woff2");
}

/* ------------------------------------------------------------------ tokens */

:root {
  color-scheme: dark light;
  --sans: "Atkinson Hyperlegible Next", "Atkinson Hyperlegible", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Atkinson Hyperlegible Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --braille: "Apple Braille", "Segoe UI Symbol", "DejaVu Sans", "Noto Sans Symbols 2", sans-serif;

  /* Screen off. */
  --bg: #0d0d0c;
  --bg-2: #151513;
  --bg-3: #1d1c19;
  --text: #f2efe6;
  --text-2: #c4c0b5;
  --muted: #9a968b;
  --rule: #2a2925;
  --rule-strong: #6a675e;

  /* Tactile paving yellow. On dark it can be text; on light it is only ever a fill under black text. */
  --yellow: #ffd200;
  --on-yellow: #0d0d0c;
  --accent-text: var(--yellow);
  --mark-bg: transparent;
  --mark-pad: 0;
  --bar-edge: var(--yellow);

  --good: #8fd19e;
  --focus: var(--yellow);
  --focus-ring: 0 0 0 0 transparent;
  --dome: #262521;
  --hear-outline: rgba(255, 210, 0, 0.55);

  /* "Heard" panels: always dark. */
  --term-bg: #121210;
  --term-border: #2a2925;
  --term-text: #ece8dd;
  --term-dim: #9a968b;

  --radius: 4px;
  --gutter: 16px;
  --measure: 42em;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f4f2ec;
    --bg-2: #fbfaf7;
    --bg-3: #e9e6dd;
    --text: #0d0d0c;
    --text-2: #3a3833;
    --muted: #625f57;
    --rule: #d6d2c7;
    --rule-strong: #7d796f;

    --accent-text: #0d0d0c;
    --mark-bg: var(--yellow);
    --mark-pad: 0 0.3em;
    --bar-edge: #0d0d0c;

    --good: #2f6b3f;
    --focus: #0d0d0c;
    --focus-ring: 0 0 0 2px var(--yellow);
    --dome: #dedacf;
    --hear-outline: rgba(13, 13, 12, 0.5);

    --term-bg: #0d0d0c;
    --term-border: #0d0d0c;
  }
}

/* Dark scopes inside the light theme: the heard side of the world. */
.demo-hear,
.transcript,
.fix-code,
.cmp-run,
.lightbox {
  --bg: #0d0d0c;
  --bg-2: #151513;
  --bg-3: #1d1c19;
  --text: #f2efe6;
  --text-2: #c4c0b5;
  --muted: #9a968b;
  --rule: #2a2925;
  --rule-strong: #6a675e;
  --accent-text: var(--yellow);
  --mark-bg: transparent;
  --mark-pad: 0;
  --good: #8fd19e;
  --focus: var(--yellow);
  --focus-ring: 0 0 0 0 transparent;
}

/* ------------------------------------------------------------------ base */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: 24px;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-kerning: normal;
}

::selection {
  background: var(--yellow);
  color: var(--on-yellow);
}

h1,
h2,
h3 {
  margin: 0;
  font-weight: 700;
  line-height: 1.12;
  text-wrap: balance;
}

h2 {
  font-size: clamp(1.75rem, 1.4rem + 1vw, 2.375rem);
  letter-spacing: -0.015em;
}

p {
  margin: 0;
  text-wrap: pretty;
}

a {
  color: inherit;
  text-decoration-line: underline;
  text-decoration-thickness: 1px;
  text-decoration-color: var(--rule-strong);
  text-underline-offset: 0.22em;
  transition: text-decoration-color 0.15s, color 0.15s;
}

a:hover {
  text-decoration-color: currentColor;
  text-decoration-thickness: 2px;
}

code,
pre,
kbd {
  font-family: var(--mono);
}

img {
  max-width: 100%;
}

/* Focus: a thick yellow ring on dark; black with a yellow halo on light (the classic accessible focus style). */
:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  box-shadow: var(--focus-ring);
}

[tabindex="-1"]:focus:not(:focus-visible),
h1[tabindex="-1"]:focus,
h2[tabindex="-1"]:focus,
li[tabindex="-1"]:focus {
  outline: none;
  box-shadow: none;
}

[hidden] {
  display: none !important;
}

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

.muted {
  color: var(--muted);
}

.wrap {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

@media (min-width: 720px) {
  :root {
    --gutter: 40px;
  }
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -80px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--yellow);
  color: var(--on-yellow);
  font-weight: 700;
  text-decoration: none;
}

.skip-link:focus {
  top: 12px;
}

.icon {
  flex: none;
  width: 1.05em;
  height: 1.05em;
}

/* Small labels are set like a screen reader's role words: mono, lower case, dim. */
.head-kicker,
.presets-label,
.action-label,
.gauge-caption,
.stat-label,
.issue-meta dt,
.step-facts dt,
.summary figcaption,
.runs-cols,
.fix-label,
.announce-role {
  font-family: var(--mono);
  font-size: 0.8125rem;
  font-weight: 400;
  letter-spacing: 0;
  color: var(--muted);
  line-height: 1.4;
}

/* A highlighter mark: yellow text on dark, black text on a yellow block on light. */
.mark,
.badge.status-bad {
  color: var(--accent-text);
  background: var(--mark-bg);
  padding: var(--mark-pad);
}

/* ------------------------------------------------------------------ announcements (headings) */

.announce {
  display: grid;
  justify-items: start;
  gap: 8px;
  min-width: 0;
}

.announce-role {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

/* The "speaking" tick before a role: a short bar, like a caption cursor. */
.announce-role::before {
  content: "";
  width: 10px;
  height: 2px;
  background: var(--rule-strong);
}

.announce > :is(h1, h2) {
  min-width: 0;
  max-width: 100%;
}

.q {
  font-family: var(--mono);
  font-weight: 400;
  color: var(--muted);
}

@media (min-width: 600px) {
  /* Hang the opening quote so the words line up with the role above. */
  .q-open {
    display: inline-block;
    width: 0.62em;
    margin-left: -0.62em;
  }
}

/* ------------------------------------------------------------------ header / footer */

.site-header {
  border-bottom: 1px solid var(--rule);
}

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 28px;
  padding-top: 16px;
  padding-bottom: 14px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
  text-decoration: none;
}

.brand-mark {
  flex: none;
  width: 40px;
  height: 16px;
  overflow: visible;
}

.brand-cross {
  fill: none;
  stroke: var(--text);
  stroke-width: 2.2;
  stroke-linecap: round;
}

.brand-spot {
  fill: var(--yellow);
}

@media (prefers-color-scheme: light) {
  .brand-spot {
    stroke: #0d0d0c;
    stroke-width: 1.5;
  }
}

.brand-text {
  display: grid;
  gap: 3px;
  line-height: 1;
}

.brand-name {
  font-size: 1.375rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.brand-braille {
  font-family: var(--braille);
  font-size: 0.875rem;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.header-tag {
  font-family: var(--mono);
  color: var(--muted);
  font-size: 0.8125rem;
}

.flag {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--text);
  border: 1px solid var(--rule-strong);
  border-radius: 999px;
  padding: 2px 10px;
}

.hear-toggle {
  margin-left: auto;
}

@media (max-width: 640px) {
  .header-tag {
    display: none;
  }
}

main.wrap {
  flex: 1;
  padding-top: 48px;
  padding-bottom: 96px;
}

main:focus {
  outline: none;
}

.tactile {
  height: 12px;
  background-image: radial-gradient(circle, var(--dome) 2.2px, transparent 2.9px);
  background-size: 12px 12px;
  background-position: center;
}

.site-footer {
  color: var(--muted);
  font-size: 0.9375rem;
  padding: 0 0 40px;
}

.site-footer .tactile {
  margin-bottom: 28px;
}

.footer-inner {
  display: grid;
  gap: 16px 48px;
}

.footer-lead {
  color: var(--text-2);
  max-width: 44em;
}

.colophon {
  max-width: 34em;
}

@media (min-width: 900px) {
  .footer-inner {
    grid-template-columns: minmax(0, 6fr) minmax(0, 5fr);
  }
}

.colophon a {
  color: var(--text);
}

/* ------------------------------------------------------------------ switches (Screen off, Hear this page) */

.hear-toggle,
.screen-toggle {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 40px;
  padding: 0 16px 0 10px;
  border: 1px solid var(--rule-strong);
  border-radius: 999px;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
  transition: border-color 0.15s, background-color 0.15s;
}

.hear-toggle:hover,
.screen-toggle:hover {
  border-color: var(--text);
}

.switch {
  position: relative;
  flex: none;
  width: 36px;
  height: 22px;
  border: 2px solid currentColor;
  border-radius: 999px;
  transition: background-color 0.2s, border-color 0.2s;
}

.switch-knob {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: currentColor;
  transition: transform 0.2s, background-color 0.2s;
}

[aria-pressed="true"] > .switch {
  background: var(--yellow);
  border-color: var(--yellow);
}

[aria-pressed="true"] > .switch .switch-knob {
  transform: translateX(14px);
  background: var(--on-yellow);
}

.hear-toggle[aria-pressed="true"],
.screen-toggle[aria-pressed="true"] {
  border-color: var(--yellow);
}

@media (prefers-color-scheme: light) {
  [aria-pressed="true"] > .switch {
    border-color: #0d0d0c;
  }
  .hear-toggle[aria-pressed="true"],
  .screen-toggle[aria-pressed="true"] {
    border-color: #0d0d0c;
    background: var(--yellow);
    color: #0d0d0c;
  }
}

/* ------------------------------------------------------------------ generic pieces */

.card {
  background: none;
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 10px 24px;
  margin-bottom: 20px;
}

.count {
  font-family: var(--mono);
  font-size: 0.5em;
  font-weight: 400;
  letter-spacing: 0;
  color: var(--muted);
  vertical-align: 0.6em;
  margin-left: 0.15em;
}

.section-note {
  color: var(--muted);
  font-size: 0.9375rem;
  max-width: 36em;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.35;
  white-space: nowrap;
  color: var(--text-2);
}

.badge .icon {
  width: 1em;
  height: 1em;
}

/* Run status: a word and a symbol, never colour alone. */
.status-good {
  color: var(--good);
}

.status-warn,
.status-info {
  color: var(--text-2);
}

.badge.status-bad {
  border-radius: 2px;
}

.pulse-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--yellow);
  animation: pulse 1.2s ease-in-out infinite;
}

@media (prefers-color-scheme: light) {
  .pulse-dot {
    box-shadow: 0 0 0 1px #0d0d0c;
  }
}

@keyframes pulse {
  50% {
    opacity: 0.3;
  }
}

/* Severity: a mono label, like a role. Four dots give the weight; the word says it. */
.sev-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.4;
  color: var(--text-2);
}

.sev-dots {
  display: inline-flex;
  gap: 3px;
}

.sev-dots span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  border: 1px solid currentColor;
}

.sev-dots .is-on {
  background: currentColor;
}

.sev-label.sev-critical,
.sev-label.is-blocking {
  color: var(--accent-text);
  background: var(--mark-bg);
  padding: var(--mark-pad);
}

.sev-label.sev-serious {
  color: var(--text);
}

.sev-label.sev-moderate {
  color: var(--text-2);
}

.sev-label.sev-minor {
  color: var(--muted);
}

.sev-sep {
  color: inherit;
}

.source {
  font-size: 0.8125rem;
  color: var(--muted);
}

/* ------------------------------------------------------------------ buttons */

.btn {
  --btn-fg: var(--text);
  --btn-bg: transparent;
  --btn-border: var(--rule-strong);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--btn-border);
  border-radius: var(--radius);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s, color 0.15s, border-color 0.15s;
}

.btn:hover:not(:disabled) {
  --btn-bg: var(--bg-3);
  --btn-border: var(--text);
}

.btn:disabled {
  --btn-bg: transparent;
  --btn-fg: var(--muted);
  --btn-border: var(--rule);
  cursor: not-allowed;
}

/* Primary actions wear the tactile yellow. */
.btn-primary {
  --btn-bg: var(--yellow);
  --btn-fg: var(--on-yellow);
  --btn-border: var(--yellow);
  font-weight: 700;
}

.btn-primary:hover:not(:disabled) {
  --btn-bg: var(--text);
  --btn-fg: var(--bg);
  --btn-border: var(--text);
}

@media (prefers-color-scheme: light) {
  .btn-primary {
    --btn-border: #0d0d0c;
  }
  .btn-primary:hover:not(:disabled) {
    --btn-bg: #0d0d0c;
    --btn-fg: var(--yellow);
  }
}

.btn-primary:disabled {
  --btn-bg: transparent;
  --btn-fg: var(--muted);
  --btn-border: var(--rule-strong);
  font-weight: 600;
}

.btn-ghost {
  --btn-border: var(--rule-strong);
}

.btn-sm {
  min-height: 36px;
  padding: 0 12px;
  font-size: 0.875rem;
}

.btn-lg {
  min-height: 52px;
  padding: 0 26px;
  font-size: 1.0625rem;
}

.btn-lg .icon {
  transition: transform 0.2s;
}

.btn-lg:hover .icon {
  transform: translateX(3px);
}

.spinner {
  width: 14px;
  height: 14px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ------------------------------------------------------------------ messages */

.error-box {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 16px;
  border: 1px solid var(--rule-strong);
  box-shadow: inset 4px 0 var(--yellow);
  padding-left: 20px;
  color: var(--text);
  background: var(--bg-2);
  overflow-wrap: anywhere;
}

.error-box .icon {
  margin-top: 4px;
}

.error-title {
  font-weight: 700;
}

.error-box p + p {
  color: var(--text-2);
  margin-top: 2px;
}

.empty {
  padding: 24px 0;
  color: var(--muted);
}

.empty-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
}

/* ------------------------------------------------------------------ home: hero */

.hero h1 {
  font-size: clamp(2.375rem, 1.1rem + 5vw, 5.25rem);
  line-height: 1.02;
  letter-spacing: -0.028em;
  max-width: 13em;
}

.announce-hero .announce-role {
  font-size: 0.9375rem;
}

.hero-intro {
  display: grid;
  gap: 32px;
  margin-top: 36px;
}

.lede {
  font-size: clamp(1.25rem, 1.1rem + 0.5vw, 1.5rem);
  line-height: 1.35;
  font-weight: 600;
  max-width: 26em;
}

.lede-2 {
  margin-top: 14px;
  color: var(--text-2);
  max-width: 38em;
}

@media (min-width: 960px) {
  .hero-intro {
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
    gap: 64px;
    align-items: end;
  }
}

.hero-links:empty {
  display: none;
}

.hero-links {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--rule);
}

.hero-links li {
  border-bottom: 1px solid var(--rule);
}

.hero-links a {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 2px 16px;
  padding: 14px 0;
  text-decoration: none;
}

.hero-link-label {
  font-weight: 700;
}

.hero-link-sub {
  grid-column: 1;
  font-size: 0.9375rem;
  color: var(--muted);
}

.hero-link-score {
  grid-row: 1 / span 2;
  grid-column: 2;
  font-family: var(--mono);
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1;
}

.hero-link-score .to {
  font-size: 0;
}

.hero-link-score .to::after {
  content: "→";
  font-size: 1.25rem;
  color: var(--muted);
  margin: 0 8px;
  vertical-align: 0.15em;
}

.hero-links .is-bad {
  color: var(--accent-text);
  background: var(--mark-bg);
  padding: var(--mark-pad);
}

.hero-links a:hover .hero-link-label {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.2em;
}

/* "Screen on / Screen off" demo. */
.demo {
  margin: 56px 0 0;
  border: 1px solid var(--rule);
  background: var(--bg-2);
  border-radius: var(--radius);
  overflow: hidden;
}

.demo-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--rule);
}

.demo-title {
  font-weight: 700;
}

.demo-source {
  font-size: 0.875rem;
  color: var(--muted);
}

.demo-panes {
  display: grid;
}

@media (min-width: 900px) {
  .demo-panes {
    grid-template-columns: minmax(0, 11fr) minmax(0, 9fr);
  }
}

.demo-screen {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px 18px 18px;
  min-width: 0;
}

.screen-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  align-self: flex-start;
  font-family: var(--mono);
  font-size: 0.75rem;
  line-height: 1.5;
  color: var(--text-2);
  padding: 1px 9px 1px 7px;
  border: 1px solid var(--rule-strong);
  border-radius: 999px;
}

.screen-label::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
}

.screen-label-off,
.is-screen-off .screen-label-on {
  display: none;
}

.is-screen-off .screen-label-off {
  display: inline;
}

.is-screen-off .screen-label::before {
  background: transparent;
  box-shadow: inset 0 0 0 1.5px currentColor;
}

.demo-shot {
  position: relative;
  background: #050505;
  border-radius: 2px;
  overflow: hidden;
  box-shadow: 0 0 0 1px var(--rule);
}

.demo-shot img {
  display: block;
  width: 100%;
  height: auto;
  transition: opacity 0.7s ease, filter 0.7s ease;
}

/* The faint sheen of a switched-off screen. */
.demo-shot::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(125deg, rgba(255, 255, 255, 0.06), transparent 38%);
  opacity: 0;
  transition: opacity 0.7s ease;
  pointer-events: none;
}

.is-screen-off .demo-shot img {
  opacity: 0;
  filter: brightness(0.2);
}

.is-screen-off .demo-shot::after {
  opacity: 1;
}

.pin {
  position: absolute;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: var(--yellow);
  color: #0d0d0c;
  font-family: var(--mono);
  font-size: 0.8125rem;
  font-weight: 700;
  line-height: 1;
  box-shadow: 0 0 0 2px #0d0d0c;
  transition: opacity 0.4s ease;
}

.is-screen-off .pin {
  opacity: 0;
}

.demo-off-caption {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 16px;
  text-align: center;
  font-family: var(--mono);
  font-size: clamp(0.9375rem, 0.8rem + 0.5vw, 1.1875rem);
  color: #f2efe6;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.is-screen-off .demo-off-caption {
  opacity: 1;
  transition-delay: 0.5s;
}

.demo-off-arrow {
  display: inline-flex;
  color: var(--yellow);
}

@media (max-width: 899px) {
  .demo-off-arrow {
    transform: rotate(90deg);
  }
}

.demo-hear {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--term-bg);
  color: var(--term-text);
}

.demo-hear .pane-head {
  padding: 14px 18px 4px;
  margin: 0;
}

.demo-transcript {
  flex: 1;
  margin: 0;
  padding: 8px 0 18px;
  font-size: 0.875rem;
  line-height: 1.6;
  overflow-x: auto;
}

.dl {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 40px;
  align-items: center;
  padding-left: 18px;
  color: var(--term-dim);
  transition: color 0.35s ease, background-color 0.35s ease, box-shadow 0.35s ease;
}

/* Wrapped lines hang under their own indentation, like a tree. --in is the line's leading spaces. */
.dl-code,
.t-line {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  padding-left: calc((var(--in, 0) + 2) * 1ch);
  text-indent: calc((var(--in, 0) + 2) * -1ch);
}

.dl .t-id {
  color: var(--term-dim);
}

.dl .t-empty {
  color: var(--yellow);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.2em;
}

.dl.is-barrier {
  box-shadow: inset 2px 0 rgba(255, 210, 0, 0.6);
}

.dl.is-first {
  margin-top: 3px;
}

.dl.is-last {
  margin-bottom: 3px;
}

.note-num {
  justify-self: center;
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1.5px solid var(--yellow);
  color: var(--yellow);
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1;
  transition: background-color 0.35s ease, color 0.35s ease;
}

/* Screen off: the transcript lights up line by line, like captions, and the barriers turn yellow. */
.is-screen-off .dl {
  color: var(--term-text);
  transition-delay: calc(var(--i) * 70ms);
}

.is-screen-off .dl.is-barrier {
  color: var(--yellow);
  background: rgba(255, 210, 0, 0.09);
  box-shadow: inset 4px 0 var(--yellow);
}

.is-screen-off .dl.is-barrier .t-id {
  color: rgba(255, 210, 0, 0.75);
}

.is-screen-off .note-num {
  background: var(--yellow);
  color: #0d0d0c;
  transition-delay: calc(var(--i) * 70ms);
}

.demo-notes {
  padding: 18px;
  border-top: 1px solid var(--rule);
}

.demo-notes ol {
  display: grid;
  gap: 14px 28px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: note;
}

@media (min-width: 720px) {
  .demo-notes ol {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1100px) {
  .demo-notes ol {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.demo-notes li {
  counter-increment: note;
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  align-content: start;
  gap: 6px 0;
  font-size: 0.9375rem;
  color: var(--text-2);
}

.demo-notes li::before {
  content: counter(note);
  content: counter(note) / "";
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--yellow);
  color: #0d0d0c;
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1;
}

@media (prefers-color-scheme: light) {
  .demo-notes li::before,
  .pin {
    box-shadow: 0 0 0 1.5px #0d0d0c;
  }
}

.note-flag {
  grid-column: 2;
  justify-self: start;
  font-family: var(--mono);
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--on-yellow);
  background: var(--yellow);
  padding: 0 7px;
  border-radius: 2px;
}

.demo-foot {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--rule);
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text);
}

/* ------------------------------------------------------------------ home: run form */

.run-card {
  margin-top: 88px;
  display: grid;
  gap: 28px;
}

.hero::after {
  content: "";
  display: block;
  height: 12px;
  margin-top: 88px;
  background-image: radial-gradient(circle, var(--dome) 2.2px, transparent 2.9px);
  background-size: 12px 12px;
  background-position: center;
}

.hero + .run-card {
  margin-top: 64px;
}

.run-intro .announce {
  margin-bottom: 14px;
}

@media (min-width: 960px) {
  .run-card {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: 64px;
  }
}

.run-form {
  display: grid;
  gap: 24px;
  max-width: 720px;
}

.presets-label {
  margin-bottom: 8px;
}

.preset-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 168px), 1fr));
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.preset-item {
  display: flex;
}

.btn-preset {
  flex: 1;
  justify-content: flex-start;
  min-height: 44px;
  padding: 0 12px;
  font-size: 0.875rem;
  font-weight: 600;
}

.preset-dot {
  flex: none;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid currentColor;
}

.preset-bad .preset-dot {
  background: var(--yellow);
  border-color: var(--yellow);
}

@media (prefers-color-scheme: light) {
  .preset-bad .preset-dot {
    border-color: #0d0d0c;
  }
}

.field label {
  display: block;
  font-size: 0.9375rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.field input,
.field textarea,
.field select,
.compare-select {
  display: block;
  width: 100%;
  font: inherit;
  font-size: 1rem;
  color: var(--text);
  background: var(--bg-2);
  border: 1px solid var(--rule-strong);
  border-radius: var(--radius);
  padding: 12px 14px;
  transition: border-color 0.15s;
}

.field input:hover,
.field textarea:hover,
.field select:hover,
.compare-select:hover {
  border-color: var(--text-2);
}

.field input:focus,
.field textarea:focus,
.field select:focus,
.compare-select:focus {
  border-color: var(--text);
}

#run-url {
  font-family: var(--mono);
  font-size: 0.9375rem;
}

.field textarea {
  resize: vertical;
  min-height: 96px;
  line-height: 1.5;
}

::placeholder {
  color: var(--muted);
  opacity: 1;
}

.field [aria-invalid="true"] {
  border-color: var(--yellow);
  box-shadow: inset 4px 0 var(--yellow);
}

@media (prefers-color-scheme: light) {
  .field [aria-invalid="true"] {
    border-color: #0d0d0c;
    box-shadow: inset 5px 0 var(--yellow), inset 6px 0 #0d0d0c;
  }
}

.field select,
.compare-select {
  appearance: none;
  padding-right: 40px;
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: calc(100% - 20px) 52%, calc(100% - 15px) 52%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  cursor: pointer;
}

.hint {
  margin-top: 6px;
  font-size: 0.875rem;
  color: var(--muted);
}

.form-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 16px;
  padding-top: 8px;
}

.field-inline {
  flex: 1 1 220px;
}

.form-error:empty {
  display: none;
}

.static-text {
  color: var(--text-2);
  max-width: 34em;
}

.static-notice .presets {
  align-self: end;
}

/* ------------------------------------------------------------------ home: runs list */

.runs-section {
  margin-top: 96px;
}

.runs-section .section-head {
  margin-bottom: 24px;
}

.compare-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 20px;
  padding: 0 0 16px;
}

.compare-hint {
  font-size: 0.9375rem;
  color: var(--muted);
}

.runs-loading {
  padding: 20px 0;
}

/* One grid for the column heads and every row: pick | task | result | started | score. */
.runs-cols,
.run-row {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) 190px 130px 150px;
  column-gap: 20px;
  align-items: center;
}

.runs-cols {
  padding: 8px 0;
  border-top: 1px solid var(--rule-strong);
  border-bottom: 1px solid var(--rule);
}

.col-score {
  text-align: right;
}

.runs {
  list-style: none;
  margin: 0;
  padding: 0;
}

.run-row {
  border-bottom: 1px solid var(--rule);
  transition: background-color 0.15s;
}

.run-row:hover,
.run-row.is-picked {
  background: var(--bg-2);
}

.run-row.is-picked {
  box-shadow: inset 3px 0 var(--text);
}

.run-pick {
  display: grid;
  place-items: center;
  align-self: stretch;
  cursor: pointer;
}

.run-pick input {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--yellow);
  cursor: pointer;
}

@media (prefers-color-scheme: light) {
  .run-pick input {
    accent-color: #0d0d0c;
  }
}

.run {
  grid-column: 2 / -1;
  display: grid;
  grid-template-columns: subgrid;
  align-items: center;
  padding: 18px 0;
  color: inherit;
  text-decoration: none;
  min-width: 0;
}

.run-main {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.run-task {
  font-weight: 600;
  line-height: 1.4;
  text-decoration: underline;
  text-decoration-color: transparent;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.2em;
  transition: text-decoration-color 0.15s;
}

.run:hover .run-task {
  text-decoration-color: currentColor;
}

.run-url {
  font-family: var(--mono);
  font-size: 0.8125rem;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.run-when {
  font-size: 0.875rem;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.run-score {
  justify-self: end;
  padding-right: 4px;
}

/* Score in lists: mono number and ten small cells. */
.score-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.score-pill-num {
  min-width: 3ch;
  text-align: right;
  font-family: var(--mono);
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1;
  color: var(--text);
}

.score-pill.tone-bad .score-pill-num {
  color: var(--accent-text);
  background: var(--mark-bg);
  padding: var(--mark-pad);
}

.score-pill.tone-none .score-pill-num {
  color: var(--muted);
}

@media (max-width: 799px) {
  .runs-cols {
    display: none;
  }
  .run-row {
    grid-template-columns: 32px minmax(0, 1fr);
    column-gap: 12px;
    align-items: start;
  }
  .runs {
    border-top: 1px solid var(--rule-strong);
  }
  .run-pick {
    align-self: start;
    padding-top: 18px;
  }
  .run {
    grid-column: 2;
    grid-template-columns: minmax(0, 1fr);
    row-gap: 8px;
    padding: 16px 4px 16px 0;
  }
  .run-score {
    justify-self: start;
  }
  .run-when {
    font-size: 0.8125rem;
  }
}

/* ------------------------------------------------------------------ score cells */

.cells {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.cell {
  flex: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid var(--rule-strong);
}

/* Five and five, like a pair of braille cells. */
.cell:nth-child(5) {
  margin-right: 8px;
}

.cell.is-on {
  background: var(--text);
  border-color: var(--text);
}

.tone-good .cell.is-on {
  background: var(--good);
  border-color: var(--good);
}

.cells.is-unscored .cell {
  border-style: dotted;
}

.cells-sm {
  gap: 3px;
}

.cells-sm .cell {
  width: 7px;
  height: 7px;
  border-width: 1.5px;
}

.cells-sm .cell:nth-child(5) {
  margin-right: 4px;
}

/* ------------------------------------------------------------------ report: header */

.crumbs {
  margin-bottom: 32px;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-2);
  text-decoration: none;
}

.back-link:hover {
  color: var(--text);
}

.back-link .icon {
  transition: transform 0.2s;
}

.back-link:hover .icon {
  transform: translateX(-3px);
}

.report-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-areas: "main" "score" "stats" "error" "summary";
  gap: 32px;
}

.head-main {
  grid-area: main;
  min-width: 0;
}

.head-kicker {
  margin-bottom: 14px;
}

.report-head h1,
.cmp-head h1 {
  font-size: clamp(1.75rem, 1.2rem + 2vw, 2.875rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  max-width: 21em;
  overflow-wrap: anywhere;
}

.head-url {
  margin-top: 18px;
  font-family: var(--mono);
  font-size: 0.875rem;
  color: var(--text-2);
  overflow-wrap: anywhere;
}

.head-score {
  grid-area: score;
  min-width: 0;
}

.head-score .gauge-caption {
  margin-bottom: 12px;
}

.report-head > .error-box {
  grid-area: error;
}

@media (min-width: 900px) {
  .report-head {
    grid-template-columns: minmax(0, 1fr) 300px;
    grid-template-areas: "main score" "stats stats" "error error" "summary summary";
    column-gap: 64px;
  }
  .head-score {
    padding-left: 32px;
    border-left: 1px solid var(--rule);
  }
}

/* Score: a mono numeral over ten cells. */
.gauge {
  display: grid;
  justify-items: start;
  gap: 14px;
}

.gauge-label {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.gauge-number {
  font-family: var(--mono);
  font-size: 5rem;
  font-weight: 700;
  line-height: 0.9;
  letter-spacing: -0.05em;
  color: var(--text);
}

.gauge.tone-bad .gauge-number {
  color: var(--accent-text);
  background: var(--mark-bg);
  padding: var(--mark-pad);
}

.gauge.tone-good .gauge-number {
  color: var(--good);
}

.gauge.tone-none .gauge-number {
  color: var(--muted);
  font-size: 3.5rem;
}

.gauge-of {
  font-family: var(--mono);
  font-size: 1rem;
  color: var(--muted);
}

.gauge-verdict {
  font-weight: 700;
  color: var(--text);
}

/* Facts strip under the title. */
.head-stats {
  grid-area: stats;
  display: flex;
  flex-wrap: wrap;
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--rule-strong);
  border-bottom: 1px solid var(--rule);
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 28px 14px 0;
  margin-right: 28px;
  border-right: 1px solid var(--rule);
  min-width: 0;
}

.stat:last-child {
  border-right: 0;
  margin-right: 0;
}

.stat-value {
  font-size: 1.0625rem;
  font-weight: 700;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}

.stat-bad .stat-value {
  color: var(--accent-text);
  background: var(--mark-bg);
  padding: var(--mark-pad);
  justify-self: start;
  align-self: flex-start;
}

.stat-model .stat-value {
  font-family: var(--mono);
  font-size: 0.875rem;
  font-weight: 400;
  color: var(--text-2);
  padding-top: 2px;
}

@media (max-width: 699px) {
  .head-stats {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .stat {
    padding: 12px 12px 12px 0;
    margin: 0;
    border-right: 0;
    border-bottom: 1px solid var(--rule);
  }
  .stat:last-child {
    border-bottom: 0;
  }
  .stat-status,
  .stat-model {
    grid-column: 1 / -1;
  }
}

/* The agent's verdict. */
.summary {
  grid-area: summary;
  margin: 0;
  display: grid;
  gap: 12px;
}

.summary blockquote {
  margin: 0;
  padding-left: 20px;
  border-left: 2px solid var(--rule-strong);
}

.summary blockquote p {
  font-size: clamp(1.125rem, 1rem + 0.5vw, 1.375rem);
  line-height: 1.45;
  color: var(--text);
  max-width: 38em;
}

@media (min-width: 900px) {
  .summary {
    grid-template-columns: 200px minmax(0, 1fr);
    gap: 32px;
  }
  .summary figcaption {
    padding-top: 6px;
  }
}

/* ------------------------------------------------------------------ report: toolbar */

.report-actions-slot:empty {
  display: none;
}

.report-actions-slot {
  margin-top: 40px;
}

.report-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 56px;
  padding: 16px 0;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

.action-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
  min-width: 0;
}

.action-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.action-prefix {
  font-size: 0.875rem;
  color: var(--text-2);
}

.action-note {
  font-size: 0.875rem;
}

.compare-select {
  width: auto;
  max-width: 100%;
  min-height: 36px;
  padding: 5px 36px 5px 10px;
  font-size: 0.875rem;
}

.copy-status {
  font-size: 0.875rem;
  color: var(--good);
}

.copy-status.tone-bad {
  color: var(--accent-text);
  background: var(--mark-bg);
  padding: var(--mark-pad);
}

/* ------------------------------------------------------------------ report: live status */

.live-banner {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 32px;
}

.live-banner:empty {
  display: none;
}

.live-banner.is-running,
.live-banner.is-warning {
  padding: 14px 18px;
  border: 1px solid var(--rule-strong);
  box-shadow: inset 4px 0 var(--yellow);
  padding-left: 22px;
}

.live-text {
  min-width: 0;
  overflow-wrap: anywhere;
}

.live-text strong {
  font-weight: 700;
}

.radar {
  position: relative;
  flex: none;
  width: 10px;
  height: 10px;
}

.radar span {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: var(--yellow);
}

@media (prefers-color-scheme: light) {
  .radar span:last-child {
    box-shadow: 0 0 0 1px #0d0d0c;
  }
}

.radar span:first-child {
  animation: ping 1.6s cubic-bezier(0, 0, 0.2, 1) infinite;
}

@keyframes ping {
  75%,
  100% {
    transform: scale(2.6);
    opacity: 0;
  }
}

.jump {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 28px;
  margin-top: 48px;
  font-size: 0.9375rem;
  font-weight: 600;
}

.jump a {
  color: var(--text-2);
}

.jump a:hover {
  color: var(--text);
}

/* ------------------------------------------------------------------ report: issues ("blind spots") */

.issues-section {
  margin-top: 40px;
  padding-top: 28px;
  border-top: 1px solid var(--rule-strong);
  display: grid;
  gap: 8px 64px;
}

.issues-section .section-head,
.cmp-section .section-head {
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 12px;
  margin: 0;
}

.sev-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 16px;
  font-family: var(--mono);
  font-size: 0.875rem;
  color: var(--text-2);
}

.sev-count {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
}

.sev-count strong {
  font-weight: 700;
  color: var(--text);
}

.sev-count.sev-critical {
  color: var(--accent-text);
  background: var(--mark-bg);
  padding: var(--mark-pad);
}

.sev-count.sev-critical strong {
  color: inherit;
}

@media (min-width: 900px) {
  .issues-section {
    grid-template-columns: 250px minmax(0, 1fr);
  }
  .issues-section .section-head,
  .cmp-section .section-head {
    position: sticky;
    top: 24px;
    align-self: start;
  }
  .sev-summary {
    flex-direction: column;
    align-items: flex-start;
    margin-top: 4px;
  }
}

.issues {
  list-style: none;
  margin: 0;
  padding: 0;
}

.issue {
  padding: 24px 0 28px;
  border-bottom: 1px solid var(--rule);
  scroll-margin-top: 24px;
}

/* A blocking blind spot gets the tactile strip. */
.issue.is-blocking {
  padding-left: 22px;
  box-shadow: inset 5px 0 var(--yellow), inset 6px 0 var(--bar-edge);
}

.issue:first-child {
  padding-top: 8px;
}

.issue:focus-visible {
  outline-offset: 6px;
}

.issue-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 16px;
}

.issue-num {
  font-family: var(--mono);
  font-size: 0.875rem;
  color: var(--muted);
}

.issue-step {
  margin-left: auto;
  font-family: var(--mono);
  font-size: 0.875rem;
  color: var(--text-2);
}

.issue-title {
  margin-top: 12px;
  font-size: clamp(1.25rem, 1.15rem + 0.4vw, 1.5rem);
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.issue-desc {
  margin-top: 8px;
  color: var(--text-2);
  max-width: var(--measure);
}

.issue-meta {
  display: grid;
  gap: 10px;
  margin: 18px 0 0;
}

.issue-meta > div {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: 12px;
  align-items: baseline;
}

.issue-meta dd {
  margin: 0;
  min-width: 0;
  font-size: 0.9375rem;
}

/* WCAG criteria: plain links separated by a middle dot. */
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.chips li:not(:last-child)::after {
  content: "·";
  content: "·" / "";
  margin: 0 10px;
  color: var(--muted);
}

.chip.wcag {
  color: var(--text);
}

.chip-num {
  font-family: var(--mono);
  font-weight: 700;
}

/* An element as a screen reader names it. */
.el-chip {
  font-family: var(--mono);
  font-size: 0.875em;
  overflow-wrap: anywhere;
}

.el-role {
  color: var(--muted);
}

.el-name {
  color: var(--text);
}

.el-chip.is-empty .el-name {
  color: var(--accent-text);
  background: var(--mark-bg);
  padding: var(--mark-pad);
}

.el-warn {
  margin-left: 8px;
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent-text);
  white-space: nowrap;
}

.el-html {
  display: block;
  margin-top: 6px;
  font-size: 0.8125rem;
  color: var(--muted);
  overflow-wrap: anywhere;
}

/* The fix: code on a dark panel, with copy. */
.fix {
  margin-top: 20px;
  max-width: 52rem;
}

.fix > summary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  list-style: none;
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--text);
}

.fix > summary::-webkit-details-marker {
  display: none;
}

.fix > summary::before {
  content: "+";
  content: "+" / "";
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border: 1.5px solid currentColor;
  border-radius: 50%;
  font-family: var(--mono);
  font-size: 0.875rem;
  line-height: 1;
}

.fix[open] > summary::before {
  content: "−";
  content: "−" / "";
}

.fix > summary:hover {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.2em;
}

.fix-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.fix-label {
  color: var(--text);
}

.fix-code {
  margin: 10px 0 0;
  padding: 16px 18px;
  background: var(--term-bg);
  border: 1px solid var(--term-border);
  border-radius: var(--radius);
  font-size: 0.8125rem;
  line-height: 1.65;
  color: var(--term-text);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  max-height: 28rem;
  overflow: auto;
}

.fix-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.fix-foot {
  display: flex;
  justify-content: flex-end;
  margin-top: 8px;
}

/* ------------------------------------------------------------------ report: steps, a timeline of announcements */

.steps-section {
  margin-top: 96px;
  padding-top: 28px;
  border-top: 1px solid var(--rule-strong);
}

.steps-section .section-head {
  margin-bottom: 8px;
}

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
}

.step {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 0 24px;
  padding: 36px 0 40px;
  scroll-margin-top: 16px;
}

.step:focus-visible {
  outline-offset: 0;
}

/* The rail: a number, then a thin line down to the next step. */
.step-rail {
  position: relative;
}

.step-rail::after {
  content: "";
  position: absolute;
  top: 44px;
  bottom: -44px;
  left: 18px;
  width: 1px;
  background: var(--rule);
}

.step:last-child .step-rail::after {
  display: none;
}

.step-num {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1.5px solid var(--rule-strong);
  border-radius: 50%;
  font-family: var(--mono);
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--text);
  background: var(--bg);
}

.step.is-failed .step-num {
  border-color: var(--yellow);
  background: var(--yellow);
  color: var(--on-yellow);
}

@media (prefers-color-scheme: light) {
  .step.is-failed .step-num {
    border-color: #0d0d0c;
  }
}

.step-card {
  min-width: 0;
}

.step-head {
  display: flex;
  align-items: baseline;
  gap: 12px 20px;
}

.step-num-inline {
  display: none;
  font-family: var(--mono);
  font-size: 0.8125rem;
  color: var(--muted);
}

.step-title {
  flex: 1;
  min-width: 0;
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

.step-title .el-chip {
  font-size: 0.85em;
  font-weight: 400;
}

.step-title .el-warn {
  vertical-align: 0.15em;
}

q.value {
  font-family: var(--mono);
  font-size: 0.85em;
  font-weight: 400;
}

.ok-badge {
  flex: none;
  font-family: var(--mono);
  font-size: 0.8125rem;
  font-weight: 700;
}

.ok-badge.is-ok {
  color: var(--good);
}

.ok-badge.is-fail {
  color: var(--accent-text);
  background: var(--mark-bg);
  padding: var(--mark-pad);
}

.step-facts {
  display: grid;
  gap: 16px 40px;
  margin: 16px 0 0;
}

@media (min-width: 900px) {
  .step-facts {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }
}

.fact dt {
  margin-bottom: 4px;
}

.fact dd {
  margin: 0;
}

.reason {
  font-style: italic;
  color: var(--text-2);
  max-width: var(--measure);
}

.result {
  font-family: var(--mono);
  font-size: 0.8125rem;
  line-height: 1.65;
  color: var(--text-2);
  overflow-wrap: anywhere;
}

.fact-fail .result {
  color: var(--accent-text);
}

@media (prefers-color-scheme: light) {
  .fact-fail .result {
    box-shadow: inset 3px 0 var(--yellow);
    padding-left: 10px;
  }
}

.step-issues-slot:empty {
  display: none;
}

.step-issues {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.step-issue {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--accent-text);
  background: var(--mark-bg);
  padding: var(--mark-pad);
  text-decoration-color: currentColor;
}

.step-issue .icon {
  width: 1em;
  height: 1em;
}

/* Heard first and larger; seen second, smaller and dimmed. */
.compare {
  display: grid;
  gap: 24px;
  margin-top: 24px;
}

@media (min-width: 1000px) {
  .compare {
    grid-template-columns: minmax(0, 5fr) minmax(0, 3fr);
    align-items: start;
  }
}

.pane {
  margin: 0;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.pane-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  margin-bottom: 8px;
}

.pane-icon {
  display: inline-flex;
  color: var(--muted);
}

.pane-title {
  flex: 1;
  font-size: 0.9375rem;
  font-weight: 700;
}

.pane-see .pane-title {
  font-weight: 600;
  color: var(--text-2);
}

.pane-see .screen-label {
  flex: none;
}

.shot-frame {
  flex: 1;
  border: 1px solid var(--rule);
  background: var(--bg-2);
  padding: 5px;
  border-radius: var(--radius);
}

.shot-btn {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: #fff;
  cursor: zoom-in;
}

.shot-btn img {
  display: block;
  width: 100%;
  height: auto;
  opacity: 0.62;
  filter: saturate(0.5);
  transition: opacity 0.2s, filter 0.2s;
}

@media (prefers-color-scheme: light) {
  .shot-btn img {
    opacity: 0.8;
  }
}

.shot-btn:hover img,
.shot-btn:focus-visible img {
  opacity: 1;
  filter: none;
}

.shot-zoom {
  position: absolute;
  top: 8px;
  right: 8px;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #0d0d0c;
  color: #f2efe6;
  opacity: 0;
  transition: opacity 0.15s;
}

.shot-btn:hover .shot-zoom,
.shot-btn:focus-visible .shot-zoom {
  opacity: 1;
}

.shot-missing {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 6px;
  height: 100%;
  min-height: 200px;
  padding: 32px 16px;
  text-align: center;
  color: var(--text-2);
  font-size: 0.9375rem;
}

.shot-missing .icon {
  width: 24px;
  height: 24px;
  color: var(--muted);
}

.shot-missing .muted {
  font-size: 0.8125rem;
}

.transcript {
  position: relative;
  max-height: 30rem;
  margin: 0;
  padding: 14px 0;
  overflow: auto;
  background: var(--term-bg);
  color: var(--term-text);
  font-size: 0.8125rem;
  line-height: 1.7;
  border-radius: var(--radius);
  border: 1px solid var(--term-border);
  scrollbar-color: var(--rule-strong) var(--term-bg);
}

.transcript:focus-visible {
  outline-offset: 2px;
}

.transcript-empty {
  display: grid;
  place-items: center;
  min-height: 8rem;
  font-family: var(--mono);
  color: var(--term-dim);
}

.t-line {
  display: block;
  padding-right: 18px;
  padding-left: calc(18px + (var(--in, 0) + 2) * 1ch);
  transition: color 0.2s, background-color 0.2s;
}

.t-id {
  color: var(--term-dim);
}

.t-empty {
  color: var(--yellow);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.2em;
}

.t-line.is-target {
  background: rgba(255, 210, 0, 0.07);
  box-shadow: inset 2px 0 var(--yellow);
}

.t-acted {
  margin-left: 10px;
  padding: 0 6px;
  border-radius: 2px;
  background: var(--yellow);
  color: #0d0d0c;
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 700;
  white-space: nowrap;
}

/* Listen = captions: the line being spoken is lit, the rest dims. */
.transcript.is-speaking .t-line {
  color: var(--term-dim);
}

.transcript .t-line.is-current {
  color: #ffffff;
  background: rgba(255, 210, 0, 0.16);
  box-shadow: inset 4px 0 var(--yellow);
}

.btn-listen {
  min-height: 34px;
  padding: 0 12px 0 10px;
  gap: 6px;
  border-radius: 999px;
}

.btn-listen.is-playing {
  --btn-bg: var(--yellow);
  --btn-fg: var(--on-yellow);
  --btn-border: var(--yellow);
}

.btn-listen.is-playing:hover:not(:disabled) {
  --btn-bg: var(--yellow);
  --btn-fg: var(--on-yellow);
  --btn-border: var(--text);
}

.btn-icon {
  display: inline-flex;
}

.step-url {
  margin-top: 10px;
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.steps-tail:empty {
  display: none;
}

.step-pending {
  display: grid;
  grid-template-columns: 64px auto minmax(0, 1fr);
  align-items: center;
  gap: 0 24px;
  padding: 28px 0;
  color: var(--text-2);
}

.step-pending .step-num {
  color: var(--muted);
  border-style: dashed;
}

.typing {
  display: inline-flex;
  gap: 5px;
}

.typing span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--yellow);
  animation: blink 1.2s infinite ease-in-out;
}

.typing span:nth-child(2) {
  animation-delay: 0.15s;
}

.typing span:nth-child(3) {
  animation-delay: 0.3s;
}

@keyframes blink {
  0%,
  80%,
  100% {
    opacity: 0.2;
  }
  40% {
    opacity: 1;
  }
}

.step.is-new {
  animation: rise 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
}

@media (max-width: 699px) {
  .step {
    grid-template-columns: minmax(0, 1fr);
    padding: 28px 0 32px;
    border-bottom: 1px solid var(--rule);
  }
  .step-rail {
    display: none;
  }
  .step-num-inline {
    display: block;
  }
  .step-head {
    flex-wrap: wrap;
  }
  .step-title {
    font-size: 1.125rem;
    flex-basis: 100%;
  }
  .step-num-inline {
    order: -2;
  }
  .ok-badge {
    order: -1;
    margin-left: auto;
  }
  .step-pending {
    grid-template-columns: auto minmax(0, 1fr);
  }
  .step-pending .step-num {
    display: none;
  }
  .transcript {
    max-height: 24rem;
  }
}

/* ------------------------------------------------------------------ compare view */

.cmp-head {
  display: grid;
  gap: 14px;
}

.cmp-head .head-kicker {
  margin: 0 0 12px;
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-2);
}

.cmp-note {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9375rem;
  color: var(--text-2);
}

.cmp-not-comparable {
  padding: 10px 14px 10px 18px;
  box-shadow: inset 4px 0 var(--yellow);
  background: var(--bg-2);
}

/* Before and after as two "heard" panels, the change between them. */
.cmp-scores {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  gap: 0;
  margin-top: 40px;
}

.cmp-run {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
  padding: 24px 28px 28px;
  min-width: 0;
  background: var(--term-bg);
  color: var(--text);
  border: 1px solid var(--term-border);
  border-radius: var(--radius);
}

.cmp-run-label {
  font-size: 1.5rem;
}

.cmp-run .gauge {
  margin-top: 4px;
}

.cmp-run .gauge-number {
  font-size: clamp(4rem, 2.6rem + 3.5vw, 6.5rem);
}

.cmp-run .gauge.tone-none .gauge-number {
  font-size: 3.5rem;
}

.cmp-run-facts {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.9375rem;
  color: var(--text-2);
  display: grid;
  gap: 2px;
}

.cmp-run-url {
  font-family: var(--mono);
  font-size: 0.8125rem;
  overflow-wrap: anywhere;
}

.cmp-run > .btn {
  margin-top: 4px;
}

.cmp-delta {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 24px 32px;
  text-align: center;
  --tone-color: var(--text);
}

.cmp-delta.tone-good {
  --tone-color: var(--good);
}

.cmp-delta.tone-bad {
  --tone-color: var(--accent-text);
}

.cmp-delta-arrow {
  display: inline-flex;
  color: var(--muted);
}

.cmp-delta-num {
  font-family: var(--mono);
  font-size: clamp(2.5rem, 1.8rem + 2.4vw, 4rem);
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: -0.04em;
  color: var(--tone-color);
}

.cmp-delta.tone-bad .cmp-delta-num {
  background: var(--mark-bg);
  padding: var(--mark-pad);
}

.cmp-delta-label {
  font-family: var(--mono);
  font-size: 0.8125rem;
  color: var(--muted);
}

.compare-view .jump {
  margin-top: 40px;
}

.cmp-section {
  margin-top: 64px;
  padding-top: 28px;
  border-top: 1px solid var(--rule-strong);
  display: grid;
  gap: 8px 64px;
}

.cmp-section h2 {
  display: block;
  font-size: clamp(1.625rem, 1.4rem + 0.6vw, 1.875rem);
}

.cmp-section-icon {
  display: inline-flex;
  margin-right: 10px;
  vertical-align: -0.08em;
  color: var(--tone-color, var(--muted));
}

.cmp-section-icon .icon {
  width: 24px;
  height: 24px;
}

.cmp-section-icon.tone-good {
  --tone-color: var(--good);
}

.cmp-section-icon.tone-warn {
  --tone-color: var(--text-2);
}

.cmp-section-icon.tone-bad {
  --tone-color: var(--accent-text);
}

/* A fixed blind spot is no longer a barrier: it loses the yellow. */
.cmp-good .cmp-issue.is-blocking {
  padding-left: 0;
  box-shadow: none;
}

.cmp-good .sev-label.sev-critical,
.cmp-good .sev-label.is-blocking,
.cmp-good .el-chip.is-empty .el-name,
.cmp-good .el-warn {
  color: var(--text-2);
  background: none;
  padding: 0;
}

@media (min-width: 900px) {
  .cmp-section {
    grid-template-columns: 250px minmax(0, 1fr);
  }
}

.cmp-issues {
  list-style: none;
  margin: 0;
  padding: 0;
}

.cmp-issue {
  padding: 4px 0 22px;
  border-bottom: 1px solid var(--rule);
}

.cmp-issue.is-blocking {
  padding-left: 22px;
  box-shadow: inset 5px 0 var(--yellow), inset 6px 0 var(--bar-edge);
}

.cmp-issue + .cmp-issue {
  padding-top: 20px;
}

.cmp-issue-title {
  margin-top: 10px;
  font-size: 1.25rem;
  line-height: 1.25;
}

.cmp-issue-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 24px;
  margin-top: 8px;
  font-size: 0.9375rem;
}

.cmp-change {
  font-size: 0.875rem;
  font-style: italic;
  color: var(--text-2);
}

.cmp-section .empty {
  padding: 4px 0 0;
}

@media (max-width: 699px) {
  .cmp-scores {
    grid-template-columns: minmax(0, 1fr);
  }
  .cmp-run {
    padding: 20px;
  }
  .cmp-delta {
    flex-direction: row;
    justify-content: flex-start;
    gap: 14px;
    padding: 16px 4px;
    text-align: left;
  }
  .cmp-delta-arrow {
    transform: rotate(90deg);
  }
}

/* ------------------------------------------------------------------ lightbox */

.lightbox {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--text);
  max-width: min(1400px, 96vw);
  max-height: 94vh;
  width: auto;
}

.lightbox::backdrop {
  background: rgba(5, 5, 5, 0.92);
}

.lightbox-inner {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 94vh;
  padding: 8px; /* room for the focus ring of Close */
}

.lightbox-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.lightbox-caption {
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.25;
}

.lightbox-close {
  flex: none;
}

.lightbox-close kbd {
  font-size: 0.75rem;
  color: var(--muted);
}

.lightbox img {
  display: block;
  max-width: 100%;
  max-height: calc(94vh - 64px);
  object-fit: contain;
  background: #fff;
}

/* ------------------------------------------------------------------ "Hear this page" overlay */

.hear-layer {
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  z-index: 50;
  pointer-events: none;
}

.hear-box {
  position: absolute;
  outline: 1px dashed var(--hear-outline);
  outline-offset: 1px;
  border-radius: 2px;
}

.hear-box.is-landmark {
  outline-style: solid;
  outline-offset: -1px;
  opacity: 0.6;
}

.hear-label {
  position: absolute;
  max-width: calc(100vw - 8px);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 1px 6px;
  border: 1px solid var(--yellow);
  border-radius: 3px;
  background: #0d0d0c;
  color: #f2efe6;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 400;
  line-height: 1.4;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
}

.hear-role {
  color: #b9b5aa;
}

.hear-name {
  color: #ffffff;
}

.hear-state {
  color: var(--yellow);
}

.hear-label.is-empty .hear-name {
  color: #0d0d0c;
  background: var(--yellow);
}

.hear-label.is-landmark {
  background: var(--yellow);
  border-color: #0d0d0c;
}

.hear-label.is-landmark .hear-role,
.hear-label.is-landmark .hear-name {
  color: #0d0d0c;
  font-weight: 700;
}

/* The computed labels replace the decorative role prefixes while hearing. */
.is-hearing .announce-role {
  visibility: hidden;
}

/* Sticky headings would drift away from their labels. */
.is-hearing .issues-section .section-head,
.is-hearing .cmp-section .section-head {
  position: static;
}

/* ------------------------------------------------------------------ motion & contrast preferences */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    transition-delay: 0s !important;
    scroll-behavior: auto !important;
  }
  .radar span:first-child {
    display: none;
  }
}

@media (forced-colors: active) {
  .cells,
  .sev-dots,
  .switch,
  .pulse-dot,
  .radar,
  .typing,
  .preset-dot,
  .note-num,
  .pin,
  .demo-notes li::before {
    forced-color-adjust: none;
  }
  .cell,
  .sev-dots span {
    border-color: CanvasText;
  }
  .cell.is-on,
  .sev-dots .is-on,
  .pulse-dot,
  .radar span,
  .typing span,
  .preset-bad .preset-dot {
    background: CanvasText;
    border-color: CanvasText;
  }
  .switch {
    border-color: ButtonText;
  }
  .switch-knob {
    background: ButtonText;
  }
  [aria-pressed="true"] > .switch {
    background: Highlight;
    border-color: Highlight;
  }
  [aria-pressed="true"] > .switch .switch-knob {
    background: HighlightText;
  }
  .note-num,
  .pin,
  .demo-notes li::before {
    background: Canvas;
    color: CanvasText;
    border: 1px solid CanvasText;
  }
  .brand-cross {
    stroke: CanvasText;
  }
  .brand-spot {
    fill: CanvasText;
  }
  .t-acted,
  .note-flag,
  .hear-label,
  .step-num {
    border: 1px solid CanvasText;
  }
  .t-line.is-target,
  .dl.is-barrier,
  .issue.is-blocking,
  .cmp-issue.is-blocking {
    border-left: 4px solid CanvasText;
  }
  .t-line.is-current {
    outline: 2px solid Highlight;
    outline-offset: -2px;
  }
  .tactile,
  .hero::after {
    display: none;
  }
}

@media print {
  .site-header,
  .site-footer,
  .report-actions-slot,
  .jump,
  .btn-listen,
  .crumbs,
  .screen-toggle {
    display: none;
  }
  .transcript {
    max-height: none;
    overflow: visible;
  }
}
