:root {
  color-scheme: dark;
  --bg: #07100e;
  --surface: #0c1714;
  --surface-2: #111e1a;
  --surface-3: #162521;
  --border: #20332d;
  --border-bright: #345047;
  --text: #f0f5f2;
  --muted: #91a49d;
  --faint: #61746d;
  --mint: #76e7b7;
  --mint-strong: #42d89a;
  --mint-dark: #0b3a2a;
  --amber: #f2bf68;
  --red: #ff7c78;
  --blue: #79a9ff;
  --radius: 16px;
  --sidebar: 250px;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
}

* { box-sizing: border-box; }
html { min-width: 320px; background: var(--bg); }
body { min-height: 100vh; margin: 0; background: var(--bg); color: var(--text); }
button, input, select, textarea { font: inherit; }
button, select { cursor: pointer; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible { outline: 2px solid var(--mint); outline-offset: 2px; }
[hidden] { display: none !important; }

.skip-link { position: fixed; top: -60px; left: 16px; z-index: 1000; padding: 10px 16px; border-radius: 8px; background: var(--mint); color: #04100c; font-weight: 800; text-decoration: none; }
.skip-link:focus { top: 16px; }
.muted { color: var(--muted); }
.eyebrow, .section-kicker { margin: 0 0 9px; color: var(--mint); font-size: 11px; font-weight: 800; letter-spacing: .15em; text-transform: uppercase; }
.pulse-dot { display: inline-block; width: 7px; height: 7px; margin-right: 7px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 0 4px #76e7b71a, 0 0 18px #76e7b799; animation: breathe 2s ease-in-out infinite; }
@keyframes breathe { 50% { opacity: .55; box-shadow: 0 0 0 7px #76e7b70c; } }

.brand { display: inline-flex; align-items: center; gap: 11px; color: var(--text); font-size: 17px; font-weight: 800; letter-spacing: .055em; text-decoration: none; }
.brand b { color: var(--mint); font-weight: 800; }
.brand--large { font-size: 20px; }
.brand-mark { position: relative; display: inline-flex; align-items: flex-end; gap: 3px; width: 26px; height: 26px; padding: 5px; border: 1px solid #76e7b766; border-radius: 8px; background: #76e7b70d; transform: rotate(-4deg); }
.brand-mark i { display: block; width: 3px; border-radius: 4px; background: var(--mint); }
.brand-mark i:nth-child(1) { height: 8px; opacity: .55; }
.brand-mark i:nth-child(2) { height: 14px; }
.brand-mark i:nth-child(3) { height: 10px; opacity: .75; }

.auth-shell { min-height: 100vh; display: grid; grid-template-columns: minmax(420px, 1.15fr) minmax(420px, .85fr); }
.auth-story { position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: space-between; min-height: 100vh; padding: clamp(32px, 5vw, 72px); border-right: 1px solid var(--border); background: radial-gradient(circle at 20% 80%, #1f725035 0, transparent 34%), linear-gradient(145deg, #091713, #07100e 64%); }
.auth-story::before { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .22; background-image: linear-gradient(#76e7b70b 1px, transparent 1px), linear-gradient(90deg, #76e7b70b 1px, transparent 1px); background-size: 52px 52px; mask-image: linear-gradient(to bottom, transparent, #000 30%, #000 80%, transparent); }
.auth-story::after { content: ""; position: absolute; width: 500px; height: 500px; right: -260px; bottom: -240px; border: 1px solid #76e7b733; border-radius: 50%; box-shadow: 0 0 0 65px #76e7b708, 0 0 0 130px #76e7b707; }
.auth-story > * { position: relative; z-index: 1; }
.auth-copy { max-width: 760px; }
.auth-copy h1 { max-width: 780px; margin: 18px 0 24px; font-size: clamp(42px, 5.4vw, 82px); font-weight: 570; letter-spacing: -.055em; line-height: .98; }
.auth-copy h1 em { color: var(--mint); font-family: Georgia, serif; font-weight: 400; }
.auth-copy > p:last-child { max-width: 620px; margin: 0; color: var(--muted); font-size: clamp(16px, 1.4vw, 20px); line-height: 1.7; }
.auth-signals { display: flex; flex-wrap: wrap; gap: 10px; }
.auth-signals span { padding: 8px 12px; border: 1px solid var(--border); border-radius: 999px; background: #0b1714cc; color: #b8c9c2; font-size: 12px; }
.auth-signals span::before { content: "✓"; margin-right: 7px; color: var(--mint); }
.auth-panel { display: grid; place-items: center; min-height: 100vh; padding: 28px; background: #09120f; }
.auth-card { width: min(440px, 100%); }
.auth-card h2 { margin: 0 0 8px; font-size: 34px; letter-spacing: -.035em; }
.auth-card > div > .muted { margin: 0 0 32px; line-height: 1.6; }
.stack { display: grid; gap: 11px; }
label { color: #c8d5d0; font-size: 13px; font-weight: 650; }
label span { color: var(--faint); font-weight: 500; }
input, select, textarea { width: 100%; border: 1px solid var(--border); border-radius: 10px; background: #0b1613; color: var(--text); transition: border-color .18s, box-shadow .18s, background .18s; }
input, select { height: 46px; padding: 0 13px; }
textarea { min-height: 96px; padding: 12px 13px; resize: vertical; line-height: 1.5; }
input::placeholder, textarea::placeholder { color: #53645e; }
input:hover, select:hover, textarea:hover { border-color: var(--border-bright); }
input:focus, select:focus, textarea:focus { border-color: var(--mint-strong); outline: 0; box-shadow: 0 0 0 3px #42d89a17; background: #0e1c18; }
.password-field { position: relative; }
.password-field input { padding-right: 66px; }
.input-action { position: absolute; right: 8px; top: 7px; height: 32px; border: 0; background: transparent; color: var(--muted); font-size: 12px; font-weight: 700; }
.button { min-height: 42px; display: inline-flex; align-items: center; justify-content: center; gap: 9px; padding: 0 16px; border: 1px solid transparent; border-radius: 9px; font-weight: 750; transition: transform .15s, background .15s, border-color .15s, opacity .15s; }
.button:hover { transform: translateY(-1px); }
.button:active { transform: translateY(0); }
.button:disabled { cursor: not-allowed; opacity: .48; transform: none; }
.button--primary { background: var(--mint); color: #04110c; box-shadow: 0 8px 24px #2ed5901c; }
.button--primary:hover { background: #8af0c3; }
.button--ghost { border-color: var(--border); background: #101c19; color: #cfdbd6; }
.button--danger { border-color: #ff7c7840; background: #ff7c7812; color: #ff9c98; }
.button--wide { width: 100%; justify-content: space-between; margin-top: 14px; padding-inline: 18px; }
.button.is-loading { color: transparent; pointer-events: none; position: relative; }
.button.is-loading::after { content: ""; position: absolute; width: 16px; height: 16px; border: 2px solid #07100e44; border-top-color: #07100e; border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.auth-footnote { margin: 28px 0 0; padding-top: 20px; border-top: 1px solid var(--border); color: var(--faint); font-size: 11px; line-height: 1.55; }
.form-error { margin: 16px 0 0; padding: 10px 12px; border: 1px solid #ff7c7833; border-radius: 8px; background: #ff7c780d; color: #ffaaa7; font-size: 13px; }
.back-button, .text-button { padding: 0; border: 0; background: transparent; color: var(--mint); font-size: 13px; font-weight: 700; }
.back-button { margin-bottom: 24px; color: var(--muted); }
.secret-box { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 20px 0; padding: 14px; border: 1px dashed var(--border-bright); border-radius: 10px; background: #0b1714; }
.secret-box code { overflow-wrap: anywhere; color: var(--mint); font-size: 13px; letter-spacing: .08em; }
.secret-box button { border: 0; background: transparent; color: var(--text); font-size: 12px; font-weight: 750; }
.otp-input { height: 60px; text-align: center; font-size: 27px; letter-spacing: .45em; font-variant-numeric: tabular-nums; }

.app-shell { min-height: 100vh; display: grid; grid-template-columns: var(--sidebar) minmax(0, 1fr); }
.sidebar { position: fixed; z-index: 40; inset: 0 auto 0 0; width: var(--sidebar); overflow-y: auto; display: flex; flex-direction: column; padding: 28px 20px 20px; border-right: 1px solid var(--border); background: #08120f; }
.sidebar > .brand { margin: 0 10px 35px; }
.main-nav { display: grid; gap: 4px; }
.main-nav p { margin: 23px 12px 7px; color: #52645d; font-size: 9px; font-weight: 850; letter-spacing: .18em; }
.main-nav p:first-child { margin-top: 0; }
.nav-item { position: relative; width: 100%; height: 42px; display: flex; align-items: center; gap: 12px; padding: 0 12px; border: 0; border-radius: 8px; background: transparent; color: #83958e; text-align: left; font-size: 13px; font-weight: 650; transition: color .15s, background .15s; }
.nav-item > span { width: 18px; color: #647770; font-size: 17px; text-align: center; }
.nav-item:hover { background: #101c18; color: #d8e2de; }
.nav-item.is-active { background: #14231e; color: var(--text); }
.nav-item.is-active::before { content: ""; position: absolute; left: 0; width: 2px; height: 20px; border-radius: 2px; background: var(--mint); }
.nav-item.is-active > span { color: var(--mint); }
.nav-item--primary { margin: 5px 0; border: 1px solid #76e7b738; background: linear-gradient(90deg, #17382c, #10251e); color: #dff8ee; }
.nav-advanced { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border); }
.nav-advanced summary { min-height: 42px; display: flex; align-items: center; justify-content: space-between; padding: 0 12px; border-radius: 8px; color: #71847c; cursor: pointer; font-size: 12px; font-weight: 700; list-style: none; }
.nav-advanced summary::-webkit-details-marker { display: none; }
.nav-advanced summary::after { content: "+"; color: var(--mint); font-size: 16px; }
.nav-advanced[open] summary::after { content: "−"; }
.nav-advanced summary:hover { background: #101c18; color: #c8d5d0; }
.nav-badge { min-width: 20px; margin-left: auto; padding: 2px 6px; border-radius: 999px; background: #6fe6b51c; color: var(--mint); font-size: 10px; text-align: center; }
.sidebar-foot { margin-top: auto; padding-top: 18px; border-top: 1px solid var(--border); }
.runtime-state { display: flex; align-items: center; padding: 4px 8px; }
.runtime-state .pulse-dot { flex: 0 0 auto; }
.runtime-state div { display: grid; gap: 3px; min-width: 0; }
.runtime-state b { font-size: 11px; }
.runtime-state small { overflow: hidden; color: var(--faint); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.workspace { grid-column: 2; min-width: 0; }
.topbar { position: sticky; top: 0; z-index: 30; height: 72px; display: flex; align-items: center; gap: 16px; padding: 0 clamp(20px, 3vw, 44px); border-bottom: 1px solid var(--border); background: #07100eef; backdrop-filter: blur(18px); }
.org-switcher { display: flex; align-items: center; gap: 10px; }
.org-switcher label { color: var(--faint); font-size: 10px; letter-spacing: .1em; text-transform: uppercase; }
.org-switcher select { width: auto; min-width: 190px; height: 34px; border: 0; background: transparent; color: var(--text); font-size: 13px; font-weight: 750; }
.topbar-actions { position: relative; display: flex; align-items: center; gap: 10px; margin-left: auto; }
.live-state { display: flex; align-items: center; gap: 7px; padding: 7px 10px; border: 1px solid var(--border); border-radius: 999px; color: var(--muted); font-size: 10px; font-weight: 750; letter-spacing: .06em; text-transform: uppercase; }
.live-state span { width: 6px; height: 6px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 9px var(--mint); }
.live-state.is-offline span { background: var(--amber); box-shadow: none; }
.icon-button { width: 36px; height: 36px; display: grid; place-items: center; padding: 0; border: 1px solid var(--border); border-radius: 8px; background: #0c1714; color: #aebeb8; }
.menu-toggle { display: none; }
.profile-button { height: 44px; display: flex; align-items: center; gap: 10px; padding: 0 9px 0 5px; border: 1px solid transparent; border-radius: 9px; background: transparent; color: var(--text); text-align: left; }
.profile-button:hover { border-color: var(--border); background: #0d1815; }
.profile-button > span:first-child { width: 33px; height: 33px; display: grid; place-items: center; border: 1px solid #76e7b744; border-radius: 8px; background: #76e7b712; color: var(--mint); font-size: 11px; font-weight: 850; }
.profile-button > span:nth-child(2) { display: grid; gap: 2px; }
.profile-button b { max-width: 150px; overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.profile-button small { color: var(--faint); font-size: 9px; text-transform: capitalize; }
.profile-button i { color: var(--faint); font-style: normal; }
.profile-menu { position: absolute; top: 51px; right: 0; width: 150px; padding: 7px; border: 1px solid var(--border); border-radius: 10px; background: #0c1714; box-shadow: 0 18px 45px #0008; }
.profile-menu button { width: 100%; padding: 9px 10px; border: 0; border-radius: 6px; background: transparent; color: #ff9d99; text-align: left; font-size: 12px; }
.profile-menu button:hover { background: #ff7c780d; }

.content { width: min(1500px, 100%); margin: 0 auto; padding: clamp(26px, 4vw, 52px); }
.view { display: none; }
.view.is-active { display: block; animation: fade-in .2s ease; }
@keyframes fade-in { from { opacity: 0; transform: translateY(3px); } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 32px; }
.page-actions { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 10px; }
.page-heading h1 { margin: 0; font-size: clamp(29px, 3.2vw, 43px); font-weight: 610; letter-spacing: -.045em; }
.page-heading > div > p:last-child { margin: 9px 0 0; color: var(--muted); font-size: 14px; }
.metrics-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 13px; margin-bottom: 14px; }
.metric-card { min-height: 135px; display: flex; flex-direction: column; justify-content: space-between; padding: 18px; border: 1px solid var(--border); border-radius: var(--radius); background: linear-gradient(145deg, #101c18, #0b1512); }
.metric-card:hover { border-color: #324940; }
.metric-card > div:first-child { display: flex; align-items: center; justify-content: space-between; }
.metric-card small { color: var(--faint); font-size: 10px; font-weight: 750; letter-spacing: .1em; text-transform: uppercase; }
.metric-card .metric-icon { width: 28px; height: 28px; display: grid; place-items: center; border: 1px solid var(--border); border-radius: 7px; color: var(--mint); font-size: 13px; }
.metric-card strong { display: block; margin-top: 16px; font-size: 28px; font-weight: 620; letter-spacing: -.035em; font-variant-numeric: tabular-nums; }
.metric-card p { margin: 4px 0 0; color: var(--faint); font-size: 10px; }
.overview-grid { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(300px, .75fr); gap: 14px; }
.readiness-banner { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 15px; margin: -17px 0 18px; padding: 14px 16px; border: 1px solid #76e7b72c; border-radius: 13px; background: linear-gradient(90deg, #76e7b70e, #0c1815); }
.readiness-banner b { display: block; margin-bottom: 3px; font-size: 12px; }
.readiness-banner p { margin: 0; color: var(--muted); font-size: 10px; line-height: 1.5; }
.readiness-icon, .agent-avatar { display: grid; place-items: center; flex: 0 0 auto; border: 1px solid #76e7b744; border-radius: 10px; background: #76e7b710; color: var(--mint); font-weight: 850; }
.readiness-icon { width: 36px; height: 36px; }
.panel { border: 1px solid var(--border); border-radius: var(--radius); background: #0b1512; }
.panel-heading { min-height: 74px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 17px 20px; border-bottom: 1px solid var(--border); }
.panel-heading h2 { margin: 0; font-size: 17px; font-weight: 650; letter-spacing: -.02em; }
.panel-heading .section-kicker { margin-bottom: 4px; font-size: 8px; }
.task-list { min-height: 275px; }
.task-row { display: grid; grid-template-columns: 34px minmax(150px, 1fr) 120px 115px auto; align-items: center; gap: 13px; padding: 14px 20px; border-bottom: 1px solid #172722; cursor: pointer; transition: background .15s; }
.task-row:last-child { border-bottom: 0; }
.task-row:hover { background: #101d19; }
.task-symbol { width: 31px; height: 31px; display: grid; place-items: center; border: 1px solid var(--border); border-radius: 8px; color: var(--mint); font-size: 11px; }
.task-main { min-width: 0; }
.task-main b { display: block; overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.task-main small, .task-cell { color: var(--faint); font-size: 10px; }
.status-pill { width: fit-content; display: inline-flex; align-items: center; gap: 6px; padding: 5px 8px; border: 1px solid var(--border); border-radius: 999px; background: #101c18; color: #aabbb4; font-size: 9px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.status-pill::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: #74857f; }
.status-pill[data-status="succeeded"] { border-color: #50dca735; color: var(--mint); }
.status-pill[data-status="succeeded"]::before { background: var(--mint); }
.status-pill[data-status="running"], .status-pill[data-status="planning"], .status-pill[data-status="validating"] { border-color: #79a9ff35; color: #9bbcff; }
.status-pill[data-status="running"]::before, .status-pill[data-status="planning"]::before, .status-pill[data-status="validating"]::before { background: var(--blue); box-shadow: 0 0 8px var(--blue); }
.status-pill[data-status="waiting_approval"], .status-pill[data-status="waiting_human_review"] { border-color: #f2bf6840; color: var(--amber); }
.status-pill[data-status="waiting_approval"]::before, .status-pill[data-status="waiting_human_review"]::before { background: var(--amber); }
.status-pill[data-status="failed"], .status-pill[data-status="cancelled"] { border-color: #ff7c7838; color: var(--red); }
.status-pill[data-status="failed"]::before, .status-pill[data-status="cancelled"]::before { background: var(--red); }
.approval-preview { min-height: 275px; padding: 18px; }
.approval-card-mini { padding: 15px; border: 1px solid var(--border); border-radius: 11px; background: #0e1b17; }
.approval-card-mini + .approval-card-mini { margin-top: 10px; }
.approval-card-mini b { display: block; margin-bottom: 7px; font-size: 12px; }
.approval-card-mini small { color: var(--muted); }
.risk { display: inline-block; padding: 3px 6px; border-radius: 5px; background: #f2bf6812; color: var(--amber); font-size: 8px; font-weight: 850; text-transform: uppercase; }
.empty-state { min-height: 220px; display: grid; place-items: center; padding: 30px; color: var(--faint); text-align: center; }
.empty-state div { max-width: 320px; }
.empty-state i { display: grid; place-items: center; width: 42px; height: 42px; margin: 0 auto 12px; border: 1px solid var(--border); border-radius: 12px; color: var(--mint); font-style: normal; }
.empty-state b { display: block; margin-bottom: 5px; color: #b9c7c2; font-size: 12px; }
.empty-state p { margin: 0; font-size: 11px; line-height: 1.6; }

.cards-grid { display: grid; grid-template-columns: repeat(3, minmax(240px, 1fr)); gap: 14px; }
.project-card { min-height: 190px; display: flex; flex-direction: column; padding: 20px; border: 1px solid var(--border); border-radius: var(--radius); background: linear-gradient(145deg, #101c18, #0a1512); }
.project-card:hover { border-color: #375248; transform: translateY(-1px); }
.project-card-top { display: flex; align-items: flex-start; justify-content: space-between; }
.project-glyph { width: 40px; height: 40px; display: grid; place-items: center; border: 1px solid #76e7b733; border-radius: 11px; background: #76e7b70b; color: var(--mint); }
.project-card h2 { margin: 20px 0 5px; font-size: 16px; }
.project-card p { margin: 0; color: var(--faint); font-size: 10px; }
.project-card footer { display: flex; justify-content: space-between; margin-top: auto; padding-top: 18px; color: var(--faint); font-size: 9px; }
.agent-grid { display: grid; grid-template-columns: repeat(3, minmax(260px, 1fr)); gap: 14px; }
.agent-card { min-height: 275px; display: flex; flex-direction: column; gap: 15px; padding: 19px; border: 1px solid var(--border); border-radius: var(--radius); background: linear-gradient(145deg, #101d19, #0a1411); }
.agent-card:hover { border-color: #365149; transform: translateY(-1px); }
.agent-card__top, .agent-identity { display: flex; align-items: center; gap: 11px; }
.agent-card__top { justify-content: space-between; }
.agent-avatar { width: 39px; height: 39px; font-size: 10px; letter-spacing: .03em; }
.agent-identity { min-width: 0; }
.agent-identity h2 { margin: 0 0 3px; font-size: 15px; }
.agent-identity small { display: block; overflow: hidden; max-width: 175px; color: var(--faint); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.agent-purpose { min-height: 49px; margin: 0; color: #afbeb8; font-size: 11px; line-height: 1.55; }
.agent-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.agent-tags span { padding: 5px 7px; border: 1px solid var(--border); border-radius: 999px; color: var(--muted); font-size: 8px; }
.agent-card__facts { display: flex; flex-wrap: wrap; gap: 7px 13px; color: var(--faint); font-size: 9px; }
.agent-card > .button { width: 100%; margin-top: auto; }
.status-pill[data-status="ready"], .status-pill[data-status="auto_checked"] { border-color: #50dca735; color: var(--mint); }
.status-pill[data-status="ready"]::before, .status-pill[data-status="auto_checked"]::before { background: var(--mint); }
.status-pill[data-status="enabled"] { border-color: #50dca735; color: var(--mint); }
.status-pill[data-status="enabled"]::before { background: var(--mint); }
.status-pill[data-status="locked"] { border-color: #f2bf6840; color: var(--amber); }
.status-pill[data-status="locked"]::before { background: var(--amber); }
.status-pill[data-status="catalog_only"] { color: var(--faint); }
.table-panel { overflow: hidden; }
.data-table { width: 100%; overflow-x: auto; }
.table-row { min-width: 780px; display: grid; grid-template-columns: 1.35fr 1fr .8fr .8fr .8fr; align-items: center; gap: 14px; min-height: 53px; padding: 10px 18px; border-bottom: 1px solid #172722; }
.table-row:last-child { border-bottom: 0; }
.table-row:not(.table-head):hover { background: #0f1c18; }
.table-row.table-head { min-height: 40px; background: #0e1916; color: var(--faint); font-size: 9px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.table-row > span { overflow: hidden; color: #aebdb7; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.table-row > span:first-child { color: var(--text); font-weight: 650; }
.table-row.is-clickable { cursor: pointer; }
.skill-table .table-row { min-width: 900px; grid-template-columns: 1.2fr .55fr .65fr 1.35fr auto; }
.skill-table .button-row { flex-wrap: wrap; justify-content: flex-end; }
.inline-status { min-height: 32px; padding: 8px 18px; color: var(--muted); font-size: 11px; border-bottom: 1px solid var(--border); }
.proposal-panel .task-card { margin: 12px; }
.proposal-panel .task-card ol { margin: 10px 0; padding-left: 22px; color: #aebdb7; font-size: 11px; line-height: 1.7; }
.proposal-summary { white-space: pre-wrap; overflow-wrap: anywhere; }
.proposal-panel .button-row { flex-wrap: wrap; }
.goal-command { display: grid; grid-template-columns: minmax(240px, .72fr) minmax(0, 1.5fr); gap: 28px; margin-bottom: 14px; padding: 24px; background: radial-gradient(circle at 95% 5%, #76e7b712, transparent 34%), linear-gradient(145deg, #0e1d19, #0a1411); }
.goal-command__copy h2 { margin: 0; font-size: clamp(22px, 2vw, 30px); letter-spacing: -.035em; }
.goal-command__copy > p:last-child { max-width: 440px; margin: 10px 0 0; color: var(--muted); font-size: 13px; line-height: 1.65; }
.goal-templates { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.goal-templates button { min-height: 38px; padding: 0 12px; border: 1px solid #76e7b738; border-radius: 999px; background: #76e7b70c; color: #c9eee0; font-size: 11px; font-weight: 700; transition: background .18s, border-color .18s, transform .18s; }
.goal-templates button:hover { border-color: #76e7b788; background: #76e7b719; transform: translateY(-1px); }
.goal-command__form { display: grid; gap: 10px; }
.goal-command__form textarea { min-height: 122px; padding: 15px; background: #07100ecc; font-size: 15px; }
.goal-command__actions { display: grid; grid-template-columns: minmax(150px, .42fr) auto; gap: 10px; align-items: end; }
.goal-command__actions label { display: grid; gap: 7px; }
.button--large { min-height: 46px; padding-inline: 24px; }
.field-feedback { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.field-feedback[data-status="running"] { color: var(--blue); }
.field-feedback[data-status="success"] { color: var(--mint); }
.field-feedback[data-status="error"] { color: var(--red); }
.goal-steps { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; margin: 0 0 14px; padding: 0; list-style: none; }
.goal-steps li { min-width: 0; display: flex; align-items: center; gap: 10px; padding: 12px; border: 1px solid var(--border); border-radius: 11px; background: #0b1512; }
.goal-steps li > b { width: 28px; height: 28px; display: grid; flex: 0 0 auto; place-items: center; border: 1px solid #76e7b744; border-radius: 50%; background: #76e7b70c; color: var(--mint); font-size: 10px; }
.goal-steps li.is-active { border-color: #76e7b788; background: #10241d; box-shadow: 0 0 0 1px #76e7b71f inset; }
.goal-steps li.is-active > b { background: var(--mint); color: #06100d; }
.goal-steps li.is-complete { border-color: #76e7b744; }
.goal-steps li.is-complete > b::after { content: "\2713"; }
.goal-steps li.is-complete > b { font-size: 0; }
.status-pill[data-status="review"], .status-pill[data-status="needs_attention"] { border-color: #f4bd624c; background: #f4bd6212; color: #f4bd62; }
.status-pill[data-status="in_progress"] { border-color: #6eb7ff4c; background: #6eb7ff12; color: #8bc5ff; }
.status-pill[data-status="completed"] { border-color: #76e7b74c; background: #76e7b712; color: var(--mint); }
.status-pill[data-status="rejected"] { border-color: #ff7c7c4c; background: #ff7c7c12; color: #ff9b9b; }
.goal-steps span { min-width: 0; display: grid; gap: 3px; }
.goal-steps strong { font-size: 11px; }
.goal-steps small { overflow: hidden; color: var(--faint); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.goal-card { margin: 12px; padding: 18px; border-radius: 13px; background: linear-gradient(145deg, #0f1c18, #0a1411); }
.goal-card__title { min-width: 0; display: flex; align-items: center; gap: 11px; }
.goal-card__title > div { min-width: 0; display: grid; gap: 4px; }
.goal-card__title b { overflow: hidden; font-size: 15px; text-overflow: ellipsis; white-space: nowrap; }
.goal-card__title small { color: var(--muted); font-size: 10px; }
.goal-card__index { width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid #76e7b744; border-radius: 10px; background: #76e7b70c; color: var(--mint); font-size: 11px; font-weight: 850; }
.goal-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 14px 0; }
.goal-facts > span { display: grid; gap: 4px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 9px; background: #08110f; }
.goal-facts small { color: var(--faint); font-size: 8px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.goal-facts b { font-size: 12px; }
.goal-progress { display: grid; gap: 7px; margin: 13px 0; }
.goal-progress__head { display: flex; justify-content: space-between; color: var(--muted); font-size: 10px; }
.goal-progress__head b { color: var(--text); }
.goal-progress__track { height: 7px; overflow: hidden; border-radius: 99px; background: #172722; }
.goal-progress__track i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--mint-strong), var(--mint)); transition: width .25s ease; }
.goal-task-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; margin: 14px 0; padding: 0; list-style: none; }
.goal-task-list li { display: grid; grid-template-columns: 25px minmax(0, 1fr); gap: 9px; align-items: center; padding: 9px; border: 1px solid var(--border); border-radius: 8px; background: #091310; }
.goal-task-list li > span { width: 25px; height: 25px; display: grid; place-items: center; border-radius: 7px; background: var(--surface-3); color: var(--muted); font-size: 9px; }
.goal-task-list li > div { min-width: 0; display: grid; gap: 3px; }
.goal-task-list b, .goal-task-list small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.goal-task-list b { font-size: 10px; }
.goal-task-list small { color: var(--faint); font-size: 8px; }
.goal-card__actions { justify-content: flex-end; margin-top: 15px; }
.section-divider { display: flex; align-items: center; gap: 12px; margin: 28px 0 14px; color: var(--faint); font-size: 9px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.section-divider::before, .section-divider::after { content: ""; height: 1px; flex: 1; background: var(--border); }
#artifacts-table .table-row { min-width: 920px; grid-template-columns: 1.25fr 1fr .8fr .7fr .7fr auto; }
#deployment-targets-table .table-row { min-width: 940px; grid-template-columns: 1.1fr .75fr 1.5fr .65fr .9fr auto; }
.brain-toolbar { display: grid; grid-template-columns: auto minmax(180px, 1fr) auto minmax(220px, 1.4fr) auto; gap: 12px; align-items: end; margin-bottom: 18px; padding: 16px 18px; }
.brain-toolbar label { align-self: center; margin: 0; }
.brain-body { max-height: 42vh; overflow: auto; padding: 16px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #08110f; color: #c7d4cf; white-space: pre-wrap; overflow-wrap: anywhere; }
.brain-citation { display: grid; gap: 4px; margin-top: 14px; padding: 12px; border-left: 2px solid var(--accent); background: rgba(78, 226, 164, .05); }
.load-more { width: calc(100% - 36px); margin: 14px 18px; }
.approval-list { display: grid; gap: 12px; }
.approval-card { display: grid; grid-template-columns: 1fr auto; gap: 24px; padding: 20px; border: 1px solid var(--border); border-radius: var(--radius); background: #0b1512; }
.approval-card h2 { margin: 6px 0 11px; font-size: 17px; }
.approval-meta { display: flex; flex-wrap: wrap; gap: 8px 18px; color: var(--muted); font-size: 10px; }
.approval-meta code { color: #8ea39b; }
.approval-actions { display: flex; align-items: center; gap: 8px; }

.toast-region { position: fixed; z-index: 200; right: 20px; bottom: 20px; display: grid; gap: 8px; pointer-events: none; }
.toast { max-width: 390px; padding: 12px 15px; border: 1px solid var(--border-bright); border-radius: 10px; background: #11201bcc; color: #dbe6e2; box-shadow: 0 16px 45px #0009; backdrop-filter: blur(14px); font-size: 12px; animation: toast-in .2s ease; }
.toast.is-error { border-color: #ff7c7855; color: #ffb0ad; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } }

.modal { width: min(640px, calc(100% - 28px)); max-height: calc(100vh - 36px); overflow-y: auto; padding: 0; border: 1px solid var(--border-bright); border-radius: 16px; background: #0b1613; color: var(--text); box-shadow: 0 40px 100px #000c; }
.modal--small { width: min(470px, calc(100% - 28px)); }
.modal::backdrop { background: #02060480; backdrop-filter: blur(3px); }
.modal form, #task-detail { display: grid; gap: 11px; padding: 24px; }
.artifact-preview-detail { display: grid; gap: 11px; padding: 24px; }
.preview-mode-tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.artifact-render-panel { overflow: hidden; border: 1px solid var(--border); border-radius: 12px; background: #fff; }
.artifact-render-panel .inline-status { min-height: 42px; display: flex; align-items: center; margin: 0; padding: 0 14px; border-bottom: 1px solid var(--border); background: #0b1512; color: var(--muted); font-size: 10px; }
.artifact-render-panel iframe { width: 100%; height: min(68vh, 760px); display: block; border: 0; background: #fff; }
.artifact-preview-toolbar { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; }
.artifact-preview-source { min-height: 320px; max-height: 55vh; overflow: auto; margin: 0; padding: 16px; border: 1px solid var(--border); border-radius: 10px; background: #050b09; color: #d8eee6; white-space: pre; tab-size: 2; font: 12px/1.55 ui-monospace, SFMono-Regular, Consolas, monospace; }
.workspace-file-toolbar { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 14px; padding: 16px 18px; }
.workspace-editor-panel { padding: 18px; }
.workspace-file-editor { width: 100%; min-height: 480px; resize: vertical; border: 1px solid var(--border); border-radius: 10px; padding: 16px; background: #050b09; color: #d8eee6; tab-size: 2; font: 12px/1.55 ui-monospace, SFMono-Regular, Consolas, monospace; }
.modal-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 8px; }
.modal-heading h2 { margin: 0; font-size: 22px; letter-spacing: -.025em; }
.modal-heading .section-kicker { margin-bottom: 5px; }
.launcher-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 0 0 8px; padding: 0; list-style: none; }
.launcher-steps li { display: flex; align-items: center; gap: 7px; padding: 8px; border: 1px solid var(--border); border-radius: 8px; color: var(--faint); font-size: 9px; font-weight: 750; text-transform: uppercase; }
.launcher-steps b { width: 19px; height: 19px; display: grid; place-items: center; border-radius: 50%; background: var(--surface-3); color: var(--muted); font-size: 8px; }
.launcher-steps li.is-active { border-color: #76e7b739; color: var(--mint); }
.launcher-steps li.is-active b { background: var(--mint); color: #06110d; }
.agent-selection { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 13px; border: 1px solid #76e7b72c; border-radius: 11px; background: #76e7b709; }
.agent-selection b { font-size: 12px; }
.agent-selection p { margin: 3px 0; color: var(--muted); font-size: 10px; line-height: 1.45; }
.agent-selection small { color: var(--faint); font-size: 8px; }
.secret-notice { display: flex; align-items: flex-start; gap: 12px; padding: 13px; border: 1px solid #76e7b72c; border-radius: 10px; background: #76e7b709; }
.secret-notice > span { font-size: 19px; }
.secret-notice b { font-size: 11px; }
.secret-notice p { margin: 4px 0 0; color: var(--muted); font-size: 9px; line-height: 1.55; }
.advanced-options { border: 1px solid var(--border); border-radius: 10px; background: #0d1916; }
.advanced-options summary { padding: 12px; color: #b8c7c1; cursor: pointer; font-size: 11px; font-weight: 700; }
.advanced-options[open] summary { border-bottom: 1px solid var(--border); }
.advanced-options .form-row { padding: 12px; }
.task-launcher { display: grid; grid-template-columns: minmax(180px, 1fr) auto; align-items: end; gap: 10px; padding: 13px; border: 1px solid var(--border); border-radius: 10px; background: #0d1916; }
.task-launcher label { display: grid; gap: 6px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.check-row { display: flex; align-items: center; gap: 10px; margin-top: 6px; padding: 12px; border: 1px solid var(--border); border-radius: 9px; background: #0e1916; }
.check-row input { width: 16px; height: 16px; accent-color: var(--mint); }
.modal-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 13px; padding-top: 17px; border-top: 1px solid var(--border); }
.task-detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.detail-item { padding: 12px; border: 1px solid var(--border); border-radius: 9px; background: #0e1916; }
.detail-item small { display: block; margin-bottom: 5px; color: var(--faint); font-size: 8px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.detail-item b { font-size: 12px; overflow-wrap: anywhere; }
.detail-objective { margin: 0; color: #c6d3ce; line-height: 1.6; }
.detail-error { padding: 10px; border: 1px solid #ff7c7833; border-radius: 8px; background: #ff7c780d; color: #ffaaa7; font-family: ui-monospace, monospace; font-size: 11px; }

.omni-control-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
.omni-control-card { padding: 19px; background: radial-gradient(circle at 100% 0, #76e7b70d, transparent 38%), linear-gradient(145deg, #101d19, #0a1411); }
.omni-control-card .panel-heading { margin-bottom: 14px; }
.omni-live-dot { display: inline-flex; align-items: center; gap: 7px; color: var(--mint); font-size: 9px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.omni-live-dot::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 10px #76e7b799; }
.omni-facts { display: grid; gap: 8px; }
.omni-fact { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px; align-items: center; min-height: 42px; padding: 9px 11px; border: 1px solid #1d302a; border-radius: 9px; background: #0a1512aa; }
.omni-fact span { color: var(--muted); font-size: 10px; }
.omni-fact b { color: #d7e3de; font-size: 10px; text-align: right; }
.omni-panel { margin-top: 14px; }
.omni-panel .panel-heading { padding: 18px; border-bottom: 1px solid #172722; }
.omni-panel .panel-heading h2 { margin-bottom: 4px; }
.omni-panel .panel-heading p:last-child { margin: 0; color: var(--faint); font-size: 9px; }
.omni-profile-table .table-row { min-width: 1040px; grid-template-columns: 1.15fr 1.25fr 1fr 1fr .72fr auto; }
.omni-model-table .table-row { min-width: 960px; grid-template-columns: 1.15fr 1.2fr .7fr .85fr 1fr .65fr; }
.omni-routes-table .table-row { min-width: 980px; grid-template-columns: 1fr 1fr 1fr .7fr .7fr .8fr; }
.omni-row-action { min-height: 32px; padding-inline: 11px; font-size: 9px; }
.omni-route-stack { display: grid; gap: 2px; min-width: 0; }
.omni-route-stack b { overflow: hidden; color: var(--text); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.omni-route-stack small { overflow: hidden; color: var(--faint); font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }
.plugin-panel { margin-top: 14px; }
.plugin-panel .panel-heading { padding: 18px; border-bottom: 1px solid var(--border); }
.plugin-catalog-table .table-row { min-width: 1020px; grid-template-columns: 1.2fr 1fr 1.35fr 1.15fr .85fr auto; }
.plugin-installations-table .table-row { min-width: 960px; grid-template-columns: 1.1fr 1.1fr .8fr .8fr 1fr auto; }
.mcp-catalog-table .table-row { min-width: 1040px; grid-template-columns: 1.15fr .8fr 1.2fr 1.2fr .8fr auto; }
.mcp-bindings-table .table-row { min-width: 940px; grid-template-columns: 1.1fr 1.1fr .8fr .9fr 1fr auto; }
.consent-summary { display: grid; gap: 7px; margin: 14px 0; padding: 14px; border: 1px solid var(--border); border-radius: 10px; background: #0a1512; }
.consent-summary b { color: var(--text); font-size: 10px; }
.consent-summary p, .consent-summary pre { margin: 0 0 7px; color: var(--muted); font: 10px/1.55 ui-monospace, monospace; white-space: pre-wrap; overflow-wrap: anywhere; }
.omni-health-bar { width: 82px; height: 5px; overflow: hidden; border-radius: 99px; background: #1a2924; }
.omni-health-bar i { display: block; height: 100%; border-radius: inherit; background: var(--mint); }

.chat-status[data-status="error"] { border-color: #ff7c7838; background: linear-gradient(90deg, #ff7c780d, #0c1815); }
.chat-status[data-status="error"] .readiness-icon { border-color: #ff7c7848; background: #ff7c7810; color: var(--red); }
.chat-status[data-status="running"] .readiness-icon { color: var(--blue); }
.chat-toolbar { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-bottom: 14px; padding: 16px 18px; }
.build-settings, .advanced-conversation { margin-bottom: 14px; }
.build-settings > summary, .advanced-conversation > summary { width: fit-content; min-height: 44px; display: flex; align-items: center; gap: 8px; padding: 0 14px; border: 1px solid var(--border); border-radius: 10px; background: #0c1714; color: #b9c9c3; cursor: pointer; font-size: 12px; font-weight: 750; list-style: none; }
.build-settings > summary::-webkit-details-marker, .advanced-conversation > summary::-webkit-details-marker { display: none; }
.build-settings > summary::before, .advanced-conversation > summary::before { content: "+"; color: var(--mint); }
.build-settings[open] > summary::before, .advanced-conversation[open] > summary::before { content: "−"; }
.build-settings[open] > .chat-toolbar { margin-top: 10px; }
.advanced-conversation[open] > .section-divider { margin-top: 22px; }
.chat-toolbar > div { display: grid; gap: 7px; }
.chat-toolbar .muted { margin: 0; color: var(--faint); font-size: 9px; line-height: 1.5; }
.chat-shell { display: grid; grid-template-columns: minmax(260px, .72fr) minmax(0, 2fr); gap: 14px; align-items: stretch; }
.chat-threads, .chat-conversation { min-height: 610px; overflow: hidden; }
.chat-thread-form { display: grid; gap: 8px; padding: 14px; border-bottom: 1px solid var(--border); }
.chat-thread-form > div { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
.chat-thread-form input { height: 42px; }
.chat-thread-form .button { min-height: 42px; }
.chat-thread-list { max-height: 465px; overflow-y: auto; }
.chat-thread-list .empty-state { min-height: 230px; }
.chat-thread-item { width: 100%; display: grid; grid-template-columns: 31px minmax(0, 1fr); gap: 10px; align-items: center; padding: 13px 14px; border: 0; border-bottom: 1px solid #172722; background: transparent; color: var(--text); text-align: left; }
.chat-thread-item:hover { background: #101d19; }
.chat-thread-item:focus-visible { position: relative; z-index: 1; outline: 2px solid var(--mint); outline-offset: -3px; }
.chat-thread-item.is-active { background: #14231e; }
.chat-thread-item > span:nth-child(2) { min-width: 0; }
.chat-thread-item b, .chat-thread-item small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-thread-item b { font-size: 11px; }
.chat-thread-item small { margin-top: 4px; color: var(--faint); font-size: 8px; }
.chat-thread-glyph { width: 31px; height: 31px; display: grid; place-items: center; border: 1px solid #76e7b733; border-radius: 8px; background: #76e7b70a; color: var(--mint); font-size: 9px; font-weight: 850; }
.chat-conversation { display: grid; grid-template-rows: auto minmax(310px, 1fr) auto; }
.chat-transcript { max-height: 540px; overflow-y: auto; display: flex; flex-direction: column; gap: 12px; padding: 20px; background: radial-gradient(circle at 100% 0, #76e7b708, transparent 36%); scroll-behavior: smooth; }
.chat-transcript .empty-state { min-height: 300px; }
.chat-message { width: min(78%, 760px); padding: 13px 15px; border: 1px solid var(--border); border-radius: 12px 12px 12px 3px; background: #101d19; }
.chat-message--user { align-self: flex-end; border-color: #76e7b72e; border-radius: 12px 12px 3px 12px; background: #76e7b70c; }
.chat-message header { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 7px; color: var(--faint); font-size: 8px; }
.chat-message header b { color: var(--mint); font-size: 9px; }
.chat-message p { margin: 0; color: #cad6d1; font-size: 12px; line-height: 1.65; white-space: pre-wrap; overflow-wrap: anywhere; }
.chat-composer { display: grid; gap: 8px; padding: 16px 18px; border-top: 1px solid var(--border); background: #0d1815; }
.chat-composer textarea { min-height: 92px; max-height: 280px; }
.chat-composer-foot { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 12px; align-items: center; }
.chat-composer-foot .muted { margin: 0; color: var(--faint); font-size: 9px; line-height: 1.45; }
.chat-composer-foot output { color: var(--faint); font-size: 9px; font-variant-numeric: tabular-nums; }

.telegram-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-bottom: 14px; }
.telegram-panel { overflow: hidden; }
.telegram-panel-body { display: grid; gap: 13px; padding: 20px; }
.telegram-panel-body > .muted { margin: -4px 0 2px; font-size: 10px; line-height: 1.55; }
.telegram-shield { width: 36px; height: 36px; display: grid; place-items: center; border: 1px solid #76e7b744; border-radius: 10px; background: #76e7b710; color: var(--mint); font-size: 12px; font-weight: 900; }
.telegram-code-card { padding: 15px; border: 1px dashed #76e7b766; border-radius: 11px; background: #76e7b709; }
.telegram-code-card > p:not(.section-kicker) { margin: 11px 0 0; color: #becdc7; font-size: 11px; line-height: 1.55; }
.telegram-code-line { display: flex; align-items: center; gap: 10px; }
.telegram-code-line code { min-width: 0; flex: 1; overflow-wrap: anywhere; color: var(--mint); font-size: 19px; font-weight: 800; letter-spacing: .08em; }
.telegram-code-line .button { flex: 0 0 auto; }
.telegram-expiry { color: var(--muted) !important; }
.telegram-expiry time { color: var(--amber); font-variant-numeric: tabular-nums; }
.telegram-steps { display: grid; gap: 11px; margin: 0; padding: 0; list-style: none; }
.telegram-steps li { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 11px; align-items: start; color: #b7c6c0; font-size: 11px; line-height: 1.55; }
.telegram-steps b { width: 28px; height: 28px; display: grid; place-items: center; border: 1px solid #76e7b744; border-radius: 50%; background: #76e7b710; color: var(--mint); font-size: 10px; }
.telegram-steps code { color: var(--mint); }
.telegram-security-note { padding: 13px; border: 1px solid #76e7b72c; border-radius: 10px; background: #76e7b708; }
.telegram-security-note b { font-size: 11px; }
.telegram-security-note p { margin: 5px 0 0; color: var(--muted); font-size: 9px; line-height: 1.55; }
.telegram-security-note--warning { border-color: #f2bf6840; background: #f2bf680a; }
.telegram-bindings-panel { margin-top: 14px; }
.telegram-bindings-panel .panel-heading p:last-child { margin: 4px 0 0; color: var(--faint); font-size: 9px; }
.telegram-binding-row { min-width: 800px; grid-template-columns: 1.25fr 1.1fr 1fr 1fr auto; }
.telegram-binding-action { display: flex; justify-content: flex-end; }
.telegram-revoke-button { min-height: 32px; padding-inline: 12px; font-size: 9px; }

.skeleton { position: relative; overflow: hidden; min-height: 16px; border-radius: 6px; background: #14231f; }
.skeleton::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, #ffffff09, transparent); transform: translateX(-100%); animation: shimmer 1.4s infinite; }
@keyframes shimmer { to { transform: translateX(100%); } }

@media (max-width: 1100px) {
  .metrics-grid { grid-template-columns: repeat(2, 1fr); }
  .overview-grid { grid-template-columns: 1fr; }
  .cards-grid { grid-template-columns: repeat(2, 1fr); }
  .agent-grid { grid-template-columns: repeat(2, minmax(240px, 1fr)); }
  .omni-control-grid { grid-template-columns: 1fr; }
  .telegram-grid { grid-template-columns: 1fr; }
  .chat-shell { grid-template-columns: minmax(230px, .75fr) minmax(0, 1.6fr); }
}

@media (max-width: 820px) {
  .goal-command { grid-template-columns: 1fr; }
  .goal-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .chat-toolbar, .chat-shell { grid-template-columns: 1fr; }
  .chat-threads, .chat-conversation { min-height: auto; }
  .chat-thread-list { max-height: 280px; }
  .chat-transcript { min-height: 390px; }
  .brain-toolbar { grid-template-columns: 1fr; align-items: stretch; }
  .auth-shell { grid-template-columns: 1fr; }
  .auth-story { min-height: 40vh; padding: 28px; border-right: 0; border-bottom: 1px solid var(--border); }
  .auth-copy { margin: 70px 0; }
  .auth-copy h1 { font-size: clamp(38px, 10vw, 58px); }
  .auth-panel { min-height: 60vh; padding: 45px 24px; }
  .app-shell { grid-template-columns: 1fr; }
  .sidebar { transform: translateX(-102%); transition: transform .22s ease; box-shadow: 20px 0 60px #0008; }
  body.nav-open .sidebar { transform: translateX(0); }
  .workspace { grid-column: 1; }
  .menu-toggle { display: grid; }
  .profile-button > span:nth-child(2), .profile-button > i, .live-state { display: none; }
  .content { padding: 28px 20px; }
  .topbar { padding: 0 16px; }
  .org-switcher label { display: none; }
  .org-switcher select { min-width: 130px; max-width: 42vw; }
  .approval-card { grid-template-columns: 1fr; }
  .approval-actions { justify-content: flex-start; }
}

.inline-form {
  display: grid;
  grid-template-columns: minmax(16rem, 2fr) minmax(12rem, 1fr) auto;
  gap: 1rem;
  align-items: end;
  padding: 1.25rem;
}

.inline-form label {
  display: grid;
  gap: .45rem;
  color: var(--muted);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.integration-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-bottom: 14px; }
.integration-card { display: grid; gap: 16px; padding: 22px; border: 1px solid var(--border); border-radius: 14px; background: linear-gradient(145deg, #0c1915, #09120f); }
.integration-card__head { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; }
.integration-card__head h2 { margin: 2px 0 0; font-size: 19px; }
.integration-card__head p, .integration-card > p { margin: 0; }
.integration-mark { width: 40px; height: 40px; display: grid; place-items: center; border: 1px solid #76e7b744; border-radius: 11px; background: #76e7b710; color: var(--mint); font-weight: 800; }
.integration-card dl { display: grid; gap: 8px; margin: 0; }
.integration-card dl div { display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 10px; }
.integration-card dt { color: var(--faint); font-size: 10px; text-transform: uppercase; }
.integration-card dd { min-width: 0; margin: 0; color: var(--muted); overflow-wrap: anywhere; }
.integration-card code { color: #b8d8ca; }

@media (max-width: 760px) {
  .inline-form, .integration-grid { grid-template-columns: 1fr; }
}

@media (max-width: 580px) {
  .goal-command { padding: 18px; }
  .goal-command__actions, .goal-facts, .goal-task-list, .goal-steps { grid-template-columns: 1fr; }
  .auth-story { min-height: auto; }
  .auth-copy { margin: 58px 0 45px; }
  .auth-signals { display: none; }
  .page-heading { align-items: flex-start; flex-direction: column; }
  .metrics-grid, .cards-grid { grid-template-columns: 1fr; }
  .agent-grid { grid-template-columns: 1fr; }
  .readiness-banner { grid-template-columns: auto 1fr; }
  .readiness-banner .button { grid-column: 1 / -1; width: 100%; }
  .proposal-panel .panel-heading { align-items: stretch; }
  .proposal-panel .panel-heading .button { width: 100%; }
  .proposal-panel .task-card { margin: 8px; }
  .proposal-panel .button-row .button { flex: 1 1 44%; }
  .agent-selection { grid-template-columns: auto 1fr; }
  .agent-selection .status-pill { grid-column: 1 / -1; }
  .task-launcher { grid-template-columns: 1fr; }
  .metric-card { min-height: 120px; }
  .task-row { grid-template-columns: 32px minmax(0, 1fr) auto; }
  .task-row .task-cell { display: none; }
  .form-row, .task-detail-grid { grid-template-columns: 1fr; }
  .approval-actions { flex-wrap: wrap; }
  .telegram-code-line { align-items: stretch; flex-direction: column; }
  .telegram-code-line .button { width: 100%; }
  .chat-thread-form > div, .chat-composer-foot { grid-template-columns: 1fr; }
  .artifact-preview-toolbar { grid-template-columns: 1fr; }
  .workspace-file-toolbar { grid-template-columns: 1fr; }
  .chat-thread-form .button, .chat-composer-foot .button { width: 100%; }
  .chat-message { width: 92%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
.integration-evidence {
  margin: 0;
  max-height: 9rem;
  max-width: 28rem;
  overflow: auto;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: .72rem;
}
