:root {
  --bg: #f5f6f8; --card: #ffffff; --text: #15181d; --muted: #5d6673; --line: #e2e5ea;
  --accent: #2563eb; --accent-text: #fff; --ok: #15803d; --bad: #b91c1c; --warn: #b45309;
  --code: #f0f2f5;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #111418; --card: #1a1e24; --text: #e8ebef; --muted: #98a2b0; --line: #2a3038;
    --accent: #3b82f6; --accent-text: #fff; --ok: #4ade80; --bad: #f87171; --warn: #fbbf24;
    --code: #0d1014;
  }
}
* { box-sizing: border-box; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 16px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  padding-bottom: env(safe-area-inset-bottom);
}
header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px; border-bottom: 1px solid var(--line); background: var(--card);
  position: sticky; top: 0; z-index: 1;
}
.brand { display: flex; align-items: center; gap: 8px; font-weight: 600; }
.dot { width: 10px; height: 10px; border-radius: 50%; background: var(--ok); }
main { max-width: 640px; margin: 0 auto; padding: 16px; }
h1 { font-size: 22px; margin: 8px 0 12px; }
h2 { font-size: 15px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin: 24px 0 8px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 16px; margin-bottom: 12px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
pre, code { font: 13px/1.4 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
pre { background: var(--code); border-radius: 10px; padding: 10px; overflow: auto; white-space: pre-wrap; word-break: break-word; max-height: 50vh; margin: 8px 0 0; }
button {
  font: inherit; font-weight: 600; border: 0; border-radius: 12px; padding: 14px 16px; width: 100%;
  background: var(--accent); color: var(--accent-text); cursor: pointer; margin-top: 8px;
}
button.secondary { background: transparent; color: var(--text); border: 1px solid var(--line); }
button.danger { background: transparent; color: var(--bad); border: 1px solid var(--bad); }
button.ghost { background: transparent; color: var(--muted); width: auto; padding: 6px 10px; margin: 0; }
button.small { font-size: 13px; padding: 8px 12px; width: auto; }
button:disabled { opacity: .5; }
input, textarea {
  font: inherit; width: 100%; padding: 12px; border-radius: 10px; border: 1px solid var(--line);
  background: var(--bg); color: var(--text); margin-top: 6px;
}
label { display: block; margin-top: 10px; font-size: 14px; color: var(--muted); }
.row { display: flex; gap: 8px; align-items: center; justify-content: space-between; }
.row > * { min-width: 0; }
.list-item { padding: 12px 0; border-top: 1px solid var(--line); }
.list-item:first-child { border-top: 0; padding-top: 0; }
.pill { display: inline-block; font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 99px; border: 1px solid currentColor; }
.pending { color: var(--warn); } .approved { color: var(--ok); } .denied, .expired { color: var(--bad); }
.big-icon { font-size: 44px; text-align: center; margin: 8px 0; }
.error { color: var(--bad); margin-top: 10px; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
a { color: var(--accent); }
