:root{--bg: #131416;--grid-dot: #2b2e33;--surface: #1e2024;--surface-2: #272a2f;--border: #35393f;--border-strong: #4a4f57;--text: #e8e9eb;--text-muted: #8b919b;--accent: #00ff88;--danger: #ff4d4f;--shadow: rgba(0, 0, 0, .45);--font: ui-monospace, "SF Mono", Menlo, Consolas, "Courier New", monospace;--node-width: 200px;--header-height: 36px;--port-row-height: 24px;--param-row-height: 40px;--node-padding-bottom: 8px}*{box-sizing:border-box}html,body{margin:0;padding:0}body{font-family:var(--font);font-size:13px;line-height:1.4;background:var(--bg);color:var(--text)}button{font-family:inherit;font-size:12px;color:var(--text);background:var(--surface-2);border:1px solid var(--border);border-radius:6px;padding:6px 10px;cursor:pointer;transition:background .15s ease,border-color .15s ease,transform .1s ease}button:hover{background:#30343a;border-color:var(--border-strong)}button:active{transform:translateY(1px)}select{font-family:inherit;font-size:11px;color:var(--text);background:var(--surface-2);border:1px solid var(--border);border-radius:4px;padding:2px 4px}.Board{position:relative;z-index:1}.BoardCanvas{position:absolute;top:0;left:0;background-image:radial-gradient(circle,var(--grid-dot) 1px,transparent 1px);background-size:24px 24px}.BoardCanvas>svg{position:absolute;z-index:2;left:0;top:0;width:100%;height:100%;pointer-events:none}.Board_patching{cursor:crosshair}.DraggableNode{position:absolute;z-index:3;cursor:grab}.DraggableNode:active{cursor:grabbing}.DraggableNode_content{transition:transform .15s ease}.DraggableNode:hover .DraggableNode_content{transform:scale(1.01)}.ModuleCard{background:var(--surface);border:1px solid var(--border);border-radius:8px;box-shadow:0 4px 16px var(--shadow),0 1px 4px var(--shadow);padding-bottom:var(--node-padding-bottom);transition:box-shadow .2s ease,border-color .2s ease}.DraggableNode:hover .ModuleCard{box-shadow:0 8px 24px var(--shadow),0 2px 8px var(--shadow)}.DraggableNode_selected .ModuleCard{outline:2px solid var(--accent);outline-offset:1px}.ModuleCard_header{height:var(--header-height);display:flex;align-items:center;gap:8px;padding:0 10px 0 12px;border-bottom:1px solid var(--border);border-radius:8px 8px 0 0;background:linear-gradient(90deg,color-mix(in srgb,var(--module-color) 22%,transparent),transparent 70%);box-shadow:inset 4px 0 0 var(--module-color);user-select:none}.ModuleCard_kind{font-weight:700;font-size:12px;letter-spacing:.5px;text-transform:uppercase;color:var(--module-color)}.ModuleCard_id{flex:1;font-size:11px;color:var(--text-muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.Scope{display:block;border-radius:2px;background:#00000059;flex:none}.ModuleCard_delete{flex:none;width:18px;height:18px;padding:0;line-height:1;font-size:14px;border:none;border-radius:4px;background:transparent;color:var(--text-muted);opacity:0;transition:opacity .15s ease,color .15s ease}.DraggableNode:hover .ModuleCard_delete{opacity:1}.ModuleCard_delete:hover{color:var(--danger);background:transparent}.ModuleCard_ports{padding:0}.PortRow{position:relative;height:var(--port-row-height);display:flex;align-items:center;justify-content:space-between;padding:0 12px;font-size:11px;color:var(--text-muted);user-select:none}.PortRow_label_out{margin-left:auto}.Port{position:absolute;top:50%;width:14px;height:14px;margin-top:-7px;padding:0;border-radius:50%;border:2px solid var(--module-color);background:var(--surface);cursor:pointer;z-index:4;transition:transform .15s ease,background .15s ease,box-shadow .15s ease}.Port_in{left:-8px}.Port_out{right:-8px}.Port_connected{background:var(--module-color)}.Port:hover{transform:scale(1.3);background:var(--module-color)}.Port_active{background:var(--module-color);box-shadow:0 0 0 4px color-mix(in srgb,var(--module-color) 35%,transparent);animation:pulse 1s ease-in-out infinite}@keyframes pulse{0%,to{box-shadow:0 0 0 3px color-mix(in srgb,var(--module-color) 35%,transparent)}50%{box-shadow:0 0 0 7px color-mix(in srgb,var(--module-color) 15%,transparent)}}.ModuleCard_params{border-top:1px solid var(--border)}.ParamRow{height:var(--param-row-height);display:grid;grid-template-columns:56px 1fr 46px;align-items:center;gap:6px;padding:0 12px;font-size:11px;color:var(--text-muted);cursor:default}.ParamRow_label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.ParamRow_value{text-align:right;color:var(--text);font-variant-numeric:tabular-nums}.ParamRow input[type=range]{width:100%;margin:0;accent-color:var(--module-color);cursor:pointer}.ParamRow select{grid-column:2 / 4;width:100%}.Edge{--edge-color: var(--accent)}.Edge_line{stroke:var(--edge-color);stroke-width:2.5;stroke-linecap:round;fill:none;pointer-events:none;transition:stroke .15s ease-out,stroke-width .15s ease-out}.Edge_hit{stroke:transparent;stroke-width:14;fill:none;pointer-events:stroke;cursor:pointer}.Edge:hover .Edge_line{stroke:#fff;stroke-width:3.5}.Edge circle{fill:var(--edge-color)}.Edge_temp .Edge_line{stroke-dasharray:6 5;opacity:.8}.SelectionBox{position:absolute;left:0;top:0;width:100%;height:100%;z-index:1}.SelectionBox div{position:absolute;z-index:1;background-color:color-mix(in srgb,var(--accent) 10%,transparent);border:2px solid color-mix(in srgb,var(--accent) 40%,transparent);user-select:none;border-radius:4px}.ModulePicker{position:absolute;z-index:20;display:grid;grid-template-columns:1fr 1fr;gap:4px;padding:6px;background:var(--surface);border:1px solid var(--border);border-radius:8px;box-shadow:0 8px 24px var(--shadow),0 2px 8px var(--shadow)}.ModulePicker_item{text-align:left;padding:6px 10px;box-shadow:inset 3px 0 0 var(--module-color)}.ModulePicker_item:hover,.ModulePicker_item:focus-visible{background:color-mix(in srgb,var(--module-color) 25%,var(--surface-2));outline:none}.Toolbar{position:fixed;top:12px;left:12px;right:12px;z-index:50;display:flex;flex-wrap:wrap;align-items:center;gap:8px;pointer-events:none}.ToolbarGroup{display:flex;align-items:center;gap:6px;padding:6px 8px;background:var(--surface);border:1px solid var(--border);border-radius:12px;box-shadow:0 2px 12px var(--shadow),0 1px 3px var(--shadow);pointer-events:auto}.ToolbarGroup_modules{flex-wrap:wrap}.ToolbarGroup:last-child{margin-left:auto}.Logo{display:inline-flex;align-items:center;gap:8px;padding:0 6px 0 2px;font-weight:700;font-size:14px;letter-spacing:.3px;user-select:none}.Logo_mark{width:22px;height:22px;border-radius:6px;background:linear-gradient(135deg,var(--accent),#0ea5e9)}.PlayBtn{font-weight:700;background:var(--accent);border-color:var(--accent);color:#0c0d0f}.PlayBtn:hover{background:#33ffa0;border-color:#33ffa0}.PlayBtn_running{background:var(--danger);border-color:var(--danger);color:#fff}.PlayBtn_running:hover{background:#ff6b6d;border-color:#ff6b6d}.Status{font-size:11px;padding:4px 10px;border-radius:999px;border:1px solid var(--border);color:var(--text-muted);max-width:320px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.Status_success{border-color:var(--accent);color:var(--accent)}.Status_error{border-color:var(--danger);color:var(--danger)}.AddModuleBtn{padding:4px 8px;box-shadow:inset 3px 0 0 var(--module-color)}.AddModuleBtn:hover{background:color-mix(in srgb,var(--module-color) 25%,var(--surface-2))}.PresetSelect{font-size:12px;padding:5px 8px;border-radius:6px;cursor:pointer}.Toggle{display:inline-flex;align-items:center;gap:6px;font-size:12px;color:var(--text-muted);cursor:pointer;user-select:none}.Toggle input{accent-color:var(--accent);margin:0}.ZoomControls{position:fixed;bottom:12px;right:12px;z-index:50;display:flex;align-items:center;gap:2px;padding:4px;background:var(--surface);border:1px solid var(--border);border-radius:12px;box-shadow:0 2px 12px var(--shadow),0 1px 3px var(--shadow)}.ZoomBtn,.ZoomLevel{height:28px;padding:0 8px;background:transparent;border:none;border-radius:6px}.ZoomBtn{width:28px;font-size:16px;line-height:1}.ZoomLevel{min-width:48px;font-size:11px;color:var(--text-muted)}.ZoomBtn:hover,.ZoomLevel:hover{background:var(--surface-2)}
