/* 全屏状态下修正鼠标指针，防止 Chrome 全屏 API 产生双鼠标残影 */
html:-webkit-full-screen { cursor: default; }
html:-moz-full-screen { cursor: default; }
html:-ms-fullscreen { cursor: default; }
html:fullscreen { cursor: default; }
.app-container:-webkit-full-screen,
.app-container:-moz-full-screen,
.app-container:-ms-fullscreen,
.app-container:fullscreen { cursor: default; }

/* ===== CSS Variables ===== */
:root {
  --bg: #EEF2FF;
  --white: #FFFFFF;
  --primary: #4F46E5;
  --primary-light: #818CF8;
  --primary-dark: #312E81;
  --success: #16A34A;
  --success-dark: #15803D;
  --warning: #D97706;
  --error: #EF4444;
  --text-dark: #312E81;
  --text-gray: #64748B;
  --text-body: #475569;
  --text-placeholder: #94A3B8;
  --text-option: #1E293B;
  --border-light: #EEF2FF;
  --bg-primary-light: #E0E7FF;
  --bg-success-light: #DCFCE7;
  --bg-warning-light: #FEF3C7;
  --bg-error-light: #FEE2E2;
  --bg-purple-light: #F3E8FF;
  --bg-pink-light: #FDE1F5;
  --bg-secondary-bg: #F8FAFC;
  --purple: #7C3AED;
  --yellow-warm: #EAB308;
  --orange: #EA580C;
  --font-en: 'Poppins', sans-serif;
  --font-zh: 'Noto Sans SC', "PingFang SC", "Microsoft YaHei", "Heiti SC", sans-serif;
  --radius-sm: 4px;
  --radius: 6px;
  --radius-md: 8px;
  --radius-lg: 10px;
  --radius-xl: 12px;
  --radius-2xl: 14px;
  --radius-3xl: 16px;
  --radius-full: 18px;
}

/* ===== Themes ===== */
/* Deep Blue (Default) — 浅色模式 — above :root */



/* ===== 全屏按钮 (sidebar-footer) ===== */
.sidebar-footer button.fs-footer-btn {
  background: none;
  border: none;
  font-size: 12px;
  color: #9CA3AF;
  display: block;
  line-height: 1.6;
  width: 100%;
  cursor: pointer;
  padding: 2px 0;
  font-family: inherit;
}

/* ===== Reset & Base ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { width: 100%; height: 100%; font-family: var(--font-zh); background: var(--bg); color: var(--text-dark); }

/* ===== App Layout ===== */
.app-container {
  display: flex;
  width: 100%; height: 100vh;
  overflow: hidden;
}

/* ===== Sidebar ===== */
.sidebar {
  width: 240px; min-width: 240px; height: 100vh;
  background: var(--white);
  display: flex; flex-direction: column;
  padding: 24px;
  gap: 32px;
  z-index: 10;
}
.logo-area {
  display: flex; align-items: center; gap: 12px;
  width: 192px; height: 48px;
  text-decoration: none;
}
.logo-icon {
  width: 40px; height: 40px;
  background: var(--primary);
  border-radius: var(--radius-xl);
  display: flex; align-items: center; justify-content: center;
}
.logo-icon span {
  font-family: var(--font-en);
  font-weight: 700; font-size: 22px;
  color: var(--white);
  line-height: 1;
}
.app-name {
  font-family: var(--font-zh);
  font-weight: 700; font-size: 18px;
  color: var(--text-dark);
  white-space: nowrap;
}

