/* 杠杠电台 —— 与首页一致的金/白/浅黄主题 */

:root {
  color-scheme: light;
  --gold: #d4a017;
  --gold-deep: #a87c00;
  --gold-soft: #f5d76e;
  --cream: #fffdf6;
  --ink: #5c4a12;
  --ink-soft: #8a7648;
  --card-bg: rgba(255, 255, 255, 0.88);
  --line: rgba(212, 160, 23, 0.35);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
[hidden] { display: none !important; }

body {
  min-height: 100vh;
  padding: 84px 16px 28px;
  font-family: "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", system-ui, sans-serif;
  color: var(--ink);
  background: var(--cream) url("/assets/room-cover.jpg") center / cover no-repeat fixed;
}

.bg-veil {
  position: fixed;
  inset: 0;
  z-index: -1;
  background: linear-gradient(160deg, rgba(255, 253, 246, 0.93), rgba(255, 248, 224, 0.88));
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

a:focus-visible, button:focus-visible, input:focus-visible { outline: 3px solid #346bc2; outline-offset: 3px; }

.top-nav {
  position: fixed;
  top: max(14px, env(safe-area-inset-top));
  left: max(14px, env(safe-area-inset-left));
  right: max(14px, env(safe-area-inset-right));
  z-index: 10;
  display: flex;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
}
.top-nav a { pointer-events: auto; }
.nav-icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  color: var(--gold-deep);
  background: rgba(255, 253, 246, .95);
  border: 1px solid rgba(168, 124, 0, .3);
  border-radius: 15px;
  box-shadow: 0 4px 18px rgba(92, 74, 18, .15);
}
.nav-icon svg { width: 24px; height: 24px; }
.nav-pill {
  padding: 9px 20px;
  font-weight: 600;
  color: var(--gold-deep);
  text-decoration: none;
  background: rgba(255, 255, 255, .9);
  border: 1.5px solid var(--gold);
  border-radius: 999px;
  box-shadow: 0 4px 14px rgba(168, 124, 0, .18);
}
.nav-icon:hover, .nav-pill:hover { background: #fff2c4; }

.radio { display: grid; gap: 18px; width: 100%; max-width: 640px; margin: 0 auto; }

.card {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: 0 12px 40px rgba(168, 124, 0, 0.14);
  padding: 28px 32px;
}

.player-head { display: flex; align-items: center; gap: 14px; }
.avatar { width: 56px; height: 56px; border-radius: 50%; border: 2px solid var(--gold-soft); object-fit: cover; }
.eyebrow { color: var(--ink-soft); font-size: .8rem; letter-spacing: .12em; }
.player-head h1 { color: var(--gold-deep); font-size: 1.35rem; margin-top: 2px; }
.preview-badge {
  margin-left: auto;
  padding: 3px 10px;
  font-size: .75rem;
  color: #8a4b00;
  background: #fff2c4;
  border: 1px dashed var(--gold);
  border-radius: 999px;
  white-space: nowrap;
}

.now { margin: 24px 0 18px; min-height: 104px; overflow-wrap: anywhere; }
.now h2 { font-size: 1.65rem; line-height: 1.35; }
.now-artist { margin-top: 4px; color: var(--ink-soft); }
.now-meta { margin-top: 8px; font-size: .85rem; color: var(--ink-soft); line-height: 1.6; }
.now-source { font-size: .85rem; color: var(--gold-deep); text-underline-offset: 3px; }
.now-links { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; margin-top: 8px; }
.now-links:not(:has(> :not([hidden]))) { display: none; }
.now-share {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 0;
  font: inherit;
  font-size: .85rem;
  color: var(--gold-deep);
  background: none;
  border: 0;
  cursor: pointer;
}
.now-share svg { width: 15px; height: 15px; }
.now-share:hover span { text-decoration: underline; text-underline-offset: 3px; }
.now-share[hidden] { display: none; }

.progress { display: flex; align-items: center; gap: 10px; }
.time { min-width: 3.2em; font-size: .8rem; font-variant-numeric: tabular-nums; color: var(--ink-soft); text-align: center; }

input[type="range"] {
  flex: 1;
  min-width: 0;
  height: 28px;
  accent-color: var(--gold-deep);
  cursor: pointer;
  background: transparent;
}
input[type="range"]:disabled { cursor: default; opacity: .5; }

.controls { display: flex; justify-content: center; align-items: center; gap: 22px; margin: 16px 0 8px; }
.ctrl {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  color: var(--gold-deep);
  background: #fffdf6;
  border: 1px solid var(--gold);
  border-radius: 50%;
  cursor: pointer;
}
.ctrl svg { width: 22px; height: 22px; fill: currentColor; }
.ctrl:hover:not(:disabled) { background: #fff2c4; }
.ctrl:disabled { opacity: .45; cursor: default; }
.ctrl-main { width: 68px; height: 68px; color: #fff; background: var(--gold-deep); border-color: var(--gold-deep); }
.ctrl-main svg { width: 30px; height: 30px; }
.ctrl-main:hover:not(:disabled) { background: #806000; }
.ctrl-main .icon-pause, .ctrl-main.is-playing .icon-play { display: none; }
.ctrl-main.is-playing .icon-pause { display: block; }

.status { min-height: 1.6em; text-align: center; font-size: .85rem; color: var(--ink-soft); }
.status.is-error { color: #a33a00; }
.status-actions { display: flex; justify-content: center; gap: 10px; }
.status-actions:has(> :not([hidden])) { margin-top: 8px; }

.pill {
  min-height: 40px;
  padding: 8px 18px;
  font: inherit;
  font-size: .9rem;
  font-weight: 650;
  color: var(--gold-deep);
  background: #fffdf6;
  border: 1px solid var(--gold);
  border-radius: 999px;
  cursor: pointer;
}
.pill:hover { background: #fff2c4; }
.pill-solid { color: #fff; background: var(--gold-deep); border-color: var(--gold-deep); }
.pill-solid:hover { background: #806000; }

.volume { display: flex; align-items: center; gap: 8px; max-width: 260px; margin: 14px auto 0; }
.mute { display: grid; place-items: center; width: 36px; height: 36px; color: var(--gold-deep); background: none; border: 0; cursor: pointer; }
.mute svg { width: 22px; height: 22px; fill: currentColor; }
.mute.is-muted .wave { display: none; }

fieldset { border: 0; }
legend { margin-bottom: 10px; font-weight: 650; color: var(--gold-deep); }
legend small, .mode small { margin-left: 6px; font-weight: 400; font-size: .78rem; color: var(--ink-soft); }
.mode { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-bottom: 18px; }
.mode label { display: flex; align-items: center; gap: 6px; cursor: pointer; }
.mode input { accent-color: var(--gold-deep); width: 16px; height: 16px; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip input { position: absolute; opacity: 0; pointer-events: none; }
.chip span {
  display: inline-block;
  padding: 6px 14px;
  font-size: .88rem;
  color: var(--ink);
  background: #fffdf6;
  border: 1px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
  user-select: none;
}
.chip small { margin-left: 4px; color: var(--ink-soft); font-size: .75rem; }
.chip input:checked + span { color: #fff; background: var(--gold-deep); border-color: var(--gold-deep); }
.chip input:checked + span small { color: #fff2c4; }
.chip input:focus-visible + span { outline: 3px solid #346bc2; outline-offset: 2px; }

.empty { margin-top: 16px; padding: 14px; text-align: center; background: #fff8e0; border-radius: 14px; }
.empty p { margin-bottom: 10px; }

.lists { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.lists h3 { margin-bottom: 8px; font-size: 1rem; color: var(--gold-deep); }
.track-list { list-style: none; display: grid; gap: 4px; }
.track-list li { font-size: .86rem; line-height: 1.45; overflow-wrap: anywhere; }
.track-list button, .track-list .row {
  display: block;
  width: 100%;
  padding: 6px 8px;
  font: inherit;
  text-align: left;
  color: inherit;
  background: none;
  border: 0;
  border-radius: 10px;
}
.track-list button { cursor: pointer; }
.track-list button:hover { background: #fff2c4; }
.track-list small { display: block; color: var(--ink-soft); font-size: .75rem; }
.track-list .is-current { background: #fff2c4; }
.track-list .is-failed { opacity: .55; text-decoration: line-through; }
.track-list:empty::before { content: "—"; color: var(--ink-soft); padding: 6px 8px; }

.footer { margin-top: 24px; text-align: center; font-size: .78rem; color: var(--ink-soft); }

@media (max-width: 560px) {
  body { padding-top: 76px; }
  .card { padding: 22px 18px; }
  .nav-pill { padding: 7px 14px; font-size: .9rem; }
  .now h2 { font-size: 1.35rem; }
  .controls { gap: 16px; }
  .lists { grid-template-columns: 1fr; }
  .player-head h1 { font-size: 1.15rem; }
}
