:root {
  --ink: #1d2926;
  --ink-soft: #34443f;
  --muted: #687773;
  --subtle: #8b9894;
  --line: #dce5e1;
  --line-strong: #cbd7d2;
  --surface: #ffffff;
  --surface-soft: #f7faf9;
  --page: #f2f6f4;
  --nav: #18322d;
  --nav-muted: #a9bcb5;
  --coral: #e76f61;
  --coral-dark: #b84e44;
  --coral-soft: #fff0ed;
  --mint: #4eaa8c;
  --mint-dark: #28765f;
  --mint-soft: #e8f6f1;
  --sky: #4f8fc7;
  --sky-dark: #2f6e9f;
  --sky-soft: #eaf3fb;
  --yellow: #e7b84e;
  --yellow-soft: #fff6d9;
  --danger: #b64d56;
  --danger-soft: #fff0f1;
  --shadow-sm: 0 1px 2px rgba(24, 50, 45, 0.06);
  --shadow-md: 0 14px 36px rgba(24, 50, 45, 0.12);
  --radius: 8px;
  font-family: Inter, "Microsoft YaHei", "PingFang SC", "Noto Sans CJK SC", sans-serif;
  color: var(--ink);
  background: var(--page);
}

* {
  box-sizing: border-box;
  letter-spacing: 0;
}

html {
  min-width: 320px;
  background: var(--page);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  color: var(--ink);
  background: var(--page);
  -webkit-font-smoothing: antialiased;
}

body.drawer-open,
body:has(dialog[open]) {
  overflow: hidden;
}

[hidden] {
  display: none !important;
}

button,
input,
textarea {
  font: inherit;
}

button {
  color: inherit;
}

button,
[role="button"] {
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
input:focus-visible,
textarea:focus-visible,
a:focus-visible {
  outline: 3px solid rgba(79, 143, 199, 0.32);
  outline-offset: 2px;
}

img {
  max-width: 100%;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1 {
  margin: 0;
  font-size: 34px;
  line-height: 1.28;
}

h2 {
  margin: 0;
  font-size: 22px;
  line-height: 1.35;
}

h3 {
  margin: 0;
  font-size: 17px;
  line-height: 1.45;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 200;
  padding: 10px 14px;
  color: #ffffff;
  background: var(--nav);
  border-radius: 6px;
  transform: translateY(-150%);
}

.skip-link:focus {
  transform: translateY(0);
}

.app-shell {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  min-height: 100vh;
}

.app-sidebar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  flex-direction: column;
  width: 220px;
  height: 100vh;
  padding: 22px 14px 18px;
  color: #ffffff;
  background: var(--nav);
  border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-brand,
.mobile-brand {
  display: flex;
  align-items: center;
  min-width: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  text-align: left;
}

.sidebar-brand {
  gap: 11px;
  width: 100%;
  padding: 2px 8px 24px;
  color: #ffffff;
}

.brand-mark {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  color: #ffffff;
  background: var(--coral);
  border: 2px solid rgba(255, 255, 255, 0.72);
  border-radius: 50%;
  font-size: 17px;
  font-weight: 900;
}

.brand-copy {
  min-width: 0;
}

.brand-copy strong,
.brand-copy small {
  display: block;
}

.brand-copy strong {
  white-space: nowrap;
  font-size: 16px;
}

.brand-copy small {
  margin-top: 3px;
  color: var(--nav-muted);
  font-size: 11px;
}

.sidebar-nav {
  display: grid;
  gap: 8px;
}

.sidebar-nav-item,
.sidebar-install {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 46px;
  padding: 0 13px;
  color: #c6d4cf;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 7px;
  cursor: pointer;
  font-weight: 700;
  text-align: left;
}

.sidebar-nav-item svg,
.sidebar-install svg {
  flex: 0 0 auto;
  width: 20px;
  height: 20px;
  stroke-width: 2;
}

.sidebar-nav-item:hover,
.sidebar-install:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
}

.sidebar-nav-item.is-active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.08);
}

.sidebar-nav-item.is-active::before {
  content: "";
  position: absolute;
  left: -14px;
  width: 4px;
  height: 24px;
  background: var(--coral);
  border-radius: 0 3px 3px 0;
}

.nav-badge {
  display: grid;
  place-items: center;
  min-width: 19px;
  height: 19px;
  margin-left: auto;
  padding: 0 5px;
  color: #ffffff;
  background: var(--coral);
  border-radius: 10px;
  font-size: 10px;
  line-height: 1;
}

.sidebar-footer {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 8px 10px;
  align-items: center;
  margin-top: auto;
  padding: 16px 8px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-install {
  grid-column: 1 / -1;
  padding: 0 9px;
  min-height: 38px;
}

.profile-dot {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  color: var(--nav);
  background: var(--yellow-soft);
  border-radius: 50%;
  font-size: 13px;
  font-weight: 900;
}

.sidebar-footer small {
  color: var(--nav-muted);
}

.app-frame {
  min-width: 0;
}

.app-header {
  position: sticky;
  top: 0;
  z-index: 35;
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: 70px;
  padding: 0 clamp(22px, 4vw, 52px);
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.mobile-brand {
  display: none;
}

.header-context {
  min-width: 0;
}

.header-context small,
.header-context strong {
  display: block;
}

.header-context small {
  margin-bottom: 2px;
  color: var(--muted);
  font-size: 11px;
}

.header-context strong {
  font-size: 16px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.icon-button {
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  padding: 0;
  color: var(--ink-soft);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 50%;
  cursor: pointer;
}

.icon-button:hover {
  color: var(--nav);
  background: var(--surface-soft);
  border-color: var(--line-strong);
}

.icon-button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.icon-button svg {
  width: 19px;
  height: 19px;
  stroke-width: 2;
}

.header-progress {
  display: flex;
  align-items: center;
  gap: 9px;
  height: 44px;
  padding: 0 11px 0 8px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 7px;
  cursor: pointer;
  text-align: left;
}

.header-progress:hover {
  background: var(--surface-soft);
  border-color: var(--line);
}

.header-progress > span:last-child strong,
.header-progress > span:last-child small {
  display: block;
}

.header-progress > span:last-child strong {
  font-size: 13px;
}

.header-progress > span:last-child small {
  margin-top: 1px;
  color: var(--muted);
  font-size: 10px;
}

.progress-ring {
  --progress: 0deg;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  background: conic-gradient(var(--mint) var(--progress), #e5ece9 0deg);
  border-radius: 50%;
}

.progress-ring i {
  display: grid;
  place-items: center;
  width: 23px;
  height: 23px;
  color: var(--muted);
  background: var(--surface);
  border-radius: 50%;
  font-size: 8px;
  font-style: normal;
  font-weight: 900;
}

.main-content {
  width: min(100%, 1320px);
  min-height: calc(100vh - 70px);
  margin: 0 auto;
  padding: 34px clamp(22px, 4vw, 56px) 76px;
}

.loading-view {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 14px;
  min-height: 55vh;
  color: var(--muted);
}

.loading-mark {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  color: #ffffff;
  background: var(--coral);
  border-radius: 50%;
  font-weight: 900;
  animation: gentle-pulse 1.3s ease-in-out infinite;
}

.view {
  display: none;
}

.view.is-active {
  display: block;
  animation: view-in 0.18s ease-out;
}

.page-intro {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
}

.page-intro > div:first-child {
  min-width: 0;
}

.page-intro h1 {
  max-width: 780px;
}

.eyebrow {
  margin: 0 0 7px;
  color: var(--coral-dark);
  font-size: 12px;
  font-weight: 800;
}

.intro-copy,
.muted {
  color: var(--muted);
  line-height: 1.72;
}

.intro-copy {
  max-width: 720px;
  margin: 10px 0 0;
}

.primary-button,
.secondary-button,
.quiet-button,
.danger-button,
.text-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  border-radius: 7px;
  cursor: pointer;
  font-weight: 800;
}

.primary-button,
.secondary-button,
.quiet-button,
.danger-button {
  padding: 0 16px;
}

.primary-button {
  color: #ffffff;
  background: var(--nav);
  border: 1px solid var(--nav);
}

.primary-button:hover {
  background: #24483f;
  border-color: #24483f;
}

.primary-button:disabled,
.secondary-button:disabled {
  opacity: 0.46;
  cursor: not-allowed;
}

.secondary-button {
  background: var(--surface);
  border: 1px solid var(--line-strong);
}

.secondary-button:hover,
.quiet-button:hover {
  background: var(--surface-soft);
  border-color: #b8c8c2;
}

.quiet-button {
  background: transparent;
  border: 1px solid transparent;
}

.danger-button {
  color: var(--danger);
  background: var(--surface);
  border: 1px solid #e8c0c4;
}

.danger-button:hover {
  background: var(--danger-soft);
}

.text-button {
  min-height: 34px;
  padding: 0 4px;
  color: var(--sky-dark);
  background: transparent;
  border: 0;
}

.text-button:hover {
  color: #20557d;
}

.primary-button svg,
.secondary-button svg,
.quiet-button svg,
.text-button svg {
  width: 17px;
  height: 17px;
}

.section-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--coral-dark);
  font-size: 12px;
  font-weight: 900;
}

.section-label svg {
  width: 15px;
  height: 15px;
  fill: currentColor;
}

.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
}

