:root {
  --ink: #18312c;
  --ink-soft: #5f6f69;
  --paper: #f7f1e7;
  --paper-deep: #efe5d6;
  --white: #fffdf8;
  --green: #1d5b50;
  --green-mid: #487f70;
  --green-pale: #dce9df;
  --coral: #d86c4f;
  --coral-pale: #fae2d6;
  --yellow: #e8bb58;
  --yellow-pale: #f9edc9;
  --line: rgba(24, 49, 44, 0.13);
  --shadow: 0 18px 60px rgba(42, 58, 48, 0.1);
  --radius-lg: 30px;
  --radius-md: 20px;
  --radius-sm: 12px;
  --serif: "Noto Serif SC", "Songti SC", "STSong", Georgia, serif;
  --sans: "Noto Sans SC", "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  --ipa: "Charis SIL", "Doulos SIL", "Noto Serif", "Times New Roman", serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

body.font-large {
  font-size: 18px;
}

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

button {
  font: inherit;
}

button:focus-visible,
a:focus-visible {
  outline: 3px solid var(--yellow);
  outline-offset: 4px;
}

a {
  color: inherit;
}

[hidden] {
  display: none !important;
}

.skip-link {
  position: fixed;
  top: -100px;
  left: 24px;
  z-index: 999;
  padding: 10px 18px;
  background: var(--ink);
  color: #fff;
  border-radius: 0 0 10px 10px;
}

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

.button-reset {
  border: 0;
  padding: 0;
  background: none;
  color: inherit;
  cursor: pointer;
}

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

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 30;
  width: 240px;
  display: flex;
  flex-direction: column;
  padding: 32px 24px 24px;
  border-right: 1px solid var(--line);
  background: rgba(250, 246, 238, 0.9);
  backdrop-filter: blur(18px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
  margin-bottom: 42px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  border-radius: 14px;
  background: var(--green);
  color: var(--yellow-pale);
}

.brand-mark svg {
  width: 34px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  font-family: var(--serif);
  font-size: 19px;
  letter-spacing: 0.08em;
}

.brand small {
  margin-top: 1px;
  color: var(--ink-soft);
  font-size: 11px;
  letter-spacing: 0.15em;
}

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

.nav-item {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 14px;
  border: 0;
  border-radius: 13px;
  background: transparent;
  color: var(--ink-soft);
  text-align: left;
  cursor: pointer;
  transition: 160ms ease;
}

.nav-item::before {
  content: "";
  position: absolute;
  inset: 11px auto 11px 0;
  width: 3px;
  border-radius: 3px;
  background: transparent;
}

.nav-item:hover {
  background: rgba(29, 91, 80, 0.07);
  color: var(--ink);
}

.nav-item.is-active {
  background: var(--green);
  color: #fffdf8;
  box-shadow: 0 8px 22px rgba(29, 91, 80, 0.18);
}

.nav-item.is-active::before {
  background: var(--yellow);
}

.nav-icon {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border: 1px solid currentColor;
  border-radius: 9px;
  font-family: var(--serif);
  font-size: 13px;
  opacity: 0.82;
}

.sidebar-note {
  display: flex;
  gap: 11px;
  margin-top: auto;
  padding: 16px;
  border-radius: 17px;
  background: var(--yellow-pale);
  color: #6f5728;
}

.sidebar-note p,
.source-note p {
  margin: 0;
  font-size: 12px;
  line-height: 1.6;
}

.note-sun {
  font-size: 17px;
}

.source-note {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 18px;
  padding: 0 5px;
  color: #86908a;
}

.source-dot {
  width: 6px;
  height: 6px;
  flex: 0 0 6px;
  margin-top: 7px;
  border-radius: 50%;
  background: var(--green-mid);
}

.page-column {
  grid-column: 2;
  min-width: 0;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  min-height: 82px;
  display: flex;
  align-items: center;
  gap: 18px;
  justify-content: space-between;
  padding: 18px clamp(28px, 4.5vw, 76px);
  border-bottom: 1px solid rgba(24, 49, 44, 0.08);
  background: rgba(247, 241, 231, 0.88);
  backdrop-filter: blur(16px);
}

.topbar-title .eyebrow {
  display: block;
  margin-bottom: 2px;
}

.topbar-title strong {
  font-family: var(--serif);
  font-size: 15px;
  font-weight: 600;
}

.eyebrow {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--green-mid);
}

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

.font-control {
  display: flex;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}

.font-control button {
  width: 34px;
  height: 34px;
  border: 0;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  font-family: var(--serif);
}

.font-control button + button {
  border-left: 1px solid var(--line);
  font-size: 19px;
}

.font-control button.is-active {
  background: var(--white);
  color: var(--coral);
}

.sound-setting {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 36px;
  padding: 7px 13px;
  border: 1px solid var(--line);
  border-radius: 99px;
  background: rgba(255, 253, 248, 0.6);
  color: var(--ink-soft);
  font-size: 12px;
  cursor: pointer;
}

.sound-setting.is-on .sound-label::after {
  content: " 开";
  color: var(--coral);
}

.sound-bars {
  display: flex;
  align-items: center;
  gap: 2px;
  height: 15px;
}

.sound-bars i {
  display: block;
  width: 2px;
  border-radius: 2px;
  background: currentColor;
}

.sound-bars i:nth-child(1) {
  height: 5px;
}

.sound-bars i:nth-child(2) {
  height: 12px;
}

.sound-bars i:nth-child(3) {
  height: 8px;
}

.sound-setting.is-on .sound-bars i {
  animation: soundbar 0.9s ease-in-out infinite alternate;
}

.sound-setting.is-on .sound-bars i:nth-child(2) {
  animation-delay: 0.2s;
}

.sound-setting.is-on .sound-bars i:nth-child(3) {
  animation-delay: 0.4s;
}

.mobile-menu {
  display: none;
  width: 38px;
  height: 38px;
  padding: 9px;
  border-radius: 9px;
  background: var(--white);
}

.mobile-menu span {
  display: block;
  height: 2px;
  margin: 4px 0;
  background: var(--ink);
}

