:root {
  color-scheme: light dark;
  --bg: #f5f5f5;
  --panel: #fff;
  --text: #1d1d1f;
  --muted: #62656a;
  --border: #d9d9dc;
  --accent: #2f5d50;
  --soft: #eef4f1;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1d1e20;
    --panel: #252629;
    --text: #ececee;
    --muted: #b3b5ba;
    --border: #42444a;
    --accent: #9ac8b9;
    --soft: #293a35;
  }
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.5 ui-sans-serif, system-ui, sans-serif;
}
main { max-width: 980px; margin: auto; padding: 1.25rem; }
h1, h2, p { margin-top: 0; }
h1 { font-size: clamp(1.55rem, 4vw, 2.2rem); }
.lede, .muted { color: var(--muted); }
.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.panel {
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--panel);
}
label { display: grid; gap: 0.35rem; color: var(--muted); font-weight: 650; }
textarea, input, select, button {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 0.7rem;
  background: var(--panel);
  color: var(--text);
  font: inherit;
}
textarea { min-height: 150px; resize: vertical; }
button { cursor: pointer; background: var(--accent); color: var(--bg); font-weight: 750; }
button.secondary { background: var(--soft); color: var(--text); }
button:focus-visible, textarea:focus-visible, input:focus-visible, select:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}
.actions { display: flex; gap: 0.65rem; margin-top: 0.8rem; }
.chips { display: flex; flex-wrap: wrap; gap: 0.45rem; margin: 0 0 1rem; }
.chip { padding: 0.25rem 0.55rem; border: 1px solid var(--border); border-radius: 999px; color: var(--muted); }
pre { white-space: pre-wrap; overflow-wrap: anywhere; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 0.55rem; text-align: left; border-bottom: 1px solid var(--border); }
.pass { color: #268b57; font-weight: 700; }
.fail { color: #b94444; font-weight: 700; }
.metric { font-size: 1.5rem; font-weight: 800; }
@media (max-width: 680px) {
  main { padding: 0.75rem; }
  .grid { grid-template-columns: 1fr; }
  .actions { flex-direction: column; }
}
