/* ============================================================
   月色の小窝 — design system
   Visual language adapted from komichi-vup.com (fan site),
   re-themed for VTuber 月色_Moon (moonlight silver-violet).
   ============================================================ */

:root {
  --brand: #a9bdf5;
  --brand-deep: #6678c8;
  --brand-glow: rgba(169, 189, 245, 0.65);
  --brand-rgb: 169, 189, 245;   /* 主题色的 r,g,b, 用于 rgba(var(--brand-rgb), a) 这类半透明色; 随壁纸切换 */
  --bg: #07070f;
  --bg-soft: #0d0d1a;
  --ink: #f2f3fa;
  --ink-dim: rgba(242, 243, 250, 0.62);
  --ink-faint: rgba(242, 243, 250, 0.5);
  --line: rgba(242, 243, 250, 0.16);
  --line-strong: rgba(242, 243, 250, 0.32);
  --selection-bg: #cdd6f7;
  --selection-fg: #1b1e33;
  --font-sans: Inter, "SF Pro Display", "PingFang SC", "Noto Sans CJK SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-display: "Noto Serif SC", Georgia, "Songti SC", "STSong", "SimSun", serif;
  --h1-size: clamp(2.2rem, 7vw, 4.8rem);
  --radius-pill: 999px;
  /* 动效令牌: 全站统一缓动与时长 */
  --ease-out: cubic-bezier(0.22, 0.9, 0.32, 1);
  --ease-in-out: cubic-bezier(0.45, 0, 0.15, 1);
  --ease-soft: cubic-bezier(0.4, 0, 0.2, 1);   /* 匀速偏柔, 用于壁纸淡入 */
  --dur-1: 0.14s;
  --dur-2: 0.24s;
  --dur-3: 0.38s;
  --dur-4: 0.6s;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { -webkit-text-size-adjust: 100%; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  min-height: 100svh;
}

::selection { background: var(--selection-bg); color: var(--selection-fg); }

a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
img { display: block; }

/* ---------- animations ---------- */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes twinkle {
  from { opacity: 0.15; transform: scale(0.7); }
  to   { opacity: 0.9;  transform: scale(1); }
}
@keyframes trafficFloat {
  from { transform: translate(-50%, -50%) translateY(-4px); }
  to   { transform: translate(-50%, -50%) translateY(4px); }
}
.fade-up { animation: fadeUp 0.7s cubic-bezier(0.22, 0.9, 0.32, 1) both; }
.d1 { animation-delay: 120ms; }
.d2 { animation-delay: 240ms; }
.d3 { animation-delay: 380ms; }
.d4 { animation-delay: 480ms; }

/* ---------- loading overlay ---------- */
.loading-overlay {
  position: fixed; inset: 0; z-index: 9999;
  display: grid; place-items: center;
  background: radial-gradient(ellipse at 50% 40%, #191a2e, #101020 55%, #08080f);
  opacity: 1; transition: opacity 0.55s ease;
}
.loading-overlay.hidden { opacity: 0; pointer-events: none; }
.loading-overlay .stars { position: absolute; inset: 0; overflow: hidden; }
.loading-overlay .stars i {
  position: absolute; width: 3px; height: 3px; border-radius: 50%;
  background: #fff; opacity: 0.8;
  animation: twinkle 1.6s ease-in-out infinite alternate;
}
.loading-overlay .stars i:nth-child(1) { left: 12%; top: 22%; }
.loading-overlay .stars i:nth-child(2) { left: 26%; top: 64%; animation-delay: 0.3s; }
.loading-overlay .stars i:nth-child(3) { left: 38%; top: 16%; animation-delay: 0.6s; }
.loading-overlay .stars i:nth-child(4) { left: 58%; top: 70%; animation-delay: 0.2s; }
.loading-overlay .stars i:nth-child(5) { left: 72%; top: 28%; animation-delay: 0.8s; }
.loading-overlay .stars i:nth-child(6) { left: 86%; top: 56%; animation-delay: 0.5s; }
.loading-overlay .stars i:nth-child(7) { left: 48%; top: 84%; animation-delay: 1s; }
.loading-overlay .stars i:nth-child(8) { left: 8%;  top: 78%; animation-delay: 0.7s; }
.loading-overlay .stars i:nth-child(9) { left: 92%; top: 14%; animation-delay: 0.4s; }
.loading-overlay .orbit {
  position: relative; width: 170px; height: 170px;
  display: grid; place-items: center;
}
/* 加载页吉祥物: 静态图 + CSS 浮动(动图要 250KB+, 太重) */

.loading-overlay .mascot {
  position: absolute; top: 50%; left: 50%;
  width: 132px; height: auto;
  transform: translate(-50%, -50%);
  filter: drop-shadow(0 6px 10px rgba(0, 0, 0, 0.45));
  animation: trafficFloat 2.6s ease-in-out infinite alternate;
  transition: opacity 0.3s var(--ease-soft);
  pointer-events: none;
}
/* 第一帧(内联 base64): HTML 一到就显示, 不依赖网络 */
.loading-overlay .mascot-first { opacity: 1; }
/* 动图: 下载/解码完成后交叉淡入, 同时让第一帧淡出 */
.loading-overlay .mascot-anim { opacity: 0; }
.loading-overlay .mascot-anim.on { opacity: 1; }
.loading-overlay .orbit.anim-ready .mascot-first { opacity: 0; }
@media (max-width: 639px) {
  .loading-overlay .mascot { width: 112px; }
}

.loading-overlay .text {
  position: absolute; bottom: calc(50% - 120px);
  font-size: 11px; letter-spacing: 0.5em; text-indent: 0.5em;
  color: var(--ink-dim); text-transform: uppercase;
}

/* ---------- top progress bar ---------- */
.progress-bar {
  pointer-events: none; position: fixed; inset-inline: 0; top: 0;
  z-index: 100; height: 2px; overflow: hidden;
}
.progress-bar > i {
  display: block; height: 100%; width: 100%;
  background: var(--brand);
  box-shadow: 0 0 10px var(--brand-glow);
  transform-origin: left;
  transform: scaleX(0);
  transition: transform 0.4s ease, opacity 0.4s ease;
}

/* ---------- nav ---------- */
.nav {
  position: fixed; inset-inline: 0; top: 0; z-index: 30;
  display: flex; align-items: center; gap: 8px;
  padding: calc(env(safe-area-inset-top, 0px) + 10px) 12px 0;
  pointer-events: none;
}
.nav > * { pointer-events: auto; }
.nav .crumbs {
  min-width: 0; flex: 1 1 0;
  display: flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 500; letter-spacing: 0.12em;
  color: var(--ink-dim);
}
.nav .crumbs a:hover { color: var(--brand); }
.nav .crumbs .sep { color: var(--ink-faint); }
.nav .crumbs .here {
  max-width: 10em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: var(--ink);
}
.nav .pill-group {
  display: flex; align-items: center; gap: 2px;
  border: 1px solid var(--line); border-radius: var(--radius-pill);
  background: rgba(10, 10, 22, 0.55);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  padding: 2px;
}
.nav .pill-group a {
  border-radius: var(--radius-pill);
  padding: 7px 9px;
  font-size: 10px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--ink-dim);
  transition: color 0.25s, background 0.25s;
  white-space: nowrap;
}
.nav .pill-group a:hover { color: var(--ink); background: rgba(255,255,255,0.08); }
.nav .pill-group a.active { color: #141630; background: var(--brand); }
.nav .ext-btn {
  display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--line-strong); border-radius: var(--radius-pill);
  padding: 8px; font-size: 12px; font-weight: 500;
  color: var(--ink-dim);
  background: rgba(10, 10, 22, 0.55);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  transition: color 0.25s, border-color 0.25s;
}
.nav .ext-btn:hover { color: var(--ink); border-color: var(--brand); }
.nav .ext-btn svg { width: 14px; height: 14px; }
.nav .ext-btn span { display: none; }
@media (max-width: 639px) {
  .nav .crumbs { display: none; }
  .nav { justify-content: flex-end; }
}
@media (min-width: 640px) {
  .nav .ext-btn { padding: 8px 14px; }
  .nav .ext-btn span { display: inline; }
  .nav .pill-group a { padding: 7px 12px; font-size: 11px; }
}

/* ---------- hero (home) ---------- */
.hero {
  position: relative; display: flex; flex-direction: column;
  min-height: 100svh; width: 100%; overflow: hidden;
  padding-top: calc(env(safe-area-inset-top, 0px) + 64px);
}
.hero .bg {
  position: absolute; inset: 0; z-index: -3;
  background-image: var(--hero-img, url("../wallpaper/pc-01.webp"));
  background-position: var(--hero-pos, center 22%);
  background-size: cover;
  background-repeat: no-repeat;
  animation: fadeIn 1.2s ease both;
  filter: saturate(0.9);
  transition: opacity 0.5s ease;
}
@media (max-width: 639px) {
  /* 窄屏与宽屏同一套: 整屏清晰壁纸 + 底部渐变压暗放文字。
     壁纸按高度放大到 140%, 这样有纵向取景余地, 能把人物脸放在文字上方 */
  .hero .bg {
    background-size: var(--hero-size-m, cover);   /* 兜底: 铺满; JS 按图片尺寸精算(见 applyHeroMobile) */
    background-position: var(--hero-pos-m2, center 30%);
    background-repeat: no-repeat;
  }
}
.hero .bg.switching { opacity: 0; }

.hero .bg-overlay {
  position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(to left, rgba(7, 7, 15, 0.88) 0%, rgba(7, 7, 15, 0.45) 38%, rgba(7, 7, 15, 0.15) 62%),
    radial-gradient(ellipse at center, transparent 30%, rgba(7, 7, 15, 0.55) 78%),
    linear-gradient(to top, var(--bg) 4%, rgba(7, 7, 15, 0.72) 34%, rgba(7, 7, 15, 0.28) 62%, rgba(7, 7, 15, 0.55)),
    rgba(7, 7, 15, 0.30);
}
.hero .content {
  position: relative; margin-top: auto; margin-left: auto;
  display: flex; flex-direction: column; align-items: flex-end; gap: 20px;
  padding: 24px 24px max(20px, env(safe-area-inset-bottom, 0px));
  max-width: 56rem; width: 100%;
  text-align: right;
}
@media (min-width: 640px) { .hero .content { padding: 40px 48px 48px; gap: 26px; } }

.hero .kicker { flex-direction: row-reverse; }
.hero .kicker::before { margin-left: 0; }

.kicker {
  display: flex; align-items: center; gap: 12px;
  font-size: 11px; font-weight: 500; letter-spacing: 0.42em;
  color: var(--ink-dim); text-transform: uppercase;
}
.kicker::before { content: ""; display: inline-block; height: 1px; width: 40px; background: var(--brand); }

.hero h1 {
  font-family: var(--font-display);
  font-size: var(--h1-size);
  line-height: 0.95; font-weight: 900; letter-spacing: -0.02em;
}
.hero h1 .latin {
  margin-left: 0.18em;
  font-family: Georgia, serif; font-weight: 600; letter-spacing: -0.02em;
  font-style: italic; color: var(--brand);
}
.hero .roman {
  font-family: var(--font-display);
  font-size: clamp(0.8rem, 1.5vw, 1.05rem);
  font-weight: 600; letter-spacing: 0.5em;
  color: var(--ink-dim); text-transform: uppercase;
}
@media (max-width: 639px) {
  .hero .roman { letter-spacing: 0.3em; font-size: 0.72rem; }
  .kicker { letter-spacing: 0.26em; }
  .footer .links a, .footer .brand-line { letter-spacing: 0.12em; }
  .info-card h2, details.info-card > summary { letter-spacing: 0.2em; }
}
/* 首页导语: 三行结构 —— 首行强调, 后两行说明; 尽量不出现孤字/断词 */
.hero .intro {
  max-width: 32rem; font-size: 13px; line-height: 1.95; color: var(--ink-dim);
  text-wrap: pretty;
}
.hero .intro b {
  display: block; margin-bottom: 4px;
  color: var(--ink); font-weight: 500; letter-spacing: 0.02em; font-size: 13.5px;
}
.hero .intro span { display: block; }
.hero .intro span + span { margin-top: 1px; }
@media (max-width: 639px) {
  .hero .intro { font-size: 12.5px; line-height: 1.85; max-width: none; }
  .hero .intro b { font-size: 13px; }
}

.card-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));   /* 不让文字撑宽列, 否则卡片会比下面的最近直播宽 */
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 12px; width: 17rem; max-width: 100%;
}
.link-card {
  position: relative;
  display: flex; flex-direction: column; align-items: flex-start; gap: 4px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  padding: 14px 20px;
  transition: border-color 0.3s, background 0.3s, transform 0.3s;
}
.link-card:hover {
  border-color: var(--brand);
  background: rgba(var(--brand-rgb), 0.07);
  transform: translateY(-2px);
}
.link-card .zh { font-size: 17px; font-weight: 600; letter-spacing: 0.28em; }
.link-card .en {
  font-size: 11px; font-weight: 500; letter-spacing: 0.34em;
  color: var(--ink-faint); text-transform: uppercase;
  transition: color 0.3s;
}
.link-card:hover .en { color: var(--brand); }
.link-card .zh, .link-card .en { white-space: nowrap; }
.link-card::after {
  content: "→"; position: absolute; right: 12px; bottom: 10px;
  font-size: 14px; line-height: 1; color: var(--ink-faint);
  transition: color var(--dur-2) var(--ease-out), transform var(--dur-2) var(--ease-out);
}
.link-card[target="_blank"]::after { content: "↗"; }
.link-card:hover::after { color: var(--brand); transform: translateX(2px); }
.link-card .badge {
  position: absolute; right: -1px; top: -1px;
  background: var(--brand); color: #141630;
  font-size: 10px; font-weight: 700; letter-spacing: 0.12em;
  padding: 3px 10px; border-radius: 0 0 0 8px;
}
.link-card .live-badge { background: #ff5b7f; color: #fff; box-shadow: 0 0 10px rgba(255, 91, 127, 0.7); }
/* 窄屏收紧卡片: 写在基础样式之后才生效 */
@media (max-width: 720px) {
  .link-card { padding: 12px 14px; }
  .link-card .zh { font-size: 15px; letter-spacing: 0.12em; }
  .link-card .en { font-size: 10px; letter-spacing: 0.16em; }
}
@media (max-width: 340px) {
  .link-card { align-items: center; padding: 12px 8px; }
  .link-card .zh { font-size: 14px; letter-spacing: 0.04em; }
  .link-card .en { font-size: 9px; letter-spacing: 0.06em; }
  .link-card .badge { padding: 1px 6px; font-size: 9px; }
  .link-card::after { display: none; }
}

/* live status strip */
.live-strip {
  display: inline-flex; align-items: center; gap: 10px;
  align-self: flex-end;
  border: 1px solid var(--line); border-radius: var(--radius-pill);
  padding: 8px 16px; font-size: 12px; letter-spacing: 0.08em;
  color: var(--ink-dim);
  background: rgba(10, 10, 22, 0.5);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  transition: border-color 0.3s;
}
.live-strip:hover { border-color: var(--brand); }
.live-strip .dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: #565c7a;
}
.live-strip.live .dot { background: #ff5b7f; box-shadow: 0 0 8px rgba(255, 91, 127, 0.9); animation: twinkle 1.2s infinite alternate; }
.live-strip.live { color: var(--ink); }

/* ---------- subpage layout ---------- */
/* 全站贯通的毛玻璃壁纸层(app.js 自动注入子页面) */
.page-bg {
  position: fixed; inset: 0; z-index: -3; overflow: hidden;
  background: var(--bg);
  /* 毛玻璃"透明度" --glass(0~1): 只改各层的不透明度, 不改图片亮度 */
}
.page-bg img {
  width: 100%; height: 100%; object-fit: cover;
  object-position: var(--page-pos, center);
  /* --glass(0~1) = 背景清晰度: 0 → 完全模糊, 1 → 几乎清晰; 亮度固定不参与 */
  filter: blur(calc(2px + 46px * (1 - var(--glass, 0.6)))) saturate(1.1) brightness(0.8);
  transform: scale(1.06);
  animation: fadeIn 1s ease both;
}
.page-bg::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(to bottom, rgba(7,7,15,0.34), rgba(7,7,15,0.58) 72%, rgba(7,7,15,0.86));
  opacity: 0.62;                                        /* 固定压暗: 只保证文字可读, 不随滑块变 */
}
.page {
  position: relative; min-height: 100svh; width: 100%;
}
.page .bg-glow {
  pointer-events: none; position: fixed; inset: 0; z-index: -1;
  background: radial-gradient(ellipse 50% 40% at 85% -5%, var(--brand-glow), transparent 70%);
  opacity: 0.22;
  transition: background 0.5s ease;
}
.page .wrap {
  position: relative; margin-inline: auto;
  display: flex; flex-direction: column; min-height: 100svh;
  width: 100%; max-width: 64rem;
  padding: 40px 24px 0;
}
@media (min-width: 640px) { .page .wrap { padding: 56px 40px 0; } }