main {
  max-width: 1480px;
  margin: 0 auto;
  padding: clamp(30px, 4vw, 58px) clamp(28px, 4.5vw, 76px) 68px;
}

.view {
  animation: pageIn 360ms ease both;
}

.welcome-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(300px, 0.8fr);
  gap: 24px;
}

.hero {
  position: relative;
  min-height: 480px;
  overflow: hidden;
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  border-radius: var(--radius-lg);
  background: var(--green);
  color: #fffaf0;
  box-shadow: var(--shadow);
}

.hero::before {
  content: "";
  position: absolute;
  top: -60px;
  left: -50px;
  width: 230px;
  height: 230px;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 50%;
  box-shadow: 0 0 0 45px rgba(255, 255, 255, 0.025), 0 0 0 90px rgba(255, 255, 255, 0.018);
}

.hero-copy {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 48px 20px 48px 48px;
}

.pill {
  width: max-content;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #f9df9f;
  font-size: 11px;
  letter-spacing: 0.08em;
}

.pill span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 0 4px rgba(249, 223, 159, 0.12);
}

.hero h1 {
  margin: 22px 0 18px;
  font-family: var(--serif);
  font-size: clamp(42px, 5vw, 68px);
  font-weight: 600;
  line-height: 1.14;
  letter-spacing: -0.05em;
}

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

.hero h1 em::after {
  content: "";
  position: absolute;
  left: 4px;
  right: 2px;
  bottom: -6px;
  height: 7px;
  border-top: 2px solid rgba(244, 211, 131, 0.62);
  border-radius: 50%;
  transform: rotate(-1deg);
}

.hero-copy > p {
  max-width: 470px;
  margin: 0;
  color: rgba(255, 250, 240, 0.72);
  font-size: 14px;
  line-height: 1.9;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 22px;
  margin-top: 28px;
}

.primary-button,
.secondary-button,
.outline-button,
.text-button,
.check-button,
.learn-button {
  cursor: pointer;
  transition: transform 160ms ease, background 160ms ease, color 160ms ease, border-color 160ms ease;
}

.primary-button {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  min-height: 50px;
  padding: 12px 22px;
  border: 0;
  border-radius: 13px;
  background: #f6d98b;
  color: #25443c;
  font-size: 14px;
  font-weight: 700;
  box-shadow: 0 8px 24px rgba(12, 35, 29, 0.18);
}

.primary-button:hover {
  transform: translateY(-2px);
  background: #ffe5a6;
}

.primary-button > span {
  font-size: 21px;
  line-height: 1;
}

.text-button {
  padding: 8px 0;
  border: 0;
  border-bottom: 1px solid currentColor;
  background: transparent;
  color: rgba(255, 250, 240, 0.78);
  font-size: 12px;
}

.text-button:hover {
  color: #fff;
}

.hero-visual {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 420px;
  padding: 25px;
}

.arch {
  position: absolute;
  border-radius: 160px 160px 20px 20px;
}

.arch-back {
  width: 78%;
  height: 68%;
  bottom: 9%;
  background: #e7bf62;
  transform: rotate(5deg);
  opacity: 0.84;
}

.arch-front {
  width: 71%;
  height: 65%;
  bottom: 12%;
  background: #f2dfb5;
  transform: rotate(-4deg);
}

.sound-portrait {
  position: relative;
  z-index: 2;
  width: 72%;
  aspect-ratio: 0.92;
  display: grid;
  place-items: center;
  background: #d56c50;
  border-radius: 50% 50% 18px 18px;
  box-shadow: 0 20px 44px rgba(28, 44, 36, 0.2);
  overflow: hidden;
}

.face {
  position: absolute;
  top: 23%;
  width: 72%;
  aspect-ratio: 0.9;
  border: 3px solid rgba(255, 247, 232, 0.88);
  border-radius: 48% 48% 45% 45%;
}

.face-eye {
  position: absolute;
  top: 44%;
  width: 9px;
  height: 4px;
  border-radius: 50%;
  border-top: 3px solid #fff5e1;
}

.face-eye.left {
  left: 28%;
}

.face-eye.right {
  right: 28%;
}

.face-nose {
  position: absolute;
  left: 49%;
  top: 42%;
  width: 10px;
  height: 27%;
  border-left: 2px solid rgba(255, 247, 232, 0.64);
  border-bottom: 2px solid rgba(255, 247, 232, 0.64);
  border-radius: 0 0 0 10px;
}

.face-mouth {
  position: absolute;
  left: 36%;
  bottom: 17%;
  width: 29%;
  height: 11%;
  border: 3px solid #fff5e1;
  border-top: 0;
  border-radius: 0 0 50% 50%;
}

.floating-letter {
  position: absolute;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  z-index: 4;
  border-radius: 50%;
  background: var(--white);
  color: var(--green);
  font-family: var(--ipa);
  font-size: 24px;
  font-weight: 700;
  box-shadow: 0 8px 20px rgba(42, 42, 25, 0.13);
}

.letter-one {
  top: 14%;
  right: 8%;
  transform: rotate(8deg);
}

.letter-two {
  left: 5%;
  bottom: 27%;
  transform: rotate(-8deg);
}

.letter-three {
  right: 14%;
  bottom: 13%;
  width: 44px;
  height: 44px;
  font-size: 21px;
  transform: rotate(5deg);
}

.mouth-guide {
  position: absolute;
  bottom: 2.5%;
  left: 0;
  right: 0;
  padding: 10px;
  background: rgba(38, 44, 35, 0.42);
  color: #fff7e9;
  font-size: 10px;
  text-align: center;
  letter-spacing: 0.07em;
}

.hero-caption {
  position: absolute;
  z-index: 5;
  bottom: 2%;
  right: 5%;
  color: rgba(255, 250, 240, 0.65);
  font-family: var(--serif);
  font-size: 11px;
  writing-mode: vertical-rl;
  letter-spacing: 0.18em;
}

.today-card {
  display: flex;
  flex-direction: column;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: rgba(255, 253, 248, 0.73);
}

.today-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.today-head h2 {
  margin: 6px 0 0;
  font-family: var(--serif);
  font-size: 22px;
}