.compact-heading {
  align-items: center;
}

.page-section,
.settings-section {
  margin-top: 40px;
}

.count-pill,
.status-pill,
.page-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 25px;
  padding: 0 9px;
  border-radius: 14px;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.count-pill {
  color: var(--mint-dark);
  background: var(--mint-soft);
}

.today-intro {
  align-items: center;
}

.daily-pulse {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 174px;
  padding: 10px 13px;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.daily-pulse svg {
  width: 21px;
  height: 21px;
  color: var(--yellow);
}

.daily-pulse strong,
.daily-pulse small {
  display: block;
}

.daily-pulse strong {
  color: var(--ink);
  font-size: 13px;
}

.daily-pulse small {
  margin-top: 2px;
  font-size: 11px;
}

.today-focus-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(270px, 0.72fr);
  gap: 18px;
}

.continue-card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 190px;
  min-height: 280px;
  overflow: hidden;
  background: var(--coral-soft);
  border: 1px solid #f1d5d0;
  border-radius: var(--radius);
}

.continue-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 5px;
  background: var(--coral);
}

.continue-copy {
  align-self: center;
  min-width: 0;
  padding: 36px 16px 36px 38px;
}

.continue-copy h2 {
  max-width: 640px;
  margin-top: 13px;
  font-size: 27px;
  line-height: 1.35;
}

.continue-copy .muted {
  margin: 10px 0 0;
}

.continue-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
}

.continue-guide {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-width: 0;
  padding: 20px 24px 0 0;
  text-align: center;
}

.continue-guide img {
  width: 148px;
  height: 172px;
  margin: auto auto 0;
  object-fit: cover;
  object-position: top center;
  background: var(--surface);
  border: 5px solid rgba(255, 255, 255, 0.84);
  border-bottom: 0;
  border-radius: 8px 8px 0 0;
  box-shadow: 0 8px 24px rgba(123, 65, 58, 0.13);
}

.continue-guide div {
  position: absolute;
  top: 20px;
  right: 20px;
  max-width: 175px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid #f0d9d5;
  border-radius: 7px;
  text-align: left;
  box-shadow: var(--shadow-sm);
}

.continue-guide strong,
.continue-guide span {
  display: block;
}

.continue-guide strong {
  font-size: 12px;
}

.continue-guide span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.45;
}

