:root {
  --bg: #f5f6f2;
  --surface: #ffffff;
  --ink: #151716;
  --muted: #69716d;
  --line: #dfe4dc;
  --accent: #1f6f5b;
  --accent-2: #b95f33;
  --accent-3: #2e5f9e;
  --soft: #eaf2ef;
  --shadow: 0 18px 48px rgba(22, 29, 25, .08);
}

[data-theme="dark"] {
  --bg: #111413;
  --surface: #181d1b;
  --ink: #f3f5f1;
  --muted: #aab3ad;
  --line: #2b3530;
  --soft: #1d2925;
  --shadow: 0 20px 60px rgba(0, 0, 0, .22);
}

* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: "DM Sans", system-ui, sans-serif;
  letter-spacing: 0;
}
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
code { font-family: "JetBrains Mono", monospace; }

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 25px;
  font-weight: 900;
  line-height: 1;
}
.brand-accent { color: var(--accent-3); }
.brand-mark {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 8px;
  background: var(--ink);
  color: var(--bg);
  font-family: "JetBrains Mono", monospace;
  font-size: 12px;
  line-height: 1;
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 18px;
  border: 1px solid var(--ink);
  border-radius: 8px;
  background: var(--ink);
  color: var(--bg);
  font-weight: 700;
  line-height: 1;
  text-align: center;
  cursor: pointer;
}
.button.secondary, .button.ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}
.eyebrow {
  margin: 0 0 8px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.muted, small { color: var(--muted); }

.landing-shell {
  width: min(1180px, calc(100vw - 32px));
  margin: 0 auto;
}
.landing-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 0;
}
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(340px, .9fr);
  gap: 32px;
  align-items: center;
  min-height: calc(100vh - 190px);
  padding: 28px 0;
}
.hero h1 {
  margin: 0;
  max-width: 780px;
  font-size: clamp(52px, 8vw, 110px);
  line-height: .86;
  letter-spacing: 0;
}
.hero-text {
  max-width: 680px;
  color: var(--muted);
  font-size: 20px;
  line-height: 1.55;
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-panel, .panel, .auth-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.hero-panel { padding: 22px; }
.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}
.panel-header strong { font-size: 44px; color: var(--accent); }
.signal-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 0;
  border-top: 1px solid var(--line);
}
.signal-row span { color: var(--muted); }
.landing-band {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  padding: 20px 0 44px;
}
.metric {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}
.metric strong { display: block; font-size: 32px; }
.metric span { color: var(--muted); }

.auth-shell {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 24px;
}
.auth-card {
  width: min(420px, 100%);
  padding: 28px;
}
.auth-card h1 { margin: 28px 0 20px; }
.auth-card label {
  display: grid;
  gap: 8px;
  margin-bottom: 14px;
  color: var(--muted);
  font-weight: 700;
}
.auth-card input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
  color: var(--ink);
  padding: 12px;
}
.form-error { color: #b53434; font-weight: 700; }
.messages {
  position: fixed;
  z-index: 20;
  top: 14px;
  right: 14px;
  display: grid;
  gap: 8px;
}
.message {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  max-width: 420px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
  font-weight: 700;
}
.message.success .material-symbols-outlined { color: var(--accent); }
.message.error .material-symbols-outlined { color: #b53434; }

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  display: flex;
  flex-direction: column;
  width: 342px;
  padding: 22px 16px 16px;
  border-right: 1px solid var(--line);
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--surface) 96%, var(--soft)), color-mix(in srgb, var(--surface) 88%, var(--bg))),
    var(--surface);
  box-shadow: 14px 0 42px rgba(22, 29, 25, .05);
  backdrop-filter: blur(18px);
}
.sidebar-brand-block {
  display: grid;
  gap: 8px;
  padding: 10px 8px 24px;
  border-bottom: 1px solid var(--line);
}
.sidebar-brand-block p {
  margin: 0 0 0 46px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}
.workspace-switcher,
.menu-search-trigger {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--surface) 82%, var(--bg));
  color: var(--muted);
  cursor: pointer;
}
.workspace-switcher {
  gap: 10px;
  margin-top: 24px;
  padding: 0 12px;
  text-align: left;
}
.workspace-switcher > span:first-child {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 34%, var(--line));
}
.workspace-switcher strong {
  flex: 1;
  color: var(--muted);
  font-size: 15px;
  font-weight: 800;
}
.workspace-switcher .material-symbols-outlined {
  color: var(--muted);
}
.sidebar-search-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  margin-top: 14px;
}
.menu-search-trigger {
  gap: 10px;
  justify-content: flex-start;
  padding: 0 12px;
  font-weight: 700;
  text-align: left;
}
.menu-search-trigger span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.nav {
  display: grid;
  gap: 4px;
  margin-top: 22px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}
