/* ==========================================================================
   官网站点样式 · 现代简洁风
   ========================================================================== */

:root {
  --brand: #1f5eff;
  --brand-dark: #1447d6;
  --brand-soft: #eaf0ff;
  --ink: #0f1c33;
  --ink-2: #33415c;
  --ink-3: #6b7891;
  --ink-4: #9aa6bd;
  --line: #e6ebf5;
  --bg: #f7f9fc;
  --white: #fff;
  --ok: #12a172;
  --warn: #e8792b;
  --radius: 16px;
  --shadow-sm: 0 2px 8px rgba(15, 28, 51, 0.04);
  --shadow: 0 10px 30px rgba(15, 28, 51, 0.07);
  --shadow-lg: 0 18px 48px rgba(15, 28, 51, 0.12);
  --wrap: 1200px;
  --hd-h: 72px;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Hiragino Sans GB',
    'Microsoft YaHei', 'Helvetica Neue', Arial, sans-serif;
  font-size: 15px;
  line-height: 1.7;
  color: var(--ink-2);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

h1,
h2,
h3,
h4 {
  color: var(--ink);
  font-weight: 700;
  line-height: 1.35;
  margin: 0;
}

p {
  margin: 0;
}

button {
  font-family: inherit;
  cursor: pointer;
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 24px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

/* ---------------------------------- 顶栏 --------------------------------- */

.hd {
  position: sticky;
  top: 0;
  z-index: 60;
  height: var(--hd-h);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}

.hd__inner {
  height: 100%;
  display: flex;
  align-items: center;
  gap: 32px;
}

.hd__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.hd__logo {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  object-fit: contain;
  background: linear-gradient(135deg, var(--brand), #5b8cff);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: 17px;
  overflow: hidden;
}

.hd__logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.hd__name {
  font-size: 17px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: 0.5px;
}

.hd__nav {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.hd__link {
  padding: 8px 14px;
  border-radius: 10px;
  font-size: 14.5px;
  color: var(--ink-2);
  white-space: nowrap;
  transition: color 0.15s, background 0.15s;
}

.hd__link:hover {
  color: var(--brand);
  background: var(--brand-soft);
}

.hd__link.is-active {
  color: var(--brand);
  font-weight: 600;
  background: var(--brand-soft);
}

.hd__cta {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 38px;
  padding: 0 18px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--brand), #4b7dff);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  box-shadow: 0 6px 16px rgba(31, 94, 255, 0.28);
  transition: transform 0.15s, box-shadow 0.15s;
}

.hd__cta:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(31, 94, 255, 0.34);
}

.hd__burger {
  display: none;
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
  font-size: 16px;
}

/* ---------------------------------- 页头 -------------------------------- */

.page-hd {
  padding: 44px 0 28px;
  background: linear-gradient(180deg, #f2f6ff 0%, var(--bg) 100%);
}

.page-hd__crumb {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--ink-4);
  margin-bottom: 10px;
}

.page-hd__crumb a:hover {
  color: var(--brand);
}

.page-hd h1 {
  font-size: 30px;
  letter-spacing: 0.5px;
}

.page-hd p {
  margin-top: 8px;
  font-size: 14.5px;
  color: var(--ink-3);
  max-width: 760px;
}

/* ---------------------------------- 英雄区 ------------------------------- */

.hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(120deg, #10265c 0%, #1f5eff 58%, #4b8bff 100%);
  color: #fff;
}

.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 82% 18%, rgba(255, 255, 255, 0.22), transparent 42%),
    radial-gradient(circle at 8% 88%, rgba(255, 255, 255, 0.12), transparent 46%);
  pointer-events: none;
}

.hero__inner {
  position: relative;
  z-index: 2;
  padding: 66px 0 74px;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 48px;
  align-items: center;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.28);
  font-size: 13px;
  margin-bottom: 20px;
}

.hero h1 {
  color: #fff;
  font-size: 42px;
  line-height: 1.28;
  letter-spacing: 1px;
}

.hero h1 em {
  font-style: normal;
  background: linear-gradient(90deg, #ffe9a8, #ffd166);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero__desc {
  margin-top: 18px;
  font-size: 16px;
  line-height: 1.9;
  color: rgba(255, 255, 255, 0.86);
  max-width: 560px;
}

.hero__actions {
  margin-top: 30px;
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 46px;
  padding: 0 26px;
  border-radius: 12px;
  border: 1px solid transparent;
  font-size: 15px;
  font-weight: 600;
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s, color 0.15s;
}

.btn--primary {
  background: #fff;
  color: var(--brand);
  box-shadow: 0 10px 24px rgba(6, 22, 62, 0.22);
}

.btn--primary:hover {
  transform: translateY(-2px);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.4);
  color: #fff;
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.2);
}

.btn--brand {
  background: linear-gradient(135deg, var(--brand), #4b7dff);
  color: #fff;
  box-shadow: 0 8px 20px rgba(31, 94, 255, 0.3);
}

.btn--brand:hover {
  transform: translateY(-1px);
}

.btn--line {
  background: #fff;
  border-color: var(--line);
  color: var(--ink-2);
}

.btn--line:hover {
  border-color: var(--brand);
  color: var(--brand);
}

.btn--sm {
  height: 36px;
  padding: 0 16px;
  font-size: 13.5px;
  border-radius: 10px;
}

.hero__panel {
  position: relative;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 22px;
  padding: 26px;
  backdrop-filter: blur(6px);
}

.hero__panel-title {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 18px;
}

.hero__stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.hero__stat {
  background: rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  padding: 16px;
}

.hero__stat b {
  display: block;
  font-size: 26px;
  color: #fff;
  line-height: 1.2;
}

.hero__stat span {
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.76);
}

/* 轮播 */
.banner {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  background: #0b1b3f;
}

.banner__track {
  display: flex;
  transition: transform 0.5s ease;
}

.banner__item {
  flex: 0 0 100%;
  position: relative;
  aspect-ratio: 16 / 10;
}

.banner__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.banner__cap {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 16px 18px;
  font-size: 14px;
  color: #fff;
  background: linear-gradient(0deg, rgba(4, 12, 32, 0.78), transparent);
}

.banner__dots {
  position: absolute;
  right: 14px;
  bottom: 14px;
  display: flex;
  gap: 6px;
  z-index: 3;
}

.banner__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.45);
  padding: 0;
}

.banner__dot.is-active {
  background: #fff;
  width: 18px;
  border-radius: 4px;
}

/* ------------------------------ 考试倒计时条 ------------------------------ */

.cd-band {
  background: #fff;
  border-bottom: 1px solid var(--line);
}

.cd-band[hidden] {
  display: none;
}

.cd-band__inner {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 13px 24px;
}

.cd-band__badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  padding: 7px 14px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}

.cd-band__viewport {
  position: relative;
  flex: 1;
  min-width: 0;
  height: 58px;
  overflow: hidden;
}

.cd-track {
  display: flex;
  flex-direction: column;
  transition: transform 0.52s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform;
}

