:root{font-family:"Trebuchet MS","Segoe UI",sans-serif;color:#f4ecff;background:#110d1c;--orange:#ffb365;--purple:#c3a0ff;--muted:#bcb0ce;--border:#493557;font-synthesis:none}*{box-sizing:border-box}body{margin:0;min-width:300px;background:radial-gradient(ellipse at 15% 0,#38234477,transparent 45%),radial-gradient(ellipse at 90% 80%,#45230f44,transparent 50%),#110d1c}button,select{font:inherit}button,a,select{touch-action:manipulation}button{cursor:pointer;color:inherit;background:#30243c;border:1px solid #60486e;border-radius:10px;font-weight:700;transition:background .15s,transform .15s}button:hover:not(:disabled){background:#453250;transform:translateY(-1px)}button:disabled{opacity:.4;cursor:default}button:focus-visible,select:focus-visible,a:focus-visible,summary:focus-visible{outline:3px solid var(--orange);outline-offset:3px}a{color:inherit;text-decoration:none}.app{max-width:1600px;margin:auto;padding:0 30px}.site-header{min-height:91px;display:flex;align-items:center;gap:24px;border-bottom:1px solid #493557}.school-brand{display:block;background:#e43433;padding:7px 11px;border-radius:12px;flex-shrink:0}.school-brand img{display:block;width:147px;height:auto}.brand{display:flex;align-items:center;gap:10px;font-size:25px;font-weight:800;letter-spacing:-.8px}.brand>img{filter:drop-shadow(0 0 9px #bd7bff55)}.brand b{color:var(--orange)}.brand small{display:block;font-size:9px;letter-spacing:1.8px;color:var(--muted);margin-top:5px}.utilities{margin-left:auto;display:flex;gap:8px;align-items:center}.utilities button,.utilities>a{min-height:42px;font-size:12px;padding:10px;background:transparent;border:1px solid #493557;border-radius:9px}.utilities>a{display:grid;place-items:center}.mission-bar{display:flex;justify-content:space-between;gap:24px;align-items:center;margin:23px 0 17px}.mission-bar>div{min-width:0}.eyebrow{font-size:10px;letter-spacing:1.8px;color:var(--orange);font-weight:700}h1{font-size:27px;letter-spacing:-.6px;margin:6px 0}#mission-hint{margin:0;color:var(--muted);font-size:13px;line-height:1.4}#missions{display:flex;flex-wrap:wrap;gap:6px;flex-shrink:0}#missions button{width:38px;height:40px;font-size:17px;border-color:#654774;background:#2a2034}#missions button[aria-current=true]{color:#25132e;background:var(--orange);border-color:#ffd2a3;box-shadow:0 0 18px #ffb36525}.mode-bar{display:flex;align-items:center;gap:20px;background:#21182b;border:1px solid var(--border);border-radius:14px;padding:10px 14px;margin-bottom:18px}.mode-switch{display:flex;gap:7px}.mode-switch button{min-width:125px;padding:8px 16px;font-size:15px;background:transparent}.mode-switch button span{display:block;font-size:10px;color:#c0afcf;font-weight:400;margin-top:3px}.mode-switch button[aria-pressed=true]{background:#553968;border-color:#b18ad2}.mode-switch button[data-mode=escape][aria-pressed=true]{background:#774216;border-color:var(--orange)}#mode-description{font-size:12px;color:var(--muted);max-width:360px;line-height:1.5}.clock{margin-left:auto;min-width:135px;display:flex;align-items:center;gap:12px;justify-content:flex-end}.clock>span{font-size:9px;letter-spacing:1px;color:var(--muted);max-width:70px}.clock strong{font-size:30px;font-variant-numeric:tabular-nums;color:#ffcf8b;white-space:nowrap}.clock.urgent strong{color:#ff9b94}.workspace{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);gap:20px;align-items:start}.maze-panel{padding:16px 20px;background:linear-gradient(150deg,#281c35,#191322);border:1px solid #574068;border-radius:21px;min-width:0}.board-top{display:flex;align-items:center;justify-content:space-between;margin-bottom:12px;gap:10px;font-size:11px;letter-spacing:1px;color:#c9b4de}.board-top b{color:#87efb9;font-size:17px}#turn{font-variant-numeric:tabular-nums;white-space:nowrap;color:var(--orange);letter-spacing:0;font-size:12px}.board{display:grid;grid-template-columns:repeat(13,minmax(0,1fr));grid-template-rows:repeat(11,minmax(0,1fr));width:100%;aspect-ratio:13/11;gap:3px;padding:5px;background:#09070e;border:1px solid #5e4673;border-radius:13px;overflow:hidden}.cell{position:relative;min-width:0;min-height:0;border-radius:3px;display:grid;place-items:center}.wall{background:linear-gradient(130deg,#3b2f49,#251c31);box-shadow:inset 0 2px #68537366,inset 0 -3px #0a071555;background-image:linear-gradient(0deg,#17101f 1px,transparent 1px),linear-gradient(90deg,#17101f 1px,transparent 1px),linear-gradient(130deg,#3b2f49,#251c31);background-size:100% 50%,50% 100%,100% 100%}.floor{background:#c9c0d7}.floor:nth-child(even){background:#bdb3cd}.ghost-zone{outline:2px dotted #8453b6;outline-offset:-3px;background:#c9b0e5!important}.creature{position:absolute;width:84%;height:84%;object-fit:contain;z-index:3;filter:drop-shadow(0 2px 2px #25123566)}.ghost{animation:ghost-float 2.6s ease-in-out infinite}.spider{animation:spider-step .25s ease-out}.web{position:absolute;inset:0;width:100%;height:100%;filter:drop-shadow(0 1px 1px #1e0d3299);z-index:1;background:#53415b66;border-radius:3px}.web-cost{position:absolute;bottom:1px;right:2px;z-index:2;font-size:clamp(8px,1vw,11px);font-weight:800;background:#3c2559;color:#fff;min-width:13px;text-align:center;border-radius:3px;line-height:1.2}.next-marker{display:block;width:9px;height:9px;border:2px solid #b04d00;border-radius:50%;background:#ffad54;box-shadow:0 0 0 1px #ffdeaa}.cell>.next-marker{position:absolute;top:3px;left:3px;z-index:5;width:7px;height:7px;border-width:1px}.exit{background:#78c7a0!important;box-shadow:inset 0 0 0 2px #265b40}.exit-door{font-size:clamp(17px,2.5vw,35px);color:#173929;font-weight:900;line-height:1}.robot{display:block;position:absolute;width:83%;height:83%;z-index:6;transition:transform .25s;filter:drop-shadow(0 1px 2px #20112788)}.robot>img{display:block;width:100%;height:100%}.robot-arrow{position:absolute;top:-12%;left:38%;font-size:clamp(5px,.65vw,10px);color:#271238}.caught .robot{opacity:.55;filter:grayscale(.6);animation:absorb .6s ease-in-out}.escaped .robot{animation:celebrate .8s ease-in-out 2}.board-caption{display:flex;align-items:center;justify-content:space-between;font-size:11px;color:#d7c5e4;gap:10px;margin-top:12px}#web-status{color:#ffc285;text-align:right}.legend{display:flex;flex-wrap:wrap;gap:9px 16px;margin-top:15px}.legend>span{display:flex;gap:6px;align-items:center;font-size:10px;color:#c7bad6}.legend img{width:21px;height:21px;object-fit:contain}.maze-tip{font-size:10px;color:#a99bb9;line-height:1.5;margin:10px 0 0}.program-panel{border:1px solid #574068;border-radius:21px;background:#21192c;padding:19px;min-width:0}.panel-heading{display:flex;align-items:center;justify-content:space-between;gap:12px}h2{font-size:23px;margin:0;letter-spacing:-.5px}#count{font-size:12px;background:#3d2b4c;border:1px solid #614678;border-radius:20px;padding:6px 11px;color:#dec9f0;white-space:nowrap}.hint{font-size:11px;line-height:1.5;color:#beafce;margin:8px 0 11px}.program-meta{display:flex;justify-content:space-between;gap:10px;font-size:10px;color:#c4b1d6;margin:0 0 10px}.sequence{margin:0;padding:0;list-style:none;display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:6px}.sequence li{position:relative;height:46px;border:1px dashed #654d79;border-radius:8px;background:#1a1324;min-width:0}.sequence .number{position:absolute;top:3px;left:5px;font-size:8px;pointer-events:none;color:#b4a0c8;z-index:1}.sequence .filled{border:1px solid #aa83cc;background:#432d5c}.sequence .jump{background:#294354;border-color:#6ab5bc}.sequence .left{background:#5e421e;border-color:#ce9759}.sequence .right{background:#532d47;border-color:#ba80a3}.sequence .wait{background:#39462b;border-color:#91b46a}.card-button{display:flex;align-items:center;justify-content:center;gap:5px;border:0;width:100%;height:100%;min-width:0;padding:8px 3px 3px;background:transparent;font-size:23px}.card-button small{font-size:10px;align-self:flex-end;margin-bottom:3px}.card-button:hover:not(:disabled){background:#ffffff0d;transform:none}.card-button:disabled{opacity:1}.sequence li.chosen{outline:3px solid #ffb365;outline-offset:1px}.sequence li.active{box-shadow:0 0 0 3px #eee2ff}.sequence li.failed{border:2px dashed #ff958d;background:#6a2e3f}.status{min-height:61px;display:grid;place-items:center;text-align:center;font-size:12px;line-height:1.5;color:#e4d4f1;background:#30213e;border:1px solid #5d426e;border-radius:11px;padding:9px 12px;margin:14px 0 12px}.status.warning{background:#512735;border-color:#e69c78;color:#ffdecc}.status.success{background:#1e493b;border-color:#80cfa7;color:#e0ffef}.program-actions{display:grid;grid-template-columns:1fr .9fr 1.1fr;gap:7px}.program-actions button{min-height:43px;font-size:12px;padding:8px 4px}.primary{color:#291c20;background:var(--orange);border-color:#ffd7b2}.primary:hover:not(:disabled){background:#ffce95}.transport{display:flex;align-items:center;justify-content:space-between;gap:7px;margin:9px 0 16px}.transport button{font-size:10px;padding:7px 4px;min-height:36px;flex:1;background:transparent;border-color:#533b63}.builder{padding-top:12px;border-top:1px solid #513a60}.repeat-control{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:12px}.repeat-control label{font-size:14px;font-weight:700}.stepper{display:flex;gap:6px}.stepper button{width:35px;height:35px;font-size:18px}.stepper select{background:#342541;color:#f4ecff;border:1px solid #9471b0;border-radius:9px;padding:5px 10px;font-size:12px}.commands{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:7px}.commands button{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;min-height:61px;font-size:10px;padding:5px 2px;min-width:0;border-color:#9471b0}.commands button>b{font-size:24px;line-height:1}.commands [data-command=jump]{background:#294354;border-color:#6ab5bc}.commands [data-command=left]{background:#5e421e;border-color:#ce9759}.commands [data-command=right]{background:#532d47;border-color:#ba80a3}.commands [data-command=wait]{background:#39462b;border-color:#91b46a}.help{margin:18px 0 12px;padding:12px 17px;border:1px solid #493557;border-radius:12px;background:#21182b;color:#cdbfda;font-size:12px;line-height:1.7}.help summary{cursor:pointer;font-weight:700;color:#e4d5f0}.help-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:26px;margin-top:12px}.help h3{color:var(--orange);margin:8px 0}.help p{margin:8px 0}footer{display:flex;align-items:center;justify-content:space-between;gap:14px;color:#b4a1c1;font-size:10px;padding:10px 2px 18px}@keyframes ghost-float{50%{transform:translateY(-7%)}}@keyframes spider-step{from{transform:scale(.75)}to{transform:scale(1)}}@keyframes absorb{50%{transform:scale(.4) rotate(180deg);opacity:.1}}@keyframes celebrate{50%{filter:drop-shadow(0 0 5px #78fcb6);scale:1.1}}@media(min-width:1600px){.app{padding:0 40px}.sequence li{height:54px}.card-button{font-size:29px}.program-panel{padding:23px}.status{font-size:14px;min-height:70px}.commands button{min-height:68px;font-size:12px}.program-actions button{font-size:14px}.maze-panel{padding:20px 24px}.legend>span{font-size:11px}}@media(max-width:1100px){.app{padding:0 20px}.site-header{gap:15px}.school-brand img{width:120px}.brand{font-size:22px}.brand small{display:none}.brand>img{width:37px;height:37px}.utilities{gap:5px}.utilities button,.utilities>a{font-size:10px;padding:8px}.mission-bar{align-items:flex-start;flex-wrap:wrap;gap:12px}#missions button{width:40px;height:40px}.workspace{grid-template-columns:minmax(0,1.15fr) minmax(0,1fr);gap:14px}.maze-panel{padding:13px}.program-panel{padding:14px}h2{font-size:20px}.sequence li{height:41px}.card-button{font-size:20px;gap:2px}.card-button small{font-size:9px}.mode-bar{gap:12px}#mode-description{font-size:11px}.mode-switch button{min-width:110px;padding:8px 11px}.legend{gap:8px 10px}.legend>span{font-size:9px}.program-meta{font-size:9px}.transport button{font-size:9px}.commands{gap:4px}.commands button{font-size:9px}.program-actions button{font-size:11px}.status{font-size:11px}}@media(max-width:760px){.app{padding:0 14px}.site-header{flex-wrap:wrap;padding:13px 0;gap:12px}.school-brand{padding:6px 9px}.school-brand img{width:114px}.brand{margin-left:auto;font-size:20px;gap:5px}.brand>img{width:30px;height:30px}.brand b{display:block;font-size:16px;margin-top:2px}.utilities{width:100%;margin-left:0;justify-content:space-between}.utilities button,.utilities>a{font-size:11px;flex:1}.mission-bar{margin:19px 0 14px}h1{font-size:23px}.eyebrow{font-size:9px}#mission-hint{font-size:12px}#missions{gap:6px;width:100%}#missions button{width:calc((100% - 54px)/10);min-width:25px;height:37px;font-size:14px}.mode-bar{flex-wrap:wrap;padding:10px;gap:10px}.mode-switch{flex:1}.mode-switch button{min-width:0;flex:1;padding:8px 9px}.mode-switch button span{font-size:9px}.clock{min-width:103px;gap:6px}.clock>span{font-size:8px;max-width:54px}.clock strong{font-size:27px}#mode-description{order:3;max-width:none;width:100%;font-size:11px}.workspace{grid-template-columns:1fr}.board{gap:2px;padding:3px}.maze-panel{padding:12px}.board-top{font-size:10px}.board-caption{font-size:10px}.legend>span{font-size:10px}.legend img{width:20px;height:20px}.legend{gap:8px 12px}.robot-arrow{font-size:5px}.creature{width:92%;height:92%}.web-cost{font-size:8px;min-width:10px}.cell>.next-marker{width:5px;height:5px;top:2px;left:2px}.program-panel{padding:16px}.sequence li{height:45px}.card-button{font-size:24px}.status{font-size:12px;min-height:65px}.program-meta{font-size:10px}.commands button{min-height:62px;font-size:10px}.program-actions button{min-height:46px;font-size:12px}.transport button{font-size:10px;min-height:42px}.repeat-control label{font-size:15px}.stepper button{width:40px;height:40px}.stepper select{font-size:13px}.help-grid{grid-template-columns:1fr;gap:8px}.help{font-size:12px}.next-marker{flex-shrink:0}footer{font-size:9px}}@media(prefers-reduced-motion:reduce){*,*:before,*:after{animation:none!important;transition:none!important;scroll-behavior:auto!important}}
