:root {
  --bg: #f7f5f0;
  --card: #ffffff;
  --ink: #1d2433;
  --muted: #5d6677;
  --line: #e4e0d6;
  --brand: #1f5f5b;
  --brand-soft: #e3efed;
  --accent: #e07a3f;
  --accent-soft: #fbeadf;
  --warn-bg: #fff6d9;
  --warn-ink: #7a5a00;
  --radius: 14px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
}
a { color: var(--brand); }
.wrap { max-width: 720px; margin: 0 auto; padding: 0 16px; }

/* 样板提示条 */
.draft-bar {
  background: var(--warn-bg);
  color: var(--warn-ink);
  font-size: 13px;
  padding: 8px 16px;
  text-align: center;
  border-bottom: 1px solid #f0e2a8;
}

/* 顶栏 */
.top {
  position: sticky; top: 0; z-index: 10;
  background: rgba(247, 245, 240, 0.96);
  border-bottom: 1px solid var(--line);
}
.top .wrap { display: flex; align-items: center; justify-content: space-between; height: 54px; }
.logo { font-weight: 700; font-size: 18px; color: var(--ink); text-decoration: none; }
.logo small { font-weight: 400; font-size: 12px; color: var(--muted); margin-left: 4px; }
.nav a { margin-left: 14px; font-size: 15px; color: var(--muted); text-decoration: none; }
.nav a.on { color: var(--brand); font-weight: 600; }