.cd-item {
  display: flex;
  align-items: center;
  gap: 16px;
  height: 58px;
  min-width: 0;
  padding: 0 18px;
  border-radius: 12px;
  border: 1px solid #e2eaff;
  background: linear-gradient(100deg, #f4f7ff, #eef3ff);
}

.cd-item__name {
  font-size: 14.5px;
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cd-item__date {
  font-size: 13px;
  color: var(--ink-3);
  white-space: nowrap;
}

.cd-item__days {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  margin-left: auto;
  flex-shrink: 0;
  font-size: 12.5px;
  color: var(--brand-dark);
  white-space: nowrap;
}

.cd-item__days b {
  font-size: 23px;
  font-weight: 700;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.cd-item--urgent {
  background: linear-gradient(100deg, #fff6f3, #ffe9e2);
  border-color: #ffd8cd;
}

.cd-item--urgent .cd-item__days {
  color: #d4380d;
}

.cd-band__nav {
  display: flex;
  flex-shrink: 0;
  gap: 6px;
}

.cd-band__arrow {
  width: 30px;
  height: 26px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink-3);
  font-size: 11px;
  line-height: 1;
  transition: color 0.16s, border-color 0.16s, background 0.16s;
}

.cd-band__arrow:hover {
  border-color: var(--brand);
  background: var(--brand-soft);
  color: var(--brand);
}

@media (max-width: 720px) {
  .cd-band__inner {
    gap: 10px;
    padding: 12px 16px;
  }

  .cd-band__badge {
    display: none;
  }

  .cd-item {
    gap: 10px;
    padding: 0 12px;
  }

  .cd-item__date {
    display: none;
  }
}

/* ---------------------------------- 区块 --------------------------------- */

.section {
  padding: 62px 0;
}

.section--tight {
  padding: 44px 0;
}

.section--white {
  background: #fff;
}

.section__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 28px;
}

.section__eyebrow {
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--brand);
  text-transform: uppercase;
  margin-bottom: 8px;
}

.section__head h2 {
  font-size: 26px;
  letter-spacing: 0.5px;
}

.section__head p {
  margin-top: 8px;
  font-size: 14px;
  color: var(--ink-3);
}

.section__more {
  flex-shrink: 0;
  font-size: 14px;
  color: var(--brand);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.section__more:hover {
  text-decoration: underline;
}

/* 特性卡 */
.features {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.feature {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  transition: transform 0.18s, box-shadow 0.18s, border-color 0.18s;
}

.feature:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  border-color: #d8e3ff;
}

.feature__icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: 19px;
  margin-bottom: 14px;
}

.feature h3 {
  font-size: 16px;
  margin-bottom: 6px;
}

.feature p {
  font-size: 13.5px;
  color: var(--ink-3);
  line-height: 1.75;
}

/* 公告列表（首页） */
.news-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.news-card {
  display: flex;
  gap: 16px;
  padding: 18px 20px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  transition: border-color 0.16s, box-shadow 0.16s, transform 0.16s;
}

.news-card:hover {
  border-color: #cfdcff;
  box-shadow: var(--shadow-sm);
  transform: translateY(-2px);
}

.news-card__date {
  flex-shrink: 0;
  width: 58px;
  text-align: center;
  border-right: 1px solid var(--line);
  padding-right: 14px;
}

.news-card__day {
  display: block;
  font-size: 22px;
  font-weight: 700;
  color: var(--brand);
  line-height: 1.1;
}

.news-card__ym {
  font-size: 11.5px;
  color: var(--ink-4);
}

.news-card__body {
  min-width: 0;
  flex: 1;
}

.news-card__title {
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.55;
}

.news-card:hover .news-card__title {
  color: var(--brand);
}

.news-card__meta {
  margin-top: 8px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: var(--ink-4);
}

.chip {
  display: inline-flex;
  align-items: center;
  padding: 1px 8px;
  border-radius: 6px;
  font-size: 11.5px;
  background: var(--brand-soft);
  color: var(--brand);
}

.chip--hot {
  background: #fff1e6;
  color: var(--warn);
}

.chip--muted {
  background: #f1f4f9;
  color: var(--ink-3);
}

/* 课程卡片 */
.course-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
}

.course-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.18s, box-shadow 0.18s;
}

