:root {
  --ink: #14110f;
  --ink-soft: #2a2420;
  --paper: #f3efe6;
  --paper-2: #e8e1d4;
  --lime: #c8f24a;
  --lime-deep: #9bc91f;
  --coral: #ff5a36;
  --sky: #6ec8ff;
  --muted: #7a7168;
  --line: rgba(20, 17, 15, 0.12);
  --glass: rgba(243, 239, 230, 0.72);
  --shadow: 0 18px 50px rgba(20, 17, 15, 0.14);
  --radius: 18px;
  --player-h: 92px;
  --font-display: "Syne", "Noto Sans SC", sans-serif;
  --font-poster: "Bebas Neue", "Syne", sans-serif;
  --font-body: "Noto Sans SC", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
/* 未登录：陌生人只能看到登录页 */
body.locked .topbar,
body.locked .layout,
body.locked .player-bar,
body.locked .mobile-dock,
body.locked .embed-layer,
body.locked .lyric-stage,
body.locked .match-sheet {
  visibility: hidden !important;
  pointer-events: none !important;
}
body.locked .auth-dialog {
  visibility: visible;
  pointer-events: auto;
}
body {
  margin: 0;
  color: var(--ink);
  font-family: var(--font-body);
  background:
    radial-gradient(1200px 700px at 10% -10%, rgba(200, 242, 74, 0.35), transparent 55%),
    radial-gradient(900px 600px at 95% 0%, rgba(110, 200, 255, 0.28), transparent 50%),
    radial-gradient(700px 500px at 70% 100%, rgba(255, 90, 54, 0.18), transparent 55%),
    linear-gradient(160deg, #f7f3ea 0%, #efe7d8 45%, #e7f0e2 100%);
  overflow-x: hidden;
  padding-bottom: calc(var(--player-h) + 16px);
}

button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }

.noise {
  pointer-events: none;
  position: fixed;
  inset: 0;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  z-index: 0;
}

.orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0.45;
  z-index: 0;
  animation: drift 14s ease-in-out infinite alternate;
}
.orb-a {
  width: 280px; height: 280px;
  left: -60px; top: 20%;
  background: var(--lime);
}
.orb-b {
  width: 220px; height: 220px;
  right: -40px; bottom: 18%;
  background: var(--sky);
  animation-delay: -4s;
}
@keyframes drift {
  from { transform: translateY(0) scale(1); }
  to { transform: translateY(-24px) scale(1.08); }
}

.topbar, .layout, .player-bar, .embed-layer { position: relative; z-index: 1; }

.topbar {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 20px;
  align-items: center;
  padding: 18px 28px 8px;
}

.brand { display: flex; align-items: center; gap: 12px; }
.brand-mark {
  width: 46px; height: 46px;
  display: grid; place-items: center;
  border-radius: 14px;
  background: var(--ink);
  color: var(--lime);
  font-family: var(--font-poster);
  font-size: 28px;
  letter-spacing: 1px;
  box-shadow: 0 10px 24px rgba(20, 17, 15, 0.25);
  animation: pulseMark 2.8s ease-in-out infinite;
}
@keyframes pulseMark {
  0%, 100% { transform: rotate(-4deg) scale(1); }
  50% { transform: rotate(2deg) scale(1.04); }
}
.brand-text strong {
  display: block;
  font-family: var(--font-display);
  font-size: 22px;
  letter-spacing: 0.08em;
  line-height: 1;
}
.brand-text small {
  color: var(--muted);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 11px;
}

.search-form { width: min(680px, 100%); justify-self: center; }
.search-box {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 6px 6px 16px;
  border-radius: 999px;
  background: rgba(255,255,255,0.72);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(20,17,15,0.1);
  box-shadow: 0 12px 36px rgba(20,17,15,0.08);
}
.search-icon {
  width: 18px;
  height: 18px;
  fill: var(--muted);
  flex-shrink: 0;
}
.search-box input {
  border: 0;
  outline: none;
  background: transparent;
  min-width: 0;
  flex: 1;
  padding: 10px 0;
  font-size: 15px;
}
.search-box input::placeholder { color: #9a9186; }
.search-tools {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}
.search-source {
  display: inline-flex;
  align-items: center;
  margin: 0;
}
.search-source select {
  appearance: none;
  border: 0;
  outline: none;
  background: rgba(20,17,15,0.06);
  border-radius: 999px;
  padding: 8px 28px 8px 12px;
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 600;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%237a7168' stroke-width='2.5'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  cursor: pointer;
}
.search-go {
  border: 0;
  border-radius: 999px;
  padding: 10px 18px;
  background: var(--ink);
  color: var(--lime);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.02em;
  transition: transform 0.15s ease, background 0.15s ease;
}
.search-go:hover { background: #000; transform: translateY(-1px); }
.search-go:active { transform: scale(0.97); }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  border: 0;
}

.btn-primary, .btn-ghost {
  border: 0;
  border-radius: 999px;
  padding: 10px 18px;
  transition: transform 0.18s ease, background 0.18s ease;
}
.btn-primary {
  background: var(--ink);
  color: var(--lime);
  font-weight: 700;
}
.btn-primary:hover { transform: translateY(-1px); background: #000; }
.btn-ghost {
  background: transparent;
  border: 1px solid var(--line);
}

.user-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--line);
  background: var(--glass);
  border-radius: 999px;
  padding: 6px 14px 6px 6px;
}
.avatar {
  width: 34px; height: 34px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: linear-gradient(135deg, var(--coral), #ffb347);
  color: white;
  font-weight: 700;
}

.layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 22px;
  padding: 12px 28px 24px;
  min-height: calc(100vh - 120px - var(--player-h));
}

.sidebar {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.nav {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px;
  border-radius: var(--radius);
  background: rgba(255,255,255,0.45);
  border: 1px solid var(--line);
}
.nav-item {
  text-align: left;
  border: 0;
  background: transparent;
  padding: 12px 14px;
  border-radius: 12px;
  font-weight: 600;
  color: var(--muted);
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}
.nav-item:hover { color: var(--ink); transform: translateX(2px); }
.nav-item.active {
  background: var(--ink);
  color: var(--lime);
}

.panel {
  padding: 16px;
  border-radius: var(--radius);
  background: rgba(255,255,255,0.5);
  border: 1px solid var(--line);
}
.panel-label {
  margin: 0 0 10px;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.voice-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 0;
  border-radius: 12px;
  padding: 12px 14px;
  background: var(--ink);
  color: var(--lime);
  font-weight: 700;
  transition: transform 0.15s ease, background 0.15s ease;
}
.voice-toggle:hover { transform: translateY(-1px); }
.voice-toggle.is-on {
  background: var(--lime);
  color: var(--ink);
}
.voice-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #666;
  flex-shrink: 0;
}
.voice-toggle.is-on .voice-dot {
  background: var(--coral);
  box-shadow: 0 0 0 0 rgba(255, 90, 54, 0.55);
  animation: voicePulse 1.4s ease-out infinite;
}
.voice-toggle.is-listening .voice-dot {
  background: #1f8f4e;
}
@keyframes voicePulse {
  0% { box-shadow: 0 0 0 0 rgba(255, 90, 54, 0.5); }
  70% { box-shadow: 0 0 0 10px rgba(255, 90, 54, 0); }
  100% { box-shadow: 0 0 0 0 rgba(255, 90, 54, 0); }
}
.voice-select-label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 10px;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}
.voice-select-label select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 8px 10px;
  background: rgba(255,255,255,0.7);
  outline: none;
}
.voice-preview {
  width: 100%;
  margin-top: 8px;
  padding: 8px 12px;
  font-size: 12px;
}
.voice-status {
  margin: 10px 0 0;
  font-size: 12px;
  line-height: 1.45;
  color: var(--ink-soft);
  min-height: 34px;
}
.voice-tips {
  margin: 10px 0 0;
  padding-left: 16px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.6;
}
.mini-cover {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 14px;
  background:
    linear-gradient(135deg, rgba(20,17,15,0.08), rgba(20,17,15,0.02)),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 80 80'%3E%3Ccircle cx='40' cy='40' r='28' fill='none' stroke='%2314110f' stroke-width='2' opacity='0.2'/%3E%3Ccircle cx='40' cy='40' r='6' fill='%2314110f' opacity='0.25'/%3E%3C/svg%3E") center/cover;
  margin-bottom: 12px;
  overflow: hidden;
}
.mini-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.now-playing-mini h3 { margin: 0 0 4px; font-size: 16px; line-height: 1.3; }
.now-playing-mini p:last-child { margin: 0; color: var(--muted); font-size: 13px; }

