:root {
  --bg: #f7f8fc;
  --surface: #ffffff;
  --text: #101828;
  --muted: #667085;
  --line: #e7e9f2;
  --brand: #3b5bfd;
  --brand-600: #2c46d8;
  --brand-soft: #eef1ff;
  --accent: #ff7a45;
  --ok: #12b76a;
  --warn: #f79009;
  --danger: #f04438;
  --radius: 14px;
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, .05);
  --shadow-md: 0 12px 30px -18px rgba(16, 24, 40, .28);
  --shadow-lg: 0 30px 60px -40px rgba(16, 24, 40, .45);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", "PingFang SC", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 14.5px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4, h5 { margin: 0; font-weight: 700; letter-spacing: -.01em; }
p { margin: 0; }
img { max-width: 100%; }
button { font-family: inherit; }
input, select, textarea { font-family: inherit; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .92em; }

.wrap { max-width: 1180px; margin: 0 auto; padding: 0 24px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.tiny { font-size: 12px; }
.bold { font-weight: 700; }
.nowrap { white-space: nowrap; }
.row { display: flex; align-items: center; gap: 10px; }
.between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.col { display: flex; flex-direction: column; gap: 10px; }
.grow { flex: 1; }
.mt-8 { margin-top: 8px; } .mt-16 { margin-top: 16px; } .mt-24 { margin-top: 24px; }
.hidden { display: none !important; }

/* ------------------------------ 按钮 / 表单 ------------------------------ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 40px; padding: 0 18px; border-radius: 10px;
  font-size: 14.5px; font-weight: 600; border: 1px solid transparent;
  cursor: pointer; transition: .18s ease; white-space: nowrap; background: none; color: var(--text);
}
.btn-primary { background: var(--brand); color: #fff; box-shadow: 0 8px 18px -8px rgba(59, 91, 253, .7); }
.btn-primary:hover { background: var(--brand-600); transform: translateY(-1px); }
.btn-ghost { background: #fff; border-color: var(--line); color: #344054; }
.btn-ghost:hover { border-color: #c9d0e3; background: #fbfcff; }
.btn-soft { background: var(--brand-soft); color: var(--brand); }
.btn-soft:hover { background: #e3e8ff; }
.btn-dark { background: #101828; color: #fff; }
.btn-dark:hover { background: #1d2939; }
.btn-danger { background: #fef3f2; color: #b42318; }
.btn-danger:hover { background: #fee4e2; }
.btn-sm { height: 32px; padding: 0 12px; font-size: 13px; border-radius: 8px; }
.btn-lg { height: 48px; padding: 0 26px; font-size: 15.5px; border-radius: 12px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; transform: none !important; }
.btn-link { border: 0; background: none; color: var(--brand); font-weight: 600; cursor: pointer; padding: 0; height: auto; font-size: 13.5px; }
.btn-link:hover { text-decoration: underline; }

.input {
  width: 100%; height: 44px; padding: 0 14px; border-radius: 10px;
  border: 1px solid var(--line); font-size: 14.5px; background: #fff;
  color: var(--text); outline: none; transition: .15s;
}
.input::placeholder { color: #98a2b3; }
.input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(59, 91, 253, .12); }
textarea.input { height: auto; padding: 11px 14px; resize: vertical; line-height: 1.65; }
select.input { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23667085' d='M1 1l5 5 5-5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 34px; }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 13px; font-weight: 600; color: #344054; margin-bottom: 6px; }
.field .hint { font-size: 12px; color: #98a2b3; margin-top: 5px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

/* -------------------------------- 顶栏 -------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 80;
  background: rgba(255, 255, 255, .88);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.header-in { height: 68px; display: flex; align-items: center; gap: 18px; }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 19px; letter-spacing: -.03em; white-space: nowrap; flex: none; }
.logo-mark {
  width: 34px; height: 34px; border-radius: 10px; flex: none;
  background: linear-gradient(135deg, #3b5bfd, #7a4dff);
  color: #fff; display: grid; place-items: center;
  box-shadow: 0 6px 14px -6px rgba(59, 91, 253, .8);
}
.logo-mark svg { width: 19px; height: 19px; }
.main-nav { display: flex; gap: 4px; }
.main-nav a { padding: 8px 12px; border-radius: 9px; color: #566073; font-size: 14.5px; font-weight: 500; transition: .15s; white-space: nowrap; }
.main-nav a:hover { color: var(--text); background: #f4f5fa; }
.main-nav a.active { color: var(--brand); background: var(--brand-soft); font-weight: 600; }
.search { margin-left: auto; position: relative; width: 208px; flex: 0 0 auto; }
.search input { width: 100%; height: 38px; padding: 0 12px 0 36px; border-radius: 10px; border: 1px solid var(--line); background: #f8f9fc; font-size: 13.5px; outline: none; transition: .15s; }
.search input:focus { background: #fff; border-color: #c7d2fe; box-shadow: 0 0 0 3px rgba(59, 91, 253, .1); }
.search svg { position: absolute; left: 12px; top: 11px; width: 15px; height: 15px; opacity: .45; }
.header-actions { display: flex; align-items: center; gap: 8px; flex: none; margin-left: auto; }

.user-menu { position: relative; }
.user-btn { display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); background: #fff; border-radius: 99px; padding: 4px 10px 4px 4px; cursor: pointer; transition: .15s; }
.user-btn:hover { border-color: #c9d0e3; box-shadow: var(--shadow-sm); }
.avatar { width: 30px; height: 30px; border-radius: 50%; background: linear-gradient(135deg, #5b74ff, #9b6bff); color: #fff; display: grid; place-items: center; font-size: 13px; font-weight: 700; flex: none; }
.avatar-lg { width: 56px; height: 56px; font-size: 20px; }
.dropdown {
  position: absolute; right: 0; top: calc(100% + 8px); min-width: 200px;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  box-shadow: 0 22px 40px -24px rgba(16, 24, 40, .35); padding: 6px;
  display: none; z-index: 90;
}
.dropdown.open { display: block; animation: pop .16s ease; }
.dropdown .dd-head { padding: 10px 11px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.dropdown a, .dropdown button {
  display: flex; width: 100%; align-items: center; gap: 9px; padding: 9px 11px;
  border-radius: 8px; font-size: 13.8px; color: #374151; border: 0; background: none;
  cursor: pointer; text-align: left; transition: .12s;
}
.dropdown a:hover, .dropdown button:hover { background: #f6f7fb; color: var(--text); }

/* --------------------------------- 首页 --------------------------------- */
.hero { position: relative; overflow: hidden; padding: 58px 0 46px; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: 0;
  background:
    radial-gradient(900px 380px at 78% -10%, rgba(91, 116, 255, .18), transparent 65%),
    radial-gradient(600px 300px at 10% 10%, rgba(155, 107, 255, .12), transparent 60%);
}
.hero-in { position: relative; z-index: 1; display: grid; grid-template-columns: 1.15fr .85fr; gap: 46px; align-items: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 7px; height: 28px; padding: 0 12px;
  border-radius: 99px; background: #fff; border: 1px solid #dfe4f7;
  font-size: 12.5px; font-weight: 600; color: var(--brand); box-shadow: var(--shadow-sm);
}
.hero h1 { font-size: 43px; line-height: 1.16; letter-spacing: -.035em; margin: 18px 0 14px; font-weight: 800; }
.hero h1 em { font-style: normal; color: var(--brand); }
.hero .lead { font-size: 16px; color: #5a6478; max-width: 520px; line-height: 1.7; }
.hero-cta { display: flex; gap: 12px; margin-top: 26px; flex-wrap: wrap; }
.hero-stats { display: flex; gap: 38px; margin-top: 38px; padding-top: 24px; border-top: 1px solid rgba(16, 24, 40, .07); }
.hero-stats .n { font-size: 24px; font-weight: 800; letter-spacing: -.02em; }
.hero-stats .l { font-size: 12.5px; color: var(--muted); }

.hero-card {
  background: #fff; border: 1px solid var(--line); border-radius: 18px;
  padding: 14px; box-shadow: 0 40px 80px -46px rgba(16, 24, 40, .55);
  transform: rotate(-1deg);
}
.hero-card img { border-radius: 12px; display: block; aspect-ratio: 16/9; object-fit: cover; width: 100%; }
.hero-card-body { padding: 13px 6px 4px; }
.hero-card-title { font-size: 14.5px; font-weight: 700; margin-bottom: 10px; }
.mini-tag { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px; border-radius: 6px; background: #f2f4f7; font-size: 11.5px; color: #475467; font-weight: 600; }

.section { padding: 34px 0; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.section-head h2 { font-size: 23px; letter-spacing: -.025em; }
.section-head p { color: var(--muted); font-size: 13.5px; margin-top: 5px; }

.chips { display: flex; gap: 9px; flex-wrap: wrap; }
.chip {
  height: 34px; padding: 0 15px; border-radius: 99px; border: 1px solid var(--line);
  background: #fff; font-size: 13.5px; color: #475467; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px; transition: .15s; font-weight: 500;
}
.chip:hover { border-color: #c7d2fe; color: var(--brand); }
.chip.active { background: #101828; border-color: #101828; color: #fff; }
.chip .cnt { opacity: .55; font-size: 12px; }

.course-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.course-card {
  background: #fff; border: 1px solid var(--line); border-radius: 16px;
  overflow: hidden; display: flex; flex-direction: column;
  transition: .2s ease; cursor: pointer;
}
.course-card:hover { transform: translateY(-3px); box-shadow: 0 22px 44px -28px rgba(16, 24, 40, .42); border-color: #dbe0f2; }
.course-cover { position: relative; aspect-ratio: 16/9; background: #eef1ff; overflow: hidden; }
.course-cover img { width: 100%; height: 100%; object-fit: cover; display: block; transition: .4s; }
.course-card:hover .course-cover img { transform: scale(1.035); }
.cover-badge { position: absolute; top: 11px; right: 11px; display: flex; gap: 6px; }
.cover-chip {
  height: 23px; padding: 0 9px; border-radius: 6px; font-size: 11.5px; font-weight: 700;
  display: inline-flex; align-items: center; background: rgba(255, 255, 255, .92); color: #344054;
  backdrop-filter: blur(4px);
}
.cover-chip.free { background: var(--ok); color: #fff; }
.course-body { padding: 15px 17px 16px; display: flex; flex-direction: column; gap: 7px; flex: 1; }
.course-title { font-size: 15.5px; font-weight: 700; line-height: 1.45; letter-spacing: -.01em; }
.course-sub { font-size: 12.8px; color: var(--muted); line-height: 1.55; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 40px; }
.course-meta { display: flex; align-items: center; gap: 10px; font-size: 12.3px; color: #98a2b3; margin-top: 2px; }
.course-meta .dot { width: 3px; height: 3px; border-radius: 50%; background: #d0d5dd; }
.course-foot { margin-top: auto; padding-top: 11px; display: flex; align-items: center; justify-content: space-between; border-top: 1px solid #f4f5fa; }
.price { color: #e5484d; font-weight: 800; font-size: 17px; letter-spacing: -.02em; }
.price small { font-size: 11.5px; font-weight: 600; }
.price .old { color: #b4b9c6; font-size: 12px; text-decoration: line-through; font-weight: 500; margin-left: 6px; }
.price.free { color: var(--ok); }
.rating { color: #f79009; font-weight: 700; font-size: 12.8px; display: inline-flex; align-items: center; gap: 3px; }
.teacher-line { font-size: 12.5px; color: #667085; }

.value-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.value-card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 20px; }
.value-card .ico { width: 38px; height: 38px; border-radius: 10px; background: var(--brand-soft); display: grid; place-items: center; margin-bottom: 12px; font-size: 17px; }
.value-card h4 { font-size: 14.5px; margin-bottom: 6px; }
.value-card p { font-size: 13px; color: var(--muted); line-height: 1.65; }

.cta-band {
  background: linear-gradient(120deg, #16205c, #2d3fb8 55%, #5b3bfd);
  border-radius: 20px; padding: 38px 42px; color: #fff; display: flex;
  align-items: center; justify-content: space-between; gap: 24px; margin: 26px 0 10px;
  overflow: hidden; position: relative;
}
.cta-band h3 { font-size: 25px; letter-spacing: -.02em; margin-bottom: 8px; }
.cta-band p { color: rgba(255, 255, 255, .78); font-size: 14px; }
.cta-band .btn-primary { background: #fff; color: #1e2a78; box-shadow: 0 12px 24px -14px #000; }

/* --------------------------------- 列表页 -------------------------------- */
.page-head { padding: 30px 0 8px; }
.page-head h1 { font-size: 28px; letter-spacing: -.03em; }
.page-head p { color: var(--muted); margin-top: 6px; }
.catalog { display: grid; grid-template-columns: 226px 1fr; gap: 26px; align-items: start; padding: 18px 0 46px; }
.filter-panel { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 18px; position: sticky; top: 88px; }
.filter-group + .filter-group { margin-top: 18px; padding-top: 16px; border-top: 1px dashed var(--line); }
.filter-title { font-size: 11.5px; text-transform: uppercase; letter-spacing: .09em; color: #98a2b3; font-weight: 700; margin-bottom: 9px; }
.filter-item { display: flex; align-items: center; justify-content: space-between; padding: 7px 10px; border-radius: 8px; font-size: 13.8px; cursor: pointer; color: #475467; transition: .12s; }
.filter-item:hover { background: #f6f7fb; }
.filter-item.active { background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.filter-item .n { font-size: 12px; opacity: .55; }
.catalog-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.seg { display: inline-flex; background: #f1f3f9; padding: 3px; border-radius: 10px; gap: 2px; }
.seg button { height: 31px; padding: 0 13px; border-radius: 8px; font-size: 13px; color: #667085; border: 0; background: transparent; cursor: pointer; font-weight: 500; transition: .15s; }
.seg button.active { background: #fff; color: var(--text); font-weight: 600; box-shadow: 0 1px 3px rgba(16, 24, 40, .12); }
.pager { display: flex; justify-content: center; gap: 6px; margin-top: 30px; }
.pager button { min-width: 34px; height: 34px; border-radius: 8px; border: 1px solid var(--line); background: #fff; cursor: pointer; font-size: 13.5px; color: #475467; }
.pager button.active { background: var(--brand); border-color: var(--brand); color: #fff; font-weight: 600; }
.pager button[disabled] { opacity: .4; cursor: not-allowed; }
/* 链接式页码（学员/教师/管理员列表） */
.pager { flex-wrap: wrap; align-items: center; }
.pager .pg { min-width: 34px; height: 34px; padding: 0 10px; display: inline-flex; align-items: center; justify-content: center; border-radius: 8px; border: 1px solid var(--line); background: #fff; font-size: 13.5px; color: #475467; text-decoration: none; }
.pager .pg:hover { border-color: var(--brand); color: var(--brand); }
.pager .pg.active { background: var(--brand); border-color: var(--brand); color: #fff; font-weight: 600; }
.pager .pg.is-off { opacity: .4; cursor: not-allowed; }
.pager .pg.is-off:hover { border-color: var(--line); color: #475467; }
.pager .pager-gap { color: #98a2b3; padding: 0 2px; }
.pager .pager-info { margin-left: 10px; font-size: 12.5px; color: #667085; }
/* 表格下方自动生成的页码条，间距比独立页面分页小一点 */
.pager[data-paged] { margin-top: 16px; }
/* 只有一页时的「共 N 条」：单独一行居中，不再和表格 / 分隔线贴在一起 */
.pager-solo { margin-top: 16px; }
.pager-solo .pager-info { margin-left: 0; }

/* --------------------------------- 详情页 -------------------------------- */
.breadcrumb { padding: 18px 0 0; font-size: 13px; color: #98a2b3; display: flex; gap: 7px; align-items: center; }
.breadcrumb a:hover { color: var(--brand); }
.detail-band { background: linear-gradient(180deg, #eef1ff, #f7f8fc); border-bottom: 1px solid var(--line); margin-top: -1px; }
.detail-grid { display: grid; grid-template-columns: 1fr 348px; gap: 34px; align-items: start; padding: 18px 0 40px; }
.detail-title { font-size: 31px; line-height: 1.32; letter-spacing: -.03em; font-weight: 800; }
.detail-sub { font-size: 15px; color: #5a6478; margin-top: 10px; line-height: 1.65; }
.detail-badges { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 15px; }
.badge-pill { height: 26px; padding: 0 11px; border-radius: 99px; background: #fff; border: 1px solid #dfe4f7; font-size: 12.3px; font-weight: 600; color: #475467; display: inline-flex; align-items: center; gap: 5px; }
.teacher-box { display: flex; align-items: center; gap: 12px; margin-top: 22px; }
.teacher-box .t-name { font-weight: 700; font-size: 14px; }
.teacher-box .t-title { font-size: 12.5px; color: var(--muted); }

.buy-card { background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 20px; position: sticky; top: 88px; box-shadow: 0 26px 50px -40px rgba(16, 24, 40, .5); }
.buy-card .cover { border-radius: 12px; overflow: hidden; margin-bottom: 16px; }
.buy-price { display: flex; align-items: baseline; gap: 9px; margin-bottom: 14px; }
.buy-price .p { font-size: 30px; font-weight: 800; color: #e5484d; letter-spacing: -.03em; }
.buy-price .p.free { color: var(--ok); }
.buy-price .o { font-size: 14px; color: #b4b9c6; text-decoration: line-through; }
.buy-price .off { font-size: 11.5px; font-weight: 700; color: #e5484d; background: #fef3f2; border-radius: 6px; padding: 2px 6px; }
.buy-list { display: flex; flex-direction: column; gap: 9px; margin-top: 16px; padding-top: 16px; border-top: 1px dashed var(--line); }
.buy-list .li { display: flex; align-items: center; gap: 8px; font-size: 13px; color: #475467; }
.buy-list .li svg { color: var(--ok); flex: none; }
.guarantee { margin-top: 14px; text-align: center; font-size: 12px; color: #98a2b3; }

.tabs { display: flex; gap: 26px; border-bottom: 1px solid var(--line); margin: 6px 0 20px; }
.tab { padding: 12px 2px; font-size: 14.5px; font-weight: 600; color: #667085; border-bottom: 2px solid transparent; cursor: pointer; transition: .15s; }
.tab:hover { color: var(--text); }
.tab.active { color: var(--brand); border-color: var(--brand); }

.content-card { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 26px; }
.content-card h3 { font-size: 17px; margin-bottom: 12px; }
.rich p { color: #475467; font-size: 14.3px; line-height: 1.85; margin-bottom: 12px; }
.hl-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 16px 0 4px; }
.hl { display: flex; gap: 9px; align-items: flex-start; background: #f8f9fe; border: 1px solid #eef0f9; border-radius: 10px; padding: 11px 13px; font-size: 13.3px; color: #344054; }
.hl .tick { color: var(--brand); flex: none; margin-top: 2px; }

.chapter { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; margin-bottom: 9px; background: #fff; }
.chapter-head { display: flex; align-items: center; gap: 10px; padding: 13px 16px; cursor: pointer; background: #fbfcff; user-select: none; }
.chapter-head:hover { background: #f6f8ff; }
.chapter-head h4 { font-size: 14px; font-weight: 700; }
.chapter-head .chev { margin-left: auto; transition: .2s; color: #98a2b3; }
.chapter.open .chev { transform: rotate(180deg); }
.chapter-body { display: none; }
.chapter.open .chapter-body { display: block; }
.lesson-row { display: flex; align-items: center; gap: 9px; padding: 10px 16px; border-top: 1px solid #f4f5fa; font-size: 13.6px; color: #475467; }
.lesson-row:hover { background: #fafbff; }
.lesson-row .l-icon { width: 18px; text-align: center; opacity: .55; flex: none; font-size: 12px; }
.lesson-row .l-dur { margin-left: auto; font-size: 12px; color: #98a2b3; }
.lesson-row .preview { font-size: 11px; font-weight: 700; color: var(--brand); background: var(--brand-soft); border-radius: 5px; padding: 1px 6px; }
.lesson-row.locked { color: #8a93a5; }

.review-item { padding: 15px 0; border-bottom: 1px solid #f2f4f9; display: flex; gap: 12px; }
.review-item:last-child { border-bottom: 0; }
.review-item .r-head { display: flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 600; }
.review-item .r-date { font-size: 12px; color: #98a2b3; font-weight: 400; }
.review-item p { font-size: 13.5px; color: #475467; margin-top: 4px; }

/* --------------------------------- 学习页 -------------------------------- */
.learn-shell { display: grid; grid-template-columns: 328px 1fr; }
.learn-side { background: #fff; border-right: 1px solid var(--line); height: calc(100vh - 68px); position: sticky; top: 68px; overflow-y: auto; }
.learn-side-head { padding: 18px 18px 14px; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: #fff; z-index: 2; }
.learn-side-head h3 { font-size: 14.5px; line-height: 1.5; margin-bottom: 10px; }
.chapter-label { padding: 12px 18px 6px; font-size: 11.5px; font-weight: 700; letter-spacing: .05em; color: #98a2b3; background: #fbfcff; border-bottom: 1px solid #f4f5fa; }
.lesson-item { display: flex; gap: 10px; padding: 11px 18px; font-size: 13.3px; border-bottom: 1px solid #f8f9fc; cursor: pointer; color: #475467; transition: .12s; align-items: flex-start; }
.lesson-item:hover { background: #fafbff; }
.lesson-item.active { background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.lesson-item .dot { width: 16px; height: 16px; border-radius: 50%; border: 1.5px solid #d0d5dd; flex: none; margin-top: 2px; display: grid; place-items: center; font-size: 9px; color: #fff; }
.lesson-item.done .dot { background: var(--ok); border-color: var(--ok); }
.lesson-item .dur { margin-left: auto; font-size: 11.5px; color: #98a2b3; flex: none; }

.learn-main { padding: 20px 28px 70px; min-width: 0; }
.player-wrap { background: #0b1020; border-radius: 14px; overflow: hidden; aspect-ratio: 16/9; position: relative; box-shadow: 0 24px 50px -34px rgba(11, 16, 32, .8); }
.player-wrap video { width: 100%; height: 100%; display: block; background: #0b1020; }
.player-empty { position: absolute; inset: 0; display: grid; place-items: center; color: #98a2b3; font-size: 13.5px; text-align: center; padding: 20px; }
.lesson-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-top: 18px; flex-wrap: wrap; }
.lesson-head h2 { font-size: 20px; letter-spacing: -.02em; line-height: 1.4; }
.lesson-toolbar { display: flex; align-items: center; gap: 8px; margin-top: 6px; flex-wrap: wrap; }
.lesson-note { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 20px 22px; margin-top: 18px; }
.lesson-note h4 { font-size: 14px; margin-bottom: 8px; }
.lesson-note p { font-size: 13.6px; color: #475467; line-height: 1.8; }

/* --------------------------------- 测验 --------------------------------- */
.quiz-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 16px; flex-wrap: wrap; }
.quiz-q { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 20px 22px; margin-bottom: 13px; }
.q-stem { font-size: 14.8px; font-weight: 600; margin-bottom: 14px; line-height: 1.65; }
.q-stem .idx { color: var(--brand); margin-right: 7px; }
.opt { display: flex; gap: 10px; align-items: flex-start; padding: 11px 14px; border: 1px solid var(--line); border-radius: 10px; margin-bottom: 8px; cursor: pointer; font-size: 13.8px; transition: .14s; color: #344054; }
.opt:hover { border-color: #c7d2fe; background: #fafbff; }
.opt.sel { border-color: var(--brand); background: var(--brand-soft); }
.opt.correct { border-color: #12b76a; background: #ecfdf3; color: #027a48; }
.opt.wrong { border-color: #f04438; background: #fef3f2; color: #b42318; }
.opt .k { width: 20px; height: 20px; border-radius: 50%; border: 1px solid #d0d5dd; display: grid; place-items: center; font-size: 11px; flex: none; font-weight: 600; margin-top: 1px; }
.opt.sel .k { background: var(--brand); border-color: var(--brand); color: #fff; }
.opt.correct .k { background: var(--ok); border-color: var(--ok); color: #fff; }
.opt.wrong .k { background: var(--danger); border-color: var(--danger); color: #fff; }
.q-analysis { margin-top: 10px; padding: 10px 12px; border-radius: 8px; background: #f6f8ff; font-size: 12.8px; color: #475467; line-height: 1.7; }
.score-card { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 28px; text-align: center; margin-bottom: 16px; }
.score-ring { width: 108px; height: 108px; border-radius: 50%; margin: 0 auto 14px; display: grid; place-items: center; font-size: 30px; font-weight: 800; letter-spacing: -.03em; }

/* --------------------------------- 订单 --------------------------------- */
.order-card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; display: flex; gap: 16px; align-items: center; margin-bottom: 12px; }
.order-card img { width: 116px; height: 66px; object-fit: cover; border-radius: 9px; flex: none; }
.order-main { flex: 1; min-width: 0; }
.order-main .t { font-weight: 700; font-size: 14.5px; margin-bottom: 5px; }
.order-meta { font-size: 12.3px; color: #98a2b3; display: flex; gap: 12px; flex-wrap: wrap; }

/* --------------------------------- 账号 --------------------------------- */
.auth-page { display: grid; place-items: center; padding: 54px 20px 70px; min-height: calc(100vh - 68px); }
.auth-card { width: 100%; max-width: 424px; background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 32px; box-shadow: 0 34px 70px -46px rgba(16, 24, 40, .55); }
.auth-card h1 { font-size: 23px; letter-spacing: -.025em; }
.auth-card .sub { color: var(--muted); font-size: 13.5px; margin-top: 5px; margin-bottom: 22px; }
.auth-alt { text-align: center; font-size: 13.5px; color: var(--muted); margin-top: 18px; }
.auth-alt a { color: var(--brand); font-weight: 600; }
.demo-tip { margin-top: 18px; padding: 11px 13px; border-radius: 10px; background: #f6f8ff; border: 1px dashed #ccd6fb; font-size: 12.4px; color: #475467; line-height: 1.65; }
.demo-tip code { background: #fff; padding: 1px 5px; border-radius: 4px; color: var(--brand); font-weight: 600; }

/* --------------------------------- 通用组件 ------------------------------- */
.badge { display: inline-flex; align-items: center; gap: 4px; height: 22px; padding: 0 8px; border-radius: 6px; font-size: 11.8px; font-weight: 600; white-space: nowrap; }
.badge-green { background: #ecfdf3; color: #027a48; }
.badge-gray { background: #f2f4f7; color: #475467; }
.badge-red { background: #fef3f2; color: #b42318; }
.badge-blue { background: #eef4ff; color: #3538cd; }
.badge-orange { background: #fffaeb; color: #b54708; }

.progress { height: 6px; background: #eaecf5; border-radius: 99px; overflow: hidden; }
.progress > i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, #3b5bfd, #8b5cf6); transition: width .35s ease; }
.progress.thin { height: 4px; }

.table-wrap { background: #fff; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.tbl { width: 100%; border-collapse: collapse; font-size: 13.6px; }
.tbl th { text-align: left; padding: 11px 16px; background: #fbfcff; color: #667085; font-weight: 600; font-size: 12.3px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl td { padding: 12px 16px; border-bottom: 1px solid #f3f5fa; vertical-align: middle; }
.tbl tbody tr:last-child td { border-bottom: 0; }
.tbl tbody tr:hover { background: #fafbff; }
.tbl .actions { display: flex; gap: 6px; justify-content: flex-end; }

.empty { text-align: center; padding: 54px 20px; color: var(--muted); font-size: 13.5px; }
.empty .ico { font-size: 32px; opacity: .45; margin-bottom: 10px; }

.modal-mask { position: fixed; inset: 0; background: rgba(16, 24, 40, .45); backdrop-filter: blur(3px); z-index: 300; display: grid; place-items: center; padding: 24px; animation: fade .16s ease; overflow-y: auto; }
.modal { background: #fff; border-radius: 18px; width: 100%; max-width: 540px; box-shadow: 0 40px 90px -30px rgba(16, 24, 40, .55); animation: pop .2s ease; margin: auto;
  display: flex; flex-direction: column; max-height: calc(100vh - 44px); }
/* 字段多的表单（补录考勤、写点评）在矮屏上要能内部滚动，头部和底部按钮始终可见 */
.modal > .modal-head, .modal > .modal-foot { flex: none; }
.modal-body { overflow-y: auto; }
.modal > form { display: flex; flex-direction: column; min-height: 0; flex: 1 1 auto; }
.modal > form > .modal-body { min-height: 0; }
.modal-lg { max-width: 760px; }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 22px; border-bottom: 1px solid var(--line); }
.modal-head h3 { font-size: 16px; }
.modal-body { padding: 20px 22px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 15px 22px; border-top: 1px solid var(--line); background: #fbfcff; border-radius: 0 0 18px 18px; }
.icon-btn { width: 30px; height: 30px; border-radius: 8px; border: 0; background: #f4f5f8; color: #667085; cursor: pointer; display: grid; place-items: center; font-size: 15px; }
.icon-btn:hover { background: #eceef5; }

/* 叠层弹窗：在上层弹窗之上再开一层（如课程表单里选封面），不能清掉下面那层表单 */
.modal-layer { z-index: 320; }

/* 课程封面选择：左侧预览 + 右侧操作 */
.cover-pick { display: flex; gap: 14px; align-items: flex-start; }
.cover-prev {
  width: 168px; height: 96px; flex: 0 0 168px; border-radius: 10px; border: 1px solid var(--line);
  background: #f4f6fb center/cover no-repeat; box-shadow: inset 0 0 0 1px rgba(16, 24, 40, .02);
}
.cover-ops { flex: 1; min-width: 0; padding-top: 2px; }

/* 素材库弹窗：按来源分组的小图墙 */
.asset-title { font-size: 13px; font-weight: 600; color: #344054; margin: 4px 0 10px; }
.asset-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 10px; margin-bottom: 18px; }
.asset-item {
  padding: 0; border: 1px solid var(--line); border-radius: 10px; background: #f7f8fc; cursor: pointer;
  overflow: hidden; aspect-ratio: 16 / 9; display: block; transition: box-shadow .15s ease, border-color .15s ease, transform .15s ease;
}
.asset-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.asset-item:hover { border-color: #6c8cff; box-shadow: 0 8px 20px -10px rgba(60, 90, 220, .5); transform: translateY(-1px); }
.asset-item.active { border-color: #3b5bdb; box-shadow: 0 0 0 2px rgba(59, 91, 219, .25); }

/* 课程列表里「当前学期」的小标记 */
.term-now { display: inline-block; padding: 0 5px; border-radius: 4px; background: #fef3f2; color: #b42318; font-weight: 600; }

.toast-wrap { position: fixed; top: 82px; right: 24px; z-index: 500; display: flex; flex-direction: column; gap: 9px; align-items: flex-end; }
.toast { background: #101828; color: #fff; padding: 10px 16px; border-radius: 10px; font-size: 13.2px; box-shadow: 0 14px 30px -14px rgba(16, 24, 40, .6); animation: slidein .2s ease; max-width: 340px; }
.toast.ok { background: #054f31; }
.toast.err { background: #7a271a; }

.skeleton { background: linear-gradient(90deg, #eef0f7 25%, #f6f7fb 37%, #eef0f7 63%); background-size: 400% 100%; animation: shimmer 1.4s infinite; border-radius: 10px; }

footer.site-foot { border-top: 1px solid var(--line); background: #fff; margin-top: 40px; padding: 34px 0 30px; }
.foot-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 30px; }
.foot-grid h5 { font-size: 13px; margin-bottom: 10px; }
.foot-grid a { display: block; font-size: 13px; color: var(--muted); padding: 3px 0; }
.foot-grid a:hover { color: var(--brand); }
.copyright { margin-top: 26px; padding-top: 18px; border-top: 1px solid var(--line); font-size: 12.4px; color: #98a2b3; display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; }

/* --------------------------------- 管理后台 ------------------------------- */
.admin { display: grid; grid-template-columns: 232px 1fr; min-height: 100vh; }
.admin-side {
  background: #0f1535; padding: 18px 14px; position: sticky; top: 0; height: 100vh;
  display: flex; flex-direction: column; color: #a9b0cd;
}
.admin-side .logo { color: #fff; padding: 6px 8px 18px; }
.admin-side .logo-mark { background: linear-gradient(135deg, #5b74ff, #8b5cf6); }
.side-nav { display: flex; flex-direction: column; gap: 3px; flex: 1; min-height: 0; overflow-y: auto; padding-right: 2px; }
/* 菜单多了以后要能滚动，否则底部几项被 side-foot 压住点不到 */
.side-nav::-webkit-scrollbar { width: 6px; }
.side-nav::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .14); border-radius: 99px; }
.side-nav a { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 9px; color: #a9b0cd; font-size: 13.8px; transition: .14s; }
.side-nav a:hover { background: rgba(255, 255, 255, .06); color: #fff; }
.side-nav a.active { background: rgba(91, 116, 255, .22); color: #fff; font-weight: 600; box-shadow: inset 2px 0 0 #7b93ff; }
.side-nav .ico { width: 17px; text-align: center; opacity: .85; }
.side-foot { margin-top: auto; padding-top: 14px; border-top: 1px solid rgba(255, 255, 255, .08); font-size: 12.3px; }
.side-foot a { display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 8px; color: #a9b0cd; }
.side-foot a:hover { color: #fff; background: rgba(255, 255, 255, .06); }

.admin-main { background: #f7f8fc; min-width: 0; display: flex; flex-direction: column; }
.admin-top { height: 62px; background: #fff; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; padding: 0 26px; position: sticky; top: 0; z-index: 20; }
.admin-top h1 { font-size: 16px; letter-spacing: -.01em; }
.admin-body { padding: 22px 26px 50px; }

.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 15px; }
.stat-card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 16px 19px; }
.stat-card .k { font-size: 12.5px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.stat-card .v { font-size: 25px; font-weight: 800; margin-top: 7px; letter-spacing: -.03em; }
.stat-card .d { font-size: 12px; margin-top: 4px; color: #98a2b3; }
.stat-card .d em { font-style: normal; color: var(--ok); font-weight: 600; }

.grid-2 { display: grid; grid-template-columns: 1.05fr 1fr; gap: 16px; margin-top: 16px; }

/* 数据看板：学期切换条 + 按学校/按课程统计表 */
.dash-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; flex-wrap: wrap; margin-bottom: 14px;
}
.dash-head .input { height: 36px; }
.dash-empty {
  margin-bottom: 14px; padding: 11px 14px; border-radius: 11px;
  background: #fffaeb; color: #b54708; font-size: 12.8px; line-height: 1.6;
}
.grid-2 > .card { margin-top: 0; }
.stat-tbl td { max-width: 250px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stat-tbl th:nth-child(2), .stat-tbl th:nth-child(3) { text-align: right; }
.stat-tbl .num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; color: #344054; }
.stat-tbl td:nth-child(4) { padding-right: 16px; }
.card { background: #fff; border: 1px solid var(--line); border-radius: 14px; }
.card-head { padding: 15px 19px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.card-head h3 { font-size: 14.5px; }
.card-body { padding: 16px 19px; }

.bars { display: flex; align-items: flex-end; gap: 12px; height: 176px; padding: 6px 2px 0; }
.bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 7px; height: 100%; justify-content: flex-end; }
.bar { width: 100%; max-width: 40px; border-radius: 6px 6px 3px 3px; background: linear-gradient(180deg, #6b82ff, #3b5bfd); min-height: 4px; position: relative; transition: .3s; }
.bar:hover { filter: brightness(1.08); }
.bar-val { font-size: 11px; color: #667085; font-weight: 600; }
.bar-lbl { font-size: 11px; color: #98a2b3; }

.admin-toolbar { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.admin-toolbar .input { height: 36px; font-size: 13.5px; }
.admin-toolbar .search { width: 230px; margin-left: 0; }
.admin-toolbar .search input { height: 36px; }
/* 用户列表的年级筛选（含停用的历史毕业年级） */
.admin-toolbar .select-sm { height: 36px; width: 156px; padding: 0 10px; border: 1px solid var(--line); border-radius: 8px; background: #fff; font-size: 13.5px; color: #344054; }
.admin-toolbar .select-sm:focus { outline: none; border-color: var(--brand); }
#userPager { margin: 16px 0 4px; }
.count-tip { font-size: 12.5px; color: #98a2b3; }

.lesson-admin-row { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; margin-bottom: 7px; background: #fff; font-size: 13.4px; }
.lesson-admin-row .idx { width: 22px; color: #98a2b3; font-size: 12px; }
.lesson-admin-row .t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chapter-block { margin-bottom: 16px; }
.chapter-block-title { font-size: 12.5px; font-weight: 700; color: #475467; margin-bottom: 8px; display: flex; align-items: center; gap: 8px; }
.ch-ops { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.ch-ops .btn { padding: 2px 8px; font-size: 12px; line-height: 1.7; }
.ch-ops .btn[disabled] { opacity: .35; cursor: not-allowed; }
.ch-ops .ch-del { color: #b42318; }
.ch-ops .ch-del:hover { background: #fef3f2; }

.opt-editor { display: flex; flex-direction: column; gap: 8px; }
.opt-editor .row { gap: 8px; }
.opt-editor .k { width: 25px; flex: none; }
.radio-line { display: flex; align-items: center; gap: 7px; font-size: 13px; color: #475467; cursor: pointer; white-space: nowrap; }

/* --------------------------------- 动画 --------------------------------- */
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes pop { from { opacity: 0; transform: translateY(6px) scale(.985); } to { opacity: 1; transform: none; } }
@keyframes slidein { from { opacity: 0; transform: translateX(12px); } to { opacity: 1; transform: none; } }
@keyframes shimmer { 0% { background-position: 100% 0; } 100% { background-position: -100% 0; } }

/* --------------------------------- 响应式 -------------------------------- */
@media (max-width: 1080px) {
  .course-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-in { grid-template-columns: 1fr; gap: 30px; }
  .hero h1 { font-size: 36px; }
  .detail-grid { grid-template-columns: 1fr 300px; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .grid-2 { grid-template-columns: 1fr; }
  .learn-shell { grid-template-columns: 280px 1fr; }
}
@media (max-width: 860px) {
  .main-nav { display: none; }
  .search { width: 180px; }
  .catalog { grid-template-columns: 1fr; }
  .filter-panel { position: static; }
  .detail-grid { grid-template-columns: 1fr; }
  .buy-card { position: static; }
  .learn-shell { grid-template-columns: 1fr; }
  .learn-side { position: static; height: auto; max-height: 320px; }
  .admin { grid-template-columns: minmax(0, 1fr); }
  .admin-side { position: static; height: auto; flex-direction: column; min-width: 0; }
  /* min-width:0 + flex:1 让横向导航在自己的盒子里滚动，不把整页撑宽 */
  .side-nav { flex-direction: row; overflow-x: auto; padding-bottom: 4px; min-width: 0; max-width: 100%; }
  .side-group.open .side-sub { flex-direction: row; margin-left: 0; padding-left: 0; border-left: 0; gap: 4px; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .value-grid { grid-template-columns: 1fr; }
  .cta-band { flex-direction: column; align-items: flex-start; padding: 28px; }
  .learn-main { padding: 16px 16px 60px; }
  .admin-body { padding: 16px; }
  .admin-top { padding: 0 16px; }
  .hl-grid { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .course-grid { grid-template-columns: 1fr; }
  .wrap { padding: 0 16px; }
  .hero h1 { font-size: 30px; }
  .hero-stats { gap: 22px; }
  .detail-title { font-size: 24px; }
  .order-card img { width: 84px; height: 52px; }
  .tbl { font-size: 12.6px; }
  .field-row { grid-template-columns: 1fr; }
  .header-actions .btn-ghost { display: none; }
}

/* =============================== 系统配置 =============================== */
/* 侧边栏分组 */
.side-group { display: flex; flex-direction: column; gap: 2px; }
.side-group-head {
  display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 12px;
  border: 0; border-radius: 9px; background: transparent; cursor: pointer;
  color: #a9b0cd; font-size: 13.8px; font-family: inherit; text-align: left; transition: .14s;
}
.side-group-head:hover { background: rgba(255, 255, 255, .06); color: #fff; }
.side-group.open .side-group-head { color: #fff; }
.side-group-head .chev { margin-left: auto; font-size: 10px; opacity: .65; transition: transform .18s; }
.side-group.open .side-group-head .chev { transform: rotate(180deg); }
.side-sub { display: none; flex-direction: column; gap: 2px; margin: 3px 0 4px 30px; padding-left: 9px; border-left: 1px solid rgba(255, 255, 255, .1); }
.side-group.open .side-sub { display: flex; }
.side-sub a { padding: 7px 10px !important; font-size: 13px !important; border-radius: 7px !important; }
.side-sub a.active { box-shadow: none !important; background: rgba(91, 116, 255, .26); }

/* 页面头部（保存栏） */
.set-head {
  position: sticky; top: 62px; z-index: 12; display: flex; align-items: flex-start;
  justify-content: space-between; gap: 18px; flex-wrap: wrap;
  padding: 14px 0 12px; margin: -22px -26px 4px; padding-left: 26px; padding-right: 26px;
  background: #f7f8fc; border-bottom: 1px solid transparent; transition: border-color .2s;
}
.set-head.stuck { border-bottom-color: var(--line); }
.set-head h2 { font-size: 17px; letter-spacing: -.02em; }
.set-head p { font-size: 12.8px; color: var(--muted); margin-top: 4px; max-width: 640px; line-height: 1.6; }
.set-actions { display: flex; align-items: center; gap: 9px; }
.dirty-tip { font-size: 12.5px; color: #b54708; display: none; align-items: center; gap: 5px; }
.dirty-tip.on { display: inline-flex; }
.dirty-tip::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: #f79009; }

/* 配置卡片 */
.set-card { margin-bottom: 16px; }
.set-card .card-head { align-items: flex-start; }
.set-card .card-head .row { gap: 11px; align-items: flex-start; }
.set-ico {
  width: 30px; height: 30px; border-radius: 9px; flex: none; display: grid; place-items: center;
  background: #eef1ff; color: #4557d4; font-size: 14px; margin-top: 1px;
}
.set-body { padding: 4px 19px 8px; }
.set-row { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 18px; padding: 13px 0; border-bottom: 1px dashed #eef0f7; }
.set-row:last-child { border-bottom: 0; }
.set-row > .set-label { padding-top: 7px; }
.set-row label.lbl { display: block; font-size: 13.2px; font-weight: 600; color: #344054; }
.set-row .req { color: #e5484d; margin-left: 2px; }
.set-row .set-hint { font-size: 11.8px; color: #98a2b3; line-height: 1.55; margin-top: 3px; }
.set-ctrl { min-width: 0; }
.set-ctrl .input { height: 36px; font-size: 13.4px; }
.set-ctrl textarea.input { height: auto; padding: 9px 12px; line-height: 1.6; }
.set-ctrl .row { gap: 8px; flex-wrap: wrap; }
.set-inline { display: flex; align-items: center; gap: 9px; }
.set-inline .input { flex: 1; min-width: 0; }
.count-tip-inline { font-size: 11.5px; color: #98a2b3; white-space: nowrap; }

/* 开关 */
.switch { position: relative; display: inline-flex; align-items: center; gap: 9px; cursor: pointer; user-select: none; font-size: 13px; color: #475467; }
.switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.switch .track {
  width: 40px; height: 22px; border-radius: 99px; background: #d0d5dd; position: relative;
  flex: none; transition: background .18s;
}
.switch .track::after {
  content: ''; position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; border-radius: 50%;
  background: #fff; box-shadow: 0 1px 3px rgba(16, 24, 40, .25); transition: transform .18s;
}
.switch input:checked + .track { background: var(--brand); }
.switch input:checked + .track::after { transform: translateX(18px); }
.switch input:disabled + .track { opacity: .5; }
.switch .sw-txt { font-weight: 500; }

/* 密钥输入 */
.secret-wrap { display: flex; align-items: center; gap: 8px; }
.secret-wrap .input { flex: 1; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .08em; }
.secret-flag { font-size: 11.5px; padding: 2px 7px; border-radius: 5px; background: #fef3f2; color: #b42318; white-space: nowrap; }
.secret-flag.ok { background: #ecfdf3; color: #027a48; }
.link-btn { border: 0; background: transparent; color: var(--brand); font-size: 12.5px; cursor: pointer; padding: 4px 2px; font-family: inherit; }
.link-btn:hover { text-decoration: underline; }
.link-btn.danger { color: #b42318; }

/* 图片上传 */
.img-field { display: flex; align-items: flex-start; gap: 12px; }
.img-prev {
  width: 76px; height: 52px; flex: none; border-radius: 9px; border: 1px dashed #d8ddee; background:
    repeating-conic-gradient(#f4f6fb 0% 25%, #fff 0% 50%) 50% / 12px 12px;
  display: grid; place-items: center; overflow: hidden;
}
.img-prev img { max-width: 100%; max-height: 100%; object-fit: contain; }
.img-prev span { font-size: 10.5px; color: #b0b7c9; }
.img-meta { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 7px; }

/* 颜色 */
.color-field { display: flex; align-items: center; gap: 10px; }
.color-field input[type=color] { width: 40px; height: 34px; padding: 2px; border: 1px solid var(--line); border-radius: 8px; background: #fff; cursor: pointer; }
.color-field code { font-size: 12.3px; color: #667085; background: #f6f7fb; padding: 4px 8px; border-radius: 6px; }

/* 测试结果 */
.test-out { margin: 0 19px 14px; padding: 12px 14px; border-radius: 10px; font-size: 12.8px; line-height: 1.7; display: none; }
.test-out.show { display: block; }
.test-out.ok { background: #ecfdf3; border: 1px solid #abefc6; color: #05603a; }
.test-out.err { background: #fef3f2; border: 1px solid #fecdca; color: #912018; }
.test-out .t-head { font-weight: 700; margin-bottom: 6px; display: flex; align-items: center; gap: 6px; }
.test-out ul { margin: 6px 0 0; padding-left: 18px; }
.test-out li { margin: 2px 0; }
.test-out .t-tip { color: #667085; font-size: 12px; margin-top: 7px; }
.test-out .t-net { font-family: ui-monospace, Menlo, monospace; font-size: 11.8px; color: #475467; }

.set-foot-note { font-size: 12.2px; color: #98a2b3; padding: 6px 2px 18px; }
.sticky-ghost { height: 1px; }

/* 前台登录方式切换 */
.login-tabs { display: flex; gap: 4px; background: #f1f3f9; padding: 4px; border-radius: 11px; margin-bottom: 18px; }
.login-tabs button {
  flex: 1; height: 34px; border: 0; border-radius: 8px; background: transparent; cursor: pointer;
  font-size: 13px; color: #667085; font-family: inherit; font-weight: 500; transition: .15s; white-space: nowrap;
}
.login-tabs button.active { background: #fff; color: var(--text); font-weight: 600; box-shadow: 0 1px 3px rgba(16, 24, 40, .12); }
.sms-row { display: flex; gap: 9px; }
.sms-row .input { flex: 1; }
.sms-row .btn { flex: none; white-space: nowrap; }
.wechat-box { text-align: center; padding: 4px 0 6px; }
.wechat-box iframe { width: 100%; height: 340px; border: 0; border-radius: 12px; background: #fafbff; }
.wechat-empty { padding: 22px 16px; border: 1px dashed #dbe0ef; border-radius: 12px; background: #fafbff; }
.wechat-empty .ico { font-size: 26px; }
.demo-code { font-size: 12.4px; color: #b54708; background: #fffaeb; border: 1px solid #fedf89; padding: 7px 10px; border-radius: 8px; margin-top: 10px; }

@media (max-width: 860px) {
  .set-head { margin: -16px -16px 4px; padding-left: 16px; padding-right: 16px; top: 62px; }
  .set-row { grid-template-columns: 1fr; gap: 8px; padding: 12px 0; }
  .set-row > .set-label { padding-top: 0; }
  .side-sub { margin-left: 16px; }
}

/* =============================== 组织架构 =============================== */
/* 侧边栏三级分组（系统配置 → 组织架构 → 学校/年级/班级） */
.side-nest { display: flex; flex-direction: column; gap: 1px; margin-top: 3px; }
.side-nest-head {
  display: flex; align-items: center; width: 100%; padding: 7px 10px; border: 0; border-radius: 7px;
  background: transparent; cursor: pointer; color: #a9b0cd; font-size: 13px; font-family: inherit;
  text-align: left; transition: .14s;
}
.side-nest-head:hover { background: rgba(255, 255, 255, .06); color: #fff; }
.side-nest.open .side-nest-head { color: #fff; }
.side-nest-head .chev { margin-left: auto; font-size: 9px; opacity: .6; transition: transform .18s; }
.side-nest.open .side-nest-head .chev { transform: rotate(180deg); }
.side-nest-sub {
  display: none; flex-direction: column; gap: 1px;
  margin: 2px 0 2px 9px; padding-left: 8px; border-left: 1px dashed rgba(255, 255, 255, .16);
}
.side-nest.open .side-nest-sub { display: flex; }
.side-nest-sub a {
  padding: 6px 9px !important; font-size: 12.6px !important; border-radius: 6px !important; color: #98a0c0;
}
.side-nest-sub a:hover { color: #fff; }
.side-nest-sub a.active { background: rgba(91, 116, 255, .3) !important; color: #fff; box-shadow: none !important; }

/* 页面内切换标签 */
.org-tabs {
  display: inline-flex; gap: 3px; padding: 4px; border-radius: 11px;
  background: #eff1f8; margin: 2px 0 16px;
}
.org-tabs a {
  padding: 7px 18px; border-radius: 8px; font-size: 13.2px; color: #667085;
  font-weight: 500; transition: .15s; white-space: nowrap;
}
.org-tabs a:hover { color: var(--text); }
.org-tabs a.active { background: #fff; color: var(--text); font-weight: 600; box-shadow: 0 1px 3px rgba(16, 24, 40, .12); }

/* 指标卡 */
.org-stats { display: flex; gap: 11px; flex-wrap: wrap; margin-bottom: 16px; }
.org-stat {
  flex: 1 1 150px; min-width: 132px; background: #fff; border: 1px solid var(--line);
  border-radius: 12px; padding: 12px 16px 13px;
}
.org-stat .k { font-size: 12.2px; color: #667085; }
.org-stat .v { font-size: 22px; font-weight: 700; letter-spacing: -.02em; margin-top: 3px; color: #101828; }
.org-stat .v em { font-size: 12px; font-weight: 500; font-style: normal; color: #98a2b3; margin-left: 4px; }

/* 筛选条 */
.org-filters { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.org-filters .input { height: 38px; font-size: 13.2px; padding: 0 10px; }
.org-filters .search input { height: 38px; }

/* 排序单元格 */
.sort-cell { display: flex; align-items: center; gap: 7px; }
.sort-no {
  width: 22px; height: 22px; flex: none; border-radius: 6px; background: #f2f4f7; color: #475467;
  font-size: 11.5px; font-weight: 700; display: grid; place-items: center; font-variant-numeric: tabular-nums;
}
.sort-btns { display: flex; flex-direction: column; gap: 2px; }
.sort-btn {
  width: 20px; height: 15px; padding: 0; display: grid; place-items: center; cursor: pointer;
  border: 1px solid #e4e7ec; background: #fff; border-radius: 4px; color: #98a2b3; transition: .12s;
}
.sort-btn .ar { display: block; width: 0; height: 0; border-left: 4px solid transparent; border-right: 4px solid transparent; }
.sort-btn[data-dir="up"] .ar { border-bottom: 5px solid currentColor; }
.sort-btn[data-dir="down"] .ar { border-top: 5px solid currentColor; }
.sort-btn:hover:not(:disabled) { border-color: #b8c4fd; color: var(--brand); background: #f5f7ff; }
.sort-btn:disabled { opacity: .3; cursor: not-allowed; }

/* 名称与标签 */
.org-name { font-weight: 600; color: #101828; }
.org-sub { font-size: 11.5px; color: #98a2b3; margin-top: 2px; }
.org-tags { display: flex; gap: 5px; flex-wrap: wrap; }
.org-tag {
  display: inline-block; font-size: 11.5px; padding: 2px 8px; border-radius: 6px;
  background: #f4f6fb; color: #475467; white-space: nowrap; transition: .14s;
}
a.org-tag:hover { background: #e8ecfb; color: var(--brand); }
.org-tag.major { background: #eef4ff; color: #3538cd; }
.org-warn {
  font-size: 13px; line-height: 1.7; color: #b54708; background: #fffaeb;
  border: 1px solid #fedf89; border-radius: 10px; padding: 14px 16px;
}

.th-act { text-align: right; }
.tbl td .actions { justify-content: flex-end; }
.field label .req { color: #e5484d; margin-left: 2px; }

/* 列数较多的表格允许横向滚动（原 overflow:hidden 会裁掉右侧列） */
.table-wrap { overflow-x: auto; }

@media (max-width: 860px) {
  .org-tabs { display: flex; width: 100%; overflow-x: auto; }
  .org-tabs a { flex: 1; text-align: center; padding: 7px 12px; }
  .org-stats { gap: 9px; }
  .org-stat { flex: 1 1 46%; }
  .side-nest-sub { margin-left: 4px; }
  /* 窄屏侧边栏变成横向滚动条：链接不许被压窄，否则文字会竖排 */
  .side-nav > a, .side-group, .side-group-head { flex: 0 0 auto; white-space: nowrap; }
}

/* =============================== 课程管理 =============================== */
.modal-xl { max-width: 980px; }

.course-tbl td { padding: 10px 11px; }
.course-tbl th { padding-left: 11px; padding-right: 11px; }
.course-title {
  font-weight: 600; color: #101828; max-width: 250px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

/* 上架 / 显示 状态切换按钮 */
.st-pill {
  min-width: 56px; height: 25px; padding: 0 10px; border-radius: 7px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid transparent; font-size: 12px; font-weight: 600;
  font-family: inherit; cursor: pointer; transition: .14s; white-space: nowrap;
}
.st-pill.on { background: #ecfdf3; color: #027a48; border-color: #c8f0da; }
.st-pill.on:hover { background: #d7f7e5; }
.st-pill.off { background: #f2f4f7; color: #667085; border-color: #e4e7ec; }
.st-pill.off:hover { background: #e9ecf2; color: #475467; }
.st-pill.warn { background: #fffaeb; color: #b54708; border-color: #fedf89; }
.st-pill.warn:hover { background: #fef0c7; }
.st-pill:disabled { opacity: .6; cursor: default; }

/* 报名学员 / 课程资料 数量按钮 */
.num-link {
  border: 0; background: #f4f6fb; color: #475467; border-radius: 8px;
  padding: 3px 9px; font-size: 12.4px; font-family: inherit; cursor: pointer;
  transition: .14s; white-space: nowrap;
}
.num-link b { color: #101828; font-variant-numeric: tabular-nums; }
.num-link:hover { background: #e8ecfb; color: var(--brand); }
.num-link:hover b { color: var(--brand); }

.mini-avatar {
  width: 28px; height: 28px; flex: none; border-radius: 50%;
  display: grid; place-items: center; font-size: 12px; font-weight: 700;
  background: linear-gradient(135deg, #e8ecff, #dfe4ff); color: #3b4bc9;
}

/* 课程资料弹窗 */
.mat-sum {
  font-size: 12.6px; color: #667085; margin-bottom: 12px;
  padding: 9px 12px; background: #f7f8fc; border-radius: 9px;
}
.mat-sum b { color: #101828; }

/* 报名学员弹窗：顶部工具条 + 后台添加面板 */
.stu-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.stu-bar .mat-sum { margin-bottom: 0; }
.stu-bar .input { height: 34px; }
.stu-add {
  margin: 12px 0 14px; padding: 14px;
  border: 1px solid #e6e9f5; border-radius: 12px; background: #fbfcff;
}
.stu-add-blk + .stu-add-blk { margin-top: 14px; padding-top: 14px; border-top: 1px dashed #e6e9f5; }
.stu-add-t { font-size: 12.6px; font-weight: 700; color: #344054; margin-bottom: 9px; }
.stu-add .input { height: 36px; }
.stu-found { margin-top: 9px; max-height: 210px; overflow-y: auto; }
.stu-hit {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 9px 11px; border: 1px solid #eceffa; border-radius: 9px; background: #fff;
}
.stu-hit + .stu-hit { margin-top: 7px; }
.stu-tip {
  margin-top: 13px; padding: 9px 12px; border-radius: 9px;
  background: #fffaeb; color: #b54708; font-size: 12.4px; line-height: 1.6;
}
.stu-tip b { color: #93370d; }
.tbl-stu td { vertical-align: middle; }
/* 进度列要放得下进度条 + 百分比，学校名过长用省略号，避免整列换行把表格撑高 */
.tbl-stu th:nth-child(1), .tbl-stu td:nth-child(1) { min-width: 178px; }
.tbl-stu th:nth-child(3), .tbl-stu td:nth-child(3) { max-width: 190px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tbl-stu th:nth-child(4), .tbl-stu td:nth-child(4) { min-width: 108px; }
.tbl-stu th:nth-child(6), .tbl-stu td:nth-child(6) { min-width: 146px; }
.tbl-stu th:nth-child(7), .tbl-stu td:nth-child(7) { width: 74px; }
.mat-upload {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 12px; margin-bottom: 14px;
  border: 1px dashed #dfe4f7; border-radius: 11px; background: #fbfcff;
}
.mat-ico {
  width: 30px; height: 30px; flex: none; border-radius: 8px;
  display: grid; place-items: center; font-size: 13px;
  background: #eef2ff; color: #3b4bc9;
}
.mat-ico.image { background: #ecfdf3; color: #027a48; }
.mat-ico.video { background: #fffaeb; color: #b54708; }

@media (max-width: 860px) {
  .course-title { max-width: 150px; }
  .mat-upload { align-items: flex-start; }
}

/* 课程表列比较多：给表格一个最小宽度，让标题列有足够空间，窄屏横向滚动 */
.course-tbl { min-width: 1120px; }
.course-tbl th:nth-child(2) { width: 300px; }
.course-tbl .course-title { max-width: 300px; }
.course-tbl .course-sub {
  display: block; min-height: 0; max-width: 300px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.course-tbl .sort-btn {
  width: 20px; height: 16px; font-size: 9.5px; color: #475467; font-weight: 700;
  border-color: #dfe4f7;
}
.course-tbl .sort-btns { gap: 2px; }

/* ============================ 视频库 / 课时管理 ============================ */
/* 课时页顶部：返回链接 + 课程选择 + 类型标记 */
.lesson-top { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.lesson-top .link-btn { text-decoration: none; font-size: 13px; color: #667085; }
.lesson-top .link-btn:hover { color: var(--brand); text-decoration: none; }

/* 课时类型标签 */
.lv-tag {
  display: inline-block; flex: none; font-size: 11.5px; font-weight: 600;
  padding: 2px 8px; border-radius: 6px; white-space: nowrap;
}
.lv-tag.vod { background: #eef4ff; color: #3538cd; }
.lv-tag.push { background: #fef3f2; color: #b42318; }
.lv-tag.pseudo { background: #f4f3ff; color: #5925cd; }
.lv-tag.quiz { background: #fffaeb; color: #b54708; }

.lv-meta { flex: 1; min-width: 0; display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.lv-flag {
  font-size: 11.5px; color: #b54708; background: #fffaeb;
  border: 1px solid #fedf89; border-radius: 6px; padding: 1px 7px; white-space: nowrap;
}
.lv-state { font-size: 11.5px; border-radius: 6px; padding: 1px 7px; white-space: nowrap; }
.lv-state.upcoming { background: #eef4ff; color: #3538cd; }
.lv-state.live { background: #ecfdf3; color: #027a48; }
.lv-state.ended { background: #f2f4f7; color: #667085; }

/* 视频库表格：列多，用固定布局 + 省略号，任何屏宽都不横向滚动 */
.video-tbl { table-layout: fixed; width: 100%; min-width: 900px; }
.video-tbl > thead > tr > th,
.video-tbl > tbody > tr > td { overflow: hidden; text-overflow: ellipsis; }
.video-tbl .course-title { max-width: 100%; }
.vid-sub { display: flex; align-items: center; gap: 5px; min-width: 0; }
.vid-sub > span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vid-sub .v-ref { color: #475467; flex: none; }
.vid-sub .v-dot { color: #d0d5dd; flex: none; }
.vid-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 11.5px; color: #475467; background: #f4f6fb;
  border-radius: 5px; padding: 2px 6px; white-space: nowrap;
}

/* 批量上传视频弹窗 */
.up-wrap {
  max-height: 46vh; overflow: auto;
  border: 1px solid var(--line); border-radius: 10px;
}
.up-wrap .up-tbl { min-width: 0; }
.up-wrap .up-tbl thead th {
  position: sticky; top: 0; z-index: 1;
  background: #f8fafc; font-size: 12.5px;
}
.up-wrap .up-tbl td { vertical-align: middle; }
.up-bar {
  height: 8px; border-radius: 999px; background: #eef1f6; overflow: hidden;
}
.up-bar i {
  display: block; height: 100%; width: 0;
  background: linear-gradient(90deg, #16b988, #0ea5a0);
  transition: width .18s ease;
}
.up-pct { margin-top: 3px; font-size: 11px; }
.up-err { color: #b42318; margin-top: 2px; }
/* 上传列表里的标题输入框：默认宽度跟列走，聚焦时给出清晰边框 */
.up-title { height: 32px; font-size: 13px; padding: 0 8px; }
.up-title:disabled { background: #f9fafb; color: #475467; }
.up-file { margin-top: 3px; word-break: break-all; }
.up-st { font-size: 12px; color: #98a2b3; white-space: nowrap; }
.up-st.uploading, .up-st.saving { color: #0f766e; }
.up-st.done { color: #027a48; font-weight: 600; }
.up-st.fail { color: #b42318; font-weight: 600; }
.up-foot { justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.up-cate { display: flex; align-items: center; gap: 8px; font-size: 13px; color: #475467; }
.up-cate .input { height: 34px; width: 208px; font-size: 13px; }
.up-actions { display: flex; gap: 8px; margin-left: auto; }

@media (max-width: 700px) {
  .up-cate { width: 100%; }
  .up-cate .input { flex: 1; width: auto; }
  .up-actions { width: 100%; }
  .up-actions .btn { flex: 1; }
}

/* 课时表单里的视频选择器 */
.vid-pick { display: flex; flex-direction: column; gap: 8px; }
.vid-pick-head { display: flex; align-items: center; gap: 10px; }
.vid-pick-head .input { height: 36px; font-size: 13px; }
.vid-pick-head .link-btn { flex: none; white-space: nowrap; }
.vid-meta {
  font-size: 12.2px; color: #667085; background: #f7f8fc;
  border-radius: 8px; padding: 8px 11px; display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
}

/* 开关一组两个 */
.switches { display: flex; gap: 24px; flex-wrap: wrap; padding: 4px 0 10px; }

/* 弹窗里的分段控件 */
.seg-inline { margin-top: 2px; }

@media (max-width: 860px) {
  .lesson-top { gap: 8px; }
  .lesson-top .input { width: 100% !important; }
  .lesson-admin-row { flex-wrap: wrap; }
  .lesson-admin-row .lv-meta { flex: 1 1 100%; order: 3; }
  .switches { gap: 14px; }
}

/* ============================== 前台播放器 ============================== */
/* 直播等待 / 结束 / 未开播的占位面板 */
.player-state { display: grid; place-items: center; background: radial-gradient(120% 120% at 20% 0%, #1d2757 0%, #0b1020 60%); }
.ps-inner { text-align: center; color: #fff; padding: 24px; max-width: 460px; }
.ps-tag {
  display: inline-block; font-size: 11.5px; letter-spacing: .04em;
  padding: 3px 10px; border-radius: 999px; background: rgba(255, 255, 255, .14);
  color: #d7ddff; margin-bottom: 14px;
}
.ps-title { font-size: 18px; font-weight: 700; line-height: 1.5; }
.ps-clock {
  font-size: 34px; font-weight: 800; letter-spacing: .02em; margin: 14px 0 8px;
  font-variant-numeric: tabular-nums; color: #fff;
}
.ps-tip { font-size: 13px; color: rgba(255, 255, 255, .66); line-height: 1.7; }

/* 自绘控制条（禁快进 / 禁变速时启用） */
.pl-wrap { display: flex; flex-direction: column; background: #0b1020; }
.pl-wrap video { flex: 1; min-height: 0; }
.pl-bar {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px; background: rgba(11, 16, 32, .96);
  border-top: 1px solid rgba(255, 255, 255, .08);
}
.pl-btn {
  width: 30px; height: 30px; flex: none; border: 0; border-radius: 8px;
  background: rgba(255, 255, 255, .1); color: #fff; font-size: 13px;
  cursor: pointer; display: grid; place-items: center; transition: .14s;
}
.pl-btn:hover { background: rgba(255, 255, 255, .2); }
.pl-time { font-size: 12px; color: #c7cde0; font-variant-numeric: tabular-nums; white-space: nowrap; }
.pl-range { flex: 1; min-width: 60px; accent-color: var(--brand); cursor: pointer; }
.pl-speed {
  height: 28px; border-radius: 7px; border: 1px solid rgba(255, 255, 255, .16);
  background: rgba(255, 255, 255, .08); color: #fff; font-size: 12px;
  padding: 0 4px; cursor: pointer; font-family: inherit;
}
.pl-lock {
  font-size: 11.5px; color: #98a2b3; border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 6px; padding: 3px 8px; white-space: nowrap;
}
.pl-note {
  font-size: 12px; color: #ffd8a8; background: rgba(181, 71, 8, .18);
  border-top: 1px solid rgba(255, 216, 168, .18); padding: 7px 12px; text-align: center;
}

/* 课时行里的直播标记 */
.l-dur.live, .dur.live { color: var(--brand); font-weight: 600; }

/* 清晰度切换：叠在画面右上角，原生控件和自绘控件都用同一套（原生控件塞不进额外按钮） */
.player-wrap { position: relative; }
.pl-quality { position: absolute; top: 10px; right: 10px; z-index: 5; }
.pl-qbtn {
  display: inline-flex; align-items: center; gap: 3px;
  height: 28px; padding: 0 10px; border-radius: 999px; border: 0;
  background: rgba(11, 16, 32, .68); color: #fff; font-size: 12.5px;
  font-family: inherit; cursor: pointer; backdrop-filter: blur(6px);
  transition: background .14s;
}
.pl-qbtn:hover { background: rgba(11, 16, 32, .86); }
.pl-qbtn .caret { font-size: 10px; opacity: .8; }
.pl-qmenu {
  position: absolute; top: 34px; right: 0; min-width: 132px;
  background: rgba(11, 16, 32, .95); border-radius: 10px; padding: 5px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, .38); backdrop-filter: blur(8px);
  display: flex; flex-direction: column; gap: 2px;
}
.pl-qmenu[hidden] { display: none; }
.pl-qmenu button {
  border: 0; background: transparent; color: #d7dcec; font-size: 12.5px;
  font-family: inherit; text-align: left; padding: 7px 10px; border-radius: 7px;
  cursor: pointer; white-space: nowrap;
}
.pl-qmenu button:hover { background: rgba(255, 255, 255, .1); color: #fff; }
.pl-qmenu button.on { color: #fff; background: rgba(255, 255, 255, .16); font-weight: 600; }
.pl-qmenu .tiny { font-size: 11px; }

@media (max-width: 640px) {
  .pl-quality { top: 8px; right: 8px; }
  .pl-qbtn { height: 26px; font-size: 12px; padding: 0 8px; }
}

@media (max-width: 640px) {
  .ps-clock { font-size: 26px; }
  .pl-time { display: none; }
}

/* ------------------------------- 注册 / 选课 ------------------------------ */
.auth-card-wide { max-width: 560px; }
.auth-card-wide .field-row { gap: 14px; }

.select-tip {
  display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap;
  background: var(--brand-soft); border: 1px solid #dbe2ff; color: #2c3a67;
  border-radius: 12px; padding: 12px 16px; font-size: 13px; margin: 6px 0 16px;
}
.select-tip b { color: var(--brand); white-space: nowrap; }
.select-done {
  display: flex; gap: 10px; align-items: center; flex-wrap: wrap;
  background: #ecfdf3; border: 1px solid #c7f0d8; color: #05603a;
  border-radius: 12px; padding: 10px 16px; font-size: 13px; margin-bottom: 16px;
}
.select-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; padding: 4px 0 60px; }
.select-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow-sm); transition: .18s;
}
.select-card:hover { border-color: #c9d3fb; box-shadow: var(--shadow-md); transform: translateY(-2px); }
.select-cover { aspect-ratio: 16 / 9; background: #eef1f8; overflow: hidden; }
.select-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.select-body { padding: 14px 16px 16px; }
.select-body h3 { font-size: 15px; line-height: 1.45; }
.select-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 14px; }

/* --------------------------------- 学习日历 -------------------------------
   参考主流网校日历：左上「学习日历」页签 + 特别提醒，右上「我的课程」；
   第二行四个翻页按钮 + 今天、居中月份标题、右侧「月 / 周 / 日 / 日程」切换。
   格子内直接列课时（时间 + 名称），圆点颜色表示未开始 / 进行中 / 已结束。 */
.cal-panel {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 14px 18px 14px; margin: 18px 0 4px; box-shadow: var(--shadow-sm);
}
.cal-top { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding-bottom: 2px; border-bottom: 1px solid var(--line); }
.cal-tab { position: relative; font-size: 15px; font-weight: 700; color: var(--brand); padding: 4px 2px 11px; }
.cal-tab::after { content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--brand); border-radius: 2px; }
.cal-notice { font-size: 13px; color: #344054; }
.cal-notice b { color: var(--danger); font-weight: 700; }
.cal-notice a { color: var(--brand); text-decoration: underline; }
.cal-mine { margin-left: auto; }

.cal-toolbar { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; padding: 14px 0 12px; }
.cal-left { display: flex; align-items: center; gap: 8px; justify-self: start; }
.cal-ops { display: flex; gap: 5px; }
.cal-op {
  height: 30px; min-width: 30px; padding: 0 9px; border-radius: 4px; cursor: pointer;
  border: 1px solid #344054; background: #344054; color: #fff; font-size: 14px; line-height: 1; font-weight: 700;
  transition: .15s;
}
.cal-op:hover { background: #475467; }
.cal-today {
  height: 30px; padding: 0 12px; border-radius: 4px; cursor: pointer;
  border: 1px solid #d0d5dd; background: #fff; color: #344054; font-size: 13px;
}
.cal-today:hover { border-color: var(--brand); color: var(--brand); }
.cal-title { font-size: 20px; font-weight: 600; text-align: center; letter-spacing: .01em; color: var(--text); }
.cal-views { display: flex; justify-self: end; border: 1px solid var(--line); border-radius: 5px; overflow: hidden; }
.cal-views button {
  height: 30px; padding: 0 14px; border: 0; border-left: 1px solid var(--line);
  background: #fff; color: #344054; font-size: 13px; cursor: pointer;
}
.cal-views button:first-child { border-left: 0; }
.cal-views button:hover { color: var(--brand); }
.cal-views button.on { background: #344054; color: #fff; }

.cal-board { border: 1px solid var(--line); border-radius: 5px; overflow: hidden; }
.cal-week { display: grid; grid-template-columns: repeat(7, 1fr); background: #fafbfd; }
.cal-week span {
  padding: 8px 0; text-align: center; font-size: 13px; color: #475467;
  border-left: 1px solid var(--line);
}
.cal-week span:first-child { border-left: 0; }

.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); }
.cal-cell {
  min-height: 108px; padding: 6px 8px 8px; background: #fff; cursor: pointer;
  display: flex; flex-direction: column; gap: 4px; transition: background .15s;
  border-left: 1px solid var(--line); border-top: 1px solid var(--line);
}
.cal-grid .cal-cell:nth-child(7n + 1) { border-left: 0; }
.cal-grid .cal-cell:nth-child(-n + 7) { border-top: 0; }
.cal-cell:hover { background: #f8faff; }
.cal-cell.other { background: #fcfcfd; }
.cal-cell.other .cal-date { color: #c3c8d4; }
.cal-cell.other .cal-ev { opacity: .6; }
.cal-cell.today { background: #f5f8ff; }
.cal-cell.today .cal-date { color: var(--brand); font-weight: 700; }
.cal-date { text-align: right; font-size: 12.5px; color: #475467; font-variant-numeric: tabular-nums; }
.cal-evs { display: flex; flex-direction: column; gap: 2px; }
.cal-ev {
  display: flex; align-items: baseline; gap: 5px; padding: 1px 2px; border-radius: 4px;
  font-size: 12px; line-height: 1.55; color: #1d2939; min-width: 0;
}
.cal-ev:hover { background: var(--brand-soft); }
.cal-ev i { width: 6px; height: 6px; border-radius: 50%; flex: none; transform: translateY(-1px); background: #3b82f6; }
.cal-ev b { font-weight: 500; font-variant-numeric: tabular-nums; }
.cal-ev span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-ev.st-live i { background: #12b76a; }
.cal-ev.st-done i { background: #f79009; }
.cal-ev.st-done, .cal-ev.st-done b { color: #98a2b3; }

.view-week .cal-cell { min-height: 300px; }
.view-week .cal-grid .cal-cell { border-top: 0; }

.cal-dayview { padding: 6px 16px 14px; }
.cal-dayview-head { display: flex; align-items: baseline; gap: 10px; padding: 10px 0; font-size: 15px; font-weight: 600; }
.cal-list { display: flex; flex-direction: column; }
.cal-row { display: flex; align-items: center; gap: 12px; padding: 10px 6px; border-top: 1px solid #f2f4f7; font-size: 13.5px; }
.cal-row:hover { background: #f8faff; }
.cal-row-time { width: 52px; flex: none; color: #475467; font-variant-numeric: tabular-nums; }
.cal-row-main { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.4; }
.cal-row-main b { font-weight: 600; }
.cal-pill { flex: none; font-size: 12px; color: #fff; padding: 2px 9px; border-radius: 4px; }
.cal-pill.st-todo { background: #3b82f6; }
.cal-pill.st-live { background: #12b76a; }
.cal-pill.st-done { background: #f79009; }
.cal-list-agenda { padding: 2px 16px 12px; }
.cal-agenda-day { display: flex; gap: 16px; padding: 10px 0; border-top: 1px solid #f2f4f7; }
.cal-agenda-day:first-child { border-top: 0; }
.cal-agenda-date { width: 96px; flex: none; font-size: 13px; font-weight: 600; }
.cal-agenda-date span { margin-left: 6px; font-weight: 400; font-size: 12px; color: var(--muted); }
.cal-agenda-evs { flex: 1; min-width: 0; }
.cal-agenda-evs .cal-row:first-child { border-top: 0; padding-top: 2px; }

.cal-status { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 12px; font-size: 12.5px; color: var(--muted); }
.cal-st { color: #fff; padding: 3px 12px; border-radius: 4px; font-size: 12px; }
.cal-st.st-todo { background: #3b82f6; }
.cal-st.st-live { background: #12b76a; }
.cal-st.st-done { background: #f79009; }
.cal-tip { margin-left: auto; }
.cal-empty { color: var(--muted); font-size: 13px; padding: 18px 4px; }

@media (max-width: 900px) {
  .select-grid { grid-template-columns: repeat(2, 1fr); }
  .cal-toolbar { grid-template-columns: 1fr; justify-items: start; gap: 10px; }
  .cal-title { order: -1; font-size: 17px; }
  .cal-views { justify-self: start; }
  .cal-board { overflow-x: auto; }
  .cal-week, .cal-grid { min-width: 640px; }
}
@media (max-width: 640px) {
  .select-grid { grid-template-columns: 1fr; }
  .cal-cell { min-height: 84px; padding: 4px 5px; }
  .cal-ev span { display: none; }
  .cal-status .cal-tip { margin-left: 0; width: 100%; }
}

/* 注册页：未解锁的下级下拉要一眼看出不可用 */
select.input:disabled { background: #f5f6fa; color: #98a2b3; cursor: not-allowed; }

/* 学习页：试看提示 + 未解锁课时 */
.preview-tip {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap; justify-content: space-between;
  background: var(--brand-soft); border: 1px solid #dbe2ff; color: #2c3a67;
  border-radius: 12px; padding: 10px 16px; font-size: 13px; margin-bottom: 14px;
}
.preview-tip span { flex: 1; min-width: 200px; }
.lesson-item.locked { color: #98a2b3; cursor: not-allowed; }
.lesson-item.locked:hover { background: #fafbfd; }
.lesson-item.locked .dot { border-color: #e4e7ec; }

/* 禁快进的课时：进度条只做展示，不提供拖动 */
.pl-range:disabled { cursor: not-allowed; opacity: .6; }
.player-error { z-index: 3; background: rgba(11, 16, 32, .82); font-size: 13.5px; line-height: 1.7; }

/* ============================== 直播课程 ============================== */
/* 课程卡 / 选课卡上的直播标识：点播课不加任何标记，避免视觉噪音 */
.cover-chip.live { background: linear-gradient(135deg, #f04438, #d92d20); color: #fff; gap: 5px; }
.cover-chip.live .live-dot { background: #fff; }
.live-dot {
  width: 6px; height: 6px; border-radius: 50%; background: #f04438;
  display: inline-block; flex: none; animation: livePulse 1.4s ease-in-out infinite;
}
@keyframes livePulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: .35; transform: scale(.78); }
}
.live-line { font-size: 12.3px; color: #b42318; display: flex; align-items: center; gap: 6px; }
.course-card .live-line { margin-top: -2px; }

/* 首页直播课堂 */
.live-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.live-card {
  background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 18px 18px 16px;
  display: flex; flex-direction: column; gap: 8px; cursor: pointer; transition: .2s ease;
}
.live-card:hover { transform: translateY(-3px); box-shadow: 0 22px 44px -28px rgba(16, 24, 40, .42); border-color: #dbe0f2; }
.live-card h3 { font-size: 15.5px; line-height: 1.45; font-weight: 700; }
.live-card-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.live-flag {
  font-size: 11.5px; font-weight: 700; color: #b42318; background: #fef3f2;
  border-radius: 6px; padding: 2px 8px; display: inline-flex; align-items: center; gap: 5px;
}
.live-flag.on { background: #e5484d; color: #fff; }
.live-flag.on .live-dot { background: #fff; }
.live-card-foot {
  margin-top: auto; padding-top: 10px; border-top: 1px solid #f4f5fa;
  display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 13px;
}

/* 学习页直播状态带 */
.live-banner {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 10px 14px; border-radius: 10px; margin-bottom: 12px;
  background: #fff7ed; border: 1px solid #fed7aa; color: #9a3412; font-size: 13px;
}
.live-banner.on { background: #fef2f2; border-color: #fecaca; color: #b42318; }
.live-banner.off { background: #f8fafc; border-color: #e2e8f0; color: #475467; }
.live-banner .lb-tag { font-size: 11.5px; font-weight: 700; padding: 1px 8px; border-radius: 6px; background: rgba(0, 0, 0, .06); }
.live-banner .tiny { margin-left: auto; opacity: .78; }

/* 播放器：直播平台 H5 观看页 / 直播中角标 */
.player-embed iframe { width: 100%; height: 100%; border: 0; display: block; background: #000; }
.pl-live {
  position: absolute; top: 10px; left: 10px; z-index: 2;
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 11.5px; font-weight: 700; color: #fff;
  background: rgba(229, 72, 77, .92); padding: 3px 9px; border-radius: 6px;
}
.pl-live .live-dot { background: #fff; }

@media (max-width: 860px) {
  .live-grid { grid-template-columns: 1fr; }
}

/* ============================ 后台学员管理 ============================ */
/* 学员资料字段多，给表格一个下限宽度，配合 .table-wrap 的横向滚动，避免列被压成竖排 */
.tbl-users { min-width: 1180px; }
.tbl-users td { white-space: nowrap; }
.tbl-users .u-mono { font-variant-numeric: tabular-nums; letter-spacing: .2px; color: #344054; }
.tbl-users .pw-mask { color: #98a2b3; letter-spacing: 2px; margin-right: 8px; vertical-align: middle; }
.tbl-users .link-btn { font-size: 12px; }
.tbl-users .avatar { flex: none; }

/* 首列（姓名）与末列（操作）固定，中间列横向滚动；横向滚动条常驻可见 */
.table-scroll { overflow-x: auto; overflow-y: visible; }
.table-scroll::-webkit-scrollbar { height: 10px; }
.table-scroll::-webkit-scrollbar-track { background: #f2f4f7; }
.table-scroll::-webkit-scrollbar-thumb { background: #cfd6e4; border-radius: 6px; }
.table-scroll::-webkit-scrollbar-thumb:hover { background: #b6bfd0; }
.tbl-sticky th:first-child,
.tbl-sticky td:first-child { position: sticky; left: 0; z-index: 2; background: #fff; }
.tbl-sticky th:last-child,
.tbl-sticky td:last-child { position: sticky; right: 0; z-index: 2; background: #fff; }
.tbl-sticky thead th:first-child,
.tbl-sticky thead th:last-child { z-index: 3; background: #fbfcff; }
/* border-collapse 下固定列的边框会跟着滚动，用内阴影补回行分隔线 */
.tbl-sticky tbody td:first-child,
.tbl-sticky tbody td:last-child { box-shadow: inset 0 -1px 0 #f3f5fa; }
.tbl-sticky tbody tr:last-child td:first-child,
.tbl-sticky tbody tr:last-child td:last-child { box-shadow: none; }
.tbl-sticky tbody tr:hover td:first-child,
.tbl-sticky tbody tr:hover td:last-child { background: #fafbff; }
/* 固定列边缘的淡阴影，提示中间区域可横向滚动 */
.tbl-sticky th:first-child::after,
.tbl-sticky td:first-child::after { content: ''; position: absolute; top: 0; right: -12px; width: 12px; height: 100%; pointer-events: none; background: linear-gradient(90deg, rgba(16, 24, 40, .07), rgba(16, 24, 40, 0)); }
.tbl-sticky th:last-child::after,
.tbl-sticky td:last-child::after { content: ''; position: absolute; top: 0; left: -12px; width: 12px; height: 100%; pointer-events: none; background: linear-gradient(270deg, rgba(16, 24, 40, .07), rgba(16, 24, 40, 0)); }
.tbl-sticky th:first-child,
.tbl-sticky td:first-child { min-width: 132px; }
.tbl-sticky th:last-child,
.tbl-sticky td:last-child { min-width: 156px; }

/* ==================== 用户管理：分类 Tab / 角色 / 日志 ==================== */
.user-tabs,
.log-tabs {
  display: inline-flex; align-items: center; gap: 4px; flex-wrap: wrap;
  padding: 4px; background: #f2f4f7; border: 1px solid #e4e7ec; border-radius: 10px;
}
.user-tabs { width: fit-content; margin-bottom: 14px; }
.user-tabs a,
.log-tabs a {
  padding: 7px 14px; border-radius: 7px; font-size: 13px; color: #667085;
  text-decoration: none; white-space: nowrap; transition: background .15s, color .15s;
}
.user-tabs a:hover,
.log-tabs a:hover { color: #344054; background: rgba(255, 255, 255, .7); }
.user-tabs a.active,
.log-tabs a.active {
  background: #fff; color: #3538cd; font-weight: 600;
  box-shadow: 0 1px 3px rgba(16, 24, 40, .12);
}
.log-tabs a em {
  font-style: normal; margin-left: 6px; padding: 1px 6px; border-radius: 5px;
  background: rgba(53, 56, 205, .09); color: #3538cd; font-size: 11.5px; font-weight: 700;
}

/* 管理员角色卡片 */
.role-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.role-card {
  background: #fff; border: 1px solid #e4e7ec; border-radius: 14px; padding: 18px;
  box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
}
.role-card.is-off { opacity: .62; }
.role-card .role-top { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.role-card .role-ico {
  width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center;
  background: #eef2ff; color: #3538cd; font-size: 18px;
}
.role-card .role-top .badge:last-child { margin-left: auto; }
.role-card h3 { font-size: 16px; margin: 0 0 2px; color: #101828; }
.role-card .role-code {
  font-size: 11.5px; color: #98a2b3; font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  margin-bottom: 10px;
}
.role-card p { font-size: 12.5px; line-height: 1.6; color: #667085; min-height: 40px; margin: 0 0 12px; }
.role-card .role-meta {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 6px;
  padding: 10px 0; margin-bottom: 12px; font-size: 12px; color: #667085;
  border-top: 1px solid #f2f4f7; border-bottom: 1px solid #f2f4f7;
}
.role-card .role-meta b { color: #344054; }
.role-card .role-actions { display: flex; gap: 8px; }

/* 用户日志表 */
.tbl-logs { min-width: 960px; }
.tbl-logs td { font-size: 12.5px; }
.tbl-logs td:nth-child(7) { max-width: 320px; white-space: normal; color: #475467; }

/* 用户表单里按账号类别显示的专属字段 */
.uf-only {
  padding: 12px 14px 2px; margin-bottom: 14px;
  border: 1px dashed #d0d5dd; border-radius: 10px; background: #fcfcfd;
}
.uf-only > .field:first-child { margin-top: 0; }
.uf-only .field-row.hidden { display: none !important; }

@media (max-width: 860px) {
  .role-grid { grid-template-columns: 1fr; }
  .user-tabs a, .log-tabs a { padding: 6px 10px; font-size: 12px; }
}

/* ============================ 后台订单管理 ============================ */
/* 筛选行：年份 / 学期 / 学校 / 年级 / 班级，五联下拉 */
.admin-filters { margin-top: -6px; gap: 8px; }
.admin-filters .select-sm { width: 128px; }
.admin-filters .select-sm[data-order-filter="term"] { width: 148px; }
.admin-filters .select-sm[data-order-filter="school"] { width: 150px; }
.admin-filters .link-btn { font-size: 12.5px; }
/* 订单列多，给宽度下限让中间列横向滚动；首列（学员）与末列（操作）固定 */
.tbl-orders { min-width: 1500px; }
.tbl-orders td { white-space: nowrap; }
.tbl-orders .u-mono { font-variant-numeric: tabular-nums; letter-spacing: .2px; color: #344054; }
/* 姓名列只放头像 + 姓名，手机号 / 学校 / 班级各自独立成列 */
.tbl-orders th:first-child,
.tbl-orders td:first-child { width: 150px; min-width: 150px; }
/* 固定列必须铺满整列宽，内部文字再截断，否则中间列的字会从缝隙里透出来 */
.tbl-orders td:first-child > div { max-width: 134px; overflow: hidden; }
.tbl-orders td:first-child .row span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tbl-orders .o-phone { width: 122px; min-width: 122px; }
.tbl-orders .o-school { max-width: 190px; min-width: 150px; overflow: hidden; text-overflow: ellipsis; }
.tbl-orders .o-class { max-width: 150px; min-width: 110px; overflow: hidden; text-overflow: ellipsis; }
.tbl-orders .o-course { max-width: 200px; overflow: hidden; text-overflow: ellipsis; }
/* 操作列最多三个按钮（标记已支付 / 取消 / 删除），留够宽度不换行 */
.tbl-orders th:last-child,
.tbl-orders td:last-child { min-width: 118px; }
/* 固定列越窄，遮挡中间内容越少；待付单的三个按钮允许换行 */
.tbl-orders .actions { flex-wrap: wrap; justify-content: flex-end; }
/* 滚动处阴影加重一点，让「中间列滚到固定列下面」看起来是有意的分层 */
.tbl-orders.tbl-sticky td:first-child::after,
.tbl-orders.tbl-sticky th:first-child::after { background: linear-gradient(90deg, rgba(16, 24, 40, .12), rgba(16, 24, 40, 0)); }
.tbl-orders.tbl-sticky td:last-child::after,
.tbl-orders.tbl-sticky th:last-child::after { background: linear-gradient(270deg, rgba(16, 24, 40, .12), rgba(16, 24, 40, 0)); }

/* -------------------------------- 统计中心 --------------------------------
   校管理员 / 班级管理员的前台报表页：左侧固定菜单 + 右侧筛选与表格。
   表格用 .s-tbl 独立命名，避免和后台 .tbl 的固定列规则互相干扰。 */
.stats-wrap { display: grid; grid-template-columns: 208px minmax(0, 1fr); gap: 20px; padding: 16px 0 60px; align-items: start; }
/* 左侧菜单已去掉（导航由顶部页签承担），单栏铺满 */
.stats-wrap.solo { grid-template-columns: minmax(0, 1fr); }
.stats-side { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px; box-shadow: var(--shadow-sm); position: sticky; top: 84px; }
.stats-side .t { font-size: 12px; color: var(--muted); letter-spacing: .04em; padding: 6px 10px 8px; }
.stats-side a { display: flex; align-items: center; gap: 9px; padding: 9px 10px; border-radius: 9px; font-size: 14px; color: #344054; transition: .15s; }
.stats-side a:hover { background: #f6f7fb; }
.stats-side a.on { background: var(--brand-soft); color: var(--brand); font-weight: 700; }
.stats-side .scope { margin-top: 8px; border-top: 1px dashed var(--line); padding: 10px; font-size: 12.5px; color: var(--muted); line-height: 1.55; }
.stats-side .scope b { color: var(--text); font-weight: 600; }

.stats-main { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); overflow: hidden; }
.stats-tabs { display: flex; gap: 24px; padding: 0 20px; border-bottom: 1px solid var(--line); }
.stats-tabs a { padding: 13px 2px 11px; font-size: 14.5px; font-weight: 600; color: var(--muted); border-bottom: 2px solid transparent; }
.stats-tabs a.on { color: var(--brand); border-bottom-color: var(--brand); }
.stats-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 16px 20px 14px; }
.stats-bar label { font-size: 13px; font-weight: 600; color: #344054; }
.stats-bar .input { height: 34px; width: 148px; font-size: 13.5px; }
.stats-bar .btn { height: 34px; }
.stats-bar .btn[type="submit"] { margin-left: 2px; }

.s-tbl { width: 100%; border-collapse: collapse; font-size: 13.2px; }
.s-tbl th { background: #f7f8fc; color: #475467; font-weight: 600; text-align: left; padding: 10px 14px; font-size: 12.6px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.s-tbl td { padding: 11px 14px; border-bottom: 1px solid #f2f3f9; color: #344054; vertical-align: middle; }
.s-tbl tbody tr:hover td { background: #fbfcff; }
.s-tbl .num { font-variant-numeric: tabular-nums; }
.s-tbl .s-empty { padding: 44px 14px; text-align: center; color: var(--muted); font-size: 13.5px; }
.stats-note { padding: 12px 20px 16px; font-size: 12.3px; color: var(--muted); border-top: 1px dashed var(--line); }
.stats-main .pager { padding: 14px 20px 16px; }

/* 统计中心的绿色按钮：与「查看课时 / 查看学生」的强化操作对应 */
.btn-ok { background: var(--ok); color: #fff; }
.btn-ok:hover { background: #0f9d5c; }
.btn-danger.btn-sm { background: #fef3f2; color: #b42318; border: 1px solid #fecdca; }
.btn-danger.btn-sm:hover { background: #fee4e2; }
.modal-xl { max-width: 940px; }
.stats-main .s-tbl th:last-child, .stats-main .s-tbl td:last-child { width: 1%; }

@media (max-width: 900px) {
  .stats-wrap { grid-template-columns: 1fr; }
  .stats-side { position: static; }
  .stats-side { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
  .stats-side .t { display: none; }
  .stats-side .scope { width: 100%; border-top: 0; padding: 2px 10px 6px; }
}