.course-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.course-card__cover {
  position: relative;
  aspect-ratio: 16 / 10;
  background: linear-gradient(135deg, #dce8ff, #eef4ff);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #7d9ae0;
  font-size: 13px;
  overflow: hidden;
}

.course-card__cover img {
  width: 100%;
  height: 100%;
  /* 等比缩放完整展示，不裁切图片；比例不一致时留白用白底过渡 */
  object-fit: contain;
  background: #fff;
}

.course-card__tag {
  position: absolute;
  left: 10px;
  top: 10px;
  padding: 2px 9px;
  border-radius: 8px;
  background: rgba(15, 28, 51, 0.62);
  color: #fff;
  font-size: 11.5px;
  backdrop-filter: blur(4px);
}

.course-card__body {
  padding: 14px 16px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.course-card__title {
  font-size: 14.5px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.course-card:hover .course-card__title {
  color: var(--brand);
}

.course-card__sub {
  font-size: 12.5px;
  color: var(--ink-3);
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.course-card__foot {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 12.5px;
  color: var(--ink-4);
}

.price {
  color: #e8452c;
  font-weight: 700;
  font-size: 17px;
}

.price small {
  font-size: 12px;
  font-weight: 500;
}

.price--old {
  color: var(--ink-4);
  font-size: 12px;
  text-decoration: line-through;
  margin-left: 6px;
  font-weight: 400;
}

/* 下载区 */
.dl-band {
  background: linear-gradient(120deg, #10265c, #1f5eff);
  border-radius: 22px;
  padding: 42px 44px;
  color: #fff;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 32px;
  align-items: center;
}

.dl-band h2 {
  color: #fff;
  font-size: 26px;
  margin-bottom: 12px;
}

.dl-band p {
  color: rgba(255, 255, 255, 0.82);
  font-size: 14.5px;
}

.dl-band__actions {
  margin-top: 22px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.dl-band__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.dl-mini {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  font-size: 13.5px;
  color: #fff;
  transition: background 0.16s;
}

.dl-mini:hover {
  background: rgba(255, 255, 255, 0.22);
}

.dl-mini__os {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
}

/* --------------------------------- 列表页 -------------------------------- */

.toolbar {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  padding: 16px 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  margin-bottom: 22px;
}

.tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  flex: 1;
  min-width: 0;
}

.tab {
  height: 34px;
  padding: 0 15px;
  border-radius: 9px;
  border: 1px solid transparent;
  background: #f4f7fc;
  color: var(--ink-2);
  font-size: 13.5px;
  transition: all 0.15s;
}

.tab:hover {
  color: var(--brand);
}

.tab.is-active {
  background: var(--brand);
  color: #fff;
  font-weight: 600;
}

.toolbar__right {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.select,
.input {
  height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  color: var(--ink-2);
  font-size: 13.5px;
  font-family: inherit;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.select:focus,
.input:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(31, 94, 255, 0.12);
}

.input--search {
  width: 220px;
}

.list-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.doc-row {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 20px 24px;
  border-bottom: 1px solid var(--line);
  transition: background 0.15s;
}

.doc-row:last-child {
  border-bottom: none;
}

.doc-row:hover {
  background: #fafcff;
}

.doc-row__main {
  flex: 1;
  min-width: 0;
}

.doc-row__title {
  font-size: 15.5px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.6;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.doc-row:hover .doc-row__title {
  color: var(--brand);
}

.doc-row__sum {
  margin-top: 6px;
  font-size: 13px;
  color: var(--ink-3);
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.doc-row__meta {
  margin-top: 8px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  color: var(--ink-4);
  flex-wrap: wrap;
}

.doc-row__side {
  flex-shrink: 0;
  text-align: right;
  font-size: 12.5px;
  color: var(--ink-4);
  width: 110px;
}

.doc-row__side b {
  display: block;
  font-size: 17px;
  color: var(--ink-2);
}

.pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 26px;
}

.pager button {
  min-width: 36px;
  height: 36px;
  padding: 0 12px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink-2);
  font-size: 13.5px;
}

.pager button:hover:not(:disabled) {
  border-color: var(--brand);
  color: var(--brand);
}

.pager button.is-active {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
  font-weight: 600;
}

.pager button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.empty {
  padding: 64px 20px;
  text-align: center;
  color: var(--ink-4);
  font-size: 14px;
}

.empty__icon {
  font-size: 34px;
  margin-bottom: 12px;
  opacity: 0.5;
}

.skeleton {
  background: linear-gradient(90deg, #f0f3f9 25%, #f7f9fd 37%, #f0f3f9 63%);
  background-size: 400% 100%;
  animation: shimmer 1.4s ease infinite;
  border-radius: 10px;
}

@keyframes shimmer {
  0% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0 50%;
  }
}

/* --------------------------------- 公告详情 ------------------------------- */

.doc-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 28px;
  padding: 34px 0 70px;
  align-items: start;
}

.doc-main {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 40px 44px 46px;
}

.doc-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 12.5px;
  color: var(--ink-4);
  margin-bottom: 18px;
}

.doc-meta__chip {
  padding: 2px 10px;
  border-radius: 7px;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: 12px;
}

.doc-meta__chip--hot {
  background: #fff1e6;
  color: var(--warn);
}

.doc-main h1 {
  font-size: 29px;
  line-height: 1.45;
  letter-spacing: 0.5px;
}

.doc-summary {
  margin-top: 16px;
  padding: 14px 18px;
  border-left: 3px solid var(--brand);
  background: #f6f9ff;
  border-radius: 0 10px 10px 0;
  font-size: 13.5px;
  color: var(--ink-3);
  line-height: 1.85;
}

.article {
  margin-top: 30px;
  font-size: 15.5px;
  line-height: 2;
  color: var(--ink-2);
  word-break: break-word;
}

.article h1,
.article h2,
.article h3,
.article h4 {
  margin: 30px 0 14px;
  line-height: 1.5;
}

.article h1 {
  font-size: 23px;
}

.article h2 {
  font-size: 20px;
  padding-left: 12px;
  border-left: 4px solid var(--brand);
}

.article h3 {
  font-size: 17px;
}

.article p {
  margin: 14px 0;
}

.article a {
  color: var(--brand);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.article img {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: 12px;
  margin: 18px auto;
}

.article ul,
.article ol {
  margin: 14px 0;
  padding-left: 24px;
}

.article li {
  margin: 6px 0;
}

.article blockquote {
  margin: 18px 0;
  padding: 12px 18px;
  border-left: 3px solid #cfdcff;
  background: #f8faff;
  color: var(--ink-3);
  border-radius: 0 10px 10px 0;
}

.article table {
  display: block;
  width: 100%;
  overflow-x: auto;
  border-collapse: collapse;
  margin: 18px 0;
  font-size: 14px;
}

.article th,
.article td {
  border: 1px solid var(--line);
  padding: 9px 12px;
  text-align: left;
}

.article th {
  background: #f6f9ff;
  color: var(--ink);
  font-weight: 600;
}

.article code {
  padding: 2px 6px;
  border-radius: 5px;
  background: #f1f4f9;
  font-size: 13px;
}

.article pre {
  padding: 16px;
  border-radius: 12px;
  background: #0f1c33;
  color: #dbe6ff;
  overflow-x: auto;
}

.article pre code {
  background: none;
  color: inherit;
  padding: 0;
}

.article hr {
  border: none;
  border-top: 1px solid var(--line);
  margin: 28px 0;
}

.doc-attach {
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px dashed var(--line);
}

.doc-attach__title {
  font-size: 16px;
  margin-bottom: 14px;
}

.doc-attach__count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 6px;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: 12px;
  font-weight: 600;
  vertical-align: middle;
}

.doc-attach__list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.doc-attach__item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fbfcff;
  transition: border-color 0.15s, background 0.15s;
}

.doc-attach__item:hover {
  border-color: var(--brand);
  background: #f5f8ff;
}

.doc-attach__icon {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  border-radius: 9px;
  background: var(--brand-soft);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
}

.doc-attach__name {
  flex: 1;
  min-width: 0;
  font-size: 14px;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.doc-attach__size {
  font-size: 12px;
  color: var(--ink-4);
  flex-shrink: 0;
}

.doc-side {
  position: sticky;
  top: calc(var(--hd-h) + 20px);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
}

.doc-side__title {
  font-size: 14.5px;
  font-weight: 700;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.doc-side__item {
  display: block;
  padding: 10px 0;
  border-bottom: 1px dashed #eef2f9;
}

.doc-side__item:last-child {
  border-bottom: none;
}

.doc-side__title-text,
.doc-side__item .doc-side__title {
  font-size: 13.5px;
  color: var(--ink-2);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  padding: 0;
  margin: 0;
  border: none;
}

.doc-side__item:hover .doc-side__title-text,
.doc-side__item:hover .doc-side__title {
  color: var(--brand);
}

.doc-side__date {
  display: block;
  margin-top: 4px;
  font-size: 11.5px;
  color: var(--ink-4);
}

.doc-side__empty {
  font-size: 13px;
  color: var(--ink-4);
}

/* --------------------------------- 题库页 -------------------------------- */

.quiz-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.quiz-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px 26px;
  transition: box-shadow 0.18s, border-color 0.18s;
}

.quiz-card:hover {
  box-shadow: var(--shadow);
  border-color: #d8e3ff;
}

.quiz-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.quiz-card__name {
  font-size: 18px;
  font-weight: 700;
  color: var(--ink);
}

.quiz-card__count {
  font-size: 12.5px;
  color: var(--ink-4);
}

.quiz-card__count b {
  color: var(--brand);
  font-size: 16px;
  margin: 0 2px;
}

.quiz-subjects {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.quiz-subject {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 13px;
  border-radius: 9px;
  background: #f5f8fd;
  border: 1px solid #eaf0fb;
  font-size: 13px;
  color: var(--ink-2);
}

.quiz-subject b {
  font-size: 12px;
  color: var(--brand);
  font-weight: 600;
}

/* -------------------------------- 课程详情 ------------------------------- */

.course-hero {
  background: #fff;
  border-bottom: 1px solid var(--line);
  padding: 34px 0;
}

.course-hero__inner {
  display: grid;
  grid-template-columns: 380px minmax(0, 1fr);
  gap: 32px;
  align-items: start;
}

.course-hero__cover {
  aspect-ratio: 16 / 10;
  border-radius: var(--radius);
  overflow: hidden;
  background: linear-gradient(135deg, #dce8ff, #eef4ff);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #7d9ae0;
  font-size: 13px;
  box-shadow: var(--shadow);
}

.course-hero__cover img {
  width: 100%;
  height: 100%;
  /* 详情页主视觉同样不裁切，按原比例缩放进容器 */
  object-fit: contain;
  background: #fff;
}

.course-hero h1 {
  font-size: 26px;
  line-height: 1.5;
}

.course-hero__tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.course-hero__sub {
  margin-top: 12px;
  font-size: 14px;
  color: var(--ink-3);
  line-height: 1.85;
}

.course-buy {
  margin-top: 24px;
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

.course-buy__price {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.course-buy__price b {
  font-size: 30px;
  color: #e8452c;
  line-height: 1;
}

.course-buy__price b small {
  font-size: 15px;
}

/* 咨询购买弹窗（微信二维码 + 微信号） */
.wx-modal {
  position: fixed;
  inset: 0;
  z-index: 900;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(15, 28, 51, 0.45);
}

.wx-modal.is-open {
  display: flex;
}

.wx-modal__panel {
  position: relative;
  width: 330px;
  max-width: 100%;
  padding: 26px 22px 20px;
  border-radius: 16px;
  background: var(--white);
  box-shadow: var(--shadow-lg);
  text-align: center;
}

.wx-modal__close {
  position: absolute;
  top: 8px;
  right: 10px;
  width: 28px;
  height: 28px;
  border: none;
  border-radius: 50%;
  background: transparent;
  font-size: 20px;
  line-height: 1;
  color: var(--ink-3);
  cursor: pointer;
}

.wx-modal__close:hover {
  background: #f1f5fc;
  color: var(--ink);
}

.wx-modal__title {
  font-size: 17px;
  color: var(--ink);
}

.wx-modal__course {
  margin-top: 6px;
  font-size: 12.5px;
  color: var(--ink-3);
  line-height: 1.6;
  word-break: break-all;
}

.wx-modal__qr {
  margin: 16px auto 12px;
  width: 186px;
  height: 186px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fbfcfe;
}

.wx-modal__qr img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.wx-modal__qr-empty {
  padding: 0 12px;
  font-size: 12px;
  line-height: 1.8;
  color: var(--ink-3);
}

.wx-modal__qr-empty small {
  color: var(--ink-4);
}

.wx-modal__tip {
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--ink-2);
}

.wx-modal__id {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px dashed var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 13px;
  color: var(--ink-2);
}

.wx-modal__id b {
  color: var(--ink);
}

.wx-modal__copy {
  padding: 3px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--white);
  font-size: 12px;
  color: var(--ink-2);
  cursor: pointer;
}

.wx-modal__copy:hover {
  border-color: var(--brand);
  color: var(--brand);
}

/* 免费试听课时行 */
.chapter__video--preview {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  margin: 0 -10px;
  border-radius: 10px;
  cursor: pointer;
}

.chapter__video--preview:hover {
  background: var(--brand-soft);
}

.chapter__video--preview .chapter__video-title {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.preview-tag {
  flex-shrink: 0;
  padding: 2px 7px;
  border-radius: 8px;
  background: rgba(18, 161, 114, 0.12);
  font-size: 11px;
  font-weight: 600;
  color: var(--ok);
}

.chapter__video-dur {
  flex-shrink: 0;
  font-size: 11.5px;
  color: var(--ink-4);
}

.preview-play {
  flex-shrink: 0;
  font-size: 12px;
  font-weight: 600;
  color: var(--brand);
}

/* 试听视频弹窗播放器 */
.vmodal {
  position: fixed;
  inset: 0;
  z-index: 950;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(6, 12, 24, 0.72);
}

.vmodal.is-open {
  display: flex;
}

.vmodal__panel {
  width: min(860px, 100%);
  padding: 14px 16px 14px;
  border-radius: 16px;
  background: var(--white);
  box-shadow: var(--shadow-lg);
}

.vmodal__head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.vmodal__tag {
  flex-shrink: 0;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(18, 161, 114, 0.12);
  font-size: 12px;
  font-weight: 600;
  color: var(--ok);
}

.vmodal__title {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--ink);
}

.vmodal__close {
  flex-shrink: 0;
  width: 30px;
  height: 30px;
  border: none;
  border-radius: 50%;
  background: transparent;
  font-size: 20px;
  line-height: 1;
  color: var(--ink-3);
  cursor: pointer;
}

.vmodal__close:hover {
  background: #f1f5fc;
  color: var(--ink);
}

.vmodal__video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 10px;
  background: #000;
}

.vmodal__tip {
  margin-top: 12px;
  text-align: center;
  font-size: 12.5px;
  color: var(--ink-3);
}

.course-detail {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  /* 只覆盖上下内边距，左右沿用 .wrap 的 24px */
  padding-top: 34px;
  padding-bottom: 70px;
  align-items: start;
}

.course-panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px 32px;
  margin-bottom: 20px;
}

.course-panel h2 {
  font-size: 18px;
  margin-bottom: 16px;
}

.chapter {
  border-bottom: 1px dashed #eef2f9;
  padding: 14px 0;
}

.chapter:last-child {
  border-bottom: none;
}

.chapter__head {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--ink);
}

.chapter__idx {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  border-radius: 7px;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: 11.5px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.chapter__videos {
  margin: 8px 0 0 32px;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.chapter__video {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--ink-3);
}

.chapter__video::before {
  content: '▷';
  color: var(--ink-4);
  font-size: 11px;
}

.chapter__chapter {
  margin-left: 32px;
  padding-top: 12px;
}

.highlight-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.highlight-item {
  display: flex;
  gap: 10px;
  font-size: 14px;
  color: var(--ink-2);
}

.highlight-item::before {
  content: '✓';
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border-radius: 6px;
  background: #e8f8f1;
  color: var(--ok);
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
}

/* -------------------------------- 下载页 -------------------------------- */

.dl-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.dl-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: box-shadow 0.18s, border-color 0.18s;
}

.dl-card:hover {
  box-shadow: var(--shadow);
  border-color: #d8e3ff;
}

.dl-card__head {
  display: flex;
  align-items: center;
  gap: 12px;
}

.dl-card__icon {
  width: 46px;
  height: 46px;
  border-radius: 13px;
  background: var(--brand-soft);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}

.dl-card__name {
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
}

.dl-card__ver {
  font-size: 12.5px;
  color: var(--ink-4);
}

.dl-card__log {
  font-size: 13px;
  color: var(--ink-3);
  line-height: 1.8;
  white-space: pre-wrap;
  padding: 12px 14px;
  background: #fafcff;
  border-radius: 10px;
  border: 1px solid #eef2f9;
  max-height: 120px;
  overflow: auto;
}

.dl-card__foot {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
  color: var(--ink-4);
}

.dl-card__foot .btn {
  margin-left: auto;
}

.dl-empty {
  padding: 40px;
  text-align: center;
  color: var(--ink-4);
  font-size: 14px;
  background: #fff;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
}

.history-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.history-table th,
.history-table td {
  padding: 13px 18px;
  text-align: left;
  border-bottom: 1px solid var(--line);
}

.history-table th {
  background: #f7f9fd;
  font-size: 13px;
  color: var(--ink-3);
  font-weight: 600;
}

.history-table tr:last-child td {
  border-bottom: none;
}

.history-table td a {
  color: var(--brand);
  font-weight: 600;
}

/* -------------------------------- 关于我们 ------------------------------- */

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.6fr);
  gap: 28px;
  align-items: start;
}

.about-main {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 34px 38px;
}

.about-main h2 {
  font-size: 20px;
  margin: 28px 0 12px;
}

.about-main h2:first-child {
  margin-top: 0;
}

.about-main p {
  font-size: 14.5px;
  line-height: 1.95;
  color: var(--ink-2);
  margin-bottom: 12px;
}

.about-side {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.about-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}

.about-card h3 {
  font-size: 15px;
  margin-bottom: 12px;
}

.about-card__row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 0;
  font-size: 13.5px;
  border-bottom: 1px dashed #eef2f9;
}