.content {
  border-radius: 28px;
  padding: 24px;
  background: rgba(255,255,255,0.42);
  border: 1px solid var(--line);
  backdrop-filter: blur(10px);
  min-height: 60vh;
}

.view-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.view-heading-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  min-width: 0;
}
.view-heading { min-width: 0; flex: 1; }
.home-wave {
  display: none;
  align-items: flex-end;
  gap: 3px;
  height: 48px;
  padding-bottom: 4px;
  flex-shrink: 0;
}
body.view-home .home-wave { display: flex; }
.home-wave i {
  display: block;
  width: 4px;
  border-radius: 99px;
  background: var(--lime);
  box-shadow: 0 0 10px rgba(200, 242, 74, 0.55);
  animation: wavePulse 1.2s ease-in-out infinite;
}
.home-wave i:nth-child(1) { height: 18%; animation-delay: 0s; }
.home-wave i:nth-child(2) { height: 42%; animation-delay: 0.08s; }
.home-wave i:nth-child(3) { height: 70%; animation-delay: 0.16s; }
.home-wave i:nth-child(4) { height: 100%; animation-delay: 0.24s; }
.home-wave i:nth-child(5) { height: 62%; animation-delay: 0.32s; }
.home-wave i:nth-child(6) { height: 88%; animation-delay: 0.4s; }
.home-wave i:nth-child(7) { height: 46%; animation-delay: 0.48s; }
.home-wave i:nth-child(8) { height: 74%; animation-delay: 0.56s; }
.home-wave i:nth-child(9) { height: 34%; animation-delay: 0.64s; }
.home-wave i:nth-child(10) { height: 58%; animation-delay: 0.72s; }
.home-wave i:nth-child(11) { height: 26%; animation-delay: 0.8s; }
.home-wave i:nth-child(12) { height: 40%; animation-delay: 0.88s; }
@keyframes wavePulse {
  0%, 100% { transform: scaleY(0.55); opacity: 0.7; }
  50% { transform: scaleY(1); opacity: 1; }
}

.view-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.7);
  border-radius: 999px;
  padding: 8px 14px;
  font-weight: 700;
  font-size: 13px;
  color: var(--ink);
}
.view-back.hidden { display: none !important; }
.view-back:active { transform: scale(0.98); }
.eyebrow {
  margin: 0 0 4px;
  color: var(--lime-deep);
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-size: 11px;
}
body.view-home .eyebrow { color: #8bbb14; }
#viewTitle {
  margin: 0;
  font-family: var(--font-body);
  font-weight: 800;
  font-size: clamp(24px, 3.4vw, 34px);
  letter-spacing: 0.01em;
  line-height: 1.15;
}
.view-desc {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
  max-width: 52ch;
}