/* Nav */
.nav-section { display: flex; flex-direction: column; gap: 4px; }
.nav-label {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 11px;
  color: var(--primary-light);
  margin-bottom: 12px;
}
.nav-item {
  display: flex; align-items: center; gap: 12px;
  width: 192px; height: 44px;
  border-radius: var(--radius-lg);
  padding: 0 10px;
  cursor: pointer;
  text-decoration: none;
}
.nav-item:hover { background: var(--bg-primary-light); }
.nav-item.active { background: var(--bg); }
.nav-icon {
  width: 24px; height: 24px;
  border-radius: var(--radius);
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
}
.nav-icon svg {
  width: 18px; height: 18px;
}
.nav-icon.default { color: #94A3B8; }
.nav-icon.primary { color: var(--primary); }
.nav-icon.success { color: var(--success); }
.nav-icon.warning { color: #F59E0B; }
.nav-icon.purple { color: var(--purple); }
.nav-text {
  font-family: var(--font-zh);
  font-size: 14px;
}
.nav-text.default { font-weight: 400; color: var(--text-gray); }
.nav-text.active { font-weight: 500; color: inherit; }

.spacer { flex: 1; }

/* User Area */
.user-area {
  display: flex; align-items: center; gap: 12px;
  padding: 8px;
  border-radius: var(--radius-xl);
  height: 48px;
  text-decoration: none;
  cursor: pointer;
  
}
.user-area:hover { background: var(--bg); }
.avatar {
  width: 36px; height: 36px;
  background: var(--primary-light);
  border-radius: var(--radius-full);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.avatar span {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 14px;
  color: var(--white);
}
.user-info { display: flex; flex-direction: column; }
.user-name {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 14px;
  color: var(--text-dark);
}
.user-level {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 11px;
  color: var(--text-gray);
}

/* ===== Main Content ===== */
.main-content {
  flex: 1; height: 100vh;
  display: flex; flex-direction: column;
  padding: 32px;
  gap: 24px;
  overflow-y: auto;
}

/* Top Bar */
.top-bar {
  display: flex; align-items: center;
  justify-content: space-between;
  width: 100%;
}
.breadcrumb {
  display: flex; align-items: center; gap: 8px;
  font-size: 14px;
}
.breadcrumb .bc-home {
  font-weight: 400; color: var(--primary-light); cursor: pointer;
  text-decoration: none;
}
.breadcrumb .bc-arrow { color: #C7D2FE; }
.breadcrumb .bc-current {
  font-weight: 500; color: var(--text-dark);
}

/* Welcome */
.welcome-group { display: flex; flex-direction: column; gap: 4px; }
.welcome-title {
  font-family: var(--font-zh);
  font-weight: 700; font-size: 24px;
  color: var(--text-dark);
}
.welcome-sub {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 14px;
  color: var(--text-gray);
}

/* Streak Badge */
.streak-badge {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 16px;
  background: var(--white);
  border-radius: 22px;
}
.streak-icon {
  width: 24px; height: 24px;
  background: var(--bg-warning-light);
  border-radius: var(--radius-xl);
  display: flex; align-items: center; justify-content: center;
  font-size: 14px;
}
.streak-text {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 14px;
  color: var(--text-dark);
}

/* Stats Row */
.stats-row { display: flex; gap: 16px; width: 100%; }
.stat-card {
  flex: 1;
  background: var(--white);
  border-radius: var(--radius-3xl);
  padding: 20px;
  display: flex; flex-direction: column;
  align-items: center; text-align: center;
  gap: 12px;
}
.stat-icon {
  width: 40px; height: 40px;
  border-radius: var(--radius-lg);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
}
.stat-icon.blue { background: var(--bg-primary-light); }
.stat-icon.green { background: var(--bg-success-light); }
.stat-icon.yellow { background: var(--bg-warning-light); }
.stat-icon.purple { background: var(--bg-purple-light); }
.stat-number {
  font-family: var(--font-en);
  font-weight: 700; font-size: 28px;
  line-height: 1.5;
}
.stat-number.blue { color: var(--primary); }
.stat-number.green { color: var(--success); }
.stat-number.yellow { color: var(--warning); }
.stat-number.purple { color: var(--purple); }
.stat-label {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 13px;
  color: var(--text-gray);
}

/* Quick Actions */
.quick-actions { display: flex; gap: 16px; width: 100%; }
.action-card {
  flex: 1; height: 120px;
  border-radius: var(--radius-3xl);
  display: flex; align-items: center;
  padding: 0 24px;
  gap: 20px;
  cursor: pointer;
  text-decoration: none;
}
.action-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(79,70,229,0.2); }
.action-card.learn { background: var(--primary); }
.action-card.practice { background: var(--success); }
.action-card-content { flex: 1; display: flex; flex-direction: column; gap: 8px; }
.action-card-title {
  font-family: var(--font-zh);
  font-weight: 700; font-size: 20px;
  color: var(--white);
}
.action-card-desc {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 13px;
}
.action-card.learn .action-card-desc { color: #C7D2FE; }
.action-card.practice .action-card-desc { color: #BBF7D0; }
.action-arrow {
  width: 44px; height: 44px;
  border-radius: 22px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.action-card.learn .action-arrow { background: #6366F1; }
.action-card.practice .action-arrow { background: var(--success-dark); }
.action-arrow span {
  font-family: var(--font-en);
  font-weight: 700; font-size: 20px;
  color: var(--white);
}

/* Words Section */
.words-section { display: flex; flex-direction: column; gap: 16px; width: 100%; }
.words-header {
  display: flex; align-items: center;
  justify-content: space-between;
}
.words-title {
  font-family: var(--font-zh);
  font-weight: 700; font-size: 18px;
  color: var(--text-dark);
}
.see-all {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 14px;
  color: var(--primary);
  cursor: pointer;
  text-decoration: none;
}
.words-row { display: flex; gap: 16px; width: 100%; }
.word-card {
  flex: 1;
  background: var(--white);
  border-radius: var(--radius-2xl);
  padding: 20px;
  display: flex; flex-direction: column;
  gap: 8px;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.2s;
}
.word-card:hover { transform: translateY(-2px); box-shadow: 0 4px 16px rgba(0,0,0,0.06); }
.word-tag {
  display: inline-flex; align-items: center;
  padding: 4px 8px;
  border-radius: var(--radius);
  width: fit-content;
}
.word-tag.phrase { background: var(--bg); color: var(--primary); }
.word-tag.synonym { background: var(--bg-success-light); color: var(--success); }
.word-tag.mix { background: var(--bg-warning-light); color: var(--warning); }
.word-tag-text {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 11px;
}
.word-english {
  font-family: var(--font-en);
  font-weight: 700; font-size: 18px;
  color: var(--text-dark);
}
.word-chinese {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 13px;
  color: var(--text-gray);
}
/* 推荐加载骨架 */
.word-card-skel {
  cursor: default;
  display: flex; flex-direction: column; gap: 10px;
  animation: skelPulse 1.5s ease-in-out infinite;
}
.word-card-skel:hover { transform: none; box-shadow: none; }
@keyframes skelPulse {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.5; }
}
.skel-line {
  display: block; height: 14px; background: #E2E8F0; border-radius: 8px;
}
.skel-line.short { width: 60%; }
.words-empty {
  text-align: center; padding: 24px;
  color: var(--text-gray); font-size: 14px;
  width: 100%;
}
.words-empty a { color: var(--primary); text-decoration: underline; }

/* ===== Learn Page ===== */
.search-box {
  display: flex; align-items: center; gap: 10px;
  width: 280px; height: 40px;
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 0 10px;
}
.search-icon {
  width: 18px; height: 18px;
  background: #C7D2FE;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}
.search-placeholder {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 13px;
  color: var(--text-placeholder);
}
.category-tabs {
  display: flex; gap: 4px;
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 4px;
  width: fit-content;
}
.tab {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 12px;
  border-radius: var(--radius-md);
  cursor: pointer;
  
  border: none;
  font-family: var(--font-zh);
}
.tab.active { background: var(--primary); }
.tab-icon {
  width: 18px; height: 18px;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}
.tab.active .tab-icon { background: #6366F1; }
.tab:not(.active) .tab-icon { background: var(--bg); }
.tab-text {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 13px;
}
.tab.active .tab-text { color: var(--white); }
.tab:not(.active) .tab-text { color: var(--text-gray); }
.category-tabs {
  display: flex; flex-wrap: wrap; gap: 6px;
  margin-top: -8px;
}
.category-tabs .tab {
  padding: 5px 10px;
  border-radius: var(--radius-md);
  font-size: 12px;
}
.two-cols {
  display: flex; gap: 24px;
  flex: 1; min-height: 0;
}
.col-left, .col-right {
  flex: 1;
  display: flex; flex-direction: column;
  gap: 16px;
  overflow-y: auto;
  padding-bottom: 10px;
}
.grade-selector {
  display: flex; align-items: center; gap: 12px;
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 0 10px;
  height: 44px;
  cursor: pointer;
  position: relative;
  z-index: 50;
}
.grade-selector .book-icon {
  width: 20px; height: 20px;
  background: var(--primary);
  border-radius: 5px;
  flex-shrink: 0;
}
.grade-selector .grade-text {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 15px;
  color: var(--text-dark);
  flex: 1;
}
.grade-selector .arrow-down { font-size: 10px; color: var(--primary-light); }
.unit-group { display: flex; flex-direction: column; gap: 8px; }
.unit-header { display: flex; align-items: center; gap: 8px; }
.unit-title {
  font-family: var(--font-zh);
  font-weight: 700; font-size: 16px;
  color: var(--text-dark);
}
.unit-subtitle {
  display: inline-flex; align-items: center;
  padding: 2px 6px;
  border-radius: var(--radius);
  font-family: var(--font-zh);
  font-weight: 500; font-size: 11px;
}
.unit-subtitle.blue { background: var(--bg); color: var(--primary); }
.unit-subtitle.green { background: var(--bg-success-light); color: var(--success); }
.word-item {
  display: flex; align-items: center; gap: 14px;
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: 14px;
  cursor: pointer;
  transition: transform 0.2s;
}
.word-item:hover { transform: translateX(4px); box-shadow: 0 2px 8px rgba(0,0,0,0.04); }
.word-item-icon {
  width: 44px; height: 44px;
  border-radius: var(--radius-lg);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  font-size: 20px;
}
.word-item-icon.blue { background: var(--bg-primary-light); }
.word-item-icon.green { background: var(--bg-success-light); }
.word-item-icon.yellow { background: var(--bg-warning-light); }
.word-item-icon.purple { background: var(--bg-purple-light); }
.word-item-icon.pink { background: var(--bg-pink-light); }
.word-item-info { flex: 1; display: flex; flex-direction: column; gap: 4px; }
.word-item-eng {
  font-family: var(--font-en);
  font-weight: 700; font-size: 16px;
  color: var(--text-dark);
}
.word-item-chn {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 12px;
  color: var(--text-gray);
}
.word-item-tag {
  display: inline-flex; align-items: center;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  font-family: var(--font-zh);
  font-weight: 500; font-size: 10px;
  flex-shrink: 0;
}
.word-item-tag.blue { background: var(--bg); color: var(--primary); }
.word-item-tag.green { background: var(--bg-success-light); color: var(--success); }
.word-item-tag.yellow { background: var(--bg-warning-light); color: var(--warning); }
.word-item-tag.purple { background: var(--bg-purple-light); color: var(--purple); }
.word-item-tag.pink { background: var(--bg-pink-light); color: #DB2777; }
.detail-header { display: flex; align-items: center; gap: 12px; }
.detail-icon {
  width: 48px; height: 48px;
  background: var(--bg);
  border-radius: var(--radius-xl);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  font-size: 24px;
}
.detail-info { display: flex; flex-direction: column; gap: 2px; }
.detail-eng {
  font-family: var(--font-en);
  font-weight: 700; font-size: 20px;
  color: var(--text-dark);
}
.detail-chn {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 13px;
  color: var(--text-gray);
}
.illust-card {
  background: var(--white);
  border-radius: var(--radius-2xl);
  padding: 16px;
  display: flex; flex-direction: column;
  gap: 12px;
}
.ai-label { display: flex; align-items: center; gap: 8px; }
.ai-spark {
  width: 16px; height: 16px;
  background: var(--primary);
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  font-size: 8px;
}
.ai-label-text {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 11px;
  color: var(--primary-light);
}
.illust-placeholder {
  width: 100%; height: 200px;
  background: var(--bg);
  border-radius: var(--radius-lg);
  display: flex; align-items: center; justify-content: center;
}
.illust-placeholder span {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 14px;
  color: var(--text-placeholder);
}
.analysis-card {
  background: var(--white);
  border-radius: var(--radius-2xl);
  padding: 18px 20px;
  display: flex; flex-direction: column;
  gap: 12px;
  border-left: 4px solid var(--primary);
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.analysis-card:nth-child(2) { border-left-color: var(--success); }
.analysis-card:nth-child(3) { border-left-color: var(--warning); }
.analysis-card:nth-child(4) { border-left-color: var(--error); }


.section-header { 
  display: flex; align-items: center; gap: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--bg);
}
.section-dot {
  width: 32px; height: 32px;
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}
.section-dot.blue { background: #EEEDFE; }
.section-dot.green { background: #E1F5EE; }
.section-dot.orange { background: #FAEEDA; }


.section-title {
  font-family: var(--font-zh);
  font-weight: 700; font-size: 15px;
  color: var(--text-dark);
}
.analysis-text {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 13px;
  color: var(--text-body);
  line-height: 1.8;
  white-space: pre-line;
}
/* 美化：自动识别英文词组并加粗 */
.analysis-text strong {
  font-weight: 600;
  color: var(--primary);
}
/* ===== Practice Page Icons ===== */
.practice-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}
.practice-icon-sm {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}
 setup-section-title {
  display: flex;
  align-items: center;
  gap: 8px;
}
.loading-title {
  display: flex;
  align-items: center;
  gap: 8px;
}
.hint-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
}
.parse-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.ai-analysis-header {
  display: flex;
  align-items: center;
  gap: 8px;
}
.result-card-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.result-stat-label {
  display: flex;
  align-items: center;
  gap: 4px;
}
.result-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.review-btn {
  display: flex;
  align-items: center;
  gap: 6px;
}
.divider {
  width: 100%; height: 1px;
  background: var(--bg);
}
.examples-text {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 12px;
  color: var(--primary);
  line-height: 1.8;
}
.cta-btn {
  display: flex; align-items: center; justify-content: center;
  gap: 8px;
  width: 100%; height: 48px;
  background: var(--success);
  border: none;
  border-radius: var(--radius-xl);
  color: var(--white);
  font-family: var(--font-zh);
  font-weight: 500; font-size: 15px;
  cursor: pointer;
  
}
.cta-btn:hover { background: var(--success-dark); }
.cta-btn:disabled,
.cta-btn.disabled {
  background: #CBD5E1;
  color: #94A3B8;
  cursor: not-allowed;
  pointer-events: none;
}

/* ===== Practice Page ===== */
.practice-centered {
  align-items: center;
  justify-content: flex-start;
  padding: 32px 210px;
  overflow-y: auto;
}
.quiz-card {
  background: var(--white);
  border-radius: var(--radius-3xl);
  padding: 28px;
  display: flex; flex-direction: column;
  gap: 20px;
  width: 780px;
}
.quiz-header {
  display: flex; align-items: center;
  justify-content: space-between;
}
.quiz-num {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 14px;
  color: var(--primary);
}
.quiz-type {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 12px;
  color: var(--primary-light);
}
.progress-track {
  width: 724px; height: 6px;
  background: var(--bg);
  border-radius: 3px;
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  background: var(--primary);
  border-radius: 3px;
  transition: width 0.3s;
}
.scenario-img {
  width: 100%; height: 200px;
  background: var(--bg);
  border-radius: var(--radius-xl);
  display: flex; align-items: center; justify-content: center;
}
.scenario-img span {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 16px;
  color: var(--text-placeholder);
}
.question-text {
  font-family: var(--font-en);
  font-weight: 600; font-size: 18px;
  color: var(--text-dark);
}
.question-hint {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 13px;
  color: var(--text-placeholder);
  padding: 8px 12px;
  background: #F8FAFC;
  border-radius: var(--radius-md);
  margin-top: 4px;
  line-height: 1.5;
}
.question-hint-wrap {
  text-align: center;
}
.hint-toggle {
  display: inline-flex; align-items: center; gap: 4px;
  font-family: var(--font-zh);
  font-size: 13px; font-weight: 500;
  color: var(--link-color, #7C3AED);
  cursor: pointer;
  user-select: none;
  padding: 4px 0;
  transition: opacity 0.15s;
}
.hint-toggle:hover { opacity: 0.75; }
.option {
  display: flex; align-items: center; gap: 12px;
  padding: 14px;
  border-radius: var(--radius-xl);
  cursor: pointer;
  transition: border-color 0.2s;
  border: 2px solid transparent;
}
.option.normal { background: #F8FAFC; }
.option.normal:hover { border-color: var(--primary-light); }
.option.selected { background: var(--bg); border-color: var(--primary); }
.option.correct { background: var(--bg-success-light); border-color: var(--success); }
.option.wrong { background: var(--bg-error-light); border-color: var(--error); }
.option-letter {
  width: 36px; height: 36px;
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.option-letter.blue { background: var(--bg); }
.option-letter.green { background: var(--bg-success-light); }
.option-letter.green-filled { background: var(--success); }
.option-letter-text {
  font-family: var(--font-en);
  font-weight: 700; font-size: 16px;
}
.option-letter.blue .option-letter-text { color: var(--primary); }
.option-letter.green .option-letter-text { color: var(--success); }
.option-letter.green-filled .option-letter-text { color: var(--white); }
.option-text {
  font-family: var(--font-en);
  font-weight: 500; font-size: 16px;
  color: var(--text-option);
}
.option-text.correct { color: var(--success-dark); font-weight: 700; }
.checkmark { font-weight: 700; font-size: 16px; color: var(--success); display: none; }
.parse-btn {
  display: flex; align-items: center; justify-content: center;
  gap: 8px;
  width: 100%; height: 48px;
  background: var(--primary);
  border: none;
  border-radius: var(--radius-xl);
  color: var(--white);
  font-family: var(--font-zh);
  font-weight: 500; font-size: 15px;
  cursor: pointer;
  
}
.parse-btn:hover { background: #4338CA; }
.ai-analysis {
  background: var(--bg);
  border-radius: var(--radius-xl);
  padding: 16px;
  display: flex; flex-direction: column;
  gap: 12px;
}
.ai-analysis-header { display: flex; align-items: center; gap: 8px; }
.ai-analysis-header .spark { font-size: 16px; }
.ai-analysis-title {
  font-family: var(--font-zh);
  font-weight: 700; font-size: 15px;
  color: var(--primary);
}
.ai-analysis-body {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 13px;
  color: var(--text-body);
  line-height: 1.8;
  white-space: pre-line;
}
.next-btn {
  display: flex; align-items: center; justify-content: center;
  gap: 8px;
  width: 100%; height: 44px;
  background: var(--success);
  border: none;
  border-radius: var(--radius-lg);
  color: var(--white);
  font-family: var(--font-zh);
  font-weight: 500; font-size: 15px;
  cursor: pointer;
  
}
.next-btn:hover { background: var(--success-dark); }
.bottom-nav {
  display: flex; align-items: center;
  justify-content: space-between;
  width: 780px;
}
.prev-btn {
  display: flex; align-items: center; gap: 6px;
  background: var(--white);
  border: none;
  border-radius: var(--radius-lg);
  padding: 10px 16px;
  font-family: var(--font-zh);
  font-weight: 500; font-size: 14px;
  color: var(--text-gray);
  cursor: pointer;
  
}
.prev-btn:hover { background: var(--bg); }
.submit-btn {
  display: flex; align-items: center; gap: 6px;
  background: var(--primary);
  border: none;
  border-radius: var(--radius-lg);
  padding: 10px 16px;
  font-family: var(--font-zh);
  font-weight: 500; font-size: 14px;
  color: var(--white);
  cursor: pointer;
  
}
.submit-btn:hover { background: #4338CA; }

.review-btn {
  display: flex; align-items: center; gap: 6px;
  background: var(--white);
  border: 1.5px solid var(--primary);
  border-radius: var(--radius-lg);
  padding: 10px 16px;
  font-family: var(--font-zh);
  font-weight: 500; font-size: 14px;
  color: var(--primary);
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, opacity 0.2s;
}
.review-btn:hover { background: var(--bg-primary-light); }

/* ===== Practice Setup Panel ===== */
.practice-setup {
  display: flex; flex-direction: column; gap: 24px;
  padding: 32px 0;
}
.setup-section { display: flex; flex-direction: column; gap: 10px; }
.setup-section-title {
  font-family: var(--font-zh);
  font-weight: 600; font-size: 14px;
  color: var(--text-secondary);
}
.setup-count-row { display: flex; gap: 10px; }
.setup-count-btn {
  flex: 1; padding: 14px 0;
  border: 2px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--white);
  font-family: var(--font-en);
  font-weight: 700; font-size: 20px;
  color: var(--text-dark);
  cursor: pointer;
  transition: border-color 0.18s, color 0.18s, opacity 0.18s;
}
.setup-count-btn:hover { border-color: var(--primary); color: var(--primary); }
.setup-count-btn.active { border-color: var(--primary); background: var(--primary); color: white; }

.setup-grade-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.setup-grade-chip {
  padding: 8px 16px;
  border: 1.5px solid var(--border);
  border-radius: 100px;
  background: var(--white);
  font-family: var(--font-zh);
  font-size: 13px; font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s, opacity 0.15s;
}
.setup-grade-chip:hover { border-color: var(--primary); color: var(--primary); }
.setup-grade-chip.active { border-color: var(--primary); background: #EEF2FF; color: var(--primary); font-weight: 600; }

.setup-start-btn {
  width: 100%; padding: 16px;
  border: none; border-radius: var(--radius-xl);
  background: var(--primary);
  font-family: var(--font-zh);
  font-weight: 700; font-size: 18px;
  color: white;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, opacity 0.2s;
}
.setup-start-btn:hover { background: #4F46E5; transform: translateY(-1px); box-shadow: 0 4px 16px rgba(99,102,241,0.35); }
.setup-start-btn:disabled { background: #CBD5E1; cursor: not-allowed; transform: none; box-shadow: none; }

/* ===== Practice Result Overlay ===== */
.result-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.45);
  display: flex; align-items: center; justify-content: center;
  z-index: 100;
  backdrop-filter: blur(4px);
}
.result-card-title {
  font-family: var(--font-zh);
  font-weight: 700; font-size: 22px;
  color: var(--text-dark);
}
.result-stats { display: flex; justify-content: center; gap: 32px; }
.result-stat {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
}
.result-stat-value {
  font-family: var(--font-en);
  font-weight: 800; font-size: 32px;
}
.result-stat-value.green { color: var(--success); }
.result-stat-value.red { color: var(--danger); }
.result-stat-label {
  font-family: var(--font-zh);
  font-size: 12px; color: var(--text-placeholder);
}
.result-accuracy {
  font-family: var(--font-en);
  font-weight: 800; font-size: 48px;
  background: linear-gradient(135deg, var(--primary), #818CF8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.result-actions { display: flex; flex-direction: column; gap: 10px; }
.result-btn {
  width: 100%; padding: 14px;
  border: none; border-radius: var(--radius-lg);
  font-family: var(--font-zh);
  font-weight: 600; font-size: 15px;
  cursor: pointer;
  transition: border-color 0.18s, color 0.18s, opacity 0.18s;
}
.result-btn.primary { background: var(--primary); color: white; }
.result-btn.primary:hover { background: #4F46E5; }
.result-btn.secondary { background: var(--bg); color: var(--text-secondary); }
.result-btn.secondary:hover { background: var(--border); }

/* ===== Practice Page ===== */
.stats-mini { display: flex; gap: 16px; }
.mini-stat { display: flex; align-items: center; gap: 6px; }
.mini-value {
  font-family: var(--font-en);
  font-weight: 700; font-size: 18px;
}
.mini-value.orange { color: var(--warning); }
.mini-value.green { color: var(--success); }
.mini-value.blue { color: var(--primary); }
.mini-label {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 12px;
  color: var(--text-gray);
}
.filter-bar {
  display: flex; align-items: center; gap: 12px;
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: 12px;
}
.filter-pill {
  display: flex; align-items: center; gap: 6px;
  padding: 7px 12px;
  border-radius: var(--radius-md);
  cursor: pointer;
  border: none;
  font-family: var(--font-zh);
  
}
.filter-pill.active { background: var(--primary); }
.filter-pill:not(.active):hover { background: var(--bg); }
.filter-pill-text {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 13px;
}
.filter-pill.active .filter-pill-text { color: var(--white); }
.filter-pill:not(.active) .filter-pill-text { color: var(--text-gray); }
.filter-spacer { flex: 1; }
.retry-all-btn {
  display: flex; align-items: center; gap: 6px;
  padding: 7px 12px;
  background: var(--warning);
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-zh);
  font-weight: 500; font-size: 13px;
  color: var(--white);
  cursor: pointer;
}
.mistake-list {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 20px 20px;
  overflow-y: auto;
  align-content: start;
  justify-items: center;
}
.mistake-card {
  background: var(--white);
  border-radius: var(--radius-2xl);
  padding: 20px;
  display: flex; flex-direction: column;
  gap: 16px;
  max-width: 520px;
  width: 100%;
}
.card-header {
  display: flex; align-items: center;
  justify-content: space-between;
}
.card-tags { display: flex; gap: 8px; }
.tag-category {
  display: inline-flex; align-items: center;
  padding: 3px 6px;
  border-radius: var(--radius);
}
.tag-category.blue { background: var(--bg); }
.tag-category.green { background: var(--bg-success-light); }
.tag-category.yellow { background: var(--bg-warning-light); }
.tag-category-text {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 11px;
}
.tag-category.blue .tag-category-text { color: var(--primary); }
.tag-category.green .tag-category-text { color: var(--success); }
.tag-category.yellow .tag-category-text { color: var(--warning); }
.tag-vocab {
  display: inline-flex; align-items: center;
  padding: 3px 6px;
  background: var(--bg-warning-light);
  border-radius: var(--radius);
}
.tag-vocab-text {
  font-family: var(--font-en);
  font-weight: 500; font-size: 11px;
  color: var(--warning);
}
.card-date {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 12px;
  color: var(--text-placeholder);
}
.card-question {
  font-family: var(--font-en);
  font-weight: 600; font-size: 16px;
  color: var(--text-dark);
}
.answers-row { display: flex; gap: 16px; }
.answer-box {
  flex: 1; display: flex; align-items: center; gap: 10px;
  border-radius: var(--radius-md);
  padding: 10px 14px;
}
.answer-box.wrong { background: var(--bg-error-light); }
.answer-box.correct-box { background: #F0FDF4; }
.answer-icon {
  width: 20px; height: 20px;
  border-radius: var(--radius-lg);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.answer-icon.wrong { background: var(--error); }
.answer-icon.correct-icon { background: var(--success); }
.answer-label {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 11px;
}
.answer-box.wrong .answer-label { color: var(--error); }
.answer-box.correct-box .answer-label { color: var(--success); }
.answer-value {
  font-family: var(--font-en);
  font-weight: 600; font-size: 15px;
  color: var(--text-option);
}
.ai-compact {
  background: var(--bg);
  border-radius: var(--radius-lg);
  padding: 12px;
  display: flex; flex-direction: column;
  gap: 8px;
}
.ai-compact-title {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 12px;
  color: var(--primary);
}
.ai-compact-body {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 12px;
  color: var(--text-body);
  line-height: 1.7;
}
.card-actions {
  display: flex; align-items: center;
  justify-content: space-between;
}
.mark-mastered {
  display: flex; align-items: center; gap: 6px;
  padding: 6px 12px;
  background: #F0FDF4;
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-zh);
  font-weight: 500; font-size: 13px;
  color: var(--success);
  cursor: pointer;
}
.re-practice-btn {
  display: flex; align-items: center; gap: 6px;
  padding: 6px 14px;
  background: var(--primary);
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-zh);
  font-weight: 500; font-size: 13px;
  color: var(--white);
  cursor: pointer;
}
.delete-mistake-btn {
  display: flex; align-items: center; gap: 6px;
  padding: 6px 14px;
  background: var(--bg-danger-light, #FEE2E2);
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-zh);
  font-weight: 500; font-size: 13px;
  color: var(--danger, #EF4444);
  cursor: pointer;
}
.delete-mistake-btn:hover {
  background: #FECACA;
}

/* ===== Profile Page ===== */
.profile-card {
  background: var(--white);
  border-radius: var(--radius-3xl);
  padding: 24px;
  display: flex; align-items: center;
  gap: 20px;
}
.avatar-big {
  width: 72px; height: 72px;
  background: var(--primary-light);
  border-radius: 36px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.avatar-big span {
  font-family: var(--font-zh);
  font-weight: 700; font-size: 28px;
  color: var(--white);
}
.profile-info { flex: 1; display: flex; flex-direction: column; gap: 8px; }
.profile-name {
  font-family: var(--font-zh);
  font-weight: 700; font-size: 22px;
  color: var(--text-dark);
}
.profile-meta { display: flex; gap: 12px; }
.grade-badge {
  display: inline-flex; align-items: center;
  padding: 4px 8px;
  background: var(--bg);
  border-radius: var(--radius);
  font-family: var(--font-zh);
  font-weight: 500; font-size: 13px;
  color: var(--primary);
}
.days-badge {
  display: inline-flex; align-items: center;
  padding: 4px 8px;
  background: var(--bg-warning-light);
  border-radius: var(--radius);
  font-family: var(--font-zh);
  font-weight: 500; font-size: 13px;
  color: var(--warning);
}
.profile-stats { display: flex; flex-direction: column; gap: 6px; }
.stat-row {
  display: flex; justify-content: space-between;
  width: 200px;
}
.stat-row-label {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 13px;
  color: var(--text-gray);
}
.stat-row-value {
  font-family: var(--font-en);
  font-weight: 700; font-size: 16px;
}
.stat-row-value.blue { color: var(--primary); }
.stat-row-value.green { color: var(--success); }
.stat-row-value.orange { color: var(--warning); }
.activity-card {
  background: var(--white);
  border-radius: var(--radius-2xl);
  padding: 20px;
  display: flex; flex-direction: column;
  gap: 16px;
}
.activity-title {
  font-family: var(--font-zh);
  font-weight: 700; font-size: 16px;
  color: var(--text-dark);
}
.bar-chart {
  display: flex; gap: 16px;
  align-items: flex-end;
  justify-content: space-evenly;
  height: 140px;
}
.bar-col {
  flex: 1;
  display: flex; flex-direction: column;
  align-items: center;
  gap: 4px;
  justify-content: flex-end;
}
.bar-value {
  width: 32px;
  border-radius: var(--radius);
}
.bar-value.medium { background: var(--primary-light); }
.bar-value.full { background: var(--primary); }
.bar-value.light { background: #C7D2FE; }
.bar-day {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 12px;
  color: var(--text-placeholder);
}
.weak-card {
  background: var(--white);
  border-radius: var(--radius-2xl);
  padding: 20px;
  display: flex; flex-direction: column;
  gap: 16px;
}
.weak-title {
  font-family: var(--font-zh);
  font-weight: 700; font-size: 16px;
  color: var(--text-dark);
}
.weak-item {
  display: flex; align-items: center; gap: 14px;
  border-radius: var(--radius-lg);
  padding: 12px;
}
.weak-item.danger { background: var(--bg-error-light); }
.weak-item.warning-bg { background: #FEF3C7; }
.weak-item.caution { background: #FEF9E7; }
.rank-num {
  width: 28px; height: 28px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.rank-num.red { background: var(--error); }
.rank-num.orange { background: #F97316; }
.rank-num.yellow { background: #EAB308; }
.rank-num span {
  font-family: var(--font-en);
  font-weight: 700; font-size: 14px;
  color: var(--white);
}
.weak-info { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.weak-eng {
  font-family: var(--font-en);
  font-weight: 600; font-size: 14px;
  color: var(--text-dark);
}
.weak-chn {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 12px;
  color: var(--text-gray);
}
.go-btn {
  display: flex; align-items: center; gap: 4px;
  padding: 6px 12px;
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-zh);
  font-weight: 500; font-size: 12px;
  color: var(--white);
  cursor: pointer;
  flex-shrink: 0;
}
.go-btn.red { background: var(--error); }
.go-btn.orange { background: #F97316; }
.go-btn.yellow { background: #EAB308; }
.settings-card {
  background: var(--white);
  border-radius: var(--radius-2xl);
  padding: 20px;
  display: flex; flex-direction: column;
  gap: 16px;
}
.settings-title {
  font-family: var(--font-zh);
  font-weight: 700; font-size: 16px;
  color: var(--text-dark);
}
.setting-item {
  display: flex; align-items: center; gap: 12px;
  background: var(--bg-secondary-bg);
  border-radius: var(--radius-lg);
  padding: 12px;
  cursor: pointer;
}
.setting-item:hover { background: var(--bg); }
.setting-icon {
  width: 36px; height: 36px;
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  background: #F1F5F9;
  color: #64748B;
}
.setting-info { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.setting-label {
  font-family: var(--font-zh);
  font-weight: 500; font-size: 14px;
  color: var(--text-dark);
}
.setting-value {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 13px;
  color: var(--text-gray);
}
.setting-arrow {
  width: 24px; height: 24px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; color: var(--primary);
}
.setting-arrow svg { display: block; }
.setting-arrow-danger { color: #EF4444; }
.setting-toggle {
  width: 44px; height: 24px;
  background: var(--success);
  border-radius: var(--radius-xl);
  flex-shrink: 0;
  position: relative;
}
.setting-toggle::after {
  content: '';
  position: absolute;
  right: 3px; top: 3px;
  width: 18px; height: 18px;
  background: var(--white);
  border-radius: 50%;
}
.logout-btn {
  display: flex; align-items: center; justify-content: center;
  width: 100%; height: 44px;
  background: var(--white);
  border: none;
  border-radius: var(--radius-xl);
  font-family: var(--font-zh);
  font-weight: 500; font-size: 14px;
  color: var(--error);
  cursor: pointer;
}

/* Scrollbar */
.main-content::-webkit-scrollbar,
.col-left::-webkit-scrollbar, .col-right::-webkit-scrollbar,
.mistake-list::-webkit-scrollbar, .word-list-scroll::-webkit-scrollbar { width: 4px; }
.main-content::-webkit-scrollbar-thumb,
.col-left::-webkit-scrollbar-thumb, .col-right::-webkit-scrollbar-thumb,
.mistake-list::-webkit-scrollbar-thumb, .word-list-scroll::-webkit-scrollbar-thumb {
  background: #C7D2FE;
  border-radius: 2px;
}

/* ===== Learn Page: Word List Scroll ===== */
.word-list-scroll {
  flex: 1;
  overflow-y: auto; overflow-x: hidden;
  display: flex; flex-direction: column;
  gap: 16px;
}

/* ===== Practice Page: Quiz Vocab Tag ===== */
.quiz-vocab-tag {
  display: flex; align-items: center;
  padding: 6px 14px;
  background: var(--bg);
  border-radius: var(--radius-xl);
  font-family: var(--font-zh);
  font-weight: 500; font-size: 13px;
  color: var(--primary);
}

/* ===== Loading Overlay ===== */
.loading-overlay {
  position: fixed;
  inset: 0;
  background: rgba(49, 46, 129, 0.6);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9998;
}
.loading-card {
  background: var(--white);
  border-radius: var(--radius-3xl);
  padding: 40px 48px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  min-width: 360px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.15);
}
.loading-spinner {
  width: 48px; height: 48px;
  border: 4px solid var(--bg);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}
.loading-title {
  font-family: var(--font-zh);
  font-weight: 700; font-size: 18px;
  color: var(--text-dark);
}
.loading-subtitle {
  font-family: var(--font-zh);
  font-weight: 400; font-size: 13px;
  color: var(--text-gray);
  text-align: center;
  max-width: 300px;
  line-height: 1.5;
}
.loading-steps {
  display: flex; flex-direction: column;
  gap: 8px;
  width: 100%;
  margin-top: 8px;
}
.loading-step {
  display: flex; align-items: center;
  gap: 10px;
  font-family: var(--font-zh);
  font-weight: 400; font-size: 13px;
  color: var(--text-placeholder);
}
.step-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #C7D2FE;
  flex-shrink: 0;
  
}
.step-dot.active {
  background: var(--primary);
  box-shadow: 0 0 8px var(--primary-light);
}

/* ===== Toast ===== */
.toast {
  position: fixed;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary-dark);
  color: var(--white);
  padding: 10px 24px;
  border-radius: 20px;
  font-size: 14px;
  z-index: 9999;
  font-family: var(--font-zh);
  animation: toastIn 0.3s ease;
}
@keyframes toastIn {
  from { opacity: 0; transform: translateX(-50%) translateY(10px); }
  to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

/* ===== Stats Grid (profile) ===== */
.stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.stats-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 20px 12px;
  border-radius: var(--radius-lg);
  background: var(--white);
  text-align: center;
}
.stats-block.blue { background: var(--bg-primary-light); }
.stats-block.green { background: var(--bg-success-light); }
.stats-block.orange { background: var(--bg-warning-light); }
.stats-block.purple { background: var(--bg-purple-light); }
.stats-block-icon { font-size: 28px; line-height: 1; }
.stats-block-value {
  font-family: var(--font-en);
  font-weight: 700;
  font-size: 24px;
  line-height: 1.2;
}
.stats-block.blue .stats-block-value { color: var(--primary); }
.stats-block.green .stats-block-value { color: var(--success); }
.stats-block.orange .stats-block-value { color: var(--warning); }
.stats-block.purple .stats-block-value { color: var(--purple); }
.stats-block-label {
  font-family: var(--font-zh);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-gray);
}
@media (max-width: 480px) {
  .stats-grid { gap: 8px; }
  .stats-block { padding: 14px 8px; }
  .stats-block-icon { font-size: 22px; }
  .stats-block-value { font-size: 20px; }
}

/* ============================================================
   Mobile Responsive — ≤ 768px
   ============================================================ */
@media (max-width: 768px) {

  /* ── Layout ── */
  .app-container { flex-direction: column; min-height: 100vh; }

  /* ── Sidebar → Bottom Nav ── */
  .sidebar {
    position: fixed; bottom: 0; left: 0; right: 0;
    width: 100%; height: 60px;
    flex-direction: row; align-items: center;
    padding: 0 8px;
    border-radius: 0;
    border-top: 1px solid var(--border-light);
    z-index: 1000;
    background: var(--white);
  }
  .sidebar .logo-area { display: none; }
  .sidebar .nav-section {
    flex-direction: row; width: 100%;
    justify-content: space-around; gap: 0;
  }
  .sidebar .nav-section .nav-label { display: none; }
  .sidebar .nav-item {
    flex-direction: column; gap: 2px;
    padding: 6px 8px; border-radius: 8px;
    height: auto; min-width: 50px;
  }
  .sidebar .nav-item .nav-text { font-size: 10px; }
  .sidebar .nav-item .nav-icon { width: 22px; height: 22px; border-radius: 6px; }
  .sidebar .nav-item .nav-icon svg { width: 16px; height: 16px; }
  .sidebar .sidebar-footer { display: none; }
  .sidebar .spacer { display: none; }
  .sidebar .user-area { display: none; }

  /* ── Main content ── */
  .main-content { margin-left: 0; padding: 16px; padding-bottom: 96px; overflow-y: auto; overflow-x: hidden; }

  /* ── Top bar ── */
  .top-bar { flex-direction: column; align-items: flex-start; gap: 8px; padding: 12px; }
  .welcome-group { width: 100%; }
  .welcome-title { font-size: 18px; }
  .welcome-sub { font-size: 12px; }
  .streak-badge { align-self: flex-start; }

  /* ── Stats row (home) ── */
  .stats-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
  .stat-card { padding: 14px; }
  .stat-number { font-size: 22px; }

  /* ── Quick actions ── */
  .quick-actions { flex-direction: column; gap: 12px; }
  .quick-actions .action-card { padding: 20px 18px; gap: 12px; height: auto; min-height: 80px; }
  .quick-actions .action-card-title { font-size: 17px; }
  .quick-actions .action-card-desc { font-size: 13px; }
  .quick-actions .action-arrow { width: 36px; height: 36px; font-size: 16px; }

  /* ── Words section ── */
  .words-row { flex-direction: column; }
  .word-card { width: 100%; }

  /* ── Two columns → single ── */
  .two-cols { flex-direction: column; gap: 16px; overflow: visible; }
  .col-left, .col-right { flex: none; width: 100%; overflow: visible; }

  /* ── Learn page ── */
  .grade-selector { height: 40px; }
  .word-list-scroll { max-height: none; overflow: visible; }
  .category-tabs { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 4px; }
  .category-tabs .tab { white-space: nowrap; flex-shrink: 0; }
  .detail-header { padding: 14px; }
  .illust-card { min-height: 100px; }
  /* 词汇列表紧凑 */
  .word-item { padding: 10px 12px; gap: 10px; }
  .word-item-icon { width: 32px; height: 32px; font-size: 14px; }
  .word-item-eng { font-size: 13px; }
  .word-item-chn { font-size: 11px; }
  .word-item-tag { font-size: 10px; padding: 2px 6px; }
  .unit-title { font-size: 14px; }
  .unit-subtitle { font-size: 10px; }
  /* 分析面板 */
  .col-right { margin-top: 8px; }
  .analysis-card { padding: 14px; }
  .analysis-text { font-size: 13px; }
  .cta-btn { width: 100%; justify-content: center; margin-bottom: 32px; }
  .col-right { padding-bottom: 20px; }
  .logout-btn { margin-bottom: 80px; }

  /* ── Practice page ── */
  .main-content.practice-centered { padding: 10px !important; padding-bottom: 96px !important; width: 100%; max-width: 100%; }
  .quiz-card { padding: 14px; display: flex; flex-direction: column; width: 100%; max-width: 100%; }
  .quiz-card .question-text { font-size: 15px; line-height: 1.6; margin-bottom: 8px; word-break: break-word; }
  .quiz-card .scenario-img { min-height: 60px; margin-bottom: 8px; }
  .quiz-card .scenario-img span { font-size: 12px; }
  .quiz-card .quiz-header { flex-wrap: wrap; gap: 4px; margin-bottom: 4px; }
  .quiz-card .quiz-num { font-size: 13px; }
  .quiz-card .progress-track { margin-bottom: 8px; }
  .option { padding: 10px 12px; min-height: 40px; font-size: 13px; gap: 8px; word-break: break-word; }
  .option .option-letter { width: 26px; height: 26px; font-size: 11px; min-width: 26px; }
  /* 底部按钮紧凑一行 */
  .bottom-nav { 
    display: flex; width: 100%; gap: 6px; margin-top: 10px;
    flex-direction: row; flex-wrap: nowrap; flex-shrink: 0;
  }
  .bottom-nav button { 
    flex: 1; min-width: 0; font-size: 11px; padding: 8px 6px;
    white-space: nowrap; justify-content: center; height: 36px;
  }
  .bottom-nav .submit-btn { flex: 1; }
  .bottom-nav .review-btn { flex: 1; }

  /* ── Learn page — force column layout ── */
  .two-cols { flex-direction: column !important; }
  .col-left, .col-right { flex: none !important; width: 100% !important; overflow: visible !important; }
  .col-left { max-height: none !important; }

  /* ── Mistake page ── */
  .stats-mini { flex-wrap: wrap; gap: 10px; }
  .filter-bar { overflow-x: auto; flex-wrap: nowrap; display: flex; gap: 6px; align-items: center; padding-bottom: 4px; }
  .filter-bar .filter-pill { white-space: nowrap; flex-shrink: 0; }
  .filter-bar .filter-spacer { display: none; }
  .filter-bar .retry-all-btn { 
    white-space: nowrap; flex-shrink: 0; 
    font-size: 12px; padding: 6px 12px; margin-left: auto;
  }
  .mistake-list { grid-template-columns: 1fr; }
  .mistake-card { padding: 16px; }
  .answers-row { flex-direction: column; gap: 8px; }
  .card-actions { flex-direction: column; gap: 8px; }
  .card-actions button { width: 100%; justify-content: center; }

  /* ── Profile page ── */
  .profile-card { flex-direction: column; align-items: center; text-align: center; padding: 20px; }
  .profile-stats .stat-row { justify-content: center; }
  .bar-chart { gap: 6px; }
  .bar-col { min-width: 28px; }
  .settings-card { padding: 16px; }
  .setting-item { padding: 12px; }
  .setting-item .setting-icon { width: 32px; height: 32px; }
  .setting-label { font-size: 13px; }
  .setting-value { font-size: 11px; }

  /* ── Breadcrumb ── */
  .breadcrumb { font-size: 12px; }
  .search-box { width: 100%; }
}

/* ===== Mobile: ≤ 480px (small phones) ===== */
@media (max-width: 480px) {
  .main-content { padding: 12px; padding-bottom: 82px; }
  .stats-row { grid-template-columns: 1fr 1fr; gap: 8px; }
  .stat-card { padding: 10px; }
  .stat-number { font-size: 18px; }
  .stat-label { font-size: 11px; }
  .words-title { font-size: 15px; }
  .welcome-title { font-size: 16px; }
  .quiz-card { padding: 12px; width: 100%; max-width: 100%; }
  .question-text { font-size: 14px; }
  .bottom-nav button { font-size: 12px; padding: 8px 10px; }
  .sidebar { height: 52px; }
  .sidebar .nav-item { padding: 4px 6px; }
  .sidebar .nav-item .nav-text { font-size: 9px; }
  .sidebar .nav-item .nav-icon { width: 20px; height: 20px; }
  .sidebar .nav-item .nav-icon svg { width: 15px; height: 15px; }
  .main-content { padding-bottom: 68px; }
  .logout-btn { margin-bottom: 72px; }
}

/* ===== 自定义词汇管理弹窗 ===== */
.vocab-modal-overlay {
  position: fixed; inset: 0; z-index: 1000;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
}
.vocab-modal {
  background: var(--white);
  border-radius: 16px;
  width: 100%; max-width: 440px; max-height: 70vh;
  display: flex; flex-direction: column;
  box-shadow: 0 20px 60px rgba(0,0,0,0.18);
  animation: vocabModalIn 0.25s ease-out;
}
@keyframes vocabModalIn {
  from { opacity: 0; transform: translateY(20px) scale(0.96); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
.vocab-modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 24px 12px;
}
.vocab-modal-header h3 {
  margin: 0; font-size: 17px; font-weight: 700;
  color: var(--text-dark);
}
.vocab-modal-close {
  background: none; border: none; font-size: 22px;
  color: var(--text-gray); cursor: pointer;
  padding: 0; line-height: 1; width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 8px; 
}
.vocab-modal-close:hover { background: #F1F5F9; }
.vocab-modal-body {
  padding: 0 24px 16px; overflow-y: auto; flex: 1;
}
.vocab-modal-empty {
  text-align: center; padding: 32px 16px;
  color: var(--text-gray); font-size: 14px;
}
.vocab-modal-item {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 16px; border-radius: 12px;
  background: var(--bg);
  margin-bottom: 8px;
  
}
.vocab-modal-item:hover { background: #E2E8F0; }
.vocab-modal-item .vmi-vocab {
  flex: 1; font-weight: 600; font-size: 15px;
  color: var(--text-dark); min-width: 0;
}
.vocab-modal-item .vmi-meta {
  font-size: 12px; color: var(--text-gray);
  background: var(--white); padding: 2px 10px;
  border-radius: 20px; white-space: nowrap;
}
.vocab-modal-item .vmi-delete {
  background: none; border: 1px solid #FECACA; color: #EF4444;
  padding: 6px 14px; border-radius: 8px; font-size: 13px;
  cursor: pointer; white-space: nowrap;
  transition: border-color 0.15s, color 0.15s, opacity 0.15s;
}
.vocab-modal-item .vmi-delete:hover {
  background: #FEF2F2; border-color: #EF4444;
}
.vocab-modal-item.vmi-new {
  border-left: 3px solid #16A34A;
  background: #F0FDF4;
  animation: vocabNewPulse 1.5s ease-in-out 2;
}
@keyframes vocabNewPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(22,163,74,0); }
  50%       { box-shadow: 0 0 0 6px rgba(22,163,74,0.15); }
}
.vocab-modal-item .vmi-new-tag {
  font-size: 11px; font-weight: 600;
  color: #16A34A; background: #DCFCE7;
  padding: 2px 8px; border-radius: 10px;
  white-space: nowrap; margin-right: 4px;
}
/* Dark theme new tag */
/* Pink theme new tag */

.vocab-modal-footer {
  padding: 8px 24px 20px;
}
.vocab-add-form {
  display: none; padding: 0 24px 16px;
  border-top: 1px solid var(--border-light, #E2E8F0);
  animation: vocabFormIn 0.2s ease-out;
}
@keyframes vocabFormIn {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}
.vaf-row { margin-bottom: 12px; }
.vaf-row-inline { display: flex; gap: 12px; }
.vaf-row-inline .vaf-field { flex: 1; }
.vaf-label { display: block; font-size: 12px; font-weight: 600; color: var(--text-gray); margin-bottom: 6px; }
.vaf-input {
  width: 100%; padding: 10px 14px; border: 1.5px solid var(--border-light, #E2E8F0);
  border-radius: 10px; font-size: 14px; font-family: var(--font-zh);
  outline: none; transition: border-color 0.2s; box-sizing: border-box;
  background: var(--white); color: var(--text-dark);
}
.vaf-input:focus { border-color: var(--primary); }
.vaf-input.vaf-error { border-color: #EF4444; }
.vaf-hint { font-size: 11px; color: var(--text-placeholder, #94A3B8); margin-top: 4px; }
.vaf-hint.vaf-hint-error { color: #EF4444; }
.vaf-select {
  width: 100%; padding: 10px 12px; border: 1.5px solid var(--border-light, #E2E8F0);
  border-radius: 10px; font-size: 14px; font-family: var(--font-zh);
  outline: none; background: var(--white); color: var(--text-dark);
  box-sizing: border-box; cursor: pointer; appearance: auto;
}
.vaf-select:focus { border-color: var(--primary); }
.vaf-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 4px; }
.vaf-cancel {
  padding: 8px 20px; border: 1.5px solid var(--border-light, #E2E8F0);
  border-radius: 10px; background: var(--white); color: var(--text-gray);
  font-size: 13px; font-weight: 500; cursor: pointer; transition: border-color 0.15s, color 0.15s, opacity 0.15s;
}
.vaf-cancel:hover { background: #F1F5F9; }
.vaf-submit {
  padding: 8px 24px; border: none; border-radius: 10px;
  background: var(--primary); color: #fff;
  font-size: 13px; font-weight: 600; cursor: pointer; transition: border-color 0.15s, color 0.15s, opacity 0.15s;
}
.vaf-submit:hover { background: var(--primary-dark); opacity: 0.9; }
.vaf-submit:disabled { opacity: 0.5; cursor: not-allowed; }
.vocab-modal-add {
  width: 100%; padding: 12px; border: 1px dashed var(--primary-light);
  background: var(--bg-primary-light, #EEF2FF); color: var(--primary);
  font-size: 14px; font-weight: 600; border-radius: 12px;
  cursor: pointer; transition: border-color 0.15s, color 0.15s, opacity 0.15s;
}
.vocab-modal-add:hover {
  background: #E0E7FF; border-color: var(--primary);
}

/* Dark theme modal */

/* Pink theme modal */

/* Mobile modal */
@media (max-width: 480px) {
  .vocab-modal { max-width: 100%; max-height: 85vh; border-radius: 16px 16px 0 0; }
  .vocab-modal-header { padding: 16px 16px 8px; }
  .vocab-modal-body { padding: 0 16px 12px; }
  .vocab-modal-footer { padding: 8px 16px 16px; }
  .vocab-add-form { padding: 0 16px 12px; }
  #choiceModalBody { padding: 8px 16px 16px; }
  #confirmModalBody { padding: 12px 16px 8px; }
}

/* ===== 通用选择弹窗选项 ===== */
.choice-item {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px; margin-bottom: 6px;
  border-radius: 12px; cursor: pointer;
   font-size: 14px; color: var(--text-dark);
}
.choice-item:hover { background: var(--bg-primary-light, #EEF2FF); }
.choice-item.choice-active { background: var(--bg-primary-light, #EEF2FF); font-weight: 600; }
.choice-icon { font-size: 18px; width: 28px; text-align: center; }
.choice-radio {
  margin-left: auto; width: 20px; height: 20px; border-radius: 50%;
  border: 2px solid var(--border-light, #E2E8F0); display: flex; align-items: center; justify-content: center;
  transition: border-color 0.15s;
}
.choice-active .choice-radio { border-color: var(--primary); }
.choice-active .choice-radio::after {
  content: ''; width: 10px; height: 10px; border-radius: 50%; background: var(--primary); display: block;
}

/* ===== 确认弹窗危险按钮 ===== */
.vaf-danger {
  background: #EF4444; border-color: #EF4444;
}
.vaf-danger:hover { background: #DC2626; }

/* ==========================================
   课件版专属样式 — 大字体、高对比度
   ========================================== */

/* ── 首页 ── */
.home-page { max-width: 900px; margin: 0 auto; }

/* ── 词组页工具栏 ── */
.top-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.btn-action {
  padding: 10px 18px; border: 2px solid #E5E7EB; border-radius: 10px;
  background: #fff; font-size: 15px; cursor: pointer; transition: border-color 0.2s, color 0.2s, opacity 0.2s;
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--font-zh, 'PingFang SC'); color: var(--text-dark);
}
.btn-action:hover { background: #F3F4F6; border-color: #D1D5DB; }
.btn-danger-outline { border-color: #FECACA; color: #DC2626; }
.btn-danger-outline:hover { background: #FEF2F2; }

/* ── 词组复选框列表 ── */
.word-item-checkbox {
  display: flex; align-items: center; gap: 12px; padding: 12px 16px;
  border-radius: 10px; cursor: pointer; 
  border: 2px solid transparent; margin-bottom: 4px;
}
.word-item-checkbox:hover { background: #F3F4F6; }
.word-item-checkbox input[type="checkbox"] {
  width: 22px; height: 22px; accent-color: #4F46E5; cursor: pointer; flex-shrink: 0;
}

/* ── 设置页 ── */
.settings-page { max-width: 600px; margin: 0 auto; }
.settings-title { font-size: 28px; margin-bottom: 24px; color: var(--text-dark); }
.settings-list { display: flex; flex-direction: column; gap: 4px; }
.setting-item {
  display: flex; align-items: center; padding: 16px 20px;
  border-radius: 12px; cursor: pointer;
  gap: 16px; border: 2px solid transparent;
}
.setting-item:hover { background: #F3F4F6; }
.setting-item.setting-danger:hover { background: #FEF2F2; }
.setting-info { flex: 1; }
.setting-name { font-size: 17px; font-weight: 600; color: var(--text-dark); display: block; margin-bottom: 2px; }
.setting-desc { font-size: 14px; color: #6B7280; }
.setting-arrow { font-size: 20px; color: #9CA3AF; }

/* ── 模态弹窗 ── */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 1000;
  display: flex; align-items: center; justify-content: center;
}
.modal-box {
  background: #fff; border-radius: 16px; padding: 28px; min-width: 380px;
  max-width: 90vw; box-shadow: 0 20px 60px rgba(0,0,0,0.2);
}
.modal-box h3 { font-size: 22px; margin-bottom: 16px; color: var(--text-dark); }
.modal-box.modal-wide { min-width: 500px; max-width: 80vw; }
.form-group { margin-bottom: 14px; }
.form-group label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 4px; color: #374151; }
.form-group input, .form-group select {
  width: 100%; padding: 10px 14px; border: 2px solid #E5E7EB;
  border-radius: 8px; font-size: 16px; outline: none;
  font-family: var(--font-zh, 'PingFang SC');
}
.form-group input:focus, .form-group select:focus { border-color: #4F46E5; }
.form-row { display: flex; gap: 12px; }
.form-row .form-group { flex: 1; }
.modal-actions { display: flex; gap: 12px; justify-content: flex-end; margin-top: 20px; }

/* ── 按钮通用 ── */
.btn {
  padding: 10px 24px; border-radius: 10px; font-size: 16px; cursor: pointer;
  border: none; font-family: var(--font-zh, 'PingFang SC'); font-weight: 600;
  transition: border-color 0.15s, color 0.15s, opacity 0.15s;
}
.btn-primary { background: #4F46E5; color: #fff; }
.btn-primary:hover { background: #4338CA; }
.btn-secondary { background: #E5E7EB; color: #374151; }
.btn-secondary:hover { background: #D1D5DB; }
.btn-cancel { background: #F3F4F6; color: #6B7280; }
.btn-cancel:hover { background: #E5E7EB; }
.btn-danger { background: #EF4444; color: #fff; }
.btn-danger:hover { background: #DC2626; }

/* ── 选择弹窗选项 ── */
.choice-option {
  padding: 14px 18px; border: 2px solid #E5E7EB; border-radius: 10px;
  margin-bottom: 8px; cursor: pointer; font-size: 16px; color: #374151; transition: border-color 0.15s, color 0.15s, opacity 0.15s;
}
.choice-option:hover { border-color: #A5B4FC; background: #EEF2FF; }
.choice-option.active { border-color: #4F46E5; background: #EEF2FF; font-weight: 600; color: #4F46E5; }

/* ── 练习页设置面板 ── */
.setup-card {
  max-width: 600px; margin: 40px auto; padding: 36px;
  background: #fff; border-radius: 20px; box-shadow: 0 4px 24px rgba(0,0,0,0.06);
}
.setup-title { font-size: 28px; text-align: center; margin-bottom: 28px; color: var(--text-dark); }
.setup-section { margin-bottom: 24px; }
.setup-label { font-size: 17px; font-weight: 600; margin-bottom: 10px; color: var(--text-dark); }
.setup-hint { font-size: 13px; color: #9CA3AF; font-weight: 400; }
.mode-tabs { display: flex; gap: 10px; }
.mode-tab {
  flex: 1; padding: 14px; text-align: center; border: 2px solid #E5E7EB;
  border-radius: 12px; cursor: pointer; font-size: 17px; font-weight: 600;
  transition: border-color 0.2s, color 0.2s, opacity 0.2s;
}
.mode-tab:hover { border-color: #A5B4FC; }
.mode-tab.active { background: #EEF2FF; border-color: #4F46E5; color: #4F46E5; }
.count-chips { display: flex; gap: 10px; flex-wrap: wrap; }
.count-chip {
  padding: 12px 24px; border: 2px solid #E5E7EB; border-radius: 12px;
  cursor: pointer; font-size: 17px; font-weight: 600; transition: border-color 0.2s, color 0.2s, opacity 0.2s;
}
.count-chip:hover { border-color: #A5B4FC; }
.count-chip.active { background: #4F46E5; color: #fff; border-color: #4F46E5; }
.grade-chips { display: flex; gap: 8px; flex-wrap: wrap; }
.grade-chip {
  padding: 8px 16px; border: 2px solid #E5E7EB; border-radius: 10px;
  cursor: pointer; font-size: 14px; transition: border-color 0.2s, color 0.2s, opacity 0.2s;
}
.grade-chip:hover { border-color: #A5B4FC; }
.grade-chip.active { background: #DBEAFE; border-color: #3B82F6; color: #1E40AF; font-weight: 600; }

/* ── 练习页答题区（大字体）── */
.progress-bar { width: 100%; height: 8px; background: #E5E7EB; border-radius: 4px; margin-bottom: 20px; }
.progress-fill { height: 100%; background: #4F46E5; border-radius: 4px; transition: width 0.3s; }
.quiz-top-bar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; flex-wrap: wrap; gap: 12px; }
.quiz-num { font-size: 22px; font-weight: 700; color: var(--text-dark); }
.quiz-vocab { font-size: 16px; color: #6B7280; background: #F3F4F6; padding: 4px 12px; border-radius: 8px; }
.quiz-timer { display: flex; align-items: center; gap: 6px; font-size: 28px; font-weight: 700; color: #F59E0B; }
.question-area { margin-bottom: 28px; }
.question-text { font-size: 26px; font-weight: 600; line-height: 1.6; color: var(--text-dark); margin-bottom: 16px; }
.hint-area { background: #FFFBEB; border: 2px solid #FDE68A; border-radius: 10px; padding: 14px 18px; margin-top: 12px; }
.hint-label { font-size: 16px; font-weight: 600; color: #D97706; }
#questionHint { font-size: 16px; color: #92400E; }
.options-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 24px; }
.option-btn {
  display: flex; align-items: center; gap: 14px; 
  /* padding: 18px 22px; */
  border: 3px solid #E5E7EB; border-radius: 14px; background: #fff;
  cursor: pointer; font-size: 22px; transition: border-color 0.2s, color 0.2s, opacity 0.2s; font-family: var(--font-zh, 'PingFang SC');
  text-align: left; color: var(--text-dark);
}
.option-btn:hover { border-color: #A5B4FC; background: #F5F3FF; }
.option-btn:disabled { cursor: default; }
.option-btn.option-selected { border-color: #4F46E5; background: #EEF2FF; }
.option-btn.option-correct { border-color: #10B981; background: #D1FAE5; color: #065F46; }
.option-btn.option-wrong { border-color: #EF4444; background: #FEE2E2; color: #991B1B; }
.opt-label { font-size: 24px; font-weight: 700; min-width: 36px; text-align: center; }
.opt-text { flex: 1; font-size: 20px; }

.answer-reveal { margin: 20px 0; padding: 20px; background: #F0FDF4; border: 2px solid #BBF7D0; border-radius: 12px; font-size: 18px; line-height: 1.7; }
.answer-reveal .answer-status { font-size: 22px; font-weight: 600; margin-bottom: 8px; }
.answer-reveal .answer-source { font-size: 14px; color: #6B7280; margin-top: 8px; }

.quiz-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; margin-top: 20px; }
.quiz-btn {
  padding: 14px 24px; border: 2px solid #E5E7EB; border-radius: 12px;
  background: #fff; cursor: pointer; font-size: 18px; font-weight: 600;
  transition: border-color 0.2s, color 0.2s, opacity 0.2s; font-family: var(--font-zh, 'PingFang SC');
}
.quiz-btn:hover:not(:disabled) { border-color: #A5B4FC; background: #F5F3FF; }
.quiz-btn:disabled { opacity: 0.4; cursor: default; }
.quiz-btn-primary { background: #4F46E5; color: #fff; border-color: #4F46E5; }
.quiz-btn-primary:hover:not(:disabled) { background: #4338CA; }

/* ── 结果弹窗 ── */
.result-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.6); z-index: 1000; display: flex; align-items: center; justify-content: center; }
.result-card {
  background: #fff; border-radius: 24px; padding: 40px; text-align: center;
  min-width: 360px; max-width: 600px; box-shadow: 0 20px 60px rgba(0,0,0,0.2);
}
.result-icon { font-size: 64px; margin-bottom: 12px; }
.result-title { font-size: 28px; font-weight: 700; margin-bottom: 8px; color: var(--text-dark); }
.result-score { font-size: 48px; font-weight: 800; color: #4F46E5; margin-bottom: 24px; }
.result-detail { display: flex; gap: 20px; justify-content: center; margin-bottom: 28px; }
.result-stat { text-align: center; }
.stat-num { display: block; font-size: 32px; font-weight: 700; }
.stat-label { font-size: 14px; color: #6B7280; }
.result-actions { display: flex; gap: 12px; justify-content: center; }

/* ── 知识点弹窗 ── */
.knowledge-card {
  margin-bottom: 16px; padding: 16px 20px; border-left: 4px solid #4F46E5;
  background: #F5F3FF; border-radius: 8px;
}

/* ── 课堂版 app-edition 标签 ── */
.app-edition {
  display: block; font-size: 11px; color: #818CF8; font-weight: 600;
  text-align: center; margin-top: -4px; letter-spacing: 1px;
}

/* ── 响应式：小屏单列选项 ── */
@media (max-width: 768px) {
  .options-grid { grid-template-columns: 1fr; }
  .question-text { font-size: 20px; }
  .option-btn { font-size: 18px; padding: 14px 16px; }
  .opt-text { font-size: 17px; }
  .quiz-num { font-size: 18px; }
  .modal-box { min-width: auto; width: 90vw; padding: 20px; }
}

/* ============================================================
   Admin 后台 — 复用 App 设计语言（indigo 主色 / 白卡 / #E5E7EB 描边 / token 圆角）
   ============================================================ */

/* 返回首页链接 */
.admin-back {
  font-family: var(--font-zh);
  font-size: 14px; font-weight: 500;
  color: var(--primary);
  text-decoration: none;
  padding: 8px 14px;
  border-radius: var(--radius-lg);
  background: var(--white);
  border: 1px solid #E5E7EB;
  transition: all .18s;
  white-space: nowrap;
}
.admin-back:hover { background: var(--bg-primary-light); border-color: var(--primary-light); }

/* 仪表盘：复用 stats-block，桌面端自适应多列，图标着色与数值同色 */
.admin-stats { grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.admin-stats .stats-block.blue .stats-block-icon { color: var(--primary); }
.admin-stats .stats-block.green .stats-block-icon { color: var(--success); }
.admin-stats .stats-block.orange .stats-block-icon { color: var(--warning); }
.admin-stats .stats-block.purple .stats-block-icon { color: var(--purple); }

/* 工具栏：分段 Tab + 右侧操作按钮 */
.admin-toolbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; flex-wrap: wrap;
}
.admin-tabs {
  display: inline-flex;
  background: var(--white);
  border: 1px solid #E5E7EB;
  border-radius: var(--radius-lg);
  padding: 4px;
  gap: 4px;
}
.admin-tab {
  border: none; background: transparent;
  padding: 8px 18px;
  border-radius: var(--radius-md);
  font-family: var(--font-zh);
  font-size: 14px; font-weight: 500;
  color: var(--text-gray);
  cursor: pointer;
  transition: all .18s;
}
.admin-tab:hover { color: var(--primary); }
.admin-tab.active {
  background: var(--primary);
  color: var(--white);
  font-weight: 600;
}

/* 操作按钮 */
.admin-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.admin-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 9px 16px;
  border: 1px solid #E5E7EB;
  border-radius: var(--radius-lg);
  background: var(--white);
  font-family: var(--font-zh);
  font-size: 14px; font-weight: 500;
  color: var(--text-dark);
  cursor: pointer;
  transition: all .18s;
}
.admin-btn:hover { border-color: var(--primary-light); color: var(--primary); }
.admin-btn.primary {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--white);
}
.admin-btn.primary:hover { background: var(--primary-dark); color: var(--white); }

/* 面板容器（白卡） */
.admin-panel {
  background: var(--white);
  border: 1px solid #E5E7EB;
  border-radius: var(--radius-2xl);
  padding: 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}

/* 表格 */
.admin-table-wrap { overflow-x: auto; }
.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--font-zh);
}
.admin-table thead th {
  text-align: left;
  padding: 12px 14px;
  font-size: 13px; font-weight: 600;
  color: var(--text-gray);
  background: var(--bg-secondary-bg);
  border-bottom: 1px solid #E5E7EB;
  white-space: nowrap;
}
.admin-table thead th:first-child { border-top-left-radius: var(--radius-lg); }
.admin-table thead th:last-child { border-top-right-radius: var(--radius-lg); }
.admin-table tbody td {
  padding: 12px 14px;
  font-size: 14px;
  color: var(--text-dark);
  border-bottom: 1px solid #F1F5F9;
  vertical-align: middle;
}
.admin-table tbody tr:last-child td { border-bottom: none; }
.admin-table tbody tr:hover td { background: var(--bg-secondary-bg); }
.admin-table .u-name { font-weight: 600; color: var(--text-dark); }
.admin-empty {
  text-align: center;
  color: var(--text-placeholder);
  font-size: 14px;
  padding: 32px 12px !important;
}

/* 状态徽标 */
.badge {
  display: inline-flex; align-items: center;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: 12px; font-weight: 600;
  font-family: var(--font-zh);
}
.badge.active { background: var(--bg-success-light); color: var(--success); }
.badge.disabled { background: var(--bg-error-light); color: var(--error); }
.badge.admin { background: var(--bg-primary-light); color: var(--primary); }

/* 行内操作按钮 */
.row-actions { white-space: nowrap; }
.row-btn {
  border: 1px solid #E5E7EB;
  background: var(--white);
  padding: 5px 10px;
  margin-right: 6px;
  border-radius: var(--radius-md);
  font-family: var(--font-zh);
  font-size: 12px; font-weight: 500;
  color: var(--text-body);
  cursor: pointer;
  transition: all .15s;
}
.row-btn:last-child { margin-right: 0; }
.row-btn:hover { border-color: var(--primary-light); color: var(--primary); }
.row-btn.enable { color: var(--success); border-color: #BBF7D0; }
.row-btn.enable:hover { background: var(--bg-success-light); }
.row-btn.disable { color: var(--warning); border-color: #FDE68A; }
.row-btn.disable:hover { background: var(--bg-warning-light); }
.row-btn.danger { color: var(--error); border-color: #FECACA; }
.row-btn.danger:hover { background: var(--bg-error-light); }
.admin-muted { color: var(--text-placeholder); }

/* 薄弱词汇汇总容器 */
.weak-summary {
  display: flex; flex-direction: column; gap: 10px;
  background: var(--white);
  border: 1px solid #E5E7EB;
  border-radius: var(--radius-2xl);
  padding: 16px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}
.weak-count {
  font-family: var(--font-en);
  font-weight: 700; font-size: 14px;
  color: var(--text-gray);
  flex-shrink: 0;
}

/* 学生详情弹窗内容 */
.detail-stats {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 10px; margin-bottom: 8px;
}
.detail-stat {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 14px 8px;
  background: var(--bg-secondary-bg);
  border-radius: var(--radius-lg);
}
.detail-stat .dv {
  font-family: var(--font-en);
  font-weight: 700; font-size: 20px;
  color: var(--primary);
}
.detail-stat .dl {
  font-family: var(--font-zh);
  font-size: 12px; color: var(--text-gray);
}
.detail-section-title {
  font-family: var(--font-zh);
  font-weight: 600; font-size: 14px;
  color: var(--text-dark);
  margin: 16px 0 10px;
}
.detail-mistake {
  border: 1px solid #E5E7EB;
  border-radius: var(--radius-lg);
  padding: 12px;
  margin-bottom: 10px;
}
.dm-q {
  font-family: var(--font-zh);
  font-size: 14px; font-weight: 500;
  color: var(--text-dark);
  margin-bottom: 8px; line-height: 1.5;
}
.dm-meta {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  margin-bottom: 8px;
}
.dm-vocab {
  font-family: var(--font-en);
  font-size: 13px; font-weight: 600; color: var(--primary);
}
.dm-date { font-size: 12px; color: var(--text-placeholder); }
.dm-opts { display: flex; flex-direction: column; gap: 6px; }
.dm-opt {
  font-family: var(--font-zh);
  font-size: 13px;
  color: var(--text-body);
  padding: 6px 10px;
  border-radius: var(--radius-md);
  background: var(--bg-secondary-bg);
}
.dm-opt.ok { background: var(--bg-success-light); color: var(--success-dark); font-weight: 600; }
.dm-opt.bad { background: var(--bg-error-light); color: var(--error); font-weight: 600; }

/* 移动端响应式 */
@media (max-width: 768px) {
  .admin-stats { grid-template-columns: 1fr 1fr; }
  .admin-toolbar { flex-direction: column; align-items: stretch; }
  .admin-tabs { width: 100%; }
  .admin-tab { flex: 1; }
  .admin-actions { width: 100%; }
  .admin-btn { flex: 1; justify-content: center; }
  .detail-stats { grid-template-columns: repeat(2, 1fr); }
}