.about-card__row:last-child {
  border-bottom: none;
}

.about-card__row span {
  color: var(--ink-4);
}

/* --------------------------------- 页脚 --------------------------------- */

.ft {
  margin-top: 20px;
  background: #0d1a35;
  color: rgba(255, 255, 255, 0.68);
  font-size: 13.5px;
}

.ft__inner {
  padding: 48px 0 26px;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) repeat(2, minmax(0, 0.8fr));
  gap: 36px;
}

.ft__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.ft__logo {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--brand), #5b8cff);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 700;
}

.ft__name {
  color: #fff;
  font-size: 16px;
  font-weight: 700;
}

.ft__desc {
  line-height: 1.9;
  max-width: 380px;
}

.ft__col h4 {
  color: #fff;
  font-size: 14px;
  margin-bottom: 14px;
  font-weight: 600;
}

.ft__col a {
  display: block;
  padding: 5px 0;
  color: rgba(255, 255, 255, 0.66);
  transition: color 0.15s;
}

.ft__col a:hover {
  color: #fff;
}

.ft__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 18px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.45);
}

/* --------------------------------- 404 ---------------------------------- */

.nf {
  padding: 110px 0 130px;
  text-align: center;
}

.nf__code {
  font-size: 92px;
  font-weight: 800;
  line-height: 1;
  background: linear-gradient(135deg, var(--brand), #7aa4ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.nf h1 {
  margin-top: 18px;
  font-size: 22px;
}

.nf p {
  margin-top: 10px;
  color: var(--ink-3);
  font-size: 14px;
}

.nf__actions {
  margin-top: 26px;
  display: flex;
  gap: 12px;
  justify-content: center;
}

/* -------------------------------- 响应式 -------------------------------- */

@media (max-width: 1080px) {
  .hero__inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 34px;
    padding: 52px 0 60px;
  }

  .hero h1 {
    font-size: 34px;
  }

  .features {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .course-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .doc-layout {
    grid-template-columns: minmax(0, 1fr) 260px;
  }

  .course-detail {
    grid-template-columns: minmax(0, 1fr);
  }

  .course-hero__inner {
    grid-template-columns: minmax(0, 1fr);
  }

  .course-hero__cover {
    max-width: 420px;
  }

  .dl-band {
    grid-template-columns: minmax(0, 1fr);
    padding: 34px 30px;
  }
}

@media (max-width: 860px) {
  .hd__nav {
    position: fixed;
    left: 0;
    right: 0;
    top: var(--hd-h);
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 12px 16px 18px;
    background: #fff;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
    transform: translateY(-140%);
    transition: transform 0.24s ease;
    max-height: calc(100vh - var(--hd-h));
    overflow: auto;
  }

  .hd__nav.is-open {
    transform: translateY(0);
  }

  .hd__burger {
    display: block;
    margin-left: auto;
  }

  .hd__cta {
    display: none;
  }

  .hero h1 {
    font-size: 28px;
  }

  .section {
    padding: 46px 0;
  }

  .section__head {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .news-grid,
  .quiz-grid,
  .dl-grid {
    grid-template-columns: 1fr;
  }

  .course-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .doc-layout {
    grid-template-columns: 1fr;
  }

  .doc-side {
    position: static;
  }

  .doc-main {
    padding: 26px 20px 32px;
  }

  .doc-main h1 {
    font-size: 22px;
  }

  .article {
    font-size: 15px;
  }

  .ft__inner {
    grid-template-columns: 1fr;
    gap: 26px;
    padding: 36px 0 20px;
  }

  .about-grid {
    grid-template-columns: 1fr;
  }

  .hero__stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  .input--search {
    width: 100%;
  }

  .history-table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }
}

@media (max-width: 480px) {
  .wrap {
    padding: 0 16px;
  }

  .course-grid {
    grid-template-columns: 1fr;
  }

  .features {
    grid-template-columns: 1fr;
  }

  .doc-row {
    padding: 16px 16px;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .doc-row__side {
    width: auto;
    text-align: left;
    display: flex;
    align-items: baseline;
    gap: 8px;
  }

  .doc-row__side b {
    display: inline;
    font-size: 13px;
  }
}

/* --------------------------------- 轻提示 -------------------------------- */

.site-toast {
  position: fixed;
  left: 50%;
  bottom: 38px;
  z-index: 990;
  transform: translate(-50%, 12px);
  max-width: min(80vw, 420px);
  padding: 11px 20px;
  border-radius: 12px;
  background: rgba(15, 28, 51, 0.92);
  color: #fff;
  font-size: 13.5px;
  line-height: 1.5;
  text-align: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s, transform 0.18s;
}

.site-toast.is-show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.site-toast--ok {
  background: rgba(18, 161, 114, 0.95);
}

/* ------------------------------ 页头登录入口 ------------------------------ */

.hd__auth {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
}

/* 移动端汉堡菜单里的登录入口：桌面端隐藏 */
.hd__auth-link {
  display: none;
}

.hd__cta--user {
  gap: 8px;
  padding-left: 6px;
}

.hd__avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.24);
  font-size: 13px;
  font-weight: 600;
  color: #fff;
}

