/* ==========================================================================
   回声 Echo · style.css
   纯静态、零外部依赖。目录：
   1 主题变量  2 基础重置  3 布局骨架  4 侧边导航  5 顶部栏 / Tab
   6 通用组件  7 发现页  8 歌单详情  9 搜索  10 我的
   11 播放条  12 全屏播放页  13 动画与响应式  14 无障碍降级
   ========================================================================== */

/* ==========================================================================
   1 主题变量
   ========================================================================== */

:root {
  /* 尺寸与节奏 */
  --sidebar-w: 236px;
  --content-max: 1120px;
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 18px;
  --r-xl: 24px;
  --ease: cubic-bezier(0.22, 0.72, 0.3, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  /* 字体：只用系统字体，零网络请求 */
  --font-sans: system-ui, -apple-system, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  /* 移动端底部安全区（刘海屏） */
  --safe-b: env(safe-area-inset-bottom, 0px);
}

/* 深色（默认） */
html[data-theme="dark"] {
  --bg: #0a0b0f;
  --bg-1: #101218;
  --bg-2: #171a22;
  --bg-3: #232733;
  --bg-blur: rgba(16, 18, 24, 0.78);
  --text: #f4f5f8;
  --text-2: #a7adbd;
  --text-3: #737988;
  --line: rgba(255, 255, 255, 0.07);
  --line-2: rgba(255, 255, 255, 0.16);
  --accent: #8b7cf6;
  --accent-ink: #ffffff;
  --accent-soft: rgba(139, 124, 246, 0.16);
  --play-bg: #f4f5f8;
  --play-fg: #0a0b0f;
  --shadow-1: 0 10px 30px rgba(0, 0, 0, 0.42);
  --shadow-2: 0 18px 60px rgba(0, 0, 0, 0.55);
  --cover-a: #3b3560;
  --cover-b: #14131f;
  color-scheme: dark;
}

/* 浅色 */
html[data-theme="light"] {
  --bg: #f5f6fa;
  --bg-1: #ffffff;
  --bg-2: #eff0f5;
  --bg-3: #e4e6ee;
  --bg-blur: rgba(255, 255, 255, 0.82);
  --text: #13151b;
  --text-2: #585f70;
  --text-3: #8a90a0;
  --line: rgba(16, 18, 24, 0.08);
  --line-2: rgba(16, 18, 24, 0.16);
  --accent: #5b4bd6;
  --accent-ink: #ffffff;
  --accent-soft: rgba(91, 75, 214, 0.12);
  --play-bg: #13151b;
  --play-fg: #ffffff;
  --shadow-1: 0 8px 24px rgba(23, 26, 40, 0.1);
  --shadow-2: 0 20px 60px rgba(23, 26, 40, 0.16);
  --cover-a: #cfc9f3;
  --cover-b: #ece9fb;
  color-scheme: light;
}

/* ==========================================================================
   2 基础重置
   ========================================================================== */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

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

body {
  margin: 0;
  height: 100vh;
  height: 100dvh;
  overflow: hidden; /* 页面级不滚动，滚动只发生在 main 内部 */
  display: flex;
  flex-direction: column;
  min-height: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
  transition: background-color 0.24s linear, color 0.24s linear;
}

h1,
h2,
h3,
p,
ol,
ul,
figure {
  margin: 0;
  padding: 0;
}

ol,
ul {
  list-style: none;
}

img {
  display: block;
  max-width: 100%;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  text-align: inherit;
  -webkit-appearance: none;
  appearance: none;
}

input {
  font: inherit;
  color: inherit;
}

[hidden] {
  display: none !important;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 6px;
}

/* 滚动条（桌面） */
.views::-webkit-scrollbar,
.sheet__lyric::-webkit-scrollbar {
  width: 10px;
}

.views::-webkit-scrollbar-thumb,
.sheet__lyric::-webkit-scrollbar-thumb {
  background: var(--bg-3);
  border: 3px solid transparent;
  background-clip: content-box;
  border-radius: 8px;
}

.views::-webkit-scrollbar-track {
  background: transparent;
}

.icon {
  display: block;
  flex: 0 0 auto;
  pointer-events: none;
}

.icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

/* 跳转链接：键盘用户可见 */
.skip-link {
  position: absolute;
  left: 8px;
  top: -48px;
  z-index: 200;
  padding: 10px 14px;
  background: var(--accent);
  color: var(--accent-ink);
  border-radius: var(--r-sm);
  font-size: 13px;
  transition: top 0.16s var(--ease);
}

.skip-link:focus {
  top: 8px;
}

.noscript {
  margin: 12px;
  padding: 12px 16px;
  border-radius: var(--r-md);
  background: var(--bg-2);
  color: var(--text-2);
  font-size: 13px;
}

/* ==========================================================================
   3 布局骨架
   ========================================================================== */

.app {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  overflow: hidden;
}

.stage {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.views {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: var(--bg-3) transparent;
}

.view {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 28px 32px 56px;
  animation: viewIn 0.26s var(--ease-out) both;
}

@keyframes viewIn {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

/* ==========================================================================
   4 侧边导航（桌面）
   ========================================================================== */

.sidebar {
  display: none;
  flex: 0 0 var(--sidebar-w);
  width: var(--sidebar-w);
  flex-direction: column;
  gap: 20px;
  padding: 20px 14px 16px;
  border-right: 1px solid var(--line);
  background: var(--bg-1);
  overflow: hidden;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 8px 2px;
}

.brand__mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 11px;
  background: var(--accent);
  color: var(--accent-ink);
  box-shadow: 0 6px 16px var(--accent-soft);
}

.brand__text strong {
  display: block;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.04em;
}

.brand__text small {
  display: block;
  font-size: 10px;
  color: var(--text-3);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav__item {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 0 10px;
  border-radius: var(--r-md);
  color: var(--text-2);
  font-size: 13.5px;
  transition: background-color 0.16s linear, color 0.16s linear;
}

.nav__item:hover {
  background: var(--bg-2);
  color: var(--text);
}

.nav__item:active {
  transform: scale(0.99);
}

.nav__item.is-active {
  color: var(--accent);
  background: var(--accent-soft);
  font-weight: 500;
}

.sidebar__group {
  min-height: 0;
  flex: 1 1 auto;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.sidebar__label {
  padding: 8px 10px 4px;
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--text-3);
}

.sidelist {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.sidelist__item {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 0 8px;
  border-radius: var(--r-md);
  cursor: pointer;
  transition: background-color 0.16s linear;
}

.sidelist__item:hover {
  background: var(--bg-2);
}

.sidelist__item.is-active {
  background: var(--bg-2);
}

.sidelist__thumb {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  border-radius: 8px;
  background: linear-gradient(140deg, var(--cover-a), var(--cover-b));
  color: var(--text);
  font-size: 12px;
  overflow: hidden;
}

.sidelist__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.sidelist__name {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 13px;
  color: var(--text-2);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sidelist__count {
  flex: 0 0 auto;
  font-size: 11px;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
}

.sidebar__foot {
  flex: 0 0 auto;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}

.themebtn {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-height: 44px;
  padding: 0 10px;
  border-radius: var(--r-md);
  color: var(--text-2);
  font-size: 12.5px;
  transition: background-color 0.16s linear, color 0.16s linear;
}

.themebtn:hover {
  background: var(--bg-2);
  color: var(--text);
}

.themebtn__moon {
  display: none;
}

html[data-theme="light"] .themebtn__sun {
  display: none;
}

html[data-theme="light"] .themebtn__moon {
  display: block;
}

.themebtn__text {
  flex: 1 1 auto;
}

.themebtn__track {
  position: relative;
  width: 34px;
  height: 20px;
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--bg-3);
  transition: background-color 0.2s linear;
}

.themebtn__knob {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--text);
  transition: transform 0.22s var(--ease), background-color 0.2s linear;
}

html[data-theme="light"] .themebtn__track {
  background: var(--accent);
}

html[data-theme="light"] .themebtn__knob {
  transform: translateX(14px);
  background: #fff;
}

/* ==========================================================================
   5 顶部栏 / 底部 Tab（移动）
   ========================================================================== */

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex: 0 0 auto;
  height: 54px;
  padding: 0 8px 0 16px;
  background: var(--bg);
}

.topbar__title {
  font-size: 17px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.topbar__actions {
  display: flex;
  align-items: center;
  gap: 2px;
}

html[data-theme="light"] #themeToggleMobile .icon {
  transform: rotate(0deg);
}

.tabbar {
  display: flex;
  flex: 0 0 auto;
  padding-bottom: var(--safe-b);
  background: var(--bg-1);
  border-top: 1px solid var(--line);
}

.tabbar__item {
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-height: 50px;
  padding: 6px 0 4px;
  color: var(--text-3);
  font-size: 10.5px;
  transition: color 0.16s linear;
}

.tabbar__item.is-active {
  color: var(--accent);
}

.tabbar__item:active {
  opacity: 0.7;
}

/* ==========================================================================
   6 通用组件
   ========================================================================== */

/* 图标按钮 */
.iconbtn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
  border-radius: 50%;
  color: var(--text-2);
  transition: background-color 0.16s linear, color 0.16s linear,
    transform 0.12s var(--ease);
}

.iconbtn:hover {
  background: var(--bg-2);
  color: var(--text);
}

.iconbtn:active {
  transform: scale(0.92);
}

.iconbtn--sm {
  width: 38px;
  height: 38px;
}

/* 爱心图标：默认线框，收藏后切换为实心（全局统一，含播放条 / 全屏页 / 列表） */
.icon--fill {
  display: none;
}

.is-liked .icon--line {
  display: none;
}

.is-liked .icon--fill {
  display: block;
}

/* 播放模式「单曲循环」角标 */
.iconbtn.is-one::after {
  content: "1";
  position: absolute;
  right: 6px;
  top: 4px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 9px;
  line-height: 13px;
  text-align: center;
  font-weight: 500;
}

/* 主播放圆钮 */
.playbtn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--play-bg);
  color: var(--play-fg);
  transition: transform 0.14s var(--ease), opacity 0.16s linear;
}

