@font-face{font-family:NH Handwriting;src:url('/vendor/nh-handwriting.otf') format('opentype');font-display:swap}
:root{font-family:Inter,"Helvetica Neue",Arial,"Hiragino Kaku Gothic ProN","Yu Gothic",Meiryo,sans-serif;font-size:16px;color:#102735;background:#e9f2f2;--ink:#102735;--muted:#566c76;--ocean:#075a82;--deep:#064363;--aqua:#088c9b;--coral:#f65859;--gold:#ffbf32;--line:#d2e0e5;--shadow:0 5px 18px #123b4f12;--learn:NH Handwriting,"Helvetica Neue",Arial,sans-serif}
*{box-sizing:border-box}html,body{height:100%;margin:0;overscroll-behavior:none}body{overflow:hidden}button,input,select,textarea{font:inherit}button,a,input,select{touch-action:manipulation}button{display:inline-flex;align-items:center;justify-content:center;gap:.45rem;min-height:40px;padding:9px 14px;border:1px solid var(--line);border-radius:12px;background:#fff;color:var(--ink);font-size:.875rem;font-weight:600;line-height:1.25;cursor:pointer;transition:background .14s,color .14s,border-color .14s,box-shadow .14s}button:hover{background:#eef7f8;border-color:#a7c7d2}button:active{transform:translateY(1px)}button:disabled{opacity:.42;cursor:not-allowed;transform:none}button.active,button[aria-pressed=true]:not(.language-button){color:#fff;background:var(--ocean);border-color:var(--ocean)}button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible,canvas:focus-visible{outline:3px solid var(--gold);outline-offset:3px}button svg,svg.icon{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.65;stroke-linecap:round;stroke-linejoin:round;flex:0 0 auto}svg{display:block}.svg-defs{position:absolute;width:0;height:0;overflow:hidden}[hidden]{display:none!important}a{color:var(--ocean);text-decoration:none}a:hover{text-decoration:underline}h1,h2,h3,p{margin-top:0}.primary{background:var(--ocean);border-color:var(--ocean);color:white}.primary:hover{background:var(--deep);border-color:var(--deep)}.secondary{background:#eef7f8;border-color:#c9e1e7;color:var(--ocean)}.text-button{border-color:transparent;background:transparent;min-height:36px;padding:8px;font-size:.875rem;white-space:nowrap}.text-button:hover{border-color:transparent;background:#eaf3f5}.icon-button{width:38px;height:38px;min-height:38px;padding:8px;flex:0 0 auto}.small-button{min-height:38px;padding:8px 12px}.eyebrow{font-size:.75rem;color:var(--muted);font-weight:650;letter-spacing:.045em;text-transform:uppercase}.flip{transform:scaleX(-1)}
.game-shell{height:100dvh;min-height:320px;display:grid;grid-template-rows:auto minmax(0,1fr);gap:12px;padding:12px;padding-top:max(12px,env(safe-area-inset-top));padding-bottom:max(12px,env(safe-area-inset-bottom))}.topbar{display:flex;align-items:center;gap:18px;background:#fff;border:1px solid var(--line);border-bottom:3px solid var(--aqua);border-radius:20px;padding:10px 14px;min-height:76px;box-shadow:var(--shadow);z-index:5}.brand{display:flex;align-items:center;gap:9px;color:var(--ink);flex:0 0 auto}.brand:hover{text-decoration:none}.brand-mark{display:grid;place-items:center;background:var(--ocean);width:42px;height:42px;border-radius:14px;color:#fff;box-shadow:inset 0 -4px 0 #06436340}.brand-mark svg{width:27px;height:27px;fill:none;stroke:currentColor;stroke-width:1.55;stroke-linecap:round;stroke-linejoin:round}.brand strong{display:block;font-size:1.2rem;letter-spacing:-.045em;font-weight:800}.brand-subtitle{display:block;font-size:.75rem;letter-spacing:.005em;font-weight:600;color:var(--muted);margin-top:1px}.mode-tabs{display:flex;gap:4px;align-items:center;border-radius:999px;padding:4px;background:#eef4f6;margin-left:8px}.mode-tabs button{border-radius:999px;border-color:transparent;background:transparent;white-space:nowrap;min-height:38px;padding:9px 16px}.mode-tabs button.active{background:var(--ocean);box-shadow:0 3px 7px #075a8220}.mode-tabs button:not(.active):hover{background:#dfeef2}.mode-tabs svg{width:19px;height:19px}.header-actions{margin-left:auto;display:flex;gap:5px;align-items:center}.header-actions .icon-button{border-color:transparent}.language-button{border:0;padding:8px 9px;background:transparent;white-space:nowrap;font-size:.8125rem}.language-button span{color:var(--muted);font-weight:400}.workspace{min-height:0;display:flex;gap:12px}.build-panel{width:264px;flex:0 0 264px;background:white;border:1px solid var(--line);border-radius:20px;display:flex;flex-direction:column;overflow:hidden;box-shadow:var(--shadow)}.palette-title{display:flex;align-items:flex-start;justify-content:space-between;gap:8px;padding:19px 16px 12px}.palette-title h1{font-size:1rem;letter-spacing:-.025em;margin:0;font-weight:750;white-space:nowrap}.save-status{font-size:.6875rem;line-height:1.4;text-align:right;color:var(--muted);max-width:95px;padding-top:3px}.save-status.error{color:#ab2539}.build-tools{display:grid;grid-template-columns:repeat(4,1fr);gap:5px;margin:0 12px 16px}.build-tools button{padding:9px 1px 8px;min-height:57px;flex-direction:column;gap:6px;font-size:.6875rem;border-color:#dae6eb;border-radius:12px;font-weight:600}.build-tools svg{width:21px;height:21px}.catalog-tabs{display:flex;gap:2px;margin:0 14px;border-bottom:1px solid var(--line)}.catalog-tabs button{flex:1;border:0;background:transparent;color:var(--muted);border-radius:9px 9px 0 0;min-height:38px;position:relative;font-size:.8125rem}.catalog-tabs button.active{background:transparent;color:var(--ocean)}.catalog-tabs button.active:after{content:"";height:3px;position:absolute;bottom:-1px;left:10px;right:10px;border-radius:4px;background:var(--aqua)}.room-catalog{overflow:auto;min-height:0;flex:1;display:grid;grid-template-columns:1fr 1fr;align-content:start;gap:8px;padding:14px 12px 12px;scrollbar-width:thin;scrollbar-color:#bfd3db transparent}.room-catalog button,.room-card{display:flex;flex-direction:column;justify-content:flex-start;gap:5px;min-width:0;min-height:93px;padding:10px 5px 9px;border-radius:13px;font-size:.875rem;line-height:1.1;text-align:center;position:relative;overflow:hidden;background:#f8fbfc;border-color:#dfe8ec}.room-catalog button:hover,.room-card:hover{background:#e8f4f6;border-color:#71adbc}.room-catalog button.active,.room-catalog button.selected{background:#e8f5f6;color:var(--deep);border:2px solid var(--aqua);padding:9px 4px 8px;box-shadow:0 2px 6px #088c9b12}.room-catalog button strong,.room-catalog button .room-name,.room-card .name{font:400 1rem/1.15 var(--learn);color:inherit;display:block}.room-catalog button small,.room-card small{font:500 .6875rem/1.2 Inter,Arial,sans-serif;color:var(--muted);display:block}.room-catalog .room-icon,.room-card .room-icon{display:grid;place-items:center;min-height:30px;font-size:1.3rem}.room-catalog .room-icon svg{width:27px;height:27px}.room-catalog img,.room-catalog canvas{width:100%;height:52px;object-fit:contain}.room-catalog .placed,.room-card .placed{position:absolute;right:6px;top:6px;color:var(--aqua);font-size:.75rem}.room-catalog .swatch{width:33px;height:23px;display:block;border-radius:7px;background:var(--room-color,#d9e9ec);box-shadow:inset 0 -4px 0 #0000000d;margin:1px 0 4px}.readiness{margin:0;border:0;border-top:1px solid var(--line);border-radius:0;background:#f2f8f9;min-height:52px;padding:12px 14px;font-size:.75rem;justify-content:flex-start;gap:7px;flex-shrink:0}.readiness svg{color:var(--aqua);width:18px;height:18px}.readiness .count{font-size:.6875rem;margin-left:auto;color:var(--muted)}.readiness.ready{background:#e8f7ef;color:#1e654e}.viewport{position:relative;isolation:isolate;flex:1;min-width:0;min-height:0;overflow:hidden;border:1px solid #bdcfd6;border-radius:22px;background:#dcece6;box-shadow:var(--shadow)}#scene{display:block;width:100%;height:100%;outline:none;touch-action:none}.viewport-top,.viewport-bottom{position:absolute;left:14px;right:14px;display:flex;justify-content:space-between;align-items:center;gap:10px;pointer-events:none;z-index:2}.viewport-top{top:14px}.viewport-bottom{bottom:14px}.viewport-top>*,.viewport-bottom>*{pointer-events:auto}.activity-label{background:#fffffff0;backdrop-filter:blur(10px);padding:9px 14px;border:1px solid #ffffffbd;border-radius:999px;font-size:.8125rem;font-weight:650;box-shadow:0 3px 12px #143a3a0c;max-width:60%;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.view-toggles{display:flex;gap:6px}.view-toggles button,.help-button{background:#fffffff2;box-shadow:0 3px 12px #143a3a0c;border-color:#ffffffa0}.view-toggles button[aria-pressed=true]{background:var(--ocean);border-color:#ffffff80}.camera-tools{display:flex;align-items:center;gap:2px;background:#fffffff2;border:1px solid #ffffffa0;border-radius:15px;padding:4px;box-shadow:0 3px 12px #143a3a12}.camera-tools button{border:0;background:transparent;width:34px;height:34px;min-height:34px}.camera-tools button:hover{background:#e4f0f3}.camera-tools svg{width:18px;height:18px}.glyph-button{font-size:1.4rem;font-weight:400;line-height:1}.tool-divider{height:20px;width:1px;background:var(--line);margin:0 3px}.empty-state{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);background:#fffffff0;border:1px solid white;border-radius:21px;box-shadow:0 8px 35px #23473415;padding:24px 30px;text-align:center;display:flex;align-items:center;flex-direction:column;gap:12px;pointer-events:none;max-width:85%;width:max-content;color:var(--ocean)}.empty-state strong{font-size:.9375rem;font-weight:600}.empty-icon{width:49px;height:49px;display:grid;place-items:center;background:#e7f3f5;border-radius:15px}.empty-icon svg{width:31px;height:31px;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}.toast{position:absolute;z-index:10;top:68px;left:50%;transform:translateX(-50%);max-width:min(90%,540px);width:max-content;padding:12px 19px;border-radius:13px;background:#102735ee;color:#fff;font-size:.875rem;line-height:1.4;text-align:center;box-shadow:0 6px 24px #10273522;pointer-events:none}.toast.error{background:#a52c3b}.floating-panel{position:absolute;z-index:3;background:#fffffff2;backdrop-filter:blur(12px);border:1px solid #fff;border-radius:18px;box-shadow:0 6px 26px #173d5017;padding:18px}.walk-hud{top:68px;left:14px;max-width:260px}.destination{display:flex;flex-direction:column;gap:5px}.destination strong,#target-name{font:400 1.65rem/1.1 var(--learn);color:var(--deep)}.run-status{display:block;margin-top:11px;font-size:.8125rem;line-height:1.35;color:#a13b27;border-radius:8px;background:#fff0e5;padding:7px 10px}.hud-actions{display:flex;flex-wrap:wrap;gap:6px;margin-top:14px;align-items:center}.hud-actions button{font-size:.75rem;min-height:34px;padding:8px 10px}.hud-actions .text-button{padding:5px 2px;min-height:28px;color:var(--muted)}.hud-actions .primary{width:100%;margin-bottom:3px}.host-hud{left:14px;top:68px;min-width:228px;max-width:270px}.pair-heading{display:flex;align-items:center;justify-content:space-between;gap:12px}.pair-heading .icon-button{width:33px;height:33px;min-height:33px;padding:6px;border-color:transparent}.room-code{font-size:1.7rem;font-weight:750;letter-spacing:.15em;color:var(--ocean);padding:7px 0 4px;font-variant-numeric:tabular-nums}.pair-status{font-size:.75rem;color:var(--muted);display:block;line-height:1.4}.host-target{font:400 1.45rem/1.2 var(--learn);color:var(--deep);margin:16px 0}.host-hud>.secondary{font-size:.75rem;min-height:34px;padding:7px 12px}.touch-controls{position:absolute;bottom:72px;left:18px;right:18px;z-index:4;display:flex;justify-content:space-between;align-items:flex-end;pointer-events:none;user-select:none;-webkit-user-select:none}.touch-controls button{pointer-events:auto;touch-action:none;box-shadow:0 2px 12px #15384815;background:#ffffffdf;border-color:#fff;user-select:none;-webkit-user-select:none}.direction-pad{display:grid;grid-template-columns:repeat(3,44px);grid-template-rows:repeat(2,44px);gap:4px;pointer-events:auto}.direction-pad button{width:44px;height:44px;min-height:44px;border-radius:12px}.pad-up{grid-column:2;grid-row:1}.pad-left{grid-column:1;grid-row:2}.pad-down{grid-column:2;grid-row:2}.pad-right{grid-column:3;grid-row:2}.pad-left svg{transform:rotate(-90deg)}.pad-right svg{transform:rotate(90deg)}.pad-down svg{transform:rotate(180deg)}.run-button{width:64px;height:64px;border-radius:50%;color:var(--ocean);font-size:.875rem}.touch-controls button:active,.touch-controls button.pressed{background:var(--ocean);color:white}.touch-controls:has(button[disabled]) .run-button:disabled{opacity:.55}
dialog{color:var(--ink);border:1px solid #d6e4e9;padding:0;background:white;box-shadow:0 24px 100px #052b4550;max-width:calc(100vw - 32px);border-radius:24px}dialog::backdrop{background:#073a5260;backdrop-filter:blur(5px)}.modal{width:560px;max-height:calc(100dvh - 40px);overflow:hidden}.modal[open]{display:flex;flex-direction:column}.modal-header{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:20px 23px 16px;border-bottom:1px solid var(--line);flex-shrink:0}.modal-header h2{font-size:1.15rem;letter-spacing:-.025em;margin:0}.modal-header .icon-button{border:0;background:#eef5f6;width:34px;height:34px;min-height:34px}.modal-body{padding:22px 24px 24px;overflow:auto;font-size:.9375rem;line-height:1.55}.modal-body p{color:var(--muted);margin-bottom:16px}.modal-body h3{font-size:1rem;margin-bottom:12px}.modal-body form{display:flex;flex-direction:column;gap:14px}.modal-body label{display:flex;flex-direction:column;gap:6px;font-size:.875rem;font-weight:600}.modal-body input:not([type=checkbox]):not([type=radio]),.modal-body select,.modal-body textarea{min-height:44px;padding:11px 12px;background:#f7fafb;color:var(--ink);border:1px solid #bdcfd7;border-radius:11px;width:100%;font-size:1rem}.modal-body input:focus,.modal-body select:focus{border-color:var(--aqua)}.modal-body input[type=checkbox]{accent-color:var(--ocean);width:19px;height:19px}.modal-body .field-error,.modal-body .error{color:#b82e42;font-size:.875rem;line-height:1.4}.modal-body .actions,.modal-actions{display:flex;align-items:center;justify-content:flex-end;gap:8px;flex-wrap:wrap;margin-top:20px}.modal-body .checkbox-label,.modal-body label:has(input[type=checkbox]){flex-direction:row;align-items:center;gap:10px;padding:9px 0}.modal-body .checklist,.modal-body .room-checklist{list-style:none;padding:0;margin:0;display:grid;gap:7px}.modal-body .checklist li,.modal-body .room-checklist li{padding:9px 12px;border-radius:10px;background:#f2f7f8;font-size:.875rem;display:flex;align-items:center;gap:9px}.modal-body .checklist .complete,.modal-body .checklist .done{color:#17704c;background:#eaf7ef}.modal-body .checklist .missing{color:#a7522b;background:#fff4e8}.modal-body table{width:100%;border-collapse:collapse;font-size:.875rem}.modal-body th,.modal-body td{text-align:left;padding:10px 8px;border-bottom:1px solid var(--line)}.modal-body th{font-weight:650;color:var(--muted)}.modal-body canvas,.modal-body img.qr{max-width:100%;height:auto;margin:0 auto;display:block}.modal-body .room-code{text-align:center;margin:10px 0}.modal-body .hint,.modal-body small{font-size:.8125rem;line-height:1.45;color:var(--muted)}.modal-body .student-list{display:flex;flex-direction:column;gap:6px;max-height:42vh;overflow:auto}.modal-body .student-list button{justify-content:space-between;width:100%;text-align:left}.modal-body .control-row{display:flex;justify-content:space-between;align-items:center;gap:18px;padding:12px 0;border-bottom:1px solid var(--line)}.modal-body .control-row label{flex-direction:row;align-items:center}.modal-body kbd{display:inline-grid;place-items:center;min-width:27px;min-height:26px;margin:2px;padding:2px 7px;background:#f0f5f7;border:1px solid #c4d5dc;border-bottom-width:2px;border-radius:5px;color:var(--ink);font:500 .8125rem/1.2 Inter,Arial,sans-serif}.start-dialog{position:fixed;inset:0;width:440px;height:max-content;max-height:calc(100dvh - 32px);overflow:auto;margin:auto;border:1px solid #fff;box-shadow:0 0 0 100vmax #073a525c,0 25px 100px #08273d33;z-index:20;border-radius:28px}.start-dialog:not([open]){display:none}.start-accent{height:8px;background:linear-gradient(100deg,var(--ocean),var(--aqua) 50%,var(--coral) 80%,var(--gold))}.start-content{padding:25px 38px 26px;text-align:center}.start-brand{color:var(--ocean);font-weight:750;font-size:.875rem;letter-spacing:-.02em}.start-symbol{display:grid;place-items:center;margin:22px auto 15px;width:75px;height:75px;background:#e6f3f5;color:var(--ocean);border-radius:24px;transform:rotate(-5deg);border:1px solid #cce6eb}.start-symbol svg{width:48px;height:48px;fill:none;stroke:currentColor;stroke-width:1.3;stroke-linecap:round;stroke-linejoin:round;transform:rotate(5deg)}.start-content h1{font-size:2.1rem;line-height:1.1;letter-spacing:-.055em;font-weight:800;margin:0 0 12px}.start-content>p{font-size:1rem;line-height:1.45;color:var(--muted);margin:0 0 25px}.start-actions{display:flex;flex-direction:column;gap:9px}.start-actions button{min-height:45px;border-radius:999px;font-size:.9375rem}.start-actions .primary{box-shadow:0 4px 10px #075a8212}.join-button{width:100%;margin-top:11px;border:0;min-height:40px;border-radius:999px;font-size:.875rem;color:var(--ocean)}.start-signin{display:flex;align-items:center;justify-content:center;gap:3px;border-top:1px solid var(--line);margin-top:20px;padding-top:14px}.start-signin .text-button{font-size:.75rem;color:var(--muted);padding:7px 8px}.start-signin>span{width:1px;height:14px;background:var(--line)}
@media(min-width:1600px){.build-panel{width:284px;flex-basis:284px}.room-catalog{gap:10px;padding:14px}.room-catalog button{min-height:106px}.game-shell{padding:16px;gap:14px}.workspace{gap:14px}}
@media(max-width:1200px){.topbar{gap:10px;padding:9px 11px}.mode-tabs{margin-left:0}.mode-tabs button{padding:9px 12px}.games-link{display:none}.brand-subtitle{font-size:.6875rem}.brand-mark{width:36px;height:36px;border-radius:12px}.brand-mark svg{width:24px;height:24px}.header-actions{gap:2px}.header-actions .icon-button{width:34px;height:34px;min-height:34px}.build-panel{width:242px;flex-basis:242px}.room-catalog{gap:6px;padding:12px 10px}.palette-title{padding:16px 13px 12px}.build-tools{margin:0 10px 13px}.language-button span{display:none}.header-actions #teacher-open{max-width:100px;white-space:normal;font-size:.75rem}}
@media(max-width:930px){.game-shell{padding:8px;gap:8px}.workspace{gap:8px}.topbar{min-height:64px;border-radius:17px;gap:6px}.brand strong{font-size:1.05rem}.brand-subtitle{font-size:.625rem}.mode-tabs{padding:3px;gap:1px}.mode-tabs button{font-size:.8125rem;padding:8px 10px;min-height:36px;gap:5px}.mode-tabs svg{width:17px;height:17px}.header-actions #teacher-open{max-width:72px;font-size:.6875rem}.language-button{padding:7px 6px;font-size:.75rem}.brand{gap:6px}.build-panel{width:218px;flex-basis:218px;border-radius:17px}.viewport{border-radius:18px}.room-catalog button strong,.room-catalog .room-name{font-size:.9375rem}.build-tools button{font-size:.625rem}.readiness{padding:10px;font-size:.6875rem;gap:5px}.viewport-top,.viewport-bottom{left:11px;right:11px}.viewport-top{top:11px}.viewport-bottom{bottom:11px}}
@media(max-width:740px){.game-shell{padding:6px;gap:6px;min-height:290px}.topbar{padding:7px 9px;gap:6px;min-height:58px;flex-wrap:wrap;border-radius:15px}.brand{margin-right:auto}.brand-mark{width:32px;height:32px;border-radius:11px}.brand-mark svg{width:22px;height:22px}.brand strong{font-size:.9375rem}.brand-subtitle{font-size:.625rem}.header-actions{order:2;margin-left:0;gap:1px}.mode-tabs{order:3;width:100%;justify-content:center;padding:3px;background:#eef5f7}.mode-tabs button{flex:1;font-size:.8125rem;min-height:32px;padding:6px 9px}.header-actions #teacher-open{max-width:none;font-size:.6875rem;padding:5px}.header-actions .icon-button{width:31px;height:31px;min-height:31px;padding:6px}.header-actions .icon-button svg{width:18px;height:18px}.workspace{flex-direction:column;gap:6px}.viewport{order:1;flex:1;min-height:150px;border-radius:15px}.build-panel{order:2;flex:0 0 169px;width:100%;display:grid;grid-template-columns:140px minmax(0,1fr);grid-template-rows:39px minmax(0,1fr) 28px;border-radius:15px}.palette-title{grid-row:1;grid-column:1;display:block;padding:9px 10px}.palette-title h1{font-size:.8125rem}.save-status{font-size:.5625rem;padding:2px 0 0;display:block;text-align:left;max-width:none}.build-tools{grid-column:1;grid-row:2;margin:4px 9px 7px;display:grid;grid-template-columns:1fr 1fr;grid-template-rows:1fr 1fr;gap:4px}.build-tools button{min-height:0;padding:5px 2px;gap:3px;font-size:.5625rem;border-radius:9px;flex-direction:row}.build-tools svg{width:17px;height:17px}.catalog-tabs{grid-row:1;grid-column:2;margin:0 9px 0 3px;align-self:end;max-width:240px}.catalog-tabs button{min-height:33px;padding:6px;font-size:.75rem}.room-catalog{grid-row:2 / 4;grid-column:2;display:flex;gap:7px;overflow-x:auto;overflow-y:hidden;align-items:stretch;padding:9px 9px 9px 3px;scroll-snap-type:x proximity}.room-catalog button,.room-card{flex:0 0 94px;min-height:0;width:94px;scroll-snap-align:start;justify-content:center;gap:5px;padding:7px 5px}.room-catalog button strong,.room-catalog .room-name{font-size:.875rem}.room-catalog button small{font-size:.625rem}.room-catalog img,.room-catalog canvas{height:42px}.readiness{grid-row:3;grid-column:1;min-height:0;padding:3px 8px;font-size:.625rem;border-top:0;gap:4px;border-radius:0 0 0 15px}.readiness svg{width:14px;height:14px}.readiness .count{font-size:.5625rem}.viewport-top{top:9px;left:9px;right:9px}.viewport-bottom{bottom:9px;left:9px;right:9px}.activity-label{font-size:.6875rem;padding:7px 11px}.view-toggles button{height:32px;min-height:32px;padding:6px}.view-toggles .icon-button{width:32px}.view-toggles button span{font-size:.75rem}.camera-tools{padding:2px;border-radius:12px;gap:0}.camera-tools button{width:29px;height:29px;min-height:29px;padding:5px}.camera-tools svg{width:16px;height:16px}.help-button{width:33px;height:33px;min-height:33px;padding:6px}.camera-tools .tool-divider{height:17px;margin:0 2px}.empty-state{padding:16px 19px;gap:9px;border-radius:16px}.empty-state strong{font-size:.8125rem}.empty-icon{width:37px;height:37px;border-radius:12px}.empty-icon svg{width:26px;height:26px}.floating-panel{padding:12px;border-radius:14px}.walk-hud{top:51px;left:9px;max-width:218px}.destination strong,#target-name{font-size:1.35rem}.destination .eyebrow{font-size:.625rem}.hud-actions{margin-top:9px;gap:4px}.hud-actions button{font-size:.6875rem;min-height:29px;padding:6px 8px}.host-hud{top:51px;left:9px;min-width:190px;max-width:230px}.room-code{font-size:1.4rem}.host-target{font-size:1.2rem;margin:10px 0}.host-hud .eyebrow,.pair-status{font-size:.6875rem}.pair-heading .icon-button{width:27px;height:27px;min-height:27px;padding:4px}.touch-controls{bottom:55px;left:12px;right:12px}.direction-pad{grid-template-columns:repeat(3,39px);grid-template-rows:repeat(2,39px);gap:3px}.direction-pad button{width:39px;height:39px;min-height:39px;border-radius:11px}.run-button{width:55px;height:55px;font-size:.8125rem}.toast{top:50px;padding:9px 13px;font-size:.8125rem}.start-content{padding:20px 28px 19px}.start-symbol{width:62px;height:62px;margin:17px auto 13px;border-radius:20px}.start-symbol svg{width:40px;height:40px}.start-content h1{font-size:1.85rem}.start-content>p{font-size:.9375rem;margin-bottom:20px}.start-signin{margin-top:15px;padding-top:10px}.modal-header{padding:15px 18px 12px}.modal-body{padding:18px;font-size:.875rem}.modal{max-height:calc(100dvh - 24px)}.modal-header h2{font-size:1.05rem}}
@media(max-width:430px){.brand-subtitle{display:none}.brand-mark{width:29px;height:29px;border-radius:10px}.header-actions #teacher-open{max-width:65px;white-space:normal;font-size:.625rem}.header-actions .language-button{font-size:.6875rem}.build-panel{grid-template-columns:123px minmax(0,1fr);flex-basis:156px}.build-tools{margin-left:6px;margin-right:6px}.build-tools button{font-size:.5rem;gap:2px}.build-tools svg{width:15px;height:15px}.palette-title{padding-left:9px}.room-catalog button{flex-basis:86px;width:86px}.readiness .count{display:none}.mode-tabs button{font-size:.75rem;padding:6px}.mode-tabs svg{width:16px;height:16px}.start-content{padding-inline:23px}.start-dialog{max-width:calc(100vw - 24px)}.start-content h1{font-size:1.8rem}.start-signin .text-button{font-size:.6875rem;padding:7px 6px}.walk-hud{max-width:195px}.hud-actions{gap:3px}}
@media(max-height:620px) and (min-width:741px){.game-shell{padding:7px;gap:7px}.topbar{min-height:60px;padding-block:6px}.workspace{gap:7px}.palette-title{padding-top:12px;padding-bottom:9px}.build-tools{margin-bottom:9px}.build-tools button{min-height:45px;padding:5px 1px;gap:3px}.start-content{padding-top:17px;padding-bottom:17px}.start-symbol{margin:12px auto 11px;width:52px;height:52px;border-radius:17px}.start-symbol svg{width:34px;height:34px}.start-content h1{font-size:1.8rem;margin-bottom:9px}.start-content>p{font-size:.875rem;margin-bottom:16px}.start-actions button{min-height:39px}.join-button{margin-top:6px;min-height:34px}.start-signin{margin-top:11px;padding-top:8px}}
@media(max-height:520px) and (max-width:740px){.topbar{flex-wrap:nowrap;min-height:48px}.brand-subtitle,.brand strong,.header-actions .language-button,.games-link{display:none}.mode-tabs{order:1;width:auto;background:transparent;flex:1;padding:0}.header-actions{order:2}.mode-tabs button{min-height:32px;padding:5px 7px;font-size:.6875rem}.mode-tabs svg{width:16px}.brand{margin-right:0}.workspace{flex-direction:row}.build-panel{order:0;flex:0 0 195px;width:195px;display:flex;flex-direction:column}.palette-title{display:flex;padding:10px 11px}.build-tools{display:grid;grid-template-columns:repeat(4,1fr);grid-template-rows:auto;margin:0 8px 7px}.build-tools button{flex-direction:column;font-size:.5rem;padding:5px 1px;gap:3px;min-height:39px}.catalog-tabs{margin:0 8px;max-width:none;align-self:auto;flex-shrink:0}.catalog-tabs button{min-height:27px;font-size:.6875rem}.room-catalog{display:grid;grid-template-columns:1fr 1fr;overflow:auto;padding:8px;gap:6px}.room-catalog button{width:auto;min-height:75px;padding:6px 3px}.readiness{min-height:29px;border-top:1px solid var(--line);border-radius:0}.start-dialog{max-height:calc(100dvh - 16px);width:400px}.start-content{padding:12px 28px}.start-brand{font-size:.75rem}.start-symbol{display:none}.start-content h1{font-size:1.65rem;margin-top:12px}.start-content>p{font-size:.8125rem;margin-bottom:12px}.start-content>p br{display:none}.start-actions{flex-direction:row;flex-wrap:wrap;gap:6px}.start-actions button{flex:1;min-width:140px;min-height:35px;font-size:.8125rem}.join-button{margin-top:5px;min-height:31px;font-size:.75rem}.start-signin{margin-top:6px;padding-top:5px}.start-signin .text-button{min-height:28px}.walk-hud{top:48px}.host-hud{top:48px}.touch-controls{bottom:48px}}
@media(prefers-reduced-motion:reduce){*{transition:none!important;scroll-behavior:auto!important}}
@media print{html,body{height:auto;overflow:visible;background:white}.topbar,.build-panel,.viewport-top,.viewport-bottom,.walk-hud,.host-hud,.touch-controls,dialog,.toast,.empty-state{display:none!important}.game-shell,.workspace{display:block;height:auto;padding:0}.viewport{height:170mm;width:100%;border:0;box-shadow:none}.viewport canvas{width:100%;height:100%}}

/* The application supplies the catalogue, checklist, and classroom content. */
.account-button{width:auto;max-width:132px;min-width:38px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:.8125rem;padding:8px 10px;border-color:transparent}.palette-title{gap:6px;align-items:center}.palette-title .save-status{font-size:.6875rem;max-width:72px;line-height:1.25;padding-top:0}.undo-button{width:28px;height:28px;min-height:28px;padding:5px;border:0;color:var(--ocean);background:#edf5f6}.undo-button svg{width:16px;height:16px}.readiness.complete{background:#e8f7ef;color:#1e654e}.room-thumb{display:block;width:76px;max-width:100%;height:54px}.room-thumb svg{width:100%;height:100%;stroke:none;fill:initial}.room-card-text{font:400 1.05rem/1.15 var(--learn);display:flex;flex-direction:column;gap:5px;max-width:100%;overflow-wrap:anywhere}.room-card-text small{font:500 .6875rem/1.2 Inter,Arial,sans-serif;color:var(--muted)}.room-catalog .room-card{min-height:116px;justify-content:center;padding:9px 6px;gap:6px}.room-catalog .room-card:disabled{opacity:.55;background:#f2f6f6}.room-catalog .room-card.selected{border-color:var(--aqua);background:#e4f4f5;color:var(--deep)}.pair-heading .qr-button{font-size:.6875rem;min-height:30px;padding:6px 8px;border:0;border-radius:9px;background:#edf6f7;color:var(--ocean);white-space:nowrap}.touch-controls button.held{background:var(--ocean);color:#fff}.modal-body .action-row{display:flex;flex-wrap:wrap;gap:8px;margin-top:20px;align-items:center}.modal-body .action-row button,.modal-body .file-button{font-size:.8125rem;min-height:38px}.modal-body .file-button{display:inline-flex;align-items:center;justify-content:center;padding:8px 12px;border-radius:11px;background:#edf6f7;color:var(--ocean);border:1px solid #cee2e7;cursor:pointer;font-weight:600}.modal-body .learning{font:400 1.3rem/1.45 var(--learn);color:var(--deep)}.modal-body .help-grid h3:not(:first-child){margin-top:22px}.modal-body .checklist{display:flex;flex-direction:column;gap:4px}.modal-body .check-row{display:flex;gap:10px;align-items:center;padding:8px 9px;background:#f5f9fa;border-radius:9px;font-size:.875rem}.modal-body .check-row>small{margin-left:auto;color:var(--muted);font-size:.75rem;white-space:nowrap}.modal-body .check{width:22px;height:22px;display:grid;place-items:center;color:#21815d;background:#e4f4eb;border-radius:50%;font-size:.8125rem;font-weight:700;flex-shrink:0}.modal-body .check.missing{background:#faeddf;color:#a96e34}.modal-body .notice{border-radius:11px;background:#fff4e7;color:#936031;padding:11px 13px;margin:17px 0 0;font-size:.875rem}.modal-body .notice.success{background:#e9f7ef;color:#267151}.modal-body .teacher-intro{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:20px}.modal-body .teacher-intro a{font-size:.875rem;text-decoration:underline;text-underline-offset:3px}.modal-body .teacher-intro button{font-size:.8125rem}.modal-body .switch-list{margin:14px 0 11px;display:flex;flex-direction:column;border:1px solid var(--line);border-radius:13px;padding:0 13px}.modal-body label.switch-row{display:flex;flex-direction:row;align-items:center;justify-content:space-between;padding:12px 0;gap:15px;font-size:.875rem;border-bottom:1px solid var(--line);line-height:1.3}.modal-body label.switch-row:last-child{border-bottom:0}.modal-body .switch-row input[type=checkbox]{appearance:none;-webkit-appearance:none;flex:0 0 36px;width:36px;height:22px;border:1px solid #b9cdd6;border-radius:999px;background:#d7e2e8;position:relative;cursor:pointer;transition:background .15s}.modal-body .switch-row input:after{content:"";position:absolute;left:3px;top:3px;width:14px;height:14px;border-radius:50%;background:white;box-shadow:0 1px 3px #10273530;transition:transform .15s}.modal-body .switch-row input:checked{background:var(--ocean);border-color:var(--ocean)}.modal-body .switch-row input:checked:after{transform:translateX(14px)}#class-controls{margin-bottom:24px}#class-saved{font-size:.8125rem;color:#267151;padding-left:12px}.modal-body .student-row{display:flex;gap:12px;padding:10px 12px;font-weight:400}.modal-body .student-row>strong{display:grid;place-items:center;flex:0 0 27px;height:27px;border-radius:8px;background:#e5f1f4;color:var(--ocean);font-size:.75rem}.modal-body .student-row>span{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.modal-body .student-row>small{color:var(--ocean);font-size:.75rem}.pair-dialog{text-align:center}.pair-dialog canvas{background:white;border:1px solid var(--line);border-radius:16px;max-width:100%}.pair-dialog .large-code{display:block;font-size:2rem;font-weight:750;letter-spacing:.15em;line-height:1.2;color:var(--ocean);margin:18px 0 11px;font-variant-numeric:tabular-nums}.pair-dialog p{font-size:.875rem;max-width:300px;margin:0 auto 17px}.modal-body #login-error,.modal-body #join-error{color:#b82e42;font-size:.875rem;line-height:1.4;margin:0}.modal-body #join-form input{text-align:center;letter-spacing:.22em;font-size:1.6rem;font-weight:650}.build-tools button{font-size:.75rem}.readiness{font-size:.8125rem}.room-catalog button small{font-size:.75rem}
@media(max-width:1200px){.palette-title{padding-inline:11px}.palette-title h1{font-size:.9375rem}.palette-title .save-status{max-width:64px;font-size:.625rem}.account-button{max-width:105px;padding-inline:7px;font-size:.75rem}.build-tools button{font-size:.6875rem}.readiness{font-size:.75rem}}
@media(max-width:930px){.palette-title .save-status{max-width:50px;font-size:.625rem}.palette-title h1{font-size:.875rem}.undo-button{width:25px;height:25px;min-height:25px}.account-button{max-width:82px;font-size:.6875rem}.build-tools button{font-size:.625rem}.readiness{font-size:.6875rem}.room-card-text{font-size:1rem}.room-catalog button small{font-size:.6875rem}}
@media(max-width:740px){.palette-title{position:relative;display:block;padding-right:34px}.palette-title h1{font-size:.8125rem}.palette-title .save-status{max-width:none;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:.5625rem;padding-top:2px}.palette-title .undo-button{position:absolute;right:7px;top:9px;width:25px;height:25px;min-height:25px;padding:4px}.account-button{max-width:90px;min-width:34px;min-height:31px;padding:6px 7px;font-size:.75rem}.build-tools button{font-size:.6875rem;flex-direction:column;gap:2px;padding:3px}.room-catalog .room-card{min-height:0;gap:3px;padding:5px;flex-shrink:0}.room-thumb{width:62px;height:43px}.room-card-text{font-size:.9375rem;gap:3px}.room-catalog button small{font-size:.625rem}.readiness{font-size:.6255rem}.room-catalog .room-card.selected{padding:4px}.pair-heading .qr-button{font-size:.625rem;min-height:27px;padding:5px 6px}.modal-body .check-row{font-size:.8125rem;padding:7px 8px}.modal-body .switch-row{font-size:.8125rem}.pair-dialog .large-code{font-size:1.7rem}.modal-body .teacher-intro{gap:7px}.modal-body .teacher-intro a,.modal-body .teacher-intro button{font-size:.75rem}}
@media(max-width:430px){.account-button{max-width:74px;font-size:.6875rem}.palette-title h1{font-size:.75rem}.palette-title .save-status{font-size:.5rem}.palette-title .undo-button{right:5px}.build-tools button{font-size:.625rem}.room-card-text{font-size:.875rem}}
@media(max-height:520px) and (max-width:740px){.palette-title{display:flex;padding-right:36px}.palette-title .save-status{max-width:60px;font-size:.5625rem;white-space:normal}.build-tools button{font-size:.5625rem}.room-catalog .room-card{min-height:87px}.room-thumb{height:36px;width:51px}.room-card-text{font-size:.8125rem}.readiness{font-size:.625rem}}
