:root {
  --ink: #173c3b;
  --ink-soft: #4f6662;
  --muted: #7b8b87;
  --green: #2f7b6d;
  --green-deep: #1d5f55;
  --green-soft: #dfeee6;
  --mint: #9ccbb0;
  --cream: #f5f0e6;
  --paper: #fffdf8;
  --white: #ffffff;
  --orange: #e97958;
  --orange-soft: #f7ddd2;
  --yellow: #f2bd4b;
  --yellow-soft: #f9eabd;
  --blue: #6c9db2;
  --blue-soft: #dfeef3;
  --red: #c95e51;
  --red-soft: #f9e3df;
  --line: #e8e3d8;
  --shadow-sm: 0 8px 26px rgba(44, 72, 65, .07);
  --shadow-md: 0 20px 55px rgba(44, 72, 65, .11);
  --serif: "Noto Serif SC", "Songti SC", "STSong", "SimSun", serif;
  --sans: "Noto Sans SC", "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", sans-serif;
  --radius-lg: 28px;
  --radius-md: 20px;
  --radius-sm: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  background: var(--cream);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body.menu-open {
  overflow: hidden;
}

button,
input,
select {
  color: inherit;
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  border: 0;
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
}

a {
  color: inherit;
  text-decoration: none;
}

svg {
  display: block;
}

[hidden] {
  display: none !important;
}

::selection {
  color: var(--ink);
  background: var(--yellow-soft);
}

:focus-visible {
  outline: 3px solid rgba(47, 123, 109, .42);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 12px;
  left: 12px;
  padding: 10px 16px;
  border-radius: 10px;
  color: white;
  background: var(--green-deep);
  transform: translateY(-150%);
}

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

.home-view {
  display: flex;
  flex-direction: column;
}

.home-view > .home-topline {
  order: 0;
}

.home-view > .home-lower-grid {
  order: 1;
  margin-top: 12px;
}

.home-view > .home-plan-panel {
  order: 2;
  margin-top: 20px;
}

.home-view > .reading-tip {
  order: 3;
}

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

.sidebar {
  position: sticky;
  z-index: 30;
  top: 0;
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow-y: auto;
  padding: 27px 20px 20px;
  background:
    radial-gradient(circle at 20% 0%, rgba(255, 255, 255, .74), transparent 34%),
    #fffdf8;
  border-right: 1px solid rgba(29, 95, 85, .08);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  margin: 0 8px 39px;
}

.brand-mark {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 15px;
  background: var(--green);
  box-shadow: 0 8px 18px rgba(47, 123, 109, .22);
}

.brand-mark svg {
  width: 37px;
  height: 37px;
}

.brand-copy {
  display: flex;
  align-items: baseline;
  gap: 3px;
  letter-spacing: .02em;
}

.brand-copy strong {
  font-family: var(--serif);
  font-size: 24px;
  font-weight: 800;
}

.brand-copy small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .12em;
  writing-mode: vertical-rl;
}

.main-nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.nav-item {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border-radius: 14px;
  color: #62736f;
  background: transparent;
  gap: 12px;
  text-align: left;
  transition: color .2s ease, background .2s ease, transform .2s ease;
}

.nav-item:hover {
  color: var(--ink);
  background: #f2f6f1;
}

.nav-item.is-active {
  color: var(--green-deep);
  background: var(--green-soft);
  font-weight: 700;
}

.nav-item.is-active::before {
  position: absolute;
  left: -20px;
  width: 4px;
  height: 23px;
  border-radius: 0 4px 4px 0;
  background: var(--green);
  content: "";
}

.nav-item svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.nav-item span:nth-child(2) {
  flex: 1;
}

.nav-subnav {
  display: grid;
  margin: -2px 0 3px 21px;
  padding: 4px 0 5px 10px;
  border-left: 1px solid #dce6df;
  gap: 3px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.nav-subitem {
  min-width: 0;
  min-height: 31px;
  padding: 5px 7px;
  border-radius: 8px;
  color: #73817d;
  background: transparent;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.25;
  text-align: left;
  white-space: nowrap;
}

.nav-subitem:hover {
  color: var(--green-deep);
  background: #edf4ee;
}

.nav-subitem.is-active {
  color: var(--green-deep);
  background: #dfeee3;
  font-weight: 800;
}

.nav-dot {
  width: 6px;
  height: 6px;
  flex: 0 0 auto !important;
  border-radius: 50%;
  background: var(--orange);
}

.soon-badge {
  flex: 0 0 auto !important;
  padding: 2px 7px;
  border-radius: 20px;
  color: #998f7d;
  background: #f1eee6;
  font-size: 12px;
  font-weight: 500;
}

.sidebar-bottom {
  display: flex;
  flex-direction: column;
  gap: 13px;
  margin-top: auto;
}

.daily-mini {
  display: flex;
  align-items: center;
  padding: 14px;
  border-radius: 18px;
  color: white;
  background:
    radial-gradient(circle at 90% 0%, rgba(255, 255, 255, .15), transparent 43%),
    var(--green);
  gap: 11px;
}

.mini-orbit {
  position: relative;
  width: 48px;
  height: 48px;
  flex: 0 0 auto;
}

.mini-orbit svg {
  width: 48px;
  height: 48px;
}

.mini-orbit span {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 800;
}

.daily-mini strong {
  font-size: 13px;
  font-weight: 700;
}

.daily-mini p {
  margin: 2px 0 0;
  color: rgba(255, 255, 255, .76);
  font-size: 12px;
}

.profile-button {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 9px;
  border-radius: 17px;
  background: transparent;
  gap: 10px;
  text-align: left;
}

.profile-button:hover {
  background: #f3f2ec;
}

.avatar {
  display: grid;
  width: 37px;
  height: 37px;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid #eed9a4;
  border-radius: 13px;
  color: #866628;
  background: #faeecb;
  font-family: var(--serif);
  font-weight: 800;
}

.profile-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

.profile-copy strong {
  overflow: hidden;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-copy small {
  color: var(--muted);
  font-size: 12px;
}

.profile-button > svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: #93a09d;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.page-column {
  display: flex;
  min-width: 0;
  min-height: 100vh;
  flex-direction: column;
}

.mobile-header {
  display: none;
}

main {
  width: 100%;
  max-width: 1480px;
  margin: 0 auto;
  padding: 36px 43px 20px;
  flex: 1;
}

.view {
  animation: view-in .45s ease both;
}

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

.home-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.date-line {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  letter-spacing: .02em;
}

.streak-chip {
  display: flex;
  align-items: center;
  padding: 7px 12px;
  border: 1px solid rgba(242, 189, 75, .3);
  border-radius: 30px;
  color: #80662a;
  background: #fdf5dc;
  gap: 6px;
  font-size: 12px;
}

.streak-chip span {
  color: var(--yellow);
  font-size: 14px;
}

.streak-chip strong {
  font-size: 14px;
}

.hero-card {
  position: relative;
  display: grid;
  min-height: 380px;
  overflow: hidden;
  border-radius: 32px;
  color: #fffdf6;
  background:
    radial-gradient(circle at 73% 23%, rgba(154, 208, 172, .28), transparent 23%),
    linear-gradient(123deg, #1c5f56 0%, #2c776b 56%, #4c907c 100%);
  grid-template-columns: 1.03fr .97fr;
  box-shadow: 0 22px 55px rgba(31, 91, 82, .19);
}

.hero-card::before {
  position: absolute;
  top: -68px;
  left: 51%;
  width: 420px;
  height: 420px;
  border: 1px solid rgba(255, 255, 255, .09);
  border-radius: 50%;
  content: "";
}

.hero-card::after {
  position: absolute;
  top: 30px;
  right: 40%;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--yellow);
  box-shadow: 40px 44px 0 -2px rgba(255, 255, 255, .5);
  content: "";
}

.hero-copy {
  z-index: 2;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 50px 0 39px 51px;
  flex-direction: column;
}

.eyebrow {
  display: flex;
  align-items: center;
  margin: 0 0 15px;
  color: #dceee4;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .12em;
}

.eyebrow span {
  width: 21px;
  height: 1px;
  margin-right: 9px;
  background: var(--yellow);
}

.hero-copy h1 {
  max-width: 580px;
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(36px, 3.8vw, 55px);
  font-weight: 800;
  letter-spacing: .02em;
  line-height: 1.22;
}

.hero-copy h1 em {
  position: relative;
  color: #f8d075;
  font-style: normal;
}

.hero-copy h1 em::after {
  position: absolute;
  right: 2px;
  bottom: -4px;
  left: 1px;
  height: 6px;
  border-radius: 50%;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 8' preserveAspectRatio='none'%3E%3Cpath d='M2 6C50 0 150 0 198 4' fill='none' stroke='%23f2bd4b' stroke-width='2'/%3E%3C/svg%3E") center/100% 100% no-repeat;
  opacity: .7;
  content: "";
}

.hero-lead {
  max-width: 440px;
  margin: 18px 0 24px;
  color: rgba(255, 255, 255, .72);
  font-size: 14px;
  line-height: 1.9;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 20px;
}

.primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 21px;
  border-radius: 14px;
  color: var(--green-deep);
  background: #fffdf7;
  gap: 11px;
  font-size: 14px;
  font-weight: 800;
  box-shadow: 0 8px 22px rgba(14, 54, 49, .14);
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.primary-button:hover {
  background: white;
  box-shadow: 0 12px 26px rgba(14, 54, 49, .21);
  transform: translateY(-2px);
}

.primary-button:active {
  transform: translateY(0);
}

.primary-button svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.hero-actions .primary-button {
  color: #264e46;
  background: #f7cc6d;
}

.hero-actions .primary-button:hover {
  background: #fbd987;
}

.text-button {
  padding: 8px 0;
  color: rgba(255, 255, 255, .8);
  background: transparent;
  font-size: 13px;
  text-decoration: underline;
  text-decoration-color: rgba(255, 255, 255, .35);
  text-underline-offset: 5px;
}

.text-button:hover {
  color: white;
}

.hero-stats {
  display: flex;
  align-items: center;
  margin-top: 27px;
  gap: 19px;
}

.hero-stats div {
  display: flex;
  flex-direction: column;
}

.hero-stats strong {
  color: white;
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 800;
}

.hero-stats span {
  color: rgba(255, 255, 255, .53);
  font-size: 12px;
  letter-spacing: .05em;
}

.hero-stats i {
  width: 1px;
  height: 25px;
  background: rgba(255, 255, 255, .18);
}

.hero-art {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-top: 42px;
}

.sun-disc {
  position: absolute;
  top: 42px;
  right: 49px;
  width: 248px;
  height: 248px;
  border-radius: 50%;
  background: radial-gradient(circle at 42% 38%, #fbe2a3, #f1ba48);
  box-shadow: 0 0 0 20px rgba(250, 214, 130, .06), 0 0 70px rgba(247, 205, 101, .26);
}

.book-illustration {
  position: relative;
  z-index: 2;
  width: min(100%, 535px);
  margin-right: -20px;
  filter: drop-shadow(0 16px 25px rgba(24, 64, 57, .14));
}

.floating-note {
  position: absolute;
  z-index: 4;
  padding: 7px 12px;
  border-radius: 9px;
  color: #436259;
  background: #fffaf0;
  font-family: var(--serif);
  font-size: 12px;
  font-weight: 700;
  box-shadow: 0 7px 18px rgba(24, 64, 57, .14);
  animation: float 4s ease-in-out infinite;
}

.floating-note::after {
  position: absolute;
  bottom: -4px;
  left: 16px;
  width: 8px;
  height: 8px;
  background: inherit;
  transform: rotate(45deg);
  content: "";
}

.note-one {
  top: 128px;
  left: 1.5%;
  transform: rotate(-7deg);
}

.note-two {
  top: 207px;
  right: 2%;
  animation-delay: -2s;
  transform: rotate(5deg);
}

@keyframes float {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -7px; }
}

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

.section-kicker {
  margin: 0 0 4px;
  color: #92a39e;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .18em;
}

.section-heading h2,
.recommend-head h2,
.growth-head h2,
.history-head h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 800;
  letter-spacing: .02em;
}

