:root {
  --app-bg: #070b17;
  --sidebar-bg: #080d1a;
  --surface-1: #101827;
  --surface-2: #152036;
  --surface-3: #1a263d;
  --border: #243147;
  --text: #f2f5fa;
  --muted: #9aa7bc;
  --muted-2: #748299;
  --accent: #06b6d4;
  --accent-action: #0e7490;
  --accent-light: #ecfeff;
  --accent-dark: #155e75;
  --success: #22c55e;
  --warning: #f59e0b;
  --critical: #f43f5e;
  --topbar-h: 72px;
  --sidebar-w: 248px;
  --sidebar-collapsed: 72px;
  --ai-w: 390px;
  --shadow: 0 20px 60px rgba(0, 0, 0, .26);
  --ease: 180ms ease;
}

html[data-theme="light"] {
  --app-bg: #f4f7fb;
  --surface-1: #ffffff;
  --surface-2: #f8fafc;
  --surface-3: #eef4f8;
  --border: #dce3ee;
  --text: #111827;
  --muted: #667085;
  --muted-2: #98a2b3;
  --shadow: 0 20px 60px rgba(27, 45, 77, .12);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { color-scheme: dark; }
html[data-theme="light"] { color-scheme: light; }
body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  overflow: hidden;
  background: var(--app-bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 1.55;
  text-rendering: optimizeLegibility;
}
button, input, select, textarea { font: inherit; }
button { color: inherit; }
button, a, input, select, textarea { outline: none; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  box-shadow: 0 0 0 3px rgba(6, 182, 212, .25);
}
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }
.svg-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; flex: 0 0 auto; }
.icon-button {
  width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid transparent; background: transparent; color: var(--muted); border-radius: 8px;
  transition: background var(--ease), color var(--ease), border-color var(--ease), transform var(--ease);
}
.icon-button:hover { color: var(--text); background: var(--surface-2); border-color: var(--border); }
.icon-button:active { transform: translateY(1px); }
.icon-button.small { width: 36px; height: 36px; }
.button {
  min-height: 40px; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 8px 14px; border-radius: 8px; border: 1px solid transparent; font-weight: 650;
  transition: background var(--ease), color var(--ease), border-color var(--ease), transform var(--ease), box-shadow var(--ease);
}
.button:hover { transform: translateY(-1px); }
.button:active { transform: translateY(0); }
.button.primary { background: var(--accent-action); color: #fff; box-shadow: 0 8px 24px rgba(14, 116, 144, .24); }
.button.primary:hover { background: #0891b2; }
.button.secondary { background: var(--surface-1); color: var(--text); border-color: var(--border); }
.button.secondary:hover { border-color: var(--accent); color: var(--accent); }
.button.small { min-height: 36px; padding: 6px 10px; font-size: 12px; }
.button.full { width: 100%; }
.text-button { border: 0; background: transparent; color: var(--accent); padding: 6px; font-weight: 650; }
.text-button:hover { color: #67e8f9; }

.app-shell {
  height: 100vh;
  display: grid;
  grid-template-columns: var(--sidebar-w) minmax(0, 1fr) var(--ai-w);
  grid-template-rows: var(--topbar-h) minmax(0, 1fr);
  grid-template-areas: "top top top" "side main ai";
  transition: grid-template-columns 240ms ease;
}
.app-shell.sidebar-collapsed { grid-template-columns: var(--sidebar-collapsed) minmax(0, 1fr) var(--ai-w); }
.app-shell.ai-collapsed { grid-template-columns: var(--sidebar-w) minmax(0, 1fr) 0; }
.app-shell.sidebar-collapsed.ai-collapsed { grid-template-columns: var(--sidebar-collapsed) minmax(0, 1fr) 0; }
.app-shell.portal-mode {
  grid-template-columns: minmax(0, 1fr) var(--ai-w);
  grid-template-areas: "top top" "main ai";
}
.portal-mode .sidebar { display: none; }
.portal-mode .notification-button, .portal-mode .user-wrap { display: none; }


.topbar {
  grid-area: top;
  height: var(--topbar-h);
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 0 16px;
  background: color-mix(in srgb, var(--surface-1) 90%, transparent);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(18px);
  z-index: 50;
}
.topbar-left, .topbar-actions { display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand-link {
  height: 58px; display: inline-flex; align-items: center; padding: 3px 8px;
  border-radius: 10px; transition: background var(--ease);
}
.brand-link:hover { background: var(--surface-2); }
.brand-logo {
  display: block; width: 154px; height: 53px; object-fit: contain; object-position: left center;
  border-radius: 8px;
}
.brand-mark {
  width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center;
  border-radius: 10px; background: linear-gradient(145deg, #8b5cf6, var(--accent)); color: #fff;
  font-weight: 850; font-size: 17px; box-shadow: 0 8px 26px rgba(109, 40, 217, .28);
}
.brand-word { font-size: 13px; font-weight: 800; letter-spacing: .09em; white-space: nowrap; }
.assistant-identity { display: flex; align-items: center; gap: 10px; margin-left: 6px; padding-left: 16px; border-left: 1px solid var(--border); min-width: 0; }
.identity-dot { width: 10px; height: 10px; border-radius: 999px; background: var(--accent); box-shadow: 0 0 0 6px rgba(6, 182, 212, .12), 0 0 22px rgba(6, 182, 212, .55); }
.assistant-identity div { display: grid; line-height: 1.25; min-width: 0; }
.assistant-identity strong { font-size: 14px; white-space: nowrap; }
.assistant-identity span { font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 260px; }
.language-switch { height: 36px; display: flex; align-items: center; gap: 4px; padding: 0 7px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface-2); }
.language-switch span { color: var(--border); }
.lang-btn { border: 0; background: transparent; color: var(--muted); padding: 4px; font-size: 12px; font-weight: 700; border-radius: 4px; }
.lang-btn.active { color: var(--accent); }
.theme-moon { display: none; }
html[data-theme="light"] .theme-sun { display: none; }
html[data-theme="light"] .theme-moon { display: block; }
.voice-control {
  height: 40px; display: flex; align-items: center; gap: 7px; border: 1px solid var(--border); background: var(--surface-2);
  border-radius: 8px; padding: 0 10px; color: var(--text);
}
.voice-control .icon { color: var(--accent); width: 17px; height: 17px; }
.voice-label { font-size: 12px; font-weight: 650; }
.voice-status { font-size: 10px; padding: 2px 6px; border-radius: 999px; font-weight: 750; }
.voice-status.off { color: var(--critical); background: rgba(244, 63, 94, .12); }
.voice-status.on { color: var(--success); background: rgba(34, 197, 94, .12); }
.notification-button { position: relative; }
.notification-badge { position: absolute; top: 4px; right: 4px; min-width: 16px; height: 16px; display: flex; align-items: center; justify-content: center; border-radius: 999px; background: var(--critical); color: #fff; font-size: 9px; font-weight: 800; border: 2px solid var(--surface-1); }
.user-button { height: 48px; display: flex; align-items: center; gap: 9px; border: 1px solid transparent; background: transparent; border-radius: 10px; padding: 4px 7px; min-width: 0; }
.user-button:hover { background: var(--surface-2); border-color: var(--border); }
.user-button img { width: 36px; height: 36px; object-fit: cover; object-position: 50% 28%; border-radius: 10px; border: 1px solid var(--border); }
.user-copy { display: grid; line-height: 1.25; text-align: left; }
.user-copy strong { font-size: 12px; white-space: nowrap; }
.user-copy small { color: var(--muted); font-size: 10px; white-space: nowrap; }
.user-button > .icon { width: 16px; height: 16px; color: var(--muted); }
.popover-wrap { position: relative; }
.popover {
  position: absolute; top: calc(100% + 10px); right: 0; min-width: 290px; background: var(--surface-1); border: 1px solid var(--border);
  border-radius: 12px; box-shadow: var(--shadow); z-index: 100; overflow: hidden;
}
.popover-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; border-bottom: 1px solid var(--border); }
.popover-head span { color: var(--accent); }
.notification-item { width: 100%; display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; border: 0; border-bottom: 1px solid var(--border); background: transparent; text-align: left; }
.notification-item:hover { background: var(--surface-2); }
.notification-item > span:last-child { display: grid; gap: 2px; }
.notification-item strong { font-size: 12px; }
.notification-item small { color: var(--muted); font-size: 11px; line-height: 1.4; }
.user-popover { min-width: 180px; padding: 6px; }
.user-popover button { width: 100%; border: 0; background: transparent; text-align: left; padding: 10px; border-radius: 7px; color: var(--text); }
.user-popover button:hover { background: var(--surface-2); }
.mobile-menu { display: none; }

.sidebar {
  grid-area: side; min-width: 0; background: var(--sidebar-bg); border-right: 1px solid #1b2639;
  display: flex; flex-direction: column; overflow: hidden; z-index: 40;
}
.sidebar-scroll { flex: 1; overflow-y: auto; overflow-x: hidden; padding: 14px 10px 8px; scrollbar-width: thin; }
.nav-group { margin: 0 0 18px; }
.nav-group-title { padding: 0 10px 7px; color: #66758d; font-size: 10px; font-weight: 800; letter-spacing: .11em; white-space: nowrap; }
.nav-item {
  width: 100%; min-height: 42px; position: relative; display: flex; align-items: center; gap: 11px; padding: 8px 10px;
  border: 1px solid transparent; background: transparent; color: #9aa7bc; border-radius: 8px; text-align: left;
  transition: background var(--ease), color var(--ease), border-color var(--ease);
}
.nav-item::before { content: ""; position: absolute; left: -10px; top: 8px; bottom: 8px; width: 3px; border-radius: 0 3px 3px 0; background: transparent; }
.nav-item:hover { color: #e8eef8; background: rgba(6, 182, 212, .08); }
.nav-item:hover .icon { color: var(--accent); }
.nav-item.active { color: #fff; background: rgba(6, 182, 212, .13); border-color: rgba(6, 182, 212, .18); }
.nav-item.active::before { background: var(--accent); }
.nav-item.active .icon { color: var(--accent); }
.nav-item span:not(.nav-badge) { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nav-badge { margin-left: auto; min-width: 21px; height: 19px; display: inline-flex; align-items: center; justify-content: center; border-radius: 999px; padding: 0 6px; background: rgba(6, 182, 212, .14); color: #67e8f9; font-size: 10px; font-weight: 800; }
.nav-badge.warning { background: rgba(245, 158, 11, .14); color: #fbbf24; }
.nav-badge.critical { background: rgba(244, 63, 94, .14); color: #fb7185; }
.collapse-button { min-height: 48px; display: flex; align-items: center; gap: 10px; padding: 0 18px; border: 0; border-top: 1px solid #1b2639; background: #0b1220; color: #7f8da3; text-align: left; }
.collapse-button:hover { color: #fff; background: #101827; }
.collapse-right { display: none; }
.sidebar-collapsed .nav-group-title, .sidebar-collapsed .nav-item span, .sidebar-collapsed .collapse-button span, .sidebar-collapsed .collapse-left { display: none; }
.sidebar-collapsed .collapse-right { display: block; }
.sidebar-collapsed .sidebar-scroll { padding-left: 9px; padding-right: 9px; }
.sidebar-collapsed .nav-item { justify-content: center; padding: 8px; }
.sidebar-collapsed .nav-item::before { left: -9px; }
.sidebar-collapsed .collapse-button { justify-content: center; padding: 0; }

.main-canvas { grid-area: main; min-width: 0; overflow: auto; background: var(--app-bg); }
.page-content { max-width: 1540px; min-height: 100%; padding: 20px 24px 44px; margin: 0 auto; }
.demo-banner { min-height: 34px; display: flex; align-items: center; gap: 9px; padding: 7px 12px; margin-bottom: 18px; border: 1px solid rgba(6, 182, 212, .24); border-radius: 8px; background: rgba(6, 182, 212, .07); color: var(--muted); font-size: 11px; }
.demo-banner .icon { width: 16px; height: 16px; color: var(--accent); }
.page-header { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.eyebrow, .panel-kicker { color: var(--accent); font-size: 10px; font-weight: 850; letter-spacing: .12em; }
.page-header h1 { margin: 5px 0 4px; font-size: 28px; line-height: 34px; letter-spacing: -.02em; }
.page-header p { margin: 0; color: var(--muted); max-width: 720px; }
.page-actions { display: flex; align-items: center; gap: 10px; }
.mode-switch { height: 40px; display: flex; align-items: center; padding: 3px; border: 1px solid var(--border); background: var(--surface-2); border-radius: 9px; }
.mode-btn { min-width: 58px; height: 32px; border: 0; border-radius: 6px; background: transparent; color: var(--muted); font-weight: 750; }
.mode-btn.active { background: var(--accent-action); color: #fff; box-shadow: 0 5px 16px rgba(14, 116, 144, .22); }
.screen { display: none; animation: screenIn 220ms ease; }
.screen.active { display: block; }
@keyframes screenIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

.kpi-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 12px; }
.kpi-card { min-height: 146px; padding: 16px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-1); box-shadow: 0 8px 24px rgba(0,0,0,.04); }
.kpi-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; color: var(--muted); font-size: 12px; font-weight: 650; }
.kpi-head .icon { color: var(--accent); width: 18px; height: 18px; }
.kpi-value { margin: 12px 0 2px; font-size: 31px; line-height: 1; font-weight: 800; letter-spacing: -.03em; }
.kpi-value span { margin-left: 2px; color: var(--muted); font-size: 13px; font-weight: 650; }
.kpi-foot { font-size: 11px; font-weight: 700; }
.kpi-foot span { color: var(--muted); font-weight: 500; }
.positive, .positive-text { color: var(--success); }
.negative, .critical-text { color: var(--critical); }
.warning { color: var(--warning); }
.neutral { color: var(--muted); }
.source-line { margin-top: 13px; padding-top: 10px; border-top: 1px solid var(--border); color: var(--muted-2); font-size: 9px; text-transform: uppercase; letter-spacing: .05em; }
.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(300px, .65fr); gap: 12px; }
.panel { min-width: 0; padding: 17px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-1); box-shadow: 0 8px 24px rgba(0,0,0,.035); }
.panel.wide { grid-column: 1 / -1; }
.panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 15px; }
.panel-head h2 { margin: 3px 0 0; font-size: 16px; line-height: 24px; }
.data-badge { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 10px; }
.status-dot { width: 8px; height: 8px; border-radius: 999px; display: inline-block; flex: 0 0 auto; }
.status-dot.success { background: var(--success); box-shadow: 0 0 0 4px rgba(34, 197, 94, .1); }
.status-dot.warning { background: var(--warning); box-shadow: 0 0 0 4px rgba(245, 158, 11, .1); }
.status-dot.critical { background: var(--critical); box-shadow: 0 0 0 4px rgba(244, 63, 94, .1); }
.priority-list { display: grid; gap: 8px; }
.priority-item { width: 100%; display: grid; grid-template-columns: 42px minmax(0, 1fr) 48px; align-items: center; gap: 11px; padding: 10px; border: 1px solid var(--border); background: var(--surface-2); border-radius: 9px; text-align: left; transition: border-color var(--ease), transform var(--ease), background var(--ease); }
.priority-item:hover { border-color: var(--accent); transform: translateY(-1px); background: color-mix(in srgb, var(--surface-2) 92%, var(--accent)); }
.priority-icon { width: 38px; height: 38px; display: flex; align-items: center; justify-content: center; border-radius: 9px; }
.priority-icon .icon { width: 18px; height: 18px; }
.priority-icon.critical { color: var(--critical); background: rgba(244, 63, 94, .11); }
.priority-icon.warning { color: var(--warning); background: rgba(245, 158, 11, .11); }
.priority-icon.success { color: var(--success); background: rgba(34, 197, 94, .11); }
.priority-copy { display: grid; min-width: 0; }
.priority-copy strong { font-size: 12px; }
.priority-copy small { color: var(--muted); font-size: 10px; line-height: 1.4; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.priority-meta { display: grid; justify-items: end; }
.priority-meta b { font-size: 16px; }
.priority-meta small { color: var(--muted); font-size: 9px; }
.health-visual { display: flex; align-items: center; justify-content: center; gap: 22px; padding: 4px 0 14px; }
.donut { --value: 82; width: 138px; aspect-ratio: 1; border-radius: 50%; display: grid; place-items: center; position: relative; background: conic-gradient(var(--accent) calc(var(--value) * 1%), rgba(148, 163, 184, .15) 0); }
.donut::after { content: ""; position: absolute; inset: 12px; border-radius: inherit; background: var(--surface-1); }
.donut > div { position: relative; z-index: 1; display: flex; align-items: baseline; }
.donut strong { font-size: 29px; }
.donut small { color: var(--muted); font-size: 11px; }
.donut.small { width: 116px; margin: 8px auto 14px; }
.legend-list { min-width: 150px; display: grid; gap: 11px; }
.legend-list div { display: grid; grid-template-columns: 10px 1fr auto; align-items: center; gap: 8px; font-size: 11px; }
.legend-list span:not(.legend-color) { color: var(--muted); }
.legend-color { width: 9px; height: 9px; border-radius: 3px; }
.legend-color.healthy { background: var(--success); }
.legend-color.attention { background: var(--warning); }
.legend-color.risk { background: var(--critical); }
.insight-strip { display: flex; gap: 9px; padding: 10px 11px; border: 1px solid rgba(6, 182, 212, .16); background: rgba(6, 182, 212, .06); border-radius: 8px; }
.insight-strip .icon { width: 17px; height: 17px; color: var(--accent); margin-top: 1px; }
.insight-strip p { margin: 0; color: var(--muted); font-size: 10px; line-height: 1.5; }
.insight-strip strong { color: var(--text); }
.table-actions { display: flex; gap: 4px; }
.data-table-wrap { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; min-width: 790px; }
.data-table th { padding: 8px 10px; border-bottom: 1px solid var(--border); color: var(--muted); font-size: 9px; font-weight: 750; letter-spacing: .06em; text-align: left; text-transform: uppercase; }
.data-table td { padding: 11px 10px; border-bottom: 1px solid var(--border); font-size: 11px; }
.data-table tr:last-child td { border-bottom: 0; }
.data-table tbody tr { transition: background var(--ease); cursor: pointer; }
.data-table tbody tr:hover { background: var(--surface-2); }
.data-table td:first-child { display: flex; align-items: center; gap: 9px; }
.data-table td:first-child > div { display: grid; }
.data-table td:first-child small { color: var(--muted); font-size: 9px; }
.company-avatar { width: 32px; height: 32px; display: inline-flex; align-items: center; justify-content: center; border-radius: 8px; color: #fff; font-size: 9px; font-weight: 800; }
.company-avatar.cyan { background: #0891b2; }.company-avatar.purple { background: #7c3aed; }.company-avatar.green { background: #15803d; }.company-avatar.blue { background: #2563eb; }.company-avatar.orange { background: #c2410c; }
.tag { display: inline-flex; align-items: center; justify-content: center; min-height: 22px; padding: 2px 8px; border-radius: 999px; font-size: 9px; font-weight: 750; white-space: nowrap; }
.tag.a { background: rgba(6, 182, 212, .13); color: var(--accent); }
.tag.b { background: rgba(139, 92, 246, .13); color: #a78bfa; }
.tag.neutral { background: var(--surface-3); color: var(--muted); }
.tag.warning { background: rgba(245, 158, 11, .13); color: var(--warning); }
.tag.critical { background: rgba(244, 63, 94, .13); color: var(--critical); }
.tag.success { background: rgba(34, 197, 94, .13); color: var(--success); }
.score { min-width: 31px; height: 25px; display: inline-flex; align-items: center; justify-content: center; border-radius: 7px; font-size: 10px; font-weight: 800; }
.score.good { color: var(--success); background: rgba(34, 197, 94, .11); }.score.attention { color: var(--warning); background: rgba(245, 158, 11, .11); }.score.risk { color: var(--critical); background: rgba(244, 63, 94, .11); }

.module-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(300px, .6fr); gap: 12px; }
.module-grid.two-thirds { grid-template-columns: minmax(0, 1.55fr) minmax(300px, .45fr); }
.filter-bar { display: grid; grid-template-columns: 1fr 160px 160px; gap: 8px; margin-bottom: 13px; }
.filter-bar label { height: 40px; display: flex; align-items: center; gap: 8px; padding: 0 11px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface-2); }
.filter-bar label .icon { width: 16px; height: 16px; color: var(--muted); }
.filter-bar input { width: 100%; border: 0; background: transparent; color: var(--text); }
select { height: 40px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface-2); color: var(--text); padding: 0 10px; }
.client-card-list { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 8px; }
.client-card { display: grid; grid-template-columns: 40px minmax(0,1fr) auto; align-items: center; gap: 10px; padding: 11px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-2); cursor: pointer; }
.client-card:hover { border-color: var(--accent); }
.client-card-copy { display: grid; }
.client-card-copy small { color: var(--muted); font-size: 10px; }
.client-card-meta { display: flex; gap: 6px; align-items: center; }
.segment-stack { display: grid; gap: 8px; }
.segment-stack > div { display: grid; grid-template-columns: 40px 40px 1fr; align-items: center; gap: 9px; padding: 11px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-2); }
.segment-stack span { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 8px; background: rgba(6, 182, 212, .12); color: var(--accent); font-weight: 800; }
.segment-stack strong { font-size: 18px; }
.segment-stack small { color: var(--muted); }
.segment-stack + .insight-strip { margin-top: 12px; }
.task-board { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 9px; }
.task-column { padding: 10px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--border); }
.task-column h3 { display: flex; justify-content: space-between; margin: 0 0 8px; font-size: 11px; }
.task-column h3 span { color: var(--muted); }
.task-card { padding: 10px; margin-bottom: 7px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface-1); }
.task-card:last-child { margin-bottom: 0; }
.task-card strong { display: block; font-size: 10px; }
.task-card small { display: block; margin-top: 4px; color: var(--muted); font-size: 9px; }
.metric-big { font-size: 56px; line-height: 1; font-weight: 850; margin: 20px 0 8px; }
.muted { color: var(--muted); }.centered { text-align: center; }
.onboarding-list, .renewal-list, .escalation-list { display: grid; gap: 9px; }
.onboarding-card, .renewal-card, .escalation-card { display: grid; grid-template-columns: minmax(0,1fr) 150px 100px; align-items: center; gap: 14px; padding: 12px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-2); }
.onboarding-card strong, .renewal-card strong, .escalation-card strong { display: block; font-size: 11px; }
.onboarding-card small, .renewal-card small, .escalation-card small { color: var(--muted); font-size: 9px; }
.progress { height: 7px; overflow: hidden; border-radius: 999px; background: rgba(148,163,184,.18); }
.progress i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--accent-action), var(--accent)); }
.check-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.check-list li { display: flex; align-items: center; gap: 9px; color: var(--muted); }
.check-list .icon { width: 17px; height: 17px; color: var(--success); }
.driver-list { display: grid; gap: 13px; }
.driver-row { display: grid; grid-template-columns: 170px minmax(0,1fr) 48px 80px; align-items: center; gap: 10px; font-size: 10px; }
.driver-row > span:first-child { color: var(--muted); }
.driver-bar { height: 8px; border-radius: 999px; background: rgba(148,163,184,.16); overflow: hidden; }
.driver-bar i { display: block; height: 100%; border-radius: inherit; background: var(--accent); }
.driver-row em { font-style: normal; color: var(--muted); text-align: right; }
.opportunity-card { padding: 11px; margin-bottom: 9px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-2); }
.opportunity-card strong { display: block; margin: 8px 0 4px; font-size: 11px; }
.opportunity-card p { margin: 0; color: var(--muted); font-size: 10px; }
.signal-card { display: flex; gap: 12px; padding: 12px; border: 1px solid rgba(245,158,11,.22); border-radius: 9px; background: rgba(245,158,11,.06); }
.signal-card .icon { color: var(--warning); }
.signal-card p { margin: 4px 0 0; color: var(--muted); font-size: 10px; }
.horizontal-bars { display: grid; gap: 12px; }
.bar-row { display: grid; grid-template-columns: 150px minmax(0,1fr) 50px; gap: 10px; align-items: center; font-size: 10px; }
.bar-row span { color: var(--muted); }
.bar-track { height: 9px; border-radius: 999px; background: rgba(148,163,184,.15); overflow: hidden; }
.bar-track i { height: 100%; display: block; border-radius: inherit; background: linear-gradient(90deg, var(--accent-action), var(--accent)); }
.bar-row strong { text-align: right; }
.sentiment-stack { display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; margin-bottom: 14px; }
.sentiment { padding: 11px 8px; border-radius: 9px; text-align: center; border: 1px solid var(--border); background: var(--surface-2); }
.sentiment strong { display: block; font-size: 18px; }
.sentiment span { color: var(--muted); font-size: 9px; }
.sentiment.positive strong { color: var(--success); }.sentiment.neutral strong { color: var(--muted); }.sentiment.negative strong { color: var(--critical); }
.conversation-preview, .conversation-list { display: grid; gap: 8px; }
.conversation-row { display: grid; grid-template-columns: 38px minmax(0,1fr) 95px 90px; gap: 10px; align-items: center; padding: 10px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-2); }
.play-button { width: 34px; height: 34px; display: grid; place-items: center; border: 0; border-radius: 9px; background: rgba(6,182,212,.12); color: var(--accent); }
.play-button .icon { width: 15px; height: 15px; }
.conversation-row strong { display: block; font-size: 10px; }
.conversation-row small { color: var(--muted); font-size: 9px; }
.conversation-row .conversation-summary { min-width: 0; }
.conversation-row .conversation-summary small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.insight-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.insight-list li { display: flex; gap: 10px; padding: 10px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-2); }
.insight-list li > span { color: var(--accent); font-weight: 800; }
.insight-list p { margin: 0; color: var(--muted); font-size: 10px; }
.agent-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px; }
.agent-card { padding: 12px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-2); }
.agent-card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.agent-card-head > div { display: flex; align-items: center; gap: 8px; }
.agent-avatar { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 9px; background: var(--accent-dark); color: #fff; font-size: 10px; font-weight: 800; }
.agent-card h3 { margin: 0; font-size: 11px; }
.agent-card small { color: var(--muted); font-size: 9px; }
.agent-metrics { display: grid; grid-template-columns: repeat(3,1fr); gap: 6px; margin-top: 10px; }
.agent-metrics div { padding: 7px; border-radius: 7px; background: var(--surface-1); text-align: center; }
.agent-metrics strong { display: block; font-size: 12px; }
.agent-metrics span { color: var(--muted); font-size: 8px; }
.training-list { display: grid; gap: 8px; }
.training-list button { width: 100%; display: flex; align-items: center; gap: 10px; padding: 10px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-2); text-align: left; }
.training-list button:hover { border-color: var(--accent); }
.training-list button > span { width: 27px; height: 27px; display: grid; place-items: center; border-radius: 7px; background: rgba(6,182,212,.12); color: var(--accent); font-size: 9px; font-weight: 800; }
.training-list div { display: grid; }
.training-list strong { font-size: 10px; }
.training-list small { color: var(--muted); font-size: 9px; }
.footnote { color: var(--muted); font-size: 9px; line-height: 1.5; margin: 12px 0 0; }
.knowledge-grid, .report-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px; }
.knowledge-card, .report-card { padding: 12px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-2); }
.knowledge-card-head, .report-card-head { display: flex; justify-content: space-between; gap: 8px; }
.knowledge-card strong, .report-card strong { font-size: 11px; }
.knowledge-card p, .report-card p { margin: 6px 0; color: var(--muted); font-size: 9px; }
.knowledge-card small, .report-card small { color: var(--muted-2); font-size: 8px; }
.gap-list { display: grid; gap: 8px; margin-bottom: 12px; }
.gap-list button { width: 100%; display: grid; grid-template-columns: 42px 1fr; gap: 8px; align-items: center; padding: 10px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-2); text-align: left; }
.gap-list strong { color: var(--warning); }.gap-list span { color: var(--muted); font-size: 10px; }
.cadence-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.cadence-list li { display: flex; align-items: center; gap: 10px; }
.cadence-list div { display: grid; }.cadence-list small { color: var(--muted); }

