@font-face {
  font-family: "KaiZi";
  src: url("assets/kaizi.woff2") format("woff2");
  font-display: swap;
}

:root {
  --ink: #202723;
  --paper: #f5efe3;
  --paper-deep: #e9ddca;
  --cream: #fffaf0;
  --red: #b84230;
  --red-dark: #8f2f24;
  --gold: #c6923f;
  --jade: #447464;
  --jade-light: #dce9df;
  --blue: #5b7181;
  --muted: #6f746d;
  --line: rgba(47, 58, 52, .16);
  --shadow: 0 24px 70px rgba(78, 58, 34, .13);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background:
    radial-gradient(circle at 12% 12%, rgba(198, 146, 63, .12), transparent 24rem),
    linear-gradient(rgba(76, 61, 39, .028) 1px, transparent 1px),
    var(--paper);
  background-size: auto, 100% 24px, auto;
  color: var(--ink);
  font-family: "Avenir Next", "PingFang SC", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
}

button, a { font: inherit; }
button { color: inherit; }
button:focus-visible, a:focus-visible, summary:focus-visible {
  outline: 3px solid rgba(184, 66, 48, .35);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 100;
  transform: translateY(-150%);
  padding: 10px 14px;
  background: var(--ink);
  color: #fff;
}
.skip-link:focus { transform: none; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: 1fr minmax(220px, 440px) 1fr;
  align-items: center;
  gap: 24px;
  min-height: 68px;
  padding: 10px clamp(18px, 4vw, 64px);
  border-bottom: 1px solid var(--line);
  background: rgba(245, 239, 227, .9);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: max-content;
  color: var(--ink);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .15em;
  text-decoration: none;
}
.brand img { width: 31px; height: 31px; object-fit: contain; }

.top-progress { display: flex; align-items: center; gap: 12px; }
.top-progress > span { min-width: 88px; color: var(--muted); font-size: 11px; font-weight: 700; }
.top-progress i {
  overflow: hidden;
  flex: 1;
  height: 7px;
  border-radius: 99px;
  background: rgba(32, 39, 35, .1);
}
.top-progress b {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--red), #e99155);
  transition: width 450ms ease;
}

.quiet-button {
  justify-self: end;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 11px;
  font-weight: 700;
}

main { overflow: hidden; }
.intro, .classic-library, .route, .lesson, .finish-note, footer {
  width: min(1320px, calc(100% - 40px));
  margin-inline: auto;
}

.intro {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(320px, .85fr);
  min-height: 620px;
  border-inline: 1px solid var(--line);
}
.intro-copy {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(48px, 8vw, 110px);
  border-right: 1px solid var(--line);
}
.eyebrow {
  margin: 0 0 18px;
  color: var(--red);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .18em;
  text-transform: uppercase;
}
.intro h1 {
  max-width: 750px;
  margin: 0;
  font-family: KaiZi, "STKaiti", "KaiTi", serif;
  font-size: clamp(46px, 6.1vw, 86px);
  font-weight: 400;
  letter-spacing: -.04em;
  line-height: 1.12;
}
.intro h1 em { color: var(--red); font-style: normal; }
.intro-lead {
  max-width: 610px;
  margin: 32px 0 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.9;
}
.intro-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 38px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .08em;
}
.primary-action {
  display: inline-flex;
  align-items: center;
  gap: 28px;
  padding: 15px 20px;
  border-radius: 5px;
  background: var(--red);
  color: #fff;
  text-decoration: none;
  box-shadow: 0 12px 24px rgba(184, 66, 48, .2);
}
.primary-action span { font-size: 18px; }
.text-action {
  border-bottom: 1px solid var(--ink);
  padding-bottom: 5px;
  color: var(--ink);
  font-size: 11px;
  font-weight: 800;
  text-decoration: none;
}