.tiny-badge {
  flex: 0 0 auto;
  padding: 4px 9px;
  border-radius: 99px;
  background: var(--coral-pale);
  color: #a14b38;
  font-size: 10px;
}

.mini-sound-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 23px 0;
}

.mini-sound {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 12px 14px;
  border: 1px solid transparent;
  border-radius: 15px;
  text-align: left;
  cursor: pointer;
  transition: 160ms ease;
}

.mini-sound:hover {
  transform: translateX(4px);
  box-shadow: 0 5px 15px rgba(42, 58, 48, 0.08);
}

.sound-green {
  background: var(--green-pale);
}

.sound-coral {
  background: var(--coral-pale);
}

.sound-yellow {
  background: var(--yellow-pale);
}

.sound-symbol {
  width: 45px;
  font-family: var(--ipa);
  font-size: 25px;
  font-weight: 700;
  color: var(--ink);
}

.sound-example {
  flex: 1;
}

.sound-example strong,
.sound-example small {
  display: block;
}

.sound-example strong {
  font-size: 13px;
}

.sound-example small {
  color: var(--ink-soft);
  font-size: 10px;
}

.play-dot {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid rgba(24, 49, 44, 0.18);
  font-size: 8px;
}

.mini-sound.is-learned .play-dot {
  background: var(--green);
  color: white;
}

.mini-sound.is-learned .play-dot::before {
  content: "✓";
  font-size: 12px;
}

.mini-sound.is-learned .play-dot {
  font-size: 0;
}

.progress-block {
  margin-top: auto;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.progress-label {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
}

.progress-label strong {
  color: var(--green);
}

.progress-track {
  height: 5px;
  margin-top: 8px;
  overflow: hidden;
  border-radius: 99px;
  background: #e9e4da;
}

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

.progress-block p {
  margin: 8px 0 0;
  color: var(--ink-soft);
  font-size: 10px;
}

.learning-path {
  margin-top: 58px;
}

.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 22px;
}

.section-heading h2 {
  margin: 4px 0 0;
  font-family: var(--serif);
  font-size: clamp(25px, 2.4vw, 34px);
  font-weight: 600;
}

.section-heading > p {
  max-width: 350px;
  margin: 0;
  color: var(--ink-soft);
  font-size: 12px;
  text-align: right;
}

.path-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(145px, 1fr));
  gap: 12px;
  overflow-x: auto;
  padding: 0 0 12px;
  scrollbar-width: thin;
}

.path-step {
  position: relative;
  min-width: 145px;
  min-height: 220px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 19px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 253, 248, 0.62);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  transition: 180ms ease;
}

.path-step:hover {
  transform: translateY(-4px);
  border-color: rgba(29, 91, 80, 0.3);
  box-shadow: 0 13px 30px rgba(42, 58, 48, 0.08);
}

.path-step.is-current {
  background: var(--yellow-pale);
  border-color: #e4c16e;
}

.path-step.is-complete {
  background: var(--green-pale);
}

.step-day {
  color: var(--green-mid);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.12em;
}

.step-number {
  position: absolute;
  right: 10px;
  top: 2px;
  color: rgba(24, 49, 44, 0.06);
  font-family: var(--serif);
  font-size: 67px;
  font-weight: 700;
  line-height: 1;
}

.path-step strong {
  position: relative;
  margin-top: 23px;
  font-family: var(--serif);
  font-size: 16px;
  line-height: 1.5;
}

.path-step small {
  position: relative;
  margin-top: 9px;
  color: var(--ink-soft);
  font-family: var(--ipa);
  font-size: 12px;
}

.step-status {
  position: relative;
  margin-top: auto;
  padding-top: 18px;
  color: var(--green);
  font-size: 10px;
}

.principles {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin-top: 42px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.principles article {
  display: flex;
  gap: 15px;
  padding: 28px 24px;
}

.principles article + article {
  border-left: 1px solid var(--line);
}

.principle-number {
  color: var(--coral);
  font-family: var(--serif);
  font-size: 12px;
}

.principles h3 {
  margin: 0 0 6px;
  font-family: var(--serif);
  font-size: 16px;
}

.principles p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 11px;
  line-height: 1.7;
}

.page-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 30px;
  margin-bottom: 34px;
}

.page-heading h1 {
  margin: 5px 0 10px;
  font-family: var(--serif);
  font-size: clamp(31px, 4vw, 48px);
  font-weight: 600;
  line-height: 1.28;
  letter-spacing: -0.035em;
}

.page-heading p {
  max-width: 620px;
  margin: 0;
  color: var(--ink-soft);
  font-size: 13px;
}

.outline-button {
  flex: 0 0 auto;
  padding: 10px 16px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: rgba(255, 253, 248, 0.48);
  color: var(--ink);
  font-size: 12px;
}

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

.chart-progress {
  display: grid;
  grid-template-columns: auto minmax(120px, 1fr) auto auto;
  align-items: center;
  gap: 18px;
  margin-bottom: 28px;
  padding: 15px 18px;
  border-radius: 14px;
  background: rgba(255, 253, 248, 0.68);
}

.chart-progress > div:first-child {
  display: flex;
  align-items: baseline;
  gap: 8px;
  color: var(--ink-soft);
  font-size: 11px;
}

.chart-progress strong {
  color: var(--ink);
  font-size: 17px;
}

.chart-progress .progress-track {
  margin: 0;
}

.chart-progress p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 10px;
}

.local-audio-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 9px;
  border-radius: 99px;
  background: var(--yellow-pale);
  color: #715722;
  font-size: 9px;
  white-space: nowrap;
}

.local-audio-badge i {
  display: grid;
  place-items: center;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  background: var(--yellow);
  color: var(--ink);
  font-style: normal;
  font-weight: 700;
}

.chart-section {
  padding: 24px 0 30px;
  border-top: 1px solid var(--line);
}

.chart-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 19px;
}

.chart-title {
  display: flex;
  gap: 14px;
}

.chart-index {
  padding-top: 4px;
  color: var(--coral);
  font-family: var(--serif);
  font-size: 11px;
}

.chart-title h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: 22px;
}