.playbtn:hover {
  transform: scale(1.06);
}

.playbtn:active {
  transform: scale(0.94);
}

.playbtn__pause {
  display: none;
}

.playbtn.is-playing .playbtn__play {
  display: none;
}

.playbtn.is-playing .playbtn__pause {
  display: block;
}

.playbtn__spinner {
  display: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid currentColor;
  border-top-color: transparent;
  animation: spin 0.8s linear infinite;
}

.playbtn.is-loading .playbtn__play,
.playbtn.is-loading .playbtn__pause {
  display: none;
}

.playbtn.is-loading .playbtn__spinner {
  display: block;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* 按钮 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
  transition: transform 0.12s var(--ease), opacity 0.16s linear,
    background-color 0.16s linear, border-color 0.16s linear;
}

.btn:active {
  transform: scale(0.97);
}

.btn--primary {
  background: var(--accent);
  color: var(--accent-ink);
  box-shadow: 0 8px 20px var(--accent-soft);
}

.btn--primary:hover {
  filter: brightness(1.08);
}

.btn--ghost {
  border: 1px solid var(--line-2);
  color: var(--text);
}

.btn--ghost:hover {
  background: var(--bg-2);
  border-color: var(--text-3);
}

.btn.is-liked {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-soft);
}

.btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* 分类胶囊 */
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--bg-1);
  color: var(--text-2);
  font-size: 12.5px;
  transition: background-color 0.16s linear, color 0.16s linear,
    border-color 0.16s linear, transform 0.12s var(--ease);
}

