/* ===== Reset & Base ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --red: #c0392b;
  --red-light: #e74c3c;
  --red-pale: #fdecea;
  --gold: #d4a017;
  --gold-light: #f1c40f;
  --dark: #1a202c;
  --mid: #4a5568;
  --muted: #718096;
  --border: #e2e8f0;
  --bg: #f7f8fc;
  --white: #ffffff;
  --green: #27ae60;
  --blue: #2980b9;
  --purple: #8e44ad;
  --orange: #e67e22;
  --teal: #16a085;
  --radius: 12px;
  --shadow: 0 2px 16px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.12);
}

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', 'Helvetica Neue', sans-serif;
  background: var(--bg);
  color: var(--dark);
  line-height: 1.7;
}

/* ===== Typography ===== */
h1, h2, h3, h4 { font-weight: 700; line-height: 1.3; }
h1 { font-size: clamp(1.8rem, 4vw, 2.8rem); }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.35rem); }
h4 { font-size: 1.05rem; }
p { margin-bottom: 0.8rem; }

/* ===== Navbar ===== */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  border-bottom: 2px solid var(--red);
  box-shadow: var(--shadow);
}
.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}
.nav-logo {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--red);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.nav-logo img { width: 32px; height: 32px; object-fit: contain; border-radius: 6px; }
.nav-links {
  display: flex;
  gap: 0.25rem;
  list-style: none;
  flex-wrap: wrap;
}
.nav-links a {
  text-decoration: none;
  color: var(--mid);
  font-size: 0.88rem;
  font-weight: 500;
  padding: 0.4rem 0.7rem;
  border-radius: 6px;
  transition: all 0.2s;
}
.nav-links a:hover { background: var(--red-pale); color: var(--red); }
.nav-toggle { display: none; background: none; border: none; cursor: pointer; font-size: 1.5rem; color: var(--dark); }

/* ===== Hero ===== */
.hero {
  background: linear-gradient(135deg, #1a0a0a 0%, #7b1414 40%, #c0392b 100%);
  color: white;
  padding: 5rem 1.5rem 4rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -50px; right: -50px;
  width: 300px; height: 300px;
  background: rgba(255,255,255,0.04);
  border-radius: 50%;
}
.hero::after {
  content: '';
  position: absolute;
  bottom: -80px; left: -80px;
  width: 400px; height: 400px;
  background: rgba(255,255,255,0.03);
  border-radius: 50%;
}
.hero-badge {
  display: inline-block;
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.25);
  color: #ffd700;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 0.35rem 1rem;
  border-radius: 50px;
  margin-bottom: 1.2rem;
  letter-spacing: 1px;
  text-transform: uppercase;
}
.hero h1 { color: white; margin-bottom: 1rem; }
.hero-sub {
  font-size: 1.1rem;
  color: rgba(255,255,255,0.8);
  margin-bottom: 2.5rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}
.hero-stats {
  display: flex;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}
.hero-stat {
  background: rgba(255,255,255,0.12);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: var(--radius);
  padding: 1rem 1.5rem;
  text-align: center;
  min-width: 100px;
}
.hero-stat-num { font-size: 2rem; font-weight: 800; color: #ffd700; display: block; }
.hero-stat-label { font-size: 0.8rem; color: rgba(255,255,255,0.75); }
.hero-btns { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }
.btn {
  display: inline-block;
  padding: 0.75rem 1.8rem;
  border-radius: 50px;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.25s;
  cursor: pointer;
  border: none;
}
.btn-primary { background: #ffd700; color: #1a0a0a; }
.btn-primary:hover { background: white; transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,0.25); }
.btn-outline { background: transparent; color: white; border: 2px solid rgba(255,255,255,0.6); }
.btn-outline:hover { background: rgba(255,255,255,0.15); transform: translateY(-2px); }

/* ===== Section Container ===== */
.section { padding: 4rem 1.5rem; }
.section-alt { background: white; }
.container { max-width: 1100px; margin: 0 auto; }

.section-header { text-align: center; margin-bottom: 3rem; }
.section-tag {
  display: inline-block;
  background: var(--red-pale);
  color: var(--red);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.3rem 0.9rem;
  border-radius: 50px;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 0.75rem;
}
.section-header h2 { color: var(--dark); margin-bottom: 0.5rem; }
.section-header p { color: var(--muted); font-size: 1.05rem; max-width: 580px; margin: 0 auto; }

/* ===== Cards ===== */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}
.card {
  background: white;
  border-radius: var(--radius);
  padding: 1.8rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  transition: transform 0.2s, box-shadow 0.2s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.card-icon { font-size: 2.2rem; margin-bottom: 1rem; }
.card h3 { margin-bottom: 0.5rem; color: var(--dark); }
.card p { color: var(--muted); font-size: 0.93rem; margin: 0; }

/* ===== Exam Format Table ===== */
.format-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}
.format-card {
  background: white;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}
