@import url('https://fonts.googleapis.com/css2?family=Space+Mono:ital,wght@0,400;0,700;1,400&family=Chakra+Petch:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500;700&display=swap');

:root {
  --gold: #D4A843;
  --gold-light: #F0D68A;
  --red: #E63946;
  --red-light: #FF6B7A;
  --cyan: #5BC0EB;
  --cyan-light: #8DD8F8;
  --green: #2EC04A;
  --dark: #0A0A0A;
  --bg: #F2F0EB;
  --card-bg: #FAFAF8;
  --font-display: 'Chakra Petch', sans-serif;
  --font-mono: 'JetBrains Mono', 'Space Mono', monospace;
  --border: 3px solid #000;
  --border-thin: 2px solid #000;
  --shadow: 6px 6px 0 #000;
  --shadow-sm: 3px 3px 0 #000;
  --radius: 0;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { font-size: 15px; }

body {
  background: var(--bg);
  color: #111;
  font-family: var(--font-mono);
  overflow-x: hidden;
  min-height: 100vh;
}

/* === ANIMATIONS === */
@keyframes fadeIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
@keyframes slideUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }
@keyframes glowPulse { 0%, 100% { box-shadow: 0 0 8px rgba(212,168,67,0.3); } 50% { box-shadow: 0 0 20px rgba(212,168,67,0.6); } }
@keyframes scanline { 0% { top: -10%; } 100% { top: 110%; } }
@keyframes float1 { 0%, 100% { transform: translateY(0) rotate(0deg); } 50% { transform: translateY(-18px) rotate(6deg); } }
@keyframes float2 { 0%, 100% { transform: translateY(0) rotate(45deg); } 50% { transform: translateY(-12px) rotate(51deg); } }
@keyframes float3 { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.08); } }
@keyframes typing { from { width: 0; } to { width: 100%; } }
@keyframes cardEnter { from { opacity: 0; transform: translateY(24px) scale(0.97); } to { opacity: 1; transform: translateY(0) scale(1); } }

.fade-in { animation: fadeIn 0.5s ease-out; }

/* === FLOATING SHAPES === */
.float-shape {
  position: absolute;
  z-index: 1;
}
.shape-diamond {
  width: 64px; height: 64px;
  border: 4px solid #000;
  background: #fff;
  transform: rotate(45deg);
  animation: float2 6s ease-in-out infinite;
}
.shape-diamond::after {
  content: ''; position: absolute; inset: 8px;
  background: #000;
}
.shape-ellipse {
  width: 80px; height: 48px;
  border-radius: 50%;
  background: var(--gold);
  border: 3px solid #000;
  transform: rotate(-20deg);
  animation: float1 5s ease-in-out infinite;
}
.shape-circle {
  width: 64px; height: 64px;
  border-radius: 50%;
  background: var(--red);
  border: 3px solid transparent;
  animation: float3 4s ease-in-out infinite;
}
.shape-square {
  width: 48px; height: 48px;
  background: #000;
  animation: float1 7s ease-in-out infinite reverse;
}

/* === NAVBAR === */
.navbar {
  position: sticky; top: 0; z-index: 100;
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 24px;
  background: #0A0A0A;
  color: #fff;
  border-bottom: 3px solid var(--gold);
}
.nav-logo {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: 3px;
  color: var(--gold);
}
.status-badge {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 3px;
  letter-spacing: 0.5px;
}
.status-badge.green { background: rgba(46,192,74,0.15); color: var(--green); border: 1px solid rgba(46,192,74,0.3); }
.status-badge.small { font-size: 10px; padding: 2px 8px; }
.status-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 4px; }
.status-dot.green { background: var(--green); }
.status-dot.red { background: var(--red); }

/* === BUTTONS === */
.btn-brutal {
  font-family: var(--font-mono);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  border: var(--border-thin);
  background: #fff;
  cursor: pointer;
  transition: all 0.15s;
  box-shadow: var(--shadow-sm);
}
.btn-brutal:hover { transform: translate(-1px, -1px); box-shadow: 5px 5px 0 #000; }
.btn-brutal:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 #000; }

.action-btn {
  width: 100%; padding: 12px; font-size: 13px;
}
.action-btn.gold { background: var(--gold); color: #000; }
.action-btn.red { background: var(--red); color: #fff; }
.action-btn.cyan { background: var(--cyan); color: #000; }
.action-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none !important; }

/* === GATEWAY CARDS === */
.gateway-card {
  background: var(--card-bg);
  border: var(--border);
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.2, 0, 0, 1);
  animation: cardEnter 0.6s ease-out both;
  position: relative;
  overflow: hidden;
}
.gateway-card::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s;
}
.gateway-card:hover::before { transform: scaleX(1); }
.gateway-card:hover {
  transform: translate(-4px, -4px);
  box-shadow: 10px 10px 0 #000;
}
.gateway-card:active {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 #000;
}
.gateway-header {
  padding: 10px 14px;
  display: flex; justify-content: space-between; align-items: center;
  border-bottom: var(--border-thin);
}
.gateway-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.gateway-id {
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 2px 8px;
  background: rgba(0,0,0,0.1);
  border: 1px solid rgba(0,0,0,0.2);
  letter-spacing: 0.5px;
}
.gateway-body {
  padding: 20px 14px;
  text-align: center;
}
.gateway-icon {
  font-size: 48px;
  margin-bottom: 14px;
  opacity: 0.7;
  transition: all 0.3s;
}
.gateway-card:hover .gateway-icon { opacity: 1; transform: scale(1.1); }
.gateway-status {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 6px;
}
.gateway-desc {
  font-family: var(--font-mono);
  font-size: 10px;
  opacity: 0.5;
  letter-spacing: 0.3px;
}
.gateway-footer {
  padding: 8px 14px;
  border-top: 1px solid rgba(0,0,0,0.08);
  text-align: center;
  opacity: 0;
  transition: opacity 0.3s;
}
.gateway-card:hover .gateway-footer { opacity: 1; }

/* === STAT CARDS === */
.stat-card {
  background: var(--card-bg);
  border: var(--border);
  box-shadow: var(--shadow-sm);
  padding: 16px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.stat-value {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 32px;
  letter-spacing: 1px;
}
.stat-label {
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  opacity: 0.6;
  margin-top: 4px;
}
.stat-accent-bar {
  position: absolute; bottom: 0; left: 0; right: 0;
  height: 4px;
}

/* === WIDGET CARDS === */
.widget-card {
  background: var(--card-bg);
  border: var(--border);
  box-shadow: var(--shadow-sm);
  padding: 16px;
  animation: fadeIn 0.5s ease-out both;
}
.widget-card.compact { padding: 12px; }
.widget-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 2px solid #000;
}
.terminal-widget { background: #0A0A0A; color: #fff; }
.terminal-widget .widget-title { border-color: #333; color: var(--green); }
.terminal-body {
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.8;
  max-height: 200px;
  overflow-y: auto;
}
.terminal-line { white-space: pre-wrap; }
.cursor-blink { opacity: 0; transition: opacity 0.1s; }
.cursor-blink.on { opacity: 1; color: var(--green); }

/* === PROGRESS BARS === */
.progress-row {
  display: grid;
  grid-template-columns: 140px 1fr 42px;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.progress-row.compact { grid-template-columns: 80px 1fr 36px; font-size: 10px; margin-bottom: 6px; }
.progress-bar {
  height: 10px;
  background: #E5E5E0;
  border: 1px solid #000;
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}
.progress-fill.green { background: var(--green); }
.progress-fill.blue { background: var(--cyan); }
.progress-val { text-align: right; }

/* === MINI CHART === */
.mini-chart {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 80px;
}
.mini-chart.tall { height: 120px; }
.chart-bar-col { flex: 1; display: flex; align-items: flex-end; height: 100%; }
.chart-bar {
  width: 100%;
  min-height: 4px;
  border-radius: 1px 1px 0 0;
  transition: height 0.6s ease-out;
}

/* === TIMELINE === */
.timeline-list { display: flex; flex-direction: column; gap: 0; }
.timeline-item {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(0,0,0,0.06);
  animation: fadeIn 0.4s ease-out both;
}
.timeline-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  margin-top: 4px;
  flex-shrink: 0;
}
.timeline-action {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
}
.timeline-time {
  font-family: var(--font-mono);
  font-size: 10px;
  opacity: 0.4;
  margin-top: 2px;
}

/* === NETWORK TOPOLOGY === */
.topology-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}
.topology-node {
  position: relative;
  display: flex; align-items: center; justify-content: center;
  padding: 12px 6px;
  border: 2px solid #000;
  background: var(--card-bg);
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-align: center;
}
.topology-node.online { border-color: var(--green); }
.topology-node.busy { border-color: var(--gold); }
.topology-node.alert { border-color: var(--red); background: rgba(230,57,70,0.05); }
.node-pulse {
  position: absolute; top: 4px; right: 4px;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--green);
}
.topology-node.busy .node-pulse { background: var(--gold); animation: pulse 2s infinite; }
.topology-node.alert .node-pulse { background: var(--red); animation: pulse 1s infinite; }

/* === QUICK ACTIONS === */
.quick-actions-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}
.quick-action-btn {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 14px 8px;
  background: var(--card-bg);
  border: var(--border-thin);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: all 0.15s;
  box-shadow: var(--shadow-sm);
}
.quick-action-btn:hover {
  transform: translate(-2px, -2px);
  box-shadow: 5px 5px 0 #000;
  background: var(--accent);
}
.qa-icon { font-size: 22px; }

/* === DASHBOARD LAYOUT === */
.dashboard-content {
  position: relative;
  z-index: 2;
  padding: 24px 32px 60px;
  max-width: 1400px;
  margin: 0 auto;
}
.dashboard-header {
  margin-bottom: 28px;
  animation: fadeIn 0.4s ease-out;
}
.dashboard-header h1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 42px;
  text-transform: uppercase;
  letter-spacing: 3px;
  line-height: 1;
}
.dashboard-header .portal-badge {
  display: inline-block;
  padding: 4px 14px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  border: var(--border-thin);
  box-shadow: var(--shadow-sm);
  margin-left: 12px;
  transform: rotate(-2deg);
}
.dashboard-header p {
  font-family: var(--font-mono);
  font-size: 11px;
  opacity: 0.5;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-top: 8px;
}

.gateways-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}
.widgets-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 24px;
}
.widgets-grid-3 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 16px;
  margin-bottom: 24px;
}
.section-divider {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 3px;
  padding: 10px 0;
  margin-bottom: 16px;
  border-bottom: 3px solid #000;
  display: flex; justify-content: space-between; align-items: center;
}

/* === SUB-PAGE STYLES === */
.subpage {
  position: relative; z-index: 2;
  padding: 24px 32px 60px;
  max-width: 1400px;
  margin: 0 auto;
}
.subpage-header { margin-bottom: 24px; }
.subpage-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 36px;
  text-transform: uppercase;
  letter-spacing: 3px;
}
.subpage-subtitle {
  font-family: var(--font-mono);
  font-size: 11px;
  opacity: 0.5;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-top: 6px;
}
.back-btn { position: relative; z-index: 5; }
.gateway-badge {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  padding: 3px 12px;
  border: var(--border-thin);
  box-shadow: var(--shadow-sm);
  letter-spacing: 0.5px;
  color: #000;
}

/* === TWO COLUMN === */
.two-col-layout {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 20px;
}
.col-panel {
  border: var(--border);
  box-shadow: var(--shadow);
  background: var(--card-bg);
  overflow: hidden;
}
.panel-header {
  padding: 10px 16px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  border-bottom: var(--border-thin);
}
.panel-body { padding: 20px; }

