*{box-sizing:border-box}body{margin:0;background:#f4f7fc;color:#20314a;font-family:Tahoma,sans-serif}button,a{-webkit-tap-highlight-color:transparent}button{font-family:inherit;cursor:pointer}button:focus-visible,a:focus-visible{outline:3px solid #3867ee;outline-offset:4px}[hidden]{display:none!important}.web-top{max-width:1320px;margin:0 auto;padding:20px 28px;display:flex;align-items:center;justify-content:space-between;gap:16px}.web-top a{text-decoration:none;color:#23384f;display:flex;align-items:center;gap:16px}.web-top b{font-size:25px;color:#f07732}.web-top span{font-size:13px}.web-top button{padding:12px 20px;background:white;border:1px solid #d7e0ef;border-radius:16px;min-height:48px;color:#243b60}#catalog{max-width:1240px;margin:auto;padding:8px 24px 36px}.welcome{padding:34px 40px;background:#e8efff;border:1px solid #dbe5fb;border-radius:28px;margin:10px 0 28px}.welcome>span{color:#6253bc;font-weight:bold;font-size:14px}.welcome h1{font-size:clamp(30px,4vw,48px);line-height:1.35;margin:14px 0}.welcome em{font-style:normal;color:#3b66c4}.welcome p{margin:12px 0 20px}.welcome>div{font-size:13px;color:#596d87}.welcome i{padding:0 10px}.game-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:20px}.game-card{position:relative;text-align:left;background:white;border:1px solid #e0e7f2;border-radius:24px;padding:22px;color:#253851;box-shadow:0 6px 20px #22375c05;transition:transform .15s,border-color .15s}.game-card:hover{transform:translateY(-3px);border-color:#8aaaf0}.card-number{position:absolute;top:18px;left:18px;color:#6884aa;background:#edf3fc;border-radius:10px;padding:4px 10px;font-size:12px}.card-photo{height:145px;display:flex;align-items:center;justify-content:center;margin:8px 0 14px}.card-photo img{max-width:85%;height:100%;object-fit:contain}.game-card small{color:#5d76a0}.game-card h2{font-size:21px;margin:8px 0;line-height:1.5}.game-card p{font-size:14px;line-height:1.7;color:#6f7d92;min-height:46px}.card-start{display:flex;justify-content:space-between;padding:12px 16px;background:#edf3ff;color:#345ec2;border-radius:12px;font-weight:bold;font-size:14px}.web-note{font-size:13px;text-align:center;margin:26px 0;color:#6a7b93}#play{max-width:1440px;margin:auto;padding:0 20px 24px}#game-host{min-width:0}#game-host button{min-height:44px}#game-host svg{max-width:100%}@media(max-width:900px){.game-grid{grid-template-columns:repeat(2,1fr)}}@media(max-width:560px){.web-top{padding:16px}.web-top span{display:none}#catalog{padding:0 14px 24px}.welcome{padding:24px}.game-grid{grid-template-columns:1fr}.game-card{padding:20px}.card-photo{height:145px}#play{padding:0 8px 16px}.welcome>div{line-height:2}.web-top button{font-size:13px;padding:10px 12px}}@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important;transition:none!important}}
/* Standalone room entry, matching the original classroom. */
body.room-mode .web-top{display:none}#room{width:100%;max-width:none;margin:0;padding:0}#room .classroom-3d{margin:0;border:0;border-radius:0;height:100dvh;min-height:520px}#room .classroom-stage{height:100%;min-height:520px}#room .classroom-home{border:1px solid #deebf7;cursor:pointer;font:inherit;font-size:14px}#room .classroom-sensor-dock button{min-height:48px}#roomView{border:1px solid #d4e2f5;border-radius:15px;padding:12px 20px;background:white;color:#245484;min-height:48px;margin:12px 0}#room .classroom-sensor-detail{z-index:35}#room .classroom-loading{pointer-events:none}@media(max-width:600px){#room .classroom-title{max-width:180px}#room .classroom-home{font-size:12px;padding:12px}#room .classroom-sensor-detail strong{font-size:22px}#room .classroom-sensor-detail span,#room .classroom-sensor-detail small{font-size:15px}}
/* Larger touch controls for the light game only. */
#game-host .lightquest .lq-lamp{width:29%}
#game-host .lightquest .lq-lamp>button{width:100%;min-width:0;min-height:68px;padding:12px 8px;font-size:20px;line-height:1.35;white-space:normal;border:3px solid #769bc9;border-radius:18px;background:#edf4ff;color:#183c68;touch-action:manipulation;box-shadow:0 5px 0 #365e8b}
#game-host .lightquest .lq-lamp.on>button{background:#ffe28b;border-color:#c89226;color:#593b06;box-shadow:0 5px 0 #9a701e}
#game-host .lightquest .lq-window>button{min-height:72px;padding:12px 10px;font-size:21px;line-height:1.4;border:3px solid #c5902c;border-radius:18px;background:#fff0bb;color:#604309;touch-action:manipulation;box-shadow:0 5px 0 #ac812c}
#game-host .lightquest .lq-lamp>button:disabled,#game-host .lightquest .lq-window>button:disabled{opacity:.5;cursor:default}
#game-host .lightquest .lq-lamp>button:focus-visible,#game-host .lightquest .lq-window>button:focus-visible{outline:4px solid #265fce;outline-offset:4px}
@media(max-width:550px){#game-host .lightquest .lq-lamp>button{font-size:16px;min-height:64px;padding:10px 5px;margin-top:8px;border-radius:15px}#game-host .lightquest .lq-window>button{font-size:17px;min-height:68px;padding:10px 6px}#game-host .lightquest .lq-window{top:32%}#game-host .lightquest .lq-window>small{font-size:11px}}
/* Child-friendly touch targets across the standalone games. */
#game-host button{min-height:56px;min-width:56px;font-size:18px;line-height:1.4;touch-action:manipulation}
#game-host .sensor-game-tools{display:flex;flex-wrap:wrap;gap:10px}
#game-host .sensor-game-tools button,#game-host .sensor-game-sound{padding:12px 16px;border-radius:14px}
#game-host button:focus-visible{outline:4px solid #265fce;outline-offset:3px}
#game-host input[type=range]{height:56px;width:100%;cursor:pointer}
#game-host input[type=range]::-webkit-slider-thumb{width:32px;height:32px}
#game-host input[type=range]::-moz-range-thumb{width:32px;height:32px}
#game-host .cq-speeds{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
#game-host .cq-modes{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
#game-host .cq-modes button{font-size:16px;white-space:normal;min-width:0}
#game-host .cq-speeds button{font-size:18px;min-width:0}
#game-host .dq-speed{display:flex;flex-wrap:wrap;gap:8px}
#game-host .dq-speed button{min-width:56px;font-size:18px}
#game-host .dq-window>button,#game-host .dq-power{font-size:18px;white-space:normal}
#game-host .kq-heat,#game-host .fq-controls>div,#game-host .water-actions{gap:10px;flex-wrap:wrap}
#game-host .garden-tap-button,#game-host .garden-valve-button{font-size:18px;padding:12px 16px}
@media(max-width:600px){
 #game-host .cq-modes{grid-template-columns:1fr}
 #game-host .cq-ac{top:8%}
 #game-host .cq-fan{top:48%}
 #game-host .cq-window{width:43%}
 #game-host .cq-window button{font-size:16px}
 #game-host .dq-speed button{min-width:48px;min-height:56px;padding:6px}
 #game-host .dq-window>button,#game-host .dq-power{font-size:16px}
 #game-host header{flex-wrap:wrap;gap:12px}
 #game-host .flat-appliance b{white-space:normal;font-size:16px}
}
/* Mobile verification: keep scene controls inside the playable area. */
@media(max-width:600px){
 #game-host .cq-room{height:620px;min-height:620px;aspect-ratio:auto}
 #game-host .cq-fan{top:48%}
 #game-host .garden-world{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;padding:10px;overflow:visible;min-height:0}
 #game-host .garden-world>.garden-scene{position:relative;inset:auto;width:100%;height:auto;min-width:0;grid-column:1/-1}
 #game-host .garden-search-spot{position:relative;inset:auto;width:100%;height:130px}
 #game-host .garden-scene-tap,#game-host .garden-scene-valve{position:relative;inset:auto;width:100%;grid-column:1/-1}
 #game-host .garden-scene-tap button,#game-host .garden-scene-valve button{width:100%;min-height:60px}
 #game-host .garden-found button{min-width:0;width:100%;font-size:16px;padding:8px 3px}
}
@media(max-width:600px){
 #game-host .dq-scene{height:680px;min-height:680px;aspect-ratio:auto}
 #game-host .dq-purifier{top:20%}
}
/* Separate the two result actions, including their raised shadows. */
#game-host .dq-intro button{width:100%;max-width:100%;white-space:normal;min-height:56px}
#game-host .dq-intro button+button{margin-top:18px}
/* Shared result actions: separate raised buttons in all nine games. */
#game-host .sensor-game-return{display:block;width:100%;max-width:100%;min-height:56px;margin:16px 0 0;white-space:normal;box-sizing:border-box}
#game-host .sensor-game-return+button{display:block;width:100%;max-width:100%;min-height:56px;margin:18px 0 0;white-space:normal;box-sizing:border-box}
#game-host .water-success+button,#game-host .air-win+button{display:block;min-height:56px;margin-top:18px}
