:root {
  --bg: #0f1220; --card: #171a2b; --line: #2c3150; --text: #e8eaf2; --muted: #9aa1c0;
  --acc: #e64980; --acc-hi: #f783ac; --err: #ff8787;
  --s: #f76707; --d: #37b24d; --coop: #fab005; --ucs: #868e96;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text);
  font: 15px/1.55 system-ui, -apple-system, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif; }
a { color: var(--acc-hi); }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 18px;
  border-bottom: 1px solid var(--line); border-top: 3px solid var(--acc); }
.brand { font-weight: 800; color: var(--text); text-decoration: none; }
nav { display: flex; gap: 4px; }
nav a { color: var(--muted); text-decoration: none; padding: 5px 10px; border-radius: 8px; }
nav a.on { color: var(--text); background: var(--card); }
main { max-width: 1000px; margin: 0 auto; padding: 16px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; margin-bottom: 14px; }
h1 { margin: 2px 0; font-size: 22px; }
h2 { margin: 0 0 10px; font-size: 17px; }
h2 .muted { font-size: 13px; font-weight: 400; }
.muted { color: var(--muted); font-size: 13px; }
.err { color: var(--err); }
.summary { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.summary .big { text-align: right; }
.pb { font-size: 34px; font-weight: 800; color: var(--acc-hi); font-variant-numeric: tabular-nums; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; }
.stats > div { display: flex; flex-direction: column; }
.stats b { font-size: 20px; font-variant-numeric: tabular-nums; }
.stats small { font-size: 12px; }
.notice { background: rgba(230,73,128,.1); border: 1px solid var(--acc); border-radius: 10px; padding: 10px 14px; font-size: 14px; }
.scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; color: var(--muted); font-weight: 400; font-size: 12px; padding: 4px 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
td { padding: 6px 8px; border-bottom: 1px solid rgba(44,49,80,.5); white-space: nowrap; }
td.num { text-align: right; font-variant-numeric: tabular-nums; }
td.song { display: flex; align-items: center; gap: 8px; white-space: normal; min-width: 180px; }
td.judge { font-size: 12px; }
.jk { width: 34px; height: 34px; border-radius: 6px; object-fit: cover; flex: none; }
.chart { display: inline-block; min-width: 38px; text-align: center; padding: 1px 6px; border-radius: 999px; font-weight: 700; font-size: 12px; color: #fff; }
.chart-s { background: var(--s); } .chart-d { background: var(--d); } .chart-coop { background: var(--coop); color: #222; } .chart-ucs { background: var(--ucs); }
.plate { display: inline-block; padding: 0 6px; border-radius: 4px; font-size: 12px; font-weight: 700; background: #2c3150; }
.plate-pg { background: #fff3bf; color: #5c3c00; } .plate-ug { background: #d0bfff; color: #2b1a66; } .plate-eg { background: #a5d8ff; color: #0b3a60; }
.plate-sg { background: #b2f2bb; color: #0b4a1a; } .plate.none { background: none; color: var(--muted); font-weight: 400; }
.steps li { margin-bottom: 6px; }
.btn { display: inline-block; padding: 9px 16px; border-radius: 10px; background: var(--acc); color: #fff; border: 1px solid var(--acc);
  font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; }
.btn.ghost { background: none; color: var(--text); border-color: var(--line); font-weight: 400; }
.btn.danger { color: var(--err); }
code { background: #0f1220; padding: 1px 5px; border-radius: 4px; }
#toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: #232845; border: 1px solid var(--line);
  padding: 10px 16px; border-radius: 10px; max-width: calc(100% - 32px); box-shadow: 0 10px 30px rgba(0,0,0,.4); }
@media (max-width: 600px) { .summary .big { text-align: left; } main { padding: 10px; } }