/* === FORM ELEMENTS === */
.form-content { display: flex; flex-direction: column; }
.field-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 6px;
}
.brutal-input, .brutal-select, .brutal-textarea {
  font-family: var(--font-mono);
  font-size: 13px;
  padding: 10px 12px;
  border: var(--border-thin);
  background: #fff;
  width: 100%;
  outline: none;
  transition: box-shadow 0.2s;
}
.brutal-input:focus, .brutal-select:focus, .brutal-textarea:focus {
  box-shadow: 4px 4px 0 var(--gold);
}
.brutal-textarea { resize: vertical; }
.file-drop {
  border: 2px dashed #000;
  padding: 20px;
  text-align: center;
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 12px;
  transition: all 0.2s;
  background: #FAFAF8;
}
.file-drop:hover { background: #F0EDE6; border-style: solid; }
.file-icon { font-size: 20px; margin-right: 8px; }
.tab-row { display: flex; gap: 0; margin-bottom: 16px; }
.tab-btn {
  padding: 8px 20px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  border: var(--border-thin);
  background: #fff;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.tab-btn.active { background: var(--accent, var(--red)); color: #fff; }

/* === RESULTS === */
.empty-state {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  height: 100%; min-height: 200px;
  opacity: 0.4;
  text-align: center;
}
.empty-icon { font-size: 48px; margin-bottom: 12px; }
.empty-state p { font-family: var(--font-mono); font-size: 12px; }

.result-meta {
  display: flex; gap: 16px;
  font-family: var(--font-mono);
  font-size: 11px;
  padding: 10px 0;
  border-bottom: 1px solid #ddd;
  margin-bottom: 16px;
}
.entity-table { display: flex; flex-direction: column; gap: 8px; }
.entity-row {
  display: grid;
  grid-template-columns: 100px 1fr 80px 40px;
  align-items: center;
  gap: 10px;
  padding: 8px;
  border: 1px solid #eee;
  font-family: var(--font-mono);
  font-size: 12px;
}
.entity-label { font-weight: 700; text-transform: uppercase; font-size: 10px; letter-spacing: 0.5px; }
.entity-value { font-weight: 500; }
.confidence-bar { height: 6px; background: #eee; border: 1px solid #ddd; overflow: hidden; }
.confidence-bar > div { height: 100%; }
.confidence-num { text-align: right; font-size: 10px; opacity: 0.6; }

/* === CANDIDATE CARDS === */
.candidate-card { border: var(--border-thin); padding: 14px; margin-bottom: 10px; background: #fff; }
.candidate-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.candidate-name { font-family: var(--font-display); font-weight: 700; font-size: 15px; }
.candidate-status {
  font-family: var(--font-mono); font-size: 10px; font-weight: 700;
  padding: 2px 10px; letter-spacing: 0.5px;
}
.candidate-status.shortlisted { background: rgba(46,192,74,0.15); color: var(--green); border: 1px solid var(--green); }
.candidate-status.review { background: rgba(212,168,67,0.15); color: #B8941F; border: 1px solid var(--gold); }
.candidate-status.rejected { background: rgba(230,57,70,0.15); color: var(--red); border: 1px solid var(--red); }
.candidate-meta { font-family: var(--font-mono); font-size: 11px; display: flex; gap: 16px; margin-bottom: 8px; }
.candidate-skills { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.skill-tag {
  font-family: var(--font-mono); font-size: 10px; font-weight: 700;
  padding: 2px 8px; border: 1px solid #000; background: var(--bg);
  text-transform: uppercase; letter-spacing: 0.5px;
}
.score-bar { height: 6px; background: #eee; overflow: hidden; }
.score-bar > div { height: 100%; transition: width 0.8s; }

/* === VIOLATION RESULTS === */
.violation-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.violation-btn {
  padding: 8px; font-family: var(--font-mono); font-size: 10px; font-weight: 700;
  border: var(--border-thin); background: #fff; cursor: pointer;
  text-transform: uppercase; letter-spacing: 0.3px; transition: all 0.15s;
}
.violation-btn.active { background: var(--cyan); box-shadow: var(--shadow-sm); }
.violation-btn:hover { background: var(--cyan-light); }

.violation-result { border: var(--border-thin); padding: 14px; margin-bottom: 10px; background: #fff; }
.vr-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.vr-type { font-family: var(--font-display); font-weight: 700; font-size: 14px; text-transform: uppercase; }
.vr-details { font-family: var(--font-mono); font-size: 11px; display: flex; gap: 16px; }

.severity-badge {
  font-family: var(--font-mono); font-size: 10px; font-weight: 700;
  padding: 2px 10px; letter-spacing: 0.5px;
}
.severity-badge.critical { background: var(--red); color: #fff; }
.severity-badge.high { background: var(--gold); color: #000; }
.severity-badge.medium { background: var(--cyan); color: #000; }

/* === ANOMALY PAGE === */
.anomaly-stats-row { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin-bottom: 20px; }
.anomaly-stat {
  border: var(--border-thin); padding: 12px; text-align: center; background: var(--card-bg);
  box-shadow: var(--shadow-sm);
}
.anomaly-stat-val { font-family: var(--font-display); font-weight: 700; font-size: 28px; color: var(--red); }
.anomaly-stat-lbl { font-family: var(--font-mono); font-size: 10px; text-transform: uppercase; letter-spacing: 1px; opacity: 0.6; }
.anomaly-main-grid { display: grid; grid-template-columns: 1fr 1.5fr; gap: 16px; }
.anomaly-left { display: flex; flex-direction: column; gap: 16px; }
.alert-card { border: var(--border-thin); padding: 14px; margin-bottom: 10px; background: #fff; }
.alert-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.alert-title { font-family: var(--font-display); font-weight: 700; font-size: 13px; text-transform: uppercase; }
.alert-meta { font-family: var(--font-mono); font-size: 10px; opacity: 0.5; display: flex; justify-content: space-between; margin-bottom: 4px; }
.alert-loc { font-family: var(--font-mono); font-size: 11px; margin-bottom: 8px; }

/* === CHAT === */
.chat-layout { display: grid; grid-template-columns: 240px 1fr; gap: 16px; }
.chat-sidebar .widget-card { margin-bottom: 12px; }
.info-rows { display: flex; flex-direction: column; gap: 8px; }
.info-row { display: flex; justify-content: space-between; font-size: 11px; }
.chat-main {
  border: var(--border); box-shadow: var(--shadow);
  display: flex; flex-direction: column; background: var(--card-bg);
  height: 560px;
}
.chat-header {
  padding: 12px 16px;
  border-bottom: var(--border-thin);
  display: flex; justify-content: space-between; align-items: center;
  font-family: var(--font-display); font-weight: 700; font-size: 16px;
  text-transform: uppercase; letter-spacing: 1px;
}
.chat-messages {
  flex: 1; padding: 16px; overflow-y: auto;
  display: flex; flex-direction: column; gap: 12px;
}
.chat-msg { display: flex; gap: 10px; align-items: flex-start; }
.chat-msg.user { justify-content: flex-end; }
.msg-avatar { font-size: 24px; flex-shrink: 0; }
.msg-bubble {
  font-family: var(--font-mono); font-size: 12px; line-height: 1.7;
  padding: 12px 16px; border: var(--border-thin);
  max-width: 80%; white-space: pre-wrap;
}
.chat-msg.bot .msg-bubble { background: #fff; }
.chat-msg.user .msg-bubble { background: var(--gold); }
.msg-bubble.typing { opacity: 0.6; }
.dots { animation: pulse 1.5s infinite; }
.chat-input-bar {
  padding: 12px 16px; border-top: var(--border-thin);
  display: flex; gap: 10px;
}
.chat-input {
  flex: 1; padding: 10px 14px;
  font-family: var(--font-mono); font-size: 13px;
  border: var(--border-thin); background: #fff; outline: none;
}
.chat-input:focus { box-shadow: 4px 4px 0 var(--gold); }

/* === FAKE NEWS === */
.verdict-badge {
  font-family: var(--font-display); font-weight: 700; font-size: 22px;
  padding: 10px 20px; text-align: center; letter-spacing: 2px;
  border: var(--border); margin-bottom: 12px;
}
.verdict-badge.fake { background: var(--red); color: #fff; }
.verdict-badge.real { background: var(--green); color: #fff; }
.confidence-big { font-family: var(--font-mono); font-size: 14px; margin-bottom: 16px; }
.flags-list { margin-bottom: 16px; }
.flag-item { font-family: var(--font-mono); font-size: 12px; padding: 6px 0; border-bottom: 1px solid #eee; }
.sentiment-row { display: flex; height: 12px; margin-bottom: 8px; border: 1px solid #000; overflow: hidden; }
.sent-bar.pos { background: var(--green); }
.sent-bar.neg { background: var(--red); }
.sent-bar.neu { background: #ccc; }

/* === MODEL INFO BAR === */
.model-info-bar {
  display: flex; gap: 20px; margin-top: 20px;
  padding: 12px 16px;
  border: var(--border); background: #0A0A0A; color: #fff;
  font-family: var(--font-mono); font-size: 11px;
  box-shadow: var(--shadow-sm);
}

/* === TICKETS === */
.ticket-card { border: var(--border-thin); padding: 14px; margin-bottom: 8px; background: #fff; }
.ticket-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; }
.ticket-id { font-family: var(--font-mono); font-size: 10px; font-weight: 700; opacity: 0.5; }
.ticket-status { font-family: var(--font-mono); font-size: 10px; font-weight: 700; padding: 2px 8px; }
.ticket-status.open { background: var(--cyan); }
.ticket-subject { font-family: var(--font-display); font-weight: 600; font-size: 14px; }
.ticket-meta { font-family: var(--font-mono); font-size: 10px; opacity: 0.5; margin-top: 4px; }
.template-btn {
  display: block; width: 100%; text-align: left;
  padding: 8px 12px; margin-bottom: 4px;
  font-family: var(--font-mono); font-size: 11px;
  background: #0A0A0A; color: #fff;
  border: none; cursor: pointer; transition: background 0.15s;
}
.template-btn:hover { background: #333; }

/* === EXPENSES === */
.expense-summary {
  font-family: var(--font-display); font-size: 16px;
  padding: 10px 0; border-bottom: 2px solid #000; margin-bottom: 12px;
}
.expense-row {
  display: grid; grid-template-columns: 1fr 120px 80px auto;
  align-items: center; gap: 10px;
  padding: 10px; border-bottom: 1px solid #eee;
  font-family: var(--font-mono); font-size: 12px;
}
.expense-row.anomaly { background: rgba(230,57,70,0.05); border-left: 3px solid var(--red); }
.expense-cat { font-size: 10px; opacity: 0.6; text-transform: uppercase; }
.expense-amt { font-weight: 700; text-align: right; }
.anomaly-flag { font-size: 10px; color: var(--red); font-weight: 700; }

/* === LANDING PAGE === */
.landing-page {
  position: relative; z-index: 2;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  min-height: 100vh;
  padding: 40px;
}
.landing-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 72px;
  letter-spacing: 10px;
  text-align: center;
  margin-bottom: 4px;
}
.landing-sub {
  font-family: var(--font-display);
  font-size: 15px;
  letter-spacing: 4px;
  text-transform: uppercase;
  text-align: center;
  opacity: 0.7;
  margin-bottom: 4px;
}
.landing-sub2 {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  text-align: center;
  opacity: 0.4;
  margin-bottom: 48px;
}
.portal-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  max-width: 900px;
  width: 100%;
}
.portal-card {
  border: var(--border);
  box-shadow: var(--shadow);
  background: var(--card-bg);
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.2, 0, 0, 1);
  overflow: hidden;
  position: relative;
}
.portal-card:hover {
  transform: translate(-6px, -6px);
  box-shadow: 12px 12px 0 #000;
}
.portal-card:active { transform: translate(2px, 2px); box-shadow: 2px 2px 0 #000; }
.portal-card-header {
  padding: 14px 20px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 24px;
  text-transform: uppercase;
  letter-spacing: 3px;
  border-bottom: var(--border-thin);
}
.portal-card-body {
  padding: 32px 24px;
  text-align: center;
}
.portal-icon { font-size: 56px; margin-bottom: 20px; opacity: 0.6; }
.portal-features {
  list-style: none; text-align: left; margin-bottom: 24px;
}
.portal-features li {
  font-family: var(--font-mono); font-size: 12px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 1px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(0,0,0,0.06);
  display: flex; align-items: center; gap: 10px;
}
.portal-features li::before {
  content: '■'; font-size: 8px;
}
.portal-card-footer {
  padding: 14px 24px;
  border-top: var(--border-thin);
  text-align: center;
}
.portal-btn {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 2px;
  padding: 10px 28px;
  border: var(--border-thin);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: all 0.15s;
}
.portal-btn:hover { transform: translate(-1px, -1px); box-shadow: 5px 5px 0 #000; }
.landing-footer {
  margin-top: 48px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  opacity: 0.3;
}

/* === LOGIN === */
.login-page {
  position: relative; z-index: 2;
  display: flex; align-items: center; justify-content: center;
  min-height: 100vh;
}
.login-card {
  border: var(--border);
  box-shadow: var(--shadow);
  background: var(--card-bg);
  width: 400px;
  overflow: hidden;
}
.login-header {
  padding: 16px 24px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
  text-transform: uppercase;
  letter-spacing: 2px;
  text-align: center;
  border-bottom: var(--border-thin);
}
.login-body { padding: 28px 24px; }
.login-body .field-label { margin-bottom: 6px; margin-top: 16px; }
.login-body .field-label:first-child { margin-top: 0; }
.login-footer {
  padding: 16px 24px;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 11px;
  border-top: 1px solid #eee;
}
.login-footer a {
  font-weight: 700;
  color: #000;
  text-decoration: underline;
  cursor: pointer;
}

/* === SCROLLBAR === */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #333; }

/* =============================================================
   ENTERPRISE EXTENSIONS  —  neo-brutalist primitives & modules
   All shadows 6px hard, borders 3px, 0 radius, bold palette.
   ============================================================= */

/* === UTILITIES === */
.mt-14 { margin-top: 14px; }
.mt-20 { margin-top: 20px; }
.hide-sm {}

/* === NAV: ICON BTNS, BADGES, USER === */
.nav-icon-btn {
  background: transparent; border: 2px solid #333; color: #fff;
  width: 36px; height: 36px; display: flex; align-items: center; justify-content: center;
  cursor: pointer; font-family: 'JetBrains Mono', monospace; font-size: 14px; font-weight: 700;
  transition: background .12s, transform .12s;
}
.nav-icon-btn:hover { background: #1a1a1a; transform: translate(-1px,-1px); }
.nav-icon-btn:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.nav-badge {
  position: absolute; top: -6px; right: -6px;
  background: var(--red); color: #fff;
  min-width: 18px; height: 18px; padding: 0 4px;
  display: flex; align-items: center; justify-content: center;
  font-family: 'JetBrains Mono', monospace; font-size: 10px; font-weight: 700;
  border: 2px solid #000;
}
.nav-user {
  display: flex; flex-direction: column; align-items: flex-end;
  border-left: 2px solid #333; padding-left: 12px; margin-left: 4px; line-height: 1.1;
}
.nav-user-name { font-family: 'JetBrains Mono', monospace; font-size: 12px; font-weight: 700; color: #fff; }
.nav-user-role { font-family: 'JetBrains Mono', monospace; font-size: 9px; color: var(--gold); letter-spacing: 1px; }

/* === DRAWER (notifications / side panel) === */
.drawer-scrim {
  position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 999;
  animation: fadeIn .18s ease;
}
.notif-drawer {
  position: fixed; top: 0; right: 0; bottom: 0; width: 380px; max-width: 94vw;
  background: var(--bg); border-left: 3px solid #000;
  box-shadow: -6px 0 0 rgba(0,0,0,0.08);
  z-index: 1000; display: flex; flex-direction: column;
}
.slide-in-right { animation: slideInRight .22s ease-out; }
@keyframes slideInRight { from { transform: translateX(24px); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
.drawer-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px; border-bottom: 3px solid #000; background: #111; color: #fff;
  font-family: 'Chakra Petch', sans-serif; font-size: 16px; font-weight: 700;
  letter-spacing: 1px;
}
.drawer-body { flex: 1; overflow-y: auto; padding: 8px; }
.drawer-footer { padding: 12px 18px; border-top: 3px solid #000; background: #fff; display: flex; justify-content: flex-end; }
.notif-item {
  display: grid; grid-template-columns: auto 1fr auto; gap: 10px;
  padding: 12px 14px; border: 2px solid #000; background: #fff;
  margin-bottom: 8px; cursor: pointer;
  transition: transform .12s, box-shadow .12s;
}
.notif-item:hover { transform: translate(-2px,-2px); box-shadow: 4px 4px 0 #000; }
.notif-dot { width: 10px; height: 10px; background: var(--gold); margin-top: 6px; border: 2px solid #000; }
.notif-item.read .notif-dot { background: #ccc; }
.notif-title { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 13px; color: #000; }
.notif-desc { font-family: 'JetBrains Mono', monospace; font-size: 11px; color: #555; margin-top: 2px; line-height: 1.45; }
.notif-time { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #999; white-space: nowrap; }
.icon-btn {
  background: transparent; border: 2px solid #000; color: #000;
  width: 30px; height: 30px; display: inline-flex; align-items: center; justify-content: center;
  cursor: pointer; font-size: 12px; font-weight: 700;
}
.icon-btn:hover { background: #000; color: #fff; }

/* === COMMAND PALETTE === */
.cmd-scrim {
  position: fixed; inset: 0; background: rgba(0,0,0,0.55); z-index: 1200;
  display: flex; align-items: flex-start; justify-content: center; padding-top: 12vh;
  animation: fadeIn .16s ease;
}
.cmd-palette {
  width: 640px; max-width: 92vw; background: #fff; border: 3px solid #000;
  box-shadow: 8px 8px 0 var(--gold);
}
.cmd-input-wrap {
  display: flex; align-items: center; gap: 10px; padding: 12px 16px;
  border-bottom: 3px solid #000;
}
.cmd-input {
  flex: 1; border: none; outline: none; background: transparent;
  font-family: 'JetBrains Mono', monospace; font-size: 16px; color: #000;
}
.cmd-kbd {
  font-family: 'JetBrains Mono', monospace; font-size: 10px;
  border: 2px solid #000; padding: 2px 6px; background: #f5f4ef;
}
.cmd-results { max-height: 360px; overflow-y: auto; }
.cmd-item {
  display: flex; justify-content: space-between; align-items: center;
  width: 100%; padding: 10px 16px; background: #fff; border: none;
  border-bottom: 1px solid #eee; cursor: pointer; text-align: left;
  font-family: 'JetBrains Mono', monospace;
}
.cmd-item:hover, .cmd-item:focus-visible { background: var(--gold); color: #000; outline: none; }
.cmd-item-label { font-size: 13px; font-weight: 700; }
.cmd-item-cat { font-size: 10px; color: #888; text-transform: uppercase; letter-spacing: 1px; }
.cmd-footer {
  display: flex; justify-content: space-between; padding: 8px 14px;
  border-top: 2px solid #000; background: #f5f4ef;
  font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #666;
}

/* === KPI CARDS === */
.kpi-card {
  background: #fff; border: 3px solid #000; padding: 14px;
  box-shadow: 6px 6px 0 var(--accent, var(--gold));
  display: flex; flex-direction: column; gap: 10px; position: relative;
  transition: transform .15s, box-shadow .15s;
}
.kpi-card:hover { transform: translate(-2px,-2px); box-shadow: 8px 8px 0 var(--accent, var(--gold)); }
.kpi-top { display: flex; justify-content: space-between; align-items: flex-start; }
.kpi-label {
  font-family: 'JetBrains Mono', monospace; font-size: 10px; letter-spacing: 1px;
  text-transform: uppercase; color: #555;
}
.kpi-value {
  font-family: 'Chakra Petch', sans-serif; font-size: 28px; font-weight: 700;
  color: #000; line-height: 1.1; margin-top: 4px;
}
.kpi-sparkline { width: 64px; height: 28px; }
.stat-trend {
  font-family: 'JetBrains Mono', monospace; font-size: 11px; font-weight: 700;
}

/* === DONUT === */
.donut-wrap { display: flex; align-items: center; gap: 20px; }
.donut-legend { display: flex; flex-direction: column; gap: 6px; flex: 1; }
.donut-legend-item { display: flex; align-items: center; gap: 8px; font-family: 'JetBrains Mono', monospace; font-size: 11px; }
.legend-dot { width: 10px; height: 10px; border: 2px solid #000; }
.legend-label { flex: 1; color: #333; }
.legend-val { font-weight: 700; color: #000; }

/* === HEATMAP === */
.heatmap-wrap {
  display: grid; grid-template-columns: auto 1fr; gap: 6px;
}
.heatmap-y-axis { display: flex; flex-direction: column; gap: 2px; padding-top: 2px; }
.heatmap-y-label { font-family: 'JetBrains Mono', monospace; font-size: 9px; color: #666; height: 14px; display: flex; align-items: center; }
.heatmap-grid { display: flex; flex-direction: column; gap: 2px; }
.heatmap-row { display: grid; grid-template-columns: repeat(24, 1fr); gap: 2px; }
.heatmap-cell { height: 14px; border: 1px solid #0001; cursor: pointer; }
.heatmap-cell:hover { outline: 2px solid #000; }
.heatmap-x-axis {
  grid-column: 2; display: grid; grid-template-columns: repeat(24, 1fr); gap: 2px; margin-top: 4px;
  font-family: 'JetBrains Mono', monospace; font-size: 8px; color: #888; text-align: center;
}

/* === TABS BAR === */
.tabs-bar {
  display: flex; gap: 6px; flex-wrap: wrap;
  border-bottom: 3px solid #000; padding-bottom: 0; margin-bottom: 18px;
}
.tab-pill {
  background: #fff; border: 3px solid #000; border-bottom: none;
  padding: 8px 16px; cursor: pointer;
  font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 13px;
  letter-spacing: 1px; color: #000;
  display: inline-flex; align-items: center; gap: 6px;
  position: relative; top: 3px;
  transition: background .12s, transform .12s;
  min-height: 36px;
}
.tab-pill:hover { background: #f5f4ef; }
.tab-pill.active { background: var(--gold); box-shadow: 0 -2px 0 #000 inset; }
.tab-pill:focus-visible { outline: 3px solid var(--cyan); outline-offset: 2px; }
.tab-pill-badge {
  background: #000; color: #fff; font-family: 'JetBrains Mono', monospace;
  font-size: 10px; padding: 2px 6px; font-weight: 700;
}

/* === SEGMENTED CONTROL === */
.segmented-control {
  display: inline-flex; border: 3px solid #000; background: #fff;
}
.seg-btn {
  background: transparent; border: none; border-right: 2px solid #000;
  padding: 8px 14px; cursor: pointer; min-height: 36px;
  font-family: 'JetBrains Mono', monospace; font-weight: 700; font-size: 11px;
  letter-spacing: 1px; color: #000;
}
.seg-btn:last-child { border-right: none; }
.seg-btn.active { background: var(--accent, var(--gold)); color: #000; }
.seg-btn:hover:not(.active) { background: #f2f0eb; }

/* === STATUS / BADGES / CHIPS / AVATARS === */
.status-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border: 2px solid #000; background: #fff;
  font-family: 'JetBrains Mono', monospace; font-size: 10px; font-weight: 700;
  letter-spacing: 1px; text-transform: uppercase;
}
.pill-dot { width: 8px; height: 8px; background: var(--gold); border: 1px solid #000; display: inline-block; }
.badge {
  display: inline-block; padding: 3px 8px; border: 2px solid #000;
  background: #fff; color: #000;
  font-family: 'JetBrains Mono', monospace; font-size: 10px; font-weight: 700;
  letter-spacing: 1px; text-transform: uppercase;
}
.badge.gold { background: var(--gold); }
.badge.red { background: var(--red); color: #fff; }
.badge.cyan { background: var(--cyan); color: #000; }
.badge.green { background: var(--green); color: #fff; }
.badge.gray { background: #e8e6df; color: #333; }
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border: 2px solid #000; background: #fff;
  color: #000;
  font-family: 'JetBrains Mono', monospace; font-size: 11px; font-weight: 700;
  letter-spacing: 0.5px;
  cursor: pointer;
  user-select: none;
  transition: transform 0.08s, box-shadow 0.08s;
}
.chip:hover { transform: translate(-1px, -1px); box-shadow: 2px 2px 0 #000; }
.chip:active { transform: translate(0, 0); box-shadow: 0 0 0 #000; }

/* Selected (active filter) — filled cyan */
.chip.selected {
  background: var(--cyan);
  color: #000;
  box-shadow: 2px 2px 0 #000;
}
/* Unselected (filter is OFF) — dimmed, hollow */
.chip:not(.selected) {
  background: #fff;
  color: #000;
  opacity: 0.55;
}
.chip:not(.selected):hover { opacity: 1; }

.chip-remove {
  background: transparent; border: none; cursor: pointer;
  font-size: 12px; line-height: 1; padding: 0; color: #000;
}
.chip-remove:hover { color: var(--red); }
.avatar {
  display: inline-flex; align-items: center; justify-content: center;
  border: 2px solid #000; color: #000; font-family: 'Chakra Petch', sans-serif;
  font-weight: 700; text-transform: uppercase;
}

/* === DATA TABLE === */
.data-table-wrap {
  border: 3px solid #000; background: #fff; overflow-x: auto;
  box-shadow: 4px 4px 0 #000;
}
.data-table { width: 100%; border-collapse: collapse; font-family: 'JetBrains Mono', monospace; font-size: 12px; }
.data-table thead th {
  background: #111; color: #fff; text-align: left; padding: 10px 12px;
  font-family: 'Chakra Petch', sans-serif; font-weight: 700;
  font-size: 12px; letter-spacing: 1px; text-transform: uppercase;
  border-bottom: 3px solid #000; cursor: pointer; user-select: none;
  white-space: nowrap;
}
.data-table thead th.sortable:hover { background: #222; }
.data-table tbody td {
  padding: 10px 12px; border-bottom: 1px solid #e8e6df; color: #222;
  vertical-align: middle;
}
.data-table tbody tr:hover { background: #fafaf5; }
.data-table tbody tr.selected { background: rgba(212,168,67,0.18); }
.data-table .col-check { width: 36px; text-align: center; }

/* === SEARCHBAR / FILTERS / TOOLBAR === */
.searchbar {
  display: inline-flex; align-items: center; gap: 8px;
  border: 3px solid #000; background: #fff; padding: 0 10px;
  min-height: 40px; min-width: 220px;
}
.search-icon { font-family: 'JetBrains Mono', monospace; font-size: 14px; font-weight: 700; color: #555; }
.search-input {
  border: none; outline: none; background: transparent; flex: 1;
  font-family: 'JetBrains Mono', monospace; font-size: 12px; color: #000;
  padding: 8px 0;
}
.search-clear {
  background: transparent; border: none; cursor: pointer;
  font-size: 12px; color: #666;
}
.filter-bar {
  display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px;
  padding: 12px; background: #fff; border: 3px solid #000;
  box-shadow: 4px 4px 0 #000; margin-bottom: 14px;
}
.filter-group { display: flex; flex-direction: column; gap: 4px; }
.filter-label {
  font-family: 'JetBrains Mono', monospace; font-size: 9px;
  letter-spacing: 1px; text-transform: uppercase; color: #555;
}
.filter-select {
  border: 2px solid #000; background: #fff; padding: 6px 10px;
  font-family: 'JetBrains Mono', monospace; font-size: 12px;
  min-height: 34px; cursor: pointer;
}
.filter-clear { align-self: flex-end; }
.toolbar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
  padding: 10px 12px; background: #fff; border: 3px solid #000;
  box-shadow: 4px 4px 0 #000; margin-bottom: 14px;
}
.bulk-bar {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  background: var(--gold); border: 3px solid #000; padding: 10px 14px;
  margin-bottom: 14px; box-shadow: 4px 4px 0 #000;
  font-family: 'JetBrains Mono', monospace; font-weight: 700; font-size: 12px;
}

/* === TOGGLES === */
.toggle-group { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.toggle-wrap {
  display: flex; align-items: center; gap: 10px; cursor: pointer;
  font-family: 'JetBrains Mono', monospace; font-size: 12px; color: #000;
  user-select: none;
}
.toggle-wrap input { position: absolute; opacity: 0; width: 0; height: 0; }
.toggle-switch {
  position: relative; width: 40px; height: 22px;
  background: #ddd; border: 2px solid #000; display: inline-block;
  transition: background .15s;
}
.toggle-knob {
  position: absolute; top: 1px; left: 1px; width: 16px; height: 16px;
  background: #fff; border: 2px solid #000;
  transition: transform .15s;
}
.toggle-wrap input:checked + .toggle-switch { background: var(--green); }
.toggle-wrap input:checked + .toggle-switch .toggle-knob { transform: translateX(18px); }
.toggle-wrap:focus-within .toggle-switch { outline: 3px solid var(--cyan); outline-offset: 2px; }
/* New: Toggle is a button now, ON state via .on class */
.toggle-switch.on { background: var(--green); }
.toggle-switch.on .toggle-knob { transform: translateX(18px); }
.toggle-switch { cursor: pointer; padding: 0; }
.toggle-label { flex: 1; }

/* === MODAL === */
.modal-scrim {
  /* Transparent backdrop — keep page fully visible behind the modal.
     Click on the (invisible) scrim still closes via onClick handler.
     The modal-shell is a CHILD of this flex container — flex centers it. */
  position: fixed; inset: 0; background: transparent; z-index: 1500;
  display: flex; align-items: center; justify-content: center; padding: 20px;
  pointer-events: auto;
  animation: fadeIn .16s ease;
}
.modal-shell {
  background: var(--bg); border: 3px solid #000;
  /* Stronger shadow so the modal stands out without a dark scrim */
  box-shadow: 10px 10px 0 #000, 0 0 0 3px var(--gold);
  width: 100%;
  max-height: calc(100vh - 40px);   /* leave room for the scrim's 20px padding */
  display: flex; flex-direction: column;
  position: relative;
  overflow: hidden;                  /* contain rounded corners and scrolling */
}
.modal-md { max-width: 620px; }
.modal-lg { max-width: 980px; }
.modal-sm { max-width: 440px; }
.modal-header { flex: 0 0 auto; }    /* never shrinks */
.modal-body   {
  flex: 1 1 auto;                    /* takes remaining space */
  overflow-y: auto;                  /* internal scroll for tall content */
  overflow-x: hidden;
  min-height: 0;                     /* required for flex+overflow */
}
.modal-footer {
  flex: 0 0 auto;                    /* sticky-pinned, always visible */
  border-top: 3px solid #000;
  background: var(--bg);
}

/* === Resume Screening: JD display === */
.resume-jd { display: flex; flex-direction: column; gap: 14px; }
.resume-jd-summary {
  font-family: 'Chakra Petch', sans-serif; font-size: 14px; line-height: 1.6;
  padding: 12px 14px; background: #fafaf5; border-left: 4px solid var(--red);
  border: 2px solid #000; box-shadow: 4px 4px 0 var(--red);
}
.resume-jd-strip {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px;
  background: #000; color: #fff; padding: 12px;
}
.strip-stat { text-align: center; }
.strip-v { font-family: 'Chakra Petch', sans-serif; font-size: 22px; font-weight: 700; color: var(--gold); }
.strip-l { font-family: 'JetBrains Mono', monospace; font-size: 9px; letter-spacing: 1px; opacity: 0.7; }
.resume-jd-section { padding: 12px; border: 2px solid #000; background: #fff; }
.resume-jd-h {
  font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 12px;
  letter-spacing: 1px; margin-bottom: 10px; padding-bottom: 6px;
  border-bottom: 2px solid var(--red);
}
.resume-jd-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.resume-jd-sub { font-family: 'JetBrains Mono', monospace; font-size: 10px; opacity: 0.6; margin-bottom: 6px; letter-spacing: 1px; text-transform: uppercase; }
.resume-jd-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.resume-jd-chip {
  display: inline-block; padding: 4px 10px; border: 2px solid #000;
  font-family: 'JetBrains Mono', monospace; font-size: 11px; font-weight: 700;
  background: #f5f4ef;
}
.resume-jd-chip.must { background: var(--red); color: #fff; border-color: #000; }
.resume-jd-chip.nice { background: var(--gold); }

/* === Resume: source effectiveness quality grid === */
.src-grid { display: flex; flex-direction: column; gap: 6px; margin-top: 4px; }
.src-row {
  display: grid;
  grid-template-columns: 100px 64px 1fr 36px 44px;
  gap: 8px; align-items: center;
  padding: 6px 8px; border: 2px solid #000; background: #fff;
  font-family: 'JetBrains Mono', monospace; font-size: 11px;
}
.src-name { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; }
.src-dot { width: 10px; height: 10px; border: 1px solid #000; flex: 0 0 auto; }
.src-apps { font-weight: 700; text-align: right; }
.src-apps-l { font-weight: 400; opacity: 0.55; font-size: 10px; }
.src-bar-wrap { display: flex; align-items: center; gap: 6px; }
.src-bar {
  flex: 1; height: 10px; border: 2px solid #000; background: #f5f4ef; position: relative;
}
.src-bar-fill { height: 100%; background: var(--green); transition: width .3s ease; }
.src-bar-pct { font-size: 10px; font-weight: 700; min-width: 32px; text-align: right; }
.src-score {
  width: 36px; height: 30px; display: flex; align-items: center; justify-content: center;
  border: 2px solid #000; font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 14px;
  color: #000;
}
.src-t2h { text-align: right; opacity: 0.7; }
.src-callouts {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 8px; margin-top: 14px;
}
.src-callout {
  display: flex; gap: 8px; align-items: center;
  padding: 8px 10px; background: #000; color: #fff;
  border: 2px solid #000;
}
.src-callout-icon {
  font-family: 'Chakra Petch', sans-serif; font-size: 18px; color: var(--gold);
}
.src-callout-l {
  font-family: 'JetBrains Mono', monospace; font-size: 9px;
  letter-spacing: 1px; opacity: 0.55;
}
.src-callout-v {
  font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 13px;
}

/* === Resume: pipeline mini-stats on job cards === */
.pipeline-mini { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; padding: 8px; background: #f5f4ef; border: 2px solid #000; margin-top: 10px; }
.pmini { text-align: center; }
.pmini-v { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 18px; }
.pmini-l { font-family: 'JetBrains Mono', monospace; font-size: 8px; opacity: 0.6; letter-spacing: 1px; }

/* === Resume: job pills (jobs picker for candidates/settings) === */
.job-pills { display: flex; flex-wrap: wrap; gap: 6px; padding: 8px 0; }
.job-pill {
  background: #fff; border: 2px solid #000; padding: 8px 12px;
  cursor: pointer; display: flex; flex-direction: column; gap: 2px;
  font-family: 'JetBrains Mono', monospace; min-width: 160px; text-align: left;
}
.job-pill:hover { background: #fafaf5; transform: translate(-1px, -1px); box-shadow: 3px 3px 0 #000; }
.job-pill.active { background: var(--red); color: #fff; }
.jp-title { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 13px; }
.jp-meta { font-size: 10px; opacity: 0.7; }
.job-pill.active .jp-meta { opacity: 0.85; color: #fff; }

/* === Resume: candidate cards === */
.candidate-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; padding-top: 10px; }
.candidate-card {
  background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 #000;
  padding: 12px; display: flex; flex-direction: column; gap: 10px; cursor: pointer;
  animation: slideUp .2s ease-out;
  transition: transform .12s, box-shadow .12s;
}
.candidate-card:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--red); }
.candidate-card.comparing { border-color: var(--red); box-shadow: 4px 4px 0 var(--red); background: #fff8f8; }
.cc-top { display: flex; align-items: center; gap: 10px; }
.cc-name { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 14px; color: #000; }
.cc-meta { font-family: 'JetBrains Mono', monospace; font-size: 10px; opacity: 0.6; }
.cc-score { width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 18px; border: 2px solid #000; color: #000; }
.cc-skills { display: flex; flex-wrap: wrap; gap: 4px; }
.cc-foot { display: flex; gap: 8px; flex-wrap: wrap; font-family: 'JetBrains Mono', monospace; font-size: 10px; opacity: 0.7; align-items: center; }
.cc-status { padding: 2px 8px; border: 2px solid #000; font-weight: 700; }
.cc-status.status-shortlisted { background: var(--green); color: #000; }
.cc-status.status-rejected    { background: #888; color: #fff; }
.cc-status.status-interview   { background: #d946ef; color: #fff; }
.cc-status.status-offer       { background: var(--red); color: #fff; }
.cc-status.status-recruited   { background: #000; color: var(--gold); }
.cc-status.status-processing  { background: var(--cyan); color: #000; }

/* === Resume: candidate detail header === */
.cand-header { display: grid; grid-template-columns: auto 1fr auto; gap: 16px; padding-bottom: 14px; border-bottom: 3px solid #000; align-items: center; }
.cand-meta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4px; font-family: 'JetBrains Mono', monospace; font-size: 11px; opacity: 0.75; }

/* === Resume: dimension breakdown grid === */
.dim-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 8px; }
.dim-card { padding: 10px; border: 2px solid #000; background: #fff; }
.dim-label { font-family: 'JetBrains Mono', monospace; font-size: 9px; opacity: 0.6; letter-spacing: 1px; }
.dim-value { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 22px; margin: 2px 0 6px; }

/* === Resume: timeline === */
.resume-timeline { display: flex; flex-direction: column; gap: 0; padding-left: 10px; }
.rt-step { display: grid; grid-template-columns: 32px 1fr; gap: 10px; padding: 8px 0; position: relative; }
.rt-step:not(:last-child)::before {
  content: ''; position: absolute; left: 16px; top: 32px; bottom: -8px; width: 2px; background: #ddd;
}
.rt-step.done:not(:last-child)::before { background: var(--green); }
.rt-node { width: 28px; height: 28px; border: 2px solid #000; display: flex; align-items: center; justify-content: center; background: #fff; font-family: 'JetBrains Mono', monospace; font-weight: 700; font-size: 11px; }
.rt-step.done .rt-node { background: var(--green); color: #000; }
.rt-step.current .rt-node { background: var(--gold); }
.rt-title { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 12px; }
.rt-time { font-family: 'JetBrains Mono', monospace; font-size: 10px; opacity: 0.55; margin-top: 2px; }

/* === Resume: work experience list === */
.work-list { display: flex; flex-direction: column; gap: 10px; }
.work-item { padding: 10px 12px; border: 2px solid #000; background: #fff; }
.work-title { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 13px; }
.work-company { font-family: 'JetBrains Mono', monospace; font-weight: 400; font-size: 12px; opacity: 0.7; }
.work-meta { font-family: 'JetBrains Mono', monospace; font-size: 10px; opacity: 0.6; margin: 2px 0 6px; }
.work-bullets { font-family: 'JetBrains Mono', monospace; font-size: 11px; line-height: 1.5; padding-left: 18px; }
.work-tech { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }

/* === Resume: notes === */
.notes-list { display: flex; flex-direction: column; gap: 8px; }
.note-item { padding: 10px 12px; background: #fafaf5; border-left: 3px solid var(--gold); }
.note-text { font-family: 'JetBrains Mono', monospace; font-size: 12px; line-height: 1.5; }
.note-meta { font-family: 'JetBrains Mono', monospace; font-size: 10px; opacity: 0.5; margin-top: 4px; }

/* === Resume: compare board === */
.compare-board { display: flex; flex-direction: column; gap: 4px; }
.compare-header, .compare-row { display: grid; grid-template-columns: 160px repeat(var(--n, 3), 1fr); gap: 8px; }
.compare-header { padding: 12px 0; border-bottom: 3px solid #000; align-items: center; }
.compare-cand-cell { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px; border: 2px solid #000; background: #fff; }
.compare-cand-name { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 13px; text-align: center; }
.compare-cand-score { width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 16px; border: 2px solid #000; color: #000; }
.compare-row { padding: 8px 0; border-bottom: 1px solid #eee; align-items: center; }
.compare-label { font-family: 'JetBrains Mono', monospace; font-size: 11px; font-weight: 700; opacity: 0.7; }
.compare-cell { font-family: 'JetBrains Mono', monospace; font-size: 12px; padding: 4px 8px; }

/* === Resume: skill matrix === */
.skill-matrix { display: flex; flex-direction: column; gap: 2px; }
.sm-row { display: grid; grid-template-columns: 1fr repeat(var(--n, 3), 40px); gap: 6px; align-items: center; padding: 4px 0; border-bottom: 1px dashed #ddd; }
.sm-skill { font-family: 'JetBrains Mono', monospace; font-size: 12px; }
.sm-cell { text-align: center; font-family: 'JetBrains Mono', monospace; font-weight: 700; opacity: 0.3; }
.sm-cell.has { background: var(--green); color: #000; opacity: 1; border: 2px solid #000; }

/* === Quill RichEditor — restyled to match brutal theme === */
.rich-editor-wrap {
  border: 3px solid #000;
  background: #fff;
  box-shadow: 4px 4px 0 #000;
  margin-top: 6px;
}
.rich-editor-wrap .ql-toolbar.ql-snow {
  border: none !important;
  border-bottom: 2px solid #000 !important;
  background: #f5f4ef;
  padding: 6px 8px;
}
.rich-editor-wrap .ql-container.ql-snow {
  border: none !important;
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  line-height: 1.6;
}
.rich-editor-wrap .ql-editor {
  min-height: 280px;
  background: #fff;
  color: #111;
  padding: 14px 16px;
}
.rich-editor-wrap .ql-editor.ql-blank::before {
  font-style: normal;
  color: #999;
  font-family: 'JetBrains Mono', monospace;
}
/* Brutal-theme tweak: square buttons, sharp focus */
.rich-editor-wrap .ql-snow .ql-picker { color: #000; }
.rich-editor-wrap .ql-snow .ql-stroke { stroke: #000; }
.rich-editor-wrap .ql-snow .ql-fill { fill: #000; }
.rich-editor-wrap .ql-snow.ql-toolbar button:hover,
.rich-editor-wrap .ql-snow.ql-toolbar button.ql-active {
  background: var(--gold);
  border-radius: 0;
}
.rich-editor-wrap .ql-snow.ql-toolbar button:hover .ql-stroke { stroke: #000; }
.modal-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 18px; border-bottom: 3px solid #000; background: #111; color: #fff;
  font-family: 'Chakra Petch', sans-serif; font-size: 16px; font-weight: 700; letter-spacing: 1px;
}
.modal-body { padding: 18px; overflow-y: auto; flex: 1; }
.modal-footer {
  padding: 12px 18px; border-top: 3px solid #000; background: #fff;
  display: flex; justify-content: flex-end; gap: 10px;
}

/* === EMPTY STATE / SKELETON === */
.empty-state {
  padding: 36px 20px; text-align: center;
  border: 3px dashed #000; background: #fafaf5;
  font-family: 'JetBrains Mono', monospace; font-size: 12px; color: #666;
}
.empty-state.enhanced { padding: 48px 20px; }
.empty-icon { font-size: 40px; margin-bottom: 10px; }
.empty-title {
  font-family: 'Chakra Petch', sans-serif; font-size: 20px;
  font-weight: 700; color: #000; margin: 8px 0 4px;
  letter-spacing: 1px; text-transform: uppercase;
}
.skeleton {
  background: linear-gradient(90deg, #e8e6df 25%, #f2f0eb 50%, #e8e6df 75%);
  background-size: 200% 100%; animation: skeletonPulse 1.2s ease-in-out infinite;
  border: 2px solid #dedbd1;
}
@keyframes skeletonPulse { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* === PAGINATION === */
.pagination { display: flex; gap: 4px; align-items: center; padding: 12px 0; }
.page-btn {
  background: #fff; border: 2px solid #000; padding: 6px 12px;
  font-family: 'JetBrains Mono', monospace; font-size: 11px; font-weight: 700;
  cursor: pointer; min-height: 32px; min-width: 32px;
}
.page-btn:hover:not(:disabled) { background: var(--gold); }
.page-btn.active { background: #000; color: #fff; }
.page-btn:disabled { opacity: 0.4; cursor: not-allowed; }
.page-ellipsis { font-family: 'JetBrains Mono', monospace; padding: 0 4px; color: #666; }

/* === KANBAN === */
.kanban-board {
  display: grid; grid-template-columns: repeat(6, minmax(220px, 1fr)); gap: 12px;
  overflow-x: auto; padding-bottom: 6px;
}
.kanban-col {
  background: #fff; border: 3px solid #000;
  box-shadow: 4px 4px 0 #000;
  display: flex; flex-direction: column;
  min-height: 300px;
}
.kanban-col-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 12px; border-bottom: 3px solid #000;
  background: var(--col-accent, var(--gold)); color: #000;
  font-family: 'Chakra Petch', sans-serif; font-weight: 700;
  letter-spacing: 1px; font-size: 12px; text-transform: uppercase;
}
.kanban-col-title { font-weight: 700; }
.kanban-col-count {
  background: #000; color: #fff; padding: 2px 8px;
  font-family: 'JetBrains Mono', monospace; font-size: 10px; font-weight: 700;
}
.kanban-col-body {
  flex: 1; padding: 8px; display: flex; flex-direction: column; gap: 8px;
}
.kanban-card {
  background: #fff; border: 2px solid #000; padding: 10px;
  box-shadow: 3px 3px 0 #000;
  cursor: pointer; animation: slideUp .2s ease-out;
  transition: transform .12s, box-shadow .12s;
}
.kanban-card:hover { transform: translate(-1px,-1px); box-shadow: 4px 4px 0 var(--gold); }
.kanban-empty {
  padding: 20px; text-align: center; font-family: 'JetBrains Mono', monospace;
  font-size: 10px; color: #aaa; border: 2px dashed #ccc;
}
@keyframes slideUp { from { transform: translateY(6px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

/* === FUNNEL === */
.funnel-chart { display: flex; flex-direction: column; gap: 12px; padding: 4px 0; }
.funnel-stage { display: flex; flex-direction: column; gap: 4px; }
.funnel-bar-wrap {
  position: relative; background: #f5f4ef; border: 2px solid #000;
  height: 32px; display: flex; align-items: center;
}
.funnel-bar { height: 100%; border-right: 2px solid #000; transition: width .4s ease; }
.funnel-value {
  position: absolute; right: 10px; top: 50%; transform: translateY(-50%);
  font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 13px; color: #000;
}
.funnel-label {
  font-family: 'JetBrains Mono', monospace; font-size: 11px; font-weight: 700;
  color: #333; letter-spacing: 1px; text-transform: uppercase;
}
.funnel-drop {
  font-family: 'JetBrains Mono', monospace; font-size: 10px; color: var(--red);
  padding-left: 6px;
}

/* === RADAR === */
.radar-chart { display: block; margin: 0 auto; }

/* === CITY MAP === */
.map-mock {
  background: #0e0e0e; border: 3px solid #000;
  box-shadow: 6px 6px 0 var(--cyan); padding: 10px;
  position: relative; overflow: hidden;
}
.map-title {
  font-family: 'Chakra Petch', sans-serif; font-weight: 700;
  font-size: 12px; letter-spacing: 2px; color: var(--gold);
  text-transform: uppercase; margin-bottom: 8px;
}
.map-canvas {
  position: relative; width: 100%; aspect-ratio: 1.4;
  background: repeating-linear-gradient(0deg, #161616 0 19px, #1d1d1d 19px 20px),
              repeating-linear-gradient(90deg, #161616 0 19px, #1d1d1d 19px 20px);
  background-size: 20px 20px;
}
.map-canvas svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.map-legend {
  display: flex; gap: 12px; flex-wrap: wrap; margin-top: 10px;
  font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #ddd;
}
.map-legend span { display: inline-flex; align-items: center; gap: 5px; }
.map-legend .dot { width: 9px; height: 9px; display: inline-block; border: 1px solid #000; }
.pin-pulse {
  animation: pinPulse 1.6s ease-in-out infinite;
  transform-origin: center; transform-box: fill-box;
}
@keyframes pinPulse { 0%,100% { opacity: 0.25; transform: scale(1); } 50% { opacity: 0.8; transform: scale(1.4); } }

/* === STATUS TIMELINE === */
.status-timeline { display: flex; flex-direction: column; gap: 0; }
.status-step {
  display: grid; grid-template-columns: 36px 1fr; gap: 12px;
  position: relative; padding: 8px 0;
}
.status-node {
  width: 32px; height: 32px; border: 2px solid #000;
  display: flex; align-items: center; justify-content: center;
  background: #fff; font-family: 'JetBrains Mono', monospace;
  font-weight: 700; font-size: 12px; color: #000;
  box-shadow: 3px 3px 0 #000;
}
.status-step.done .status-node { background: var(--green); color: #fff; }
.status-step.active .status-node { background: var(--gold); }
.status-label { padding-top: 4px; }
.status-title { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 13px; color: #000; }
.status-time { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #888; margin-top: 2px; }
.status-connector {
  position: absolute; left: 17px; top: 40px; bottom: -4px;
  width: 2px; background: #000; z-index: 0;
}
.status-step.done + .status-step .status-connector { background: var(--green); }

/* === TOAST === */
.toast-host {
  position: fixed; top: 80px; right: 20px; z-index: 3000;
  display: flex; flex-direction: column; gap: 8px;
}
.toast {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; min-width: 260px; max-width: 380px;
  background: #fff; border: 3px solid #000;
  box-shadow: 5px 5px 0 #000; animation: slideInRight .22s ease-out;
  font-family: 'JetBrains Mono', monospace; font-size: 12px; color: #000;
}
.toast-icon {
  font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 18px;
  color: var(--gold); line-height: 1;
}
.toast.success { border-left: 8px solid var(--green); }
.toast.success .toast-icon { color: var(--green); }
.toast.error { border-left: 8px solid var(--red); }
.toast.error .toast-icon { color: var(--red); }
.toast.warn { border-left: 8px solid var(--gold); }
.toast.info { border-left: 8px solid var(--cyan); }
.toast.info .toast-icon { color: var(--cyan); }

/* === PROGRESS RING === */
.progress-ring-wrap {
  display: inline-flex; flex-direction: column; align-items: center; gap: 6px;
}
.ring-label {
  font-family: 'JetBrains Mono', monospace; font-size: 10px;
  letter-spacing: 1px; text-transform: uppercase; color: #555;
}

/* === ALERT TICKER === */
.alert-ticker {
  display: flex; align-items: stretch;
  border: 3px solid #000; background: #111; color: #fff;
  box-shadow: 4px 4px 0 var(--red); overflow: hidden;
}
.ticker-label {
  background: var(--red); color: #fff; padding: 8px 12px;
  font-family: 'JetBrains Mono', monospace; font-size: 11px; font-weight: 700;
  letter-spacing: 1px; border-right: 3px solid #000; white-space: nowrap;
  display: flex; align-items: center; gap: 6px;
}
.ticker-track { flex: 1; overflow: hidden; position: relative; display: flex; align-items: center; padding: 6px 10px; }
.ticker-content { display: inline-flex; gap: 24px; white-space: nowrap; animation: tickerScroll 30s linear infinite; }
.ticker-item { display: inline-flex; align-items: center; gap: 8px; font-family: 'JetBrains Mono', monospace; font-size: 12px; color: #eee; }
.ticker-tag { padding: 2px 8px; border: 2px solid #000; font-size: 10px; font-weight: 700; color: #000; }
@keyframes tickerScroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* === SUBPAGE ACTIONS === */
.subpage-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 10px; }

/* === CONFIDENCE BAR === */
.confidence-bar {
  position: relative; height: 10px; width: 100%;
  background: #f0efec; border: 2px solid #000;
}
.confidence-bar > div { height: 100%; transition: width .35s ease; }
.confidence-num {
  font-family: 'JetBrains Mono', monospace; font-size: 10px;
  font-weight: 700; margin-left: 8px; color: #333;
}

/* === PROGRESS LARGE === */
.progress-wrap { display: flex; align-items: center; gap: 10px; }
.progress-bar-lg {
  flex: 1; height: 14px; background: #f0efec;
  border: 2px solid #000;
}
.progress-fill-lg { height: 100%; background: var(--gold); transition: width .4s ease; }
.progress-pct {
  font-family: 'JetBrains Mono', monospace; font-size: 11px;
  font-weight: 700; min-width: 42px; text-align: right;
}

/* === SUMMARY / KPI GRIDS === */
.summary-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px; margin-bottom: 16px;
}
.kpi-grid-4 {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 16px;
}
.grid-3-col {
  display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px;
}
@media (max-width: 1100px) { .kpi-grid-4 { grid-template-columns: repeat(2, 1fr); } .grid-3-col { grid-template-columns: 1fr; } }

/* === INLINE FIELDS === */
.inline-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 600px) { .inline-fields { grid-template-columns: 1fr; } }

/* === ENTITY ROW ENHANCED === */
.entity-row.enhanced {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px;
  padding: 10px 12px; border: 2px solid #000; background: #fff; margin-bottom: 8px;
}
.entity-row.enhanced:hover { background: #fafaf5; }
.pii-row { display: flex; flex-wrap: wrap; gap: 6px; }
.pii-chip {
  display: inline-flex; gap: 6px; padding: 4px 8px;
  background: #fff3e0; border: 2px solid var(--red);
  font-family: 'JetBrains Mono', monospace; font-size: 11px;
}
.warning-banner {
  display: flex; gap: 10px; padding: 10px 12px;
  background: #fff3e0; border: 3px solid var(--red);
  box-shadow: 4px 4px 0 var(--red);
  font-family: 'JetBrains Mono', monospace; font-size: 12px; color: #000;
  margin-bottom: 14px;
}
.action-row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.small-meta { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #666; }

/* === FILE LIST (intake) === */
.file-list { display: flex; flex-direction: column; gap: 6px; margin-top: 10px; }
.file-item {
  display: grid; grid-template-columns: auto 1fr auto; gap: 10px; align-items: center;
  padding: 8px 10px; border: 2px solid #000; background: #fff;
  font-family: 'JetBrains Mono', monospace; font-size: 11px;
}
.file-name { color: #000; font-weight: 700; word-break: break-all; }
.file-meta { color: #666; font-size: 10px; margin-top: 2px; }

/* === DOC LIBRARY === */
.doc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.doc-card {
  background: #fff; border: 3px solid #000; padding: 0;
  box-shadow: 4px 4px 0 #000; cursor: pointer;
  transition: transform .12s, box-shadow .12s;
  display: flex; flex-direction: column;
}
.doc-card:hover { transform: translate(-2px,-2px); box-shadow: 6px 6px 0 var(--gold); }
.doc-thumb {
  aspect-ratio: 1.2; background: #f5f4ef; border-bottom: 3px solid #000;
  display: flex; align-items: center; justify-content: center;
  font-size: 40px; color: #aaa; position: relative;
}
.doc-type-badge {
  position: absolute; top: 6px; left: 6px; background: #000; color: #fff;
  padding: 2px 6px; font-family: 'JetBrains Mono', monospace; font-size: 9px;
}
.doc-info { padding: 10px; display: flex; flex-direction: column; gap: 4px; }
.doc-title {
  font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 13px;
  color: #000; line-height: 1.2;
}
.doc-meta { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #666; }
.doc-tags { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 4px; }
.doc-footer {
  padding: 8px 10px; border-top: 2px solid #eee;
  display: flex; justify-content: space-between; align-items: center;
  font-family: 'JetBrains Mono', monospace; font-size: 10px;
}

/* === TEMPLATE GRID === */
.template-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.template-card {
  background: #fff; border: 3px solid #000; padding: 14px;
  box-shadow: 4px 4px 0 #000;
  display: flex; gap: 12px; align-items: flex-start;
}
/* Type-card variant: full-row layout, cleaner gaps, no overlapping action buttons */
.template-card.type-card {
  align-items: center; gap: 14px;
  transition: transform .12s, box-shadow .12s;
}
.template-card.type-card:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--gold);
}
.template-card.type-card .template-meta { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.template-icon {
  width: 42px; height: 42px; background: var(--gold); border: 2px solid #000;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Chakra Petch', sans-serif; font-size: 18px; font-weight: 700;
}

/* === LEADERBOARD / SLA === */
.leaderboard { display: flex; flex-direction: column; gap: 6px; }
.leaderboard-row {
  display: grid; grid-template-columns: 28px 1fr auto; gap: 10px; align-items: center;
  padding: 8px 10px; background: #fff; border: 2px solid #000;
}
.sla-list { display: flex; flex-direction: column; gap: 6px; }
.sla-row {
  display: grid; grid-template-columns: 1fr auto auto; gap: 10px; align-items: center;
  padding: 8px 10px; background: #fff; border: 2px solid #000;
  font-family: 'JetBrains Mono', monospace; font-size: 12px;
}

/* === JOBS === */
.jobs-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.job-card {
  background: #fff; border: 3px solid #000; padding: 14px;
  box-shadow: 4px 4px 0 #000;
  display: flex; flex-direction: column; gap: 10px;
  transition: transform .12s, box-shadow .12s;
}
.job-card:hover { transform: translate(-2px,-2px); box-shadow: 6px 6px 0 var(--cyan); }
.job-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.job-title { font-family: 'Chakra Petch', sans-serif; font-size: 16px; font-weight: 700; color: #000; }
.job-stats { display: flex; gap: 12px; flex-wrap: wrap; font-family: 'JetBrains Mono', monospace; font-size: 11px; color: #555; }
.job-progress {}
.job-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 4px; }

/* === PIPELINE / CANDIDATE === */
.pipeline-toolbar {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px;
  margin-bottom: 12px;
}
.candidate-split {
  display: grid; grid-template-columns: 340px 1fr; gap: 14px;
}
@media (max-width: 1100px) { .candidate-split { grid-template-columns: 1fr; } }
.candidate-list-pane {
  background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 #000;
  max-height: 720px; overflow-y: auto;
}
.candidate-detail-pane {
  background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 var(--gold);
  padding: 16px;
}
.candidate-card-enhanced {
  display: grid; grid-template-columns: 1fr auto; gap: 10px; align-items: center;
  padding: 10px 12px; border-bottom: 2px solid #000; cursor: pointer;
  transition: background .12s;
}
.candidate-card-enhanced:hover { background: #fafaf5; }
.candidate-card-enhanced.selected { background: var(--gold); }
.candidate-score-big {
  font-family: 'Chakra Petch', sans-serif; font-size: 22px; font-weight: 700;
  color: #000; line-height: 1;
}
.candidate-detail {
  display: flex; flex-direction: column; gap: 16px;
}
.detail-header {
  display: grid; grid-template-columns: auto 1fr auto; gap: 14px; align-items: center;
  padding-bottom: 12px; border-bottom: 3px solid #000;
}
.detail-role { font-family: 'JetBrains Mono', monospace; font-size: 12px; color: #555; }
.detail-meta-row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 6px; }
.detail-section { padding-top: 10px; border-top: 2px solid #eee; }
.detail-section-title {
  font-family: 'Chakra Petch', sans-serif; font-size: 13px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 1px; margin-bottom: 10px;
}
.analysis-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; }
.analysis-card {
  background: #f5f4ef; border: 2px solid #000; padding: 10px;
  display: flex; gap: 10px; align-items: flex-start;
}
.ac-icon {
  width: 32px; height: 32px; background: #fff; border: 2px solid #000;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Chakra Petch', sans-serif; font-weight: 700;
}
.skill-row {
  display: grid; grid-template-columns: 140px 1fr auto; gap: 10px; align-items: center;
  margin-bottom: 6px; font-family: 'JetBrains Mono', monospace; font-size: 12px;
}
.weight-row {
  display: grid; grid-template-columns: 140px 1fr 40px; gap: 10px; align-items: center;
  margin-bottom: 8px;
}
.weight-label {
  font-family: 'JetBrains Mono', monospace; font-size: 11px;
  letter-spacing: 1px; text-transform: uppercase; color: #333;
}
.brutal-slider {
  -webkit-appearance: none; appearance: none;
  width: 100%; height: 6px; background: #000; border: none; cursor: pointer;
}
.brutal-slider::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 18px; height: 18px; background: var(--gold); border: 2px solid #000;
  cursor: pointer;
}
.brutal-slider::-moz-range-thumb {
  width: 18px; height: 18px; background: var(--gold); border: 2px solid #000;
  cursor: pointer;
}
.weight-total {
  font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 14px;
  margin-top: 12px; padding: 8px 12px; background: #000; color: #fff;
  display: inline-block; letter-spacing: 1px;
}

/* === TRAFFIC LIVE === */
.live-top-bar {
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap;
  gap: 12px; padding: 10px 14px; background: #0e0e0e; color: #fff;
  border: 3px solid #000; box-shadow: 4px 4px 0 var(--red);
  margin-bottom: 14px;
}
.live-controls { display: flex; gap: 10px; flex-wrap: wrap; }
.pulse-dot {
  width: 10px; height: 10px; background: var(--red); border: 1px solid #000;
  display: inline-block; animation: pulseLive 1.2s ease-in-out infinite;
}
@keyframes pulseLive { 0%,100% { opacity: 1; } 50% { opacity: 0.3; } }
.live-indicator {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: 'JetBrains Mono', monospace; font-size: 12px; font-weight: 700;
  letter-spacing: 1px; color: #fff;
}

/* === CAMERA GRID === */
.camera-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px;
  margin-bottom: 14px;
}
@media (max-width: 900px) { .camera-grid { grid-template-columns: 1fr; } }
.camera-tile {
  position: relative; background: #0a0a0a; border: 3px solid #000;
  aspect-ratio: 16 / 10; overflow: hidden;
  box-shadow: 4px 4px 0 #000;
}
.cam-feed {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, #1a1a1a 0%, #0a0a0a 100%);
}
.cam-noise {
  position: absolute; inset: 0; opacity: 0.15;
  background-image: repeating-linear-gradient(0deg, rgba(255,255,255,0.1) 0, rgba(255,255,255,0.1) 1px, transparent 1px, transparent 3px);
  animation: camNoise 0.3s steps(3) infinite;
}
@keyframes camNoise { 0% { transform: translateY(0); } 100% { transform: translateY(-2px); } }
.cam-scan-line {
  position: absolute; left: 0; right: 0; height: 2px;
  background: rgba(91,192,235,0.4);
  animation: scanLine 3s linear infinite;
}
@keyframes scanLine { 0% { top: 0; } 100% { top: 100%; } }
.cam-overlay-tl, .cam-overlay-tr, .cam-overlay-bl, .cam-overlay-br {
  position: absolute; padding: 4px 8px;
  font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #fff;
  text-shadow: 1px 1px 0 #000; z-index: 2;
}
.cam-overlay-tl { top: 6px; left: 6px; }
.cam-overlay-tr { top: 6px; right: 6px; }
.cam-overlay-bl { bottom: 6px; left: 6px; }
.cam-overlay-br { bottom: 6px; right: 6px; }
.cam-rec {
  display: inline-flex; align-items: center; gap: 4px;
  color: var(--red); font-weight: 700;
}
.cam-id { color: var(--gold); font-weight: 700; }
.cam-detection-boxes { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.cam-box {
  position: absolute; border: 2px solid var(--gold);
  animation: boxPulse 1.4s ease-in-out infinite;
}
@keyframes boxPulse { 0%,100% { box-shadow: 0 0 0 0 rgba(212,168,67,0.6); } 50% { box-shadow: 0 0 0 6px rgba(212,168,67,0.0); } }
.cam-box-label {
  position: absolute; top: -20px; left: 0; background: var(--gold);
  padding: 2px 5px; font-family: 'JetBrains Mono', monospace;
  font-size: 9px; font-weight: 700; color: #000; white-space: nowrap;
}

/* === INCIDENTS === */
.incident-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; }
.incident-card {
  background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 var(--red);
  display: flex; flex-direction: column;
}
.incident-video-thumb {
  position: relative; aspect-ratio: 16 / 10; background: #0a0a0a;
  border-bottom: 3px solid #000; overflow: hidden;
}
.vt-cam-label {
  position: absolute; top: 6px; left: 8px; color: var(--gold);
  font-family: 'JetBrains Mono', monospace; font-size: 10px; font-weight: 700;
  text-shadow: 1px 1px 0 #000;
}
.vt-play {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
  width: 44px; height: 44px; background: rgba(0,0,0,0.6);
  border: 2px solid #fff; color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; cursor: pointer;
}
.vt-duration {
  position: absolute; bottom: 6px; right: 8px;
  background: rgba(0,0,0,0.7); color: #fff;
  padding: 2px 6px; font-family: 'JetBrains Mono', monospace; font-size: 10px;
}
.incident-info { padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; }
.incident-top { display: flex; justify-content: space-between; align-items: center; }
.incident-id { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #888; }
.incident-type { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 14px; color: #000; }
.incident-meta { display: flex; gap: 8px; flex-wrap: wrap; font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #555; }
.incident-plate {
  background: #000; color: var(--gold); padding: 3px 8px;
  font-family: 'JetBrains Mono', monospace; font-size: 12px; font-weight: 700;
  letter-spacing: 1px; display: inline-block; border: 2px solid #000;
}
.incident-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 4px; }

/* === OFFENDER === */
.offender-list { display: flex; flex-direction: column; gap: 6px; }
.offender-row {
  display: grid; grid-template-columns: 36px 1fr 1fr auto; gap: 10px; align-items: center;
  padding: 10px 12px; background: #fff; border: 2px solid #000;
}
.offender-rank {
  font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 18px;
  color: var(--red); text-align: center;
}
.offender-plate {
  background: #000; color: var(--gold); padding: 3px 8px;
  font-family: 'JetBrains Mono', monospace; font-size: 12px; font-weight: 700;
  display: inline-block;
}
.offender-driver { font-family: 'JetBrains Mono', monospace; font-size: 12px; color: #222; }
.offender-stats {
  font-family: 'JetBrains Mono', monospace; font-size: 11px; color: #555;
  display: flex; gap: 12px; flex-wrap: wrap;
}
.offender-actions { display: flex; gap: 6px; }

/* === HOTSPOTS === */
.hotspot-list { display: flex; flex-direction: column; gap: 4px; }
.hotspot-row {
  display: grid; grid-template-columns: 1fr auto auto; gap: 10px; align-items: center;
  padding: 8px 10px; border: 2px solid #000; background: #fff;
  font-family: 'JetBrains Mono', monospace; font-size: 12px;
}
.hotspot-name { font-weight: 700; color: #000; }

/* === ALERTS === */
.alert-list { display: flex; flex-direction: column; gap: 10px; }
.alert-card-lg {
  display: grid; grid-template-columns: 6px 1fr auto; gap: 12px; align-items: stretch;
  background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 #000;
  overflow: hidden;
}
.alert-left-bar { background: var(--red); }
.alert-card-lg.severity-high .alert-left-bar { background: var(--red); }
.alert-card-lg.severity-med .alert-left-bar { background: var(--gold); }
.alert-card-lg.severity-low .alert-left-bar { background: var(--cyan); }
.alert-body { padding: 12px; display: flex; flex-direction: column; gap: 6px; }
.alert-header-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.alert-title-lg { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 15px; color: #000; }
.alert-meta-lg {
  display: flex; gap: 10px; flex-wrap: wrap;
  font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #666;
}
.alert-loc-row {
  font-family: 'JetBrains Mono', monospace; font-size: 11px; color: #333;
}
.zone-row {
  display: grid; grid-template-columns: 1fr auto auto; gap: 10px; align-items: center;
  padding: 8px 10px; border: 2px solid #000; background: #fff; margin-bottom: 4px;
  font-family: 'JetBrains Mono', monospace; font-size: 11px;
}

/* === MAP LAYOUT === */
.map-layout { display: grid; grid-template-columns: 1fr 340px; gap: 14px; }
@media (max-width: 1100px) { .map-layout { grid-template-columns: 1fr; } }
.map-sidebar {
  background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 #000;
  padding: 14px; display: flex; flex-direction: column; gap: 10px;
}
.asset-list { display: flex; flex-direction: column; gap: 6px; }
.asset-row {
  display: grid; grid-template-columns: 1fr auto; gap: 10px; align-items: center;
  padding: 8px 10px; border: 2px solid #000; background: #fff;
  font-family: 'JetBrains Mono', monospace; font-size: 11px;
}

/* === CHAT ENHANCED === */
.chat-layout-enhanced {
  display: grid; grid-template-columns: 260px 1fr; gap: 14px;
  min-height: 640px;
}
@media (max-width: 900px) { .chat-layout-enhanced { grid-template-columns: 1fr; } }
.chat-sidebar-enhanced {
  background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 #000;
  padding: 14px; display: flex; flex-direction: column; gap: 12px;
  max-height: 760px; overflow-y: auto;
}
.chat-main-enhanced {
  background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 #000;
  display: flex; flex-direction: column;
}
.quick-link {
  display: block; width: 100%; text-align: left;
  padding: 8px 10px; border: 2px solid #000; background: #fff;
  font-family: 'JetBrains Mono', monospace; font-size: 11px; cursor: pointer;
  margin-bottom: 4px;
}
.quick-link:hover { background: var(--gold); }
.msg-sources { margin-top: 8px; padding-top: 8px; border-top: 1px dashed #999; }
.msg-sources-title {
  font-family: 'JetBrains Mono', monospace; font-size: 9px;
  letter-spacing: 1px; text-transform: uppercase; color: #888; margin-bottom: 6px;
}
.source-chip {
  display: inline-flex; flex-direction: column; gap: 2px;
  padding: 6px 8px; background: #f5f4ef; border: 2px solid #000;
  margin-right: 6px; margin-bottom: 4px;
  font-family: 'JetBrains Mono', monospace; font-size: 10px;
  max-width: 220px;
}
.source-title { font-weight: 700; color: #000; }
.source-section { color: #555; }
.source-rel { color: var(--green); font-weight: 700; }
.msg-footer {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: 8px; padding-top: 6px; border-top: 1px dashed #bbb;
  font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #777;
}
.feedback-btns { display: flex; gap: 6px; }
.feedback-btns button {
  background: transparent; border: 2px solid #000; width: 24px; height: 24px;
  cursor: pointer; font-size: 11px;
}
.feedback-btns button:hover { background: var(--gold); }
.msg-suggestions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.suggestion-chip {
  background: #fff; border: 2px solid #000; padding: 4px 10px;
  font-family: 'JetBrains Mono', monospace; font-size: 11px; cursor: pointer;
}
.suggestion-chip:hover { background: var(--cyan); }
.typing-dots { display: inline-flex; gap: 3px; }
.typing-dots span {
  width: 6px; height: 6px; background: #555;
  border-radius: 50%; display: inline-block;
  animation: typingBounce 1.2s ease-in-out infinite;
}
.typing-dots span:nth-child(2) { animation-delay: 0.15s; }
.typing-dots span:nth-child(3) { animation-delay: 0.3s; }
@keyframes typingBounce { 0%,80%,100% { opacity: 0.3; transform: scale(1); } 40% { opacity: 1; transform: scale(1.4); } }

/* === SERVICE CATALOG === */
.service-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.service-card {
  background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 #000;
  padding: 0; display: flex; flex-direction: column; overflow: hidden;
}
.service-cat-header {
  padding: 8px 12px; background: var(--gold); color: #000;
  font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 13px;
  letter-spacing: 1px; text-transform: uppercase; border-bottom: 3px solid #000;
}
.service-items { display: flex; flex-direction: column; }
.service-item {
  padding: 8px 12px; border-bottom: 1px solid #eee;
  font-family: 'JetBrains Mono', monospace; font-size: 12px; cursor: pointer;
}
.service-item:hover { background: #f5f4ef; }
.service-item:last-child { border-bottom: none; }

/* === SESSION HISTORY === */
.session-list { display: flex; flex-direction: column; gap: 6px; }
.session-item {
  padding: 10px 12px; border: 2px solid #000; background: #fff; cursor: pointer;
  display: flex; flex-direction: column; gap: 4px;
}
.session-item:hover { background: #fafaf5; }
.session-title { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 13px; color: #000; }
.session-meta { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #666; }

/* === FAKE NEWS === */
.verdict-big {
  background: #fff; border: 3px solid #000; box-shadow: 6px 6px 0 var(--red);
  padding: 20px; display: flex; flex-direction: column; align-items: center;
  gap: 8px; text-align: center;
}
.verdict-big.real { box-shadow: 6px 6px 0 var(--green); }
.verdict-big.mixed { box-shadow: 6px 6px 0 var(--gold); }
.verdict-icon { font-size: 44px; line-height: 1; }
.verdict-label {
  font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 28px;
  letter-spacing: 2px; text-transform: uppercase; color: #000;
}
.verdict-conf { font-family: 'JetBrains Mono', monospace; font-size: 12px; color: #666; }
.claim-list { display: flex; flex-direction: column; gap: 8px; }
.claim-card {
  background: #fff; border: 2px solid #000; padding: 10px 12px;
  display: flex; flex-direction: column; gap: 6px;
}
.claim-verdict-badge {
  display: inline-block; padding: 2px 8px; border: 2px solid #000;
  font-family: 'JetBrains Mono', monospace; font-size: 10px; font-weight: 700;
}
.claim-conf { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #666; }
.claim-text { font-family: 'JetBrains Mono', monospace; font-size: 12px; color: #000; line-height: 1.5; }
.claim-notes { font-family: 'JetBrains Mono', monospace; font-size: 11px; color: #555; font-style: italic; padding-left: 10px; border-left: 2px solid #ccc; }
.analysis-widget {
  background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 #000;
  padding: 14px; display: flex; flex-direction: column; gap: 10px;
}
.source-details { font-family: 'JetBrains Mono', monospace; font-size: 11px; }
.source-details > div { display: flex; justify-content: space-between; padding: 3px 0; border-bottom: 1px dashed #ddd; }
.bias-bar {
  display: grid; grid-template-columns: 1fr 1fr 1fr;
  height: 20px; border: 2px solid #000; margin-top: 6px;
}
.bias-seg { position: relative; }
.bias-seg.left { background: #5BC0EB; }
.bias-seg.center { background: #e8e6df; }
.bias-seg.right { background: #E63946; }
.bias-seg .marker {
  position: absolute; top: -4px; bottom: -4px; width: 4px; background: #000;
}
.bias-labels {
  display: flex; justify-content: space-between;
  font-family: 'JetBrains Mono', monospace; font-size: 9px; color: #666;
  margin-top: 4px; letter-spacing: 1px;
}
.manipulation-row {
  display: grid; grid-template-columns: 1fr auto auto; gap: 8px; align-items: center;
  font-family: 'JetBrains Mono', monospace; font-size: 11px;
  padding: 4px 0; border-bottom: 1px dashed #ddd;
}
.related-list { display: flex; flex-direction: column; gap: 6px; }
.related-item {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 8px 10px; border: 2px solid #000; background: #fff; cursor: pointer;
}
.related-item > div { min-width: 0; flex: 1; }
.related-item > a { flex: none; }
.related-item:hover { background: #fafaf5; }
.related-title { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 12px; color: #000; overflow-wrap: anywhere; }
.related-src { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #666; margin-top: 2px; }

/* === FLAG GUIDE / TRUSTED / VERIFY STEPS === */
.flag-guide { display: flex; flex-direction: column; gap: 10px; }
.flag-guide-item {
  padding: 10px 12px; background: #fff; border: 2px solid #000;
  display: flex; flex-direction: column; gap: 4px;
}
.flag-guide-title {
  font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 13px; color: #000;
}
.flag-guide-desc { font-family: 'JetBrains Mono', monospace; font-size: 11px; color: #555; line-height: 1.5; }
.trusted-list { display: flex; flex-direction: column; gap: 6px; }
.trusted-row {
  display: grid; grid-template-columns: auto 1fr auto; gap: 10px; align-items: center;
  padding: 8px 10px; border: 2px solid #000; background: #fff;
  font-family: 'JetBrains Mono', monospace; font-size: 12px;
}
.trusted-row > div { min-width: 0; }
.verify-steps { display: flex; flex-direction: column; gap: 10px; }
.verify-step {
  display: grid; grid-template-columns: 42px 1fr; gap: 12px; align-items: flex-start;
  padding: 10px 12px; background: #fff; border: 2px solid #000;
}
.verify-num {
  width: 32px; height: 32px; background: var(--gold); border: 2px solid #000;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 16px;
}
.verify-t { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 13px; color: #000; }
.verify-d { font-family: 'JetBrains Mono', monospace; font-size: 11px; color: #555; margin-top: 2px; line-height: 1.5; }

/* === BULK RESULTS === */
.bulk-results { display: flex; flex-direction: column; gap: 6px; }
.bulk-row {
  display: grid; grid-template-columns: 1fr auto auto; gap: 10px; align-items: center;
  padding: 8px 10px; border: 2px solid #000; background: #fff;
  font-family: 'JetBrains Mono', monospace; font-size: 11px;
}
.bulk-url { color: #222; word-break: break-all; }
.bulk-conf { font-weight: 700; }

/* === TICKETS === */
.ai-preview {
  background: #fff; border: 3px solid var(--cyan); padding: 12px;
  box-shadow: 4px 4px 0 var(--cyan);
}
.ai-preview-body { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; margin-top: 6px; }
.ai-row { font-family: 'JetBrains Mono', monospace; font-size: 11px; display: flex; gap: 6px; }
.ai-row strong { color: #000; }
.attach-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 8px;
}
.attach-btn {
  background: #fff; border: 2px solid #000; padding: 10px;
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  cursor: pointer; min-height: 72px;
  font-family: 'JetBrains Mono', monospace; font-size: 10px; font-weight: 700;
}
.attach-btn:hover { background: var(--gold); }
.attach-btn .icon { font-size: 22px; }
.template-list-lg { display: flex; flex-direction: column; gap: 6px; }
.template-btn-lg {
  display: grid; grid-template-columns: 1fr auto; gap: 10px; align-items: center;
  padding: 10px 12px; background: #fff; border: 2px solid #000; cursor: pointer;
  text-align: left;
}
.template-btn-lg:hover { background: var(--gold); }
.template-cat-lg {
  font-family: 'JetBrains Mono', monospace; font-size: 9px;
  letter-spacing: 1px; text-transform: uppercase; color: #666;
}
.ticket-card-lg {
  background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 #000;
  padding: 14px; display: flex; flex-direction: column; gap: 8px;
}
.ticket-top-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.ticket-id-lg { font-family: 'JetBrains Mono', monospace; font-size: 11px; color: #888; }
.ticket-subject-lg { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 15px; color: #000; }
.ticket-meta-row { display: flex; gap: 10px; flex-wrap: wrap; font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #666; }
.ticket-expanded { padding-top: 10px; border-top: 2px solid #eee; }
.ticket-updates { display: flex; flex-direction: column; gap: 6px; margin-top: 10px; }
.update-item {
  padding: 8px 10px; background: #f5f4ef; border-left: 3px solid var(--gold);
  display: flex; flex-direction: column; gap: 2px;
}
.update-text { font-family: 'JetBrains Mono', monospace; font-size: 12px; color: #222; }
.update-time { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #888; }
.community-list { display: flex; flex-direction: column; gap: 10px; }
.community-card {
  display: grid; grid-template-columns: 80px 1fr auto; gap: 14px; align-items: center;
  padding: 12px; background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 #000;
}
.upvote-col { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.upvote-btn {
  background: #fff; border: 2px solid #000; width: 48px; height: 36px;
  cursor: pointer; font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 16px;
}
.upvote-btn:hover { background: var(--green); color: #fff; }
.upvote-count { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 20px; color: #000; }
.upvote-label {
  font-family: 'JetBrains Mono', monospace; font-size: 9px;
  letter-spacing: 1px; text-transform: uppercase; color: #666;
}
.community-title { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 14px; color: #000; }
.community-meta { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #666; margin-top: 2px; }
.community-actions { display: flex; gap: 6px; }
.nearby-list { display: flex; flex-direction: column; gap: 6px; }
.nearby-row {
  display: grid; grid-template-columns: 1fr auto; gap: 10px; align-items: center;
  padding: 8px 10px; border: 2px solid #000; background: #fff;
  font-family: 'JetBrains Mono', monospace; font-size: 11px;
}

/* === EXPENSES === */
.ai-predict {
  background: #fff; border: 3px solid var(--cyan); padding: 10px 12px;
  box-shadow: 4px 4px 0 var(--cyan); margin-top: 10px;
  font-family: 'JetBrains Mono', monospace; font-size: 12px;
  display: flex; gap: 10px; align-items: center;
}
.ocr-preview {
  background: #f5f4ef; border: 2px solid #000; padding: 10px;
  margin-top: 10px;
}
.ocr-preview-title {
  font-family: 'JetBrains Mono', monospace; font-size: 9px;
  letter-spacing: 1px; text-transform: uppercase; color: #666; margin-bottom: 6px;
}
.ocr-preview-body { display: flex; flex-direction: column; gap: 4px; }
.ocr-row { display: flex; justify-content: space-between; font-family: 'JetBrains Mono', monospace; font-size: 11px; }
.expense-list { display: flex; flex-direction: column; gap: 6px; }
.expense-row-lg {
  display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center;
  padding: 10px 12px; background: #fff; border: 2px solid #000;
}
.expense-desc-lg { font-family: 'JetBrains Mono', monospace; font-size: 13px; font-weight: 700; color: #000; }
.expense-meta { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #666; margin-top: 2px; }
.expense-amt-lg { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 18px; color: #000; }
.budget-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.budget-card {
  background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 #000;
  padding: 14px; display: flex; flex-direction: column; gap: 8px;
}
.budget-card.over { box-shadow: 4px 4px 0 var(--red); }
.budget-card.near { box-shadow: 4px 4px 0 var(--gold); }
.budget-card-top { display: flex; justify-content: space-between; align-items: center; }
.budget-cat {
  font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 13px;
  letter-spacing: 1px; text-transform: uppercase;
}
.budget-amt { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 18px; color: #000; }
.budget-footer {
  display: flex; justify-content: space-between; font-family: 'JetBrains Mono', monospace;
  font-size: 10px; color: #666;
}
.receipt-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; }
.receipt-card {
  background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 #000;
  display: flex; flex-direction: column; overflow: hidden;
}
.receipt-thumb {
  aspect-ratio: 1 / 1.2; background: #f5f4ef; border-bottom: 3px solid #000;
  display: flex; align-items: center; justify-content: center; font-size: 36px; color: #aaa;
}
.receipt-info { padding: 10px; display: flex; flex-direction: column; gap: 4px; }
.receipt-merchant { font-family: 'Chakra Petch', sans-serif; font-weight: 700; font-size: 13px; color: #000; }
.receipt-amt { font-family: 'JetBrains Mono', monospace; font-size: 12px; color: #000; font-weight: 700; }
.receipt-date { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: #666; }
.receipt-tags { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 4px; }
.tax-rows { display: flex; flex-direction: column; gap: 4px; margin-top: 10px; }
.tax-row {
  display: flex; justify-content: space-between;
  padding: 6px 10px; background: #fff; border: 2px solid #000;
  font-family: 'JetBrains Mono', monospace; font-size: 12px;
}

/* === FIELD / FILE HELPERS === */
.field-label {
  display: block; font-family: 'JetBrains Mono', monospace;
  font-size: 10px; letter-spacing: 1px; text-transform: uppercase;
  color: #555; margin-bottom: 4px;
}
.file-drop {
  padding: 24px 16px; border: 3px dashed #000; background: #fafaf5;
  cursor: pointer; text-align: center;
  font-family: 'JetBrains Mono', monospace; font-size: 12px;
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  transition: background .12s;
}
.file-drop:hover { background: #f2f0eb; }
.file-drop.dragging { background: var(--gold); }
.file-icon { font-size: 28px; }
.brutal-select {
  display: block; width: 100%; padding: 8px 10px;
  border: 2px solid #000; background: #fff;
  font-family: 'JetBrains Mono', monospace; font-size: 12px;
  min-height: 36px; cursor: pointer;
}
.brutal-select:focus-visible { outline: 3px solid var(--cyan); outline-offset: 2px; }

/* === TAB PANE === */
.tab-pane { animation: fadeIn .18s ease; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* === ACCESSIBILITY / REDUCED-MOTION === */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .cam-scan-line, .cam-noise, .pin-pulse, .ticker-content, .pulse-dot { animation: none !important; }
}

/* === FOCUS VISIBLE (global) === */
button:focus-visible, [role="button"]:focus-visible, a:focus-visible {
  outline: 3px solid var(--cyan); outline-offset: 2px;
}

/* === SCROLLBAR === */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #333; }

/* === RESPONSIVE === */
@media (max-width: 900px) {
  .gateways-grid, .widgets-grid-3 { grid-template-columns: 1fr 1fr; }
  .two-col-layout, .anomaly-main-grid { grid-template-columns: 1fr; }
  .portal-cards { grid-template-columns: 1fr; }
  .chat-layout { grid-template-columns: 1fr; }
  .chat-sidebar { display: none; }
  .hide-sm { display: none !important; }
  .kpi-grid-4 { grid-template-columns: 1fr 1fr; }
  .kanban-board { grid-template-columns: 1fr; }
  .camera-grid { grid-template-columns: 1fr; }
  .candidate-split { grid-template-columns: 1fr; }
  .map-layout { grid-template-columns: 1fr; }
  .summary-grid { grid-template-columns: repeat(2, 1fr); }
  .nav-user { display: none; }
}
@media (max-width: 600px) {
  .kpi-grid-4 { grid-template-columns: 1fr; }
  .widgets-grid { grid-template-columns: 1fr; }
  .summary-grid { grid-template-columns: 1fr; }
  .notif-drawer { width: 100vw; }
  .cmd-palette { width: 95vw; }
  .tab-pill { font-size: 11px; padding: 6px 10px; }
  .kpi-value { font-size: 22px; }
}

/* ============================================================
   Traffic Violations — Phase 1+ additions
   ============================================================ */

/* System Status Bar (below SubPageHeader) */
.tv-system-status {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 8px 12px; margin: 12px 0;
  background: #0a0a0a; border: 3px solid #000; box-shadow: 4px 4px 0 #000;
  font-family: var(--font-mono); font-size: 11px; color: #d4d4d4;
}
.tv-status-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 10px; border: 2px solid var(--green); border-radius: 2px;
  background: #111;
}
.tv-status-dot {
  width: 7px; height: 7px; border-radius: 50%;
  box-shadow: 0 0 6px currentColor;
}
.tv-status-label { font-weight: 700; letter-spacing: 1px; }
.tv-status-sub { opacity: 0.6; margin-left: 4px; }
.tv-status-env { margin-left: auto; opacity: 0.5; letter-spacing: 1px; }

/* Camera Health Strip (top of Live Feed) */
.tv-health-strip {
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px;
  margin-bottom: 12px;
}
.tv-health-block {
  background: #fff; border: 3px solid #000; padding: 10px 12px;
  box-shadow: 4px 4px 0 #000;
}
:root[data-theme="dark"] .tv-health-block,
body.dark .tv-health-block { background: #1a1a1a; color: #f0f0f0; }
.tv-health-num {
  font-family: var(--font-mono); font-size: 24px; font-weight: 800;
  letter-spacing: 1px; line-height: 1;
}
.tv-health-lbl {
  margin-top: 4px; font-size: 9px; font-weight: 700; letter-spacing: 1.5px;
  opacity: 0.6; text-transform: uppercase;
}
@media (max-width: 1100px) {
  .tv-health-strip { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 700px) {
  .tv-health-strip { grid-template-columns: repeat(2, 1fr); }
}

/* Live grid layout: camera grid + side mini-map */
.live-grid-row {
  display: grid; grid-template-columns: 3fr 1fr; gap: 12px;
  margin-bottom: 14px;
}
.live-grid-main { min-width: 0; }
.live-grid-side { min-width: 0; }
@media (max-width: 1100px) {
  .live-grid-row { grid-template-columns: 1fr; }
}

/* Mini-map widget */
.tv-mini-map {
  background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 #000;
  padding: 10px; margin-bottom: 12px;
}
:root[data-theme="dark"] .tv-mini-map,
body.dark .tv-mini-map { background: #1a1a1a; color: #f0f0f0; }

/* ============================================================
   Live Feed motion + detection animations
   ============================================================ */
@keyframes tvKenBurns {
  0%   { transform: scale(1)    translate(0,    0); }
  100% { transform: scale(1.08) translate(-2%, -1%); }
}
@keyframes tvBoxPulse {
  0%, 100% { stroke-opacity: 1; stroke-width: 0.005; }
  50%      { stroke-opacity: 0.55; stroke-width: 0.008; }
}

/* ============================================================
   Plate Lookup + Bulk Actions (Incidents tab)
   ============================================================ */
.tv-plate-lookup {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; margin-bottom: 12px;
  background: #fff; border: 3px solid #000; box-shadow: 4px 4px 0 #000;
}
:root[data-theme="dark"] .tv-plate-lookup,
body.dark .tv-plate-lookup { background: #1a1a1a; color: #f0f0f0; }
.tv-plate-lbl {
  font-family: var(--font-mono); font-size: 10px; font-weight: 700;
  letter-spacing: 1.5px; opacity: 0.6;
}
.tv-plate-input {
  flex: 1; max-width: 320px;
  padding: 6px 10px;
  font-family: var(--font-mono); font-size: 13px; font-weight: 700;
  background: #fff; border: 2px solid #000; outline: none;
}
:root[data-theme="dark"] .tv-plate-input,
body.dark .tv-plate-input { background: #0a0a0a; color: #f0f0f0; }
.tv-plate-input:focus { box-shadow: 2px 2px 0 #000; }

/* Bulk action bar — sticky at bottom of viewport */
.tv-bulk-bar {
  position: sticky; bottom: 16px; z-index: 30;
  display: flex; align-items: center; gap: 10px;
  margin-top: 16px;
  padding: 10px 16px;
  background: #000; color: #fff;
  border: 3px solid #000; box-shadow: 4px 4px 0 var(--cyan);
}
.tv-bulk-count {
  font-family: var(--font-mono); font-size: 12px; font-weight: 700;
  letter-spacing: 1px; color: var(--cyan);
}

/* Incident card selection state */
.incident-card.tv-selected {
  outline: 3px solid var(--cyan); outline-offset: 2px;
}
.tv-card-checkbox {
  position: absolute; top: 6px; left: 6px; z-index: 5;
  background: rgba(0,0,0,0.6); padding: 4px;
  border: 2px solid #fff;
  cursor: pointer;
}
.tv-card-checkbox input { cursor: pointer; }

/* ============================================================
   Plate-detail modal
   ============================================================ */
.tv-modal-backdrop {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(0,0,0,0.65);
  display: flex; align-items: flex-start; justify-content: center;
  padding: 60px 20px 20px;
  overflow-y: auto;
}
.tv-modal {
  width: 100%; max-width: 900px;
  background: #fff; border: 4px solid #000; box-shadow: 8px 8px 0 #000;
}
:root[data-theme="dark"] .tv-modal,
body.dark .tv-modal { background: #1a1a1a; color: #f0f0f0; }
.tv-modal-head {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 18px; border-bottom: 3px solid #000;
  background: var(--cyan);
}
.tv-modal-stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
  padding: 12px 18px; border-bottom: 2px solid #000;
}
.tv-modal-body { padding: 14px 18px; max-height: 60vh; overflow-y: auto; }
.tv-history-row {
  display: grid; grid-template-columns: 90px 1fr auto auto auto;
  align-items: center; gap: 10px;
  padding: 8px 10px; margin-bottom: 4px;
  background: #f8f8f8; border-left: 4px solid var(--cyan);
}
:root[data-theme="dark"] .tv-history-row,
body.dark .tv-history-row { background: #0f0f0f; }

/* Phase 5: Offender timeline modal */
.tv-modal.tv-modal-pad { padding: 20px; }
.tv-timeline {
  max-height: 50vh;
  overflow-y: auto;
  border-top: 2px solid #000;
  padding-top: 10px;
  margin-top: 6px;
}
.tv-timeline-row {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 10px 12px; margin-bottom: 6px;
  background: #f8f8f8;
  border-left: 4px solid var(--cyan);
}
:root[data-theme="dark"] .tv-timeline-row,
body.dark .tv-timeline-row { background: #0f0f0f; }
.tv-timeline-dot {
  width: 12px; height: 12px; border-radius: 50%;
  border: 2px solid #000; flex-shrink: 0; margin-top: 4px;
}

/* ============================================================
   Challans tab — SLA + Revenue Forecast
   ============================================================ */
.tv-grid-2col { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 1000px) { .tv-grid-2col { grid-template-columns: 1fr; } }
.tv-sla-row {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
  margin-bottom: 10px;
}
.tv-sla-list { margin-top: 8px; }

/* ============================================================
   Anomaly Monitoring — enhanced Leaflet city map
   ============================================================ */
.anm-map-shell { position: relative; }
.anm-map-canvas {
  height: 560px; border: 3px solid #000; box-shadow: 6px 6px 0 #000;
  background: #0b1622;
}
.anm-map-toolbar {
  position: absolute; top: 10px; right: 10px; z-index: 600;
  display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end;
}
.anm-map-btn {
  font-family: var(--font-mono); font-size: 10px; font-weight: 700;
  letter-spacing: 0.5px; padding: 5px 9px; cursor: pointer;
  background: #fff; color: #000; border: 2px solid #000;
  box-shadow: 2px 2px 0 #000; text-transform: uppercase;
}
.anm-map-btn.active { background: var(--cyan); color: #000; }
.anm-map-btn:hover { transform: translate(-1px,-1px); box-shadow: 3px 3px 0 #000; }

/* permanent zone label chips drawn as Leaflet divIcons */
.anm-zone-label {
  font-family: var(--font-mono); font-size: 10px; font-weight: 700;
  letter-spacing: 0.4px; color: #fff; white-space: nowrap;
  background: rgba(8,14,22,0.82); border: 1px solid rgba(255,255,255,0.35);
  padding: 1px 6px; border-radius: 2px; transform: translateY(-26px);
  text-shadow: 0 1px 2px #000;
}
.anm-zone-label.crit { border-color: #ef4444; color: #fecaca; }
.anm-zone-label.high { border-color: #f59e0b; color: #fde68a; }

/* pulsing halo for critical/high markers */
.anm-pulse { position: relative; }
.anm-pulse::before {
  content: ''; position: absolute; left: 50%; top: 50%;
  width: 14px; height: 14px; border-radius: 50%;
  transform: translate(-50%,-50%);
  background: currentColor; opacity: 0.55;
  animation: anmPulse 1.8s ease-out infinite;
}
@keyframes anmPulse {
  0%   { width: 14px; height: 14px; opacity: 0.55; }
  100% { width: 64px; height: 64px; opacity: 0; }
}
.anm-quake-icon {
  width: 0; height: 0; border-left: 9px solid transparent;
  border-right: 9px solid transparent; border-bottom: 16px solid #ef4444;
  filter: drop-shadow(0 1px 2px #000);
}
.anm-legend-chip {
  cursor: pointer; user-select: none; opacity: 1;
  transition: opacity 0.15s;
}
.anm-legend-chip.off { opacity: 0.32; text-decoration: line-through; }
.leaflet-popup-content-wrapper {
  border: 2px solid #000; border-radius: 3px; box-shadow: 4px 4px 0 #000;
}
.leaflet-popup-content { font-family: var(--font-mono); font-size: 12px; margin: 10px 12px; }
.anm-popup-btn {
  display: inline-block; margin-top: 7px; padding: 4px 10px;
  background: var(--cyan); color: #000; border: 2px solid #000;
  font-weight: 700; font-size: 11px; cursor: pointer; text-decoration: none;
}

/* ============================================================
   Citizen AI Assistant — PageIndex chat (Citizen Module 1)
   ============================================================ */
.cz-chat { display: grid; grid-template-columns: 280px 1fr; gap: 16px; }
@media (max-width: 980px) { .cz-chat { grid-template-columns: 1fr; } }
.cz-side { display: flex; flex-direction: column; gap: 14px; }
.cz-lang-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; }
.cz-lang {
  font-family: var(--font-mono); font-size: 11px; padding: 5px 6px;
  border: 2px solid #000; background: #fff; color: #000; cursor: pointer;
  box-shadow: 2px 2px 0 #000; transition: transform .1s;
}
.cz-lang.on { background: var(--gold); }
.cz-lang:hover { transform: translate(-1px,-1px); }
.cz-tts {
  display: flex; align-items: center; gap: 8px; margin-top: 10px;
  font-family: var(--font-mono); font-size: 12px; cursor: pointer;
}
.cz-kb { display: flex; flex-direction: column; gap: 6px; }
.cz-kb-item {
  border-left: 4px solid var(--gold); background: #0f0f0f; color: #eee;
  padding: 6px 9px; font-family: var(--font-mono);
}
:root[data-theme="light"] .cz-kb-item, body.light .cz-kb-item { background: #f3f3f3; color: #111; }
.cz-kb-name { font-size: 12px; font-weight: 700; text-transform: capitalize; }
.cz-kb-sec { font-size: 10px; opacity: 0.6; }
.cz-kb-build { font-family: var(--font-mono); font-size: 11px; opacity: 0.6; padding: 6px; }

.cz-main {
  display: flex; flex-direction: column; height: 640px;
  border: 3px solid #000; box-shadow: 6px 6px 0 #000; background: #111;
}
:root[data-theme="light"] .cz-main, body.light .cz-main { background: #fafafa; }
.cz-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 14px; border-bottom: 3px solid #000; background: var(--gold);
}
.cz-title { font-family: var(--font-display); font-weight: 800; letter-spacing: 1px; }
.cz-pill {
  font-family: var(--font-mono); font-size: 10px; font-weight: 700;
  background: #000; color: var(--gold); padding: 3px 8px; letter-spacing: 1px;
}
.cz-msgs { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.cz-row { display: flex; gap: 10px; align-items: flex-start; }
.cz-row.user { justify-content: flex-end; }
.cz-av { font-size: 22px; flex-shrink: 0; }
.cz-bubble {
  max-width: 76%; padding: 12px 14px; border: 2px solid #000;
  box-shadow: 3px 3px 0 #000; font-size: 14px; line-height: 1.6;
  background: #fff; color: #111;
}
.cz-row.user .cz-bubble { background: var(--gold); }
.cz-bubble.restricted { background: #2a1c00; color: #ffd98a; border-color: var(--gold); }
:root[data-theme="light"] .cz-bubble.restricted, body.light .cz-bubble.restricted { background: #fff6e0; color: #7a5b00; }
.cz-file { font-family: var(--font-mono); font-size: 11px; opacity: 0.7; margin-bottom: 6px; }
.cz-ocr {
  margin-top: 8px; font-family: var(--font-mono); font-size: 10px;
  background: #0a3d1f; color: var(--green); padding: 4px 8px; border: 1px solid var(--green);
}
.cz-trace { margin-top: 8px; }
.cz-trace-tog {
  background: none; border: none; cursor: pointer; font-family: var(--font-mono);
  font-size: 11px; color: var(--cyan); padding: 0; font-weight: 700;
}
.cz-trace-list {
  margin: 6px 0 0; padding-left: 18px; font-family: var(--font-mono);
  font-size: 11px; opacity: 0.8; line-height: 1.7;
}
.cz-src { margin-top: 10px; padding-top: 8px; border-top: 1px dashed #999; }
.cz-src-t { font-family: var(--font-mono); font-size: 10px; font-weight: 700; opacity: 0.6; margin-bottom: 5px; }
.cz-src-chip {
  display: inline-flex; gap: 6px; align-items: center; margin: 0 5px 5px 0;
  background: #0f0f0f; color: #ddd; border: 1px solid #444; padding: 3px 8px;
  font-family: var(--font-mono); font-size: 10px;
}
:root[data-theme="light"] .cz-src-chip, body.light .cz-src-chip { background: #eee; color: #222; }
.cz-src-chip.web { color: var(--cyan); text-decoration: none; border-color: var(--cyan); }
.cz-src-c { font-weight: 700; text-transform: capitalize; opacity: 0.7; }
.cz-foot {
  display: flex; align-items: center; gap: 8px; margin-top: 8px;
  padding-top: 6px; border-top: 1px solid #ddd;
  font-family: var(--font-mono); font-size: 10px;
}
.cz-lng { color: var(--cyan); }
.cz-web { color: var(--gold); }
.cz-conf { opacity: 0.6; }
.cz-sugg { display: flex; flex-wrap: wrap; gap: 6px; padding-left: 34px; }
.cz-sugg-c {
  font-family: var(--font-mono); font-size: 11px; padding: 5px 10px;
  background: #fff; border: 2px solid #000; cursor: pointer; box-shadow: 2px 2px 0 #000;
}
.cz-sugg-c:hover { background: var(--cyan); }
.cz-dots { display: inline-flex; gap: 3px; }
.cz-dots span {
  width: 7px; height: 7px; background: var(--gold); border-radius: 50%;
  animation: czb 1s infinite;
}
.cz-dots span:nth-child(2) { animation-delay: .15s; }
.cz-dots span:nth-child(3) { animation-delay: .3s; }
@keyframes czb { 0%,100% { opacity: .3; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-4px); } }
.cz-attach {
  margin: 0 14px; padding: 6px 10px; background: #0f0f0f; color: var(--cyan);
  border: 1px solid var(--cyan); font-family: var(--font-mono); font-size: 11px;
  display: flex; justify-content: space-between; align-items: center;
}
.cz-attach button { background: none; border: none; color: var(--red); cursor: pointer; font-weight: 700; }
.cz-input {
  display: flex; gap: 8px; align-items: center; padding: 12px 14px;
  border-top: 3px solid #000; background: #1a1a1a;
}
:root[data-theme="light"] .cz-input, body.light .cz-input { background: #f0f0f0; }
.cz-field {
  flex: 1; padding: 10px 12px; border: 2px solid #000; font-size: 14px;
  font-family: var(--font-sans); background: #fff; color: #000;
}
.cz-field:focus { outline: none; box-shadow: 3px 3px 0 var(--gold); }
.cz-mic, .cz-clip {
  width: 40px; height: 40px; border: 2px solid #000; background: #fff;
  cursor: pointer; font-size: 16px; box-shadow: 2px 2px 0 #000; flex-shrink: 0;
}
.cz-mic.live { background: var(--red); color: #fff; animation: czpulse 1s infinite; }
@keyframes czpulse { 0%,100% { box-shadow: 2px 2px 0 #000; } 50% { box-shadow: 2px 2px 0 #000, 0 0 0 6px rgba(255,59,48,0.35); } }

/* stop-voice + language indicator */
.cz-stop {
  font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  background: var(--red); color: #fff; border: 2px solid #000;
  padding: 4px 10px; cursor: pointer; box-shadow: 2px 2px 0 #000;
  animation: czpulse 1.1s infinite;
}
.cz-stop-wide {
  width: 100%; margin-top: 8px; padding: 7px; cursor: pointer;
  font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  border: 2px solid #000; box-shadow: 2px 2px 0 #000;
  background: var(--red); color: #fff;
}
.cz-stop-wide:disabled { background: #ddd; color: #666; cursor: default; box-shadow: 2px 2px 0 #000; animation: none; }
.cz-lang-now {
  margin-top: 8px; font-family: var(--font-mono); font-size: 10px;
  opacity: 0.7; line-height: 1.5;
}
.cz-lang-now strong { color: var(--gold); }

/* renovated Service Catalog */
.cz-svc-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 14px;
}
/* Theme-independent: the app runs light by default with NO theme
   class, so never rely on inherited colour — set bg AND fg explicitly. */
.cz-svc-card {
  border: 3px solid #000; box-shadow: 5px 5px 0 #000;
  background: #ffffff; color: #111;
  animation: fadeIn .4s ease both; overflow: hidden;
}
.cz-svc-head {
  display: flex; align-items: center; gap: 10px; padding: 12px 14px;
  border-bottom: 3px solid #000; background: var(--gold); color: #000;
  font-family: var(--font-display); font-weight: 800; letter-spacing: 1px;
}
.cz-svc-items { display: flex; flex-direction: column; }
.cz-svc-item {
  display: flex; justify-content: space-between; align-items: center;
  gap: 8px; text-align: left; padding: 10px 14px; border: none;
  border-bottom: 1px solid #e2e2e2;
  background: #ffffff; color: #111; cursor: pointer;
  font-family: var(--font-sans); font-size: 13px; font-weight: 600;
  transition: background .12s, color .12s;
}
.cz-svc-item:last-child { border-bottom: none; }
.cz-svc-item:hover { background: var(--cyan); color: #000; }
.cz-svc-go {
  font-family: var(--font-mono); font-size: 9px; font-weight: 800;
  color: #c026d3; opacity: 0; transition: opacity .12s; letter-spacing: 1px;
  flex-shrink: 0;
}
.cz-svc-item:hover .cz-svc-go { opacity: 1; color: #000; }
.cz-kb-chip {
  font-family: var(--font-mono); font-size: 11px; padding: 5px 10px;
  background: #1a1a1a; color: #f0f0f0; border: 2px solid #000;
  box-shadow: 2px 2px 0 #000; cursor: pointer; transition: all .12s;
}
.cz-kb-chip:hover { background: var(--gold); color: #000; transform: translate(-1px,-1px); }

/* ====================================================================
   === FAKE NEWS DETECTOR (Citizen M2) — neo-brutalist, theme-independent
   ==================================================================== */
.fn-strip {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  background: #111; color: #f0f0f0; border: 3px solid #000;
  box-shadow: 6px 6px 0 var(--red); padding: 10px 16px; margin: 12px 0 18px;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .5px;
}
.fn-strip strong { color: #fff; font-weight: 700; }
.fn-strip-k { color: #8a8a8a; }
.fn-strip-sep { color: #444; padding: 0 2px; }
.fn-dot { width: 9px; height: 9px; border: 2px solid #000; display: inline-block; }
.fn-dot.on { background: var(--green); } .fn-dot.off { background: var(--red); }

.fn-waterfall { display: flex; align-items: stretch; flex-wrap: wrap; margin: 12px 0; }
.fn-wf-node {
  flex: 1; min-width: 120px; border: 3px solid #000; padding: 12px;
  background: #fff; color: #111; box-shadow: 6px 6px 0 #000;
  margin-right: 14px; margin-bottom: 8px;
}
.fn-wf-node.off { background: #ECEAE3; color: #888; box-shadow: 6px 6px 0 #999; }
.fn-wf-node.on  { background: #fff; box-shadow: 6px 6px 0 var(--red); }
.fn-wf-k { font-family: var(--font-mono); font-size: 10px; font-weight: 700;
  background: #111; color: #fff; display: inline-block; padding: 2px 7px; }
.fn-wf-t { font-family: var(--font-display); font-weight: 700; font-size: 14px;
  margin-top: 8px; color: #111; }
.fn-wf-node.off .fn-wf-t { color: #888; }
.fn-wf-v { font-family: var(--font-mono); font-size: 13px; font-weight: 700;
  margin-top: 4px; color: var(--red); }
.fn-wf-node.off .fn-wf-v { color: #999; }
.fn-wf-s { font-family: var(--font-mono); font-size: 10px; color: #777; margin-top: 4px; }
.fn-wf-arrow { display: flex; align-items: center; color: #111;
  font-size: 16px; margin: 0 14px 8px -6px; }

.fn-verdict {
  display: flex; align-items: center; gap: 16px; border: 3px solid #000;
  background: #fff; color: #111; box-shadow: 6px 6px 0 var(--vc, #000);
  padding: 16px 18px;
}
.fn-verdict-badge { width: 52px; height: 52px; display: flex;
  align-items: center; justify-content: center; border: 3px solid #000;
  font-size: 26px; font-weight: 700; }
.fn-verdict-main { flex: 1; }
.fn-verdict-label { font-family: var(--font-display); font-weight: 700;
  font-size: 26px; color: #111; letter-spacing: .5px; }
.fn-verdict-meta { font-family: var(--font-mono); font-size: 12px;
  color: #444; margin-top: 4px; }
.fn-chip { background: var(--gold); color: #000; border: 2px solid #000;
  font-size: 10px; font-weight: 700; padding: 2px 8px; margin-left: 10px; }
.fn-quota { background: #FBEFC8; color: #5a4500; border: 3px solid #000;
  box-shadow: 6px 6px 0 var(--gold); padding: 12px 16px; margin-bottom: 16px;
  font-family: var(--font-mono); font-size: 12px; font-weight: 600; }
.fn-err { background: #FBE0E2; color: #8a1a22; border: 2px solid var(--red);
  padding: 10px 14px; font-family: var(--font-mono); font-size: 12px; }

.fn-loading { padding: 30px 16px; text-align: center; }
.fn-scan { height: 6px; background: #ECEAE3; border: 2px solid #000;
  overflow: hidden; position: relative; }
.fn-scan::after { content: ''; position: absolute; top: 0; bottom: 0;
  width: 30%; background: var(--red); animation: fnScan 1.1s linear infinite; }
@keyframes fnScan { 0% { left: -30%; } 100% { left: 100%; } }
.fn-load-txt { font-family: var(--font-mono); font-size: 12px;
  color: #555; margin-top: 14px; }

.fn-claim { border: 3px solid #000; background: #fff; color: #111;
  box-shadow: 5px 5px 0 var(--cc, #000); padding: 12px 14px; margin-bottom: 12px; }
.fn-claim-top { display: flex; align-items: center; gap: 10px; }
.fn-claim-badge { font-family: var(--font-mono); font-size: 11px;
  font-weight: 700; border: 2px solid #000; padding: 2px 9px; }
.fn-claim-nli { font-family: var(--font-mono); font-size: 10px; color: #666;
  border: 1px solid #999; padding: 1px 6px; }
.fn-claim-conf { margin-left: auto; font-family: var(--font-mono);
  font-weight: 700; font-size: 13px; color: #111; }
.fn-claim-text { font-family: var(--font-mono); font-size: 13px;
  color: #111; margin: 8px 0 6px; line-height: 1.5; }
.fn-claim-notes { font-size: 12px; color: #555; font-style: italic; }
.fn-ev { border-left: 4px solid #000; padding: 6px 10px; margin-top: 8px;
  background: #F7F6F1; }
.fn-ev-support { border-left-color: var(--green); }
.fn-ev-contra  { border-left-color: var(--red); }
.fn-ev-h { font-family: var(--font-mono); font-size: 10px; font-weight: 700;
  color: #333; margin-bottom: 4px; }
.fn-ev-row { display: flex; align-items: baseline; gap: 8px; font-size: 11px;
  color: #333; margin: 3px 0; }
.fn-ev-pub { font-weight: 700; color: #111; white-space: nowrap; }
.fn-ev-snip { color: #555; flex: 1; }
.fn-ev-link { color: var(--red); font-weight: 700; text-decoration: none; }
.fn-trace { font-family: var(--font-mono); font-size: 12px;
  background: #111; color: #e8e8e8; border: 3px solid #000;
  padding: 14px 14px 14px 30px; margin-top: 10px; line-height: 1.7; }
.fn-trace li { margin: 4px 0; }
.fn-tag { font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  border: 2px solid #000; padding: 2px 8px; display: inline-block; }
.fn-meta-bar { display: flex; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: 12px; color: #333;
  background: #F7F6F1; border: 2px solid #000; padding: 8px 12px; margin: 10px 0; }
.fn-review { border: 3px solid #000; background: #fff; color: #111;
  box-shadow: 5px 5px 0 #000; padding: 14px; margin: 12px 0; }
.fn-review-top { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.fn-review-reason { font-family: var(--font-mono); font-size: 12px;
  color: #555; flex: 1; }
@media (prefers-reduced-motion: reduce) {
  .fn-scan::after { animation: none; width: 50%; }
}

/* === TRAFFIC — CAMERA DELETE (Live Feed tile control) === */
.cam-del-btn {
  position: absolute; top: 6px; right: 6px; z-index: 5;
  width: 24px; height: 24px; padding: 0; line-height: 1;
  display: flex; align-items: center; justify-content: center;
  background: var(--red); color: #fff;
  border: 2px solid #000; box-shadow: 2px 2px 0 #000;
  font-family: 'JetBrains Mono', monospace; font-size: 13px; font-weight: 700;
  cursor: pointer; opacity: 0.55; transition: opacity 0.12s, transform 0.12s;
}
.camera-tile:hover .cam-del-btn { opacity: 1; }
.cam-del-btn:hover { transform: translate(1px, 1px); box-shadow: 1px 1px 0 #000; }
.cam-del-btn:focus-visible { opacity: 1; outline: 3px solid var(--cyan); outline-offset: 2px; }
/* keep the live FPS / fresh badge clear of the ✕ control */
.cam-overlay-tr { right: 34px; }
@media (prefers-reduced-motion: reduce) { .cam-del-btn { transition: none; } }

/* === TICKETS MAP (live Leaflet) === */
.tk-map-canvas {
  height: 420px;
  border-top: 3px solid #000;
  background: #dcdad4;
}
.tk-map-canvas.leaflet-container { font-family: var(--font-mono); }

/* === TELEGRAM SETUP (Phase 6) === */
.tg-card { display: flex; flex-direction: column; }
.tg-status { font-family: var(--font-mono); font-size: 9px; font-weight: 700; letter-spacing: 1px; padding: 3px 8px; border: 2px solid #000; }
.tg-body { padding: 4px 2px 2px; }
.tg-lede { font-family: var(--font-mono); font-size: 12px; line-height: 1.6; color: #333; margin: 0 0 14px; }
.tg-actions { display: flex; gap: 10px; align-items: stretch; margin-top: 16px; flex-wrap: wrap; }
.tg-msg { margin-top: 12px; padding: 8px 10px; border: 2px solid #000; background: #fff; font-family: var(--font-mono); font-size: 11px; font-weight: 700; line-height: 1.5; }
.tg-guide-toggle { margin-top: 16px; width: 100%; text-align: left; background: #f2f0eb; border: 2px solid #000; padding: 9px 12px; font-family: var(--font-display); font-weight: 700; font-size: 12px; letter-spacing: 0.5px; cursor: pointer; box-shadow: 3px 3px 0 #000; }
.tg-guide-toggle:hover { background: #fff; }
.tg-guide { margin-top: 12px; border: 2px solid #000; background: #fbfaf7; padding: 14px 16px; }
.tg-guide-h { font-family: var(--font-display); font-weight: 700; font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px; margin: 6px 0 8px; padding-bottom: 4px; border-bottom: 2px solid #000; }
.tg-guide-h:first-child { margin-top: 0; }
.tg-guide ol { margin: 0 0 10px; padding-left: 20px; }
.tg-guide li { font-family: var(--font-mono); font-size: 11.5px; line-height: 1.7; margin-bottom: 5px; color: #222; }
.tg-guide code { background: #eceae4; border: 1px solid #ccc; padding: 0 4px; font-size: 10.5px; }
.tg-note { font-family: var(--font-mono); font-size: 10.5px; line-height: 1.6; color: #666; border-top: 1px dashed #bbb; padding-top: 10px; margin-top: 4px; }

/* === ADMIN CONSOLE (Phase 6) === */
.admin-table-wrap { overflow-x: auto; border: 3px solid #000; box-shadow: 6px 6px 0 #000; background: #fff; margin-top: 14px; }
.admin-table { width: 100%; border-collapse: collapse; font-family: var(--font-mono); font-size: 12px; }
.admin-table th { text-align: left; background: #000; color: var(--gold); font-family: var(--font-display); font-size: 11px; letter-spacing: 1px; padding: 10px 12px; text-transform: uppercase; }
.admin-table td { padding: 9px 12px; border-top: 2px solid #eee; vertical-align: middle; }
.admin-table td strong { margin-right: 6px; }
.admin-table tr.admin-off td { opacity: 0.5; }
.admin-role { padding: 4px 6px; font-size: 11px; min-width: 118px; }
.admin-empty { padding: 30px; text-align: center; font-family: var(--font-mono); font-size: 12px; opacity: 0.5; }
.audit-list { margin-top: 14px; border: 3px solid #000; box-shadow: 6px 6px 0 #000; background: #fff; max-height: 560px; overflow-y: auto; }
.audit-row { display: grid; grid-template-columns: 14px 160px 130px 1fr 120px; gap: 10px; align-items: center; padding: 8px 12px; border-bottom: 1px dashed #ddd; font-family: var(--font-mono); font-size: 11px; }
.audit-dot { width: 10px; height: 10px; border: 2px solid #000; }
.audit-action { font-weight: 700; }
.audit-actor { color: #555; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.audit-detail { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.role-row { display: flex; justify-content: space-between; align-items: center; padding: 8px 4px; border-bottom: 1px dashed #ddd; font-family: var(--font-mono); font-size: 13px; }
.role-count { font-family: var(--font-display); font-weight: 700; font-size: 18px; }
@media (max-width: 720px) { .audit-row { grid-template-columns: 14px 1fr; } .audit-actor, .audit-detail, .audit-time { display: none; } }
