/**
 * 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:not(.debug),.xterm .xterm-message{position:absolute;left:0;top:0;bottom:0;right:0;z-index:10;color:transparent;pointer-events:none}.xterm .xterm-accessibility-tree:not(.debug) *::selection{color:transparent}.xterm .xterm-accessibility-tree{-webkit-user-select:text;user-select:text;white-space:pre}.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}:root{font-family:Inter,ui-sans-serif,system-ui,sans-serif;color:#e7eaf0;background:#090b10;font-synthesis:none}*{box-sizing:border-box}body{margin:0;min-width:320px}button,input,textarea,select{font:inherit}button{cursor:pointer}.shell{display:grid;grid-template-columns:245px 1fr;min-height:100vh}aside{position:sticky;top:0;height:100vh;background:#0d1017;border-right:1px solid #202631;padding:22px 14px;display:flex;flex-direction:column}.brand{display:flex;align-items:center;gap:11px;padding:0 8px 24px}.brand-mark{width:42px;height:42px;border-radius:12px;background:linear-gradient(145deg,#19c37d,#087f5b);display:grid;place-items:center;color:#fff;box-shadow:0 8px 24px #19c37d30}.brand strong,.brand span{display:block}.brand span,.profile span{font-size:12px;color:#778195}nav{display:flex;flex-direction:column;gap:4px;flex:1}nav button{display:flex;align-items:center;gap:11px;background:none;border:0;color:#939bad;padding:10px 12px;border-radius:8px;text-align:left}nav button:hover,nav button.active{background:#192029;color:#f4f7fb}nav button.active{box-shadow:inset 3px 0 #19c37d}.profile{border-top:1px solid #202631;padding:15px 4px 0;display:flex;align-items:center;gap:9px}.avatar{width:34px;height:34px;border-radius:50%;background:#26313e;display:grid;place-items:center}.profile div:nth-child(2){flex:1}.profile strong{font-size:13px;display:block}.profile button,.card-head button,.actions button{background:none;border:0;color:#8d97a8;padding:7px;border-radius:6px}.content{padding:28px 34px;min-width:0;background:radial-gradient(circle at 90% 0,#15251f 0,transparent 24%),#090b10}.content>header{display:flex;align-items:center;justify-content:space-between;margin-bottom:26px}.content h1{font-size:25px;margin:0}.content header p{margin:5px 0 0;color:#737e90;font-size:13px}.status{font-size:12px;color:#9da6b4;display:flex;align-items:center;gap:8px}.status span{width:8px;height:8px;border-radius:50%;background:#19c37d;box-shadow:0 0 10px #19c37d}.metrics{display:grid;grid-template-columns:repeat(4,1fr);gap:14px;margin-bottom:16px}.metric,.card,.project{background:#11151d;border:1px solid #222936;border-radius:12px}.metric{padding:18px}.metric span,.metric small{display:block;color:#7c8799;font-size:12px}.metric strong{display:block;font-size:25px;margin:12px 0 5px}.card{padding:18px;min-width:0}.card-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:15px;gap:10px}.card h2{font-size:15px;margin:0;color:#dbe0e8}.grid2{display:grid;grid-template-columns:1fr 1fr;gap:16px}.quickstart-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:10px}.quickstart{min-height:72px;display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px;border:1px solid #263140;border-radius:8px;background:#151b24;color:#e7eaf0;text-decoration:none}.quickstart:hover{border-color:#19c37d;background:#192029}.quickstart span,.quickstart strong,.quickstart small{display:block}.quickstart small{margin-top:5px;color:#8d97a8;font-size:12px}.info{display:flex;justify-content:space-between;gap:20px;padding:10px 0;border-bottom:1px solid #202632;font-size:13px}.info span{color:#828da0}.info strong{text-align:right}.primary{display:inline-flex;align-items:center;justify-content:center;gap:7px;border:0;border-radius:8px;padding:9px 13px;background:#19c37d;color:#07130e;font-weight:700}.toolbar{display:flex;justify-content:flex-end;margin-bottom:15px}.cards{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:14px}.project{display:flex;gap:13px;padding:17px;align-items:flex-start;cursor:pointer}.project:hover,.project.selected{border-color:#19c37d}.project div{flex:1}.project h3{margin:0 0 6px}.project p{margin:0 0 10px;color:#929bad;font-size:13px}.project small{color:#657085}.tag{background:#1e2b27;color:#70dbad;border:1px solid #28513f;border-radius:99px;padding:4px 8px;font-size:11px}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-bottom:15px}label{display:flex;flex-direction:column;gap:6px;color:#9ba4b4;font-size:12px}input,textarea,select{background:#0b0e14;border:1px solid #2a3240;color:#e9edf4;border-radius:7px;padding:9px;outline:none}input:focus,textarea:focus,select:focus{border-color:#19c37d}.table{width:100%}.tr{display:grid;grid-template-columns:1.2fr 2fr 1fr 150px;gap:12px;padding:11px 6px;border-bottom:1px solid #202632;align-items:center;font-size:13px}.tr.th{color:#6f7a8d;text-transform:uppercase;font-size:10px}.tr>span{min-width:0;overflow:hidden;text-overflow:ellipsis}.tr>span:first-child{display:flex;align-items:center;gap:8px}.muted{color:#818b9c}.ok,.off{display:inline-block;width:7px;height:7px;border-radius:50%;margin-right:7px;background:#19c37d}.off{background:#768092}.actions{display:flex}.actions button:hover{background:#222b36;color:#fff}.logs{background:#080a0e;border:1px solid #202631;border-radius:8px;padding:13px;min-height:450px;max-height:65vh;overflow:auto;white-space:pre-wrap;color:#aab7c9;font:12px/1.55 ui-monospace,monospace}.logs.short{min-height:280px}.file-layout{display:grid;grid-template-columns:310px 1fr;gap:15px}.chat-layout{display:grid;grid-template-columns:270px minmax(420px,1fr) 360px;gap:15px}.file-list,.convs{display:flex;flex-direction:column}.file-list button{display:flex;justify-content:space-between;background:none;color:#afb7c5;border:0;border-bottom:1px solid #202631;padding:10px;text-align:left}.file-list button:hover,.conversation-row:hover,.conversation-row.active{background:#1a202a;color:#fff}.conversation-toolbar{display:flex;align-items:center;gap:6px}.conversation-toolbar button,.conversation-actions button{display:inline-flex;align-items:center;justify-content:center;min-width:32px;min-height:32px;padding:6px 8px;border:1px solid #29313d;border-radius:8px;background:#11151d;color:#c9d2df}.conversation-toolbar button.active{border-color:#19c37d;color:#e9fff5;background:#14261f}.conversation-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px;align-items:center;border-bottom:1px solid #202631;padding:8px}.conversation-select{display:grid;gap:4px;min-width:0;padding:0;border:0;background:transparent;color:#afb7c5;text-align:left}.conversation-select span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.conversation-select small{color:#748095;font-size:11px}.conversation-actions{display:flex;gap:5px}.conversation-actions .danger-link{color:#f0a0ac}.empty-list{padding:14px 10px;color:#748095;font-size:12px}.editor{width:100%;height:62vh;resize:none;font:13px/1.55 ui-monospace,monospace}.project-select{display:flex;justify-content:flex-end;align-items:center;gap:10px;margin-bottom:13px;color:#7e899b;font-size:12px}.project-actions{display:flex;justify-content:flex-end;gap:8px;margin:-4px 0 12px;flex-wrap:wrap}.project-actions button{display:inline-flex;align-items:center;gap:7px;min-height:38px;padding:8px 11px;border:1px solid #29313d;border-radius:8px;background:#11151d;color:#dce2eb}.project-actions button:hover:not(:disabled){border-color:#19c37d;color:#f4f7fb}.project-actions button:disabled{cursor:not-allowed;opacity:.45}.preview-link{display:flex;align-items:center;gap:10px;min-height:38px;margin:-2px 0 12px;padding:8px 10px;border:1px solid #25303d;border-radius:8px;background:#0d1219;color:#8f9bad;font-size:12px}.preview-link a{color:#dce2eb;overflow-wrap:anywhere}.mode-selector{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-bottom:12px}.mode-selector button{display:flex;flex-direction:column;gap:5px;padding:13px;text-align:left;color:#aeb7c5;background:#11151d;border:1px solid #29313d;border-radius:9px}.mode-selector button span{color:#788498;font-size:12px}.mode-selector button.selected{color:#e9fff5;border-color:#19c37d;background:#14261f}.mode-selector button.write.selected{border-color:#d8a63d;background:#2c2516}.mode-selector code{font-family:ui-monospace,monospace}.messages{height:51vh;overflow:auto;padding:5px}.message{max-width:85%;padding:11px 13px;border-radius:10px;margin:10px 0;background:#1a202a}.message.user{margin-left:auto;background:#173c2e}.message strong{font-size:11px;color:#8a96a8}.message pre{margin:5px 0 0;white-space:pre-wrap;font:13px/1.5 inherit}.composer{display:flex;flex-direction:column;gap:8px;margin-top:12px}.composer-row{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.composer-row input[type=file]{display:none}.composer-row button{min-height:42px}.composer textarea{resize:none;height:70px}.composer button:not(.primary){background:#202735;border:0;color:#dce2eb;border-radius:8px}.danger{background:#7f2430!important}.warning,.notice,.error{border:1px solid #725927;background:#2c2516;color:#e7ca7b;padding:10px 12px;border-radius:8px;font-size:12px;margin:10px 0}.notice{border-color:#28513f;background:#14261f;color:#83d9b2}.error{border-color:#743743;background:#2c161b;color:#f4a8b4}.activity-feed{height:64vh;overflow:auto;display:flex;flex-direction:column;gap:9px}.activity-event{display:grid;gap:5px;padding:10px;border:1px solid #273140;border-radius:8px;background:#0d1118}.activity-event strong{color:#72d5ac;font-size:12px}.activity-event small,.activity-event span{color:#929daf;font-size:11px}.activity-event pre{margin:0;padding:8px;max-height:180px;overflow:auto;white-space:pre-wrap;background:#080b10;color:#b9c5d6}.activity-event pre.command{color:#e7ca7b}.page-error{padding:24px;border:1px solid #743743;border-radius:10px;background:#2c161b}.page-error pre{white-space:pre-wrap;color:#f4a8b4}.app-fatal{width:min(760px,calc(100vw - 32px));margin:15vh auto 0}.app-fatal h1{margin:0 0 8px;font-size:24px}.task-list details{border-bottom:1px solid #222a36;padding:12px}.task-list summary{display:grid;grid-template-columns:100px 1fr auto;gap:12px;align-items:center;cursor:pointer}.task-list pre{white-space:pre-wrap;background:#0a0d12;padding:12px;max-height:400px;overflow:auto}.task-status{font-size:11px;text-transform:uppercase;color:#8e98a8}.task-status.succeeded{color:#38d896}.task-status.failed{color:#ee6b7e}.task-status.running{color:#e5c45d}.terminal{height:65vh;background:#0b0e14;border-radius:8px;padding:7px}.inline{display:flex;gap:8px}.inline input{flex:1}.preview-toolbar{display:flex;flex-wrap:wrap;gap:8px;margin-bottom:12px}.preview-toolbar button,.button-link{display:inline-flex;align-items:center;gap:7px;min-height:38px;padding:8px 11px;border:1px solid #29313d;border-radius:8px;background:#11151d;color:#dce2eb;text-decoration:none}.preview-toolbar button:disabled{cursor:not-allowed;opacity:.45}.preview{width:100%;height:70vh;border:1px solid #29313d;border-radius:8px;background:#fff}.tr.audit{grid-template-columns:180px 1fr 1fr 100px}.loading{display:flex;align-items:center;gap:10px;color:#8f9bad;padding:30px}.spin{animation:spin 1s linear infinite}@keyframes spin{to{transform:rotate(360deg)}}.login{min-height:100vh;display:grid;place-items:center;background:radial-gradient(circle at 50% 20%,#17382b,#090b10 45%)}.login-card{width:min(400px,90vw);background:#11151d;border:1px solid #28313f;border-radius:15px;padding:32px;box-shadow:0 30px 70px #0008}.login-card .brand-mark{margin-bottom:20px}.login-card h1{font-size:23px;margin:0}.login-card p{color:#7f899b;margin:7px 0 25px}.login-card label{margin:12px 0}.login-card button{width:100%;margin-top:14px}@media(max-width:950px){.shell{grid-template-columns:74px 1fr}.brand>div:last-child,nav button:not(.active){font-size:0}.brand{padding-left:2px}.profile div:nth-child(2),.profile button{display:none}.metrics{grid-template-columns:1fr 1fr}.grid2,.file-layout,.chat-layout,.mode-selector{grid-template-columns:1fr}.content{padding:22px 18px}}@media(max-width:620px){.metrics,.form-grid,.tr{grid-template-columns:1fr}.tr.th{display:none}.content>header{align-items:flex-start}.status{display:none}}.message-attachments{display:flex;flex-wrap:wrap;gap:10px;margin-top:12px}.attachment-card{display:flex;flex-direction:column;gap:6px;width:min(260px,100%);padding:10px;border:1px solid #273140;border-radius:10px;background:#0e131a;color:inherit;text-decoration:none}.attachment-card img{width:100%;max-height:180px;object-fit:contain;border-radius:8px;background:#090b10}.attachment-file{display:flex;align-items:center;gap:8px}.pending-attachments{display:flex;flex-direction:column;gap:8px}.pending-attachment{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:8px 10px;border:1px solid #273140;border-radius:8px;background:#0e131a}.pending-attachment span{display:flex;flex:1;justify-content:space-between;gap:10px}.pending-attachment small,.attachment-card small{color:#8a93a3}