.page header.page-head { margin-top: 48px; display: flex; flex-direction: column; gap: 16px; }
.page h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3rem);
  line-height: 1; font-weight: 900; letter-spacing: -0.01em;
}
.page .lede { max-width: 42rem; font-size: 13px; line-height: 1.9; color: var(--ink-dim); }

/* ---------- buttons / inputs / pills ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 18px;
  border: 1px solid var(--line-strong); border-radius: var(--radius-pill);
  font-size: 12px; font-weight: 500; letter-spacing: 0.14em;
  color: var(--ink-dim); white-space: nowrap;
  transition: color 0.25s, border-color 0.25s, background 0.25s;
}
.btn:hover { color: var(--ink); border-color: var(--brand); background: rgba(var(--brand-rgb), 0.06); }
.btn svg { width: 15px; height: 15px; }
.btn.primary { background: var(--brand); border-color: var(--brand); color: #141630; }
.btn.primary:hover { background: color-mix(in srgb, var(--brand) 80%, #fff); }

.search-box { position: relative; }
.search-box svg {
  position: absolute; left: 14px; top: 50%; transform: translateY(-50%);
  width: 15px; height: 15px; color: var(--ink-faint); pointer-events: none;
}
.search-box input {
  height: 36px; width: 100%; max-width: 220px;
  border: 1px solid var(--line-strong); border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.05);
  padding: 0 32px 0 36px;
  font-size: 13px; color: var(--ink); outline: none;
  transition: border-color 0.25s, background 0.25s;
}
.search-box input::placeholder { color: var(--ink-faint); }
.search-box input:focus { border-color: var(--brand); background: rgba(var(--brand-rgb), 0.07); }

.tag-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-pills button {
  height: 32px; padding: 0 16px;
  border: 1px solid var(--line); border-radius: var(--radius-pill);
  font-size: 12px; font-weight: 500; letter-spacing: 0.1em;
  color: var(--ink-dim);
  transition: all 0.25s;
}
.tag-pills button:hover { border-color: var(--brand); color: var(--ink); }
.tag-pills button.active { background: var(--brand); border-color: var(--brand); color: #141630; }

/* ---------- 通用表格(愿望单等仍在使用; 点歌单已改多列) ---------- */
.song-table { width: 100%; border-collapse: collapse; text-align: left; }
.song-table thead th {
  padding: 12px 16px 12px 0;
  border-bottom: 1px solid var(--line-strong);
  font-size: 12px; font-weight: 500; letter-spacing: 0.16em;
  color: var(--ink-faint); text-transform: uppercase;
  white-space: nowrap;
}
.song-table tbody td {
  padding: 13px 16px 13px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px; vertical-align: middle;
}
.song-table tbody tr { transition: background 0.2s; }
.song-table tbody tr:hover { background: rgba(var(--brand-rgb), 0.05); }
.song-table .name { font-weight: 600; cursor: pointer; transition: color 0.2s; }
.song-table .name:hover { color: var(--brand); }
.song-table .name .idx { color: var(--ink-faint); font-size: 12px; margin-right: 10px; font-weight: 400; font-variant-numeric: tabular-nums; }
.song-table .singer { color: var(--ink-dim); font-size: 13px; }
.song-table .tags { display: flex; flex-wrap: wrap; gap: 6px; }
.song-table .tags i {
  font-style: normal; font-size: 11px; letter-spacing: 0.06em;
  border: 1px solid var(--line-strong); border-radius: var(--radius-pill);
  padding: 2px 9px; color: var(--ink-dim); white-space: nowrap;
}
.song-table .copy-btn {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11px; letter-spacing: 0.1em; color: var(--ink-faint);
  transition: color 0.2s; white-space: nowrap;
}
.song-table .copy-btn:hover { color: var(--brand); }
.song-table .copy-btn svg { width: 13px; height: 13px; }

/* mobile: table becomes cards */
@media (max-width: 639px) {
  .song-table thead { display: none; }
  .song-table, .song-table tbody, .song-table tr, .song-table td { display: block; width: 100%; }
  .song-table tbody tr { padding: 12px 0; border-bottom: 1px solid var(--line); }
  .song-table tbody td { border: none; padding: 3px 0; }
  .song-table td.tags-cell { padding-top: 6px; }
}

/* ---------- 点唱歌单: 多列横条(无封面) ----------
   1002 首用表格太占纵向空间, 改成自适应多列: 桌面 4/3/2 列, 手机 1 列。
   每个条目=序号 + 歌名 + (原唱 · 标签), 整行可点(复制「点歌 歌名」)。 */