.chart-title p {
  margin: 3px 0 0;
  color: var(--ink-soft);
  font-size: 11px;
}

.chart-count {
  padding: 3px 10px;
  border: 1px solid var(--line);
  border-radius: 99px;
  color: var(--ink-soft);
  font-size: 10px;
}

.phoneme-grid {
  display: grid;
  grid-template-columns: repeat(8, minmax(76px, 1fr));
  gap: 10px;
}

.phoneme-card {
  position: relative;
  min-height: 106px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: flex-start;
  padding: 14px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: rgba(255, 253, 248, 0.66);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  transition: transform 160ms ease, background 160ms ease, border-color 160ms ease;
}

.phoneme-card:nth-child(4n + 1) {
  background: rgba(220, 233, 223, 0.55);
}

.phoneme-card:nth-child(4n + 2) {
  background: rgba(250, 226, 214, 0.55);
}

.phoneme-card:nth-child(4n + 3) {
  background: rgba(249, 237, 201, 0.6);
}

.phoneme-card:hover {
  transform: translateY(-4px);
  border-color: rgba(29, 91, 80, 0.3);
  background: var(--white);
  box-shadow: 0 10px 24px rgba(42, 58, 48, 0.08);
}

.phoneme-card .phoneme-symbol {
  font-family: var(--ipa);
  font-size: clamp(26px, 2.6vw, 35px);
  line-height: 1.1;
}

.phoneme-card .phoneme-word {
  color: var(--ink-soft);
  font-family: var(--sans);
  font-size: 10px;
}

.phoneme-card .learned-check {
  position: absolute;
  right: 9px;
  top: 9px;
  width: 17px;
  height: 17px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--green);
  color: white;
  font-size: 10px;
  opacity: 0;
  transform: scale(0.5);
  transition: 160ms ease;
}

.phoneme-card.is-learned {
  border-color: rgba(29, 91, 80, 0.34);
}

.phoneme-card.is-learned .learned-check {
  opacity: 1;
  transform: scale(1);
}

.authority-box {
  display: flex;
  gap: 24px;
  margin-top: 28px;
  padding: 30px;
  border-radius: var(--radius-md);
  background: var(--green);
  color: #fffaf0;
}

.authority-mark {
  width: 62px;
  height: 62px;
  flex: 0 0 62px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  color: var(--yellow);
  font-family: var(--serif);
  font-size: 22px;
}

.authority-box .eyebrow {
  color: #a8c8bd;
}

.authority-box h2 {
  margin: 6px 0 8px;
  font-family: var(--serif);
  font-size: 22px;
}

.authority-box p {
  max-width: 700px;
  margin: 0;
  color: rgba(255, 250, 240, 0.72);
  font-size: 11px;
}

.source-links {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 18px;
}

.source-links a {
  padding: 6px 10px;
  border: 1px solid rgba(255, 255, 255, 0.19);
  border-radius: 8px;
  color: #fffaf0;
  font-size: 10px;
  text-decoration: none;
}

.source-links a:hover {
  background: rgba(255, 255, 255, 0.08);
}

.step-indicator {
  display: flex;
  align-items: baseline;
  padding: 12px 17px;
  border: 1px solid var(--line);
  border-radius: 12px;
}

.step-indicator strong {
  font-family: var(--serif);
  font-size: 30px;
  color: var(--coral);
}

.step-indicator span {
  margin-left: 4px;
  color: var(--ink-soft);
  font-size: 11px;
}

.blend-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(290px, 0.7fr);
  gap: 22px;
}

.blend-card {
  min-height: 430px;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: 0 15px 40px rgba(42, 58, 48, 0.06);
}

.blend-context {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--ink-soft);
  font-size: 10px;
}

.pill.light {
  background: var(--green-pale);
  border: 0;
  color: var(--green);
}

.blend-word-parts {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
  gap: 13px;
  margin: auto 0 20px;
}

.sound-part {
  min-width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  padding: 0 16px;
  border: 0;
  border-radius: 50%;
  background: var(--yellow-pale);
  color: var(--ink);
  font-family: var(--ipa);
  font-size: 30px;
  font-weight: 700;
  cursor: pointer;
  transition: 160ms ease;
}

.sound-part:nth-child(even) {
  background: var(--green-pale);
}

.sound-part:hover,
.sound-part.is-playing {
  transform: scale(1.06);
  box-shadow: 0 7px 20px rgba(42, 58, 48, 0.13);
}

.part-plus {
  color: #a4aaa6;
  font-family: var(--serif);
  font-size: 23px;
}

.blend-meaning {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 13px;
}

.blend-meaning #blendEnglish {
  color: var(--green);
  font-size: 16px;
  font-weight: 700;
}

.meaning-dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--ink-soft);
}

.blend-ipa {
  margin-top: 3px;
  color: var(--ink-soft);
  font-family: var(--ipa);
  font-size: 18px;
}

.blend-controls {
  display: flex;
  align-items: center;
  gap: 11px;
  margin-top: 24px;
}

.round-audio {
  width: 45px;
  height: 45px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: var(--green);
  color: white;
  cursor: pointer;
  font-size: 11px;
}

.round-audio:hover {
  background: #17493f;
}

.secondary-button,
.check-button {
  min-height: 42px;
  padding: 9px 15px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: transparent;
  color: var(--ink);
  font-size: 11px;
}

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

.check-button {
  border-color: var(--green);
  background: var(--green);
  color: #fff;
}

.check-button:hover {
  background: #17493f;
}

.blend-tip {
  display: flex;
  flex-direction: column;
  padding: 30px;
  border-radius: var(--radius-lg);
  background: var(--yellow-pale);
}

.tip-label {
  color: #8a631f;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
}

.tip-illustration {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 28px 0;
}

.tip-illustration span,
.tip-illustration strong {
  display: grid;
  place-items: center;
  min-width: 45px;
  height: 45px;
  padding: 0 8px;
  border-radius: 12px;
  background: rgba(255, 253, 248, 0.7);
  font-family: var(--ipa);
  font-size: 18px;
}

.tip-illustration i {
  font-style: normal;
  color: var(--ink-soft);
}

