.classroom .join,.classroom #home{display:none!important}
.startup-tip,.upload-note{position:fixed;left:50%;top:18px;z-index:95;transform:translateX(-50%);padding:12px 18px;border:3px solid #fff;border-radius:16px;background:#fff4ce;color:#67420d;box-shadow:0 8px 24px #173f3b45;font-weight:800}.startup-tip[hidden],.upload-note[hidden]{display:none}.upload-note.error{background:#fff0e8;color:#9a3528}
.scene-dock{position:fixed;left:50%;bottom:max(14px,env(safe-area-inset-bottom));z-index:45;transform:translateX(-50%);display:grid;grid-template-columns:repeat(6,58px);gap:7px;padding:8px;border:3px solid #fff7dc;border-radius:22px;background:#17483feF;box-shadow:0 10px 30px #06241f70;backdrop-filter:blur(8px)}
.scene-dock[hidden]{display:none}.scene-button{width:58px;height:54px;border:0;border-radius:15px;background:#e6f2eb;color:#1b5d54;box-shadow:0 3px 0 #779b8d;display:grid;grid-template-columns:1fr 1fr;place-items:center;padding:5px;font-weight:900}.scene-button b{font-size:20px;grid-row:1/3}.scene-button span{font-size:13px}.scene-button i{width:7px;height:7px;border-radius:50%;background:#9fb8ae}.scene-button.active{background:#ffc958;color:#67420d;box-shadow:0 3px 0 #a66c28}.scene-button.active i{background:#fff}.scene-button:disabled{opacity:.28;filter:grayscale(.6)}
.classroom #submit{width:auto;min-width:122px;padding:0 9px;display:flex;align-items:center;justify-content:center;gap:6px}.classroom #submit svg{width:27px;height:27px;flex:none}.classroom #submit .submit-copy{display:grid;gap:1px;text-align:left;line-height:1.05;white-space:nowrap}.classroom #submit .submit-copy b{font-size:13px}.classroom #submit .submit-copy small{font-size:9px;font-weight:800;opacity:.78}.classroom #submit[aria-busy="true"]{opacity:.65;pointer-events:none}.classroom #submit.retry{background:linear-gradient(145deg,#ffd37a,#f08a43);color:#713615}.classroom #submit.sent{background:linear-gradient(145deg,#8ae0b7,#30a67d);color:#084c3c}.classroom #submit.locked{background:linear-gradient(145deg,#c5d2cc,#8fa79d);color:#36554d}.classroom #submit.error{animation:button-warn .32s 2}.teacher-mode #submit{min-width:146px;background:linear-gradient(145deg,#fff4b5,#ffc34b);color:#67420d}@keyframes button-warn{50%{transform:translateX(5px)}}
.works-scene{position:fixed;inset:0;z-index:25;overflow:auto;padding:20px 22px 105px;background:radial-gradient(circle at 12% 3%,#fff2bd 0,transparent 25%),radial-gradient(circle at 92% 0,#c4ebdd 0,transparent 29%),#edf6f2;color:#173f3b}.works-scene[hidden]{display:none}.works-heading{min-height:76px;max-width:1500px;margin:0 auto 18px;display:flex;align-items:center;gap:16px}.works-heading h1{margin:3px 0 0;font-size:clamp(24px,3vw,38px)}.works-heading>div:nth-child(2){flex:1}.round-back{width:58px;height:58px;border:3px solid #fff;border-radius:18px;background:#ffc958;font-size:27px;box-shadow:0 5px 0 #a66c28}.works-round-pips,#worksRoundPips{display:flex;gap:5px}#worksRoundPips i{display:inline-block;width:11px;height:11px;margin-right:5px;border-radius:50%;background:#b1c8bf}#worksRoundPips i.on{background:#ef765d;box-shadow:0 0 0 3px #ffd9cb}.works-meta{display:flex;align-items:center;gap:10px}.works-meta>strong{padding:9px 13px;border-radius:99px;background:#fff;border:2px solid #d4e7df;font-size:17px}#classStatus{display:flex;align-items:center;gap:7px;padding:9px 13px;border-radius:99px;background:#fff;color:#667e77;font-size:13px}#classStatus i{width:10px;height:10px;border-radius:50%;background:#f0ad54}#classStatus.online i{background:#43c98e;box-shadow:0 0 0 4px #43c98e25}#classStatus.offline i{background:#ef765d}#classStatus b{font-weight:800}.works-grid{width:min(1500px,100%);margin:auto;display:grid;grid-template-columns:repeat(5,minmax(150px,1fr));gap:13px}.work-slot{position:relative;min-height:145px;aspect-ratio:5/3;padding:0;overflow:hidden;border:4px solid #fff;border-radius:19px;background:linear-gradient(145deg,#dfece6,#c9ddd4);box-shadow:0 8px 20px #17483f18;color:#6e8b82}.work-slot.empty{cursor:default}.work-slot.empty::before{content:attr(data-number);position:absolute;inset:0;display:grid;place-items:center;font-size:33px;font-weight:900;opacity:.38}.work-slot img{display:block;width:100%;height:100%;object-fit:cover}.work-slot footer{position:absolute;left:8px;bottom:8px;min-width:35px;padding:5px 8px;border-radius:99px;background:#173f3bdf;color:#fff;font-size:13px;font-weight:900}.work-slot.mine{outline:5px solid #ffc958;outline-offset:0}.work-slot.confirmed::after{content:'✓';position:absolute;top:8px;right:8px;width:34px;height:34px;display:grid;place-items:center;border-radius:50%;background:#2bb481;color:#fff;border:3px solid #fff;font-size:20px;font-weight:900;box-shadow:0 4px 10px #17483f40}
.work-viewer[hidden]{display:none}.work-viewer{position:fixed;inset:0;z-index:80;display:grid;place-items:center;padding:28px;background:#071f1ce8;backdrop-filter:blur(8px)}.work-viewer figure{width:min(1320px,94vw);margin:0}.work-viewer img{display:block;width:100%;max-height:84vh;object-fit:contain;border:6px solid #fff9e9;border-radius:23px;background:#cadfbf}.work-viewer figcaption{margin-top:10px;color:#fff;text-align:center;font-size:17px}.work-viewer>button{position:absolute;right:22px;top:18px;width:56px;height:56px;border:0;border-radius:18px;background:#fff;color:#17483f;font-size:34px;line-height:1}
.teacher-panel{position:fixed;z-index:55;right:20px;top:92px;width:min(430px,calc(100vw - 40px));min-height:215px;display:flex;align-items:center;gap:18px;padding:18px;border:4px solid #fff;border-radius:25px;background:#fff8df;box-shadow:0 18px 45px #102f2960}.teacher-panel[hidden]{display:none}.teacher-panel-close{position:absolute;right:8px;top:6px;border:0;background:transparent;color:#54736b;font-size:27px}.teacher-qr{width:174px;height:174px;flex:0 0 174px;display:grid;place-items:center;padding:8px;border-radius:18px;background:#fff;border:3px solid #f0bd53}.teacher-qr img,.teacher-qr canvas{max-width:100%;height:auto}.teacher-copy{min-width:0;display:flex;flex-direction:column;gap:8px}.teacher-copy>strong{font-size:25px}.teacher-copy>span{color:#6b7e78;font-size:13px}.teacher-copy #joinLinks{display:flex;flex-direction:column;gap:5px}.teacher-copy button{border:0;border-radius:8px;padding:5px 7px;background:#e1efe8;color:#285f56;font-size:11px;overflow-wrap:anywhere}.teacher-copy button.active{background:#17483f;color:#fff}.teacher-qr-toggle{position:fixed;z-index:54;right:18px;bottom:94px;width:52px;height:52px;border:3px solid #fff;border-radius:17px;background:#ffc958;color:#68430d;font-size:28px;box-shadow:0 5px 0 #a66c28}.teacher-qr-toggle::after{content:'';position:absolute;right:3px;top:3px;width:10px;height:10px;border:2px solid #fff;border-radius:50%;background:#43c98e}.teacher-qr-toggle.offline{background:#ef765d;color:#fff}.teacher-qr-toggle.offline::after{background:#7e251d}
.teacher-copy .teacher-help{padding:7px 9px;border-radius:10px;background:#fff;color:#315f57;font-size:12px;font-weight:800;line-height:1.45}.teacher-mode .scene-dock{grid-template-columns:repeat(6,66px)}.teacher-mode .scene-button{width:66px}.teacher-mode .game-shell{padding-bottom:78px}
@media(max-width:1050px){.works-grid{grid-template-columns:repeat(4,minmax(135px,1fr))}.teacher-panel{top:75px}}
@media(max-width:720px){.scene-dock{grid-template-columns:repeat(6,46px);gap:4px;padding:6px;border-radius:17px}.scene-button,.teacher-mode .scene-button{width:46px;height:46px;border-radius:12px;padding:3px}.scene-button b{font-size:16px}.scene-button span{font-size:10px}.works-scene{padding:10px 10px 88px}.works-heading{min-height:58px;margin-bottom:9px;gap:9px}.round-back{width:47px;height:47px;border-radius:15px}.works-meta{gap:5px}#classStatus{padding:8px}#classStatus b{display:none}.works-meta>strong{padding:7px 9px}.works-grid{grid-template-columns:repeat(4,1fr);gap:7px}.work-slot{min-height:82px;border-width:2px;border-radius:12px}.work-slot.empty::before{font-size:23px}.work-slot footer{left:4px;bottom:4px;padding:3px 6px;font-size:10px}.teacher-panel{right:8px;top:68px;width:calc(100vw - 16px);min-height:170px;gap:11px;padding:12px}.teacher-qr{width:135px;height:135px;flex-basis:135px}.teacher-copy>strong{font-size:20px}.teacher-mode .scene-dock{grid-template-columns:repeat(6,46px)}}
@media(max-width:470px){.scene-dock,.teacher-mode .scene-dock{grid-template-columns:repeat(6,42px)}.scene-button,.teacher-mode .scene-button{width:42px}.works-grid{grid-template-columns:repeat(3,1fr)}.works-heading h1{font-size:19px}.teacher-qr{width:115px;height:115px;flex-basis:115px}.teacher-copy>span{font-size:11px}}
@media(prefers-reduced-motion:reduce){*{animation:none!important;transition:none!important}}

#workViewerRun{position:absolute;top:18px;right:90px;width:56px;height:56px;border-radius:18px;border:3px solid #fff4cc;background:#ffc958;color:#174c44;font-size:30px;z-index:2}#workViewerRun[hidden]{display:none}
@media(max-width:850px){.classroom #submit{min-width:106px;height:47px;padding:0 7px;gap:4px}.classroom #submit svg{width:23px;height:23px}.classroom #submit .submit-copy b{font-size:11px}.classroom #submit .submit-copy small{font-size:8px}.teacher-mode #submit{min-width:128px}}
@media(max-width:650px){.classroom #submit{min-width:90px;height:42px;padding:0 5px;gap:3px}.classroom #submit svg{width:20px;height:20px}.classroom #submit .submit-copy b{font-size:10px}.classroom #submit .submit-copy small{font-size:7px}.teacher-mode #submit{min-width:116px}}
.teacher-new-class{padding:10px 15px;border:3px solid #fff;border-radius:15px;background:#ef765d;color:#fff;font-weight:900;box-shadow:0 4px 0 #a34534}.teacher-new-class:active{transform:translateY(3px);box-shadow:0 1px 0 #a34534}.teacher-new-class:disabled{opacity:.55}.student-mode .teacher-new-class,.student-mode #workViewerRemove{display:none!important}
.join-address{display:flex;align-items:stretch;gap:5px}.join-address input{min-width:0;width:100%;padding:7px 8px;border:2px solid #b8d4ca;border-radius:9px;background:#fff;color:#17483f;font:700 11px/1.25 Consolas,monospace;user-select:text}.join-address button{flex:none;padding-inline:10px!important;font-weight:900}
#workViewerRemove{left:22px;right:auto;top:18px;width:auto;min-width:142px;padding:0 16px;border:3px solid #ffd7ce;background:#ef765d;color:#fff;font-size:16px;font-weight:900}#workViewerRemove[hidden]{display:none}
.teacher-confirm[hidden]{display:none}.teacher-confirm{position:fixed;inset:0;z-index:120;display:grid;place-items:center;padding:20px;background:#071f1cc7;backdrop-filter:blur(7px)}.teacher-confirm>div{width:min(470px,calc(100vw - 34px));padding:27px;border:5px solid #fff;border-radius:25px;background:#fff9e9;color:#173f3b;box-shadow:0 22px 65px #0007}.teacher-confirm strong{display:block;font-size:27px}.teacher-confirm p{margin:12px 0 22px;color:#526f67;line-height:1.7}.teacher-confirm footer{display:flex;justify-content:flex-end;gap:11px}.teacher-confirm button{min-width:105px;padding:11px 16px;border:0;border-radius:13px;background:#dcebe5;color:#285b52;font-weight:900}.teacher-confirm #teacherConfirmOk{background:#ef765d;color:#fff}
@media(max-width:720px){.teacher-new-class{padding:8px 10px;font-size:12px}.teacher-confirm strong{font-size:23px}#workViewerRemove{left:12px;top:12px;min-width:122px;height:48px;font-size:14px}}
.teacher-panel{width:min(650px,calc(100vw - 40px));max-height:calc(100dvh - 120px);overflow:auto}.teacher-copy{flex:1}.teacher-copy .teacher-help{font-size:14px;line-height:1.65}.teacher-copy .teacher-entry-alt{font-size:12px;line-height:1.6}.join-address input{font-size:clamp(12px,1.4vw,17px);padding:10px 8px}.join-address button{font-size:14px;padding:8px!important}
@media(max-width:540px){.teacher-panel{flex-direction:column;max-height:calc(100dvh - 90px);gap:8px}.teacher-copy{width:100%}.teacher-copy>strong{font-size:18px}.teacher-qr{width:110px;height:110px;flex-basis:110px}.teacher-copy .teacher-help{font-size:13px}.join-address input{font-size:14px}}
