:root {
  color-scheme: light;
  font: 16px/1.5 system-ui, sans-serif;
  color: #182728;
  background: #f2f5f4;
  --muted: #506561;
  --line: #dce6e1;
  --accent: #156152;
  --positive: #146451;
  --negative: #9e3e34;
}
* { box-sizing: border-box; }
body { margin: 0; }
button, input, select { font: inherit; }
button, select { cursor: pointer; }
button:focus-visible, input:focus-visible, select:focus-visible, canvas:focus-visible { outline: 3px solid #268674; outline-offset: 3px; }
button { background: #fff; color: inherit; border: 1px solid var(--line); border-radius: 8px; padding: .55rem .85rem; }
button:hover { background: #edf5f0; }
button[aria-pressed=true], button.primary { color: white; background: var(--accent); border-color: var(--accent); }
button:disabled { opacity: .55; cursor: wait; }
main { width: min(1120px, 100% - 2rem); margin: 2.25rem auto 4rem; }
header { background: #152d2c; color: white; }
header > div { width: min(1120px, 100% - 2rem); margin: auto; padding: .9rem 0; display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
header button { color: white; background: transparent; border-color: #58746d; }
header button:hover { background: #234440; }
.brand { font-weight: 750; letter-spacing: -.025em; }
.gate { max-width: 420px; margin-top: clamp(3rem, 13vh, 9rem); }
h1, h2, p { margin: 0; }
h1 { font-size: clamp(2rem, 5vw, 3rem); font-weight: 740; letter-spacing: -.06em; line-height: 1.05; }
h2 { font-size: 1.2rem; letter-spacing: -.025em; }
p { margin: .7rem 0; }
.muted, small { color: var(--muted); }
small { font-size: .875rem; }
.panel, .metrics > div { background: white; border: 1px solid var(--line); border-radius: 14px; }
.panel { padding: 1.25rem; margin-top: 1rem; min-width: 0; }
nav, .controls { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
nav { margin: 1.2rem 0; }
.metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: .75rem; margin: 1.2rem 0; }
.metrics > div { padding: .9rem 1rem; }
.metrics strong { display: block; font-size: 1.5rem; letter-spacing: -.045em; font-variant-numeric: tabular-nums; }
.split { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 1rem; }
.panel-head { display: flex; align-items: baseline; justify-content: space-between; gap: .75rem; flex-wrap: wrap; }
.chart { width: 100%; height: 265px; display: block; margin-top: 1rem; }
.chart-status { min-height: 1.5rem; margin: 0; }
.scroll { overflow-x: auto; margin-top: .75rem; }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
td, th { padding: .65rem .55rem; border-bottom: 1px solid var(--line); text-align: left; }
td.numeric, th.numeric { text-align: right; white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
th { color: var(--muted); font-size: .875rem; font-weight: 650; white-space: nowrap; }
td small { display: block; }
label { display: grid; gap: .25rem; margin: .8rem 0; font-weight: 600; }
input, select { width: 100%; background: white; border: 1px solid #9fb5ad; border-radius: 8px; padding: .55rem .75rem; color: inherit; }
.controls input, .controls select { width: auto; max-width: 100%; }
[role=status] { min-height: 1.2em; }
.negative { color: var(--negative); }
.positive { color: var(--positive); }
.alloc { display: grid; gap: .6rem; padding: 0; list-style: none; }
.alloc li { display: grid; grid-template-columns: 1fr auto; gap: .15rem .5rem; }
progress { grid-column: 1/-1; width: 100%; height: .6rem; accent-color: var(--accent); }
@media (max-width: 720px) {
  main { margin-top: 1.5rem; }
  .split { grid-template-columns: 1fr; gap: 0; }
  .panel { padding: .85rem; }
  .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .metrics strong { font-size: 1.2rem; }
}
.chart-controls { margin-top: .65rem; }