.intro-art {
  position: relative;
  overflow: hidden;
  min-height: 480px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.2), transparent 50%),
    #d8e1d9;
}
.intro-art::before, .intro-art::after {
  position: absolute;
  right: -12%;
  bottom: -13%;
  width: 118%;
  height: 53%;
  border-radius: 54% 0 0;
  background: #829a8d;
  content: "";
  rotate: -5deg;
}
.intro-art::after {
  right: 32%;
  bottom: -20%;
  background: #526f64;
  rotate: 7deg;
}
.intro-art > strong {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 2;
  transform: translate(-50%, -50%);
  color: rgba(255,255,255,.72);
  font-family: KaiZi, "STKaiti", serif;
  font-size: clamp(180px, 25vw, 360px);
  font-weight: 400;
  line-height: 1;
  text-shadow: 0 14px 40px rgba(41, 72, 61, .12);
}
.sun {
  position: absolute;
  top: 15%;
  right: 14%;
  width: 108px;
  aspect-ratio: 1;
  border-radius: 50%;
  background: #dc7655;
  box-shadow: 0 0 0 28px rgba(255,255,255,.14);
}
.cloud {
  position: absolute;
  z-index: 1;
  width: 150px;
  height: 18px;
  border-radius: 50%;
  background: rgba(255,255,255,.58);
  box-shadow: 36px -12px 0 -2px rgba(255,255,255,.58), 82px 2px 0 -5px rgba(255,255,255,.58);
}
.cloud-one { top: 20%; left: 9%; }
.cloud-two { top: 38%; right: 8%; transform: scale(.7); opacity: .62; }
.seal {
  position: absolute;
  right: 28px;
  bottom: 28px;
  z-index: 4;
  width: 84px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border: 2px solid rgba(255,255,255,.72);
  color: #fff;
  font-family: KaiZi, serif;
  font-size: 15px;
  line-height: 1.25;
  text-align: center;
  rotate: 3deg;
}
.seal b { font-size: 28px; font-weight: 400; }

.classic-library { padding: 120px 0 40px; }
.library-head {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, .65fr);
  gap: 7vw;
  align-items: end;
}
.library-head h2, .grade-copy h2 {
  max-width: 820px;
  margin: 0;
  font-family: KaiZi, "STKaiti", serif;
  font-size: clamp(38px, 5vw, 66px);
  font-weight: 400;
  line-height: 1.18;
}
.profile-progress {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px 20px;
  border-left: 3px solid var(--red);
  padding: 18px 22px;
  background: rgba(255,250,240,.72);
}
.profile-progress span { color: var(--muted); font-size: 10px; font-weight: 800; }
.profile-progress strong { grid-row: span 2; color: var(--red); font-family: Georgia, serif; font-size: 26px; font-weight: 500; }
.profile-progress a { width: max-content; color: var(--ink); font-size: 11px; font-weight: 800; text-decoration: none; }
.library-legend {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  margin-top: 54px;
  border-block: 1px solid var(--line);
  padding: 16px 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.6;
}
.library-legend span { display: flex; align-items: center; gap: 8px; }
.library-legend i { width: 30px; height: 5px; border-radius: 99px; background: linear-gradient(90deg, var(--red) 40%, rgba(32,39,35,.1) 40%); }
.classic-groups { margin-top: 64px; }
.classic-group + .classic-group { margin-top: 78px; }
.classic-group-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 22px;
}
.classic-group-head h3 { margin: 0; font-family: KaiZi, serif; font-size: 31px; font-weight: 400; }
.classic-group-head p { margin: 0; color: var(--muted); font-size: 10px; }
.classic-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.classic-card {
  position: relative;
  overflow: hidden;
  display: flex;
  min-height: 250px;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 24px;
  background: rgba(255,250,240,.74);
  color: var(--ink);
  text-decoration: none;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}