.beta-nav-badge {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 2px 10px;
  align-items: center;
  margin-top: 18px;
  padding: 12px;
  border: 1px solid color-mix(in srgb, var(--accent) 28%, var(--line));
  border-radius: 8px;
  background: var(--soft);
}
.beta-nav-badge .material-symbols-outlined {
  grid-row: span 2;
  color: var(--accent);
}
.beta-nav-badge strong {
  line-height: 1.1;
}
.beta-nav-badge small {
  display: block;
  overflow: hidden;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.nav-label {
  margin: 12px 8px 4px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.workspace-label {
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}
.nav a {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  padding: 0 12px;
  border-radius: 8px;
  color: var(--muted);
  font-size: 17px;
  font-weight: 800;
}
.nav a.active, .nav a:hover {
  background: color-mix(in srgb, var(--soft) 78%, var(--surface));
  color: var(--ink);
}
.advanced-nav {
  display: grid;
  gap: 6px;
  margin-top: 4px;
}
.advanced-nav summary {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  font-size: 17px;
  font-weight: 800;
  cursor: pointer;
  list-style: none;
}
.advanced-nav summary::-webkit-details-marker { display: none; }
.advanced-nav summary:hover {
  background: var(--soft);
  color: var(--ink);
}
.advanced-nav a {
  margin-left: 10px;
  min-height: 42px;
  font-size: 15px;
}
.nav a.coming-soon {
  color: color-mix(in srgb, var(--muted) 74%, var(--ink));
}
.nav a small {
  margin-left: auto;
  padding: 6px 8px;
  border-radius: 6px;
  background: color-mix(in srgb, var(--accent) 12%, var(--surface));
  color: var(--accent);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .08em;
  line-height: 1;
}
.material-symbols-outlined { font-size: 22px; }
.sidebar-footer {
  display: flex;
  gap: 8px;
  margin-top: auto;
  padding-top: 14px;
}
.icon-btn {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  line-height: 1;
  cursor: pointer;
}
.main {
  margin-left: 342px;
  min-height: 100vh;
}
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 108px;
  padding: 24px 28px;
  border-bottom: 1px solid var(--line);
}
.topbar h1 { margin: 0; font-size: 32px; }
.topbar-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
}
.notification-menu { position: relative; }
.notification-menu summary {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--surface) 82%, var(--bg));
  line-height: 1;
  cursor: pointer;
  list-style: none;
}
.notification-menu summary::-webkit-details-marker { display: none; }
.notification-menu summary strong {
  position: absolute;
  top: -6px;
  right: -6px;
  display: grid;
  min-width: 20px;
  height: 20px;
  place-items: center;
  border-radius: 999px;
  background: #b53434;
  color: #fff;
  font-size: 11px;
  line-height: 1;
}
.notification-panel {
  position: absolute;
  z-index: 30;
  top: 54px;
  right: 0;
  display: grid;
  gap: 10px;
  width: min(360px, calc(100vw - 32px));
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.sidebar-notifications .notification-panel {
  left: auto;
  right: 0;
}
.sidebar-notifications summary {
  width: 54px;
}
.sidebar-notifications summary strong {
  top: -2px;
  right: -2px;
}
.notification-panel article {
  display: grid;
  gap: 4px;
  padding: 10px;
  border-radius: 8px;
  background: var(--bg);
}
.notification-panel article.unread { border-left: 3px solid var(--accent); }
.notification-panel span { color: var(--muted); }
.content { padding: 28px; }
.content > * { scroll-margin-top: 18px; }
.assistant-rail {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(260px, auto) auto;
  gap: 14px;
  align-items: center;
  margin-bottom: 18px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--surface) 88%, var(--soft));
  box-shadow: var(--shadow);
}
.assistant-rail h2 {
  margin: 0;
  font-size: 22px;
}
.assistant-rail p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.45;
}
.assistant-counts,
.assistant-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}
.assistant-drawer {
  grid-column: 1 / -1;
  border-top: 1px solid var(--line);
  padding-top: 10px;
}
.assistant-drawer summary {
  color: var(--ink);
  font-weight: 800;
  cursor: pointer;
}
.assistant-checklist,
.assistant-log {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}
.assistant-checklist a,
.assistant-log article {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}
.assistant-checklist a.done .material-symbols-outlined {
  color: var(--accent);
}
.assistant-checklist a:not(.done) .material-symbols-outlined {
  color: var(--muted);
}
.assistant-log article {
  grid-template-columns: 1fr;
}
.assistant-log small {
  display: block;
}
.assistant-counts span {
  display: grid;
  min-width: 94px;
  min-height: 54px;
  place-items: center;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}
.assistant-counts strong {
  display: block;
  color: var(--ink);
  font-family: "JetBrains Mono", monospace;
  font-size: 18px;
}
.simple-assistant {
  grid-template-columns: minmax(280px, 1fr) auto;
}
.simple-assistant .assistant-drawer {
  background: color-mix(in srgb, var(--surface) 70%, var(--bg));
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
}
.command-trigger {
  gap: 8px;
}
.command-palette[hidden] {
  display: none;
}
.command-palette {
  position: fixed;
  z-index: 80;
  inset: 0;
  display: grid;
  place-items: start center;
  padding: 9vh 18px 18px;
}
.command-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(8, 12, 10, .48);
  backdrop-filter: blur(6px);
}
.command-dialog {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 10px;
  width: min(720px, 100%);
  max-height: min(720px, 82vh);
  overflow: hidden;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 26px 80px rgba(0, 0, 0, .24);
}
.command-search-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.command-search-row input {
  min-height: 42px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
}
.command-results {
  display: grid;
  gap: 8px;
  overflow: auto;
  padding-right: 4px;
}
.command-result-group {
  display: grid;
  gap: 8px;
}
.command-result-group h3 {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}
.command-results a {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.command-results a.active,
.command-results a:hover {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
  background: var(--soft);
}
.command-results a > span {
  display: grid;
  place-items: center;
  min-height: 34px;
  border-radius: 8px;
  background: var(--surface);
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}
.command-results small {
  display: block;
  margin-top: 3px;
}
[data-action-help] {
  position: relative;
}
[data-action-help]:hover::after,
[data-action-help]:focus-visible::after {
  content: attr(data-action-help);
  position: absolute;
  z-index: 50;
  right: 0;
  bottom: calc(100% + 8px);
  width: min(320px, 80vw);
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--ink);
  color: var(--bg);
  box-shadow: var(--shadow);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
  text-align: left;
}
.button.is-running,
button.is-running {
  opacity: .78;
  cursor: progress;
}
.global-action-rail {
  display: grid;
  grid-template-columns: minmax(220px, .8fr) repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 18px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--surface) 84%, var(--bg));
}
.global-action-rail > div {
  display: grid;
  align-content: center;
}
.global-action-rail > div strong {
  display: block;
  line-height: 1.25;
}
.global-action {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: 8px;
  background: var(--surface);
}
.global-action.high { border-left-color: #b53434; }
.global-action.medium { border-left-color: var(--accent-2); }
.global-action.low { border-left-color: var(--accent); }
.global-action span {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}
.global-action strong,
.global-action small {
  display: block;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: normal;
}
.workspace-action-rail {
  display: grid;
  grid-template-columns: minmax(220px, .65fr) repeat(3, minmax(0, 1fr)) auto;
  gap: 10px;
  margin-bottom: 18px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--surface) 84%, var(--bg));
}
.workspace-action-rail > div {
  display: grid;
  align-content: center;
}
.workspace-action-rail .global-action {
  background: var(--surface);
}
.workspace-action-rail form,
.workspace-action-rail .button {
  width: 100%;
}
.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}
.metric-card {
  display: block;
  min-height: 118px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}