.round-arrow {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid #ded9ce;
  border-radius: 50%;
  background: transparent;
  transition: background .2s ease, transform .2s ease;
}

.round-arrow:hover {
  background: white;
  transform: translateX(2px);
}

.round-arrow svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

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

.skill-card {
  position: relative;
  min-height: 188px;
  overflow: hidden;
  padding: 21px 20px 18px;
  border: 1px solid rgba(255, 255, 255, .5);
  border-radius: var(--radius-md);
  background: var(--white);
  text-align: left;
  box-shadow: var(--shadow-sm);
  transition: transform .24s ease, box-shadow .24s ease;
}

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

.skill-card::after {
  position: absolute;
  right: -22px;
  bottom: -26px;
  width: 91px;
  height: 91px;
  border: 18px solid currentColor;
  border-radius: 50%;
  opacity: .05;
  content: "";
}

.skill-find { color: #317e6f; background: #eef6f0; }
.skill-words { color: #b86a4b; background: #fbeee8; }
.skill-infer { color: #4a7890; background: #e9f2f3; }
.skill-feel { color: #9a7626; background: #fcf3d9; }

.skill-icon {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 13px;
  background: rgba(255, 255, 255, .74);
}

.skill-icon svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.65;
}

.skill-number {
  position: absolute;
  top: 24px;
  right: 20px;
  opacity: .3;
  font-family: var(--serif);
  font-size: 13px;
  font-weight: 800;
}

.skill-card strong {
  display: block;
  margin-top: 14px;
  color: var(--ink);
  font-size: 16px;
}

.skill-card p {
  margin: 4px 0 10px;
  color: var(--ink-soft);
  font-size: 12px;
}

.skill-link {
  font-size: 12px;
  font-weight: 700;
}

.skill-link i {
  display: inline-block;
  margin-left: 3px;
  font-style: normal;
  transition: transform .2s ease;
}

.skill-card:hover .skill-link i {
  transform: translateX(4px);
}

.home-lower-grid {
  display: grid;
  margin-top: 27px;
  gap: 19px;
  grid-template-columns: 1.35fr .65fr;
}

.recommend-card,
.week-card,
.growth-card,
.calendar-card,
.history-card {
  padding: 23px;
  border: 1px solid rgba(224, 219, 208, .66);
  border-radius: var(--radius-md);
  background: rgba(255, 253, 248, .8);
  box-shadow: var(--shadow-sm);
}

.recommend-head,
.growth-head,
.history-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.recommend-label {
  padding: 4px 9px;
  border-radius: 20px;
  color: #8b6d2c;
  background: #faedc9;
  font-size: 12px;
}

.daily-card-content {
  display: grid;
  min-height: 146px;
  margin-top: 17px;
  overflow: hidden;
  border-radius: 16px;
  background:
    radial-gradient(circle at 86% 20%, rgba(242, 189, 75, .23), transparent 28%),
    #e8f2ec;
  grid-template-columns: 1fr;
}

.daily-copy {
  display: flex;
  justify-content: center;
  padding: 20px 21px;
  flex-direction: column;
}

.daily-copy .daily-tags {
  display: flex;
  align-items: center;
  gap: 8px;
}

.daily-copy .daily-tags span {
  color: var(--green);
  font-size: 12px;
  font-weight: 700;
}

.daily-copy h3 {
  margin: 7px 0 4px;
  font-family: var(--serif);
  font-size: 21px;
}

.daily-copy p {
  display: -webkit-box;
  overflow: hidden;
  margin: 0 0 13px;
  color: var(--ink-soft);
  font-size: 12px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
}

.daily-copy.daily-complete p {
  -webkit-line-clamp: 2;
}

.inline-start {
  display: flex;
  align-items: center;
  width: fit-content;
  padding: 0;
  color: var(--green-deep);
  background: transparent;
  gap: 5px;
  font-size: 12px;
  font-weight: 800;
}

.inline-start svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 2;
  transition: transform .2s ease;
}

.inline-start:hover svg {
  transform: translateX(4px);
}

.daily-visual {
  position: relative;
  display: grid;
  place-items: center;
}

.mini-book {
  position: relative;
  width: 110px;
  height: 88px;
  filter: drop-shadow(0 12px 12px rgba(34, 82, 70, .16));
  transform: rotate(-5deg);
}

.mini-book::before,
.mini-book::after {
  position: absolute;
  top: 5px;
  width: 54px;
  height: 75px;
  border: 3px solid #377a6b;
  border-radius: 3px 9px 9px 3px;
  background: #fffaf0;
  content: "";
}

.mini-book::before {
  left: 1px;
  transform: skewY(6deg);
}

.mini-book::after {
  right: 1px;
  border-radius: 9px 3px 3px 9px;
  transform: skewY(-6deg);
}

.mini-book span {
  position: absolute;
  z-index: 2;
  top: 25px;
  left: 52px;
  width: 6px;
  height: 54px;
  border-radius: 3px;
  background: #ee8a66;
}

.plain-link {
  padding: 0;
  color: var(--green);
  background: transparent;
  font-size: 12px;
  font-weight: 700;
}

.plain-link:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.week-bars {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  height: 99px;
  margin: 24px 3px 0;
  gap: 8px;
}

.day-bar {
  display: flex;
  height: 100%;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.day-bar-track {
  display: flex;
  width: 100%;
  height: 72px;
  align-items: flex-end;
  justify-content: center;
}

.day-bar-track i {
  width: min(25px, 70%);
  min-height: 5px;
  border-radius: 6px 6px 3px 3px;
  background: #dfe8df;
  transition: height .5s ease;
}

.day-bar.is-today .day-bar-track i {
  background: var(--orange);
}

.day-bar.has-reading .day-bar-track i {
  background: var(--green);
}

.day-bar.is-today.has-reading .day-bar-track i {
  background: linear-gradient(#ef9c6e, var(--orange));
}

.day-bar span {
  color: var(--muted);
  font-size: 12px;
}

.day-bar.is-today span {
  color: var(--orange);
  font-weight: 800;
}

.week-summary {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-top: 17px;
  padding-top: 13px;
  border-top: 1px solid var(--line);
}

.week-summary span {
  color: var(--muted);
  font-size: 12px;
}

.week-summary strong {
  font-family: var(--serif);
  font-size: 16px;
}

.reading-tip {
  display: flex;
  align-items: center;
  margin: 19px 0 3px;
  padding: 14px 18px;
  border: 1px dashed #d8d3c7;
  border-radius: 15px;
  gap: 13px;
}

.tip-icon {
  display: grid;
  width: 37px;
  height: 37px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 12px;
  color: #b98a23;
  background: #faedc9;
}

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

.reading-tip div:nth-child(2) {
  flex: 1;
}

.reading-tip span {
  color: #9a7626;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .08em;
}

.reading-tip p {
  margin: 1px 0 0;
  color: var(--ink-soft);
  font-size: 12px;
}

.reading-tip button {
  padding: 5px 9px;
  border-radius: 20px;
  color: var(--muted);
  background: transparent;
  font-size: 12px;
}

.reading-tip button:hover {
  background: white;
}

.site-footer {
  display: flex;
  width: 100%;
  max-width: 1480px;
  align-items: center;
  justify-content: space-between;
  margin: 0 auto;
  padding: 15px 43px 25px;
  color: #99a49f;
  font-size: 12px;
}

.home-plan-panel {
  margin-top: 26px;
  padding: 19px 20px;
  border: 1px solid #e5dfd2;
  border-radius: 22px;
  background: linear-gradient(145deg, #fffdf8, #fbfaf4);
  box-shadow: var(--shadow-sm);
}

.home-plan-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 14px;
  gap: 16px;
}

.home-plan-head h2 {
  margin: 3px 0 3px;
  font-family: var(--serif);
  font-size: 24px;
  line-height: 1.35;
}

.home-plan-head > div > p:last-child {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.home-plan-link {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  padding: 8px 11px;
  border-radius: 10px;
  color: var(--green);
  background: #eaf4ed;
  gap: 5px;
  font-size: 12px;
  font-weight: 800;
}

.home-plan-link svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.home-plan-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.home-plan-grade {
  overflow: hidden;
  border: 1px solid #e8e4da;
  border-radius: 14px;
  background: white;
}

.home-plan-grade > strong {
  display: block;
  padding: 8px 11px;
  color: var(--green);
  background: #f0f7f1;
  font-family: var(--serif);
  font-size: 14px;
}

.home-plan-grade button {
  display: grid;
  width: 100%;
  align-items: center;
  padding: 8px 10px;
  color: var(--ink-soft);
  background: transparent;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 4px;
  text-align: left;
}

.home-plan-grade button + button {
  border-top: 1px dashed #eee9df;
}

.home-plan-grade button:hover {
  background: #fbfcf8;
}

.home-plan-grade button span {
  color: #9a7a3b;
  font-size: 11px;
  font-weight: 800;
}

.home-plan-grade button p {
  margin: 0;
  font-size: 12px;
  line-height: 1.5;
}

@media (max-width: 650px) {
  .home-plan-panel {
    padding: 16px;
  }

  .home-plan-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .home-plan-grid {
    overflow-x: auto;
    padding-bottom: 4px;
    grid-template-columns: repeat(3, 220px);
    scrollbar-width: none;
  }

  .home-plan-grid::-webkit-scrollbar {
    display: none;
  }
}

/* Library */
.page-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin: 7px 0 30px;
}

.back-text {
  display: inline-flex;
  align-items: center;
  margin: 0 0 20px;
  padding: 0;
  color: var(--muted);
  background: transparent;
  gap: 5px;
  font-size: 12px;
}

.back-text:hover {
  color: var(--ink);
}

.back-text svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.page-heading h1 {
  margin: 3px 0 8px;
  font-family: var(--serif);
  font-size: clamp(32px, 4vw, 46px);
  line-height: 1.25;
}

.page-heading > div > p:last-child {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.plan-seal {
  display: flex;
  width: 104px;
  height: 104px;
  align-items: center;
  justify-content: center;
  padding: 14px;
  border: 1px solid #e3d6b8;
  border-radius: 50%;
  color: #7b5e28;
  background: radial-gradient(circle at 35% 30%, #fff9e8, #f7edd4);
  flex-direction: column;
  box-shadow: var(--shadow-sm);
}

.plan-seal span {
  font-family: var(--serif);
  font-size: 32px;
  font-weight: 800;
  line-height: 1;
}

.plan-seal strong {
  margin-top: 4px;
  font-size: 12px;
}

.plan-note {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  margin-bottom: 22px;
  padding: 16px 18px;
  border: 1px solid #dce5d9;
  border-radius: 18px;
  background: linear-gradient(135deg, #eef7f0, #fffdf6);
  gap: 16px;
}

.plan-note strong {
  color: var(--green);
  font-family: var(--serif);
  font-size: 16px;
}

.plan-note p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 12px;
  line-height: 1.85;
}

.roadmap {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.roadmap::before {
  position: absolute;
  top: 18px;
  bottom: 18px;
  left: 35px;
  width: 2px;
  background: linear-gradient(#cfe4d7, #ead9b4 55%, #dfcfba);
  content: "";
}

.semester-card {
  position: relative;
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid #e5dfd1;
  border-radius: 22px;
  background: #fffdf9;
  box-shadow: var(--shadow-sm);
}

.semester-label {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 22px 0;
  color: #456f62;
  background: #eef6ef;
  flex-direction: column;
}

.semester-label strong {
  font-family: var(--serif);
  font-size: 20px;
}

.semester-label span {
  margin-top: 5px;
  font-size: 11px;
  writing-mode: vertical-rl;
  letter-spacing: .08em;
}

.semester-eight .semester-label {
  color: #795b2d;
  background: #fbf3df;
}

.semester-nine .semester-label {
  color: #7d5149;
  background: #f8ece8;
}

.semester-body {
  padding: 21px 22px 18px;
}

.semester-title > span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .08em;
}

.semester-title h2 {
  margin: 4px 0 15px;
  font-family: var(--serif);
  font-size: 21px;
  line-height: 1.4;
}

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

.required-book-grid button {
  display: flex;
  min-height: 92px;
  align-items: flex-start;
  padding: 13px 14px;
  border: 1px solid #dfe8da;
  border-radius: 14px;
  color: var(--ink);
  background: linear-gradient(145deg, #f6fbf6, #fff);
  flex-direction: column;
  text-align: left;
  transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}

.required-book-grid button:hover {
  border-color: #91b7a4;
  box-shadow: var(--shadow-sm);
  transform: translateY(-2px);
}

.required-book-grid span {
  color: var(--muted);
  font-size: 11px;
}

.required-book-grid strong {
  margin: 4px 0 7px;
  font-family: var(--serif);
  font-size: 16px;
}

.required-book-grid small {
  margin-top: auto;
  color: var(--green);
  font-size: 11px;
  font-weight: 800;
}

.semester-tasks {
  display: grid;
  margin-top: 15px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.semester-tasks > div {
  padding: 11px 12px;
  border-left: 3px solid #b7d0c0;
  border-radius: 3px 11px 11px 3px;
  background: #f7f8f3;
}

.semester-tasks span {
  color: var(--green);
  font-size: 11px;
  font-weight: 800;
}

.semester-tasks p {
  margin: 4px 0 0;
  color: var(--ink-soft);
  font-size: 12px;
  line-height: 1.7;
}

.plan-warning {
  margin-top: 10px;
  padding: 9px 11px;
  border-radius: 10px;
  color: #76541d;
  background: #fbf0d5;
  font-size: 12px;
  line-height: 1.65;
}

.optional-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  margin-top: 13px;
  gap: 6px;
}

.optional-line strong {
  margin-right: 2px;
  color: var(--muted);
  font-size: 11px;
}

.optional-line span {
  padding: 3px 7px;
  border-radius: 999px;
  color: #6d6658;
  background: #f2f0e9;
  font-size: 11px;
}

.grade-subtopics {
  margin-bottom: 18px;
  padding: 17px;
  border: 1px solid #e3ded2;
  border-radius: 20px;
  background: rgba(255, 253, 248, .84);
}

.grade-subtopics-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 12px;
}

.grade-subtopics-head h2 {
  margin: 3px 0 0;
  font-family: var(--serif);
  font-size: 20px;
}

.grade-subtopics-head > span {
  color: var(--muted);
  font-size: 11px;
}

.grade-subtopics-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.grade-topic-group {
  min-width: 0;
  border: 1px solid #e8e3d8;
  border-radius: 13px;
  background: white;
}

.grade-topic-group summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 12px;
  color: var(--ink);
  cursor: pointer;
  gap: 10px;
  list-style: none;
}

.grade-topic-group summary::-webkit-details-marker {
  display: none;
}

.grade-topic-group summary::after {
  color: var(--green);
  content: "+";
  font-size: 16px;
}

.grade-topic-group[open] summary::after {
  content: "−";
}

.grade-topic-group summary span {
  font-family: var(--serif);
  font-size: 16px;
  font-weight: 800;
}

.grade-topic-group summary small {
  margin-left: auto;
  color: var(--muted);
  font-size: 11px;
}

.semester-topic-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  padding: 7px 10px;
  border-top: 1px dashed #eee8dc;
  gap: 5px;
}

.semester-topic-row strong {
  width: 30px;
  color: #876632;
  font-size: 11px;
}

.semester-topic-row button {
  padding: 4px 7px;
  border: 1px solid #e3e1d7;
  border-radius: 999px;
  color: var(--ink-soft);
  background: #fafaf6;
  font-size: 11px;
}

.semester-topic-row button:hover {
  border-color: #9fc1ae;
  color: var(--green);
  background: #eff7f1;
}

.grade-book-links {
  display: flex;
  flex-wrap: wrap;
  padding: 8px 10px 10px;
  border-top: 1px dashed #eee8dc;
  gap: 6px;
}

.grade-book-links button {
  padding: 5px 8px;
  border: 1px solid #e3e1d7;
  border-radius: 999px;
  color: var(--ink-soft);
  background: #fafaf6;
  font-size: 11px;
}

.grade-book-links button:hover {
  border-color: #9fc1ae;
  color: var(--green);
  background: #eff7f1;
}

.library-badge {
  display: flex;
  align-items: center;
  padding: 10px 17px 10px 10px;
  border: 1px solid #e3ded2;
  border-radius: 18px;
  background: #fffdf8;
  gap: 10px;
}

.library-badge > span {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 13px;
  color: #8d6c25;
  background: var(--yellow-soft);
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 800;
}

.library-badge > div {
  display: flex;
  flex-direction: column;
}

.library-badge strong {
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.2;
}

.library-badge small {
  color: var(--muted);
  font-size: 12px;
}

.filter-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 17px;
  border: 1px solid rgba(225, 220, 210, .8);
  border-radius: 17px;
  background: rgba(255, 253, 248, .78);
  gap: 20px;
}

.filter-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.filter-label {
  color: var(--muted);
  font-size: 12px;
}

.filter-chips {
  display: flex;
  gap: 5px;
}

.genre-filter-chips {
  flex-wrap: wrap;
}

.filter-chip {
  padding: 6px 12px;
  border-radius: 20px;
  color: var(--ink-soft);
  background: transparent;
  font-size: 12px;
}

.filter-chip:hover {
  background: #f1f3ed;
}

.filter-chip.is-active {
  color: white;
  background: var(--green);
  font-weight: 700;
}

.filter-group select {
  min-width: 116px;
  padding: 7px 30px 7px 12px;
  border: 1px solid #e1ddd4;
  border-radius: 10px;
  color: var(--ink-soft);
  background: white;
  font-size: 12px;
}

.library-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 22px 2px 13px;
}

.library-meta p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

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

.library-meta-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.unread-toggle {
  padding: 5px 9px;
  border: 1px solid #dfe4dc;
  border-radius: 999px;
  color: var(--muted);
  background: #fffdf8;
  font-size: 12px;
  font-weight: 700;
}

.unread-toggle:hover,
.unread-toggle.is-active {
  border-color: var(--green);
  color: white;
  background: var(--green);
}

.sort-button {
  display: flex;
  align-items: center;
  padding: 5px 0;
  color: var(--muted);
  background: transparent;
  gap: 5px;
  font-size: 12px;
}

.sort-button svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 1.6;
}

.passage-grid {
  display: grid;
  gap: 17px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.passage-card {
  position: relative;
  display: flex;
  min-height: 215px;
  overflow: hidden;
  padding: 20px;
  border: 1px solid rgba(255, 255, 255, .7);
  border-radius: 22px;
  background: white;
  cursor: pointer;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
  transition: transform .24s ease, box-shadow .24s ease;
}

.passage-card:focus-visible {
  outline: 3px solid rgba(55, 124, 109, .35);
  outline-offset: 3px;
}

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

.passage-card.classic-card {
  border-color: #ddd3bd;
  background: linear-gradient(180deg, #fffdf8, #fff);
}

.passage-card.classic-card::before {
  position: absolute;
  top: 0;
  right: 22px;
  left: 22px;
  height: 3px;
  border-radius: 0 0 4px 4px;
  background: linear-gradient(90deg, #b8903e, #d9c27e);
  content: "";
}

.passage-art {
  position: relative;
  display: flex;
  height: 98px;
  overflow: hidden;
  align-items: center;
  justify-content: center;
  margin: -5px -5px 16px;
  border-radius: 16px;
  isolation: isolate;
}

.passage-art::before,
.passage-art::after {
  position: absolute;
  z-index: -1;
  border-radius: 50%;
  content: "";
}

.passage-art::before {
  top: -40px;
  right: -15px;
  width: 125px;
  height: 125px;
  background: rgba(255, 255, 255, .3);
}

.passage-art::after {
  bottom: -48px;
  left: 20px;
  width: 110px;
  height: 110px;
  border: 22px solid rgba(255, 255, 255, .18);
}

.passage-art svg {
  width: 76px;
  height: 76px;
}

.theme-forest .passage-art { background: #e2f0e6; color: #3e7b69; }
.theme-rain .passage-art { background: #e2edf2; color: #527f92; }
.theme-sun .passage-art { background: #f9edcd; color: #9b7222; }
.theme-peach .passage-art { background: #f8e5db; color: #a65e45; }
.theme-night .passage-art { background: #e4e7f1; color: #566583; }
.theme-clock .passage-art { background: #ece5d8; color: #86684c; }
.theme-ocean .passage-art { background: #dcecf0; color: #487788; }
.theme-garden .passage-art { background: #e9efd9; color: #627748; }

.passage-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.passage-top span {
  color: var(--muted);
  font-size: 12px;
}

.passage-statuses {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.exam-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 7px;
  border-radius: 20px;
  color: #795c25 !important;
  background: #f7e8bf;
  font-size: 11px !important;
  font-weight: 800;
}

.finished-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 7px;
  border-radius: 20px;
  color: var(--green) !important;
  background: #e4f1e9;
  gap: 3px;
  font-weight: 700;
}

.passage-card h3 {
  margin: 0 0 5px;
  font-family: var(--serif);
  font-size: 20px;
  line-height: 1.4;
}

.passage-card > p {
  display: -webkit-box;
  overflow: hidden;
  margin: 0;
  color: var(--ink-soft);
  font-size: 12px;
  line-height: 1.7;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.classic-books {
  display: flex;
  flex-wrap: wrap;
  margin-top: 10px;
  gap: 5px;
}

.classic-books span {
  padding: 3px 7px;
  border: 1px solid #e8dfcb;
  border-radius: 6px;
  color: #765d32;
  background: #fcf8ed;
  font-size: 11px;
}

.passage-tags {
  display: flex;
  flex-wrap: wrap;
  margin-top: 11px;
  gap: 5px;
}

.passage-skill-summary {
  flex: 1 0 100%;
  width: fit-content;
}

.passage-tags span {
  padding: 3px 7px;
  border-radius: 6px;
  color: #7b8984;
  background: #f2f2ec;
  font-size: 12px;
  line-height: 1.5;
}

.passage-source-line {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-top: 11px;
  color: var(--muted);
  gap: 8px;
  font-size: 11px;
  line-height: 1.55;
}

.passage-source-line > span {
  min-width: 0;
  flex: 1;
}

.passage-source-line a {
  flex: 0 0 auto;
  color: var(--green);
  font-weight: 700;
}

.passage-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid #eeebe3;
}

.passage-footer > span {
  color: var(--muted);
  font-size: 12px;
}

.passage-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.checkin-button {
  padding: 7px 9px;
  border: 1px solid #d8e2da;
  border-radius: 9px;
  color: var(--muted);
  background: #fffdf8;
  font-size: 12px;
  font-weight: 700;
}

.checkin-button:hover {
  border-color: var(--green);
  color: var(--green);
  background: #f2f8f4;
}

.checkin-button.is-checked {
  border-color: #a7c7b4;
  color: white;
  background: var(--green);
}

.start-passage {
  display: flex;
  align-items: center;
  padding: 7px 10px;
  border-radius: 9px;
  color: var(--green-deep);
  background: #e9f3ed;
  gap: 5px;
  font-size: 12px;
  font-weight: 800;
}

.start-passage:hover {
  color: white;
  background: var(--green);
}

.start-passage svg {
  width: 13px;
  height: 13px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 2;
}

.empty-state {
  padding: 60px 20px;
  color: var(--muted);
  text-align: center;
}

.empty-state span {
  font-size: 38px;
}

.empty-state h3 {
  margin: 8px 0 4px;
  color: var(--ink);
  font-family: var(--serif);
}

.empty-state p {
  margin: 0;
  font-size: 12px;
}

/* Reader */
main:has(.reader-view:not([hidden])) {
  max-width: 1560px;
  padding-top: 25px;
}

.reader-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 15px;
}

.reader-topbar .back-text {
  margin: 0;
}

.reader-controls {
  display: flex;
  align-items: center;
  gap: 7px;
}

.reading-timer {
  display: flex;
  align-items: center;
  min-width: 83px;
  padding: 7px 10px;
  border: 1px solid #dedad0;
  border-radius: 10px;
  color: var(--ink-soft);
  background: rgba(255, 255, 255, .58);
  gap: 6px;
  font-variant-numeric: tabular-nums;
  font-size: 12px;
}

.reading-timer svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.icon-control {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid #dedad0;
  border-radius: 10px;
  color: var(--ink-soft);
  background: rgba(255, 255, 255, .58);
}

.icon-control:hover {
  color: var(--green);
  background: white;
}

.icon-control svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.font-icon {
  font-family: Georgia, serif;
  font-size: 16px;
  line-height: 1;
}

.font-icon small {
  font-size: 12px;
}

.reader-layout {
  display: grid;
  align-items: start;
  gap: 20px;
  grid-template-columns: minmax(0, 1fr) 378px;
}

.reading-paper {
  min-width: 0;
  padding: 44px clamp(27px, 5vw, 74px) 40px;
  border: 1px solid rgba(232, 226, 214, .8);
  border-radius: 26px;
  background:
    linear-gradient(90deg, transparent 0, transparent calc(100% - 1px), rgba(231, 224, 211, .4) calc(100% - 1px)),
    #fffdf8;
  box-shadow: var(--shadow-sm);
}

.paper-header {
  max-width: 790px;
  margin: 0 auto;
  text-align: center;
}

.paper-tags {
  display: flex;
  justify-content: center;
  margin-bottom: 13px;
  gap: 6px;
}

.paper-tags span {
  padding: 4px 9px;
  border-radius: 20px;
  color: var(--green);
  background: #e8f2ec;
  font-size: 12px;
}

.paper-tags span:first-child {
  color: #946e20;
  background: #faedca;
}

.paper-header h1 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(31px, 4vw, 43px);
  letter-spacing: .06em;
  line-height: 1.3;
}

.paper-header > p {
  margin: 7px 0 13px;
  color: var(--ink-soft);
  font-family: var(--serif);
  font-size: 14px;
  letter-spacing: .04em;
}

.paper-header > p.reader-source {
  display: flex;
  align-items: stretch;
  justify-content: center;
  flex-wrap: wrap;
  flex-direction: column;
  margin: -2px auto 13px;
  padding: 7px 10px;
  border: 1px solid #e4dece;
  border-radius: 9px;
  color: #75603a;
  background: #fcf8ed;
  gap: 5px;
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0;
}

.reader-source-row {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 5px;
}

.reader-source-row + .reader-source-row {
  margin-top: 4px;
  padding-top: 5px;
  border-top: 1px dashed #e6dfd0;
}

.reader-source-row > span {
  padding: 2px 6px;
  border-radius: 999px;
  color: #7a5b26;
  background: #f4e4bb;
  font-size: 11px;
  font-weight: 800;
}

.reader-source-row > strong {
  font-weight: 600;
}

.reader-source-row > a {
  color: var(--green);
  font-weight: 800;
}

.paper-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  gap: 10px;
  font-size: 12px;
}

.paper-meta span + span::before {
  display: inline-block;
  width: 3px;
  height: 3px;
  margin: 0 10px 2px 0;
  border-radius: 50%;
  background: #c9c5ba;
  content: "";
}

.paper-divider {
  display: flex;
  max-width: 790px;
  align-items: center;
  margin: 24px auto 27px;
  color: #b8a575;
  gap: 12px;
}

.paper-divider::before,
.paper-divider::after {
  height: 1px;
  background: #ebe5d9;
  content: "";
  flex: 1;
}

.paper-divider span {
  font-size: 12px;
}

.article-body {
  max-width: 790px;
  margin: 0 auto;
  color: #2b4340;
  font-family: var(--serif);
  font-size: 17px;
  letter-spacing: .035em;
  line-height: 2.12;
}

.article-body.font-large {
  font-size: 20px;
}

.article-paragraph {
  position: relative;
  margin: 0 0 16px;
  padding: 2px 9px;
  border-left: 3px solid transparent;
  border-radius: 3px 9px 9px 3px;
  text-align: justify;
  cursor: pointer;
  transition: background .18s ease, border-color .18s ease;
}

.article-paragraph:hover {
  background: rgba(246, 237, 210, .53);
}

.article-paragraph.is-marked {
  border-left-color: var(--yellow);
  background: #fcf4dd;
}

.article-paragraph.is-marked::after {
  position: absolute;
  top: 10px;
  right: -17px;
  color: #c39738;
  font-family: var(--sans);
  font-size: 12px;
  content: "✦";
}

.article-body .vocab-word {
  position: relative;
  display: inline;
  padding: 0 1px;
  border: 0;
  color: #9a642a;
  background: transparent;
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
  text-decoration: underline dotted #d2a14c 1.5px;
  text-underline-offset: 5px;
  cursor: help;
}

.article-body .vocab-word:hover {
  color: #74491d;
  background: #fff2cf;
}

.article-body .vocab-word.is-open::after {
  position: absolute;
  z-index: 5;
  right: 0;
  bottom: calc(100% + 8px);
  width: max-content;
  max-width: 270px;
  padding: 9px 12px;
  border-radius: 9px;
  color: white;
  background: #28594f;
  box-shadow: 0 7px 20px rgba(25, 61, 54, .2);
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0;
  line-height: 1.65;
  text-align: left;
  white-space: normal;
  content: attr(data-definition);
}

.paragraph-dialogue {
  padding-left: 24px;
  text-indent: -1em;
}

.article-paragraph.paragraph-material {
  margin-bottom: 18px;
  padding: 14px 17px 14px 20px;
  border: 1px solid #dfe7dc;
  border-left: 4px solid #7eaa8e;
  border-radius: 10px;
  background: #fbfcf8;
  line-height: 1.9;
  text-indent: 0;
}

.article-paragraph.paragraph-material:hover {
  background: #f5f8ef;
}

.article-paragraph.paragraph-material.is-marked {
  border-color: #e7c96c;
  border-left-color: var(--yellow);
  background: #fcf4dd;
}

.annotation-key {
  display: flex;
  max-width: 790px;
  justify-content: flex-end;
  margin: 23px auto 0;
  color: var(--muted);
  gap: 17px;
  font-size: 12px;
}

.annotation-key span {
  display: flex;
  align-items: center;
  gap: 5px;
}

.reader-translations {
  max-width: 790px;
  margin: 22px auto 0;
  border: 1px solid #e5ded0;
  border-radius: 14px;
  background: #fbf8f0;
}

.reader-translations summary {
  padding: 13px 16px;
  color: var(--ink);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

.reader-translations summary span {
  margin-left: 6px;
  color: var(--muted);
  font-size: 8px;
  font-weight: 400;
}

.translation-content {
  padding: 0 16px 15px;
}

.translation-item {
  padding: 13px 0;
  border-top: 1px solid #e9e2d5;
}

.translation-item strong {
  display: block;
  margin-bottom: 5px;
  color: #7b642e;
  font-family: var(--serif);
  font-size: 12px;
}

.translation-item p {
  margin: 0;
  color: var(--ink-soft);
  font-family: var(--serif);
  font-size: 12px;
  line-height: 1.9;
}

.key-marker {
  display: inline-block;
  width: 3px;
  height: 10px;
  border-radius: 2px;
  background: var(--yellow);
}

.key-word {
  display: inline-block;
  width: 12px;
  height: 7px;
  border-bottom: 1px dotted #c7943e;
}

.paper-footer {
  max-width: 790px;
  margin: 33px auto 0;
  padding-top: 25px;
  border-top: 1px solid #eee8dc;
  text-align: center;
}

.paper-footer p {
  margin: 0;
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 800;
}

.paper-footer > span {
  display: block;
  margin: 3px 0 14px;
  color: var(--muted);
  font-size: 12px;
}

.paper-footer .primary-button {
  color: white;
  background: var(--green);
}

.paper-footer .primary-button:hover {
  background: var(--green-deep);
}

.paper-footer-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 9px;
}

.reader-checkin-button {
  min-height: 40px;
  padding: 9px 15px;
  border: 1px solid #d8e2da;
  border-radius: 10px;
  color: var(--green);
  background: #f2f8f4;
  font-size: 13px;
  font-weight: 700;
}

.reader-checkin-button.is-checked {
  color: white;
  background: var(--green);
}

.quiz-panel {
  position: sticky;
  top: 20px;
  overflow: hidden;
  border: 1px solid rgba(225, 220, 210, .85);
  border-radius: 22px;
  background: #fffdf8;
  box-shadow: var(--shadow-sm);
}

.quiz-start-state {
  padding: 30px 25px 24px;
  text-align: center;
}

.quiz-orbit {
  display: block;
  width: 88px;
  margin: 0 auto 15px;
}

.quiz-orbit svg {
  width: 88px;
  height: 88px;
}

.quiz-start-state h2 {
  margin: 5px 0 8px;
  font-family: var(--serif);
  font-size: 22px;
}

.quiz-start-state > p:not(.section-kicker) {
  margin: 0 auto;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.8;
}

.quiz-preview {
  display: flex;
  justify-content: center;
  margin: 20px 0 17px;
  gap: 5px;
}

.preview-total {
  align-self: center;
  margin-left: 2px;
  color: #8a6b32;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.preview-pill {
  display: flex;
  align-items: center;
  padding: 6px 8px;
  border-radius: 7px;
  color: var(--ink-soft);
  background: #f2f2eb;
  gap: 4px;
  font-size: 11px;
}

.preview-pill i {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--orange);
}

.soft-button {
  padding: 9px 15px;
  border-radius: 10px;
  color: var(--green);
  background: #e8f2ec;
  font-size: 12px;
  font-weight: 700;
}

.soft-button:hover {
  color: white;
  background: var(--green);
}

.quiz-content {
  max-height: calc(100vh - 42px);
  overflow: auto;
  padding: 23px 21px 21px;
  scrollbar-width: thin;
  scrollbar-color: #d9dfd6 transparent;
}

.quiz-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.quiz-header h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: 20px;
}

.question-progress {
  padding: 3px 8px;
  border-radius: 20px;
  color: var(--green);
  background: #e8f2ec;
  font-size: 12px;
  font-weight: 800;
}

.quiz-progress-track {
  height: 3px;
  overflow: hidden;
  margin: 12px 0 19px;
  border-radius: 3px;
  background: #edeee8;
}

.quiz-progress-track span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--green);
  transition: width .3s ease;
}

.question-block {
  margin: 0 0 22px;
  padding: 0 0 22px;
  border: 0;
  border-bottom: 1px solid #eeeae1;
}

.question-block:last-of-type {
  border-bottom: 0;
}

.question-title {
  position: relative;
  display: flex;
  width: 100%;
  align-items: flex-start;
  margin: 0 0 11px;
  padding-right: 40px;
  color: #29413d;
  gap: 8px;
  font-family: var(--serif);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.65;
}

.question-copy {
  min-width: 0;
  flex: 1;
}

.question-points {
  position: absolute;
  top: 1px;
  right: 0;
  display: inline-flex;
  min-width: 31px;
  justify-content: center;
  padding: 1px 6px;
  border: 1px solid #e6dcc5;
  border-radius: 999px;
  color: #806238;
  background: #fffaf0;
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  word-break: keep-all;
}

.exam-paper-note {
  margin: 0 0 20px;
  padding: 14px 15px;
  border: 1px solid #d9e2d8;
  border-radius: 12px;
  background: linear-gradient(135deg, #f5f9f3, #fffdf7);
}

.exam-paper-note > span {
  display: inline-block;
  margin-bottom: 7px;
  padding: 2px 7px;
  border-radius: 999px;
  color: var(--green);
  background: #e6f1e9;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .04em;
}

.exam-paper-note strong {
  display: block;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 14px;
  line-height: 1.65;
}

.exam-paper-note p {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.65;
}

.question-number {
  display: grid;
  width: 21px;
  height: 21px;
  flex: 0 0 auto;
  place-items: center;
  margin-top: 1px;
  border-radius: 7px;
  color: var(--green);
  background: var(--green-soft);
  font-family: var(--sans);
  font-size: 12px;
}

.question-type-badge {
  display: inline-flex;
  align-items: center;
  margin-right: 5px;
  padding: 1px 6px;
  border-radius: 999px;
  color: #8a5b20;
  background: #f8e8c2;
  font-family: var(--sans);
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
  letter-spacing: .04em;
  vertical-align: 1px;
}

.short-answer-field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.short-answer-field textarea {
  width: 100%;
  min-height: 112px;
  resize: vertical;
  padding: 12px 13px;
  border: 1px solid #dfe4db;
  border-radius: 11px;
  outline: none;
  color: var(--ink);
  background: #fbfcf9;
  font: inherit;
  font-size: 12px;
  line-height: 1.75;
  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
}

.short-answer-field textarea::placeholder {
  color: #9ba59f;
}

.short-answer-field textarea:focus {
  border-color: #87b59b;
  background: white;
  box-shadow: 0 0 0 3px rgba(126, 170, 142, .12);
}

.short-answer-field textarea:disabled {
  opacity: .82;
  cursor: default;
}

.short-answer-hint {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
}

.option-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.option-label {
  position: relative;
  display: flex;
  min-height: 39px;
  align-items: center;
  padding: 8px 10px;
  border: 1px solid #e8e5dd;
  border-radius: 10px;
  background: white;
  gap: 9px;
  cursor: pointer;
  transition: border-color .18s ease, background .18s ease;
}

.option-label:hover {
  border-color: #b7d1c5;
  background: #fbfdfb;
}

.option-label input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.option-letter {
  display: grid;
  width: 21px;
  height: 21px;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid #dddcd6;
  border-radius: 6px;
  color: var(--muted);
  background: #fafaf7;
  font-family: Georgia, serif;
  font-size: 12px;
  font-weight: 700;
}

.option-text {
  color: var(--ink-soft);
  font-size: 12px;
  line-height: 1.6;
}

.option-label:has(input:checked) {
  border-color: var(--green);
  background: #eff7f2;
}

.option-label:has(input:checked) .option-letter {
  border-color: var(--green);
  color: white;
  background: var(--green);
}

.option-label.is-correct {
  border-color: #62a285;
  background: #edf7f1;
}

.option-label.is-correct .option-letter {
  border-color: #62a285;
  color: white;
  background: #62a285;
}

.option-label.is-wrong {
  border-color: #d68b80;
  background: #fcf0ed;
}

.option-label.is-wrong .option-letter {
  border-color: #d68b80;
  color: white;
  background: #d68b80;
}

.question-feedback {
  margin-top: 9px;
  padding: 9px 11px;
  border-radius: 9px;
  color: var(--ink-soft);
  background: #f7f5ee;
  font-size: 12px;
  line-height: 1.7;
}

.question-feedback strong {
  display: block;
  margin-bottom: 2px;
  color: var(--ink);
}

.short-answer-feedback {
  padding: 12px;
}

.student-answer,
.model-answer {
  margin-top: 10px;
  padding: 10px 11px;
  border-radius: 8px;
}

.student-answer {
  border: 1px solid #e4e4dc;
  background: white;
}

.model-answer {
  border: 1px solid #d7e7dc;
  background: #edf6ef;
}

.student-answer > span,
.model-answer > span {
  display: block;
  margin-bottom: 4px;
  color: var(--green);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .05em;
}

.student-answer p,
.model-answer p {
  margin: 0;
  white-space: pre-wrap;
}

.scoring-points {
  margin: 10px 0 0;
  padding-left: 17px;
  color: var(--ink-soft);
}

.scoring-points li {
  margin: 4px 0;
}

.self-check-note {
  margin: 10px 0 0;
  padding-top: 9px;
  border-top: 1px dashed #dddcd2;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.65;
}

.quiz-submit {
  width: 100%;
  min-height: 43px;
  margin-top: 2px;
  color: white;
  background: var(--green);
}

.quiz-submit:hover {
  background: var(--green-deep);
}

.quiz-submit:disabled {
  color: #a4ada8;
  background: #ebede8;
  box-shadow: none;
  transform: none;
}

.submit-hint {
  margin: 8px 0 0;
  color: var(--muted);
  text-align: center;
  font-size: 11px;
}

.quiz-result {
  text-align: center;
}

.result-score {
  position: relative;
  display: grid;
  width: 118px;
  height: 118px;
  margin: 5px auto 15px;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(var(--green) var(--score-angle), #e8ede7 0);
}

.result-score::before {
  position: absolute;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  background: #fffdf8;
  content: "";
}

.result-score div {
  position: relative;
  z-index: 1;
}

.result-score strong {
  display: block;
  color: var(--green-deep);
  font-family: var(--serif);
  font-size: 32px;
  line-height: 1.1;
}

.result-score span {
  color: var(--muted);
  font-size: 11px;
}

.quiz-result h2 {
  margin: 0 0 4px;
  font-family: var(--serif);
  font-size: 22px;
}

.quiz-result > p {
  margin: 0 auto 17px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.8;
}

.quiz-result > p.short-answer-result-note {
  margin: -8px auto 16px;
  padding: 9px 11px;
  border-radius: 9px;
  color: #745626;
  background: #fbf1d9;
  font-size: 11px;
  line-height: 1.65;
}

.result-metrics {
  display: grid;
  margin: 18px 0;
  overflow: hidden;
  border: 1px solid #ebe8df;
  border-radius: 12px;
  background: #faf9f4;
  grid-template-columns: repeat(3, 1fr);
}

.result-metrics div {
  padding: 10px 5px;
}

.result-metrics div + div {
  border-left: 1px solid #e8e5dd;
}

.result-metrics strong {
  display: block;
  font-family: var(--serif);
  font-size: 14px;
}

.result-metrics span {
  color: var(--muted);
  font-size: 11px;
}

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

.result-actions button {
  min-height: 38px;
  flex: 1;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 700;
}

.show-explanations {
  color: var(--green);
  background: #e8f2ec;
}

.next-reading {
  color: white;
  background: var(--green);
}

.show-explanations:hover {
  background: #dcece2;
}

.next-reading:hover {
  background: var(--green-deep);
}

.review-mode .quiz-result {
  display: none;
}

.focus-exit {
  position: fixed;
  z-index: 60;
  top: 18px;
  right: 18px;
  display: flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 10px;
  color: white;
  background: rgba(24, 51, 47, .8);
  gap: 5px;
  font-size: 12px;
}

.focus-exit svg {
  width: 13px;
  height: 13px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 1.8;
}

.print-control {
  display: inline-flex;
  height: 34px;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  border: 1px solid #dfe2da;
  border-radius: 9px;
  color: var(--ink-soft);
  background: rgba(255, 255, 255, .58);
  gap: 5px;
  font-size: 12px;
  font-weight: 700;
}

.print-control:hover {
  color: var(--green);
  background: white;
}

.print-control svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.print-sheet {
  display: none;
}

body.reader-focus .sidebar,
body.reader-focus .site-footer {
  display: none;
}

body.reader-focus .app-shell {
  display: block;
}

body.reader-focus main {
  max-width: 1200px;
  padding-top: 54px;
}

body.reader-focus .reader-topbar {
  visibility: hidden;
}

body.reader-focus .reader-layout {
  display: block;
}

body.reader-focus .quiz-panel {
  display: none;
}

body.reader-focus .reading-paper {
  min-height: calc(100vh - 90px);
}

/* Records */
.records-heading {
  align-items: center;
}

.streak-emblem {
  display: flex;
  width: 124px;
  height: 106px;
  align-items: center;
  justify-content: center;
  border: 1px solid #f0dcad;
  border-radius: 23px;
  background:
    radial-gradient(circle at 50% 25%, rgba(255, 255, 255, .9), transparent 31%),
    #fcf0d1;
  flex-direction: column;
}

.emblem-flame {
  color: var(--orange);
  font-size: 20px;
  line-height: 1;
}

.streak-emblem strong {
  font-family: var(--serif);
  font-size: 31px;
  line-height: 1.1;
}

.streak-emblem small {
  color: #8f7a4c;
  font-size: 11px;
}

.record-stats {
  display: grid;
  gap: 13px;
  grid-template-columns: repeat(4, 1fr);
}

.record-stats article {
  display: flex;
  min-height: 92px;
  align-items: center;
  padding: 17px;
  border: 1px solid rgba(225, 220, 210, .7);
  border-radius: 18px;
  background: rgba(255, 253, 248, .82);
  gap: 12px;
  box-shadow: var(--shadow-sm);
}

.stat-icon {
  display: grid;
  width: 43px;
  height: 43px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 13px;
}

.stat-icon svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.stat-green { color: var(--green); background: var(--green-soft); }
.stat-orange { color: var(--orange); background: var(--orange-soft); }
.stat-yellow { color: #a27a25; background: var(--yellow-soft); }
.stat-blue { color: var(--blue); background: var(--blue-soft); }

.record-stats article > div {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.record-stats strong {
  font-family: var(--serif);
  font-size: 25px;
  line-height: 1.2;
}

.record-stats em {
  margin-left: 3px;
  font-family: var(--sans);
  font-size: 11px;
  font-style: normal;
}

.record-stats small {
  color: var(--muted);
  font-size: 12px;
}

.records-grid {
  display: grid;
  margin-top: 17px;
  gap: 17px;
  grid-template-columns: 1.08fr .92fr;
}

.growth-level {
  padding: 4px 9px;
  border-radius: 20px;
  color: #627443;
  background: #e9f0d9;
  font-size: 12px;
  font-weight: 700;
}

.skill-bars {
  display: flex;
  margin-top: 24px;
  flex-direction: column;
  gap: 17px;
}

.skill-bar-row {
  display: grid;
  align-items: center;
  gap: 8px 11px;
  grid-template-columns: 64px minmax(0, 1fr) 32px;
}

.skill-bar-row > span {
  color: var(--ink-soft);
  font-size: 12px;
}

.skill-bar-row > strong {
  color: var(--muted);
  font-size: 12px;
  text-align: right;
}

.skill-bar-track {
  height: 7px;
  overflow: hidden;
  border-radius: 10px;
  background: #eef0e9;
}

.skill-bar-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #7fb49d, var(--green));
  transition: width .6s ease;
}

.growth-note {
  margin: 22px 0 0;
  padding: 10px 12px;
  border-radius: 10px;
  color: var(--ink-soft);
  background: #f3f5ed;
  font-size: 12px;
}

.calendar-legend {
  display: flex;
  align-items: center;
  color: var(--muted);
  gap: 4px;
  font-size: 11px;
}

.calendar-legend i {
  width: 7px;
  height: 7px;
  border-radius: 2px;
  background: var(--green);
}

.calendar-days {
  display: grid;
  margin-top: 24px;
  gap: 7px;
  grid-template-columns: repeat(7, 1fr);
}

.calendar-day {
  display: flex;
  align-items: center;
  flex-direction: column;
  gap: 5px;
}

.calendar-day i {
  display: grid;
  width: 100%;
  aspect-ratio: 1;
  max-width: 34px;
  place-items: center;
  border: 1px solid #e5e5de;
  border-radius: 8px;
  color: #a1aaa5;
  background: #fbfbf8;
  font-size: 11px;
  font-style: normal;
}

.calendar-day.has-reading i {
  border-color: var(--green);
  color: white;
  background: var(--green);
}

.calendar-day.is-today i {
  outline: 2px solid #f1bf51;
  outline-offset: 1px;
}

.calendar-day span {
  color: var(--muted);
  font-size: 11px;
}

.calendar-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 23px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.calendar-summary span {
  color: var(--muted);
  font-size: 11px;
}

.calendar-summary strong {
  color: var(--orange);
  font-size: 12px;
}

.history-card {
  margin-top: 17px;
}

.history-list {
  margin-top: 14px;
}

.history-item {
  display: grid;
  align-items: center;
  padding: 12px 3px;
  border-top: 1px solid #eeebe4;
  gap: 11px;
  grid-template-columns: 41px minmax(0, 1fr) 78px 64px 55px;
}

.history-book {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 10px;
  color: var(--green);
  background: var(--green-soft);
  font-family: var(--serif);
  font-size: 16px;
  font-weight: 800;
}

.history-title {
  min-width: 0;
}

.history-title strong {
  display: block;
  overflow: hidden;
  font-family: var(--serif);
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.history-title span {
  color: var(--muted);
  font-size: 11px;
}

.history-detail {
  color: var(--muted);
  font-size: 12px;
}

.history-score {
  font-family: var(--serif);
  font-size: 14px;
  font-weight: 800;
}

.history-score.good { color: var(--green); }
.history-score.mid { color: #aa7d20; }
.history-score.low { color: var(--orange); }

.history-date {
  color: var(--muted);
  font-size: 11px;
  text-align: right;
}

.history-empty {
  padding: 30px 20px;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

.reset-data-button {
  display: block;
  margin: 20px auto 0;
  padding: 6px 10px;
  color: #a4aaa5;
  background: transparent;
  font-size: 11px;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.reset-data-button:hover {
  color: var(--red);
}

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

.word-study-heading {
  align-items: flex-start;
}

.word-deck-badge {
  display: flex;
  align-items: center;
  margin-top: 12px;
  padding: 10px 16px 10px 10px;
  border: 1px solid #e3ded2;
  border-radius: 18px;
  background: #fffdf8;
  gap: 10px;
  box-shadow: var(--shadow-sm);
}

.word-deck-badge > span {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 13px;
  color: var(--green-deep);
  background: #e3f0e7;
  font-family: var(--serif);
  font-size: 13px;
  font-weight: 800;
}

.word-deck-badge strong,
.word-deck-badge small {
  display: block;
}

.word-deck-badge strong {
  font-family: var(--serif);
  font-size: 24px;
  line-height: 1.1;
}

.word-deck-badge small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
}

.word-deck-panel {
  padding: clamp(18px, 3vw, 30px);
  border: 1px solid rgba(224, 219, 208, .72);
  border-radius: 26px;
  background:
    radial-gradient(circle at 12% 10%, rgba(228, 241, 232, .8), transparent 25%),
    rgba(255, 253, 248, .82);
  box-shadow: var(--shadow-sm);
}

.word-category-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.word-grade-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.word-filter-select select {
  min-width: 145px;
  padding: 9px 34px 9px 12px;
  border: 1px solid #e1ddd4;
  border-radius: 11px;
  color: var(--ink-soft);
  background: #fffdf8;
  font-size: 13px;
}

.word-empty-state {
  margin: 24px 0 8px;
  padding: 42px 20px;
  border: 1px dashed #d7ddd5;
  border-radius: 20px;
  color: var(--muted);
  background: rgba(255, 253, 248, .7);
  text-align: center;
}

.word-empty-state strong {
  display: block;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 22px;
}

.word-empty-state p {
  margin: 8px 0 0;
  font-size: 13px;
}

.word-category-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.word-category-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.word-category-chip {
  padding: 7px 12px;
  border: 1px solid #e3dfd5;
  border-radius: 999px;
  color: var(--ink-soft);
  background: #fffdf8;
  font-size: 12px;
  transition: color .2s ease, border-color .2s ease, background .2s ease;
}

.word-category-chip:hover {
  border-color: #a4c6b2;
  color: var(--green);
  background: #f1f7f2;
}

.word-category-chip.is-active {
  border-color: var(--green);
  color: white;
  background: var(--green);
  font-weight: 700;
}

.word-progress-row {
  display: flex;
  align-items: center;
  margin: 22px 0 14px;
  gap: 12px;
}

.word-progress-row > span {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.word-progress-track {
  height: 7px;
  overflow: hidden;
  flex: 1;
  border-radius: 999px;
  background: #e8e6dd;
}

.word-progress-track > span {
  display: block;
  width: 5%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--green), #7eb494);
  transition: width .25s ease;
}

.word-random-button {
  display: inline-flex;
  align-items: center;
  padding: 6px 9px;
  color: var(--green);
  background: transparent;
  gap: 4px;
  font-size: 12px;
  font-weight: 700;
}

.word-random-button svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.word-flashcard {
  width: min(100%, 760px);
  min-height: 470px;
  margin: 0 auto;
  padding: 0;
  border: 0;
  background: transparent;
  perspective: 1500px;
}

.word-flashcard-inner {
  position: relative;
  display: block;
  width: 100%;
  min-height: 470px;
  transition: transform .62s cubic-bezier(.2, .72, .25, 1);
  transform-style: preserve-3d;
}

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

.word-card-face {
  position: absolute;
  inset: 0;
  display: flex;
  overflow: hidden;
  align-items: center;
  justify-content: center;
  padding: clamp(25px, 5vw, 48px);
  border: 1px solid rgba(211, 220, 210, .88);
  border-radius: 28px;
  flex-direction: column;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  box-shadow: 0 20px 50px rgba(52, 77, 67, .1);
}

.word-card-front {
  color: var(--ink);
  background:
    radial-gradient(circle at 18% 18%, rgba(255, 255, 255, .72), transparent 24%),
    linear-gradient(145deg, #e5efe5, #c9dfd1);
}

.word-flashcard[data-category="动物"] .word-card-front {
  background: linear-gradient(145deg, #f8e9dc, #efcfb9);
}

.word-flashcard[data-category="食物"] .word-card-front {
  background: linear-gradient(145deg, #fff0c8, #efd392);
}

.word-flashcard[data-category="自然"] .word-card-front {
  background: linear-gradient(145deg, #e4eff2, #bfdce4);
}

.word-flashcard[data-category="学校生活"] .word-card-front {
  background: linear-gradient(145deg, #e8e5f5, #cabfe9);
}

.word-flashcard[data-category="日常用品"] .word-card-front {
  background: linear-gradient(145deg, #e4f0e8, #b9d8c6);
}

.word-front-category,
.word-back-category {
  position: absolute;
  top: 20px;
  left: 22px;
  padding: 5px 10px;
  border-radius: 999px;
  color: var(--green-deep);
  background: rgba(255, 253, 248, .78);
  font-size: 11px;
  font-weight: 800;
}

.word-picture {
  display: grid;
  width: clamp(150px, 28vw, 235px);
  height: clamp(150px, 28vw, 235px);
  margin-bottom: 22px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .7);
  border-radius: 50%;
  background: rgba(255, 253, 248, .64);
  box-shadow: 0 18px 35px rgba(55, 91, 73, .1);
  font-size: clamp(92px, 17vw, 142px);
  line-height: 1;
}

.word-picture[hidden],
.word-text-clue[hidden] {
  display: none;
}

.word-text-clue {
  display: grid;
  width: min(100%, 520px);
  min-height: clamp(150px, 24vw, 210px);
  margin-bottom: 22px;
  padding: 24px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .72);
  border-radius: 28px;
  color: var(--green-deep);
  background:
    radial-gradient(circle at 30% 24%, rgba(255, 255, 255, .9), transparent 28%),
    #edf4ee;
  font-family: var(--serif);
  font-size: clamp(27px, 5vw, 42px);
  font-weight: 800;
  line-height: 1.5;
  text-align: center;
}

.word-card-front strong {
  font-family: var(--serif);
  font-size: clamp(22px, 3vw, 30px);
}

.word-card-front > small {
  margin-top: 9px;
  color: #61736c;
  font-size: 12px;
}

.word-card-back {
  color: var(--ink);
  background: #fffdf8;
  transform: rotateY(180deg);
}

.word-spelling {
  margin-top: 8px;
  font-family: var(--serif);
  font-size: clamp(48px, 8vw, 78px);
  line-height: 1.1;
  letter-spacing: .02em;
}

.word-phonetic {
  margin-top: 8px;
  color: var(--green);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(19px, 3vw, 25px);
}

.word-translation {
  margin-top: 14px;
  color: var(--green-deep);
  font-size: clamp(22px, 3vw, 29px);
  font-weight: 800;
}

.word-example-card {
  display: flex;
  width: min(100%, 540px);
  margin-top: 25px;
  padding: 17px 20px;
  border: 1px solid #e4e9e3;
  border-radius: 16px;
  background: #f4f8f4;
  flex-direction: column;
  gap: 6px;
  text-align: left;
}

.word-example-card small {
  color: var(--green);
  font-size: 11px;
  font-weight: 800;
}

.word-example-card span:nth-child(2) {
  color: var(--ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 17px;
  line-height: 1.55;
}

.word-example-card span:last-child {
  color: var(--muted);
  font-size: 12px;
}

.word-flip-hint {
  margin-top: 17px;
  color: var(--muted);
  font-size: 11px;
}

.word-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 20px;
  gap: 9px;
}

.word-nav-button,
.word-flip-button {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  padding: 9px 15px;
  border-radius: 12px;
  gap: 5px;
  font-size: 13px;
  font-weight: 700;
}

.word-nav-button {
  border: 1px solid #dfe3da;
  color: var(--ink-soft);
  background: #fffdf8;
}

.word-nav-button:hover {
  border-color: #9fc1ae;
  color: var(--green);
}

.word-nav-button svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.word-flip-button {
  color: white;
  background: var(--green);
}

.word-flip-button:hover {
  background: var(--green-deep);
}

.word-study-tip {
  margin: 13px 0 0;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

/* Coming soon */
.coming-card {
  display: grid;
  min-height: 510px;
  overflow: hidden;
  margin-top: 15px;
  border: 1px solid rgba(225, 220, 210, .75);
  border-radius: 30px;
  background: #fffdf8;
  grid-template-columns: .9fr 1.1fr;
  box-shadow: var(--shadow-md);
}

.coming-garden {
  position: relative;
  display: flex;
  overflow: hidden;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(circle at 24% 22%, rgba(255, 255, 255, .78), transparent 22%),
    linear-gradient(145deg, #dcebdf, #a8cfb7);
}

.coming-garden::before {
  position: absolute;
  right: -40px;
  bottom: -100px;
  width: 390px;
  height: 280px;
  border-radius: 50% 50% 0 0;
  background: #7eb494;
  content: "";
}

.coming-garden strong {
  position: relative;
  z-index: 2;
  color: #f9e8a8;
  font-family: var(--serif);
  font-size: 100px;
  letter-spacing: .12em;
  opacity: .88;
  text-shadow: 0 8px 0 rgba(51, 107, 83, .17);
}

.coming-sun {
  position: absolute;
  top: 45px;
  right: 51px;
  width: 95px;
  height: 95px;
  border-radius: 50%;
  background: #f3c963;
  box-shadow: 0 0 0 15px rgba(255, 246, 195, .21);
}

.sprout {
  position: absolute;
  z-index: 3;
  bottom: 38px;
  width: 4px;
  height: 65px;
  border-radius: 4px;
  background: #3b795d;
}

.sprout::before,
.sprout::after {
  position: absolute;
  width: 31px;
  height: 18px;
  border-radius: 100% 0 100% 0;
  background: #4f8c67;
  content: "";
}

.sprout::before {
  top: 14px;
  left: -28px;
  transform: rotate(20deg);
}

.sprout::after {
  top: 2px;
  left: 3px;
  border-radius: 0 100% 0 100%;
  transform: rotate(-13deg);
}

.sprout-one { left: 13%; height: 75px; }
.sprout-two { right: 14%; bottom: 24px; height: 53px; transform: rotate(8deg); }
.sprout-three { left: 35%; bottom: 14px; height: 40px; transform: scale(.8); opacity: .65; }

.coming-copy {
  display: flex;
  justify-content: center;
  padding: 55px clamp(30px, 6vw, 85px);
  flex-direction: column;
}

.coming-copy h1 {
  margin: 4px 0 15px;
  font-family: var(--serif);
  font-size: clamp(32px, 4vw, 45px);
}

.coming-copy > p:not(.section-kicker) {
  max-width: 440px;
  margin: 0 0 22px;
  color: var(--ink-soft);
  font-size: 13px;
  line-height: 1.9;
}

.coming-items {
  display: flex;
  flex-wrap: wrap;
  margin-bottom: 29px;
  gap: 8px;
}

.coming-items span {
  padding: 7px 11px;
  border-radius: 20px;
  color: var(--ink-soft);
  background: #f2f1ea;
  font-size: 12px;
}

.coming-copy .primary-button {
  width: fit-content;
  color: white;
  background: var(--green);
}

.coming-copy .primary-button:hover {
  background: var(--green-deep);
}

/* Dialogs and toast */
dialog {
  width: min(92vw, 400px);
  padding: 0;
  border: 0;
  border-radius: 24px;
  color: var(--ink);
  background: #fffdf8;
  box-shadow: 0 30px 80px rgba(29, 62, 56, .28);
}

dialog::backdrop {
  background: rgba(24, 52, 48, .48);
  backdrop-filter: blur(4px);
}

.name-dialog form {
  position: relative;
  padding: 32px 30px 28px;
}

.dialog-close {
  position: absolute;
  top: 13px;
  right: 14px;
  display: grid;
  width: 29px;
  height: 29px;
  place-items: center;
  border-radius: 50%;
  color: var(--muted);
  background: #f3f2ec;
  font-size: 18px;
}

.dialog-sprout {
  display: grid;
  width: 48px;
  height: 48px;
  margin-bottom: 13px;
  place-items: center;
  border-radius: 16px;
  color: #7c6329;
  background: #f7e7b7;
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 800;
}

.name-dialog h2,
.goal-dialog h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: 25px;
}

.name-dialog p,
.goal-dialog p {
  margin: 6px 0 18px;
  color: var(--muted);
  font-size: 12px;
}

.name-dialog label {
  display: block;
  margin-bottom: 6px;
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 700;
}

.name-dialog input {
  width: 100%;
  height: 44px;
  padding: 0 12px;
  border: 1px solid #ddd9ce;
  border-radius: 11px;
  background: white;
  font-size: 14px;
}

.name-dialog input:focus {
  border-color: var(--green);
  outline: 3px solid rgba(47, 123, 109, .12);
}

.dialog-actions {
  display: flex;
  margin-top: 20px;
  gap: 9px;
}

.dialog-actions button {
  min-height: 42px;
  flex: 1;
  border-radius: 11px;
  font-size: 12px;
  font-weight: 700;
}

.dialog-actions button:first-child {
  color: var(--muted);
  background: #f2f1eb;
}

.dialog-actions .primary-button {
  color: white;
  background: var(--green);
}

.goal-dialog form {
  padding: 34px 30px 29px;
  text-align: center;
}

.goal-dialog-icon {
  display: grid;
  width: 58px;
  height: 58px;
  margin: 0 auto 14px;
  place-items: center;
  border-radius: 50%;
  color: white;
  background: var(--green);
  font-size: 26px;
  box-shadow: 0 0 0 9px #e8f2ec;
}

.goal-dialog .primary-button {
  width: 100%;
  color: white;
  background: var(--green);
}

.toast {
  position: fixed;
  z-index: 100;
  right: 24px;
  bottom: 24px;
  padding: 11px 16px;
  border-radius: 11px;
  color: white;
  background: #264f48;
  box-shadow: 0 10px 28px rgba(31, 67, 60, .22);
  opacity: 0;
  pointer-events: none;
  font-size: 12px;
  transform: translateY(12px);
  transition: opacity .2s ease, transform .2s ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

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

  .sidebar {
    padding-right: 16px;
    padding-left: 16px;
  }

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

  main {
    padding-right: 28px;
    padding-left: 28px;
  }

  .site-footer {
    padding-right: 28px;
    padding-left: 28px;
  }

  .filter-bar {
    align-items: stretch;
    padding: 13px;
    flex-direction: column;
    gap: 10px;
  }

  .filter-group {
    width: 100%;
    min-width: 0;
    flex-wrap: wrap;
  }

  .filter-chips {
    max-width: 100%;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .filter-chips::-webkit-scrollbar {
    display: none;
  }

  .filter-group select {
    width: 100%;
    min-width: 0;
  }

  .hero-card {
    grid-template-columns: 1.12fr .88fr;
  }

  .hero-copy {
    padding-left: 39px;
  }

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

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

  .reader-layout {
    grid-template-columns: minmax(0, 1fr) 340px;
  }

  .reading-paper {
    padding-right: 35px;
    padding-left: 35px;
  }

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

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

  .sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    width: 248px;
    height: 100dvh;
    box-shadow: 20px 0 55px rgba(29, 57, 52, .16);
    transform: translateX(-105%);
    transition: transform .25s ease;
  }

  body.menu-open .sidebar {
    transform: translateX(0);
  }

  body.menu-open::after {
    position: fixed;
    z-index: 25;
    inset: 0;
    background: rgba(24, 52, 48, .4);
    content: "";
  }

  .mobile-header {
    position: sticky;
    z-index: 24;
    top: 0;
    display: flex;
    height: 66px;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    border-bottom: 1px solid rgba(225, 220, 211, .75);
    background: rgba(255, 253, 248, .9);
    backdrop-filter: blur(14px);
  }

  .brand--mobile {
    margin: 0;
  }

  .brand--mobile .brand-mark {
    width: 36px;
    height: 36px;
    border-radius: 12px;
  }

  .brand--mobile .brand-mark svg {
    width: 30px;
    height: 30px;
  }

  .brand--mobile .brand-copy strong {
    font-size: 20px;
  }

  .mobile-menu-button {
    display: flex;
    width: 38px;
    height: 38px;
    align-items: center;
    justify-content: center;
    border-radius: 11px;
    background: #eff3ed;
    flex-direction: column;
    gap: 4px;
  }

  .mobile-menu-button span {
    width: 17px;
    height: 1.5px;
    border-radius: 2px;
    background: var(--ink);
    transition: transform .2s ease, opacity .2s ease;
  }

  body.menu-open .mobile-menu-button span:nth-child(1) {
    transform: translateY(5.5px) rotate(45deg);
  }

  body.menu-open .mobile-menu-button span:nth-child(2) {
    opacity: 0;
  }

  body.menu-open .mobile-menu-button span:nth-child(3) {
    transform: translateY(-5.5px) rotate(-45deg);
  }

  main {
    padding: 24px 20px 16px;
  }

  .site-footer {
    padding-right: 20px;
    padding-left: 20px;
  }

  .hero-card {
    min-height: 400px;
    grid-template-columns: 1fr 230px;
  }

  .hero-copy {
    padding: 37px 10px 33px 30px;
  }

  .hero-copy h1 {
    font-size: 35px;
  }

  .hero-lead {
    max-width: 380px;
  }

  .hero-art {
    padding-top: 80px;
  }

  .sun-disc {
    top: 54px;
    right: -23px;
    width: 180px;
    height: 180px;
  }

  .book-illustration {
    width: 320px;
    margin-right: -71px;
  }

  .floating-note {
    display: none;
  }

  .home-lower-grid {
    grid-template-columns: 1fr;
  }

  .reading-tip {
    align-items: flex-start;
  }

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

  .reader-layout {
    display: block;
  }

  .quiz-panel {
    position: static;
    margin-top: 17px;
  }

  .quiz-content {
    max-height: none;
  }

  .quiz-start-state {
    padding-top: 23px;
  }

  .quiz-orbit {
    display: none;
  }

  .coming-card {
    grid-template-columns: .75fr 1.25fr;
  }

  .coming-garden strong {
    font-size: 70px;
  }

  body.reader-focus main {
    padding: 52px 15px 15px;
  }
}

@media (max-width: 650px) {
  body {
    font-size: 15px;
  }

  main {
    padding: 18px 14px 12px;
  }

  .site-footer {
    display: block;
    padding: 12px 14px 22px;
    line-height: 2;
  }

  .home-topline {
    margin-bottom: 13px;
  }

  .date-line {
    font-size: 12px;
  }

  .streak-chip {
    padding: 6px 9px;
    font-size: 12px;
  }

  .hero-card {
    display: block;
    min-height: 520px;
    border-radius: 24px;
  }

  .hero-copy {
    z-index: 3;
    padding: 29px 23px 0;
  }

  .eyebrow {
    margin-bottom: 10px;
    font-size: 12px;
  }

  .hero-copy h1 {
    font-size: 32px;
  }

  .hero-lead {
    margin: 13px 0 18px;
    font-size: 12px;
    line-height: 1.8;
  }

  .hero-actions {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .hero-actions .primary-button {
    min-height: 42px;
    padding: 0 18px;
  }

  .text-button {
    display: none;
  }

  .hero-stats {
    justify-content: space-between;
    margin-top: 19px;
    gap: 8px;
  }

  .hero-stats div {
    min-width: 0;
    flex: 1;
    text-align: center;
  }

  .hero-stats strong {
    font-size: 17px;
  }

  .hero-stats span {
    font-size: 12px;
    line-height: 1.35;
    white-space: normal;
  }

  .hero-art {
    position: absolute;
    right: 0;
    bottom: -7px;
    left: 0;
    height: 265px;
    padding: 0;
  }

  .sun-disc {
    top: 31px;
    right: 6px;
    width: 180px;
    height: 180px;
  }

  .book-illustration {
    width: 365px;
    max-width: 105%;
    margin: 0;
  }

  .section-heading {
    margin-top: 27px;
  }

  .section-heading h2,
  .recommend-head h2,
  .growth-head h2,
  .history-head h2 {
    font-size: 18px;
  }

  .skill-grid {
    gap: 9px;
  }

  .skill-card {
    min-height: 168px;
    padding: 15px;
    border-radius: 17px;
  }

  .skill-icon {
    width: 35px;
    height: 35px;
    border-radius: 11px;
  }

  .skill-icon svg {
    width: 21px;
    height: 21px;
  }

  .skill-number {
    top: 17px;
    right: 15px;
  }

  .skill-card strong {
    margin-top: 11px;
    font-size: 14px;
  }

  .skill-card p {
    min-height: 30px;
    margin-bottom: 6px;
  }

  .home-lower-grid {
    margin-top: 20px;
    gap: 12px;
  }

  .recommend-card,
  .week-card,
  .growth-card,
  .calendar-card,
  .history-card {
    padding: 18px;
  }

  .daily-card-content {
    min-height: 139px;
    grid-template-columns: 1fr 105px;
  }

  .daily-copy {
    padding: 16px 4px 16px 15px;
  }

  .daily-copy h3 {
    font-size: 18px;
  }

  .mini-book {
    width: 82px;
    height: 68px;
  }

  .mini-book::before,
  .mini-book::after {
    width: 41px;
    height: 59px;
  }

  .mini-book span {
    top: 20px;
    left: 39px;
    height: 42px;
  }

  .reading-tip {
    margin-top: 13px;
    padding: 12px;
  }

  .reading-tip p {
    line-height: 1.65;
  }

  .reading-tip > button {
    display: none;
  }

  .page-heading {
    position: relative;
    align-items: flex-start;
    margin-bottom: 20px;
  }

  .page-heading h1 {
    font-size: 29px;
    line-height: 1.35;
  }

  .library-badge {
    display: none;
  }

  .filter-bar {
    align-items: flex-start;
    padding: 12px;
    flex-direction: column;
    gap: 10px;
  }

  .filter-group {
    width: 100%;
  }

  .filter-group:last-child {
    padding-top: 9px;
    border-top: 1px solid var(--line);
  }

  .filter-chips {
    overflow-x: auto;
    scrollbar-width: none;
  }

  .filter-chip {
    flex: 0 0 auto;
  }

  .filter-group select {
    flex: 1;
  }

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

  .passage-card {
    min-height: 205px;
  }

  .reader-topbar {
    margin-bottom: 10px;
  }

  .reading-timer {
    min-width: 68px;
    padding: 6px 8px;
  }

  .icon-control {
    width: 31px;
    height: 31px;
  }

  .print-control {
    width: 31px;
    height: 31px;
    padding: 0;
  }

  .print-control > span {
    display: none;
  }

  .reading-paper {
    padding: 29px 19px 28px;
    border-radius: 20px;
  }

  .paper-header h1 {
    font-size: 29px;
  }

  .paper-header > p {
    font-size: 12px;
  }

  .paper-meta span:last-child {
    display: none;
  }

  .paper-meta span + span::before {
    display: none;
  }

  .paper-divider {
    margin: 19px auto 20px;
  }

  .article-body {
    font-size: 16px;
    letter-spacing: .02em;
    line-height: 2.05;
  }

  .article-body.font-large {
    font-size: 19px;
  }

  .article-paragraph {
    margin-bottom: 12px;
    padding-right: 2px;
    padding-left: 7px;
  }

  .article-paragraph.is-marked::after {
    right: -4px;
  }

  .annotation-key {
    align-items: flex-end;
    flex-direction: column;
    gap: 5px;
  }

  .paper-footer {
    margin-top: 24px;
  }

  .quiz-start-state {
    padding: 20px 18px;
  }

  .quiz-content {
    padding: 19px 17px 17px;
  }

  .question-feedback {
    font-size: 12px;
  }

  .record-stats {
    gap: 8px;
  }

  .record-stats article {
    min-height: 78px;
    padding: 12px;
    gap: 9px;
  }

  .stat-icon {
    width: 35px;
    height: 35px;
    border-radius: 11px;
  }

  .stat-icon svg {
    width: 18px;
    height: 18px;
  }

  .record-stats strong {
    font-size: 20px;
  }

  .record-stats small {
    font-size: 11px;
    line-height: 1.4;
  }

  .streak-emblem {
    width: 90px;
    height: 80px;
    border-radius: 17px;
  }

  .streak-emblem strong {
    font-size: 24px;
  }

  .calendar-days {
    gap: 4px;
  }

  .calendar-day i {
    border-radius: 6px;
  }

  .calendar-summary span {
    max-width: 170px;
  }

  .history-item {
    grid-template-columns: 37px minmax(0, 1fr) 50px;
  }

  .history-detail {
    display: none;
  }

  .history-date {
    display: none;
  }

  .history-score {
    text-align: right;
  }

  .coming-card {
    display: flex;
    min-height: auto;
    margin-top: 6px;
    border-radius: 22px;
    flex-direction: column;
  }

  .coming-garden {
    min-height: 230px;
  }

  .coming-garden strong {
    font-size: 64px;
  }

  .coming-copy {
    padding: 29px 23px 31px;
  }

  .coming-copy h1 {
    font-size: 29px;
  }

  .toast {
    right: 14px;
    bottom: 14px;
    left: 14px;
    text-align: center;
  }
}

@media (max-width: 900px) {
  .filter-bar {
    align-items: stretch;
    padding: 13px;
    flex-direction: column;
    gap: 10px;
  }

  .filter-group {
    width: 100%;
    min-width: 0;
    flex-wrap: wrap;
  }

  .filter-chips {
    max-width: 100%;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .filter-chips::-webkit-scrollbar {
    display: none;
  }

  .filter-group select {
    width: 100%;
    min-width: 0;
  }

  .grade-subtopics-grid {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 650px) {
  .library-meta {
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 8px;
  }

  .library-meta-actions {
    margin-left: auto;
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .passage-actions {
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .plan-seal {
    display: none;
  }

  .plan-note {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .roadmap::before {
    display: none;
  }

  .semester-card {
    display: block;
  }

  .semester-label {
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    flex-direction: row;
  }

  .semester-label span {
    margin-top: 0;
    writing-mode: horizontal-tb;
  }

  .semester-body {
    padding: 16px 14px;
  }

  .required-book-grid,
  .semester-tasks {
    grid-template-columns: 1fr;
  }

  .grade-subtopics {
    padding: 13px;
  }

  .grade-subtopics-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 5px;
  }
}

@media (max-width: 650px) {
  .word-study-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .word-deck-badge {
    margin-top: 0;
  }

  .word-deck-panel {
    padding: 15px;
    border-radius: 21px;
  }

  .word-grade-row {
    align-items: stretch;
  }

  .word-category-label {
    flex: 1 0 100%;
  }

  .word-filter-select {
    flex: 1 1 140px;
  }

  .word-filter-select select {
    width: 100%;
  }

  .word-progress-row {
    margin-top: 18px;
  }

  .word-flashcard,
  .word-flashcard-inner {
    min-height: 455px;
  }

  .word-card-face {
    padding: 26px 18px;
    border-radius: 22px;
  }

  .word-picture {
    width: 150px;
    height: 150px;
    font-size: 92px;
  }

  .word-example-card {
    margin-top: 18px;
    padding: 14px 15px;
  }

  .word-example-card span:nth-child(2) {
    font-size: 15px;
  }

  .word-controls {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .word-flip-button {
    grid-column: 1 / -1;
    grid-row: 1;
  }
}

@media print {
  @page {
    size: A4;
    margin: 15mm;
  }

  html,
  body {
    min-width: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    color: #111 !important;
    background: white !important;
  }

  body > * {
    display: none !important;
  }

  body > .print-sheet {
    display: block !important;
  }

  .print-sheet {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    color: #111;
    background: white;
    font-family: "Noto Serif SC", "Songti SC", SimSun, serif;
    font-size: 11pt;
    line-height: 1.75;
  }

  .print-sheet *,
  .print-sheet *::before,
  .print-sheet *::after {
    box-sizing: border-box;
  }

  .print-header {
    padding-bottom: 12pt;
    border-bottom: 2px solid #222;
  }

  .print-header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 9pt;
    gap: 12pt;
  }

  .print-brand,
  .print-date {
    color: #333;
    font-family: "Microsoft YaHei", sans-serif;
    font-size: 9pt;
  }

  .print-brand {
    font-weight: 700;
    letter-spacing: .08em;
  }

  .print-date {
    color: #555;
    text-align: right;
    white-space: nowrap;
  }

  .print-header h1 {
    margin: 0;
    font-size: 24pt;
    line-height: 1.35;
    text-align: center;
  }

  .print-header > p {
    margin: 5pt 0 0;
    color: #333;
    font-size: 10pt;
    text-align: center;
  }

  .print-meta {
    display: flex;
    justify-content: center;
    margin-top: 7pt;
    color: #444;
    gap: 12pt;
    font-family: "Microsoft YaHei", sans-serif;
    font-size: 9pt;
  }

  .print-source {
    margin-top: 10pt;
    padding: 7pt 9pt;
    border: 1px solid #bbb;
    color: #333;
    font-family: "Microsoft YaHei", sans-serif;
    font-size: 8.5pt;
  }

  .print-source p {
    margin: 2pt 0;
    overflow-wrap: anywhere;
  }

  .print-article,
  .print-questions {
    margin-top: 12pt;
  }

  .print-article h2,
  .print-questions h2 {
    margin: 0 0 7pt;
    padding-left: 8pt;
    border-left: 4px solid #333;
    font-size: 14pt;
  }

  .print-article {
    column-count: 2;
    column-gap: 16pt;
    column-rule: 1px solid #ddd;
    font-size: 10pt;
    line-height: 1.58;
  }

  .print-article h2 {
    column-span: all;
  }

  .print-article p {
    margin: 0 0 6pt;
    text-align: justify;
    text-indent: 2em;
    break-inside: avoid;
    orphans: 3;
    widows: 3;
  }

  .print-article p.print-material {
    padding: 5pt 7pt;
    border: 1px solid #aaa;
    text-indent: 0;
  }

  .print-section-heading {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 4pt;
  }

  .print-section-heading > span {
    font-size: 9pt;
    font-weight: 700;
  }

  .print-questions ol {
    margin: 0;
    padding: 0;
    list-style: none;
  }

  .print-question {
    margin: 0 0 12pt;
    break-inside: avoid;
  }

  .print-question-title {
    display: grid;
    align-items: start;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 5pt;
  }

  .print-question-title strong {
    font-weight: 600;
    overflow-wrap: anywhere;
  }

  .print-question-title em {
    font-size: 9pt;
    font-style: normal;
    white-space: nowrap;
  }

  .print-options {
    display: grid;
    margin: 7pt 0 0 18pt;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 3pt 14pt;
  }

  .print-options span {
    break-inside: avoid;
    overflow-wrap: anywhere;
  }

  .print-options b {
    font-weight: 700;
  }

  .print-answer-lines {
    display: flex;
    margin: 12pt 0 0 18pt;
    flex-direction: column;
    gap: 20pt;
  }

  .print-answer-lines span {
    height: 1px;
    border-bottom: 1px solid #777;
  }

  .print-answers {
    break-before: page;
    page-break-before: always;
    margin-top: 0;
    padding-top: 0;
  }

  .print-sheet.compact-exam .print-header {
    padding-bottom: 8pt;
  }

  .print-sheet.compact-exam .print-header-top {
    margin-bottom: 5pt;
  }

  .print-sheet.compact-exam .print-header h1 {
    font-size: 20pt;
  }

  .print-sheet.compact-exam .print-header > p {
    margin-top: 3pt;
  }

  .print-sheet.compact-exam .print-meta {
    margin-top: 4pt;
  }

  .print-sheet.compact-exam .print-source {
    margin-top: 6pt;
    padding: 5pt 7pt;
    font-size: 7.5pt;
  }

  .print-sheet.compact-exam .print-article,
  .print-sheet.compact-exam .print-questions {
    margin-top: 8pt;
  }

  .print-sheet.compact-exam .print-article {
    font-size: 9pt;
    line-height: 1.48;
  }

  .print-sheet.compact-exam .print-article p {
    margin-bottom: 4pt;
  }

  .print-sheet.compact-exam .print-question {
    margin-bottom: 8pt;
  }

  .print-sheet.compact-exam .print-questions {
    font-size: 9.5pt;
  }

  .print-sheet.compact-exam .print-answer-lines {
    margin-top: 7pt;
    gap: 13pt;
  }

  .print-answers ol {
    margin: 0;
    padding: 0;
    list-style: none;
  }

  .print-answer {
    margin: 0 0 15pt;
    padding: 9pt 10pt;
    border: 1px solid #aaa;
    break-inside: avoid;
  }

  .print-answer-title {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 5pt;
  }

  .print-answer-title strong {
    font-weight: 600;
    overflow-wrap: anywhere;
  }

  .print-answer p {
    margin: 6pt 0 0;
    text-align: justify;
    overflow-wrap: anywhere;
  }

  .print-correct-answer {
    padding: 4pt 7pt;
    border-left: 3px solid #333;
    background: #eee;
    font-weight: 700;
  }

  .print-model-answer {
    line-height: 1.7;
  }

  .print-rubric {
    margin-top: 8pt;
    padding-top: 6pt;
    border-top: 1px dashed #999;
  }

  .print-rubric ul {
    margin: 4pt 0 0;
    padding-left: 16pt;
  }

  .print-rubric li {
    margin: 2pt 0;
  }

}

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