.tip-illustration strong {
  background: var(--green);
  color: #fff;
}

.blend-tip h2 {
  margin: 0 0 10px;
  font-family: var(--serif);
  font-size: 23px;
}

.blend-tip p {
  margin: 0;
  color: #6b624d;
  font-size: 11px;
}

.blend-tip .text-button {
  align-self: flex-start;
  margin-top: auto;
  color: #725426;
}

.listen-practice {
  margin-top: 48px;
}

.listen-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 140px;
  overflow: hidden;
  border-radius: var(--radius-md);
  background: var(--white);
  border: 1px solid var(--line);
}

.listen-main {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 28px;
  padding: 28px;
}

.big-listen-button {
  min-height: 145px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 0;
  border-radius: 16px;
  background: var(--coral-pale);
  color: var(--ink);
  cursor: pointer;
}

.big-listen-button:hover {
  background: #f7d8c7;
}

.big-listen-button strong {
  font-size: 13px;
}

.big-listen-button small {
  color: var(--ink-soft);
  font-size: 9px;
}

.sound-wave {
  height: 25px;
  display: flex;
  align-items: center;
  gap: 3px;
}

.sound-wave i {
  width: 3px;
  height: 8px;
  border-radius: 2px;
  background: var(--coral);
}

.sound-wave i:nth-child(2),
.sound-wave i:nth-child(4) {
  height: 16px;
}

.sound-wave i:nth-child(3) {
  height: 24px;
}

.big-listen-button.is-playing .sound-wave i {
  animation: soundbar 0.45s ease-in-out infinite alternate;
}

.quiz-area {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.quiz-kicker {
  color: var(--ink-soft);
  font-size: 10px;
}

.quiz-kicker strong {
  color: var(--coral);
}

.quiz-area h3 {
  margin: 5px 0 16px;
  font-family: var(--serif);
  font-size: 19px;
}

.quiz-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.quiz-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(247, 241, 231, 0.46);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}

.quiz-option span {
  font-family: var(--ipa);
  color: var(--ink-soft);
  font-size: 12px;
}

.quiz-option .quiz-symbol {
  font-family: var(--ipa);
  color: var(--ink);
  font-size: 23px;
}

.quiz-option:hover {
  border-color: var(--green);
}

.quiz-option:disabled {
  cursor: default;
}

.quiz-option.is-correct {
  border-color: #4f8a73;
  background: var(--green-pale);
}

.quiz-option.is-wrong {
  border-color: #d98a72;
  background: var(--coral-pale);
}

.quiz-feedback {
  min-height: 20px;
  margin: 8px 0 0;
  color: var(--ink-soft);
  font-size: 10px;
}

.next-quiz {
  align-self: flex-start;
  color: var(--green);
}

.quiz-score {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background: var(--green);
  color: rgba(255, 255, 255, 0.72);
  font-size: 10px;
}

.quiz-score strong {
  margin-top: 6px;
  color: #fff;
  font-family: var(--serif);
  font-size: 22px;
}

.speed-toggle {
  display: flex;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 10px;
}

.speed-toggle button {
  padding: 6px 12px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--ink-soft);
  font-size: 10px;
  cursor: pointer;
}

.speed-toggle button.is-active {
  background: var(--green);
  color: white;
}

.conversation-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 17px;
  overflow-x: auto;
}

.conversation-tabs button {
  flex: 0 0 auto;
  padding: 8px 15px;
  border: 1px solid transparent;
  border-radius: 99px;
  background: transparent;
  color: var(--ink-soft);
  font-size: 11px;
  cursor: pointer;
}

.conversation-tabs button:hover {
  color: var(--ink);
}

.conversation-tabs button.is-active {
  border-color: var(--green);
  background: var(--green);
  color: white;
}

.conversation-card {
  display: grid;
  grid-template-columns: minmax(230px, 0.7fr) minmax(0, 1.5fr);
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--white);
  border: 1px solid var(--line);
  box-shadow: 0 15px 45px rgba(42, 58, 48, 0.06);
}

.scene-info {
  position: relative;
  padding: 34px;
  overflow: hidden;
  background: var(--yellow-pale);
}

.scene-info::after {
  content: "";
  position: absolute;
  right: -70px;
  bottom: -70px;
  width: 220px;
  height: 220px;
  border: 1px solid rgba(29, 91, 80, 0.1);
  border-radius: 50%;
  box-shadow: 0 0 0 25px rgba(29, 91, 80, 0.025), 0 0 0 50px rgba(29, 91, 80, 0.018);
}

.scene-icon {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  margin-bottom: 22px;
  border-radius: 50%;
  background: rgba(255, 253, 248, 0.72);
  font-size: 24px;
}

.scene-info h2 {
  margin: 7px 0 9px;
  font-family: var(--serif);
  font-size: 24px;
}

.scene-info > p {
  margin: 0;
  color: #6f6959;
  font-size: 11px;
}

.focus-sound {
  position: absolute;
  z-index: 2;
  left: 34px;
  bottom: 32px;
  display: grid;
  grid-template-columns: auto auto;
  column-gap: 10px;
  align-items: center;
}

.focus-sound > span {
  grid-column: 1 / -1;
  color: #7b6a46;
  font-size: 9px;
  letter-spacing: 0.1em;
}

.focus-sound strong {
  font-family: var(--ipa);
  font-size: 31px;
}

.focus-sound small {
  max-width: 100px;
  color: #7b6a46;
  font-size: 9px;
  line-height: 1.4;
}

.dialogue-wrap {
  padding: 27px 30px;
}

.dialogue-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 15px;
  border-bottom: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 10px;
}

.outline-small {
  padding: 6px 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: transparent;
  color: var(--ink);
  font-size: 9px;
  cursor: pointer;
}

.dialogue-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px 0;
}

.dialogue-line {
  display: grid;
  grid-template-columns: 37px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
  padding: 10px;
  border-radius: 13px;
  cursor: pointer;
  transition: background 140ms ease;
}

.dialogue-line:hover {
  background: var(--paper);
}

.dialogue-line.is-speaking {
  background: var(--green-pale);
}