.today-plan {
  min-width: 0;
  padding: 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.plan-list {
  display: grid;
}

.plan-item {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  gap: 11px;
  align-items: center;
  min-width: 0;
  padding: 14px 0;
  background: transparent;
  border: 0;
  border-top: 1px solid var(--line);
  cursor: pointer;
  text-align: left;
}

.plan-item:first-child {
  border-top: 0;
}

.plan-item:hover strong {
  color: var(--sky-dark);
}

.plan-item > span:first-child {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  color: var(--mint-dark);
  background: var(--mint-soft);
  border-radius: 50%;
}

.plan-item > span:first-child svg {
  width: 16px;
  height: 16px;
}

.plan-item strong,
.plan-item small {
  display: block;
  min-width: 0;
}

.plan-item strong {
  display: -webkit-box;
  overflow: hidden;
  font-size: 13px;
  line-height: 1.45;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.plan-item small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.plan-item > svg {
  width: 16px;
  height: 16px;
  color: var(--subtle);
}

/* 真题考频优先级徽标（A 高频 / B 中频 / C 常规） */
.tier-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
  color: #5c6f6b;
  background: #e9efee;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.tier-pill.tier-A { color: #b3402d; background: #fde8e4; }
.tier-pill.tier-B { color: #96661a; background: #fdf3dd; }

/* 徽标占的是原本给“圆形图标位”的位置，这里重置圆底与尺寸 */
.plan-item > .tier-pill {
  width: 26px;
  height: 26px;
  border-radius: 8px;
}

.episode-card > .tier-pill {
  width: 22px;
  height: 22px;
  border-radius: 7px;
  font-size: 11px;
}


/* ============================================================
   刷题 / 题眼快测 / 错题本
   ============================================================ */

.practice-intro-actions { display: flex; gap: 10px; flex-wrap: wrap; }

.practice-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 22px;
  align-items: center;
  margin-top: 18px;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.filter-group { display: flex; flex-wrap: wrap; gap: 6px; }

.filter-group button {
  padding: 6px 12px;
  color: var(--muted);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 12px;
  cursor: pointer;
}

.filter-group button:hover { border-color: #bbc9c4; color: var(--ink); }
.filter-group button.is-active { color: #fff; background: var(--mint-dark); border-color: var(--mint-dark); }

.toggle-line {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  cursor: pointer;
}

.practice-list { display: grid; gap: 14px; }

.question-card {
  padding: 16px 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.question-card > header {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.q-index {
  display: grid;
  place-items: center;
  min-width: 24px;
  height: 24px;
  padding: 0 7px;
  color: #fff;
  background: var(--ink);
  border-radius: 7px;
  font-size: 12px;
  font-weight: 700;
}

.q-year, .q-subject { color: var(--subtle); font-size: 11px; }
.q-subject { margin-left: auto; }

.q-stem { margin: 0 0 12px; font-size: 14px; line-height: 1.65; }

.q-options { display: grid; gap: 7px; margin-bottom: 12px; }

.q-option {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 9px 12px;
  background: #fbfdfc;
  border: 1px solid var(--line);
  border-radius: 9px;
  font-size: 13px;
  line-height: 1.55;
  text-align: left;
  cursor: pointer;
}

.q-option:hover { border-color: #bbc9c4; }
.q-option b { flex: 0 0 auto; color: var(--mint-dark); }
.q-option.is-picked { border-color: var(--sky-dark); background: #eef5fa; }
.q-option.is-right { border-color: #4eaa8c; background: #e8f6f1; }
.q-option.is-right b { color: #2f7d63; }
.q-option.is-wrong { border-color: #d4624f; background: #fdece8; }
.q-option.is-wrong b { color: #b3402d; }

.q-input {
  width: 100%;
  min-height: 74px;
  margin-bottom: 12px;
  padding: 10px 12px;
  font-family: inherit;
  font-size: 13px;
  line-height: 1.6;
  color: var(--ink);
  background: #fbfdfc;
  border: 1px solid var(--line);
  border-radius: 9px;
  resize: vertical;
}

input.q-input { min-height: 0; }

.q-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

.q-answer {
  margin-top: 12px;
  padding: 12px 14px;
  background: #f4f8f6;
  border-left: 3px solid var(--mint-dark);
  border-radius: 0 9px 9px 0;
  font-size: 13px;
  line-height: 1.7;
}

.q-answer p { margin: 0 0 6px; }
.q-answer p:last-child { margin-bottom: 0; }
.q-source { color: var(--subtle); font-size: 11px; }

/* 题眼快测 */
.drill-card, .drill-result {
  padding: 26px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  text-align: center;
}

.drill-stem {
  margin: 14px 0;
  font-size: 22px;
  line-height: 1.5;
  color: var(--mint-dark);
}

.drill-answer {
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px dashed var(--line);
}

.drill-answer .q-actions { justify-content: center; margin-top: 14px; }
.drill-result .q-actions { justify-content: center; margin-top: 18px; }
.drill-misses { margin: 16px 0; text-align: left; }
.drill-misses ul { margin: 8px 0 0; padding-left: 20px; color: var(--muted); font-size: 13px; line-height: 1.8; }

@media (max-width: 920px) {
  .practice-filters { gap: 10px; padding: 12px; }
  .q-subject { margin-left: 0; }
  .drill-stem { font-size: 18px; }
}










/* ============================================================
   机械记忆特训：年份人物 / 咬文嚼字 / 核字防错
   ============================================================ */

.drill-launcher {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.drill-card-btn {
  position: relative;
  display: grid;
  gap: 5px;
  padding: 18px 18px 16px;
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}
.drill-card-btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.drill-card-btn strong { font-size: 15px; }
.drill-card-btn small { color: var(--muted); font-size: 12px; line-height: 1.5; }

.drill-card-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  margin-bottom: 4px;
  border-radius: 10px;
}
.drill-card-icon svg { width: 20px; height: 20px; }
.tone-year .drill-card-icon { color: #9a6b1f; background: #fdf3dd; }
.tone-confuse .drill-card-icon { color: #b3402d; background: #fdece8; }
.tone-typo .drill-card-icon { color: #4f6f9a; background: #eaf1fa; }

.drill-card-count {
  position: absolute;
  top: 16px;
  right: 16px;
  color: var(--subtle);
  font-size: 11px;
}

.drill-card-stat { display: grid; place-items: center; color: var(--subtle); font-size: 12px; }

/* 训练面板 */
.drill-body { min-height: 260px; }
.drill-progress { height: 5px; margin-bottom: 18px; background: #e9efee; border-radius: 3px; overflow: hidden; }
.drill-progress i { display: block; height: 100%; background: var(--mint-dark); transition: width 0.3s; }

.drill-card-big {
  padding: 28px 26px;
  text-align: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.drill-years { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; margin: 10px 0; }
.year-chip {
  padding: 8px 18px;
  color: #9a6b1f;
  background: #fdf3dd;
  border-radius: 10px;
  font-size: 30px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
}
.drill-persons { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; margin: 14px 0 20px; }
.person-chip {
  padding: 6px 16px;
  color: #fff;
  background: var(--ink);
  border-radius: 999px;
  font-size: 17px;
  font-weight: 700;
}

.drill-answer-box {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px dashed var(--line);
  text-align: left;
}
.drill-answer-box p { margin: 0 0 9px; font-size: 14px; line-height: 1.75; }
.drill-hook { padding: 10px 13px; background: #e8f6f1; border-radius: 9px; color: #2f7d63; }
.drill-answer-box .q-actions { justify-content: center; margin-top: 16px; }

.drill-list { margin: 0; padding-left: 20px; text-align: left; font-size: 14px; line-height: 1.9; }

.typo-wrong {
  color: #b3402d;
  text-decoration: line-through;
  text-decoration-thickness: 2px;
  font-size: 32px;
}
.typo-right { color: #2f7d63; font-size: 32px; font-weight: 700; }

.drill-done { padding: 34px; text-align: center; }
.drill-done h3 { margin: 0 0 10px; font-size: 20px; }
.drill-done .q-actions { justify-content: center; margin-top: 20px; }

@media (max-width: 920px) {
  .year-chip { font-size: 24px; padding: 7px 14px; }
  .typo-wrong, .typo-right { font-size: 24px; }
  .drill-card-big { padding: 20px 16px; }
}


/* ============================================================
   多端适配：手机 / 平板 / 电脑
   ============================================================ */

/* 「更多」面板（手机上放不下的入口） */
.mobile-more-sheet {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  align-items: end;
  background: rgba(20, 32, 29, 0.42);
  backdrop-filter: blur(2px);
}

.mobile-more-inner {
  padding: 20px 18px calc(20px + env(safe-area-inset-bottom));
  background: var(--surface);
  border-radius: 18px 18px 0 0;
  animation: sheet-up 0.22s ease-out;
}

@keyframes sheet-up {
  from { transform: translateY(18px); opacity: 0.4; }
  to { transform: translateY(0); opacity: 1; }
}

.mobile-more-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 11px;
  margin: 12px 0 16px;
}

.mobile-more-grid button {
  display: grid;
  gap: 3px;
  justify-items: start;
  padding: 15px 14px;
  text-align: left;
  background: var(--surface-soft);
  border: 1px solid var(--line);
  border-radius: 13px;
  cursor: pointer;
}
.mobile-more-grid button svg { width: 21px; height: 21px; color: var(--mint-dark); }
.mobile-more-grid button span { font-size: 14px; font-weight: 700; }
.mobile-more-grid button small { color: var(--subtle); font-size: 11px; }

/* 平板（600–1100px）：用双列，而不是照搬手机单列 */
@media (min-width: 600px) and (max-width: 1100px) {
  .episode-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .plan-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hook-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .phase-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .metric-strip { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .practice-list { grid-template-columns: 1fr; }
  .question-card { padding: 18px 20px; }
  .exam-paper-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  /* 平板上底部导航只需 5 项，且可以更高一点 */
  .mobile-nav { min-height: calc(72px + env(safe-area-inset-bottom)); }
  .mobile-nav button { font-size: 11px; }
}

/* 手机：保证可读性与触控目标 */
@media (max-width: 599px) {
  /* 正文最小 13px，辅助文字最小 11px */
  .episode-card-copy small,
  .plan-item small,
  .hook-meta,
  .q-source { font-size: 11.5px; }

  /* 触控目标至少 44px */
  .icon-button,
  .quiet-button,
  .secondary-button,
  .filter-group button,
  .world-switch button,
  .self-rating-options button { min-height: 44px; }

  .self-rating-options button { min-width: 44px; }

  /* 主内容留出底部导航空间 */
  .main-content { padding-bottom: calc(92px + env(safe-area-inset-bottom)); }

  /* 标题不要在手机上过大 */
  .page-intro h1 { font-size: 26px; line-height: 1.28; }
  .page-intro .intro-copy { font-size: 13.5px; }
}

/* 电脑：侧栏 + 三栏内容，底部导航隐藏 */
@media (min-width: 1101px) {
  .mobile-nav, .mobile-more-sheet { display: none !important; }
}

/* ============================================================
   真题模拟考
   ============================================================ */

.exam-launcher { margin-top: 26px; }
.exam-paper-list { display: grid; gap: 10px; margin-top: 14px; }

.exam-paper-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  gap: 12px;
  align-items: center;
  width: 100%;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  text-align: left;
  cursor: pointer;
}
.exam-paper-card:hover { border-color: #bbc9c4; box-shadow: var(--shadow-sm); }

.exam-kind {
  padding: 3px 9px;
  color: #45566b;
  background: #eceff4;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.exam-kind.is-real { color: #b3402d; background: #fdece8; }

.exam-paper-copy { display: grid; gap: 3px; min-width: 0; }
.exam-paper-copy strong { font-size: 14px; }
.exam-paper-copy small { color: var(--subtle); font-size: 11px; }
.exam-score { color: var(--mint-dark); font-size: 14px; font-weight: 700; }

/* 考试进行中 */
.exam-runner {
  margin-top: 22px;
  padding: 20px 22px;
  background: var(--surface);
  border: 1px solid var(--mint-dark);
  border-radius: var(--radius);
  box-shadow: 0 0 0 3px rgba(78, 170, 140, 0.1);
}

.exam-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.exam-head h2 { margin: 4px 0 3px; font-size: 19px; }
.exam-head small { color: var(--muted); font-size: 12px; }

.exam-clock-wrap { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }

.exam-clock {
  padding: 8px 15px;
  color: #fff;
  background: var(--ink);
  border-radius: 9px;
  font-size: 19px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.exam-clock.is-urgent { background: #b3402d; }

.exam-progress { height: 5px; margin: 16px 0 20px; background: #e9efee; border-radius: 3px; overflow: hidden; }
.exam-progress i { display: block; height: 100%; background: var(--mint-dark); transition: width 0.3s; }

.exam-items { display: grid; gap: 16px; margin: 0; padding: 0; list-style: none; counter-reset: exam; }

.exam-item { padding: 15px 17px; background: #fbfdfc; border: 1px solid var(--line); border-radius: 10px; }
.exam-item > header { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }

.exam-rubric { margin-top: 10px; font-size: 12px; }
.exam-rubric summary { color: var(--mint-dark); cursor: pointer; }
.exam-rubric ul { margin: 8px 0 4px; padding-left: 20px; color: var(--muted); line-height: 1.8; }
.exam-rubric b { color: var(--ink); }
.exam-rubric small { color: var(--subtle); }

.exam-foot { margin-top: 20px; text-align: center; }

/* 结果 */
.exam-result .exam-head { margin-bottom: 18px; }

.exam-score-big {
  display: grid;
  place-items: center;
  gap: 5px;
  padding: 26px;
  margin-bottom: 20px;
  background: #f4f8f6;
  border-radius: var(--radius);
}
.exam-score-big strong { font-size: 46px; color: var(--mint-dark); line-height: 1; }
.exam-score-big span { color: var(--muted); font-size: 12px; }

.exam-selfcheck, .exam-review { margin-top: 24px; padding-top: 18px; border-top: 1px dashed var(--line); }
.selfcheck-row { padding: 14px 0; border-top: 1px solid var(--line); }
.selfcheck-row:first-of-type { border-top: 0; }
.selfcheck-row .q-stem { margin: 0 0 8px; }

.exam-answer { margin-top: 10px; font-size: 13px; }
.exam-answer summary { color: var(--mint-dark); cursor: pointer; }
.exam-answer p { margin: 8px 0 0; line-height: 1.75; }

.exam-review-row {
  display: flex;
  gap: 11px;
  align-items: flex-start;
  padding: 11px 0;
  border-top: 1px solid var(--line);
}
.exam-review-row:first-of-type { border-top: 0; }
.exam-review-copy { display: grid; gap: 3px; min-width: 0; }
.exam-review-copy strong { font-size: 13px; line-height: 1.5; }
.exam-review-copy small { color: var(--muted); font-size: 11px; }
.exam-review-row.is-bad .exam-review-copy strong { color: #b3402d; }

@media (max-width: 920px) {
  .exam-paper-card { grid-template-columns: auto minmax(0, 1fr) auto; }
  .exam-score { grid-column: 2; }
  .exam-clock { font-size: 17px; padding: 7px 12px; }
}

/* ============================================================
   剧情卡：双世界故事 + 高频精修 + 白月光追问
   ============================================================ */

.view-toggle { display: flex; gap: 6px; flex-wrap: wrap; }
.view-toggle button {
  padding: 8px 14px;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 9px;
  font-size: 12px;
  cursor: pointer;
}
.view-toggle button:hover { border-color: #bbc9c4; color: var(--ink); }
.view-toggle button.is-active { color: #fff; background: var(--mint-dark); border-color: var(--mint-dark); }

.card-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  align-items: center;
  margin: 18px 0;
  padding: 13px 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.card-filters input[type="search"] {
  flex: 1 1 200px;
  padding: 8px 12px;
  font-family: inherit;
  font-size: 13px;
  border: 1px solid var(--line);
  border-radius: 9px;
}

.cards-body { display: grid; gap: 12px; }

.point-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.point-card.is-open { border-color: #bbc9c4; box-shadow: var(--shadow-sm); }

.point-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  gap: 11px;
  align-items: center;
  width: 100%;
  padding: 14px 16px;
  background: transparent;
  border: 0;
  text-align: left;
  cursor: pointer;
}
.point-head:hover strong { color: var(--sky-dark); }
.point-subject {
  padding: 3px 9px;
  color: #2f7d63;
  background: #e8f6f1;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.point-head strong { font-size: 14px; line-height: 1.5; }
.point-meta { color: var(--subtle); font-size: 11px; white-space: nowrap; }

.point-body { padding: 0 16px 18px; border-top: 1px solid var(--line); }

.point-position, .point-risk {
  display: flex;
  gap: 9px;
  margin: 12px 0 0;
  font-size: 12px;
  line-height: 1.65;
  color: var(--muted);
}
.point-position span, .point-risk span, .block-label {
  flex: 0 0 auto;
  padding: 1px 8px;
  height: fit-content;
  background: #eef3f1;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  color: var(--mint-dark);
}
.point-risk span { background: #fdece8; color: #b3402d; }

/* 双世界切换：3 秒内换一个世界 */
.world-switch { display: flex; gap: 7px; flex-wrap: wrap; margin: 16px 0 12px; }
.world-switch button {
  padding: 7px 13px;
  font-size: 12px;
  color: var(--muted);
  background: #fbfdfc;
  border: 1px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
}
.world-switch button:hover { border-color: #bbc9c4; }
.world-switch button.is-active { color: #fff; background: var(--ink); border-color: var(--ink); }

.world-story { padding: 14px 0 4px; }
.world-story .story-acts li { border-top: 1px dashed var(--line); }
.world-story .act-label { background: var(--ink); }
.world-secondary .act-label { background: #7f9aa8; }

.point-locks { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 13px; }
.point-locks.verify { margin-top: 8px; }
.lock-word.warn { color: #b3402d; background: #fdece8; }

.point-quiz { margin-top: 15px; }
.point-quiz ol { margin: 8px 0 0; padding-left: 22px; font-size: 13px; line-height: 1.85; }
.point-source { margin: 13px 0 0; color: var(--subtle); font-size: 11px; }

/* 高频精修卡 */
.hf-card, .inquiry-card {
  padding: 16px 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.hf-card > header, .inquiry-card > header {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.hf-card > header strong, .inquiry-card > header strong { font-size: 15px; }

.hf-block { display: flex; gap: 9px; margin: 0 0 10px; font-size: 13px; line-height: 1.75; }
.hf-block > span {
  flex: 0 0 auto;
  height: fit-content;
  padding: 2px 9px;
  background: #eef3f1;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  color: var(--mint-dark);
  white-space: nowrap;
}
.world-three > span { background: #eceff4; color: #45566b; }
.world-sanrio > span { background: #fdf1e6; color: #a6602a; }

.hf-inquiry { margin: 0; padding-left: 18px; }
.hf-inquiry li { margin-bottom: 3px; }

.recite-cue {
  display: flex;
  gap: 9px;
  margin: 13px 0 0;
  padding: 11px 13px;
  background: #e8f6f1;
  border-radius: 9px;
  font-size: 14px;
  font-weight: 600;
  color: #2f7d63;
  line-height: 1.65;
}
.recite-cue > span {
  flex: 0 0 auto;
  height: fit-content;
  padding: 2px 8px;
  background: #fff;
  border-radius: 6px;
  font-size: 11px;
}

/* 白月光追问 */
.inquiry-six { margin: 0; }
.inquiry-six > div {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 12px;
  padding: 9px 0;
  border-top: 1px solid var(--line);
}
.inquiry-six > div:first-child { border-top: 0; }
.inquiry-six dt { font-size: 12px; font-weight: 700; color: var(--mint-dark); }
.inquiry-six dd { margin: 0; font-size: 13px; line-height: 1.7; color: var(--muted); }

@media (max-width: 920px) {
  .point-head { grid-template-columns: auto minmax(0, 1fr) auto; }
  .point-meta { grid-column: 2; white-space: normal; }
  .inquiry-six > div { grid-template-columns: 1fr; gap: 3px; }
}

/* 反馈与调整 */
.feedback-panel { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; }

.feedback-card {
  display: flex;
  gap: 11px;
  align-items: flex-start;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 3px solid var(--line);
  border-radius: var(--radius);
}

.feedback-card.tone-warn { border-left-color: #d4624f; }
.feedback-card.tone-due { border-left-color: #d99a2b; }
.feedback-card.tone-ok { border-left-color: #4eaa8c; }
.feedback-card.tone-info { border-left-color: #4f8fc7; }

.feedback-icon { flex: 0 0 auto; color: var(--muted); }
.feedback-icon svg { width: 17px; height: 17px; }
.feedback-card strong { display: block; font-size: 13px; line-height: 1.5; }
.feedback-card small { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; line-height: 1.6; }

/* ============================================================
   记忆钩子 / 故事闭环 / 背诵页
   ============================================================ */

.hook-list { display: grid; gap: 12px; }

.hook-card {
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 3px solid var(--mint-dark);
  border-radius: var(--radius);
}

.hook-kind {
  display: inline-block;
  margin-bottom: 7px;
  padding: 2px 9px;
  color: #2f7d63;
  background: #e8f6f1;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
}

.hook-card > strong { display: block; font-size: 13px; line-height: 1.55; }

.hook-text {
  margin: 7px 0 0;
  padding: 8px 11px;
  background: #fbfdfc;
  border-radius: 8px;
  font-size: 13px;
  line-height: 1.7;
  color: var(--mint-dark);
}

.hook-meta { display: block; margin-top: 7px; color: var(--subtle); font-size: 11px; }
.hook-summary { margin-bottom: 22px; }

.memory-hook-inline {
  margin: 6px 0;
  padding: 7px 10px;
  background: #f4f8f6;
  border-radius: 7px;
  font-size: 12px;
  line-height: 1.65;
  color: var(--mint-dark);
}
.memory-hook-inline .hook-kind { margin: 0 6px 0 0; padding: 1px 7px; vertical-align: middle; }

/* 七幕故事闭环 */
.story-flow { margin: 22px 0; padding-top: 18px; border-top: 1px dashed var(--line); }
.story-premise { margin: 10px 0 14px; color: var(--muted); font-size: 13px; line-height: 1.75; }
.story-acts { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }

.story-acts li {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 14px;
  padding: 12px 0;
  border-top: 1px solid var(--line);
}
.story-acts li:first-child { border-top: 0; }

.act-label {
  display: grid;
  place-items: center;
  align-self: start;
  height: 26px;
  color: #fff;
  background: var(--ink);
  border-radius: 7px;
  font-size: 12px;
  font-weight: 700;
}

.act-body p { margin: 0; font-size: 13px; line-height: 1.75; }
.act-link { display: block; margin-top: 5px; color: var(--mint-dark); font-size: 11px; }

/* 背诵页：八种记忆法 */
.hook-kind-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; }

.hook-kind-card {
  display: grid;
  gap: 4px;
  padding: 15px 16px;
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  cursor: pointer;
}
.hook-kind-card:hover { border-color: #bbc9c4; }
.hook-kind-card.is-active { border-color: var(--mint-dark); box-shadow: 0 0 0 2px rgba(78, 170, 140, 0.16); }
.hook-kind-card strong { font-size: 15px; }
.hook-kind-card span { color: var(--subtle); font-size: 11px; }

/* 背诵阶段 D0-D30 */
.recite-schedule { display: grid; }

.recite-stage {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) auto;
  gap: 13px;
  align-items: center;
  padding: 12px 0;
  border-top: 1px solid var(--line);
}
.recite-stage:first-child { border-top: 0; }
.recite-stage.is-done { opacity: 0.62; }

.recite-badge {
  display: grid;
  place-items: center;
  height: 28px;
  color: var(--mint-dark);
  background: var(--mint-soft);
  border-radius: 7px;
  font-size: 12px;
  font-weight: 700;
}
.recite-stage strong { display: block; font-size: 13px; }
.recite-stage small { display: block; margin-top: 3px; color: var(--subtle); font-size: 11px; }

.hook-reveal {
  margin: 0 0 8px;
  padding: 12px 14px;
  background: #e8f6f1;
  border-radius: 9px;
  font-size: 15px;
  line-height: 1.75;
  color: #2f7d63;
  font-weight: 600;
}

@media (max-width: 920px) {
  .story-acts li { grid-template-columns: 62px minmax(0, 1fr); gap: 10px; }
  .recite-stage { grid-template-columns: 48px minmax(0, 1fr); }
  .recite-stage .quiet-button { grid-column: 2; justify-self: start; }
}

/* 主观题自评（0-5 分法） */
.self-rating { margin: 0 0 12px; }
.self-rating > small { display: block; margin-bottom: 7px; color: var(--subtle); font-size: 11px; }
.self-rating-options { display: flex; gap: 6px; flex-wrap: wrap; }

.self-rating-options button {
  width: 34px;
  height: 34px;
  color: var(--muted);
  background: #fbfdfc;
  border: 1px solid var(--line);
  border-radius: 9px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.self-rating-options button:hover { border-color: #bbc9c4; color: var(--ink); }
.self-rating-options button.is-picked { color: #fff; background: var(--mint-dark); border-color: var(--mint-dark); }
.self-rating-hint { margin: 8px 0 0; font-size: 12px; }

.lock-word {
  display: inline-block;
  margin: 2px 4px 2px 0;
  padding: 2px 8px;
  background: #e8f6f1;
  border-radius: 6px;
  font-size: 12px;
  color: #2f7d63;
}

/* 搜索结果分组（课程 / 题库 / 原文答案库） */
.search-group { margin-bottom: 18px; }
.search-group .eyebrow { margin: 0 0 8px; }

.search-row {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  width: 100%;
  padding: 10px 0;
  background: transparent;
  border: 0;
  border-top: 1px solid var(--line);
  text-align: left;
  cursor: pointer;
}
.search-row:first-of-type { border-top: 0; }
.search-row-copy { display: grid; gap: 3px; min-width: 0; }
.search-row-copy strong { font-size: 13px; line-height: 1.5; }
.search-row-copy small { color: var(--subtle); font-size: 11px; }

.question-card.is-highlight { box-shadow: 0 0 0 3px rgba(78, 170, 140, 0.28); }

/* 错题本 */
.wrong-book-hint { margin: -6px 0 14px; font-size: 12px; }
.wrong-book-list { display: grid; gap: 12px; }

.wrong-card {
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 3px solid #d4624f;
  border-radius: var(--radius);
}
.wrong-card > header { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.wrong-count { margin-left: auto; color: #b3402d; font-size: 11px; font-weight: 700; }

.wrong-form { display: grid; gap: 9px; margin: 10px 0; }
.wrong-form label { display: grid; gap: 4px; font-size: 11px; color: var(--subtle); }
.wrong-form select, .wrong-form input {
  padding: 7px 10px;
  font-family: inherit;
  font-size: 12px;
  color: var(--ink);
  background: #fbfdfc;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.wrong-form input:focus, .wrong-form select:focus { border-color: var(--mint-dark); outline: none; }

/* ============================================================
   30 天计划 / 白月光调查
   ============================================================ */

.plan-day-picker {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: 12px;
  color: var(--muted);
}

.plan-day-picker input {
  width: 62px;
  padding: 5px 8px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
  text-align: center;
  border: 1px solid var(--line);
  border-radius: 7px;
}

.plan-today-card {
  margin-top: 18px;
  padding: 20px 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--mint-dark);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.plan-today-head { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.plan-today-head h2 { margin: 0; font-size: 18px; }

.plan-today-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 16px;
}

.plan-today-grid div { display: grid; gap: 4px; }
.plan-today-grid small { color: var(--subtle); font-size: 11px; }
.plan-today-grid strong { font-size: 13px; line-height: 1.55; }

.plan-modules { display: flex; flex-wrap: wrap; gap: 8px; }
.plan-modules span {
  padding: 5px 10px;
  background: #f4f8f6;
  border-radius: 999px;
  font-size: 11px;
  color: var(--muted);
}
.plan-modules b { margin-right: 5px; color: var(--mint-dark); }

.phase-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px; }

.phase-card {
  padding: 16px 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.phase-card.is-current { border-color: var(--mint-dark); box-shadow: 0 0 0 2px rgba(78, 170, 140, 0.16); }
.phase-card header { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.phase-no { padding: 3px 8px; color: #fff; background: var(--ink); border-radius: 6px; font-size: 11px; }
.phase-card header small { margin-left: auto; color: var(--subtle); font-size: 11px; }
.phase-card p { margin: 0 0 8px; font-size: 12px; color: var(--muted); line-height: 1.6; }
.phase-card ul { margin: 0; padding-left: 18px; font-size: 12px; color: var(--muted); line-height: 1.85; }

.plan-days { display: grid; }

.plan-day-row {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 11px 0;
  border-top: 1px solid var(--line);
}
.plan-day-row:first-child { border-top: 0; }
.plan-day-row.is-current { background: #f4f8f6; border-radius: 8px; padding-left: 10px; padding-right: 10px; }

.plan-day-no {
  display: grid;
  place-items: center;
  height: 26px;
  color: var(--mint-dark);
  background: var(--mint-soft);
  border-radius: 7px;
  font-size: 12px;
  font-weight: 700;
}

.plan-day-body strong { display: block; font-size: 13px; }
.plan-day-body small { display: block; margin-top: 3px; color: var(--subtle); font-size: 11px; line-height: 1.5; }

/* 白月光调查 */
.investigation-list { display: grid; gap: 14px; margin: 16px 0; }

.investigation-item { display: grid; gap: 5px; }
.inv-label { font-size: 13px; font-weight: 700; color: var(--mint-dark); }
.investigation-item small { color: var(--subtle); font-size: 11px; }
.investigation-item textarea {
  min-height: 54px;
  padding: 9px 12px;
  font-family: inherit;
  font-size: 13px;
  line-height: 1.6;
  color: var(--ink);
  background: #fbfdfc;
  border: 1px solid var(--line);
  border-radius: 9px;
  resize: vertical;
}
.investigation-item textarea:focus { border-color: var(--mint-dark); outline: none; }

@media (max-width: 920px) {
  .plan-today-grid { grid-template-columns: 1fr; }
  .plan-day-picker { width: 100%; justify-content: center; }
}

.metric-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.metric-strip > div {
  display: flex;
  align-items: baseline;
  gap: 5px;
  min-width: 0;
  padding: 18px 21px;
  border-left: 1px solid var(--line);
}

.metric-strip > div:first-child {
  border-left: 0;
}

.metric-strip span {
  margin-right: auto;
  color: var(--muted);
  font-size: 12px;
}

.metric-strip strong {
  font-size: 23px;
}

.metric-strip small {
  color: var(--muted);
  font-size: 11px;
}

.book-progress-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.book-card {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) auto;
  gap: 15px;
  align-items: center;
  min-width: 0;
  padding: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  text-align: left;
}

.book-card:hover {
  border-color: var(--line-strong);
  box-shadow: 0 7px 20px rgba(24, 50, 45, 0.08);
  transform: translateY(-1px);
}

.book-cover {
  display: grid;
  place-items: center;
  width: 56px;
  height: 70px;
  color: #ffffff;
  border-radius: 5px;
  box-shadow: 5px 5px 0 #e3e9e6;
  font-size: 18px;
  font-weight: 900;
}

.book-cover.management {
  background: var(--coral);
}

.book-cover.tourism {
  background: var(--mint);
}

.book-card-copy {
  min-width: 0;
}

.book-card-copy strong,
.book-card-copy small,
.book-progress-track {
  display: block;
}

.book-card-copy strong {
  font-size: 15px;
}

.book-card-copy small {
  margin: 5px 0 10px;
  color: var(--muted);
  font-size: 11px;
}

.book-progress-track,
.wide-progress {
  overflow: hidden;
  height: 7px;
  background: #e7eeeb;
  border-radius: 4px;
}

.book-progress-track i,
.wide-progress i {
  display: block;
  width: 0;
  height: 100%;
  background: var(--sky);
  border-radius: inherit;
  transition: width 0.25s ease;
}

.book-card > svg {
  width: 19px;
  height: 19px;
  color: var(--subtle);
}

.episode-list {
  display: grid;
  gap: 9px;
}

.episode-card {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr) auto auto 20px;
  gap: 13px;
  align-items: center;
  width: 100%;
  min-width: 0;
  min-height: 78px;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  text-align: left;
}

.episode-card:hover {
  border-color: #bbc9c4;
  box-shadow: 0 7px 18px rgba(24, 50, 45, 0.08);
}

.episode-card:disabled {
  opacity: 0.63;
  cursor: default;
  box-shadow: none;
}

.episode-avatar {
  width: 48px;
  height: 48px;
  object-fit: cover;
  background: var(--surface-soft);
  border: 2px solid var(--yellow-soft);
  border-radius: 8px;
}

.episode-card-copy {
  min-width: 0;
}

.episode-card-copy small,
.episode-card-copy strong {
  display: block;
}

.episode-card-copy small {
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 11px;
}

.episode-card-copy strong {
  display: -webkit-box;
  overflow: hidden;
  font-size: 14px;
  line-height: 1.5;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.episode-card > svg {
  width: 18px;
  height: 18px;
  color: var(--subtle);
}

.status-pill.available {
  color: var(--sky-dark);
  background: var(--sky-soft);
}

.status-pill.video {
  color: var(--coral-dark);
  background: var(--coral-soft);
}

.status-pill.completed {
  color: var(--mint-dark);
  background: var(--mint-soft);
}

.status-pill.due {
  color: #8a641c;
  background: var(--yellow-soft);
}

.status-pill.pending {
  color: var(--muted);
  background: #edf1ef;
}

.empty-state {
  display: grid;
  place-items: center;
  min-height: 132px;
  padding: 26px;
  color: var(--muted);
  background: var(--surface);
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  line-height: 1.7;
  text-align: center;
}

.empty-state svg {
  width: 30px;
  height: 30px;
  margin-bottom: 4px;
  color: var(--mint);
}

.course-toolbar {
  display: grid;
  grid-template-columns: auto minmax(230px, 1fr) auto;
  gap: 12px;
  align-items: center;
  margin-bottom: 22px;
}

.subject-switch,
.filter-switch {
  display: inline-grid;
  padding: 3px;
  background: #e8eeeb;
  border-radius: 7px;
}

.subject-switch {
  grid-template-columns: repeat(2, minmax(112px, 1fr));
}

.filter-switch {
  grid-template-columns: repeat(3, auto);
}

.subject-switch button,
.filter-switch button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 36px;
  padding: 0 12px;
  background: transparent;
  border: 0;
  border-radius: 5px;
  cursor: pointer;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.subject-switch button.is-active,
.filter-switch button.is-active {
  color: var(--ink);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.subject-swatch {
  width: 9px;
  height: 9px;
  border-radius: 50%;
}

.subject-swatch.management {
  background: var(--coral);
}

.subject-swatch.tourism {
  background: var(--mint);
}

.search-field {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  height: 42px;
  padding: 0 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 7px;
}

.search-field:focus-within {
  border-color: var(--sky);
  box-shadow: 0 0 0 3px rgba(79, 143, 199, 0.12);
}

.search-field svg {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  color: var(--subtle);
}

.search-field input {
  width: 100%;
  min-width: 0;
  height: 100%;
  color: var(--ink);
  background: transparent;
  border: 0;
  outline: 0;
}

.search-field input::placeholder,
textarea::placeholder {
  color: #95a19d;
}

.course-browser {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}

.chapter-panel {
  position: sticky;
  top: 96px;
  max-height: calc(100vh - 118px);
  overflow-y: auto;
  padding-right: 18px;
  border-right: 1px solid var(--line);
  scrollbar-width: thin;
}

.chapter-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  padding: 0 6px;
}

.chapter-panel-head small,
.chapter-panel-head strong {
  display: block;
}

.chapter-panel-head small {
  margin-bottom: 2px;
  color: var(--muted);
  font-size: 10px;
}

.chapter-panel-head strong {
  font-size: 15px;
}

.chapter-list {
  display: grid;
  gap: 4px;
}

.chapter-button {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  width: 100%;
  min-width: 0;
  padding: 11px 10px;
  color: var(--muted);
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
  cursor: pointer;
  text-align: left;
}

.chapter-button:hover {
  color: var(--ink);
  background: var(--surface);
}

.chapter-button.is-active {
  color: var(--ink);
  background: var(--surface);
  border-color: var(--line);
  box-shadow: var(--shadow-sm);
}

.chapter-button.is-active::before {
  content: "";
  position: absolute;
  top: 9px;
  bottom: 9px;
  left: -1px;
  width: 3px;
  background: var(--coral);
  border-radius: 0 2px 2px 0;
}

.chapter-button span {
  min-width: 0;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.5;
}

.chapter-button small {
  color: var(--subtle);
  font-size: 10px;
  white-space: nowrap;
}

.course-results {
  min-width: 0;
}

.chapter-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  margin-bottom: 15px;
  padding-bottom: 17px;
  border-bottom: 1px solid var(--line);
}

.chapter-summary p,
.chapter-summary span {
  margin: 0;
  color: var(--muted);
}

.chapter-summary p {
  margin-bottom: 4px;
  font-size: 11px;
  font-weight: 700;
}

.chapter-summary h2 {
  margin-bottom: 6px;
}

.chapter-summary span {
  font-size: 11px;
}

.chapter-summary-progress {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  color: var(--mint-dark);
  background: var(--mint-soft);
  border-radius: 50%;
  font-size: 12px;
  font-weight: 900;
}

.review-overview {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.review-overview > div {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 20px 22px;
  border-left: 1px solid var(--line);
}

.review-overview > div:first-child {
  border-left: 0;
}

.review-overview small,
.review-overview strong {
  display: block;
}

.review-overview small {
  color: var(--muted);
  font-size: 11px;
}

.review-overview strong {
  margin-top: 3px;
  font-size: 25px;
}

.metric-icon,
.setting-icon {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 8px;
}

.metric-icon svg,
.setting-icon svg {
  width: 19px;
  height: 19px;
}

.metric-icon.due {
  color: #8a641c;
  background: var(--yellow-soft);
}

.metric-icon.weak {
  color: var(--coral-dark);
  background: var(--coral-soft);
}

.metric-icon.known {
  color: var(--mint-dark);
  background: var(--mint-soft);
}

.profile-hero {
  display: grid;
  grid-template-columns: 66px minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 24px;
  color: #ffffff;
  background: var(--nav);
  border-radius: var(--radius);
}

.profile-avatar {
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  color: var(--nav);
  background: var(--yellow-soft);
  border: 3px solid rgba(255, 255, 255, 0.65);
  border-radius: 50%;
  font-size: 21px;
  font-weight: 900;
}

.profile-main-copy {
  min-width: 0;
}

.profile-main-copy small,
.profile-main-copy strong {
  display: block;
}

.profile-main-copy small {
  color: #bdd0c9;
  font-size: 11px;
}

.profile-main-copy strong {
  margin: 4px 0 12px;
  font-size: 18px;
}

.profile-main-copy .wide-progress {
  max-width: 560px;
  background: rgba(255, 255, 255, 0.15);
}

.profile-main-copy .wide-progress i {
  background: var(--yellow);
}

.profile-percent {
  font-size: 31px;
  font-weight: 900;
}

.profile-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.profile-stat {
  padding: 18px 20px;
  border-left: 1px solid var(--line);
}

.profile-stat:first-child {
  border-left: 0;
}

.profile-stat strong,
.profile-stat span {
  display: block;
}

.profile-stat strong {
  font-size: 23px;
}

.profile-stat span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
}

.settings-list {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.setting-row {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  gap: 13px;
  align-items: center;
  min-height: 76px;
  padding: 14px 18px;
  border-top: 1px solid var(--line);
}

.setting-row:first-child {
  border-top: 0;
}

.setting-icon {
  color: var(--sky-dark);
  background: var(--sky-soft);
}

.setting-row > span:nth-child(2) {
  min-width: 0;
}

.setting-row strong,
.setting-row small {
  display: block;
}

.setting-row strong {
  font-size: 13px;
}

.setting-row small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
}

.setting-actions {
  display: flex;
  gap: 7px;
}

.danger-row .setting-icon {
  color: var(--danger);
  background: var(--danger-soft);
}

.episode-view {
  max-width: 1120px;
  margin: 0 auto;
}

.episode-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.episode-nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.episode-nav-actions > span {
  min-width: 70px;
  color: var(--muted);
  font-size: 11px;
  text-align: center;
}

.episode-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 150px;
  gap: 24px;
  align-items: center;
  margin-bottom: 20px;
}

.episode-heading-copy {
  min-width: 0;
}

.episode-heading h1 {
  max-width: 850px;
  font-size: 31px;
}

.episode-question {
  max-width: 850px;
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.75;
}

.episode-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 13px;
}

.episode-meta span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 27px;
  padding: 0 9px;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  font-size: 10px;
}

.episode-meta svg {
  width: 13px;
  height: 13px;
}

.episode-guide {
  display: flex;
  align-items: center;
  gap: 9px;
  justify-content: flex-end;
}

.episode-guide img {
  width: 70px;
  height: 70px;
  object-fit: cover;
  background: var(--surface);
  border: 3px solid var(--yellow-soft);
  border-radius: 8px;
}

.episode-guide strong,
.episode-guide span {
  display: block;
}

.episode-guide strong {
  font-size: 12px;
}

.episode-guide span {
  max-width: 72px;
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
  line-height: 1.4;
}

.learning-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 13px;
  margin: 0 0 15px;
  padding: 12px 16px;
  color: var(--subtle);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: 11px;
  font-weight: 700;
}

.learning-steps span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.learning-steps b {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  background: #edf1ef;
  border-radius: 50%;
  font-size: 10px;
}

.learning-steps .is-active {
  color: var(--ink);
}

.learning-steps .is-active b {
  color: #ffffff;
  background: var(--coral);
}

.learning-steps > svg {
  width: 15px;
  height: 15px;
}

.player-shell {
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #1c2523;
  border: 1px solid #273431;
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
}

.player-shell video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #111716;
}

.video-pending {
  display: grid;
  justify-items: center;
  gap: 10px;
  max-width: 480px;
  padding: 28px;
  color: #ffffff;
  text-align: center;
}

.video-pending > span:last-child {
  color: #b7c7c1;
  font-size: 12px;
  line-height: 1.65;
}

.pending-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  color: var(--yellow);
  background: rgba(255, 255, 255, 0.08);
  border-radius: 50%;
}

.pending-icon svg {
  width: 23px;
  height: 23px;
}

.episode-status-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 48px;
  color: var(--muted);
  border-bottom: 1px solid var(--line);
  font-size: 11px;
}

.lesson-tabs {
  position: sticky;
  top: 70px;
  z-index: 20;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 16px;
  background: rgba(242, 246, 244, 0.96);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.lesson-tabs button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-width: 0;
  min-height: 50px;
  padding: 0 10px;
  color: var(--muted);
  background: transparent;
  border: 0;
  border-bottom: 3px solid transparent;
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
}

.lesson-tabs button:hover {
  color: var(--ink);
}

.lesson-tabs button.is-active {
  color: var(--coral-dark);
  border-bottom-color: var(--coral);
}

.lesson-tabs svg {
  width: 17px;
  height: 17px;
}

.lesson-panel {
  display: none;
  min-height: 300px;
  padding: 30px 0 10px;
}

.lesson-panel.is-active {
  display: block;
}

.pending-copy,
.notes-flow,
.recall-lab,
.exam-output {
  max-width: 880px;
  margin: 0 auto;
}

.pending-copy {
  padding: 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.pending-copy p {
  margin: 15px 0 0;
  padding-top: 15px;
  color: var(--muted);
  border-top: 1px solid var(--line);
  line-height: 1.72;
}

.notes-flow > h2 {
  margin-bottom: 22px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
  font-size: 24px;
}

.notes-flow > section {
  padding: 23px 0;
  border-bottom: 1px solid var(--line);
}

.notes-flow > section > h3 {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  color: var(--sky-dark);
  background: var(--sky-soft);
  border-radius: 5px;
  font-size: 12px;
}

.knowledge-line {
  position: relative;
  padding: 18px 0 0 18px;
}

.knowledge-line::before {
  content: "";
  position: absolute;
  top: 24px;
  left: 0;
  width: 7px;
  height: 7px;
  background: var(--mint);
  border-radius: 50%;
}

.knowledge-line strong {
  font-size: 15px;
}

.knowledge-line p {
  margin: 7px 0;
  color: var(--muted);
  line-height: 1.82;
}

.knowledge-line small {
  color: #81631f;
  line-height: 1.6;
}

.source-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.source-grid figure {
  min-width: 0;
  margin: 0;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.source-grid img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: contain;
  background: #e8ecea;
}

.source-grid figcaption {
  padding: 11px 13px;
  color: var(--muted);
  border-top: 1px solid var(--line);
  font-size: 11px;
}

.recall-lab {
  padding: 26px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.recall-lab h2,
.exam-output h2 {
  max-width: 720px;
  font-size: 22px;
}

.recall-lab textarea {
  display: block;
  width: 100%;
  min-height: 180px;
  margin: 18px 0 13px;
  padding: 14px;
  resize: vertical;
  color: var(--ink);
  background: #fbfdfc;
  border: 1px solid var(--line-strong);
  border-radius: 7px;
  line-height: 1.75;
}

.recall-result {
  margin-top: 20px;
  padding: 20px;
  background: var(--mint-soft);
  border-left: 4px solid var(--mint);
  border-radius: 0 7px 7px 0;
}

.recall-result p {
  color: var(--ink-soft);
  line-height: 1.75;
}

.keyword-list,
.lock-words {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 15px 0;
}

.keyword-list span,
.lock-words span {
  display: inline-flex;
  align-items: center;
  min-height: 29px;
  padding: 0 9px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 5px;
  font-size: 11px;
}

.keyword-list span.hit {
  color: var(--mint-dark);
  border-color: var(--mint);
}

.lock-words span {
  color: #78591b;
  background: var(--yellow-soft);
  border-color: #e8d18a;
}

.exam-output ol {
  padding-left: 24px;
  line-height: 1.9;
}

.model-answer {
  margin-top: 22px;
  padding: 21px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 5px solid var(--coral);
  border-radius: 0 7px 7px 0;
}

.model-answer p {
  margin: 10px 0 0;
  line-height: 1.9;
}

.rating-row {
  margin-top: 24px;
  padding: 20px 0 0;
  border-top: 1px solid var(--line);
}

.rating-row > span {
  display: block;
  margin-bottom: 11px;
  font-weight: 800;
}

.rating-options {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.rating-options button {
  min-height: 44px;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: 7px;
  cursor: pointer;
  font-weight: 700;
}

.rating-options button:hover,
.rating-options button.is-selected {
  color: var(--mint-dark);
  background: var(--mint-soft);
  border-color: var(--mint);
}

.search-dialog {
  width: min(700px, calc(100vw - 32px));
  max-height: min(760px, calc(100vh - 48px));
  padding: 0;
  overflow: hidden;
  background: var(--page);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  box-shadow: 0 28px 80px rgba(10, 31, 26, 0.24);
}

.search-dialog::backdrop {
  background: rgba(15, 30, 26, 0.5);
  backdrop-filter: blur(3px);
}

.search-dialog-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 40px;
  gap: 10px;
  padding: 14px;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}

.global-search-field {
  height: 44px;
  background: var(--surface-soft);
}

.search-results {
  display: grid;
  gap: 8px;
  max-height: calc(100vh - 150px);
  padding: 14px;
  overflow-y: auto;
}

.search-hint {
  display: grid;
  place-items: center;
  min-height: 180px;
  padding: 26px;
  color: var(--muted);
  text-align: center;
}

.search-hint svg {
  width: 31px;
  height: 31px;
  margin-bottom: 10px;
  color: var(--mint);
}

.toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 180;
  max-width: min(360px, calc(100vw - 32px));
  padding: 12px 15px;
  color: #ffffff;
  background: var(--nav);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 7px;
  box-shadow: var(--shadow-md);
  font-size: 12px;
  line-height: 1.5;
}

.drawer-backdrop {
  display: none;
}

.mobile-nav {
  display: none;
}

.mobile-only {
  display: none;
}

.fatal {
  max-width: 680px;
  margin: 90px auto;
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

@keyframes gentle-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(0.94); opacity: 0.76; }
}

@keyframes view-in {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 1180px) {
  .app-shell {
    grid-template-columns: 84px minmax(0, 1fr);
  }

  .app-sidebar {
    width: 84px;
    padding-inline: 10px;
  }

  .sidebar-brand {
    justify-content: center;
    padding-inline: 0;
  }

  .brand-copy,
  .sidebar-nav-item > span,
  .sidebar-install > span,
  .sidebar-footer small {
    display: none;
  }

  .sidebar-nav-item,
  .sidebar-install {
    justify-content: center;
    padding-inline: 0;
  }

  .sidebar-nav-item.is-active::before {
    left: -10px;
  }

  .sidebar-footer {
    grid-template-columns: 1fr;
    justify-items: center;
    padding-inline: 0;
  }

  .sidebar-install {
    grid-column: 1;
  }

  .course-toolbar {
    grid-template-columns: auto minmax(200px, 1fr);
  }

  .course-toolbar .filter-switch {
    grid-column: 1 / -1;
    justify-self: start;
  }
}

@media (max-width: 920px) {
  .app-shell {
    display: block;
  }

  .app-sidebar {
    display: none;
  }

  .app-header {
    min-height: 62px;
    padding: 0 14px;
  }

  .mobile-brand {
    display: flex;
    gap: 8px;
    color: var(--ink);
  }

  .mobile-brand .brand-mark {
    width: 34px;
    height: 34px;
    font-size: 14px;
  }

  .mobile-brand strong {
    font-size: 14px;
    white-space: nowrap;
  }

  .header-context {
    display: none;
  }

  .header-progress > span:last-child {
    display: none;
  }

  .header-progress {
    width: 40px;
    padding: 0;
    justify-content: center;
  }

  .main-content {
    min-height: calc(100vh - 62px);
    padding: 24px 18px calc(92px + env(safe-area-inset-bottom));
  }

  .today-focus-grid {
    grid-template-columns: 1fr;
  }

  .today-plan {
    padding: 20px;
  }

  .course-toolbar {
    grid-template-columns: 1fr;
  }

  .course-toolbar .filter-switch {
    grid-column: auto;
    justify-self: stretch;
  }

  .filter-switch button {
    width: 100%;
  }

  .course-browser {
    display: block;
  }

  .chapter-panel {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 110;
    width: min(86vw, 360px);
    max-height: none;
    padding: 22px 16px calc(24px + env(safe-area-inset-bottom));
    background: var(--surface);
    border-right: 1px solid var(--line);
    box-shadow: var(--shadow-md);
    transform: translateX(-105%);
    transition: transform 0.2s ease;
  }

  body.drawer-open .chapter-panel {
    transform: translateX(0);
  }

  .chapter-panel-head {
    position: sticky;
    top: -22px;
    z-index: 2;
    margin: -22px -16px 12px;
    padding: 16px;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
  }

  .drawer-backdrop {
    position: fixed;
    inset: 0;
    z-index: 105;
    display: block;
    padding: 0;
    background: rgba(15, 30, 26, 0.48);
    border: 0;
  }

  .mobile-only {
    display: inline-flex;
  }

  .mobile-nav {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 70;
    display: grid;
    /* 5 个主入口：今日/刷课/课程/复习/我的 —— 其余进"更多"
       之前写死 repeat(4) 但有 8 个按钮，导致挤成两行 */
    grid-template-columns: repeat(5, minmax(0, 1fr));
    min-height: calc(68px + env(safe-area-inset-bottom));
    padding-bottom: env(safe-area-inset-bottom);
    background: rgba(255, 255, 255, 0.97);
    border-top: 1px solid var(--line);
    backdrop-filter: blur(12px);
  }

  .mobile-nav button {
    position: relative;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 4px;
    min-width: 0;
    color: var(--muted);
    background: transparent;
    border: 0;
    cursor: pointer;
    font-size: 10px;
  }

  .mobile-nav button svg {
    width: 21px;
    height: 21px;
  }

  .mobile-nav button.is-active {
    color: var(--coral-dark);
    font-weight: 900;
  }

  .mobile-nav .nav-badge {
    position: absolute;
    top: 8px;
    left: calc(50% + 7px);
    min-width: 17px;
    height: 17px;
  }

  body.episode-mode .mobile-nav {
    display: none;
  }

  body.episode-mode .main-content {
    padding-bottom: calc(34px + env(safe-area-inset-bottom));
  }

  .lesson-tabs {
    top: 62px;
  }

  .episode-heading {
    grid-template-columns: minmax(0, 1fr) 72px;
  }

  .episode-guide div {
    display: none;
  }

  .review-list-heading {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 680px) {
  h1 {
    font-size: 28px;
  }

  .page-intro {
    flex-direction: column;
    align-items: flex-start;
    margin-bottom: 22px;
  }

  .page-intro h1 {
    font-size: 28px;
  }

  .intro-copy {
    font-size: 13px;
  }

  .daily-pulse {
    display: none;
  }

  .continue-card {
    grid-template-columns: minmax(0, 1fr) 124px;
    min-height: 244px;
  }

  .continue-copy {
    padding: 28px 4px 28px 26px;
  }

  .continue-copy h2 {
    font-size: 22px;
  }

  .continue-guide {
    padding: 18px 10px 0 0;
  }

  .continue-guide img {
    width: 108px;
    height: 135px;
    border-width: 4px;
  }

  .continue-guide div {
    top: 15px;
    right: 12px;
    max-width: 108px;
    text-align: center;
  }

  .continue-guide div span {
    display: none;
  }

  .continue-actions .quiet-button {
    display: none;
  }

  .metric-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .metric-strip > div {
    border-top: 1px solid var(--line);
  }

  .metric-strip > div:nth-child(-n + 2) {
    border-top: 0;
  }

  .metric-strip > div:nth-child(odd) {
    border-left: 0;
  }

  .book-progress-list {
    grid-template-columns: 1fr;
  }

  .episode-card {
    grid-template-columns: 44px minmax(0, 1fr) auto;
    gap: 10px;
    padding: 11px;
  }

  .episode-avatar {
    width: 42px;
    height: 42px;
  }

  .episode-card > svg {
    display: none;
  }

  .status-pill {
    max-width: 70px;
    padding-inline: 7px;
    font-size: 9px;
  }

  .subject-switch {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .subject-switch button {
    min-width: 0;
  }

  .review-overview {
    grid-template-columns: 1fr;
  }

  .review-overview > div {
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .review-overview > div:first-child {
    border-top: 0;
  }

  .profile-hero {
    grid-template-columns: 54px minmax(0, 1fr) auto;
    gap: 12px;
    padding: 19px;
  }

  .profile-avatar {
    width: 52px;
    height: 52px;
  }

  .profile-percent {
    font-size: 24px;
  }

  .profile-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .profile-stat {
    border-top: 1px solid var(--line);
  }

  .profile-stat:nth-child(-n + 2) {
    border-top: 0;
  }

  .profile-stat:nth-child(odd) {
    border-left: 0;
  }

  .setting-row {
    grid-template-columns: 40px minmax(0, 1fr) auto;
    padding-inline: 13px;
  }

  .episode-toolbar {
    margin-bottom: 17px;
  }

  .episode-heading {
    gap: 11px;
  }

  .episode-heading h1 {
    font-size: 24px;
  }

  .episode-question {
    font-size: 13px;
  }

  .episode-guide img {
    width: 62px;
    height: 62px;
  }

  .learning-steps {
    justify-content: flex-start;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .learning-steps::-webkit-scrollbar {
    display: none;
  }

  .lesson-tabs button {
    gap: 4px;
    padding-inline: 3px;
    font-size: 10px;
  }

  .lesson-tabs svg {
    width: 15px;
    height: 15px;
  }

  .source-grid {
    grid-template-columns: 1fr;
  }

  .recall-lab {
    padding: 20px 16px;
  }

  .rating-options {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .episode-status-bar {
    align-items: flex-start;
    flex-direction: column;
    gap: 2px;
    padding: 9px 0;
  }

  .toast {
    right: 16px;
    bottom: calc(82px + env(safe-area-inset-bottom));
    left: 16px;
  }
}

@media (max-width: 440px) {
  .main-content {
    padding-right: 13px;
    padding-left: 13px;
  }

  .app-header {
    padding-inline: 11px;
  }

  .mobile-brand strong {
    display: none;
  }

  .continue-card {
    grid-template-columns: minmax(0, 1fr) 104px;
  }

  .continue-copy {
    padding-left: 22px;
  }

  .continue-copy h2 {
    font-size: 20px;
  }

  .continue-guide img {
    width: 92px;
    height: 122px;
  }

  .continue-guide div {
    right: 7px;
    max-width: 94px;
  }

  .metric-strip > div {
    display: grid;
    grid-template-columns: 1fr auto auto;
    padding: 14px;
  }

  .book-card {
    grid-template-columns: 50px minmax(0, 1fr) auto;
    padding: 14px;
  }

  .book-cover {
    width: 48px;
    height: 60px;
  }

  .section-heading {
    align-items: flex-start;
  }

  .section-heading .text-button {
    font-size: 11px;
  }

  .page-intro .primary-button {
    padding-inline: 12px;
  }

  .episode-nav-actions > span {
    min-width: 48px;
  }

  .lesson-tabs button svg {
    width: 16px;
    height: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