.metric-card span { color: var(--muted); font-weight: 700; }
.metric-card strong { display: block; margin-top: 18px; font-size: 34px; }
.workspace-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  margin-bottom: 18px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}
.workspace-hero h2 {
  max-width: 780px;
  margin: 0;
  font-size: 28px;
}
.workspace-hero p:not(.eyebrow) {
  max-width: 820px;
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.55;
}
.dd-command-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 210px;
  gap: 18px;
  align-items: stretch;
  margin-bottom: 18px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.dd-command-copy h2 {
  max-width: 940px;
  margin: 0;
  font-size: clamp(30px, 4vw, 52px);
  line-height: 1;
}
.dd-command-copy p:not(.eyebrow) {
  max-width: 980px;
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.55;
}
.dd-decision-card {
  display: grid;
  place-items: center;
  align-content: center;
  min-height: 170px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
  text-align: center;
}
.dd-decision-card span,
.dd-decision-card small {
  color: var(--muted);
  font-weight: 800;
}
.dd-decision-card strong {
  display: block;
  margin: 10px 0 6px;
  color: var(--accent);
  font-size: 28px;
  line-height: 1;
  text-transform: uppercase;
}
.dd-decision-card.conditional strong { color: var(--accent-2); }
.dd-decision-card.pass strong { color: #b53434; }
.dd-decision-card.investable strong { color: var(--accent); }
.live-status-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-left: 4px solid var(--muted);
}
.live-status-panel.running { border-left-color: var(--accent-2); }
.live-status-panel.succeeded { border-left-color: var(--accent); }
.live-status-panel.failed { border-left-color: #b53434; }
.live-status-panel strong,
.live-status-panel span {
  display: block;
}
.live-status-panel span {
  margin-top: 4px;
  color: var(--muted);
  font-weight: 700;
}
.live-status-panel p {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}
.review-command-panel {
  margin-bottom: 18px;
  border-left: 4px solid var(--accent-3);
}
.review-action-grid {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) repeat(3, auto);
  gap: 10px;
  align-items: end;
}
.review-action-grid label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-weight: 700;
}
.review-action-grid textarea {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
  color: var(--ink);
  padding: 9px 10px;
}
.deal-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 18px;
  margin-bottom: 14px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.deal-hero-main {
  display: grid;
  gap: 14px;
}
.deal-hero-kicker {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  color: var(--muted);
  font-weight: 800;
}
.deal-hero h2 {
  max-width: 900px;
  margin: 0;
  font-size: clamp(30px, 4vw, 54px);
  line-height: .98;
}
.deal-hero p {
  max-width: 850px;
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.55;
}
.deal-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.deal-hero-score {
  display: grid;
  place-items: center;
  align-content: center;
  min-height: 160px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
  text-align: center;
}
.deal-hero-score span, .deal-hero-score small {
  color: var(--muted);
  font-weight: 800;
}
.deal-hero-score strong {
  font-family: "JetBrains Mono", monospace;
  font-size: 52px;
  line-height: 1;
  color: var(--accent);
}
.summary-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}
.summary-strip div {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--surface) 76%, var(--bg));
}
.summary-strip span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}
.summary-strip strong {
  display: block;
  margin-top: 6px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.workspace-command {
  display: grid;
  grid-template-columns: minmax(260px, .7fr) minmax(0, 1.3fr);
  gap: 16px;
  align-items: stretch;
  margin-bottom: 14px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}
.workspace-command-copy h2 {
  margin: 0;
  font-size: 24px;
}
.workspace-command-copy p:not(.eyebrow) {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.55;
}
.workspace-status-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.status-tile {
  display: grid;
  gap: 6px;
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent-2);
  border-radius: 8px;
  background: var(--bg);
}
.status-tile.done { border-left-color: var(--accent); }
.status-tile span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}
.status-tile strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.status-tile small {
  min-height: 18px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.workspace-nav {
  position: sticky;
  z-index: 10;
  top: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 18px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  backdrop-filter: blur(16px);
}
.workspace-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 8px;
  color: var(--muted);
  font-weight: 800;
}
.workspace-nav a:hover {
  background: var(--soft);
  color: var(--ink);
}
.workspace-tabs {
  top: 0;
  justify-content: flex-start;
}
.workspace-tabs a {
  border: 1px solid transparent;
}
.workspace-tabs a:hover {
  border-color: var(--line);
}
.workspace-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 18px;
}
.workspace-section {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.queue-section {
  margin-bottom: 18px;
}
.module-action-panel {
  margin-top: 18px;
  border-left: 4px solid var(--accent-3);
}
.action-disclosure-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.action-disclosure {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.action-disclosure summary {
  min-height: 34px;
}
.action-disclosure[open] {
  background: color-mix(in srgb, var(--surface) 80%, var(--bg));
}
.soft-list {
  display: grid;
  gap: 8px;
}
.soft-list article {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.soft-list article div {
  min-width: 0;
}
.soft-list strong, .soft-list span {
  display: block;
}
.soft-list div > span {
  margin-top: 3px;
  color: var(--muted);
}
.disclosure-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.timeline-list {
  display: grid;
  gap: 10px;
}
.timeline-list article {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.timeline-list article > span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  border-radius: 8px;
  background: var(--soft);
  color: var(--accent);
  font-weight: 800;
}
.timeline-list small {
  display: block;
  margin-top: 4px;
}
.grid { display: grid; gap: 18px; }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 18px; }
.panel { padding: 18px; overflow: hidden; }
.section-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}
.section-title h2 { margin: 0; font-size: 18px; }
.section-title a, .section-title span { color: var(--muted); font-weight: 700; }
.deal-row, .compact-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}
.deal-row div, .compact-row { min-width: 0; }
.deal-row span, .compact-row span { display: block; color: var(--muted); }
.score {
  display: flex;
  flex: 0 0 46px;
  align-items: center;
  justify-content: center;
  width: 46px;
  min-width: 46px;
  height: 34px;
  padding: 0;
  border-radius: 8px;
  background: var(--soft);
  color: var(--accent);
  font-family: "JetBrains Mono", monospace;
  font-variant-numeric: tabular-nums;
  font-weight: 800;
  line-height: 1;
  text-align: center;
  text-indent: 0;
  white-space: nowrap;
}
.progress-row {
  display: grid;
  grid-template-columns: 82px 1fr 34px;
  gap: 10px;
  align-items: center;
  padding: 12px 0;
}
.progress-row div, .score-line {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--soft);
}
.progress-row i, .score-line i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent), var(--accent-3));
}
.score-line.wide { height: 10px; margin: 16px 0; }
.kanban {
  display: grid;
  grid-template-columns: repeat(5, minmax(230px, 1fr));
  gap: 14px;
  align-items: start;
  overflow-x: auto;
  padding-bottom: 8px;
}
.kanban-column {
  min-height: 520px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--surface) 76%, var(--bg));
}
.kanban-column header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 12px;
}
.kanban-column h2 { margin: 0; font-size: 16px; }
.deal-card {
  display: grid;
  gap: 12px;
  margin-bottom: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}
