/**
 * 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{--bg: #14171d;--panel: #1b1f27;--panel-2: #232935;--line: #2d3441;--text: #e4e7ec;--muted: #8f98a7;--accent: #f0b44c;--accent-ink: #231a06;--running: #5fc2a0;--review: #f0b44c;--done: #8f9ef2;--danger: #f07a6a;--radius: 6px;--sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;--mono: "IBM Plex Mono", ui-monospace, Menlo, Consolas, monospace;color-scheme:dark}*{box-sizing:border-box}html,body,#root{margin:0;min-height:100%}body{background:var(--bg);color:var(--text);font:15px/1.55 var(--sans);-webkit-font-smoothing:antialiased}a{color:inherit;text-decoration:none}h1{font-size:22px;font-weight:600;margin:0;letter-spacing:-.01em}h2{font-size:16px;font-weight:600;margin:0}h3{font-size:14px;font-weight:600;margin:0}p{margin:0}code,.mono{font-family:var(--mono);font-size:.9em}.muted{color:var(--muted)}.error{color:var(--danger)}.success{color:var(--running)}:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.boot{padding:40px;color:var(--muted)}.shell{min-height:100vh;display:flex;flex-direction:column}.topbar{display:flex;align-items:center;gap:20px;padding:calc(env(safe-area-inset-top,0px) + 10px) 20px 10px;border-bottom:1px solid var(--line);background:var(--panel);position:sticky;top:0;z-index:5}.brand{display:inline-flex;align-items:center;gap:10px;font-weight:600}.brand-mark{display:inline-grid;place-items:center;width:26px;height:26px;border-radius:4px;background:var(--accent);color:var(--accent-ink);font-family:var(--mono);font-weight:500}.brand-large{font-size:24px}.brand-large .brand-mark{width:36px;height:36px;font-size:20px}.crumbs{display:flex;gap:8px;min-width:0;flex:1;color:var(--muted);overflow:hidden}.crumb{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.crumb+.crumb:before{content:"/";margin-right:8px;color:var(--line)}.crumb a:hover{color:var(--text)}.topbar-user{display:flex;align-items:center;gap:12px}.page{width:100%;max-width:1080px;margin:0 auto;padding:28px 20px calc(env(safe-area-inset-bottom,0px) + 60px)}.stack{display:flex;flex-direction:column;gap:24px}.stack-sm{display:flex;flex-direction:column;gap:12px}input,select,textarea{font:inherit;color:var(--text);background:var(--bg);border:1px solid var(--line);border-radius:var(--radius);padding:8px 10px;min-width:0}textarea{resize:vertical;line-height:1.5}input:focus,select:focus,textarea:focus{border-color:var(--accent);outline:none}label{display:flex;flex-direction:column;gap:6px;font-size:13px;color:var(--muted)}label small{font-size:12px}.btn{font:inherit;font-size:14px;font-weight:500;padding:8px 14px;border-radius:var(--radius);border:1px solid var(--line);background:var(--panel-2);color:var(--text);cursor:pointer;white-space:nowrap}.btn:hover:not(:disabled){border-color:var(--muted)}.btn:disabled{opacity:.5;cursor:default}.btn-primary{background:var(--accent);border-color:var(--accent);color:var(--accent-ink)}.btn-primary:hover:not(:disabled){border-color:var(--text)}.btn-ghost{background:transparent}.btn-small{padding:4px 10px;font-size:13px}.inline-form{display:flex;flex-wrap:wrap;gap:8px;align-items:center}.inline-form input{flex:1 1 200px}.card{background:var(--panel);border:1px solid var(--line);border-radius:8px;padding:18px}.list{list-style:none;margin:0;padding:0;border:1px solid var(--line);border-radius:8px;overflow:hidden}.list>li+li{border-top:1px solid var(--line)}.list-row{display:flex;align-items:center;gap:14px;padding:11px 14px;background:var(--panel);width:100%}a.list-row:hover,.list-button:hover{background:var(--panel-2)}.list-row>:first-child{flex:1;min-width:0}.list-button{font:inherit;color:inherit;border:0;text-align:left;cursor:pointer}.list-button.selected{background:var(--panel-2);box-shadow:inset 3px 0 0 var(--accent)}.list-compact .list-row{padding:8px 12px}.task-row .code{flex:0 0 auto;color:var(--muted)}.task-row .task-title{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.status-heading{display:flex;align-items:center;gap:8px}.status-heading:before{content:"";width:8px;height:8px;border-radius:50%;background:var(--muted)}.status-running:before{background:var(--running)}.status-review:before{background:var(--review)}.status-done:before{background:var(--done)}.count{color:var(--muted);font-weight:400}.badge{font-size:12px;font-weight:500;padding:3px 9px;border-radius:999px;border:1px solid var(--line);color:var(--muted)}.badge.status-running{color:var(--running);border-color:currentColor}.badge.status-review{color:var(--review);border-color:currentColor}.badge.status-done{color:var(--done);border-color:currentColor}.tabs{display:flex;gap:4px;border-bottom:1px solid var(--line);overflow-x:auto}.tab{padding:8px 12px;color:var(--muted);border-bottom:2px solid transparent;margin-bottom:-1px;white-space:nowrap}.tab:hover{color:var(--text)}.tab-active{color:var(--text);border-bottom-color:var(--accent)}.task-head{display:flex;align-items:baseline;gap:12px;flex-wrap:wrap}.task-head .code{color:var(--muted);font-size:15px}.task-meta{display:flex;flex-wrap:wrap;gap:16px;align-items:flex-end}.task-meta>div{display:flex;flex-direction:column;gap:6px}.task-meta .label{font-size:13px;color:var(--muted)}.description{white-space:pre-wrap;color:var(--text);max-width:75ch}.terminal{border:1px solid var(--line);border-radius:8px;overflow:hidden;background:#0f1216}.terminal-bar{display:flex;align-items:center;gap:10px;padding:7px 12px;border-bottom:1px solid var(--line);background:var(--panel);font-size:13px}.terminal-bar .btn{margin-left:auto}.terminal-screen{height:min(62vh,620px);padding:8px}.dot{width:8px;height:8px;border-radius:50%;background:var(--muted)}.dot-open{background:var(--running)}.dot-connecting{background:var(--review)}.dot-closed{background:var(--danger)}.output{margin:0;padding:14px;max-height:480px;overflow:auto;background:#0f1216;border:1px solid var(--line);border-radius:8px;font:12.5px/1.5 var(--mono);white-space:pre}.split{display:grid;grid-template-columns:240px 1fr;gap:20px;align-items:start}.editor{min-height:360px}.stats{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:1px;margin:0;background:var(--line);border:1px solid var(--line);border-radius:8px;overflow:hidden}.stats>div{background:var(--panel);padding:14px 16px}.stats dt{font-size:13px;color:var(--muted)}.stats dd{margin:4px 0 0;font:500 20px/1.3 var(--mono)}.auth{min-height:100vh;display:grid;grid-template-columns:1fr 400px;gap:60px;align-items:center;max-width:960px;margin:0 auto;padding:40px 24px}.auth-intro p{margin-top:18px;font-size:18px;color:var(--muted);max-width:32ch}.auth-card{display:flex;flex-direction:column;gap:14px}.empty{color:var(--muted)}@media (max-width: 760px){.topbar{gap:12px;padding-left:14px;padding-right:14px}.topbar-user .muted{display:none}.page{padding:20px 14px 60px}.split,.auth{grid-template-columns:1fr;gap:24px}.task-row>.muted:last-child{display:none}.terminal-screen{height:60vh}}.terminal-bar .btn{margin-left:0}.terminal-actions{margin-left:auto;display:flex;gap:6px;flex-wrap:wrap}.terminal-foot{display:flex;align-items:center;gap:12px;flex-wrap:wrap;padding:7px 12px;border-top:1px solid var(--line);background:var(--panel);font-size:12.5px}.viewers{list-style:none;margin:0;padding:0;display:flex;gap:6px;flex-wrap:wrap}.viewer{padding:2px 9px;border-radius:999px;border:1px solid var(--running);color:var(--running)}.viewer-view{border-color:var(--line);color:var(--muted)}.typing{color:var(--review);margin-left:auto}.terminal-note{padding:6px 12px;font-size:12.5px;color:var(--muted);background:var(--panel-2);border-bottom:1px solid var(--line)}a.btn{text-decoration:none;display:inline-flex;align-items:center}.output.log{white-space:pre-wrap;word-break:break-word}.choice{border:0;margin:0;padding:0;display:flex;flex-direction:column;gap:6px}.choice label,.check{display:flex;align-items:baseline;gap:8px;font-size:14px}.choice input:disabled+*{opacity:.5}.banner{padding:10px 14px;border-radius:8px;border:1px solid;font-size:14px}.banner-warn{border-color:var(--review);background:color-mix(in srgb,var(--review) 10%,transparent)}.banner-full{border-color:var(--danger);background:color-mix(in srgb,var(--danger) 12%,transparent)}.banner a{color:inherit;text-decoration:underline}.warn-text{color:var(--review)}.meter-row{display:grid;grid-template-columns:120px 1fr auto;gap:12px;align-items:center;font-size:13px}@media (max-width: 560px){.meter-row{grid-template-columns:1fr;gap:4px}}.meter{height:8px;border-radius:999px;background:var(--panel-2);overflow:hidden}.meter>span{display:block;height:100%;background:var(--running)}.meter-warn>span{background:var(--review)}.meter-full>span{background:var(--danger)}.meter-host>span{background:var(--done)}
