:root {
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #e5e7eb;
  background: #0b1120;
  font-synthesis: none;
  --bg: #0b1120;
  --surface: #111827;
  --surface-2: #172033;
  --border: #27344a;
  --muted: #8b98ad;
  --text: #e5e7eb;
  --blue: #4f8cff;
  --cyan: #42c7d6;
  --orange: #f2a35a;
  --red: #ed796c;
  --green: #56c596;
  --violet: #9e8df7;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 0; background: var(--bg); color: var(--text); }
button { font: inherit; }
.app-shell { display: flex; min-height: 100vh; }
.sidebar { width: 242px; min-height: 100vh; background: #0f1728; border-right: 1px solid #1e2a3f; padding: 27px 17px 20px; display: flex; flex-direction: column; }
.brand-lockup { display: flex; align-items: center; gap: 11px; padding: 0 9px 26px; }
.brand-mark { width: 42px; height: 42px; border-radius: 10px; display: grid; place-items: center; font-weight: 800; letter-spacing: -.04em; color: #07101e; background: linear-gradient(135deg, #6bd8dd, #5e8dff); }
.brand-lockup strong, .brand-lockup span { display: block; }
.brand-lockup strong { font-size: 14px; letter-spacing: .01em; }
.brand-lockup span { color: var(--muted); font-size: 11px; margin-top: 3px; }
.scenario-badge { margin: 0 9px 25px; border: 1px solid #344059; color: #a8b5ca; border-radius: 5px; padding: 8px 9px; font-size: 9px; letter-spacing: .1em; }
.status-dot, .online-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 3px #193b3a; margin-right: 6px; }
.nav-list { display: grid; gap: 6px; }
.nav-item { border: 0; background: transparent; color: #95a3b8; text-align: left; padding: 11px 10px; border-radius: 6px; cursor: pointer; font-size: 12px; display: flex; align-items: center; gap: 11px; }
.nav-item.active { color: #f2f6ff; background: #1a2a45; box-shadow: inset 3px 0 0 var(--blue); }
.nav-item:hover { color: #fff; background: #17243a; }
.nav-glyph { font-size: 9px; color: #63718a; letter-spacing: .08em; }
.nav-item.active .nav-glyph { color: #7baaff; }
.sidebar-foot { margin-top: auto; padding: 18px 8px 0; border-top: 1px solid #202c41; }
.operator-row { display: flex; align-items: center; gap: 9px; font-size: 11px; position: relative; }
.operator-row strong, .operator-row small { display: block; }
.operator-row small { color: var(--muted); margin-top: 3px; font-size: 10px; }
.avatar, .profile-button { display: grid; place-items: center; border-radius: 50%; background: #273b64; color: #bed3ff; font-weight: 700; }
.avatar { width: 29px; height: 29px; font-size: 9px; }
.online-dot { margin-left: auto; width: 6px; height: 6px; box-shadow: none; }
.version { color: #53627a; font-size: 9px; margin-top: 18px; }
.main-content { flex: 1; padding: 28px 35px 17px; max-width: 1680px; margin: 0 auto; width: 100%; }
.topbar { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 25px; }
.eyebrow, .section-kicker { color: #70819a; letter-spacing: .14em; font-size: 9px; font-weight: 700; }
h1, h2, p { margin: 0; }
h1 { font-size: 25px; letter-spacing: -.02em; margin-top: 7px; }
h2 { font-size: 15px; letter-spacing: -.01em; margin-top: 5px; }
.top-actions { display: flex; align-items: center; gap: 16px; padding-top: 4px; }.scenario-select { display: flex; align-items: center; gap: 7px; color: #718198; font-size: 10px; }.scenario-select select { appearance: none; color: #bdc9da; background: #131e31; border: 1px solid #34435d; border-radius: 5px; padding: 7px 26px 7px 9px; font: inherit; outline: none; max-width: 205px; }.scenario-select select:focus { border-color: #76a7ff; box-shadow: 0 0 0 2px #4779c533; }
.last-sync { color: #718198; font-size: 10px; }
.ghost-button { color: #9eabc0; background: transparent; border: 1px solid #33415a; border-radius: 5px; padding: 8px 12px; cursor: pointer; font-size: 10px; }
.ghost-button:hover { border-color: #6c7e9d; color: #fff; }
.profile-button { border: 0; width: 32px; height: 32px; font-size: 10px; cursor: pointer; }
.metric-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 13px; margin-bottom: 15px; }
.metric-card { min-height: 111px; padding: 16px 18px; border: 1px solid var(--border); border-radius: 7px; background: #111a2c; }
.metric-card.critical-card { border-top: 2px solid var(--red); }
.metric-label { color: #8b99ae; font-size: 11px; }
.metric-value { color: #f2f5fb; font-weight: 700; font-size: 29px; line-height: 1; margin-top: 16px; letter-spacing: -.04em; }
.unit { font-size: 15px; margin-left: 3px; color: #acb8ca; }
.metric-meta { margin-top: 10px; font-size: 10px; }
.metric-meta span { color: #74829a; margin-left: 5px; }
.danger { color: var(--red); }
.warning { color: var(--orange); }
.positive { color: var(--green); }
.workspace-grid { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(420px, .88fr); gap: 15px; }
.left-column, .right-column { display: grid; align-content: start; gap: 15px; }
.panel { border: 1px solid var(--border); border-radius: 7px; background: var(--surface); overflow: hidden; }
.incident-panel { padding: 20px 21px 18px; }
.panel-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; }
.severity-pill { color: #ffb2a6; background: #3a242c; border: 1px solid #65404b; border-radius: 4px; padding: 6px 8px; font-size: 10px; white-space: nowrap; }
.incident-summary { margin-top: 19px; border-left: 2px solid var(--orange); padding: 2px 0 2px 12px; display: flex; justify-content: space-between; gap: 20px; }
.incident-summary p { color: #aab5c6; line-height: 1.65; font-size: 12px; max-width: 610px; }
.incident-id { color: #65738b; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 9px; white-space: nowrap; align-self: flex-end; }
.signal-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 20px; }
.signal { min-height: 57px; border: 1px solid #26344a; background: #141f32; border-radius: 5px; display: flex; align-items: center; gap: 9px; padding: 9px; }
.signal-icon { width: 25px; height: 25px; display: grid; place-items: center; border-radius: 5px; font-size: 10px; font-weight: 800; }
.signal-icon.orange { color: #ffc080; background: #493528; }.signal-icon.blue { color: #9cc1ff; background: #243a62; }.signal-icon.violet { color: #c3b8ff; background: #393257; }
.signal strong, .signal span { display: block; }.signal strong { font-size: 10px; color: #cbd5e4; }.signal span { color: #71809a; font-size: 9px; margin-top: 4px; }
.agent-progress { margin: 21px 0 17px; }
.progress-head { display: flex; justify-content: space-between; color: #8693a8; font-size: 10px; }.progress-head strong { color: var(--cyan); font-weight: 600; }
.progress-track { height: 4px; background: #243149; border-radius: 9px; margin-top: 9px; overflow: hidden; }.progress-track span { display: block; height: 100%; width: 8%; background: linear-gradient(90deg, var(--cyan), var(--blue)); transition: width .4s ease; }
.agent-steps { display: flex; justify-content: space-between; margin-top: 8px; color: #596880; font-size: 9px; }.step.active { color: #b8c9e5; }
.primary-button, .approve-button { border: 0; border-radius: 5px; cursor: pointer; color: #081322; font-weight: 700; font-size: 11px; padding: 11px 15px; transition: transform .15s ease, opacity .15s ease; }.primary-button { background: #70d4d3; }.primary-button:hover, .approve-button:not(:disabled):hover { transform: translateY(-1px); }.primary-button:disabled, .approve-button:disabled { opacity: .42; cursor: not-allowed; }
.primary-button span { margin-right: 6px; }
.evidence-panel, .audit-panel { padding: 19px 21px; }
.evidence-gate { margin-top: 12px; padding: 10px 11px; border: 1px solid #76502d; border-radius: 5px; background: #2b221d; display: flex; align-items: center; justify-content: space-between; gap: 10px; }.evidence-gate[hidden] { display: none; }.evidence-gate strong, .evidence-gate span { display: block; }.evidence-gate strong { color: #f2c17e; font-size: 10px; }.evidence-gate span { color: #aa9174; font-size: 9px; line-height: 1.4; margin-top: 3px; }.gate-button { color: #1a150d; background: #f2c17e; border: 0; border-radius: 4px; cursor: pointer; font-size: 9px; font-weight: 700; padding: 8px 9px; white-space: nowrap; }.gate-button:disabled { opacity: .5; cursor: not-allowed; }
.confidence, .tiny-label, .audit-count { color: #7e8ca2; font-size: 9px; }.confidence strong { color: var(--green); margin-left: 4px; }
.empty-state { min-height: 148px; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #697890; gap: 7px; border: 1px dashed #2b3950; border-radius: 5px; margin-top: 17px; }.empty-state strong { color: #a1aec0; font-size: 11px; font-weight: 600; }.empty-state span:last-child { font-size: 9px; }.empty-icon { font-size: 21px; color: #52637c; }.empty-state.compact { min-height: 175px; margin-top: 13px; }
.timeline-panel { padding: 19px 21px 14px; }.timeline-status { color: #7e8ca2; font-size: 9px; }.timeline-chart { height: 188px; margin-top: 10px; width: 100%; }.chart-legend { display: flex; gap: 17px; align-items: center; color: #78869d; font-size: 9px; }.legend-line { display: inline-block; width: 17px; height: 2px; vertical-align: middle; margin: 0 5px 2px 0; }.orange-line { background: var(--orange); }.blue-line { background: var(--blue); }.red-line { background: var(--red); }.intervention-key { color: #c6b5ff; margin-left: auto; }
.evidence-list { margin-top: 15px; display: grid; gap: 8px; }.evidence-item { background: #141f32; border: 1px solid #26344a; border-radius: 5px; padding: 10px 11px; display: grid; grid-template-columns: auto 1fr auto; gap: 9px; align-items: start; }.evidence-marker { width: 8px; height: 8px; border-radius: 50%; margin-top: 4px; }.evidence-marker.blue { background: var(--blue); }.evidence-marker.orange { background: var(--orange); }.evidence-marker.red { background: var(--red); }.evidence-item strong { display: block; color: #c7d1df; font-size: 10px; }.evidence-item span { display: block; color: #78869d; font-size: 9px; line-height: 1.5; margin-top: 3px; }.evidence-score { color: #9fafd0 !important; font-family: ui-monospace, monospace; margin-top: 0 !important; }
.decision-panel { padding: 19px 21px 16px; }.baseline-note { color: #687892; font-size: 9px; margin-top: 9px; }.options-list { margin-top: 10px; display: grid; gap: 8px; }.option-card { position: relative; border: 1px solid #293850; border-radius: 5px; padding: 12px 12px 11px 14px; background: #141f32; cursor: pointer; transition: border-color .15s ease, background .15s ease; }.option-card:hover { border-color: #58739f; }.option-card.selected { background: #1b2e48; border-color: #6c9bff; box-shadow: inset 3px 0 0 var(--blue); }.option-radio { position: absolute; right: 12px; top: 13px; width: 13px; height: 13px; border-radius: 50%; border: 1px solid #5b6d88; }.selected .option-radio { border: 4px solid #76a7ff; }.option-title { padding-right: 22px; color: #dae2ee; font-size: 11px; font-weight: 700; }.option-desc { color: #8491a7; font-size: 9px; line-height: 1.45; margin-top: 5px; max-width: 90%; }.option-metrics { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 11px; padding-top: 9px; border-top: 1px solid #293850; }.option-metrics span { color: #78869d; font-size: 9px; }.option-metrics strong { display: block; color: #c7d3e4; font-size: 11px; margin-top: 3px; }.option-metrics .good { color: var(--green); }.option-metrics .bad { color: var(--red); }.option-metrics .warn { color: var(--orange); }
.decision-footer { border-top: 1px solid #26344a; margin-top: 14px; padding-top: 13px; display: flex; gap: 12px; justify-content: space-between; align-items: center; }.approval-note { display: flex; gap: 8px; color: #8d9ab0; font-size: 9px; }.approval-note strong, .approval-note small { display: block; }.approval-note strong { color: #c6d2e3; font-size: 10px; margin-top: 3px; }.approval-note small { color: #66758c; margin-top: 3px; }.lock-icon { color: var(--green); font-size: 14px; }.decision-actions { display: flex; align-items: center; gap: 7px; }.approve-button { background: #69d1a4; white-space: nowrap; }.rollback-button { color: #ffaaa0; background: #35232b; border: 1px solid #68404b; border-radius: 5px; cursor: pointer; font-size: 10px; padding: 10px 11px; white-space: nowrap; }.rollback-button:hover:not(:disabled) { background: #4a2b35; }.rollback-button:disabled { opacity: .42; cursor: not-allowed; }
.audit-trail { margin-top: 17px; border-left: 1px solid #31405a; padding-left: 15px; display: grid; gap: 14px; min-height: 83px; }.audit-empty { color: #697890; font-size: 10px; padding: 15px 0; }.audit-entry { position: relative; }.audit-entry::before { content: ""; position: absolute; width: 7px; height: 7px; border-radius: 50%; background: #5d739b; border: 2px solid var(--surface); left: -19px; top: 3px; }.audit-entry.success::before { background: var(--green); }.audit-entry strong { display: block; color: #c9d4e3; font-size: 10px; }.audit-entry span { display: block; color: #738199; font-size: 9px; margin-top: 4px; line-height: 1.45; }.audit-entry time { float: right; color: #55647d; font-size: 8px; margin-top: -14px; }
.page-footer { display: flex; justify-content: space-between; color: #53627a; font-size: 9px; padding: 17px 2px 0; }.toast { position: fixed; left: 50%; bottom: 27px; transform: translate(-50%, 18px); opacity: 0; background: #d5f7ea; color: #0e3328; padding: 10px 15px; border-radius: 5px; font-size: 11px; box-shadow: 0 8px 25px #0005; pointer-events: none; transition: all .25s ease; }.toast.show { transform: translate(-50%, 0); opacity: 1; }
@media (max-width: 1200px) { .main-content { padding-left: 24px; padding-right: 24px; }.workspace-grid { grid-template-columns: minmax(0, 1fr) minmax(390px, .9fr); } }
@media (max-width: 860px) {
  .app-shell { display: block; }
  .sidebar { width: 100%; min-height: 0; padding: 14px 16px; border-right: 0; border-bottom: 1px solid #1e2a3f; }
  .brand-lockup { padding: 0 0 12px; }
  .scenario-badge { display: inline-flex; margin: 0 0 12px; }
  .nav-list { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; }
  .nav-item { justify-content: center; padding: 9px 5px; font-size: 10px; gap: 6px; }
  .sidebar-foot { display: none; }
  .main-content { max-width: none; padding: 19px 16px 20px; }
  .topbar { flex-direction: column; gap: 13px; margin-bottom: 18px; }
  .top-actions { width: 100%; flex-wrap: wrap; gap: 9px; padding-top: 0; }
  .scenario-select { flex: 1 1 250px; justify-content: space-between; }
  .scenario-select select { max-width: none; flex: 1; }
  .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .metric-card { min-height: 96px; padding: 13px; }
  .metric-value { font-size: 25px; margin-top: 13px; }
  .workspace-grid { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .left-column, .right-column { gap: 12px; }
  .incident-summary { flex-direction: column; gap: 7px; }
  .incident-id { align-self: flex-start; }
  .signal-row { grid-template-columns: 1fr; }
  .evidence-gate { align-items: flex-start; }
  .decision-footer { align-items: stretch; flex-direction: column; }
  .decision-actions { justify-content: flex-end; }
  .page-footer { align-items: flex-start; flex-direction: column; gap: 5px; }
}
@media (max-width: 480px) {
  .nav-item { font-size: 9px; }
  .nav-glyph { display: none; }
  .last-sync { display: none; }
  .metric-grid { grid-template-columns: 1fr; }
  .panel-heading { gap: 8px; }
  .evidence-gate { flex-direction: column; }
  .gate-button { width: 100%; }
  .option-metrics { gap: 6px; }
  .approval-note { line-height: 1.35; }
}
