.grade-three-screen.home-screen{height:auto;min-height:100dvh;overflow-x:hidden;overflow-y:auto;background:#e3f4e4}.grade-three-screen.home-screen #app{min-height:100dvh;height:auto}.grade-three-screen .reference-topbar{position:relative;z-index:5}.grade3-home{position:relative;max-width:1440px;margin:auto;padding:12px clamp(18px,4vw,58px) 125px;isolation:isolate}.grade3-home:before{content:"";position:absolute;z-index:-2;inset:0 calc((min(100vw,1440px) - 100vw)/2);background:linear-gradient(#def3fc8c,#e5f4dfdd 53%,#d9efd9),url('assets/reference-world.webp') center top/cover fixed;opacity:.85}.grade3-welcome{min-height:215px;display:flex;align-items:center;justify-content:center;gap:55px;position:relative;padding:10px 20px 20px}.grade3-label{font-size:12px;letter-spacing:2px;font-weight:900;color:#397b79}.grade3-welcome h1{font-size:clamp(30px,3.5vw,46px);line-height:1.15;color:#102f59;margin:9px 0}.grade3-welcome h1 br{display:none}.grade3-welcome p{font-size:17px;font-weight:700;line-height:1.45;color:#40635c;margin:0}.grade3-fox{width:150px;height:150px;background:url('assets/props.webp') no-repeat;background-size:400% 400%;background-position:100% 100%;filter:drop-shadow(0 7px 5px #547c7420);transform:rotate(-4deg)}.grade3-floating{position:absolute;color:#f5bb3d;font-size:45px;filter:drop-shadow(0 2px 1px white)}.star-a{top:19%;left:8%;transform:rotate(-20deg)}.star-b{right:9%;bottom:15%;font-size:30px}.grade3-subjects{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:24px 26px;max-width:1200px;margin:0 auto}.grade3-house{min-width:0;color:#264b50;text-decoration:none;text-align:center;position:relative;transition:transform .2s;display:flex;align-items:center;flex-direction:column}.grade3-house:nth-child(n+5){transform:translateX(54%)}.grade3-house:hover{filter:brightness(1.03);margin-top:-3px;margin-bottom:3px}.grade3-house:focus-visible{outline:4px solid #173f59;outline-offset:7px;border-radius:25px}.grade3-house-art{height:119px;width:160px;position:relative;border-radius:39px 39px 11px 11px;background:linear-gradient(135deg,#fff9e8,var(--card-soft));border:5px solid #fff6dc;box-shadow:0 6px 0 #b6c3a266,inset -12px 0 0 #b49c6222;margin-top:27px}.g3-roof{position:absolute;left:-21px;top:-30px;width:189px;height:54px;clip-path:polygon(50% 0,100% 73%,96% 100%,50% 29%,4% 100%,0 73%);background:var(--card);filter:drop-shadow(0 4px 0 #213f4522)}.g3-door{position:absolute;left:48px;bottom:-2px;display:grid;place-items:center;width:57px;height:80px;border-radius:30px 30px 0 0;background:var(--card);border:4px solid #fff6dc;box-shadow:inset 4px 2px 0 #ffffff40}.g3-door svg{width:34px;height:34px;stroke:white;color:white;fill:none;stroke-width:2.4}.g3-window{position:absolute;left:13px;top:33px;width:25px;height:31px;border-radius:14px 14px 3px 3px;background:#a7dcdf;border:4px solid white}.grade3-house-art>b{position:absolute;right:7px;top:20px;color:var(--card);font-size:22px;transform:rotate(8deg)}.g3-leaf{position:absolute;bottom:-11px;left:-13px;font-size:39px;color:#7bb65c;text-shadow:16px -8px #99c976,131px 3px #88b966}.g3-house-button{position:relative;z-index:2;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;min-height:85px;width:100%;border-radius:24px;background:linear-gradient(155deg,color-mix(in srgb,var(--card),white 16%),var(--card));color:white;box-shadow:inset 0 2px 0 #ffffff70,inset 0 -4px 0 #ffffff32,0 7px 0 color-mix(in srgb,var(--card),#3a3f42 22%),0 11px 18px #43634d20;border:3px solid #ffffff80;padding:9px 9px 11px}.g3-house-button strong{font-size:clamp(17px,1.65vw,23px);font-weight:1000;line-height:1.15;text-transform:uppercase;text-shadow:0 2px 1px #244f4e30}.g3-house-button small{font-size:17px;font-weight:800;display:flex;align-items:center;gap:7px;line-height:1.2}.g3-house-button svg{width:18px;height:18px}.g3-house-note{font-size:12px;font-weight:800;line-height:1.35;margin-top:14px;color:#446959}.grade3-daily{margin:30px auto 0;max-width:750px;display:flex;align-items:center;gap:16px;padding:14px 20px;background:#fffaf0f2;border:2px solid white;border-radius:26px;box-shadow:0 7px 20px #6b917a15}.grade3-daily>span{font-size:48px}.grade3-daily h2{font-size:24px;color:#153c5b;margin:0}.grade3-daily p{margin:2px 0;font-size:14px;color:#698073}.grade3-daily>a{margin-left:auto;display:flex;align-items:center;gap:10px;white-space:nowrap;background:#ff775e;box-shadow:0 4px 0 #d95945;color:white;font-weight:900;text-decoration:none;border-radius:20px;padding:15px 24px}.grade3-daily svg{width:21px;height:21px}.g3-calendar,.g3-data{max-width:480px;margin:14px auto;overflow-x:auto}.g3-calendar>strong{display:block;text-align:center;margin-bottom:10px}.g3-calendar table,.g3-data table{border-collapse:collapse;width:100%;font-size:16px}.g3-calendar th,.g3-calendar td,.g3-data th,.g3-data td{padding:9px 7px;text-align:center;border:1px solid #d5e3d3}.g3-calendar th,.g3-data th{background:#e6f0dc}.g3-calendar .selected{background:#ffd78b}.g3-data caption{font-size:14px;text-align:left;margin-bottom:8px}.g3-bars{padding:12px}.g3-bars>div{display:flex;gap:8px;align-items:center;margin:8px 0;font-size:15px}.g3-bars span{width:48px}.g3-bars i{height:20px;border-radius:4px;background:#78b4b7}.g3-object-groups{display:flex;justify-content:center;flex-wrap:wrap;gap:10px;max-width:600px;margin:10px auto}.g3-object-groups figure{margin:0;padding:8px;max-width:120px;background:#fff2d7;border:2px solid #edc980;border-radius:15px}.g3-object-groups small{font-size:12px}.g3-object-groups figure>div{font-size:21px;line-height:1.4}.g3-money{display:flex;justify-content:center;flex-wrap:wrap;gap:10px;margin:15px auto}.g3-money>div{display:flex;flex-direction:column;border:2px dashed #82b09a;border-radius:13px;background:#e1efe0;padding:10px 17px;min-width:110px}.g3-money strong{font-size:23px}.g3-money small,.g3-money span{font-size:10px}.study-poem p{white-space:pre-line}.grade3-lab-controls{display:flex;align-items:center;flex-wrap:wrap;gap:12px;margin:18px 0}.grade3-lab-controls label{display:flex;flex-direction:column;gap:5px;font-weight:800;flex:1;min-width:115px}.grade3-lab-controls input,.grade3-lab-controls select{border:2px solid #dbe2d4;border-radius:12px;padding:10px;font:inherit;background:white;width:100%}.grade3-lab-result{padding:15px;background:#eef5e8;border-radius:17px;font-size:20px;font-weight:800;overflow-wrap:anywhere}.g3-keyboard{display:flex;gap:5px;justify-content:center;flex-wrap:wrap}.g3-keyboard button{font:inherit;font-weight:900;width:42px;height:44px;border:2px solid #d6dfda;border-radius:10px;background:white;box-shadow:0 3px 0 #d6dfda}.g3-keyboard button.is-next{background:#e7dcff;border-color:#ad93d8}.g3-mouse-targets{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.g3-mouse-targets button{padding:15px 8px;font:inherit;font-weight:800;border-radius:18px;border:2px solid #d5cbe6;background:#f2edfb;min-height:75px}.g3-tree{list-style:none;padding-left:12px;border-left:2px solid #d7c8e8}.g3-tree li{margin:10px 0}.g3-tree button{font:inherit;border:1px solid #d5cbe6;background:#f9f5ff;border-radius:10px;padding:9px 12px}.g3-slide-preview{border:3px solid #b5c5d2;border-radius:18px;padding:22px;background:linear-gradient(120deg,#e7f5ed,#fff9e4);text-align:center;min-height:160px}.g3-slide-preview h3{color:#183e62}.g3-slide-preview p{font-size:18px}.grade3-three-columns{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.grade3-step{display:block;border:2px solid #d7c9e8;background:#f8f2ff;border-radius:14px;padding:14px;font:inherit;text-align:left;line-height:1.5;cursor:pointer}.grade3-step[disabled]{opacity:.6}.grade3-lab .learning-diagram{max-width:500px}.grade3-lab-status{min-height:28px;color:#456b59;font-weight:800;line-height:1.5}.grade-three-screen .subject-hero{align-items:center}
@media(min-width:1500px){.grade3-home{padding-top:18px}.grade3-welcome{min-height:260px}.grade3-subjects{gap:30px 38px}.grade3-house-art{height:145px;width:180px}.g3-roof{width:210px}.g3-door{left:57px;height:95px}.g3-house-button{min-height:95px}}
@media(max-width:850px){.grade3-subjects{grid-template-columns:repeat(2,minmax(0,1fr));gap:21px 17px;max-width:620px}.grade3-house:nth-child(n+5){transform:none}.grade3-house:last-child{grid-column:1/-1;width:calc((100% - 17px)/2);justify-self:center}.grade3-welcome{min-height:210px;gap:8px;justify-content:space-between;padding:13px 5px 15px}.grade3-welcome h1{font-size:34px}.grade3-welcome h1 br{display:block}.grade3-welcome p{font-size:15px}.grade3-fox{width:120px;height:120px}.star-a{display:none}.star-b{right:2%;top:9%;font-size:22px}.g3-house-button strong{font-size:20px}.grade3-daily{padding:13px;gap:8px}.grade3-daily h2{font-size:20px}.grade3-daily>a{padding:12px 15px}.grade3-daily>span{font-size:33px}.grade3-house-note{font-size:11px}.grade-three-screen .reference-brand-copy small{font-size:11px}}
@media(max-width:480px){.grade3-home{padding:8px 15px 114px}.grade3-welcome{min-height:210px}.grade3-welcome h1{font-size:31px}.grade3-welcome p{font-size:13px}.grade3-label{font-size:10px}.grade3-fox{width:105px;height:105px}.grade3-house-art{width:130px;height:101px;margin-top:24px}.g3-roof{width:154px;left:-16px;height:46px;top:-25px}.g3-door{left:39px;width:46px;height:66px}.g3-door svg{width:27px;height:27px}.g3-window{left:8px;top:25px;width:20px;height:25px}.grade3-house-art>b{font-size:18px;right:2px;top:17px}.g3-leaf{font-size:30px;text-shadow:10px -8px #99c976,102px 3px #88b966}.g3-house-button{border-radius:21px;min-height:87px;padding:8px 5px 10px}.g3-house-button strong{font-size:19px}.g3-house-science strong{font-size:17px}.g3-house-button small{font-size:15px}.grade3-house-note{font-size:10px;min-height:27px;padding:0 2px}.grade3-daily{flex-wrap:wrap}.grade3-daily>div{flex:1}.grade3-daily>a{width:100%;justify-content:center;margin-top:3px;font-size:17px}.g3-calendar th,.g3-calendar td{padding:8px 3px;font-size:14px}.g3-data th,.g3-data td{font-size:14px;padding:8px 4px}.grade3-three-columns{grid-template-columns:1fr}.g3-mouse-targets{gap:7px}.g3-mouse-targets button{font-size:14px;padding:12px 3px}.g3-keyboard button{width:35px;height:42px}.grade3-lab-result{font-size:17px}}
@media(prefers-reduced-motion:reduce){.grade3-house{transition:none}}

.device-layout-preview select{font:inherit;border:2px solid #dce5d6;border-radius:12px;padding:10px;background:white;max-width:100%}.device-preview-scroll{max-width:100%;overflow:auto;background:#e4ece5;border-radius:20px}.device-preview-scroll:has(iframe){padding:12px}.device-preview-scroll iframe{display:block;border:0;background:#fffaf1;height:703px;min-height:703px;flex-shrink:0}.grade-three-screen.playing .player-header h1{overflow-wrap:break-word}.grade-three-screen.playing .answer.words{white-space:normal;overflow-wrap:anywhere;line-height:1.4;font-size:19px}.grade-three-screen.playing .options{align-items:stretch}.grade-three-screen .functional-table{overflow-x:auto}@media(max-width:480px){.grade-three-screen.playing .player-header h1{font-size:26px;line-height:1.4}.grade-three-screen.playing .answer.words{font-size:17px;min-width:calc(50% - 10px)}.grade-three-screen.playing .answer.words:has(span){min-width:130px}.grade-three-screen.playing .reading-passage{font-size:17px;line-height:1.75}}

@media(min-width:851px) and (max-height:900px){.grade3-home{padding-top:4px;padding-bottom:90px}.grade3-welcome{min-height:116px;padding:0 20px 8px;gap:30px}.grade3-welcome h1{font-size:35px;margin:5px 0}.grade3-welcome p{font-size:14px}.grade3-fox{width:100px;height:100px}.grade3-floating{font-size:25px}.grade3-subjects{gap:15px 25px;max-width:1150px}.grade3-house-art{height:73px;width:118px;margin-top:18px;border-width:4px}.g3-roof{width:140px;height:38px;left:-15px;top:-23px}.g3-door{left:35px;width:42px;height:53px;border-width:3px}.g3-door svg{width:25px;height:25px}.g3-window{left:9px;top:22px;width:18px;height:23px;border-width:3px}.grade3-house-art>b{font-size:15px;top:13px;right:3px}.g3-leaf{font-size:27px;text-shadow:10px -8px #99c976,91px 3px #88b966}.g3-house-button{min-height:70px;padding:7px 8px 9px;border-radius:22px}.g3-house-button strong{font-size:21px}.g3-house-button small{font-size:15px}.g3-house-note{font-size:11px;margin-top:11px}.grade3-daily{margin-top:18px;padding:9px 18px}.grade3-daily h2{font-size:22px}.grade3-daily>span{font-size:38px}.grade3-daily>a{padding:11px 22px}}

.g3-calendar-pair{display:flex;flex-wrap:wrap;gap:16px}.g3-calendar-pair .g3-calendar{flex:1;min-width:235px}.g3-word-groups{display:flex;flex-wrap:wrap;gap:12px}.g3-word-groups article{flex:1;min-width:130px;padding:12px;background:#edf4e8;border-radius:14px}.g3-reading-log dl{display:grid;gap:14px}.g3-reading-log dt{font-weight:800}.g3-reading-log dd{margin:4px 0;overflow:hidden;color:#819084}.g3-process-flow{display:flex;flex-wrap:wrap;gap:12px;padding-left:24px}.g3-process-flow li{flex:1;min-width:120px;padding:15px;background:#e8f3ed;border-radius:15px}.g3-source-project li{margin:10px 0;line-height:1.65}.g3-cost-lab table{width:100%;border-collapse:collapse;font-size:15px;table-layout:fixed}.g3-cost-lab th,.g3-cost-lab td{border:1px solid #d5dfd0;padding:8px 5px;overflow-wrap:anywhere}.g3-cost-lab input{max-width:100%;width:160px;margin:12px;padding:10px;border:2px solid #d7e0d4;border-radius:12px;font:inherit}.grade3-lab-controls textarea{width:100%;min-width:0;border:2px solid #dbe2d4;border-radius:12px;padding:10px;font:inherit;resize:vertical}.grade3-lab input[type=file]{width:100%;max-width:100%;margin:12px 0;font:inherit;font-size:14px}.g3-slide-preview{overflow-wrap:anywhere}.g3-planet-list,.g3-butterfly{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.g3-planet-list .grade3-step[aria-pressed=true]{border-color:#d19a42;background:#fff0c9}.g3-mouse-targets [data-it-drag]{touch-action:none;position:relative;user-select:none;font-size:30px;cursor:grab}.g3-mouse-targets .dragging{z-index:10;cursor:grabbing;box-shadow:0 8px 18px #375f4933}.g3-mouse-targets [aria-pressed=true]{border-color:#8a6eb1;background:#e7dcf5}.g3-drop-box{min-height:110px;border:3px dashed #7aab91;border-radius:18px;background:#edf7e8;display:grid;place-items:center;padding:18px;margin:20px 0}.g3-scroll-box{height:160px;overflow:auto;overscroll-behavior:contain;border:2px solid #b9cbbb;border-radius:15px;padding:15px;background:#f8fbf5}.g3-scroll-row{min-height:80px;border-top:1px dashed #b9cbbb;padding-top:15px}.grade3-lab #it-mouse-menu{border:2px solid #baa9ce;border-radius:12px;padding:12px;background:#f6f0ff}@media(max-width:480px){.g3-butterfly{grid-template-columns:1fr}.g3-cost-lab table{font-size:12px}.g3-cost-lab input{margin-left:0}.g3-calendar-pair .g3-calendar{min-width:0;flex-basis:100%}}

/* Compact subject links retain the garden after removing the house artwork. */
.grade3-home{min-height:calc(100dvh - 80px)}
@media(max-width:700px) and (orientation:portrait){.grade3-home{min-height:calc(100dvh - 116px)}}

/* Compact subject rows near the bottom of the garden, grades 3–5. */
.grade3-home{display:grid;grid-template-rows:minmax(180px,1fr) auto auto;gap:18px;min-height:calc(100dvh - 80px);padding:18px clamp(20px,4vw,58px) calc(var(--ref-footer) + 22px)}
.grade3-home:before{background:url('assets/reference-world.webp') center center/cover no-repeat;opacity:1}
.grade3-home .grade3-welcome{min-height:0;padding:0;gap:24px;align-self:start}
.grade3-welcome>div:first-child{background:#fff9ebed;padding:12px 22px;border-radius:22px;box-shadow:0 5px 18px #31593d18}
.grade3-home .grade3-subjects{width:100%;max-width:960px;grid-template-columns:repeat(8,minmax(0,1fr));grid-auto-rows:1fr;gap:16px 22px;align-items:end;margin:0 auto}
.grade3-home .grade3-house,.grade3-home .grade3-house:last-child{grid-column:span 2;width:100%;transform:none;justify-self:stretch}
.grade3-home:not(.grade4-home) .grade3-house:nth-child(5){grid-column:2/span 2}
.grade3-home .g3-house-button{min-height:78px;height:100%;padding:9px 8px;gap:4px;border-radius:20px}
.grade3-home .g3-house-button strong{font-size:clamp(17px,1.5vw,21px)}
.grade3-home .g3-house-button small{font-size:14px}
.grade3-home .grade3-daily{width:min(100%,850px);margin:0 auto}
@media(max-width:850px){.grade3-home{grid-template-rows:minmax(145px,1fr) auto auto;gap:18px;min-height:calc(100dvh - 116px)}.grade3-home .grade3-subjects{grid-template-columns:repeat(4,minmax(0,1fr));gap:14px 16px;max-width:560px}.grade3-home:not(.grade4-home) .grade3-house:nth-child(5){grid-column:span 2}.grade3-home:not(.grade4-home) .grade3-house:last-child{grid-column:2/span 2}.grade3-home .grade3-welcome{gap:10px}.grade3-welcome>div:first-child{padding:12px 14px}.grade3-home .g3-house-button{min-height:84px}.grade3-home .grade3-welcome h1{font-size:clamp(26px,5vw,34px)}}
@media(max-width:480px){.grade3-home{padding:18px 15px calc(var(--ref-footer) + 24px)}.grade3-home .grade3-subjects{gap:14px 12px}.grade3-home .grade3-fox{width:80px;height:80px;flex-shrink:0}.grade3-home .grade3-welcome p{font-size:12px}.grade3-home .grade3-welcome h1{font-size:26px}.grade3-home .grade3-floating{display:none}}
