*{box-sizing:border-box}html,body{height:100%;margin:0}body{display:flex;flex-direction:column;font-family:system-ui,-apple-system,Segoe UI,Roboto,sans-serif;background:#1e1e1e;color:#d4d4d4}header{position:sticky;top:0;z-index:30;display:flex;align-items:center;gap:10px;padding:8px 14px;flex-wrap:wrap;background:#252526;border-bottom:1px solid #3c3c3c}header h1{font-size:15px;margin:0 4px 0 0;color:#00979d;font-weight:700;white-space:nowrap}header .tag{font-size:11px;color:gray}#status{font-size:12px;color:#00979d}.palette{display:flex;gap:8px;flex-wrap:wrap}.catnav{display:flex;gap:6px;overflow-x:auto;padding:2px 0}.cat-tab{background:#333;color:#d4d4d4;border:1px solid #4a4a4a;border-radius:6px;padding:7px 12px;font-size:13px;cursor:pointer;white-space:nowrap}.cat-tab:hover{background:#3a3a3a}.cat-tab.active{background:#00979d;color:#fff;border-color:#00979d}.blockrow{display:flex;gap:8px;overflow-x:auto;padding:2px 0}.pal-btn{background:#2d2d2d;color:#e8e8e8;border:1px solid #3c3c3c;border-radius:6px;padding:7px 12px;font-size:13px;cursor:pointer;touch-action:manipulation;-webkit-user-select:none;user-select:none}.pal-btn:active{background:#00979d;color:#fff}.pal-btn.pin{border-left:3px solid #00979D}.topgrp{margin-left:auto;display:flex;align-items:center;gap:8px}#langSel,.tbtn{background:#2d2d2d;color:#e8e8e8;border:1px solid #3c3c3c;border-radius:6px;padding:6px 10px;font-size:13px;cursor:pointer}.tbtn.hl{border-color:#00979d;color:#a5f0f4}#container{flex:1;position:relative}#blocklyDiv{position:absolute;inset:0}aside{position:absolute;top:10px;right:10px;width:360px;max-width:74vw;background:#252526f5;border:1px solid #3c3c3c;border-radius:8px;padding:10px 12px;font-family:ui-monospace,Menlo,Consolas,monospace;font-size:12px;line-height:1.5;max-height:66vh;overflow:auto;z-index:20}aside h2{font-size:12px;margin:0 0 6px;color:#00979d;font-weight:600}aside pre{margin:0;white-space:pre-wrap;color:#9cdcfe}#codeEditor{height:45vh;min-height:200px}#codeEditor .cm-editor{height:100%}#codeEditor .cm-scroller{overflow:auto}#codeEditor .cm-block-hl{background:#00979d4d}.manual-banner{display:flex;align-items:center;gap:8px;justify-content:space-between;background:#e6662d26;border:1px solid #e7662d;color:#ffd9c2;border-radius:6px;padding:6px 10px;font-size:12px;margin-bottom:6px}.manual-banner button{background:#e7662d;color:#fff;border:0;border-radius:6px;padding:5px 10px;font-size:12px;cursor:pointer;font-weight:600}.hint{font-family:inherit;font-size:12px;color:#ccc;margin:6px 0 0}:focus-visible{outline:2px solid #00979D;outline-offset:2px}button:focus-visible,select:focus-visible,input:focus-visible{outline:2px solid #00979D;outline-offset:2px}.welcome{position:fixed;inset:0;z-index:12000;background:#141416eb;display:flex;align-items:center;justify-content:center;padding:20px}.welcome-card{background:#252526;border:1px solid #3c3c3c;border-radius:12px;max-width:420px;width:100%;padding:24px;text-align:center}.welcome-card h2{margin:0 0 8px;color:#00979d;font-size:20px}.welcome-card p{margin:0 0 18px;color:#b8b8b8;font-size:14px;line-height:1.5}.welcome-actions{display:flex;flex-direction:column;gap:10px}.welcome-btn{background:#2d2d2d;color:#e8e8e8;border:1px solid #3c3c3c;border-radius:8px;padding:12px 16px;font-size:14px;cursor:pointer;text-align:left}.welcome-btn:hover{border-color:#00979d;color:#a5f0f4}.acct-backdrop{position:fixed;inset:0;background:#0000008c;z-index:11000;display:flex;align-items:center;justify-content:center}.acct-card{background:#252526;border:1px solid #3c3c3c;border-radius:10px;width:400px;max-width:94vw;max-height:90vh;overflow:auto;color:#d4d4d4}.acct-wide{width:430px}.acct-ok{background:#4ec97a24;color:#8bd8a6;border:1px solid rgba(78,201,122,.3);border-radius:8px;padding:12px 14px;font-size:14px;font-weight:600}.acct-link{background:none;border:0;color:#4ec97a;cursor:pointer;font-size:12px;text-align:center;width:100%;padding:4px}.acct-link:hover{text-decoration:underline}.acct-forgot-title{font-size:15px;font-weight:600;color:#a5f0f4}.acct-role{color:#ffd166;font-size:12px}.acct-admin-bar{display:flex;justify-content:space-between;align-items:center;font-size:14px;font-weight:600;color:#ffd166}.acct-admin-list{display:flex;flex-direction:column;gap:6px;max-height:50vh;overflow:auto}.acct-admin-row{display:flex;justify-content:space-between;align-items:center;gap:8px;background:#1e1e1e;border:1px solid #3c3c3c;border-radius:8px;padding:8px 10px}.acct-admin-info{flex:1;font-size:13px;line-height:1.5}.acct-admin-actions{display:flex;flex-wrap:wrap;gap:4px}.acct-admin-act{padding:5px 8px;font-size:13px}.acct-admin-del:hover{background:#944040;color:#fff}.acct-head{display:flex;justify-content:space-between;align-items:center;padding:12px 16px;border-bottom:1px solid #3c3c3c;font-size:15px;font-weight:600;color:#a5f0f4}.acct-close{background:none;border:0;color:gray;font-size:22px;cursor:pointer;line-height:1}.acct-body{padding:14px 16px;display:flex;flex-direction:column;gap:10px}.acct-body label{font-size:12px;color:#a0a0a0}.acct-body input{background:#1e1e1e;border:1px solid #3c3c3c;color:#e8e8e8;border-radius:6px;padding:8px 10px;font-size:14px;width:100%}.acct-tabs{display:flex;gap:6px}.acct-tab{flex:1;background:#2d2d2d;color:#a0a0a0;border:1px solid #3c3c3c;border-radius:6px;padding:7px;cursor:pointer;font-size:13px}.acct-tab.active{background:#00979d;color:#fff;border-color:#00979d}.acct-btn{background:#2d2d2d;color:#e8e8e8;border:1px solid #3c3c3c;border-radius:6px;padding:9px 12px;cursor:pointer;font-size:13px}.acct-btn.acct-primary{background:#00878f;color:#fff;border-color:#00878f;font-weight:600}.acct-btn.acct-danger{background:#6b2d2d;color:#ffd7d7;border-color:#944040}.acct-btn:disabled{opacity:.5;cursor:not-allowed}.acct-row{display:flex;gap:8px}.acct-row .acct-btn{flex:1}.acct-err{color:#ff6b6b;font-size:12px;min-height:16px}.acct-pass-row{display:flex;gap:6px}.acct-pass-row input{flex:1}.acct-eye{background:none;border:0;color:gray;cursor:pointer;font-size:16px}.acct-meter{height:8px;background:#3c3c3c;border-radius:4px;overflow:hidden;margin-top:6px}.acct-meter-fill{height:100%;width:0;background:#ff6b6b;transition:width .2s}.acct-meter.weak .acct-meter-fill{width:25%;background:#ff6b6b}.acct-meter.good .acct-meter-fill{width:65%;background:#ffb55c}.acct-meter.strong .acct-meter-fill{width:100%;background:#4ec97a}.acct-strength-row{display:flex;gap:8px;font-size:12px}.acct-strength-time.time-bad{color:#ff6b6b}.acct-strength-time.time-ok{color:#ffb55c}.acct-strength-time.time-good{color:#4ec97a}.acct-breach{font-size:12px;padding:8px 10px;border-radius:6px}.acct-breach.ok{background:#4ec97a1f;color:#8bd8a6}.acct-breach.bad{background:#ff6b6b1f;color:#ffb0b0}.acct-breach.pending{color:#a0a0a0}.acct-gen{background:none;border:1px dashed #00979D;color:#00979d;border-radius:6px;padding:8px;cursor:pointer;font-size:13px;margin-bottom:10px}.acct-tip{font-size:12px;color:#a0a0a0;line-height:1.5}.acct-who{font-size:13px}.acct-program-list{display:flex;flex-direction:column;gap:6px}.acct-prog{display:flex;align-items:center;gap:8px;background:#1e1e1e;border:1px solid #3c3c3c;border-radius:6px;padding:6px 10px}.acct-prog-active{border-color:#00979d}.acct-prog-name{flex:1;cursor:pointer;font-size:13px}.acct-prog-btn{background:none;border:0;color:#a0a0a0;cursor:pointer;font-size:14px}.acct-prog-btn.acct-prog-del:hover{color:#ff6b6b}.acct-empty{color:gray;font-size:13px;padding:8px}.acct-hint{font-size:11px;color:gray}#compileBar{position:fixed;right:16px;bottom:16px;z-index:9999;display:flex;flex-direction:column;gap:6px;font-family:sans-serif;font-size:13px;align-items:flex-end}.compile-btn{padding:10px 16px;border:0;border-radius:8px;cursor:pointer;color:#fff;font-weight:700;font-size:14px}#compileBtn{background:#00878f}#flashBtn{background:#e7662d;display:none}#compileDl{color:#00979d;cursor:pointer;font-weight:600;display:none;text-decoration:underline;font-size:12px}#compileStatus{background:#0d3a3d;color:#d9f6f8;border:1px solid #00979D;padding:9px 12px;border-radius:8px;max-width:360px;display:none;white-space:pre-wrap;font-size:12px;text-align:left}#compileStatus.err{background:#3a0d0d;border-color:#ff6b6b;color:#ffd7d7}#compileStatus.warn{background:#3a2a0d;border-color:#ffb55c;color:#ffe9c9}.board-sel,.board-lab{font-family:inherit;font-size:12px}.board-lab{color:#9ee9ed;margin:0 4px 0 0}.board-sel{background:#223138;color:#e6eef0;border:1px solid #2f434b;border-radius:6px;padding:5px 6px;margin-right:8px;cursor:pointer;max-width:130px}#simPanelWrap{position:fixed;z-index:9500;background:#181a1c;border:1px solid #333;border-radius:10px;box-shadow:0 8px 30px #00000080;overflow:hidden;display:flex;flex-direction:column;min-width:320px;min-height:240px;max-width:none;max-height:none}#simPanelWrap.sim-max{inset:0!important;width:100vw!important;height:100vh!important;max-width:none!important;max-height:none!important;border-radius:0;border:0}.sim-win-bar{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:8px 10px;background:#202224;border-bottom:1px solid #333;cursor:grab;-webkit-user-select:none;user-select:none;touch-action:none}.sim-win-bar:active{cursor:grabbing}.sim-win-title{color:#9fd8db;font-weight:700;font-size:14px}.sim-win-actions{display:flex;gap:6px}.sim-win-btn{background:#2a2c30;color:#d4d4d4;border:1px solid #3c3c3c;border-radius:6px;width:30px;height:30px;cursor:pointer;font-size:13px;line-height:1}.sim-win-btn:hover{background:#3a3c40}#simPanel{display:flex;flex-direction:column;gap:8px;padding:10px;overflow-y:auto;flex:1}.sim-resize{position:absolute;right:0;bottom:0;width:18px;height:18px;cursor:nwse-resize;touch-action:none}.sim-resize:after{content:"";position:absolute;right:3px;bottom:3px;width:8px;height:8px;border-right:2px solid #555;border-bottom:2px solid #555}.sim-bar{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.sim-title{color:#9fd8db;font-weight:700;font-size:14px}.sim-mode{background:#252526;color:#d4d4d4;border:1px solid #3c3c3c;border-radius:6px;padding:6px 8px;font-size:12px}.sim-board{background:#202224;border-radius:10px;padding:4px}.sim-board-svg{width:100%;height:auto;display:block}.sim-btn{cursor:pointer}.sim-knob{cursor:ns-resize}.sim-status{color:#7fd;font-size:12px;flex-basis:100%}.sim-status.err{color:#ff8b8b}.sim-serial{background:#0d1216;border:1px solid #233a2d;border-radius:8px;margin-top:4px}.sim-serial-title{color:#8ec9a5;font-size:11px;padding:6px 10px;font-weight:700;display:flex;justify-content:space-between;align-items:center}.sim-serial-clear{cursor:pointer;font-weight:400;text-decoration:underline;color:#6aa;font-size:10px}.sim-serial-body{margin:0;padding:4px 10px 10px;min-height:40px;max-height:120px;overflow-y:auto;color:#b8f0cf;font-family:monospace;font-size:12px;white-space:pre-wrap}#simRun{background:#00878f}#simStop{background:#8f2d2d}.ex-panel{position:fixed;right:12px;top:12px;z-index:9500;width:420px;max-width:92vw;max-height:86vh;background:#202224;border:1px solid #3c3c3c;border-radius:12px;box-shadow:0 8px 30px #00000080;overflow:hidden;display:flex;flex-direction:column}.ex-bar{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:8px 10px;background:#202224;border-bottom:1px solid #333}.ex-title{color:#9fd8db;font-weight:700;font-size:14px}.ex-actions{display:flex;gap:6px}.ex-close{background:#2a2c30;color:#d4d4d4;border:1px solid #3c3c3c;border-radius:6px;width:30px;height:30px;cursor:pointer;font-size:13px;line-height:1}.ex-close:hover{background:#3a3c40}.ex-body{display:flex;flex-direction:column;gap:8px;padding:10px;overflow-y:auto;flex:1}.ex-themes{display:flex;flex-wrap:wrap;gap:6px}.ex-theme{background:#2a2c30;color:#d4d4d4;border:1px solid #3c3c3c;border-radius:16px;padding:6px 12px;font-size:13px;cursor:pointer}.ex-theme:hover,.ex-theme.on{border-color:#00979d;color:#a5f0f4}.ex-list{display:flex;flex-direction:column;gap:6px}.ex-item{background:#252526;color:#e8e8e8;border:1px solid #3c3c3c;border-radius:8px;padding:10px 12px;font-size:14px;cursor:pointer;text-align:left}.ex-item:hover{border-color:#00979d;color:#a5f0f4}.ex-detail{background:#1a1c1e;border:1px solid #00979D;border-radius:10px;padding:12px}.ex-detail h3{margin:0 0 6px;color:#a5f0f4;font-size:15px}.ex-detail p{margin:0 0 10px;color:#c8c8c8;font-size:13px;line-height:1.5}.ex-detail .ex-desc{color:#9fd8db;font-size:12px;margin-bottom:10px}.ex-load{background:#00878f;color:#fff;border:none;border-radius:8px;padding:10px 14px;font-size:14px;font-weight:600;cursor:pointer;width:100%}.ex-load:hover{background:#00979d}.ex-empty{color:#888;font-size:13px;text-align:center;padding:20px 0}@media(any-pointer:coarse){.pal-btn,.tbtn,.acct-btn,.cat-tab{min-height:44px;font-size:15px}header h1{font-size:18px}aside{width:100%;right:0;top:0;max-width:none;max-height:50vh;border-radius:0}.topgrp{order:3;width:100%}}#codeEditor .cm-tooltip{background:transparent;border:0;padding:0}.arduino-tip{background:#1e2124;border:1px solid #00979D;border-radius:10px;box-shadow:0 8px 24px #0000008c;padding:12px 14px;max-width:340px;font-family:system-ui,sans-serif}.arduino-tip-head{display:flex;align-items:baseline;gap:8px;flex-wrap:wrap;margin-bottom:6px}.arduino-tip-fn{font-family:ui-monospace,Menlo,Consolas,monospace;font-size:13px;font-weight:700;color:#a5f0f4}.arduino-tip-kind{font-size:11px;color:#00979d;font-weight:600;text-transform:uppercase;letter-spacing:.4px}.arduino-tip-fr{font-size:12.5px;color:#d4d4d4;line-height:1.55}.arduino-tip-ex{font-size:12px;color:#ffd9a8;margin-top:7px;line-height:1.5;background:#e68a2d1a;border-left:2px solid #e7662d;padding:5px 8px;border-radius:0 6px 6px 0}.arduino-tip-pins{margin-top:8px}.arduino-tip-pins svg{display:block;max-width:100%;height:auto}