.chip:hover {
  color: var(--text);
  border-color: var(--line-2);
  background: var(--bg-2);
}

.chip:active {
  transform: scale(0.96);
}

.chip.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
  font-weight: 500;
}

/* 区块标题 */
.section {
  margin-top: 34px;
}

.section__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.section__head--page {
  align-items: flex-start;
  margin-bottom: 4px;
}

.section__title {
  font-size: 17px;
  font-weight: 500;
  letter-spacing: 0.01em;
}

.section__title--sm {
  font-size: 14.5px;
}

.section__sub {
  margin-top: 3px;
  font-size: 11.5px;
  color: var(--text-3);
}

.section__count {
  font-size: 11.5px;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
}

.section__more {
  flex: 0 0 auto;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--text-2);
  font-size: 12px;
  transition: color 0.16s linear, border-color 0.16s linear,
    background-color 0.16s linear;
}

.section__more:hover {
  color: var(--text);
  border-color: var(--line-2);
  background: var(--bg-2);
}

/* 封面容器：无图时显示文字占位，有图时显示 img */
.cover__glyph {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  background: linear-gradient(140deg, var(--cover-a), var(--cover-b));
  color: var(--text);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.04em;
}

.cover__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  animation: fadeIn 0.32s var(--ease-out) both;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* 卡片 */
.card {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  padding: 8px;
  border-radius: var(--r-md);
  transition: background-color 0.18s linear, transform 0.16s var(--ease);
}

.card:hover {
  background: var(--bg-2);
}

.card:active {
  transform: scale(0.985);
}

.card__cover {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 10px;
  overflow: hidden;
  background: var(--bg-3);
  margin-bottom: 7px;
}

.card__play {
  position: absolute;
  right: 7px;
  bottom: 7px;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-ink);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.34);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.18s linear, transform 0.2s var(--ease);
}

.card:hover .card__play,
.card:focus-visible .card__play {
  opacity: 1;
  transform: none;
}

