/* 启蒙课堂：给孩子看的画面 —— 热身卡片、找笔画、点图片读音 */
@keyframes kid-pop{0%{transform:scale(1)}40%{transform:scale(1.09) rotate(-1.5deg)}100%{transform:scale(1)}}
/* 找笔画 */
.kid-find{display:flex;flex-direction:column;align-items:center;gap:10px;margin:6px 0 10px}
.kid-find-target{display:flex;align-items:center;gap:14px;padding:6px 26px;background:#fff4dc;border:3px solid #f0a93c;border-radius:999px}
.kid-find-label{font-size:22px;color:#b7791f}
.kid-find-target .finder-target-stroke{width:84px;height:58px;background:transparent;border:0;padding:0;color:#f0a93c}
.kid-find-name{font-weight:400;font-size:34px;color:#b7791f}
.finder-dots{display:flex;gap:8px}
.finder-dots i{width:14px;height:14px;border-radius:50%;background:#e3e7dd;box-sizing:border-box}
.finder-dots i.is-done{background:#f0a93c}
.finder-dots i.is-now{background:#fff;border:3px solid #f0a93c}
.finder-box{border:3px solid #e9d9cf}
.find-stroke:hover{fill:#f0a93c;opacity:.55}
.find-stroke.is-found{fill:#f0a93c;opacity:1}
@keyframes kid-shake{0%,100%{transform:translateX(0)}25%{transform:translateX(-7px)}75%{transform:translateX(7px)}}
.finder-box.is-shake{animation:kid-shake .3s}
.finder-q~.flow-feedback,.kid-find~.flow-feedback{font-size:20px;color:#b7791f;min-height:28px;margin:6px 0}
.stage-stroke [data-solo-find]{background:#f0a93c!important;border-color:#f0a93c!important;color:#fff!important;font-size:20px;padding:12px 26px;border-radius:999px;box-shadow:0 4px 0 #b7791f}
/* 选择题：图片本身就是读音按钮 */
.quiz-photo-btn{display:block;border:0;padding:0;background:none;cursor:pointer;border-radius:16px}
.stage-quiz .quiz-prompt:has(.quiz-photo-btn){grid-template-columns:1fr;justify-items:center}
.stage-quiz .quiz-photo-btn .quiz-photo{grid-row:auto;width:260px;height:160px}
.quiz-photo-btn:focus-visible{outline:3px solid #75976b;outline-offset:3px}
/* 找笔画：左边题目，右边汉字，一屏装得下 */
#finder-host .finder-box,#finder-host .finder-box svg{width:min(300px,40vh);height:min(300px,40vh)}
@media(min-width:760px){
 #finder-host{display:grid;grid-template-columns:minmax(0,1fr) auto;column-gap:36px;align-items:center;justify-content:center;max-width:760px;margin:0 auto}
 #finder-host>.finder-chips,#finder-host>.flow-done{grid-column:1/-1}
 #finder-host>.kid-find,#finder-host>.flow-feedback,#finder-host>.solo-actions{grid-column:1;justify-self:center;text-align:center}
 #finder-host>.finder-box{grid-column:2;grid-row:span 3;margin:0}
}
#flow-stage:has(#finder-host)>.flow-title{display:none}
#finder-host .finder-box,#finder-host .finder-box svg{width:min(300px,36vh);height:min(300px,36vh)}
/* 有趣的小图标（纯装饰，不影响读屏） */
.lc-tabs [data-tab="outline"]::before,[role=tablist] [data-tab="outline"]::before{content:"📖 "}
[role=tablist] [data-tab="lesson"]::before{content:"🎒 "}
[role=tablist] [data-tab="games"]::before{content:"🎮 "}
[role=tablist] [data-tab="home"]::before{content:"🏠 "}
.flow-steps [data-flow="warm"] span{font-size:0}.flow-steps [data-flow="warm"] span::before{content:"🔥";font-size:14px}
.flow-steps [data-flow="stroke"] span{font-size:0}.flow-steps [data-flow="stroke"] span::before{content:"✏️";font-size:14px}
.flow-steps [data-flow="learn"] span{font-size:0}.flow-steps [data-flow="learn"] span::before{content:"👀";font-size:14px}
.flow-steps [data-flow="quiz"] span{font-size:0}.flow-steps [data-flow="quiz"] span::before{content:"🎯";font-size:14px}
.flow-steps [data-flow="write"] span{font-size:0}.flow-steps [data-flow="write"] span::before{content:"🖌️";font-size:14px}
.flow-steps [data-flow="combo"] span{font-size:0}.flow-steps [data-flow="combo"] span::before{content:"🧩";font-size:14px}
.flow-steps [data-flow="play"] span{font-size:0}.flow-steps [data-flow="play"] span::before{content:"🎮";font-size:14px}
[data-activity="strokefind"]::before{content:"🔍 "}[data-activity="pairs"]::before{content:"🃏 "}[data-activity="listen"]::before{content:"👂 "}
[data-activity="bingo"]::before{content:"🎲 "}[data-activity="combine"]::before{content:"🧩 "}[data-activity="colour"]::before{content:"🎨 "}[data-activity="book"]::before{content:"📚 "}
[data-practice-mode="odd"]::before{content:"🧐 "}[data-practice-mode="missing"]::before{content:"❓ "}[data-practice-mode="find"]::before{content:"🔎 "}
.play-card[data-play="strokefind"]::before{content:"🔍 "}.play-card[data-play="pairs"]::before{content:"🃏 "}.play-card[data-play="listen"]::before{content:"👂 "}.play-card[data-play="bingo"]::before{content:"🎲 "}.play-card[data-play="odd"]::before{content:"🧐 "}.play-card[data-play="missing"]::before{content:"❓ "}.play-card[data-play="find"]::before{content:"🔎 "}.play-card[data-play="combine"]::before{content:"🧩 "}
/* 课程目录：保留带图片的卡片，改成左右滑，一屏看三节课 */
.scroll-rail-wrap{position:relative}
/* 组合字：左右滑 */
/* 今天的笔画：笔画图随屏幕高度缩放，一屏装下 */
.stage-stroke .solo-box{width:min(280px,34vh);height:min(280px,34vh)}
.stage-stroke .solo-box svg{width:100%;height:100%}
.stage-stroke .solo-wrap{margin:0;gap:22px}
.stage-stroke .solo-name{font-size:3rem}
.stage-stroke .solo-side{gap:6px}
.stage-stroke .flow-title{margin:0 0 4px}
.quiz-listen{font-size:26px;padding:16px 34px;border-radius:999px;box-shadow:0 4px 0 #1f3d27}
.quiz-listen:active{transform:translateY(3px);box-shadow:0 1px 0 #1f3d27}
#hz-title[role=button]{cursor:pointer}
#hz-title[role=button]:focus-visible{outline:3px solid #75976b;outline-offset:4px;border-radius:8px}
/* 听音题：整个题目区都能点，没有单独的按钮 */
/* 课程目录再紧凑一点，1024×768 一屏装下 */
#panel-outline .lc-panel-head{margin:0 0 2px!important;padding:0!important}
#panel-outline .lc-panel-head h2{margin:0}
#class-notice{gap:6px!important;margin-block:6px!important}
/* 认字、写一写：图和田字格随屏幕高度缩放，一屏装下 */
html body .visual-lesson .stage-learn .picture-stage{height:clamp(110px,17.5vh,300px)!important}
.visual-lesson .stage-learn .visual-prompt{margin:0 0 4px!important}
.visual-lesson .stage-learn .step-controls{margin:6px 0 0!important}
.visual-lesson .stage-learn .kids-actions{margin:6px 0 0!important}
.visual-lesson #flow-stage.stage-learn{gap:6px!important}
html body .visual-lesson .stage-write .sp-body svg,html body .visual-lesson .stage-write #flow-stroke-host svg{max-height:34vh}
html body #class-notice{margin-block:4px!important}
html body #class-notice>*{margin-block:0!important}
/* 课程目录：笔画用图形显示 */
.kid-stroke .stroke-ico{width:38px;height:38px;margin:0 3px;padding:4px;border:1.5px solid #f4d79b;border-radius:10px;background:#fff;color:#f0a93c;vertical-align:middle}
#outline-list .kid-tag.kid-stroke{display:inline-flex;align-items:center;gap:2px;padding:3px 10px}
#outline-list .kid-tag.kid-stroke::before{content:none}

/* ========== 「本节课」面板重新设计 ========== */
/* 顶栏：标题 + 小信息一行，右边是工具按钮 */
html body .visual-lesson{padding:12px 16px 10px!important;gap:6px!important;border-radius:22px!important;background:#fff}
html body .visual-lesson .panel-heading{display:flex!important;align-items:center;justify-content:space-between;gap:12px;margin:0!important;padding:0 0 8px!important;border:0!important;border-bottom:2px dashed #e3ece0!important}
.visual-lesson .lesson-title{display:flex;align-items:baseline;gap:12px;min-width:0;flex-wrap:wrap}
.visual-lesson .lesson-title h2{margin:0!important;font-size:26px!important;font-weight:400;color:#2f4a28;letter-spacing:.06em}
.visual-lesson .lesson-title .lesson-label{font-size:14px;color:#7b887f;font-weight:400}
.visual-lesson .panel-buttons{display:flex;gap:6px;flex-wrap:nowrap}
.visual-lesson .panel-buttons>*{min-height:34px!important;padding:4px 12px!important;font-size:14px!important;border-radius:999px!important;white-space:nowrap}
/* 步骤条：圆润的大药丸，当前这一步实心 */
html body .visual-lesson .flow-steps{margin:2px 0 4px!important;padding:2px!important;background:none!important;gap:8px!important;justify-content:center}
html body .visual-lesson .flow-steps button{min-height:42px;padding:6px 16px!important;border:2px solid #dbe7d6!important;border-radius:999px!important;background:#fff!important;font-size:16px!important;box-shadow:0 2px 0 #dbe7d6}
html body .visual-lesson .flow-steps button[aria-current=step]{background:#315b3c!important;border-color:#315b3c!important;color:#fff!important;box-shadow:0 2px 0 #1f3d27}
/* 内容区：居中，不再留一大片空白 */
html body .visual-lesson #flow-stage.stage-warm,html body .visual-lesson #flow-stage.stage-stroke,html body .visual-lesson #flow-stage.stage-quiz,html body .visual-lesson #flow-stage.stage-combo{display:flex!important;flex-direction:column;justify-content:center;align-items:center}
/* 底部导航：一行 —— 上一步 | 上一节 下一节 | 下一步 */
html body .visual-lesson .flow-nav{display:flex!important;align-items:center;justify-content:space-between;gap:10px;margin:0!important;padding:8px 0 0!important;border-top:2px dashed #e3ece0}
.visual-lesson .flow-lessons{display:inline-flex;gap:6px}
.visual-lesson .flow-lessons .ghost{min-height:34px;padding:2px 12px;border:0;border-radius:999px;background:transparent;color:#6a7a70;font-size:14px;cursor:pointer}
.visual-lesson .flow-lessons .ghost:hover:not(:disabled){background:#f1f6ee;color:#315b3c}
.visual-lesson .flow-lessons .ghost:disabled{opacity:.35;cursor:default}
.visual-lesson .flow-nav>button{min-height:40px;padding:4px 20px;border-radius:999px;font-size:16px}
/* 热身：「上节课 | 本节课」切换 + 大卡片，箭头放在卡片两边，不压在卡片上 */
html body .visual-lesson .stage-learn .picture-stage{height:clamp(150px,29vh,340px)!important}


/* ========== 第三版：同页显示、去掉箭头和滚动条 ========== */
/* 热身：上节课 + 本节课 在同一页 */
.warm-all{display:flex;flex-direction:column;gap:12px;width:100%;max-width:960px}
.warm-group{display:grid;grid-template-columns:64px minmax(0,1fr);align-items:center;gap:10px}
.warm-group h3{margin:0;padding:6px 0;border-radius:14px;text-align:center;font-size:16px;font-weight:400;writing-mode:horizontal-tb}
.warm-group.is-review h3{background:#e8f1e4;color:#3f6436}
.warm-group.is-new h3{background:#ffeccc;color:#8a5a0f}
.warm-grid{display:grid;gap:10px}
.warm-group.is-review .warm-grid{grid-template-columns:repeat(auto-fill,minmax(68px,1fr))}
.warm-group.is-new .warm-grid{grid-template-columns:repeat(auto-fill,minmax(112px,1fr))}
.warm-card{display:flex;flex-direction:column;align-items:center;gap:1px;padding:6px 6px 8px;background:#fff;border:3px solid #bcd3b4;border-radius:20px;cursor:pointer;box-shadow:0 4px 0 #bcd3b4;transition:transform .12s,box-shadow .12s}
.warm-card.is-new{border-color:#f0b94d;box-shadow:0 4px 0 #f0b94d;background:#fffdf7}
.warm-card:hover{transform:translateY(-2px)}
.warm-card:active,.warm-card.is-tapped{transform:translateY(3px);box-shadow:0 1px 0 #bcd3b4}
.warm-card.is-new:active{box-shadow:0 1px 0 #f0b94d}
.warm-card:focus-visible{outline:3px solid #75976b;outline-offset:3px}
.warm-card-img{display:block;width:100%;aspect-ratio:16/10;border-radius:13px;overflow:hidden;background:#f3f6ef}
.warm-card-img img{width:100%;height:100%;object-fit:cover;display:block}
.warm-card-char{font-weight:400;line-height:1.1;color:#2f4a28}
.warm-card.is-new .warm-card-char{font-size:clamp(34px,5.4vh,48px)}
.warm-card.is-review .warm-card-char{font-size:clamp(30px,4.6vh,40px)}
.warm-card .py{font-size:13px;color:#6f7d73}
.warm-card.is-tapped{animation:kid-pop .35s}
@media(max-width:560px){.warm-group{grid-template-columns:1fr}.warm-group h3{justify-self:start;padding:4px 16px}}
/* 听音题：显示拼音，点拼音就读 */
.quiz-pinyin{display:block;margin:0 auto;min-width:min(420px,86%);padding:14px 40px;border:3px solid #bcd3b4;border-radius:28px;background:#f3f8f0;color:#2f4a28;font-size:56px;line-height:1.2;letter-spacing:.04em;cursor:pointer;box-shadow:0 5px 0 #bcd3b4;transition:transform .12s,box-shadow .12s}
.quiz-pinyin:hover{background:#e9f3e4}
.quiz-pinyin:active{transform:translateY(3px);box-shadow:0 1px 0 #bcd3b4}
.stage-quiz .quiz-prompt:has(.quiz-pinyin){display:block;text-align:center}
/* 认字、写一写上面的字：不滚动，放不下就换行 */
html body .visual-lesson .stage-write .write-picker,html body .visual-lesson .stage-learn .visual-character-picker.grouped{flex-wrap:wrap!important;overflow:visible!important;justify-content:center;row-gap:6px!important}
/* 组合字：居中排开 */
.combo-list{display:flex;flex-wrap:wrap;justify-content:center;gap:14px}
/* 课程目录：一屏 4×2 的小卡片，没有滚动条 */
#outline-list{display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:12px!important;overflow:visible!important;padding:4px 2px!important;align-items:stretch}
#outline-list>.lc-trials:empty{display:none}
#outline-list .kid-pic{aspect-ratio:21/9!important}
#outline-list .kid-num{width:36px;height:36px;font-size:19px;left:8px;top:8px}
#outline-list .kid-body{display:flex!important;flex-wrap:wrap;align-items:center;justify-content:center;gap:4px 8px!important;padding:8px 10px 2px!important}
#outline-list .kid-chars{display:none!important}
#outline-list .kid-date{font-size:14px}
#outline-list .kid-texts{justify-content:center;gap:4px;flex:0 0 100%}
#outline-list .kid-texts span{display:inline-flex;align-items:center;gap:5px;padding:2px 10px 2px 3px;font-size:13px}
#outline-list .kid-texts span::before{content:none}
#outline-list .kid-texts span img{width:26px;height:26px;border-radius:50%;object-fit:cover;object-position:top;border:1.5px solid #fff;box-shadow:0 0 0 1.5px #f4d79b}
#outline-list .kid-go{min-height:38px!important;margin:6px auto 4px!important;padding:0 24px!important;font-size:16px!important}
#outline-list .kid-more summary{padding:6px 10px;font-size:14px;color:#3f6436;font-weight:600}
#outline-list .kid-more summary::after{content:" ›"}
#outline-list .kid-more[open] summary::after{content:" ˅"}
@media(max-width:680px){#outline-list{grid-template-columns:repeat(2,minmax(0,1fr))!important}}
@media(max-width:420px){#outline-list{grid-template-columns:1fr!important}}
/* 进阶：选择课文 —— 带封面的圆形卡片，不用下拉框 */
.text-reader-nav{display:flex;align-items:center;justify-content:center;gap:12px;flex-wrap:wrap}
.text-picks{display:flex;flex-wrap:wrap;justify-content:center;gap:10px}
.text-pick{display:grid;justify-items:center;gap:2px;width:104px;padding:6px 4px 8px;border:3px solid #dbe7d6;border-radius:20px;background:#fff;color:#2f4a28;cursor:pointer;box-shadow:0 3px 0 #dbe7d6;transition:transform .12s}
.text-pick:hover{transform:translateY(-2px)}
.text-pick.is-on{border-color:#f0b94d;background:#fffaf0;box-shadow:0 3px 0 #f0b94d}
.text-pick-cover{display:grid;place-items:center;width:64px;height:64px;border-radius:50%;overflow:hidden;background:#eef4ea;border:3px solid #fff;box-shadow:0 0 0 2px #cfe0c9}
.text-pick.is-on .text-pick-cover{box-shadow:0 0 0 2px #f0b94d}
.text-pick-cover img{width:100%;height:100%;object-fit:cover;object-position:top}
.text-pick-cover i{font-style:normal;font-size:28px}
.text-pick b{font-size:15px;font-weight:400;line-height:1.2;text-align:center}
.text-pick small{font-size:11px;color:#7b887f}
.text-open{align-self:center;color:#3f6436;font-size:14px;text-decoration:none;padding:6px 12px;border-radius:999px;background:#f1f6ee}
/* 课程目录再压一压，1024×768 一屏装下 */
html body #outline-list .kid-pic{aspect-ratio:7/2!important}
html body #outline-list .kid-num{width:32px;height:32px;font-size:17px;left:8px;top:6px}
html body #outline-list .kid-pic .day-tag{top:8px!important;padding:2px 10px!important;font-size:13px!important}
html body #outline-list .kid-body{padding:6px 8px 0!important;gap:2px 8px!important}
html body #outline-list .kid-tags .kid-tag{padding:2px 8px!important}
html body #outline-list .kid-stroke .stroke-ico{width:30px;height:30px;padding:3px;margin:0 2px}
html body #outline-list .kid-go{min-height:34px!important;margin:4px auto 2px!important;font-size:15px!important}
html body #outline-list .kid-more summary{padding:4px 10px}
html body #panel-outline .lc-panel-head h2{display:none}
html body #panel-outline .lc-panel-head{justify-content:flex-end;min-height:0}
html body #panel-outline .lc-panel-head a,html body #panel-outline .lc-panel-head button{min-height:32px!important;padding:2px 14px!important;font-size:14px!important}
html body .class-notice>*,html body #class-notice>*{padding-block:6px!important}
html body #outline-list .kid-pic .day-tag.kid-trial{top:auto!important;bottom:8px}
html body #outline-list .kid-pic{aspect-ratio:4/1!important}
html body #outline-list .kid-date{flex:0 0 100%;text-align:center;font-size:13px}
html body #panel-outline .lc-panel-head{display:none!important}
html body .lc-tabs{padding:4px!important}
html body .lc-tabs [role=tab]{min-height:40px!important;padding-block:4px!important}
html body .notice-homework{padding-block:4px!important;min-height:0!important;margin-block:0!important}
html body .class-notice-detail>summary{padding-block:6px!important;min-height:0!important}
html body #outline-list .kid-stroke .stroke-ico{width:28px;height:28px}
html body #outline-list .kid-date{line-height:1.2;margin:0}
html body #outline-list .kid-more summary{padding:2px 10px;line-height:1.5}
html body #outline-list .kid-go{margin:2px auto 0!important}
html body #outline-list{gap:10px!important}
html body .visual-lesson #flow-stage{scrollbar-width:none}
html body .visual-lesson #flow-stage::-webkit-scrollbar{display:none}
.warm-all{gap:8px}
.warm-grid{gap:8px}
.warm-card.is-new .warm-card-char{font-size:clamp(30px,4.8vh,44px)}
.warm-card.is-review{padding:4px 4px 6px}
.warm-card.is-review .warm-card-char{font-size:clamp(28px,4.2vh,38px)}
/* 进阶的步骤条分组较多：换行显示，不要左右滚动条 */
html body .visual-lesson .flow-steps.is-grouped{flex-wrap:wrap!important;overflow:visible!important;justify-content:center!important;gap:6px 10px!important;scrollbar-width:none}
html body .visual-lesson .flow-steps.is-grouped::-webkit-scrollbar{display:none}
html body .visual-lesson .flow-steps.is-grouped .flow-module{display:inline-flex;flex-wrap:wrap;align-items:center;gap:6px}
html body .visual-lesson .flow-steps.is-grouped button{min-height:36px;padding:3px 12px!important;font-size:15px!important}
html body .visual-lesson .flow-module-name{font-size:13px;color:#7b887f}
html body #outline-list .kid-pic{overflow:hidden;min-height:0}
html body #outline-list .kid-pic img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
/* 字很多时（进阶），认字上面的字格缩小，两三行放得下 */
html body .visual-lesson #flow-stage.is-dense.stage-learn .visual-character-picker.grouped{gap:4px!important}
html body .visual-lesson #flow-stage.is-dense.stage-learn .pick-group button{width:44px!important;min-height:44px!important;padding:0!important}
html body .visual-lesson #flow-stage.is-dense.stage-learn .pick-big{font-size:24px!important}
html body .visual-lesson #flow-stage.is-dense.stage-learn .pick-group button .py{display:none}
html body .visual-lesson #flow-stage.is-dense.stage-learn .picture-stage{height:clamp(100px,17vh,190px)!important}
html body .visual-lesson #flow-stage.is-dense.stage-learn .pick-group button{width:40px!important;min-height:40px!important}
html body .visual-lesson #flow-stage.is-dense.stage-learn .pick-big{font-size:22px!important}
html body .visual-lesson .flow-steps.is-grouped{margin:0!important;gap:4px 8px!important}
html body .visual-lesson .flow-steps.is-grouped button{min-height:32px;font-size:14px!important}

/* ========== 按屏幕高度均匀铺满（不再写死比例） ========== */
@media(min-width:681px){
 .learning-page:not(.hanzi-page) #panel-outline:not([hidden]){display:flex;flex-direction:column;height:calc(100vh - var(--panel-top,260px) - 12px);min-height:440px}
 html body #outline-list{flex:1 1 auto;min-height:0;grid-template-rows:repeat(2,minmax(0,1fr))!important;align-content:stretch}
 html body #outline-list>.lc-card{min-height:0;display:flex;flex-direction:column}
 html body #outline-list .kid-pic{aspect-ratio:auto!important;flex:1 1 90px;min-height:84px!important}
 html body #outline-list .kid-pic img{object-position:center 78%}
 html body #outline-list .kid-body{flex:0 0 auto}
}
html body #outline-list .kid-more{margin-top:auto}
@media(min-width:681px){
 .learning-page:not(.hanzi-page) #panel-outline:not([hidden]){height:calc(100vh - var(--panel-top,260px) - 46px)}
 html body #outline-list{align-items:stretch!important}
 html body #outline-list>.lc-card{align-self:stretch!important;height:auto!important}
}
/* 热身：每排字数均分（12 个 = 6+6），整体居中 */
html body .warm-group.is-new .warm-grid{grid-template-columns:repeat(var(--cols,6),minmax(0,150px))!important;justify-content:center}
html body .warm-group.is-review .warm-grid{grid-template-columns:repeat(var(--cols,9),minmax(0,86px))!important;justify-content:center}
.warm-all{margin:0 auto}
html body .visual-lesson .stage-learn .picture-stage{height:clamp(120px,22vh,340px)!important}

/* ========== 第四版：各标签页同样大小 · 没有滚动条 · 单字图标步骤 ========== */
/* 1) 所有标签页（目录、本节课、游戏、作业与复习）高度完全一样 */
@media(min-width:681px){
 html body.learning-page:not(.hanzi-page) .learning-content>.lc-panel:not([hidden]){display:flex!important;flex-direction:column;height:var(--panel-h)!important;min-height:440px!important;max-height:none;overflow:hidden}
 html body.learning-page:not(.hanzi-page) #lesson-panel{flex:1 1 auto;min-height:0;display:flex;flex-direction:column}
 html body.learning-page:not(.hanzi-page) #lesson-panel>.lesson-panel-card{flex:1 1 auto;min-height:0;height:auto!important}
 html body.learning-page:not(.hanzi-page) #panel-games>*,html body.learning-page:not(.hanzi-page) #home-review>*{flex:0 0 auto}
}
:root{--panel-h:calc(100vh - var(--panel-top,260px) - 46px)}
/* 2) 滚动条全部隐藏（内容已经按一屏排好） */
.learning-page main *{scrollbar-width:none}
.learning-page main *::-webkit-scrollbar{display:none}
/* 3) 步骤条：单字图标药丸，一行放得下 */
html body .visual-lesson .flow-steps{flex-wrap:nowrap!important;overflow:visible!important;gap:8px!important}
html body .visual-lesson .flow-steps button{min-width:54px;justify-content:center;font-size:20px!important;padding:4px 14px!important;gap:4px}
html body .visual-lesson .flow-steps.is-grouped{flex-wrap:wrap!important}
html body .visual-lesson .flow-steps.is-grouped button{min-width:48px;font-size:18px!important}
/* 4) 游戏菜单：换行，不用横向滚动 */
html body #game-menu{flex-wrap:wrap!important;overflow:visible!important;justify-content:center;gap:6px 8px}
/* 5) 「本课详情」：点开是浮在卡片上的小面板，不撑高卡片 */
html body #outline-list>.lc-card{position:relative;overflow:visible!important}
html body #outline-list .kid-pic{border-radius:20px 20px 0 0}
html body #outline-list .kid-more[open]>dl{position:absolute;left:-2px;right:-2px;bottom:calc(100% - 4px);z-index:20;margin:0!important;padding:12px 14px!important;background:#fff;border:2px solid #cfe0c9;border-radius:18px;box-shadow:0 10px 28px #1b3a2433;max-height:none;font-size:14px}
html body #outline-list .kid-more[open]>summary{position:relative;z-index:21}
html body #outline-list>.lc-card:nth-child(-n+5) .kid-more[open]>dl{bottom:auto;top:calc(100% - 4px)}
/* 6) 今天的笔画：笔画图随屏幕高度缩放 */
html body .stage-stroke .solo-box{width:min(260px,30vh)!important;height:min(260px,30vh)!important}
html body.learning-page:not(.hanzi-page) .lc-tabs{position:static!important}
/* 四个标签页（目录、本节课、游戏、作业与复习）用同一个高度 —— 用 id 选择器压过旧规则 */
@media(min-width:681px){
 html body.learning-page:not(.hanzi-page) #panel-outline:not([hidden]),
 html body.learning-page:not(.hanzi-page) #lesson:not([hidden]),
 html body.learning-page:not(.hanzi-page) #activities:not([hidden]),
 html body.learning-page:not(.hanzi-page) #home-review:not([hidden]){display:flex!important;flex-direction:column;height:var(--panel-h)!important;min-height:440px!important;max-height:none!important;overflow:hidden!important;box-sizing:border-box}
}

/* ========== 第五版：每页一种颜色 · 圆润的游戏 · 轻一点的卡片边框 ========== */
body.learning-page{--accent:#3f7d52;--accent-dark:#2d5d3b;--soft:#eaf4e6;--line:#cfe2c8}
body.learning-page[data-view=lesson]{--accent:#2f81b7;--accent-dark:#1f6190;--soft:#e6f2fa;--line:#bddaee}
body.learning-page[data-view=games]{--accent:#e0852a;--accent-dark:#b86513;--soft:#fff0dd;--line:#f4d4a4}
body.learning-page[data-view=home]{--accent:#8a63c4;--accent-dark:#6a47a1;--soft:#f0e9fb;--line:#d9c9f0}
body.learning-page[data-view=text]{--accent:#259a8c;--accent-dark:#177468;--soft:#e2f5f2;--line:#b7e2dc}
html body.learning-page:not(.hanzi-page) .lc-tabs [role=tab][aria-selected=true]{background:var(--accent)!important;border-color:var(--accent)!important;color:#fff!important;box-shadow:0 3px 0 var(--accent-dark)}
html body.learning-page:not(.hanzi-page) .lc-tabs [role=tab]{border-radius:999px}
html body.learning-page:not(.hanzi-page) .learning-content>.lc-panel:not([hidden]){border:3px solid var(--line)!important;border-radius:28px!important;background:linear-gradient(180deg,var(--soft) 0,#fff 150px)!important;transition:border-color .25s}
html body .visual-lesson{background:transparent!important}
html body .visual-lesson .panel-heading,html body .visual-lesson .flow-nav{border-color:var(--line)!important}
html body .visual-lesson .lesson-title h2{color:var(--accent-dark)}
html body .visual-lesson .flow-steps button{border-color:var(--line)!important;box-shadow:0 2px 0 var(--line)}
html body .visual-lesson .flow-steps button[aria-current=step]{background:var(--accent)!important;border-color:var(--accent)!important;color:#fff!important;box-shadow:0 2px 0 var(--accent-dark)}
html body .visual-lesson .flow-nav>button.solid,html body #activities .solid,html body #home-review .solid{background:var(--accent)!important;border-color:var(--accent)!important;box-shadow:0 3px 0 var(--accent-dark)}
html body #game-menu button[aria-pressed=true]{background:var(--accent)!important;border-color:var(--accent)!important;color:#fff!important}
/* 热身：外框轻一点，让字更突出 */
.warm-card{border:2px solid #dbe8d5!important;box-shadow:0 2px 0 #dbe8d5!important;border-radius:26px!important}
.warm-card.is-new{border-color:#f7e0b4!important;box-shadow:0 2px 0 #f7e0b4!important;background:#fffdf8}
.warm-card-img{border-radius:18px!important}
.warm-card-char{color:#22391f;font-size:clamp(34px,5.6vh,52px)!important}
.warm-card.is-review .warm-card-char{font-size:clamp(30px,4.8vh,42px)!important}
.warm-group h3{border-radius:999px!important}
/* 游戏：全部圆润，不用方块 */
html body #activities .activity-card,html body #activities .practice-tile,html body #activities .part-options button{border-radius:50%!important;aspect-ratio:1/1;display:grid;place-items:center;padding:0!important;border:3px solid var(--line)!important;background:#fff!important;box-shadow:0 3px 0 var(--line)!important;color:#2b3f26;font-size:clamp(28px,5.5vh,46px)}
html body #activities .activity-card.matched,html body #activities .practice-tile.found{background:var(--soft)!important;border-color:var(--accent)!important}
html body #activities .pairs-grid .activity-card{border-radius:32px!important;aspect-ratio:auto}
html body #activities .cols-grid,html body #activities .bingo-grid,html body #practice-board{display:grid;grid-template-columns:repeat(var(--cols,3),minmax(0,1fr));gap:10px;width:min(100%,46vh,420px);margin-inline:auto;justify-items:center}
html body #activities .bingo-grid .activity-card,html body #activities .cols-grid:not(.pairs-grid) .activity-card,html body #practice-board .practice-tile{width:100%;max-width:130px}
html body #activities button.outline,html body #activities .practice-controls button,html body #activities select{border-radius:999px!important}
html body #activities .activity-card,html body #activities .practice-tile{height:auto!important;min-height:0!important;width:100%}
html body.learning-page:not(.hanzi-page) #activities:not([hidden]),html body.learning-page:not(.hanzi-page) #home-review:not([hidden]),html body.learning-page:not(.hanzi-page) #panel-outline:not([hidden]){padding:12px 16px!important}
html body #activities>h2,html body #activities .lc-panel-head h2{margin:0 0 6px;font-size:22px;color:var(--accent-dark)}

/* ========== 第六版：在统一的面板高度里排好每个步骤 ========== */
/* 认字：上面一排字，下面左边大图、右边提示和按钮 */
@media(min-width:681px){
 html body .visual-lesson #visual-stage{display:grid!important;grid-template-columns:minmax(0,1.35fr) minmax(0,1fr);grid-template-rows:auto 1fr;column-gap:16px;row-gap:8px;align-items:start;max-width:none!important;width:100%}
 html body .visual-lesson #visual-stage .picture-stage{grid-column:1;grid-row:1/span 2;height:clamp(170px,34vh,380px)!important}
 html body .visual-lesson #visual-stage .visual-prompt{grid-column:2;grid-row:1;align-self:end;margin:0!important}
 html body .visual-lesson #visual-stage .step-controls{grid-column:2;grid-row:2;flex-direction:column;align-items:stretch;gap:8px;margin:0!important}
 html body .visual-lesson #visual-stage .step-controls .step-dots{display:flex;flex-direction:column;gap:6px}
 html body .visual-lesson #flow-stage.is-dense.stage-learn .picture-stage{height:clamp(130px,26vh,300px)!important}
}
/* 写一写、组合字、今天的笔画：随高度缩放 */
html body .visual-lesson .stage-write #flow-stroke-host svg{max-height:30vh}
html body .stage-stroke .solo-box{width:min(240px,25vh)!important;height:min(240px,25vh)!important}
html body .stage-stroke .solo-wrap{gap:18px}
html body .visual-lesson .stage-combo .combo{padding:8px 12px}
/* 游戏：圆形格子随高度缩放，说明文字更紧凑 */
html body #activities .cols-grid,html body #activities .bingo-grid,html body #practice-board{width:min(100%,30vh,300px)!important;gap:8px}
html body #activities .pairs-grid{width:min(100%,520px)!important;gap:8px}
html body #activities .activity-card,html body #activities .practice-tile{font-size:clamp(24px,4.6vh,40px)}
html body #activities .practice-play{padding:8px 10px!important}
html body #activities .practice-play h3{margin:0 0 4px}
html body #activities .practice-play>p{margin:2px 0 6px;font-size:14px}
html body #activities #activity-stage,html body #activities #practice-pane>*{overflow:visible}
/* 提示条更薄 */
html body #class-notice{margin-block:4px!important}
html body .class-notice-detail>summary{padding-block:5px!important}
html body .notice-homework{padding-block:3px!important;font-size:14px}
/* 页头和「下次上课」提示条在所有标签页都显示，页面框架保持一致 */
html body.learning-page:is([data-tab="lesson"],[data-tab="games"],[data-tab="books"]) :is(.mc-site-header,#class-notice){display:revert!important}
/* 认字：上面的字格紧凑一点 */
html body .visual-lesson .stage-learn .visual-character-picker.grouped{gap:6px!important;padding:2px 0 4px!important;max-height:none}
html body .visual-lesson .stage-learn .pick-group button{width:52px!important;min-height:52px!important;padding:0!important;border-radius:50%!important}
html body .visual-lesson .stage-learn .pick-big{font-size:28px!important}
html body .visual-lesson .stage-learn .pick-group button .py{display:none}
html body .visual-lesson #visual-stage .picture-stage{height:clamp(150px,30vh,330px)!important}
html body .visual-lesson #visual-stage .step-controls{gap:6px}
html body .visual-lesson #visual-stage .step-controls button{min-height:34px;padding:2px 12px}
html body .visual-lesson .stage-learn .kids-actions{margin:0!important}
/* 写一写、组合字 */
html body .visual-lesson .stage-write #flow-stroke-host svg{max-height:26vh}
html body .visual-lesson .stage-combo .combo-list{gap:10px}
html body .visual-lesson .stage-combo{padding-block:4px!important}
/* 游戏：说明文字去掉一行，菜单再紧凑 */
html body #activities #game-menu button{padding:4px 10px!important;min-height:32px!important;font-size:14px!important}
html body #activities .practice-play>p.small,html body #activities .game-round-count{display:none}
html body #activities .craft-card{aspect-ratio:auto;border-radius:24px!important}
#activity-finder .finder-box,#activity-finder .finder-box svg{width:min(300px,27vh)!important;height:min(300px,27vh)!important}
html body .finder-chips button[aria-pressed=true]{background:var(--accent,#3f7d52)!important;border-color:var(--accent,#3f7d52)!important;color:#fff!important}
/* 进阶（字多）：步骤条一行放下；热身用紧凑的圆角字格 */
html body .visual-lesson .flow-steps.is-grouped{flex-wrap:nowrap!important;gap:4px 6px!important;justify-content:center}
html body .visual-lesson .flow-steps.is-grouped .flow-module{flex-wrap:nowrap;gap:4px}
html body .visual-lesson .flow-steps.is-grouped button{min-width:42px;padding:3px 8px!important;font-size:17px!important}
html body .visual-lesson .flow-module-name{font-size:12px}
.warm-group.is-compact .warm-grid{grid-template-columns:repeat(var(--cols,8),minmax(0,64px))!important}
.warm-group.is-compact .warm-card{padding:4px 4px 6px;border-radius:22px!important}
.warm-group.is-compact .warm-card-char{font-size:clamp(26px,4.2vh,36px)!important}
.warm-group.is-compact .py{font-size:11px}
/* 写一写：字多时字格小一点，笔画画布也小 */
html body .visual-lesson #flow-stage.is-dense.stage-write .write-picker button{width:36px!important;height:36px!important;font-size:22px!important}
html body #finder-host .finder-box,html body #finder-host .finder-box svg{width:min(300px,27vh)!important;height:min(300px,27vh)!important}
html body .visual-lesson #flow-stage.is-dense.stage-learn #visual-stage .picture-stage{height:clamp(110px,21vh,260px)!important}

/* ========== 第七版：浅绿、笔画图标、笔顺小卡自动排布、翻牌拼音、橙色底 ========== */
body.learning-page{--accent:#5fa374;--accent-dark:#3f7d52;--soft:#eef7ec;--line:#d3e7cd}
/* 上课按钮、本课详情：浅绿 */
html body #outline-list .kid-go{background:#dff1e0!important;color:#2d6a43!important;border:2px solid #a8d4b1!important;box-shadow:0 3px 0 #a8d4b1!important}
html body #outline-list .kid-go:hover,html body #outline-list .kid-go:focus-visible{background:#cfeAD3!important}
html body #outline-list .kid-num{background:#6fb184!important}
html body #outline-list .kid-more{border-top:0!important}
html body #outline-list .kid-more summary{margin:2px 12px 8px;padding:3px 12px;border-radius:999px;background:#eef7ec;color:#3f7d52!important;font-weight:400!important}
html body #outline-list .kid-more summary:hover{background:#e0f0dd}
html body #outline-list .kid-more[open]>dl .lc-strokes{display:flex;gap:6px;flex-wrap:wrap}
html body #outline-list .kid-more .lc-strokes .stroke-ico{width:32px;height:32px;padding:3px;border:1.5px solid #f4d79b;border-radius:10px;background:#fff;color:#e0a026}
/* 写一写：笔顺小卡按笔数自动排布，一笔也不会被拉得很大 */
html body .stage-write .sp-right .sp-rail{grid-template-columns:repeat(auto-fill,minmax(80px,104px))!important;justify-content:start}
html body .stage-write .sp-rail li{width:auto!important;max-width:104px}
html body .stage-write .sp-rail li svg{max-height:92px!important}
html body .stage-write .sp-body{grid-template-columns:auto minmax(0,1fr)!important;align-items:start}
html body .stage-write .sp-bar button,html body .stage-write .sp-tools button{border-radius:999px!important}
/* 翻牌找朋友：提示卡上是拼音，不是喇叭 */
.card-pinyin{position:absolute;left:50%;bottom:6px;transform:translateX(-50%);padding:1px 12px;border-radius:999px;background:#ffffffe6;color:#6a4a10;font-size:15px;line-height:1.4;box-shadow:0 1px 4px #0002}
.card-pinyin.is-big{position:static;transform:none;font-size:clamp(24px,4.4vh,36px);background:none;box-shadow:none;color:#6a4a10}
html body #activities .pairs-grid .activity-card{position:relative;overflow:hidden}
.card-audio-mark,.sound-cue{display:none!important}
/* 游戏页：底色跟着橙色走，不再是绿色 */
html body #activities #activity-stage,html body #activities .practice-play,html body #activities #practice-pane{background:var(--soft)!important;border-radius:26px!important;border:0!important}
html body #activities{background:linear-gradient(180deg,var(--soft) 0,#fff 150px)!important}
html body #activities #game-menu button{background:#fff!important;border:2px solid var(--line)!important}
/* 游戏里的「找笔画」：题目在上，汉字在正中，一屏放下 */
html body #activity-finder{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;max-width:720px;margin:0 auto}
html body #activity-finder>.finder-box{margin:0 auto}
html body #activity-finder>.kid-find{margin:0}
/* 本课详情：屏幕中间的弹窗，不会被面板裁掉 */
html body #outline-list .kid-more[open]::before{content:"";position:fixed;inset:0;background:#1b3a2440;z-index:59}
html body #outline-list .kid-more[open]>dl,html body #outline-list>.lc-card:nth-child(-n+5) .kid-more[open]>dl{position:fixed!important;left:50%!important;top:50%!important;right:auto!important;bottom:auto!important;transform:translate(-50%,-50%);width:min(92vw,440px);max-height:80vh;overflow:auto;z-index:60;padding:18px 22px!important;border:3px solid var(--line);border-radius:26px;box-shadow:0 18px 50px #1b3a2459;font-size:16px;line-height:1.7;display:grid;gap:10px}
html body #outline-list .kid-more[open]>dl>div{display:grid;grid-template-columns:64px 1fr;gap:8px;align-items:baseline}
html body #outline-list .kid-more[open]>dl dt{color:#6f7d73;font-size:14px}
html body #outline-list .kid-more[open]>summary{z-index:58}
html body #activities #game-menu button[aria-pressed=true]{background:var(--accent)!important;color:#fff!important;border-color:var(--accent)!important}
/* 自动适配用：内容按 --fit 比例缩小 */
html body .visual-lesson #flow-stage>*{zoom:var(--fit,1)}

/* 内容区可以随面板收缩（去掉最小高度），自动适配才能生效 */
html body .visual-lesson #flow{flex:1 1 auto!important;min-height:0!important}
html body .visual-lesson #flow-stage,html body .visual-lesson #flow-stage.flow-stage{min-height:0!important;flex:1 1 0!important}
/* 认字、写一写：旧规则把内容区固定成「不伸缩」+ 最小高度，这里还原成随面板伸缩 */
html body .visual-lesson:has(.stage-learn) #flow,html body .visual-lesson:has(.stage-write) #flow{flex:1 1 auto!important;min-height:0!important}
html body .visual-lesson #flow-stage.stage-learn,html body .visual-lesson #flow-stage.stage-write{flex:1 1 0!important;min-height:0!important;height:auto!important;max-height:none!important;overflow:hidden!important}

/* 进阶汉语：11 个步骤也用和启蒙一样的大圆形按钮，一行放下；分组名去掉，用间隔区分 */
html body .visual-lesson .flow-steps.is-grouped{flex-wrap:nowrap!important;gap:0 4px!important;justify-content:center}
html body .visual-lesson .flow-steps.is-grouped .flow-module{background:transparent!important;padding:0 !important;gap:4px;flex-wrap:nowrap;border:0!important}
html body .visual-lesson .flow-steps.is-grouped .flow-module+.flow-module{margin-left:10px;padding-left:10px!important;border-left:2px dotted #c9d9c6!important}
html body .visual-lesson .flow-steps.is-grouped .flow-module-name{display:none}
html body .visual-lesson .flow-steps.is-grouped button{min-height:44px;min-width:50px;padding:4px 10px!important;font-size:19px!important;border-radius:999px}