.classic-card:hover { transform: translateY(-4px); border-color: rgba(184,66,48,.5); box-shadow: 0 18px 34px rgba(68,53,34,.1); }
.classic-card::after {
  position: absolute;
  right: -16px;
  bottom: -32px;
  content: attr(data-emoji);
  font-size: 110px;
  filter: grayscale(1);
  opacity: .055;
  rotate: -8deg;
}
.classic-card-top { position: relative; z-index: 1; display: flex; align-items: start; justify-content: space-between; gap: 18px; }
.classic-identity { display: flex; gap: 12px; }
.classic-emoji { font-size: 28px; line-height: 1; }
.classic-card small { color: var(--red); font-size: 8px; font-weight: 900; letter-spacing: .12em; }
.classic-card h4 { margin: 5px 0 0; font-family: KaiZi, serif; font-size: 29px; font-weight: 400; }
.classic-count { color: var(--muted); font-family: Georgia, serif; font-size: 10px; text-align: right; white-space: nowrap; }
.classic-count b { display: block; color: var(--ink); font-size: 17px; font-weight: 500; }
.classic-desc { position: relative; z-index: 1; margin: 22px 0 0; color: var(--muted); font-size: 11px; line-height: 1.65; }
.classic-quote { position: relative; z-index: 1; margin: auto 0 0; padding-top: 20px; color: #665947; font-family: KaiZi, serif; font-size: 15px; line-height: 1.55; }
.classic-progress { position: relative; z-index: 1; display: grid; grid-template-columns: 1fr auto; gap: 8px 12px; align-items: center; margin-top: 18px; }
.classic-progress i { overflow: hidden; height: 6px; border-radius: 99px; background: rgba(32,39,35,.09); }
.classic-progress i b { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--red), #e89a62); }
.classic-progress span { color: var(--jade); font-size: 9px; font-weight: 900; }
.classic-progress em { grid-column: 1 / -1; color: var(--muted); font-size: 9px; font-style: normal; }
.classic-card.is-culture-reading small::after { content: " · 文化阅读"; color: var(--jade); }

.grade-library {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(460px, 1.1fr);
  gap: 7vw;
  align-items: center;
  margin-top: 100px;
  padding: clamp(42px, 6vw, 78px);
  border-radius: 9px;
  background: #29322e;
  color: #fff;
}
.grade-copy .eyebrow { color: #ecad76; }
.grade-copy h2 { font-size: clamp(34px, 4vw, 54px); }
.grade-copy > p:last-child { margin: 24px 0 0; color: rgba(255,255,255,.58); font-size: 12px; line-height: 1.8; }
.grade-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 9px; }
.grade-card {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 6px;
  padding: 15px;
  background: rgba(255,255,255,.045);
  color: #fff;
  text-decoration: none;
  transition: background 180ms ease, border-color 180ms ease;
}
.grade-card:hover { border-color: rgba(236,173,118,.5); background: rgba(255,255,255,.08); }
.grade-card strong { font-family: KaiZi, serif; font-size: 19px; font-weight: 400; }
.grade-card span { color: rgba(255,255,255,.48); font-size: 9px; }
.grade-card i { grid-column: 1 / -1; overflow: hidden; height: 4px; border-radius: 99px; background: rgba(255,255,255,.1); }
.grade-card i b { display: block; height: 100%; background: #e7a56f; }

.route { padding: 110px 0; }
.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 42px;
}
.section-heading h2, .finish-note h2 {
  margin: 0;
  font-family: KaiZi, "STKaiti", serif;
  font-size: clamp(32px, 4vw, 54px);
  font-weight: 400;
  line-height: 1.25;
}
.section-heading > p { margin: 0; color: var(--muted); font-size: 12px; }
.section-heading > p strong { color: var(--red); font-family: Georgia, serif; font-size: 36px; }

.poem-route {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
.route-card {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: 116px 1fr;
  gap: 18px;
  min-height: 150px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255,250,240,.68);
  text-align: left;
  cursor: pointer;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}
.route-card:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(69,55,36,.09); }
.route-card.is-active { border-color: var(--red); }
.route-card.is-passed::after {
  position: absolute;
  right: 10px;
  bottom: 8px;
  content: "通\A关";
  white-space: pre;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 2px solid var(--red);
  color: var(--red);
  font-family: KaiZi, serif;
  font-size: 13px;
  line-height: 1;
  text-align: center;
  rotate: -9deg;
}
.route-card img {
  width: 116px;
  height: 116px;
  border-radius: 5px;
  object-fit: cover;
}
.route-card-copy { align-self: center; min-width: 0; }
.route-card small { color: var(--red); font-size: 9px; font-weight: 900; letter-spacing: .12em; }
.route-card h3 { margin: 9px 0 5px; font-family: KaiZi, serif; font-size: 26px; font-weight: 400; }
.route-card p { margin: 0; color: var(--muted); font-size: 11px; }
.card-meter { margin-top: 15px; color: var(--jade); font-size: 10px; font-weight: 800; }