.portal-screen { padding-bottom: 30px; }
.portal-top { min-height: 58px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; margin-bottom: 15px; padding: 9px 12px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-1); }
.portal-brand { display: flex; align-items: center; gap: 10px; }
.portal-brand > div { display: grid; }.portal-brand small { color: var(--muted); font-size: 9px; }
.portal-user { justify-self: end; display: flex; align-items: center; gap: 8px; }
.portal-user > span { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 9px; background: var(--surface-3); color: var(--accent); font-weight: 800; font-size: 10px; }
.portal-user div { display: grid; text-align: right; }.portal-user small { color: var(--muted); font-size: 9px; }
.portal-hero { min-height: 180px; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 28px; margin-bottom: 12px; border: 1px solid rgba(6,182,212,.25); border-radius: 16px; background: radial-gradient(circle at 85% 25%, rgba(6,182,212,.18), transparent 34%), linear-gradient(135deg, var(--surface-1), var(--surface-2)); overflow: hidden; }
.portal-hero h1 { margin: 6px 0; font-size: 30px; }.portal-hero p { margin: 0; color: var(--muted); }
.portal-score { display: flex; align-items: center; gap: 15px; }.portal-score > div:last-child { display: grid; }
.portal-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.goal-list { display: grid; gap: 12px; }
.goal-list > div { display: grid; grid-template-columns: 30px 1fr; gap: 10px; }
.goal-list > div > span { color: var(--accent); font-weight: 800; }
.goal-list > div > div { display: grid; grid-template-columns: 1fr 34px; gap: 7px; align-items: center; }
.goal-list strong { grid-column: 1 / -1; font-size: 10px; }.goal-list small { color: var(--muted); text-align: right; }
.ticket-list, .resource-list { display: grid; gap: 8px; }
.ticket-list button, .resource-list button { width: 100%; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 9px; padding: 10px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-2); text-align: left; }
.ticket-id { color: var(--accent); font-size: 9px; font-weight: 800; }
.ticket-list div, .resource-list div { display: grid; }.ticket-list small, .resource-list small { color: var(--muted); font-size: 9px; }
.resource-list button { grid-template-columns: 30px 1fr; }.resource-list .icon { color: var(--accent); }
.portal-actions-list { display: grid; gap: 9px; }
.portal-actions-list > div { display: flex; gap: 9px; padding: 10px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-2); }
.portal-actions-list input { accent-color: var(--accent); }.portal-actions-list span { display: grid; }.portal-actions-list strong { font-size: 10px; }.portal-actions-list small { color: var(--muted); font-size: 9px; }

