:root {
  --bg: #0e0d12; --panel: #18161f; --line: #2a2733; --text: #f1eef7; --muted: #9a94a8;
  --accent: #ff4fa3; --accent-2: #7c5cff; --ok: #3ad29f; --warn: #ffb547; --bad: #ff5a5a;
  color-scheme: dark;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text); font: 15px/1.45 system-ui, -apple-system, "Segoe UI", sans-serif; }
a { color: var(--accent); }
header { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
header h1 { margin: 0; font-size: 18px; letter-spacing: .02em; }
header h1 span { color: var(--accent); }
header nav a { margin-left: 14px; color: var(--muted); text-decoration: none; }
header nav a.active { color: var(--text); }
main { max-width: 960px; margin: 0 auto; padding: 16px; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 16px; margin-bottom: 16px; }
.panel h2 { margin: 0 0 12px; font-size: 15px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .06em; }
label { display: block; font-size: 13px; color: var(--muted); margin: 10px 0 4px; }
select, input, textarea { width: 100%; padding: 10px 12px; border-radius: 8px; border: 1px solid var(--line); background: #0f0e14; color: var(--text); font: inherit; }
textarea { min-height: 160px; font-family: ui-monospace, Menlo, monospace; font-size: 13px; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 560px) { .row { grid-template-columns: 1fr; } }
button { padding: 11px 16px; border-radius: 8px; border: 1px solid var(--line); background: #24212d; color: var(--text); font: inherit; font-weight: 600; cursor: pointer; }
button.primary { background: linear-gradient(135deg, var(--accent), var(--accent-2)); border: none; }
button.danger { background: #3a1b22; border-color: #5a2630; color: #ffb3bd; }
button:disabled { opacity: .5; cursor: default; }
button.big { width: 100%; padding: 16px; font-size: 17px; margin-top: 16px; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.hidden { display: none !important; }
.now { text-align: center; padding: 20px 8px; }
.now .title { font-size: 22px; font-weight: 700; }
.now .artist { color: var(--muted); margin-top: 4px; }
.pulse { width: 14px; height: 14px; border-radius: 50%; background: var(--bad); display: inline-block; margin-right: 8px; animation: pulse 1.4s infinite; vertical-align: middle; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(255,90,90,.6); } 100% { box-shadow: 0 0 0 14px rgba(255,90,90,0); } }
.meter { height: 8px; background: #0f0e14; border-radius: 4px; overflow: hidden; margin-top: 12px; }
.meter div { height: 100%; width: 0; background: linear-gradient(90deg, var(--ok), var(--warn), var(--bad)); transition: width .1s; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 10px; }
.stat { background: #0f0e14; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.stat .v { font-size: 22px; font-weight: 700; }
.stat .k { font-size: 12px; color: var(--muted); }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: 12px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
.scroll { overflow-x: auto; }
.list { list-style: none; margin: 0; padding: 0; }
.list li { padding: 8px 0; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; gap: 10px; }
.tag { font-size: 11px; padding: 2px 7px; border-radius: 99px; border: 1px solid var(--line); color: var(--muted); white-space: nowrap; }
.tag.matched { color: var(--ok); border-color: #1f5a47; }
.tag.no_match { color: var(--warn); border-color: #5a4320; }
.tag.error { color: var(--bad); border-color: #5a2630; }
.mv-up { color: var(--ok); } .mv-down { color: var(--bad); } .mv-new { color: var(--accent); }
.tabs { display: flex; gap: 8px; margin-bottom: 16px; flex-wrap: wrap; }
.tabs button.active { border-color: var(--accent); }
.controls { display: flex; gap: 10px; flex-wrap: wrap; align-items: end; margin-bottom: 12px; }
.controls > div { min-width: 140px; }
tr.click { cursor: pointer; }
tr.click:hover td { background: #1f1c27; }
.banner { padding: 10px 12px; border-radius: 8px; background: #2b2410; border: 1px solid #5a4320; color: #ffd591; margin-bottom: 16px; font-size: 13px; }
