:root {
  --paper: #f5f3ee;
  --paper-deep: #ebe8e0;
  --card: rgba(255, 255, 255, 0.82);
  --ink: #19201e;
  --muted: #717975;
  --line: #dddcd5;
  --accent: #d95f4b;
  --accent-deep: #b84939;
  --accent-soft: #f8e6e1;
  --sage: #6f8779;
  --sage-soft: #e7eee9;
  --blue: #5f7f99;
  --blue-soft: #e7eff4;
  --amber: #a97931;
  --amber-soft: #f6eddb;
  --shadow: 0 18px 55px rgba(39, 48, 44, 0.08);
  --radius: 22px;
  --sidebar: 246px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background:
    radial-gradient(circle at 88% 3%, rgba(217, 95, 75, 0.08), transparent 26rem),
    radial-gradient(circle at 8% 96%, rgba(111, 135, 121, 0.09), transparent 28rem),
    var(--paper);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI",
    "Hiragino Sans GB", "PingFang SC", "Noto Sans CJK SC", "Yu Gothic", sans-serif;
  -webkit-font-smoothing: antialiased;
}

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

.shell { min-height: 100vh; }
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--sidebar);
  padding: 28px 22px 24px;
  border-right: 1px solid rgba(25, 32, 30, 0.08);
  background: rgba(247, 245, 240, 0.88);
  backdrop-filter: blur(18px);
  z-index: 20;
  display: flex;
  flex-direction: column;
}

.brand { display: flex; gap: 12px; align-items: center; margin: 0 7px 38px; }
.brand-mark {
  width: 42px; height: 42px; border-radius: 14px;
  background: var(--accent); color: white;
  display: grid; place-items: center;
  font-size: 18px; font-weight: 800; letter-spacing: -2px;
  box-shadow: 0 10px 26px rgba(217, 95, 75, 0.24);
}
.brand-name { font-size: 17px; font-weight: 800; letter-spacing: .03em; }
.brand-sub { font-size: 11px; color: var(--muted); margin-top: 2px; letter-spacing: .1em; }

