/* ============================================================
   English for Work & Hotel · 酒店英语
   设计语言：浅色卡片 · 紫罗兰主色 · 部门色"照片感"封面
   布局：顶栏 + 底部 Tab + 全局迷你播放条 + 沉浸播放页
   ============================================================ */

:root {
  --bg: #eef0f4;            /* 页面底 */
  --panel: #f7f8fa;         /* App 列底 */
  --card: #ffffff;
  --ink: #191b20;
  --ink-2: #55595f;
  --dim: #6a6f78;           /* 辅助文字 · WCAG AA 达标 */
  --dim2: #9aa0a9;          /* 仅装饰性文字 */
  --pri: #129c70;           /* 翡翠绿主色 */
  --pri-deep: #0c845a;
  --pri-soft: #e3f4ec;      /* 选中淡绿 */
  --gold: #d9b36c;
  --line: #edeef2;
  --sh-card: 0 1px 2px rgba(23, 26, 35, .04), 0 10px 26px -12px rgba(23, 26, 35, .12);
  --sh-pop: 0 18px 50px -12px rgba(23, 26, 35, .28);
  --r-lg: 20px; --r-md: 14px; --r-sm: 10px;
  --tab-h: 58px;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { font-family: var(--sans); background: var(--bg); color: var(--ink); line-height: 1.5; }
button { font-family: inherit; border: 0; background: none; cursor: pointer; color: inherit; }
.hidden { display: none !important; }
:focus-visible { outline: 2px solid var(--pri); outline-offset: 2px; border-radius: 6px; }
::selection { background: rgba(18, 156, 112, .20); }
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-thumb { background: #c9cdd4; border-radius: 3px; }
::-webkit-scrollbar-track { background: transparent; }

.ic { width: 22px; height: 22px; display: block; flex: none; }

/* ============ 手机立式布局（桌面也居中显示） ============ */
.app {
  position: relative; max-width: 440px; margin: 0 auto; height: 100dvh;
  background: var(--panel); display: flex; flex-direction: column;
}
@media (min-width: 480px) {
  body { padding: 24px 0; }
  .app { height: calc(100dvh - 48px); border-radius: 28px; overflow: hidden; box-shadow: var(--sh-pop); }
}
.app__body { flex: 1; display: flex; flex-direction: column; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding-bottom: 0; }
.view { flex: 1; display: flex; flex-direction: column; min-height: 0; }
.view.hidden { display: none; }
.view:not(.hidden) { animation: viewin .22s ease; }
@keyframes viewin { from { opacity: 0; transform: translateY(6px); } }
body.has-mini .app__body { padding-bottom: 92px; }

/* 沉浸播放页：隐藏 Tab 与底部留白 */
.app--imm .tabbar { display: none; }
.app--imm .app__body { padding-bottom: 0; }

/* ============ 顶栏 ============ */
.topbar {
  flex: none; display: grid; grid-template-columns: 48px 1fr 48px; align-items: center;
  height: 54px; padding: 0 6px; background: transparent;
}
.topbar__left { width: 40px; height: 40px; border-radius: 12px; color: var(--ink); justify-self: start; display: grid; place-items: center; }
.topbar__left:active { background: rgba(25, 27, 32, .06); }
.topbar__title { text-align: center; font-size: 15.5px; font-weight: 700; letter-spacing: .01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar__right { justify-self: end; }

/* ============ 部门色"照片感"封面（--pa/--pa2 由行内样式注入） ============ */
.photo {
  position: relative; overflow: hidden; color: #f5ead2;
  background:
    radial-gradient(120% 95% at 82% 6%, rgba(255, 244, 214, .26), rgba(255, 244, 214, 0) 52%),
    radial-gradient(150% 120% at 10% 100%, rgba(0, 0, 0, .58), rgba(0, 0, 0, 0) 58%),
    linear-gradient(158deg, var(--pa, #57492f) 0%, var(--pa2, #241e14) 62%, #14110c 130%);
}
.photo::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(152deg, rgba(255, 235, 200, .16), rgba(255, 255, 255, 0) 40%);
}
.photo__em { position: relative; z-index: 1; filter: drop-shadow(0 6px 14px rgba(0, 0, 0, .45)); }
.photo__caps {
  position: relative; z-index: 1; font-size: 10px; font-weight: 700; letter-spacing: .34em;
  color: var(--gold); text-transform: uppercase;
}

/* ============ 通用组件 ============ */
.sec { padding: 6px 16px 0; }
.sec__title { font-size: 15px; font-weight: 700; margin: 16px 2px 12px; }
.page { flex: 1; padding-bottom: 24px; }

.btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; height: 50px; border-radius: 14px;
  background: var(--pri); color: #fff; font-size: 15.5px; font-weight: 700; letter-spacing: .06em;
}
.btn:active { background: var(--pri-deep); transform: scale(.99); }
.btn--ghost { background: #fff; color: var(--ink); border: 1px solid var(--line); box-shadow: var(--sh-card); }
.btn--ghost:active { background: #f3f4f8; }

.pill {
  padding: 7px 14px; border-radius: 10px; font-size: 13px; font-weight: 600;
  background: #f1f2f6; color: var(--ink-2);
}
.pill--on { background: var(--pri); color: #fff; }
.pill:active { transform: scale(.96); }

/* 课程行（首页/课程列表/随身听通用） */
.crow {
  display: flex; align-items: center; gap: 12px; width: 100%; text-align: left;
  background: var(--card); border-radius: var(--r-md); padding: 10px; margin-bottom: 8px;
  box-shadow: var(--sh-card);
}
.crow:active { transform: scale(.985); }
.crow--on { background: var(--pri-soft); }
.crow__thumb {
  flex: none; width: 56px; height: 56px; border-radius: 12px;
  display: grid; place-items: center; font-size: 24px;
}
.crow__body { flex: 1; min-width: 0; }
.crow__name { display: block; font-size: 14.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.crow__en { display: block; font-size: 12px; color: var(--dim); margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.crow__meta { flex: none; text-align: right; font-size: 12.5px; color: var(--dim); font-variant-numeric: tabular-nums; }
.crow__eq { display: inline-flex; gap: 2px; align-items: flex-end; height: 12px; margin-left: 6px; }
.crow__eq i { width: 3px; background: var(--pri); border-radius: 1px; animation: eq 1s ease-in-out infinite; }
.crow__eq i:nth-child(2) { animation-delay: .2s; }
.crow__eq i:nth-child(3) { animation-delay: .4s; }
@keyframes eq { 0%, 100% { height: 5px; } 50% { height: 12px; } }

/* ============ 首页 ============ */
.hero {
  display: block; margin: 4px 16px 0; border-radius: var(--r-lg); padding: 22px 18px 18px; text-align: left;
  width: calc(100% - 32px); box-shadow: var(--sh-card);
}
.hero__t { position: relative; z-index: 1; font-size: 24px; font-weight: 900; color: #fdf6e7; line-height: 1.3; letter-spacing: .02em; }
.hero__s { position: relative; z-index: 1; display: block; font-size: 12px; color: rgba(245, 234, 210, .82); margin-top: 6px; }
.hero__caps { position: absolute; right: 16px; bottom: 14px; }
.hero__bell { position: absolute; right: 18px; top: 50%; transform: translateY(-58%); font-size: 58px; }

/* 继续学习卡 */
.resume {
  display: flex; align-items: center; gap: 12px; width: calc(100% - 32px);
  margin: 10px 16px 0; padding: 12px; border-radius: var(--r-md); text-align: left;
  background: var(--card); box-shadow: var(--sh-card);
}
.resume:active { transform: scale(.985); }
.resume__thumb { flex: none; width: 52px; height: 52px; border-radius: 12px; display: grid; place-items: center; font-size: 24px; }
.resume__body { flex: 1; min-width: 0; }
.resume__tag { display: block; font-size: 10.5px; color: var(--pri); font-weight: 700; letter-spacing: .08em; }
.resume__name { display: block; font-size: 14.5px; font-weight: 700; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.resume__en { display: block; font-size: 12px; color: var(--dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.resume__go { flex: none; color: var(--dim2); font-size: 18px; }

/* ============ 骨架屏 ============ */
.sk {
  border-radius: 14px; background: linear-gradient(90deg, #e9ebf0 25%, #f2f3f7 45%, #e9ebf0 65%);
  background-size: 200% 100%; animation: skmove 1.2s infinite linear;
}
@keyframes skmove { to { background-position: -200% 0; } }
.sk--hero { height: 128px; border-radius: var(--r-lg); margin: 4px 16px 0; }
.sk--resume { height: 78px; margin: 10px 16px 0; }
.sk--row { height: 78px; margin: 8px 16px 0; }

/* ============ 课程详情 ============ */
.cd__cover {
  margin: 2px 16px 0; height: 168px; border-radius: var(--r-lg);
  display: flex; align-items: flex-end; padding: 16px; box-shadow: var(--sh-card);
}
.cd__cover .photo__caps { position: static; margin-left: auto; }
.cd__cover__em { position: relative; z-index: 1; font-size: 44px; }
.cd__head { display: flex; align-items: baseline; gap: 10px; padding: 16px 20px 0; }
.cd__name { font-size: 21px; font-weight: 900; }
.cd__en { font-size: 13px; color: var(--dim); }
.cd__dur { margin-left: auto; font-size: 13px; color: var(--dim); font-variant-numeric: tabular-nums; }
.cd__sec { padding: 0 20px; margin-top: 18px; }
.cd__label { font-size: 13.5px; font-weight: 600; margin-bottom: 8px; }
.cd__desc { font-size: 13.5px; color: var(--ink-2); line-height: 1.75; }
.cd__list { display: grid; gap: 9px; }
.cd__li { display: flex; gap: 9px; font-size: 13.5px; color: var(--ink-2); align-items: baseline; }
.cd__li::before { content: "✓"; color: var(--pri); font-weight: 800; flex: none; }
.cd__acts { padding: 22px 20px 24px; display: grid; gap: 10px; }
.cd__row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

/* ============ 课程内容（卡片学习） ============ */
.learn { flex: 1; display: flex; flex-direction: column; padding: 0 16px; }
.learn__n { text-align: right; font-size: 12.5px; color: var(--dim); padding: 2px 6px 8px; font-variant-numeric: tabular-nums; }
.learn__stage { flex: 1; display: flex; flex-direction: column; justify-content: center; gap: 14px; min-height: 300px; }
.bub { position: relative; max-width: 88%; padding: 15px 52px 15px 16px; border-radius: 18px; background: #f1f2f6; text-align: left; width: 100%; }
.bub--g { align-self: flex-end; background: var(--pri-soft); padding: 15px 16px 15px 52px; }
.bub__en { display: block; font-size: 16px; font-weight: 700; line-height: 1.55; color: var(--ink); }
.bub__zh { display: block; font-size: 13px; color: var(--ink-2); margin-top: 6px; line-height: 1.6; }
.bub__who { position: absolute; top: 12px; font-size: 10px; font-weight: 800; color: var(--dim2); letter-spacing: .1em; }
.bub .bub__who { right: 16px; }
.bub--g .bub__who { left: 16px; right: auto; }
.bub__spk {
  position: absolute; right: 12px; bottom: 12px; width: 32px; height: 32px; border-radius: 50%;
  background: var(--pri); color: #fff; display: grid; place-items: center;
}
.bub__spk .ic { width: 15px; height: 15px; }
.bub--g .bub__spk { right: auto; left: 12px; }
.bub__spk:active { transform: scale(.92); }
.learn__ctrl { flex: none; display: flex; align-items: center; justify-content: center; gap: 16px; padding: 14px 0 22px; }
.learn__side {
  min-width: 86px; height: 46px; border-radius: 14px; background: #fff; box-shadow: var(--sh-card);
  font-size: 13.5px; font-weight: 700; color: var(--ink-2);
}
.learn__side:active { background: #f3f4f8; }
.learn__side[disabled] { opacity: .4; }
.learn__main {
  width: 64px; height: 64px; border-radius: 50%; background: var(--pri); color: #fff;
  display: grid; place-items: center;
  box-shadow: 0 12px 26px -8px rgba(18, 156, 112, .5);
}
.learn__main .ic { width: 26px; height: 26px; }
.learn__main:active { transform: scale(.94); background: var(--pri-deep); }

/* ============ 单词学习 ============ */
.wg { display: flex; gap: 8px; overflow-x: auto; padding: 8px 16px 2px; scrollbar-width: none; }
.wg::-webkit-scrollbar { display: none; }
.wg .pill { flex: none; padding: 6px 13px; font-size: 12.5px; }
.wcard { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 0 26px; text-align: center; }
.wcard__grp { font-size: 11px; color: var(--dim); background: #f1f2f6; border-radius: 99px; padding: 4px 12px; margin-bottom: 22px; }
.wcard__en { font-size: 30px; font-weight: 900; letter-spacing: .01em; }
.wcard__ipa { display: flex; align-items: center; gap: 10px; margin-top: 12px; color: var(--ink-2); font-size: 14.5px; }
.wcard__spk { width: 30px; height: 30px; border-radius: 50%; background: var(--pri); color: #fff; display: grid; place-items: center; }
.wcard__spk .ic { width: 14px; height: 14px; }
.wcard__zh { font-size: 16px; font-weight: 600; color: var(--ink); margin-top: 20px; }
.wcard__ctrl { flex: none; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding: 14px 16px 22px; }

/* ============ 播放页（沉浸 · 歌词居中滚动） ============ */
.player { flex: 1; display: flex; flex-direction: column; min-height: 0; padding: 0 20px calc(18px + env(safe-area-inset-bottom)); }
.ply__head { display: flex; align-items: center; gap: 14px; padding-top: 6px; }
.ply__cover {
  flex: none; width: 64px; height: 64px; border-radius: 14px;
  display: grid; place-items: center; font-size: 28px; box-shadow: var(--sh-card);
}
.ply__cover.playing .photo__em { animation: spin 14s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.ply__meta { flex: 1; min-width: 0; }
.ply__meta b { display: block; font-size: 18px; font-weight: 900; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ply__meta span { display: block; font-size: 12px; color: var(--dim); margin-top: 3px; }
.player__prog { margin-top: 14px; }
.player__bar { height: 4px; border-radius: 2px; background: #e7e8ee; overflow: hidden; }
.player__bar i { display: block; height: 100%; width: 0%; border-radius: 2px; background: var(--pri); transition: width .25s linear; }
.player__times { display: flex; justify-content: space-between; align-items: center; font-size: 11px; color: var(--dim2); margin-top: 6px; font-variant-numeric: tabular-nums; }
.player__stage { font-size: 10px; font-weight: 700; color: var(--pri); background: var(--pri-soft); padding: 2px 10px; border-radius: 99px; letter-spacing: .1em; }

/* 歌词区：当前句居中 · 平滑滚动 · 可手势拖动 · 上下渐隐 */
.player__lyr {
  position: relative; flex: 1; min-height: 0; overflow-y: auto;
  scroll-behavior: smooth; overscroll-behavior: contain; scrollbar-width: none;
  margin: 8px -20px 0; -webkit-overflow-scrolling: touch;
}
.player__lyr::-webkit-scrollbar { display: none; }
.player__lyr::before, .player__lyr::after {
  content: ""; position: absolute; left: 0; right: 0; height: 64px; z-index: 2; pointer-events: none;
}
.player__lyr::before { top: 0; background: linear-gradient(to bottom, var(--panel) 8%, rgba(247, 248, 250, 0)); }
.player__lyr::after { bottom: 0; background: linear-gradient(to top, var(--panel) 8%, rgba(247, 248, 250, 0)); }
.lyr__inner { }
.lyr { padding: 13px 24px; text-align: center; cursor: pointer; border-radius: 12px; transition: opacity .35s, background .2s; }
.lyr:active { background: rgba(25, 27, 32, .06); }
.lyr b { display: block; font-size: 16.5px; font-weight: 700; color: var(--dim); line-height: 1.55; transition: color .3s, font-size .3s; }
.lyr span { display: block; font-size: 12.5px; color: var(--dim2); margin-top: 3px; transition: color .3s; }
.lyr--past { opacity: .42; }
.lyr--on { opacity: 1; }
.lyr--on b { color: var(--ink); font-size: 19px; font-weight: 800; }
.lyr--on span { color: var(--ink-2); }

.player__ctrl {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  padding: 16px 2px calc(2px + env(safe-area-inset-bottom)) 0;
}
.pc__main { display: flex; align-items: center; justify-content: center; gap: 10px; }
.pc__side {
  height: 42px; min-width: 60px; padding: 0 14px; border-radius: 13px; background: #f1f2f6;
  font-size: 13px; font-weight: 700; color: var(--ink-2); display: inline-flex; align-items: center;
  justify-content: center; transition: background .2s, color .2s;
}
.pc__side.on { background: var(--pri-soft); color: var(--pri); }
.pc__side:active { transform: scale(.95); }
.pc__side--sleep { min-width: 0; width: 42px; padding: 0; border-radius: 50%; position: relative; }
.pc__side--sleep .ic { width: 19px; height: 19px; }
.pc__side--sleep.on::after { content: ""; position: absolute; top: 11px; right: 11px; width: 6px; height: 6px; border-radius: 50%; background: var(--pri); }
.pbtn { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; color: var(--ink); }
.pbtn:active { background: rgba(25, 27, 32, .06); }
.pbtn .ic { width: 20px; height: 20px; }
.pbtn--main {
  width: 70px; height: 70px; color: #fff; background: var(--pri);
  box-shadow: 0 14px 30px -8px rgba(18, 156, 112, .5);
}
.pbtn--main .ic { width: 28px; height: 28px; }
.pbtn--main:active { transform: scale(.94); background: var(--pri-deep); }

/* 底部弹层（倍速/模式） */
.sheet { position: absolute; inset: 0; z-index: 60; display: flex; align-items: flex-end; }
.sheet[hidden] { display: none; }
.sheet__bd { position: absolute; inset: 0; background: rgba(20, 22, 28, .45); animation: fadein .2s ease; }
@keyframes fadein { from { opacity: 0; } }
.sheet__card {
  position: relative; width: 100%; background: #fff; border-radius: 22px 22px 0 0;
  padding: 18px 20px calc(20px + env(safe-area-inset-bottom)); box-shadow: var(--sh-pop);
  animation: sheetup .25s cubic-bezier(.25, .6, .3, 1);
}
@keyframes sheetup { from { transform: translateY(40%); opacity: .5; } }
.sheet__head { display: flex; align-items: center; justify-content: space-between; font-size: 15px; font-weight: 700; margin-bottom: 14px; }
.sheet__x { width: 30px; height: 30px; border-radius: 50%; color: var(--dim); background: #f1f2f6; display: grid; place-items: center; }
.sheet__x .ic { width: 14px; height: 14px; }
.sheet__lb { font-size: 12px; color: var(--dim); margin: 12px 0 8px; }
.sheet__pills { display: flex; gap: 8px; flex-wrap: wrap; }
.sheet .pill { padding: 9px 16px; font-size: 13.5px; }

/* ============ 设置页 ============ */
.set { padding: 2px 16px; }
.set__card { background: var(--card); border-radius: var(--r-md); box-shadow: var(--sh-card); padding: 4px 16px; margin-bottom: 12px; }
.set__row { display: flex; align-items: center; gap: 12px; min-height: 56px; }
.set__row + .set__row { border-top: 1px solid var(--line); }
.set__label { font-size: 14px; font-weight: 600; }
.set__hint { display: block; font-size: 11.5px; color: var(--dim); margin-top: 1px; font-weight: 400; }
.set__ctrl { margin-left: auto; display: flex; gap: 7px; flex-wrap: wrap; justify-content: flex-end; }
.set .pill { padding: 6px 11px; font-size: 12px; }

/* 开关 */
.sw { position: relative; width: 48px; height: 28px; border-radius: 99px; background: #e3e5ea; transition: background .2s; flex: none; }
.sw::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 4px rgba(0,0,0,.2); transition: left .2s; }
.sw--on { background: var(--pri); }
.sw--on::after { left: 23px; }

/* ============ 搜索页 ============ */
.search { padding: 2px 16px; }
.search__box { position: relative; }
.search__box input {
  width: 100%; height: 46px; border: 0; outline: none; border-radius: 13px;
  background: #eceef2; padding: 0 14px 0 40px; font-size: 14px; font-family: var(--sans); color: var(--ink);
}
.search__box input::placeholder { color: var(--dim2); }
.search__ico { position: absolute; left: 13px; top: 13px; font-size: 15px; opacity: .5; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip { padding: 7px 14px; border-radius: 99px; background: var(--card); box-shadow: var(--sh-card); font-size: 12.5px; color: var(--ink-2); font-weight: 600; }
.chip:active { color: var(--pri); }
.sres { margin-top: 4px; }
.sres__row {
  display: flex; gap: 10px; align-items: center; width: 100%; text-align: left; cursor: pointer;
  background: var(--card); border-radius: var(--r-sm); padding: 11px 13px; margin-bottom: 7px; box-shadow: var(--sh-card);
}
.sres__row:active { transform: scale(.985); }
.sres__en { display: block; font-size: 13.5px; font-weight: 700; }
.sres__zh { display: block; font-size: 12px; color: var(--dim); margin-top: 1px; }
.sres__go {
  margin-left: auto; flex: none; font-size: 10.5px; color: var(--pri); background: var(--pri-soft);
  padding: 3px 9px; border-radius: 99px;
}
.sres__go--plain { color: var(--dim2); background: #f1f2f6; }
.sres__spk { flex: none; color: var(--pri); }
.sres__spk .ic { width: 18px; height: 18px; }
.histhead { display: flex; align-items: center; justify-content: space-between; }
.histhead button { font-size: 13px; color: var(--dim); }

/* ============ 关于页 ============ */
.about { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 0 30px 40px; }
.about__logo {
  width: 84px; height: 84px; border-radius: 24px; display: grid; place-items: center; font-size: 38px;
  background: var(--pri-soft); margin-bottom: 18px;
}
.about__t { font-size: 20px; font-weight: 900; line-height: 1.35; }
.about__v { font-size: 12px; color: var(--dim); margin-top: 6px; }
.about__s { font-size: 13.5px; color: var(--ink-2); margin-top: 22px; }
.about__k { font-size: 12px; color: var(--dim); letter-spacing: .3em; margin-top: 8px; }
.about__c { font-size: 11px; color: var(--dim2); margin-top: 34px; }

/* ============ 底部 Tab ============ */
.tabbar {
  flex: none; position: relative; z-index: 40;
  display: grid; grid-template-columns: repeat(3, 1fr);
  height: calc(var(--tab-h) + env(safe-area-inset-bottom));
  padding-bottom: env(safe-area-inset-bottom);
  background: rgba(255, 255, 255, .97); backdrop-filter: blur(14px);
  border-top: 1px solid var(--line);
}
.tabbar__item {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  color: var(--dim); text-decoration: none; font-size: 10.5px; font-weight: 600;
  -webkit-tap-highlight-color: transparent;
}
.tabbar__item .ic { width: 24px; height: 24px; }
.tabbar__item--on { color: var(--pri); }
.tabbar__item:active { transform: scale(.94); }

/* ============ 迷你播放条 ============ */
.mini {
  position: absolute; left: 14px; right: 14px; bottom: calc(var(--tab-h) + 12px + env(safe-area-inset-bottom)); z-index: 50;
  display: flex; align-items: center; gap: 2px;
  background: #fff; border-radius: 16px; padding: 8px 10px; box-shadow: var(--sh-pop);
}
body:not(.has-mini) .mini { bottom: 14px; }
.mini__main { display: flex; align-items: center; gap: 11px; flex: 1; min-width: 0; text-align: left; }
.mini__thumb { flex: none; width: 44px; height: 44px; border-radius: 11px; display: grid; place-items: center; font-size: 20px; }
.mini__txt { min-width: 0; }
.mini__tag { display: block; font-style: normal; font-size: 10px; color: var(--dim); letter-spacing: .08em; }
.mini__txt b { display: block; font-size: 12.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini__btn {
  flex: none; width: 40px; height: 40px; border-radius: 50%; background: var(--pri); color: #fff;
  display: grid; place-items: center;
}
.mini__btn .ic { width: 18px; height: 18px; }
.mini__btn:active { transform: scale(.93); }
.mini__btn--x { background: transparent; color: var(--dim2); width: 30px; }
.mini__btn--x .ic { width: 15px; height: 15px; }

/* ============ 抽屉 ============ */
.drawer { position: fixed; inset: 0; z-index: 80; }
.drawer[hidden] { display: none; }
.drawer__bd { position: absolute; inset: 0; background: rgba(20, 22, 28, .42); }
.drawer__panel {
  position: absolute; top: 0; bottom: 0; left: max(0px, calc(50% - 220px)); width: min(78vw, 300px);
  background: #fff; border-radius: 0 24px 24px 0; padding: 26px 14px 18px;
  display: flex; flex-direction: column; animation: slidein .22s ease;
}
@keyframes slidein { from { transform: translateX(-30px); opacity: 0; } }
.drawer__brand { display: flex; gap: 12px; align-items: center; padding: 0 8px 20px; border-bottom: 1px solid var(--line); margin-bottom: 10px; }
.drawer__logo { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; font-size: 22px; }
.drawer__brand b { font-size: 14.5px; line-height: 1.3; display: block; }
.drawer__brand i { font-style: normal; font-size: 11px; color: var(--dim); }
.drawer__item { text-align: left; padding: 13px 12px; border-radius: 12px; font-size: 14.5px; font-weight: 600; color: var(--ink-2); }
.drawer__item:active, .drawer__item--on { background: var(--pri-soft); color: var(--pri); }
.drawer__foot { margin-top: auto; text-align: center; font-size: 11px; color: var(--dim2); letter-spacing: .3em; padding-top: 14px; }

/* ============ 轻提示 / 错误 ============ */
.toast {
  position: fixed; left: 50%; bottom: calc(var(--tab-h) + 96px); transform: translate(-50%, 12px);
  background: rgba(25, 27, 32, .92); color: #fff; padding: 10px 20px; font-size: 13px;
  border-radius: 99px; opacity: 0; pointer-events: none; transition: all .25s; z-index: 95;
}
.toast--show { opacity: 1; transform: translate(-50%, 0); }
.loading { padding: 70px 0; text-align: center; color: var(--dim2); font-size: 13px; letter-spacing: .2em; }
.fatal { margin: 40px 16px; background: #fff; border: 1px solid #f0c7c5; border-radius: 14px; padding: 18px; font-size: 13.5px; color: #8c3b37; line-height: 1.8; }
.fatal .btn { margin-top: 14px; height: 42px; font-size: 14px; }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}
