:root{font-family:system-ui,-apple-system,'PingFang SC','Microsoft YaHei',sans-serif;color:#3c5147;background:#e4e9e3}*{box-sizing:border-box}body{margin:0;min-height:100vh;display:grid;place-items:center}button{font:inherit;cursor:pointer}button:focus-visible{outline:3px solid #eca862;outline-offset:2px}.app{width:min(402px,100vw);height:min(874px,100dvh);min-height:620px;background:#fbf8f3;position:relative;overflow:hidden;border:6px solid #394c46;border-radius:38px;box-shadow:0 24px 75px #28463b3b}.header{height:67px;display:flex;align-items:center;justify-content:space-between;padding:0 22px;background:#fffefa}.brand{display:flex;gap:8px;align-items:center;font-weight:800;color:#bc7057;font-size:18px;letter-spacing:-.02em}.brand small{font-size:12px;font-weight:600;color:#6c846a;margin-left:4px}.paw{font-size:25px;color:#ee9d9b}.day{font-size:12px;color:#758b7c;background:#f0f5ed;border-radius:20px;padding:7px 11px}.view{height:calc(100% - 143px);overflow:auto;display:none}.view.active{display:block}.hero{height:46%;min-height:260px;max-height:345px;position:relative;background-color:#cde7c7;background-position:30% center;background-size:cover}.hero:after{content:'';position:absolute;bottom:0;left:0;right:0;height:42px;background:linear-gradient(transparent,#fbf8f3)}.hero-copy{position:absolute;top:22px;left:22px;z-index:1}.tag{font-size:12px;font-weight:700;color:#668771;background:#fffef6c9;border-radius:18px;padding:6px 10px}.hero h1{font-size:23px;line-height:1.45;color:#366c5b;margin:16px 0 0;text-shadow:0 1px 0 #fff}.characters{position:absolute;left:0;right:0;bottom:1px;height:155px;display:flex;justify-content:center;align-items:end;z-index:1}.char{display:block;background-image:url('./assets/pets.png');background-repeat:no-repeat;background-size:300px auto;width:150px;height:153px;filter:drop-shadow(0 6px 4px #46614a3a)}.fox{background-position:0 0;transform:translate(20px,5px)}.baize{background-position:-150px 0;transform:translate(-9px,6px)}.home-content{padding:5px 19px 22px}.today{background:#fffefa;border:1px solid #efebe2;border-radius:21px;padding:18px 19px;box-shadow:0 7px 19px #79866c11}.eyebrow{font-size:12px;font-weight:700;color:#b57558;letter-spacing:.07em}.today h2{font-size:23px;margin:8px 0 4px;color:#385948}.today p{font-size:13px;color:#829088;margin:0 0 15px;line-height:1.5}.primary{background:#e78a67;border:0;color:#fff;border-radius:14px;padding:13px 18px;min-height:46px;font-size:15px;font-weight:700;box-shadow:0 4px 0 #c36c50}.primary span{margin-left:12px}.primary:active{transform:translateY(3px);box-shadow:0 1px 0 #c36c50}.journey{padding:20px 6px 4px}.journey-head{display:flex;justify-content:space-between;align-items:center;font-size:14px}.journey-head span{font-size:12px;color:#88958c}.dots{display:flex;align-items:center;gap:8px;padding-top:14px}.dots i{height:10px;flex:1;border-radius:10px;background:#e8e6da}.dots i.done{background:#e6a587}.dots i.current{background:#a2cbb6}.nav{height:76px;border-top:1px solid #edece3;display:flex;justify-content:space-around;align-items:center;background:#fffefa;padding-bottom:env(safe-area-inset-bottom)}.nav button{background:none;border:0;display:flex;align-items:center;flex-direction:column;gap:2px;width:85px;color:#91a197;font-size:12px}.nav button span{font-size:25px;line-height:25px}.nav button.selected{color:#d47f60;font-weight:700}.page-head{padding:37px 24px 15px}.page-head h2{font-size:23px;margin:8px 0;color:#3e624f}.page-head p{font-size:13px;color:#8a988e}.books{padding:0 18px}.book{width:100%;display:flex;align-items:center;gap:13px;text-align:left;margin:9px 0;padding:15px;background:#fffefa;border:1px solid #eeece2;border-radius:17px;color:#465c4c}.book .num{width:42px;height:42px;background:#fce9dc;color:#d58564;display:grid;place-items:center;border-radius:14px;font-weight:800}.book strong{font-size:16px;display:block}.book small{font-size:12px;color:#93a097;display:block;margin-top:4px}.book.locked{opacity:.5}.stats{display:flex;gap:12px;margin:4px 22px 18px}.stats div{flex:1;background:#eaf2e8;border-radius:18px;padding:22px}.stats strong{display:block;font-size:32px;color:#528068}.stats span{font-size:12px;color:#779082}.record{margin:0 22px;background:#fffefa;border:1px solid #eeece2;border-radius:18px;padding:19px}.record h3{font-size:16px;margin:0 0 9px}.record p{font-size:13px;line-height:1.7;color:#839388;margin:0}.reset{border:0;background:none;text-decoration:underline;color:#a88a7b;font-size:12px;margin:18px 22px}.overlay{position:absolute;inset:0;z-index:10;background:#fbf8f3;display:flex;flex-direction:column}.overlay[hidden]{display:none}.study-head{height:68px;display:flex;align-items:center;justify-content:space-between;padding:0 22px;border-bottom:1px solid #eeece2;color:#66816d;font-size:13px}.study-head button{border:0;background:none;color:#66816d;font-size:30px;width:32px}.study-body{flex:1;overflow:auto;padding:27px 25px}.study-foot{padding:15px 24px 24px;border-top:1px solid #eeece2}.study-foot .primary{width:100%}.study-foot .primary:disabled{opacity:.45;box-shadow:none;cursor:not-allowed}.study-title{font-size:26px;color:#466e58;margin:10px 0 13px}.study-hint{font-size:14px;color:#809286;line-height:1.7}.text-card{background:#fffefa;border:1px solid #ece9df;border-radius:22px;padding:24px;margin-top:20px}.text-card .original{font-size:19px;line-height:2.1;color:#3e5448;margin:0}.source{font-size:12px;color:#a1aaa1;margin:14px 0 0}.pet-tip{display:flex;gap:10px;align-items:center;background:#ecf4e9;border-radius:15px;padding:12px;margin-top:15px;font-size:13px;color:#61816c}.mini-pet{width:42px;height:43px;background:url('./assets/pets.png') no-repeat 0 0;background-size:90px auto;border-radius:50%;background-color:#fff}.tools{display:flex;gap:9px;margin-top:16px}.tools button{border:1px solid #b6d2bd;background:#f2f8ef;color:#567d63;border-radius:12px;padding:10px 12px;font-size:13px}.explain{margin-top:15px;background:#fff4e9;padding:15px;border-radius:14px;color:#786857;font-size:14px;line-height:1.75}.question{font-size:19px;line-height:1.6;font-weight:700;margin:22px 0}.option{width:100%;background:#fffefa;border:1px solid #e3e7dc;border-radius:14px;text-align:left;padding:16px;margin:7px 0;color:#476252;font-size:15px}.option.selected{background:#e4f2e5;border-color:#7bb791}.feedback{font-size:13px;color:#ae795e;line-height:1.6;min-height:38px}.success{text-align:center;padding-top:60px}.success .star{font-size:70px;color:#e9ae72}.success h2{font-size:27px;color:#4f7d65}.success p{font-size:15px;line-height:1.9;color:#779084}.toast{position:absolute;bottom:90px;left:50%;transform:translateX(-50%);background:#3b6852;color:white;border-radius:20px;padding:10px 14px;opacity:0;transition:opacity .2s;white-space:nowrap;z-index:20;font-size:13px;pointer-events:none}.toast.show{opacity:1}@media(max-width:600px){body{display:block;background:#fbf8f3}.app{width:100vw;height:100dvh;min-height:620px;border:0;border-radius:0;box-shadow:none}}@media(max-height:740px){.hero{min-height:220px;height:41%}.characters{height:125px}.char{background-size:250px auto;width:125px;height:128px}.baize{background-position:-125px 0}.today{padding:14px}.journey{padding-top:13px}}

.char{mix-blend-mode:multiply}

.story-scene{height:185px;border-radius:18px;background-size:cover;background-position:center;box-shadow:0 3px 12px #44694c18;margin-top:19px}.story-scene+.text-card{margin-top:14px}

.dots{gap:8px;overflow-x:auto;padding-bottom:7px;scrollbar-width:thin}.grade-chip{flex:none;width:77px;min-height:55px;padding:8px;background:#f0f0e9;border-radius:12px;color:#9ba79c;display:flex;flex-direction:column;gap:3px}.grade-chip strong{font-size:12px}.grade-chip small{font-size:11px}.grade-chip.done{background:#f9e6d9;color:#bf785e}.grade-chip.current{background:#e5f1e4;color:#55866a}.grade-heading{font-size:14px;color:#7c927d;margin:21px 5px 7px}.grade-heading:first-child{margin-top:3px}
/* Home: one lesson and one route preview */
.map-preview{width:100%;text-align:left;border:1px solid #e4e9da;background:#eef6eb;border-radius:18px;padding:14px 17px;margin-top:14px;color:#486b54;display:block}.map-preview-top{display:flex;align-items:center;justify-content:space-between;font-size:14px}.map-preview-top span{font-size:12px;color:#78947d}.map-preview small{display:block;font-size:12px;color:#829786;margin-top:6px}.map-mini-path{display:flex;gap:7px;margin-top:13px}.map-mini-path i{height:8px;flex:1;background:#d9e0d4;border-radius:8px}.map-mini-path i.done{background:#e3ab87}.map-mini-path i.current{background:#84bea1}
/* A short illustrated stop for each grade, following one vertical route */
.map-view{background:#fbf8f3}.map-route{position:relative;margin:4px 20px 35px;padding-left:41px}.map-route:before{content:'';position:absolute;left:15px;top:21px;bottom:24px;border-left:3px dotted #bcd1b7}.grade-stop{position:relative;margin:0 0 16px}.route-point{position:absolute;left:-42px;top:19px;width:33px;height:33px;border-radius:50%;display:grid;place-items:center;background:#eceee7;color:#91a398;font-weight:800;border:3px solid #fbf8f3;z-index:1;font-size:13px}.grade-stop.current .route-point{background:#e38e6b;color:#fff}.grade-stop.done .route-point{background:#86b99a;color:#fff}.stop-card{overflow:hidden;border:1px solid #e4e7dc;background:#fffefa;border-radius:17px;box-shadow:0 3px 13px #415b4510}.stop-heading{height:86px;background-image:linear-gradient(90deg,#fffef7d9,#fffef700),var(--scene);background-size:cover;background-position:30% 45%;padding:14px;display:flex;flex-direction:column;align-items:flex-start;justify-content:space-between;color:#405d49;text-shadow:0 1px 5px white}.stop-heading span{font-size:16px;font-weight:800;background:#fffcf0ca;border-radius:9px;padding:3px 8px}.stop-heading strong{font-size:11px;color:#a17256;background:#fff8ecdd;border-radius:10px;padding:4px 8px}.grade-stop.locked .stop-card{opacity:.65}.stop-lessons{padding:4px 12px}.stop-lesson{border:0;border-bottom:1px solid #eceee4;background:transparent;display:flex;align-items:center;text-align:left;gap:8px;width:100%;min-height:57px;color:#455d4c;padding:7px 2px}.stop-lesson:last-child{border-bottom:0}.stop-lesson span{font-size:14px;font-weight:700;flex:1}.stop-lesson small{font-size:11px;color:#8e9c90}.stop-lesson b{font-size:19px;color:#93b19b}.stop-lesson.locked{color:#9aa59a}
/* Earned stamps and grade badges */
.reward-section{margin:0 20px 14px;padding:17px;background:#fffefa;border:1px solid #ebe9df;border-radius:19px}.reward-head{display:flex;justify-content:space-between;align-items:center}.reward-head h3{font-size:16px;margin:0;color:#48644f}.reward-head span{font-size:12px;color:#9aab9e}.reward-section p{font-size:12px;color:#8b9b90;margin:5px 0 15px;line-height:1.5}.stamp-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:13px 7px}.stamp{min-width:0;text-align:center;opacity:.32;filter:grayscale(1)}.stamp.earned{opacity:1;filter:none}.stamp-picture{width:54px;height:54px;margin:0 auto 5px;border-radius:50%;background-size:cover;background-position:center;border:3px solid #d88f70;box-shadow:0 2px 5px #ac8b7630}.stamp span{display:block;font-size:11px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:#6d7e6e}.grade-reward{background:#f2f5eb}.badge-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:5px}.grade-badge{min-width:0;text-align:center;opacity:.3;filter:grayscale(1)}.grade-badge.earned{opacity:1;filter:none}.grade-badge strong{display:grid;place-items:center;margin:auto;width:31px;height:31px;border-radius:10px;background:#e3ab88;color:white;font-size:16px}.grade-badge small{display:block;font-size:10px;color:#78907b;margin-top:5px;white-space:nowrap}.result-stamp{height:115px;width:115px;background-size:cover;background-position:center;border:7px double #d98566;border-radius:50%;margin:22px auto 4px;display:grid;place-items:end center;box-shadow:0 8px 25px #638c6d38}.result-stamp span{background:#fff8e4ed;padding:2px 7px;border-radius:10px;font-size:12px;color:#935a45;margin-bottom:9px;white-space:nowrap}.result-pets{position:relative;height:143px;margin-top:15px}.result-pets .char{height:143px}
@media(max-height:740px){.map-preview{margin-top:10px;padding:10px 14px}.map-mini-path{margin-top:8px}.home-content{padding-bottom:8px}}

.baize-mini{background-position:-45px 0}
.lesson-meta{display:flex;justify-content:space-between;align-items:center}.listen-pill{font-size:11px;color:#e47763;background:#fff0eb;border-radius:20px;padding:7px 10px}.voice-guide{display:flex;align-items:center;gap:10px;padding:12px 14px;margin:7px 0 12px;background:#edf7ff;border-radius:17px;color:#436875}.voice-guide .mini-pet{flex:0 0 42px}.voice-guide strong{font-size:14px}.voice-guide p{font-size:12px;margin:3px 0 0;color:#78929a}.voice-guide button,.explain-block button{margin-left:auto;border:0;width:34px;height:34px;border-radius:50%;background:#fff;color:#ec806c;box-shadow:0 3px 8px #79a2b329}.lesson-card{margin-top:0;padding:20px}.lesson-card .original{font-size:20px;line-height:2.12}.pinyin{display:block;font-family:system-ui;font-size:11px;line-height:1.2;color:#b2a7de;letter-spacing:.02em;margin-bottom:5px}.listen-main{border:0;background:#fff1ec;color:#e47661;border-radius:12px;padding:11px 13px;margin-top:15px;font-size:13px;font-weight:700}.voice-actions{display:flex;gap:10px;margin-top:12px}.record-button,.play-button{border:0;border-radius:16px;min-height:66px;padding:10px 12px;display:flex;align-items:center;justify-content:center;gap:7px;font-weight:800}.record-button{flex:1;background:#ff816e;color:#fff;box-shadow:0 5px 0 #df6557}.record-button span{font-size:17px}.record-button small,.play-button small{display:block;font-size:10px;font-weight:600;margin-left:4px}.record-button.recording{background:#dc5260;animation:pulse 1.1s infinite}.play-button{width:118px;background:#eaf3ff;color:#6489ca}.play-button:disabled{opacity:.45;box-shadow:none}.explain-stack{display:grid;gap:9px;margin-top:13px}.explain-block{display:flex;align-items:center;gap:10px;background:#fffefa;border:1px solid #eee9df;border-radius:15px;padding:12px 13px;box-shadow:0 3px 10px #879b8a12}.explain-block>div{flex:1}.explain-kicker{display:block;color:#df8b70;font-size:11px;font-weight:800;margin-bottom:4px}.explain-block strong{font-size:15px;color:#45644e}.explain-block p{font-size:13px;line-height:1.55;color:#6f8176;margin:2px 0 0}.explain-block.fact{background:#f6f1ff;border-color:#ebe2ff}.explain-block.fact .explain-kicker{color:#8f78bd}.explain-block.fact button{color:#8b72bd}@keyframes pulse{50%{transform:scale(1.03);box-shadow:0 5px 0 #b94456,0 0 0 7px #dc526033}}
