:root {
  --bg: #f6f5f2; --panel: #ffffff; --ink: #1d1f23; --quiet: #6b6f76; --line: #e3e1dc;
  --accent: #1f5f8b; --good: #2e7d4f; --warn: #b26b00; --bad: #b3261e; --chip: #eef1f4;
}
* { box-sizing: border-box; }
body { margin: 0; font: 14px/1.45 -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; background: var(--bg); color: var(--ink); }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
header.top { background: #15212c; color: #fff; display: flex; align-items: center; gap: 22px; padding: 0 20px; height: 52px; flex-wrap: wrap; }
header.top .brand { font-weight: 700; letter-spacing: .2px; color: #fff; }
header.top nav { display: flex; gap: 16px; flex-wrap: wrap; }
header.top nav a { color: #c9d6e2; }
header.top nav a.on { color: #fff; font-weight: 600; }
header.top .me { margin-left: auto; color: #9fb2c4; font-size: 13px; }
header.top .me a { color: #c9d6e2; margin-left: 10px; }
main { max-width: 1180px; margin: 0 auto; padding: 20px 16px 60px; }
h1 { font-size: 22px; margin: 4px 0 16px; }
h2 { font-size: 16px; margin: 24px 0 10px; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; }
.stat .n { font-size: 26px; font-weight: 700; }
.stat .l { color: var(--quiet); font-size: 12.5px; }
table { width: 100%; border-collapse: collapse; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
th, td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: #faf9f7; font-weight: 600; font-size: 12.5px; color: var(--quiet); }
tr:last-child td { border-bottom: 0; }
.wrap { overflow-x: auto; }
.chip { display: inline-block; padding: 1px 8px; border-radius: 999px; background: var(--chip); font-size: 12px; margin: 1px 2px 1px 0; white-space: nowrap; }
.chip.bad { background: #fbe9e7; color: var(--bad); }
.chip.warn { background: #fff3e0; color: var(--warn); }
.chip.good { background: #e8f5ec; color: var(--good); }
.quiet { color: var(--quiet); }
.small { font-size: 12.5px; }
form.inline { display: inline; }
input[type=text], input[type=email], select, textarea { font: inherit; padding: 7px 9px; border: 1px solid var(--line); border-radius: 7px; background: #fff; }
textarea { width: 100%; min-height: 80px; }
button, .btn { font: inherit; padding: 7px 13px; border-radius: 7px; border: 1px solid var(--accent); background: var(--accent); color: #fff; cursor: pointer; }
button.ghost { background: #fff; color: var(--accent); }
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; align-items: center; }
.filters a.on { font-weight: 700; }
.flash { background: #e8f5ec; border: 1px solid #b9dfc6; padding: 8px 12px; border-radius: 8px; margin-bottom: 12px; }
ol.alerts { padding-left: 22px; margin: 0; }
ol.alerts li { margin-bottom: 10px; }
.login { max-width: 380px; margin: 12vh auto; text-align: center; }
.login .btn { display: inline-block; padding: 10px 18px; margin-top: 10px; }
.err { color: var(--bad); margin-top: 12px; }
@media (max-width: 640px) { header.top { height: auto; padding: 10px 16px; } header.top .me { margin-left: 0; } }