.song-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  column-gap: 30px;
}
.song-item {
  display: flex; align-items: center; gap: 11px;
  height: 60px; padding: 0 10px 0 2px;
  border: 0; border-bottom: 1px solid var(--line); border-radius: 8px;
  background: none; text-align: left; cursor: pointer;
  color: inherit; font: inherit;
  transition: background var(--dur-2) var(--ease-out), border-color var(--dur-2) var(--ease-out);
}
.song-item:hover { background: rgba(var(--brand-rgb), 0.07); border-color: rgba(var(--brand-rgb), 0.22); }
.song-item:focus-visible { outline: 1px solid var(--brand); outline-offset: -1px; }
.song-item .idx {
  flex: 0 0 30px; text-align: right; font-size: 11px; font-weight: 400;
  color: var(--ink-faint); font-variant-numeric: tabular-nums;
}
.song-item .body { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 3px; }
.song-item .name {
  font-size: 14.5px; font-weight: 600; line-height: 1.25;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  transition: color var(--dur-2) var(--ease-out);
}
.song-item:hover .name { color: var(--brand); }
.song-item .meta {
  display: flex; align-items: center; gap: 7px; min-width: 0;
  font-size: 12px; line-height: 1.2; color: var(--ink-dim);
}
/* 歌手名可截断; 标签库固定在行尾右对齐, 永不出现半截 pill */
.song-item .singer { flex: 0 1 auto; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.song-item .tags { display: flex; gap: 5px; flex: 0 0 auto; margin-left: auto; }
.song-item .tags i {
  flex: 0 0 auto; font-style: normal; font-size: 11px; letter-spacing: 0.06em;
  border: 1px solid var(--line-strong); border-radius: var(--radius-pill);
  padding: 2px 8px; color: var(--ink-dim); white-space: nowrap;
}
.song-item .copy {
  flex: 0 0 auto; display: flex; align-items: center; opacity: 0;
  color: var(--brand); transition: opacity var(--dur-2) var(--ease-out);
}
.song-item .copy svg { width: 14px; height: 14px; }
.song-item:hover .copy, .song-item:focus-visible .copy { opacity: 1; }

/* 空状态 / 加载失败 */
.song-empty {
  grid-column: 1 / -1; padding: 56px 0; text-align: center;
  color: var(--ink-faint); font-size: 13px; letter-spacing: 0.2em;
}

@media (max-width: 1460px) { .song-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: 26px; } }
@media (max-width: 1120px) { .song-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 22px; } }
@media (max-width: 720px) {
  .song-grid { grid-template-columns: 1fr; column-gap: 0; }
  .song-item { height: 54px; gap: 9px; padding-right: 4px; }
  .song-item .idx { flex-basis: 26px; }
  .song-item .name { font-size: 14px; }
  .song-item .singer { max-width: 46%; }
  .song-item .tags i:nth-child(n+3) { display: none; }
  .song-item .copy { display: none; }
}

/* ---------- pagination ---------- */
.pager { display: flex; align-items: center; gap: 12px; }
.pager button {
  display: flex; align-items: center; justify-content: center;
  width: 32px; height: 32px;
  border: 1px solid var(--line-strong); border-radius: 50%;
  color: var(--ink-dim); transition: all 0.25s;
}
.pager button:hover:not(:disabled) { border-color: var(--brand); color: var(--brand); }
.pager button:disabled { opacity: 0.3; cursor: default; }
.pager button svg { width: 14px; height: 14px; }
.pager .num { font-size: 12px; letter-spacing: 0.2em; color: var(--ink-dim); font-variant-numeric: tabular-nums; }
/* 页码可直接输入跳转 */
.pager .jump { display: inline-flex; align-items: center; gap: 6px; letter-spacing: 0.12em; }
.pager .jump input {
  width: 38px; height: 32px; text-align: center;
  border: 1px solid var(--line-strong); border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  font: inherit; font-size: 12px; font-variant-numeric: tabular-nums;
  color: var(--ink); letter-spacing: 0; transition: border-color 0.2s, background 0.2s;
}
.pager .jump input:hover { border-color: var(--brand); }
.pager .jump input:focus {
  outline: none; border-color: var(--brand);
  background: rgba(var(--brand-rgb), 0.12);
  box-shadow: 0 0 0 3px var(--brand-glow);
}
.pager .jump b { font-weight: 500; color: var(--ink-dim); }

/* ---------- toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 36px; z-index: 200;
  transform: translate(-50%, 20px);
  border: 1px solid var(--brand); border-radius: var(--radius-pill);
  background: rgba(10, 10, 22, 0.88);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  padding: 10px 22px; font-size: 13px; letter-spacing: 0.06em;
  opacity: 0; pointer-events: none;
  transition: opacity 0.3s, transform 0.3s;
  max-width: min(90vw, 480px);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* 表格容器毛玻璃化(透明度跟随外观设置) */
#table-anchor {
  border: 1px solid var(--line); border-radius: 16px;
  background: rgba(10, 10, 22, var(--panel-alpha, 0.26));
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  padding: 6px 18px 14px;
}
.sing-table thead th { border-bottom-color: var(--line-strong); }

/* ---------- SPA 视图切换 ---------- */
.view { display: none; }
.view.active { display: block; }
#page-bg.hide { display: none; }

/* ---------- 唱过的歌 · 控制区 ---------- */
.sing-controls {
  display: flex; flex-wrap: wrap; align-items: center;
  justify-content: space-between; gap: 12px; margin-bottom: 16px;
}
.sing-controls-left { display: flex; gap: 8px; flex-wrap: wrap; }
.sing-meta-row {
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px;
  margin-bottom: 14px;
}
.sing-count {
  margin-left: auto; font-size: 12px; letter-spacing: 0.08em;
  color: var(--ink-faint); font-variant-numeric: tabular-nums;
}
.sort-pills { display: flex; gap: 6px; margin-left: auto; }
.sort-pills button {
  height: 28px; padding: 0 12px;
  border: 1px solid var(--line); border-radius: var(--radius-pill);
  font-size: 11px; letter-spacing: 0.08em; color: var(--ink-faint);
  transition: all 0.25s;
}
.sort-pills button:hover { border-color: var(--brand); color: var(--ink); }
.sort-pills button.active { background: var(--brand); border-color: var(--brand); color: #141630; }
.sing-hint {
  margin: 14px 0 0; font-size: 12px; letter-spacing: 0.08em;
  color: var(--ink-faint); text-align: center;
}
@media (max-width: 720px) {
  .sing-count { margin-left: 0; }
  .sort-pills { margin-left: 0; }
}
/* 鼠标 / 触屏各看各的操作说明 */
.for-touch { display: none; }
@media (hover: none) and (pointer: coarse) {
  .for-mouse { display: none; }
  .for-touch { display: inline; }
}
@media (max-width: 639px) {
  /* 手机: 搜索框占满一行; 来源筛选单行横向滑动, 列表能早点露出来 */
  .toolbar > .search-box, .sing-controls > .search-box { flex: 1 1 100%; }
  .search-box input { max-width: none; }
  .sing-controls, .toolbar { gap: 10px; }
  .sing-controls .btn { height: 36px; padding: 0 14px; }
  #sing-from-pills, #song-tag-pills {
    flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none;
    width: calc(100% + 48px); margin-inline: -24px; padding-inline: 24px;
  }
  #sing-from-pills::-webkit-scrollbar, #song-tag-pills::-webkit-scrollbar { display: none; }
  #sing-from-pills button, #song-tag-pills button { flex-shrink: 0; }
  .sing-meta-row { gap: 10px; }
}

.page .lede strong { color: var(--ink); font-weight: 600; }
.pager-top { margin: 0 0 6px; }
/* 复制后(含随机点歌)那一条闪一下, 复制图标常亮 */
@keyframes itemCopied {
  0% { background: rgba(var(--brand-rgb), 0.28); }
  100% { background: rgba(var(--brand-rgb), 0.06); }
}
.song-item.copied { animation: itemCopied 1.6s var(--ease-out) both; border-color: rgba(var(--brand-rgb), 0.4); }
.song-item.copied .name { color: var(--brand); }
.song-item.copied .copy { opacity: 1; }

/* ---------- 播放列表面板: 清空/移除/拖动 ---------- */
.qp-actions { display: flex; gap: 6px; }
.qp-actions button {
  font-size: 11px; letter-spacing: 0.1em; color: var(--ink-faint);
  border: 1px solid var(--line); border-radius: var(--radius-pill);
  padding: 3px 10px; transition: all 0.2s;
}
.qp-actions button:hover { color: var(--brand); border-color: var(--brand); }
.qp-empty {
  padding: 28px 16px; text-align: center;
  font-size: 12px; color: var(--ink-dim); line-height: 2;
}
.qp-empty span { font-size: 11px; color: var(--ink-faint); }
.qp-row {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 8px 10px 8px 16px; text-align: left;
  font-size: 13px; color: var(--ink-dim); cursor: pointer;
  transition: background 0.15s, color 0.15s;
  touch-action: pan-y;          /* 手机可上下滚动列表 */
}
.qp-row .q-handle { touch-action: none; }   /* 手柄区域用于拖动 */
.qp-row:hover { background: rgba(var(--brand-rgb), 0.07); color: var(--ink); }
.qp-row.playing { color: var(--brand); }
.qp-row.dragging { background: rgba(var(--brand-rgb), 0.16); opacity: 0.92; }
.qp-row .q-idx {
  width: 22px; flex-shrink: 0; text-align: right;
  font-size: 11px; color: var(--ink-faint); font-variant-numeric: tabular-nums;
}
.qp-row.playing .q-idx { color: var(--brand); }
.qp-row .q-name {
  flex: 1; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.qp-row .q-dur { flex-shrink: 0; font-size: 11px; color: var(--ink-faint); font-variant-numeric: tabular-nums; }
.qp-row .q-remove {
  flex-shrink: 0; width: 20px; height: 20px; border-radius: 50%;
  font-size: 14px; line-height: 1; color: var(--ink-faint);
  transition: color 0.2s, background 0.2s;
}
.qp-row .q-remove:hover { color: #ff7a9c; background: rgba(255, 122, 156, 0.12); }
.qp-row .q-handle {
  flex-shrink: 0; padding: 0 4px; cursor: grab;
  font-size: 13px; color: var(--ink-faint); letter-spacing: -2px;
  transition: color 0.2s;
}
.qp-row .q-handle:hover { color: var(--brand); }
body.dragging-row { user-select: none; cursor: grabbing; }

/* 音量 */
.vol-wrap { display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
.vol-wrap #vol-range {
  -webkit-appearance: none; appearance: none;
  width: 68px; height: 3px; border-radius: 3px;
  background: rgba(255, 255, 255, 0.18);
  accent-color: var(--brand); cursor: pointer; outline: none;
}
.vol-wrap #vol-range::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 11px; height: 11px; border-radius: 50%;
  background: var(--brand); box-shadow: 0 0 6px var(--brand-glow);
}
.vol-wrap #vol-range::-moz-range-thumb {
  width: 11px; height: 11px; border: none; border-radius: 50%;
  background: var(--brand);
}
.vol-wrap #vol-range::-moz-range-track {
  height: 3px; border-radius: 3px; background: rgba(255, 255, 255, 0.18);
}
@media (max-width: 720px) {
  .vol-wrap #vol-range { display: none; }   /* 手机上隐藏滑块, 保留静音按钮 */
}

