:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --bg: #f4f7ff;
  --surface: #ffffff;
  --surface-soft: #f8faff;
  --surface-blue: #eef5ff;
  --line: #dfe7f5;
  --line-strong: #c9d8f1;
  --ink: #10213f;
  --ink-soft: #3f5273;
  --muted: #7f8faa;
  --primary: #0b6cff;
  --primary-strong: #0758d5;
  --primary-soft: #e8f1ff;
  --cyan: #42a5ff;
  --navy: #111c35;
  --navy-soft: #192847;
  --green: #2eb67d;
  --red: #e45465;
  --amber: #e7a23b;
  background: var(--bg);
  color: var(--ink);
}

* { box-sizing: border-box; }
html { min-width: 320px; background: var(--bg); }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(circle at 92% -10%, rgba(72, 150, 255, .25), transparent 31rem),
    radial-gradient(circle at 32% 0%, rgba(197, 220, 255, .6), transparent 27rem),
    linear-gradient(180deg, #f8faff 0%, var(--bg) 100%);
}
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 3px solid rgba(11, 108, 255, .2);
  outline-offset: 2px;
}

.shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  z-index: 30;
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 22px 15px 17px;
  color: #f8fbff;
  border-right: 1px solid rgba(255, 255, 255, .07);
  overflow: hidden;
  background:
    radial-gradient(circle at 10% 3%, rgba(46, 125, 255, .3), transparent 13rem),
    linear-gradient(180deg, #121d37 0%, #0e1830 100%);
  box-shadow: 14px 0 42px rgba(20, 42, 78, .08);
}
.sidebar::after {
  content: "";
  position: absolute;
  width: 230px;
  height: 230px;
  right: -150px;
  bottom: 10%;
  border-radius: 50%;
  border: 1px solid rgba(74, 151, 255, .16);
  box-shadow: 0 0 0 34px rgba(74, 151, 255, .04), 0 0 0 68px rgba(74, 151, 255, .025);
  pointer-events: none;
}
.brand {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 3px 6px;
}
.logo {
  width: 42px;
  height: 42px;
  flex: none;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 14px;
  color: #fff;
  font-weight: 900;
  background: linear-gradient(145deg, #37a0ff, #0b6cff 62%, #0753c8);
  box-shadow: 0 12px 26px rgba(11, 108, 255, .34), inset 0 1px 0 rgba(255, 255, 255, .25);
}
.brand h1 { margin: 0; font-size: 17px; letter-spacing: -.025em; }
.brand p { margin: 3px 0 0; color: #8fa6cd; font-size: 10px; letter-spacing: .025em; }

.nav {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 6px;
}
.nav-button {
  position: relative;
  width: 100%;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 0;
  border-radius: 13px;
  padding: 11px 12px 11px 43px;
  color: #b8c5df;
  background: transparent;
  text-align: left;
  font-size: 12px;
  font-weight: 700;
  transition: background .16s ease, color .16s ease, transform .16s ease;
}
.nav-button::before {
  position: absolute;
  left: 13px;
  width: 20px;
  text-align: center;
  color: #7fa6e8;
  font-size: 16px;
  font-weight: 500;
}
.nav-button[data-view="dashboard"]::before { content: "⌂"; }
.nav-button[data-view="reports"]::before { content: "▤"; }
.nav-button[data-view="flow"]::before { content: "▦"; }
.nav-button[data-view="office"]::before { content: "✉"; }
.nav-button[data-view="deploy"]::before { content: "⌘"; }
.nav-button[data-view="reminders"]::before { content: "◷"; }
.nav-button[data-view="engineer"]::before { content: "◇"; }
.nav-button[data-view="chat"]::before { content: "◌"; }
.nav-button:hover {
  color: #fff;
  background: rgba(255, 255, 255, .065);
  transform: translateX(2px);
}
.nav-button.active {
  color: #fff;
  background: linear-gradient(100deg, rgba(20, 111, 255, .32), rgba(20, 111, 255, .11));
  box-shadow: inset 3px 0 0 #49a7ff, 0 8px 18px rgba(0, 30, 86, .13);
}
.nav-button.active::before { color: #69b8ff; }
.nav-count {
  min-width: 21px;
  height: 21px;
  padding: 0 6px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #dbeaff;
  background: rgba(121, 175, 255, .16);
  font-size: 9px;
  font-weight: 900;
}
.nav-button.active .nav-count { color: #fff; background: var(--primary); }

.office-section-head { align-items: center; }
.office-tenant-badge { padding: 8px 11px; border: 1px solid #cfe0f5; border-radius: 999px; color: #45658f; background: #f4f8ff; font-size: 10px; font-weight: 800; }
.office-layout { display: grid; grid-template-columns: minmax(0, 1fr) 310px; gap: 14px; align-items: start; }
.office-sync-form { display: grid; grid-template-columns: minmax(0, 1fr) 130px auto; gap: 10px; align-items: end; }
.office-sync-form label { display: grid; gap: 6px; color: var(--ink-soft); font-size: 10px; font-weight: 800; }
.office-sync-form input { width: 100%; padding: 10px 11px; border: 1px solid var(--line-strong); border-radius: 10px; background: #fff; font-size: 12px; }
.office-source-note { margin-top: 11px; color: var(--muted); font-size: 10px; }
.office-inbox-list { display: grid; gap: 10px; }
.office-inbox-item { padding: 13px; border: 1px solid var(--line); border-radius: 14px; background: #fff; transition: border-color .16s ease, box-shadow .16s ease; }
.office-inbox-item:hover { border-color: #b8d1f4; box-shadow: 0 10px 28px rgba(50, 100, 170, .08); }
.office-inbox-item.triaged { background: #fbfffd; }
.office-inbox-item.ignored { opacity: .66; }
.office-inbox-head { display: flex; align-items: start; justify-content: space-between; gap: 10px; }
.office-status { flex: none; padding: 4px 7px; border-radius: 999px; color: #607594; background: #eef3f9; font-size: 9px; font-weight: 900; text-transform: uppercase; }
.office-status.new { color: #0c62d8; background: #eaf3ff; }
.office-status.triaged { color: #168458; background: #e8faf1; }
.office-status.ignored { color: #7b8799; background: #f0f2f5; }
.office-snippet { margin-top: 8px; color: var(--ink-soft); font-size: 11px; line-height: 1.55; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.office-item-actions { display: flex; align-items: center; gap: 7px; margin-top: 11px; }
.small-button { padding: 7px 10px; border-radius: 8px; font-size: 10px; }
.office-linked-task { color: var(--green); font-size: 10px; font-weight: 800; }
.office-usage-card { position: sticky; top: 14px; }
.usage-status { padding: 4px 7px; border-radius: 999px; color: #168458; background: #e8faf1; font-size: 9px; font-weight: 900; }
.usage-value { margin: 13px 0 8px; color: var(--ink); font-size: 28px; font-weight: 900; letter-spacing: -.04em; }
.usage-bar { height: 9px; overflow: hidden; border-radius: 999px; background: #e9eff8; }
.usage-bar span { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #2eb67d, #0b6cff); transition: width .25s ease; }
.usage-bar span.warning { background: linear-gradient(90deg, #e7a23b, #f1c04f); }
.usage-bar span.danger { background: linear-gradient(90deg, #e45465, #c82d49); }
.usage-meta { margin-top: 8px; color: var(--muted); font-size: 10px; line-height: 1.5; }
.usage-breakdown { display: grid; gap: 8px; margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }
.usage-row { display: flex; align-items: center; justify-content: space-between; color: var(--ink-soft); font-size: 10px; }
.usage-row strong { color: var(--ink); }
.office-product-note { display: grid; gap: 5px; margin-top: 20px; padding: 12px; border-radius: 12px; color: #3d5e8d; background: #eef5ff; font-size: 10px; line-height: 1.5; }
.office-product-note strong { color: #144d9b; }

.report-hero-primary { color: #fff !important; border-color: rgba(255,255,255,.35) !important; background: rgba(255,255,255,.2) !important; }
.report-section-head { align-items: center; }
.report-privacy { display: grid; gap: 3px; max-width: 330px; padding: 10px 13px; border: 1px solid #bfe3d2; border-radius: 13px; color: #377058; background: #effbf5; font-size: 9px; line-height: 1.45; }
.report-privacy strong { color: #19714a; font-size: 10px; }
.report-launch-grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(300px, .7fr); gap: 14px; }
.report-upload-card, .report-sample-card { min-height: 290px; }
.report-credit { padding: 5px 8px; border-radius: 999px; color: #31649f; background: #edf5ff; font-size: 9px; font-weight: 850; }
.report-dropzone { min-height: 155px; display: grid; place-content: center; justify-items: center; gap: 7px; padding: 22px; border: 1.5px dashed #a9c8ed; border-radius: 16px; color: #6981a1; background: #f7fbff; text-align: center; transition: border-color .16s ease, background .16s ease, transform .16s ease; }
.report-dropzone:hover, .report-dropzone.dragging { border-color: var(--primary); background: #edf6ff; transform: translateY(-1px); }
.report-dropzone.has-file { border-style: solid; border-color: #7bc8a5; background: #f0fbf6; }
.report-dropzone strong { color: #365a84; font-size: 12px; }
.report-dropzone span { font-size: 9px; }
.report-drop-icon { width: 43px; height: 43px; display: grid; place-items: center; border-radius: 14px; color: #fff; background: linear-gradient(145deg, #40a5ff, #0b6cff); box-shadow: 0 10px 20px rgba(11,108,255,.2); font-size: 19px; font-weight: 900; }
.report-launch-controls { display: grid; grid-template-columns: minmax(180px, 1fr) auto; gap: 10px; align-items: end; margin-top: 12px; }
.report-launch-controls label { display: grid; gap: 5px; color: #7487a3; font-size: 9px; font-weight: 850; text-transform: uppercase; letter-spacing: .05em; }
.report-sample-card { position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: center; background: linear-gradient(145deg, #122341, #183a70); }
.report-sample-card::after { content: ""; position: absolute; width: 190px; height: 190px; right: -105px; top: -105px; border: 1px solid rgba(111,181,255,.28); border-radius: 50%; box-shadow: 0 0 0 34px rgba(79,151,255,.06); }
.report-sample-card h3 { position: relative; z-index: 1; margin: 10px 0 7px; color: #fff; font-size: 17px; }
.report-sample-card p { position: relative; z-index: 1; margin: 0; color: #b8cbe9; font-size: 10px; line-height: 1.6; }
.report-sample-card .primary { position: relative; z-index: 1; margin-top: 16px; }
.report-sample-badge { position: relative; z-index: 1; width: max-content; padding: 4px 7px; border-radius: 999px; color: #97c5ff; background: rgba(70,151,255,.15); font-size: 8px; font-weight: 900; letter-spacing: .09em; }
.report-sample-preview { position: relative; z-index: 1; height: 62px; display: flex; align-items: end; gap: 6px; margin-top: 11px; padding-top: 16px; border-bottom: 1px solid rgba(157,194,239,.22); }
.report-sample-preview span { position: absolute; top: 0; left: 0; color: #82a9d9; font-size: 8px; }
.report-sample-preview i { width: 18px; height: var(--h); border-radius: 4px 4px 0 0; background: linear-gradient(#5cb2ff, #176cff); }
.report-progress-card { margin-top: 14px; }
.report-progress-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.report-progress-head h3 { margin: 6px 0 3px; font-size: 14px; }
.report-progress-head p { margin: 0; color: var(--muted); font-size: 9px; }
.report-progress-head > strong { color: var(--primary); font-size: 26px; }
.report-progress-bar { height: 7px; overflow: hidden; margin-top: 13px; border-radius: 999px; background: #e7eef8; }
.report-progress-bar span { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #45a1ff, #0b6cff); transition: width .25s ease; }
.report-pipeline { display: grid; grid-template-columns: repeat(6, minmax(70px, 1fr)); gap: 7px; margin-top: 15px; overflow-x: auto; }
.report-pipeline-step { display: flex; align-items: center; gap: 6px; min-width: 88px; color: #8b9bb0; font-size: 9px; font-weight: 750; }
.report-pipeline-step i { width: 24px; height: 24px; flex: none; display: grid; place-items: center; border: 1px solid #d5dfed; border-radius: 50%; background: #f7f9fc; font-style: normal; font-size: 8px; }
.report-pipeline-step.done { color: #277657; }
.report-pipeline-step.done i { color: #fff; border-color: var(--green); background: var(--green); }
.report-pipeline-step.active { color: #1762c0; }
.report-pipeline-step.active i { color: #fff; border-color: var(--primary); background: var(--primary); box-shadow: 0 0 0 5px rgba(11,108,255,.1); animation: report-step-pulse 1.7s ease-in-out infinite; }
.report-pipeline-step.failed { color: #b13b4b; }
.report-pipeline-step.failed i { color: #fff; border-color: var(--red); background: var(--red); }
@keyframes report-step-pulse { 50% { box-shadow: 0 0 0 9px rgba(11,108,255,.025); } }
.report-workspace { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 14px; align-items: start; margin-top: 14px; }
.report-library { position: sticky; top: 14px; max-height: calc(100vh - 100px); overflow: auto; }
.report-list { display: grid; gap: 7px; }
.report-list-item { width: 100%; display: grid; gap: 5px; padding: 10px; border: 1px solid #e1e9f4; border-radius: 11px; color: #58708f; background: #f9fbfe; text-align: left; }
.report-list-item:hover, .report-list-item.active { border-color: #8ebcf6; background: #eef6ff; }
.report-list-item > div { display: flex; align-items: start; justify-content: space-between; gap: 6px; }
.report-list-item strong { overflow: hidden; color: #345274; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.report-list-item small { overflow: hidden; color: #8a99ad; font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }
.report-status { width: max-content; padding: 4px 7px; border-radius: 999px; color: #657895; background: #edf2f8; font-size: 8px; font-weight: 900; white-space: nowrap; text-transform: uppercase; }
.report-status.running, .report-status.queued { color: #1762c0; background: #e3efff; }
.report-status.succeeded { color: #247957; background: #e7f8ef; }
.report-status.degraded { color: #956518; background: #fff2d6; }
.report-status.failed { color: #b13b4b; background: #ffebee; }
.report-result { min-width: 0; }
.report-empty { min-height: 320px; display: grid; place-content: center; justify-items: center; gap: 7px; text-align: center; }
.report-empty-orb { width: 52px; height: 52px; display: grid; place-items: center; border-radius: 16px; color: var(--primary); background: #e9f3ff; font-size: 22px; }
.report-empty h3 { margin: 5px 0 0; color: #355476; }
.report-empty p { max-width: 420px; margin: 0; color: var(--muted); font-size: 10px; line-height: 1.55; }
#reportDashboard { display: grid; gap: 14px; }
#reportDashboard[hidden] { display: none; }
.report-result-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.report-result-head h2 { margin: 9px 0 6px; color: #203d64; font-size: 21px; }
.report-result-head p { max-width: 840px; margin: 0; color: #5d718e; font-size: 11px; line-height: 1.65; }
.report-result-badges { display: flex; flex-wrap: wrap; gap: 6px; }
.report-result-badges > span:not(.report-status) { padding: 4px 7px; border-radius: 999px; color: #4e6c92; background: #eef3f9; font-size: 8px; font-weight: 800; }
.report-source { margin-top: 9px; color: #8b99ac; font: 8px/1.5 ui-monospace, monospace; overflow-wrap: anywhere; }
.report-result-actions { min-width: 150px; display: grid; gap: 7px; }
.danger-link { padding: 7px; border: 0; color: #bb5260; background: transparent; font-size: 9px; }
.report-kpis { display: grid; grid-template-columns: repeat(5, minmax(120px, 1fr)); gap: 10px; }
.report-kpi { min-height: 112px; display: grid; align-content: center; gap: 6px; }
.report-kpi span { color: #70839f; font-size: 9px; font-weight: 750; }
.report-kpi strong { color: #1b4f93; font-size: 23px; letter-spacing: -.035em; }
.report-kpi small { color: #96a3b5; font: 8px/1.4 ui-monospace, monospace; }
.report-charts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.report-chart-card { min-width: 0; }
.report-chart-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.report-chart-head h3 { margin: 0; color: #304d71; font-size: 12px; }
.report-chart-head span { padding: 3px 6px; border-radius: 999px; color: #547295; background: #edf3fa; font-size: 8px; text-transform: uppercase; }
.report-chart-svg { width: 100%; height: auto; margin-top: 8px; overflow: visible; font-family: inherit; }
.report-detail-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.report-insights, .report-quality { display: grid; gap: 8px; }
.report-insight { padding: 10px 11px; border-left: 4px solid #6daefc; border-radius: 9px; background: #f5f9ff; }
.report-insight.positive { border-color: var(--green); background: #f1fbf6; }
.report-insight.warning { border-color: var(--amber); background: #fff9ed; }
.report-insight strong { color: #355476; font-size: 10px; }
.report-insight p { margin: 4px 0; color: #5a6f8d; font-size: 9px; line-height: 1.55; }
.report-insight small { color: #8a9aaf; font: 8px ui-monospace, monospace; }
.report-quality-item { display: grid; gap: 3px; padding: 9px 10px; border: 1px solid #f0d7a9; border-radius: 9px; background: #fffaf1; }
.report-quality-item strong { color: #956518; font: 8px ui-monospace, monospace; text-transform: uppercase; }
.report-quality-item span { color: #6d6a64; font-size: 9px; line-height: 1.45; }
.report-quality-ok { padding: 13px; border-radius: 10px; color: #247957; background: #edf9f3; font-size: 10px; font-weight: 750; }
.report-mapping-card summary { cursor: pointer; color: #416286; font-size: 11px; font-weight: 800; }
.report-mapping-card summary span { margin-left: 6px; color: #8495aa; font-size: 8px; font-weight: 600; }
.report-mapping-card form { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) auto; gap: 10px; align-items: end; margin-top: 15px; }
.report-mapping-card label { display: grid; gap: 5px; color: #7587a1; font-size: 9px; font-weight: 800; }
.report-mapping-card select[multiple] { min-height: 112px; }
button:disabled { cursor: not-allowed; opacity: .58; }

.runtime {
  position: relative;
  z-index: 1;
  margin-top: auto;
  padding: 13px;
  border: 1px solid rgba(132, 168, 226, .19);
  border-radius: 16px;
  color: #8fa6ca;
  background: rgba(255, 255, 255, .045);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .03);
  font-size: 10px;
  line-height: 1.45;
}
.runtime-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; color: #eef5ff; font-weight: 700; }
.dot { width: 7px; height: 7px; display: inline-block; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px rgba(46, 182, 125, .12); }
.install {
  display: none;
  width: 100%;
  margin-top: 10px;
  padding: 9px;
  border: 1px solid rgba(103, 169, 255, .35);
  border-radius: 10px;
  color: #fff;
  background: rgba(11, 108, 255, .18);
}

.main { min-width: 0; min-height: 100vh; position: relative; }
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  border-bottom: 1px solid rgba(207, 219, 239, .88);
  background: rgba(250, 252, 255, .88);
  backdrop-filter: blur(18px);
  box-shadow: 0 8px 24px rgba(30, 73, 134, .035);
}
.topbar h2 { margin: 0; color: #4c5e7d; font-size: 13px; font-weight: 750; }
.top-actions { display: flex; align-items: center; gap: 8px; }
.ghost-button, .secondary {
  border: 1px solid var(--line);
  border-radius: 10px;
  color: #536684;
  background: rgba(255, 255, 255, .88);
  padding: 8px 10px;
  font-size: 11px;
  font-weight: 700;
  box-shadow: 0 4px 11px rgba(32, 72, 128, .03);
}
.ghost-button:hover, .secondary:hover { border-color: #aac8f6; color: var(--primary); background: #f7fbff; }
.notify-button.enabled { color: #217e5b; border-color: #bce8d5; background: #effbf6; }
.approval-count {
  min-width: 19px;
  height: 19px;
  margin-left: 5px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: var(--primary);
  font-size: 9px;
  font-weight: 900;
}

.view { display: none; max-width: 1450px; margin: 0 auto; padding: 27px 30px 46px; }
.view.active { display: block; }
.hero {
  position: relative;
  min-height: 176px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  margin-bottom: 18px;
  padding: 27px 30px;
  border: 1px solid #cfe0fa;
  border-radius: 23px;
  overflow: hidden;
  background:
    linear-gradient(112deg, #ffffff 0%, #f4f8ff 48%, #e7f1ff 100%);
  box-shadow: 0 17px 36px rgba(38, 89, 158, .075);
}
.hero::before {
  content: "";
  position: absolute;
  width: 225px;
  height: 225px;
  right: -38px;
  top: -92px;
  border-radius: 50%;
  border: 1px solid rgba(11, 108, 255, .12);
  box-shadow: 0 0 0 28px rgba(11, 108, 255, .035), 0 0 0 58px rgba(11, 108, 255, .02);
}
.hero::after {
  content: "C";
  position: absolute;
  right: 78px;
  bottom: -28px;
  color: rgba(11, 108, 255, .075);
  font-size: 170px;
  line-height: 1;
  font-weight: 950;
}
.hero > div { position: relative; z-index: 1; }
.eyebrow { color: #3478d8; font-size: 10px; text-transform: uppercase; letter-spacing: .13em; font-weight: 900; }
.hero h1 { margin: 8px 0 7px; color: #10213f; font-size: clamp(27px, 3.1vw, 42px); line-height: 1.08; letter-spacing: -.045em; }
.hero p { max-width: 660px; margin: 0; color: #73829c; font-size: 12px; line-height: 1.6; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 17px; }
.suggestion-chip {
  border: 1px solid #c9dcf8;
  border-radius: 999px;
  padding: 8px 11px;
  color: #315f9f;
  background: rgba(255, 255, 255, .82);
  font-size: 10px;
  font-weight: 800;
  transition: transform .16s ease, border-color .16s ease, color .16s ease;
}
.suggestion-chip:hover { transform: translateY(-2px); border-color: #7fb3f8; color: var(--primary); }
.date-chip {
  position: relative;
  z-index: 1;
  padding: 10px 13px;
  border: 1px solid #cbdcf5;
  border-radius: 12px;
  color: #45648e;
  background: rgba(255, 255, 255, .82);
  font-size: 11px;
  white-space: nowrap;
}

.stats { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 11px; margin-bottom: 18px; }
.stat {
  position: relative;
  min-height: 98px;
  padding: 15px 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  background: rgba(255, 255, 255, .9);
  box-shadow: 0 9px 23px rgba(42, 82, 137, .045);
}
.stat::after {
  content: "";
  position: absolute;
  width: 55px;
  height: 55px;
  right: -24px;
  bottom: -28px;
  border-radius: 50%;
  background: rgba(11, 108, 255, .08);
}
.stat-label { color: #8795ab; font-size: 10px; font-weight: 700; }
.stat-value { margin-top: 9px; color: #17315b; font-size: 28px; font-weight: 900; letter-spacing: -.035em; }
.stat.overdue .stat-value { color: var(--red); }
.stat.alerts .stat-value { color: var(--primary); }

.grid-2 { display: grid; grid-template-columns: minmax(300px, .85fr) minmax(360px, 1.15fr); gap: 14px; }
.card {
  padding: 17px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, .92);
  box-shadow: 0 10px 28px rgba(36, 78, 137, .045);
}
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.card-head h3 { margin: 0; color: #263c60; font-size: 13px; }
.card-sub { margin-top: 3px; color: #8a98ad; font-size: 10px; line-height: 1.45; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.field { display: grid; gap: 5px; }
.field.full { grid-column: 1 / -1; }
label { color: #8290a6; font-size: 9px; text-transform: uppercase; letter-spacing: .07em; font-weight: 800; }
input, select, textarea {
  width: 100%;
  padding: 10px 11px;
  border: 1px solid #d5e0ef;
  border-radius: 10px;
  outline: 0;
  color: #243a5d;
  background: #fbfdff;
}
input::placeholder, textarea::placeholder { color: #a4b0c1; }
input:focus, select:focus, textarea:focus { border-color: #70a9f5; box-shadow: 0 0 0 3px rgba(11, 108, 255, .1); background: #fff; }
textarea { min-height: 76px; resize: vertical; }
.primary {
  border: 0;
  border-radius: 10px;
  padding: 10px 13px;
  color: #fff;
  background: linear-gradient(135deg, #1982ff, #0b6cff 56%, #0757ce);
  box-shadow: 0 8px 17px rgba(11, 108, 255, .2);
  font-weight: 850;
}
.primary:hover { filter: brightness(1.035); transform: translateY(-1px); }

.timeline, .reminder-list, .alert-list, .engineer-loop-list, .runbook-list { display: grid; gap: 8px; }
.timeline-item, .reminder-card, .alert-card, .flow-card, .engineer-loop-card, .runbook-card {
  padding: 11px;
  border: 1px solid #dfe7f3;
  border-radius: 12px;
  background: #fbfdff;
}
.timeline-row, .item-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.timeline-time, .reminder-next { min-width: 56px; color: #3477d1; font-size: 10px; font-weight: 750; }
.item-title { color: #263b5c; font-size: 12px; font-weight: 800; }
.item-meta { margin-top: 4px; color: #8c99ac; font-size: 9px; }
.pill { display: inline-block; padding: 3px 7px; border-radius: 999px; color: #586c8b; background: #edf3fb; font-size: 8px; font-weight: 750; }
.pill.urgent { color: #bb394a; background: #ffecef; }
.pill.high { color: #9a671a; background: #fff3d9; }
.empty { padding: 24px; border: 1px dashed #cfdced; border-radius: 12px; color: #95a2b4; background: rgba(255, 255, 255, .5); text-align: center; font-size: 11px; }

.section-head { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.section-head h1 { margin: 0 0 4px; color: #142a4d; font-size: 26px; letter-spacing: -.035em; }
.section-head p { margin: 0; color: #8290a5; font-size: 11px; line-height: 1.5; }
.quick-add {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 130px 190px auto;
  gap: 8px;
  margin-bottom: 16px;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: rgba(255, 255, 255, .72);
}
.board { display: grid; grid-template-columns: repeat(5, minmax(220px, 1fr)); gap: 10px; overflow-x: auto; padding-bottom: 12px; }
.column {
  min-height: 470px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: rgba(248, 251, 255, .86);
}
.column.dragover { border-color: #6fa9f8; background: #eef6ff; }
.column-head { display: flex; align-items: center; justify-content: space-between; padding: 4px 4px 10px; color: #62738e; font-size: 10px; font-weight: 900; text-transform: uppercase; letter-spacing: .08em; }
.column-count { color: #9aa7b9; }
.flow-list { display: grid; gap: 8px; }
.flow-card { cursor: grab; box-shadow: 0 5px 12px rgba(42, 80, 131, .035); }
.flow-card:hover { border-color: #a8c7f2; box-shadow: 0 9px 18px rgba(42, 80, 131, .075); }
.flow-card:active { cursor: grabbing; }
.flow-card.overdue { border-color: #f0a7b0; }
.flow-card .item-title { line-height: 1.35; }
.flow-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; }

.reminder-layout { display: grid; grid-template-columns: minmax(320px, .8fr) minmax(420px, 1.2fr); gap: 14px; }
.schedule-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.schedule-option { display: none; }
.schedule-option.visible { display: grid; }
.weekdays { display: flex; flex-wrap: wrap; gap: 5px; }
.weekday { padding: 6px 8px; border: 1px solid #d5e0ef; border-radius: 8px; color: #61728d; background: #fff; font-size: 9px; }
.weekday input { width: auto; margin: 0 4px 0 0; }
.reminder-card { display: grid; grid-template-columns: 1fr auto; gap: 10px; align-items: center; }
.toggle { padding: 6px 9px; border: 1px solid #d5e0ef; border-radius: 999px; color: #687b98; background: #fff; font-size: 9px; }
.toggle.on { color: #247a58; border-color: #b9e4d1; background: #eaf9f2; }
.alert-card.unread { border-color: #89b8f5; background: #eef6ff; }
.alert-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 9px; }
.alert-actions button { padding: 6px 8px; border: 1px solid #d5e0ef; border-radius: 8px; color: #647692; background: #fff; font-size: 9px; }

.chat-shell {
  height: calc(100vh - 116px);
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  background: rgba(255, 255, 255, .9);
  box-shadow: 0 15px 34px rgba(36, 80, 140, .065);
}
.chat-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px max(16px, calc((100% - 860px) / 2)); border-bottom: 1px solid var(--line); background: #f8fbff; }
.chat-session-identity { display: flex; align-items: baseline; gap: 9px; min-width: 0; }
.chat-toolbar strong { color: #315b8d; font-size: 11px; }
.chat-toolbar span { overflow: hidden; color: #8292aa; font: 9px ui-monospace, SFMono-Regular, Consolas, monospace; text-overflow: ellipsis; white-space: nowrap; }
.chat-toolbar-actions { display: flex; align-items: center; justify-content: flex-end; gap: 7px; min-width: 0; }
.ssh-connection-pill { max-width: 220px; padding: 6px 9px; border: 1px solid #e2c887; border-radius: 999px; color: #8b671f !important; background: #fff8e6; font-family: inherit !important; font-weight: 800 !important; }
.ssh-connection-pill.ready { color: #187452 !important; border-color: #a9dcc7; background: #eaf9f2; }
.chat { flex: 1; display: flex; flex-direction: column; gap: 14px; overflow: auto; padding: 24px max(16px, calc((100% - 860px) / 2)); }
.message { max-width: 82%; padding: 13px 15px; border-radius: 16px; line-height: 1.55; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 12px; }
.message.assistant, .assistant { align-self: flex-start; color: #365173; border: 1px solid #d4e5fb; border-top-left-radius: 5px; background: #eef6ff; }
.message.user, .user { align-self: flex-end; color: #fff; border-top-right-radius: 5px; background: linear-gradient(135deg, #258aff, #0b6cff); }
.meta { margin-top: 7px; color: #8e9cb0; font-size: 9px; }
.composer-wrap { padding: 13px max(14px, calc((100% - 860px) / 2)); border-top: 1px solid var(--line); background: #f8fbff; }
.composer { display: grid; grid-template-columns: 1fr auto; gap: 8px; padding: 7px 7px 7px 12px; border: 1px solid #a9c8f3; border-radius: 14px; background: #fff; box-shadow: 0 7px 18px rgba(36, 83, 145, .055); }
.composer textarea { min-height: 36px; max-height: 180px; padding: 8px 0; border: 0; background: transparent; resize: none; box-shadow: none; }
.composer textarea:focus { border: 0; box-shadow: none; }
.send { width: 42px; height: 42px; border: 0; border-radius: 11px; color: #fff; background: linear-gradient(145deg, #2990ff, #0b6cff); box-shadow: 0 8px 17px rgba(11, 108, 255, .23); font-size: 19px; font-weight: 900; }

.ssh-login-dialog { width: min(680px, calc(100% - 28px)); max-height: calc(100dvh - 32px); overflow: auto; padding: 0; border: 1px solid #c8daf2; border-radius: 22px; color: var(--ink); background: #fff; box-shadow: 0 28px 90px rgba(18, 50, 98, .28); }
.ssh-login-dialog::backdrop { background: rgba(21, 46, 83, .4); backdrop-filter: blur(8px); }
.ssh-login-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; padding: 22px 22px 17px; border-bottom: 1px solid var(--line); background: linear-gradient(145deg, #f9fcff, #eef6ff); }
.ssh-login-head h2 { margin: 4px 0 3px; color: #203b64; font-size: 19px; }
.ssh-login-head p { margin: 0; color: #71839d; font-size: 10px; line-height: 1.5; }
.ssh-login-flow { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; padding: 16px 22px 0; }
.ssh-login-node { position: relative; display: flex; align-items: center; gap: 7px; min-width: 0; padding: 9px; border: 1px solid #dce6f3; border-radius: 11px; color: #8a99ad; background: #f9fbfe; font-size: 9px; font-weight: 800; }
.ssh-login-node:not(:last-child)::after { content: '›'; position: absolute; right: -7px; z-index: 1; color: #8eafd7; font-size: 16px; }
.ssh-login-node i { width: 20px; height: 20px; flex: none; display: grid; place-items: center; border-radius: 50%; color: #71839d; background: #eaf0f8; font-style: normal; font-size: 8px; }
.ssh-login-node.active { color: #1762c0; border-color: #a9c9ef; background: #eef6ff; }
.ssh-login-node.active i { color: #fff; background: var(--primary); }
.ssh-login-node.done { color: #187452; border-color: #a9dcc7; background: #eefaf4; }
.ssh-login-node.done i { color: #fff; background: var(--green); }
.ssh-login-node.failed { color: #b13b4b; border-color: #efc3ca; background: #fff6f7; }
.ssh-login-node.failed i { color: #fff; background: var(--red); }
.ssh-login-form { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(110px, .6fr); gap: 11px; padding: 18px 22px 22px; }
.ssh-login-form .field label { color: #617594; font-size: 10px; font-weight: 800; }
.ssh-login-form input, .ssh-login-form select, .ssh-login-form textarea { width: 100%; padding: 10px 11px; border: 1px solid var(--line-strong); border-radius: 10px; background: #fff; font-size: 11px; }
.ssh-login-form textarea { resize: vertical; font: 9px/1.45 ui-monospace, SFMono-Regular, Consolas, monospace; }
.ssh-private-key-field > input { padding: 7px; }
.ssh-fingerprint { display: grid; gap: 6px; margin-top: 10px; padding: 11px; border: 1px solid #c4daf4; border-radius: 11px; color: #647a98; background: #f4f9ff; font-size: 9px; }
.ssh-fingerprint[hidden], .ssh-password-field[hidden] { display: none; }
.ssh-fingerprint strong { overflow-wrap: anywhere; color: #204f89; font: 800 10px/1.4 ui-monospace, SFMono-Regular, Consolas, monospace; }
.ssh-fingerprint label { display: flex; align-items: center; gap: 7px; margin-top: 2px; color: #365a84; font-weight: 800; }
.ssh-fingerprint input { width: auto; }
.ssh-login-result { padding: 9px 11px; border-radius: 10px; color: #647a98; background: #f3f6fa; font-size: 10px; line-height: 1.5; }
.ssh-login-result.success { color: #187452; background: #eaf9f2; }
.ssh-login-result.error { color: #b13b4b; background: #ffedef; }
.ssh-login-actions { display: flex; justify-content: flex-end; gap: 8px; }
.node-pair-command { display: grid; gap: 8px; padding: 11px; border: 1px solid #c4daf4; border-radius: 11px; background: #f4f9ff; }
.node-pair-command[hidden] { display: none; }
.node-pair-command textarea { font: 9px/1.5 ui-monospace, SFMono-Regular, Consolas, monospace; }
.node-pair-list { display: grid; gap: 8px; }
.node-pair-item { display: grid; grid-template-columns: 1fr auto; gap: 9px; align-items: center; padding: 10px; border: 1px solid #dce6f3; border-radius: 11px; background: #f9fbfe; }
.node-pair-item strong { display: block; color: #294e7d; font-size: 10px; }
.node-pair-item span { display: block; margin-top: 3px; color: #7c8ea6; font-size: 8px; }
.node-pair-item.online { border-color: #a9dcc7; background: #eefaf4; }
.node-pair-item.bound { box-shadow: inset 3px 0 #2f72c8; }

.engineer-stats { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.engineer-layout { display: grid; grid-template-columns: minmax(320px, .72fr) minmax(500px, 1.28fr); gap: 14px; }
.engineer-loop-card.blocked { border-color: #efc579; }
.engineer-loop-card.failed { border-color: #eda5ae; }
.engineer-loop-card.succeeded { border-color: #9ed9c0; }
.engineer-loop-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.engineer-phase-track { display: grid; grid-template-columns: repeat(8, minmax(54px, 1fr)); gap: 4px; margin-top: 11px; overflow-x: auto; }
.engineer-phase { padding: 6px 4px; border: 1px solid #dce6f3; border-radius: 8px; color: #95a2b5; background: #f9fbff; text-align: center; font-size: 8px; text-transform: uppercase; }
.engineer-phase.done { color: #3471c1; border-color: #c4dcfa; background: #edf5ff; }
.engineer-phase.active { color: #fff; border-color: var(--primary); background: var(--primary); box-shadow: 0 0 16px rgba(11, 108, 255, .2); }
.engineer-evidence { margin-top: 9px; padding: 9px; border-radius: 9px; color: #536885; background: #f3f7fc; font-size: 9px; line-height: 1.5; }
.engineer-status { padding: 4px 7px; border-radius: 999px; color: #657895; background: #edf2f8; font-size: 8px; text-transform: uppercase; letter-spacing: .06em; }
.engineer-status.running { color: #285fa9; background: #e5f0ff; }
.engineer-status.blocked { color: #9a681d; background: #fff3d9; }
.engineer-status.succeeded { color: #267957; background: #e9f8f1; }
.engineer-status.failed, .engineer-status.aborted { color: #b13b4b; background: #ffebee; }
.runbook-card details { margin-top: 8px; }
.runbook-card summary { cursor: pointer; color: #2f6fca; font-size: 10px; font-weight: 750; }
.runbook-body { margin-top: 8px; color: #596c88; font-size: 9px; line-height: 1.55; white-space: pre-wrap; }

.deploy-section-head { align-items: center; }
.deploy-live-badge { display: inline-flex; align-items: center; gap: 8px; padding: 9px 12px; border: 1px solid #cfe0f5; border-radius: 999px; color: #52709b; background: rgba(255, 255, 255, .78); font-size: 10px; font-weight: 800; white-space: nowrap; }
.deploy-live-badge .dot { width: 8px; height: 8px; }
.deploy-layout { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 14px; align-items: start; }
.deploy-main { min-width: 0; display: grid; gap: 14px; }
.deploy-launch-card { padding-bottom: 15px; }
.deploy-form { display: grid; gap: 10px; }
.deploy-form textarea { min-height: 70px; }
.deploy-form-row { display: flex; align-items: end; justify-content: space-between; gap: 12px; }
.deploy-role-select { display: grid; gap: 5px; width: min(280px, 100%); color: #8290a6; font-size: 9px; text-transform: uppercase; letter-spacing: .07em; font-weight: 800; }
.deploy-tag-input { display: grid; gap: 5px; width: min(280px, 100%); color: #8290a6; font-size: 9px; text-transform: uppercase; letter-spacing: .07em; font-weight: 800; }
.deploy-submit { min-width: 150px; }
.flow-toolbar { display: flex; align-items: end; justify-content: space-between; gap: 12px; padding: 11px 13px; }
.flow-run-picker { display: grid; gap: 5px; min-width: min(560px, 100%); color: #8290a6; font-size: 9px; text-transform: uppercase; letter-spacing: .07em; font-weight: 800; }
.flow-run-identity { max-width: 390px; color: #7187a7; font: 8px/1.55 ui-monospace, monospace; overflow-wrap: anywhere; }
.flow-toolbar-actions { display: flex; gap: 7px; }
.topology-card { min-width: 0; padding: 0; overflow: hidden; }
.topology-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 17px 13px; border-bottom: 1px solid var(--line); }
.topology-header h3 { margin: 0; color: #263c60; font-size: 13px; }
.topology-legend { display: flex; flex-wrap: wrap; justify-content: end; gap: 8px; color: #8090a8; font-size: 9px; }
.topology-legend span { display: inline-flex; align-items: center; gap: 4px; }
.legend-dot { width: 7px; height: 7px; display: inline-block; border-radius: 50%; background: #9db0cb; }
.legend-dot.running { background: var(--primary); box-shadow: 0 0 0 4px rgba(11, 108, 255, .12); }
.legend-dot.succeeded { background: var(--green); }
.legend-dot.blocked { background: var(--amber); }
.flow-viewport { position: relative; height: 620px; overflow: hidden; cursor: grab; background-color: #f7faff; background-image: linear-gradient(rgba(132, 169, 221, .12) 1px, transparent 1px), linear-gradient(90deg, rgba(132, 169, 221, .12) 1px, transparent 1px); background-size: 24px 24px; }
.flow-viewport.panning { cursor: grabbing; }
.flow-stage { position: absolute; left: 0; top: 0; transform-origin: 0 0; will-change: transform; }
.flow-svg { position: absolute; left: 0; top: 0; overflow: visible; pointer-events: none; }
.flow-edge { fill: none; stroke: #b7c9e4; stroke-width: 2.2; stroke-dasharray: 6 6; opacity: .85; }
.flow-edge.complete { stroke: #75cba8; stroke-dasharray: none; }
.flow-node { position: absolute; z-index: 2; display: grid; grid-template-rows: auto 1fr auto auto; gap: 7px; padding: 12px 13px; border: 1px solid #cbdcf2; border-radius: 15px; color: var(--ink); background: rgba(255, 255, 255, .96); box-shadow: 0 10px 25px rgba(36, 78, 137, .1); text-align: left; transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease; }
.flow-node:hover, .flow-node.selected { border-color: #5e9cf0; box-shadow: 0 0 0 3px rgba(11, 108, 255, .12), 0 14px 30px rgba(36, 78, 137, .14); transform: translateY(-2px); }
.flow-node.running { border-color: #5e9cf0; box-shadow: 0 0 0 4px rgba(11, 108, 255, .1), 0 13px 30px rgba(36, 105, 209, .15); animation: flow-node-pulse 2s ease-in-out infinite; }
.flow-node.succeeded { border-color: #a6ddc3; }
.flow-node.blocked { border-color: #efcf91; background: #fffaf0; }
.flow-node.failed { border-color: #efb0b8; background: #fff8f9; }
.flow-node-head { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.flow-node-role { color: #356eb6; font-size: 9px; font-weight: 900; text-transform: uppercase; letter-spacing: .07em; }
.flow-node-status, .inspector-status { padding: 4px 6px; border-radius: 999px; color: #70829d; background: #edf2f8; font-size: 8px; font-weight: 800; white-space: nowrap; }
.flow-node-status.running, .inspector-status.running { color: #1762c0; background: #e3efff; }
.flow-node-status.succeeded, .inspector-status.succeeded { color: #247957; background: #e7f8ef; }
.flow-node-status.blocked, .inspector-status.blocked { color: #956518; background: #fff2d6; }
.flow-node-status.failed, .inspector-status.failed { color: #b13b4b; background: #ffebee; }
.flow-node-title { display: block; overflow: hidden; color: #253c60; font-size: 11px; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; }
.flow-node-meta { overflow: hidden; color: #8090a7; font-size: 9px; white-space: nowrap; text-overflow: ellipsis; }
.flow-node-progress { height: 4px; overflow: hidden; border-radius: 999px; background: #e8eef7; }
.flow-node-progress i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #55a5ff, #0b6cff); transition: width .25s ease; }
@keyframes flow-node-pulse { 0%, 100% { box-shadow: 0 0 0 4px rgba(11, 108, 255, .1), 0 13px 30px rgba(36, 105, 209, .15); } 50% { box-shadow: 0 0 0 9px rgba(11, 108, 255, .03), 0 13px 34px rgba(36, 105, 209, .2); } }
.flow-empty { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 8px; padding: 20px; color: #8393aa; text-align: center; font-size: 11px; pointer-events: none; }
.flow-empty[hidden] { display: none; }
.flow-empty strong { color: #496585; font-size: 14px; }
.flow-empty span { max-width: 300px; line-height: 1.5; }
.flow-empty-orb { width: 46px; height: 46px; display: grid; place-items: center; border: 1px solid #c7dcf8; border-radius: 16px; color: #0b6cff; background: #eaf3ff; font-size: 20px; }
.flow-inspector { position: sticky; top: 85px; min-height: 620px; }
.flow-inspector .card-head { align-items: start; }
.inspector-empty { display: grid; min-height: 270px; place-items: center; padding: 24px; border: 1px dashed #cbdcf2; border-radius: 12px; color: #93a1b4; background: #f8fbff; text-align: center; font-size: 10px; line-height: 1.6; }
.inspector-title { color: #213c63; font-size: 16px; font-weight: 900; line-height: 1.3; }
.inspector-meta { margin-top: 5px; color: #8a99ad; font-size: 9px; }
.inspector-section { margin-top: 17px; padding-top: 12px; border-top: 1px solid #e7edf6; }
.inspector-section > span { color: #7b8ca7; font-size: 9px; font-weight: 900; text-transform: uppercase; letter-spacing: .08em; }
.inspector-section p { margin: 6px 0 0; color: #4d6381; font-size: 10px; line-height: 1.55; white-space: pre-wrap; overflow-wrap: anywhere; }
.inspector-section pre { max-height: 130px; overflow: auto; margin: 6px 0 0; padding: 8px; border-radius: 8px; color: #536985; background: #f3f7fc; font: 9px/1.5 ui-monospace, monospace; white-space: pre-wrap; overflow-wrap: anywhere; }
.inspector-evidence { display: grid; gap: 6px; margin-top: 7px; }
.evidence-item { padding: 7px 8px; border-left: 3px solid #8db8f2; border-radius: 7px; color: #607796; background: #f4f8fd; font-size: 9px; line-height: 1.4; }
.deploy-bottom-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px; margin-top: 14px; }
.active-task-list, .flow-activity-list { display: grid; gap: 7px; }
.active-task-row { display: grid; gap: 4px; padding: 10px; border: 1px solid #dce8f6; border-radius: 10px; background: #f8fbff; }
.active-task-row.running { border-color: #a7c9f5; background: #eef6ff; }
.active-task-row strong { overflow: hidden; color: #315579; font-size: 10px; white-space: nowrap; text-overflow: ellipsis; }
.active-task-row span { color: #7d90a9; font-size: 9px; }
.flow-activity-row { display: grid; grid-template-columns: 105px 1fr; gap: 8px; padding: 8px 0; border-bottom: 1px solid #edf1f7; }
.flow-activity-row:last-child { border-bottom: 0; }
.flow-activity-row time { color: #8c9aae; font-size: 8px; }
.flow-activity-row div { display: grid; gap: 3px; min-width: 0; }
.flow-activity-row strong { color: #536b8b; font-size: 9px; }
.flow-activity-row span { overflow: hidden; color: #8797ad; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.flow-log-meta { color: #8c9aae; font: 8px/1.4 ui-monospace, monospace; overflow-wrap: anywhere; }
.flow-log-tags { color: #7892b6; font-size: 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.flow-activity-row.warn strong { color: #956518; }
.flow-activity-row.error strong { color: #b13b4b; }

.drawer {
  position: fixed;
  inset: 0 0 0 auto;
  z-index: 40;
  width: min(520px, 100%);
  display: none;
  flex-direction: column;
  border-left: 1px solid var(--line);
  color: var(--ink);
  background: #fbfdff;
  box-shadow: -20px 0 60px rgba(19, 47, 89, .18);
}
.drawer.open { display: flex; }
.drawer-head { height: 68px; display: flex; align-items: center; justify-content: space-between; padding: 0 18px; border-bottom: 1px solid var(--line); }
.drawer-head h3 { margin: 0; }
.drawer-list { flex: 1; display: grid; align-content: start; gap: 10px; overflow: auto; padding: 15px; }
.approval-card { padding: 13px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.approval-title { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.risk { padding: 3px 6px; border-radius: 999px; color: #647692; background: #edf2f8; font-size: 8px; text-transform: uppercase; }
.risk.external { color: #9a681d; background: #fff3d9; }
.risk.dangerous { color: #b13b4b; background: #ffebee; }
.approval-args { max-height: 220px; overflow: auto; padding: 9px; border-radius: 9px; color: #536784; background: #f4f7fb; white-space: pre-wrap; overflow-wrap: anywhere; font: 10px/1.5 ui-monospace, monospace; }
.approval-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.approval-actions button { border: 0; border-radius: 9px; padding: 9px; font-weight: 800; }
.approve { color: #fff; background: var(--green); }
.deny { color: #5e6f88; background: #edf2f7; }

.toast-stack { position: fixed; right: 18px; bottom: 18px; z-index: 60; width: min(360px, calc(100% - 36px)); display: grid; gap: 8px; }
.toast { padding: 11px 13px; border: 1px solid #afd0fb; border-radius: 12px; color: #315b94; background: #edf6ff; box-shadow: 0 18px 50px rgba(22, 62, 119, .18); font-size: 11px; }

.auth-overlay { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px; background: rgba(31, 65, 110, .22); backdrop-filter: blur(12px); }
.auth-overlay[hidden] { display: none; }
.auth-card { width: min(430px, 100%); padding: 28px; border: 1px solid #cfe0f5; border-radius: 22px; background: #fff; box-shadow: 0 24px 70px rgba(22, 62, 119, .2); }
.auth-card h2 { margin: 0 0 6px; color: #203b64; }
.auth-card p { color: #71839d; font-size: 12px; line-height: 1.5; }
.auth-card form { display: grid; gap: 12px; margin-top: 18px; }
.auth-card label { display: grid; gap: 6px; color: #617594; font-size: 11px; font-weight: 700; }
.auth-card button { width: 100%; }
.auth-error { min-height: 18px; margin: 0 !important; color: #c55862 !important; }

@media (max-width: 1180px) {
  .stats { grid-template-columns: repeat(3, 1fr); }
  .grid-2, .reminder-layout, .engineer-layout, .deploy-layout, .deploy-bottom-grid { grid-template-columns: 1fr; }
  .flow-inspector { position: static; min-height: 0; }
  .report-workspace { grid-template-columns: 1fr; }
  .report-library { position: static; max-height: none; }
  .report-kpis { grid-template-columns: repeat(3, minmax(120px, 1fr)); }
}

@media (max-width: 760px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed;
    inset: auto 0 0 0;
    width: auto;
    height: 68px;
    padding: 7px;
    border: 0;
    border-top: 1px solid rgba(255, 255, 255, .1);
    flex-direction: row;
  }
  .sidebar::after, .brand, .runtime { display: none; }
  .nav { width: 100%; grid-auto-flow: column; grid-auto-columns: minmax(68px, 1fr); grid-template-columns: none; gap: 4px; overflow-x: auto; scrollbar-width: none; }
  .nav::-webkit-scrollbar { display: none; }
  .nav-button { min-height: 52px; min-width: 68px; justify-content: center; padding: 27px 2px 5px; text-align: center; font-size: 8px; }
  .nav-button::before { top: 7px; left: 50%; transform: translateX(-50%); }
  .nav-button:hover { transform: none; }
  .nav-count { display: none; }
  .main { padding-bottom: 68px; }
  .topbar { padding: 0 12px; }
  .topbar h2 { font-size: 12px; }
  .view { padding: 15px 12px 28px; }
  .hero { min-height: 205px; align-items: flex-start; flex-direction: column; padding: 22px 19px; }
  .hero h1 { max-width: 88%; }
  .hero::after { right: -8px; }
  .date-chip { display: none; }
  .stats, .engineer-stats { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .stat { min-height: 84px; padding: 12px; }
  .stat-value { margin-top: 5px; font-size: 24px; }
  .quick-add { grid-template-columns: 1fr; padding: 8px; }
  .board { grid-template-columns: repeat(5, 82vw); }
  .form-grid, .schedule-fields { grid-template-columns: 1fr; }
  .reminder-card { grid-template-columns: 1fr; }
  .deploy-form-row, .flow-toolbar, .topology-header { align-items: stretch; flex-direction: column; }
  .deploy-role-select, .deploy-tag-input, .flow-run-picker { width: 100%; min-width: 0; }
  .office-layout, .office-sync-form { grid-template-columns: 1fr; }
  .office-usage-card { position: static; }
  .deploy-submit { width: 100%; }
  .flow-toolbar-actions { justify-content: end; }
  .topology-legend { justify-content: start; }
  .flow-viewport { height: 520px; }
  .flow-inspector { min-height: 0; }
  .flow-activity-row { grid-template-columns: 82px 1fr; }
  .ghost-label { display: none; }
  .chat-shell { height: calc(100dvh - 166px); }
  .chat-toolbar { align-items: flex-start; }
  .chat-session-identity { display: grid; gap: 2px; }
  .chat-toolbar-actions { flex-wrap: wrap; }
  .ssh-connection-pill { width: 100%; max-width: 180px; }
  .ssh-login-flow { grid-template-columns: 1fr 1fr; }
  .ssh-login-node:nth-child(2)::after { display: none; }
  .ssh-login-form { grid-template-columns: 1fr; padding: 15px; }
  .ssh-login-head { padding: 18px 15px 14px; }
  .report-section-head, .report-result-head { align-items: stretch; flex-direction: column; }
  .report-privacy { max-width: none; }
  .report-launch-grid, .report-charts, .report-detail-grid { grid-template-columns: 1fr; }
  .report-launch-controls { grid-template-columns: 1fr; }
  .report-upload-card, .report-sample-card { min-height: 0; }
  .report-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .report-result-actions { grid-template-columns: 1fr 1fr; }
  .report-result-actions .danger-link { grid-column: 1 / -1; }
  .report-mapping-card form { grid-template-columns: 1fr; }
  .report-progress-head > strong { font-size: 21px; }
}
