/* =========================================================
   森谷英语 Sunny English · style.css
   移动优先 · 断点 460 / 768 / 1024 px
   纯 class 选择器 · 无 !important
   ========================================================= */

/* ---------- 设计变量 ---------- */
:root {
  --green-900: #1b5e20;
  --green-700: #2e7d32;
  --green-500: #43a047;
  --green-100: #e8f5e9;
  --teal-700: #00796b;
  --cream: #faf7ef;
  --surface: #ffffff;
  --border: #e9e3d5;
  --text: #26332b;
  --text-muted: #5c6b5a;
  --orange-600: #bf360c;
  --danger-700: #c62828;
  --danger-900: #b71c1c;
  --radius-lg: 16px;
  --radius-md: 12px;
  --radius-pill: 999px;
  --shadow-sm: 0 2px 8px rgba(27, 94, 32, 0.07);
  --shadow-md: 0 10px 28px rgba(27, 94, 32, 0.12);
  --shadow-lg: 0 18px 44px rgba(27, 94, 32, 0.16);
  --header-h: 64px;
}

/* ---------- 全局 ---------- */
.site,
.site *,
.site *::before,
.site *::after {
  box-sizing: border-box;
}

.site {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto,
    "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background: var(--cream);
  color: var(--text);
  line-height: 1.65;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

.site :focus-visible {
  outline: 3px solid var(--green-900);
  outline-offset: 2px;
  border-radius: 4px;
}

.site-header :focus-visible {
  outline-color: #ffffff;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: -999px;
  z-index: 100;
  padding: 10px 18px;
  font-weight: 700;
  background: var(--green-900);
  color: #ffffff;
  border-radius: 0 0 10px 0;
}

.skip-link:focus-visible {
  left: 0;
  top: 0;
}

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

.anchor {
  scroll-margin-top: calc(var(--header-h) + 8px);
}

/* ---------- 顶栏 + 汉堡菜单 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  min-height: var(--header-h);
  background: linear-gradient(135deg, #1b5e20 0%, #2e7d32 55%, #00796b 100%);
  color: #ffffff;
  box-shadow: var(--shadow-sm);
}

.header-bar {
  position: relative;
  max-width: 1080px;
  margin: 0 auto;
  min-height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: #ffffff;
}

.logo-emoji {
  font-size: 1.5rem;
}

.logo-text {
  font-size: 1.2rem;
  font-weight: 800;
  letter-spacing: 1px;
}

.logo-sub {
  align-self: flex-end;
  margin-bottom: 3px;
  font-size: 0.68rem;
  letter-spacing: 0.5px;
  opacity: 0.92;
}

.nav-toggle {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.nav-toggle-btn {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 10px;
  border-radius: 10px;
  cursor: pointer;
}

.nav-toggle-btn:hover {
  background: rgba(255, 255, 255, 0.15);
}

.nav-toggle:focus-visible ~ .nav-toggle-btn {
  outline: 3px solid #ffffff;
  outline-offset: 2px;
}

.burger-bar {
  display: block;
  width: 22px;
  height: 3px;
  border-radius: 2px;
  background: #ffffff;
  transition: transform 0.25s ease, opacity 0.2s ease;
}

.nav-toggle:checked ~ .nav-toggle-btn .burger-bar:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.nav-toggle:checked ~ .nav-toggle-btn .burger-bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle:checked ~ .nav-toggle-btn .burger-bar:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

.site-nav {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  left: 12px;
  right: 12px;
  flex-direction: column;
  gap: 4px;
  padding: 10px;
  background: var(--surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

.nav-toggle:checked ~ .site-nav {
  display: flex;
}

.nav-link {
  display: block;
  padding: 12px 14px;
  font-weight: 600;
  color: var(--green-900);
  text-decoration: none;
  border-radius: var(--radius-md);
}

.nav-link:hover {
  background: var(--green-100);
}

.nav-link:active {
  transform: scale(0.98);
}

/* ---------- 通用区块 ---------- */
.section {
  padding: 48px 20px;
}

.section-inner {
  max-width: 1080px;
  margin: 0 auto;
}

.section-head {
  max-width: 640px;
  margin: 0 auto 30px;
  text-align: center;
}

.section-tag {
  display: inline-block;
  margin: 0 0 8px;
  padding: 4px 14px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--orange-600);
  background: #ffe9d6;
  border-radius: var(--radius-pill);
}

.section-title {
  margin: 0 0 8px;
  font-size: 1.6rem;
  color: var(--green-900);
}

.section-desc {
  margin: 0;
  font-size: 0.95rem;
  color: var(--text-muted);
}