.ai-panel { grid-area: ai; min-width: 0; display: flex; flex-direction: column; border-left: 1px solid var(--border); background: var(--surface-1); overflow: hidden; z-index: 35; transition: opacity 160ms ease, transform 220ms ease; }
.ai-collapsed .ai-panel { opacity: 0; transform: translateX(100%); pointer-events: none; }
.ai-panel-head { min-height: 65px; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 11px 12px; border-bottom: 1px solid var(--border); }
.ai-identity { display: flex; align-items: center; gap: 10px; }
.ai-orb { width: 37px; height: 37px; display: grid; place-items: center; border-radius: 12px; background: radial-gradient(circle at 35% 30%, #67e8f9, var(--accent) 35%, var(--accent-dark) 75%); box-shadow: 0 0 26px rgba(6,182,212,.26); }
.ai-orb i { width: 12px; height: 12px; border-radius: 999px; border: 2px solid rgba(255,255,255,.9); box-shadow: inset 0 0 0 3px rgba(255,255,255,.2); }
.ai-identity > div { display: grid; line-height: 1.3; }.ai-identity strong { font-size: 12px; }.ai-identity small { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 9px; }
.ai-context { min-height: 37px; display: flex; align-items: center; gap: 7px; padding: 7px 14px; border-bottom: 1px solid var(--border); background: var(--surface-2); font-size: 10px; }
.ai-context span { color: var(--muted); }.ai-context strong { color: var(--accent); }
.chat-messages { flex: 1; overflow-y: auto; padding: 13px; display: flex; flex-direction: column; gap: 12px; scrollbar-width: thin; }
.message { display: flex; gap: 8px; align-items: flex-start; }
.message.user { justify-content: flex-end; }
.message-avatar { width: 29px; height: 29px; display: grid; place-items: center; border-radius: 9px; background: rgba(6,182,212,.13); color: var(--accent); font-size: 9px; font-weight: 850; flex: 0 0 auto; }
.message-bubble { max-width: calc(100% - 40px); padding: 10px 11px; border: 1px solid var(--border); border-radius: 4px 12px 12px 12px; background: var(--surface-2); }
.message.user .message-bubble { background: var(--accent-action); color: #fff; border-color: transparent; border-radius: 12px 4px 12px 12px; }
.message-bubble p { margin: 0; font-size: 11px; line-height: 1.55; white-space: pre-line; }
.message-sources { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.message-sources span { padding: 2px 6px; border-radius: 999px; background: var(--surface-1); color: var(--muted); font-size: 8px; }
.message-actions { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.message-actions button { border: 1px solid var(--border); border-radius: 7px; background: var(--surface-1); color: var(--accent); padding: 5px 7px; font-size: 9px; }
.message-actions button:hover { border-color: var(--accent); }
.typing { display: flex; gap: 4px; padding: 4px 0; }
.typing i { width: 5px; height: 5px; border-radius: 50%; background: var(--muted); animation: blink 1s infinite alternate; }.typing i:nth-child(2){animation-delay:.2s}.typing i:nth-child(3){animation-delay:.4s}
@keyframes blink { to { opacity: .25; transform: translateY(-2px); } }
.suggested-prompts { display: flex; gap: 6px; overflow-x: auto; padding: 7px 12px 8px; border-top: 1px solid var(--border); scrollbar-width: none; }
.suggested-prompts::-webkit-scrollbar { display: none; }
.suggested-prompts button { flex: 0 0 auto; border: 1px solid var(--border); background: var(--surface-2); color: var(--muted); border-radius: 999px; padding: 5px 8px; font-size: 9px; }
.suggested-prompts button:hover { border-color: var(--accent); color: var(--accent); }
.chat-form { padding: 10px 12px 11px; border-top: 1px solid var(--border); }
.chat-input-wrap { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: end; gap: 7px; min-height: 48px; padding: 5px 5px 5px 10px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-2); }
.chat-input-wrap:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(6,182,212,.1); }
.chat-input-wrap textarea { width: 100%; max-height: 120px; resize: none; border: 0; background: transparent; color: var(--text); padding: 8px 0; font-size: 11px; line-height: 1.4; }
.chat-tools { display: flex; align-items: center; gap: 3px; }
.send-button { width: 36px; height: 36px; display: grid; place-items: center; border: 0; border-radius: 8px; background: var(--accent-action); color: #fff; }
.send-button:hover { background: #0891b2; }.send-button .icon { width: 16px; height: 16px; }
.chat-disclaimer { margin-top: 6px; color: var(--muted-2); font-size: 8px; text-align: center; }
.ai-reopen { position: fixed; right: 0; bottom: 28px; height: 48px; display: none; align-items: center; gap: 6px; padding: 5px 8px; border: 1px solid var(--border); border-right: 0; border-radius: 12px 0 0 12px; background: var(--surface-1); box-shadow: var(--shadow); z-index: 80; }
.ai-reopen .ai-orb { width: 34px; height: 34px; border-radius: 9px; }.ai-reopen .icon { width: 15px; height: 15px; color: var(--muted); }
.ai-collapsed .ai-reopen { display: flex; }
.mobile-overlay { display: none; position: fixed; inset: var(--topbar-h) 0 0; background: rgba(0,0,0,.5); z-index: 29; }

.modal-backdrop { position: fixed; inset: 0; display: grid; place-items: center; padding: 20px; background: rgba(2,6,16,.72); backdrop-filter: blur(5px); z-index: 200; }
.modal { width: min(720px, 100%); max-height: calc(100vh - 40px); display: flex; flex-direction: column; border: 1px solid var(--border); border-radius: 16px; background: var(--surface-1); box-shadow: var(--shadow); overflow: hidden; }
.modal-head, .modal-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--border); }
.modal-head h2 { margin: 3px 0 0; font-size: 19px; }.modal-body { overflow-y: auto; padding: 16px; }.modal-foot { justify-content: flex-end; border-top: 1px solid var(--border); border-bottom: 0; }
.client-modal-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; margin-bottom: 13px; }
.client-modal-grid div { padding: 10px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface-2); }
.client-modal-grid span { color: var(--muted); font-size: 9px; }.client-modal-grid strong { display: block; margin-top: 3px; font-size: 13px; }
.modal-section { margin-top: 14px; }.modal-section h3 { margin: 0 0 8px; font-size: 12px; }.modal-section ul { margin: 0; padding-left: 18px; color: var(--muted); font-size: 10px; }
.toast-region { position: fixed; right: 20px; bottom: 20px; display: grid; gap: 8px; z-index: 300; }
.toast { min-width: 280px; max-width: 380px; display: flex; align-items: flex-start; gap: 9px; padding: 11px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-1); box-shadow: var(--shadow); animation: toastIn 180ms ease; }
.toast .icon { color: var(--accent); }.toast strong { display: block; font-size: 10px; }.toast p { margin: 2px 0 0; color: var(--muted); font-size: 9px; }
@keyframes toastIn { from { opacity:0; transform: translateY(8px);} }