/* 首屏 */
.hero { padding: 36px 0 28px; }
.hero h1 { font-size: 28px; line-height: 1.3; margin: 0 0 12px; }
.hero h1 em { font-style: normal; color: var(--brand); }
.hero p.lead { color: var(--muted); margin: 0 0 22px; font-size: 16px; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.tag { background: var(--brand-soft); color: var(--brand); font-size: 13px; padding: 4px 10px; border-radius: 999px; }

.btn {
  display: inline-block; text-align: center; text-decoration: none; cursor: pointer;
  background: var(--accent); color: #fff; font-size: 17px; font-weight: 600;
  border: 0; border-radius: 12px; padding: 14px 22px; min-height: 50px;
  -webkit-appearance: none; appearance: none;
}
.btn.block { display: block; width: 100%; }
.btn.ghost { background: transparent; color: var(--brand); border: 1.5px solid var(--brand); }
.btn:disabled { background: #c9c4b8; cursor: not-allowed; }
.btn-row { display: flex; gap: 10px; flex-wrap: wrap; }
.btn-row .btn { flex: 1 1 140px; }

/* 区块 */
section.blk { padding: 26px 0; border-top: 1px solid var(--line); }
section.blk h2 { font-size: 21px; margin: 0 0 14px; }
.sub { color: var(--muted); font-size: 14px; margin: -6px 0 14px; }

.steps { list-style: none; padding: 0; margin: 0; counter-reset: s; }
.steps li {
  counter-increment: s; position: relative; padding: 12px 14px 12px 52px; margin-bottom: 10px;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
}
.steps li::before {
  content: counter(s); position: absolute; left: 14px; top: 13px;
  width: 26px; height: 26px; border-radius: 50%; background: var(--brand); color: #fff;
  font-size: 14px; font-weight: 700; text-align: center; line-height: 26px;
}
.steps b { display: block; }
.steps span { color: var(--muted); font-size: 14px; }

/* 价格卡 */
.prices { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.price {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 14px;
}
.price.hot { border-color: var(--accent); background: var(--accent-soft); }
.price h3 { margin: 0 0 4px; font-size: 16px; }
.price .num { font-size: 26px; font-weight: 700; color: var(--accent); }
.price .num small { font-size: 14px; color: var(--muted); font-weight: 400; }
.price p { margin: 6px 0 0; font-size: 13px; color: var(--muted); }

.tbd {
  display: inline-block; font-size: 11px; font-weight: 600; color: var(--warn-ink); background: var(--warn-bg);
  border: 1px solid #f0e2a8; border-radius: 6px; padding: 0 6px; margin-left: 6px; vertical-align: 2px;
}

.rules { padding-left: 20px; margin: 0; }
.rules li { margin-bottom: 8px; }

details.faq { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; margin-bottom: 8px; }
details.faq summary { font-weight: 600; cursor: pointer; }
details.faq p { margin: 8px 0 0; color: var(--muted); font-size: 15px; }

/* 老师卡 */
.teachers { display: grid; grid-template-columns: 1fr; gap: 12px; }
.t-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.t-head { display: flex; gap: 12px; align-items: center; margin-bottom: 10px; }
.avatar {
  width: 56px; height: 56px; border-radius: 50%; flex: none;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 700; font-size: 20px;
}
.t-name { font-weight: 700; font-size: 17px; }
.t-meta { color: var(--muted); font-size: 13px; }
.t-card .chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.chip { font-size: 12px; padding: 3px 8px; border-radius: 999px; background: var(--brand-soft); color: var(--brand); }
.t-intro { font-size: 15px; margin: 6px 0 10px; }
.t-video {
  font-size: 13px; color: var(--muted); background: #f1efe9; border-radius: 10px; padding: 10px; text-align: center; margin-bottom: 12px;
}

/* 约课表单 */
.form-step { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin-bottom: 12px; }
.form-step h3 { margin: 0 0 4px; font-size: 17px; }
.form-step .hint { color: var(--muted); font-size: 13px; margin: 0 0 12px; }
.opts { display: flex; flex-wrap: wrap; gap: 8px; }
.opt {
  border: 1.5px solid var(--line); background: #fff; color: var(--ink); border-radius: 10px;
  padding: 9px 12px; font-size: 15px; cursor: pointer; min-height: 42px;
  -webkit-appearance: none; appearance: none; font-family: inherit;
}
.opt.on { border-color: var(--brand); background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.opts.grid4 .opt { flex: 1 1 calc(25% - 8px); text-align: center; padding: 9px 4px; }
.opts.grid3 .opt { flex: 1 1 calc(33.33% - 8px); text-align: center; padding: 9px 4px; }
.field { display: block; margin-bottom: 10px; }
.field span { display: block; font-size: 14px; color: var(--muted); margin-bottom: 4px; }
.field input, .field select, .field textarea {
  width: 100%; font-size: 16px; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 10px;
  background: #fff; color: var(--ink); font-family: inherit;
}
.check { display: flex; gap: 8px; align-items: flex-start; font-size: 15px; margin: 4px 0 14px; }
.check input { width: 20px; height: 20px; margin-top: 2px; flex: none; }
.check.need { outline: 2px solid var(--accent, #e07a3f); outline-offset: 6px; border-radius: 6px; }
.err { color: #b3261e; font-size: 14px; margin: 0 0 10px; min-height: 0; }

.result { background: var(--card); border: 2px solid var(--brand); border-radius: var(--radius); padding: 16px; margin-bottom: 12px; }
.result h3 { margin: 0 0 8px; }
.result pre {
  white-space: pre-wrap; word-break: break-all; background: #f4f7f6; border-radius: 10px; padding: 12px;
  font-family: inherit; font-size: 15px; margin: 0 0 12px;
}
.wechat { display: flex; gap: 14px; align-items: center; margin-top: 14px; }
.qr {
  width: 120px; height: 120px; flex: none; border: 2px dashed #c9c4b8; border-radius: 10px;
  display: flex; align-items: center; justify-content: center; text-align: center; color: var(--muted); font-size: 13px;
}
.tprice { color: var(--accent); font-size: 1.08em; }
.qr.has-img { width: 150px; height: 150px; border: 0; background: #fff; padding: 6px; }
.wechat p { margin: 0; font-size: 14px; color: var(--muted); }
.wechat b { color: var(--ink); }
.toast {
  position: fixed; left: 50%; bottom: 40px; transform: translateX(-50%);
  background: rgba(29, 36, 51, 0.92); color: #fff; padding: 10px 18px; border-radius: 10px; font-size: 15px;
  opacity: 0; transition: opacity .2s; pointer-events: none; z-index: 50;
}
.toast.show { opacity: 1; }

/* 底部 */
footer { border-top: 1px solid var(--line); padding: 22px 0 40px; color: var(--muted); font-size: 13px; }
footer p { margin: 0 0 6px; }

.sticky-cta {
  position: sticky; bottom: 0; background: rgba(247, 245, 240, 0.97); border-top: 1px solid var(--line);
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
}

@media (min-width: 640px) {
  .hero h1 { font-size: 34px; }
  .teachers { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 360px) {
  .prices { grid-template-columns: 1fr; }
  .nav a { margin-left: 10px; font-size: 14px; }
}

/* ===== PC 端（11-30：用户要先按 PC 做） ===== */
@media (min-width: 960px) {
  body { font-size: 16px; }
  .wrap { max-width: 1120px; padding: 0 32px; }
  .top .wrap { height: 64px; }
  .logo { font-size: 20px; }
  .nav a { margin-left: 28px; font-size: 16px; }
  .hero { padding: 64px 0 48px; max-width: 760px; }
  .hero h1 { font-size: 46px; }
  .hero p.lead { font-size: 18px; }
  .btn-row .btn { flex: 0 0 auto; min-width: 180px; }
  section.blk { padding: 40px 0; }
  section.blk h2 { font-size: 26px; }
  .steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
  .steps li { margin-bottom: 0; }
  .prices { grid-template-columns: repeat(2, 320px); gap: 16px; }
  .rules { columns: 2; column-gap: 48px; }
  .rules li { break-inside: avoid; }
  .faq-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
  .sticky-cta { display: none; }
  .teachers { grid-template-columns: repeat(3, 1fr); gap: 16px; }
  #resultArea { max-width: 720px; }
}

/* ===== 11-30 v2：课程 / 老师库 / 周时间表 ===== */
.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 16px; }
.tabs button {
  border: 1.5px solid var(--line); background: #fff; color: var(--ink); border-radius: 999px;
  padding: 6px 14px; font-size: 14px; cursor: pointer; font-family: inherit;
}
.tabs button.on { border-color: var(--brand); background: var(--brand); color: #fff; }
.search { width: 100%; max-width: 320px; font-size: 15px; padding: 8px 12px; border: 1.5px solid var(--line); border-radius: 10px; margin-bottom: 12px; font-family: inherit; }

.t-code { font-size: 12px; color: var(--muted); font-weight: 400; margin-left: 6px; }
.heat { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; margin: 8px 0 12px; }
.heat div { text-align: center; font-size: 11px; color: var(--muted); }
.heat span {
  display: block; height: 22px; line-height: 22px; border-radius: 6px; font-size: 12px; font-weight: 600; margin-top: 2px;
  background: #efede7; color: #a8a396;
}
.heat span.l1 { background: #d6ebe7; color: var(--brand); }
.heat span.l2 { background: #9fcdc4; color: #0f3b38; }
.heat span.l3 { background: var(--brand); color: #fff; }
.heat-cap { font-size: 12px; color: var(--muted); margin-top: -6px; margin-bottom: 10px; }

.courses { display: grid; grid-template-columns: 1fr; gap: 12px; }
.c-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.c-card h3 { margin: 0 0 6px; font-size: 18px; }
.c-card .ic { font-size: 22px; margin-right: 6px; }
.c-card p { margin: 4px 0; font-size: 14px; color: var(--muted); }
.c-card p b { color: var(--ink); font-weight: 600; }

.svc { display: grid; grid-template-columns: 1fr; gap: 10px; }
.svc div { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; }
.svc b { display: block; }
.svc span { font-size: 14px; color: var(--muted); }

.plans { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.plan {
  text-align: left; background: var(--card); border: 1.5px solid var(--line); border-radius: var(--radius); padding: 14px;
  cursor: pointer; font-family: inherit; color: var(--ink); -webkit-appearance: none; appearance: none;
}
.plan.hot { border-color: var(--accent); }
.plan.on { border-color: var(--brand); background: var(--brand-soft); box-shadow: 0 0 0 1px var(--brand) inset; }
.plan b { display: block; font-size: 15px; }
.plan .num { font-size: 22px; font-weight: 700; color: var(--accent); }
.plan small { color: var(--muted); font-size: 13px; }

.wk-legend { display: flex; gap: 14px; font-size: 13px; color: var(--muted); margin: 8px 0; flex-wrap: wrap; }
.wk-legend i { display: inline-block; width: 14px; height: 14px; border-radius: 4px; vertical-align: -2px; margin-right: 4px; }
.picked { font-size: 15px; margin: 8px 0 0; }
.pick-t { display: flex; gap: 10px; align-items: center; }
.t-pick-list { display: grid; grid-template-columns: 1fr; gap: 8px; max-height: 420px; overflow-y: auto; padding-right: 4px; }
.t-pick {
  display: flex; gap: 10px; align-items: center; text-align: left; width: 100%;
  border: 1.5px solid var(--line); background: #fff; border-radius: 12px; padding: 8px 10px; cursor: pointer; font-family: inherit; color: var(--ink);
}
.t-pick.on { border-color: var(--brand); background: var(--brand-soft); }
.t-pick .meta { font-size: 12px; color: var(--muted); }

@media (min-width: 960px) {
  .courses { grid-template-columns: repeat(3, 1fr); gap: 16px; }
  .svc { grid-template-columns: repeat(4, 1fr); gap: 14px; }
  .plans { grid-template-columns: repeat(4, 1fr); }
  .book-grid { display: grid; grid-template-columns: 360px 1fr; gap: 16px; align-items: start; }
  .t-pick-list { grid-template-columns: 1fr; max-height: 640px; }
}

/* ===== 11-30 v3：头像视频 + 普通约课 / 固定课 ===== */
.t-tools { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; }
.t-tools .search { margin: 0; }
.day-pick { font-size: 14px; color: var(--muted); }
.day-pick select { font-size: 15px; padding: 7px 10px; border: 1.5px solid var(--line); border-radius: 10px; margin-left: 6px; background: #fff; font-family: inherit; }
.btn.sm { font-size: 14px; padding: 7px 14px; min-height: 0; border-radius: 10px; }
.btn.off { color: #a8a396; border-color: #e4e0d6; cursor: default; }
.t-btns { display: flex; gap: 8px; }
.t-btns .btn { flex: 1; }
.t-card .soon { color: var(--brand); }
img.avatar { background: #eee; }

.modal { position: fixed; inset: 0; background: rgba(20, 24, 32, .72); z-index: 60; display: flex; align-items: center; justify-content: center; padding: 16px; }
.modal-in { background: #fff; border-radius: var(--radius); width: 100%; max-width: 760px; padding: 12px; }
.modal-h { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.modal-x { border: 0; background: none; font-size: 28px; line-height: 1; cursor: pointer; color: var(--muted); }
.modal video { width: 100%; max-height: 70vh; background: #000; border-radius: 10px; display: block; }
.modal .hint { font-size: 13px; color: var(--muted); margin: 8px 0 0; }

.mode { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 14px; }
.mode button {
  border: 1.5px solid var(--line); background: #fff; border-radius: 12px; padding: 10px; cursor: pointer;
  font-family: inherit; font-size: 16px; font-weight: 700; color: var(--ink);
}
.mode button small { display: block; font-size: 12px; font-weight: 400; color: var(--muted); }
.mode button.on { border-color: var(--brand); background: var(--brand); color: #fff; }
.mode button.on small { color: #d6ebe7; }

.dtabs { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 6px; margin-bottom: 8px; -webkit-overflow-scrolling: touch; }
.dtabs button {
  position: relative; flex: 0 0 auto; min-width: 78px; border: 1.5px solid var(--line); background: #fff; border-radius: 10px;
  padding: 6px 8px; cursor: pointer; font-family: inherit; color: var(--ink); text-align: center;
}
.dtabs button b { display: block; font-size: 14px; }
.dtabs button small { font-size: 11px; color: var(--muted); }
.dtabs button.none { opacity: .55; }
.dtabs button.on { border-color: var(--brand); background: var(--brand-soft); }
.dtabs button i {
  position: absolute; top: -6px; right: -4px; font-style: normal; font-size: 11px; background: var(--accent); color: #fff;
  border-radius: 999px; min-width: 18px; height: 18px; line-height: 18px; padding: 0 4px;
}
.slots { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.slot {
  border: 1px solid #9fcdc4; background: var(--brand-soft); color: var(--ink); border-radius: 8px; padding: 9px 0;
  font-size: 15px; font-family: inherit; cursor: pointer; line-height: 1.2;
}
.slot small { display: block; font-size: 10px; color: var(--muted); }
.slot:hover { background: #cfe6e1; }
.slot.full { background: #eceae4; border-color: #eceae4; color: #a8a396; cursor: default; }
.slot.sel { background: var(--accent); border-color: var(--accent); color: #fff; }
.slot.sel small { color: #fde3d3; }
.empty { color: var(--muted); font-size: 14px; grid-column: 1 / -1; margin: 6px 0; }
.rule-box { background: var(--warn-bg); border: 1px solid #f0e2a8; border-radius: 10px; padding: 10px 12px; font-size: 13px; margin-bottom: 12px; }
.rule-box ul { margin: 4px 0 0; padding-left: 18px; color: var(--warn-ink); }
.confirm-bar { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.confirm-bar span { font-size: 15px; font-weight: 600; }
.confirm-bar .btn { flex: 1 1 200px; }

@media (min-width: 960px) {
  .slots { grid-template-columns: repeat(8, 1fr); }
  .dtabs { overflow: visible; }
  .dtabs button { flex: 1 1 0; min-width: 0; padding: 6px 2px; }
  .book-grid { grid-template-columns: 320px 1fr; }
  .confirm-bar .btn { flex: 0 0 240px; }
}

/* ===== 12-01 账号 / 我的 / 客服 / 教材库 / 后台 ===== */
.nav a.logged::after { content: ''; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: #2f9e6a; margin-left: 3px; vertical-align: 6px; }
@media (max-width: 639px) {
  .nav a.home { display: none; }
  .nav a { margin-left: 11px; font-size: 14px; }
  .logo small { display: none; }
}

.kefu-fab {
  position: fixed; right: 14px; bottom: calc(20px + env(safe-area-inset-bottom)); z-index: 40;
  background: var(--brand); color: #fff; border: 0; border-radius: 999px; padding: 10px 16px 10px 12px;
  font-size: 15px; font-weight: 600; font-family: inherit; box-shadow: 0 4px 14px rgba(20, 40, 40, .25); cursor: pointer;
}
.kefu-fab span { margin-right: 4px; }
.kefu-fab.up { bottom: calc(84px + env(safe-area-inset-bottom)); }
@media (min-width: 960px) { .kefu-fab.up { bottom: 28px; } .kefu-fab { right: 28px; bottom: 28px; } }
.kefu-in { max-width: 360px; text-align: center; padding: 14px 18px 18px; }
.kefu-in .modal-h { text-align: left; }
.kefu-qr { width: 220px; height: 220px; object-fit: contain; display: block; margin: 4px auto 8px; }
.kefu-id { margin: 0 0 6px; font-size: 16px; }
.kefu-in .hint { text-align: left; }

/* 登录 / 注册 */
.auth { max-width: 420px; margin: 28px auto 40px; }
.auth .tabs button { flex: 1 1 0; }
.check.small { font-size: 13px; color: var(--muted); margin: 0 0 10px; }
.check.small a { color: var(--brand); }
.privacy { font-size: 13px; color: var(--muted); background: #f1efe9; border-radius: 10px; padding: 10px 12px; margin: 0 0 12px; }
.privacy p { margin: 0 0 6px; }

/* 我的 */
.me-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin: 20px 0 14px; }
.me-head h2 { margin: 0; font-size: 22px; }
.me-head .meta { color: var(--muted); font-size: 13px; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 16px; }
.stats div { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 10px 8px; text-align: center; }
.stats b { display: block; font-size: 20px; }
.stats span { font-size: 12px; color: var(--muted); }
.lesson { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; margin-bottom: 10px; }
.lesson .row1 { display: flex; justify-content: space-between; gap: 8px; align-items: flex-start; }
.lesson .when { font-weight: 700; font-size: 16px; }
.lesson .who { color: var(--muted); font-size: 14px; margin-top: 2px; }
.lesson .meet { background: var(--brand-soft); border-radius: 10px; padding: 8px 10px; margin: 10px 0 0; font-size: 14px; }
.lesson .acts { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.lesson details { margin-top: 10px; font-size: 14px; }
.lesson details summary { cursor: pointer; color: var(--brand); }
.notes { margin: 8px 0; padding: 0; list-style: none; }
.notes li { font-size: 13px; padding: 6px 10px; border-radius: 8px; background: #f4f2ec; margin-bottom: 6px; }
.notes li.admin { background: var(--brand-soft); }
.notes li small { color: var(--muted); margin-left: 6px; }
.note-form { display: flex; gap: 8px; }
.note-form input { flex: 1; font-size: 15px; padding: 8px 10px; border: 1.5px solid var(--line); border-radius: 10px; font-family: inherit; min-width: 0; }
.badges { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.badge { font-size: 12px; padding: 2px 8px; border-radius: 999px; white-space: nowrap; background: #eceae4; color: var(--muted); }
.badge.pending, .badge.cancel_req { background: var(--warn-bg); color: var(--warn-ink); }
.badge.booked { background: var(--brand-soft); color: var(--brand); }
.badge.done { background: #e2f3e8; color: #23764a; }
.badge.s_absent, .badge.t_absent, .badge.declined, .badge.canceled { background: #f6e3df; color: #a2402e; }
.badge.unpaid { background: var(--accent-soft); color: #b35a22; }
.badge.paid { background: #e2f3e8; color: #23764a; }
.badge.fix { background: #e8e6f6; color: #5b52a3; }
.howto { font-size: 13px; color: var(--muted); padding-left: 18px; margin: 6px 0 0; }
.bill { width: 100%; border-collapse: collapse; font-size: 14px; background: var(--card); border-radius: var(--radius); overflow: hidden; }
.bill th, .bill td { padding: 9px 10px; border-bottom: 1px solid var(--line); text-align: left; }
.bill th { background: #f1efe9; font-weight: 600; font-size: 13px; color: var(--muted); }
.bill td.num, .bill th.num { text-align: right; }

/* 教材库 */
.books { display: grid; grid-template-columns: 1fr; gap: 12px; }
.book { display: flex; gap: 12px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; }
.book .cover {
  flex: none; width: 74px; height: 98px; border-radius: 8px; color: #fff; font-size: 13px; font-weight: 700; line-height: 1.3;
  display: flex; align-items: flex-end; padding: 8px; box-shadow: inset -6px 0 0 rgba(0, 0, 0, .12);
}
.book h3 { margin: 0 0 4px; font-size: 16px; }
.book p { margin: 0 0 8px; font-size: 13px; color: var(--muted); }
.book .grp { font-size: 12px; color: var(--brand); }
@media (min-width: 960px) {
  .books { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .stats { gap: 14px; }
}

/* 后台 */
.admin .wrap { max-width: 1240px; }
.adm-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; margin-bottom: 12px; }
.adm-card h3 { margin: 0 0 6px; font-size: 16px; }
.adm-card .meta { color: var(--muted); font-size: 13px; }
.adm-grid { display: grid; grid-template-columns: 1fr; gap: 8px; }
.adm-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding: 8px 0; border-top: 1px dashed var(--line); font-size: 14px; }
.adm-row:first-child { border-top: 0; }
.adm-row input, .adm-row select { font-size: 14px; padding: 6px 8px; border: 1.5px solid var(--line); border-radius: 8px; font-family: inherit; background: #fff; max-width: 100%; }
.adm-row .grow { flex: 1 1 160px; }
.day-h { font-weight: 700; margin: 18px 0 6px; font-size: 15px; }
.adm-table { width: 100%; border-collapse: collapse; font-size: 14px; background: var(--card); }
.adm-table th, .adm-table td { padding: 8px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.adm-table th { background: #f1efe9; font-size: 13px; color: var(--muted); }
.adm-table tr.click { cursor: pointer; }
.adm-table tr.click:hover td { background: #faf9f5; }
.scroll-x { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: var(--radius); }
.tabs .n { display: inline-block; min-width: 18px; padding: 0 5px; margin-left: 4px; border-radius: 999px; background: var(--accent); color: #fff; font-size: 12px; line-height: 18px; }
.ok-bar { background: #e2f3e8; color: #23764a; border-radius: 10px; padding: 8px 12px; font-size: 14px; margin-bottom: 12px; }
/* 12-01 验收小修：「我的」顶部按钮横排；页脚给右下角客服按钮让位 */
.me-head .btn-row { display: flex; flex-direction: row; flex-wrap: wrap; gap: 8px; }
.me-head .btn-row .btn { width: auto; display: inline-block; }
footer { padding-bottom: 76px; }
.me-head .btn-row .btn { flex: 0 0 auto; min-width: 0; }
/* 12-01 课卡：本节教材 / 老师反馈（对标「我的学习书单」「老师反馈」）*/
.lesson .bookline { font-size: 14px; margin: 8px 0 0; color: var(--ink, #222); }
.lesson .bookline a { color: var(--brand); }
.lesson .who a { color: var(--brand); }
.lesson .fb { background: #f1efe9; border-radius: 10px; padding: 8px 12px; margin: 10px 0 0; font-size: 14px; }
.lesson .fb p { margin: 4px 0 0; }
.book.hl { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 12px; }
/* 12-01 教材：真封面 + 详情弹窗（目录 / 课件）*/
.book { cursor: pointer; }
.book img.cover { flex: none; width: 74px; height: 98px; object-fit: cover; border-radius: 8px; background: #eee; box-shadow: 0 1px 3px rgba(0,0,0,.15); padding: 0; }
.book-detail { max-width: 560px; width: 100%; max-height: 88vh; overflow-y: auto; }
.book-detail .bd-top { display: flex; gap: 14px; align-items: flex-start; margin: 10px 0; }
.book-detail .bd-top img { width: 110px; border-radius: 8px; flex: none; box-shadow: 0 1px 4px rgba(0,0,0,.2); }
.book-detail .bd-top p { font-size: 14px; color: var(--muted); margin: 6px 0 10px; line-height: 1.6; }
.book-detail .grp { font-size: 12px; color: var(--brand); }
.book-detail h4 { margin: 14px 0 6px; }
.book-detail .unit { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 8px 0; border-top: 1px dashed var(--line); font-size: 14px; flex-wrap: wrap; }
.lesson .bookcover { width: 44px; border-radius: 6px; float: left; margin: 0 10px 0 0; }
@media (max-width: 480px) { .book-detail .bd-top img { width: 84px; } }

/* 教材库：系列小按钮（12-01 全量 125 本） */
.tabs.series { gap: 6px; margin-top: -6px; }
.tabs.series button { font-size: 13px; padding: 4px 10px; }
/* 课件多的书（最多 80 条）：详情往下滚时标题和 × 留在顶上 */
.book-detail .modal-h { position: sticky; top: -12px; background: #fff; z-index: 1; margin: -12px -12px 0; padding: 12px; border-bottom: 1px solid var(--line); }
/* 教材库只分两类：成人 / 青少年，做成左右两大块 */
.tabs.cat2 { flex-wrap: nowrap; }
.tabs.cat2 button { flex: 1 1 0; font-size: 16px; padding: 10px 12px; font-weight: 600; }
.tabs.cat2 button small { font-weight: 400; opacity: .8; font-size: 13px; }