.nav { display: grid; gap: 7px; }
.nav-btn {
  border: 0; background: transparent; cursor: pointer;
  min-height: 48px; border-radius: 14px; padding: 0 14px;
  display: flex; align-items: center; gap: 12px;
  color: #59615e; text-align: left; font-weight: 650;
  transition: .2s ease;
}
.nav-btn:hover { background: rgba(255,255,255,.7); color: var(--ink); }
.nav-btn.active { background: white; color: var(--ink); box-shadow: 0 8px 24px rgba(39,48,44,.07); }
.nav-icon { width: 23px; text-align: center; font-size: 17px; }
.nav-badge {
  margin-left: auto; min-width: 22px; height: 22px; padding: 0 6px;
  border-radius: 999px; background: var(--accent-soft); color: var(--accent-deep);
  font-size: 11px; display: grid; place-items: center;
}
.nav-divider { height: 1px; margin: 9px 12px; background: var(--line); }
.sidebar-foot { margin-top: auto; padding: 16px 13px 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.sidebar-foot b { color: var(--ink); }

.main { margin-left: var(--sidebar); min-height: 100vh; padding: 34px 42px 64px; }
.page { width: min(1120px, 100%); margin: 0 auto; animation: rise .35s ease both; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }

.topbar { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 34px; }
.eyebrow { font-size: 12px; font-weight: 750; color: var(--accent); letter-spacing: .14em; text-transform: uppercase; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 7px; font-size: clamp(28px, 4vw, 42px); line-height: 1.15; letter-spacing: -.035em; }
h2 { margin-bottom: 8px; font-size: 23px; letter-spacing: -.02em; }
h3 { margin-bottom: 7px; font-size: 16px; }
.subtitle { color: var(--muted); line-height: 1.7; margin-bottom: 0; }
.date-pill {
  flex: 0 0 auto; padding: 10px 14px; border-radius: 999px;
  background: rgba(255,255,255,.72); border: 1px solid var(--line);
  color: var(--muted); font-size: 12px;
}

.focus-home { width: min(820px, 100%); padding-top: 24px; }
.focus-welcome { display: flex; align-items: flex-end; justify-content: space-between; gap: 30px; margin-bottom: 28px; }
.focus-welcome h1 { margin: 7px 0 9px; font-size: clamp(31px, 5vw, 48px); }
.focus-welcome p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.65; }
.focus-streak { flex: 0 0 auto; width: 106px; min-height: 86px; padding: 15px 12px; border: 1px solid var(--line); border-radius: 18px; background: rgba(255,255,255,.56); text-align: center; }
.focus-streak b, .focus-streak span { display: block; }
.focus-streak b { font-size: 29px; line-height: 1; }
.focus-streak span { margin-top: 7px; color: var(--muted); font-size: 9px; }
.today-focus { position: relative; overflow: hidden; padding: 38px 42px 34px; background: linear-gradient(145deg, rgba(255,255,255,.98), rgba(255,249,246,.9)); }
.today-focus::after { content: "日"; position: absolute; right: -16px; bottom: -82px; color: rgba(217,95,75,.045); font: 700 260px/1 "Yu Mincho", "Hiragino Mincho ProN", serif; pointer-events: none; }
.today-focus > * { position: relative; z-index: 1; }
.today-focus-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 23px; }
.today-focus-top > span { padding: 7px 11px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-deep); font-size: 10px; font-weight: 800; letter-spacing: .05em; }
.today-focus-top > div { text-align: right; }
.today-focus-top b, .today-focus-top small { display: block; }
.today-focus-top b { font-size: 18px; }
.today-focus-top small { margin-top: 2px; color: var(--muted); font-size: 9px; }
.focus-kana { margin: 0 0 20px; color: rgba(95,127,153,.76); font: 700 clamp(26px, 5vw, 42px)/1.25 "Yu Mincho", "Hiragino Mincho ProN", serif; letter-spacing: .12em; }
.focus-kicker { margin-bottom: 9px; color: var(--sage); font-size: 10px; font-weight: 850; letter-spacing: .14em; }
.today-focus h2 { max-width: 620px; margin-bottom: 8px; font-size: clamp(25px, 4vw, 34px); }
.today-focus > p { max-width: 620px; margin-bottom: 0; color: var(--muted); font-size: 14px; line-height: 1.72; }
.focus-jp { margin: -2px 0 13px; color: var(--blue); font-size: 15px; }
.focus-three { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; max-width: 580px; margin: 27px 0 24px; }
.focus-three span { display: flex; align-items: center; gap: 8px; color: #4f5955; font-size: 11px; font-weight: 700; }
.focus-three b { width: 24px; height: 24px; border-radius: 8px; display: grid; place-items: center; background: var(--paper-deep); color: var(--muted); font-size: 9px; }
.focus-start { width: min(360px, 100%); min-height: 54px; font-size: 14px; }
.focus-start span { margin-left: auto; font-size: 17px; }
.focus-permission { display: block; margin-top: 12px; color: var(--muted); font-size: 9px; }
.focus-roadmap { margin-top: 15px; padding: 20px 24px; box-shadow: none; border-color: var(--line); background: rgba(255,255,255,.58); }
.focus-roadmap-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.focus-roadmap-head b, .focus-roadmap-head span { display: block; }
.focus-roadmap-head b { font-size: 13px; }
.focus-roadmap-head span { margin-top: 4px; color: var(--muted); font-size: 10px; line-height: 1.5; }
.focus-roadmap-head strong { font-size: 20px; }
.focus-dots { display: grid; grid-template-columns: repeat(7, 1fr); gap: 9px; margin-top: 17px; }
.focus-dots > span { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 0; }
.focus-dots i { width: 100%; height: 8px; overflow: hidden; border-radius: 99px; background: var(--paper-deep); color: transparent; font-size: 0; }
.focus-dots .done i { background: var(--sage); }
.focus-dots .current i { background: var(--accent); box-shadow: 0 0 0 3px rgba(217,95,75,.1); }
.focus-dots small { min-height: 11px; color: var(--accent); font-size: 8px; }
.lesson-roadmap .lesson-progress { margin: 17px 0 0; }
.focus-tip-line { display: grid; grid-template-columns: auto minmax(0,1fr) auto; gap: 10px; align-items: center; margin-top: 15px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 10px; }
.focus-tip-line span { color: var(--sage); font-weight: 800; }
.focus-tip-line b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.focus-tip-line button, .focus-quiet-actions button { border: 0; background: transparent; color: var(--muted); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.focus-tip-line button:hover, .focus-quiet-actions button:hover { color: var(--accent); }
.focus-quiet-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 7px 22px; padding: 17px 8px 0; }
.focus-quiet-actions button { font-size: 10px; }

.more-page { width: min(920px, 100%); }
.more-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.more-card { width: 100%; min-height: 185px; padding: 24px; border-color: var(--line); box-shadow: none; cursor: pointer; text-align: left; display: flex; flex-direction: column; align-items: flex-start; transition: transform .18s, background .18s; }
.more-card:hover { transform: translateY(-2px); background: white; }
.more-card-mark { width: 43px; height: 43px; display: grid; place-items: center; border-radius: 13px; background: var(--accent); color: white; font-weight: 850; }
.more-card-mark.sage { background: var(--sage); }
.more-card-mark.blue { background: var(--blue); }
.more-card > span:nth-child(2) { margin-top: 22px; }
.more-card b, .more-card small { display: block; }
.more-card b { font-size: 14px; }
.more-card small { margin-top: 7px; color: var(--muted); font-size: 10px; line-height: 1.55; }
.more-card i { margin-top: auto; align-self: flex-end; color: var(--muted); font-style: normal; }

.grid { display: grid; gap: 18px; }
.grid-2 { grid-template-columns: 1.45fr .85fr; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.card {
  background: var(--card); border: 1px solid rgba(255,255,255,.9);
  border-radius: var(--radius); box-shadow: var(--shadow);
}
.hero-card {
  min-height: 270px; padding: 32px;
  background:
    linear-gradient(145deg, rgba(255,255,255,.97), rgba(255,250,246,.88)),
    var(--card);
  position: relative; overflow: hidden;
}
.hero-card::after {
  content: "日"; position: absolute; right: 18px; bottom: -50px;
  font-family: "Yu Mincho", "Hiragino Mincho ProN", serif;
  font-size: 230px; font-weight: 700; line-height: 1; color: rgba(217,95,75,.055);
  pointer-events: none;
}
.lesson-kicker { color: var(--sage); font-size: 12px; font-weight: 750; letter-spacing: .08em; margin-bottom: 18px; }
.hero-title { font-size: 29px; margin-bottom: 4px; }
.jp-heading { color: var(--muted); font-size: 15px; margin-bottom: 18px; }
.can-do { max-width: 620px; line-height: 1.72; font-size: 15px; position: relative; z-index: 1; }
.hero-actions { display: flex; gap: 11px; margin-top: 26px; position: relative; z-index: 1; }
.btn {
  border: 0; border-radius: 13px; min-height: 44px; padding: 0 18px;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  cursor: pointer; font-weight: 730; transition: transform .18s, box-shadow .18s, background .18s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--accent); color: white; box-shadow: 0 10px 24px rgba(217,95,75,.2); }
.btn-primary:hover { background: var(--accent-deep); }
.btn-soft { background: var(--sage-soft); color: #496555; }
.btn-ghost { background: white; border: 1px solid var(--line); color: #4e5753; }
.btn-disabled, .btn:disabled { background: #dedfdc; color: #929793; cursor: not-allowed; box-shadow: none; transform: none; }
.btn-small { min-height: 36px; padding: 0 12px; font-size: 12px; border-radius: 11px; }

.stats-card { padding: 26px; display: flex; flex-direction: column; }
.ring-wrap { display: grid; place-items: center; padding: 10px 0 19px; }
.ring {
  --p: 0deg;
  width: 132px; height: 132px; border-radius: 50%;
  background: conic-gradient(var(--accent) var(--p), var(--paper-deep) 0);
  position: relative; display: grid; place-items: center;
}
.ring::after { content: ""; position: absolute; width: 104px; height: 104px; border-radius: 50%; background: #fff; }
.ring-content { position: relative; z-index: 1; text-align: center; }
.ring-number { font-weight: 850; font-size: 29px; letter-spacing: -.05em; }
.ring-label { color: var(--muted); font-size: 11px; margin-top: 2px; }
.mini-stats { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); padding-top: 18px; }
.mini-stat { text-align: center; border-right: 1px solid var(--line); }
.mini-stat:last-child { border: 0; }
.mini-value { font-size: 17px; font-weight: 800; }
.mini-label { font-size: 10px; color: var(--muted); margin-top: 4px; }

.section { margin-top: 30px; }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 16px; margin-bottom: 15px; }
.section-head p { margin: 0; font-size: 13px; color: var(--muted); }
.daily-plan { grid-template-columns: repeat(3, 1fr); }
.plan-item { padding: 21px; box-shadow: none; border-color: var(--line); background: rgba(255,255,255,.6); }
.plan-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 18px; }
.plan-icon { width: 37px; height: 37px; border-radius: 12px; background: var(--accent-soft); display: grid; place-items: center; }
.plan-time { color: var(--muted); font-size: 11px; }
.plan-item p { color: var(--muted); font-size: 12px; line-height: 1.6; margin-bottom: 0; }
.pace-chip { padding: 7px 11px; border-radius: 999px; background: var(--sage-soft); color: #4d6758; font-size: 11px; font-weight: 750; }
.week-rhythm { display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; }
.rhythm-day { min-height: 98px; padding: 13px 10px; border: 1px solid var(--line); background: rgba(255,255,255,.58); border-radius: 15px; display: flex; flex-direction: column; justify-content: space-between; }
.rhythm-day span { width: 24px; height: 24px; border-radius: 8px; background: var(--paper-deep); display: grid; place-items: center; color: var(--muted); font-size: 10px; }
.rhythm-day b { font-size: 11px; line-height: 1.45; }
.rhythm-day.today { background: white; border-color: rgba(217,95,75,.55); box-shadow: 0 8px 20px rgba(39,48,44,.06); }
.rhythm-day.today span { color: white; background: var(--accent); }

.home-tip { padding: 24px; display: grid; grid-template-columns: 58px minmax(0,1fr) auto; gap: 18px; align-items: center; box-shadow: none; border-color: var(--line); background: linear-gradient(135deg, rgba(255,255,255,.84), rgba(231,238,233,.72)); }
.home-tip-mark, .tip-group-mark { width: 58px; height: 58px; border-radius: 18px; display: grid; place-items: center; background: var(--ink); color: white; font-size: 20px; font-weight: 850; }
.home-tip h2 { font-size: 19px; margin-bottom: 5px; }
.home-tip-copy > p { margin-bottom: 11px; color: var(--muted); font-size: 13px; }
.home-tip-action { color: #47534e; font-size: 12px; line-height: 1.6; }
.home-tip-action b { color: var(--sage); }

.foundation-home-hero { min-height: 310px; }
.foundation-rule { display: flex; align-items: center; gap: 9px; width: fit-content; max-width: 100%; padding: 10px 13px; border-radius: 12px; background: var(--amber-soft); color: #6c542e; font-size: 11px; line-height: 1.45; position: relative; z-index: 1; }
.foundation-rule span { color: var(--amber); font-weight: 800; }
.foundation-rule b { font-size: 12px; }
.foundation-ready-note { padding-top: 17px; border-top: 1px solid var(--line); text-align: center; }
.foundation-ready-note b, .foundation-ready-note span { display: block; }
.foundation-ready-note b { font-size: 14px; }
.foundation-ready-note span { margin-top: 5px; color: var(--muted); font-size: 10px; line-height: 1.5; }
.foundation-week { display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; }
.foundation-day-mini { min-height: 112px; padding: 13px 9px; border: 1px solid var(--line); border-radius: 15px; background: rgba(255,255,255,.58); cursor: pointer; display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between; text-align: left; transition: .18s; }
.foundation-day-mini:hover { background: white; transform: translateY(-1px); }
.foundation-day-mini > span { width: 27px; height: 27px; border-radius: 9px; display: grid; place-items: center; background: var(--paper-deep); color: var(--muted); font-size: 10px; font-weight: 800; }
.foundation-day-mini b { font-size: 11px; line-height: 1.35; }
.foundation-day-mini small { color: var(--muted); font-size: 8px; }
.foundation-day-mini.current { border-color: rgba(217,95,75,.55); background: white; box-shadow: 0 8px 20px rgba(39,48,44,.06); }
.foundation-day-mini.current > span { background: var(--accent); color: white; }
.foundation-day-mini.done { border-color: rgba(111,135,121,.42); background: var(--sage-soft); }
.foundation-day-mini.done > span { background: var(--sage); color: white; }
.foundation-explain { padding: 22px 24px; display: grid; grid-template-columns: 58px minmax(0,1fr); gap: 17px; align-items: center; box-shadow: none; border-color: var(--line); background: rgba(255,255,255,.6); }
.foundation-explain h2 { font-size: 18px; margin-bottom: 5px; }
.foundation-explain p { color: var(--muted); font-size: 12px; line-height: 1.65; margin: 0; }
.family-access { padding: 22px 24px; display: grid; grid-template-columns: 52px minmax(0,1fr) auto; gap: 16px; align-items: center; box-shadow: none; border-color: var(--line); background: linear-gradient(135deg, rgba(255,255,255,.72), rgba(231,239,244,.68)); }
.family-access-mark { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; background: var(--blue); color: white; font-size: 17px; font-weight: 850; }
.family-access h2 { font-size: 18px; margin-bottom: 4px; }
.family-access p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.62; }
.family-access-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }

.course-gate { padding: 24px; margin-bottom: 28px; display: grid; grid-template-columns: 56px minmax(0,1fr) auto; gap: 17px; align-items: center; border-color: rgba(217,95,75,.25); background: linear-gradient(135deg, rgba(255,255,255,.9), rgba(248,230,225,.7)); }
.course-gate-mark { width: 56px; height: 56px; border-radius: 17px; display: grid; place-items: center; background: var(--accent); color: white; font-size: 21px; font-weight: 850; }
.course-gate h2 { font-size: 19px; margin-bottom: 5px; }
.course-gate p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.lesson-card.locked { cursor: not-allowed; opacity: .58; filter: saturate(.65); }
.lesson-card.locked:hover { transform: none; background: rgba(255,255,255,.72); box-shadow: none; }
.lesson-lock { position: absolute; right: 16px; top: 16px; width: 24px; height: 24px; border-radius: 50%; background: var(--paper-deep); color: var(--muted); display: grid; place-items: center; font-size: 8px; font-weight: 800; }

.foundation-status { padding: 23px 25px; display: grid; grid-template-columns: minmax(0,1fr) 150px auto; gap: 22px; align-items: center; margin-bottom: 17px; background: linear-gradient(135deg, rgba(255,255,255,.92), rgba(231,238,233,.66)); }
.foundation-status h2 { font-size: 20px; margin-bottom: 5px; }
.foundation-status p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.foundation-status-progress { text-align: right; }
.foundation-status-progress strong { font-size: 23px; }
.foundation-status-progress > span { margin-left: 5px; color: var(--muted); font-size: 10px; }
.foundation-status-progress .lesson-progress { margin: 8px 0 0; }
.foundation-day-tabs { display: grid; grid-template-columns: repeat(7, 1fr); gap: 7px; margin-bottom: 17px; }
.foundation-day-tabs button { min-height: 67px; padding: 9px 7px; border: 1px solid var(--line); border-radius: 13px; background: rgba(255,255,255,.56); cursor: pointer; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px; }
.foundation-day-tabs button span { color: var(--muted); font-size: 9px; font-weight: 800; }
.foundation-day-tabs button b { font-size: 10px; line-height: 1.25; }
.foundation-day-tabs button.active { color: white; background: var(--ink); border-color: var(--ink); }
.foundation-day-tabs button.active span { color: rgba(255,255,255,.65); }
.foundation-day-tabs button.done:not(.active) { border-color: rgba(111,135,121,.5); background: var(--sage-soft); color: #496555; }

.foundation-lesson { padding: 28px; }
.foundation-lesson-head { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 20px; align-items: start; }
.foundation-lesson-head h2 { font-size: 25px; }
.foundation-lesson-head p { color: var(--muted); line-height: 1.7; margin: 0; }
.foundation-day-score { min-width: 86px; padding: 13px; border-radius: 14px; background: var(--paper-deep); text-align: center; }
.foundation-day-score b, .foundation-day-score span { display: block; }
.foundation-day-score b { font-size: 21px; }
.foundation-day-score span { margin-top: 3px; color: var(--muted); font-size: 9px; }
.foundation-day-score.done { background: var(--sage-soft); color: #496555; }
.foundation-teacher { margin: 20px 0; padding: 15px 17px; border-radius: 15px; background: var(--amber-soft); display: grid; grid-template-columns: auto minmax(0,1fr); gap: 13px; align-items: start; }
.foundation-teacher > span { padding: 5px 7px; border-radius: 7px; background: white; color: var(--amber); font-size: 9px; font-weight: 850; }
.foundation-teacher p { margin: 0; color: #6c542e; font-size: 12px; line-height: 1.7; }
.foundation-sound-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(88px,1fr)); gap: 8px; }
.foundation-sound-grid.words { grid-template-columns: repeat(auto-fill, minmax(155px,1fr)); }
.foundation-sound { min-height: 82px; padding: 9px; border: 1px solid var(--line); border-radius: 14px; background: rgba(246,244,239,.68); cursor: pointer; display: grid; grid-template-columns: 16px minmax(0,1fr); align-items: center; column-gap: 5px; text-align: left; transition: .18s; }
.foundation-sound:hover { border-color: rgba(217,95,75,.45); background: white; transform: translateY(-1px); }
.foundation-sound > span { grid-row: 1 / span 2; color: var(--accent); font-size: 8px; }
.foundation-sound b { font-size: 23px; font-weight: 700; }
.foundation-sound small { color: var(--muted); font-size: 9px; overflow-wrap: anywhere; }
.foundation-sound-grid.words .foundation-sound b { font-size: 18px; }
.foundation-examples { margin-top: 23px; padding-top: 18px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 8px; }
.foundation-examples .section-label { width: 100%; }
.foundation-examples button { min-height: 52px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 12px; background: white; cursor: pointer; display: grid; grid-template-columns: 18px auto; column-gap: 7px; text-align: left; }
.foundation-examples button > span { grid-row: 1 / span 2; align-self: center; color: var(--accent); font-size: 9px; }
.foundation-examples b { font-size: 13px; }
.foundation-examples small { color: var(--muted); font-size: 9px; }
.foundation-record { margin-top: 18px; padding: 17px; border-radius: 15px; border: 1px solid var(--line); background: rgba(255,255,255,.56); }
.foundation-record > div:first-child b, .foundation-record > div:first-child span { display: block; }
.foundation-record > div:first-child span { margin-top: 4px; color: var(--muted); font-size: 11px; }

.foundation-quiz-start, .foundation-quiz-result { margin-top: 15px; padding: 25px; display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 22px; align-items: center; }
.foundation-quiz-start h2, .foundation-quiz-result h2 { font-size: 20px; }
.foundation-quiz-start p, .foundation-quiz-result p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.65; }
.foundation-quiz-live { margin-top: 15px; padding: 27px; }
.foundation-quiz-top { display: flex; justify-content: space-between; gap: 14px; color: var(--muted); font-size: 10px; }
.foundation-quiz-top b { color: var(--ink); }
.foundation-question-sound { width: 100%; min-height: 176px; margin: 18px 0; border: 0; border-radius: 19px; background: linear-gradient(145deg, var(--ink), #323d39); color: white; cursor: pointer; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.foundation-question-sound > span { color: rgba(255,255,255,.6); font-size: 11px; }
.foundation-question-sound strong { margin: 9px 0 5px; font-size: clamp(38px, 7vw, 62px); font-weight: 650; }
.foundation-question-sound small { color: rgba(255,255,255,.65); font-size: 10px; }
.foundation-options { display: grid; grid-template-columns: repeat(4, 1fr); gap: 9px; }
.foundation-options button { min-height: 49px; border: 1px solid var(--line); border-radius: 13px; background: white; cursor: pointer; font-weight: 750; }
.foundation-options button:hover:not(:disabled) { border-color: var(--accent); background: var(--accent-soft); }
.foundation-options button.correct { border-color: var(--sage); background: var(--sage-soft); color: #496555; }
.foundation-options button.wrong { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-deep); }
.foundation-options button:disabled { opacity: 1; cursor: default; }
.foundation-answer-note { min-height: 45px; margin-top: 12px; padding: 10px 12px 10px 15px; border-radius: 12px; display: flex; align-items: center; justify-content: space-between; gap: 13px; font-size: 11px; }
.foundation-answer-note.correct { background: var(--sage-soft); color: #496555; }
.foundation-answer-note.wrong { background: var(--accent-soft); color: var(--accent-deep); }
.foundation-quiz-hint { margin: 12px 0 0; color: var(--muted); text-align: center; font-size: 10px; }
.foundation-quiz-result { grid-template-columns: 105px minmax(0,1fr); }
.foundation-quiz-result.passed { border-color: rgba(111,135,121,.48); background: var(--sage-soft); }
.foundation-quiz-result.retry { border-color: rgba(217,95,75,.3); background: rgba(248,230,225,.66); }
.foundation-result-score { width: 92px; height: 92px; border-radius: 50%; background: white; display: flex; align-items: baseline; justify-content: center; padding-top: 26px; }
.foundation-result-score strong { font-size: 30px; }
.foundation-result-score span { color: var(--muted); font-size: 11px; }
.foundation-result-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.foundation-next-explain { margin-bottom: 10px; }

.tips-hero { padding: 30px; display: grid; grid-template-columns: minmax(0,1fr) 210px; gap: 30px; background: linear-gradient(145deg, rgba(255,255,255,.96), rgba(248,230,225,.58)); }
.tips-recommended { display: flex; align-items: center; gap: 14px; margin-bottom: 15px; }
.tips-recommended > span { width: 48px; height: 48px; flex: 0 0 48px; border-radius: 15px; background: var(--accent); color: white; display: grid; place-items: center; font-size: 18px; font-weight: 850; }
.tips-recommended small { display: block; color: var(--muted); font-size: 10px; font-weight: 750; margin-bottom: 3px; }
.tips-recommended h2 { margin: 0; }
.tips-hero-main > p { color: #4d5753; line-height: 1.75; margin-bottom: 14px; max-width: 760px; }
.tips-do-now { padding: 14px 16px; border-radius: 14px; background: rgba(255,255,255,.72); border: 1px solid rgba(217,95,75,.18); font-size: 13px; line-height: 1.65; }
.tips-do-now b { color: var(--accent-deep); }
.tips-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 18px; }
.tips-hero-score { display: flex; flex-direction: column; align-items: center; justify-content: center; padding-left: 26px; border-left: 1px solid rgba(25,32,30,.08); text-align: center; }
.tips-hero-score p { margin: 14px 0 0; color: var(--muted); font-size: 11px; line-height: 1.55; }
.ring.compact { width: 118px; height: 118px; }
.ring.compact::after { width: 92px; height: 92px; }
.ring.compact .ring-number { font-size: 23px; }

.learning-progress-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.skill-progress-card { padding: 17px; box-shadow: none; border-color: var(--line); background: rgba(255,255,255,.64); position: relative; }
.skill-progress-head { display: grid; grid-template-columns: 36px minmax(0,1fr) auto; gap: 10px; align-items: center; }
.skill-progress-head > span { width: 36px; height: 36px; border-radius: 11px; background: var(--sage-soft); color: #4c6858; display: grid; place-items: center; font-size: 12px; font-weight: 850; }
.skill-progress-head b { display: block; font-size: 13px; }
.skill-progress-head small { display: block; color: var(--muted); font-size: 9px; line-height: 1.4; margin-top: 3px; }
.skill-progress-head strong { font-size: 13px; }
.skill-progress-card .lesson-progress { margin: 13px 0 0; height: 6px; }
.skill-progress-card em { position: absolute; right: 17px; bottom: 10px; color: var(--muted); font-size: 9px; font-style: normal; }

.method-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 9px; }
.method-strip span { display: flex; gap: 9px; align-items: center; min-height: 52px; padding: 10px 12px; border-radius: 14px; border: 1px solid var(--line); background: rgba(255,255,255,.58); color: #4e5753; font-size: 11px; line-height: 1.45; }
.method-strip b { width: 25px; height: 25px; flex: 0 0 25px; border-radius: 8px; display: grid; place-items: center; color: white; background: var(--ink); font-size: 10px; }

.tip-group-section { scroll-margin-top: 20px; }
.tip-group-heading { display: grid; grid-template-columns: 48px minmax(0,1fr) auto; gap: 13px; align-items: center; margin-bottom: 14px; }
.tip-group-mark { width: 48px; height: 48px; border-radius: 15px; background: var(--sage); font-size: 16px; }
.tip-group-heading h2 { font-size: 20px; margin: 0; }
.tip-group-heading p { color: var(--muted); font-size: 12px; margin: 3px 0 0; }
.tip-group-heading > span { min-width: 48px; padding: 7px 10px; border-radius: 999px; background: var(--paper-deep); color: var(--muted); text-align: center; font-size: 11px; font-weight: 750; }
.learning-tip-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 13px; }
.learning-tip-card { padding: 22px; display: flex; flex-direction: column; box-shadow: none; border-color: var(--line); background: rgba(255,255,255,.67); transition: .2s ease; }
.learning-tip-card.mastered { border-color: rgba(111,135,121,.48); background: rgba(231,238,233,.72); }
.tip-card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.tip-group-chip { padding: 5px 8px; border-radius: 8px; background: var(--accent-soft); color: var(--accent-deep); font-size: 9px; font-weight: 800; }
.tip-week { color: var(--muted); font-size: 9px; }
.learning-tip-card h3 { font-size: 18px; line-height: 1.42; margin-bottom: 8px; }
.tip-memory { color: var(--sage); font-weight: 750; font-size: 12px; line-height: 1.55; margin-bottom: 12px; }
.learning-tip-card > p { color: var(--muted); font-size: 12px; line-height: 1.72; margin-bottom: 14px; }
.tip-example, .tip-practice { padding: 12px 13px; border-radius: 13px; font-size: 11px; line-height: 1.62; }
.tip-example { background: var(--blue-soft); color: #475e70; margin-bottom: 8px; }
.tip-practice { background: var(--amber-soft); color: #6c542e; margin-bottom: 16px; }
.tip-example b, .tip-practice b { display: block; font-size: 9px; letter-spacing: .08em; margin-bottom: 3px; }
.learning-tip-card > .btn { align-self: flex-start; margin-top: auto; }

.week-block { margin-bottom: 26px; }
.week-header { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.week-number {
  width: 42px; height: 42px; border-radius: 13px; background: var(--ink); color: white;
  display: grid; place-items: center; font-size: 12px; font-weight: 800;
}
.week-header h2 { font-size: 19px; margin: 0; }
.week-header p { margin: 3px 0 0; color: var(--muted); font-size: 12px; }
.lesson-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 13px; }
.lesson-card {
  position: relative; padding: 20px; min-height: 164px; cursor: pointer;
  background: rgba(255,255,255,.72); border: 1px solid var(--line); border-radius: 18px;
  transition: .2s ease; overflow: hidden;
}
.lesson-card:hover { transform: translateY(-2px); background: #fff; box-shadow: 0 14px 30px rgba(39,48,44,.08); }
.lesson-card.done { border-color: rgba(111,135,121,.45); background: rgba(239,246,241,.76); }
.lesson-card.current { border-color: rgba(217,95,75,.5); box-shadow: 0 0 0 3px rgba(217,95,75,.07); }
.lesson-index { font-size: 10px; color: var(--muted); font-weight: 800; letter-spacing: .1em; }
.lesson-card h3 { font-size: 16px; margin: 10px 0 3px; }
.lesson-card .jp { color: var(--muted); font-size: 12px; }
.lesson-card .scene { color: var(--muted); font-size: 12px; line-height: 1.55; margin-top: 16px; }
.check { position: absolute; right: 16px; top: 16px; width: 24px; height: 24px; border-radius: 50%; background: var(--sage); color: white; display: grid; place-items: center; font-size: 12px; }

.lesson-layout { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 22px; align-items: start; }
.lesson-main { min-width: 0; }
.lesson-side { position: sticky; top: 24px; display: grid; gap: 13px; }
.back-btn { border: 0; background: transparent; color: var(--muted); cursor: pointer; padding: 4px 0; margin-bottom: 18px; display: inline-flex; gap: 8px; }
.lesson-banner { padding: 29px; margin-bottom: 17px; position: relative; overflow: hidden; }
.lesson-banner .week-chip { display: inline-flex; background: var(--accent-soft); color: var(--accent-deep); padding: 6px 9px; border-radius: 8px; font-size: 10px; font-weight: 800; margin-bottom: 15px; }
.lesson-banner h1 { font-size: 32px; }
.lesson-banner .objective { line-height: 1.72; color: #46504c; max-width: 720px; }
.lesson-tabs { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 13px; scrollbar-width: none; }
.tab { border: 1px solid var(--line); background: rgba(255,255,255,.65); border-radius: 12px; min-height: 39px; padding: 0 15px; cursor: pointer; white-space: nowrap; color: var(--muted); font-size: 12px; font-weight: 700; }
.tab.active { background: var(--ink); border-color: var(--ink); color: white; }
.lesson-section { padding: 26px; }
.lesson-section + .lesson-section { margin-top: 15px; }
.section-label { color: var(--accent); font-size: 10px; font-weight: 800; letter-spacing: .15em; margin-bottom: 8px; }
.phrase-list { display: grid; gap: 11px; margin-top: 18px; }
.phrase {
  display: grid; grid-template-columns: 42px minmax(0,1fr) auto; gap: 14px; align-items: center;
  padding: 15px; background: rgba(246,244,239,.75); border-radius: 15px; border: 1px solid transparent;
}
.phrase:hover { border-color: var(--line); }
.play {
  width: 38px; height: 38px; border-radius: 12px; border: 0; cursor: pointer;
  background: white; color: var(--accent); display: grid; place-items: center; box-shadow: 0 4px 14px rgba(39,48,44,.07);
}
.phrase-jp { font-size: 18px; font-weight: 720; line-height: 1.45; }
.phrase-kana { font-size: 11px; color: var(--blue); margin-top: 3px; }
.replace-hint { margin-top: 9px; color: #66716c; font-size: 11px; line-height: 1.55; }
.replace-hint b { color: var(--sage); }
.phrase-cn { font-size: 12px; color: var(--muted); text-align: right; max-width: 220px; }
.register { display: inline-flex; align-items: center; gap: 5px; font-size: 10px; font-weight: 750; padding: 4px 7px; border-radius: 999px; margin-top: 6px; }
.register.safe { background: var(--sage-soft); color: #4d6758; }
.register.casual { background: var(--amber-soft); color: #79551e; }
.register.listen { background: var(--blue-soft); color: #496b84; }

.dialogue { display: grid; gap: 14px; margin-top: 20px; }
.line { display: flex; gap: 11px; align-items: flex-start; }
.line.me { flex-direction: row-reverse; }
.avatar { width: 34px; height: 34px; border-radius: 11px; background: var(--sage-soft); color: var(--sage); font-size: 11px; font-weight: 800; display: grid; place-items: center; flex: 0 0 auto; }
.line.me .avatar { background: var(--accent-soft); color: var(--accent); }
.bubble { max-width: 76%; background: #f3f4f1; padding: 12px 15px; border-radius: 5px 16px 16px 16px; line-height: 1.6; }
.line.me .bubble { background: var(--accent-soft); border-radius: 16px 5px 16px 16px; }
.speaker { font-size: 10px; font-weight: 800; color: var(--muted); margin-bottom: 3px; }
.bubble-jp { font-size: 15px; }
.bubble-cn { color: var(--muted); font-size: 11px; margin-top: 4px; }

.grammar-list { display: grid; gap: 11px; margin-top: 17px; }
.grammar { border-left: 3px solid var(--sage); padding: 4px 0 4px 14px; }
.grammar b { display: block; font-size: 14px; margin-bottom: 5px; }
.grammar span { color: var(--muted); font-size: 12px; line-height: 1.6; }
.example-warning { margin-top: 16px; padding: 13px 15px; border-radius: 13px; background: var(--amber-soft); color: #715727; font-size: 12px; line-height: 1.65; }
.coach-flow { display: grid; gap: 15px; }
.coach-step { padding: 27px; display: grid; grid-template-columns: 48px minmax(0, 1fr); gap: 17px; box-shadow: none; border-color: var(--line); }
.coach-step-no { width: 40px; height: 40px; border-radius: 13px; background: var(--ink); color: white; display: grid; place-items: center; font-size: 11px; font-weight: 850; }
.coach-step-body { min-width: 0; }
.coach-step-body h2 { font-size: 21px; }
.greeting-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; margin-top: 18px; }
.greeting-card { border: 1px solid var(--line); background: white; border-radius: 14px; padding: 15px; text-align: left; cursor: pointer; position: relative; }
.greeting-card::before { content: "▶"; display: block; color: var(--accent); font-size: 9px; margin-bottom: 10px; }
.greeting-card b { display: block; font-size: 14px; }
.greeting-card span { display: block; color: var(--muted); font-size: 10px; margin-top: 5px; }
.greeting-card.recommended { border-color: rgba(217,95,75,.55); background: var(--accent-soft); }
.greeting-card.recommended::after { content: "现在"; position: absolute; right: 9px; top: 9px; background: var(--accent); color: white; border-radius: 99px; padding: 3px 6px; font-size: 9px; }
.teacher-note { margin-top: 11px; color: var(--muted); font-size: 11px; }
.teacher-note b { color: var(--ink); }
.teacher-note { padding: 12px 14px; border-radius: 12px; background: var(--paper-deep); line-height: 1.65; }
.teacher-note.success { background: var(--sage-soft); color: #4d6758; }
.teacher-note.retry { background: var(--amber-soft); color: #76531c; }
.decision-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin-top: 18px; }
.decision-option { min-height: 68px; border: 1px solid var(--line); background: white; border-radius: 14px; padding: 11px; display: flex; align-items: center; gap: 10px; text-align: left; cursor: pointer; }
.decision-option > span { flex: 0 0 auto; width: 27px; height: 27px; border-radius: 9px; background: var(--paper-deep); color: var(--muted); display: grid; place-items: center; font-size: 10px; font-weight: 850; }
.decision-option b { font-size: 13px; line-height: 1.45; }
.decision-option.correct { border-color: var(--sage); background: var(--sage-soft); }
.decision-option.correct > span { background: var(--sage); color: white; }
.decision-option.wrong { border-color: var(--accent); background: var(--accent-soft); }
.decision-option.wrong > span { background: var(--accent); color: white; }
.profile-form { display: grid; grid-template-columns: 1fr 1fr auto; gap: 10px; align-items: end; margin-top: 19px; }
.profile-form label span { display: block; color: var(--muted); font-size: 10px; font-weight: 700; margin: 0 0 6px 3px; }
.profile-form input { width: 100%; min-height: 44px; border: 1px solid var(--line); background: white; border-radius: 12px; padding: 0 13px; outline: none; }
.profile-form input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(217,95,75,.08); }
.coach-context { margin-top: 18px; padding: 16px; background: var(--blue-soft); border-radius: 15px; }
.context-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.context-head b { font-size: 12px; }
.context-head span { color: var(--muted); font-size: 10px; }
.profile-form.compact { margin-top: 12px; }
.coach-phrase-picker { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; }
.coach-phrase-choice { position: relative; min-height: 138px; padding: 17px; border: 1px solid var(--line); border-radius: 15px; background: white; text-align: left; cursor: pointer; display: flex; flex-direction: column; align-items: flex-start; }
.coach-phrase-choice.active { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(217,95,75,.08); }
.coach-phrase-choice .pick-label { align-self: flex-end; padding: 4px 7px; border-radius: 999px; background: var(--paper-deep); color: var(--muted); font-size: 9px; }
.coach-phrase-choice.active .pick-label { background: var(--accent); color: white; }
.coach-phrase-choice b { margin-top: 8px; font-size: 15px; line-height: 1.45; }
.coach-phrase-choice small { margin-top: 4px; color: var(--muted); line-height: 1.5; }
.coach-phrase-choice em { margin-top: auto; padding-top: 10px; color: var(--sage); font-size: 10px; font-style: normal; line-height: 1.5; }
.listen-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 17px; }
.blind-listen { min-height: 180px; margin-top: 14px; border: 1px dashed #bfc5c0; border-radius: 16px; background: rgba(245,243,238,.6); display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 24px; }
.blind-listen > span { width: 44px; height: 44px; border-radius: 15px; background: var(--ink); color: white; display: grid; place-items: center; font-size: 18px; margin-bottom: 13px; }
.blind-listen b { font-size: 13px; }
.blind-listen small { color: var(--muted); margin-top: 6px; }
.formula { margin-top: 15px; padding: 14px 16px; border-radius: 13px; background: var(--sage-soft); display: flex; align-items: center; gap: 8px; font-size: 13px; }
.formula span { color: #476153; }
.formula b { color: var(--ink); }
.micro-copy { margin: 10px 0 0; color: var(--muted); font-size: 11px; line-height: 1.65; }
.coach-step.locked { opacity: .68; background: rgba(255,255,255,.5); }
.coach-step.ready { border-color: rgba(111,135,121,.35); }
.locked-copy { margin-top: 16px; border: 1px dashed var(--line); border-radius: 14px; padding: 22px; color: var(--muted); font-size: 12px; text-align: center; }
.my-intro { margin-top: 18px; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 20px; background: #f4f6f3; border-radius: 16px; }
.intro-jp { font-size: 21px; font-weight: 750; line-height: 1.7; }
.intro-jp mark { background: var(--accent-soft); color: var(--accent-deep); padding: 1px 5px; border-radius: 6px; }
.intro-meaning { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 8px; }
.intro-meaning span { color: var(--muted); font-size: 10px; text-align: center; }
.practice-switch { display: inline-flex; margin-top: 16px; padding: 4px; background: var(--paper-deep); border-radius: 12px; }
.practice-switch button { border: 0; background: transparent; border-radius: 9px; padding: 8px 12px; color: var(--muted); font-size: 11px; cursor: pointer; }
.practice-switch button.active { background: white; color: var(--ink); box-shadow: 0 3px 10px rgba(39,48,44,.08); }
.practice-stage { min-height: 140px; margin-top: 12px; border-radius: 16px; background: var(--ink); color: white; display: flex; flex-direction: column; justify-content: center; align-items: center; padding: 25px; font-size: 21px; font-weight: 700; line-height: 1.7; text-align: center; }
.keyword-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.keyword-row span { border: 1px solid rgba(255,255,255,.23); border-radius: 99px; padding: 8px 12px; font-size: 13px; }
.blank-practice { color: rgba(255,255,255,.7); font-size: 14px; font-weight: 500; }
.practice-jp { font-size: 22px; }
.pronunciation-lab { margin-top: 14px; padding: 17px; border: 1px solid var(--line); border-radius: 16px; background: white; }
.pron-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.pron-head > div:first-child b, .pron-head > div:first-child span { display: block; }
.pron-head > div:first-child b { font-size: 13px; }
.pron-head > div:first-child span { margin-top: 4px; color: var(--muted); font-size: 10px; }
.pron-actions { display: flex; gap: 7px; }
.btn-record { background: var(--accent-soft); color: var(--accent-deep); border: 1px solid rgba(217,95,75,.18); }
.pron-live { margin-top: 13px; }
.pron-placeholder { padding: 14px; background: var(--paper); color: var(--muted); border-radius: 12px; font-size: 11px; line-height: 1.65; }
.pron-status { padding: 15px; border-radius: 12px; background: var(--paper); color: var(--muted); font-size: 11px; }
.pron-status.recording span, .pron-status.analyzing span { display: inline-block; width: 8px; height: 8px; margin-right: 8px; border-radius: 50%; background: var(--accent); animation: pulse 1s ease infinite; }
@keyframes pulse { 50% { opacity: .35; transform: scale(.75); } }
.pron-status.error { background: var(--amber-soft); color: #76531c; }
.pron-result { display: grid; grid-template-columns: 88px minmax(0,1fr); gap: 13px; }
.pron-score { border-radius: 14px; background: var(--ink); color: white; display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 84px; }
.pron-score strong { font-size: 29px; }
.pron-score span { font-size: 9px; color: rgba(255,255,255,.68); }
.score-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.score-grid div { background: var(--paper); border-radius: 11px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 8px 4px; }
.score-grid b { font-size: 16px; }
.score-grid span { color: var(--muted); font-size: 9px; margin-top: 2px; }
.pron-feedback { grid-column: 1 / -1; margin: 0; padding: 12px 12px 12px 30px; border-radius: 12px; background: var(--sage-soft); color: #4d6758; font-size: 11px; line-height: 1.7; }
.pron-note { grid-column: 1 / -1; color: var(--muted); font-size: 10px; line-height: 1.6; margin: 0; }
.recording-playback { grid-column: 1 / -1; width: 100%; height: 35px; margin-top: 9px; }
.ladder { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 16px; }
.ladder > div { min-height: 72px; padding: 12px; border-radius: 13px; background: var(--paper); color: #59615e; font-size: 11px; line-height: 1.55; }
.ladder span { display: block; color: var(--accent); font-weight: 850; margin-bottom: 5px; }
.mission-checks { display: grid; gap: 8px; margin-top: 15px; }
.mission-check { display: flex; align-items: flex-start; gap: 9px; padding: 11px 12px; border: 1px solid var(--line); border-radius: 12px; background: white; cursor: pointer; color: #56605c; font-size: 11px; line-height: 1.5; }
.mission-check input { margin-top: 2px; accent-color: var(--sage); }
.mission-check.checked { border-color: rgba(111,135,121,.42); background: var(--sage-soft); }
.mastery-inline { margin-top: 17px; padding-top: 15px; border-top: 1px solid var(--line); }
.mastery-inline > div:first-child { display: flex; align-items: baseline; justify-content: space-between; }
.mastery-inline > div:first-child b { font-size: 22px; }
.mastery-inline > div:first-child span, .mastery-inline small { color: var(--muted); font-size: 10px; }
.teacher-summary ul { margin: 16px 0 0; padding-left: 20px; color: #58615d; font-size: 12px; line-height: 1.9; }
.reading-box { margin-top: 17px; padding: 22px; border-radius: 16px; background: #f3f1eb; }
.reading-strategy { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 17px; }
.reading-strategy div { padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: white; color: #59615e; font-size: 11px; line-height: 1.55; }
.reading-strategy span { display: block; color: var(--accent); font-weight: 850; margin-bottom: 4px; }
.reading-title { color: var(--muted); font-size: 11px; margin-bottom: 12px; }
.reading-body { white-space: pre-line; font-size: 17px; line-height: 2; font-family: "Yu Mincho", "Hiragino Mincho ProN", serif; }
.reading-cn { margin-top: 13px; border-top: 1px solid var(--line); padding-top: 12px; color: var(--muted); font-size: 12px; line-height: 1.7; }
.reading-question { margin-top: 13px; border-top: 1px solid var(--line); padding-top: 12px; color: var(--sage); font-size: 12px; line-height: 1.7; }
.reading-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.tip-box { padding: 19px; border-radius: 17px; background: var(--amber-soft); border: 1px solid rgba(169,121,49,.12); }
.tip-box h3 { color: #72531f; }
.tip-box p { font-size: 12px; color: #795f33; line-height: 1.7; margin: 0; }
.mission-box { padding: 19px; }
.mission-box p { font-size: 12px; color: var(--muted); line-height: 1.7; }
.mastery-side { display: flex; align-items: baseline; justify-content: space-between; margin-top: 12px; }
.mastery-side b { font-size: 24px; }
.mastery-side span, .mission-help { color: var(--muted); font-size: 10px; line-height: 1.5; }
.lesson-progress { height: 8px; border-radius: 99px; background: var(--paper-deep); overflow: hidden; margin: 14px 0 8px; }
.lesson-progress span { display: block; height: 100%; background: var(--accent); border-radius: inherit; }

.quiz-question { font-size: 20px; line-height: 1.5; margin: 22px 0; }
.answers { display: grid; gap: 10px; }
.answer { text-align: left; border: 1px solid var(--line); background: white; min-height: 49px; padding: 11px 14px; border-radius: 13px; cursor: pointer; }
.answer:hover { border-color: var(--sage); }
.answer.correct { background: var(--sage-soft); border-color: var(--sage); }
.answer.wrong { background: var(--accent-soft); border-color: var(--accent); }

.review-wrap { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 20px; }
.flashcard { min-height: 390px; padding: 38px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; cursor: pointer; position: relative; }
.flash-label { position: absolute; top: 24px; left: 26px; font-size: 10px; color: var(--muted); letter-spacing: .13em; font-weight: 800; }
.flash-context { position: absolute; top: 50px; color: var(--sage); font-size: 11px; }
.flash-jp { font-size: clamp(28px, 5vw, 46px); line-height: 1.4; font-weight: 750; }
.flash-jp.production-prompt { font-size: clamp(23px, 4vw, 36px); }
.flash-answer { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 6px; }
.flash-answer b { font-size: 22px; }
.flash-answer span { color: var(--blue); font-size: 12px; }
.flash-answer p { margin: 0; color: var(--muted); }
.flash-answer em { margin-top: 5px; color: var(--sage); font-size: 10px; font-style: normal; }
.flash-kana { margin-top: 9px; color: var(--blue); }
.flash-cn { margin-top: 20px; color: var(--muted); font-size: 16px; }
.flash-hint { position: absolute; bottom: 22px; color: var(--muted); font-size: 11px; }
.rating { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; margin-top: 13px; }
.rating button { border: 0; min-height: 44px; border-radius: 13px; cursor: pointer; font-weight: 750; }
.rating .again { background: var(--accent-soft); color: var(--accent-deep); }
.rating .hard { background: var(--amber-soft); color: #76531c; }
.rating.four { grid-template-columns: repeat(4, 1fr); }
.rating .good { background: var(--blue-soft); color: #496b84; }
.rating .easy { background: var(--sage-soft); color: #4d6758; }
.review-lapse { display: block; margin-top: 14px; color: var(--accent-deep); line-height: 1.5; }

.kana-controls { display: flex; gap: 8px; margin-bottom: 18px; }
.kana-focus { margin-top: 18px; padding: 15px 17px; border-radius: 14px; background: var(--blue-soft); display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.kana-focus span, .kana-focus b { display: block; }
.kana-focus span { color: var(--blue); font-size: 10px; font-weight: 800; margin-bottom: 6px; }
.kana-focus b { font-size: 18px; letter-spacing: .08em; }
.kana-focus > div:last-child { text-align: right; }
.kana-focus strong, .kana-focus small { display: block; }
.kana-focus strong { font-size: 20px; }
.kana-focus small { color: var(--muted); font-size: 9px; }
.kana-table { display: grid; grid-template-columns: repeat(5, minmax(74px, 1fr)); gap: 10px; }
.kana-card { min-height: 92px; border: 1px solid var(--line); background: rgba(255,255,255,.7); border-radius: 16px; cursor: pointer; display: flex; flex-direction: column; align-items: center; justify-content: center; transition: .18s; }
.kana-card:hover { background: white; transform: translateY(-2px); }
.kana-card.known { border-color: rgba(111,135,121,.5); background: var(--sage-soft); }
.kana-char { font-size: 30px; font-weight: 700; }
.kana-romaji { color: var(--muted); font-size: 10px; margin-top: 4px; }
.kana-card i { margin-top: 5px; color: var(--muted); font-size: 8px; font-style: normal; }
.kana-card.known i { color: var(--sage); }
.sound-labs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.sound-lab { padding: 22px; box-shadow: none; border-color: var(--line); }
.sound-num { color: var(--accent); font-size: 10px; font-weight: 850; letter-spacing: .14em; margin-bottom: 11px; }
.sound-lab h3 { font-size: 16px; line-height: 1.45; }
.sound-lab > p { min-height: 58px; color: var(--muted); font-size: 12px; line-height: 1.65; }
.sound-samples { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 16px; }
.sound-sample { border: 1px solid var(--line); background: white; border-radius: 12px; min-height: 62px; padding: 9px 10px; display: flex; align-items: center; gap: 9px; text-align: left; cursor: pointer; transition: .18s; }
.sound-sample:hover { border-color: var(--accent); transform: translateY(-1px); }
.sound-play { color: var(--accent); font-size: 10px; }
.sound-sample b { display: block; font-size: 13px; line-height: 1.45; }
.sound-sample small { display: block; margin-top: 2px; color: var(--muted); font-size: 10px; }
.sound-pronunciation { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.sound-pronunciation > b { display: block; font-size: 11px; line-height: 1.5; }
.sound-pron-actions { display: flex; gap: 6px; margin-top: 9px; }
.sound-pron-actions .btn { flex: 1; padding: 0 8px; }
.sound-pronunciation .pron-result { grid-template-columns: 1fr; }
.sound-pronunciation .pron-feedback, .sound-pronunciation .pron-note { grid-column: auto; }

.polite-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 15px; }
.polite-card { padding: 22px; }
.risk-head { display: flex; align-items: center; gap: 9px; margin-bottom: 16px; }
.risk-dot { width: 10px; height: 10px; border-radius: 50%; }
.risk-dot.safe { background: var(--sage); }
.risk-dot.warn { background: var(--amber); }
.risk-dot.danger { background: var(--accent); }
.bad-phrase { font-size: 20px; font-weight: 780; }
.risk-reason { color: var(--muted); font-size: 12px; line-height: 1.65; margin: 8px 0 15px; }
.better { border-top: 1px solid var(--line); padding-top: 13px; font-size: 13px; }
.better b { color: var(--sage); }

.settings-card { padding: 26px; max-width: 700px; }
.profile-settings { margin-top: 17px; }
.settings-profile-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 20px 0 16px; }
.settings-profile-grid label span { display: block; margin: 0 0 6px 3px; color: var(--muted); font-size: 10px; font-weight: 700; }
.settings-profile-grid input { width: 100%; min-height: 43px; border: 1px solid var(--line); background: white; border-radius: 12px; padding: 0 13px; outline: none; }
.settings-profile-grid input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(217,95,75,.08); }
.setting-row { display: flex; justify-content: space-between; gap: 18px; align-items: center; padding: 17px 0; border-bottom: 1px solid var(--line); }
.setting-row:last-child { border: 0; }
.setting-copy p { margin: 4px 0 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.select { border: 1px solid var(--line); background: white; border-radius: 11px; min-height: 40px; padding: 0 12px; }
.toggle { width: 46px; height: 26px; border-radius: 99px; border: 0; background: #cccfc9; cursor: pointer; padding: 3px; transition: .2s; }
.toggle::after { content: ""; display: block; width: 20px; height: 20px; border-radius: 50%; background: white; box-shadow: 0 2px 5px rgba(0,0,0,.15); transition: .2s; }
.toggle.on { background: var(--sage); }
.toggle.on::after { transform: translateX(20px); }

.empty { padding: 46px; text-align: center; }
.empty .big { font-size: 44px; margin-bottom: 13px; }
.empty p { color: var(--muted); }
.toast { position: fixed; left: 50%; bottom: 28px; transform: translate(-50%, 18px); padding: 11px 17px; border-radius: 12px; background: var(--ink); color: white; font-size: 12px; z-index: 100; opacity: 0; pointer-events: none; transition: .25s; box-shadow: 0 12px 30px rgba(0,0,0,.16); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

.mobile-nav { display: none; }

@media (max-width: 980px) {
  :root { --sidebar: 208px; }
  .main { padding: 28px 26px 54px; }
  .grid-2, .review-wrap, .lesson-layout { grid-template-columns: 1fr; }
  .lesson-side { position: static; grid-template-columns: repeat(2, 1fr); }
  .lesson-row, .daily-plan { grid-template-columns: 1fr 1fr; }
  .week-rhythm { grid-template-columns: repeat(4, 1fr); }
  .learning-progress-grid { grid-template-columns: repeat(2, 1fr); }
  .tips-hero { grid-template-columns: 1fr; }
  .tips-hero-score { padding: 20px 0 0; border-left: 0; border-top: 1px solid rgba(25,32,30,.08); }
  .method-strip { grid-template-columns: repeat(2, 1fr); }
  .foundation-week, .foundation-day-tabs { grid-template-columns: repeat(4, 1fr); }
  .foundation-status { grid-template-columns: minmax(0,1fr) 130px; }
  .foundation-status > .btn { grid-column: 1 / -1; justify-self: start; }
  .family-access { grid-template-columns: 52px minmax(0,1fr); }
  .family-access-actions { grid-column: 2; justify-content: flex-start; }
  .phrase-cn { max-width: 150px; }
}

@media (max-width: 720px) {
  body { padding-bottom: 72px; }
  .sidebar { display: none; }
  .main { margin-left: 0; padding: 23px 16px 34px; }
  .topbar { align-items: flex-start; margin-bottom: 24px; }
  .date-pill { display: none; }
  h1 { font-size: 29px; }
  .focus-home { padding-top: 3px; }
  .focus-welcome { align-items: flex-start; gap: 14px; margin-bottom: 20px; }
  .focus-welcome h1 { font-size: 31px; }
  .focus-welcome p { font-size: 12px; }
  .focus-streak { width: 72px; min-height: 69px; padding: 11px 7px; border-radius: 15px; }
  .focus-streak b { font-size: 23px; }
  .focus-streak span { font-size: 8px; }
  .today-focus { padding: 25px 21px 23px; }
  .today-focus::after { right: -34px; bottom: -62px; font-size: 190px; }
  .focus-kana { margin-bottom: 17px; font-size: 27px; letter-spacing: .08em; }
  .today-focus h2 { font-size: 25px; }
  .focus-three { grid-template-columns: 1fr; gap: 7px; margin: 21px 0; }
  .focus-three span { padding: 7px 9px; border-radius: 10px; background: rgba(245,243,238,.82); }
  .focus-start { width: 100%; }
  .focus-roadmap { padding: 18px; }
  .focus-roadmap-head span { max-width: 220px; }
  .focus-tip-line { grid-template-columns: auto minmax(0,1fr); }
  .focus-tip-line button { grid-column: 2; justify-self: start; padding: 0; }
  .focus-quiet-actions { padding-top: 15px; }
  .more-grid { grid-template-columns: 1fr; }
  .more-card { min-height: 0; display: grid; grid-template-columns: 43px minmax(0,1fr) auto; align-items: center; gap: 14px; padding: 18px; }
  .more-card > span:nth-child(2) { margin-top: 0; }
  .more-card i { margin: 0; align-self: center; }
  .hero-card { padding: 24px; min-height: 250px; }
  .hero-title { font-size: 24px; }
  .grid-3, .lesson-row, .daily-plan, .polite-grid { grid-template-columns: 1fr; }
  .lesson-side { grid-template-columns: 1fr; }
  .coach-step { grid-template-columns: 1fr; padding: 21px; }
  .greeting-grid { grid-template-columns: 1fr; }
  .profile-form { grid-template-columns: 1fr; }
  .decision-grid, .coach-phrase-picker, .ladder, .settings-profile-grid { grid-template-columns: 1fr; }
  .reading-strategy { grid-template-columns: 1fr; }
  .pron-head { align-items: flex-start; flex-direction: column; }
  .pron-actions { width: 100%; }
  .pron-actions .btn { flex: 1; }
  .pron-result { grid-template-columns: 1fr; }
  .pron-feedback, .pron-note, .recording-playback { grid-column: auto; }
  .week-rhythm { grid-template-columns: repeat(2, 1fr); }
  .home-tip { grid-template-columns: 46px minmax(0,1fr); padding: 20px; }
  .home-tip-mark { width: 46px; height: 46px; border-radius: 14px; font-size: 16px; }
  .home-tip > .btn { grid-column: 2; justify-self: start; }
  .foundation-home-hero { min-height: 340px; }
  .foundation-home-hero .hero-actions { flex-direction: column; align-items: stretch; }
  .foundation-week, .foundation-day-tabs { grid-template-columns: repeat(2, 1fr); }
  .foundation-day-mini { min-height: 96px; }
  .foundation-explain { grid-template-columns: 46px minmax(0,1fr); padding: 19px; }
  .family-access { grid-template-columns: 44px minmax(0,1fr); padding: 19px; }
  .family-access-mark { width: 44px; height: 44px; border-radius: 14px; }
  .family-access-actions { grid-column: 2; }
  .family-access-actions .btn { width: 100%; }
  .course-gate { grid-template-columns: 46px minmax(0,1fr); padding: 20px; }
  .course-gate-mark { width: 46px; height: 46px; border-radius: 14px; }
  .course-gate > .btn { grid-column: 2; justify-self: start; }
  .foundation-status { grid-template-columns: 1fr; padding: 20px; gap: 14px; }
  .foundation-status-progress { text-align: left; }
  .foundation-status > .btn { grid-column: auto; }
  .foundation-lesson { padding: 21px; }
  .foundation-lesson-head { grid-template-columns: 1fr; }
  .foundation-day-score { justify-self: start; min-width: 96px; }
  .foundation-teacher { grid-template-columns: 1fr; }
  .foundation-sound-grid { grid-template-columns: repeat(3, 1fr); }
  .foundation-sound-grid.words { grid-template-columns: repeat(2, 1fr); }
  .foundation-sound b { font-size: 21px; }
  .foundation-quiz-start, .foundation-quiz-result { grid-template-columns: 1fr; padding: 21px; }
  .foundation-quiz-start > .btn { justify-self: start; }
  .foundation-options { grid-template-columns: 1fr 1fr; }
  .foundation-answer-note { align-items: flex-start; flex-direction: column; }
  .foundation-result-score { width: 82px; height: 82px; padding-top: 22px; }
  .tips-hero { padding: 22px; }
  .tips-actions .btn { width: 100%; }
  .learning-progress-grid, .learning-tip-grid, .method-strip { grid-template-columns: 1fr; }
  .tip-group-heading { grid-template-columns: 44px minmax(0,1fr) auto; }
  .tip-group-mark { width: 44px; height: 44px; }
  .my-intro { align-items: flex-start; flex-direction: column; }
  .intro-meaning { grid-template-columns: 1fr; }
  .intro-meaning span { text-align: left; }
  .phrase { grid-template-columns: 40px minmax(0,1fr); }
  .phrase-cn { grid-column: 2; text-align: left; max-width: none; }
  .bubble { max-width: 84%; }
  .lesson-section, .lesson-banner { padding: 21px; }
  .lesson-banner h1 { font-size: 27px; }
  .kana-table { grid-template-columns: repeat(5, 1fr); gap: 6px; }
  .kana-card { min-height: 70px; border-radius: 12px; }
  .kana-char { font-size: 24px; }
  .review-wrap { display: block; }
  .review-wrap > aside { margin-top: 15px; }
  .rating.four { grid-template-columns: 1fr 1fr; }
  .sound-labs { grid-template-columns: 1fr; }
  .sound-lab > p { min-height: 0; }
  .mobile-nav {
    position: fixed; display: grid; grid-template-columns: repeat(5, 1fr);
    inset: auto 0 0; height: 68px; background: rgba(250,249,246,.94);
    border-top: 1px solid var(--line); backdrop-filter: blur(16px); z-index: 50;
    padding-bottom: env(safe-area-inset-bottom);
  }
  .mobile-nav button { border: 0; background: transparent; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; color: var(--muted); font-size: 9px; }
  .mobile-nav button span:first-child { font-size: 17px; }
  .mobile-nav button.active { color: var(--accent); }
}

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