.deal-card p { margin: 0; color: var(--muted); line-height: 1.45; }
.deal-card-top, .deal-meta, .listing-facts {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.badge {
  display: inline-flex;
  min-height: 26px;
  align-items: center;
  justify-content: center;
  padding: 0 9px;
  border-radius: 999px;
  background: var(--soft);
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  text-align: center;
}
.badge.high { color: #b53434; }
.badge.low { color: var(--muted); }
.badge.pending, .badge.review { color: var(--accent-2); }
.badge.active, .badge.approved, .badge.signed { color: var(--accent); }
.badge.blocker, .badge.high { color: #b53434; }
.badge.investable { color: var(--accent); }
.badge.conditional { color: var(--accent-2); }
.badge.pass { color: #b53434; }
.empty-state {
  margin: 0;
  padding: 16px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: var(--bg);
  font-weight: 700;
}
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 18px;
}
.list-stack { display: grid; gap: 16px; }
.action-stack {
  display: grid;
  gap: 10px;
}
.workflow-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.workflow-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--muted);
  border-radius: 8px;
  background: var(--bg);
}
.workflow-card.high { border-left-color: #b53434; }
.workflow-card.medium { border-left-color: var(--accent-2); }
.workflow-card.low { border-left-color: var(--accent); }
.workflow-card strong { display: block; }
.workflow-card span { color: var(--muted); font-weight: 700; }
.workflow-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}
.workflow-card form,
.workflow-card .button {
  width: 100%;
}
.workflow-card .button {
  min-height: 36px;
  padding: 0 12px;
}
.evidence-health-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.evidence-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.evidence-card .button {
  width: 100%;
  min-height: 36px;
}
.evidence-checks {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.evidence-checks span {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  text-align: center;
}
.evidence-checks span.done {
  border-color: color-mix(in srgb, var(--accent) 42%, var(--line));
  background: var(--soft);
  color: var(--accent);
}
.evidence-dropzone {
  margin-bottom: 18px;
  border-style: dashed;
  border-left: 4px solid var(--accent);
}
.capture-flow {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}
.capture-flow article {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 4px 10px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.capture-flow span {
  display: grid;
  grid-row: span 2;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 8px;
  background: var(--soft);
  color: var(--accent);
  font-family: "JetBrains Mono", monospace;
  font-weight: 800;
  line-height: 1;
}
.capture-flow strong,
.capture-flow small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.triage-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.triage-actions .button {
  width: 100%;
  min-height: 36px;
  padding: 0 10px;
  font-size: 13px;
}
.notification-inbox {
  display: grid;
  gap: 10px;
}
.notification-inbox article {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.notification-inbox article.unread {
  border-left-color: var(--accent);
  background: var(--surface);
}
.notification-inbox strong,
.notification-inbox p,
.notification-inbox small {
  display: block;
}
.notification-inbox p {
  margin: 8px 0;
  color: var(--muted);
  line-height: 1.45;
}
.notification-actions {
  display: grid;
  gap: 8px;
  align-content: center;
}
.notification-actions .button {
  width: 100%;
}
.action-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto auto;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.action-row span { color: var(--muted); }
.action-row .button { min-height: 36px; padding: 0 12px; }
.meeting-card h3 { margin: 0 0 8px; }
.meeting-card p { color: var(--muted); line-height: 1.55; }
.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}
.chip-row span, .checklist span {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-weight: 700;
  line-height: 1;
  text-align: center;
}
.risk-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}
.risk-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent-2);
  border-radius: 8px;
  background: var(--bg);
}
.risk-card.high { border-left-color: #b53434; }
.risk-card.medium { border-left-color: var(--accent-2); }
.risk-card.low { border-left-color: var(--accent); }
.risk-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.risk-card-top strong { line-height: 1.25; }
.risk-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}
.risk-chip {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-weight: 700;
  line-height: 1;
  text-align: center;
}
.relationship-grid, .listing-grid, .report-grid, .opportunity-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.person-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.person-card span { color: var(--muted); }
.listing-card, .report-card, .opportunity-card {
  display: grid;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.listing-card p, .report-card p, .opportunity-card p { margin: 0; color: var(--muted); line-height: 1.5; }
.report-card h3 { margin: 0; font-size: 18px; }
.swat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.swat-grid div {
  display: grid;
  gap: 7px;
  padding: 10px;
  border-radius: 8px;
  background: var(--surface);
}
.swat-grid h3 { margin: 0; font-size: 13px; }
.swat-grid small { color: var(--muted); line-height: 1.4; }
.listing-facts {
  align-items: stretch;
}
.listing-facts span {
  display: grid;
  gap: 4px;
  flex: 1;
  padding: 10px;
  border-radius: 8px;
  background: var(--soft);
  color: var(--muted);
}
.listing-facts strong { color: var(--ink); }
.checklist {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.checklist .done {
  border-color: color-mix(in srgb, var(--accent) 42%, var(--line));
  color: var(--accent);
  background: var(--soft);
}
.readable {
  max-width: 980px;
  line-height: 1.65;
  color: var(--muted);
}
.review-section {
  margin-top: 18px;
  scroll-margin-top: 82px;
}
.coverage-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.coverage-grid div {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.coverage-grid span {
  display: block;
  color: var(--muted);
  font-weight: 800;
}
.coverage-grid strong {
  display: block;
  margin-top: 8px;
  font-size: 28px;
}
.missing-evidence {
  display: grid;
  gap: 8px;
  margin: 14px 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.missing-evidence strong {
  font-size: 13px;
}
.missing-evidence span {
  display: block;
  color: var(--muted);
  line-height: 1.45;
}
.action-disclosure {
  padding: 0;
  border-top: 0;
}
.compact-source-list {
  max-height: 520px;
  overflow: auto;
  padding-right: 4px;
}
.question-list {
  display: grid;
  gap: 10px;
}
.question-list article {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.question-list span {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 8px;
  background: var(--soft);
  color: var(--accent);
  font-family: "JetBrains Mono", monospace;
  font-weight: 800;
}
.section-stack {
  display: grid;
  gap: 16px;
}
.report-section {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
table {
  width: 100%;
  border-collapse: collapse;
}
th, td {
  padding: 13px 10px;
  border-top: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}
th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}
td span { color: var(--muted); }
.form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  align-items: end;
}
.form-grid label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-weight: 700;
}
.form-grid input, .form-grid select, .form-grid textarea {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
  color: var(--ink);
  padding: 9px 10px;
}
.form-grid textarea { min-height: 96px; }
.form-grid .button { align-self: end; }
.form-stack {
  display: grid;
  gap: 12px;
}
.form-stack label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-weight: 700;
}
.form-stack input, .form-stack select, .form-stack textarea {
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
  color: var(--ink);
  padding: 8px 10px;
}
.form-stack textarea { min-height: 96px; }
.form-grid ul, .form-stack ul {
  display: grid;
  gap: 6px;
  max-height: 180px;
  margin: 0;
  padding: 10px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
  list-style: none;
}
.form-grid li label, .form-stack li label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  font-weight: 600;
}
.form-grid input[type="checkbox"], .form-stack input[type="checkbox"] {
  width: 16px;
  min-height: 16px;
}
.friendly-disclosure {
  padding: 12px 0;
  border-top: 1px solid var(--line);
}
.friendly-disclosure summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 38px;
  color: var(--ink);
  font-weight: 800;
  cursor: pointer;
}
.friendly-disclosure .form-stack { margin-top: 12px; }
.filter-bar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(160px, 240px) minmax(150px, 220px) auto;
  gap: 12px;
  align-items: end;
}
.filter-bar label, .inline-action {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-weight: 700;
}
.filter-bar input, .filter-bar select, .inline-action select {
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
  color: var(--ink);
  padding: 8px 10px;
}
.inline-action {
  grid-template-columns: 1fr auto;
  align-items: end;
  margin-top: 4px;
}
.workflow-hero {
  align-items: stretch;
}
.workflow-stat-stack {
  display: grid;
  grid-template-columns: repeat(2, minmax(96px, 1fr));
  gap: 10px;
  min-width: 260px;
}
.workflow-stat-stack div,
.quality-score {
  display: grid;
  place-items: center;
  min-height: 120px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
  text-align: center;
}
.workflow-stat-stack span,
.quality-score span {
  color: var(--muted);
  font-weight: 800;
}
.workflow-stat-stack strong,
.quality-score strong {
  font-family: "JetBrains Mono", monospace;
  font-size: 40px;
}
.bulk-action-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}
.automation-card {
  display: grid;
  gap: 8px;
  min-height: 158px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}
