/* ==========================================================================
   主流300讲 · H5 全局样式  （大气、精美、有档次感）
   设计：暖米白底 · 深墨字 · 赤陶品牌红 · 鎏金点缀 · 衬线大标题
   ========================================================================== */

:root {
  /* --- 色彩 --- */
  --bg:        #f6f1e7;   /* 暖米白 */
  --bg-2:      #ede6d8;   /* 次级底 */
  --card:      #ffffff;
  --ink:       #1a1a1a;   /* 深墨 */
  --ink-2:     #3a3a3a;
  --sub:       #6b6b6b;
  --muted:     #9a9a9a;
  --line:      #e8e2d5;
  --line-2:    #f0ebe0;
  --brand:     #a8452e;   /* 赤陶 */
  --brand-2:   #c85a3e;
  --brand-soft:#f4e7e2;
  --gold:      #c8964a;   /* 鎏金 */
  --gold-soft: #f5ecd7;
  --shadow-sm: 0 2px 8px  rgba(26,26,26,.06);
  --shadow-md: 0 6px 20px rgba(26,26,26,.08);
  --shadow-lg: 0 18px 50px rgba(26,26,26,.12);
  --radius-s:  10px;
  --radius-m:  14px;
  --radius-l:  18px;
  --radius-xl: 24px;

  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --bar-h: 62px;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  margin: 0; padding: 0;
  background: var(--bg-2);
  color: var(--ink);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "PingFang SC",
               "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  font-size: 15px; line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { display: block; max-width: 100%; }
a  { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

.shell {
  position: relative;
  max-width: 560px;
  min-height: 100vh;
  margin: 0 auto;
  background: var(--bg);
  padding-bottom: calc(var(--bar-h) + var(--safe-bottom));
  overflow-x: hidden;
}

@media (min-width: 700px) {
  body { padding: 32px 0; }
  .shell {
    border-radius: 28px; overflow: hidden;
    box-shadow: var(--shadow-lg);
  }
}

/* ==========================================================================
   Hero 轮播
   ========================================================================== */
.hero-wrap {
  position: relative;
  height: 340px;
  overflow: hidden;
}
@media (max-width: 380px) { .hero-wrap { height: 300px; } }

.hero-track { position: relative; height: 100%; }
.hero-slide {
  position: absolute; inset: 0;
  opacity: 0; transform: scale(1.04);
  transition: opacity .7s ease, transform 6s ease;
  pointer-events: none;
}
.hero-slide.active { opacity: 1; transform: scale(1); pointer-events: auto; }

.hero-slide-bg { position: absolute; inset: 0; }
.hero-slide-bg img {
  width: 100%; height: 100%; object-fit: cover;
  filter: saturate(1.05);
}
.hero-slide-veil {
  position: absolute; inset: 0;
  background: linear-gradient(transparent 20%, rgba(0,0,0,.15) 50%, rgba(0,0,0,.72) 100%);
}

/* 封面兜底：3 种优雅渐变 + 几何图案 */
.hero-fallback {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 28px 28px 60px;
}
.hero-fallback-1 { background: linear-gradient(135deg, #3d2f2a 0%, #7a4a3a 45%, #c17a4e 100%); }
.hero-fallback-2 { background: linear-gradient(135deg, #1e2a3a 0%, #2f4a5c 50%, #6a8a9a 100%); }
.hero-fallback-3 { background: linear-gradient(135deg, #2a2a3a 0%, #4a3f4a 55%, #7a5a4a 100%); }
.hero-fallback::after {
  content: ''; position: absolute; right: -40px; top: -40px;
  width: 220px; height: 220px; border-radius: 50%;
  background: rgba(255,255,255,.08);
}
.hero-fallback::before {
  content: ''; position: absolute; left: 30px; bottom: 80px;
  width: 140px; height: 140px; border-radius: 50%;
  background: rgba(255,255,255,.05);
}

.hero-slide-content {
  position: absolute; left: 24px; right: 24px; bottom: 24px; z-index: 2;
  color: #fff;
}
.hero-slide-content h2 {
  margin: 0 0 6px;
  font-family: 'Noto Serif SC', 'Songti SC', 'STSong', serif;
  font-weight: 700; font-size: 26px; line-height: 1.25;
  letter-spacing: 0.5px;
  text-shadow: 0 2px 14px rgba(0,0,0,.35);
}
@media (max-width: 380px) { .hero-slide-content h2 { font-size: 22px; } }
.hero-slide-content p {
  margin: 0; font-size: 13px; opacity: .88; letter-spacing: .3px;
  text-shadow: 0 1px 6px rgba(0,0,0,.3);
}
.hero-cta {
  display: inline-block; margin-top: 10px; padding: 6px 14px;
  font-size: 12px; font-weight: 600; letter-spacing: .5px;
  background: rgba(255,255,255,.18); backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,.3);
  border-radius: 999px;
}

/* Hero 顶部品牌条 */
.hero-topbar {
  position: absolute; top: 0; left: 0; right: 0; z-index: 5;
  display: flex; align-items: center; gap: 10px;
  padding: 16px 20px;
}
.brand-mini {
  display: flex; align-items: center; gap: 10px;
}
.brand-mini .mark-s {
  width: 32px; height: 32px; border-radius: 10px;
  background: var(--brand); color: #fff;
  font-weight: 700; font-size: 13px;
  display: grid; place-items: center;
  box-shadow: 0 4px 12px rgba(168,69,46,.35);
}
.brand-mini h1 {
  margin: 0; font-size: 15px; font-weight: 600; color: #fff;
  letter-spacing: 1px; text-shadow: 0 1px 4px rgba(0,0,0,.35);
}
.brand-mini p {
  margin: 0; font-size: 9px; color: rgba(255,255,255,.7);
  letter-spacing: 1.5px;
}
.top-login {
  margin-left: auto; padding: 6px 14px;
  font-size: 13px; font-weight: 500; color: #fff;
  background: rgba(0,0,0,.28); backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 999px;
}

/* Hero 指示点 */
.hero-dots {
  position: absolute; bottom: 14px; left: 50%; transform: translateX(-50%);
  display: flex; gap: 6px; z-index: 4;
}
.hero-dot {
  width: 20px; height: 3px; border-radius: 2px;
  background: rgba(255,255,255,.4);
  transition: all .3s ease;
}
.hero-dot.on { width: 32px; background: #fff; }

/* ==========================================================================
   数据证明条
   ========================================================================== */
.proof {
  display: flex; align-items: center; gap: 0;
  margin: -20px 16px 0; padding: 14px 8px;
  background: var(--card);
  border-radius: var(--radius-l);
  box-shadow: var(--shadow-md);
  position: relative; z-index: 6;
}
.proof-item {
  flex: 1; text-align: center;
}
.proof-item b {
  display: block; font-family: 'Noto Serif SC', serif;
  font-size: 22px; font-weight: 700; color: var(--brand);
  line-height: 1.1;
}
.proof-item span { font-size: 11px; color: var(--muted); letter-spacing: .3px; }
.proof-divider {
  width: 1px; height: 28px; background: var(--line);
}

/* ==========================================================================
   区块通用
   ========================================================================== */
.block { padding: 28px 16px 0; }
.block-head {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 16px;
}
.block-num {
  font-family: 'Noto Serif SC', serif;
  font-size: 26px; font-weight: 700;
  color: var(--gold); opacity: .35;
  line-height: 1;
}
.block-title { flex: 1; min-width: 0; }
.block-title h2 {
  margin: 0;
  font-family: 'Noto Serif SC', serif;
  font-size: 20px; font-weight: 700; color: var(--ink);
  letter-spacing: 1px;
}
.block-title span {
  display: block; font-size: 10px; color: var(--muted);
  letter-spacing: 2px; margin-top: 2px;
}
.block-more {
  font-size: 13px; color: var(--brand); font-weight: 500;
}

/* ==========================================================================
   编辑精选（横向滚动）
   ========================================================================== */
.picks {
  display: flex; gap: 14px;
  overflow-x: auto; scroll-snap-type: x mandatory;
  padding: 2px 2px 4px;
  scrollbar-width: none;
}
.picks::-webkit-scrollbar { display: none; }

.pick-card {
  flex: 0 0 200px;
  scroll-snap-align: start;
  background: var(--card);
  border-radius: var(--radius-l);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--line-2);
  transition: transform .3s ease, box-shadow .3s ease;
}
.pick-card:active { transform: scale(.98); }

.pick-cover {
  position: relative; width: 100%; height: 120px;
}
.pick-cover .media, .pick-cover img {
  width: 100%; height: 100%; object-fit: cover;
}
.pick-badge, .pick-vip {
  position: absolute; top: 8px; left: 8px;
  padding: 3px 8px; font-size: 10px; font-weight: 600;
  border-radius: 6px; backdrop-filter: blur(6px);
}
.pick-badge { background: rgba(0,0,0,.55); color: #fff; }
.pick-vip {
  top: auto; bottom: 8px;
  background: linear-gradient(135deg, #c8964a, #e8b66a);
  color: #3a2810; right: 8px; left: auto;
}

.pick-info { padding: 10px 12px 12px; }
.pick-title {
  font-size: 14px; font-weight: 600; color: var(--ink);
  line-height: 1.35;
}
.pick-meta {
  margin-top: 4px; font-size: 11px; color: var(--muted);
}
.pick-bottom {
  margin-top: 8px; display: flex; align-items: center;
}
.pick-price {
  font-family: 'Noto Serif SC', serif;
  font-size: 17px; font-weight: 700; color: var(--brand);
}
.pick-price .cur { font-size: 11px; vertical-align: super; margin-right: 1px; }

/* ==========================================================================
   会员权益 Banner
   ========================================================================== */
.member-banner {
  display: flex; align-items: center; gap: 14px;
  margin: 22px 16px 0; padding: 18px 18px 18px 22px;
  border-radius: var(--radius-l);
  position: relative; overflow: hidden;
  background: linear-gradient(135deg, #2a2220 0%, #4a3a2e 60%, #7a5a3e 100%);
  color: #f4e3c8;
  box-shadow: 0 12px 30px rgba(74,58,46,.3);
}
.member-banner-bg {
  position: absolute; right: -30px; top: -30px;
  width: 180px; height: 180px; border-radius: 50%;
  background: radial-gradient(circle, rgba(200,150,74,.35) 0%, transparent 70%);
}
.member-banner-left { flex: 1; min-width: 0; position: relative; z-index: 2; }
.member-chip {
  display: inline-block; padding: 2px 10px; margin-bottom: 8px;
  font-size: 10px; font-weight: 700; letter-spacing: 1.5px;
  color: #3a2810; background: var(--gold);
  border-radius: 999px;
}
.member-banner-left h3 {
  margin: 0 0 4px; font-size: 16px; font-weight: 700;
  letter-spacing: .5px;
}
.member-banner-left p {
  margin: 0; font-size: 12px; opacity: .8; line-height: 1.5;
}
.member-banner-right { text-align: right; position: relative; z-index: 2; }
.price-tag {
  font-family: 'Noto Serif SC', serif;
  color: var(--gold);
  display: flex; align-items: baseline; justify-content: flex-end;
}
.price-tag .cur { font-size: 14px; font-weight: 600; }
.price-tag .num { font-size: 28px; font-weight: 900; line-height: 1; }
.price-tag .unit { font-size: 11px; color: rgba(244,227,200,.7); margin-left: 2px; }
.go-btn {
  margin-top: 8px; padding: 7px 16px;
  font-size: 12px; font-weight: 600;
  background: var(--gold); color: #3a2810;
  border-radius: 999px;
  display: inline-block;
}

/* ==========================================================================
   分类卡片 2 列网格
   ========================================================================== */
.cat-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 12px;
}
.cat-card {
  background: var(--card);
  border-radius: var(--radius-m);
  overflow: hidden;
  border: 1px solid var(--line-2);
  box-shadow: var(--shadow-sm);
}
.cat-cover {
  position: relative; width: 100%; aspect-ratio: 4/3;
  background: var(--bg-2);
}
.cat-cover .media { width: 100%; height: 100%; }
.cat-cover .media img { width: 100%; height: 100%; object-fit: cover; }
.cat-type {
  position: absolute; bottom: 6px; right: 6px;
  padding: 2px 7px; font-size: 10px; font-weight: 600;
  background: rgba(0,0,0,.55); color: #fff;
  border-radius: 5px;
}
.cat-body { padding: 10px 12px 12px; }
.cat-title { font-size: 13px; font-weight: 600; line-height: 1.35; color: var(--ink); }
.cat-meta { margin-top: 3px; font-size: 11px; color: var(--muted); }
.cat-foot {
  margin-top: 6px; display: flex; align-items: center; gap: 6px;
}
.cat-price { color: var(--brand); font-weight: 700; font-size: 14px; font-family: 'Noto Serif SC', serif; }
.cat-price .cur { font-size: 10px; vertical-align: super; margin-right: 1px; }

/* ==========================================================================
   .media 封面兜底（全站通用）
   ========================================================================== */
.media { position: relative; overflow: hidden; }
.media img { width: 100%; height: 100%; object-fit: cover; transition: opacity .3s ease; }

/* 封面缺失时：优雅渐变 + 首字装饰 */
.media .fallback {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; justify-content: center; align-items: center;
  text-align: center; padding: 12px;
  color: rgba(255,255,255,.92);
}
.media .fallback::before {
  content: attr(data-char);
  font-family: 'Noto Serif SC', serif;
  font-size: 44px; font-weight: 900;
  line-height: 1; opacity: .25;
  position: absolute;
}

/* 根据 data-hue 动态生成渐变（由 JS 写入） */
.media[data-hue="0"] .fallback { background: linear-gradient(135deg, #8d5b4c, #3f4b5b); }
.media[data-hue="1"] .fallback { background: linear-gradient(135deg, #2f4a5c, #6a5a3e); }
.media[data-hue="2"] .fallback { background: linear-gradient(135deg, #4a3f4a, #6a4a3a); }
.media[data-hue="3"] .fallback { background: linear-gradient(135deg, #3a4a3a, #5a6a3a); }
.media[data-hue="4"] .fallback { background: linear-gradient(135deg, #4a3a5a, #7a5a7a); }
.media[data-hue="5"] .fallback { background: linear-gradient(135deg, #2a3a4a, #4a5a6a); }

.media[data-hue="0"] .fallback::before { color: #fff; }
.media[data-hue="1"] .fallback::before { color: #a8c5d4; }
.media[data-hue="2"] .fallback::before { color: #d4b494; }
.media[data-hue="3"] .fallback::before { color: #b4d494; }
.media[data-hue="4"] .fallback::before { color: #d4b4d4; }
.media[data-hue="5"] .fallback::before { color: #94b4d4; }

/* ==========================================================================
   原有通用组件（课程行、章节、播放器、会员套餐、底部 Tab 等保持兼容）
   ========================================================================== */

.price { color: var(--brand); font-weight: 700; font-family: 'Noto Serif SC', serif; }
.price .cur { font-size: 12px; margin-right: 1px; }
.price-old { color: var(--muted); font-size: 12px; text-decoration: line-through; margin-left: 6px; }

.tag {
  display: inline-block; padding: 2px 8px; border-radius: 6px;
  font-size: 11px; line-height: 18px; vertical-align: middle;
  font-weight: 500;
}
.tag-brand { background: var(--brand-soft); color: var(--brand); }
.tag-gold  { background: var(--gold-soft);  color: #8a6320; }
.tag-gray  { background: var(--bg-2);       color: var(--sub); }

.ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.clamp-2 {
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

/* 顶部导航条（非首页） */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 12px;
  height: 56px; padding: 0 16px;
  background: rgba(246,241,231,.94); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line-2);
}
.topbar.scrolled { border-bottom-color: var(--line); }
.topbar .back {
  width: 34px; height: 34px; display: grid; place-items: center;
  border: 0; background: transparent; border-radius: 50%;
  color: var(--ink); font-size: 20px;
}
.topbar h1 { margin: 0; font-size: 17px; font-weight: 600; letter-spacing: .3px; }
.topbar .sub { margin-left: auto; font-size: 12px; color: var(--muted); }

/* 横向课程卡（旧版） */
.hscroll {
  display: flex; gap: 12px;
  padding: 0 16px;
  overflow-x: auto; scrollbar-width: none;
}
.hscroll::-webkit-scrollbar { display: none; }
.mini-card {
  flex: 0 0 148px; background: var(--card); border-radius: var(--radius-m);
  border: 1px solid var(--line-2); overflow: hidden;
}
.mini-card .media { height: 92px; }
.mini-card .body { padding: 8px 10px 10px; }
.mini-card .title { font-size: 13px; font-weight: 600; line-height: 1.4; height: 37px; }

/* 课程行卡 */
.course-row {
  display: flex; gap: 12px; padding: 12px;
  background: var(--card); border: 1px solid var(--line-2);
  border-radius: var(--radius-m);
}
.course-row + .course-row { margin-top: 10px; }
.course-row .media { flex: 0 0 104px; height: 78px; border-radius: var(--radius-s); }
.course-row .info { min-width: 0; flex: 1; display: flex; flex-direction: column; }
.course-row .title { font-size: 14px; font-weight: 600; line-height: 1.4; }
.course-row .meta { font-size: 12px; color: var(--muted); margin-top: 4px; }
.course-row .bottom { margin-top: auto; display: flex; align-items: center; }

/* 分类 Tab */
/* ============ 个人中心 profile 区 ============ */
.profile {
  display: flex; align-items: center; gap: 14px;
  margin: 16px 16px 0;
  padding: 18px 18px;
  background: linear-gradient(135deg, #2a2220 0%, #4a3a2d 55%, #8a6a42 100%);
  border-radius: var(--radius-xl);
  box-shadow: 0 6px 20px rgba(74,58,45,.25);
  color: #fff;
  position: relative; overflow: hidden;
}
.profile::after {
  content: ''; position: absolute; top: -40px; right: -40px;
  width: 140px; height: 140px; border-radius: 50%;
  background: radial-gradient(circle, rgba(200,150,74,.4) 0%, transparent 70%);
  pointer-events: none;
}
.profile .avatar {
  flex-shrink: 0; width: 56px; height: 56px; border-radius: 50%;
  background: linear-gradient(135deg, #c8964a 0%, #a8763e 100%);
  color: #fff; font-size: 22px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  border: 2px solid rgba(255,255,255,.3);
  box-shadow: 0 2px 8px rgba(0,0,0,.2);
}
.profile h2 { margin: 0; font-size: 17px; font-weight: 600; color: #fff; }
.profile p { margin: 4px 0 0; font-size: 12px; opacity: .75; color: #f0e6d8; }

/* 统计卡片 */
.stat-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px;
  padding: 14px 16px 0;
}
.stat {
  background: #fff;
  border: 1px solid var(--line-2);
  border-radius: var(--radius-s);
  padding: 14px 10px; text-align: center;
  box-shadow: 0 1px 4px rgba(0,0,0,.04);
}
.stat b {
  display: block; font-size: 20px; font-weight: 700;
  color: var(--ink); font-family: 'Noto Serif SC', serif;
}
.stat span {
  font-size: 11px; color: var(--muted);
  display: block; margin-top: 3px;
}
.stat.stat-member b { color: var(--brand); }

/* tabs（订单筛选等）*/
.tabs {
  display: flex; gap: 8px;
  padding: 10px 16px 2px;
}
.tab {
  flex: 0 0 auto;
  padding: 7px 16px; border-radius: 18px;
  font-size: 13px; color: var(--sub);
  border: 1px solid var(--line-2);
  background: #fff;
  transition: all .2s;
  cursor: pointer;
}
.tab:hover { color: var(--ink); }
.tab.active {
  color: #fff;
  background: var(--brand);
  border-color: var(--brand);
  font-weight: 500;
  box-shadow: 0 2px 8px rgba(168,69,46,.3);
}

/* 课程卡片（已购）*/
.course-row {
  display: flex; gap: 10px;
  padding: 10px;
  background: #fff;
  border: 1px solid var(--line-2);
  border-radius: var(--radius-s);
  box-shadow: 0 1px 4px rgba(0,0,0,.03);
}
.course-row + .course-row { margin-top: 10px; }
.course-row .media { flex: 0 0 104px; height: 78px; border-radius: 8px; }
.course-row .info { min-width: 0; flex: 1; display: flex; flex-direction: column; }
.course-row .title { font-size: 14px; font-weight: 600; line-height: 1.4; color: var(--ink); }
.course-row .meta { font-size: 12px; color: var(--muted); margin-top: 4px; }
.course-row .bottom { margin-top: auto; display: flex; align-items: center; }

/* 订单卡片 */
.order {
  padding: 14px;
  background: #fff;
  border: 1px solid var(--line-2);
  border-radius: var(--radius-s);
  box-shadow: 0 1px 4px rgba(0,0,0,.03);
}
.order .row1 { display: flex; align-items: center; gap: 8px; }
.order .row1 b { font-size: 14px; color: var(--ink); }
.order .row1 .status { margin-left: auto; font-size: 12px; }
.order .meta { font-size: 12px; color: var(--muted); margin-top: 6px; }
.order .row2 { display: flex; align-items: center; margin-top: 8px; }
.order .row2 .price { font-size: 16px; font-weight: 600; color: var(--brand); font-family: 'Noto Serif SC', serif; }
.order .row2 .price .cur { font-size: 12px; font-weight: 500; }
.order .status.st-0 { color: #d97706; }
.order .status.st-1 { color: #059669; }
.order .status.st-2 { color: #dc2626; }

.orders { display: flex; flex-direction: column; gap: 10px; padding: 4px 16px 0; }

/* 通用 section 区块 */
.section { margin-top: 4px; }
.section-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 16px 10px;
}
.section-head h2 {
  margin: 0; font-size: 16px; font-weight: 700; color: var(--ink);
  font-family: 'Noto Serif SC', serif;
}
.section-head .more {
  font-size: 13px; color: var(--brand); text-decoration: none;
  display: inline-flex; align-items: center; gap: 2px;
  transition: opacity .2s;
}
.section-head .more:active { opacity: .6; }

/* 退出登录 */
.logout {
  margin: 20px 16px 32px;
  border: 1px solid rgba(168,69,46,.4);
  background: #fff;
  color: var(--brand);
  border-radius: var(--radius-s);
  padding: 13px; width: calc(100% - 32px);
  font-size: 14px; font-weight: 500;
  cursor: pointer;
  transition: all .2s;
}
.logout:active { background: var(--brand-soft); border-color: var(--brand); }

/* 搜索 */
.search {
  display: flex; align-items: center; gap: 8px;
  margin: 10px 16px 0; padding: 9px 12px;
  background: var(--card); border: 1px solid var(--line-2); border-radius: var(--radius-s);
}
.search input {
  flex: 1; border: 0; outline: none; background: transparent;
  font-size: 14px; color: var(--ink);
}
.search input::placeholder { color: var(--muted); }
.search button {
  border: 0; background: var(--brand); color: #fff;
  font-size: 13px; padding: 6px 14px; border-radius: 9px;
}

/* 课程详情 */
.hero, .detail-body, .chapter { } /* 占位，类名保留 */
.hero { position: relative; height: 210px; }
.hero .veil { position: absolute; inset: 0; background: linear-gradient(transparent 35%, rgba(0,0,0,.6)); }
.hero .caption { position: absolute; left: 16px; right: 16px; bottom: 14px; color: #fff; }
.hero .caption h1 { margin: 0 0 4px; font-size: 19px; line-height: 1.35; font-family: 'Noto Serif SC', serif; }
.hero .caption p { margin: 0; font-size: 12px; opacity: .85; }
.detail-body { padding: 14px 16px 20px; }
.detail-body .price-line { display: flex; align-items: baseline; gap: 4px; }
.detail-body .price-line .price { font-size: 24px; }
.detail-body .rights { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.detail-body .desc {
  margin-top: 14px; font-size: 14px; color: #444; line-height: 1.7;
  border-top: 1px solid var(--line); padding-top: 14px;
}
.chapter {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 14px; background: var(--card);
  border: 1px solid var(--line-2); border-radius: var(--radius-s);
  margin-top: 10px;
}
.chapter .idx { width: 26px; color: var(--muted); font-size: 13px; text-align: center; }
.chapter .main { min-width: 0; flex: 1; }
.chapter .main b { font-size: 14px; font-weight: 600; display: block; }
.chapter .main span { font-size: 12px; color: var(--muted); }
.chapter .go {
  font-size: 12px; color: var(--brand);
  border: 1px solid var(--brand-soft); background: var(--brand-soft);
  padding: 5px 10px; border-radius: 9px;
}
.chapter .lock { font-size: 12px; color: var(--muted); }

.actionbar {
  position: fixed; left: 50%; transform: translateX(-50%);
  bottom: 0; z-index: 40;
  width: 100%; max-width: 560px;
  display: flex; align-items: center; gap: 12px;
  padding: 10px 16px calc(10px + var(--safe-bottom));
  background: rgba(255,255,255,.96); backdrop-filter: blur(12px);
  border-top: 1px solid var(--line-2);
}
.actionbar .price { font-size: 20px; }
.actionbar .hint { font-size: 11px; color: var(--muted); }

.btn {
  border: 0; border-radius: var(--radius-m); padding: 12px 20px;
  font-size: 15px; font-weight: 600;
  background: var(--brand); color: #fff;
  transition: opacity .2s;
}
.btn.block { width: 100%; display: block; }
.btn.ghost { background: var(--card); color: var(--ink); border: 1px solid var(--line-2); }
.btn:disabled { opacity: .55; }
.btn-sm { padding: 8px 14px; font-size: 13px; border-radius: var(--radius-s); }

/* 会员套餐 */
.member-hero {
  margin: 16px; padding: 20px;
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, #2a2220, #4a3a2e 60%, #7a5a3e);
  color: #f4e3c8;
  position: relative; overflow: hidden;
}
.member-hero h2 { margin: 0 0 6px; font-size: 19px; letter-spacing: .5px; font-family: 'Noto Serif SC', serif; }
.member-hero p { margin: 0; font-size: 12px; opacity: .8; }
.member-hero .badge {
  position: absolute; right: -26px; top: 18px;
  padding: 4px 34px; font-size: 11px;
  background: var(--gold); color: #3a2810;
  transform: rotate(35deg);
}
.plan {
  display: flex; align-items: center; gap: 12px;
  padding: 16px; margin: 0 16px 12px;
  background: var(--card); border: 1px solid var(--line-2); border-radius: var(--radius-m);
  position: relative;
}
.plan.recommend { border-color: var(--gold); box-shadow: 0 8px 22px rgba(200,150,74,.18); }
.plan .left { flex: 1; min-width: 0; }
.plan .name { font-size: 15px; font-weight: 600; }
.plan .desc { font-size: 12px; color: var(--muted); margin-top: 2px; }
.plan .price { font-size: 20px; }

/* 播放器 */
.player-wrap { padding: 16px; }
.player-stage {
  border-radius: var(--radius-l); overflow: hidden; background: #111;
  box-shadow: 0 10px 30px rgba(0,0,0,.18);
}
.player-stage audio, .player-stage video { width: 100%; display: block; }
.player-stage video { aspect-ratio: 16/9; background: #000; }
.player-title { margin: 16px 0 4px; font-size: 17px; font-family: 'Noto Serif SC', serif; }
.player-sub { font-size: 12px; color: var(--muted); }
.player-tip {
  margin-top: 16px; padding: 14px; border-radius: var(--radius-s);
  background: var(--brand-soft); color: var(--brand); font-size: 13px;
}
.player-note { margin-top: 14px; font-size: 12px; color: var(--muted); line-height: 1.7; }

/* 登录 */
.login-card { margin: 40px 16px 0; padding: 22px; background: var(--card); border: 1px solid var(--line-2); border-radius: var(--radius-xl); }
.login-card h2 { margin: 0 0 4px; font-size: 20px; font-family: 'Noto Serif SC', serif; }
.login-card p { margin: 0 0 18px; font-size: 13px; color: var(--muted); }
.field { display: block; margin-bottom: 12px; }
.field span { display: block; font-size: 12px; color: var(--sub); margin-bottom: 6px; }
.field input {
  width: 100%; padding: 12px 14px; font-size: 15px;
  border: 1px solid var(--line-2); border-radius: var(--radius-s);
  background: #fbfaf8; outline: none; color: var(--ink);
}
.field input:focus { border-color: var(--brand); background: #fff; }

/* 底部导航 */
.tabbar {
  position: fixed; left: 50%; transform: translateX(-50%);
  bottom: 0; z-index: 45;
  width: 100%; max-width: 560px;
  display: grid; grid-template-columns: repeat(4, 1fr);
  padding: 6px 0 calc(6px + var(--safe-bottom));
  background: rgba(255,255,255,.96); backdrop-filter: blur(14px);
  border-top: 1px solid var(--line-2);
}
.tabbar a {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  padding: 4px 0; font-size: 10px; color: var(--muted);
}
.tabbar a.on { color: var(--brand); }
.tabbar svg { width: 21px; height: 21px; }

/* 状态 */
.empty { padding: 44px 16px; text-align: center; color: var(--muted); font-size: 13px; }
.empty .big { font-size: 28px; margin-bottom: 6px; }
.loading { padding: 30px 16px; text-align: center; color: var(--muted); font-size: 13px; }

.toast {
  position: fixed; left: 50%; bottom: 96px; transform: translate(-50%, 10px);
  z-index: 90; max-width: 80%;
  padding: 10px 16px; border-radius: 10px;
  background: rgba(26,26,26,.92); color: #fff; font-size: 13px;
  opacity: 0; pointer-events: none; transition: all .22s ease;
  text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

.footer-note {
  padding: 28px 16px 26px; text-align: center; font-size: 11px; color: var(--muted);
  letter-spacing: .3px;
}
.fn-brand { font-weight: 600; color: var(--sub); letter-spacing: 1px; }
.fn-sep { margin: 0 6px; }
