.difficulty.four-levels{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.difficulty.four-levels button{min-height:73px}.difficulty.four-levels small{font-size:14px}.feature-clue{margin:18px 0;padding:19px 24px;border:1px solid #afcbd4;border-left:5px solid #55929d;border-radius:17px;background:linear-gradient(115deg,#fafffff5,#e6f1f3f5);box-shadow:0 4px 15px #4568750a}.feature-clue small{color:#557b88;font-size:13px}.feature-clue h2{font-size:20px;color:#355e70;margin:3px 0 8px}.feature-clue p{font-size:20px;line-height:1.75;margin:0;color:#2d495a;word-break:keep-all;overflow-wrap:anywhere}.classroom-scene .enemy-unknown{font-size:14px}.feature-study{padding:14px 16px;border:1px solid #c2d9de;border-radius:13px;background:#eff7f8;margin:14px 0}.feature-study b{font-size:15px;color:#466f7b}.feature-study p{margin:7px 0 0!important}.quiz-mode-note{padding:10px 14px;border-radius:10px;background:#edf6f7;color:#376575;font-size:15px;line-height:1.7}.feature-answer-reveal{width:100%;height:100%;object-fit:contain}.feature-clue div{display:flex;align-items:center;justify-content:space-between;gap:20px}.feature-clue h2{margin:0}
@media(max-width:760px){.feature-clue{padding:15px;margin:14px 0}.feature-clue div{display:block;margin-bottom:8px}.feature-clue p{font-size:17px;line-height:1.85}.feature-clue h2{font-size:19px}.difficulty.four-levels button{min-height:73px}.difficulty.four-levels small{font-size:14px}.classroom-scene .enemy-unknown{font-size:12px}.feature-study p{font-size:15px}.quiz-mode-note{font-size:14px}}

.feature-room .battle-board span{display:none}.feature-room .battle-board{min-width:145px;padding:9px 16px}.feature-room .battle-board b{font-size:32px;line-height:1.1}@media(max-width:760px){.feature-room .battle-board{min-width:128px;padding:6px 11px;top:9px}.feature-room .battle-board b{font-size:26px;line-height:1.1}.feature-room .battle-board small{font-size:11px}}

/* Compact home controls line up with the welcome card beside them. */
body[data-page="home"] .mission-panel{display:flex;flex-direction:column;align-self:stretch;margin-bottom:5px;padding:18px 20px;min-width:0}
body[data-page="home"] .lesson-heading{display:flex;align-items:baseline;gap:10px;min-width:0;flex-shrink:0}
body[data-page="home"] .lesson-heading h2{font-size:25px;line-height:1.35;white-space:nowrap;flex-shrink:0}
body[data-page="home"] .lesson-heading .stage-range{margin:0;font-size:13px;line-height:1.4;white-space:nowrap;min-width:0;color:#55768a}
body[data-page="home"] .difficulty-label{font-size:12px;line-height:1.4;margin:12px 0 7px;flex-shrink:0}
body[data-page="home"] .difficulty{gap:8px;flex-shrink:0}
body[data-page="home"] .difficulty button{min-height:64px;padding:9px 5px;gap:3px;align-content:center}
body[data-page="home"] .difficulty b{font-size:15px;line-height:1.3}
body[data-page="home"] .difficulty small{font-size:13px;line-height:1.35}
body[data-page="home"] .quiz-explainer{flex:1;min-height:44px;display:flex;align-items:center;margin:8px 0 10px;font-size:14px;line-height:1.5}
body[data-page="home"] .mission-panel>.primary{min-height:46px;padding:11px 16px;font-size:16px;flex-shrink:0}
body[data-page="home"] .mission-panel>.secondary{min-height:42px;padding:9px 16px;font-size:14px;margin-top:8px;flex-shrink:0}
body[data-page="home"] .mission-panel .best{font-size:12px;line-height:1.4;margin-top:8px;flex-shrink:0}
@media(min-width:761px) and (max-width:1050px){body[data-page="home"] .mission-panel{padding:16px}body[data-page="home"] .lesson-heading{gap:8px}body[data-page="home"] .lesson-heading h2{font-size:23px}body[data-page="home"] .lesson-heading .stage-range{font-size:12px}}
@media(max-width:760px){body[data-page="home"] .mission-panel{margin-bottom:0;padding:16px}body[data-page="home"] .lesson-heading{gap:9px}body[data-page="home"] .lesson-heading h2{font-size:22px}body[data-page="home"] .lesson-heading .stage-range{font-size:12px}body[data-page="home"] .difficulty-label{margin-top:10px;margin-bottom:6px}body[data-page="home"] .difficulty button{min-height:59px;padding:8px 4px}body[data-page="home"] .quiz-explainer{min-height:36px;margin:8px 0 10px;font-size:13px}body[data-page="home"] .mission-panel>.primary{min-height:44px;font-size:15px}body[data-page="home"] .mission-panel .best{font-size:11px;margin-top:7px}}
@media(max-width:360px){body[data-page="home"] .lesson-heading{gap:7px}body[data-page="home"] .lesson-heading h2{font-size:20px}body[data-page="home"] .lesson-heading .stage-range{font-size:11px}body[data-page="home"] .difficulty small{font-size:12px}}

/* Four drawn lessons replace the duplicate family/address shortcuts. */
body[data-page="home"] .regular-course{margin-top:25px}
body[data-page="home"] .regular-map .course-card{position:relative;min-height:258px;padding:14px 16px 13px;gap:5px;align-items:center;text-align:center;border-radius:18px;border-color:color-mix(in srgb,var(--course-accent) 48%,#d5e2e6);background:linear-gradient(160deg,#fffffff5,color-mix(in srgb,var(--course-accent) 9%,white));overflow:hidden}
body[data-page="home"] .regular-map .course-card.selected{border-color:var(--course-accent);box-shadow:0 3px 0 color-mix(in srgb,var(--course-accent) 40%,#d5e6ea);background:linear-gradient(155deg,#fff,color-mix(in srgb,var(--course-accent) 17%,white))}
body[data-page="home"] .regular-map .course-card .stage-no{position:absolute;top:13px;left:13px;font-size:12px;line-height:1.4;letter-spacing:0;padding:3px 8px;border:1px solid color-mix(in srgb,var(--course-accent) 38%,white);border-radius:15px;background:#ffffffd9;color:#4d7080}
body[data-page="home"] .regular-map .course-art{display:block;width:112px;height:112px;object-fit:contain;flex-shrink:0;margin:1px auto 0;filter:drop-shadow(0 3px 3px #345a7112)}
body[data-page="home"] .regular-map .course-card .course-title{font-size:20px;line-height:1.4;letter-spacing:-.035em;white-space:normal;word-break:keep-all;overflow-wrap:anywhere}
body[data-page="home"] .regular-map .course-card .course-range{font-size:13px;line-height:1.5;color:#4f7687}
body[data-page="home"] .regular-map .course-card .course-description{font-size:13px;line-height:1.55;color:#607f8b;min-height:40px;margin:0;word-break:keep-all;overflow-wrap:anywhere}
body[data-page="home"] .regular-map .course-card .stage-stars{margin-top:auto;justify-content:center;gap:5px}
body[data-page="home"] .regular-map .course-card .stage-stars i{font-size:17px}
@media(max-width:1050px) and (min-width:761px){body[data-page="home"] .regular-map .course-card{padding:12px 10px;min-height:270px}body[data-page="home"] .regular-map .course-art{width:98px;height:98px;margin-top:13px}body[data-page="home"] .regular-map .course-card .course-title{font-size:18px;min-height:50px}body[data-page="home"] .regular-map .course-card .course-description{font-size:12px}}
@media(max-width:760px){body[data-page="home"] .regular-course{margin-top:22px}body[data-page="home"] .regular-course>.section-row h2{font-size:21px}body[data-page="home"] .regular-course>.section-row h2 span{font-size:12px;margin-left:5px}body[data-page="home"] .regular-map .course-card{padding:11px 10px;min-height:260px;gap:4px;border-radius:15px}body[data-page="home"] .regular-map .course-card .stage-no{top:9px;left:9px;font-size:10px;padding:2px 6px}body[data-page="home"] .regular-map .course-art{width:99px;height:99px;margin-top:7px}body[data-page="home"] .regular-map .course-card .course-title{font-size:17px;min-height:48px;display:flex;align-items:center;justify-content:center}body[data-page="home"] .regular-map .course-card .course-range{font-size:12px}body[data-page="home"] .regular-map .course-card .course-description{font-size:12px;line-height:1.5;min-height:54px}body[data-page="home"] .regular-map .course-card .stage-stars i{font-size:15px}}
@media(max-width:360px){body[data-page="home"] .regular-course>.section-row h2 span{display:none}body[data-page="home"] .regular-map .course-art{width:90px;height:90px;margin-top:12px}body[data-page="home"] .regular-map .course-card .course-title{font-size:16px;min-height:45px}body[data-page="home"] .regular-map .course-card .course-description{font-size:11px}body[data-page="home"] .regular-map .course-card .course-range{font-size:11px}}

/* Drawn graduation and final mastery endings. Keep the complete composition visible. */
.ending-scene{overflow:hidden;border:1px solid #cfbd8e;border-radius:24px;background:#fffcf3;box-shadow:0 12px 45px #2749591a;animation:ending-arrive .6s ease-out}
.ending-picture{background:#e8dfcd;line-height:0;overflow:hidden}
.ending-picture img{display:block;width:100%;height:auto;max-height:calc(100svh - 190px);object-fit:contain;margin:auto}
.ending-message{padding:25px 25px 28px;text-align:center;background:linear-gradient(120deg,#fffef8,#f3f8f5)}
.ending-message .eyebrow{color:#a28648;margin:0 0 7px;letter-spacing:.17em}
.ending-message h1{font-size:31px;line-height:1.45;margin:0 0 10px;color:#57685a;outline:none}
.ending-message>p:not(.eyebrow){font-size:17px;line-height:1.8;margin:0;color:#657a75;word-break:keep-all}
.ending-actions{display:flex;justify-content:center;gap:12px;flex-wrap:wrap;margin-top:21px}
.ending-actions button{min-height:46px;font-size:16px;padding:12px 24px}
.ending-scene.maestro{border-color:#ad9260;background:#151f3d;box-shadow:0 12px 50px #182e5440}
.maestro .ending-picture{background:#101934}
.maestro .ending-message{background:linear-gradient(120deg,#182443,#273151);border-top:1px solid #8e774e}
.maestro .ending-message h1{color:#f0d58c}
.maestro .ending-message>p:not(.eyebrow){color:#dee4f3}
.maestro .ending-message .eyebrow{color:#d7b873}
.maestro .ending-actions .primary{background:linear-gradient(130deg,#b89654,#e2c789);color:#25304a;box-shadow:0 3px 0 #665437;border-color:#b89654}
.course-completion .ending-replay{margin-left:auto;flex-shrink:0}
.maestro-replay{display:block;margin:14px auto 0}
.graduation-result{display:flex;align-items:center;flex-direction:column;gap:12px}
.graduation-result h2,.graduation-result p{margin:0}
@keyframes ending-arrive{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:none}}
@media(max-width:760px){.ending-scene{border-radius:16px}.ending-picture img{max-height:none}.ending-message{padding:23px 16px 25px}.ending-message h1{font-size:25px}.ending-message>p:not(.eyebrow){font-size:15px;line-height:1.9}.ending-actions{gap:10px;margin-top:18px}.ending-actions button{width:100%;font-size:15px;padding:11px 15px}.course-completion{flex-wrap:wrap}.course-completion .ending-replay{margin:6px 0 0;width:100%}.ending-message .eyebrow{font-size:11px}}
@media(prefers-reduced-motion:reduce){.ending-scene{animation:none}}