.card__title {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card__artist {
  font-size: 11.5px;
  color: var(--text-3);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card.is-current .card__title {
  color: var(--accent);
}

/* 空状态 */
.empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
  padding: 44px 16px 32px;
  color: var(--text-2);
}

.empty--inline {
  padding: 22px 12px;
  border: 1px dashed var(--line-2);
  border-radius: var(--r-md);
  margin-top: 8px;
}

.empty__art {
  color: var(--text-3);
  margin-bottom: 8px;
  opacity: 0.9;
}

.empty__title {
  font-size: 14.5px;
  font-weight: 500;
  color: var(--text);
}

.empty__desc {
  font-size: 12.5px;
  color: var(--text-3);
  max-width: 34ch;
  line-height: 1.65;
}

.empty__label {
  margin-top: 16px;
  font-size: 11.5px;
  color: var(--text-3);
  letter-spacing: 0.04em;
}

/* 轻提示 */
.toasts {
  position: fixed;
  left: 50%;
  bottom: calc(96px + var(--safe-b));
  z-index: 120;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  transform: translateX(-50%);
  pointer-events: none;
  width: max-content;
  max-width: 88vw;
}

.toast {
  padding: 9px 16px;
  border-radius: 999px;
  background: rgba(20, 22, 30, 0.94);
  color: #f4f5f8;
  font-size: 12.5px;
  box-shadow: var(--shadow-1);
  animation: toastIn 0.24s var(--ease-out) both;
  max-width: 88vw;
  text-align: center;
}

.toast.is-out {
  animation: toastOut 0.2s linear both;
}

@keyframes toastIn {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes toastOut {
  to {
    opacity: 0;
    transform: translateY(-6px);
  }
}

/* ==========================================================================
   7 发现页
   ========================================================================== */

.hero {
  position: relative;
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
  gap: 22px;
  align-items: center;
  padding: 20px;
  border-radius: var(--r-xl);
  border: 1px solid var(--line);
  background: var(--bg-1);
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: -40% 40% 30% -10%;
  background: radial-gradient(
    circle at 30% 40%,
    var(--accent-soft),
    transparent 68%
  );
  pointer-events: none;
}

.hero__media {
  position: relative;
  aspect-ratio: 1 / 1;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--bg-3);
  box-shadow: var(--shadow-1);
}

.hero__body {
  position: relative;
  min-width: 0;
}

.hero__tag {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 10.5px;
  letter-spacing: 0.04em;
}

.hero__title {
  margin-top: 10px;
  font-size: 26px;
  font-weight: 500;
  letter-spacing: -0.01em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hero__desc {
  margin-top: 8px;
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--text-2);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.hero__dots {
  display: flex;
  gap: 6px;
  margin-top: 16px;
}

.hero__dot {
  width: 20px;
  height: 4px;
  border-radius: 2px;
  background: var(--line-2);
  transition: background-color 0.2s linear, width 0.24s var(--ease);
}

.hero__dot.is-active {
  width: 30px;
  background: var(--accent);
}

/* 横向卡片轨道 */
.rail {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x proximity;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 2px 2px 6px;
  margin: 0 -2px;
}

.rail::-webkit-scrollbar {
  display: none;
}

.rail > * {
  flex: 0 0 clamp(132px, 19vw, 164px);
  scroll-snap-align: start;
}

/* 排行榜 */
.ranks {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.rank {
  padding: 14px;
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  background: var(--bg-1);
  min-width: 0;
}

.rank__head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.rank__badge {
  padding: 2px 7px;
  border-radius: 6px;
  font-size: 9.5px;
  font-weight: 500;
  letter-spacing: 0.08em;
}

.rank__badge--new {
  background: rgba(239, 159, 39, 0.16);
  color: #ef9f27;
}

.rank__badge--hot {
  background: rgba(226, 75, 74, 0.16);
  color: #e24b4a;
}

.rank__title {
  flex: 1 1 auto;
  font-size: 14px;
  font-weight: 500;
}

.rank__all {
  flex: 0 0 auto;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--text-3);
  font-size: 11.5px;
  transition: color 0.16s linear, border-color 0.16s linear;
}

.rank__all:hover {
  color: var(--text);
  border-color: var(--line-2);
}

.rank__list {
  display: flex;
  flex-direction: column;
}

.rank__item {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 6px;
  border-radius: var(--r-sm);
  cursor: pointer;
  transition: background-color 0.16s linear;
}

.rank__item:hover {
  background: var(--bg-2);
}

.rank__item.is-current {
  background: var(--accent-soft);
}

.rank__no {
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  color: var(--text-3);
  text-align: center;
}

.rank__item:nth-child(1) .rank__no {
  color: var(--accent);
  font-weight: 500;
}

.rank__item.is-current .rank__no {
  color: var(--accent);
}

.rank__info {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.rank__name {
  font-size: 13px;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank__by {
  font-size: 11px;
  color: var(--text-3);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank__item.is-current .rank__name {
  color: var(--accent);
}

.rank__dur {
  font-size: 11px;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
}

/* 分类结果网格 */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(132px, 1fr));
  gap: 6px;
  margin-top: 14px;
}

/* ==========================================================================
   8 歌单详情
   ========================================================================== */

.plhead {
  position: relative;
  display: grid;
  grid-template-columns: 208px minmax(0, 1fr);
  gap: 24px;
  align-items: end;
  padding: 8px 0 22px;
  border-bottom: 1px solid var(--line);
}

.plhead__back {
  position: absolute;
  top: -4px;
  left: -12px;
}

.plhead__cover {
  aspect-ratio: 1 / 1;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--bg-3);
  box-shadow: var(--shadow-2);
}

.plhead__body {
  min-width: 0;
  padding-bottom: 4px;
}

.plhead__badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 5px;
  border: 1px solid var(--line-2);
  font-size: 10.5px;
  color: var(--text-2);
}

.plhead__title {
  margin-top: 10px;
  font-size: 30px;
  line-height: 1.2;
  font-weight: 500;
  letter-spacing: -0.02em;
  overflow-wrap: break-word;
}

.plhead__desc {
  margin-top: 10px;
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--text-2);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.plhead__meta {
  margin-top: 10px;
  font-size: 11.5px;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
}

.plhead__meta .dot {
  margin: 0 6px;
}

.plhead__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

/* 歌曲列表 */
.tracklist {
  margin-top: 14px;
}

.tracklist__head,
.track {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) minmax(0, 0.8fr) 60px 46px;
  align-items: center;
  gap: 12px;
}

