/* Layout concept: a quiet lab console. Cool green-grey neutrals, one verdigris accent,
   sans for reading, mono for every measured number (latency, tokens, throughput). */
:root {
  --bg: #f3f5f3;
  --surface: #ffffff;
  --surface-2: #eaeeeb;
  --ink: #17201c;
  --ink-2: #3c4842;
  --muted: #66746d;
  --line: #d9e0dc;
  --line-strong: #c3cdc8;
  --accent: #0e6b57;
  --accent-hover: #0a5949;
  --accent-ink: #ffffff;
  --accent-soft: #dff0ea;
  --good: #2b7a3d;
  --good-soft: #e2f2e5;
  --bad: #b3261e;
  --bad-soft: #fbe6e4;
  --warn: #9a5b00;
  --warn-soft: #fbefd9;
  --code-bg: #f0f3f1;
  --shadow: 0 1px 2px rgba(20, 35, 28, .06), 0 8px 24px rgba(20, 35, 28, .08);
  --font-sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --r-sm: 6px;
  --r-md: 10px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0e1412; --surface: #151d1a; --surface-2: #1c2622; --ink: #e4ebe7; --ink-2: #c3cec8;
    --muted: #8e9e96; --line: #26322d; --line-strong: #34433d; --accent: #4fbf9f; --accent-hover: #6fd1b4;
    --accent-ink: #062018; --accent-soft: #173229; --good: #6cc37f; --good-soft: #17301d; --bad: #f08a80;
    --bad-soft: #3a1b18; --warn: #e0a54a; --warn-soft: #34270f; --code-bg: #111916;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .35);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0e1412; --surface: #151d1a; --surface-2: #1c2622; --ink: #e4ebe7; --ink-2: #c3cec8;
  --muted: #8e9e96; --line: #26322d; --line-strong: #34433d; --accent: #4fbf9f; --accent-hover: #6fd1b4;
  --accent-ink: #062018; --accent-soft: #173229; --good: #6cc37f; --good-soft: #17301d; --bad: #f08a80;
  --bad-soft: #3a1b18; --warn: #e0a54a; --warn-soft: #34270f; --code-bg: #111916;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .35);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 15px/1.55 var(--font-sans); -webkit-font-smoothing: antialiased;
}
[hidden] { display: none !important; }
button, input, textarea, select { font: inherit; color: inherit; }
a { color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3 { text-wrap: balance; margin: 0; line-height: 1.2; }
.mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 36px; padding: 0 14px; border-radius: var(--r-sm); border: 1px solid var(--line-strong);
  background: var(--surface); color: var(--ink); cursor: pointer; font-weight: 500; font-size: 14px;
  white-space: nowrap; transition: background .12s, border-color .12s;
}
.btn:hover { background: var(--surface-2); }
.btn:disabled { opacity: .5; cursor: default; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn.danger { color: var(--bad); }
.btn.ghost { border-color: transparent; background: transparent; }
.btn.ghost:hover { background: var(--surface-2); }
.btn.sm { height: 30px; padding: 0 10px; font-size: 13px; }
.btn.icon { width: 32px; height: 32px; padding: 0; }

.field { display: grid; gap: 6px; }
.field > span { font-size: 13px; font-weight: 500; color: var(--ink-2); }
.field small { color: var(--muted); font-size: 12px; }
.input, textarea.input, select.input {
  width: 100%; min-height: 38px; padding: 8px 11px; border-radius: var(--r-sm);
  border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink);
}
textarea.input { resize: vertical; line-height: 1.45; }
.input:focus { outline: 2px solid var(--accent); outline-offset: -1px; border-color: transparent; }
.error-text { color: var(--bad); font-size: 13px; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