/* --------------------------------- 登录页 -------------------------------- */

.auth {
  padding: 56px 0 76px;
  background: radial-gradient(120% 90% at 12% 0%, #eaf0ff 0%, var(--bg) 58%);
}

.auth__wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  gap: 56px;
  align-items: center;
}

.auth__aside h1 {
  font-size: 30px;
  letter-spacing: 0.5px;
}

.auth__aside p {
  margin-top: 14px;
  font-size: 14.5px;
  color: var(--ink-3);
  max-width: 460px;
}

.auth__list {
  list-style: none;
  margin: 26px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.auth__list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
  color: var(--ink-2);
}

.auth__list span {
  flex-shrink: 0;
  width: 30px;
  height: 30px;
  border-radius: 10px;
  background: #fff;
  border: 1px solid var(--line);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}

.auth__card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 26px 28px 24px;
  box-shadow: var(--shadow);
}

.auth__tabs {
  background: #f4f7fc;
  border-radius: 12px;
  padding: 4px;
  gap: 4px;
  margin-bottom: 22px;
}

.auth__tabs .tab {
  flex: 1;
  height: 36px;
  background: transparent;
  border-radius: 9px;
  font-size: 14px;
}

.auth__tabs .tab.is-active {
  background: #fff;
  color: var(--brand);
  box-shadow: var(--shadow-sm);
  font-weight: 600;
}

.auth__form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

/* hidden 属性需要覆盖 .field 的 display:flex */
.field[hidden] {
  display: none;
}

.field__label {
  font-size: 13px;
  color: var(--ink-3);
}

.field .input {
  height: 42px;
  width: 100%;
  font-size: 14px;
}

.field__row {
  display: flex;
  gap: 10px;
}

.field__row .input {
  flex: 1;
  min-width: 0;
}

.field__row .btn {
  flex-shrink: 0;
  height: 42px;
}

.auth__error {
  margin: 0;
  padding: 9px 12px;
  border-radius: 10px;
  background: #fff1f0;
  border: 1px solid #ffd5d2;
  color: #d92d20;
  font-size: 13px;
}

.auth__submit {
  height: 44px;
  width: 100%;
  font-size: 15px;
}

.auth__tip {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--ink-4);
}

.auth__tip b {
  color: var(--brand);
}

/* -------------------------------- 个人中心 ------------------------------- */

.me-hd__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.me-hd__user {
  display: flex;
  align-items: center;
  gap: 16px;
}

.me-hd__avatar {
  width: 58px;
  height: 58px;
  border-radius: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--brand), #4b7dff);
  color: #fff;
  font-size: 24px;
  font-weight: 600;
  box-shadow: 0 8px 20px rgba(31, 94, 255, 0.28);
}

.me-hd__user h1 {
  font-size: 24px;
}

.me-hd__meta {
  margin-top: 4px;
  font-size: 13px;
  color: var(--ink-3);
}

.me-hd__actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.me-hd__stats {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 22px;
}

.me-stat {
  flex: 1 1 160px;
  padding: 14px 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-sm);
}

.me-stat b {
  display: block;
  font-size: 20px;
  color: var(--ink);
}

.me-stat span {
  font-size: 12.5px;
  color: var(--ink-4);
}

.me-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 24px;
  /* 只覆盖上下内边距，左右沿用 .wrap 的 24px，与上方统计卡片左右对齐 */
  padding-top: 26px;
  padding-bottom: 70px;
  align-items: start;
}

.me-panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 24px 26px;
}

.me-panel__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.me-panel__head h2 {
  font-size: 18px;
}

.me-panel__hint {
  font-size: 12.5px;
  color: var(--ink-4);
}

.me-courses {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.me-course__bar {
  height: 5px;
  border-radius: 999px;
  background: #eef2f9;
  overflow: hidden;
}

.me-course__bar i {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand), #4b7dff);
}

.me-course__expire {
  flex-shrink: 0;
  color: var(--ink-4);
  font-size: 11.5px;
}

.me-side {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.me-side .course-panel {
  padding: 22px 22px 24px;
}

.me-side__p {
  font-size: 13px;
  line-height: 1.85;
  color: var(--ink-3);
}

/* -------------------------------- 网页学习 ------------------------------- */

.learn-top {
  /* 只覆盖上下内边距，左右沿用 .wrap 的 24px，保证标题与下方播放器左右对齐 */
  padding-top: 26px;
  padding-bottom: 18px;
}

.learn-top__row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.learn-top__row h1 {
  font-size: 22px;
  line-height: 1.5;
  /* flex 子项默认 min-width:auto 会被长标题撑破，窄屏必须允许收缩换行 */
  min-width: 0;
  overflow-wrap: anywhere;
}

.learn-top__sub {
  margin-top: 6px;
  font-size: 13px;
  color: var(--ink-3);
}

.learn-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 22px;
  padding-bottom: 70px;
  align-items: start;
}

.learn-main {
  min-width: 0;
}