.tracklist__head {
  min-height: 34px;
  padding: 0 8px;
  border-bottom: 1px solid var(--line);
  font-size: 11px;
  color: var(--text-3);
  letter-spacing: 0.04em;
}

.tracks {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-top: 6px;
}

.track {
  min-height: 56px;
  padding: 0 8px;
  border-radius: var(--r-sm);
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  transition: background-color 0.16s linear;
}

.track:last-child {
  border-bottom: 0;
}

.track:hover {
  background: var(--bg-2);
}

.track.is-current {
  background: var(--accent-soft);
}

.track.is-current .track__name {
  color: var(--accent);
}

.tcol {
  min-width: 0;
  display: flex;
  align-items: center;
  font-size: 12.5px;
  color: var(--text-2);
}

.tcol--no {
  font-variant-numeric: tabular-nums;
  color: var(--text-3);
  justify-content: flex-start;
}

.tcol--title {
  gap: 10px;
  overflow: hidden;
}

.tcol--artist {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--text-2);
}

.tcol--dur {
  font-variant-numeric: tabular-nums;
  color: var(--text-3);
  font-size: 11.5px;
}

.tcol--like {
  justify-content: flex-end;
}

.track__cover {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 7px;
  overflow: hidden;
  background: var(--bg-3);
}

.track__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 1px;
}

.track__name {
  font-size: 13.5px;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.track__sub {
  font-size: 11px;
  color: var(--text-3);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tracks--search .track {
  grid-template-columns: 36px minmax(0, 1fr) 60px 46px;
}

.tracks--search .tcol--artist {
  display: none;
}

/* 收藏爱心 */
.likebtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: var(--text-3);
  transition: color 0.16s linear, background-color 0.16s linear,
    transform 0.12s var(--ease);
}

.likebtn:hover {
  background: var(--bg-3);
  color: var(--text);
}

.likebtn:active {
  transform: scale(0.88);
}

.likebtn.is-liked {
  color: var(--accent);
}

.likebtn.is-liked .icon use {
  color: inherit;
}

.likebtn .icon--fill {
  display: none;
}

.likebtn.is-liked .icon--line {
  display: none;
}

.likebtn.is-liked .icon--fill {
  display: block;
}

/* ==========================================================================
   9 搜索
   ========================================================================== */

.searchbox {
  position: sticky;
  top: 0;
  z-index: 8;
  display: flex;
  align-items: center;
  gap: 8px;
  margin: -8px -4px 12px;
  padding: 10px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--bg-blur);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  transition: border-color 0.16s linear, box-shadow 0.16s linear;
}

.searchbox:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}

.searchbox__icon {
  color: var(--text-3);
}

.searchbox__input {
  flex: 1 1 auto;
  min-width: 0;
  height: 34px;
  border: 0;
  background: none;
  outline: none;
  font-size: 14px;
  color: var(--text);
}

.searchbox__input::placeholder {
  color: var(--text-3);
}

.searchbox__input::-webkit-search-cancel-button {
  -webkit-appearance: none;
  appearance: none;
}

.search-idle {
  padding: 8px 2px;
}

.search-idle__label {
  margin-bottom: 10px;
  font-size: 11.5px;
  color: var(--text-3);
  letter-spacing: 0.04em;
}

.search-result {
  padding-top: 4px;
}

.search-result__count {
  padding: 0 8px 8px;
  font-size: 11.5px;
  color: var(--text-3);
}

.search-result__count b {
  font-weight: 500;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.search-result__count em {
  font-style: normal;
  color: var(--text-2);
}

/* 空结果里的推荐 */
.recos {
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 100%;
  max-width: 420px;
  margin-top: 4px;
  text-align: left;
}

.reco {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) 40px;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 8px;
  border-radius: var(--r-sm);
  border: 1px solid var(--line);
  background: var(--bg-1);
  cursor: pointer;
  transition: background-color 0.16s linear, border-color 0.16s linear;
}

.reco:hover {
  background: var(--bg-2);
  border-color: var(--line-2);
}

.reco__cover {
  width: 36px;
  height: 36px;
  border-radius: 6px;
  overflow: hidden;
  background: var(--bg-3);
}

/* ==========================================================================
   10 我的
   ========================================================================== */

