:root{--blue:#2457c7;--pale:#edf3ff;--ink:#192945;--sub:#536783;--line:#dce4f0;--bg:#f3f6fb}
body{background:radial-gradient(ellipse at 18% 0,#e8efff 0,transparent 50%),var(--bg);min-height:100vh}
.wrap{max-width:1040px}.top{position:relative;height:78px;border-bottom:1px solid #d8e1f1;margin-bottom:32px;z-index:4}
.brand{letter-spacing:-.055em;font-size:21px}.mark{background:#173b84;border-radius:11px}
#account{margin-left:auto;position:relative}summary{cursor:pointer}#account summary{list-style:none;background:#fff;border:1px solid #bdcbe0;padding:10px 18px;border-radius:24px;font-weight:750;font-size:14px}#account summary::-webkit-details-marker{display:none}
.account-panel{position:absolute;top:calc(100% + 8px);right:0;width:min(300px,85vw);padding:20px;background:white;border:1px solid var(--line);box-shadow:0 14px 40px #152f5a22;border-radius:18px;font-size:14px}.account-panel input{width:100%;border:1px solid #aebdd4;padding:12px;margin:8px 0;border-radius:10px;font:inherit}.account-panel output{display:block;margin-top:6px}.account-panel [hidden]{display:none}
.workspace{display:grid;grid-template-columns:minmax(0,2.4fr) minmax(218px,1fr);gap:24px;align-items:start}.card{margin:0;border-radius:22px}#lesson{padding:24px;box-shadow:0 14px 40px #213c6c0c}
#lesson>p:first-child{margin:0 0 12px}.study-hero{position:relative;overflow:hidden;isolation:isolate;background:linear-gradient(120deg,#132b55,#244d89);color:white;border-radius:16px;padding:26px 30px}.stage{font-size:12px;color:#bed9ff;font-weight:750}.study-hero h1{font-size:clamp(36px,6vw,52px);letter-spacing:-.06em;margin:10px 0 6px}.reading{font-size:19px}.reading span{font-size:15px;color:#c8dcff;margin-left:6px}.ghost-char{position:absolute;z-index:-1;right:-.03em;bottom:-.18em;font:180px/1 serif;color:#ffffff13;transform:rotate(-8deg)}
.part-title,.library h2{font-size:16px;margin:20px 0 12px}.library h2{margin-top:4px}.part-grid{display:flex;gap:8px}.part-grid .tile{flex:1;min-width:0;background:#f7f9fe;display:grid;gap:2px;padding:13px}.part-grid b{font-size:28px}.part-grid span,.part-grid small{font-size:13px}.part-grid small{color:var(--blue);margin:0}.study-actions{display:flex;gap:10px;margin-top:20px}.study-actions #start{flex:1}
.library details{padding:14px;margin-bottom:10px}.library summary{font-size:14px;font-weight:750}.library summary b{float:right;color:var(--blue)}#pieces{display:block;line-height:2}.note{max-width:640px}
#lesson:has(#after:not(.hidden)) .choices,#lesson:has(#after:not(.hidden)) #skipBtn,#lesson:has(#after:not(.hidden)) .feedback+.row{display:none}
@media(max-width:700px){.top{height:58px;margin-bottom:14px}.workspace{display:block}#lesson{padding:15px}.study-hero{padding:20px}.library{margin:18px 0}.library h2{font-size:14px}.wordline{margin:10px 0;gap:6px}.wordline .kanjibox{padding:6px}.ask{margin:9px 0}.feedback:empty{display:none}.result{padding:9px}.study-actions{margin-top:14px}}
/* Rounded ink outlines and pressed controls carry through lessons and review. */
:root{--ink:#262944;--sub:#63677e;--blue:#464d88;--pale:#f0eff9;--line:#dcd9e3}
body{background:#faf7f4}
.top{border-color:#ddd9df}.brand{color:#333655}.mark{background:#ffd1bb;color:#392e48;box-shadow:0 3px #d99a85}
#lesson,.library .card,.account-panel,dialog{border:2px solid var(--line);box-shadow:0 4px #e4dfe5}
.study-hero{background:#303654;color:#fff9f3;border:2px solid #393f64;padding-right:105px}.stage,.reading span{color:#f5d3c7}.ghost-char{display:none}
.lesson-mascot{position:absolute;right:24px;top:50%;width:66px;height:60px;transform: rotate(7deg);background:#ffbc9d;border:3px solid #42314a;border-radius:18px 18px 22px 22px;box-shadow:4px 5px #5d6081}
.lesson-mascot i{position:absolute;top:22px;left:15px;width:6px;height:9px;background:#42314a;border-radius:50%}.lesson-mascot i+i{left:39px}.lesson-mascot em{position:absolute;left:25px;top:33px;width:11px;height:7px;border:2px solid #42314a;border-top:0;border-radius:0 0 8px 8px}
.btn,.choice,.part-grid .tile,#account summary{border:2px solid #dad7e2;border-radius:15px;box-shadow:0 4px #c8c3d1;transition:transform .1s,box-shadow .1s}
.btn:not(.white):not(.light){background:#a74434;color:white;border-color:#a74434;box-shadow:0 4px #763428}
.btn:active,.choice:active,.part-grid .tile:active,#account summary:active{transform:translateY(3px);box-shadow:0 1px #9d91a3}
.part-grid .tile{background:white}.part-grid .tile:hover,.choice:hover{background:#fff1ea;border-color:#d49786}
.progress{height:13px;background:#eee8eb}.progress i{background:linear-gradient(#ffc2a8 0 35%,#da826a 35%);transition:width .28s ease}
.word .active-syllable{border-color:#ad5142;color:#783a33;background:#ffe6d8}
.feedback.good,.feedback.bad{border-radius:13px;padding:10px}.feedback.good{background:#eeeafa;color:#4e477b}.feedback.bad{background:#ffebe2;color:#913c20}
.merge span{display:inline-block}dialog[open] .merge span{animation:join-kanji .55s cubic-bezier(.2,.75,.3,1) both}
@keyframes join-kanji{from{opacity:0;transform:translateX(var(--travel)) scale(.8)}to{opacity:1;transform:none}}
@media(prefers-reduced-motion:reduce){dialog[open] .merge span{animation:none}.btn,.choice,.progress i{transition:none}}
@media(max-width:400px){.lesson-mascot{right:14px;scale:.85}.study-hero{padding-right:86px}}
 .choice.good,.choice.good:disabled{border-color:#8b81ae;background:#eeeafa;color:#403968}.feedback.bad{background:#fff1e9;color:#863622}
.header-settings { display: flex; align-items: center; gap: .5rem }
#language{display:inline-flex;padding:3px;gap:2px;border:1px solid #e3d9cb;border-radius:12px;background:#f3eee6}
#language label{position:relative;cursor:pointer;font-size:.875rem}
#language input{position:absolute;inset:0;opacity:0;cursor:pointer;width:100%;height:100%;margin:0}
#language span{display:grid;place-items:center;min-height:36px;padding:0 .65rem;border-radius:9px;color:#574b41}
#language input:checked+span{background:#943627;color:white;font-weight:700}
#language input:focus-visible+span{outline:2px solid #392e28;outline-offset:1px}
.feedback:has(.answer-mark) { display: flex; align-items: center; justify-content: center; gap: .55rem }
.choice.bad:disabled { background: #fff0eb; border-color: #b65039; color: #853923 }
.answer-mark {
  flex: none;
  display: grid;
  place-items: center;
  width: 1.55rem;
  height: 1.55rem;
  border-radius: 50%;
  background: #504773;
  color: white;
  font: bold 1.4rem/1 system-ui, sans-serif;

  animation: answer-pop .33s ease-out both;
}
.feedback.bad .answer-mark { background: #9b402d }
@keyframes answer-pop {
  from { opacity: 0; transform:  scale(.5) }
  65% { opacity: 1; transform:  scale(1.16) }
  to { transform: scale(1) }
}
@media (prefers-reduced-motion: reduce) { .answer-mark { animation: none } }
.daily-learners{margin:0 .35rem 0 0;font-size:.85rem;font-weight:650;color:#705e52;text-wrap:balance}
@media(max-width:560px){
  .header-settings{min-width:0;gap:.3rem}
  .header-settings{margin-left:auto}
}
.mastery-link { display:inline-block; margin:0 0 14px; color:#794032; font-size:.95rem; font-weight:750; text-underline-offset:4px }
.mastery-card { max-width:720px; margin-inline:auto }
.mastery-card h1 { font-size:clamp(1.45rem,4vw,2rem); margin:0 }
#masterySummary { color:var(--sub); line-height:1.6 }
#masteryTable { width:100%; border-collapse:collapse; text-align:left }
#masteryTable th,#masteryTable td { padding:.75rem .4rem; border-bottom:1px solid var(--line) }
#masteryTable th { font-size:.85rem; color:var(--sub) }
#masteryTable td:first-child { font-weight:800; font-size:1.4rem }
.review-entry { margin:0 0 12px 14px; border-radius:10px; border:1px solid #d9cacf; padding:6px 12px; background:white; color:#673d3c; font-weight:700 }
.review-entry:disabled { opacity:.65 }

.weakness-dialog { width:min(420px,88vw); max-height:85vh; overflow:auto }
.weakness-dialog h2 { margin-top:0 }
.weakness-dialog .btn { margin:4px; }
.weakness-choices { display:grid; grid-template-columns:1fr 1fr }
.review-card {margin-bottom:14px;padding:18px;background:#fffaf6}
.review-card[hidden] {display:none}
.review-card h3 {font-size:1.08rem;margin:0}
.review-card p {font-size:.88rem;line-height:1.55;color:var(--sub);margin:.65rem 0}
.review-card #reviewCounts {font-weight:750;color:var(--ink)}
.review-card .btn {margin-top:6px;width:100%}
dialog.review-session {inset:0;margin:0;width:100%;height:100%;max-width:none;max-height:none;border:0;border-radius:0;background:#faf7f4;color:var(--ink);box-shadow:none;padding:clamp(16px,5vw,48px);text-align:center}
.review-session[open] {display:flex;flex-direction:column;align-items:center;overflow:auto}
.review-session h2 {font-size:1rem;color:var(--sub);margin:0 0 20px}
.session-bar {order:-1;width:min(100%,580px);margin:0 auto clamp(24px,8vh,84px);display:flex;align-items:center;justify-content:space-between;font-weight:750}
.session-exit {color:var(--ink);background:white;border:1px solid var(--line);border-radius:12px;padding:10px 16px}
.review-session h3 {font-size:clamp(2rem,6vw,4rem);line-height:1.25;margin:1rem 0;letter-spacing:-.04em}
.review-session p {line-height:1.6;margin:.65rem 0}
.review-session .weakness-choices {width:min(100%,420px);gap:10px;margin:1rem auto}
.review-session .btn {margin:2px;min-height:46px}
.review-session .word-recall {grid-template-columns:1fr}
.solution {padding:20px;border:2px solid var(--line);border-radius:16px;background:white}
.solution small,.solution strong {display:block}
.solution small {font-size:1.25rem;color:var(--sub)}
.solution strong {font-size:2.5rem}
.review-session :focus-visible {outline:3px solid var(--blue);outline-offset:3px}
@media(max-width:600px){.review-session .weakness-choices {grid-template-columns:1fr}.review-session .session-bar {margin-bottom:24px}}

#discovery #instantReview[hidden]{display:none}

.reading-intro { margin-bottom:16px }
.reading-intro h2 { margin:0; font-size:1.2rem }
.intro-words { display:flex; gap:12px; flex-wrap:wrap }
.intro-words>div { border-radius:12px; background:#f6f1ed; padding:10px 16px }
.intro-words small { display:block; margin-top:4px }
.intro-words b { color:#943c2e }

.reading-intro[hidden]{display:none}
.intro-dismiss,.intro-reopen{border:0;background:transparent;color:var(--sub);font:inherit;text-decoration:underline;text-underline-offset:.2em;padding:12px}
.intro-reopen{display:block;margin:12px auto}

.ko-kana{display:none}
.show-ko-kana .ko-kana{display:block;font-family:inherit;font-size:.9rem;font-weight:500;line-height:1.5;letter-spacing:.02em}
.study-hero .ko-kana{color:#f5d3c7}
.kana-setting{display:flex;align-items:center;gap:.5rem;width:fit-content;padding:.6rem 0;font-size:.9rem;color:var(--ink);cursor:pointer}
.kana-setting input{width:1.1rem;height:1.1rem;accent-color:var(--blue)}
.solution small.ko-kana{display:none}
.show-ko-kana .solution small.ko-kana{display:block}

#wordLesson[hidden],#lesson[hidden]{display:none}
#wordLesson{padding:clamp(18px,4vw,32px);border:2px solid var(--line);box-shadow:0 4px #e4dfe5}
#wordLesson h2{font-size:clamp(2rem,6vw,3.5rem);margin:12px 0 2px;line-height:1.2}
.round-progress{margin:0;font-size:.9rem;font-weight:700;color:var(--sub)}
.round-reading{margin:0 0 20px;color:var(--sub);font-size:1.2rem}
.round-korean{display:block;font-size:1.8rem}
#wordLesson>.btn{margin:12px 6px 0 0}
.round-choices{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.round-choices .btn{font-size:1.2rem}.round-feedback{font-weight:750}
.round-parts{padding:0;list-style:none;display:flex;flex-wrap:wrap;gap:8px}
.round-parts li{background:var(--pale);padding:6px 10px;border-radius:8px}

.char-listening{margin:12px 0}.char-listening p{font-size:.9rem;font-weight:700;margin:4px 0}
.char-listening button{margin:4px 6px 4px 0}.char-listening small,.round-choices .ja-hint{display:block;font-size:.85rem}
html[lang=ko].hide-hiragana .ja-hint,html[lang=ko].hide-hiragana .study-hero .reading span,html[lang=ko].hide-hiragana [data-piece] small,html[lang=ko].hide-hiragana #composeChoices .kana,html[lang=ko].hide-hiragana #discoverCards .kana{display:none}

#wordLesson h2 mark{background:#ffe2d1;color:#793824;border-bottom:3px solid #a74434;border-radius:.18em;padding:0 .04em}

#wordLesson .wordline h2{margin:0;font-size:clamp(1.55rem,5vw,2.25rem)}
#wordLesson .word .active-syllable{background:#ffe6d8;color:#783a33;border:2px solid #ad5142;border-radius:.3em;padding:0 .05em}
.character-footer{display:flex;justify-content:flex-end;margin-top:clamp(20px,5vh,48px)}
#wordLesson .part-label{display:block}

#wordLesson:has(.study-hero){padding:24px}#wordLesson .round-study-progress{margin:0 0 12px}#wordLesson .part-title{font-size:16px;margin:20px 0 12px}#wordLesson h2.h2{font-size:18px;margin:5px 0 0}@media(max-width:700px){#wordLesson:has(.study-hero){padding:15px}}

a.brand{text-decoration:none}.brand:focus-visible{outline:3px solid var(--blue);outline-offset:3px;border-radius:8px}.review-session>.brand{align-self:flex-start;order:-2;margin-bottom:12px}

.joined-study h1{display:flex;gap:4px;flex-wrap:wrap;align-items:stretch}
.joined-study [data-piece]{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;min-width:46px;min-height:52px;padding:5px 10px;border:1px solid #8388a2;border-radius:12px;background:#ffffff08;color:inherit;font:inherit;line-height:1.15;letter-spacing:normal}
.joined-study [data-piece]:hover,.joined-study [data-piece]:focus-visible{background:#ffffff18;border-color:#ffceb9}
.joined-study [data-piece]:active{background:#ffffff30}
.joined-study [data-piece] small{font-size:.85rem;font-weight:600;line-height:1.25;color:#f5d3c7}
@media(max-width:600px){.joined-study{padding-right:18px}.joined-study .lesson-mascot{display:none}.joined-study [data-piece]{padding:5px 7px}}
.joined-study h1{gap:6px;margin-block:16px 10px;max-width:100%}
.joined-study [data-piece]{flex:1 1 0;min-width:0;max-width:2.85em;min-height:1.95em;padding:6px 2px;font-size:clamp(34px,5vw,62px)}
.joined-study [data-piece] small{font-size:clamp(.9rem,1.8vw,1.15rem)}
.gloss-piece{position:relative}
.gloss-trigger{font:inherit;color:inherit;letter-spacing:inherit;border:0;border-radius:.2em;background:none;padding:.08em;cursor:help}
.gloss-trigger:hover,.gloss-trigger:focus-visible{background:var(--pale)}
.gloss-tip{position:absolute;z-index:2;bottom:100%;left:50%;transform:translateX(-50%);white-space:nowrap;border-radius:.55rem;background:#303654;color:white;padding:.35rem .65rem;font:600 .9rem/1.4 sans-serif;letter-spacing:normal}
.gloss-piece:has(.gloss-tip:not([hidden])){z-index:2}

#introAnswers{display:flex;flex-wrap:wrap;gap:8px} #introAnswers button{background:#fff;color:var(--ink);border:1px solid #d8d4df;min-height:44px} #introFeedback:empty{display:none} #introAnswers:not(:empty){margin-bottom:16px}

.gloss-trigger{touch-action:manipulation}

.study-slide{cursor:pointer;touch-action:pan-y pinch-zoom;animation:slide-word-in .18s ease-out}
@keyframes slide-word-in{from{opacity:.6;transform:translateX(.45rem)}to{opacity:1;transform:none}}
@media(prefers-reduced-motion:reduce){.study-slide{animation:none}}
.study-actions.slide-controls{display:flex;align-items:center;justify-content:space-between;gap:.4rem}
.slide-controls>*{flex:0 1 auto}
.slide-link{border:0;background:none;color:var(--ink);font:inherit;cursor:pointer;min-height:44px;padding:.4rem}
.slide-link:disabled{opacity:.4;cursor:default}
/* First-visit explanation */
body:has(#readingIntro:not([hidden])){background:#fcf8f0}
#app:has(>#readingIntro:not([hidden]))>:not(#readingIntro):not(dialog){display:none!important}
#readingIntro{text-align:center;max-width:760px;margin:clamp(24px,5vw,68px) auto 48px;color:#29241e}
#introTitle{font-size:clamp(1.8rem,4.1vw,3.5rem);letter-spacing:-.055em;line-height:1.16;text-wrap:balance}
#introTitle em,.intro-words b{color:#a63828;font-style:normal}
#introLead{color:#675d54;margin:12px auto 25px;text-wrap:balance}
.intro-board{background:#fff;border:1px solid #eee6da;border-radius:18px;padding:clamp(16px,3vw,36px);box-shadow:0 10px 32px #6243170b}
#readingIntro .intro-words{justify-content:center;align-items:center;flex-wrap:nowrap;gap:clamp(6px,2vw,24px)}
#readingIntro .intro-words>div{flex:0 1 170px;background:#f7f2e9;padding:14px 6px}
.intro-words strong,.intro-result>strong{display:block;font-size:clamp(2rem,5vw,3.25rem);line-height:1.4}
.intro-words>span{border-radius:50%;padding:.25rem .6rem;background:#f5efe7;color:#a63828}
.intro-arrow{display:block;margin:8px;color:#ad7967}
.intro-result{max-width:420px;margin:auto;border-radius:14px;border:1px solid #eadbd1;padding:18px 10px;background:linear-gradient(#faf2ec,#fff)}
.intro-result>strong{color:#943627}.intro-result>span,.intro-result>button{display:block;margin:auto}
#introPrompt{font-size:.9rem;margin:10px 0}#introAnswers{justify-content:center}
#introDone{display:block;width:min(100%,420px);margin:18px auto 0;background:#ad402f;color:white}
#introSkip{display:block;margin:auto}
body:has(#wordLesson :is(.study-slide,.wordline)){background:#fcf8f0}
#wordLesson:has(:is(.study-slide,.wordline)),.workspace:has(#wordLesson :is(.study-slide,.wordline)) .library .card{
  border:1px solid #e8dfd2;border-radius:18px;box-shadow:0 8px 26px #6243170b
}
#wordLesson .study-slide{background:#f7f2e9;border:1px solid #eadfd1;color:#392e28}
#wordLesson .study-slide .stage,#wordLesson .study-slide .reading span,
#wordLesson .study-slide .ko-kana,#wordLesson .study-slide [data-piece] small{color:#754d40}
#wordLesson .study-slide [data-piece]{background:#fffaf5;color:#913727;border-color:#dfc8b9}
#wordLesson .study-slide [data-piece]:is(:hover,:focus-visible){background:#f9e5d9;border-color:#9a4536}
#wordLesson .study-slide .lesson-mascot{box-shadow:3px 4px #dec2ad;border-color:#7b5144}
#wordLesson .slide-controls #hear{background:#f7f2e9;color:#573d33;border:1px solid #ddcdbf;box-shadow:none}
#wordLesson .slide-controls #start{flex:0 1 auto;font-weight:700;color:#943627}
#wordLesson .round-study-progress{color:#705e52}
/* Character practice follows the palette and surfaces of the study cards. */
#wordLesson:has(.wordline){
  --ink:#392e28;--sub:#705e52;--blue:#913727;--pale:#f7f2e9;color:var(--ink)
}
#wordLesson .progress{height:8px;background:#f1e8dd}
#wordLesson .progress i{background:#a54030}
#wordLesson .pill{background:#f7f2e9;color:#754d40}
#wordLesson .wordline{background:#f7f2e9;border:1px solid #eadfd1;border-radius:16px;padding:clamp(8px,2vw,20px);flex-wrap:wrap}
#wordLesson .kanjibox{background:#fffaf5;border:1px solid #dfc8b9;color:#913727}
#wordLesson .part-label,#wordLesson .arrow{color:#75594b}
#wordLesson .word .active-syllable{background:#943627;border-color:#943627;color:#fff}
#wordLesson .character-choices .choice{border:1px solid #dfcdbd;background:#fffaf5;color:#392e28;border-radius:12px;box-shadow:0 2px #e7dbce}
#wordLesson .character-choices .choice:is(:hover,:focus-visible){background:#f9e5d9;border-color:#9a4536}
#wordLesson:has(.wordline) :is(.btn.white,.btn.light){background:#f7f2e9;color:#573d33;border:1px solid #ddcdbf;box-shadow:none}
#wordLesson .round-feedback{padding:12px 16px;border-radius:12px}
#wordLesson .round-feedback.correct{color:#365536;background:#edf3e8}
#wordLesson .round-feedback.incorrect{color:#842e22;background:#fbece4}
.site-menu{display:flex;gap:clamp(4px,1vw,16px)}
.site-menu :is(button,a){font:inherit;font-size:.86rem;font-weight:650;color:#59473d;background:none;border:0;min-height:40px;cursor:pointer}
.site-menu :is(button,a):is(:hover,:focus-visible){color:#943627;text-decoration:underline}
#siteInfo p{line-height:1.7}
@media(max-width:900px){.top{height:auto;min-height:58px;flex-wrap:wrap;padding-block:6px}.top .site-menu{order:3;width:100%;justify-content:center;border-top:1px solid #eadfd1}}
#wordLesson:has(.recall-box){padding:clamp(14px,2vw,24px)}
.recall-box{max-width:480px;margin:auto;text-align:center}
.quiz-meta,.quiz-actions{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap}
.quiz-meta{font-size:.83rem;color:#705e52;padding-bottom:8px;border-bottom:1px solid #eee4d8}
#wordLesson .recall-box .wordline{display:flex;align-items:center;justify-content:center;gap:.3em;background:transparent;border:0;padding:0;margin:18px 0 8px;font-size:clamp(2rem,6vw,3rem);line-height:1.4}
.quiz-prompt{margin:0 0 12px;color:#594337}
.recall-box .choices{margin:0 auto;gap:8px}
.recall-box .choice{min-height:56px;padding:8px;touch-action:manipulation}
.recall-box .slide-link{font-size:.84rem;min-height:44px;margin:8px 4px 0;padding-inline:12px}
.recall-box .round-feedback{margin:12px 0}
.quiz-actions{margin-top:10px}
.quiz-actions .btn{width:100%;min-height:52px;touch-action:manipulation}
.quiz-audio{display:flex;justify-content:center;flex-wrap:wrap;gap:8px;margin-top:10px}
.quiz-audio .btn{min-height:44px}
#wordLesson .character-choices .choice:disabled{opacity:.75;background:#faf8f4;color:#574d41;box-shadow:none}
#wordLesson .character-choices .choice.answer-key{opacity:1;border-color:#527152;background:#edf3e8;color:#365536}
.recall-box .quiz-prompt,#wordLesson .recall-box .round-feedback{display:grid;align-items:center;min-height:36px;padding:2px 8px;margin:0 0 8px}
.quiz-kanji{display:inline-block;font-size:.66em;font-weight:650;line-height:1.25;padding:.12em .35em;border-radius:.3em;background:#f7f2e9;color:#754d40}

.site-menu a{display:inline-flex;align-items:center;text-decoration:none;padding:0 6px}
.site-foot .daily-learners{text-align:center;font-size:.75rem;color:#75695e;font-weight:400;margin:22px auto}
body:has(#about:not([hidden])){background:#fcf8f0}
#about{color:#322b24;padding:0 0 20px}
#about p{color:#685d51;line-height:1.65;text-wrap:pretty}
#about h1,#about h2,#about h3{line-height:1.25;text-wrap:balance;letter-spacing:-.035em}
#about em{font-style:normal;color:#9b382c}
#about .btn{display:inline-flex;align-items:center;text-decoration:none;background:#a83c2c;color:white;padding:12px 22px}
.about-lead,.about-method>h2{text-align:center}
.about-lead{padding:clamp(20px,5vw,64px) 8px 34px}
.about-lead h1{font-size:clamp(2rem,5vw,3.7rem);margin:0}
.about-demo{max-width:660px;margin:auto;background:white;border:1px solid #e8ded1;border-radius:18px;padding:clamp(16px,3vw,32px);box-shadow:0 10px 32px #6243170b}
.about-demo h2{margin:0 0 16px;font-size:1.1rem}
.about-equation{display:flex;gap:10px;align-items:center;text-align:center}
.about-equation>div,.about-result{background:#f7f2e9;border-radius:12px;padding:12px;flex:1}
.about-demo strong{display:block;font-size:2rem}
.about-result{margin-top:12px;text-align:center}.about-result strong{color:#983a2b}
#aboutHear{display:block;margin:8px auto 0;border:1px solid #d8caba;border-radius:10px;background:white;font:inherit;padding:8px 15px;cursor:pointer}
.about-method{margin:48px auto}.about-method ol{display:grid;grid-template-columns:repeat(3,1fr);gap:12px;padding:0;list-style:none;counter-reset:step}
.about-method li{background:white;border:1px solid #e8ded1;border-radius:14px;padding:20px;counter-increment:step}
.about-method li::before{content:counter(step,decimal-leading-zero);color:#983a2b;font-weight:700}
.about-method li p{margin:0}
@media(max-width:650px){.about-method ol{grid-template-columns:1fr}}
.quiz-spelling{font-size:.85em;color:#614f44}.wordline:has(.quiz-spelling)>span{white-space:nowrap}

.stage-picker{display:flex;align-items:center;gap:8px;margin:0 0 10px;width:fit-content;font-size:.88rem;color:#594b40}
.stage-picker select{min-height:38px;border:1px solid #dfd2c3;border-radius:9px;background:white;color:#57382a;font:inherit;padding:4px 8px}
#app:has(#wordLesson[hidden]) .stage-picker{display:none}
.about-stages dl{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:10px}
.about-stages dl div{border-radius:12px;background:white;border:1px solid #e8ded1;padding:16px}
.about-stages dt{color:#983a2b;font-weight:700}.about-stages dd{margin:6px 0 0}
.review-session:has(.word-recall){background:#fcf8f0}
.review-session:has(.word-recall) .session-bar{width:min(100%,680px);margin-bottom:10px}
.review-session .word-recall{width:min(100%,680px);background:white;border:1px solid #e8ded1;border-radius:18px;padding:clamp(12px,3vw,24px);box-shadow:0 8px 26px #6243170b}
.recall-surface{background:linear-gradient(125deg,#202938,#30313d);color:#fff9ee;border-radius:14px;padding:clamp(16px,3vw,32px)}
.review-parts,.review-listen{display:flex;align-items:center;justify-content:center;gap:8px;flex-wrap:wrap}
.review-piece{position:relative;padding:10px;min-width:60px;background:#ffffff12;color:white;border:1px solid #ffffff30;border-radius:10px;cursor:pointer}
.review-piece>*{display:block}.review-piece b{font-size:2rem}.review-piece small,.review-solution>.ja-hint{color:#ffe3a3}
.review-piece span{font-size:.8rem}.review-origin{border-radius:10px;background:#f7f2e9;padding:10px}.review-origin p{margin:3px}
body:has(#curriculum:not([hidden])){background:#fcf8f0}
.site-menu [aria-current=page]{background:#983a2b;color:#fff;border-radius:8px}
#curriculum{max-width:900px;margin:auto;color:#322b24}
#curriculum h1,#curriculum h2,#curriculum h3{line-height:1.24;letter-spacing:-.035em;text-wrap:balance}
.course-hero{text-align:center;padding:clamp(16px,5vw,56px) 0 24px}
.course-hero h1{font-size:clamp(2rem,5vw,3.5rem);margin:0}
.course-hero em,.course-step{font-style:normal;color:#983a2b}
.course-hero p,.course-road li p{color:#685d51;line-height:1.6}
.course-stats{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin:24px 0 0}
.course-stats div,.course-network,.course-road li{background:white;border:1px solid #e8ded1;border-radius:16px;padding:clamp(14px,2.5vw,26px)}
.course-stats dt,.course-start small{font-size:.83rem;color:#705e52}.course-stats dd{margin:6px 0 0;font-size:1.6rem;font-weight:750}
.course-network h2{text-align:center}.course-map{display:flex;align-items:center;justify-content:center;gap:clamp(12px,4vw,42px);background:#f7f2e9;border-radius:12px;padding:16px}
.course-root{background:#983a2b;color:white;padding:14px;border-radius:10px;text-align:center}.course-root b{display:block;font-size:2.6rem}
.course-map ul,.course-road ol{list-style:none;padding:0;margin:0;display:grid;gap:10px}
.course-map ul{grid-template-columns:repeat(2,1fr)}.course-map li{background:white;padding:10px 16px;border-radius:8px}.course-map li span{display:block;color:#705e52;font-size:.88rem}
.course-road{margin:32px 0}.course-road li{display:flex;align-items:center;justify-content:space-between;gap:12px}
.course-road li h3,.course-road li p{margin:.25em 0}.course-road li .course-step{color:#983a2b;font-weight:700;font-size:.85rem}
.course-start{display:grid;gap:5px;text-align:center}.course-start button{min-height:44px}
@media(max-width:600px){.course-stats{grid-template-columns:repeat(2,1fr)}.course-map{flex-direction:column}.course-road li{align-items:stretch;flex-direction:column}.course-start small{text-align:left}}
#about ruby{ruby-align:center}#about rt{font-size:.65em;color:#754d40;font-weight:500}#about .about-stages dd>div{line-height:2.15}

.social-logins{display:grid;gap:6px;border:0;margin:0 0 14px;padding:0}
.social-logins legend{font-weight:700;padding:0 0 8px}
.social-logins button{min-height:44px;border-radius:10px;border:1px solid #dfd2c3;background:white;color:#392e28;font:inherit;cursor:pointer}
.social-logins button:disabled{color:#786f65;background:#f7f3ed;cursor:default}
.social-logins button:focus-visible{outline:2px solid #943627;outline-offset:2px}

.policy-links{text-align:center;font-size:.8rem}
.policy-links a{color:inherit;display:inline-block;padding:.5rem}
