/**
 * 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}:root{--bg: #0f1419;--bg-elevated: #1a222c;--bg-input: #121820;--border: #2a3544;--text: #e8eef5;--muted: #8b9aab;--accent: #2f9e7a;--accent-hover: #3bb890;--danger: #d65a5a;--warn: #c9a227;--radius: 6px;--font: "IBM Plex Sans", system-ui, sans-serif;--mono: "IBM Plex Mono", ui-monospace, monospace}*{box-sizing:border-box}html,body,#root{margin:0;min-height:100%}body{font-family:var(--font);background:radial-gradient(ellipse 80% 50% at 10% -10%,#1a3a32 0%,transparent 50%),radial-gradient(ellipse 60% 40% at 100% 0%,#1a2535 0%,transparent 45%),var(--bg);color:var(--text);line-height:1.45}a{color:var(--accent);text-decoration:none}a:hover{color:var(--accent-hover)}h1,h2,h3{font-weight:600;letter-spacing:-.02em;margin:0 0 .75rem}.muted{color:var(--muted)}.shell{display:grid;grid-template-columns:220px 1fr;min-height:100vh}.sidebar{position:sticky;top:0;height:100vh;overflow:hidden;border-right:1px solid var(--border);background:#0f1419eb;padding:1.5rem 1rem;display:flex;flex-direction:column;gap:1rem}.brand{font-family:var(--mono);font-weight:500;font-size:1.1rem;letter-spacing:.04em;display:inline-flex;align-items:center;gap:.45rem;min-width:0}.brand-mark{width:1.75rem;height:1.75rem;flex-shrink:0;object-fit:contain;display:block}.brand-row{display:flex;align-items:center;justify-content:space-between;gap:.5rem}.bell-btn{position:relative;border:0;background:transparent;color:var(--text);cursor:pointer;padding:.2rem .35rem;font-size:1rem}.bell-btn .nav-badge{position:absolute;top:-.2rem;right:-.35rem;margin-left:0}.notify-panel{background:var(--bg-elevated);border:1px solid var(--border);border-radius:var(--radius);padding:.65rem;display:flex;flex-direction:column;gap:.35rem;max-height:22rem;overflow:auto}.notify-item{text-align:left;border:0;background:transparent;color:var(--text);cursor:pointer;padding:.4rem .35rem;border-radius:var(--radius)}.notify-item:hover{background:var(--bg)}.notify-item.unread{border-left:2px solid var(--accent);padding-left:.45rem}.nav{display:flex;flex-direction:column;gap:.35rem;flex:1;min-height:0;overflow-y:auto}.nav-group{display:flex;flex-direction:column;gap:.15rem}.nav-group-toggle{display:flex;align-items:center;gap:.35rem;width:100%;border:0;background:transparent;color:var(--muted);font:inherit;font-size:.72rem;font-weight:600;letter-spacing:.06em;text-transform:uppercase;text-align:left;cursor:pointer;padding:.45rem .65rem .25rem;border-radius:var(--radius)}.nav-group-toggle:hover{color:var(--text);background:#ffffff08}.nav-group.active-group>.nav-group-toggle{color:var(--text)}.nav-group-chevron{display:inline-block;width:.85rem;opacity:.7;font-size:.65rem}.nav-group-label{flex:1;min-width:0}.nav-group-items{display:flex;flex-direction:column;gap:.2rem;padding-left:.35rem}.nav-group-items a{padding-left:1.35rem}.lang-switch{display:inline-flex;gap:.15rem;border:1px solid var(--border);border-radius:var(--radius);padding:.1rem;background:var(--bg-input)}.lang-switch button{border:0;background:transparent;color:var(--muted);font:inherit;font-size:.75rem;letter-spacing:.04em;padding:.15rem .4rem;border-radius:4px;cursor:pointer}.lang-switch button.active{background:var(--bg-elevated);color:var(--text)}.profile-menu{position:relative;flex-shrink:0;margin-top:auto}.profile-trigger{width:100%;display:flex;align-items:center;justify-content:space-between;gap:.4rem;text-align:left;background:transparent;border:1px solid transparent;color:var(--text);cursor:pointer;padding:.55rem .65rem;border-radius:var(--radius);font:inherit}.profile-trigger:hover,.profile-trigger[aria-expanded=true]{background:var(--bg-elevated);border-color:var(--border)}.profile-trigger-name{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.profile-trigger-caret{color:var(--muted);font-size:.75rem}.profile-dropdown{position:absolute;left:0;right:0;bottom:calc(100% + .4rem);background:var(--bg-elevated);border:1px solid var(--border);border-radius:var(--radius);padding:.3rem;display:flex;flex-direction:column;gap:.15rem;z-index:40;box-shadow:0 10px 28px #0006}.profile-dropdown button{width:100%;text-align:left;border:0;background:transparent;color:var(--text);cursor:pointer;padding:.5rem .65rem;border-radius:var(--radius);font:inherit}.profile-dropdown button:hover{background:var(--bg)}.profile-dropdown button.danger{color:var(--danger)}.nav a{color:var(--muted);padding:.5rem .65rem;border-radius:var(--radius)}.nav a.active,.nav a:hover{color:var(--text);background:var(--bg-elevated)}.nav-badge{display:inline-block;margin-left:.4rem;min-width:1.25rem;padding:.05rem .35rem;border-radius:999px;background:var(--accent);color:#06140f;font-size:.75rem;font-weight:700;text-align:center;vertical-align:middle}.toast-stack{position:fixed;right:1.25rem;bottom:1.25rem;display:flex;flex-direction:column;gap:.5rem;z-index:50;max-width:min(360px,calc(100vw - 2rem))}.toast{background:var(--bg-elevated);border:1px solid var(--accent);border-radius:var(--radius);padding:.75rem 1rem;box-shadow:0 8px 24px #00000059;cursor:pointer}.main{padding:1.75rem 2rem;min-width:0;min-height:100vh;display:flex;flex-direction:column;gap:0}.main-body{flex:1;min-height:0;position:relative;display:flex;flex-direction:column}.main-outlet.obscured{display:none}.session-tabbar{display:flex;flex-wrap:wrap;gap:.35rem;align-items:stretch;margin:-.5rem 0 .85rem;padding-bottom:.65rem;border-bottom:1px solid var(--border);overflow-x:auto}.session-tab{display:inline-flex;align-items:center;max-width:220px;background:var(--bg-elevated);border:1px solid var(--border);border-radius:8px 8px 0 0;border-bottom-color:transparent}.session-tab.active{background:#2f9e7a1f;border-color:var(--accent);border-bottom-color:transparent}.session-tab-btn{display:flex;flex-direction:column;align-items:flex-start;gap:.1rem;background:transparent;border:0;color:var(--text);padding:.4rem .55rem .4rem .65rem;cursor:pointer;min-width:0;text-align:left}.session-tab-kind{font-family:var(--mono);font-size:.65rem;letter-spacing:.06em;color:var(--accent)}.session-tab-title{font-size:.82rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:160px}.session-tab-close{background:transparent;border:0;color:var(--muted);cursor:pointer;font-size:1.1rem;line-height:1;padding:.35rem .5rem;border-radius:4px}.session-tab-close:hover{color:var(--text);background:#ffffff0f}.session-keepalive{flex:1;min-height:0;position:relative;display:flex;flex-direction:column}.session-keepalive:not(.viewing){position:fixed;left:-120vw;top:0;width:100vw;height:100vh;visibility:hidden;pointer-events:none;z-index:-1}.session-keepalive.viewing{position:relative;left:auto;top:auto;width:auto;height:auto;visibility:visible;pointer-events:auto;z-index:auto}.session-panel{flex:1;min-height:0;flex-direction:column;display:flex;position:absolute;top:0;right:0;bottom:0;left:0;visibility:hidden;pointer-events:none;z-index:0}.session-panel.visible{position:relative;visibility:visible;pointer-events:auto;z-index:1}.session-panel-inner{flex:1;min-height:0;display:flex;flex-direction:column}.desktop-session{height:100%}.session-keepalive.viewing .app-frame{flex:1;min-height:480px;width:100%;border:1px solid var(--border);border-radius:var(--radius);background:#fff}.overlay{position:fixed;top:0;right:0;bottom:0;left:0;background:#080c109e;display:grid;place-items:center;z-index:40;padding:1rem}.auth-page{min-height:100vh;display:grid;place-items:center;padding:1.5rem}.auth-card{width:min(420px,100%)}.auth-card .brand{margin-bottom:1.25rem}label{display:block;font-size:.85rem;color:var(--muted);margin-bottom:.35rem}input,select{width:100%;background:var(--bg-input);border:1px solid var(--border);color:var(--text);border-radius:var(--radius);padding:.55rem .7rem;font:inherit;margin-bottom:.9rem}input:focus,select:focus{outline:1px solid var(--accent);border-color:var(--accent)}.btn{-webkit-appearance:none;-moz-appearance:none;appearance:none;border:1px solid transparent;background:var(--accent);color:#06140f;font:inherit;font-weight:600;padding:.55rem 1rem;border-radius:var(--radius);cursor:pointer}.btn:hover{background:var(--accent-hover)}.btn.secondary{background:transparent;border-color:var(--border);color:var(--text)}.btn.secondary.active{border-color:var(--accent);color:var(--accent)}.btn.danger{background:transparent;border-color:var(--danger);color:var(--danger)}.btn:disabled{opacity:.55;cursor:not-allowed}.row{display:flex;gap:.5rem;flex-wrap:wrap;align-items:center}.error{color:var(--danger);margin:0 0 .75rem;font-size:.9rem}.ok{color:var(--accent);margin:0 0 .75rem;font-size:.9rem}table{width:100%;border-collapse:collapse;font-size:.92rem}th,td{text-align:left;padding:.65rem .5rem;border-bottom:1px solid var(--border);vertical-align:top}th{color:var(--muted);font-weight:500;font-size:.8rem;text-transform:uppercase;letter-spacing:.04em}.badge{display:inline-block;font-family:var(--mono);font-size:.75rem;padding:.15rem .4rem;border-radius:4px;border:1px solid var(--border);color:var(--muted)}.badge.active{color:var(--accent);border-color:#2f9e7a55}.badge.disabled,.badge.locked{color:var(--danger);border-color:#d65a5a55}.badge.archived{color:var(--muted);border-color:color-mix(in srgb,var(--muted) 45%,transparent)}.toolbar{display:flex;justify-content:space-between;align-items:center;gap:1rem;margin-bottom:1rem}.mono{font-family:var(--mono);font-size:.85rem}.qr{background:#fff;padding:.75rem;border-radius:var(--radius);width:fit-content;margin:.5rem 0 1rem}.search-bar{display:flex;gap:.5rem;flex-wrap:wrap;align-items:center;margin-bottom:1rem}.pager{display:flex;justify-content:space-between;align-items:center;gap:.75rem;flex-wrap:wrap;margin-bottom:.75rem}.meta-grid{display:grid;grid-template-columns:1fr 1fr;gap:.75rem 1rem;margin-top:.5rem;padding-top:.75rem;border-top:1px solid var(--border);font-size:.92rem}a.btn{display:inline-block;text-decoration:none;color:var(--text)}.terminal-page .terminal-host{padding:.5rem;min-height:420px;background:#0b1016}.terminal-page .terminal-host .xterm{height:calc(100vh - 220px);min-height:360px;padding:.5rem}.k8s-exec-host{padding:.5rem;min-height:240px;background:#0b1016}.k8s-exec-host .xterm{height:240px;padding:.35rem}.watch-log{padding:.75rem 1rem;margin-top:.75rem;max-height:360px;overflow:auto;font-family:var(--mono);font-size:.85rem;line-height:1.5}.watch-log-line.deny{color:var(--danger)}.watch-log-line.err{color:#e09070}.watch-log-line.ok{color:var(--text)}.page-head{display:flex;flex-wrap:wrap;align-items:flex-start;justify-content:space-between;gap:1rem;margin-bottom:.5rem}.row.gap{display:flex;flex-wrap:wrap;gap:.5rem;align-items:center}.btn.active-window{border-color:var(--accent, #3d8bfd);color:var(--text)}.stats-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(140px,1fr));gap:.75rem}.stat-card .stat-value{font-size:1.75rem;font-weight:650;line-height:1.2;margin-bottom:.25rem}.stat-card.warn{border-color:#a65f2a}.two-col{display:grid;grid-template-columns:1fr 1fr;gap:1rem}.anomaly-list{list-style:none;padding:0;margin:.5rem 0 0}.anomaly-list li{padding:.75rem 0;border-bottom:1px solid var(--border)}.anomaly-list li:last-child{border-bottom:none}.anomaly-list li>div{display:flex;align-items:center;gap:.5rem;margin-bottom:.25rem}.badge.sev-high{background:#5c1f1f;color:#f5b4b4}.badge.sev-medium{background:#5c3d1f;color:#f0d0a0}.badge.sev-low{background:#1f3d5c;color:#a8c8e8}.spark-rows{display:flex;flex-direction:column;gap:.4rem}.spark-row{display:grid;grid-template-columns:7.5rem 1fr 3rem;gap:.5rem;align-items:center}.spark-bars{display:flex;flex-direction:column;gap:2px}.spark{height:6px;border-radius:2px;min-width:0}.spark.ok{background:#2f6f4e}.spark.fail{background:#8b3a3a}.dash-chart{width:100%;height:auto;display:block}.dash-chart-axis{fill:var(--muted);font-size:11px;font-family:inherit}.dash-legend{margin:.5rem 0 0;display:flex;align-items:center;flex-wrap:wrap;gap:.15rem}.legend-swatch{display:inline-block;width:.7rem;height:.7rem;border-radius:2px;vertical-align:middle;background:#5c5c5c}.legend-swatch.ok{background:#3d9a68}.legend-swatch.fail{background:#c45c5c}.proto-donut-wrap{position:relative;width:9rem;height:9rem;margin:.5rem auto 1rem}.proto-donut{width:100%;height:100%;border-radius:50%}.proto-donut-center{position:absolute;top:22%;right:22%;bottom:22%;left:22%;border-radius:50%;background:var(--bg-elevated);display:flex;align-items:center;justify-content:center;font-size:1.25rem}.bar-list{list-style:none;padding:0;margin:.5rem 0 0}.bar-list li{display:grid;grid-template-columns:minmax(5rem,11rem) 1fr 2.5rem;gap:.5rem;align-items:center;padding:.35rem 0}.bar-list .bar-label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:.8rem}.bar-track{height:8px;background:var(--border);border-radius:4px;overflow:hidden}.bar-fill{height:100%;background:#3d7ea6;border-radius:4px}.plain-list{list-style:none;padding:0;margin:.5rem 0 0}.plain-list li{display:flex;justify-content:space-between;gap:1rem;padding:.4rem 0;border-bottom:1px solid var(--border)}.plain-list li:last-child{border-bottom:none}.sql-input{width:100%;font-family:var(--mono);background:var(--bg-input);border:1px solid var(--border);color:var(--text);border-radius:var(--radius);padding:.75rem;margin-bottom:.75rem;resize:vertical}.app-frame{width:100%;min-height:calc(100vh - 180px);border:1px solid var(--border);border-radius:var(--radius);background:#fff}.help-page{max-width:1100px}.help-layout{display:grid;grid-template-columns:minmax(200px,240px) 1fr;gap:1.25rem;align-items:start}.help-toc{position:sticky;top:.75rem;padding:.85rem;max-height:calc(100vh - 2rem);overflow:auto}.help-search{display:flex;flex-direction:column;gap:.35rem;margin-bottom:.85rem}.help-search input{width:100%;font:inherit;background:var(--bg-input);border:1px solid var(--border);color:var(--text);border-radius:var(--radius);padding:.45rem .55rem}.help-toc-group{margin-bottom:.75rem}.help-toc-group-title{font-size:.72rem;font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:var(--muted);margin-bottom:.35rem}.help-toc-nav ul{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:.2rem}.help-toc-nav a{display:block;padding:.25rem .4rem;border-radius:4px;color:var(--text);text-decoration:none;font-size:.9rem}.help-toc-nav a:hover,.help-toc-nav a.active{background:#ffffff0d;color:var(--accent, #2f9e7a)}.help-section{margin-bottom:1.5rem}.help-section-title{font-size:1.05rem;margin:0 0 .75rem;color:var(--muted);font-weight:600}.help-article{margin-bottom:.65rem;padding:0;overflow:hidden}.help-article-head{width:100%;display:flex;gap:.55rem;align-items:flex-start;text-align:left;border:0;background:transparent;color:var(--text);cursor:pointer;padding:.85rem 1rem;font:inherit}.help-article-head:hover{background:#ffffff08}.help-article-chevron{opacity:.7;margin-top:.15rem}.help-article-summary{display:block;margin-top:.25rem;font-size:.9rem}.help-article-body{padding:0 1rem 1rem 2.2rem;display:flex;flex-direction:column;gap:.65rem}.help-article-body p{margin:0;line-height:1.55;color:var(--text)}.help-actions h3{margin:.35rem 0 .5rem;font-size:.95rem}.help-actions dl{margin:0;display:flex;flex-direction:column;gap:.55rem}.help-action dt{font-family:var(--mono);font-size:.88rem;color:var(--accent, #2f9e7a)}.help-action dd{margin:.15rem 0 0;color:var(--muted);font-size:.92rem}.help-table{width:100%;margin:.75rem 0 1rem;border-collapse:collapse;font-size:.92rem}.help-table th,.help-table td{text-align:left;vertical-align:top;padding:.45rem .6rem;border-bottom:1px solid var(--border, rgba(127, 127, 127, .25))}.help-table th{font-size:.82rem;color:var(--muted);font-weight:600}.help-table td:first-child{font-weight:600;width:32%}.help-related{color:var(--accent, #2f9e7a);text-decoration:none;font-size:.9rem;border-bottom:1px dashed rgba(47,158,122,.45)}.help-related:hover{border-bottom-style:solid}@media (max-width: 900px){.help-layout{grid-template-columns:1fr}.help-toc{position:static;max-height:none}}@media (max-width: 800px){.shell{grid-template-columns:1fr}.sidebar{border-right:none;border-bottom:1px solid var(--border)}.nav{flex-direction:column;flex-wrap:nowrap}.nav-group-items{flex-direction:column}.meta-grid,.two-col,.spark-row{grid-template-columns:1fr}}