.lesson {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(520px, 1fr);
  align-items: start;
  border: 1px solid var(--line);
  background: var(--cream);
  box-shadow: var(--shadow);
}
.lesson-visual { position: sticky; top: 88px; min-height: 700px; }
.lesson-visual img { display: block; width: 100%; min-height: 700px; object-fit: cover; }
.visual-caption {
  position: absolute;
  right: 22px;
  bottom: 22px;
  left: 22px;
  padding: 17px 20px;
  border: 1px solid rgba(255,255,255,.35);
  border-radius: 6px;
  background: rgba(28, 35, 32, .78);
  color: #fff;
  backdrop-filter: blur(10px);
}
.visual-caption span { color: #efc57f; font-size: 9px; font-weight: 900; letter-spacing: .15em; }
.visual-caption p { margin: 6px 0 0; font-size: 13px; line-height: 1.7; }

.lesson-panel { padding: clamp(34px, 5vw, 70px); }
.lesson-heading { display: flex; justify-content: space-between; gap: 20px; }
.lesson-heading h2 { margin: 0; font-family: KaiZi, serif; font-size: clamp(46px, 5vw, 70px); font-weight: 400; }
.lesson-heading > div > p:last-child { margin: 5px 0 0; color: var(--muted); font-size: 13px; }
.lesson-status {
  align-self: start;
  border: 1px solid var(--line);
  border-radius: 99px;
  padding: 7px 11px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
}
.lesson-status.is-passed { border-color: rgba(68,116,100,.35); background: var(--jade-light); color: var(--jade); }

.lesson-tools { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 30px; }
.lesson-tools button, .quiet-button, footer button {
  border: 1px solid var(--line);
  border-radius: 99px;
  padding: 9px 13px;
  background: transparent;
  cursor: pointer;
  font-size: 10px;
  font-weight: 800;
}
.lesson-tools button[aria-pressed="true"] { border-color: rgba(68,116,100,.3); background: var(--jade-light); color: var(--jade); }

.poem-text { display: grid; gap: 22px; margin-top: 42px; }
.poem-line { display: flex; justify-content: center; align-items: end; gap: clamp(4px, .65vw, 10px); }
.poem-char {
  position: relative;
  min-width: clamp(44px, 4.7vw, 64px);
  border: 0;
  border-bottom: 1px solid rgba(32,39,35,.14);
  padding: 25px 2px 6px;
  background: transparent;
  cursor: pointer;
  font-family: KaiZi, "STKaiti", serif;
  font-size: clamp(31px, 3.6vw, 47px);
  line-height: 1;
  transition: color 160ms ease, background 160ms ease, transform 160ms ease;
}
.poem-char::before {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  content: attr(data-pinyin);
  color: var(--blue);
  font-family: "Avenir Next", sans-serif;
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
}
.poem-char:hover { color: var(--red); transform: translateY(-2px); }
.poem-char.is-known { color: var(--jade); background: linear-gradient(transparent 66%, rgba(68,116,100,.12) 66%); }
.poem-char.is-known::after {
  position: absolute;
  right: -2px;
  bottom: 4px;
  content: "·";
  color: var(--red);
  font-family: sans-serif;
  font-size: 22px;
}
.poem-text.hide-pinyin .poem-char { padding-top: 7px; }
.poem-text.hide-pinyin .poem-char::before { display: none; }
.poem-punctuation { align-self: end; padding-bottom: 7px; font-family: KaiZi, serif; font-size: 34px; }
.poem-text.is-blind .poem-char { color: transparent; text-shadow: 0 0 11px rgba(32,39,35,.28); }
.poem-text.is-blind .poem-char::before { display: none; }
.tap-hint { margin: 22px 0 0; color: var(--muted); font-size: 11px; line-height: 1.7; text-align: center; }

.word-card {
  display: grid;
  grid-template-columns: 74px 1fr 42px;
  align-items: center;
  gap: 18px;
  margin-top: 32px;
  padding: 18px;
  border: 1px solid rgba(68,116,100,.2);
  border-radius: 7px;
  background: #edf2eb;
}
.word-char {
  display: grid;
  width: 74px;
  aspect-ratio: 1;
  place-items: center;
  border: 1px solid rgba(68,116,100,.25);
  background:
    linear-gradient(45deg, transparent 49.5%, rgba(68,116,100,.1) 50%, transparent 50.5%),
    linear-gradient(-45deg, transparent 49.5%, rgba(68,116,100,.1) 50%, transparent 50.5%);
  color: var(--jade);
  font-family: KaiZi, serif;
  font-size: 50px;
}
.word-card p { margin: 0; }
.word-pinyin { color: var(--red); font-size: 12px; font-weight: 800; }
.word-card strong { display: block; margin: 4px 0; font-family: KaiZi, serif; font-size: 22px; font-weight: 400; }
.word-card div p:last-child { color: var(--muted); font-size: 11px; line-height: 1.55; }
.word-card button { width: 42px; aspect-ratio: 1; border: 1px solid var(--line); border-radius: 50%; background: var(--cream); cursor: pointer; }

.meaning-card { margin-top: 18px; border-block: 1px solid var(--line); padding: 19px 0; }
.meaning-card summary { cursor: pointer; font-family: KaiZi, serif; font-size: 21px; }
.meaning-card > p { color: var(--muted); font-size: 12px; line-height: 1.85; }
.key-words { display: flex; flex-wrap: wrap; gap: 7px; }
.key-words span { border-radius: 99px; padding: 7px 10px; background: var(--paper-deep); color: #6c5e49; font-size: 10px; }

.quiz { margin-top: 38px; padding: 26px; border-radius: 8px; background: #292f2c; color: #fff; }
.quiz .eyebrow { color: #efb279; }
.quiz h3 { margin: 0; font-family: KaiZi, serif; font-size: 25px; font-weight: 400; line-height: 1.45; }
.quiz-options { display: grid; gap: 8px; margin-top: 20px; }
.quiz-options button {
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 5px;
  padding: 12px 14px;
  background: rgba(255,255,255,.05);
  color: #fff;
  cursor: pointer;
  font-size: 12px;
  text-align: left;
}
.quiz-options button:hover { background: rgba(255,255,255,.1); }
.quiz-options button.is-correct { border-color: #91c7aa; background: rgba(80,145,108,.24); }
.quiz-options button.is-wrong { border-color: #e88770; background: rgba(184,66,48,.24); }
.quiz-feedback { min-height: 1.5em; margin: 15px 0 0; color: rgba(255,255,255,.72); font-size: 11px; line-height: 1.6; }
.next-button {
  width: 100%;
  margin-top: 12px;
  border: 0;
  border-radius: 6px;
  padding: 14px;
  background: var(--red);
  color: #fff;
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
}

.finish-note {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 9vw;
  align-items: end;
  padding: 130px 0;
}
.finish-note > p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.9; }

footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 90px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .12em;
}

.celebration {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: none;
  place-items: center;
  pointer-events: none;
  background: rgba(245,239,227,.44);
}
.celebration.is-visible { display: grid; animation: fade-celebration 1400ms both; }
.celebration > span {
  display: grid;
  width: 150px;
  aspect-ratio: 1;
  place-items: center;
  border: 6px double var(--red);
  color: var(--red);
  font-family: KaiZi, serif;
  font-size: 88px;
  rotate: -7deg;
  animation: stamp-in 650ms cubic-bezier(.2,1.6,.4,1) both;
}
.celebration i {
  position: absolute;
  width: 12px;
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--gold);
  animation: spark 900ms ease-out both;
}
.celebration i:nth-of-type(1) { translate: -120px -100px; }
.celebration i:nth-of-type(2) { translate: 130px -60px; background: var(--red); }
.celebration i:nth-of-type(3) { translate: -145px 50px; background: var(--jade); }
.celebration i:nth-of-type(4) { translate: 110px 110px; }
.celebration i:nth-of-type(5) { translate: 15px -150px; background: var(--blue); }
@keyframes stamp-in { from { opacity: 0; scale: 1.8; } to { opacity: 1; scale: 1; } }
@keyframes spark { from { opacity: 0; scale: 0; } 50% { opacity: 1; } to { opacity: 0; scale: 2; } }
@keyframes fade-celebration { 0%, 80% { opacity: 1; } 100% { opacity: 0; } }

@media (max-width: 1060px) {
  .classic-grid { grid-template-columns: repeat(2, 1fr); }
  .grade-library { grid-template-columns: 1fr; }
  .poem-route { grid-template-columns: 1fr; }
  .route-card { grid-template-columns: 92px 1fr; min-height: 116px; }
  .route-card img { width: 92px; height: 92px; }
  .lesson { grid-template-columns: 1fr; }
  .lesson-visual { position: relative; top: auto; min-height: 520px; }
  .lesson-visual img { height: min(80vw, 720px); min-height: 520px; }
}

@media (max-width: 760px) {
  .topbar { grid-template-columns: 1fr auto; gap: 10px; padding-inline: 14px; }
  .top-progress { grid-column: 1 / -1; grid-row: 2; padding-bottom: 5px; }
  .quiet-button span, .brand span { display: none; }
  .intro, .classic-library, .route, .lesson, .finish-note, footer { width: min(100% - 24px, 1320px); }
  .intro { grid-template-columns: 1fr; min-height: auto; }
  .intro-copy { order: 2; padding: 46px 24px 60px; border-top: 1px solid var(--line); border-right: 0; }
  .intro-art { min-height: 330px; }
  .intro h1 { font-size: clamp(42px, 13vw, 65px); }
  .route { padding: 76px 0; }
  .classic-library { padding-top: 82px; }
  .library-head { grid-template-columns: 1fr; gap: 28px; }
  .library-legend { align-items: start; flex-direction: column; }
  .classic-grid { grid-template-columns: 1fr; }
  .classic-card { min-height: 230px; }
  .grade-library { margin-top: 72px; padding: 34px 22px; }
  .grade-grid { grid-template-columns: 1fr; }
  .section-heading { align-items: start; }
  .section-heading > p { white-space: nowrap; }
  .route-card { grid-template-columns: 84px 1fr; }
  .route-card img { width: 84px; height: 84px; }
  .route-card h3 { font-size: 23px; }
  .lesson-visual, .lesson-visual img { min-height: 410px; }
  .lesson-panel { padding: 38px 20px; }
  .poem-line { gap: 2px; }
  .poem-char { min-width: 17.5%; font-size: clamp(28px, 10vw, 42px); }
  .word-card { grid-template-columns: 60px 1fr 38px; gap: 12px; padding: 14px; }
  .word-char { width: 60px; font-size: 40px; }
  .finish-note { grid-template-columns: 1fr; gap: 30px; padding: 85px 0; }
}

@media (max-width: 420px) {
  .intro-actions { align-items: start; flex-direction: column; }
  .section-heading { flex-direction: column; gap: 15px; }
  .lesson-heading h2 { font-size: 50px; }
  .lesson-status { display: none; }
  .lesson-tools button { flex: 1; }
  .poem-char { padding-inline: 0; font-size: 29px; }
  .word-card { grid-template-columns: 56px 1fr; }
  .word-char { width: 56px; }
  .word-card button { display: none; }
  .profile-progress { grid-template-columns: 1fr; }
  .profile-progress strong { grid-row: auto; }
  .classic-group-head { align-items: start; flex-direction: column; gap: 4px; }
  .classic-card { padding: 20px; }
  footer { flex-direction: column; justify-content: center; gap: 12px; }
}

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