.statrow {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.stat {
  padding: 12px 14px;
  border-radius: var(--r-md);
  background: var(--bg-1);
  border: 1px solid var(--line);
}

.stat__num {
  font-size: 20px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

.stat__label {
  margin-top: 2px;
  font-size: 11px;
  color: var(--text-3);
}

/* ==========================================================================
   11 播放条
   ========================================================================== */

.player {
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr) minmax(0, 0.9fr);
  align-items: center;
  gap: 18px;
  padding: 10px 20px;
  background: var(--bg-1);
  border-top: 1px solid var(--line);
  transition: background-color 0.24s linear;
}

.player__now {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  cursor: pointer;
}

.player__cover {
  position: relative;
  flex: 0 0 auto;
  width: 52px;
  height: 52px;
  border-radius: 10px;
  overflow: hidden;
  background: var(--bg-3);
  transition: transform 0.16s var(--ease);
}

.player__cover:hover {
  transform: scale(1.03);
}

.player__cover-hint {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0.42);
  color: #fff;
  opacity: 0;
  transition: opacity 0.16s linear;
}

.player__cover:hover .player__cover-hint,
.player__cover:focus-visible .player__cover-hint {
  opacity: 1;
}

.player__meta {
  min-width: 0;
  flex: 1 1 auto;
}

.player__title {
  font-size: 13px;
  font-weight: 500;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.player__artist {
  margin-top: 2px;
  font-size: 11.5px;
  color: var(--text-3);
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

/* 跑马灯：只有超长才滚（由 JS 判定后加 is-overflow） */
.marquee {
  display: inline-block;
  white-space: nowrap;
  will-change: transform;
}

.marquee.is-overflow {
  animation: marqueeScroll var(--marquee-dur, 12s) linear infinite;
}

.marquee.is-overflow:hover {
  animation-play-state: paused;
}

@keyframes marqueeScroll {
  0%,
  10% {
    transform: translateX(0);
  }
  45%,
  55% {
    transform: translateX(var(--marquee-shift, 0));
  }
  90%,
  100% {
    transform: translateX(0);
  }
}

.player__like .icon--fill,
.player__like.is-liked .icon--line {
  display: none;
}

.player__like.is-liked .icon--fill {
  display: block;
}

.player__like.is-liked {
  color: var(--accent);
}

.player__main {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-width: 0;
}

.player__controls {
  display: flex;
  align-items: center;
  gap: 4px;
}

.progress {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-width: 0;
}

.progress__time {
  flex: 0 0 auto;
  min-width: 38px;
  font-size: 10.5px;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
  text-align: center;
}

.progress__track {
  position: relative;
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  height: 20px;
  min-width: 40px;
  cursor: pointer;
  touch-action: none;
}

.progress__track::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 4px;
  border-radius: 2px;
  background: var(--bg-3);
}

.progress__buffer {
  position: absolute;
  left: 0;
  width: 0;
  height: 4px;
  border-radius: 2px;
  background: var(--line-2);
  transition: width 0.2s linear;
}

.progress__fill {
  position: absolute;
  left: 0;
  width: 0;
  height: 4px;
  border-radius: 2px;
  background: var(--accent);
}

.progress__thumb {
  position: absolute;
  left: 0;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.45);
  transform: translateX(-50%) scale(0.6);
  opacity: 0;
  transition: opacity 0.16s linear, transform 0.16s var(--ease);
}

.progress__track:hover .progress__thumb,
.progress__track:focus-visible .progress__thumb,
.progress__track.is-dragging .progress__thumb {
  opacity: 1;
  transform: translateX(-50%) scale(1);
}

.progress__track.is-dragging .progress__fill {
  background: var(--accent);
}

.progress--sheet {
  gap: 12px;
}

.progress--sheet .progress__time {
  min-width: 40px;
  font-size: 11px;
}

.progress--sheet .progress__track {
  height: 26px;
}

.progress--sheet .progress__track::before,
.progress--sheet .progress__fill,
.progress--sheet .progress__buffer {
  height: 5px;
  border-radius: 3px;
}

.progress--sheet .progress__thumb {
  width: 14px;
  height: 14px;
}

.player__extra {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

.volume {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-3);
}

.volume__track {
  position: relative;
  display: flex;
  align-items: center;
  width: 84px;
  height: 20px;
  cursor: pointer;
  touch-action: none;
}

.volume__track::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 3px;
  border-radius: 2px;
  background: var(--bg-3);
}

.volume__fill {
  position: absolute;
  left: 0;
  width: 80%;
  height: 3px;
  border-radius: 2px;
  background: var(--text-2);
}

.volume:hover .volume__fill {
  background: var(--accent);
}

/* ==========================================================================
   12 全屏播放页
   ========================================================================== */

.sheet {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  transform: translateY(100%);
  visibility: hidden;
  transition: transform 0.36s var(--ease-out), visibility 0.36s linear;
  will-change: transform;
  overscroll-behavior: contain;
}

.sheet.is-open {
  transform: translateY(0);
  visibility: visible;
}

.sheet.is-dragging {
  transition: none;
}

.sheet__backdrop {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.5;
  background: radial-gradient(
    120% 60% at 50% 0%,
    var(--accent-soft),
    transparent 70%
  );
}

.sheet__grabber {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 22px;
  flex: 0 0 auto;
  cursor: grab;
  touch-action: none;
}

.sheet__grabber span {
  width: 34px;
  height: 4px;
  border-radius: 2px;
  background: var(--line-2);
}