.speaker-avatar {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--green-pale);
  color: var(--green);
  font-family: var(--serif);
  font-size: 12px;
}

.dialogue-line:nth-child(even) .speaker-avatar {
  background: var(--coral-pale);
  color: #9c4b37;
}

.speaker-name {
  display: block;
  color: var(--ink-soft);
  font-size: 9px;
}

.dialogue-en {
  display: block;
  margin-top: 1px;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.5;
}

.dialogue-ipa {
  display: block;
  margin-top: 2px;
  color: var(--green-mid);
  font-family: var(--ipa);
  font-size: 11px;
}

.dialogue-cn {
  display: block;
  margin-top: 3px;
  color: var(--ink-soft);
  font-size: 10px;
}

.line-audio {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  margin-top: 2px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: transparent;
  color: var(--green);
  font-size: 8px;
  cursor: pointer;
}

.phrase-note {
  display: flex;
  gap: 11px;
  padding: 13px;
  border-radius: 11px;
  background: var(--paper);
}

.note-mark {
  flex: 0 0 auto;
  color: var(--coral);
  font-size: 9px;
  font-weight: 700;
}

.phrase-note p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 10px;
  line-height: 1.6;
}

.shadowing-section {
  display: grid;
  grid-template-columns: 0.7fr 1.3fr;
  align-items: center;
  gap: 35px;
  margin-top: 27px;
  padding: 28px 32px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
}

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

.shadowing-copy p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 10px;
}

.shadowing-steps {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.shadowing-steps > div {
  display: grid;
  justify-items: center;
  gap: 1px;
  min-width: 64px;
}

.shadowing-steps > div span {
  width: 27px;
  height: 27px;
  display: grid;
  place-items: center;
  margin-bottom: 4px;
  border-radius: 50%;
  background: var(--green-pale);
  color: var(--green);
  font-size: 10px;
  font-weight: 700;
}

.shadowing-steps strong {
  font-family: var(--serif);
  font-size: 13px;
}

.shadowing-steps small {
  color: var(--ink-soft);
  font-size: 8px;
}

.shadowing-steps > i {
  color: #aeb4b0;
  font-style: normal;
}

.review-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(280px, 0.7fr);
  gap: 22px;
}

.flashcard-area {
  min-width: 0;
}

.card-deck-label {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  color: var(--ink-soft);
  font-size: 10px;
}

.card-deck-label strong {
  color: var(--ink);
}

.flashcard {
  width: 100%;
  min-height: 380px;
  padding: 0;
  border: 0;
  border-radius: var(--radius-lg);
  background: transparent;
  perspective: 1000px;
  cursor: pointer;
}

.flashcard-inner {
  position: relative;
  min-height: 380px;
  transform-style: preserve-3d;
  transition: transform 550ms cubic-bezier(0.2, 0.75, 0.3, 1);
}

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

.flashcard-front,
.flashcard-back {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 34px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  background: var(--yellow-pale);
  box-shadow: var(--shadow);
}

.flashcard-back {
  transform: rotateY(180deg);
  background: var(--green);
  color: #fffaf0;
}

.flash-label {
  color: #816528;
  font-size: 10px;
  letter-spacing: 0.09em;
}

.flashcard-front strong {
  margin: 18px 0 2px;
  font-family: var(--ipa);
  font-size: clamp(64px, 9vw, 100px);
  line-height: 1.2;
}

.flashcard-front > small {
  color: #7e6c4b;
  font-size: 11px;
}

.flip-hint {
  position: absolute;
  bottom: 23px;
  color: rgba(24, 49, 44, 0.52);
  font-size: 9px;
}

.flashcard-back .flash-label,
.flashcard-back .flip-hint {
  color: rgba(255, 250, 240, 0.55);
}

.flashcard-back > strong {
  margin: 14px 0 8px;
  font-family: var(--sans);
  font-size: 38px;
}

.flashcard-back > p {
  max-width: 420px;
  margin: 0;
  color: rgba(255, 250, 240, 0.77);
  font-size: 12px;
  text-align: center;
}

.inline-audio {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 22px;
  padding: 8px 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.08);
  color: white;
  font-size: 10px;
  cursor: pointer;
}

.review-actions {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
}

.primary-button.compact {
  min-height: 42px;
  padding: 9px 17px;
  border-radius: 11px;
  background: var(--green);
  color: #fff;
  font-size: 11px;
  box-shadow: none;
}

.primary-button.compact:hover {
  background: #17493f;
}

.review-summary {
  padding: 30px;
  border-radius: var(--radius-lg);
  background: var(--white);
  border: 1px solid var(--line);
}

.review-summary h2 {
  margin: 5px 0 25px;
  font-family: var(--serif);
  font-size: 23px;
}

.big-progress-ring {
  width: 172px;
  height: 172px;
  display: grid;
  place-items: center;
  margin: 0 auto 27px;
  border-radius: 50%;
  background: conic-gradient(var(--green) 0deg, var(--green) 0deg, #e9e5da 0deg);
  position: relative;
}

.big-progress-ring::before {
  content: "";
  position: absolute;
  inset: 10px;
  border-radius: 50%;
  background: var(--white);
}

.big-progress-ring > div {
  position: relative;
  display: grid;
  justify-items: center;
}

.big-progress-ring strong {
  font-family: var(--serif);
  font-size: 36px;
  line-height: 1.2;
}

.big-progress-ring span {
  color: var(--ink-soft);
  font-size: 9px;
}

.summary-stats {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--line);
}

.summary-stats > div {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  font-size: 10px;
}

.summary-stats span {
  color: var(--ink-soft);
}

.summary-stats strong {
  color: var(--ink);
  font-size: 11px;
}

.summary-note {
  margin: 21px 0 0;
  padding: 13px;
  border-radius: 10px;
  background: var(--paper);
  color: var(--ink-soft);
  font-size: 9px;
  text-align: center;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 23px clamp(28px, 4.5vw, 76px);
  border-top: 1px solid var(--line);
  color: #8c948f;
  font-size: 9px;
}

.footer p {
  margin: 0;
}

.overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(19, 39, 34, 0.34);
  backdrop-filter: blur(5px);
  animation: fadeIn 200ms ease;
}

.sound-drawer {
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: min(550px, 94vw);
  overflow-y: auto;
  padding: 28px 36px 34px;
  background: var(--paper);
  box-shadow: -20px 0 80px rgba(21, 42, 35, 0.14);
  animation: drawerIn 280ms ease both;
}

.overlay-close,
.modal-close {
  position: absolute;
  z-index: 2;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 253, 248, 0.8);
  font-family: var(--sans);
  font-size: 23px;
  line-height: 1;
}

.overlay-close {
  left: -52px;
  top: 24px;
  color: white;
  background: rgba(255, 255, 255, 0.16);
}

.drawer-top {
  display: flex;
  justify-content: space-between;
  margin-bottom: 28px;
}

.drawer-category {
  padding: 4px 9px;
  border-radius: 99px;
  background: var(--green-pale);
  color: var(--green);
  font-size: 9px;
}

.drawer-index {
  color: var(--ink-soft);
  font-size: 9px;
}

.drawer-symbol-row {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 20px;
}

.drawer-symbol {
  min-width: 65px;
  font-family: var(--ipa);
  font-size: clamp(58px, 8vw, 76px);
  line-height: 1;
}

.drawer-play {
  width: 45px;
  height: 45px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-size: 10px;
  cursor: pointer;
}

.drawer-example {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin-left: auto;
  padding-left: 20px;
  border-left: 1px solid var(--line);
  border-top: 0;
  border-right: 0;
  border-bottom: 0;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  text-align: left;
}

.drawer-example strong {
  font-family: var(--serif);
  font-size: 24px;
}

.drawer-example span {
  color: var(--ink-soft);
  font-size: 10px;
}

.drawer-example i {
  margin-top: 4px;
  color: var(--green);
  font-size: 9px;
  font-style: normal;
}

.sound-drawer > h2 {
  margin: 0 0 9px;
  font-family: var(--serif);
  font-size: 28px;
}

.drawer-description {
  margin: 0;
  color: var(--ink-soft);
  font-size: 12px;
}

.mouth-card {
  display: grid;
  grid-template-columns: 105px minmax(0, 1fr);
  align-items: center;
  gap: 22px;
  margin: 25px 0;
  padding: 22px;
  border-radius: 17px;
  background: var(--yellow-pale);
}

.mouth-visual {
  position: relative;
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: #edd9bb;
  overflow: hidden;
}

.mouth-outline {
  position: absolute;
  left: 24px;
  top: 37px;
  width: 52px;
  height: 28px;
  border: 3px solid #a55a49;
  border-radius: 50%;
  background: #bb6b59;
}

.tongue {
  position: absolute;
  left: 34px;
  top: 53px;
  width: 34px;
  height: 13px;
  border-radius: 50%;
  background: #d98e83;
}

.mouth-arrow {
  position: absolute;
  right: 11px;
  top: 47px;
  width: 16px;
  border-top: 2px solid var(--green);
}

.mouth-arrow::after {
  content: "";
  position: absolute;
  right: -1px;
  top: -4px;
  width: 6px;
  height: 6px;
  border-top: 2px solid var(--green);
  border-right: 2px solid var(--green);
  transform: rotate(45deg);
}

.mouth-card h3 {
  margin: 2px 0 5px;
  font-family: var(--serif);
  font-size: 17px;
}

.mouth-card p {
  margin: 0;
  color: #71654c;
  font-size: 11px;
}

.sound-examples {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}

.sound-examples > div {
  padding: 16px;
  border-radius: 14px;
  border: 1px solid var(--line);
}

.sound-examples > div > span {
  display: block;
  margin-bottom: 12px;
  color: var(--ink-soft);
  font-size: 9px;
}

.sound-examples button {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 8px;
  padding: 7px 0;
  border: 0;
  border-top: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}

.sound-examples .audio-method button {
  border-top: 1px solid var(--line);
}

.sound-examples .audio-method button:hover {
  color: var(--green);
}

.sound-examples button strong {
  font-size: 13px;
}

.sound-examples button small {
  color: var(--ink-soft);
  font-size: 9px;
}

.sound-examples button i {
  color: var(--green);
  font-size: 8px;
  font-style: normal;
}

.sound-examples p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 10px;
}

.drawer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 28px;
}

.learn-button {
  min-height: 44px;
  padding: 10px 17px;
  border: 1px solid var(--green);
  border-radius: 11px;
  background: var(--green);
  color: white;
  font-size: 11px;
}

.learn-button.is-learned {
  background: var(--green-pale);
  color: var(--green);
}

.learn-button span {
  margin-right: 4px;
}

.drawer-bottom a {
  max-width: 210px;
  color: var(--green);
  font-size: 9px;
  text-align: right;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 110;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(19, 39, 34, 0.43);
  backdrop-filter: blur(6px);
}

.modal-card {
  position: relative;
  width: min(540px, 100%);
  max-height: 90vh;
  overflow-y: auto;
  padding: 34px;
  border-radius: 24px;
  background: var(--paper);
  box-shadow: 0 30px 90px rgba(10, 27, 21, 0.22);
  animation: modalIn 250ms ease;
}

.modal-close {
  right: 17px;
  top: 17px;
}

.modal-card h2 {
  margin: 5px 0 22px;
  font-family: var(--serif);
  font-size: 30px;
}

.guide-steps {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.guide-steps li {
  display: grid;
  grid-template-columns: 30px 1fr;
  gap: 12px;
}

.guide-steps li > span {
  width: 27px;
  height: 27px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--green-pale);
  color: var(--green);
  font-size: 10px;
}

.guide-steps p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 11px;
  line-height: 1.7;
}

.guide-steps strong {
  color: var(--ink);
  font-size: 12px;
}

.guide-tip {
  margin: 22px 0;
  padding: 14px;
  border-radius: 12px;
  background: var(--yellow-pale);
}

.guide-tip span {
  color: #856423;
  font-size: 9px;
  font-weight: 700;
}