.format-header {
  padding: 1.2rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}
.format-header.reading { background: linear-gradient(135deg, #2980b9, #1a6fa8); color: white; }
.format-header.video { background: linear-gradient(135deg, #c0392b, #a93226); color: white; }
.format-header-icon { font-size: 2rem; }
.format-header-info h3 { color: white; font-size: 1.1rem; }
.format-header-info span { color: rgba(255,255,255,0.8); font-size: 0.85rem; }
.format-body { padding: 1.5rem; }
.format-body ul { list-style: none; }
.format-body li {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  font-size: 0.93rem;
  color: var(--mid);
}
.format-body li:last-child { border-bottom: none; }
.format-body li::before { content: '✓'; color: var(--green); font-weight: 700; flex-shrink: 0; margin-top: 0.1rem; }

.marks-bar {
  background: #f0f4f8;
  border-radius: var(--radius);
  padding: 1.5rem;
  margin: 2rem 0;
}
.marks-row { display: flex; align-items: center; gap: 1rem; margin-bottom: 1rem; }
.marks-row:last-child { margin-bottom: 0; }
.marks-label { font-size: 0.88rem; font-weight: 600; color: var(--dark); min-width: 100px; }
.marks-track { flex: 1; background: #dde3ea; border-radius: 50px; height: 12px; overflow: hidden; }
.marks-fill { height: 100%; border-radius: 50px; transition: width 1s ease; }
.marks-fill.blue { background: linear-gradient(90deg, #2980b9, #3498db); }
.marks-fill.red { background: linear-gradient(90deg, #c0392b, #e74c3c); }
.marks-num { font-weight: 700; color: var(--dark); font-size: 0.9rem; min-width: 60px; text-align: right; }

/* ===== Timeline / Process ===== */
.timeline {
  position: relative;
  padding-left: 2rem;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 0.6rem;
  top: 0; bottom: 0;
  width: 3px;
  background: linear-gradient(to bottom, var(--red), var(--gold));
  border-radius: 2px;
}
.timeline-item {
  position: relative;
  padding: 0 0 2rem 2rem;
}
.timeline-dot {
  position: absolute;
  left: -1.95rem;
  top: 0.25rem;
  width: 1.3rem;
  height: 1.3rem;
  border-radius: 50%;
  background: white;
  border: 3px solid var(--red);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.6rem;
  font-weight: 700;
  color: var(--red);
}
.timeline-content {
  background: white;
  border-radius: var(--radius);
  padding: 1.2rem 1.5rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}
.timeline-time {
  display: inline-block;
  background: var(--red-pale);
  color: var(--red);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.2rem 0.6rem;
  border-radius: 50px;
  margin-bottom: 0.5rem;
}
.timeline-content h4 { margin-bottom: 0.4rem; }
.timeline-content p { margin: 0; color: var(--muted); font-size: 0.9rem; }

/* ===== Accordion (Topics) ===== */
.topic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1rem;
}
.accordion-item {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: box-shadow 0.2s;
}
.accordion-item.open { box-shadow: var(--shadow-lg); }
.accordion-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.1rem 1.3rem;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  transition: background 0.2s;
}
.accordion-btn:hover { background: #fafafa; }
.accordion-icon { font-size: 1.6rem; flex-shrink: 0; width: 56px; height: 56px; object-fit: cover; border-radius: 8px; }
.accordion-title { flex: 1; }
.accordion-title h4 { font-size: 0.97rem; color: var(--dark); margin: 0; }
.accordion-title span { font-size: 0.78rem; color: var(--muted); }
.accordion-arrow {
  font-size: 1rem;
  color: var(--muted);
  transition: transform 0.3s;
  flex-shrink: 0;
}
.accordion-item.open .accordion-arrow { transform: rotate(180deg); }
.accordion-body {
  display: none;
  padding: 0 1.3rem 1.3rem;
  border-top: 1px solid var(--border);
}
.accordion-item.open .accordion-body { display: block; }

.vocab-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0.8rem 0;
}
.chip {
  background: var(--red-pale);
  color: var(--red);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.25rem 0.7rem;
  border-radius: 50px;
  border: 1px solid rgba(192,57,43,0.2);
}
.chip.blue { background: #ebf5fb; color: var(--blue); border-color: rgba(41,128,185,0.2); }
.chip.green { background: #eafaf1; color: var(--green); border-color: rgba(39,174,96,0.2); }
.chip.purple { background: #f5eef8; color: var(--purple); border-color: rgba(142,68,173,0.2); }

.sample-qa { margin-top: 0.8rem; }
.sample-q {
  background: #f0f4f8;
  border-left: 3px solid var(--blue);
  border-radius: 0 8px 8px 0;
  padding: 0.7rem 1rem;
  margin-bottom: 0.4rem;
  font-size: 0.88rem;
  color: var(--dark);
  font-weight: 500;
}
.sample-q::before { content: '❓ '; }
.sample-a {
  background: #f0fdf4;
  border-left: 3px solid var(--green);
  border-radius: 0 8px 8px 0;
  padding: 0.7rem 1rem;
  margin-bottom: 0.8rem;
  font-size: 0.85rem;
  color: var(--mid);
  line-height: 1.6;
}
.sample-a::before { content: '💡 参考思路：'; font-weight: 600; color: var(--green); display: block; margin-bottom: 0.3rem; }

/* ===== Tips Cards ===== */
.tips-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}
.tips-section {
  background: white;
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}
.tips-section h3 {
  color: var(--dark);
  margin-bottom: 1.2rem;
  padding-bottom: 0.8rem;
  border-bottom: 2px solid var(--border);
  display: flex;
  align-items: center;
  gap: 0.7rem;
}
.tip-item {
  display: flex;
  gap: 0.8rem;
  margin-bottom: 1rem;
  align-items: flex-start;
}
.tip-num {
  background: var(--red);
  color: white;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 0.1rem;
}
.tip-text { font-size: 0.9rem; color: var(--mid); line-height: 1.6; }
.tip-text strong { color: var(--dark); }

/* ===== Phrases / Vocab ===== */
.phrases-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.5rem;
}
.phrase-card {
  background: white;
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}
.phrase-card h4 {
  font-size: 0.88rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 1rem;
  padding-bottom: 0.6rem;
  border-bottom: 2px solid var(--border);
}
.phrase-card h4.red { color: var(--red); border-color: var(--red); }
.phrase-card h4.blue { color: var(--blue); border-color: var(--blue); }
.phrase-card h4.green { color: var(--green); border-color: var(--green); }
.phrase-card h4.gold { color: var(--gold); border-color: var(--gold); }
.phrase-card h4.purple { color: var(--purple); border-color: var(--purple); }
.phrase-list { list-style: none; }
.phrase-list li {
  padding: 0.45rem 0;
  border-bottom: 1px dashed var(--border);
  font-size: 0.88rem;
  color: var(--mid);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
}
.phrase-list li:last-child { border-bottom: none; }
.phrase-cn { font-weight: 600; color: var(--dark); }
.phrase-note { font-size: 0.75rem; color: var(--muted); font-style: italic; }

/* ===== Practice Section ===== */
.practice-tabs { display: flex; gap: 0.5rem; margin-bottom: 1.5rem; flex-wrap: wrap; }
.tab-btn {
  padding: 0.55rem 1.2rem;
  border-radius: 50px;
  border: 2px solid var(--border);
  background: white;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--mid);
  cursor: pointer;
  transition: all 0.2s;
}
.tab-btn.active { background: var(--red); border-color: var(--red); color: white; }
.tab-btn:hover:not(.active) { border-color: var(--red); color: var(--red); }
.tab-content { display: none; }
.tab-content.active { display: block; }
.practice-card {
  background: white;
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}
.practice-scene {
  background: linear-gradient(135deg, #f0f4f8, #e8edf4);
  border-radius: 8px;
  padding: 1.2rem;
  margin-bottom: 1.5rem;
  border-left: 4px solid var(--blue);
}
.practice-scene h4 { color: var(--blue); font-size: 0.88rem; text-transform: uppercase; margin-bottom: 0.5rem; }
.practice-scene p { margin: 0; color: var(--mid); font-size: 0.92rem; }
.qa-item { margin-bottom: 1.5rem; }
.qa-q {
  font-weight: 700;
  color: var(--dark);
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
}
.qa-q::before { content: 'Q:'; color: var(--red); font-size: 0.85rem; margin-top: 0.15rem; flex-shrink: 0; }
.qa-a {
  background: #f9f9fb;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1rem 1.2rem;
  font-size: 0.88rem;
  color: var(--mid);
  line-height: 1.8;
}
.qa-label { font-weight: 700; color: var(--green); font-size: 0.78rem; display: block; margin-bottom: 0.4rem; }
.highlight-phrase {
  background: #fff3cd;
  color: #856404;
  padding: 0 3px;
  border-radius: 3px;
  font-weight: 600;
}

/* ===== Study Plan ===== */
.plan-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.5rem;
}
.plan-card {
  background: white;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}
.plan-header {
  padding: 1rem 1.3rem;
  color: white;
  font-weight: 700;
  font-size: 0.95rem;
}
.plan-header.week1 { background: linear-gradient(135deg, #2980b9, #1a6fa8); }
.plan-header.week2 { background: linear-gradient(135deg, #8e44ad, #7d3c98); }
.plan-header.week3 { background: linear-gradient(135deg, #16a085, #117a65); }
.plan-header.week4 { background: linear-gradient(135deg, #d35400, #b7440e); }
.plan-header.exam { background: linear-gradient(135deg, #c0392b, #a93226); }
.plan-body { padding: 1rem 1.3rem; }
.plan-body ul { list-style: none; }
.plan-body li {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  padding: 0.3rem 0;
  font-size: 0.87rem;
  color: var(--mid);
}
.plan-body li::before { content: '•'; color: var(--red); font-weight: 700; flex-shrink: 0; }

/* ===== Scoring Rubric ===== */
.rubric-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.rubric-table th {
  background: var(--dark);
  color: white;
  padding: 0.8rem 1rem;
  text-align: left;
  font-size: 0.85rem;
}
.rubric-table th:first-child { width: 25%; }
.rubric-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
  font-size: 0.87rem;
  color: var(--mid);
  vertical-align: top;
}
.rubric-table tr:last-child td { border-bottom: none; }
.rubric-table tr:nth-child(even) td { background: #fafbfc; }
.score-badge {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 700;
  color: white;
}
.score-A { background: #27ae60; }
.score-B { background: #2980b9; }
.score-C { background: #f39c12; }
.score-D { background: #e74c3c; }

/* ===== Callout Boxes ===== */
.callout {
  border-radius: var(--radius);
  padding: 1.2rem 1.5rem;
  margin: 1.5rem 0;
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}
.callout-icon { font-size: 1.4rem; flex-shrink: 0; margin-top: 0.1rem; }
.callout-body h4 { font-size: 0.9rem; margin-bottom: 0.3rem; }
.callout-body p { font-size: 0.88rem; margin: 0; color: var(--mid); }
.callout.warning { background: #fff8e1; border-left: 4px solid #f39c12; }
.callout.warning h4 { color: #e67e22; }
.callout.info { background: #ebf5fb; border-left: 4px solid #2980b9; }
.callout.info h4 { color: #2980b9; }
.callout.success { background: #eafaf1; border-left: 4px solid #27ae60; }
.callout.success h4 { color: #27ae60; }
.callout.tip { background: #f5eef8; border-left: 4px solid #8e44ad; }
.callout.tip h4 { color: #8e44ad; }

/* ===== Stats Banner ===== */
.stats-banner {
  background: linear-gradient(135deg, #1a202c, #2d3748);
  color: white;
  padding: 3rem 1.5rem;
}
.stats-banner .container { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 2rem; }
.stat-item { text-align: center; }
.stat-num { font-size: 2.2rem; font-weight: 800; color: #ffd700; display: block; }
.stat-label { font-size: 0.85rem; color: rgba(255,255,255,0.7); margin-top: 0.2rem; }

/* ===== Footer ===== */
footer {
  background: #1a202c;
  color: rgba(255,255,255,0.65);
  padding: 2.5rem 1.5rem 1.5rem;
  text-align: center;
  font-size: 0.85rem;
}
.footer-inner { max-width: 900px; margin: 0 auto; }
.footer-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.footer-logo {
  width: 52px;
  height: 52px;
  object-fit: contain;
  border-radius: 10px;
}
.footer-brand-text { text-align: left; }
.footer-brand-name { font-size: 1.15rem; font-weight: 800; color: #fff; letter-spacing: .02em; }
.footer-brand-tagline { font-size: .76rem; color: rgba(255,255,255,.45); margin-top: .1rem; }
footer strong { color: white; }
footer .footer-links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin: 0 0 1.5rem;
  flex-wrap: wrap;
}
footer .footer-links a { color: rgba(255,255,255,0.45); text-decoration: none; transition: color 0.2s; }
footer .footer-links a:hover { color: white; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding-top: 1rem;
  margin-top: .5rem;
}
.footer-bottom p { margin: .3rem 0; font-size: .76rem; color: rgba(255,255,255,.35); }
.footer-bottom a { color: rgba(255,255,255,.45); text-decoration: underline; }
.footer-bottom a:hover { color: rgba(255,255,255,.75); }

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 60px;
    left: 0; right: 0;
    background: white;
    padding: 1rem;
    box-shadow: var(--shadow-lg);
    z-index: 99;
  }
  .nav-toggle { display: block; }
  .format-grid, .tips-grid { grid-template-columns: 1fr; }
  .topic-grid { grid-template-columns: 1fr; }
  .hero-stats { gap: 1rem; }
  .hero-stat { padding: 0.75rem 1rem; }
}

/* ===== Animations ===== */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
.fade-up { animation: fadeUp 0.5s ease forwards; }

/* ===== Progress indicator ===== */
.progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--red), var(--gold));
  z-index: 200;
  transition: width 0.1s;
}

/* ===== Back to top ===== */
.back-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background: var(--red);
  color: white;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-size: 1.2rem;
  box-shadow: 0 4px 12px rgba(192,57,43,0.4);
  opacity: 0;
  transition: opacity 0.3s, transform 0.2s;
  transform: translateY(10px);
}
.back-top.visible { opacity: 1; transform: translateY(0); }
.back-top:hover { background: var(--red-light); }

/* ===== Topic filter ===== */
.filter-bar {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}
.filter-btn {
  padding: 0.4rem 1rem;
  border-radius: 50px;
  border: 1.5px solid var(--border);
  background: white;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: all 0.2s;
}
.filter-btn.active { background: var(--red); border-color: var(--red); color: white; }
.filter-btn:hover:not(.active) { border-color: var(--red); color: var(--red); }

/* ===== CLB Reading Passages ===== */
.reading-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}
@media (max-width: 768px) {
  .reading-grid { grid-template-columns: 1fr; }
}
.reading-card {
  background: white;
  border-radius: 14px;
  padding: 1.5rem;
  box-shadow: 0 2px 12px rgba(0,0,0,0.07);
  border: 1px solid #e5e7eb;
  display: flex;
  flex-direction: column;
}
.reading-badge {
  display: inline-block;
  background: #fef2f2;
  color: var(--red);
  border: 1px solid #fecaca;
  border-radius: 50px;
  padding: 0.18rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  margin-bottom: 0.6rem;
  width: fit-content;
}
.reading-title {
  color: var(--dark);
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.9rem;
}
.reading-passage {
  font-size: 1.02rem;
  line-height: 2;
  color: #374151;
  flex: 1;
  margin-bottom: 1rem;
}
.reading-passage rt {
  display: none;
  font-size: 0.62em;
  color: #6b7280;
  letter-spacing: 0;
}
.reading-passage.show-pinyin {
  line-height: 2.8;
}
.reading-passage.show-pinyin rt {
  display: block;
}
.pinyin-btn {
  align-self: flex-start;
  background: transparent;
  border: 1.5px solid var(--red);
  color: var(--red);
  padding: 0.35rem 1rem;
  border-radius: 50px;
  font-size: 0.83rem;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.2s;
  font-family: inherit;
}
.pinyin-btn:hover,
.pinyin-btn.active {
  background: var(--red);
  color: white;
}