/* 播放列表按钮(位于进度/时间右侧) */
.player-bar .queue-btn {
  display: flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0;
  color: var(--ink-dim); transition: color 0.2s, background 0.2s;
}
.player-bar .queue-btn:hover { color: var(--brand); background: rgba(var(--brand-rgb), 0.1); }
.player-bar .queue-btn.on { color: var(--brand); }
.player-bar .queue-btn svg { width: 16px; height: 16px; }

/* 拖动排序的动效(不加横向缩放, 否则会撑出横向滚动条) */
.qp-row { will-change: transform; }
.qp-row.dragging {
  background: rgba(var(--brand-rgb), 0.18);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.45), 0 0 0 1px var(--brand) inset;
  border-radius: 10px;
  opacity: 0.96;
  z-index: 2; position: relative;
  cursor: grabbing;
}
.qp-row.shifting { transition: transform 0.18s cubic-bezier(0.22, 0.9, 0.32, 1); }
.qp-body.drop-active { background: rgba(var(--brand-rgb), 0.04); }

/* ---------- 外观设置面板 ---------- */
.appearance-panel {
  position: fixed; right: 12px; z-index: 80;
  top: calc(env(safe-area-inset-top, 0px) + 58px);
  width: min(300px, calc(100vw - 24px));
  border: 1px solid var(--line); border-radius: 16px;
  background: rgba(10, 10, 22, 0.94);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.45);
  transform: translateY(-8px) scale(0.98); opacity: 0; pointer-events: none;
  transition: transform 0.2s ease, opacity 0.2s ease;
  overflow: hidden;
}
.appearance-panel.open { transform: none; opacity: 1; pointer-events: auto; }
.ap-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; border-bottom: 1px solid var(--line);
  font-size: 12px; font-weight: 600; letter-spacing: 0.2em;
}
.ap-head button {
  font-size: 11px; letter-spacing: 0.1em; color: var(--ink-faint);
  border: 1px solid var(--line); border-radius: var(--radius-pill);
  padding: 3px 10px; transition: all 0.2s;
}
.ap-head button:hover { color: var(--brand); border-color: var(--brand); }
.ap-body { padding: 14px 16px 18px; }
.ap-label {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 11px; letter-spacing: 0.14em; color: var(--ink-dim); margin-bottom: 10px;
}
.ap-label b { color: var(--brand); font-variant-numeric: tabular-nums; }
.ap-body #frost-range {
  -webkit-appearance: none; appearance: none;
  width: 100%; height: 3px; border-radius: 3px;
  background: rgba(255, 255, 255, 0.18); accent-color: var(--brand);
  outline: none; cursor: pointer;
}
.ap-body #frost-range::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 14px; height: 14px; border-radius: 50%;
  background: var(--brand); box-shadow: 0 0 8px var(--brand-glow);
}
.ap-body #frost-range::-moz-range-thumb {
  width: 14px; height: 14px; border: none; border-radius: 50%; background: var(--brand);
}
.ap-hint { font-size: 11px; line-height: 1.8; color: var(--ink-faint); margin-top: 10px; }
.ap-wallpaper { width: 100%; height: 36px; margin-top: 14px; }

