:root {
  color-scheme: light;
  --bg: #f6f6f4; --surface: #fcfcfb; --line: #e3e2de; --text: #0b0b0b; --text-2: #52514e; --muted: #6f6e69;
  --accent: #1c5cab; --accent-ink: #fff; --bar: #2a78d6;
  --good: #1f7a3d; --good-bg: #e3f3e8; --warn: #8a5a00; --warn-bg: #fbf0d9; --bad: #a3212a; --bad-bg: #fbe5e6;
  font: 15px/1.5 system-ui, -apple-system, "Segoe UI", sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --bg: #121211; --surface: #1a1a19; --line: #33322f; --text: #fff; --text-2: #c3c2b7; --muted: #9a998f;
    --accent: #6da7ec; --accent-ink: #0b0b0b; --bar: #3987e5;
    --good: #7fd197; --good-bg: #17301f; --warn: #f0c46a; --warn-bg: #3a2d10; --bad: #f19aa0; --bad-bg: #3d1a1d;
  }
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text); }
a { color: var(--accent); }
main { max-width: 1180px; margin: 0 auto; padding: 24px 20px 64px; }
h1 { font-size: 26px; margin: 8px 0 16px; }
h2 { font-size: 18px; margin: 0 0 12px; }
h3 { font-size: 15px; margin: 20px 0 8px; color: var(--text-2); }
code, pre { font: 13px/1.45 ui-monospace, SFMono-Regular, Menlo, monospace; }
.wrap { word-break: break-all; }
.muted { color: var(--muted); } .small { font-size: 13px; }
.top { display: flex; gap: 20px; align-items: center; padding: 10px 20px; background: var(--surface); border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.brand { font-weight: 650; color: var(--text); text-decoration: none; }
.top nav { display: flex; gap: 4px; flex-wrap: wrap; flex: 1; align-items: center; }
.top nav a { padding: 6px 10px; border-radius: 6px; text-decoration: none; color: var(--text-2); }
.top nav a.on, .top nav a:hover { background: var(--bg); color: var(--text); }
.top .sep { width: 1px; height: 20px; background: var(--line); margin: 0 6px; }
.me { display: flex; gap: 12px; align-items: center; font-size: 13px; }
.me form { margin: 0; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 18px 20px; margin: 0 0 18px; overflow-x: auto; }
.card.danger { border-color: var(--bad); }
.narrow { max-width: 420px; margin: 60px auto; }
.narrow-form { max-width: 480px; }
label { display: block; margin: 0 0 12px; font-size: 14px; color: var(--text-2); }
label.check { display: flex; gap: 8px; align-items: center; color: var(--text); }
input, select, textarea { display: block; width: 100%; margin-top: 4px; padding: 8px 10px; font: inherit; color: var(--text);
  background: var(--bg); border: 1px solid var(--line); border-radius: 6px; }
label.check input { width: auto; margin: 0; }
textarea { resize: vertical; font: 13px/1.45 ui-monospace, Menlo, monospace; }
fieldset { border: 1px solid var(--line); border-radius: 8px; padding: 10px 14px; margin: 0 0 12px; }
legend { color: var(--text-2); font-size: 14px; padding: 0 4px; }
fieldset select { display: inline-block; width: auto; margin-left: 8px; }
button, .button { display: inline-block; padding: 8px 14px; font: inherit; border-radius: 6px; border: 1px solid var(--line);
  background: var(--surface); color: var(--text); cursor: pointer; text-decoration: none; }
button.primary, .button.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
button.danger { background: var(--bad); color: #fff; border-color: var(--bad); }
button.link { border: 0; background: none; padding: 0; color: var(--accent); text-decoration: underline; font-size: inherit; }
button.copy { padding: 2px 8px; font-size: 12px; margin-left: 8px; vertical-align: middle; }
.blur { filter: blur(5px); user-select: none; }
form.inline { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; }
form.inline label { margin: 0; }
form.inline input[size] { width: auto; display: inline-block; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 0 18px; align-items: end; }
.two { display: grid; grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); gap: 0 18px; }
.row-between { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.filters { display: flex; gap: 14px; align-items: flex-end; flex-wrap: wrap; margin-bottom: 8px; }
.filters label { margin: 0; } .filters .right { margin-left: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--text-2); font-weight: 550; font-size: 13px; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
table.plain th { width: 160px; }
tr.revoked td { opacity: .55; }
td.actions { white-space: nowrap; } td.actions form { display: inline; margin-left: 8px; }
.tag { display: inline-block; padding: 1px 8px; border-radius: 99px; font-size: 12px; background: var(--bg); border: 1px solid var(--line); }
.tag.good { color: var(--good); background: var(--good-bg); border-color: transparent; }
.tag.warn { color: var(--warn); background: var(--warn-bg); border-color: transparent; }
.tag.bad { color: var(--bad); background: var(--bad-bg); border-color: transparent; }
.note { padding: 10px 14px; border-radius: 8px; margin-bottom: 16px; }
.note.ok { background: var(--good-bg); color: var(--good); }
.note.err { background: var(--bad-bg); color: var(--bad); }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; margin-bottom: 18px; }
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; }
.tile .label { color: var(--text-2); font-size: 13px; }
.tile .big { font-size: 28px; font-weight: 650; font-variant-numeric: tabular-nums; margin: 2px 0; }
.secret { background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; }
pre.snippet, pre.json, pre.codes { background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 12px; overflow-x: auto; white-space: pre; }
pre.json { max-height: 520px; overflow: auto; white-space: pre-wrap; word-break: break-word; }
.qr { display: block; margin: 12px 0; border-radius: 8px; }
dl.kv { display: grid; grid-template-columns: 160px 1fr; gap: 6px 14px; margin: 0 0 16px; }
dl.kv dt { color: var(--text-2); } dl.kv dd { margin: 0; }
/* tokens per day: one series, so no legend; the title names it and the table holds the numbers */
.bars { display: flex; align-items: flex-end; gap: 2px; height: 180px; border-bottom: 1px solid var(--line); padding-top: 8px; }
.bar { flex: 1; height: 100%; display: flex; align-items: flex-end; cursor: default; outline: none; min-width: 3px; }
.bar span { display: block; width: 100%; background: var(--bar); border-radius: 4px 4px 0 0; }
.bar span.h0 { height: 0; }
.bar span.h1 { height: 1%; }
.bar span.h2 { height: 2%; }
.bar span.h3 { height: 3%; }
.bar span.h4 { height: 4%; }
.bar span.h5 { height: 5%; }
.bar span.h6 { height: 6%; }
.bar span.h7 { height: 7%; }
.bar span.h8 { height: 8%; }
.bar span.h9 { height: 9%; }
.bar span.h10 { height: 10%; }
.bar span.h11 { height: 11%; }
.bar span.h12 { height: 12%; }
.bar span.h13 { height: 13%; }
.bar span.h14 { height: 14%; }
.bar span.h15 { height: 15%; }
.bar span.h16 { height: 16%; }
.bar span.h17 { height: 17%; }
.bar span.h18 { height: 18%; }
.bar span.h19 { height: 19%; }
.bar span.h20 { height: 20%; }
.bar span.h21 { height: 21%; }
.bar span.h22 { height: 22%; }
.bar span.h23 { height: 23%; }
.bar span.h24 { height: 24%; }
.bar span.h25 { height: 25%; }
.bar span.h26 { height: 26%; }
.bar span.h27 { height: 27%; }
.bar span.h28 { height: 28%; }
.bar span.h29 { height: 29%; }
.bar span.h30 { height: 30%; }
.bar span.h31 { height: 31%; }
.bar span.h32 { height: 32%; }
.bar span.h33 { height: 33%; }
.bar span.h34 { height: 34%; }
.bar span.h35 { height: 35%; }
.bar span.h36 { height: 36%; }
.bar span.h37 { height: 37%; }
.bar span.h38 { height: 38%; }
.bar span.h39 { height: 39%; }
.bar span.h40 { height: 40%; }
.bar span.h41 { height: 41%; }
.bar span.h42 { height: 42%; }
.bar span.h43 { height: 43%; }
.bar span.h44 { height: 44%; }
.bar span.h45 { height: 45%; }
.bar span.h46 { height: 46%; }
.bar span.h47 { height: 47%; }
.bar span.h48 { height: 48%; }
.bar span.h49 { height: 49%; }
.bar span.h50 { height: 50%; }
.bar span.h51 { height: 51%; }
.bar span.h52 { height: 52%; }
.bar span.h53 { height: 53%; }
.bar span.h54 { height: 54%; }
.bar span.h55 { height: 55%; }
.bar span.h56 { height: 56%; }
.bar span.h57 { height: 57%; }
.bar span.h58 { height: 58%; }
.bar span.h59 { height: 59%; }
.bar span.h60 { height: 60%; }
.bar span.h61 { height: 61%; }
.bar span.h62 { height: 62%; }
.bar span.h63 { height: 63%; }
.bar span.h64 { height: 64%; }
.bar span.h65 { height: 65%; }
.bar span.h66 { height: 66%; }
.bar span.h67 { height: 67%; }
.bar span.h68 { height: 68%; }
.bar span.h69 { height: 69%; }
.bar span.h70 { height: 70%; }
.bar span.h71 { height: 71%; }
.bar span.h72 { height: 72%; }
.bar span.h73 { height: 73%; }
.bar span.h74 { height: 74%; }
.bar span.h75 { height: 75%; }
.bar span.h76 { height: 76%; }
.bar span.h77 { height: 77%; }
.bar span.h78 { height: 78%; }
.bar span.h79 { height: 79%; }
.bar span.h80 { height: 80%; }
.bar span.h81 { height: 81%; }
.bar span.h82 { height: 82%; }
.bar span.h83 { height: 83%; }
.bar span.h84 { height: 84%; }
.bar span.h85 { height: 85%; }
.bar span.h86 { height: 86%; }
.bar span.h87 { height: 87%; }
.bar span.h88 { height: 88%; }
.bar span.h89 { height: 89%; }
.bar span.h90 { height: 90%; }
.bar span.h91 { height: 91%; }
.bar span.h92 { height: 92%; }
.bar span.h93 { height: 93%; }
.bar span.h94 { height: 94%; }
.bar span.h95 { height: 95%; }
.bar span.h96 { height: 96%; }
.bar span.h97 { height: 97%; }
.bar span.h98 { height: 98%; }
.bar span.h99 { height: 99%; }
.bar span.h100 { height: 100%; }

.bar.hover span, .bar:focus span { opacity: .75; }
.bar-axis { display: flex; justify-content: space-between; margin: 6px 0 10px; }
.tip { position: absolute; display: none; background: var(--text); color: var(--surface); font-size: 12px; padding: 6px 9px; border-radius: 6px; pointer-events: none; z-index: 10; max-width: 320px; }
details summary { cursor: pointer; color: var(--accent); margin: 6px 0; }
.choices { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.choice { display: block; text-decoration: none; color: var(--text); margin: 0; }
.choice:hover { border-color: var(--accent); }
.choice p { margin: 0; }
.keyrow { padding: 8px 0; border-bottom: 1px solid var(--line); }
.top-gap { margin-top: 16px; }
details > summary { margin: 14px 0 4px; font-weight: 550; }