.automation-card:hover {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
  background: var(--soft);
}
.automation-card .material-symbols-outlined {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 8px;
  background: var(--soft);
  color: var(--accent);
}
.automation-card small,
.task-card p,
.task-meta span,
.readiness-grid small {
  color: var(--muted);
  line-height: 1.45;
}
.workflow-board {
  margin-top: 18px;
}
.workflow-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: flex-end;
}
.segmented-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.segmented-links a {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  font-weight: 800;
}
.segmented-links a.active {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
  color: var(--accent);
  background: var(--soft);
}
.view-toggle {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.view-toggle button {
  display: grid;
  width: 36px;
  height: 32px;
  place-items: center;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}
.view-toggle button.active {
  background: var(--surface);
  color: var(--accent);
  box-shadow: 0 4px 14px rgba(20, 27, 24, .08);
}
.task-groups {
  display: grid;
  gap: 18px;
}
.task-group {
  display: grid;
  gap: 12px;
}
.task-group > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
}
.task-group > header h3 {
  margin: 0;
}
.task-group > header span {
  display: grid;
  min-width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 8px;
  background: var(--surface);
  color: var(--accent);
  font-family: "JetBrains Mono", monospace;
  font-weight: 800;
}
.task-group-empty {
  display: grid;
  min-height: 96px;
  place-items: center;
  margin: 0;
  padding: 14px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: var(--bg);
  color: var(--muted);
  font-weight: 800;
  text-align: center;
}
.task-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.task-card {
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--muted);
  border-radius: 8px;
  background: var(--bg);
}
.task-card.high { border-left-color: var(--danger); }
.task-card.medium { border-left-color: var(--warning); }
.task-card.low { border-left-color: var(--accent); }
.task-card.overdue { background: color-mix(in srgb, var(--danger) 8%, var(--bg)); }
.task-card h3 {
  margin: 0;
  font-size: 18px;
}
.task-card-top,
.task-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  justify-content: space-between;
}
.task-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.task-meta span {
  display: grid;
  gap: 4px;
  min-height: 54px;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
  font-size: 12px;
}
.task-meta strong {
  color: var(--ink);
  overflow-wrap: anywhere;
}
.task-assignment {
  padding-bottom: 0;
}
.task-groups[data-view="list"] .task-grid {
  grid-template-columns: 1fr;
}
.task-groups[data-view="list"] .task-card {
  grid-template-columns: minmax(180px, .75fr) minmax(220px, 1fr) minmax(260px, .9fr) auto;
  align-items: center;
}
.task-groups[data-view="list"] .task-card-top {
  justify-content: flex-start;
}
.task-groups[data-view="list"] .task-card h3,
.task-groups[data-view="list"] .task-card p {
  margin: 0;
}
.task-groups[data-view="list"] .task-meta {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.task-groups[data-view="list"] .task-assignment {
  grid-column: 1 / -1;
}
.empty-workflow-state {
  display: grid;
  place-items: center;
  grid-column: 1 / -1;
  gap: 10px;
  min-height: 280px;
  padding: 26px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: var(--soft);
  text-align: center;
}
.empty-workflow-state .material-symbols-outlined {
  color: var(--accent);
  font-size: 42px;
}
.readiness-panel {
  margin-top: 18px;
}
.readiness-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.readiness-grid article,
.quality-checks article,
.snapshot-list article,
.audit-timeline article {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.readiness-grid article.ok .material-symbols-outlined,
.quality-checks article.done .material-symbols-outlined {
  color: var(--accent);
}
.readiness-grid article.attention .material-symbols-outlined,
.quality-checks article.todo .material-symbols-outlined {
  color: var(--warning);
}
.quality-overview {
  display: grid;
  grid-template-columns: minmax(180px, 260px) minmax(0, 1fr);
  gap: 14px;
  align-items: stretch;
}
.quality-checks {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}
.quality-checks article {
  align-items: center;
}
.quality-checks small,
.snapshot-list span,
.audit-timeline small {
  display: block;
  color: var(--muted);
}
.snapshot-diff-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}
.snapshot-diff-grid article {
  display: grid;
  place-items: center;
  min-height: 92px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
  text-align: center;
}
.snapshot-diff-grid span {
  color: var(--muted);
  font-weight: 800;
}
.snapshot-diff-grid strong {
  font-family: "JetBrains Mono", monospace;
  font-size: 28px;
}
.snapshot-list,
.audit-timeline {
  display: grid;
  gap: 10px;
}
.audit-timeline article {
  grid-template-columns: minmax(110px, 180px) minmax(0, 1fr);
}
.audit-timeline > article > span {
  color: var(--muted);
  font-weight: 800;
}
.swat-grid.compact {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.command-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.command-hero h2,
.pipeline-hero h2 {
  margin: 0;
  font-size: 32px;
}
.command-hero p,
.pipeline-hero p {
  max-width: 720px;
  color: var(--muted);
  line-height: 1.55;
}
.command-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.command-actions .button {
  gap: 8px;
}
.beta-workflow {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}
.beta-step {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 8px 10px;
  min-height: 168px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.beta-step > span {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 8px;
  background: var(--ink);
  color: var(--bg);
  font-family: "JetBrains Mono", monospace;
  font-weight: 800;
  line-height: 1;
}
.beta-step strong,
.module-map strong {
  display: block;
  line-height: 1.25;
}
.beta-step p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.45;
}
.beta-step small {
  grid-column: 2;
  align-self: end;
  width: fit-content;
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--soft);
  color: var(--accent);
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
}
.v1-module-panel {
  margin-bottom: 18px;
}
.module-map {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 10px;
}
.module-map a {
  position: relative;
  display: grid;
  grid-template-rows: auto minmax(92px, 1fr) auto;
  gap: 10px;
  min-height: 194px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.module-map .material-symbols-outlined {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 8px;
  background: var(--soft);
  color: var(--accent);
}
.module-map small {
  display: block;
  margin-top: 6px;
  line-height: 1.4;
}
.module-map em {
  width: fit-content;
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
  line-height: 1;
}
.focus-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}
.focus-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.focus-card > .material-symbols-outlined,
.pipeline-action-card > .material-symbols-outlined,
.preview-list .material-symbols-outlined {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 8px;
  background: var(--soft);
  color: var(--accent);
}
.focus-card.high { border-left: 4px solid #b53434; }
.focus-card.medium { border-left: 4px solid var(--accent-2); }
.focus-card.low { border-left: 4px solid var(--accent-3); }
.focus-card strong {
  display: block;
  font-family: "JetBrains Mono", monospace;
  font-size: 30px;
}
.focus-card p,
.pipeline-action-card small,
.preview-list small {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}
.shortcut-grid,
.pipeline-action-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}
.shortcut-grid a,
.pipeline-action-card {
  display: grid;
  gap: 8px;
  min-height: 128px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.shortcut-grid a:hover,
.pipeline-action-card:hover {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
  background: var(--soft);
}
.pipeline-hero {
  margin-bottom: 14px;
}
.pipeline-health,
.pipeline-gap-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.pipeline-health {
  min-width: 360px;
}
.pipeline-health div,
.pipeline-gap-strip div {
  display: grid;
  place-items: center;
  min-height: 98px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
  text-align: center;
}
.pipeline-health span,
.pipeline-gap-strip span {
  color: var(--muted);
  font-weight: 800;
}
.pipeline-health strong,
.pipeline-gap-strip strong {
  font-family: "JetBrains Mono", monospace;
  font-size: 30px;
}
.pipeline-action-grid,
.pipeline-gap-strip {
  margin-bottom: 18px;
}
.deal-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.deal-card-actions .button {
  min-height: 36px;
  padding: 0 12px;
}
.intake-stepper {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 18px;
}
.intake-stepper article,
.preview-list article {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}
.intake-stepper span {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 8px;
  background: var(--ink);
  color: var(--bg);
  font-family: "JetBrains Mono", monospace;
  font-weight: 800;
}
.intake-form {
  display: grid;
  gap: 16px;
}
.intake-form fieldset {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.intake-form legend {
  padding: 0 8px;
  color: var(--accent);
  font-weight: 800;
}
.intake-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-weight: 700;
}
.intake-form label.wide {
  grid-column: 1 / -1;
}
.intake-form input,
.intake-form textarea {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
  color: var(--ink);
  padding: 9px 10px;
}
.intake-form textarea {
  min-height: 118px;
}
.intake-toggle {
  display: flex !important;
  align-items: center;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
}
.intake-toggle input {
  width: 18px;
  min-height: 18px;
}
.intake-preview {
  align-self: start;
  position: sticky;
  top: 18px;
}
.preview-list {
  display: grid;
  gap: 10px;
}
.simple-home-hero,
.simple-deal-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  margin-bottom: 18px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(135deg, var(--surface), color-mix(in srgb, var(--soft) 70%, var(--surface)));
  box-shadow: var(--shadow);
}
.simple-home-hero h2,
.simple-deal-hero h2 {
  margin: 0;
  font-size: 36px;
  line-height: 1.05;
}
.simple-home-hero p,
.simple-deal-hero p {
  max-width: 760px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.55;
}
.simple-home-actions,
.plain-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.simple-home-actions .button {
  gap: 8px;
}
.plain-meta span {
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}
.simple-deal-hero aside {
  display: grid;
  gap: 6px;
  width: min(300px, 100%);
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}
.simple-deal-hero aside span,
.simple-deal-hero aside p {
  margin: 0;
  color: var(--muted);
}
.simple-deal-hero aside strong {
  color: var(--ink);
  font-size: 24px;
  line-height: 1.15;
}
.simple-deal-hero.ready aside { border-left: 5px solid var(--accent); }
.simple-deal-hero.needs-work aside,
.simple-deal-hero.not-started aside { border-left: 5px solid var(--accent-2); }
.simple-deal-hero.stop aside { border-left: 5px solid #b53434; }
.simple-grid {
  display: grid;
  gap: 18px;
  margin-bottom: 18px;
}
.simple-grid.two-one {
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, .65fr);
}
.simple-deal-list,
.simple-task-list,
.simple-update-list,
.client-progress-map {
  display: grid;
  gap: 10px;
}
.simple-deal-list a,
.simple-task-list a,
.client-progress-map a,
.simple-update-list article {
  display: grid;
  gap: 4px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.simple-deal-list a {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}
.simple-deal-list span,
.decision-card-simple span,
.memo-card span {
  justify-self: start;
  padding: 6px 9px;
  border-radius: 999px;
  background: var(--soft);
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
}
.simple-deal-list span.ready,
.decision-card-simple.ready span { color: var(--accent); }
.simple-deal-list span.needs-work,
.decision-card-simple.needs-work span,
.decision-card-simple.not-started span { color: var(--accent-2); }
.simple-deal-list span.stop,
.decision-card-simple.stop span { color: #b53434; }
.simple-task-list a {
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
}
.simple-task-list a > span,
.client-progress-map a > span {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 8px;
  background: var(--surface);
  color: var(--accent);
  font-weight: 900;
}
.client-progress-map {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.client-progress-map a {
  min-height: 132px;
}
.client-progress-map a.done {
  border-color: color-mix(in srgb, var(--accent) 42%, var(--line));
  background: color-mix(in srgb, var(--soft) 74%, var(--surface));
}
.client-progress-map a.done > span {
  background: var(--accent);
  color: #fff;
}
.advanced-panel {
  margin: 18px 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--surface) 82%, var(--bg));
}
.advanced-panel > summary {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 16px;
  color: var(--muted);
  font-weight: 900;
  cursor: pointer;
  list-style: none;
}
.advanced-panel > summary::-webkit-details-marker { display: none; }
.advanced-panel[open] {
  padding: 0 16px 16px;
}
.advanced-panel[open] > summary {
  margin: 0 -16px 16px;
  border-bottom: 1px solid var(--line);
}
.guided-action-panel,
.simple-progress-panel {
  margin-bottom: 18px;
}
.one-action-card,
.memo-card,
.decision-card-simple {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}
.one-action-card {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}
.one-action-card > div > span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.one-action-card p,
.memo-card p,
.decision-card-simple p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}
.memo-card .button {
  justify-self: start;
}
.memo-card.pass,
.decision-card-simple.stop { border-left: 5px solid #b53434; }
.memo-card.conditional,
.decision-card-simple.needs-work,
.decision-card-simple.not-started { border-left: 5px solid var(--accent-2); }
.memo-card.investable,
.decision-card-simple.ready { border-left: 5px solid var(--accent); }
.large-empty {
  min-height: 118px;
  display: grid;
  place-items: center;
  padding: 18px;
  text-align: center;
}
.primary-disclosure {
  margin-top: 14px;
  border-color: color-mix(in srgb, var(--accent) 28%, var(--line));
  background: color-mix(in srgb, var(--soft) 58%, var(--surface));
}
.primary-disclosure summary {
  font-size: 16px;
}

@media (max-width: 980px) {
  .hero, .deal-hero, .simple-home-hero, .simple-deal-hero, .simple-grid.two-one, .grid.two, .grid.three, .relationship-grid, .listing-grid, .report-grid, .opportunity-grid, .workflow-grid, .workspace-grid, .disclosure-grid, .landing-band, .risk-card-grid, .workspace-command, .dd-command-hero, .action-disclosure-grid, .global-action-rail, .workspace-action-rail, .evidence-health-grid, .capture-flow, .review-action-grid, .notification-inbox article, .bulk-action-grid, .task-grid, .quality-overview, .assistant-rail, .task-groups[data-view="list"] .task-card {
    grid-template-columns: 1fr;
  }
  .assistant-actions, .assistant-counts, .workflow-controls { justify-content: flex-start; }
  .summary-strip, .workspace-status-grid, .coverage-grid, .readiness-grid, .quality-checks, .snapshot-diff-grid, .focus-grid, .shortcut-grid, .pipeline-action-grid, .intake-stepper, .beta-workflow, .module-map, .client-progress-map { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .command-hero { align-items: flex-start; flex-direction: column; }
  .pipeline-health { min-width: 0; width: 100%; }
  .workspace-hero {
    align-items: flex-start;
    flex-direction: column;
  }
  .action-row { grid-template-columns: 1fr auto; }
  .swat-grid { grid-template-columns: 1fr; }
  .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .form-grid { grid-template-columns: 1fr; }
  .filter-bar { grid-template-columns: 1fr; }
  .sidebar {
    position: static;
    width: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .nav { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .nav-label { grid-column: 1 / -1; }
  .main { margin-left: 0; }
}

@media (max-width: 620px) {
  .hero h1 { font-size: 52px; }
  .simple-home-hero h2, .simple-deal-hero h2 { font-size: 30px; }
  .metric-grid, .summary-strip, .workspace-status-grid, .coverage-grid, .readiness-grid, .quality-checks, .snapshot-diff-grid, .task-meta, .swat-grid.compact, .focus-grid, .shortcut-grid, .pipeline-action-grid, .pipeline-health, .pipeline-gap-strip, .intake-stepper, .intake-form fieldset, .beta-workflow, .module-map, .client-progress-map, .one-action-card { grid-template-columns: 1fr; }
  .nav { grid-template-columns: 1fr; }
  .notification-panel {
    left: 0;
    right: auto;
    width: calc(100vw - 32px);
  }
  .command-results a { grid-template-columns: 1fr; }
  .command-dialog { padding: 10px; }
  .timeline-list article { grid-template-columns: 1fr; }
  .topbar { align-items: flex-start; flex-direction: column; }
  .topbar-actions {
    width: 100%;
    justify-content: flex-start;
  }
  .notification-menu summary {
    width: 54px;
  }
  .notification-menu summary strong {
    top: -2px;
    right: -2px;
  }
  .content { padding: 16px; }
  .intake-preview { position: static; }
}
