/* Bilibili RC 公开站 — 干净白底 + 翠绿强调，对齐 biliboard 信息架构 */
@import url("https://fonts.googleapis.com/css2?family=Outfit:wght@500;600;700;800&family=Noto+Sans+SC:wght@400;500;700&display=swap");

:root {
  --bg: #f4f6f9;
  --surface: #ffffff;
  --ink: #14161c;
  --muted: #6b7285;
  --line: #e6e9f0;
  --accent: #10b981;
  --accent-ink: #047857;
  --accent-soft: #ecfdf5;
  --link: #2b6cff;
  --ok: #059669;
  --warn: #d97706;
  --bad: #dc2626;
  --shadow: 0 10px 40px rgba(20, 22, 28, 0.06);
  --radius: 16px;
  --font-display: "Outfit", "Noto Sans SC", sans-serif;
  --font-body: "Noto Sans SC", "Outfit", sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  color: var(--ink);
  background:
    radial-gradient(1200px 500px at 10% -10%, #d1fae5 0%, transparent 55%),
    radial-gradient(900px 420px at 100% 0%, #e8efff 0%, transparent 50%),
    var(--bg);
  min-height: 100vh;
  line-height: 1.55;
}

a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
img { display: block; max-width: 100%; }

.shell { width: min(1120px, calc(100% - 32px)); margin: 0 auto; }

/* ── Nav ── */
.topbar {
  position: sticky; top: 0; z-index: 40;
  backdrop-filter: blur(14px);
  background: rgba(244, 246, 249, 0.82);
  border-bottom: 1px solid rgba(230, 233, 240, 0.9);
}
.topbar-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px; gap: 16px;
}
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-display); font-weight: 800; font-size: 20px;
  letter-spacing: -0.02em;
}
.brand svg { width: 28px; height: 16px; color: var(--accent); }
.nav-links { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.nav-links a, .nav-links .nav-cta {
  padding: 8px 14px; border-radius: 999px; font-size: 13px; font-weight: 600;
  color: var(--muted); transition: background .15s, color .15s;
}
.nav-links a:hover { color: var(--ink); background: rgba(255,255,255,.7); }
.nav-links a.is-active { color: var(--accent-ink); background: var(--accent-soft); }
.nav-cta {
  background: var(--accent) !important; color: #fff !important;
  box-shadow: 0 6px 18px rgba(16, 185, 129, 0.28);
}
.nav-cta:hover { filter: brightness(1.04); }

/* ── Hero ── */
.hero {
  padding: 48px 0 28px;
  display: grid; gap: 18px;
}
.hero-kicker {
  display: inline-flex; width: fit-content;
  padding: 5px 11px; border-radius: 999px;
  background: var(--accent-soft); color: var(--accent-ink);
  font-size: 12px; font-weight: 700; letter-spacing: 0.04em;
}
.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(34px, 5vw, 52px);
  font-weight: 800; letter-spacing: -0.035em; line-height: 1.08;
  max-width: 14ch;
}
.hero p {
  max-width: 42ch; color: var(--muted); font-size: 15px;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 0; border-radius: 999px; padding: 12px 20px;
  font-weight: 700; font-size: 14px; cursor: pointer; transition: transform .12s, filter .12s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--accent); color: #fff; }
.btn-ghost {
  background: var(--surface); color: var(--ink);
  border: 1px solid var(--line); box-shadow: var(--shadow);
}

/* ── Panels ── */
.panel {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 18px; margin-bottom: 22px;
}
.panel-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; flex-wrap: wrap; margin-bottom: 14px;
}
.panel-head h2 {
  font-family: var(--font-display); font-size: 18px; font-weight: 700;
}
.muted { color: var(--muted); font-size: 13px; }

.toolbar {
  display: flex; gap: 10px; flex-wrap: wrap; align-items: center;
  margin-bottom: 14px;
}
.search, .select {
  height: 42px; border: 1px solid var(--line); border-radius: 12px;
  background: #fafbfd; padding: 0 14px; color: var(--ink); outline: none;
}
.search { flex: 1; min-width: 200px; }
.search:focus, .select:focus {
  border-color: #6ee7b7; background: #fff;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.16);
}