.guide-tip p {
  margin: 4px 0 0;
  color: #6c624b;
  font-size: 10px;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  z-index: 200;
  max-width: calc(100vw - 36px);
  padding: 10px 17px;
  border-radius: 99px;
  background: var(--ink);
  color: #fff;
  font-size: 11px;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 15px);
  transition: 200ms ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.script-error {
  position: fixed;
  left: 50%;
  bottom: 76px;
  z-index: 300;
  padding: 10px 16px;
  border-radius: 10px;
  background: #8d3d2d;
  color: #fff;
  font-size: 12px;
  transform: translateX(-50%);
}

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

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes drawerIn {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}

@keyframes modalIn {
  from { opacity: 0; transform: translateY(12px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes soundbar {
  from { transform: scaleY(0.45); }
  to { transform: scaleY(1); }
}

@media (max-width: 1180px) {
  .welcome-grid {
    grid-template-columns: minmax(0, 1.4fr) minmax(290px, 0.8fr);
  }

  .hero {
    grid-template-columns: 1fr 0.8fr;
  }

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

  .hero h1 {
    font-size: 44px;
  }

  .phoneme-grid {
    grid-template-columns: repeat(6, minmax(76px, 1fr));
  }

  .listen-main {
    grid-template-columns: 150px minmax(0, 1fr);
  }
}

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

  .sidebar {
    width: min(280px, 84vw);
    transform: translateX(-105%);
    transition: transform 220ms ease;
    box-shadow: 20px 0 60px rgba(21, 42, 35, 0.12);
  }

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

  .mobile-menu {
    display: block;
  }

  .page-column {
    min-width: 0;
  }

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

  .hero {
    min-height: 430px;
  }

  .today-card {
    min-height: 350px;
  }

  .path-grid {
    grid-template-columns: repeat(7, 155px);
  }

  .blend-layout,
  .review-layout {
    grid-template-columns: 1fr;
  }

  .blend-tip {
    min-height: 270px;
  }

  .conversation-card {
    grid-template-columns: 0.65fr 1.35fr;
  }

  .shadowing-section {
    grid-template-columns: 1fr;
  }

  .review-summary {
    display: grid;
    grid-template-columns: 1fr 180px;
    gap: 20px;
  }

  .review-summary h2,
  .review-summary .eyebrow {
    grid-column: 1;
  }

  .big-progress-ring {
    grid-column: 2;
    grid-row: 1 / span 3;
  }

  .summary-stats {
    grid-column: 1;
  }

  .summary-note {
    grid-column: 1 / -1;
  }
}

@media (max-width: 700px) {
  .topbar {
    min-height: 70px;
    padding: 12px 18px;
  }

  .topbar-title {
    display: none;
  }

  .top-actions {
    margin-left: auto;
  }

  .sound-setting {
    min-height: 34px;
  }

  .sound-label {
    display: none;
  }

  main {
    padding: 24px 17px 50px;
  }

  .hero {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .hero-copy {
    padding: 32px 25px 18px;
  }

  .hero h1 {
    margin-top: 17px;
    font-size: 39px;
  }

  .hero-actions {
    flex-wrap: wrap;
    gap: 15px;
  }

  .hero-visual {
    min-height: 270px;
    padding: 10px 35px 35px;
  }

  .sound-portrait {
    width: 190px;
  }

  .arch-back {
    width: 220px;
    height: 220px;
  }

  .arch-front {
    width: 200px;
    height: 210px;
  }

  .hero-caption {
    display: none;
  }

  .letter-one {
    top: 0;
    right: 12%;
  }

  .letter-two {
    left: 10%;
    bottom: 30%;
  }

  .letter-three {
    right: 13%;
    bottom: 12%;
  }

  .section-heading,
  .page-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .section-heading > p {
    text-align: left;
  }

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

  .principles article + article {
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .chart-progress {
    grid-template-columns: auto 1fr;
  }

  .chart-progress p {
    grid-column: 1 / -1;
  }

  .local-audio-badge {
    grid-column: 1 / -1;
    width: max-content;
  }

  .phoneme-grid {
    grid-template-columns: repeat(4, minmax(65px, 1fr));
  }

  .phoneme-card {
    min-height: 94px;
    padding: 12px;
  }

  .phoneme-card .phoneme-symbol {
    font-size: 28px;
  }

  .authority-box {
    flex-direction: column;
    padding: 23px;
  }

  .blend-card {
    min-height: 390px;
    padding: 24px 18px;
  }

  .blend-controls {
    flex-wrap: wrap;
    justify-content: center;
  }

  .listen-card {
    grid-template-columns: 1fr;
  }

  .listen-main {
    grid-template-columns: 1fr;
    padding: 18px;
  }

  .big-listen-button {
    min-height: 110px;
  }

  .quiz-score {
    flex-direction: row;
    gap: 10px;
    padding: 9px;
  }

  .quiz-score strong {
    margin: 0;
  }

  .conversation-card {
    grid-template-columns: 1fr;
  }

  .scene-info {
    min-height: 270px;
  }

  .dialogue-wrap {
    padding: 20px 16px;
  }

  .dialogue-line {
    grid-template-columns: 32px minmax(0, 1fr) auto;
    gap: 9px;
    padding: 7px 2px;
  }

  .speaker-avatar {
    width: 30px;
    height: 30px;
  }

  .shadowing-section {
    padding: 23px 18px;
  }

  .shadowing-steps > i {
    display: none;
  }

  .shadowing-steps > div {
    min-width: 55px;
  }

  .review-summary {
    display: block;
  }

  .big-progress-ring {
    margin-top: 0;
  }

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

  .sound-drawer {
    width: 100vw;
    padding: 26px 20px 32px;
  }

  .overlay-close {
    left: 15px;
    top: 14px;
    z-index: 5;
    color: var(--ink);
    background: var(--white);
  }

  .drawer-top {
    margin-top: 15px;
  }

  .sound-examples {
    grid-template-columns: 1fr;
  }

  .drawer-bottom {
    align-items: flex-start;
    flex-direction: column;
  }

  .drawer-bottom a {
    text-align: left;
  }

  .footer {
    flex-direction: column;
    padding: 20px 18px;
  }
}

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