@media (max-width: 1360px) {
  :root { --ai-w: 350px; }
  .assistant-identity span { max-width: 180px; }
  .user-copy { display: none; }
}
@media (max-width: 1180px) {
  .app-shell, .app-shell.sidebar-collapsed { grid-template-columns: var(--sidebar-collapsed) minmax(0, 1fr) 0; }
  .sidebar .nav-group-title, .sidebar .nav-item span, .sidebar .collapse-button span, .sidebar .collapse-left { display: none; }
  .sidebar .collapse-right { display: block; }
  .sidebar .nav-item { justify-content: center; padding: 8px; }
  .sidebar .collapse-button { justify-content: center; padding: 0; }
  .ai-panel { position: fixed; top: var(--topbar-h); right: 0; bottom: 0; width: min(430px, 100vw); transform: translateX(100%); opacity: 0; box-shadow: var(--shadow); }
  .app-shell.ai-mobile-open .ai-panel { transform: translateX(0); opacity: 1; pointer-events: auto; }
  .app-shell.ai-mobile-open .mobile-overlay { display: block; }
  .ai-reopen, .ai-collapsed .ai-reopen { display: flex; }
  .kpi-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 860px) {
  .app-shell, .app-shell.sidebar-collapsed, .app-shell.ai-collapsed, .app-shell.sidebar-collapsed.ai-collapsed {
    grid-template-columns: minmax(0,1fr); grid-template-rows: var(--topbar-h) minmax(0,1fr); grid-template-areas: "top" "main";
  }
  .topbar { padding: 0 10px; }
  .mobile-menu { display: inline-flex; }
  .assistant-identity, .voice-label, .voice-status, .language-switch, .user-button > .icon { display: none; }
  .voice-control { width: 40px; justify-content: center; padding: 0; }
  .sidebar { position: fixed; top: var(--topbar-h); left: 0; bottom: 0; width: min(290px, 86vw); transform: translateX(-100%); transition: transform 220ms ease; box-shadow: var(--shadow); }
  .app-shell.mobile-nav-open .sidebar { transform: translateX(0); }
  .app-shell.mobile-nav-open .mobile-overlay { display: block; }
  .sidebar .nav-group-title, .sidebar .nav-item span, .sidebar .collapse-button span { display: block; }
  .sidebar .nav-item { justify-content: flex-start; padding: 8px 10px; }
  .sidebar .nav-badge { display: inline-flex; }
  .sidebar .collapse-button { display: none; }
  .ai-panel {
    top: 0;
    bottom: auto;
    width: 100vw;
    height: 100dvh;
    max-height: none;
    z-index: 120;
  }
  .page-content { padding: 16px 14px 36px; }
  .page-header { align-items: flex-start; flex-direction: column; }
  .page-actions { width: 100%; justify-content: space-between; }
  .page-actions .button.secondary { flex: 1; }
  .dashboard-grid, .module-grid, .module-grid.two-thirds { grid-template-columns: 1fr; }
  .panel.wide { grid-column: auto; }
  .portal-top { grid-template-columns: 1fr auto; }
  .portal-brand { display: none; }
  .portal-grid { grid-template-columns: 1fr; }
  .portal-hero { align-items: flex-start; flex-direction: column; }
  .filter-bar { grid-template-columns: 1fr 1fr; }.filter-bar label { grid-column: 1/-1; }
}
@media (max-width: 620px) {
  :root { --topbar-h: 64px; }
  .topbar-actions { gap: 4px; }.topbar-left { gap: 2px; }
  .brand-link { height: 48px; padding: 2px 3px; }.brand-logo { width: 108px; height: 42px; }.brand-mark { width: 32px; height: 32px; }
  .user-button { padding: 3px; }.user-button img { width: 34px; height: 34px; }
  .kpi-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .kpi-card { min-height: 130px; padding: 13px; }.kpi-value { font-size: 25px; }
  .page-header h1 { font-size: 23px; line-height: 29px; }
  .page-actions { align-items: stretch; flex-direction: column; }.mode-switch { width: 100%; }.mode-btn { flex: 1; }
  .health-visual { align-items: flex-start; flex-direction: column; }.donut { margin: 0 auto; }.legend-list { width: 100%; }
  .client-card-list, .agent-grid, .knowledge-grid, .report-grid { grid-template-columns: 1fr; }
  .task-board { grid-template-columns: 1fr; }
  .onboarding-card, .renewal-card, .escalation-card { grid-template-columns: 1fr; }
  .driver-row { grid-template-columns: 120px 1fr 34px; }.driver-row em { display: none; }
  .conversation-row { grid-template-columns: 34px minmax(0,1fr) 70px; }.conversation-row > :last-child { display: none; }
  .bar-row { grid-template-columns: 105px 1fr 40px; }
  .portal-user div { display: none; }
  .portal-hero { padding: 20px; }.portal-hero h1 { font-size: 24px; }
  .client-modal-grid { grid-template-columns: 1fr; }
  .modal-backdrop { padding: 10px; }.modal { max-height: calc(100vh - 20px); }
  .toast-region { left: 12px; right: 12px; bottom: 12px; }.toast { min-width: 0; max-width: none; }
}
@media (max-width: 430px) {
  .kpi-grid { grid-template-columns: 1fr; }
  .kpi-card { min-height: 118px; }
  .page-content { padding-left: 10px; padding-right: 10px; }
  .panel { padding: 14px; }
  .demo-banner { align-items: flex-start; }
  .popover { position: fixed; top: 70px; left: 10px; right: 10px; min-width: 0; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

/* CyberCompany card emphasis, without changing semantic status colours. */
:root {
  --cc-card-hover-surface: #f8fafc;
  --cc-card-hover-ink: #111827;
  --cc-card-hover-muted: #667085;
  --cc-card-hover-border: color-mix(in srgb, var(--accent) 58%, #cbd5e1);
}
html[data-theme="light"] {
  --cc-card-hover-surface: #111827;
  --cc-card-hover-ink: #f8fafc;
  --cc-card-hover-muted: #cbd5e1;
  --cc-card-hover-border: color-mix(in srgb, var(--accent) 68%, #475569);
}
.kpi-card,.priority-item,.insight-strip,.insight-list li,.client-card,.agent-card,.knowledge-card,.report-card {
  transition: background .2s ease, color .2s ease, border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
@media (hover:hover) and (pointer:fine) {
  :is(.kpi-card,.priority-item,.insight-strip,.insight-list li,.client-card,.agent-card,.knowledge-card,.report-card):hover {
    color: var(--cc-card-hover-ink);
    background: var(--cc-card-hover-surface);
    border-color: var(--cc-card-hover-border);
    transform: translateY(-3px);
    box-shadow: 0 16px 34px rgba(15,23,42,.18);
  }
  :is(.kpi-card,.priority-item,.insight-strip,.insight-list li,.client-card,.agent-card,.knowledge-card,.report-card):hover :is(.kpi-head,.source-line,.priority-copy small,.priority-meta small,.insight-strip p,.insight-list p,.client-card-copy small,.agent-card small,.knowledge-card p,.knowledge-card small,.report-card p,.report-card small) { color: var(--cc-card-hover-muted); }
}
:is(.kpi-card,.priority-item,.insight-strip,.insight-list li,.client-card,.agent-card,.knowledge-card,.report-card):focus-visible {
  color: var(--cc-card-hover-ink);
  background: var(--cc-card-hover-surface);
  border-color: var(--cc-card-hover-border);
}