/* 榜单首页：设计稿唱片卡 */
.track-grid.chart-home {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  border-top: 0;
  padding-top: 8px;
}
.track-grid.chart-home.is-fresh .chart-tile {
  animation: riseIn 0.35s ease both;
}
.chart-tile {
  appearance: none;
  border: 0;
  background: transparent;
  padding: 0;
  display: block;
  text-align: center;
  cursor: pointer;
  color: var(--ink);
  font: inherit;
  min-width: 0;
}
.chart-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 16px 12px 14px;
  border-radius: 24px;
  background: rgba(255,255,255,0.78);
  border: 1px solid rgba(255,255,255,0.7);
  box-shadow: 0 12px 28px rgba(20,17,15,0.07);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.chart-tile:hover .chart-card {
  transform: translateY(-3px);
  box-shadow: 0 16px 34px rgba(20,17,15,0.12);
}
.chart-tile:active .chart-card { transform: scale(0.98); }
.vinyl-disc {
  position: relative;
  width: min(100%, 118px);
  aspect-ratio: 1;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%,
      #111 0 30%,
      #1a1614 30% 31%,
      #0c0b0a 31% 100%);
  box-shadow:
    0 10px 22px rgba(20,17,15,0.28),
    0 0 0 1px rgba(255,255,255,0.06),
    0 0 28px color-mix(in srgb, var(--glow, #c8f24a) 35%, transparent);
  overflow: hidden;
  transition: transform 0.45s ease;
}
.vinyl-grooves {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  /* 疏一点的同心沟槽，看得见纹路 */
  background: repeating-radial-gradient(
    circle at 50% 50%,
    rgba(255,255,255,0.08) 0 1px,
    transparent 1px 3.8px
  );
  mask-image: radial-gradient(circle at 50% 50%, transparent 0 31%, #000 33% 78%, transparent 80%);
  pointer-events: none;
}
.vinyl-shine {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  /* 斜带居中穿过圆心，略加宽 */
  background: linear-gradient(
    128deg,
    transparent 0%,
    transparent 22%,
    rgba(255, 255, 255, 0.05) 34%,
    rgba(255, 255, 255, 0.18) 42%,
    rgba(255, 255, 255, 0.34) 50%,
    rgba(255, 255, 255, 0.18) 58%,
    rgba(255, 255, 255, 0.05) 66%,
    transparent 78%,
    transparent 100%
  );
  mask-image: radial-gradient(circle at 50% 50%, transparent 0 31%, #000 33% 80%, transparent 84%);
  pointer-events: none;
  z-index: 0;
}
.vinyl-label {
  position: absolute;
  inset: 29%;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 50% 50%, color-mix(in srgb, var(--glow, #c8f24a) 88%, white), var(--glow, #c8f24a));
  box-shadow:
    0 0 0 3px color-mix(in srgb, var(--glow, #c8f24a) 35%, transparent),
    0 0 22px color-mix(in srgb, var(--glow, #c8f24a) 55%, transparent),
    inset 0 0 10px rgba(255,255,255,0.35);
  z-index: 1;
}
.vinyl-icon {
  width: 48%;
  height: 48%;
  display: grid;
  place-items: center;
  color: rgba(20,17,15,0.88);
}
.vinyl-icon svg,
.vinyl-icon .lucide-ico {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
}
.lucide-ico { display: block; }

.view-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  width: 100%;
  justify-content: flex-end;
}
.view-actions.hidden { display: none !important; }
.btn-play-all,
.btn-playlist {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 0;
  border-radius: 999px;
  padding: 9px 14px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.btn-play-all {
  background: var(--ink);
  color: var(--lime);
}
.btn-playlist {
  background: rgba(20,17,15,0.06);
  color: var(--ink);
}
.btn-play-all img,
.btn-playlist img {
  filter: none;
}
.btn-play-all img {
  filter: invert(1) sepia(1) saturate(5) hue-rotate(30deg) brightness(1.2);
}
.vinyl-meta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-width: 0;
  width: 100%;
}
.vinyl-meta strong {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.2;
}
.vinyl-meta strong i {
  font-style: normal;
  color: color-mix(in srgb, var(--glow, #c8f24a) 70%, #7a7168);
  font-size: 11px;
  opacity: 0.85;
}
.vinyl-meta small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.3;
}
.chart-tile:hover .vinyl-disc { transform: rotate(10deg); }

.chart-tile.tone-qq { --glow: #c8f24a; }
.chart-tile.tone-soar { --glow: #b09cff; }
.chart-tile.tone-netease { --glow: #6ec8ff; }
.chart-tile.tone-soda { --glow: #ff7ab0; }
.chart-tile.tone-singer { --glow: #ffc857; }
.chart-tile.tone-radio { --glow: #9b8cff; }

@media (max-width: 1100px) {
  .track-grid.chart-home {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.mobile-dock { display: none; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.55);
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 13px;
}
.chip.active {
  background: var(--lime);
  border-color: transparent;
  font-weight: 700;
}

.status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 20px;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 13px;
}
.status-warn {
  color: #9a6b3f;
  font-size: 12px;
}

.track-grid {
  display: flex;
  flex-direction: column;
  gap: 2px;
  border-top: 1px solid var(--line);
  /* 给底部固定播放器留空，避免压住最后一条 */
  padding-bottom: calc(var(--player-h) + 36px);
}

.track-row {
  display: grid;
  grid-template-columns: 40px 52px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 10px 8px;
  border-bottom: 1px solid var(--line);
  border-radius: 12px;
  transition: background 0.15s ease;
}
.track-grid.is-fresh .track-row {
  animation: riseIn 0.35s ease both;
}
.track-row:hover { background: rgba(255,255,255,0.55); }
.track-row.is-active { background: rgba(200, 242, 74, 0.22); }
@keyframes riseIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.track-index {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  display: grid;
  place-items: center;
  min-height: 24px;
}
.track-index.is-eq { color: var(--lime-deep); }
.eq-bars {
  display: inline-flex;
  align-items: flex-end;
  gap: 2px;
  height: 14px;
}
.eq-bars i {
  display: block;
  width: 3px;
  height: 40%;
  border-radius: 1px;
  background: currentColor;
  animation: eqBounce 0.85s ease-in-out infinite;
}
.eq-bars i:nth-child(2) { animation-delay: 0.15s; height: 100%; }
.eq-bars i:nth-child(3) { animation-delay: 0.3s; height: 65%; }
@keyframes eqBounce {
  0%, 100% { transform: scaleY(0.45); }
  50% { transform: scaleY(1); }
}
.track-row.is-playing h3 { color: #5a7a00; }

.track-thumb {
  width: 52px;
  height: 52px;
  border-radius: 10px;
  overflow: hidden;
  background: var(--paper-2);
  flex-shrink: 0;
}
.track-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.track-main { min-width: 0; }
.track-main h3 {
  margin: 0 0 4px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.track-sub {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
}
.track-sub .artist {
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.track-sub .play-count {
  flex-shrink: 0;
  opacity: 0.85;
  font-variant-numeric: tabular-nums;
}
.badge {
  flex-shrink: 0;
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 11px;
  background: rgba(20,17,15,0.08);
  color: var(--ink-soft);
}
.badge.bilibili { background: rgba(110,200,255,0.28); }
.badge.itunes { background: rgba(255,90,54,0.18); }
.badge.deezer { background: rgba(64, 196, 168, 0.28); }
.badge.archive { background: rgba(200,242,74,0.35); }
.badge.chart { background: rgba(200,242,74,0.28); }
.badge.chart-qq,
.badge.chart-qq-soar,
.badge.chart-qq-singer { background: rgba(49, 194, 124, 0.28); }
.track-thumb.is-avatar {
  border-radius: 50%;
}

/* 歌手榜：头像网格，不用歌曲列表 */
.track-grid.singer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(112px, 1fr));
  gap: 18px 14px;
  border-top: 0;
  padding-top: 8px;
  padding-bottom: calc(var(--player-h) + 36px);
}
.track-grid.singer-grid.is-fresh .singer-tile {
  animation: riseIn 0.35s ease both;
}
.singer-tile {
  appearance: none;
  border: 0;
  background: transparent;
  color: inherit;
  padding: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  text-align: center;
  font: inherit;
}
.singer-tile:hover .singer-avatar {
  transform: scale(1.04);
  box-shadow: 0 10px 24px rgba(20, 17, 15, 0.16);
}
.singer-tile:hover .singer-name {
  color: var(--ink);
}
.singer-rank {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--muted);
}
.singer-avatar {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(20,17,15,0.08), rgba(20,17,15,0.02));
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.singer-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.singer-name {
  max-width: 100%;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--ink-soft);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.badge.chart-netease { background: rgba(236, 65, 65, 0.22); }
.badge.chart-soda { background: rgba(254, 44, 85, 0.22); }
.chips.hidden { display: none !important; }

.track-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  opacity: 0.55;
  transition: opacity 0.15s ease;
}
.track-row:hover .track-actions,
.track-row.is-active .track-actions { opacity: 1; }

.row-btn {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: rgba(20,17,15,0.06);
  color: var(--ink);
  transition: background 0.15s ease, transform 0.15s ease;
}
.row-btn:hover { background: rgba(20,17,15,0.12); transform: translateY(-1px); }
.row-btn.play { background: var(--ink); color: var(--lime); }
.row-btn.play:hover { background: #000; }
.row-btn.play.is-playing {
  background: var(--lime);
  color: var(--ink);
}
.row-btn.play.is-playing .eq-bars { color: var(--ink); }
.row-btn.play.is-loading { opacity: 0.75; }
.row-btn svg { width: 16px; height: 16px; fill: currentColor; }
.row-btn.fav svg.fav-icon {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
}
.row-btn.fav.is-on {
  color: var(--lime);
}
.row-btn.fav.is-on svg.fav-icon {
  fill: currentColor;
}
#favBtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
#favBtn .fav-icon {
  display: block;
  width: 18px;
  height: 18px;
}
#favBtn.is-on {
  color: var(--lime);
}
#favBtn.is-on .fav-icon {
  fill: currentColor;
}

.player-bar {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 12px;
  height: var(--player-h);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0;
  border-radius: 22px;
  background: linear-gradient(180deg, #1c1916 0%, #12100e 100%);
  color: #f6f1e8;
  box-shadow: 0 18px 50px rgba(20,17,15,0.38);
  border: 1px solid rgba(255,255,255,0.06);
  backdrop-filter: blur(18px);
  z-index: 20;
  overflow: hidden;
}
.player-seek {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 14px;
  display: flex;
  align-items: center;
  padding: 0 16px;
  z-index: 2;
}
.player-seek input[type="range"] {
  width: 100%;
  height: 14px;
  margin: 0;
  appearance: none;
  background: transparent;
  border: 0;
  outline: none;
  box-shadow: none;
  cursor: pointer;
  --seek-pct: 0%;
}
.player-seek input[type="range"]::-webkit-slider-runnable-track {
  height: 3px;
  border: 0;
  border-radius: 99px;
  background: linear-gradient(
    to right,
    var(--lime) 0%,
    var(--lime) var(--seek-pct, 0%),
    rgba(255, 255, 255, 0.16) var(--seek-pct, 0%),
    rgba(255, 255, 255, 0.16) 100%
  );
  box-shadow: none;
}
.player-seek input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 8px;
  height: 8px;
  margin-top: -2.5px;
  border: 0;
  border-radius: 50%;
  background: var(--lime);
  box-shadow: none;
}
.player-seek input[type="range"]::-moz-range-track {
  height: 3px;
  border: 0;
  border-radius: 99px;
  background: rgba(255,255,255,0.16);
}
.player-seek input[type="range"]::-moz-range-progress {
  height: 3px;
  border: 0;
  border-radius: 99px;
  background: var(--lime);
}
.player-seek input[type="range"]::-moz-range-thumb {
  width: 8px;
  height: 8px;
  border: 0;
  border-radius: 50%;
  background: var(--lime);
}
.player-body {
  display: grid;
  grid-template-columns: 1.05fr auto 1.25fr 1fr;
  gap: 10px;
  align-items: center;
  padding: 14px 16px;
  min-height: 100%;
  box-sizing: border-box;
}

.player-track { display: flex; align-items: center; gap: 12px; min-width: 0; }
.player-fav { justify-self: center; }
.player-cover {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background:
    linear-gradient(145deg, #2a2622, #181512);
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: 0 8px 18px rgba(0,0,0,0.35);
}
.player-cover img { width: 100%; height: 100%; object-fit: cover; }
.player-meta { min-width: 0; flex: 1; }
.player-meta strong, .player-meta span {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.player-meta strong { font-size: 14px; font-weight: 700; }
.player-meta span { color: rgba(246,241,232,0.58); font-size: 12px; margin-top: 3px; }
.player-fav { opacity: 0.9; }

.player-controls {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 12px;
  align-self: center;
  height: 52px; /* 与封面同高，整组垂直居中 */
  margin: 0;
}
.control-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}
.icon-btn, .play-btn {
  border: 0;
  background: transparent;
  color: inherit;
  width: 36px;
  height: 36px;
  border-radius: 50%;
}
.icon-btn:hover { background: rgba(255,255,255,0.06); }
#loopBtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  opacity: 0.9;
}
#loopBtn .loop-icon {
  width: 16px;
  height: 16px;
  display: block;
}
#loopBtn.is-one { color: var(--lime); }
#loopBtn.is-off { opacity: 0.4; }
.play-btn {
  width: 42px;
  height: 42px;
  background: var(--lime);
  color: var(--ink);
  font-size: 15px;
  font-weight: 800;
  box-shadow: 0 8px 20px rgba(200,242,74,0.28);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}
.play-btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
  display: block;
}
.play-btn:hover { filter: brightness(1.05); }
.player-time {
  min-width: 34px;
  line-height: 1;
  font-size: 11px;
  color: rgba(246,241,232,0.45);
  font-variant-numeric: tabular-nums;
  flex: 0 0 auto;
}
#curTime { text-align: right; }
#durTime { text-align: left; }
input[type="range"] {
  width: 100%;
  border: 0;
  outline: none;
  accent-color: var(--lime);
}

.player-extra {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: nowrap;
  min-width: 0;
}
.player-chip {
  border: 0;
  background: rgba(255,255,255,0.08);
  color: #f6f1e8;
  border-radius: 999px;
  padding: 6px 11px;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  line-height: 1;
  white-space: nowrap;
}
.player-chip:hover { background: rgba(255,255,255,0.14); }
.player-chip.ghost {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.14);
  color: rgba(246,241,232,0.75);
}
.source-tag {
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(200,242,74,0.14);
  color: var(--lime);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.volume {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: rgba(246,241,232,0.55);
  flex-shrink: 1;
  min-width: 0;
}
.volume input { width: 84px; }
.match-btn.hidden { display: none !important; }
/* 带图标的 chip：图标与文字垂直居中 */
.player-chip.match-btn,
.player-chip.lyric-open-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.player-chip.match-btn .lucide-ico {
  display: block;
  width: 14px;
  height: 14px;
  filter: invert(1);
  flex-shrink: 0;
}
.player-chip.lyric-open-btn .lyric-bars {
  display: block;
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.playlist-sheet {
  position: fixed;
  inset: 0;
  z-index: 46;
  background: rgba(20,17,15,0.45);
  display: grid;
  place-items: end center;
  padding: 16px 16px calc(var(--player-h) + 28px);
}
.playlist-sheet.hidden { display: none; }
.playlist-sheet-panel {
  width: min(560px, 100%);
  max-height: min(70vh, 560px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border-radius: 22px;
  background: rgba(246,241,232,0.96);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  color: var(--ink);
}

.play-page-stage {
  display: none;
  flex: 1;
  min-height: 0;
  position: relative;
}
.play-page .play-page-stage {
  display: flex;
  flex-direction: column;
}
.play-page-cover-wrap {
  appearance: none;
  border: 0;
  background: transparent;
  padding: 0;
  margin: 0;
  color: inherit;
  cursor: pointer;
  display: none;
  place-items: center;
}
.play-page-stage.is-cover .play-page-cover-wrap {
  display: grid;
  flex: 1;
  min-height: 0;
}
.cover-lyric {
  display: none;
  flex-shrink: 0;
  margin: 0 18px 6px;
  padding: 0 8px;
  text-align: center;
  font-size: clamp(15px, 4.2vw, 18px);
  font-weight: 600;
  line-height: 1.45;
  color: #fff;
  text-shadow: 0 0 24px rgba(200, 242, 74, 0.35);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-height: 1.45em;
  pointer-events: none;
}
.play-page-stage.is-cover .cover-lyric {
  display: block;
}
.cover-lyric:empty {
  visibility: hidden;
}
.play-page-stage.is-lyrics .lyric-scroll {
  display: block;
  flex: 1;
  position: relative;
  z-index: 3;
}
.play-page-stage.is-cover .lyric-scroll {
  display: none;
}
.play-page-stage.is-cover .spectrum-turntable {
  display: none;
}

/* 频谱圆心唱片：位置/尺寸由 JS 与频谱圆心同步（fixed）；低于歌词以免挡住当前行 */
.spectrum-turntable {
  position: fixed;
  left: 50%;
  top: 50%;
  width: 160px;
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  z-index: 1;
  pointer-events: none;
}
.spectrum-vinyl-disc {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%,
      #1a1614 0 28%,
      #0c0b0a 28% 100%);
  box-shadow: none;
  overflow: hidden;
}
.spectrum-turntable.is-playing .spectrum-vinyl-disc {
  animation: spectrum-vinyl-spin 8s linear infinite;
}
@keyframes spectrum-vinyl-spin {
  to { transform: rotate(360deg); }
}
.spectrum-vinyl-grooves {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: repeating-radial-gradient(
    circle at 50% 50%,
    rgba(255, 255, 255, 0.07) 0 1px,
    transparent 1px 3.6px
  );
  mask-image: radial-gradient(circle at 50% 50%, transparent 0 28%, #000 30% 78%, transparent 82%);
}
.spectrum-vinyl-shine {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: linear-gradient(
    128deg,
    transparent 0%,
    transparent 22%,
    rgba(255, 255, 255, 0.05) 34%,
    rgba(255, 255, 255, 0.22) 50%,
    rgba(255, 255, 255, 0.05) 66%,
    transparent 78%,
    transparent 100%
  );
  mask-image: radial-gradient(circle at 50% 50%, transparent 0 28%, #000 30% 80%, transparent 84%);
}
.spectrum-vinyl-label {
  position: absolute;
  inset: 29%;
  border-radius: 50%;
  overflow: hidden;
  background: rgba(40, 36, 32, 0.9);
  box-shadow:
    0 0 0 2px rgba(255, 255, 255, 0.08),
    inset 0 0 10px rgba(0, 0, 0, 0.35);
}
.spectrum-vinyl-label img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.spectrum-vinyl-label img:not([src]),
.spectrum-vinyl-label img[src=''] {
  opacity: 0;
}

@media (prefers-reduced-motion: reduce) {
  .spectrum-turntable.is-playing .spectrum-vinyl-disc {
    animation: none;
  }
}

.play-page-cover {
  width: min(68vw, 280px);
  aspect-ratio: 1;
  border-radius: 18px;
  overflow: hidden;
  background: rgba(255,255,255,0.08);
  box-shadow: 0 16px 40px rgba(0,0,0,0.32);
}
.play-page-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.play-page-dock {
  display: none;
}
.play-page .play-page-dock {
  display: flex;
  flex-direction: column;
  gap: 16px;
  flex-shrink: 0;
  margin: 0;
  padding: 14px 6px calc(22px + env(safe-area-inset-bottom, 0px));
  background: transparent;
  border: 0;
  border-radius: 0;
  backdrop-filter: none;
  box-shadow: none;
  pointer-events: auto;
  z-index: 2;
}
.play-page-dock-top {
  display: grid;
  grid-template-columns: 48px 1fr auto 48px;
  align-items: center;
  gap: 6px;
  min-height: 48px;
}
.play-page-dock-spacer {
  min-width: 0;
}
.play-page-icon-btn {
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  display: grid;
  place-items: center;
  cursor: pointer;
  padding: 0;
  color: #f6f1e8;
  font-size: 22px;
  line-height: 1;
}
.play-page-icon-btn:active { background: rgba(255,255,255,0.08); }
.play-page-icon-btn img {
  display: block;
  width: 24px;
  height: 24px;
  filter: invert(1);
  opacity: 0.92;
}
.play-page-dock-top .match-btn.hidden {
  display: none;
}
.play-page-fav {
  color: #f6f1e8;
}
.play-page-fav .play-page-fav-icon {
  display: block;
  width: 22px;
  height: 22px;
}
.play-page-dock-top .play-page-fav .play-page-fav-icon {
  width: 24px;
  height: 24px;
}
.play-page-fav.is-on {
  color: var(--lime);
}
.play-page-fav.is-on .play-page-fav-icon {
  fill: var(--lime);
}
.play-page-nav {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  margin: 2px 0 0;
  padding: 4px 0 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}
.play-page-nav-item {
  border: 0;
  background: transparent;
  color: rgba(246, 241, 232, 0.62);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  padding: 10px 4px 6px;
  cursor: pointer;
  border-radius: 10px;
}
.play-page-nav-item:active {
  color: #f6f1e8;
  background: transparent;
}
.play-page-nav-item:focus,
.play-page-nav-item:focus-visible {
  outline: none;
  color: rgba(246, 241, 232, 0.62);
  background: transparent;
}
.play-page-seek {
  display: grid;
  grid-template-columns: 44px 1fr 44px;
  gap: 12px;
  align-items: center;
  min-height: 36px;
  font-size: 13px;
  color: rgba(246,241,232,0.55);
  font-variant-numeric: tabular-nums;
}
.play-page-seek input[type="range"] {
  width: 100%;
  height: 28px;
  margin: 0;
  appearance: none;
  background: transparent;
  border: 0;
  outline: none;
  box-shadow: none;
  cursor: pointer;
  --seek-pct: 0%;
}
.play-page-seek input[type="range"]::-webkit-slider-runnable-track {
  height: 3px;
  border: 0;
  border-radius: 99px;
  background: linear-gradient(
    to right,
    var(--lime) 0%,
    var(--lime) var(--seek-pct, 0%),
    rgba(255, 255, 255, 0.22) var(--seek-pct, 0%),
    rgba(255, 255, 255, 0.22) 100%
  );
  box-shadow: none;
}
.play-page-seek input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 8px;
  height: 8px;
  margin-top: -2.5px;
  border: 0;
  border-radius: 50%;
  background: var(--lime);
  box-shadow: none;
}
.play-page-seek input[type="range"]::-moz-range-track {
  height: 3px;
  border: 0;
  border-radius: 99px;
  background: rgba(255,255,255,0.22);
}
.play-page-seek input[type="range"]::-moz-range-progress {
  height: 3px;
  border: 0;
  border-radius: 99px;
  background: var(--lime);
}
.play-page-seek input[type="range"]::-moz-range-thumb {
  width: 8px;
  height: 8px;
  border: 0;
  border-radius: 50%;
  background: var(--lime);
}
.play-page-toolbar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  flex-wrap: nowrap;
  min-height: 76px;
  padding: 4px 0 2px;
}
.play-page-btn {
  border: 0;
  background: transparent;
  color: #f6f1e8;
  border-radius: 999px;
  min-width: 52px;
  height: 52px;
  padding: 0 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-weight: 700;
  font-size: 18px;
  cursor: pointer;
}
.play-page-btn:active { background: rgba(255,255,255,0.08); }
.play-page-btn img { filter: invert(1); width: 22px; height: 22px; }
.play-page-loop .loop-icon {
  width: 22px;
  height: 22px;
  display: block;
}
.play-page-loop.is-one { color: var(--lime); }
.play-page-loop.is-off { opacity: 0.4; }
.play-page-play {
  width: 68px;
  height: 68px;
  min-width: 68px;
  background: var(--lime);
  color: var(--ink);
  font-size: 20px;
  box-shadow: 0 8px 22px rgba(200,242,74,0.32);
}
.play-page-play svg {
  width: 28px;
  height: 28px;
  fill: currentColor;
  display: block;
}

.match-sheet {
  position: fixed;
  inset: 0;
  z-index: 45;
  background: rgba(20,17,15,0.45);
  display: grid;
  place-items: end center;
  padding: 16px 16px calc(var(--player-h) + 28px);
}
.match-sheet.hidden { display: none; }
.match-sheet-panel {
  width: min(560px, 100%);
  max-height: min(70vh, 560px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border-radius: 22px;
  background: rgba(246,241,232,0.96);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  color: var(--ink);
}
.match-sheet-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  flex-wrap: nowrap;
  padding: 16px 18px 10px;
  border-bottom: 1px solid var(--line);
}
.match-sheet-head > div {
  min-width: 0;
  flex: 1;
}
.match-sheet-head h3 {
  margin: 0;
  font-size: 18px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.match-sheet-sub {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.match-sheet-head .btn-ghost {
  flex-shrink: 0;
  white-space: nowrap;
  align-self: flex-start;
}
.match-sheet-list {
  overflow-y: auto;
  padding: 8px;
}
.match-item {
  width: 100%;
  display: grid;
  grid-template-columns: 48px 1fr auto;
  gap: 10px;
  align-items: center;
  text-align: left;
  border: 0;
  background: transparent;
  border-radius: 14px;
  padding: 8px;
  color: inherit;
  cursor: pointer;
}
.match-item:hover { background: rgba(20,17,15,0.05); }
.match-item.is-active { background: rgba(200,242,74,0.28); }
.match-item-cover {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  overflow: hidden;
  background: rgba(20,17,15,0.08);
}
.match-item-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.match-item-main { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.match-item-main strong {
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.match-item-main small {
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.match-item-flag {
  font-size: 12px;
  color: var(--muted);
  flex-shrink: 0;
}
.match-item.is-active .match-item-flag { color: var(--ink); font-weight: 700; }
.match-empty {
  text-align: center;
  padding: 28px 12px;
  color: var(--muted);
}

/* —— 全屏歌词舞台 —— */
.lyric-stage {
  position: fixed;
  inset: 0;
  z-index: 30;
  overflow: hidden;
  /* 静态暗底，下滑时不跟着走，避免底部露白 */
  background: #0e1210;
  touch-action: pan-y;
}
.lyric-stage.hidden { display: none; }
.play-page-sheet {
  position: absolute;
  inset: 0;
  will-change: transform;
}
.lyric-stage.is-swiping .play-page-sheet {
  transition: none !important;
}
.lyric-stage.is-swipe-snap .play-page-sheet {
  transition: transform 0.28s ease, opacity 0.28s ease;
}
.play-page-backdrop {
  position: absolute;
  inset: -48px;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.45s ease;
}
.play-page-backdrop.is-on {
  opacity: 1;
}
.play-page-backdrop img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.28);
  filter: blur(52px) saturate(1.25);
  opacity: 0.58;
}
.play-page-backdrop::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(14, 18, 16, 0.28) 0%,
    rgba(14, 18, 16, 0.48) 45%,
    rgba(14, 18, 16, 0.68) 100%
  );
}
.lyric-stage canvas {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  display: block;
  pointer-events: none;
}
.lyric-stage-ui {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: 28px 28px 20px;
  color: #f6f1e8;
  pointer-events: none;
}
.lyric-stage.play-page .lyric-stage-ui {
  padding: max(28px, calc(env(safe-area-inset-top, 0px) + 20px)) 14px 0;
}
.play-page .lyric-stage-head,
.play-page-head {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-bottom: 10px;
  margin-top: 12px;
  gap: 0;
  padding: 0 48px;
}
.play-page-close {
  position: absolute;
  top: -6px;
  right: 0;
  z-index: 2;
}
.play-page .lyric-stage-actions { display: none; }
.play-page .lyric-stage-eyebrow {
  display: none;
}
.play-page .lyric-stage-head h2 {
  font-size: clamp(26px, 7.5vw, 36px);
  max-width: 92vw;
  line-height: 1.2;
}
.play-page .lyric-stage-head p:last-child,
.play-page #lyricStageArtist {
  margin-top: 8px;
  font-size: 15px;
}
.play-page .lyric-stage-status {
  margin: 8px 0 0;
  max-width: none;
  text-align: center;
  opacity: 0.65;
  font-size: 13px;
}
.lyric-stage-ui button,
.lyric-stage-ui .lyric-scroll,
.lyric-stage-ui .play-page-dock,
.lyric-stage-ui .play-page-stage,
.lyric-stage-ui .play-page-cover-wrap,
.lyric-stage-ui .play-page-nav {
  pointer-events: auto;
}
.lyric-stage-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 12px;
}
.lyric-stage-eyebrow {
  margin: 0 0 6px;
  letter-spacing: 0.16em;
  font-size: 12px;
  font-weight: 700;
  color: var(--lime);
  text-transform: uppercase;
}
.lyric-stage-head h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(28px, 4vw, 48px);
  line-height: 1.1;
  max-width: 70vw;
}
.lyric-stage-head p:last-child {
  margin: 8px 0 0;
  opacity: 0.72;
  font-size: 15px;
}
.lyric-stage-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}
.lyric-stage-status {
  font-size: 12px;
  opacity: 0.7;
  max-width: 240px;
  text-align: right;
}
.lyric-stage .btn-ghost {
  border: 1px solid rgba(246,241,232,0.35);
  background: rgba(20,17,15,0.35);
  color: #f6f1e8;
  border-radius: 999px;
  padding: 8px 16px;
  backdrop-filter: blur(8px);
}
.lyric-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  mask-image: linear-gradient(transparent, #000 10%, #000 90%, transparent);
  padding: 10vh 0 6vh;
  scroll-behavior: smooth;
  /* 不显示竖向滚动条，仍可用滚轮/自动跟随 */
  scrollbar-width: none;
  -ms-overflow-style: none;
  -webkit-tap-highlight-color: transparent;
}
.play-page .lyric-scroll {
  padding: 8vh 0 6vh;
}
/* 匹配中/空状态与频谱圆心同高（舞台垂直居中） */
.play-page-stage.is-lyrics .lyric-scroll:has(.lyric-empty) {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}
.lyric-scroll::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none;
}
.lyric-line {
  display: block;
  width: fit-content;
  max-width: min(78vw, 360px);
  margin: 0 auto;
  text-align: center;
  font-size: clamp(15px, 2.2vw, 24px);
  line-height: 1.65;
  padding: 6px 10px;
  color: rgba(246,241,232,0.22);
  transition: color 0.25s ease, transform 0.25s ease, opacity 0.25s ease;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  background: transparent;
  outline: none;
  user-select: none;
  -webkit-user-select: none;
}
.lyric-line:active,
.lyric-line:focus {
  background: transparent;
  outline: none;
}
.lyric-line.is-passed { color: rgba(246,241,232,0.3); }
.lyric-line.is-active {
  color: #fff;
  font-weight: 700;
  transform: scale(1.05);
  text-shadow:
    0 1px 10px rgba(0, 0, 0, 0.75),
    0 0 28px rgba(200, 242, 74, 0.45);
}
.lyric-empty {
  text-align: center;
  margin: 0;
  font-size: 20px;
  opacity: 0.7;
}
.play-page .lyric-empty {
  margin: 0;
  width: 100%;
}
.lyric-empty small { display: block; margin-top: 8px; font-size: 13px; opacity: 0.7; }
.lyric-plain {
  max-width: 720px;
  margin: 0 auto;
  white-space: pre-wrap;
  line-height: 1.9;
  font-size: 18px;
  opacity: 0.88;
  font-family: var(--font-body);
}
/* 播放页打开时锁住底层页面滚动，避免露出竖向滚动条 */
html.lyric-stage-open,
body.lyric-stage-open {
  overflow: hidden !important;
  overscroll-behavior: none;
  height: 100%;
}
body.lyric-stage-open .topbar,
body.lyric-stage-open .layout {
  visibility: hidden;
  pointer-events: none;
}
/* 播放页自带底栏控制，隐藏全局播放器与手机底栏 */
body.lyric-stage-open .player-bar,
body.lyric-stage-open .mobile-dock {
  display: none !important;
}

.embed-layer {
  position: fixed;
  inset: 0;
  background: rgba(20,17,15,0.55);
  display: grid;
  place-items: center;
  z-index: 40;
  padding: 24px;
}
.embed-layer.hidden { display: none; }
.embed-frame-wrap {
  width: min(960px, 100%);
  background: #111;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: var(--shadow);
}
.embed-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  background: #1b1b1b;
  color: #eee;
  font-size: 13px;
}
.embed-toolbar button {
  border: 0;
  border-radius: 999px;
  padding: 6px 12px;
  background: var(--lime);
  color: var(--ink);
  font-weight: 700;
}
.embed-frame-wrap iframe {
  width: 100%;
  height: min(62vh, 540px);
  border: 0;
  display: block;
  background: #000;
}

.auth-dialog {
  border: 0;
  border-radius: 24px;
  padding: 0;
  width: min(420px, calc(100vw - 32px));
  background: var(--paper);
  box-shadow: var(--shadow);
}
.auth-dialog::backdrop { background: rgba(20,17,15,0.45); backdrop-filter: blur(4px); }
.auth-dialog form { padding: 28px; display: flex; flex-direction: column; gap: 14px; }
.auth-dialog h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 28px;
}
.auth-dialog p { margin: 0; color: var(--muted); }
.auth-dialog label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
}
.auth-dialog input {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 14px;
  background: white;
  outline: none;
}
.dialog-actions { display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; }
.auth-tip { min-height: 18px; color: var(--coral); font-size: 13px; }

.empty {
  grid-column: 1 / -1;
  padding: 48px 20px;
  text-align: center;
  color: var(--muted);
}

/* —— 触控设备：操作按钮常显 —— */
@media (hover: none) {
  .track-actions { opacity: 1; }
  .track-row:hover { background: transparent; }
  .track-row:active { background: rgba(255,255,255,0.55); }
  .row-btn { width: 40px; height: 40px; }
}

/* —— 平板 / 手机：两级浏览（榜单 → 歌曲） —— */
@media (max-width: 960px) {
  :root {
    --player-h: 72px;
    --dock-h: 68px;
  }

  body {
    padding-bottom: calc(var(--player-h) + var(--dock-h) + 10px + env(safe-area-inset-bottom, 0px));
  }

  .topbar {
    grid-template-columns: 1fr auto;
    grid-template-areas: "brand user";
    gap: 10px;
    padding: 10px 14px 4px;
    padding-top: max(10px, env(safe-area-inset-top, 0px));
  }
  .brand { grid-area: brand; }
  .brand-mark { width: 38px; height: 38px; font-size: 22px; border-radius: 12px; }
  .brand-text strong { font-size: 18px; }
  .brand-text small { display: none; }
  .user-btn {
    grid-area: user;
    padding: 4px 10px 4px 6px;
    max-width: 42vw;
  }
  #userLabel {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 13px;
  }

  /* 默认收起搜索，点底栏「搜索」再展开 */
  .search-form {
    display: none;
    grid-area: unset;
    grid-column: 1 / -1;
    width: 100%;
  }
  body.search-open .topbar {
    grid-template-areas:
      "brand user"
      "search search";
  }
  body.search-open .search-form { display: block; margin-top: 4px; }
  .search-box {
    flex-wrap: nowrap;
    border-radius: 999px;
    padding: 5px 5px 5px 14px;
    gap: 8px;
    box-shadow: 0 12px 28px rgba(20,17,15,0.1);
  }
  .search-box input {
    flex: 1 1 auto;
    font-size: 16px;
    padding: 8px 0;
    min-width: 0;
  }
  .search-tools {
    flex: 0 0 auto;
    display: flex;
    gap: 5px;
  }
  .search-source select {
    width: auto;
    max-width: 78px;
    min-height: 38px;
    padding: 0 24px 0 10px;
    border-radius: 999px;
    font-size: 12px;
  }
  .search-go {
    min-height: 38px;
    min-width: 38px;
    padding: 0 14px;
    border-radius: 999px;
    font-size: 13px;
  }

  .layout {
    grid-template-columns: 1fr;
    gap: 0;
    padding: 0 12px;
    min-height: 0;
  }
  .sidebar { display: none; }

  .content {
    border-radius: 28px;
    padding: 18px 14px 10px;
    min-height: calc(100dvh - 120px - var(--player-h) - var(--dock-h));
    background: rgba(255,255,255,0.72);
    box-shadow: 0 18px 40px rgba(20,17,15,0.06);
  }
  body.view-home .content {
    background: rgba(255,255,255,0.78);
  }

  .view-header {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    margin-bottom: 10px;
  }
  body.view-detail .view-header {
    position: sticky;
    top: 0;
    z-index: 4;
    padding: 4px 0 8px;
    background: linear-gradient(180deg, rgba(255,255,255,0.94), rgba(255,255,255,0.82));
    backdrop-filter: blur(8px);
  }
  .view-back {
    align-self: flex-start;
    min-height: 36px;
    padding: 7px 12px;
  }
  .home-wave { height: 42px; gap: 2.5px; }
  .home-wave i { width: 3.5px; }
  #viewTitle { font-size: clamp(24px, 7vw, 30px); }
  .view-desc { font-size: 12px; max-width: none; }
  body.view-home .view-desc { margin-top: 4px; }
  body.view-home .status { display: none; }

  .track-grid.chart-home {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    padding-bottom: calc(var(--player-h) + var(--dock-h) + 20px);
  }
  .chart-card {
    padding: 14px 10px 12px;
    border-radius: 22px;
    gap: 10px;
  }
  .vinyl-disc { width: min(100%, 104px); }
  .vinyl-meta strong { font-size: 13px; gap: 4px; }
  .vinyl-meta small { font-size: 11px; }

  .track-grid,
  .track-grid.singer-grid {
    padding-bottom: calc(var(--player-h) + var(--dock-h) + 20px + env(safe-area-inset-bottom, 0px));
  }
  .track-grid.singer-grid {
    grid-template-columns: repeat(auto-fill, minmax(84px, 1fr));
    gap: 12px 8px;
  }
  .singer-avatar { width: 68px; height: 68px; }

  .track-row {
    grid-template-columns: 24px 42px minmax(0, 1fr) auto;
    gap: 8px;
    padding: 9px 2px;
  }
  .track-thumb { width: 42px; height: 42px; border-radius: 9px; }
  .track-main h3 { font-size: 13.5px; }
  .track-sub { gap: 6px; font-size: 11px; }
  .track-sub .play-count { display: none; }

  .mobile-dock {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 25;
    box-sizing: border-box;
    height: calc(var(--dock-h) + env(safe-area-inset-bottom, 0px));
    padding: 6px 10px env(safe-area-inset-bottom, 0px);
    background: rgba(255, 255, 255, 0.92);
    border-top: 1px solid rgba(20,17,15,0.06);
    backdrop-filter: blur(16px);
    align-items: center;
  }
  .dock-item {
    border: 0;
    background: transparent;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.2;
    color: #9a9186;
    border-radius: 14px;
    padding: 4px 0;
    min-height: 0;
    overflow: visible;
  }
  .dock-item .dock-ico {
    display: grid;
    place-items: center;
    width: 24px;
    height: 24px;
    flex-shrink: 0;
  }
  .dock-item .dock-ico svg { display: block; }
  .dock-item.is-active {
    color: var(--ink);
    background: rgba(200, 242, 74, 0.45);
  }

  .player-bar {
    left: 12px;
    right: 12px;
    bottom: calc(var(--dock-h) + 8px + env(safe-area-inset-bottom, 0px));
    height: auto;
    min-height: 0;
    border-radius: 22px;
    border: 0;
    box-shadow: 0 14px 36px rgba(20,17,15,0.35);
  }
  .player-seek { display: none; }
  .player-body {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    grid-template-columns: none;
    grid-template-areas: none;
  }
  .player-track {
    flex: 1;
    min-width: 0;
    gap: 10px;
  }
  .player-track .player-fav { display: none; }
  .player-cover { width: 44px; height: 44px; border-radius: 10px; }
  .player-controls {
    flex-direction: row;
    gap: 0;
    height: auto;
    flex-shrink: 0;
  }
  .player-controls .player-time { display: none; }
  .control-row { gap: 0; }
  .control-row #loopBtn { display: none; }
  .play-btn {
    width: 40px;
    height: 40px;
    box-shadow: 0 6px 14px rgba(200,242,74,0.35);
  }
  .icon-btn { width: 34px; height: 34px; }
  .player-extra {
    flex-shrink: 0;
    gap: 0;
    margin-left: 2px;
  }
  .volume,
  .source-tag,
  .player-extra #openLink { display: none !important; }
  .player-extra .match-btn {
    width: 34px;
    height: 34px;
    padding: 0;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: transparent;
  }
  /* 首页底栏不显示换源 */
  body.view-home .player-extra .match-btn {
    display: none !important;
  }
  .player-extra .match-btn span { display: none; }
  .player-extra .match-btn img {
    margin: 0;
    width: 16px;
    height: 16px;
  }
  .player-chip.lyric-open-btn {
    width: 34px;
    height: 34px;
    padding: 0;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: transparent;
  }
  .player-chip.lyric-open-btn span { display: none; }
  .player-chip.lyric-open-btn .lyric-bars { display: block; color: rgba(246,241,232,0.85); }

  .view-actions { margin-top: 2px; }
  .btn-play-all,
  .btn-playlist { min-height: 38px; font-size: 12px; padding: 8px 12px; }

  .play-page-cover { width: min(72vw, 260px); }
  .play-page-btn span { display: none; }
  .play-page .lyric-scroll { padding: 5vh 0 3vh; }
  .playlist-sheet {
    padding: 0;
    place-items: end stretch;
  }
  .playlist-sheet-panel {
    width: 100%;
    max-height: min(72vh, 560px);
    border-radius: 22px 22px 0 0;
    padding-bottom: calc(var(--dock-h) + env(safe-area-inset-bottom, 0px));
  }

  .player-body .player-fav {
    display: grid;
    width: 34px;
    height: 34px;
    flex-shrink: 0;
  }

  .match-sheet {
    padding: 0;
    place-items: end stretch;
  }
  .match-sheet-panel {
    width: 100%;
    max-height: min(72vh, 560px);
    border-radius: 22px 22px 0 0;
    padding-bottom: calc(var(--dock-h) + env(safe-area-inset-bottom, 0px));
  }

  .lyric-stage-ui {
    padding: max(14px, env(safe-area-inset-top, 0px)) 14px 0;
  }
  .lyric-stage.play-page .lyric-stage-ui {
    padding: max(32px, calc(env(safe-area-inset-top, 0px) + 24px)) 14px 0;
  }
  .lyric-stage-head { flex-direction: column; gap: 10px; }
  .play-page .lyric-stage-head { gap: 0; margin-top: 16px; }
  .lyric-stage-head h2 { max-width: 100%; font-size: clamp(22px, 7vw, 34px); }
  .play-page .lyric-stage-head h2 { font-size: clamp(26px, 7vw, 34px); }
  .lyric-stage-actions {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    width: 100%;
  }
  .lyric-stage-status { text-align: left; max-width: none; }
  .play-page .lyric-stage-status { text-align: center; }
  .play-page #lyricStageArtist { font-size: 15px; }
  .lyric-line { font-size: clamp(14px, 3.8vw, 18px); padding: 7px 10px; }
  .lyric-scroll { padding: 10vh 0; }

  .embed-layer {
    padding: 10px;
    padding-bottom: calc(var(--player-h) + var(--dock-h) + 12px);
  }
  .embed-frame-wrap iframe { height: min(42vh, 320px); }

  .auth-dialog {
    width: calc(100vw - 24px);
    max-height: calc(100dvh - 24px);
    overflow-y: auto;
    border-radius: 20px;
  }
  .auth-dialog form { padding: 22px 18px; gap: 12px; }
  .auth-dialog h2 { font-size: 24px; }
  .auth-dialog input { font-size: 16px; min-height: 46px; }
  .dialog-actions .btn-primary { width: 100%; min-height: 46px; }
}

@media (max-width: 640px) {
  .orb-a, .orb-b { opacity: 0.22; filter: blur(26px); }
  .orb-a { width: 160px; height: 160px; }
  .orb-b { width: 120px; height: 120px; }

  .status { font-size: 12px; }
  .track-row {
    grid-template-columns: 20px 40px minmax(0, 1fr) auto;
    gap: 6px;
  }
  .track-index { font-size: 11px; }
  .track-thumb { width: 40px; height: 40px; }
  .badge { padding: 2px 6px; font-size: 10px; }
  .row-btn { width: 38px; height: 38px; border-radius: 10px; }
  .player-meta strong { font-size: 13px; }
  .player-meta span { font-size: 11px; }
  .vinyl-disc { width: min(100%, 96px); }
}

@media (max-width: 380px) {
  .track-sub .badge { display: none; }
  .vinyl-meta strong { font-size: 12px; }
  .control-row #prevBtn,
  .control-row #nextBtn { width: 30px; }
}