/* ---------- 右键菜单 ---------- */
.ctx-menu {
  position: fixed; z-index: 200; min-width: 148px;
  display: none; flex-direction: column;
  border: 1px solid var(--line); border-radius: 12px;
  background: rgba(12, 12, 24, 0.96);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
  padding: 5px; overflow: hidden;
}
.ctx-menu.open { display: flex; }
.ctx-menu button {
  text-align: left; padding: 9px 14px; border-radius: 8px;
  font-size: 13px; color: var(--ink-dim); transition: background 0.15s, color 0.15s;
}
.ctx-menu button:hover { background: rgba(var(--brand-rgb), 0.12); color: var(--ink); }
.ctx-menu button.danger:hover { background: rgba(255, 122, 156, 0.14); color: #ff7a9c; }

/* ---------- footer ---------- */
.footer {
  position: relative; z-index: 1;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px;
  border-top: 1px solid var(--line);
  margin-top: auto;
  padding: 22px 24px 28px;
}
.footer .brand-line {
  font-size: 11px; font-weight: 500; letter-spacing: 0.24em;
  color: var(--ink-faint); text-transform: uppercase;
}
/* 版本号由 deploy/release.py 发版时写入 index.html */
.footer .site-version {
  margin-left: 0.8em; letter-spacing: 0.08em; text-transform: none;
  font-variant-numeric: tabular-nums; opacity: 0.8;
}
.footer .links { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.footer .links a {
  font-size: 11px; font-weight: 500; letter-spacing: 0.24em;
  color: var(--ink-dim); text-transform: uppercase;
  transition: color 0.25s;
}
.footer .links a:hover { color: var(--brand); }

/* ---------- about page ---------- */
.about-grid { display: grid; gap: 14px; margin-top: 40px; }
@media (min-width: 720px) { .about-grid { grid-template-columns: 1fr 1fr; } }
.info-card {
  border: 1px solid var(--line); border-radius: 18px;
  background: rgba(13, 13, 26, calc(var(--panel-alpha, 0.26) + 0.06));
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  padding: 24px 26px;
  display: flex; flex-direction: column; gap: 12px;
}
.info-card h2 {
  font-size: 11px; font-weight: 600; letter-spacing: 0.34em;
  color: var(--brand); text-transform: uppercase;
  display: flex; align-items: center; gap: 10px;
}
.info-card h2::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.info-card p, .info-card li { font-size: 13px; line-height: 1.9; color: var(--ink-dim); }
.info-card ul { list-style: none; display: flex; flex-direction: column; gap: 6px; }
.info-card a.link {
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--ink); font-size: 13px;
  border-bottom: 1px solid var(--line-strong); padding-bottom: 1px;
  transition: color 0.2s, border-color 0.2s;
  width: fit-content;
}
.info-card a.link:hover { color: var(--brand); border-color: var(--brand); }
.info-card .avatar {
  width: 72px; height: 72px; border-radius: 50%;
  border: 1px solid var(--line-strong);
}

.about-me { display: flex; align-items: center; gap: 16px; }
.info-card .about-name { color: var(--ink); font-size: 16px; font-weight: 600; letter-spacing: 0.06em; }
.info-card .about-role { font-size: 12px; letter-spacing: 0.12em; color: var(--ink-faint); }
.wish-table col.c-name { width: 44%; }
.wish-table col.c-artist { width: 24%; }
.wish-table col.c-status { width: 14%; }
.stat-row { display: flex; gap: 28px; flex-wrap: wrap; }
.stat { display: flex; flex-direction: column; gap: 2px; }
.stat b { font-size: 22px; font-weight: 700; font-variant-numeric: tabular-nums; }
.stat span { font-size: 11px; letter-spacing: 0.28em; color: var(--ink-faint); text-transform: uppercase; }

/* ---------- player（唱过的歌） ---------- */
/* 播放条占位: 高度由 JS 实时设置, 保证页脚/内容不被悬浮播放条压住 */
.player-spacer { height: 0; width: 100%; pointer-events: none; }
.player-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
  border-top: 1px solid var(--line);
  background: rgba(10, 10, 22, 0.82);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom, 0px));
  display: flex; align-items: center; gap: 14px;
  transform: translateY(110%);
  transition: transform 0.4s cubic-bezier(0.22, 0.9, 0.32, 1);
}
.player-bar.on { transform: translateY(0); }
.player-bar .cover {
  width: 46px; height: 46px; border-radius: 50%;
  object-fit: cover; flex-shrink: 0;
  border: 1px solid var(--line-strong);
  animation: spin 14s linear infinite paused;
}
.player-bar.playing .cover { animation-play-state: running; }
@keyframes spin { to { transform: rotate(360deg); } }
.player-bar .meta { min-width: 0; width: 220px; flex-shrink: 0; display: flex; flex-direction: column; gap: 2px; }
.player-bar .meta b {
  font-size: 13px; font-weight: 600; letter-spacing: 0.04em;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.player-bar .meta span {
  font-size: 11px; letter-spacing: 0.14em; color: var(--ink-faint);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.player-bar .ctrl {
  display: flex; align-items: center; gap: 6px; flex-shrink: 0;
}
.player-bar .ctrl button {
  display: flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 50%;
  color: var(--ink-dim); transition: color 0.2s, background 0.2s;
}
.player-bar .ctrl button:hover { color: var(--brand); background: rgba(var(--brand-rgb), 0.1); }
.player-bar .ctrl .play-btn {
  width: 42px; height: 42px;
  border: 1px solid var(--brand);
  color: var(--brand);
}
.player-bar .ctrl .play-btn:hover { background: var(--brand); color: #141630; }
/* 加载中: 播放键外圈转动 */
.player-bar .ctrl .play-btn { position: relative; }
.player-bar.loading .ctrl .play-btn::after {
  content: ""; position: absolute; inset: -4px; border-radius: 50%;
  border: 2px solid transparent; border-top-color: var(--brand); border-right-color: var(--brand);
  animation: spin 0.9s linear infinite;
}
.player-bar .ctrl svg { width: 17px; height: 17px; }
.player-bar .prog-wrap {
  flex: 1; display: flex; align-items: center; gap: 10px; min-width: 0;
}
.player-bar .time {
  font-size: 11px; letter-spacing: 0.08em; color: var(--ink-faint);
  font-variant-numeric: tabular-nums; white-space: nowrap;
}
.player-bar .prog {
  flex: 1; height: 18px; display: flex; align-items: center; cursor: pointer; min-width: 40px;
}
.player-bar .prog .rail {
  position: relative; width: 100%; height: 3px; border-radius: 3px;
  background: rgba(255, 255, 255, 0.12); overflow: hidden;
}
.player-bar .prog .fill {
  position: absolute; inset: 0; width: 0%;
  background: var(--brand); border-radius: 3px;
  box-shadow: 0 0 8px var(--brand-glow);
}
@media (max-width: 720px) {
  .player-bar .prog-wrap { position: absolute; left: 0; right: 0; top: -8px; padding: 0 12px; }
  .player-bar .time { display: none; }
  .player-bar { gap: 10px; }
  .player-bar .meta { width: auto; flex: 1; }
}
/* 窄屏: 播放条紧凑化, 避免封面/歌名/按钮互相挤压 */
@media (max-width: 639px) {
  .player-bar { padding: 8px 10px calc(8px + env(safe-area-inset-bottom, 0px)); gap: 8px; }
  .player-bar .cover { width: 38px; height: 38px; }
  .player-bar .meta b { font-size: 12px; }
  .player-bar .meta span { font-size: 10px; letter-spacing: 0.08em; }
  .player-bar .ctrl { gap: 2px; }
  .player-bar .ctrl button { width: 31px; height: 31px; }
  .player-bar .ctrl .play-btn { width: 40px; height: 40px; }
  .player-bar .ctrl svg { width: 15px; height: 15px; }
  .player-bar .queue-btn { width: 31px; height: 31px; }
  .player-bar .vol-wrap { gap: 0; }
  .player-bar #vol-range { display: none; }
}
/* 极窄屏: 播放模式移入播放列表头部, 播放条只留核心操作 */
@media (max-width: 430px) {
  .player-bar #p-mode { display: none; }
  .player-bar #p-vol, .player-bar .vol-wrap { display: none; }
}

/* 唱过的歌 — 播放器式曲目表 */
.sing-table { width: 100%; border-collapse: collapse; text-align: left; table-layout: fixed; }
.sing-table thead th {
  padding: 10px 12px;
  border-bottom: 1px solid var(--line-strong);
  font-size: 12px; font-weight: 500; letter-spacing: 0.16em;
  color: var(--ink-faint); text-transform: uppercase;
  white-space: nowrap;
}
.sing-table tbody td { padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.sing-table tbody tr { cursor: pointer; transition: background 0.2s; }
.sing-table tbody tr:hover { background: rgba(var(--brand-rgb), 0.06); }
.sing-table tbody tr.playing { background: rgba(var(--brand-rgb), 0.1); }
.sing-table tbody tr.playing .st-name { color: var(--brand); }
.sing-table .st-idx {
  width: 40px; font-size: 13px; color: var(--ink-faint);
  font-variant-numeric: tabular-nums; letter-spacing: 0.05em;
}
.sing-table .st-title { overflow: hidden; }
.sing-table .st-title-in { display: flex; align-items: center; gap: 12px; min-width: 0; max-width: 100%; }
.sing-table .st-cover {
  width: 44px; height: 44px; border-radius: 8px; object-fit: cover; flex-shrink: 0;
  border: 1px solid var(--line); background: var(--bg-soft);
}
.sing-table .st-names { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.sing-table .st-name {
  font-size: 14px; font-weight: 600;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.sing-table .st-sub {
  font-size: 11px; color: var(--ink-faint);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.sing-table .st-album { font-size: 12px; color: var(--ink-dim); letter-spacing: 0.06em; white-space: nowrap; }
.sing-table .st-fav { width: 48px; }
.sing-table .fav-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px; border-radius: 50%;
  color: var(--ink-faint); transition: color 0.2s, transform 0.2s;
}
.sing-table .fav-btn:hover { color: var(--brand); transform: scale(1.12); }
.sing-table .fav-btn.on { color: #ff6b9d; }
.sing-table .fav-btn svg { width: 16px; height: 16px; }
.sing-table .st-dur {
  width: 64px; font-size: 12px; color: var(--ink-dim);
  font-variant-numeric: tabular-nums; letter-spacing: 0.06em; white-space: nowrap;
}
@media (max-width: 639px) {
  .sing-table thead { display: none; }
  .sing-table .st-album { display: none; }
  .sing-table .st-idx { width: 28px; font-size: 11px; padding-right: 0; }
  .sing-table tbody td { padding: 8px 6px; }
  .sing-table .st-cover { width: 40px; height: 40px; }
}
/* 更窄的屏幕: 再压缩各列, 给歌名留出空间 */
@media (max-width: 400px) {
  .sing-table tbody td { padding: 7px 3px; }
  .sing-table .st-idx { width: 24px; font-size: 11px; }
  .sing-table .st-cover { width: 34px; height: 34px; }
  .sing-table .st-name { font-size: 13px; }
  .sing-table .st-sub { font-size: 11px; }
  .sing-table .st-fav { width: 36px; }
  .sing-table .st-dur { width: 44px; font-size: 11px; }
  .sing-table .st-title-in { gap: 8px; }
}
/* 播放模式按钮高亮 + 播放列表面板 */
.player-bar .ctrl button.mode-shuffle { color: var(--brand); }
.queue-panel {
  position: fixed; right: 16px; z-index: 70;
  bottom: calc(84px + env(safe-area-inset-bottom, 0px));
  width: min(380px, calc(100vw - 32px)); max-height: 52vh;
  display: flex; flex-direction: column;
  border: 1px solid var(--line); border-radius: 16px;
  background: rgba(10, 10, 22, 0.92);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  transform: translateY(12px); opacity: 0; pointer-events: none;
  transition: transform 0.25s ease, opacity 0.25s ease;
  overflow: hidden;
}
.queue-panel.open { transform: none; opacity: 1; pointer-events: auto; }
@media (max-width: 639px) {
  .queue-panel {
    left: 0; right: 0; bottom: calc(72px + env(safe-area-inset-bottom, 0px));
    width: 100%; max-height: 60vh;
    border-radius: 18px 18px 0 0;
    border-left: none; border-right: none;
  }
}
.qp-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; border-bottom: 1px solid var(--line);
  font-size: 12px; font-weight: 600; letter-spacing: 0.2em;
}
.qp-head .qp-count { font-size: 11px; color: var(--ink-faint); letter-spacing: 0.14em; }
.qp-body { overflow-y: auto; overflow-x: hidden; }
.qp-row {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 8px 16px; text-align: left;
  font-size: 13px; color: var(--ink-dim);
  transition: background 0.15s, color 0.15s;
}
.qp-row:hover { background: rgba(var(--brand-rgb), 0.07); color: var(--ink); }
.qp-row.playing { color: var(--brand); }
.qp-row .q-idx {
  width: 22px; flex-shrink: 0; text-align: right;
  font-size: 11px; color: var(--ink-faint); font-variant-numeric: tabular-nums;
}
.qp-row.playing .q-idx { color: var(--brand); }
.qp-row .q-name {
  flex: 1; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.qp-row .q-dur { flex-shrink: 0; font-size: 11px; color: var(--ink-faint); font-variant-numeric: tabular-nums; }

/* 给播放器留出底部空间(body 上的内联 padding 会按播放条真实高度动态设置) */
/* 底部空间由 .player-spacer 动态撑开(不再固定 padding) */

/* ============================================================
   动效系统 —— 统一的关键帧 / 时长 / 缓动
   ============================================================ */

/* 视图切换: 淡入 + 轻微上移(每次切换重新播放) */
@keyframes viewIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}
.view.active { animation: viewIn var(--dur-3) var(--ease-out) both; }

/* 列表逐行入场: 由 JS 写入 style="--row-i:N" 控制错峰 */
@keyframes rowIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: none; }
}
.sing-table tbody tr,
.song-item {
  animation: rowIn var(--dur-2) var(--ease-out) both;
  animation-delay: calc(var(--row-i, 0) * 14ms);
}

/* 卡片 / 按钮 / 药丸: 统一缓动, 悬停有"抬起"感 */
.link-card { transition: border-color var(--dur-2) var(--ease-out), background var(--dur-2) var(--ease-out), transform var(--dur-2) var(--ease-out); }
.link-card:hover { transform: translateY(-3px); }
.link-card:active { transform: translateY(-1px) scale(0.995); }
.pill, .pager button, .ext-btn, .btn, .qp-actions button, .icon-btn {
  transition-timing-function: var(--ease-out);
}

/* 播放器: 换曲时封面淡入; 播放键按下有回弹 */
@keyframes coverIn {
  from { opacity: 0; transform: scale(0.92); }
  to   { opacity: 1; transform: none; }
}
.player-bar .cover { animation: coverIn var(--dur-2) var(--ease-out) both; }
.player-bar .ctrl .play-btn { transition: transform var(--dur-1) var(--ease-out), background var(--dur-2) var(--ease-out); }
.player-bar .ctrl .play-btn:active { transform: scale(0.9); }
.player-bar .ctrl button:active { transform: scale(0.92); }
.player-bar .ctrl button { transition: transform var(--dur-1) var(--ease-out), color var(--dur-2) var(--ease-out); }

/* 进度条: 已播放部分平滑过渡, 拖动时禁用(JS 会加 .dragging) */
.prog-fill { transition: width 0.25s linear; }
.prog-wrap.dragging .prog-fill { transition: none; }

/* 播放列表面板: 从右下角弹出 */
.queue-panel {
  transform: translateY(14px) scale(0.98);
  transform-origin: bottom right;
  transition: transform var(--dur-2) var(--ease-out), opacity var(--dur-2) var(--ease-out);
}
.queue-panel.open { transform: none; }

/* 右键 / 长按菜单 */
@keyframes menuIn {
  from { opacity: 0; transform: scale(0.96) translateY(-4px); }
  to   { opacity: 1; transform: none; }
}
.ctx-menu.open { display: flex; animation: menuIn var(--dur-1) var(--ease-out) both; transform-origin: top left; }

/* 外观面板: 从右上角展开 */
.appearance-panel {
  transform-origin: top right;
  transition: transform var(--dur-2) var(--ease-out), opacity var(--dur-2) var(--ease-out);
}
.appearance-panel:not(.open) { transform: translateY(-8px) scale(0.97); }

/* 主题色可过渡: 把品牌色注册成 <color>, 换壁纸时颜色跟着图片一起渐变而不是突变 */
@property --brand {
  syntax: '<color>'; inherits: true; initial-value: #a9bdf5;
}
@property --brand-deep {
  syntax: '<color>'; inherits: true; initial-value: #6678c8;
}
@property --brand-glow {
  syntax: '<color>'; inherits: true; initial-value: rgba(169, 189, 245, 0.65);
}
:root {
  transition: --brand 1.3s var(--ease-soft),
              --brand-deep 1.3s var(--ease-soft),
              --brand-glow 1.3s var(--ease-soft);
}

/* 壁纸切换: 双层交叉淡入(新图在上层淡入, 旧图不动), 不会先变黑再亮 */
.hero .bg-next {
  z-index: -2;
  opacity: 0;
  animation: none;
  transition: opacity 1.3s var(--ease-soft);
  will-change: opacity;
}
.hero .bg-next.on { opacity: 1; }

/* 主题色驱动的"填充"不要自己再做过渡:
   --brand 本身已在 :root 上以 1.3s 平滑动画; 元素若再带 background 过渡,
   会产生约等于过渡时长的固定滞后 —— 看起来就是"导航比壁纸慢半拍"。
   这里显式把 background 从过渡属性里剔除, 让填充色严格跟随变量动画。 */
.nav .pill-group a.active,
.tag-pills button.active,
.sort-pills button.active,
.btn.primary {
  transition: color 0.2s var(--ease-out), border-color 0.2s var(--ease-out),
              transform 0.2s var(--ease-out), box-shadow 0.2s var(--ease-out);
}

/* toast: 从底部滑入 */
@keyframes toastIn {
  from { opacity: 0; transform: translate(-50%, 12px); }
  to   { opacity: 1; transform: translate(-50%, 0); }
}
.toast.show { animation: toastIn var(--dur-2) var(--ease-out) both; }

/* 键盘聚焦可见(鼠标点击不显示) */
:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 3px;
  border-radius: 4px;
}

/* 尊重系统"减少动态效果"设置 */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .view.active, .sing-table tbody tr, .song-item { animation: none !important; }
}

/* ============================================================
   周表 / 账号 / 愿望单 / 上车预约(沿用上方 tokens 与组件写法)
   ============================================================ */

/* hidden 属性优先于各组件自己的 display */
[hidden] { display: none !important; }

/* ---------- 导航: 窄屏短标签 + 账号按钮 ---------- */
.nav .pill-group a .s { display: none; }
/* 「关于」放不下时只留在页脚 */
@media (max-width: 959px) { .nav .pill-group .nav-about { display: none; } }
/* 放不下时逐级收起, 文字一律不折行(折行会把站名和按钮挤成竖排) */
.nav .crumbs a, .nav .ext-btn { white-space: nowrap; }
.nav .pill-group, .nav .ext-btn { flex: none; }
@media (max-width: 899px) {
  .nav .crumbs .sep, .nav .crumbs .here { display: none; }
  .nav .ext-btn.ext-bili { padding: 8px; }
  .nav .ext-btn.ext-bili span { display: none; }
}
@media (max-width: 759px) {
  .nav .ext-btn { padding: 8px; }
  .nav .ext-btn span { display: none; }
}
@media (max-width: 639px) {
  .nav .pill-group a .l { display: none; }
  .nav .pill-group a .s { display: inline; }
  .nav .ext-bili { display: none; }
  .nav .pill-group { max-width: calc(100vw - 104px); overflow-x: auto; scrollbar-width: none; }
  .nav .pill-group::-webkit-scrollbar { display: none; }
}
.nav .nav-account { position: relative; }
.nav .nav-account .nav-av { width: 18px; height: 18px; border-radius: 50%; object-fit: cover; margin: -2px 0; }
.nav .nav-account.active { color: var(--ink); border-color: var(--brand); }
.nav .nav-account span { max-width: 8em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 备份模式: 登录入口改成醒目的「备份站点」, 手机上也显示文字 */
.nav .nav-account.backup { padding: 8px 12px; border-color: #ffc454; color: #ffc454; font-weight: 600; }
.nav .nav-account.backup span { display: inline; }
@media (max-width: 639px) {
  /* 文字按钮比图标宽, 留在导航行会把栏目挤出屏幕: 移到导航行下方 */
  .nav .nav-account.backup { position: fixed; top: calc(env(safe-area-inset-top, 0px) + 54px); right: 12px; }
}
.backup-note { flex: 1 0 100%; font-size: 12px; line-height: 1.8; color: #ffc454; }
.badge-count {
  position: absolute; top: -5px; right: -5px;
  min-width: 16px; height: 16px; padding: 0 4px; border-radius: var(--radius-pill);
  background: #ff5b7f; color: #fff; box-shadow: 0 0 8px rgba(255, 91, 127, 0.7);
  font-size: 10px; font-weight: 700; font-style: normal; line-height: 16px; text-align: center;
  font-variant-numeric: tabular-nums;
}

/* toast: 错误提示允许换行, 描边换成提示色 */
.toast.error { border-color: #ff7a9c; white-space: normal; text-align: center; }

/* ---------- 通用小件 ---------- */
.view-body { margin-top: 40px; padding-bottom: 64px; }
.muted { color: var(--ink-faint); font-size: 12px; letter-spacing: 0.06em; line-height: 1.9; }
.hint { font-size: 12px; line-height: 1.9; color: var(--ink-faint); letter-spacing: 0.04em; }
.empty { padding: 40px 0; text-align: center; color: var(--ink-faint); font-size: 13px; letter-spacing: 0.16em; }
td.empty { padding: 48px 0; }
.toolbar {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 12px; margin-bottom: 16px;
}
.toolbar-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.toolbar-note {
  font-size: 12px; letter-spacing: 0.16em; color: var(--ink-faint);
  font-variant-numeric: tabular-nums;
}
a.link-note:hover { color: var(--brand); }
@media (min-width: 720px) { .toolbar .sort-pills { margin-left: 0; } .toolbar-note { margin-right: auto; } }
.form-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.btn.danger:hover { color: #ff7a9c; border-color: #ff7a9c; background: rgba(255, 122, 156, 0.08); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: 0.45; cursor: default; pointer-events: none; }
/* 行内文字按钮(与 .info-card a.link 同款下划线) */
button.link, a.inline-link, .lede a.inline-link {
  display: inline; padding: 0 0 1px; color: var(--ink);
  border-bottom: 1px solid var(--line-strong);
  font-size: inherit; letter-spacing: inherit;
  transition: color 0.2s, border-color 0.2s;
}
button.link:hover, a.inline-link:hover { color: var(--brand); border-color: var(--brand); }
.info-card a.link, .muted a.link, .empty a.link { display: inline; }
.notice-line {
  margin: 0 0 14px; padding: 10px 16px;
  border: 1px solid var(--line); border-radius: 12px;
  background: rgba(var(--brand-rgb), 0.06);
  font-size: 12.5px; line-height: 1.8; color: var(--ink-dim);
}
.notice-line.error { border-color: rgba(255, 122, 156, 0.5); background: rgba(255, 122, 156, 0.08); color: var(--ink); }
.ok-chip, .count-chip {
  display: inline-block; font-size: 11px; letter-spacing: 0.1em; font-weight: 500;
  border: 1px solid var(--line-strong); border-radius: var(--radius-pill);
  padding: 1px 9px; color: var(--ink-dim); text-transform: none;
}
.count-chip { border-color: #ff7a9c; color: #ff7a9c; letter-spacing: 0.06em; }

/* 表单字段: 与搜索框同一套描边与聚焦色 */
.field { display: flex; flex-direction: column; gap: 6px; }
.field > span { font-size: 12px; letter-spacing: 0.1em; color: var(--ink-dim); }
.field input, .field textarea, .field select {
  width: 100%; min-height: 40px;
  border: 1px solid var(--line-strong); border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  padding: 9px 14px; font: inherit; font-size: 14px; color: var(--ink); outline: none;
  transition: border-color 0.25s, background 0.25s;
}
.field textarea { resize: vertical; line-height: 1.7; }
.field input::placeholder, .field textarea::placeholder { color: var(--ink-faint); }
.field input:focus, .field textarea:focus { border-color: var(--brand); background: rgba(var(--brand-rgb), 0.07); }
.field input[readonly] { color: var(--ink-dim); font-size: 12px; }

/* 毛玻璃表格容器(透明度跟随外观设置) */
.glass-table {
  border: 1px solid var(--line); border-radius: 16px;
  background: rgba(10, 10, 22, var(--panel-alpha, 0.26));
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  padding: 4px 18px 10px; overflow-x: auto;
}
@media (max-width: 639px) { .glass-table { padding: 4px 14px 8px; } }
.pager-row { display: flex; justify-content: flex-end; margin-top: 16px; }

/* ---------- Markdown 公告 ---------- */
.md { font-size: 13px; line-height: 1.9; color: var(--ink-dim); overflow-wrap: anywhere; }
.md > * + * { margin-top: 8px; }
.md h3, .md h4, .md h5 { color: var(--ink); font-weight: 600; letter-spacing: 0.06em; }
.md h3 { font-size: 15px; } .md h4 { font-size: 14px; } .md h5 { font-size: 13px; }
.md strong { color: var(--ink); font-weight: 600; }
.md ul, .md ol { padding-left: 1.4em; display: block; }
.md ul { list-style: disc; } .md ol { list-style: decimal; }
.md li { font-size: 13px; }
.md blockquote { border-left: 2px solid var(--line-strong); padding-left: 12px; color: var(--ink-faint); }
.md code { font-size: 12px; background: rgba(255, 255, 255, 0.06); border-radius: 6px; padding: 1px 6px; }
.md pre { background: rgba(255, 255, 255, 0.04); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; overflow-x: auto; }
.md pre code { background: none; padding: 0; }
.md a { color: var(--ink); border-bottom: 1px solid var(--line-strong); transition: color 0.2s, border-color 0.2s; }
.md a:hover { color: var(--brand); border-color: var(--brand); }
.md hr { border: none; height: 1px; background: var(--line); }

/* ---------- 首页: 最近直播 + 公告（四个入口卡片左侧，直角同宽） ---------- */
.home-bottom {
  display: flex; width: 100%; gap: 12px;
  align-items: stretch; justify-content: flex-end;
}
.home-bottom > * { flex: 0 1 17rem; min-width: 0; }
.home-board {
  display: flex; flex-direction: column; gap: 12px;
  width: 17rem; max-width: 100%;
  text-align: left;
}
.home-board .info-card {
  flex: 1 1 auto;
  border-radius: 0;
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  padding: 14px 18px; gap: 10px;
}
.home-board .board-links { margin-top: auto; }
@media (max-width: 639px) {
  /* 手机放不下并排：卡片在上，直播/公告在下；连同上方的直播状态条都占满内容宽度，左右对齐 */
  .home-bottom { flex-direction: column-reverse; align-items: flex-end; }
  .home-bottom > * { flex: none; width: 100%; }
  .live-strip { width: 100%; justify-content: center; text-align: center; }
}
.upcoming { display: flex; flex-direction: column; gap: 12px; }
.upcoming-day { display: flex; flex-direction: column; gap: 6px; }
.upcoming-day + .upcoming-day { border-top: 1px solid var(--line); padding-top: 12px; }
.upcoming-date { display: flex; align-items: baseline; justify-content: space-between; gap: 4px 10px; flex-wrap: wrap; }
/* 日期+星期整体不拆行（否则卡片窄时"周四"会被断成"周"/"四"）；挤不下时让右侧状态换行 */
.upcoming-date b { font-size: 15px; font-weight: 600; letter-spacing: 0.08em; white-space: nowrap; flex: 0 0 auto; }
.upcoming-date span { font-size: 11px; letter-spacing: 0.16em; color: var(--brand); white-space: nowrap; }
.upcoming-day.quiet .upcoming-date b { font-size: 13px; color: var(--ink-dim); }
.upcoming-day.quiet .upcoming-date span { color: var(--ink-faint); }
.board-links { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 12px; }
.board-links .link { font-size: 12px; }

/* ---------- 周表 ---------- */
.notice-card { margin-bottom: 14px; }
.schedule-grid { display: grid; gap: 12px; }
@media (min-width: 640px) { .schedule-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .schedule-grid { grid-template-columns: repeat(7, 1fr); gap: 10px; } }
.day-card {
  position: relative; display: flex; flex-direction: column; gap: 10px;
  border: 1px solid var(--line); border-radius: 16px;
  background: rgba(13, 13, 26, calc(var(--panel-alpha, 0.26) + 0.06));
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  padding: 14px 16px 16px; min-height: 120px;
  animation: rowIn var(--dur-3) var(--ease-out) both;
  animation-delay: calc(var(--row-i, 0) * 40ms);
}
/* 已经过去的日子调暗, 一眼看出"接下来"从哪天开始 */
/* (卡片自身的 opacity 被入场动画占用, 所以调暗内容) */
.day-card.past > * { opacity: 0.5; transition: opacity var(--dur-2) var(--ease-out); }
.day-card.past:hover > * { opacity: 0.9; }
.day-card.today { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand) inset, 0 0 22px -8px var(--brand-glow); }
.day-head { display: flex; align-items: baseline; gap: 8px; padding-bottom: 8px; border-bottom: 1px solid var(--line); }
.day-head b { font-size: 14px; font-weight: 600; letter-spacing: 0.14em; }
.day-head span { font-size: 11px; letter-spacing: 0.08em; color: var(--ink-faint); font-variant-numeric: tabular-nums; }
.day-head b, .day-head span { white-space: nowrap; }
@media (min-width: 960px) { .day-head { flex-direction: column; gap: 2px; } }
.today-chip {
  position: absolute; right: -1px; top: -1px;
  background: var(--brand); color: #141630;
  font-size: 10px; font-weight: 700; font-style: normal; letter-spacing: 0.12em;
  padding: 3px 10px; border-radius: 0 15px 0 8px;
}
.day-status { font-size: 12px; letter-spacing: 0.3em; color: var(--ink-faint); margin: auto 0; text-align: center; }
.day-card.rest .day-status { color: var(--ink-dim); }
.day-event { display: flex; flex-direction: column; gap: 4px; }
.day-event + .day-event { padding-top: 8px; border-top: 1px dashed var(--line); }
.day-event time { font-size: 15px; font-weight: 700; color: var(--brand); font-variant-numeric: tabular-nums; letter-spacing: 0.04em; }
.day-event .ev-content { font-size: 13px; line-height: 1.7; color: var(--ink); overflow-wrap: anywhere; }
.upcoming .day-event { flex-direction: row; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; }
.upcoming .day-event + .day-event { border-top: none; padding-top: 0; }
.event-book {
  align-self: flex-start;
  display: inline-flex; align-items: center; height: 26px; padding: 0 12px;
  border: 1px solid var(--line-strong); border-radius: var(--radius-pill);
  font-size: 11px; letter-spacing: 0.1em; color: var(--ink-dim);
  transition: color 0.25s, border-color 0.25s, background 0.25s;
}
.event-book:hover { color: var(--ink); border-color: var(--brand); }
.event-book.on { border-color: var(--brand); color: var(--brand); }
.event-book.on:hover { background: var(--brand); color: #141630; }
/* 窄屏: 无直播的日子收成一行; "今天"标签跟在日期后面, 不再压住右侧的状态文字 */
@media (max-width: 639px) {
  .day-card { min-height: 0; }
  .day-head { align-items: center; }
  .today-chip { position: static; border-radius: var(--radius-pill); padding: 2px 8px; }
  .day-card.rest, .day-card.tentative { flex-direction: row; align-items: center; justify-content: space-between; padding: 12px 16px; }
  .day-card.rest .day-head, .day-card.tentative .day-head { border-bottom: none; padding-bottom: 0; }
  .day-card.rest .day-status, .day-card.tentative .day-status { margin: 0; }
}

/* ---------- 弹窗(与外观面板同一套玻璃质感) ---------- */
.moon-dialog {
  margin: auto; padding: 0;
  width: min(440px, calc(100vw - 32px)); max-height: calc(100svh - 48px);
  border: 1px solid var(--line); border-radius: 16px;
  background: rgba(10, 10, 22, 0.94); color: var(--ink);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.45);
  overflow: auto;
}
.moon-dialog[open] { animation: menuIn var(--dur-2) var(--ease-out) both; }
.moon-dialog::backdrop { background: rgba(7, 7, 15, 0.62); backdrop-filter: blur(2px); }
.dlg-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px 16px; border-bottom: 1px solid var(--line);
  font-size: 12px; font-weight: 600; letter-spacing: 0.2em;
}
.dlg-close {
  font-size: 11px; letter-spacing: 0.1em; color: var(--ink-faint);
  border: 1px solid var(--line); border-radius: var(--radius-pill);
  padding: 3px 10px; transition: all 0.2s;
}
.dlg-close:hover { color: var(--brand); border-color: var(--brand); }
.dlg-body { padding: 16px; display: flex; flex-direction: column; gap: 12px; font-size: 13px; line-height: 1.9; color: var(--ink-dim); }
.dlg-body p { overflow-wrap: anywhere; }
.dlg-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; padding: 0 16px 16px; }
.dlg-actions .btn { height: 36px; padding: 0 16px; }

/* 上车报名人机验证(阿里云组件是浅色的: 与站点深色样式隔离, 避免白底白字; 图片弹层留在弹窗内, 保持原始尺寸) */
.captcha-confirm { display: flex; flex-direction: column; gap: 12px; }
.captcha-area { max-width: 100%; overflow-x: auto; color-scheme: light; color: #333; }
.captcha-area #aliyunCaptcha-window-float { position: relative; inset: auto; transform: none; margin: 12px 0 0; }
.captcha-area:empty, .captcha-status:empty { display: none; }
.captcha-reload { align-self: flex-start; height: 32px; padding: 0 14px; }
@media (max-width: 480px) {
  .captcha-area { max-width: none; margin-inline: -12px; }
}

/* ---------- 愿望单 ---------- */
.wish-table tbody tr { cursor: default; }
.wish-table td:last-child { white-space: nowrap; }
.wish-status {
  font-style: normal; font-size: 11px; letter-spacing: 0.1em; white-space: nowrap;
  border: 1px solid var(--line); border-radius: var(--radius-pill);
  padding: 2px 9px; color: var(--ink-faint);
}
.wish-status.s-considering { border-color: var(--line-strong); color: var(--ink-dim); }
.wish-status.s-learning { border-color: var(--brand); color: var(--brand); }
.wish-status.s-added { background: var(--brand); border-color: var(--brand); color: #141630; }
.wish-status.s-declined { color: var(--ink-faint); border-style: dashed; }
.wish-status.s-pending { border-color: var(--line); color: var(--ink-faint); }
.support-btn {
  display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px;
  border: 1px solid var(--line-strong); border-radius: var(--radius-pill);
  font-size: 11px; letter-spacing: 0.08em; color: var(--ink-dim); font-variant-numeric: tabular-nums;
  transition: color 0.2s, border-color 0.2s, transform 0.2s var(--ease-out);
}
.support-btn svg { width: 13px; height: 13px; }
.support-btn:hover:not(:disabled) { color: var(--brand); border-color: var(--brand); }
.support-btn:active:not(:disabled) { transform: scale(0.95); }
.support-btn.on { color: #ff6b9d; border-color: rgba(255, 107, 157, 0.6); }
.support-btn:disabled { opacity: 0.45; cursor: default; }
.support-cell { display: inline-flex; align-items: center; gap: 6px; }
/* "N 人支持" 平时是纯文本, 只在 hover 时出现下划线(整列更干净) */
.support-sep { color: var(--ink-faint); opacity: 0.55; font-size: 11px; }
.support-who {
  font-size: 11px; letter-spacing: 0.08em; color: var(--ink-faint); font-variant-numeric: tabular-nums;
  border-bottom: 1px solid transparent; padding: 2px 0; transition: color 0.2s, border-color 0.2s;
}
.support-who:hover:not(:disabled) { color: var(--brand); border-bottom-color: rgba(var(--brand-rgb), 0.55); }
.support-who:disabled { border-bottom-color: transparent; cursor: default; }
.supporter-list {
  list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px;
  max-height: 50vh; overflow-y: auto; margin-top: 10px;
}
.supporter-list li {
  display: flex; align-items: center; gap: 8px; min-width: 0;
  border: 1px solid var(--line); border-radius: 12px; padding: 6px 10px; font-size: 12.5px;
}
.supporter-list .who { display: flex; flex-direction: column; min-width: 0; }
.supporter-list .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.supporter-list .guard-line { font-size: 11px; letter-spacing: 0.04em; color: var(--ink-faint); white-space: nowrap; font-variant-numeric: tabular-nums; }
.supporter-list .guard-line b { font-weight: 600; }
.guard-line .lv3 { color: #ffcf8f; }
.guard-line .lv2 { color: #8fb7ff; }
.guard-line .lv1 { color: #d38fff; }
.supporter-list li small { font-size: 11px; color: var(--ink-faint); }
.supporter-list li.mine { border-color: var(--brand); }
.supporter-list .av { flex-shrink: 0; width: 28px; height: 28px; border-radius: 50%; object-fit: cover; }
details.info-card { display: block; }
details.info-card > * + * { margin-top: 10px; }
details.info-card > summary {
  cursor: pointer; list-style: none;
  display: flex; align-items: center; gap: 10px;
  font-size: 11px; font-weight: 600; letter-spacing: 0.34em; color: var(--brand); text-transform: uppercase;
}
details.info-card > summary::-webkit-details-marker { display: none; }
details.info-card > summary::after { content: "展开"; margin-left: auto; font-size: 11px; letter-spacing: 0.16em; color: var(--ink-faint); font-weight: 500; }
details.info-card[open] > summary::after { content: "收起"; }
details.info-card > summary b { color: var(--ink); letter-spacing: 0.1em; font-variant-numeric: tabular-nums; }
.wish-mine { margin-bottom: 14px; padding: 16px 20px; }
/* 许愿弹窗: 查重提示 */
.wish-dupes:empty { display: none; }
.wish-dupes { display: flex; flex-direction: column; gap: 8px; }
.dupe-group {
  border: 1px solid rgba(var(--brand-rgb), 0.45); border-radius: 12px; padding: 8px 12px;
  background: rgba(var(--brand-rgb), 0.06); font-size: 12.5px; line-height: 1.8; color: var(--ink);
}
.dupe-group b { color: var(--brand); font-weight: 600; margin-right: 2px; }
.dupe-group small { display: block; font-size: 11.5px; color: var(--ink-dim); }
.dupe-group small.dupe-count { display: inline; margin-left: 4px; color: var(--ink-faint); }
.view-body .sing-meta-row > .sort-pills:first-child { margin-left: 0; }
.mine-row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 8px 0; border-top: 1px solid var(--line);
  font-size: 13px; color: var(--ink-dim);
}
.mine-row b { color: var(--ink); font-weight: 600; }
@media (max-width: 639px) {
  .wish-table td.singer { display: inline-block; width: auto; padding-right: 10px; }
  .wish-table td.tags-cell { display: inline-block; width: auto; }
  .wish-table td:last-child { padding-top: 6px; }
}

/* ---------- 上车预约 ---------- */
.rules-card { margin-bottom: 14px; padding: 16px 20px; }
.rules-card > summary { flex-wrap: wrap; }
.rules-card > summary::after { content: "展开完整规则"; }
.rules-card[open] > summary::after { content: "收起"; }
.rules-brief {
  order: 2; flex-basis: 100%; margin: 4px 0 0; padding-left: 1.4em;
  font-size: 12.5px; font-weight: 400; letter-spacing: 0.04em; text-transform: none; line-height: 1.85; color: var(--ink-dim);
}
.rules-brief li::marker { color: var(--brand); }
.rules-card[open] .rules-brief { display: none; }
.rules-card ul { list-style: none; display: flex; flex-direction: column; gap: 4px; }
.rules-card li { font-size: 12.5px; line-height: 1.85; color: var(--ink-dim); }
.rules-card li b { color: var(--ink); font-weight: 600; }
.event-panel { margin-bottom: 14px; }
.event-panel > h2 a:hover { color: var(--ink); }
.batch-grid { display: grid; gap: 12px; }
@media (min-width: 720px) { .batch-grid { grid-template-columns: repeat(2, 1fr); } }
.batch-card {
  border: 1px solid var(--line); border-radius: 14px;
  background: rgba(255, 255, 255, 0.02);
  padding: 14px 16px 16px;
  display: flex; flex-direction: column; gap: 8px;
  transition: border-color 0.25s;
}
.batch-card.is-mine { border-color: var(--brand); background: rgba(var(--brand-rgb), 0.05); }
.batch-head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; }
.batch-head b { font-size: 15px; font-weight: 600; letter-spacing: 0.06em; margin-right: auto; font-variant-numeric: tabular-nums; }
.chip {
  font-style: normal; font-size: 11px; letter-spacing: 0.12em; white-space: nowrap;
  border: 1px solid var(--line); border-radius: var(--radius-pill); padding: 2px 9px; color: var(--ink-faint);
}
.chip.open { border-color: var(--brand); color: var(--brand); }
.chip.full { border-color: var(--line-strong); color: var(--ink-dim); }
.chip.guard { border-color: rgba(255, 196, 120, 0.6); color: #ffcf8f; }
.batch-stat { font-size: 11px; letter-spacing: 0.12em; color: var(--ink-faint); font-variant-numeric: tabular-nums; }
.roster, .info-card .roster { list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.seat {
  position: relative; width: 100%; min-height: 48px;
  display: flex; align-items: center; gap: 10px;
  border: 1px solid var(--line); border-radius: 12px;
  padding: 7px 10px; text-align: left; font-size: 12.5px; color: var(--ink);
  background: rgba(10, 10, 22, 0.3);
  transition: border-color 0.2s, background 0.2s, color 0.2s;
}
.seat .av { flex-shrink: 0; width: 28px; height: 28px; border-radius: 50%; object-fit: cover; border: 1px solid var(--line-strong); }
.seat-text { display: flex; flex-direction: column; min-width: 0; gap: 1px; }
.seat-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.seat small { font-size: 11px; letter-spacing: 0.06em; color: var(--ink-faint); }
.seat.waiting { border-style: dashed; background: none; color: var(--ink-dim); }
.seat.mine { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand) inset; }
.seat.mine .seat-hint { color: var(--brand); }
button.seat.mine:hover:not(:disabled) { border-color: #ff7a9c; box-shadow: 0 0 0 1px #ff7a9c inset; }
button.seat.mine:hover:not(:disabled) .seat-hint { color: #ff7a9c; }
.seat.add {
  border-style: dashed; border-color: var(--line-strong); color: var(--ink-dim); background: none;
}
.seat.add .plus {
  flex-shrink: 0; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center;
  border: 1px solid var(--line-strong); font-size: 16px; line-height: 1; color: var(--brand);
}
.seat.add:hover:not(:disabled) { border-color: var(--brand); color: var(--ink); background: rgba(var(--brand-rgb), 0.06); }
button.seat:disabled { cursor: default; opacity: 0.7; }
.seat-empty { grid-column: 1 / -1; padding: 6px 0; }
.check-pills button:disabled { opacity: 0.4; cursor: default; }
.check-pills button small { font-size: 11px; color: inherit; opacity: 0.7; font-variant-numeric: tabular-nums; }
/* 当前安排 / 排队状态 */
.pick-status {
  border: 1px solid var(--line); border-radius: 14px; padding: 10px 14px; margin: 10px 0;
  font-size: 13px; line-height: 1.8; color: var(--ink);
}
.pick-status b { color: var(--brand); font-variant-numeric: tabular-nums; }
.pick-status small { display: block; font-size: 11px; line-height: 1.8; color: var(--ink-faint); letter-spacing: 0.04em; }
.pick-status.ok { border-color: var(--brand); background: rgba(var(--brand-rgb), 0.05); }
.pick-status.wait { border-style: dashed; border-color: var(--line-strong); }
/* 志愿编辑: 有序列表 + 待选批次 */
.pick-editor {
  border: 1px dashed var(--line-strong); border-radius: 14px; padding: 12px 14px; margin-bottom: 12px;
  display: flex; flex-direction: column; gap: 8px;
}
.pick-editor h3, .waiting-card h3 { font-size: 13px; font-weight: 600; letter-spacing: 0.12em; }
.pick-list { list-style: none; display: flex; flex-direction: column; gap: 6px; }
.pick-list li {
  display: flex; align-items: center; gap: 10px; min-height: 40px;
  border: 1px solid var(--line); border-radius: 12px; padding: 4px 6px 4px 12px;
}
.pick-num { color: var(--brand); font-size: 15px; }
.pick-info { display: flex; align-items: baseline; gap: 10px; margin-right: auto; min-width: 0; }
.pick-time { font-size: 14px; font-weight: 600; letter-spacing: 0.06em; font-variant-numeric: tabular-nums; }
.pick-list small { font-size: 11px; letter-spacing: 0.06em; color: var(--ink-faint); font-variant-numeric: tabular-nums; }
.seat-count.is-full { color: #ffb08f; }
.check-pills button small.is-full { color: #ffb08f; opacity: 1; }
.pick-login { flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: space-between; }
.pick-login .btn { height: 36px; }
@media (max-width: 639px) {
  /* 手机: 时间和人数上下排, 给排序按钮留足点击面积 */
  .pick-info { flex-direction: column; gap: 0; }
  .pick-list li { padding: 6px 6px 6px 12px; }
  .pick-btn { width: 38px; height: 38px; font-size: 14px; }
  .pick-acts { gap: 6px; }
}
.pick-acts { display: flex; gap: 4px; }
.pick-btn {
  width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center;
  border: 1px solid var(--line); color: var(--ink-dim); font-size: 13px; line-height: 1;
  transition: border-color 0.2s, color 0.2s;
}
.pick-btn:hover:not(:disabled) { border-color: var(--brand); color: var(--ink); }
.pick-btn:disabled { opacity: 0.3; cursor: default; }
.pick-editor .form-actions { margin-top: 2px; }
.waiting-card { margin-top: 12px; display: flex; flex-direction: column; gap: 8px; }

/* ---------- 登录 / 个人中心 ---------- */
.auth-wrap { display: flex; justify-content: center; }
.auth-card { width: 100%; max-width: 30rem; }
.auth-card form { display: flex; flex-direction: column; gap: 14px; }
.auth-card form[hidden] { display: none; }
.field > .pw-wrap { position: relative; display: block; font-size: inherit; letter-spacing: normal; color: inherit; }
.pw-wrap input { padding-right: 64px; }
.pw-toggle {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  height: 28px; padding: 0 10px; border-radius: var(--radius-pill);
  font-size: 12px; letter-spacing: 0.08em; color: var(--ink-dim);
  transition: color 0.2s, background 0.2s;
}
.pw-toggle:hover { color: var(--brand); background: rgba(var(--brand-rgb), 0.1); }
@media (max-width: 639px) {
  .auth-card .form-actions .btn.primary { flex: 1 1 100%; height: 44px; }
}
.steps { padding-left: 1.3em; display: flex; flex-direction: column; gap: 12px; margin-top: 4px; }
.steps li { font-size: 13px; line-height: 1.8; color: var(--ink-dim); }
.steps li > span { display: block; margin-bottom: 6px; }
.code-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.code-box {
  display: inline-block; padding: 6px 16px 6px calc(16px + 0.4em);
  border: 1px dashed var(--line-strong); border-radius: 12px;
  font-size: 26px; font-weight: 700; letter-spacing: 0.4em; color: var(--brand);
  font-variant-numeric: tabular-nums; user-select: all;
}
.profile-row { display: flex; align-items: center; gap: 16px; }
.profile-row .avatar { object-fit: cover; }
.info-card .profile-name { color: var(--ink); font-size: 16px; font-weight: 600; letter-spacing: 0.06em; line-height: 1.6; }
.info-card .profile-sub { font-size: 11px; letter-spacing: 0.12em; color: var(--ink-faint); }
.inbox-item {
  border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px;
  display: flex; flex-direction: column; gap: 4px;
}
.inbox-item.unread { border-color: rgba(255, 122, 156, 0.45); }
.inbox-item p { color: var(--ink); }
.inbox-item .hint { color: var(--ink-faint); }
.inbox-kind { font-size: 11px; letter-spacing: 0.2em; color: var(--ink-faint); }
.inbox-item.unread .inbox-kind { color: #ff7a9c; }
.inbox-item .form-actions .btn { height: 32px; padding: 0 14px; font-size: 11px; }
.info-card .form-actions .btn { height: 34px; }
.booking-link {
  display: flex; flex-direction: column; gap: 2px;
  border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px;
  transition: border-color 0.2s, background 0.2s;
}
.booking-link:hover { border-color: var(--brand); background: rgba(var(--brand-rgb), 0.05); }
.booking-link b { font-size: 13px; font-weight: 600; }
.booking-link span { font-size: 11px; letter-spacing: 0.08em; color: var(--ink-faint); font-variant-numeric: tabular-nums; }
.booking-link.waiting { border-style: dashed; }
#acc-bookings, #acc-history, #acc-inbox { display: flex; flex-direction: column; gap: 8px; }
details.history summary { cursor: pointer; font-size: 11px; letter-spacing: 0.2em; color: var(--ink-faint); }
details.history[open] summary { margin-bottom: 8px; }

@media (prefers-reduced-motion: reduce) {
  .day-card, .moon-dialog[open] { animation: none !important; }
}
/* .info-card p 的优先级更高, 卡片内的提示文字单独压低 */
.info-card p.hint, .info-card .hint { font-size: 12px; line-height: 1.9; color: var(--ink-faint); }
.info-card p.muted, .info-card .muted { font-size: 12px; color: var(--ink-faint); }
