:root{--bg:#dfe5e9;--panel:#e6ebee;--ink:#26343d;--muted:#7c8991;--accent:#16b8ae;--line:#7e8f9738;--key-size:42px;--gap:6px}*{box-sizing:border-box}html,body{min-height:100%}body{background:radial-gradient(circle at 12% 3%,#fff,transparent 25%),var(--bg);color:var(--ink);margin:0;font-family:Arial,Helvetica,sans-serif}button,input,select{font:inherit}button{-webkit-tap-highlight-color:transparent}.app-fit{--fit-scale:1;width:100%;height:calc(980px * var(--fit-scale));justify-content:center;display:flex;position:relative;overflow:hidden}main.app-canvas{width:1450px;min-width:1450px;min-height:980px;transform:scale(var(--fit-scale));transform-origin:top;margin:0;padding:14px 38px 34px;position:relative}.app-header{justify-content:space-between;align-items:center;margin:0 4px 14px;display:flex}.brand{align-items:center;gap:11px;display:flex}.brand>span,.mark{background:var(--accent);color:#fff;border-radius:11px;place-items:center;width:34px;height:34px;font-weight:900;display:grid;box-shadow:4px 5px 10px #0c847d47,-3px -3px 8px #fff}.brand div{flex-direction:column;display:flex}.brand b{letter-spacing:-.02em;font-size:17px}.brand small{color:var(--muted);letter-spacing:.15em;text-transform:uppercase;font-size:9px;font-weight:700}.connection{background:var(--panel);color:#63727a;border-radius:12px;align-items:center;gap:8px;padding:9px 12px;font-size:11px;font-weight:700;display:flex;box-shadow:4px 4px 9px #bbc3c7,-4px -4px 9px #fff}.connection i{background:var(--accent);border-radius:50%;width:8px;height:8px;box-shadow:0 0 0 4px #16b8ae1f}.toolbar{background:linear-gradient(145deg,#edf1f3,#d6dde0);border:1px solid #ffffffb3;border-radius:18px;align-items:stretch;margin-bottom:18px;padding:7px;display:flex;overflow-x:auto;box-shadow:10px 10px 24px #77848b40,-9px -9px 22px #fffc}.tool{color:#66747b;cursor:pointer;background:0 0;border:0;border-radius:11px;flex-direction:column;flex:0 0 73px;align-items:center;gap:4px;padding:8px 6px;display:flex}.tool:hover{color:#087e78;background:#ffffff59}.tool:active{box-shadow:inset 3px 3px 7px #c1c8cc,inset -3px -3px 7px #fff}.tool span{height:22px;color:var(--accent);font-size:22px;line-height:22px}.tool b{font-size:10px}.tool-separator{background:var(--line);flex:0 0 1px;margin:7px 3px}.tool-spacer{flex:1}.theme-toggle{color:#829097;cursor:pointer;-webkit-user-select:none;user-select:none;flex:0 0 38px;grid-template-rows:13px 30px 13px;align-self:center;place-items:center;margin:0 5px 0 1px;display:grid}.theme-toggle input{opacity:0;width:1px;height:1px;position:absolute}.theme-icon{font-size:12px;line-height:1;transition:color .2s,transform .2s}.theme-icon.sun{color:var(--accent)}.theme-icon.moon{font-size:14px}.theme-track{background:#d5dde0;border-radius:12px;width:18px;height:30px;padding:3px;position:relative;box-shadow:inset 2px 2px 5px #b7c0c4,inset -2px -2px 5px #fff}.theme-track i{background:#f5fafb;border-radius:50%;width:12px;height:12px;transition:transform .22s,background .22s;display:block;box-shadow:2px 2px 5px #aeb8bd,-1px -1px 3px #fff}.theme-toggle input:checked~.theme-track i{background:var(--accent);transform:translateY(12px);box-shadow:1px 2px 5px #056f698c}.theme-toggle input:checked~.moon{color:var(--accent);transform:scale(1.08)}.theme-toggle:has(input:checked) .sun{color:#77858c;transform:scale(.9)}.theme-toggle input:focus-visible~.theme-track{outline-offset:3px;outline:3px solid #16b8ae4d}.workspace-panel{grid-template-columns:245px 1fr;gap:20px;margin-bottom:18px;display:grid}.device-panel,.editor-panel,.keyboard-shell{background:linear-gradient(145deg,#edf1f3,#d7dde1);border:1px solid #ffffffb8;box-shadow:14px 14px 31px #7480874d,-13px -13px 30px #ffffffd1,inset 0 1px #fff}.device-panel{border-radius:22px;padding:18px}.panel-label{color:#6c7a81;letter-spacing:.12em;text-transform:uppercase;justify-content:space-between;align-items:center;margin-bottom:14px;font-size:10px;font-weight:800;display:flex}.segmented{background:#d8dfe2;border-radius:9px;padding:3px;display:flex;box-shadow:inset 2px 2px 5px #bdc5c9,inset -2px -2px 5px #fff}.segmented button{color:#7b888e;cursor:pointer;background:0 0;border:0;border-radius:6px;padding:5px 9px;font-size:10px}.segmented button.active{color:#087e78;background:#eef2f3;box-shadow:2px 2px 5px #bbc3c7,-2px -2px 5px #fff}.device-grid{background:#d8dfe2;border-radius:15px;gap:7px;padding:10px;display:grid;box-shadow:inset 4px 4px 9px #b9c1c5,inset -4px -4px 9px #fff}.device-grid.layout-24{grid-template-columns:repeat(4,1fr)}.device-grid.layout-48{grid-template-columns:repeat(8,1fr)}.device-grid button{aspect-ratio:1;color:#66747b;cursor:pointer;background:linear-gradient(145deg,#eef2f3,#cfd7da);border:0;border-radius:8px;min-width:0;position:relative;box-shadow:3px 3px 6px #b4bdc1,-3px -3px 6px #fff}.device-grid button span{opacity:0;font-size:9px}.device-grid button:hover span,.device-grid button.active span{opacity:1}.device-grid button.active{color:#087e78;background:#dce7e7;outline:2px solid #16b8ae80;box-shadow:inset 3px 3px 6px #b4bdc1,inset -3px -3px 6px #fff}.device-grid button.has-color{background:linear-gradient(145deg,color-mix(in srgb,var(--key-color) 42%,#f3f6f7),color-mix(in srgb,var(--key-color) 30%,#cbd4d8));box-shadow:3px 3px 7px color-mix(in srgb,var(--key-color) 18%,#aeb8bd),-3px -3px 7px #fff,inset 0 0 12px color-mix(in srgb,var(--key-color) 18%,transparent);color:color-mix(in srgb,var(--key-color) 65%,#183039)}.device-grid button.has-color.active{background:color-mix(in srgb,var(--key-color) 34%,#dce5e7);outline-color:var(--key-color);box-shadow:inset 3px 3px 7px color-mix(in srgb,var(--key-color) 22%,#aeb8bd),inset -3px -3px 7px #fff,0 0 10px color-mix(in srgb,var(--key-color) 36%,transparent)}.device-grid button i{background:var(--accent);border-radius:50%;width:5px;height:5px;position:absolute;bottom:5px;right:5px}.device-panel>p{color:#87939a;text-align:center;margin:13px 0 0;font-size:10px}.color-popover{z-index:50;background:linear-gradient(145deg,#eef2f3,#d5dcdf);border:1px solid #fffc;border-radius:17px;width:230px;padding:15px;position:absolute;box-shadow:13px 13px 27px #62707857,-9px -9px 22px #ffffffe6}.color-title{justify-content:space-between;align-items:flex-start;margin-bottom:13px;display:flex}.color-title>div{flex-direction:column;display:flex}.color-title b{font-size:13px}.color-title span{color:#839098;letter-spacing:.12em;text-transform:uppercase;font-size:9px;font-weight:700}.color-title>button{color:#738087;cursor:pointer;background:#e2e7e9;border:0;border-radius:8px;width:26px;height:26px;box-shadow:2px 2px 5px #bcc5c9,-2px -2px 5px #fff}.color-swatches{grid-template-columns:repeat(8,1fr);gap:6px;margin-bottom:13px;display:grid}.color-swatches button{aspect-ratio:1;cursor:pointer;border:2px solid #ffffffb8;border-radius:50%;box-shadow:2px 3px 5px #53606640}.color-swatches button.selected{outline-offset:2px;outline:2px solid #405158}.custom-color{color:#66747b;background:#dce3e6;border-radius:10px;justify-content:space-between;align-items:center;padding:9px 10px;font-size:10px;font-weight:700;display:flex;box-shadow:inset 2px 2px 5px #bcc4c8,inset -2px -2px 5px #fff}.custom-color input{cursor:pointer;background:0 0;border:0;border-radius:7px;width:40px;height:25px;padding:0}.reset-color{color:#7c898f;cursor:pointer;background:0 0;border:0;border-radius:9px;width:100%;margin-top:10px;padding:8px;font-size:9px;font-weight:700}.reset-color:hover{color:#d14d5c;background:#ffffff59}.editor-panel{border-radius:22px;min-width:0;padding:0 18px 15px}.level-tabs{gap:5px;margin-bottom:10px;display:flex}.level-tabs button{color:#738087;cursor:pointer;background:#d5dde0;border:0;border-radius:0 0 12px 12px;min-width:105px;padding:11px 18px;font-size:11px;font-weight:700}.level-tabs button.active{color:#087e78;background:#ecf0f2;box-shadow:4px 5px 9px #bdc5c9,-3px 0 8px #fff}.editor-title-row{justify-content:space-between;align-items:flex-end;gap:25px;margin-bottom:12px;display:flex}h1{letter-spacing:-.04em;margin:0;font-size:22px}h1 span{color:var(--accent);font-weight:400}.description{color:#6a787f;width:min(360px,45%);font-size:10px;font-weight:700}.description input,select{color:#405058;background:#dbe2e5;border:0;border-radius:9px;outline:none;width:100%;margin-top:5px;padding:9px 10px;box-shadow:inset 3px 3px 6px #bcc4c8,inset -3px -3px 6px #fff}.description input:focus,select:focus{box-shadow:inset 3px 3px 6px #bcc4c8,inset -3px -3px 6px #fff,0 0 0 3px #16b8ae33}.settings-row{color:#65747b;grid-template-columns:220px minmax(190px,1fr) 170px;align-items:end;gap:16px;margin-bottom:13px;font-size:10px;display:grid}.settings-row>label:not(.check){font-weight:700}.check{cursor:pointer;align-items:center;gap:8px;display:flex}.check input{opacity:0;position:absolute}.check span{background:#dce3e6;border-radius:5px;width:17px;height:17px;box-shadow:inset 2px 2px 4px #bcc4c8,inset -2px -2px 4px #fff}.check input:checked+span{background:var(--accent);box-shadow:inset 2px 2px 4px #0d8e87,inset -2px -2px 4px #35d3ca}.check input:checked+span:after{content:"✓";color:#fff;place-items:center;height:100%;font-size:11px;display:grid}.data-meter{grid-template-columns:1fr auto;gap:5px;display:grid}.data-meter span{font-weight:700}.data-meter b{color:#34434b}.data-meter em{color:#8a969c;font-style:normal;font-weight:400}.data-meter div{background:#cbd3d7;border-radius:7px;grid-column:1/-1;height:9px;overflow:hidden;box-shadow:inset 2px 2px 4px #adb7bc,inset -2px -2px 4px #fff}.data-meter i{border-radius:inherit;background:var(--accent);height:100%;transition:width .2s;display:block}.macro-grid{background:#d2dadd;border-radius:12px;grid-template-columns:repeat(8,minmax(72px,1fr));grid-auto-rows:34px;max-height:178px;padding:7px;display:grid;overflow:auto;box-shadow:inset 4px 4px 8px #b3bdc1,inset -4px -4px 8px #fff}.macro-grid button{color:#536269;text-overflow:ellipsis;white-space:nowrap;background:#f7f9f9b3;border:1px solid #89979e24;font-size:9px;overflow:hidden}.macro-grid button:disabled{cursor:default}.macro-grid button.filled{cursor:pointer}.macro-grid button.filled:hover{color:#087e78;background:#edf5f4}.macro-grid button.selected{z-index:1;color:#087e78;outline:2px solid var(--accent);background:#cce9e7;position:relative;box-shadow:inset 2px 2px 5px #a9c3c2}.macro-grid button.delay-cell{color:#8b6a20}.macro-actions{color:#66747b;justify-content:space-between;align-items:center;gap:15px;padding-top:11px;font-size:10px;display:flex}.macro-actions>div{gap:8px;display:flex}.macro-actions button,.delay-control button{color:#66747b;cursor:pointer;background:#e5eaec;border:0;border-radius:9px;padding:8px 13px;font-size:10px;font-weight:700;box-shadow:3px 3px 7px #bac3c7,-3px -3px 7px #fff}.macro-actions button:active,.delay-control button:active{box-shadow:inset 2px 2px 5px #bac3c7,inset -2px -2px 5px #fff}.macro-actions button:disabled{opacity:.4;cursor:default}.keyboard-shell{border-radius:24px;padding:18px}.keyboard-head{justify-content:flex-end;align-items:center;gap:18px;margin-bottom:15px;display:flex}.delay-control{color:#748188;align-items:center;gap:10px;font-size:10px;display:flex}.delay-control label{align-items:center;gap:8px;display:flex}.delay-control input{accent-color:var(--accent)}.delay-control b{color:#3e4e56;min-width:53px}.keyboard-viewport{scrollbar-color:#aeb9be transparent;padding:8px 5px 16px;overflow-x:auto}.keyboard{width:1074px;margin:auto}.keyboard-body{align-items:flex-start;gap:20px;margin-top:14px;display:flex}.key-group{gap:var(--gap);flex-direction:column;display:flex}.key-row{gap:var(--gap);height:var(--key-size);display:flex}.key,.key-spacer{width:calc(var(--key-size)*var(--key-width,1) + var(--gap)*(var(--key-width,1) - 1));min-width:calc(var(--key-size)*var(--key-width,1) + var(--gap)*(var(--key-width,1) - 1));height:var(--key-size)}.key{color:#4b5961;cursor:pointer;-webkit-user-select:none;user-select:none;background:linear-gradient(145deg,#f1f4f5,#d2dade);border:0;border-radius:9px;flex-direction:column;justify-content:center;align-items:center;gap:1px;font-size:9px;font-weight:700;line-height:1;transition:all 80ms;display:flex;box-shadow:4px 4px 8px #b6bfc3,-4px -4px 8px #fff,inset 0 0 0 1px #ffffff73}.key:hover{color:#087e78;transform:translateY(-1px)}.key:active,.key.is-active{color:#087e78;background:#d9e1e4;transform:translateY(1px);box-shadow:inset 3px 3px 7px #b4bdc1,inset -3px -3px 7px #fff}.keyboard-body>.key-group:first-child{flex:0 0 711px;width:711px}.keyboard-body>.key-group:nth-child(2){width:138px}.keyboard-body>.key-group:last-child{width:186px}.keyboard-body>.key-group:nth-child(2) .key-row:nth-child(3){margin-top:8px}@media (max-width:899px){.app-fit{height:auto;display:block;overflow:visible}.app-fit main.app-canvas{width:100%;min-width:0;min-height:100vh;padding:14px clamp(12px,3vw,38px) 34px;transform:none}.workspace-panel{grid-template-columns:1fr}.device-panel{grid-template-columns:1fr 2fr;align-items:center;gap:12px;display:grid}.device-panel .panel-label{grid-column:1/-1;margin:0}.device-grid.layout-24{grid-template-columns:repeat(8,1fr)}.device-panel>p{margin:0}.settings-row{grid-template-columns:1fr 1fr}.data-meter{grid-column:1/-1}.tool-spacer{display:none}}@media (max-width:600px){main{padding-inline-start:8px;padding-inline-end:8px}.app-header{padding:0 6px}.connection{display:none}.workspace-panel{gap:12px}.device-panel{display:block}.device-grid.layout-24{grid-template-columns:repeat(6,1fr)}.editor-panel{padding-inline-start:11px;padding-inline-end:11px}.editor-title-row{display:block}.description{width:100%;margin-top:10px;display:block}.settings-row{grid-template-columns:1fr}.data-meter{grid-column:auto}.macro-grid{grid-template-columns:repeat(4,minmax(74px,1fr))}.keyboard-shell{padding:12px 7px}.keyboard-head{padding:0 5px}.delay-control label{display:none}}@media (prefers-reduced-motion:reduce){*{scroll-behavior:auto!important;transition:none!important}}html[data-theme=dark]{--lightningcss-light: ;--lightningcss-dark:initial;color-scheme:dark;--bg:#171d21;--panel:#20272c;--ink:#e4ecef;--muted:#8f9da5;--line:#8ba0aa29}html[data-theme=dark] body{background:radial-gradient(circle at 12% 3%,#2a343a,#0000 28%),#171d21}html[data-theme=dark] .toolbar,html[data-theme=dark] .device-panel,html[data-theme=dark] .editor-panel,html[data-theme=dark] .keyboard-shell{background:linear-gradient(145deg,#252d32,#1b2226);border-color:#778f9926;box-shadow:14px 14px 31px #05080a8f,-10px -10px 25px #39454c47,inset 0 1px #ffffff0b}html[data-theme=dark] .tool{color:#93a0a7}html[data-theme=dark] .tool:hover{color:#35d0c6;background:#ffffff09}html[data-theme=dark] .tool:active{box-shadow:inset 3px 3px 7px #11171a,inset -3px -3px 7px #303a40}html[data-theme=dark] .panel-label,html[data-theme=dark] .device-panel>p,html[data-theme=dark] .description,html[data-theme=dark] .settings-row,html[data-theme=dark] .macro-actions,html[data-theme=dark] .delay-control{color:#89979e}html[data-theme=dark] .segmented,html[data-theme=dark] .device-grid{background:#171e22;box-shadow:inset 4px 4px 9px #0c1114,inset -4px -4px 9px #303940}html[data-theme=dark] .segmented button{color:#7e8c93}html[data-theme=dark] .segmented button.active{color:#37d1c7;background:#283137;box-shadow:2px 2px 5px #0e1417,-2px -2px 5px #354047}html[data-theme=dark] .device-grid button{color:#9eabb2;background:linear-gradient(145deg,#293238,#1b2226);box-shadow:3px 3px 7px #0d1215,-3px -3px 7px #333e44}html[data-theme=dark] .device-grid button.active{color:#3dd5cb;background:#1b292c;box-shadow:inset 3px 3px 7px #0c1416,inset -3px -3px 7px #304046}html[data-theme=dark] .device-grid button.has-color{color:color-mix(in srgb,var(--key-color) 78%,#d9e6e9);background:linear-gradient(145deg,color-mix(in srgb,var(--key-color) 34%,#293238),color-mix(in srgb,var(--key-color) 22%,#171e22));box-shadow:3px 3px 8px #0b1012,-3px -3px 8px #344047,inset 0 0 16px color-mix(in srgb,var(--key-color) 28%,transparent),0 0 9px color-mix(in srgb,var(--key-color) 18%,transparent)}html[data-theme=dark] .device-grid button.has-color.active{color:color-mix(in srgb,var(--key-color) 72%,white);background:color-mix(in srgb,var(--key-color) 28%,#192328);outline-color:var(--key-color);box-shadow:inset 3px 3px 8px color-mix(in srgb,var(--key-color) 14%,#071012),inset -3px -3px 8px color-mix(in srgb,var(--key-color) 20%,#334147),0 0 14px color-mix(in srgb,var(--key-color) 48%,transparent)}html[data-theme=dark] .level-tabs button{color:#7e8b92;background:#171e22}html[data-theme=dark] .level-tabs button.active{color:#3bd3c9;background:#273036;box-shadow:4px 5px 9px #0b1012,-3px 0 8px #354047}html[data-theme=dark] .description input,html[data-theme=dark] select{color:#d9e3e7;background:#171e22;box-shadow:inset 3px 3px 7px #0b1012,inset -3px -3px 7px #303a40}html[data-theme=dark] .check span{background:#1b2327;box-shadow:inset 2px 2px 4px #0b1013,inset -2px -2px 4px #303a40}html[data-theme=dark] .data-meter b{color:#d2dde1}html[data-theme=dark] .data-meter div{background:#12181b;box-shadow:inset 2px 2px 4px #090d0f,inset -2px -2px 4px #2b353a}html[data-theme=dark] .macro-grid{background:#151c20;box-shadow:inset 4px 4px 9px #090d0f,inset -4px -4px 9px #2d373d}html[data-theme=dark] .macro-grid button{color:#a5b1b7;background:#252e33b8;border-color:#7f949d1a}html[data-theme=dark] .macro-grid button.filled:hover{color:#42d8ce;background:#25363a}html[data-theme=dark] .macro-grid button.selected{color:#4be0d6;background:#173538;box-shadow:inset 2px 2px 5px #0a1b1d}html[data-theme=dark] .macro-actions button,html[data-theme=dark] .delay-control button{color:#a4b0b6;background:#242d32;box-shadow:3px 3px 7px #0d1215,-3px -3px 7px #354047}html[data-theme=dark] .macro-actions button:active,html[data-theme=dark] .delay-control button:active{box-shadow:inset 2px 2px 5px #0d1215,inset -2px -2px 5px #354047}html[data-theme=dark] .delay-control b{color:#d0dce0}html[data-theme=dark] .key{color:#aeb9be;background:linear-gradient(145deg,#293238,#1b2226);box-shadow:4px 4px 8px #0c1114,-4px -4px 8px #354047,inset 0 0 0 1px #ffffff06}html[data-theme=dark] .key:hover{color:#43d9cf}html[data-theme=dark] .key:active,html[data-theme=dark] .key.is-active{color:#45ddd3;background:#182529;box-shadow:inset 3px 3px 7px #091114,inset -3px -3px 7px #304047}html[data-theme=dark] .theme-track{background:#151c20;box-shadow:inset 2px 2px 5px #090d0f,inset -2px -2px 5px #303a40}html[data-theme=dark] .theme-track i{background:#748188;box-shadow:1px 2px 4px #080c0e}html[data-theme=dark] .color-popover{background:linear-gradient(145deg,#283137,#1b2226);border-color:#869ca52e;box-shadow:13px 13px 27px #040708a6,-7px -7px 18px #37434a47}html[data-theme=dark] .color-title>button{color:#9ba8ae;background:#222b30;box-shadow:2px 2px 5px #0c1114,-2px -2px 5px #354047}html[data-theme=dark] .custom-color{color:#a6b2b7;background:#171e22;box-shadow:inset 2px 2px 5px #090d0f,inset -2px -2px 5px #303a40}