.sheet__head {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex: 0 0 auto;
  padding: 2px 10px 6px;
}

.sheet__eyebrow {
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--text-3);
  text-transform: uppercase;
}

.sheet__body {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  padding: 0 24px calc(14px + var(--safe-b));
  gap: 12px;
  overflow: hidden;
}

.sheet__coverwrap {
  flex: 0 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
  padding: 6px 0 2px;
}

.sheet__cover {
  position: relative;
  width: min(62vw, 268px);
  height: min(62vw, 268px);
  border-radius: 50%;
  overflow: hidden;
  background: var(--bg-3);
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.45);
  animation: spin 26s linear infinite;
  animation-play-state: paused;
}

.sheet.is-playing .sheet__cover {
  animation-play-state: running;
}

.sheet__cover .cover__glyph {
  border-radius: 50%;
  font-size: 44px;
}

.sheet__cover-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.14),
    inset 0 0 26px rgba(0, 0, 0, 0.32);
}

/* 唱片中心孔 */
.sheet__cover-ring::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 16px;
  height: 16px;
  margin: -8px 0 0 -8px;
  border-radius: 50%;
  background: var(--bg);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.sheet__meta {
  flex: 0 0 auto;
  text-align: center;
  padding: 0 4px;
}

.sheet__title {
  font-size: 19px;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sheet__artist {
  margin-top: 4px;
  font-size: 12.5px;
  color: var(--text-3);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sheet__lyric {
  flex: 1 1 auto;
  min-height: 64px;
  overflow-y: auto;
  overflow-x: hidden;
  text-align: center;
  padding: 10px 0;
  scrollbar-width: none;
  mask-image: linear-gradient(
    to bottom,
    transparent,
    #000 14%,
    #000 86%,
    transparent
  );
  -webkit-mask-image: linear-gradient(
    to bottom,
    transparent,
    #000 14%,
    #000 86%,
    transparent
  );
}

.sheet__lyric::-webkit-scrollbar {
  display: none;
}

.lyric__line {
  padding: 7px 4px;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--text-3);
  transition: color 0.24s linear, transform 0.24s var(--ease),
    font-size 0.24s var(--ease);
}

.lyric__line.is-active {
  color: var(--text);
  font-weight: 500;
  transform: scale(1.045);
}

.lyric__empty {
  color: var(--text-3);
  font-size: 12.5px;
  padding: 18px 0;
}

.sheet__progress {
  flex: 0 0 auto;
}

.sheet__controls {
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  align-items: center;
  justify-items: center;
  gap: 4px;
  padding: 2px 0 6px;
}

.playbtn--lg {
  width: 60px;
  height: 60px;
}

/* ==========================================================================
   13 动画与响应式
   ========================================================================== */

/* 桌面：显示侧栏，隐藏移动端元素 */
@media (min-width: 768px) {
  .sidebar {
    display: flex;
  }

  .topbar,
  .tabbar {
    display: none;
  }

  .player {
    padding-bottom: max(10px, env(safe-area-inset-bottom));
  }
}

/* 移动端 */
@media (max-width: 767px) {
  .view {
    padding: 12px 14px 24px;
  }

  /* 播放条变成悬浮迷你条：flex 子项，不 fixed */
  .player {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    margin: 0 10px 8px;
    padding: 8px 10px 8px 8px;
    border: 1px solid var(--line);
    border-radius: 16px;
    box-shadow: var(--shadow-1);
    background: var(--bg-1);
  }

  .player__cover {
    width: 44px;
    height: 44px;
    border-radius: 9px;
  }

  .player__cover-hint {
    display: none;
  }

  .player__main {
    flex: 0 0 auto;
    flex-direction: row;
  }

  .player__controls {
    gap: 0;
  }

  /* 迷你条只保留播放键 */
  .player__controls > .iconbtn {
    display: none;
  }

  .player__main .progress {
    display: none;
  }

  .player__extra,
  .player__like {
    display: none;
  }

  .playbtn {
    width: 44px;
    height: 44px;
  }

  .player__title {
    font-size: 13px;
  }

  /* 首页 */
  .hero {
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 14px;
    padding: 12px;
    border-radius: var(--r-lg);
  }

  .hero__media {
    border-radius: 12px;
  }

  .hero__title {
    margin-top: 6px;
    font-size: 18px;
  }

  .hero__desc {
    margin-top: 5px;
    font-size: 11.5px;
    -webkit-line-clamp: 2;
  }

  .hero__tag {
    font-size: 9.5px;
    padding: 2px 7px;
  }

  .hero__actions {
    gap: 8px;
    margin-top: 10px;
  }

  .hero__actions .btn {
    min-height: 36px;
    padding: 0 13px;
    font-size: 12px;
  }

  .hero__dots {
    margin-top: 10px;
  }

  .section {
    margin-top: 24px;
  }

  .section__title {
    font-size: 15.5px;
  }

  /* 排行榜单列堆叠 */
  .ranks {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }

  .rank {
    padding: 10px 10px 6px;
  }

  .rail {
    margin: 0 -14px;
    padding: 2px 14px 6px;
  }

  .rail > * {
    flex-basis: 112px;
  }

  .card {
    padding: 6px;
  }

  .card__play {
    opacity: 1;
    transform: none;
    width: 28px;
    height: 28px;
  }

  .grid {
    grid-template-columns: repeat(auto-fill, minmax(104px, 1fr));
    gap: 4px;
  }

  /* 歌单详情 */
  .plhead {
    grid-template-columns: 104px minmax(0, 1fr);
    gap: 14px;
    padding-top: 4px;
    align-items: end;
  }

  /* 返回键在移动端回到文档流，避免浮在标题上方 */
  .plhead__back {
    position: static;
    grid-column: 1 / -1;
    justify-self: start;
    margin-left: -8px;
  }

  .plhead__cover {
    border-radius: var(--r-md);
  }

  .plhead__title {
    margin-top: 6px;
    font-size: 19px;
    white-space: normal;
  }

  .plhead__desc {
    margin-top: 6px;
    font-size: 11.5px;
    -webkit-line-clamp: 2;
  }

  .plhead__meta {
    margin-top: 6px;
    font-size: 11px;
  }

  .plhead__actions {
    grid-column: 1 / -1;
    margin-top: 4px;
  }

  .plhead__actions .btn {
    flex: 1 1 auto;
    min-height: 42px;
  }

  /* 列表：隐藏歌手列，标题行塞下专辑·歌手 */
  .tracklist__head {
    display: none;
  }

  .track {
    grid-template-columns: 26px minmax(0, 1fr) 44px 40px;
    gap: 8px;
    min-height: 58px;
    padding: 0 4px;
  }

  .track .tcol--artist {
    display: none;
  }

  .track__cover {
    width: 42px;
    height: 42px;
  }

  .track__sub {
    display: block;
  }

  .tracks--search .track {
    grid-template-columns: 26px minmax(0, 1fr) 44px 40px;
  }

  .tcol--dur {
    justify-content: flex-end;
    font-size: 11px;
  }

  .likebtn {
    width: 38px;
    height: 38px;
  }

  /* 搜索 */
  .searchbox {
    margin: 0 0 10px;
    padding: 8px 12px;
  }

  .empty {
    padding: 32px 12px 24px;
  }

  .empty__art svg {
    width: 92px;
    height: 92px;
  }

  /* 全屏播放页 */
  .sheet__body {
    padding: 0 20px calc(10px + var(--safe-b));
    gap: 10px;
  }

  .sheet__cover {
    width: min(60vw, 232px);
    height: min(60vw, 232px);
  }

  .sheet__title {
    font-size: 17px;
  }

  .sheet__lyric {
    min-height: 56px;
  }

  .lyric__line {
    font-size: 13px;
    padding: 6px 4px;
  }

  .playbtn--lg {
    width: 56px;
    height: 56px;
  }

  .toasts {
    bottom: calc(112px + var(--safe-b));
  }

  .statrow {
    gap: 8px;
  }

  .stat {
    padding: 10px;
  }

  .stat__num {
    font-size: 17px;
  }
}

/* 超窄屏（320-360）进一步压缩，保证 375 无横向滚动 */
@media (max-width: 380px) {
  .hero {
    grid-template-columns: 80px minmax(0, 1fr);
  }

  .hero__title {
    font-size: 16.5px;
  }

  .rail > * {
    flex-basis: 104px;
  }

  .track {
    grid-template-columns: 22px minmax(0, 1fr) 40px 36px;
    gap: 6px;
  }

  .track__cover {
    width: 38px;
    height: 38px;
  }
}

/* 桌面全屏播放页：变成居中面板，不做整屏铺满 */
@media (min-width: 768px) {
  /* 面板背后的遮罩：只有桌面需要，移动端是整屏页 */
  body.sheet-open::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 99;
    background: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.2s linear both;
  }

  .sheet {
    inset: 50% auto auto 50%;
    width: 452px;
    max-width: calc(100vw - 80px);
    height: min(760px, 88vh);
    border-radius: var(--r-xl);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-2);
    transform: translate(-50%, -44%) scale(0.98);
    opacity: 0;
    transition: transform 0.32s var(--ease-out), opacity 0.24s linear,
      visibility 0.32s linear;
  }

  .sheet.is-open {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }

  .sheet.is-dragging {
    transition: none;
  }

  .sheet__grabber {
    display: none;
  }

  .sheet__head {
    padding-top: 10px;
  }

  .sheet__cover {
    width: min(46vw, 240px);
    height: min(46vw, 240px);
  }

  .toasts {
    bottom: 108px;
  }
}

/* ==========================================================================
   14 无障碍降级
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }

  .sheet__cover {
    animation: none !important;
  }
}

@media (hover: none) {
  .card__play {
    opacity: 1;
    transform: none;
  }

  .progress__thumb {
    opacity: 1;
    transform: translateX(-50%) scale(0.85);
  }
}
