:root {
  --navy: #0b1220;
  --navy-2: #111b2e;
  --navy-3: #1b2740;
  --ink: #101828;
  --muted: #667085;
  --muted-2: #98a2b3;
  --line: #e4e7ec;
  --line-2: #eef1f5;
  --soft: #f7f8fa;
  --bg: #f4f6f9;
  --red: #b42318;
  --red-2: #e5483f;
  --red-soft: #fee4e2;
  --green: #067647;
  --green-soft: #dcfae6;
  --amber: #b54708;
  --amber-soft: #fef3c7;
  --blue: #026aa2;
  --blue-soft: #e0f2fe;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 1px 3px rgba(16, 24, 40, .06);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font: 14px/1.5 "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
h1, h2, h3, p { margin: 0; }
svg { display: block; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: 0 0 auto; }
.mono { font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace; font-size: 12px; }
.prototype-flag {
  position: fixed; right: 18px; bottom: 16px; z-index: 120;
  background: #101828; color: #fff; border: 1px solid #344054;
  padding: 6px 10px; border-radius: 999px; font-size: 10px; font-weight: 800;
  letter-spacing: .12em; box-shadow: 0 8px 24px rgba(0,0,0,.18);
}

/* Shell */
.app { display: grid; grid-template-columns: 256px minmax(0, 1fr); min-height: 100vh; }
.sidebar {
  position: sticky; top: 0; height: 100vh; background: var(--navy); color: #cbd5e1;
  padding: 22px 16px 18px; display: flex; flex-direction: column; gap: 20px; z-index: 30;
}
.brand { display: flex; align-items: center; gap: 10px; color: #fff; padding: 0 6px; }
.brand-mark {
  display: grid; place-items: center; width: 36px; height: 36px; border-radius: 8px;
  background: var(--red); color: #fff; font-weight: 900; font-size: 19px;
  box-shadow: 0 6px 18px rgba(180,35,24,.35);
}
.brand-text { font-weight: 800; letter-spacing: .08em; font-size: 15px; line-height: 1.1; }
.brand-text small { display: block; font-size: 8.5px; letter-spacing: .2em; color: #94a3b8; margin-top: 2px; }
.workspace {
  display: flex; align-items: center; gap: 10px; width: 100%;
  background: #111b2e; color: #fff; border: 1px solid #25324a; border-radius: 8px;
  padding: 9px 10px; text-align: left;
}
.workspace-avatar { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 6px; background: #273449; color: #fff; font-size: 12px; font-weight: 800; }
.workspace-copy { flex: 1; min-width: 0; }
.workspace-copy strong { display: block; font-size: 12px; }
.workspace-copy small { display: block; color: #94a3b8; font-size: 10px; }
.workspace .icon { width: 14px; height: 14px; color: #94a3b8; }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav-label { margin: 16px 10px 5px; font-size: 9.5px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: #64748b; }
.nav-item {
  display: flex; align-items: center; gap: 10px; color: #cbd5e1; padding: 8px 10px;
  border-radius: 6px; font-size: 13px; border-left: 3px solid transparent;
}
.nav-item .icon { width: 17px; height: 17px; color: #94a3b8; }
.nav-item em { margin-left: auto; font-style: normal; font-size: 10px; background: #1e293b; color: #cbd5e1; border-radius: 999px; padding: 1px 7px; }
.nav-item em.danger { background: #3b1d1d; color: #fda29b; }
.nav-item:hover { background: #111b2e; color: #fff; }
.nav-item.active { background: #17233a; color: #fff; border-left-color: var(--red-2); }
.nav-item.active .icon { color: #fff; }
.sidebar-foot { margin-top: auto; border-top: 1px solid #1e293b; padding-top: 14px; }
.sidebar-note { display: flex; align-items: center; gap: 7px; color: #64748b; font-size: 10px; margin-bottom: 12px; }
.sidebar-note .icon { width: 14px; height: 14px; }
.sidebar-user { display: flex; align-items: center; gap: 9px; }
.avatar { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: #334155; color: #fff; font-size: 10.5px; font-weight: 800; flex: 0 0 auto; }
.avatar.alt { background: #7f1d1d; }
.avatar.blue { background: #075985; }
.avatar.client { background: #14532d; }
.avatar.square { border-radius: 7px; width: 34px; height: 34px; }
.sidebar-user strong { display: block; color: #e2e8f0; font-size: 11.5px; }
.sidebar-user small { color: #94a3b8; font-size: 10px; }
.sidebar-user .icon-btn { margin-left: auto; }

.main { min-width: 0; }
.topbar {
  position: sticky; top: 0; z-index: 20; height: 64px; background: rgba(255,255,255,.94);
  backdrop-filter: blur(10px); border-bottom: 1px solid var(--line);
  display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 0 28px;
}
.crumbs { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--muted); }
.crumbs strong { color: var(--ink); font-weight: 650; }
.slash { color: var(--line); }
.top-actions { display: flex; align-items: center; gap: 9px; }
.search {
  display: flex; align-items: center; gap: 7px; background: var(--soft);
  border: 1px solid var(--line); border-radius: 7px; padding: 7px 10px; color: var(--muted-2);
  min-width: 240px;
}
.search .icon { width: 15px; height: 15px; }
.search input { border: 0; outline: 0; background: transparent; width: 100%; font-size: 12px; color: var(--ink); }
.search.compact { min-width: 220px; }
.icon-btn {
  display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 7px;
  border: 1px solid var(--line); background: #fff; color: var(--muted); position: relative;
}
.icon-btn:hover { background: var(--soft); color: var(--ink); }
.icon-btn .icon { width: 17px; height: 17px; }
.bell span { position: absolute; top: -5px; right: -5px; background: var(--red); color: #fff; font-size: 9px; font-weight: 800; width: 16px; height: 16px; border-radius: 50%; display: grid; place-items: center; border: 2px solid #fff; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  border: 1px solid transparent; border-radius: 7px; padding: 8px 12px;
  font-size: 12.5px; font-weight: 650; line-height: 1; background: #fff; color: var(--ink);
  white-space: nowrap;
}
.btn .icon { width: 16px; height: 16px; }
.btn-primary { background: var(--red); border-color: var(--red); color: #fff; box-shadow: 0 2px 4px rgba(180,35,24,.2); }
.btn-primary:hover { background: #981b13; }
.btn-ghost { border-color: var(--line); color: var(--ink); }
.btn-ghost:hover { background: var(--soft); }
.btn.small { padding: 6px 10px; font-size: 11.5px; }
.link-btn { display: inline-flex; align-items: center; gap: 5px; border: 0; background: none; color: var(--red); font-size: 11.5px; font-weight: 700; padding: 0; }
.link-btn .icon { width: 13px; height: 13px; }

.content { padding: 26px 28px 44px; max-width: 1500px; margin: 0 auto; }
.view { display: none; }
.view.active { display: block; animation: fade .18s ease; }
@keyframes fade { from { opacity: .3; transform: translateY(3px); } to { opacity: 1; transform: none; } }

/* Page head */
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.eyebrow { font-size: 9.5px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--red); margin-bottom: 6px; }
.page-head h1 { font-size: 28px; line-height: 1.1; letter-spacing: -.035em; }
.page-head p { color: var(--muted); font-size: 12.5px; margin-top: 6px; }
.segmented { display: inline-flex; background: #fff; border: 1px solid var(--line); border-radius: 7px; padding: 3px; }
.segmented button { border: 0; background: none; color: var(--muted); padding: 5px 10px; font-size: 11px; border-radius: 5px; font-weight: 600; }
.segmented button.active { background: var(--navy); color: #fff; }

/* KPI */
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 14px; }
.kpi { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 15px 16px 12px; box-shadow: var(--shadow); position: relative; overflow: hidden; }
.kpi-head { display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: 11px; font-weight: 600; }
.kpi-icon { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 6px; background: var(--soft); color: var(--muted); }
.kpi-icon .icon { width: 14px; height: 14px; }
.kpi-icon.danger { background: var(--red-soft); color: var(--red); }
.kpi > strong { display: block; font-size: 28px; letter-spacing: -.04em; margin-top: 9px; line-height: 1; }
.kpi > strong small { font-size: 12px; color: var(--muted); font-weight: 500; letter-spacing: 0; }
.kpi-foot { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 10.5px; margin-top: 8px; }
.trend { font-weight: 700; }
.trend.up { color: var(--green); }
.trend.down { color: var(--red); }
.spark { width: 100%; height: 24px; margin-top: 8px; color: #98a2b3; opacity: .55; }
.spark.danger { color: var(--red); }
.spark.success { color: var(--green); }
.mini-progress { height: 4px; background: var(--line-2); border-radius: 999px; margin-top: 14px; overflow: hidden; }
.mini-progress span { display: block; height: 100%; background: var(--red); border-radius: inherit; }

/* Panels */
.panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 20px; min-width: 0; }
.panel.compact { padding: 15px 17px; }
.panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 14px; }
.panel-head h2 { font-size: 14px; letter-spacing: -.01em; }
.panel-head p { color: var(--muted); font-size: 10.5px; margin-top: 3px; }
.grid-2 { display: grid; grid-template-columns: 1.25fr .75fr; gap: 14px; margin-bottom: 14px; }
.dashboard-bottom { display: grid; grid-template-columns: 1.45fr .55fr; gap: 14px; }

/* Risk bars */
.risk-list { display: flex; flex-direction: column; gap: 15px; }
.risk-row { display: grid; grid-template-columns: 1.3fr 1.4fr 64px; gap: 14px; align-items: center; }
.risk-label strong { display: block; font-size: 12px; font-weight: 650; }
.risk-label span { display: block; color: var(--muted); font-size: 10px; margin-top: 2px; }
.risk-bar { display: flex; height: 8px; border-radius: 999px; overflow: hidden; background: var(--line-2); }
.risk-bar i { display: block; height: 100%; }
.risk-bar i + i { border-left: 2px solid #fff; }
.risk-bar.empty i { background: #eaecf0; }
.sev-critical { background: #7f1d1d; }
.sev-high { background: #b42318; }
.sev-medium { background: #b54708; }
.sev-low { background: #026aa2; }
.risk-score { font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; text-align: right; }
.risk-score.critical { color: #7f1d1d; }
.risk-score.high { color: var(--red); }
.risk-score.medium { color: var(--amber); }
.risk-score.low { color: var(--green); }

/* Donut */
.donut-wrap { display: flex; align-items: center; gap: 26px; padding: 4px 2px 8px; }
.donut { width: 144px; height: 144px; border-radius: 50%; position: relative; display: grid; place-items: center; flex: 0 0 auto;
  background: conic-gradient(#7f1d1d 0 16.6%, #b42318 16.6% 41.6%, #b54708 41.6% 75%, #026aa2 75% 100%);
}
.donut::before { content: ""; position: absolute; inset: 21px; background: #fff; border-radius: 50%; }
.donut-center { position: relative; z-index: 1; text-align: center; }
.donut-center strong { display: block; font-size: 28px; line-height: 1; letter-spacing: -.04em; }
.donut-center span { display: block; color: var(--muted); font-size: 10px; margin-top: 3px; }
.legend { list-style: none; padding: 0; margin: 0; flex: 1; display: flex; flex-direction: column; gap: 9px; }
.legend li { display: grid; grid-template-columns: 10px 1fr auto; align-items: center; gap: 8px; font-size: 11.5px; color: var(--muted); }
.legend strong { color: var(--ink); font-size: 11.5px; }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.dot.critical { background: #7f1d1d; }
.dot.high { background: #b42318; }
.dot.medium { background: #b54708; }
.dot.low { background: #026aa2; }
.finding-count { display: inline-flex; align-items: center; gap: 6px; font-weight: 650; font-size: 11.5px; }
.finding-count.muted { color: var(--muted-2); font-weight: 500; }

/* Tables */
.table-wrap { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.data-table th { text-align: left; color: var(--muted); font-size: 9.5px; text-transform: uppercase; letter-spacing: .06em; padding: 8px 9px; border-bottom: 1px solid var(--line); white-space: nowrap; font-weight: 700; }
.data-table td { padding: 9px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
.data-table tr:last-child td { border-bottom: 0; }
.data-table td strong { display: block; font-weight: 650; font-size: 11.5px; }
.data-table td > span { display: block; color: var(--muted); font-size: 10px; margin-top: 2px; }
.data-table tbody tr.clickable { cursor: pointer; }
.data-table tbody tr.clickable:hover { background: #fafbfc; }
.data-table .arrow { width: 15px; height: 15px; color: var(--muted-2); }
.data-table.roomy td { padding: 12px 10px; }
.data-table.findings-table td:nth-child(3) { min-width: 210px; }
.data-table .mini-user { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: #eef2f6; color: #344054; font-size: 9px; font-weight: 800; }
.progress { height: 6px; border-radius: 999px; background: var(--line-2); overflow: hidden; width: 100px; display: inline-block; vertical-align: middle; }
.progress span { display: block; height: 100%; background: var(--red); border-radius: inherit; }
.progress + small { display: inline-block; margin-left: 7px; color: var(--muted); font-size: 9.5px; }
.progress.large { width: 100%; height: 8px; }
.progress.success span { background: var(--green); }
.progress.muted span { background: #98a2b3; }

/* Badges */
.badge { display: inline-block; padding: 2px 6px; border-radius: 4px; font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; white-space: nowrap; }
.badge.sev-critical { background: #7f1d1d; color: #fff; }
.badge.sev-high { background: #b42318; color: #fff; }
.badge.sev-medium { background: #b54708; color: #fff; }
.badge.sev-low { background: #026aa2; color: #fff; }
.badge.status-progress { background: var(--amber-soft); color: #92400e; }
.badge.status-done { background: var(--green-soft); color: var(--green); }
.badge.status-plan { background: var(--blue-soft); color: #075985; }
.badge.classification { background: #101828; color: #fff; }
.badge.mfa.on { background: var(--green-soft); color: var(--green); }
.badge.mfa.off { background: #fee4e2; color: #912018; }
.status-pill { display: inline-block; padding: 3px 7px; border-radius: 999px; font-size: 9.5px; font-weight: 700; }
.status-pill.open { background: #fef3f2; color: #b42318; }
.status-pill.ongoing { background: #fffaeb; color: #b54708; }
.status-pill.done { background: #ecfdf3; color: var(--green); }
.status-pill.risk { background: #f2f4f7; color: #475467; }
.risk-pill { font-size: 9.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; }
.risk-pill.critical { color: #7f1d1d; }
.risk-pill.high { color: var(--red); }
.risk-pill.medium { color: var(--amber); }
.risk-pill.low { color: var(--green); }

/* Activity */
.activity-panel { min-width: 0; }
.timeline { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0; }
.timeline li { display: grid; grid-template-columns: 12px 1fr; gap: 10px; position: relative; padding-bottom: 15px; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before { content: ""; position: absolute; left: 5px; top: 13px; bottom: -3px; width: 1px; background: var(--line); }
.timeline li:last-child::before { display: none; }
.timeline-dot { width: 11px; height: 11px; border-radius: 50%; border: 2px solid #fff; background: #98a2b3; box-shadow: 0 0 0 1px var(--line); margin-top: 2px; z-index: 1; }
.timeline-dot.success { background: var(--green); box-shadow: 0 0 0 1px #a6f4c5; }
.timeline-dot.critical { background: var(--red); box-shadow: 0 0 0 1px #fda29b; }
.timeline strong { display: block; font-size: 11px; font-weight: 650; }
.timeline p { color: var(--muted); font-size: 10px; margin-top: 2px; }
.timeline time { color: var(--muted-2); font-size: 9.5px; display: block; margin-top: 2px; }

/* Filter bar */
.filter-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 14px; }
.chips { display: flex; gap: 5px; flex-wrap: wrap; }
.chip { border: 1px solid var(--line); background: #fff; color: var(--muted); border-radius: 999px; padding: 5px 10px; font-size: 10.5px; font-weight: 600; }
.chip span { margin-left: 4px; color: var(--muted-2); }
.chip.active { background: var(--navy); border-color: var(--navy); color: #fff; }
.chip.active span { color: #cbd5e1; }

/* Mission */
.mission-banner { background: linear-gradient(130deg, #101828, #1b2740); color: #fff; border-radius: var(--radius); padding: 22px 24px; display: flex; justify-content: space-between; gap: 20px; margin-bottom: 14px; overflow: hidden; position: relative; }
.mission-banner::after { content: ""; position: absolute; right: -50px; top: -90px; width: 300px; height: 300px; background: radial-gradient(circle, rgba(229,72,63,.22), transparent 65%); }
.mission-banner-main { position: relative; z-index: 1; min-width: 0; }
.mission-flags { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.mission-flags .mono { color: #94a3b8; }
.mission-banner h1 { font-size: 26px; letter-spacing: -.035em; }
.mission-sub { color: #cbd5e1; font-size: 11.5px; margin-top: 5px; }
.scope-chips { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 12px; }
.scope-chips span { background: rgba(255,255,255,.07); border: 1px solid #334155; color: #e2e8f0; border-radius: 4px; padding: 3px 7px; font-family: "SFMono-Regular", Consolas, monospace; font-size: 9.5px; }
.scope-chips span.excluded { border-color: #7f1d1d; color: #fda29b; background: rgba(180,35,24,.12); }
.mission-banner-actions { display: flex; align-items: flex-start; gap: 8px; position: relative; z-index: 1; }
.mission-banner .btn-ghost { border-color: #334155; background: transparent; color: #fff; }
.mission-banner .btn-ghost:hover { background: #1e293b; }
.summary-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 14px; }
.summary-card { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 13px 15px; display: flex; align-items: center; gap: 12px; box-shadow: var(--shadow); }
.summary-card .label { display: block; color: var(--muted); font-size: 9.5px; text-transform: uppercase; letter-spacing: .05em; font-weight: 700; }
.summary-card strong { display: block; font-size: 17px; letter-spacing: -.02em; margin-top: 2px; }
.summary-card small { display: block; color: var(--muted); font-size: 9.5px; margin-top: 2px; }
.summary-icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 8px; background: var(--soft); color: var(--muted); flex: 0 0 auto; }
.summary-icon.critical { background: var(--red-soft); color: var(--red); }
.summary-icon .icon { width: 17px; height: 17px; }
.risk-dial { width: 54px; height: 54px; border-radius: 50%; background: conic-gradient(var(--red) calc(var(--score) * 1%), #e5e7eb 0); display: grid; place-items: center; position: relative; flex: 0 0 auto; }
.risk-dial::before { content: ""; position: absolute; inset: 5px; background: #fff; border-radius: 50%; }
.risk-dial span { position: relative; z-index: 1; font-size: 12px; font-weight: 800; }
.mission-grid { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 14px; align-items: start; }
.mission-panel { padding: 0; overflow: hidden; }
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); padding: 0 16px; overflow-x: auto; }
.tabs button { border: 0; background: none; padding: 13px 10px; color: var(--muted); font-size: 11.5px; font-weight: 600; border-bottom: 2px solid transparent; white-space: nowrap; }
.tabs button em { font-style: normal; font-size: 9px; background: var(--soft); color: var(--muted); padding: 1px 5px; border-radius: 999px; margin-left: 4px; }
.tabs button.active { color: var(--ink); border-bottom-color: var(--red); }
.tab-pane { display: none; padding: 16px 18px; }
.tab-pane.active { display: block; }
.tab-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.mission-aside { display: flex; flex-direction: column; gap: 12px; }
.mission-aside h3 { font-size: 11.5px; margin-bottom: 10px; }
.meta-list { display: grid; grid-template-columns: 80px 1fr; gap: 7px 10px; margin: 0; font-size: 10.5px; }
.meta-list dt { color: var(--muted); }
.meta-list dd { margin: 0; overflow-wrap: anywhere; }
.progress-block + .progress-block { margin-top: 12px; }
.progress-label { display: flex; justify-content: space-between; color: var(--muted); font-size: 10px; margin-top: 5px; }
.progress-label strong { color: var(--ink); }
.team-row { display: flex; align-items: center; gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--line-2); }
.team-row:last-child { border-bottom: 0; padding-bottom: 0; }
.team-row strong { display: block; font-size: 10.5px; }
.team-row small { display: block; color: var(--muted); font-size: 9.5px; }
.synthese-copy h3 { font-size: 12px; margin: 14px 0 5px; }
.synthese-copy h3:first-child { margin-top: 0; }
.synthese-copy p { color: var(--muted); font-size: 11.5px; }
.callout { display: flex; align-items: flex-start; gap: 9px; background: #f0fdf4; border: 1px solid #bbf7d0; border-radius: 6px; padding: 10px 12px; margin-top: 14px; color: #166534; }
.callout .icon { width: 16px; height: 16px; margin-top: 1px; }
.callout strong { display: block; font-size: 10.5px; }
.callout span { display: block; font-size: 10px; color: #15803d; margin-top: 2px; }
.report-list { display: flex; flex-direction: column; gap: 8px; }
.report-row { display: flex; align-items: center; gap: 10px; border: 1px solid var(--line); border-radius: 7px; padding: 10px 12px; }
.report-row > div { flex: 1; }
.report-row strong { display: block; font-size: 11px; }
.report-row span { display: block; color: var(--muted); font-size: 9.5px; }
.report-row .hash { flex: 0 0 auto; font-family: "SFMono-Regular", Consolas, monospace; font-size: 9px; color: var(--muted-2); }
.file-icon { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 6px; background: #eef2f6; color: #344054; font-size: 8px; font-weight: 800; letter-spacing: .02em; flex: 0 0 auto; }
.file-icon.pdf { background: #fee4e2; color: #b42318; }
.evidence-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.evidence-card { display: flex; flex-direction: column; gap: 4px; border: 1px solid var(--line); border-radius: 7px; padding: 10px; }
.evidence-card strong { font-size: 10.5px; }
.evidence-card small { color: var(--muted); font-size: 9px; }
.mission-timeline { padding-top: 2px; }

/* Findings layout */
.findings-layout { display: grid; grid-template-columns: minmax(0, 1.4fr) 320px; gap: 14px; align-items: start; }
.matrix-panel { position: sticky; top: 80px; }
.matrix { position: relative; display: grid; grid-template-columns: 18px 1fr; grid-template-rows: 1fr 18px; gap: 5px; margin-top: 10px; }
.matrix-y { writing-mode: vertical-rl; transform: rotate(180deg); font-size: 8px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); text-align: center; }
.matrix-x { grid-column: 2; text-align: center; font-size: 8px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.matrix-grid { position: relative; display: grid; grid-template-columns: repeat(5, 1fr); grid-template-rows: repeat(5, 1fr); gap: 3px; aspect-ratio: 1; }
.matrix-grid .m { border-radius: 2px; background: #ecfdf3; }
.matrix-grid .m.low { background: #ecfdf3; }
.matrix-grid .m.medium { background: #fffaeb; }
.matrix-grid .m.high { background: #fef3f2; }
.matrix-grid .m.critical { background: #fee4e2; }
.pin { position: absolute; display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: var(--navy); color: #fff; font-size: 8px; font-style: normal; font-weight: 800; border: 2px solid #fff; box-shadow: 0 1px 4px rgba(0,0,0,.2); transform: translate(-50%, -50%); }
.p1 { left: 18%; top: 18%; background: #7f1d1d; }
.p2 { left: 42%; top: 36%; background: #b42318; }
.p3 { left: 63%; top: 52%; background: #b54708; }
.p4 { left: 78%; top: 72%; background: #026aa2; }
.p5 { left: 88%; top: 86%; background: #475467; }
.matrix-legend { display: flex; flex-wrap: wrap; gap: 6px 12px; margin-top: 12px; color: var(--muted); font-size: 9px; }
.matrix-legend span { display: inline-flex; align-items: center; gap: 5px; }

/* Reports */
.report-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.report-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); }
.report-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.report-card h3 { font-size: 14px; }
.report-card p { color: var(--muted); font-size: 10.5px; margin-top: 4px; min-height: 30px; }
.report-meta { display: flex; gap: 14px; color: var(--muted); font-size: 9.5px; margin-top: 12px; }
.report-hash { color: var(--muted-2); font-size: 9px; margin-top: 7px; }
.report-actions { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line-2); }

/* Clients / team */
.mini-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 14px; }
.mini-stats > div { background: #fff; border: 1px solid var(--line); border-radius: 9px; padding: 12px 14px; }
.mini-stats span { display: block; color: var(--muted); font-size: 9.5px; text-transform: uppercase; letter-spacing: .05em; font-weight: 700; }
.mini-stats strong { display: block; font-size: 21px; margin-top: 4px; letter-spacing: -.03em; }
.client-cell { display: flex; align-items: center; gap: 9px; }
.client-cell strong { font-size: 11.5px; }
.client-cell span { font-size: 9.5px; }
.audit-action { font-family: "SFMono-Regular", Consolas, monospace; font-size: 9.5px; background: var(--soft); border: 1px solid var(--line); padding: 2px 6px; border-radius: 4px; color: #344054; }

/* Drawer */
.scrim { position: fixed; inset: 0; background: rgba(16,24,40,.42); opacity: 0; pointer-events: none; transition: opacity .18s ease; z-index: 80; }
.scrim.open { opacity: 1; pointer-events: auto; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: 470px; max-width: 92vw; background: #fff; z-index: 90; transform: translateX(102%); transition: transform .22s ease; padding: 22px 24px; overflow-y: auto; box-shadow: -20px 0 60px rgba(16,24,40,.16); }
.drawer.open { transform: none; }
.drawer-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.drawer-ref { display: flex; align-items: center; gap: 8px; }
.drawer-ref .mono { color: var(--muted); font-size: 11px; }
.drawer h2 { font-size: 20px; letter-spacing: -.03em; }
.drawer-sub { color: var(--muted); font-size: 11px; margin-top: 4px; }
.drawer-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 8px; overflow: hidden; margin: 16px 0; }
.drawer-meta > div { background: #fff; padding: 10px 12px; }
.drawer-meta span { display: block; color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: .06em; font-weight: 700; }
.drawer-meta strong { display: block; font-size: 12px; margin-top: 3px; }
.drawer-section { border-top: 1px solid var(--line-2); padding-top: 14px; margin-top: 14px; }
.drawer-section h3 { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-bottom: 7px; }
.drawer-section p { color: #344054; font-size: 11.5px; }
.drawer-section pre { background: var(--navy); color: #e2e8f0; border-radius: 7px; padding: 12px; font-size: 10px; line-height: 1.55; white-space: pre-wrap; overflow-wrap: anywhere; }
.drawer-section code { background: var(--soft); border: 1px solid var(--line); padding: 1px 4px; border-radius: 3px; font-size: 10px; }
.drawer-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line); }

/* Modal */
.modal { position: fixed; inset: 0; z-index: 100; display: none; place-items: center; background: rgba(16,24,40,.45); padding: 20px; }
.modal.open { display: grid; }
.modal-card { width: 100%; max-width: 560px; background: #fff; border-radius: 12px; padding: 22px 24px; box-shadow: 0 24px 80px rgba(16,24,40,.25); }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.modal-head h2 { font-size: 19px; letter-spacing: -.03em; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field { display: flex; flex-direction: column; gap: 5px; font-size: 10.5px; font-weight: 650; color: var(--muted); }
.field.span-2 { grid-column: span 2; }
.field input, .field select, .field textarea { border: 1px solid var(--line); border-radius: 6px; padding: 8px 9px; font-size: 11.5px; color: var(--ink); background: #fff; outline: none; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--red-2); box-shadow: 0 0 0 3px rgba(229,72,63,.12); }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; padding-top: 15px; border-top: 1px solid var(--line); }

/* Toast */
.toast { position: fixed; left: 50%; bottom: 22px; transform: translate(-50%, 20px); background: var(--navy); color: #fff; padding: 9px 14px; border-radius: 7px; font-size: 11.5px; opacity: 0; pointer-events: none; transition: all .2s ease; z-index: 130; box-shadow: 0 10px 30px rgba(0,0,0,.2); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 1180px) {
  .kpis { grid-template-columns: 1fr 1fr; }
  .grid-2, .dashboard-bottom, .findings-layout { grid-template-columns: 1fr; }
  .matrix-panel { position: static; }
  .mission-grid { grid-template-columns: 1fr; }
  .mission-aside { display: grid; grid-template-columns: 1fr 1fr; }
}
@media (max-width: 900px) {
  .app { grid-template-columns: 1fr; }
  .sidebar { position: fixed; left: -280px; width: 256px; transition: left .2s ease; }
  .sidebar.open { left: 0; }
  .topbar { padding: 0 16px; }
  .search { display: none; }
  .content { padding: 18px 16px 34px; }
  .summary-grid { grid-template-columns: 1fr 1fr; }
  .report-cards { grid-template-columns: 1fr; }
  .mission-banner { flex-direction: column; }
  .mission-banner-actions { align-self: flex-start; }
  .mini-stats { grid-template-columns: 1fr 1fr; }
  .risk-row { grid-template-columns: 1fr; gap: 5px; }
  .risk-score { text-align: left; }
}
@media (max-width: 600px) {
  .kpis, .summary-grid, .mission-aside, .mini-stats { grid-template-columns: 1fr; }
  .page-head { flex-direction: column; }
  .filter-bar { flex-direction: column; align-items: stretch; }
  .top-actions .btn-primary { width: 34px; padding: 0; overflow: hidden; font-size: 0; }
  .top-actions .btn-primary .icon { width: 17px; height: 17px; }
  .tabs { padding: 0 8px; }
  .mission-banner h1 { font-size: 21px; }
  .report-row { flex-wrap: wrap; }
}

.mobile-menu { display: none; }
@media (max-width: 900px) {
  .mobile-menu { display: inline-grid; }
}

@media (max-width: 600px) {
  html, body { overflow-x: hidden; }
  .topbar { gap: 8px; padding: 0 12px; }
  .crumbs { min-width: 0; overflow: hidden; white-space: nowrap; }
  .crumbs strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .top-actions { gap: 6px; }
  .top-actions .bell, .top-actions .btn-primary { display: none; }
  .content { padding: 16px 12px 30px; }
  .kpi, .panel, .summary-card, .report-card { min-width: 0; }
  .page-head h1 { font-size: 24px; }
  .page-head p { max-width: 100%; }
}
.login-body {
  background: #fff;
  min-height: 100vh;
}
.login-shell { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(500px, .92fr); min-height: 100vh; }

/* Visual side */
.login-visual {
  background: #0b1220; color: #fff; position: relative; overflow: hidden;
  padding: 34px 44px 26px; display: flex; flex-direction: column; justify-content: space-between;
}
.visual-grid {
  position: absolute; inset: 0;
  background-image: linear-gradient(rgba(148,163,184,.08) 1px, transparent 1px), linear-gradient(90deg, rgba(148,163,184,.08) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(150deg, #000 0%, transparent 75%);
}
.visual-glow {
  position: absolute; width: 580px; height: 580px; right: -180px; top: -160px;
  background: radial-gradient(circle, rgba(180,35,24,.38), transparent 62%);
  filter: blur(4px);
}
.visual-top, .visual-copy, .visual-foot { position: relative; z-index: 1; }
.visual-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.visual-brand { display: flex; align-items: center; gap: 10px; color: #fff; font-weight: 800; letter-spacing: .08em; }
.visual-brand small { display: block; font-size: 8.5px; letter-spacing: .2em; color: #94a3b8; margin-top: 2px; }
.visual-badge {
  display: inline-flex; align-items: center; gap: 7px; border: 1px solid #334155;
  color: #cbd5e1; border-radius: 999px; padding: 5px 10px; font-size: 10px; letter-spacing: .04em;
}
.visual-badge .dot { background: var(--red-2); }
.visual-copy { max-width: 540px; margin: 40px 0; }
.eyebrow.light { color: #fda29b; }
.visual-copy h1 { font-size: clamp(36px, 4.2vw, 56px); line-height: 1.03; letter-spacing: -.045em; margin: 12px 0 20px; }
.visual-copy h1 span { color: var(--red-2); }
.visual-copy > p { color: #cbd5e1; font-size: 14px; line-height: 1.65; max-width: 470px; }
.visual-list { list-style: none; padding: 0; margin: 28px 0 0; display: flex; flex-direction: column; gap: 11px; color: #cbd5e1; font-size: 12px; }
.visual-list li { display: flex; align-items: center; gap: 9px; }
.visual-check { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: rgba(6,118,71,.22); color: #6ce9a6; font-size: 10px; font-weight: 800; border: 1px solid rgba(108,233,166,.35); }
.visual-foot { display: flex; justify-content: space-between; gap: 16px; color: #64748b; font-size: 9.5px; border-top: 1px solid #1e293b; padding-top: 14px; }

/* Panel side */
.login-panel {
  display: flex; flex-direction: column; justify-content: center; align-items: center;
  padding: 42px 44px; background: #fff; position: relative;
}
.login-card { width: 100%; max-width: 390px; }
.login-head { margin-bottom: 24px; }
.login-head h2 { font-size: 26px; letter-spacing: -.035em; margin: 6px 0 7px; }
.login-head p { color: var(--muted); font-size: 12px; line-height: 1.6; }
.login-card .field { margin-bottom: 13px; }
.login-card .field span { font-size: 10.5px; }
.login-card .field input { padding: 10px 11px; font-size: 12.5px; }
.login-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 8px 0 18px; font-size: 10px; }
.remember { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }
.remember input { accent-color: var(--red); }
.login-row a { color: var(--red); font-weight: 600; }
.login-submit { width: 100%; padding: 11px; font-size: 13px; }
.login-divider { display: flex; align-items: center; gap: 10px; color: var(--muted-2); font-size: 9px; text-transform: uppercase; letter-spacing: .1em; margin: 18px 0; }
.login-divider::before, .login-divider::after { content: ""; height: 1px; background: var(--line); flex: 1; }
.sso { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; border: 1px solid var(--line); border-radius: 7px; padding: 10px; font-size: 12px; font-weight: 600; color: var(--ink); }
.sso:hover { background: var(--soft); }
.sso-mark { display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 4px; background: var(--navy); color: #fff; font-size: 10px; font-weight: 800; }
.login-help { color: var(--muted); font-size: 10.5px; text-align: center; margin-top: 20px; }
.login-help a { color: var(--red); font-weight: 600; }
.login-foot { position: absolute; left: 44px; right: 44px; bottom: 20px; display: flex; justify-content: space-between; color: var(--muted-2); font-size: 9px; border-top: 1px solid var(--line-2); padding-top: 12px; }
.lock { color: var(--green); }

@media (max-width: 980px) {
  .login-shell { grid-template-columns: 1fr; }
  .login-visual { min-height: 380px; padding: 28px 24px 22px; }
  .visual-copy { margin: 24px 0 10px; }
  .visual-copy h1 { font-size: 36px; }
  .visual-list { display: none; }
  .visual-foot { margin-top: 18px; }
  .login-panel { padding: 36px 22px 60px; }
  .login-foot { left: 22px; right: 22px; }
}
@media (max-width: 560px) {
  .login-visual { min-height: 300px; }
  .visual-copy h1 { font-size: 30px; }
  .visual-copy > p { font-size: 12px; }
  .visual-badge { display: none; }
  .login-panel { justify-content: flex-start; }
}

/* Portal-specific components */
a { color: inherit; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.inline { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.top-gap { margin-top: 14px; }
.muted { color: var(--muted); }
.small { font-size: 10.5px; }
.strong { font-weight: 700; }
.sub { color: var(--muted); font-size: 9.5px; margin-top: 2px; }
.pre-line { white-space: pre-line; }
.empty { color: var(--muted); font-size: 12px; padding: 14px 0; }
.flash {
  border: 1px solid var(--line); background: #fff; border-radius: 8px;
  padding: 10px 14px; margin-bottom: 16px; font-size: 12px;
}
.flash-success { background: #ecfdf3; border-color: #a6f4c5; color: #067647; }
.flash-error { background: #fef3f2; border-color: #fecdca; color: #b42318; }
.flash-info { background: #eff8ff; border-color: #b2ddff; color: #175cd3; }
.footer {
  display: flex; justify-content: space-between; gap: 14px; color: var(--muted-2);
  font-size: 9.5px; border-top: 1px solid var(--line); margin-top: 30px; padding-top: 14px;
}
.nav-item em { margin-left: auto; font-style: normal; font-size: 10px; background: #1e293b; color: #cbd5e1; border-radius: 999px; padding: 1px 7px; }
.nav-item em.danger { background: #3b1d1d; color: #fda29b; }
.brand-text { font-weight: 800; letter-spacing: .08em; font-size: 15px; line-height: 1.1; }
.brand-text small { display: block; font-size: 8.5px; letter-spacing: .2em; color: #94a3b8; margin-top: 2px; }
.sidebar-user form { margin-left: auto; }
.sidebar-user .btn { border-color: #334155; background: transparent; color: #cbd5e1; padding: 4px 7px; font-size: 9px; }
.sidebar-user .btn:hover { background: #1e293b; }
.page-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.kpi-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 14px; }
.kpi-card .kpi-value { display: flex; align-items: baseline; gap: 5px; }
.kpi-card .kpi-value small { font-size: 11px; color: var(--muted); font-weight: 500; }
.kpi-card .kpi-note { color: var(--muted); font-size: 10px; margin-top: 4px; }
.kpi-card .kpi-note a { color: var(--red); font-weight: 650; }
.risk-bar-svg { width: 100%; height: 8px; display: block; border-radius: 999px; overflow: hidden; background: var(--line-2); }
.risk-row { display: grid; grid-template-columns: 1.30fr 1.35fr 64px; gap: 14px; align-items: center; }
.risk-row .risk-label strong { display: block; font-size: 12px; }
.risk-row .risk-label span { display: block; color: var(--muted); font-size: 10px; margin-top: 2px; }
.risk-rating { font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; text-align: right; }
.risk-rating.critical { color: #7f1d1d; }
.risk-rating.high { color: var(--red); }
.risk-rating.medium { color: var(--amber); }
.risk-rating.low { color: var(--green); }
.risk-rating.none { color: var(--muted); }
.donut-svg { width: 150px; height: 150px; flex: 0 0 auto; }
.donut-svg .track { fill: none; stroke: var(--line-2); stroke-width: 13; }
.donut-svg .seg { fill: none; stroke-width: 13; stroke-linecap: butt; transform: rotate(-90deg); transform-origin: 60px 60px; }
.donut-svg .seg.critical { stroke: #7f1d1d; }
.donut-svg .seg.high { stroke: #b42318; }
.donut-svg .seg.medium { stroke: #b54708; }
.donut-svg .seg.low { stroke: #026aa2; }
.donut-svg .seg.info { stroke: #98a2b3; }
.donut-center-text { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; }
.donut-center-text strong { display: block; font-size: 27px; line-height: 1; letter-spacing: -.04em; }
.donut-center-text span { color: var(--muted); font-size: 9px; }
.donut-wrap { position: relative; display: flex; align-items: center; gap: 24px; }
.risk-dial-svg { width: 54px; height: 54px; }
.risk-dial-svg .track { fill: none; stroke: #e5e7eb; stroke-width: 7; }
.risk-dial-svg .value { fill: none; stroke: var(--red); stroke-width: 7; stroke-linecap: round; transform: rotate(-90deg); transform-origin: 30px 30px; }
.risk-dial-label { position: relative; display: grid; place-items: center; width: 54px; height: 54px; }
.risk-dial-label span { position: absolute; font-size: 11px; font-weight: 800; }
.engagement-banner { background: linear-gradient(130deg, #101828, #1b2740); color: #fff; border-radius: var(--radius); padding: 22px 24px; display: flex; justify-content: space-between; gap: 20px; margin-bottom: 14px; position: relative; overflow: hidden; }
.engagement-banner::after { content: ""; position: absolute; right: -50px; top: -90px; width: 300px; height: 300px; background: radial-gradient(circle, rgba(229,72,63,.22), transparent 65%); }
.engagement-banner h1 { font-size: 25px; letter-spacing: -.035em; }
.engagement-banner .scope-chips span { background: rgba(255,255,255,.07); border-color: #334155; color: #e2e8f0; }
.engagement-banner .scope-chips span.excluded { border-color: #7f1d1d; color: #fda29b; background: rgba(180,35,24,.12); }
.engagement-banner .btn-ghost { border-color: #334155; background: transparent; color: #fff; }
.summary-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 14px; }
.summary-card { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 13px 15px; display: flex; align-items: center; gap: 12px; box-shadow: var(--shadow); min-width: 0; }
.summary-card .label { display: block; color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: .05em; font-weight: 700; }
.summary-card strong { display: block; font-size: 16px; letter-spacing: -.02em; margin-top: 2px; }
.summary-card small { display: block; color: var(--muted); font-size: 9.5px; margin-top: 2px; }
.summary-icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 8px; background: var(--soft); color: var(--muted); flex: 0 0 auto; }
.summary-icon.critical { background: var(--red-soft); color: var(--red); }
.summary-icon .icon { width: 17px; height: 17px; }
.mission-tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); padding: 0 16px; overflow-x: auto; background: #fff; border-radius: 12px 12px 0 0; }
.mission-tabs a { padding: 13px 10px; color: var(--muted); font-size: 11.5px; font-weight: 600; border-bottom: 2px solid transparent; white-space: nowrap; }
.mission-tabs a.active { color: var(--ink); border-bottom-color: var(--red); }
.mission-tabs a em { font-style: normal; font-size: 9px; background: var(--soft); color: var(--muted); padding: 1px 5px; border-radius: 999px; margin-left: 4px; }
.mission-panel { background: #fff; border: 1px solid var(--line); border-radius: 0 0 12px 12px; border-top: 0; box-shadow: var(--shadow); padding: 16px 18px; }
.mission-grid { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 14px; align-items: start; }
.mission-aside { display: flex; flex-direction: column; gap: 12px; }
.mission-aside h3 { font-size: 11.5px; margin-bottom: 10px; }
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.detail-block h4 { font-size: 10px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 14px 0 5px; }
.detail-block h4:first-child { margin-top: 0; }
.detail-block pre { background: var(--navy); color: #e2e8f0; border-radius: 7px; padding: 11px; font-size: 10px; line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere; }
.detail-block p { color: #344054; font-size: 11.5px; }
.finding-title { font-weight: 650; font-size: 11.5px; }
.finding-meta { color: var(--muted); font-size: 9.5px; margin-top: 2px; }
.table-actions { display: flex; align-items: center; gap: 6px; justify-content: flex-end; }
.file-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0; }
.file-list li { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--line-2); font-size: 11px; }
.file-list li:last-child { border-bottom: 0; }
.file-list a { color: var(--ink); font-weight: 600; }
.file-list .file-meta { color: var(--muted); font-size: 9.5px; margin-top: 2px; }
.file-list .file-kind { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 6px; background: var(--soft); color: #344054; font-size: 8px; font-weight: 800; flex: 0 0 auto; }
.file-icon { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 6px; background: #eef2f6; color: #344054; font-size: 8px; font-weight: 800; letter-spacing: .02em; flex: 0 0 auto; }
.file-icon.pdf { background: #fee4e2; color: #b42318; }
.report-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.report-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); }
.report-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.report-card h3 { font-size: 14px; }
.report-card p { color: var(--muted); font-size: 10.5px; margin-top: 4px; }
.report-meta { display: flex; gap: 14px; color: var(--muted); font-size: 9.5px; margin-top: 12px; }
.report-hash { color: var(--muted-2); font-size: 9px; margin-top: 7px; font-family: "SFMono-Regular", Consolas, monospace; }
.report-actions { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line-2); }
.filter-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 14px; flex-wrap: wrap; }
.chips { display: flex; gap: 5px; flex-wrap: wrap; }
.chip { border: 1px solid var(--line); background: #fff; color: var(--muted); border-radius: 999px; padding: 5px 10px; font-size: 10.5px; font-weight: 600; }
.chip span { margin-left: 4px; color: var(--muted-2); }
.chip.active { background: var(--navy); border-color: var(--navy); color: #fff; }
.chip.active span { color: #cbd5e1; }
.topbar-search { display: flex; align-items: center; gap: 7px; background: var(--soft); border: 1px solid var(--line); border-radius: 7px; padding: 7px 10px; color: var(--muted-2); min-width: 240px; }
.topbar-search input { border: 0; outline: 0; background: transparent; width: 100%; font-size: 12px; color: var(--ink); }
.topbar-search .icon { width: 15px; height: 15px; }
.page-title { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.page-title h1 { font-size: 28px; line-height: 1.1; letter-spacing: -.035em; }
.page-title p { color: var(--muted); font-size: 12.5px; margin-top: 6px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field { display: flex; flex-direction: column; gap: 5px; font-size: 10.5px; font-weight: 650; color: var(--muted); }
.field.span-2 { grid-column: span 2; }
.field input, .field select, .field textarea { border: 1px solid var(--line); border-radius: 6px; padding: 8px 9px; font-size: 11.5px; color: var(--ink); background: #fff; outline: none; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--red-2); box-shadow: 0 0 0 3px rgba(229,72,63,.12); }
.form-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 4px; }
details > summary { cursor: pointer; list-style: none; }
details > summary::-webkit-details-marker { display: none; }
details > summary::before { content: "+"; display: inline-block; width: 12px; color: var(--red); font-weight: 800; }
details[open] > summary::before { content: "−"; }
.detail { padding: 8px 0 2px 14px; }
.secret-box { display: flex; align-items: center; gap: 10px; background: var(--soft); border: 1px dashed var(--line); border-radius: 7px; padding: 10px 12px; margin: 10px 0; }
.secret-box code { font-size: 11px; letter-spacing: .05em; overflow-wrap: anywhere; }
.totp-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-items: start; }
.qr { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 6px; width: 190px; height: 190px; }
.qr svg { width: 100%; height: 100%; }
.note { background: #fffaeb; border: 1px solid #fedf89; color: #93370d; border-radius: 7px; padding: 10px 12px; font-size: 10.5px; }
.danger-zone { border-color: #fecdca; }
.danger-zone h3 { color: #b42318; }
.progress-native { width: 100%; height: 7px; border: 0; border-radius: 999px; overflow: hidden; background: var(--line-2); appearance: none; }
.progress-native::-webkit-progress-bar { background: var(--line-2); border-radius: 999px; }
.progress-native::-webkit-progress-value { background: var(--red); border-radius: 999px; }
.progress-native::-moz-progress-bar { background: var(--red); border-radius: 999px; }
.progress-native.success::-webkit-progress-value { background: var(--green); }
.progress-native.success::-moz-progress-bar { background: var(--green); }

@media (max-width: 1180px) {
  .kpi-grid { grid-template-columns: 1fr 1fr; }
  .mission-grid { grid-template-columns: 1fr; }
  .mission-aside { display: grid; grid-template-columns: 1fr 1fr; }
  .report-grid { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .app { grid-template-columns: 1fr; }
  .sidebar { position: fixed; left: -280px; width: 256px; transition: left .2s ease; }
  .sidebar.open { left: 0; }
  .topbar { padding: 0 16px; }
  .topbar-search { display: none; }
  .content { padding: 18px 16px 34px; }
  .summary-grid { grid-template-columns: 1fr 1fr; }
  .detail-grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .kpi-grid, .summary-grid, .mission-aside, .totp-grid { grid-template-columns: 1fr; }
  .page-title { flex-direction: column; }
  .top-actions .btn-primary { display: none; }
  .content { padding: 16px 12px 30px; }
  .risk-row { grid-template-columns: 1fr; gap: 5px; }
  .risk-rating { text-align: left; }
  .mission-tabs { padding: 0 8px; }
  .report-grid { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .field.span-2 { grid-column: auto; }
}

/* Status and chart variants */
.badge.status-scoped { background: var(--blue-soft); color: #075985; }
.badge.status-in-progress { background: var(--amber-soft); color: #92400e; }
.badge.status-retest { background: #fef0c7; color: #93370d; }
.badge.status-on-hold { background: #f2f4f7; color: #475467; }
.badge.status-delivered,
.badge.status-closed { background: var(--green-soft); color: var(--green); }
.status-pill.status-open { background: #fef3f2; color: #b42318; }
.status-pill.status-in-progress { background: #fffaeb; color: #b54708; }
.status-pill.status-remediated { background: #ecfdf3; color: var(--green); }
.status-pill.status-accepted-risk { background: #f2f4f7; color: #475467; }
.status-pill.status-false-positive { background: #f2f4f7; color: #475467; }
.risk-bar-svg rect.critical { fill: #7f1d1d; }
.risk-bar-svg rect.high { fill: #b42318; }
.risk-bar-svg rect.medium { fill: #b54708; }
.risk-bar-svg rect.low { fill: #026aa2; }
.risk-bar-svg rect.info { fill: #98a2b3; }
.donut-figure { position: relative; width: 150px; height: 150px; flex: 0 0 auto; }
.error-page { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: var(--bg); }
.error-page .login-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); }
.sidebar:target { left: 0; }
.mobile-close { display: none; position: absolute; top: 14px; right: 14px; color: #cbd5e1; font-size: 22px; line-height: 1; }
.bar-fill { display: block; height: 100%; width: 62%; background: var(--red); border-radius: inherit; }
.data-table a.strong { color: var(--ink); }
.data-table td.mono { white-space: nowrap; }
.data-table select { font-size: 10px; padding: 4px 5px; border: 1px solid var(--line); border-radius: 5px; background: #fff; max-width: 118px; }
.data-table form.inline { gap: 4px; flex-wrap: nowrap; }
.data-table a.strong:hover { color: var(--red); }
@media (max-width: 900px) {
  .mobile-close { display: block; }
}

.recovery-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 12px 0; }
.recovery-code { display: block; background: var(--soft); border: 1px solid var(--line); border-radius: 6px; padding: 8px 10px; text-align: center; font-family: "SFMono-Regular", Consolas, monospace; font-size: 11px; letter-spacing: .08em; }
@media (max-width: 700px) { .recovery-grid { grid-template-columns: 1fr 1fr; } }