.section-note {
  margin: 18px 0 0;
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 22px;
  font: inherit;
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.4;
  color: var(--text);
  text-decoration: none;
  background: var(--surface);
  border: 2px solid transparent;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease,
    background 0.15s ease, border-color 0.15s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn:active {
  transform: translateY(0);
}

.btn-primary {
  background: linear-gradient(135deg, var(--green-700), var(--teal-700));
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(46, 125, 50, 0.28);
}

.btn-primary:hover {
  box-shadow: 0 8px 20px rgba(46, 125, 50, 0.34);
}

.btn-ghost {
  background: var(--surface);
  color: var(--green-900);
  border-color: var(--green-700);
}

.btn-ghost:hover {
  background: var(--green-100);
}

.btn-lg {
  padding: 14px 30px;
  font-size: 1.05rem;
}

.btn-round {
  width: 52px;
  height: 52px;
  padding: 0;
  font-size: 1.05rem;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--green-700), var(--teal-700));
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(46, 125, 50, 0.28);
}

.btn-round:hover {
  box-shadow: 0 8px 20px rgba(46, 125, 50, 0.34);
}

.btn-preview {
  padding: 5px 14px;
  font-size: 0.82rem;
  background: var(--surface);
  color: var(--green-900);
  border-color: var(--green-700);
}

.btn-preview:hover {
  background: var(--green-100);
}

.btn-download {
  padding: 5px 14px;
  font-size: 0.82rem;
  background: linear-gradient(135deg, var(--green-700), var(--teal-700));
  color: #ffffff;
}

.btn-download:hover {
  box-shadow: 0 4px 12px rgba(46, 125, 50, 0.3);
}

.btn:disabled {
  cursor: default;
  opacity: 0.55;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: 56px 20px 64px;
  text-align: center;
  background:
    radial-gradient(120% 90% at 90% 10%, rgba(255, 183, 77, 0.35) 0%, rgba(255, 183, 77, 0) 55%),
    linear-gradient(160deg, #e8f5e9 0%, #faf7ef 55%, #e0f2f1 100%);
}

.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 720px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-block;
  margin: 0 0 14px;
  padding: 6px 16px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--green-900);
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(46, 125, 50, 0.25);
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-sm);
}

.hero-title {
  margin: 0 0 12px;
  font-size: 2.1rem;
  line-height: 1.25;
  letter-spacing: 1px;
}

.hero-accent {
  color: var(--green-700);
  border-bottom: 4px solid #ffb74d;
  padding-bottom: 2px;
}

.hero-desc {
  max-width: 560px;
  margin: 0 auto 26px;
  font-size: 1.02rem;
  color: var(--text-muted);
}

.hero-deco {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero-deco-emoji {
  position: absolute;
  font-size: 2rem;
  animation: hero-float 6s ease-in-out infinite;
}

.deco-a {
  top: 18%;
  left: 8%;
}

.deco-b {
  top: 12%;
  right: 10%;
  animation-delay: -2s;
}

.deco-c {
  bottom: 16%;
  left: 14%;
  font-size: 1.6rem;
  animation-delay: -4s;
}

.deco-d {
  right: 12%;
  bottom: 20%;
  font-size: 1.7rem;
  animation-delay: -1s;
}

@keyframes hero-float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-12px);
  }
}