.learn-player {
  background: #0b1220;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.learn-player__video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

/* 版权保护：隐藏原生控件里的「下载」按钮（controlslist 之外的兜底） */
.learn-player__video::-webkit-media-controls-download-button,
.vmodal__video::-webkit-media-controls-download-button {
  display: none !important;
}

.learn-now {
  margin-top: 16px;
  padding: 14px 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.learn-now__meta {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.learn-now__index {
  flex-shrink: 0;
  padding: 3px 10px;
  border-radius: 8px;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: 12px;
  font-weight: 600;
}

.learn-now__meta b {
  display: block;
  font-size: 15px;
  color: var(--ink);
  line-height: 1.5;
}

.learn-now__chapter {
  font-size: 12.5px;
  color: var(--ink-4);
}

.learn-now__actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

.learn-side {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.learn-side__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
}

.learn-side__head h2 {
  font-size: 16px;
}

.learn-side__count {
  font-size: 12.5px;
  color: var(--ink-4);
}

.learn-catalog {
  max-height: 620px;
  overflow-y: auto;
  padding: 8px 10px 14px;
}

.learn-chapter {
  padding: 6px 0;
}

.learn-chapter__head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 8px 6px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink);
}

.learn-chapter__idx {
  width: 20px;
  height: 20px;
  border-radius: 6px;
  background: #f1f4f9;
  color: var(--ink-3);
  font-size: 11.5px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.learn-lesson {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px 10px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  font-family: inherit;
  font-size: 13px;
  color: var(--ink-2);
  text-align: left;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.learn-lesson:hover {
  background: #f6f9ff;
  color: var(--brand);
}

.learn-lesson.is-current {
  background: var(--brand-soft);
  border-color: rgba(31, 94, 255, 0.24);
  color: var(--brand);
  font-weight: 600;
}

.learn-lesson__no {
  flex-shrink: 0;
  font-size: 11.5px;
  color: var(--ink-4);
  font-variant-numeric: tabular-nums;
}

.learn-lesson.is-current .learn-lesson__no {
  color: var(--brand);
}

.learn-lesson__title {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.learn-lesson__dur {
  flex-shrink: 0;
  font-size: 11.5px;
  color: var(--ink-4);
}

.learn-lesson__play {
  flex-shrink: 0;
  font-size: 11px;
  color: var(--ink-4);
}

.learn-lesson.is-current .learn-lesson__play {
  color: var(--brand);
}

@media (max-width: 1100px) {
  .auth__wrap {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
  }

  .me-body {
    grid-template-columns: minmax(0, 1fr);
  }

  .me-courses {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  /* 学习页（平板 / 手机）：播放器置顶，课程标题信息下移到播放器之后，目录最后 */
  body[data-page='learn'] main {
    display: flex;
    flex-direction: column;
  }

  .learn-layout,
  .learn-main {
    display: contents;
  }

  .learn-player,
  .learn-now,
  .learn-side {
    width: calc(100% - 48px);
    max-width: calc(var(--wrap) - 48px);
    margin-left: auto;
    margin-right: auto;
  }

  .learn-player {
    order: 1;
    margin-top: 12px;
  }

  .learn-top {
    order: 2;
    padding: 18px 24px 0;
  }

  .learn-now {
    order: 3;
    margin-top: 14px;
  }

  .learn-side {
    order: 4;
    margin-top: 22px;
    margin-bottom: 60px;
  }

  .learn-catalog {
    max-height: none;
  }
}

@media (max-width: 640px) {
  .auth {
    padding: 32px 0 52px;
  }

  .auth__card {
    padding: 20px 18px;
  }

  .me-courses {
    grid-template-columns: 1fr;
  }

  .me-hd__avatar {
    width: 48px;
    height: 48px;
    font-size: 20px;
    border-radius: 14px;
  }

  .me-hd__user h1 {
    font-size: 20px;
  }

  .learn-top__row h1 {
    font-size: 18px;
  }

  .hd__cta--user .hd__cta-text {
    display: none;
  }

  /* 手机端课程详情：收窄面板内边距与目录缩进，避免内容最小宽度超出屏幕 */
  .course-panel {
    padding: 20px 16px;
  }

  .chapter__videos,
  .chapter__chapter {
    margin-left: 18px;
  }

  .chapter__video--preview {
    margin-left: 0;
    margin-right: 0;
  }
}

/* 860 以下页头 CTA 收起，登录入口改到汉堡菜单内 */
@media (max-width: 860px) {
  .hd__auth-link {
    display: block;
    margin-top: 6px;
    color: var(--brand);
    font-weight: 600;
  }
}

/* 手机端学习页：与 .wrap 的 16px 内边距对齐 */
@media (max-width: 480px) {
  .learn-player,
  .learn-now,
  .learn-side {
    width: calc(100% - 32px);
    max-width: calc(var(--wrap) - 32px);
  }

  .learn-player {
    margin-top: 10px;
  }

  .learn-top {
    padding: 14px 16px 0;
  }
}

/* ---------------------------- 移动端底部导航 ---------------------------- */

.tabbar {
  display: none;
}

@media (max-width: 1100px) {
  /* 面包屑与底部导航功能重复，手机 / 平板隐藏 */
  .page-hd__crumb {
    display: none;
  }

  .tabbar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 80;
    display: flex;
    background: rgba(255, 255, 255, 0.96);
    -webkit-backdrop-filter: saturate(180%) blur(12px);
    backdrop-filter: saturate(180%) blur(12px);
    border-top: 1px solid var(--line);
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }

  .tabbar__item {
    flex: 1 1 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    height: 56px;
    font-size: 11px;
    line-height: 1;
    color: var(--ink-4);
    -webkit-tap-highlight-color: transparent;
    transition: color 0.18s ease;
  }

  .tabbar__item svg {
    width: 22px;
    height: 22px;
  }

  .tabbar__item.is-active {
    color: var(--brand);
    font-weight: 600;
  }

  /* 给底部导航留出高度，避免遮挡页脚内容 */
  .ft {
    padding-bottom: calc(56px + env(safe-area-inset-bottom, 0px));
  }
}

/* ------------------- 移动端：学习页 / 课程详情沉浸式版式 ------------------- */

/* 课程详情「目录 / 详情」切换（桌面端不显示） */
.course-tabs {
  display: none;
  grid-column: 1 / -1;
  position: sticky;
  top: var(--hd-h);
  z-index: 6;
  background: #fff;
  border-bottom: 1px solid var(--line);
}

.course-tabs__btn {
  flex: 1 1 0;
  padding: 13px 0;
  font-family: inherit;
  font-size: 14px;
  color: var(--ink-3);
  background: none;
  border: 0;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.course-tabs__btn.is-active {
  color: var(--brand);
  font-weight: 600;
  border-bottom-color: var(--brand);
}

/* 课程详情底部固定操作条（移动端替代全局底部导航） */
.course-bar {
  display: none;
}

@media (max-width: 1100px) {
  /* 页脚只保留公司信息、版权与备案号 */
  .ft__inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
    padding: 26px 0 16px;
  }

  .ft__col {
    display: none;
  }

  .ft__desc {
    max-width: none;
    font-size: 12.5px;
    line-height: 1.8;
  }

  .ft__brand {
    margin-bottom: 10px;
  }

  .ft__bottom {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    font-size: 12px;
  }

  /* 学习页：播放器贴边铺满，信息区与目录整宽 */
  .learn-player {
    order: 1;
    width: 100%;
    max-width: none;
    margin: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .learn-top {
    order: 2;
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 16px;
    background: #fff;
    border-bottom: 1px solid var(--line);
  }

  .learn-top__row h1 {
    font-size: 19px;
    line-height: 1.45;
  }

  .learn-top__sub {
    margin-top: 8px;
    font-size: 12.5px;
  }

  .learn-now {
    order: 3;
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 13px 16px;
    border-radius: 0;
    border-left: 0;
    border-right: 0;
    border-top: 0;
  }

  .learn-side {
    order: 4;
    width: 100%;
    max-width: none;
    margin: 10px 0 0;
    border-radius: 0;
    border-left: 0;
    border-right: 0;
  }

  .learn-side__head {
    padding: 14px 16px 12px;
  }

  .learn-catalog {
    padding: 0;
  }

  .learn-chapter__head {
    padding: 12px 16px 8px;
    background: #f7f9fd;
  }

  .learn-lesson {
    padding: 13px 16px;
    border: 0;
    border-top: 1px solid #f1f4f9;
    border-radius: 0;
  }

  .learn-lesson.is-current {
    border-color: transparent;
    border-top-color: #f1f4f9;
    background: var(--brand-soft);
  }

  /* 课程详情：封面贴边、信息整宽、目录与详情分栏 */
  body[data-page='course'] .tabbar {
    display: none;
  }

  .course-hero {
    padding: 0;
  }

  .course-hero__inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
    padding: 0 0 16px;
  }

  .course-hero__cover {
    max-width: none;
    margin-bottom: 16px;
    border-radius: 0;
    aspect-ratio: 16 / 9;
    box-shadow: none;
  }

  .course-hero__tags,
  .course-hero h1,
  .course-hero__sub,
  .course-buy {
    padding-left: 16px;
    padding-right: 16px;
  }

  .course-hero h1 {
    font-size: 19px;
    line-height: 1.5;
  }

  .course-buy {
    gap: 10px;
    margin-top: 18px;
  }

  .course-buy .btn {
    flex: 1 1 auto;
  }

  .course-detail {
    gap: 0;
    padding-top: 0;
    padding-bottom: 76px;
  }

  /* Tab 已标明「目录」，面板内标题不再重复 */
  #course-catalog > h2 {
    display: none;
  }

  .course-panel {
    margin-bottom: 10px;
    padding: 16px;
    border-radius: 0;
    border-left: 0;
    border-right: 0;
  }

  .course-tabs {
    display: flex;
  }

  /* 目录 / 详情互斥展示，切换由 data-tab 控制 */
  .course-detail[data-tab='catalog'] [data-tab-panel='detail'],
  .course-detail[data-tab='detail'] [data-tab-panel='catalog'] {
    display: none;
  }

  .course-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 80;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px calc(8px + env(safe-area-inset-bottom, 0px));
    background: rgba(255, 255, 255, 0.97);
    -webkit-backdrop-filter: saturate(180%) blur(12px);
    backdrop-filter: saturate(180%) blur(12px);
    border-top: 1px solid var(--line);
  }

  .course-bar__ghost {
    flex: 0 0 auto;
    width: 50px;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    padding: 0;
    font-family: inherit;
    font-size: 10.5px;
    line-height: 1;
    color: var(--ink-3);
    background: none;
    border: 0;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }

  .course-bar__ghost svg {
    width: 20px;
    height: 20px;
  }

  .course-bar__cta {
    flex: 1 1 auto;
    height: 44px;
    border-radius: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--brand);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    box-shadow: 0 6px 16px rgba(31, 94, 255, 0.28);
  }
}

/* ---------------------- 题库页：题型切换 / 卡片 / 知识树 ---------------------- */

.qb {
  padding-bottom: 34px;
}

/* 考试类型下拉 */
.qb-exam {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.qb-exam__btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 40px;
  padding: 0 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-family: inherit;
  font-size: 14px;
  color: var(--ink);
  cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.qb-exam__btn:hover {
  border-color: rgba(31, 94, 255, 0.4);
}

.qb-exam__btn[aria-expanded='true'] {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(31, 94, 255, 0.1);
}

.qb-exam__cap {
  font-size: 12.5px;
  color: var(--ink-4);
}

.qb-exam__name {
  font-weight: 600;
}

.qb-exam__caret {
  width: 16px;
  height: 16px;
  color: var(--ink-4);
  transition: transform 0.2s;
}

.qb-exam__btn[aria-expanded='true'] .qb-exam__caret {
  transform: rotate(180deg);
}

.qb-exam__panel {
  position: absolute;
  z-index: 30;
  top: calc(100% + 8px);
  left: 0;
  min-width: 244px;
  max-height: 320px;
  overflow-y: auto;
  padding: 6px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 16px 40px rgba(15, 35, 80, 0.14);
}

.qb-exam__opt {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 12px;
  background: none;
  border: 0;
  border-radius: 8px;
  font-family: inherit;
  font-size: 14px;
  color: var(--ink-2);
  text-align: left;
  cursor: pointer;
}

.qb-exam__opt:hover {
  background: #f4f7ff;
}

.qb-exam__opt.is-active {
  background: var(--brand-soft);
  color: var(--brand);
  font-weight: 600;
}

.qb-exam__opt small {
  flex-shrink: 0;
  font-size: 12px;
  font-weight: 400;
  color: var(--ink-4);
}

/* 科目横排 */
.qb-subjects {
  display: flex;
  gap: 8px;
  margin: 16px 0 18px;
  padding-bottom: 2px;
  overflow-x: auto;
  scrollbar-width: none;
}

.qb-subjects::-webkit-scrollbar {
  display: none;
}

.qb-subject {
  flex: 0 0 auto;
  height: 36px;
  padding: 0 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: inherit;
  font-size: 14px;
  color: var(--ink-2);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.qb-subject:hover {
  border-color: rgba(31, 94, 255, 0.4);
  color: var(--brand);
}

.qb-subject.is-active {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
  font-weight: 600;
  box-shadow: 0 6px 16px rgba(31, 94, 255, 0.22);
}

/* 功能卡片 */
.qb-feats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 20px;
}

.qb-feat {
  position: relative;
  overflow: hidden;
  min-height: 134px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 18px;
  border-radius: 14px;
  color: #fff;
  box-shadow: 0 10px 24px rgba(15, 35, 80, 0.12);
  transition: transform 0.18s, box-shadow 0.18s;
}

.qb-feat:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 30px rgba(15, 35, 80, 0.18);
}

.qb-feat::after {
  content: '';
  position: absolute;
  right: -30px;
  bottom: -38px;
  width: 124px;
  height: 124px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
}

.qb-feat--blue {
  background: linear-gradient(135deg, #5a7cff, #8b6cff);
}

.qb-feat--green {
  background: linear-gradient(135deg, #1ec8a5, #35d07f);
}

.qb-feat--orange {
  background: linear-gradient(135deg, #ff9f43, #ffc93c);
}

.qb-feat--red {
  background: linear-gradient(135deg, #ff6b81, #ff9a62);
}

.qb-feat__icon {
  position: relative;
  z-index: 1;
  width: 26px;
  height: 26px;
  opacity: 0.95;
}

.qb-feat__icon svg {
  display: block;
  width: 26px;
  height: 26px;
}

.qb-feat__name {
  position: relative;
  z-index: 1;
  font-size: 17px;
  font-weight: 700;
}

.qb-feat__desc {
  position: relative;
  z-index: 1;
  font-size: 12.5px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.9);
}

.qb-feat__tag {
  position: relative;
  z-index: 1;
  align-self: flex-start;
  margin-top: auto;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
  font-size: 11.5px;
  font-weight: 600;
}

/* 专项练习知识树 */
.qb-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.qb-card__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 20px 14px;
  border-bottom: 1px solid var(--line);
}

.qb-card__head h2 {
  font-size: 17px;
}

.qb-card__hint {
  font-size: 12.5px;
  color: var(--ink-4);
}

.qb-tree {
  padding: 6px 10px 14px;
}

.qb-tree__empty {
  padding: 28px 12px;
  text-align: center;
  font-size: 13.5px;
  color: var(--ink-4);
}

.qb-node__row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 10px;
  border-bottom: 1px solid #f2f5fa;
}

.qb-node:last-child > .qb-node__row {
  border-bottom: 0;
}

.qb-node--l2 > .qb-node__row {
  padding-left: 34px;
  background: #fafcff;
}

.qb-node--l3 > .qb-node__row {
  padding-left: 58px;
  background: #fafcff;
}

.qb-node__toggle {
  flex: 1 1 auto;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0;
  background: none;
  border: 0;
  font-family: inherit;
  font-size: 14px;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}

.qb-node__toggle.is-leaf {
  cursor: default;
}

.qb-node__name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.qb-node__caret {
  flex-shrink: 0;
  position: relative;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--brand-soft);
  transition: transform 0.2s;
}

.qb-node__caret::after {
  content: '';
  position: absolute;
  left: 6px;
  top: 5px;
  width: 0;
  height: 0;
  border-left: 5px solid var(--brand);
  border-top: 4px solid transparent;
  border-bottom: 4px solid transparent;
}

.qb-node__toggle[aria-expanded='true'] .qb-node__caret {
  transform: rotate(90deg);
}

.qb-node__caret.is-dot {
  background: #eef2f8;
}

.qb-node__caret.is-dot::after {
  left: 7px;
  top: 7px;
  width: 4px;
  height: 4px;
  border: 0;
  border-radius: 50%;
  background: #b9c4d6;
}

.qb-node__count {
  flex-shrink: 0;
  font-size: 12.5px;
  color: var(--ink-4);
  font-variant-numeric: tabular-nums;
}

.qb-node__count.is-zero {
  color: #b9c4d6;
}

.qb-node__app {
  flex-shrink: 0;
  padding: 5px 12px;
  border: 1px solid rgba(31, 94, 255, 0.28);
  border-radius: 999px;
  background: rgba(31, 94, 255, 0.06);
  color: var(--brand);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.qb-node__app:hover {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}

/* 空态 */
.qb-empty {
  padding: 6px 0 30px;
}

.qb-empty__inner {
  padding: 46px 20px;
  text-align: center;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.qb-empty__icon {
  font-size: 34px;
  margin-bottom: 10px;
}

.qb-empty__inner p {
  margin-bottom: 16px;
  font-size: 14px;
  color: var(--ink-3);
}

@media (max-width: 1100px) {
  .qb-feats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .qb-exam,
  .qb-exam__btn {
    width: 100%;
  }

  .qb-exam__btn {
    justify-content: flex-start;
  }

  .qb-exam__name {
    margin-right: auto;
  }

  .qb-exam__panel {
    width: 100%;
    min-width: 0;
  }

  .qb-subjects {
    margin: 14px 0 16px;
  }

  .qb-feat {
    min-height: 116px;
    padding: 14px;
    gap: 4px;
  }

  .qb-feat__name {
    font-size: 15px;
  }

  .qb-feat__desc {
    display: none;
  }

  .qb-card__head {
    padding: 14px 16px 12px;
  }

  .qb-card__hint {
    display: none;
  }

  .qb-tree {
    padding: 2px 0 10px;
  }

  .qb-node__row {
    gap: 6px;
    padding: 12px 14px;
  }

  .qb-node__toggle {
    font-size: 13.5px;
  }

  .qb-node__app {
    padding: 4px 9px;
    font-size: 11px;
  }

  .qb-node--l2 > .qb-node__row {
    padding-left: 30px;
  }

  .qb-node--l3 > .qb-node__row {
    padding-left: 46px;
  }
}

/* ---------------------- 老师信息卡 / 精简页头 ---------------------- */

/* 题库、课程列表：页头仅保留面包屑，标题视觉隐藏（保留语义供搜索与读屏） */
.page-hd--slim {
  padding: 24px 0 20px;
}

.page-hd--slim .page-hd__crumb {
  margin-bottom: 0;
}

/* 老师信息卡：头像 + 名称（头衔）+ 简介 */
.teacher-card__head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}

.teacher-card__avatar {
  flex: 0 0 auto;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--brand-soft);
  border: 1px solid var(--line);
}

.teacher-card__avatar--empty {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 700;
  color: var(--brand);
}

.teacher-card__meta {
  min-width: 0;
}

.teacher-card__name {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--ink);
}