/* ── Songs table ── */
.table-wrap { overflow-x: auto; }
table.songs {
  width: 100%; border-collapse: collapse; font-size: 13px;
}
table.songs th {
  text-align: left; font-size: 11px; letter-spacing: 0.04em;
  text-transform: uppercase; color: var(--muted); font-weight: 700;
  padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap;
}
table.songs td {
  padding: 14px 12px; border-bottom: 1px solid #f0f2f6; vertical-align: middle;
}
table.songs tr:hover td { background: #fafbfd; }
.song-title { font-weight: 700; max-width: 360px; }
.song-title a:hover { color: var(--link); }
.up-link { color: var(--link); font-weight: 600; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px; }
.bv a { color: var(--ink); }
.bv a:hover { color: var(--link); }
.pill {
  display: inline-flex; align-items: center; padding: 2px 8px;
  border-radius: 999px; font-size: 11px; font-weight: 700;
  background: #eef2ff; color: #3b5bdb;
}

/* ── Ranking list ── */
.period-bar {
  display: flex; gap: 10px; flex-wrap: wrap; align-items: center;
  margin-bottom: 16px;
}
.rank-list { display: grid; gap: 12px; }
.rank-card {
  display: grid; grid-template-columns: 56px 112px 1fr auto;
  gap: 14px; align-items: center;
  padding: 12px; border: 1px solid var(--line); border-radius: 14px;
  background: linear-gradient(180deg, #fff, #fbfcfe);
  transition: transform .15s, box-shadow .15s;
}
.rank-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.rank-no {
  font-family: var(--font-display); font-weight: 800; font-size: 28px;
  text-align: center; color: var(--ink);
}
.rank-no.top1 { color: #e11d48; }
.rank-no.top2 { color: #ea580c; }
.rank-no.top3 { color: #ca8a04; }
.cover {
  width: 112px; height: 70px; border-radius: 10px; overflow: hidden;
  background: #e8ecf3; position: relative;
}
.cover img { width: 100%; height: 100%; object-fit: cover; }
.rank-meta h3 { font-size: 15px; font-weight: 700; margin-bottom: 4px; }
.rank-meta .sub { color: var(--muted); font-size: 12px; }
.stats {
  display: flex; flex-wrap: wrap; gap: 8px 12px; margin-top: 8px;
  font-size: 12px; color: var(--muted);
}
.score-box { text-align: right; min-width: 110px; }
.score-box .score {
  font-family: var(--font-display); font-weight: 800; font-size: 22px;
  color: var(--link); letter-spacing: -0.02em;
}
.score-box .hint { font-size: 11px; color: var(--muted); }
.tier {
  display: inline-block; margin-left: 8px; padding: 1px 7px;
  border-radius: 999px; font-size: 10px; font-weight: 700;
  background: var(--accent-soft); color: var(--accent-ink);
}
.tier.sub { background: #eef2ff; color: #3b5bdb; }

/* ── Submit ── */
.submit-grid {
  display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 18px;
}
@media (max-width: 860px) {
  .submit-grid { grid-template-columns: 1fr; }
  .rank-card { grid-template-columns: 44px 88px 1fr; }
  .score-box { grid-column: 2 / -1; text-align: left; }
  .hero h1 { max-width: none; }
}
.field { margin-bottom: 14px; }
.field label {
  display: block; font-size: 12px; font-weight: 700; color: var(--muted);
  margin-bottom: 6px;
}
.field input {
  width: 100%; height: 46px; border: 1px solid var(--line);
  border-radius: 12px; padding: 0 14px; background: #fafbfd; outline: none;
}
.field input:focus {
  border-color: #6ee7b7; background: #fff;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.16);
}
.msg {
  min-height: 22px; margin-top: 12px; font-size: 13px; font-weight: 600;
}
.msg.ok { color: var(--ok); }
.msg.err { color: var(--bad); }
.status-card {
  border: 1px dashed #d7dbe7; border-radius: 14px; padding: 16px;
  background: #fafbfd; margin-top: 8px;
}
.status-card .label { font-size: 12px; color: var(--muted); }
.status-card .value { font-size: 18px; font-weight: 800; margin-top: 4px; }
.status-card .value.pending { color: var(--warn); }
.status-card .value.approved { color: var(--ok); }
.status-card .value.rejected { color: var(--bad); }

.pager {
  display: flex; gap: 6px; flex-wrap: wrap; justify-content: center;
  margin-top: 16px;
}
.pager button {
  min-width: 36px; height: 36px; border-radius: 10px;
  border: 1px solid var(--line); background: #fff; cursor: pointer;
  font-weight: 600; color: var(--muted);
}
.pager button.is-active, .pager button:hover {
  color: var(--accent-ink); border-color: #a7f3d0; background: var(--accent-soft);
}
.pager button:disabled { opacity: 0.4; cursor: not-allowed; }

.empty, .loading {
  text-align: center; padding: 40px 16px; color: var(--muted); font-size: 14px;
}

.footer {
  padding: 28px 0 40px; text-align: center; color: var(--muted); font-size: 12px;
}