/* ---------- 学习板块卡片 ---------- */
.feature-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.feature-card {
  padding: 26px 22px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.feature-card:hover {
  transform: translateY(-6px);
  border-color: var(--green-100);
  box-shadow: var(--shadow-md);
}

.feature-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  font-size: 1.8rem;
  border-radius: 18px;
  background: linear-gradient(135deg, var(--green-100), #d7eee8);
}

.feature-title {
  margin: 14px 0 6px;
  font-size: 1.15rem;
  color: var(--green-900);
}

.feature-desc {
  margin: 0 0 12px;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.feature-link {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--green-700);
}

/* ---------- 闪卡（3D 翻转） ---------- */
.fc-wrap {
  max-width: 460px;
  margin: 0 auto;
}

.flashcard-area {
  perspective: 1100px;
  margin-bottom: 22px;
}

.flashcard {
  position: relative;
  width: 100%;
  height: 300px;
}

.flashcard-inner {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  transition: transform 0.6s cubic-bezier(0.4, 0.1, 0.2, 1);
}

.flashcard.is-flipped .flashcard-inner {
  transform: rotateY(180deg);
}

.card-face {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 24px;
  border-radius: 20px;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  box-shadow: var(--shadow-md);
}

.card-face-front {
  background: linear-gradient(145deg, #2e7d32, #00796b);
  color: #ffffff;
}

.card-face-back {
  background: var(--surface);
  border: 3px solid var(--green-100);
  color: var(--green-900);
  transform: rotateY(180deg);
}

.card-emoji {
  font-size: 3.2rem;
}

.card-word {
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: 1px;
  text-align: center;
  word-break: break-word;
}

.card-word-zh {
  color: var(--green-700);
}

.card-hint {
  font-size: 0.85rem;
}

.card-face-front .card-hint {
  color: var(--green-100);
}

.fc-tools {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.fc-controls {
  display: flex;
  align-items: center;
  gap: 14px;
}

.fc-count {
  margin: 0;
  padding: 4px 16px;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--green-900);
  background: var(--green-100);
  border-radius: var(--radius-pill);
}

.fc-progress {
  width: 100%;
  height: 10px;
  overflow: hidden;
  background: var(--border);
  border-radius: var(--radius-pill);
}

.fc-progress-bar {
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, var(--green-500), var(--teal-700));
  border-radius: inherit;
  transition: width 0.3s ease;
}

/* ---------- 词汇测验 ---------- */
.test-card {
  max-width: 560px;
  margin: 0 auto;
  padding: 26px 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.test-question {
  margin: 0 0 18px;
  font-size: 1.02rem;
  font-weight: 600;
}

.test-word {
  padding: 2px 10px;
  color: var(--green-700);
  background: var(--green-100);
  border-radius: 8px;
}

.options {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.option {
  min-height: 52px;
  padding: 12px 18px;
  font: inherit;
  font-size: 1rem;
  font-weight: 600;
  text-align: left;
  color: var(--text);
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: transform 0.15s ease, border-color 0.15s ease,
    background 0.15s ease, box-shadow 0.15s ease;
}

.option:hover:not(:disabled) {
  transform: translateY(-2px);
  border-color: var(--green-500);
}

.option:active:not(:disabled) {
  transform: translateY(0);
}

.option.correct {
  color: var(--green-900);
  background: var(--green-100);
  border-color: var(--green-700);
}

.option.wrong {
  color: var(--danger-900);
  background: #fdecea;
  border-color: var(--danger-700);
}

.option:disabled {
  cursor: default;
}

.test-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 18px;
}

.test-score {
  margin: 0;
  padding: 6px 16px;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--green-900);
  background: var(--green-100);
  border-radius: var(--radius-pill);
}

/* ---------- 绘本阅读 ---------- */
.reading-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.book-card {
  padding: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.book-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

.book-cover {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 3 / 4;
  margin-bottom: 12px;
  font-size: 3.4rem;
  border-radius: var(--radius-md);
  background: linear-gradient(150deg, #ffe0b2, #ffcc80);
  overflow: hidden;
}

.book-card:nth-child(3n + 2) .book-cover {
  background: linear-gradient(150deg, #b3e5fc, #81d4fa);
}

.book-card:nth-child(3n + 3) .book-cover {
  background: linear-gradient(150deg, #c8e6c9, #a5d6a7);
}

.book-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius-md);
}

.book-title {
  margin: 0 0 4px;
  font-size: 1rem;
  color: var(--green-900);
}

.book-desc {
  margin: 0;
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* ---------- 语法园地 ---------- */
.grammar-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.grammar-card {
  margin: 0;
  padding: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.grammar-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

.grammar-thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 4 / 3;
  font-size: 3rem;
  border-radius: var(--radius-md);
  background: linear-gradient(145deg, #e0f2f1, #b2dfdb);
  overflow: hidden;
}

.grammar-card:nth-child(2n) .grammar-thumb {
  background: linear-gradient(145deg, #fce4ec, #f8bbd0);
}

.grammar-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius-md);
}

.grammar-caption {
  margin: 10px 4px 2px;
  font-size: 0.9rem;
  font-weight: 700;
  text-align: center;
  color: var(--green-900);
}

/* ---------- 资源库 ---------- */
.library-panel {
  padding: 22px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.search-input {
  width: 100%;
  padding: 14px 18px;
  font: inherit;
  font-size: 1rem;
  color: var(--text);
  background: var(--cream);
  border: 2px solid var(--border);
  border-radius: var(--radius-pill);
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.search-input:focus-visible {
  background: var(--surface);
  border-color: var(--green-700);
  box-shadow: 0 0 0 4px rgba(46, 125, 50, 0.18);
}

.search-input::placeholder {
  color: #8a947f;
}

.status-bar {
  margin: 14px 0 10px;
  font-size: 0.88rem;
  color: var(--text-muted);
}

.category-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.category-card {
  background: var(--cream);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: box-shadow 0.2s ease;
}

.category-card.is-open {
  box-shadow: var(--shadow-sm);
}

.category-head {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 15px 16px;
  font: inherit;
  color: inherit;
  text-align: left;
  background: none;
  border: none;
  cursor: pointer;
}

.category-name {
  margin: 0;
  font-size: 1.02rem;
  font-weight: 700;
  color: var(--green-900);
}

.category-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.category-count {
  padding: 3px 12px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--green-900);
  background: var(--green-100);
  border-radius: var(--radius-pill);
}

.category-arrow {
  font-size: 0.75rem;
  color: var(--text-muted);
  transition: transform 0.2s ease;
}

.category-card.is-open .category-arrow {
  transform: rotate(180deg);
}

.file-list {
  list-style: none;
  margin: 0;
  padding: 0 16px 14px;
}

.file-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  padding: 11px 0;
  border-top: 1px solid var(--border);
}

.file-name {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  font-size: 0.9rem;
  word-break: break-all;
}

.file-icon {
  flex-shrink: 0;
  padding: 1px 7px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--green-700);
  background: var(--green-100);
  border-radius: 6px;
}

.file-size {
  flex-shrink: 0;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.file-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

.category-empty {
  padding: 10px 0 12px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.no-match {
  padding: 44px 0;
  text-align: center;
  color: var(--text-muted);
}

/* ---------- 使用说明 ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.about-card {
  padding: 22px 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.about-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  margin-bottom: 10px;
  font-size: 0.95rem;
  font-weight: 800;
  color: #ffffff;
  background: linear-gradient(135deg, var(--green-700), var(--teal-700));
  border-radius: 50%;
}

.about-title {
  margin: 0 0 6px;
  font-size: 1.05rem;
  color: var(--green-900);
}

.about-desc {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* ---------- 页脚 ---------- */
.site-footer {
  padding: 34px 20px;
  text-align: center;
  color: var(--green-100);
  background: linear-gradient(135deg, #1b5e20, #2e7d32);
}

.footer-inner {
  max-width: 1080px;
  margin: 0 auto;
}

.footer-brand {
  margin: 0 0 6px;
  font-size: 1.05rem;
  font-weight: 800;
  color: #ffffff;
}

.footer-meta {
  margin: 4px 0 0;
  font-size: 0.8rem;
}

/* ---------- 预览对话框 ---------- */
.preview-dialog {
  width: min(92vw, 860px);
  max-height: 82vh;
  padding: 0;
  color: var(--text);
  background: var(--surface);
  border: none;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

.preview-dialog::backdrop {
  background: rgba(27, 62, 30, 0.5);
}

.preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  background: var(--cream);
  border-bottom: 1px solid var(--border);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.preview-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--green-900);
  word-break: break-all;
}

.preview-close {
  padding: 6px 16px;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--green-900);
  background: var(--surface);
  border: 2px solid var(--green-700);
  border-radius: var(--radius-pill);
  cursor: pointer;
}

.preview-close:hover {
  background: var(--green-100);
}

.preview-body {
  margin: 0;
  padding: 18px;
  max-height: 60vh;
  overflow: auto;
  font-size: 0.85rem;
  white-space: pre-wrap;
  word-break: break-all;
}

.preview-media {
  padding: 18px;
}

.preview-media img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
}

/* =========================================================
   断点 460px
   ========================================================= */
@media (min-width: 460px) {
  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .reading-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .grammar-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* =========================================================
   断点 768px
   ========================================================= */
@media (min-width: 768px) {
  .section {
    padding: 64px 24px;
  }

  .nav-toggle,
  .nav-toggle-btn {
    display: none;
  }

  .site-nav {
    position: static;
    display: flex;
    flex-direction: row;
    gap: 2px;
    padding: 0;
    background: none;
    box-shadow: none;
  }

  .nav-link {
    padding: 8px 12px;
    font-size: 0.95rem;
    color: #ffffff;
  }

  .nav-link:hover {
    background: rgba(255, 255, 255, 0.14);
  }

  .hero {
    padding: 88px 24px 96px;
  }

  .hero-title {
    font-size: 2.9rem;
  }

  .hero-deco-emoji {
    font-size: 2.6rem;
  }

  .flashcard {
    height: 320px;
  }

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

  .category-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
  }

  .about-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* =========================================================
   断点 1024px
   ========================================================= */
@media (min-width: 1024px) {
  .section {
    padding: 76px 24px;
  }

  .feature-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
  }

  .reading-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
  }

  .grammar-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
  }

  .category-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .search-input {
    max-width: 460px;
  }

  .library-panel {
    padding: 26px 24px;
  }
}

/* ---------- 减弱动态效果 ---------- */
@media (prefers-reduced-motion: reduce) {
  .site *,
  .site *::before,
  .site *::after {
    animation-duration: 0.01ms;
    animation-iteration-count: 1;
    transition-duration: 0.01ms;
  }
}