.teacher-card__title {
  margin-top: 2px;
  font-size: 12.5px;
  color: var(--ink-4);
}

.teacher-card__intro {
  margin-top: 12px;
  font-size: 13.5px;
  line-height: 1.85;
  color: var(--ink-3);
  word-break: break-word;
}

/* 学习页：老师信息位于右侧目录下方 */
.learn-teacher {
  padding: 16px;
  border-top: 1px solid var(--line);
}

.learn-teacher__hd {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
}

.learn-teacher .teacher-card__head {
  margin-top: 12px;
}

@media (max-width: 1100px) {
  /* 移动端没有面包屑可显示，整段页头省略 */
  .page-hd--slim {
    display: none;
  }

  .learn-teacher {
    padding: 14px 16px 18px;
  }
}

/* ------------------ 列表页容器 / 移动端顶部留白 ------------------ */

.course-list {
  padding-bottom: 30px;
}

@media (max-width: 1100px) {
  /* 页头在移动端整体省略，列表与题库首屏补上边距 */
  .qb,
  .course-list {
    padding-top: 14px;
  }

  /* 课程详情：下方目录 / 详情面板白色铺满左右，内容保留 16px 设计边距 */
  .course-detail {
    padding-left: 0;
    padding-right: 0;
  }
}

/* ------------------ 个人中心：移动端信息区布局 ------------------ */

