/**
 * Copyright (c) 2014 The xterm.js authors. All rights reserved.
 * Copyright (c) 2012-2013, Christopher Jeffrey (MIT License)
 * https://github.com/chjj/term.js
 * @license MIT
 *
 * Permission is hereby granted, free of charge, to any person obtaining a copy
 * of this software and associated documentation files (the "Software"), to deal
 * in the Software without restriction, including without limitation the rights
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
 * copies of the Software, and to permit persons to whom the Software is
 * furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 * THE SOFTWARE.
 *
 * Originally forked from (with the author's permission):
 *   Fabrice Bellard's javascript vt100 for jslinux:
 *   http://bellard.org/jslinux/
 *   Copyright (c) 2011 Fabrice Bellard
 *   The original design remains. The terminal itself
 *   has been extended to include xterm CSI codes, among
 *   other features.
 */.xterm{cursor:text;position:relative;user-select:none;-ms-user-select:none;-webkit-user-select:none}.xterm.focus,.xterm:focus{outline:none}.xterm .xterm-helpers{position:absolute;top:0;z-index:5}.xterm .xterm-helper-textarea{padding:0;border:0;margin:0;position:absolute;opacity:0;left:-9999em;top:0;width:0;height:0;z-index:-5;white-space:nowrap;overflow:hidden;resize:none}.xterm .composition-view{background:#000;color:#fff;display:none;position:absolute;white-space:nowrap;z-index:1}.xterm .composition-view.active{display:block}.xterm .xterm-viewport{background-color:#000;overflow-y:scroll;cursor:default;position:absolute;right:0;left:0;top:0;bottom:0}.xterm .xterm-screen{position:relative}.xterm .xterm-screen canvas{position:absolute;left:0;top:0}.xterm .xterm-scroll-area{visibility:hidden}.xterm-char-measure-element{display:inline-block;visibility:hidden;position:absolute;top:0;left:-9999em;line-height:normal}.xterm.enable-mouse-events{cursor:default}.xterm.xterm-cursor-pointer,.xterm .xterm-cursor-pointer{cursor:pointer}.xterm.column-select.focus{cursor:crosshair}.xterm .xterm-accessibility,.xterm .xterm-message{position:absolute;left:0;top:0;bottom:0;right:0;z-index:10;color:transparent;pointer-events:none}.xterm .live-region{position:absolute;left:-9999px;width:1px;height:1px;overflow:hidden}.xterm-dim{opacity:1!important}.xterm-underline-1{text-decoration:underline}.xterm-underline-2{text-decoration:double underline}.xterm-underline-3{text-decoration:wavy underline}.xterm-underline-4{text-decoration:dotted underline}.xterm-underline-5{text-decoration:dashed underline}.xterm-overline{text-decoration:overline}.xterm-overline.xterm-underline-1{text-decoration:overline underline}.xterm-overline.xterm-underline-2{text-decoration:overline double underline}.xterm-overline.xterm-underline-3{text-decoration:overline wavy underline}.xterm-overline.xterm-underline-4{text-decoration:overline dotted underline}.xterm-overline.xterm-underline-5{text-decoration:overline dashed underline}.xterm-strikethrough{text-decoration:line-through}.xterm-screen .xterm-decoration-container .xterm-decoration{z-index:6;position:absolute}.xterm-screen .xterm-decoration-container .xterm-decoration.xterm-decoration-top-layer{z-index:7}.xterm-decoration-overview-ruler{z-index:8;position:absolute;top:0;right:0;pointer-events:none}.xterm-decoration-top{z-index:2;position:relative}.connection-status[data-v-5e1fd1e7]{display:flex;align-items:center;gap:8px;padding:6px 12px;border-radius:20px;font-size:12px;font-weight:500}.status-dot[data-v-5e1fd1e7]{width:8px;height:8px;border-radius:50%;animation:pulse-5e1fd1e7 2s infinite}.connected[data-v-5e1fd1e7]{background:#00ff001a;color:#0f0}.connected .status-dot[data-v-5e1fd1e7]{background:#0f0;box-shadow:0 0 8px #0f0;animation:none}.connecting[data-v-5e1fd1e7]{background:#ffa5001a;color:orange}.connecting .status-dot[data-v-5e1fd1e7]{background:orange}.error[data-v-5e1fd1e7]{background:#ff00001a;color:#f44}.error .status-dot[data-v-5e1fd1e7]{background:#f44;animation:none}@keyframes pulse-5e1fd1e7{0%,to{opacity:1}50%{opacity:.5}}.screenshot-modal[data-v-7b59f0c8]{position:fixed;top:0;left:0;right:0;bottom:0;background:#000000e6;display:flex;justify-content:center;align-items:center;z-index:1000;animation:fadeIn-7b59f0c8 .2s ease}@keyframes fadeIn-7b59f0c8{0%{opacity:0}to{opacity:1}}.modal-content[data-v-7b59f0c8]{background:var(--bg-secondary);border-radius:12px;max-width:90vw;max-height:90vh;display:flex;flex-direction:column;overflow:hidden}.modal-header[data-v-7b59f0c8]{display:flex;justify-content:space-between;align-items:center;padding:16px 20px;border-bottom:1px solid var(--border)}.modal-header h3[data-v-7b59f0c8]{margin:0;font-size:16px}.close-btn[data-v-7b59f0c8]{width:32px;height:32px;display:flex;align-items:center;justify-content:center;background:transparent;color:var(--text-secondary);font-size:24px;border-radius:8px}.close-btn[data-v-7b59f0c8]:hover{background:#ffffff1a;color:var(--text-primary)}.modal-body[data-v-7b59f0c8]{flex:1;overflow:auto;padding:20px;display:flex;justify-content:center;align-items:center}.screenshot-image[data-v-7b59f0c8]{max-width:100%;max-height:60vh;border-radius:8px;box-shadow:0 4px 24px #0000004d}.modal-footer[data-v-7b59f0c8]{display:flex;justify-content:center;gap:12px;padding:16px 20px;border-top:1px solid var(--border)}.modal-footer .btn[data-v-7b59f0c8]{text-decoration:none}.keymap-editor[data-v-5087ccab]{position:absolute;top:0;right:0;bottom:0;left:0;z-index:1000;background:#0006;pointer-events:auto;overflow:hidden;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif}.editor-toolbar[data-v-5087ccab]{position:absolute;top:16px;left:50%;transform:translate(-50%);display:flex;align-items:center;gap:16px;background:#141414f2;-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);padding:10px 20px;border-radius:12px;border:1px solid rgba(255,255,255,.1);box-shadow:0 8px 32px #00000080;z-index:1001}.toolbar-title[data-v-5087ccab]{color:#fff;font-weight:600;font-size:14px}.toolbar-tools[data-v-5087ccab]{display:flex;gap:8px;border-left:1px solid rgba(255,255,255,.2);border-right:1px solid rgba(255,255,255,.2);padding:0 16px}.tool-btn[data-v-5087ccab]{background:#ffffff1a;border:1px solid rgba(255,255,255,.2);color:#fff;padding:6px 12px;border-radius:6px;font-size:13px;cursor:pointer;transition:all .2s}.tool-btn[data-v-5087ccab]:hover{background:#fff3}.toolbar-actions[data-v-5087ccab]{display:flex;gap:8px}.action-btn[data-v-5087ccab]{padding:6px 16px;border-radius:6px;font-size:13px;font-weight:600;cursor:pointer;border:none}.action-btn.cancel[data-v-5087ccab]{background:transparent;color:#ccc}.action-btn.cancel[data-v-5087ccab]:hover{color:#fff}.action-btn.save[data-v-5087ccab]{background:var(--accent, #007bff);color:#fff}.action-btn.save[data-v-5087ccab]:hover{filter:brightness(1.1)}.keymap-overlay[data-v-5087ccab]{position:absolute;top:0;right:0;bottom:0;left:0;z-index:1000}.video-area-indicator[data-v-5087ccab]{position:absolute;border:2px dashed rgba(255,255,255,.3);pointer-events:none}.key-node[data-v-5087ccab]{position:absolute;width:60px;height:60px;margin-left:-30px;margin-top:-30px;border-radius:50%;background:#fff3;border:2px solid rgba(255,255,255,.8);display:flex;align-items:center;justify-content:center;cursor:move;box-shadow:0 4px 12px #00000080;-webkit-user-select:none;user-select:none;touch-action:none}.key-node.is-joystick[data-v-5087ccab]{background:#64c8ff33;border-color:#64c8ffcc}.key-node.is-selected[data-v-5087ccab]{background:#ffc80066;border-color:#ffc107;z-index:10}.key-label[data-v-5087ccab]{color:#fff;font-size:24px;font-weight:700;text-shadow:0 2px 4px rgba(0,0,0,.8)}.joy-label[data-v-5087ccab]{color:#fff;font-size:14px;font-weight:700;text-shadow:0 2px 4px rgba(0,0,0,.8)}.delete-btn[data-v-5087ccab]{position:absolute;top:-10px;right:-10px;width:24px;height:24px;border-radius:50%;background:#dc3545;color:#fff;border:2px solid #fff;font-size:16px;display:flex;align-items:center;justify-content:center;cursor:pointer;z-index:11;padding:0;line-height:1}.joystick-radius[data-v-5087ccab]{position:absolute;border:2px dashed rgba(100,200,255,.5);border-radius:50%;pointer-events:none}.node-settings[data-v-5087ccab]{position:absolute;right:24px;top:80px;width:240px;background:#141414f2;-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);border:1px solid rgba(255,255,255,.1);border-radius:12px;padding:16px;z-index:1002;box-shadow:0 8px 32px #00000080}.node-settings h4[data-v-5087ccab]{margin:0 0 12px;color:#fff;font-size:15px}.setting-item[data-v-5087ccab]{display:flex;align-items:center;gap:12px;margin-bottom:12px}.setting-item label[data-v-5087ccab]{color:#aaa;font-size:13px;white-space:nowrap}.key-input[data-v-5087ccab]{flex:1;background:#00000080;border:1px solid #444;color:#fff;padding:8px;border-radius:6px;text-align:center;font-size:16px;font-weight:700;outline:none;cursor:pointer;text-transform:uppercase}.key-input[data-v-5087ccab]:focus{border-color:var(--accent, #007bff);box-shadow:0 0 0 2px #007bff4d}.setting-tip[data-v-5087ccab]{margin:0;font-size:11px;color:#888;text-align:center}.device-panel-view[data-v-b9481110]{height:100%;display:flex;flex-direction:row;background:#000;position:relative;overflow:hidden}.main-content[data-v-b9481110]{flex:1;display:flex;flex-direction:column;position:relative;min-width:0}.icon[data-v-b9481110]{width:20px;height:20px;stroke:currentColor;stroke-width:2;fill:none;stroke-linecap:round;stroke-linejoin:round}.fullscreen-fab[data-v-b9481110]{position:absolute;top:16px;right:16px;width:36px;height:36px;background:#00000080;-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);border:1px solid rgba(255,255,255,.1);border-radius:50%;color:#fff;display:flex;align-items:center;justify-content:center;cursor:pointer;z-index:100;transition:all .2s}.fullscreen-fab .icon[data-v-b9481110]{width:18px;height:18px}.fullscreen-fab[data-v-b9481110]:hover{background:#000c;transform:scale(1.1)}.stats-badge[data-v-b9481110]{position:absolute;top:16px;left:16px;background:#0009;-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);color:#0f0;font-family:Fira Code,Courier New,monospace;font-size:11px;font-weight:600;padding:4px 10px;border-radius:4px;z-index:100;pointer-events:none;white-space:nowrap}.stat-delimiter[data-v-b9481110]{color:#555;margin:0 2px}.stat-warn[data-v-b9481110]{color:#f85149}.video-wrapper[data-v-b9481110]{flex:1;background:#000;display:flex;align-items:center;justify-content:center;position:relative;overflow:hidden;min-height:0}.video-stream[data-v-b9481110]{width:100%;height:100%;object-fit:contain;touch-action:none}.panel-overlay[data-v-b9481110]{position:absolute;top:0;right:0;bottom:0;left:0;background:#000000d9;display:flex;align-items:center;justify-content:center;z-index:5}.overlay-box[data-v-b9481110]{text-align:center;padding:24px}.mini-spinner[data-v-b9481110]{width:24px;height:24px;border:2px solid rgba(255,255,255,.1);border-top-color:var(--accent);border-radius:50%;animation:spin-b9481110 .8s linear infinite;margin:0 auto 12px}@keyframes spin-b9481110{to{transform:rotate(360deg)}}.error-msg[data-v-b9481110]{color:var(--accent);font-weight:600}.error-tip[data-v-b9481110]{font-size:12px;color:#999;margin:8px 0 16px}.retry-btn[data-v-b9481110]{background:var(--accent);color:#fff;border:none;padding:6px 16px;border-radius:4px;font-size:12px;cursor:pointer}.control-sidebar[data-v-b9481110]{width:64px;background:#111;border-left:1px solid var(--border);display:flex;flex-direction:column;align-items:center;padding:16px 0;gap:12px;overflow-y:auto;z-index:10}.sidebar-group[data-v-b9481110]{display:flex;flex-direction:column;gap:12px;width:100%;align-items:center}.sidebar-btn[data-v-b9481110]{background:#222;border:1px solid #333;color:#ccc;width:48px;height:48px;border-radius:8px;display:flex;flex-direction:column;align-items:center;justify-content:center;cursor:pointer;transition:all .2s;padding:0}.sidebar-btn .icon[data-v-b9481110]{margin-bottom:2px}.sidebar-btn .btn-text[data-v-b9481110]{font-size:10px;white-space:nowrap}.sidebar-btn[data-v-b9481110]:hover{background:#333;border-color:var(--accent);color:#fff}.sidebar-btn.danger[data-v-b9481110]:hover{background:#f8514933;border-color:var(--error);color:var(--error)}.sidebar-btn.danger[data-v-b9481110]{color:#888}.sidebar-btn.add-btn[data-v-b9481110]{border-style:dashed}.sidebar-divider[data-v-b9481110]{width:32px;height:1px;background:#333;margin:4px 0}.fab-overlay[data-v-b9481110]{position:fixed;top:0;right:0;bottom:0;left:0;z-index:99}.mobile-fab-container[data-v-b9481110]{position:fixed;z-index:100;width:56px;height:56px}.mobile-fab-main[data-v-b9481110]{position:absolute;top:0;left:0;width:56px;height:56px;border-radius:50%;background:var(--accent);color:#fff;border:none;box-shadow:0 4px 12px #00000080;cursor:grab;display:flex;align-items:center;justify-content:center;transition:background .2s,transform .2s;touch-action:none;z-index:2}.mobile-fab-main .icon[data-v-b9481110]{width:24px;height:24px}.mobile-fab-main[data-v-b9481110]:active{cursor:grabbing;transform:scale(.95)}.mobile-fab-main.active[data-v-b9481110]{background:#555}.mobile-fab-menu[data-v-b9481110]{position:absolute;bottom:68px;right:0;width:max-content;display:flex;flex-direction:column;gap:8px;background:#141414e6;-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);padding:12px;border-radius:12px;border:1px solid rgba(255,255,255,.1);opacity:0;pointer-events:none;transform:translateY(20px);transition:all .3s cubic-bezier(.175,.885,.32,1.275);box-shadow:0 8px 24px #00000080;max-height:60vh;overflow-y:auto;z-index:1}.mobile-fab-menu.align-left[data-v-b9481110]{right:auto;left:0}.mobile-fab-menu.align-top[data-v-b9481110]{bottom:auto;top:68px;transform:translateY(-20px)}.mobile-fab-menu.show[data-v-b9481110]{opacity:1;pointer-events:auto;transform:translateY(0)}.fab-item[data-v-b9481110]{background:#2a2a2a;border:1px solid #444;color:#eee;padding:10px 16px;border-radius:8px;font-size:14px;font-weight:500;cursor:pointer;text-align:left;white-space:nowrap;display:flex;align-items:center}.fab-item .icon[data-v-b9481110]{margin-right:8px;width:18px;height:18px}.fab-item[data-v-b9481110]:active{background:var(--accent)}.fab-item.danger[data-v-b9481110]{color:#f85149}.fab-item.add-btn[data-v-b9481110]{background:transparent;border-style:dashed;justify-content:center}.fab-divider[data-v-b9481110]{height:1px;background:#ffffff1a;margin:4px 0}.console-drawer[data-v-b9481110]{position:absolute;bottom:0;left:0;right:0;height:360px;background:#151515;border-top:2px solid var(--accent);display:flex;flex-direction:column;z-index:100;box-shadow:0 -10px 30px #0009}.console-header[data-v-b9481110]{background:#222;display:flex;justify-content:space-between;align-items:center;border-bottom:1px solid #333}.console-tabs[data-v-b9481110]{display:flex}.console-tabs button[data-v-b9481110]{background:none;border:none;color:#666;padding:12px 16px;font-size:12px;cursor:pointer;border-bottom:2px solid transparent}.console-tabs button.active[data-v-b9481110]{color:var(--accent);border-bottom-color:var(--accent);background:#ffffff0d}.close-console[data-v-b9481110]{background:none;border:none;color:#555;cursor:pointer;font-size:18px;padding-right:16px}.console-history[data-v-b9481110]{flex:1;overflow-y:auto;padding:16px;font-family:Fira Code,Courier New,monospace;font-size:12px;background:#0a0a0a}.console-empty[data-v-b9481110]{color:#444;text-align:center;margin-top:40px}.log-item[data-v-b9481110]{margin-bottom:12px}.log-cmd[data-v-b9481110]{color:var(--accent);opacity:.8;font-weight:700}.log-out[data-v-b9481110]{white-space:pre-wrap;word-break:break-all;margin:4px 0 0;color:#eee;line-height:1.4}.log-item.error .log-out[data-v-b9481110]{color:#f55}.log-item.success .log-out[data-v-b9481110]{color:#50fa7b}.console-shortcuts[data-v-b9481110]{display:flex;padding:8px;gap:8px;background:#1a1a1a;overflow-x:auto;border-top:1px solid #333}.console-shortcuts button[data-v-b9481110]{background:#252525;border:1px solid #333;color:#999;padding:4px 10px;border-radius:4px;font-size:10px;white-space:nowrap;cursor:pointer}.console-shortcuts.danger[data-v-b9481110]{border-top:none;padding-top:0;padding-bottom:8px}.console-shortcuts .quit-btn[data-v-b9481110]{color:#f85149;border-color:#f851494d}.console-shortcuts .quit-btn[data-v-b9481110]:hover{background:#f851491a;border-color:#f85149}.console-input-group[data-v-b9481110]{display:flex;padding:10px;gap:8px;background:#222}.cmd-input[data-v-b9481110]{flex:1;background:#000;border:1px solid #444;color:#fff;padding:8px 12px;border-radius:4px;outline:none}.cmd-input[data-v-b9481110]:focus{border-color:var(--accent)}.send-btn[data-v-b9481110]{background:var(--accent);color:#fff;border:none;padding:0 16px;border-radius:4px;font-weight:600;cursor:pointer}.adb-container[data-v-b9481110]{flex:1;background:#000;position:relative;overflow:hidden}.adb-placeholder[data-v-b9481110]{display:flex;flex-direction:column;align-items:center;justify-content:center;height:100%;color:#666;text-align:center;padding:20px}.adb-connect-btn[data-v-b9481110]{background:var(--accent);color:#fff;border:none;padding:10px 20px;border-radius:6px;margin-bottom:12px;cursor:pointer;font-weight:600}@media (max-width: 1024px){.device-panel-view.mobile-landscape[data-v-b9481110]{position:fixed;top:0;right:0;bottom:0;left:0;z-index:9999;background:#000}.device-panel-view.mobile-landscape .video-wrapper[data-v-b9481110]{position:absolute;top:0;right:0;bottom:0;left:0;z-index:1}.device-panel-view.mobile-landscape .video-stream[data-v-b9481110]{position:absolute;top:50%;left:50%;width:100vh;height:100vw;transform:translate(-50%,-50%) rotate(90deg);object-fit:contain}.device-panel-view.mobile-landscape .fullscreen-fab[data-v-b9481110]{z-index:101}.device-panel-view.mobile-landscape .console-drawer[data-v-b9481110]{position:fixed;bottom:60px;left:0;right:0;z-index:100}.device-panel-view.mobile-landscape .panel-overlay[data-v-b9481110]{z-index:50}}