@media (max-width: 1100px) {
  /* 个人信息在左、「退出登录」在右同一行；「浏览更多课程」入口隐藏 */
  .me-hd__row {
    flex-wrap: nowrap;
    gap: 12px;
  }

  .me-hd__user {
    flex: 1 1 auto;
    min-width: 0;
  }

  .me-hd__user > div {
    min-width: 0;
  }

  .me-hd__user h1 {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .me-hd__meta {
    overflow-wrap: anywhere;
  }

  .me-hd__actions {
    flex: 0 0 auto;
  }

  .me-hd__actions a[href="/courses"] {
    display: none;
  }

  /* 手机 / 平板不展示「加入于 …」，只保留手机号 */
  .me-hd__joined {
    display: none;
  }
}

/* ------------------ 学习页：移动端沉浸式（隐藏站点顶栏） ------------------ */

@media (max-width: 1100px) {
  /* LOGO 与导航整条隐藏，播放器直接贴顶；--hd-h 归零避免 sticky 元素留出空档 */
  body[data-page='learn'] {
    --hd-h: 0px;
  }

  body[data-page='learn'] .hd {
    display: none;
  }
}

/* ------------------ 学习页标题行：左老师 / 右课时 ------------------ */

.learn-top__meta {
  margin-top: 6px;
}

/* 老师头像 + 名称：仅手机 / 平板展示，桌面端右侧已有老师卡片 */
.learn-top__teacher {
  display: none;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.learn-top__avatar {
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--brand-soft);
  border: 1px solid var(--line);
}

.learn-top__avatar--empty {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 600;
  color: var(--brand);
}

.learn-top__tname {
  font-size: 13px;
  color: var(--ink-2);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.learn-top__sub {
  margin: 0;
  flex: 0 0 auto;
  font-size: 13px;
  color: var(--ink-3);
  white-space: nowrap;
}

/* ------------------ 学习页：播放器与标题固定，仅目录滚动 ------------------ */

@media (max-width: 1100px) {
  body[data-page='learn'] {
    height: 100vh;
    height: 100dvh;
    overflow: hidden;
  }

  /* 底部 56px 留给固定标签栏（含 iPhone 安全区） */
  body[data-page='learn'] main {
    height: calc(100vh - 56px - env(safe-area-inset-bottom, 0px));
    height: calc(100dvh - 56px - env(safe-area-inset-bottom, 0px));
    overflow: hidden;
  }

  /* 沉浸式播放页不展示站点页脚，避免占位被裁切 */
  body[data-page='learn'] .ft {
    display: none;
  }

  body[data-page='learn'] .learn-player {
    flex: 0 0 auto;
    margin-top: 0;
  }

  /* 横屏手机：限制播放器高度，保证目录仍有可滚动空间 */
  body[data-page='learn'] .learn-player__video {
    max-height: 46vh;
  }

  body[data-page='learn'] .learn-top {
    flex: 0 0 auto;
    padding-bottom: 12px;
    background: #fff;
    border-bottom: 1px solid var(--line);
  }

  /* 标题行：左侧老师（头像 + 名称），右侧课时 */
  body[data-page='learn'] .learn-top__meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 8px;
  }

  body[data-page='learn'] .learn-top__teacher {
    display: inline-flex;
  }

  /* 手机 / 平板标题行只留课时数，有效期在桌面端展示 */
  body[data-page='learn'] .learn-top__expire {
    display: none;
  }

  /* 手机 / 平板隐藏「当前课时」条，标题下方直接是课程目录；桌面端保留 */
  body[data-page='learn'] .learn-now {
    display: none;
  }

  body[data-page='learn'] .learn-side {
    flex: 1 1 auto;
    min-height: 0;
    margin-top: 0;
    margin-bottom: 0;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
  }

  /* 目录标题栏常驻，仅课时列表滚动 */
  body[data-page='learn'] .learn-side__head {
    position: sticky;
    top: 0;
    z-index: 2;
    background: #fff;
  }
}
