/* ============================================================================
   CarbonBridge & SkillSwipe Intelligence Dashboard — Styles
   ============================================================================
   Color System:  Midnight navy + Sky blue (CB) + Violet (SS)
   Typography:    Inter (UI) · DM Mono (data) · Noto Sans SC (中文)
   ============================================================================ */

/* Fonts loaded via <link> in index.html for non-blocking render */

:root {
  /* ── Backgrounds ── */
  --bg-primary:   #0b1121;
  --bg-secondary: #111827;
  --bg-tertiary:  #1a2332;
  --bg-input:     #0f172a;
  --bg-hover:     #1e293b;
  --card-bg:      #111827;

  /* ── Borders ── */
  --border:       #1e293b;
  --border-light: #334155;

  /* ── Dual Accent System ── */
  --accent-cb:    #0ea5e9;   /* CarbonBridge sky blue */
  --accent-ss:    #8b5cf6;   /* SkillSwipe violet */
  --accent:       #0ea5e9;   /* Primary accent */
  --accent-dim:   rgba(14,165,233,0.10);
  --accent-glow:  rgba(14,165,233,0.25);
  --violet-dim:   rgba(139,92,246,0.10);

  /* ── Text ── */
  --text-primary:   #e2e8f0;
  --text-secondary: #94a3b8;
  --text-muted:     #64748b;

  /* ── Semantic ── */
  --green:      #10b981;
  --green-dim:  rgba(16,185,129,0.12);
  --red:        #ef4444;
  --red-dim:    rgba(239,68,68,0.12);
  --orange:     #f59e0b;
  --orange-dim: rgba(245,158,11,0.12);
  --blue:       #3b82f6;
  --purple:     #8b5cf6;
  --cyan:       #06b6d4;

  /* ── Typography ── */
  --font-ui:   'Inter', -apple-system, sans-serif;
  --font-mono: 'DM Mono', 'Menlo', monospace;
  --font-cn:   'Noto Sans SC', 'PingFang SC', sans-serif;

  /* ── Layout ── */
  --sidebar-w: 220px;
  --header-h: 56px;
  --radius: 8px;
  --radius-lg: 12px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 14px; }
body {
  font-family: var(--font-ui);
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.55;
}

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-light); border-radius: 3px; }

/* ── Text helpers ── */
.text-cn { font-family: var(--font-cn); }
.accent-text { color: var(--accent-cb); }
.hidden { display: none !important; }
.mt-24 { margin-top: 24px; }

/* ══════════════════════════════════════════════════════════════════════════
   BACKGROUND
   ══════════════════════════════════════════════════════════════════════════ */

.bg-orb {
  position: fixed; border-radius: 50%; filter: blur(120px); opacity: 0.07;
  pointer-events: none; z-index: 0;
}
.bg-orb-1 { width: 600px; height: 600px; background: var(--accent-cb); top: -200px; left: -100px; }
.bg-orb-2 { width: 500px; height: 500px; background: var(--accent-ss); bottom: -150px; right: -100px; }
.bg-orb-3 { width: 400px; height: 400px; background: var(--cyan); top: 50%; left: 50%; transform: translate(-50%,-50%); opacity: 0.03; }
.bg-grid {
  position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: 0.015;
  background-image: linear-gradient(var(--border) 1px, transparent 1px),
                    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 60px 60px;
}

/* ══════════════════════════════════════════════════════════════════════════
   LOGIN
   ══════════════════════════════════════════════════════════════════════════ */

#loginScreen {
  position: fixed; inset: 0; z-index: 1000; display: flex;
  align-items: center; justify-content: center;
  background: var(--bg-primary);
}
.login-card {
  width: 380px; padding: 40px 32px; border-radius: var(--radius-lg);
  background: var(--bg-secondary); border: 1px solid var(--border);
  box-shadow: 0 20px 60px rgba(0,0,0,0.4);
}
.login-brand { text-align: center; margin-bottom: 28px; }
.brand-logo { width: 56px; height: 56px; margin-bottom: 12px; }
.login-brand h1 { font-size: 1.3rem; font-weight: 700; color: var(--text-primary); margin-bottom: 4px; }
.login-cn { font-size: 0.82rem; color: var(--text-secondary); margin-bottom: 6px; }
.login-tagline { font-size: 0.68rem; color: var(--text-muted); letter-spacing: 0.5px; text-transform: uppercase; }
.login-error { display: none; color: var(--red); font-size: 0.78rem; text-align: center; margin-top: 10px; }
.login-footer { display: flex; justify-content: space-between; font-size: 0.65rem; color: var(--text-muted); margin-top: 20px; padding-top: 14px; border-top: 1px solid var(--border); }

/* ── Forms ── */
.form-group { margin-bottom: 14px; }
.form-label { display: block; font-size: 0.72rem; color: var(--text-secondary); margin-bottom: 5px; font-weight: 500; }
.form-input {
  width: 100%; padding: 10px 12px; border-radius: var(--radius);
  background: var(--bg-input); border: 1px solid var(--border); color: var(--text-primary);
  font-family: var(--font-ui); font-size: 0.85rem; transition: border-color 0.2s;
}
.form-input:focus { outline: none; border-color: var(--accent-cb); box-shadow: 0 0 0 2px var(--accent-dim); }
.form-input::placeholder { color: var(--text-muted); }
textarea.form-input { resize: vertical; min-height: 60px; }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 10px 18px; border: none; border-radius: var(--radius); cursor: pointer;
  font-family: var(--font-ui); font-size: 0.82rem; font-weight: 600;
  transition: all 0.2s; width: 100%;
}
.btn-primary { background: var(--accent-cb); color: #fff; }
.btn-primary:hover { background: #0284c7; }
.btn-glow { box-shadow: 0 0 20px var(--accent-dim); }
.btn-secondary { background: var(--bg-tertiary); color: var(--text-secondary); border: 1px solid var(--border); }
.btn-secondary:hover { border-color: var(--accent-cb); color: var(--text-primary); }
.btn-accent { background: linear-gradient(135deg, var(--accent-cb), var(--accent-ss)); color: #fff; }
.btn-accent:hover { opacity: 0.9; }
.btn-danger { background: var(--red-dim); color: var(--red); border: 1px solid transparent; }
.btn-danger:hover { background: var(--red); color: #fff; }
.btn-sm { padding: 6px 12px; font-size: 0.75rem; width: auto; }
.btn-icon { background: none; border: none; cursor: pointer; font-size: 1rem; padding: 4px 6px; border-radius: 4px; transition: background 0.15s; }
.btn-icon:hover { background: var(--bg-hover); }

/* ══════════════════════════════════════════════════════════════════════════
   HEADER
   ══════════════════════════════════════════════════════════════════════════ */

#appHeader {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: var(--header-h);
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(12px);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 100%; padding: 0 16px; max-width: 100%;
}
.header-brand { display: flex; align-items: center; gap: 10px; min-width: 200px; }
.header-logo { width: 28px; height: 28px; }
.header-brand h2 { font-size: 0.92rem; font-weight: 700; white-space: nowrap; }
.header-cn-title { font-family: var(--font-cn); font-weight: 500; font-size: 0.78rem; color: var(--text-secondary); margin-left: 4px; }
.header-sub { font-size: 0.58rem; color: var(--text-muted); letter-spacing: 1px; text-transform: uppercase; font-family: var(--font-mono); }
.header-meta { display: flex; align-items: center; gap: 16px; flex-wrap: nowrap; overflow-x: auto; }
.header-stat { display: flex; flex-direction: column; align-items: center; gap: 1px; }
.stat-label-bi { font-size: 0.55rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.3px; white-space: nowrap; }
.stat-value { font-size: 0.78rem; font-weight: 600; font-family: var(--font-mono); color: var(--text-primary); }
.live-clock { color: var(--accent-cb) !important; }
.stat-countdown { color: var(--accent-cb); }
.pulse-accent { color: var(--accent-cb); }
.header-actions { display: flex; align-items: center; gap: 6px; }
.user-badge { display: flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 20px; background: var(--bg-tertiary); border: 1px solid var(--border); }
.user-avatar { font-size: 0.9rem; }
.user-name { font-size: 0.72rem; font-weight: 500; color: var(--text-secondary); }
.connection-status { cursor: default; }
.conn-dot { width: 6px; height: 6px; border-radius: 50%; display: inline-block; }
.conn-online { background: var(--green); box-shadow: 0 0 6px var(--green); }
.conn-offline { background: var(--red); }
.conn-checking { background: var(--orange); }
.conn-label { font-size: 0.65rem !important; }

/* ── Risk pill ── */
.risk-pill {
  display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px;
  border-radius: 12px; font-size: 0.65rem; font-weight: 600;
  font-family: var(--font-mono); white-space: nowrap;
}
.risk-high { background: var(--red-dim); color: var(--red); }
.risk-medium { background: var(--orange-dim); color: var(--orange); }
.risk-low { background: var(--green-dim); color: var(--green); }
.risk-pulse { width: 5px; height: 5px; border-radius: 50%; background: currentColor; animation: pulse 2s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.4; } }

/* ══════════════════════════════════════════════════════════════════════════
   LAYOUT: SIDEBAR + MAIN
   ══════════════════════════════════════════════════════════════════════════ */

.app-layout {
  display: flex; position: relative; z-index: 1;
  padding-top: var(--header-h); min-height: 100vh;
}

/* ── Sidebar ── */
.sidebar {
  width: var(--sidebar-w); min-width: var(--sidebar-w);
  background: var(--bg-secondary); border-right: 1px solid var(--border);
  padding: 16px 10px; overflow-y: auto;
  position: fixed; top: var(--header-h); bottom: 0; left: 0; z-index: 50;
}
.sidebar-title { font-size: 0.6rem; text-transform: uppercase; letter-spacing: 1px; color: var(--text-muted); padding: 8px 10px 4px; font-weight: 600; }
.sidebar-version { font-size: 0.58rem; color: var(--text-muted); text-align: center; padding: 16px 0 4px; font-family: var(--font-mono); }
.nav-item {
  display: flex; align-items: center; gap: 8px; padding: 9px 12px;
  border-radius: var(--radius); cursor: pointer; margin-bottom: 2px;
  font-size: 0.8rem; color: var(--text-secondary); transition: all 0.15s;
  border-left: 3px solid transparent;
}
.nav-item:hover { background: var(--bg-hover); color: var(--text-primary); }
.nav-item.active {
  background: var(--accent-dim);
  color: var(--accent-cb);
  border-left-color: var(--accent-cb);
  font-weight: 600;
}
.nav-icon { font-size: 1rem; width: 22px; text-align: center; flex-shrink: 0; }
.nav-label { font-size: 0.76rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ── Main Content ── */
.main-content {
  flex: 1; margin-left: var(--sidebar-w); padding: 20px 24px 40px;
  min-height: calc(100vh - var(--header-h));
  overflow-y: auto;
}

.module-panel { display: none; }
.module-panel.active { display: block; animation: fadeIn 0.2s ease; max-height: calc(100vh - var(--header-h) - 40px); overflow-y: auto; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ── Module Header ── */
.module-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 20px; flex-wrap: wrap; gap: 10px; }
.module-title { display: flex; align-items: center; gap: 10px; }
.module-icon { font-size: 1.4rem; }
.module-title h3 { font-size: 1.15rem; font-weight: 700; }
.module-title .text-cn { font-family: var(--font-cn); font-weight: 500; font-size: 0.85rem; color: var(--text-secondary); margin-left: 6px; }
.module-subtitle { font-size: 0.7rem; color: var(--text-muted); margin-top: 2px; }
.module-actions { display: flex; gap: 6px; align-items: center; }
.project-selector { background: var(--bg-input); color: var(--text-primary); border: 1px solid var(--border); border-radius: 6px; padding: 5px 8px; font-size: 0.72rem; font-family: var(--font-ui); cursor: pointer; outline: none; min-width: 90px; }
.project-selector:focus { border-color: var(--accent-cb); }
.project-selector option { background: var(--bg-card); color: var(--text-primary); }
.section-title { font-size: 0.88rem; font-weight: 600; color: var(--text-secondary); margin: 20px 0 10px; }

/* ══════════════════════════════════════════════════════════════════════════
   OVERVIEW GRID (Executive Command Center)
   ══════════════════════════════════════════════════════════════════════════ */

.overview-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 14px; margin-bottom: 24px;
}
.ov-card {
  background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 16px; overflow: hidden;
}
.ov-card:hover { border-color: var(--border-light); }
.ov-header {
  display: flex; align-items: center; gap: 6px;
  font-size: 0.78rem; font-weight: 600; color: var(--text-secondary);
  margin-bottom: 12px; padding-bottom: 8px; border-bottom: 1px solid var(--border);
}
.card-kpi-wide, .card-timeline-wide { grid-column: span 2; }

/* ── Vitals ── */
.vitals-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.vital { display: flex; flex-direction: column; gap: 1px; }
.v-label { font-size: 0.6rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.3px; }
.v-val { font-size: 0.82rem; font-weight: 600; color: var(--text-primary); font-family: var(--font-ui); }
.v-sub { font-size: 0.65rem; color: var(--text-muted); font-family: var(--font-cn); }

/* ── Charts ── */
.chart-wrap-sm { height: 140px; position: relative; }
.chart-wrap-med { height: 200px; position: relative; }
.risk-legend { display: flex; gap: 12px; justify-content: center; margin-top: 8px; font-size: 0.7rem; }
.rl { display: flex; align-items: center; gap: 4px; }
.rl b { font-family: var(--font-mono); font-size: 0.9rem; }
.rl.high { color: var(--red); }
.rl.med { color: var(--orange); }
.rl.low { color: var(--green); }

/* ── KPI strip ── */
.kpi-strip { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
.kpi { text-align: center; flex: 1; min-width: 80px; padding: 10px 6px; background: var(--bg-tertiary); border-radius: var(--radius); overflow: hidden; }
.kpi-icon { font-size: 1.1rem; margin-bottom: 4px; }
.kpi-num { font-size: 0.78rem; font-weight: 700; color: var(--accent-cb); font-family: var(--font-ui); line-height: 1.3; }
.kpi-num-big { font-size: 1.4rem; font-weight: 700; color: var(--accent-cb); font-family: var(--font-mono); }
.kpi-lab { font-size: 0.58rem; color: var(--text-muted); line-height: 1.3; margin-top: 2px; }

/* ── Org Chart — 3-Tier ── */
.org-chart { display: flex; flex-direction: column; align-items: center; gap: 0; padding: 4px 0; }

/* Tier wrapper */
.org-tier { width: 100%; }
.org-tier-label {
  font-size: 0.6rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px;
  color: var(--text-muted); text-align: center; margin-bottom: 8px;
}
.org-tier-row {
  display: flex; justify-content: center; gap: 10px; flex-wrap: wrap;
}

/* Connector between tiers */
.org-tier-conn {
  width: 2px; height: 16px; background: var(--border-light); margin: 0 auto;
  position: relative;
}
.org-tier-conn::before {
  content: ''; position: absolute; bottom: 0; left: -30px; width: 62px; height: 2px;
  background: var(--border-light);
}

/* Nodes — all same size */
.org-node {
  text-align: center; padding: 10px 12px; border-radius: var(--radius-lg);
  border: 1px solid var(--border); transition: all 0.25s ease;
  background: linear-gradient(135deg, rgba(14,165,233,0.08), rgba(139,92,246,0.08));
  min-width: 120px; max-width: 150px; flex: 0 1 150px;
}
.org-node:hover { transform: translateY(-2px); box-shadow: 0 4px 16px rgba(14,165,233,0.15); border-color: var(--accent-cb); }
.org-avatar { font-size: 1.1rem; margin-bottom: 2px; }
.org-name { font-size: 0.72rem; font-weight: 600; color: var(--text-primary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.org-title { font-size: 0.55rem; color: var(--text-secondary); line-height: 1.3; }
.org-tags { display: flex; gap: 3px; justify-content: center; margin-top: 5px; }
.org-tag { font-size: 0.48rem; font-weight: 700; padding: 1px 4px; border-radius: 3px; letter-spacing: 0.5px; }
.org-tag.ot-cb { background: rgba(14,165,233,0.15); color: var(--accent-cb); }
.org-tag.ot-ss { background: rgba(139,92,246,0.15); color: var(--accent-ss); }

/* Project accent on hover */
.node-cb:hover { border-color: var(--accent-cb); }
.node-ss:hover { border-color: var(--accent-ss); }

/* Future / open positions — dashed */
.node-open { border-style: dashed; opacity: 0.45; background: var(--bg-tertiary); }
.node-open:hover { opacity: 0.8; }
.org-tier-future .org-tier-label { color: var(--text-muted); font-style: italic; }

/* ── Risk detail charts ── */
.risk-charts-row { display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; margin-bottom: 20px; }
.risk-chart-box { background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 14px; }

/* ── Mini timeline ── */
.mini-timeline { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; }
.mini-ms {
  flex-shrink: 0; width: 140px; padding: 10px; border-radius: var(--radius);
  background: var(--bg-tertiary); border: 1px solid var(--border); text-align: center;
}
.mini-ms.active { border-color: var(--accent-cb); background: var(--accent-dim); }
.mini-ms.done { border-color: var(--green); opacity: 0.7; }
.ms-month { font-size: 0.6rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }
.ms-name { font-size: 0.72rem; font-weight: 600; color: var(--text-primary); margin: 3px 0; }
.ms-cn { font-size: 0.65rem; color: var(--text-muted); font-family: var(--font-cn); }
.ms-dates { font-size: 0.58rem; color: var(--text-muted); font-family: var(--font-mono); margin: 3px 0; }
.ms-badge { margin-top: 4px; }

/* ══════════════════════════════════════════════════════════════════════════
   STATS GRID / STAT CARDS
   ══════════════════════════════════════════════════════════════════════════ */

.stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; margin-bottom: 16px; }
.stat-card {
  background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 14px; text-align: center;
}
.stat-card.glow-card:hover { border-color: var(--accent-cb); box-shadow: 0 0 12px var(--accent-dim); }
.stat-icon { font-size: 1.2rem; margin-bottom: 4px; }
.stat-number { font-size: 1.4rem; font-weight: 700; color: var(--accent-cb); font-family: var(--font-mono); }
.stat-label { font-size: 0.65rem; color: var(--text-muted); margin-top: 2px; line-height: 1.3; }

/* ── Dev stream cards ── */
.dev-stream-card {
  background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 12px; display: flex; flex-direction: column; gap: 4px;
}
.dev-stream-name { font-size: 0.78rem; font-weight: 600; color: var(--text-primary); }
.dev-stream-cn { font-size: 0.68rem; color: var(--text-muted); font-family: var(--font-cn); }
.dev-stream-meta { display: flex; justify-content: space-between; align-items: center; font-size: 0.68rem; }
.dev-stream-days { font-weight: 700; font-family: var(--font-mono); color: var(--accent-cb); }
.priority-badge { padding: 1px 6px; border-radius: 8px; font-size: 0.58rem; font-weight: 600; }
.priority-critical { background: var(--red-dim); color: var(--red); }
.priority-high { background: var(--orange-dim); color: var(--orange); }
.priority-medium { background: var(--accent-dim); color: var(--accent-cb); }

/* ══════════════════════════════════════════════════════════════════════════
   BILINGUAL ANALYSIS VIEW
   ══════════════════════════════════════════════════════════════════════════ */

.bilingual-unified { border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; background: var(--bg-secondary); }
.bilingual-unified-header {
  display: flex; align-items: center; gap: 8px; padding: 10px 16px;
  background: var(--bg-tertiary); border-bottom: 1px solid var(--border);
  font-size: 0.78rem; font-weight: 600; color: var(--text-secondary);
}
.lang-tag { padding: 2px 6px; border-radius: 4px; font-size: 0.6rem; font-weight: 600; }
.lang-tag.en { background: rgba(59,130,246,0.15); color: #60a5fa; }
.lang-tag.cn { background: rgba(239,68,68,0.15); color: #f87171; }
.copy-analysis-btn {
  margin-left: auto; padding: 3px 10px; border-radius: 4px; font-size: 0.68rem;
  background: var(--bg-input); border: 1px solid var(--border); color: var(--text-secondary);
  cursor: pointer; transition: all 0.2s;
}
.copy-analysis-btn:hover { border-color: var(--accent-cb); color: var(--accent-cb); }
.copy-analysis-btn.copied { background: var(--green-dim); border-color: var(--green); color: var(--green); }
.bilingual-unified-body { padding: 4px 0; }
.bi-block { border-bottom: 1px solid var(--border); }
.bi-block:last-child { border-bottom: none; }
.bi-en { padding: 12px 18px; font-size: 0.82rem; line-height: 1.65; color: var(--text-primary); }
.bi-cn { padding: 10px 18px; font-size: 0.8rem; line-height: 1.7; color: var(--text-secondary); font-family: var(--font-cn); background: rgba(14,165,233,0.02); border-left: 2px solid var(--accent-dim); margin: 0 12px 8px; border-radius: 0 var(--radius) var(--radius) 0; }
.bi-en h1,.bi-en h2,.bi-en h3,.bi-cn h1,.bi-cn h2,.bi-cn h3 { color: var(--text-primary); margin: 12px 0 6px; }
.bi-en h2,.bi-cn h2 { font-size: 1rem; }
.bi-en h3,.bi-cn h3 { font-size: 0.88rem; }
.bi-en ul,.bi-cn ul,.bi-en ol,.bi-cn ol { padding-left: 18px; margin: 6px 0; }
.bi-en li,.bi-cn li { margin-bottom: 3px; }
.bi-en strong,.bi-cn strong { color: var(--text-primary); }
.bi-en code,.bi-cn code { background: var(--bg-input); padding: 1px 5px; border-radius: 3px; font-family: var(--font-mono); font-size: 0.82em; }
.bi-en blockquote,.bi-cn blockquote { border-left: 3px solid var(--accent-cb); padding: 6px 12px; margin: 8px 0; background: var(--accent-dim); border-radius: 0 4px 4px 0; }
.bi-en table,.bi-cn table { width: 100%; border-collapse: collapse; margin: 8px 0; font-size: 0.78rem; }
.bi-en th,.bi-cn th { background: var(--bg-tertiary); padding: 6px 8px; text-align: left; font-weight: 600; border-bottom: 1px solid var(--border); }
.bi-en td,.bi-cn td { padding: 5px 8px; border-bottom: 1px solid var(--border); }

/* ── Freshness ── */
.freshness-badge { font-size: 0.6rem; padding: 1px 6px; border-radius: 6px; font-family: var(--font-mono); }
.freshness-fresh { background: var(--green-dim); color: var(--green); }
.freshness-recent { background: rgba(59,130,246,0.12); color: #60a5fa; }
.freshness-stale { background: var(--orange-dim); color: var(--orange); }
.freshness-old { background: var(--red-dim); color: var(--red); }

/* ══════════════════════════════════════════════════════════════════════════
   RISK TABLE
   ══════════════════════════════════════════════════════════════════════════ */

.risk-table { width: 100%; border-collapse: collapse; font-size: 0.78rem; }
.risk-table thead th { background: var(--bg-tertiary); padding: 8px 10px; text-align: left; font-weight: 600; color: var(--text-secondary); font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.3px; border-bottom: 1px solid var(--border); }
.risk-table tbody td { padding: 8px 10px; border-bottom: 1px solid var(--border); vertical-align: top; }
.risk-table tbody tr:hover { background: var(--bg-hover); }
.risk-score { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%; font-weight: 700; font-size: 0.78rem; font-family: var(--font-mono); }
.score-high { background: var(--red-dim); color: var(--red); }
.score-medium { background: var(--orange-dim); color: var(--orange); }
.score-low { background: var(--green-dim); color: var(--green); }
.trend-badge { font-size: 0.68rem; padding: 2px 6px; border-radius: 6px; font-weight: 500; }
.trend-improving { background: var(--green-dim); color: var(--green); }
.trend-stable { background: rgba(59,130,246,0.12); color: #60a5fa; }
.trend-deteriorating { background: var(--red-dim); color: var(--red); }
.trend-volatile { background: var(--orange-dim); color: var(--orange); }

/* ══════════════════════════════════════════════════════════════════════════
   TODO LIST
   ══════════════════════════════════════════════════════════════════════════ */

.todo-section { background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 14px; }
.todo-input-row { display: flex; gap: 6px; margin-bottom: 10px; }
.todo-list { display: flex; flex-direction: column; gap: 4px; }
.todo-item { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-radius: var(--radius); background: var(--bg-tertiary); }
.todo-item.done { opacity: 0.5; }
.todo-item.done .todo-text { text-decoration: line-through; }
.todo-check { cursor: pointer; font-size: 0.9rem; }
.todo-text { flex: 1; font-size: 0.8rem; }
.todo-project-tag { font-size: 0.6rem; padding: 1px 6px; border-radius: 6px; font-weight: 600; }
.todo-project-tag.cb { background: rgba(14,165,233,0.12); color: var(--accent-cb); }
.todo-project-tag.ss { background: var(--violet-dim); color: var(--accent-ss); }
.todo-delete { cursor: pointer; font-size: 0.75rem; opacity: 0.4; }
.todo-delete:hover { opacity: 1; }

/* ══════════════════════════════════════════════════════════════════════════
   CHECKLIST
   ══════════════════════════════════════════════════════════════════════════ */

.checklist-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 6px; }
.checklist-item { display: flex; align-items: center; gap: 8px; padding: 8px 10px; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius); font-size: 0.78rem; }
.checklist-status { font-size: 0.9rem; }
.checklist-label { color: var(--text-primary); }

/* ══════════════════════════════════════════════════════════════════════════
   DOCUMENTS
   ══════════════════════════════════════════════════════════════════════════ */

.upload-zone {
  border: 2px dashed var(--border); border-radius: var(--radius-lg);
  padding: 28px; text-align: center; cursor: pointer; transition: all 0.2s; margin-bottom: 16px;
}
.upload-zone:hover, .upload-zone.dragover { border-color: var(--accent-cb); background: var(--accent-dim); }
.upload-icon { font-size: 1.8rem; display: block; margin-bottom: 6px; }
.upload-text { font-size: 0.82rem; font-weight: 500; color: var(--text-primary); }
.upload-hint { font-size: 0.68rem; color: var(--text-muted); margin-top: 4px; }

.doc-list { display: flex; flex-direction: column; gap: 6px; }
.doc-item {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px;
  background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: var(--radius); transition: border-color 0.15s;
}
.doc-item:hover { border-color: var(--border-light); }
.doc-icon { font-size: 1.1rem; }
.doc-info { flex: 1; min-width: 0; }
.doc-name { font-size: 0.8rem; font-weight: 600; color: var(--text-primary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.doc-meta { display: flex; gap: 10px; font-size: 0.62rem; color: var(--text-muted); margin-top: 2px; }
.doc-status { font-size: 0.62rem; padding: 2px 8px; border-radius: 6px; font-weight: 600; text-transform: uppercase; }
.doc-status.pending { background: var(--orange-dim); color: var(--orange); }
.doc-status.approved { background: var(--green-dim); color: var(--green); }
.doc-status.rejected { background: var(--red-dim); color: var(--red); }

/* ══════════════════════════════════════════════════════════════════════════
   COMMENTS
   ══════════════════════════════════════════════════════════════════════════ */

.comments-section { margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--border); }
.comments-title { font-size: 0.82rem; font-weight: 600; color: var(--text-secondary); margin-bottom: 10px; }
.comment-input-row { display: flex; gap: 6px; margin-bottom: 10px; }
.comment-list { display: flex; flex-direction: column; gap: 6px; }
.comment-item { display: flex; gap: 8px; padding: 8px 10px; background: var(--bg-secondary); border-radius: var(--radius); border: 1px solid var(--border); }
.comment-avatar { font-size: 1rem; flex-shrink: 0; }
.comment-body { flex: 1; min-width: 0; }
.comment-header { display: flex; gap: 8px; align-items: baseline; margin-bottom: 2px; }
.comment-author { font-size: 0.72rem; font-weight: 600; color: var(--accent-cb); }
.comment-time { font-size: 0.6rem; color: var(--text-muted); font-family: var(--font-mono); }
.comment-text { font-size: 0.78rem; color: var(--text-primary); }
.comment-delete { opacity: 0.3; font-size: 0.7rem; }
.comment-delete:hover { opacity: 1; }

/* ══════════════════════════════════════════════════════════════════════════
   MILESTONES
   ══════════════════════════════════════════════════════════════════════════ */

.milestone-track { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 6px; }
.milestone-card {
  flex-shrink: 0; width: 220px; padding: 12px; border-radius: var(--radius-lg);
  background: var(--bg-secondary); border: 1px solid var(--border); text-align: center;
  transition: all 0.2s;
}
.milestone-card.active { border-color: var(--accent-cb); background: var(--accent-dim); }
.milestone-card.completed { border-color: var(--green); opacity: 0.6; }
.milestone-month { font-size: 0.58rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }
.milestone-name { font-size: 0.78rem; font-weight: 600; color: var(--text-primary); margin: 4px 0 2px; }
.milestone-dates { font-size: 0.58rem; color: var(--text-muted); font-family: var(--font-mono); }
.milestone-project { font-size: 0.58rem; font-weight: 600; margin-top: 3px; }

/* ══════════════════════════════════════════════════════════════════════════
   AI CHAT
   ══════════════════════════════════════════════════════════════════════════ */

.chat-container { display: flex; flex-direction: column; height: calc(100vh - 180px); }
.chat-messages { flex: 1; overflow-y: auto; padding: 16px 0; display: flex; flex-direction: column; gap: 12px; }
.chat-msg { display: flex; gap: 10px; max-width: 85%; }
.chat-msg.user { align-self: flex-end; flex-direction: row-reverse; }
.chat-msg.ai { align-self: flex-start; }
.msg-avatar { width: 30px; height: 30px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 0.85rem; flex-shrink: 0; background: var(--bg-tertiary); border: 1px solid var(--border); }
.ai-avatar { background: linear-gradient(135deg, var(--accent-cb), var(--accent-ss)) !important; color: #fff; font-size: 0.6rem; font-weight: 700; border: none !important; }
.msg-bubble {
  padding: 10px 14px; border-radius: var(--radius-lg);
  font-size: 0.82rem; line-height: 1.6; max-width: 100%; overflow-wrap: break-word;
}
.chat-msg.user .msg-bubble { background: var(--accent-cb); color: #fff; border-bottom-right-radius: 4px; }
.chat-msg.ai .msg-bubble { background: var(--bg-secondary); border: 1px solid var(--border); color: var(--text-primary); border-bottom-left-radius: 4px; }
.chat-context-badge { font-size: 0.62rem; padding: 2px 6px; background: rgba(255,255,255,0.15); border-radius: 4px; }
.chat-input-row { display: flex; gap: 8px; padding-top: 12px; border-top: 1px solid var(--border); }
.ai-typing { display: flex; gap: 4px; padding: 4px 0; }
.ai-typing span { width: 6px; height: 6px; border-radius: 50%; background: var(--text-muted); animation: typing 1.2s infinite; }
.ai-typing span:nth-child(2) { animation-delay: 0.2s; }
.ai-typing span:nth-child(3) { animation-delay: 0.4s; }
@keyframes typing { 0%,60%,100% { opacity: 0.3; transform: translateY(0); } 30% { opacity: 1; transform: translateY(-4px); } }

/* ══════════════════════════════════════════════════════════════════════════
   FLOATING AI BUBBLE
   ══════════════════════════════════════════════════════════════════════════ */

.floating-ai-bubble {
  position: fixed; bottom: 24px; right: 24px; z-index: 200;
  width: 48px; height: 48px; border-radius: 50%; cursor: pointer;
  background: linear-gradient(135deg, var(--accent-cb), var(--accent-ss));
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 20px rgba(14,165,233,0.3);
  transition: transform 0.2s;
}
.floating-ai-bubble:hover { transform: scale(1.1); }
.fab-icon { color: #fff; font-weight: 700; font-size: 0.75rem; }
.fab-pulse { position: absolute; inset: -3px; border-radius: 50%; border: 2px solid var(--accent-cb); animation: fabPulse 2s infinite; }
@keyframes fabPulse { 0%,100% { opacity: 0; transform: scale(1); } 50% { opacity: 0.5; transform: scale(1.15); } }

.floating-chat-popup {
  position: fixed; bottom: 80px; right: 24px; z-index: 200;
  width: 340px; background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: var(--radius-lg); box-shadow: 0 8px 30px rgba(0,0,0,0.4);
  display: none; flex-direction: column; overflow: hidden;
}
.floating-chat-popup.show { display: flex; }
.fcp-header { display: flex; align-items: center; justify-content: space-between; padding: 10px 14px; border-bottom: 1px solid var(--border); }
.fcp-title { display: flex; align-items: center; gap: 8px; }
.ai-avatar-sm { width: 24px; height: 24px; border-radius: 50%; background: linear-gradient(135deg, var(--accent-cb), var(--accent-ss)); display: flex; align-items: center; justify-content: center; color: #fff; font-size: 0.55rem; font-weight: 700; }
.fcp-body { padding: 12px; }
.fcp-hint { display: flex; gap: 6px; font-size: 0.68rem; color: var(--text-muted); padding: 8px 10px; background: var(--bg-tertiary); border-radius: var(--radius); margin-bottom: 8px; }
.fcp-suggestions { display: flex; flex-direction: column; gap: 4px; }
.fcp-suggest-btn { padding: 6px 10px; background: var(--bg-tertiary); border: 1px solid var(--border); border-radius: var(--radius); color: var(--text-secondary); font-size: 0.72rem; cursor: pointer; text-align: left; transition: all 0.15s; font-family: var(--font-ui); }
.fcp-suggest-btn:hover { border-color: var(--accent-cb); color: var(--text-primary); }
.fcp-input-row { display: flex; gap: 6px; padding: 10px 12px; border-top: 1px solid var(--border); }

/* ══════════════════════════════════════════════════════════════════════════
   ADVISOR BUBBLES
   ══════════════════════════════════════════════════════════════════════════ */

.advisor-bubbles { position: fixed; right: 24px; bottom: 80px; z-index: 190; display: flex; flex-direction: column-reverse; gap: 6px; }
.advisor-bubble {
  width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  cursor: pointer; font-size: 0.9rem; border: 1px solid; transition: all 0.2s; position: relative;
}
.advisor-bubble:hover { transform: scale(1.15); z-index: 5; }
.advisor-bubble.active { transform: scale(1.2); box-shadow: 0 0 10px rgba(14,165,233,0.3); }
.advisor-bubble.adv-has-alert::after {
  content: ''; position: absolute; top: -2px; right: -2px; width: 8px; height: 8px;
  border-radius: 50%; background: #f59e0b; border: 1.5px solid var(--bg-primary);
  animation: advAlertPulse 2s infinite;
}
@keyframes advAlertPulse { 0%,100% { transform:scale(1); opacity:1; } 50% { transform:scale(1.3); opacity:.7; } }
.adv-tooltip {
  position: absolute; right: 46px; top: 50%; transform: translateY(-50%);
  background: var(--bg-secondary); border: 1px solid var(--border); padding: 3px 8px;
  border-radius: 4px; font-size: 0.62rem; color: var(--text-secondary);
  white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity 0.2s;
}
.advisor-bubble:hover .adv-tooltip { opacity: 1; }

.advisor-chat-popup {
  position: fixed; bottom: 80px; right: 70px; z-index: 210;
  width: 380px; max-height: 500px; background: var(--bg-secondary);
  border: 1px solid var(--border); border-radius: var(--radius-lg);
  box-shadow: 0 8px 30px rgba(0,0,0,0.4);
  display: none; flex-direction: column; overflow: hidden;
}
.advisor-chat-popup.show { display: flex; }
.acp-header { display: flex; align-items: center; justify-content: space-between; padding: 10px 14px; border-bottom: 1px solid var(--border); }
.acp-title { display: flex; align-items: center; gap: 8px; }
.acp-avatar { font-size: 1.2rem; }
.acp-messages { flex: 1; overflow-y: auto; padding: 12px; max-height: 320px; display: flex; flex-direction: column; gap: 8px; }
.acp-welcome { text-align: center; padding: 20px 10px; color: var(--text-secondary); font-size: 0.82rem; }
.acp-welcome-icon { font-size: 1.8rem; display: block; margin-bottom: 8px; }
.acp-msg { display: flex; gap: 6px; }
.acp-msg.user { align-self: flex-end; flex-direction: row-reverse; }
.acp-msg-avatar { font-size: 0.85rem; flex-shrink: 0; }
.acp-msg-bubble { padding: 8px 12px; border-radius: var(--radius); font-size: 0.78rem; line-height: 1.55; max-width: 85%; }
.acp-msg.user .acp-msg-bubble { background: var(--accent-cb); color: #fff; }
.acp-msg.ai .acp-msg-bubble { background: var(--bg-tertiary); border: 1px solid var(--border); }
.acp-msg.alert { align-self: stretch; }
.acp-msg.alert .acp-msg-bubble { border-left: 3px solid #f59e0b; background: rgba(245,158,11,0.08); max-width: 100%; font-size: 0.75rem; color: var(--text-primary); }
.acp-msg.alert .acp-msg-bubble.opinion { border-left-color: var(--accent-cb); background: rgba(14,165,233,0.06); }
.acp-alert-time { font-size: 0.6rem; color: var(--text-muted); margin-top: 3px; }
.acp-input-row { display: flex; gap: 6px; padding: 8px 12px; border-top: 1px solid var(--border); }

/* ══════════════════════════════════════════════════════════════════════════
   THINK TANK
   ══════════════════════════════════════════════════════════════════════════ */

.tt-board-intro { margin-bottom: 20px; }
.tt-table-visual { display: flex; flex-direction: column; align-items: center; gap: 14px; padding: 20px; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-lg); }
.tt-table-center { text-align: center; }
.tt-table-icon { font-size: 1.5rem; }
.tt-table-label { font-size: 0.72rem; color: var(--text-muted); margin-top: 4px; }
.tt-seats { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.tt-seat { text-align: center; padding: 8px 10px; background: var(--bg-tertiary); border: 1px solid var(--border); border-radius: var(--radius); min-width: 80px; transition: all 0.3s; }
.tt-seat.thinking { border-color: var(--orange); animation: seatThink 1.5s infinite; }
.tt-seat.done { border-color: var(--green); }
@keyframes seatThink { 0%,100% { box-shadow: none; } 50% { box-shadow: 0 0 8px var(--orange-dim); } }
.seat-avatar { font-size: 1.2rem; display: block; }
.seat-name { font-size: 0.62rem; font-weight: 600; color: var(--text-primary); margin-top: 2px; }
.seat-role { font-size: 0.55rem; color: var(--text-muted); font-family: var(--font-cn); }

.tt-input-section { margin-bottom: 20px; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 16px; }
.tt-input-header { display: flex; gap: 8px; align-items: center; margin-bottom: 10px; }
.tt-input-row { display: flex; gap: 8px; margin-bottom: 8px; }
.tt-quick-topics { display: flex; gap: 6px; flex-wrap: wrap; }

.tt-results { margin-top: 16px; }
.tt-results-header { margin-bottom: 12px; }
.tt-results-header h4 { font-size: 0.95rem; }
.tt-topic-display { font-size: 0.82rem; color: var(--accent-cb); margin-top: 4px; padding: 8px 12px; background: var(--accent-dim); border-radius: var(--radius); }
.tt-advisor-responses { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; margin-bottom: 16px; }
.tt-advisor-card { background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; }
.tt-advisor-card.loading .tt-advisor-card-body { display: flex; align-items: center; justify-content: center; padding: 20px; }
.tt-advisor-card-header { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--border); }
.ttac-avatar { font-size: 1.1rem; }
.ttac-info { flex: 1; }
.ttac-name { font-size: 0.78rem; font-weight: 600; }
.ttac-role { font-size: 0.62rem; color: var(--text-muted); }
.ttac-status { font-size: 0.6rem; padding: 2px 8px; border-radius: 8px; font-weight: 600; white-space: nowrap; }
.tt-advisor-card-body { padding: 12px; font-size: 0.78rem; line-height: 1.6; max-height: 300px; overflow-y: auto; }
.tt-consensus { background: var(--bg-secondary); border: 1px solid var(--accent-cb); border-radius: var(--radius-lg); overflow: hidden; }
.tt-consensus-header { display: flex; align-items: center; gap: 8px; padding: 12px 16px; background: var(--accent-dim); border-bottom: 1px solid var(--border); font-size: 0.88rem; }
.tt-consensus-body { padding: 16px; font-size: 0.82rem; line-height: 1.65; }

/* ══════════════════════════════════════════════════════════════════════════
   AUDIT LOG
   ══════════════════════════════════════════════════════════════════════════ */

.audit-list { display: flex; flex-direction: column; gap: 4px; }
.audit-item { display: flex; gap: 10px; padding: 8px 10px; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius); font-size: 0.78rem; align-items: baseline; }
.audit-time { font-size: 0.62rem; color: var(--text-muted); font-family: var(--font-mono); white-space: nowrap; min-width: 100px; }
.audit-user { font-weight: 600; color: var(--accent-cb); min-width: 80px; font-size: 0.72rem; }
.audit-action { color: var(--text-secondary); flex: 1; }

/* ══════════════════════════════════════════════════════════════════════════
   MODALS
   ══════════════════════════════════════════════════════════════════════════ */

.modal-overlay {
  position: fixed; inset: 0; z-index: 500; display: none;
  align-items: center; justify-content: center;
  background: rgba(0,0,0,0.6); backdrop-filter: blur(4px);
}
.modal-overlay.show { display: flex; }
.modal-content {
  width: 90%; max-width: 700px; max-height: 85vh; overflow-y: auto;
  background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 24px;
  box-shadow: 0 16px 48px rgba(0,0,0,0.4);
}
.modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.modal-title { font-size: 1rem; font-weight: 700; }
.modal-close { background: none; border: none; color: var(--text-muted); font-size: 1.5rem; cursor: pointer; padding: 0 4px; }
.modal-close:hover { color: var(--text-primary); }

/* Settings */
.settings-group { margin-bottom: 16px; padding-bottom: 12px; border-bottom: 1px solid var(--border); }
.settings-group h4 { font-size: 0.82rem; margin-bottom: 8px; color: var(--text-secondary); }
.settings-row { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.settings-row label { font-size: 0.78rem; color: var(--text-secondary); min-width: 80px; }

/* ══════════════════════════════════════════════════════════════════════════
   LOADING & WELCOME STATES
   ══════════════════════════════════════════════════════════════════════════ */

.loading-state { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px 20px; gap: 12px; }
.spinner {
  width: 32px; height: 32px; border-radius: 50%;
  border: 3px solid var(--border); border-top-color: var(--accent-cb);
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.loading-text { font-size: 0.78rem; color: var(--text-muted); text-align: center; }
.agent-status { display: flex; flex-direction: column; gap: 6px; }
.agent-step { font-size: 0.75rem; color: var(--text-muted); padding: 4px 10px; border-radius: var(--radius); transition: all 0.3s; }
.agent-step.active { color: var(--accent-cb); background: var(--accent-dim); }
.agent-step.done { color: var(--green); }
.welcome-state { text-align: center; padding: 40px 20px; }
.welcome-icon { font-size: 2rem; display: block; margin-bottom: 10px; }
.welcome-state h4 { font-size: 1rem; margin-bottom: 6px; }
.welcome-state p { font-size: 0.82rem; color: var(--text-muted); margin-bottom: 4px; }

/* ══════════════════════════════════════════════════════════════════════════
   GLOBAL SEARCH (Ctrl+K)
   ══════════════════════════════════════════════════════════════════════════ */

.search-modal-overlay { z-index: 600; }
.search-modal { width: 90%; max-width: 540px; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; box-shadow: 0 16px 48px rgba(0,0,0,0.5); }
.search-input-wrap { display: flex; align-items: center; gap: 8px; padding: 12px 16px; border-bottom: 1px solid var(--border); }
.search-icon { font-size: 1rem; }
.search-input { flex: 1; background: none; border: none; color: var(--text-primary); font-size: 0.92rem; font-family: var(--font-ui); outline: none; }
.search-input::placeholder { color: var(--text-muted); }
.search-kbd { font-size: 0.58rem; padding: 2px 6px; border-radius: 3px; background: var(--bg-tertiary); color: var(--text-muted); font-family: var(--font-mono); border: 1px solid var(--border); }
.search-results { max-height: 320px; overflow-y: auto; padding: 8px; }
.search-group-title { font-size: 0.62rem; color: var(--text-muted); padding: 6px 10px; text-transform: uppercase; letter-spacing: 0.5px; }
.search-result-item { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: var(--radius); cursor: pointer; transition: background 0.1s; }
.search-result-item:hover { background: var(--bg-hover); }
.sri-icon { font-size: 1rem; width: 24px; text-align: center; }
.sri-label { flex: 1; font-size: 0.82rem; }
.sri-hint { font-size: 0.62rem; color: var(--text-muted); padding: 2px 6px; background: var(--bg-tertiary); border-radius: 4px; }

/* ══════════════════════════════════════════════════════════════════════════
   TOASTS
   ══════════════════════════════════════════════════════════════════════════ */

.toast-container { position: fixed; top: 70px; right: 16px; z-index: 900; display: flex; flex-direction: column; gap: 6px; max-width: 340px; }
.toast {
  display: flex; align-items: flex-start; gap: 8px; padding: 10px 14px;
  background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: 0 4px 16px rgba(0,0,0,0.3);
  animation: toastIn 0.25s ease; position: relative; overflow: hidden;
}
.toast.success { border-left: 3px solid var(--green); }
.toast.error { border-left: 3px solid var(--red); }
.toast.warning { border-left: 3px solid var(--orange); }
.toast.info { border-left: 3px solid var(--accent-cb); }
@keyframes toastIn { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: none; } }
.toast-out { animation: toastOut 0.3s ease forwards; }
@keyframes toastOut { to { opacity: 0; transform: translateX(20px); } }
.toast-icon { font-size: 0.9rem; flex-shrink: 0; }
.toast-body { flex: 1; min-width: 0; }
.toast-title { font-size: 0.78rem; font-weight: 600; color: var(--text-primary); }
.toast-msg { font-size: 0.68rem; color: var(--text-muted); margin-top: 2px; }
.toast-close { background: none; border: none; color: var(--text-muted); cursor: pointer; font-size: 0.9rem; padding: 0; }
.toast-progress { position: absolute; bottom: 0; left: 0; height: 2px; background: var(--accent-cb); animation: toastProg linear forwards; width: 100%; }
@keyframes toastProg { from { width: 100%; } to { width: 0; } }

/* ══════════════════════════════════════════════════════════════════════════
   RESPONSIVE
   ══════════════════════════════════════════════════════════════════════════ */

@media (max-width: 768px) {
  .sidebar { display: none; position: fixed; top: 52px; left: 0; bottom: 0; z-index: 999; width: 220px; }
  .sidebar.mobile-open { display: flex; }
  .main-content { margin-left: 0; padding: 14px; }
  .overview-grid { grid-template-columns: 1fr; }
  .card-kpi-wide, .card-timeline-wide { grid-column: span 1; }
  .risk-charts-row { grid-template-columns: 1fr; }
  .header-meta { display: none; }
  .tt-advisor-responses { grid-template-columns: 1fr; }
  .mobile-menu-btn { display: inline-flex !important; }
}
@media (min-width: 769px) {
  .mobile-menu-btn { display: none !important; }
}

/* ══════════════════════════════════════════════════════════════════════════
   CHECKLIST INTERACTIVE
   ══════════════════════════════════════════════════════════════════════════ */
.checklist-item { transition: background 0.15s; border-radius: 4px; padding: 4px 8px; }
.checklist-item:hover { background: var(--bg-input); }
.checklist-item.done .checklist-status { color: var(--green); }
.checklist-item.active .checklist-status { color: var(--accent-cb); }
.checklist-item.blocked .checklist-status { color: var(--red); }

/* ══════════════════════════════════════════════════════════════════════════
   LIVE NEWS FEEDS
   ══════════════════════════════════════════════════════════════════════════ */
.feed-status-bar {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 16px; margin: 0 0 12px;
  background: var(--bg-input); border-radius: 8px;
  font-size: 0.78rem; color: var(--text-secondary);
  border: 1px solid var(--border);
}
.feed-status-bar.live { border-color: var(--green); }
.feed-status-bar.live .feed-status-icon { color: var(--green); }
.feed-status-bar.error { border-color: var(--red); }

.financial-ticker {
  display: flex; gap: 16px; padding: 10px 16px; margin: 0 0 12px;
  background: linear-gradient(135deg, rgba(14,165,233,0.06), rgba(139,92,246,0.06));
  border-radius: 8px; border: 1px solid var(--border);
  overflow-x: auto; white-space: nowrap;
}
.ticker-item {
  display: flex; align-items: center; gap: 6px;
  font-size: 0.78rem; color: var(--text-secondary);
}
.ticker-item .ticker-label { color: var(--text-muted); }
.ticker-item .ticker-value {
  font-family: var(--font-mono); font-weight: 600;
  color: var(--accent-cb);
}
.ticker-item .ticker-date { color: var(--text-muted); font-size: 0.7rem; }

.live-feeds-container {
  margin: 0 0 16px;
  border: 1px solid var(--border); border-radius: 10px;
  background: var(--bg-secondary); overflow: hidden;
}
.live-feeds-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 16px; border-bottom: 1px solid var(--border);
  background: var(--bg-tertiary);
}
.live-feeds-header h4 { margin: 0; font-size: 0.85rem; color: var(--text-primary); }
.feed-filter-tabs {
  display: flex; gap: 4px; flex-wrap: wrap;
}
.feed-filter-tab {
  padding: 3px 10px; border-radius: 12px; font-size: 0.68rem;
  border: 1px solid var(--border); background: transparent;
  color: var(--text-muted); cursor: pointer; transition: all 0.15s;
}
.feed-filter-tab:hover, .feed-filter-tab.active {
  background: var(--accent-dim); border-color: var(--accent-cb);
  color: var(--accent-cb);
}

.feed-articles-list {
  max-height: 420px; overflow-y: auto;
  padding: 8px 0;
}
.feed-article {
  display: flex; gap: 10px; padding: 10px 16px;
  border-bottom: 1px solid var(--border);
  transition: background 0.12s; cursor: default;
}
.feed-article:last-child { border-bottom: none; }
.feed-article:hover { background: var(--bg-hover); }
.feed-article-cat {
  flex-shrink: 0; width: 6px; border-radius: 3px;
  align-self: stretch;
}
.feed-article-cat.carbon { background: var(--green); }
.feed-article-cat.carbon-market { background: #00d4aa; }
.feed-article-cat.eu { background: var(--accent-cb); }
.feed-article-cat.china { background: var(--red); }
.feed-article-cat.china-policy { background: #ff6b6b; }
.feed-article-cat.hr { background: var(--purple); }
.feed-article-cat.trade { background: var(--orange); }
.feed-article-cat.patent { background: #4ecdc4; }
.feed-article-cat.startup { background: #ffd93d; }
.feed-article-cat.default { background: var(--text-muted); }

/* News alert highlighting */
.feed-article.feed-alert { border-left: 3px solid var(--red); background: rgba(255, 107, 107, 0.06); position: relative; }
.feed-alert-badge { position: absolute; top: 6px; right: 8px; font-size: 0.65rem; padding: 1px 6px; border-radius: 6px; background: var(--red); color: #fff; font-weight: 700; letter-spacing: .5px; }

/* Ticker icon flags */
.ticker-icon { font-size: 0.8rem; margin-right: 2px; }

/* ═══ GANTT CHART ═══ */
.gantt-container { margin-bottom: 24px; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; background: var(--bg-card); }
.gantt-header { position: relative; height: 32px; background: var(--bg-input); border-bottom: 1px solid var(--border); }
.gantt-months { display: flex; height: 100%; position: relative; }
.gantt-month { position: absolute; top: 0; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 0.65rem; font-weight: 600; color: var(--text-muted); border-right: 1px solid var(--border); }
.gantt-today { position: absolute; top: 0; bottom: -600px; width: 2px; background: var(--red); z-index: 5; opacity: 0.7; }
.gantt-today::before { content: '▼'; position: absolute; top: -2px; left: -5px; font-size: 0.55rem; color: var(--red); }
.gantt-body { padding: 8px 0; }
.gantt-row { display: flex; align-items: center; padding: 3px 8px; gap: 8px; }
.gantt-row:hover { background: var(--bg-input); }
.gantt-label { width: 140px; min-width: 140px; font-size: 0.7rem; color: var(--text-primary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gantt-track { flex: 1; position: relative; height: 20px; background: var(--bg-input); border-radius: 4px; overflow: hidden; }
.gantt-bar { position: absolute; top: 2px; height: 16px; border-radius: 3px; border: 1px solid; overflow: hidden; transition: all 0.3s; }
.gantt-bar.active { opacity: 1; }
.gantt-bar.completed { opacity: 0.6; }
.gantt-fill { height: 100%; border-radius: 2px; transition: width 0.3s; }

/* ═══ KANBAN BOARD ═══ */
.kanban-board { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; margin-bottom: 20px; }
@media (max-width: 768px) { .kanban-board { grid-template-columns: 1fr; } }
.kanban-col { background: var(--bg-input); border-radius: 10px; padding: 0; min-height: 120px; }
.kanban-col-header { padding: 10px 14px; font-size: 0.78rem; font-weight: 700; border-radius: 10px 10px 0 0; display: flex; align-items: center; gap: 8px; }
.kanban-col-header.kanban-pending { background: rgba(255, 193, 7, 0.12); color: var(--orange); }
.kanban-col-header.kanban-progress { background: rgba(0, 123, 255, 0.12); color: var(--accent-cb); }
.kanban-col-header.kanban-done { background: rgba(40, 167, 69, 0.12); color: var(--green); }
.kanban-count { background: var(--bg-card); padding: 1px 8px; border-radius: 10px; font-size: 0.68rem; }
.kanban-list { padding: 8px; display: flex; flex-direction: column; gap: 6px; }
.kanban-empty { text-align: center; padding: 20px; color: var(--text-muted); font-size: 0.75rem; }
.kanban-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; padding: 10px 12px; transition: transform 0.15s, box-shadow 0.15s; }
.kanban-card:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(0,0,0,0.15); }
.kanban-card-header { display: flex; align-items: center; gap: 6px; margin-bottom: 4px; }
.kanban-card-text { font-size: 0.78rem; color: var(--text-primary); margin-bottom: 6px; line-height: 1.3; }
.kanban-card-footer { display: flex; justify-content: space-between; align-items: center; }
.kanban-assignee { font-size: 0.65rem; color: var(--text-muted); }
.kanban-actions { display: flex; gap: 4px; }
.kanban-move, .kanban-del { border: none; background: var(--bg-input); color: var(--text-muted); width: 22px; height: 22px; border-radius: 4px; cursor: pointer; font-size: 0.7rem; display: flex; align-items: center; justify-content: center; transition: all 0.15s; }
.kanban-move:hover { background: var(--accent-cb); color: #fff; }
.kanban-del:hover { background: var(--red); color: #fff; }

/* ═══ COMPLIANCE ALERT BANNER ═══ */
.compliance-alert-banner { background: rgba(255, 107, 107, 0.08); border: 1px solid var(--red); border-radius: 12px; padding: 14px 18px; margin-bottom: 16px; animation: slideDown 0.3s ease-out; }
@keyframes slideDown { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }
.compliance-alert-header { display: flex; align-items: center; justify-content: space-between; font-weight: 700; font-size: 0.85rem; margin-bottom: 8px; color: var(--red); }
.compliance-alert-item { font-size: 0.78rem; padding: 4px 0; color: var(--text-primary); display: flex; align-items: center; gap: 8px; }

/* ═══ CHAT FILE ATTACHMENT ═══ */
.chat-attach-btn { cursor: pointer; font-size: 1.3rem; padding: 8px 4px; transition: transform 0.15s; display: flex; align-items: center; }
.chat-attach-btn:hover { transform: scale(1.15); }
.chat-file-preview { display: flex; align-items: center; gap: 8px; padding: 6px 12px; background: var(--bg-input); border-radius: 8px; margin-top: 6px; font-size: 0.78rem; }
.chat-file-name { color: var(--accent-cb); font-weight: 600; }
.feed-article-body { flex: 1; min-width: 0; }
.feed-article-title {
  font-size: 0.82rem; font-weight: 500; color: var(--text-primary);
  margin: 0 0 3px; line-height: 1.35;
}
.feed-article-title a {
  color: inherit; text-decoration: none;
}
.feed-article-title a:hover { color: var(--accent-cb); }
.feed-article-desc {
  font-size: 0.72rem; color: var(--text-muted); line-height: 1.4;
  margin: 0 0 4px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}
.feed-article-meta {
  display: flex; gap: 10px; font-size: 0.68rem; color: var(--text-muted);
}
.feed-article-source { color: var(--accent-cb); }
.feed-article-category {
  padding: 1px 6px; border-radius: 6px;
  background: var(--accent-dim); color: var(--accent-cb);
  font-size: 0.65rem;
}

/* ── AI Usage Monitor ── */
.usage-monitor {
  display: flex; flex-direction: column; gap: 10px;
  max-height: 360px; overflow-y: auto; padding: 2px 0;
}
.usage-card {
  background: var(--bg-input); border: 1px solid var(--border);
  border-radius: 10px; padding: 12px 14px;
}
.usage-card-header {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 8px;
}
.usage-card-header strong { font-size: 0.85rem; color: var(--text-primary); }
.usage-calls-badge {
  font-size: 0.72rem; font-family: var(--font-mono);
  padding: 2px 8px; border-radius: 10px;
  background: var(--accent-dim); color: var(--accent-cb);
}
.usage-bar-wrap {
  width: 100%; height: 6px; border-radius: 3px;
  background: var(--bg-tertiary); overflow: hidden; margin-bottom: 4px;
}
.usage-bar {
  height: 100%; border-radius: 3px;
  transition: width 0.4s ease;
}
.usage-quota-text {
  font-size: 0.72rem; color: var(--text-muted);
  font-family: var(--font-mono); margin-bottom: 6px;
}
.usage-stats-row {
  display: flex; gap: 12px; font-size: 0.72rem; color: var(--text-secondary);
  margin-bottom: 4px;
}
.usage-models { margin-top: 6px; }
.usage-models summary {
  font-size: 0.72rem; color: var(--text-muted); cursor: pointer;
}
.usage-model-list { padding: 4px 0 0 8px; }
.usage-model-row {
  display: flex; justify-content: space-between;
  font-size: 0.7rem; padding: 2px 0; color: var(--text-secondary);
}
.usage-model-name {
  font-family: var(--font-mono); font-size: 0.68rem;
  max-width: 280px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.usage-time {
  font-size: 0.68rem; color: var(--text-muted); margin-top: 4px;
}
.usage-loading {
  text-align: center; padding: 16px; font-size: 0.8rem; color: var(--text-muted);
}
.usage-badge .stat-value {
  font-family: var(--font-mono); font-size: 0.78rem;
}

/* ── Deadline countdown badges ── */
.deadline-badge {
  font-size: 0.65rem; font-weight: 600; padding: 1px 6px; border-radius: 8px;
  margin-left: auto; white-space: nowrap; font-family: var(--font-mono);
}
.deadline-overdue { background: rgba(239,68,68,0.25); color: #f87171; }
.deadline-urgent  { background: rgba(245,158,11,0.25); color: #fbbf24; }
.deadline-soon    { background: rgba(59,130,246,0.2);  color: #60a5fa; }
.deadline-ok      { background: rgba(16,185,129,0.15); color: #34d399; }
.checklist-item { display: flex; align-items: center; gap: 6px; }

/* ── Milestone progress bars ── */
.milestone-progress-wrap {
  width: 100%; height: 4px; background: var(--bg-input); border-radius: 2px;
  margin-top: 6px; overflow: hidden;
}
.milestone-progress-bar {
  height: 100%; border-radius: 2px; transition: width 0.4s ease;
}

/* ── Document type badges & preview ── */
.doc-type-badge { font-size: 0.85rem; }
.doc-type-label {
  font-size: 0.62rem; font-weight: 600; text-transform: uppercase;
  padding: 1px 5px; border-radius: 4px;
  background: rgba(139,92,246,0.15); color: #a78bfa;
}
.doc-preview {
  font-size: 0.7rem; color: var(--text-muted); margin: 2px 0 4px;
  line-height: 1.4; max-height: 2.8em; overflow: hidden;
}
.doc-status.in-review { background: rgba(59,130,246,0.15); color: #60a5fa; }

/* ── Development progress rings ── */
.dev-ring-wrap {
  display: inline-flex; align-items: center; gap: 4px; margin-left: 6px;
}
.dev-ring { width: 28px; height: 28px; transform: rotate(-90deg); }
.dev-ring-bg { stroke: var(--bg-input); }
.dev-ring-fill { stroke: var(--accent-cb); stroke-linecap: round; transition: stroke-dasharray 0.6s ease; }
.card-vitals:nth-child(2) .dev-ring-fill { stroke: var(--accent-ss); }
.dev-ring-pct { font-size: 0.6rem; font-weight: 700; color: var(--text-muted); font-family: var(--font-mono); }

/* ── Hiring tracker ── */
.hiring-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 10px; margin-bottom: 20px;
}
.hiring-card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px;
  padding: 14px; text-align: center;
}
.hiring-card.hiring-open { border-left: 3px solid var(--green); }
.hiring-card.hiring-planned { border-left: 3px solid var(--text-muted); }
.hiring-icon { font-size: 1.5rem; margin-bottom: 6px; }
.hiring-title { font-weight: 600; font-size: 0.82rem; margin-bottom: 2px; }
.hiring-sub { font-size: 0.7rem; color: var(--text-muted); margin-bottom: 6px; }
.hiring-status { font-size: 0.68rem; font-weight: 500; }

/* ── Meeting Scheduler ── */
.table { width: 100%; border-collapse: collapse; font-size: 0.8rem; }
.table th {
  text-align: left; padding: 6px 10px; border-bottom: 1px solid var(--border);
  color: var(--text-muted); font-size: 0.7rem; font-weight: 600; text-transform: uppercase;
}
.table td { padding: 6px 10px; border-bottom: 1px solid var(--border); }
.table-sm th, .table-sm td { padding: 4px 8px; font-size: 0.75rem; }
.btn-xs { padding: 3px 8px; font-size: 0.65rem; border-radius: 4px; }
.form-control, .form-select {
  background: var(--bg-input); border: 1px solid var(--border); border-radius: 6px;
  color: var(--text); padding: 6px 10px; font-size: 0.8rem; font-family: inherit;
}
.form-control-sm, .form-select-sm { padding: 4px 8px; font-size: 0.75rem; }
.form-control:focus, .form-select:focus { border-color: var(--accent-cb); outline: none; }
.d-flex { display: flex; }
.gap-2 { gap: 8px; }
.flex-wrap { flex-wrap: wrap; }
.align-items-end { align-items: flex-end; }
.mb-3 { margin-bottom: 12px; }
.text-muted { color: var(--text-muted); }

/* ── Gantt Dependency SVG ── */
.gantt-dep-svg {
  position: absolute; top: 0; left: 0; width: 100%; height: 100%;
  pointer-events: none; overflow: visible; z-index: 2;
}

/* ── Search Spinner ── */
.search-spinner {
  text-align: center; padding: 8px; color: var(--text-muted); font-size: 0.85rem;
}

/* ── Competitor Radar ── */
.competitor-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px; padding: 12px 16px;
}
.competitor-card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px;
  padding: 14px; position: relative;
}
.competitor-card.threat-HIGH { border-left: 3px solid var(--red, #ef4444); }
.competitor-card.threat-MEDIUM { border-left: 3px solid var(--orange, #f59e0b); }
.competitor-card.threat-LOW { border-left: 3px solid var(--green, #10b981); }
.competitor-name { font-weight: 600; font-size: 0.85rem; margin-bottom: 2px; }
.competitor-cn { font-size: 0.72rem; color: var(--text-muted); margin-bottom: 6px; }
.competitor-meta { font-size: 0.7rem; color: var(--text-muted); line-height: 1.5; }
.competitor-type {
  font-size: 0.6rem; font-weight: 600; padding: 1px 6px; border-radius: 8px;
  background: rgba(139,92,246,0.15); color: #a78bfa; margin-left: 6px;
}
.competitor-threat {
  position: absolute; top: 10px; right: 10px; font-size: 0.6rem; font-weight: 700;
  padding: 2px 6px; border-radius: 6px;
}
.competitor-threat.threat-HIGH { background: rgba(239,68,68,0.2); color: #f87171; }
.competitor-threat.threat-MEDIUM { background: rgba(245,158,11,0.2); color: #fbbf24; }
.competitor-threat.threat-LOW { background: rgba(16,185,129,0.15); color: #34d399; }

/* ── Risk Dependencies ── */
.risk-dep-list { padding: 8px 16px; }
.risk-dep-item {
  display: flex; align-items: center; gap: 8px; padding: 6px 0;
  border-bottom: 1px solid var(--border); font-size: 0.78rem;
}
.risk-dep-type {
  font-size: 0.6rem; font-weight: 600; padding: 1px 6px; border-radius: 8px;
}
.risk-dep-type.causes { background: rgba(239,68,68,0.2); color: #f87171; }
.risk-dep-type.amplifies { background: rgba(245,158,11,0.2); color: #fbbf24; }
.risk-dep-type.blocks { background: rgba(59,130,246,0.2); color: #60a5fa; }
.risk-dep-form {
  display: flex; gap: 6px; padding: 10px 16px; flex-wrap: wrap; align-items: center;
}
.risk-dep-form select, .risk-dep-form button { font-size: 0.75rem; }

/* ── Document Annotations ── */
.annotation-panel {
  background: var(--bg-input); border-radius: 8px; padding: 10px 14px;
  margin: 6px 0 10px; border: 1px solid var(--border);
}
.annotation-item {
  display: flex; justify-content: space-between; align-items: flex-start;
  padding: 6px 0; border-bottom: 1px solid rgba(255,255,255,0.05);
  font-size: 0.78rem;
}
.annotation-text { flex: 1; }
.annotation-meta { font-size: 0.65rem; color: var(--text-muted); margin-top: 2px; }
.annotation-input-row {
  display: flex; gap: 6px; margin-top: 8px;
}
.annotation-input-row input { flex: 1; }

/* ── Notification Bell ── */
.notif-bell {
  position: relative; cursor: pointer; font-size: 1.1rem;
  padding: 4px 6px; border-radius: 6px; background: transparent; border: none;
}
.notif-bell:hover { background: var(--bg-input); }
.notif-badge {
  position: absolute; top: 0; right: 0; background: var(--red, #ef4444);
  color: #fff; font-size: 0.55rem; font-weight: 700; min-width: 14px;
  height: 14px; line-height: 14px; text-align: center; border-radius: 7px;
  padding: 0 3px;
}
.notif-dropdown {
  position: absolute; top: 100%; right: 0; width: 320px; max-height: 360px;
  overflow-y: auto; background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 10px; box-shadow: 0 8px 24px rgba(0,0,0,0.4);
  z-index: 200; padding: 8px 0;
}
.notif-item {
  display: flex; gap: 8px; padding: 8px 14px; cursor: pointer;
  font-size: 0.78rem; border-bottom: 1px solid var(--border); transition: background 0.15s;
}
.notif-item:hover { background: var(--bg-input); }
.notif-item.unread { background: rgba(59,130,246,0.08); }
.notif-item-text { flex: 1; }
.notif-item-time { font-size: 0.65rem; color: var(--text-muted); white-space: nowrap; }

/* ── Time Tracker ── */
.time-tracker-summary {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 8px; padding: 10px 16px; margin-bottom: 12px;
}
.time-summary-card {
  background: var(--bg-input); border-radius: 8px; padding: 10px; text-align: center;
}
.time-summary-name { font-weight: 600; font-size: 0.78rem; margin-bottom: 4px; }
.time-summary-hours { font-size: 1.1rem; font-weight: 700; color: var(--accent-cb); font-family: var(--font-mono); }
.time-summary-label { font-size: 0.62rem; color: var(--text-muted); }
.time-log-form {
  display: flex; gap: 6px; padding: 8px 16px; flex-wrap: wrap; align-items: center;
}
.time-log-form select, .time-log-form input, .time-log-form button { font-size: 0.75rem; }
.time-entry {
  display: flex; align-items: center; gap: 8px; padding: 6px 16px;
  border-bottom: 1px solid var(--border); font-size: 0.75rem;
}
.time-entry-hours {
  font-weight: 700; color: var(--accent-cb); font-family: var(--font-mono);
  min-width: 32px; text-align: right;
}

/* ── Dual-Project Branding ── */
.brand-logos {
  display: flex; align-items: center; justify-content: center;
  gap: 16px; margin-bottom: 16px;
}
.brand-logo-item {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
}
.brand-emoji { font-size: 2.2rem; }
.brand-name { font-weight: 700; font-size: 1rem; letter-spacing: 0.02em; }
.brand-cn { font-size: 0.75rem; color: var(--text-muted); font-family: var(--font-cn); }
.cb-brand .brand-name { color: var(--accent-cb, #00e5a0); }
.ss-brand .brand-name { color: var(--accent-ss, #a78bfa); }
.brand-divider {
  font-size: 1.4rem; font-weight: 300; color: var(--text-muted); opacity: 0.5;
}
.header-brand-dual {
  display: flex; align-items: center; gap: 6px; font-weight: 700;
  font-size: 0.9rem; margin-right: 8px;
}
.hb-cb { color: var(--accent-cb, #00e5a0); }
.hb-ss { color: var(--accent-ss, #a78bfa); }
.hb-sep { color: var(--text-muted); opacity: 0.4; font-weight: 300; }

/* ── Sprint Management ── */
.sprint-active { border-left: 3px solid var(--accent-cb); }
.sprint-completed { border-left: 3px solid var(--green); opacity: 0.7; }

/* ── Compliance Attachments ── */
.comp-attach-badge {
  font-size: 0.6rem; background: rgba(59,130,246,0.15); color: #60a5fa;
  padding: 1px 5px; border-radius: 8px; margin-left: 4px; font-weight: 600;
}

/* ── Briefing Scheduler ── */
.briefing-history-item {
  padding: 4px 0; border-bottom: 1px solid var(--border); display: flex;
  gap: 8px; align-items: center;
}

/* ── Velocity Charts ── */
.velocity-chart-wrap {
  display: grid; grid-template-columns: 1fr 1fr; gap: 16px; padding: 12px 16px;
}

/* WeChat Discussion Import */
.wechat-history-item:hover { background: rgba(255,255,255,0.03); }
#wechatDiscussionInput { line-height: 1.5; color: var(--text-primary); }

/* Voice Input */
.voice-btn { border-radius: 50%; min-width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; font-size: 1.1rem; transition: all 0.3s; }
.voice-btn.voice-active { background: var(--red); animation: voice-pulse 1s infinite; }
@keyframes voice-pulse { 0%,100% { box-shadow: 0 0 0 0 rgba(255,0,0,0.4); } 50% { box-shadow: 0 0 0 10px rgba(255,0,0,0); } }
.floating-voice-btn { border-radius: 50%; width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; font-size: 0.9rem; cursor: pointer; border: 1px solid var(--border); background: var(--card-bg); transition: all 0.3s; }
.floating-voice-btn.voice-active { background: var(--red); border-color: var(--red); }

/* Article Scanner */
.scanned-article-item:hover { background: rgba(255,255,255,0.03); }
#articleUrlInput { font-size: 0.78rem; }

/* KPI Countdown & Activity Sparkline */
.countdown-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; padding: 8px 0; }
.countdown-item { text-align: center; }
.countdown-project { font-size: 0.75rem; font-weight: 600; margin-bottom: 4px; }
.countdown-days { font-size: 2rem; font-weight: 800; font-family: 'Syne', sans-serif; color: var(--accent); line-height: 1.2; }
.countdown-label { font-size: 0.65rem; color: var(--text-muted); margin-bottom: 8px; }
.countdown-bar { height: 4px; background: rgba(255,255,255,0.06); border-radius: 2px; overflow: hidden; }
.countdown-fill { height: 100%; border-radius: 2px; transition: width 0.6s ease; }
.countdown-fill.cb-fill { background: linear-gradient(90deg, #10b981, #06b6d4); }
.countdown-fill.ss-fill { background: linear-gradient(90deg, #6366f1, #8b5cf6); }
.activity-stats { text-align: center; margin-top: 6px; }

/* Export Report Modal */
.export-option-btn { display: flex; align-items: center; gap: 12px; width: 100%; padding: 14px 16px; background: var(--card-bg); border: 1px solid var(--border); border-radius: 8px; color: var(--text-primary); cursor: pointer; text-align: left; transition: all 0.2s; }
.export-option-btn:hover { border-color: var(--accent); background: rgba(99,102,241,0.08); transform: translateY(-1px); }
.export-opt-icon { font-size: 1.5rem; min-width: 36px; text-align: center; }

/* Activity Feed Timeline */
.audit-stats-bar { display: flex; gap: 16px; padding: 10px 16px; background: var(--card-bg); border-radius: 8px; margin-bottom: 12px; border: 1px solid var(--border); }
.audit-stat { text-align: center; flex: 1; }
.audit-stat-num { display: block; font-size: 1.2rem; font-weight: 700; color: var(--accent); font-family: 'Syne', sans-serif; }
.audit-stat-label { font-size: 0.65rem; color: var(--text-muted); text-transform: uppercase; }
.activity-timeline { max-height: 70vh; overflow-y: auto; }
.activity-date-header { font-size: 0.72rem; font-weight: 600; color: var(--text-muted); padding: 12px 8px 6px; border-bottom: 1px solid var(--border); margin-bottom: 4px; text-transform: uppercase; letter-spacing: 0.5px; }
.activity-item { display: flex; gap: 10px; padding: 8px; border-radius: 6px; transition: background 0.15s; }
.activity-item:hover { background: rgba(255,255,255,0.03); }
.activity-icon { font-size: 1rem; min-width: 28px; height: 28px; display: flex; align-items: center; justify-content: center; background: rgba(99,102,241,0.1); border-radius: 6px; }
.activity-body { flex: 1; min-width: 0; }
.activity-main { font-size: 0.78rem; line-height: 1.4; }
.activity-user { font-weight: 600; color: var(--text-primary); }
.activity-detail { color: var(--text-secondary); }
.activity-meta { font-size: 0.65rem; color: var(--text-muted); margin-top: 2px; }

/* Compliance Calendar */
.comp-calendar { padding: 8px 16px 16px; }
.cal-header-row { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; margin-bottom: 4px; }
.cal-day-name { text-align: center; font-size: 0.65rem; font-weight: 600; color: var(--text-muted); padding: 4px; text-transform: uppercase; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.cal-cell { min-height: 60px; padding: 4px; background: rgba(255,255,255,0.02); border-radius: 4px; border: 1px solid transparent; transition: all 0.2s; }
.cal-cell:hover { border-color: var(--border); }
.cal-empty { background: transparent; }
.cal-today { border-color: var(--accent) !important; background: rgba(99,102,241,0.08); }
.cal-has-event { background: rgba(245,158,11,0.06); }
.cal-urgent { background: rgba(239,68,68,0.08); border-color: rgba(239,68,68,0.3); }
.cal-date { font-size: 0.72rem; font-weight: 600; color: var(--text-muted); margin-bottom: 2px; }
.cal-today .cal-date { color: var(--accent); }
.cal-event { font-size: 0.58rem; padding: 1px 3px; background: rgba(99,102,241,0.15); border-radius: 2px; margin-bottom: 1px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-more { font-size: 0.55rem; color: var(--accent); cursor: pointer; }

/* Advanced Analytics */
.workload-grid { display: flex; flex-direction: column; gap: 8px; padding: 4px 0; }
.workload-card { display: flex; gap: 10px; align-items: center; padding: 6px 8px; border-radius: 6px; }
.workload-card:hover { background: rgba(255,255,255,0.03); }
.workload-avatar { font-size: 1.3rem; min-width: 32px; text-align: center; }
.workload-info { flex: 1; min-width: 0; }
.workload-name { font-size: 0.78rem; font-weight: 600; margin-bottom: 3px; }
.workload-bar-wrap { height: 4px; background: rgba(255,255,255,0.06); border-radius: 2px; overflow: hidden; margin-bottom: 3px; }
.workload-bar { height: 100%; border-radius: 2px; transition: width 0.4s; }
.workload-meta { font-size: 0.65rem; color: var(--text-muted); }

/* Financial Metrics */
.finance-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; padding: 4px 0; }
.finance-metric { text-align: center; padding: 8px; background: rgba(255,255,255,0.02); border-radius: 6px; }
.finance-label { font-size: 0.68rem; color: var(--text-muted); margin-bottom: 4px; }
.finance-value { font-size: 1.1rem; font-weight: 700; color: var(--accent); font-family: 'Syne', sans-serif; }
.finance-sub { font-size: 0.6rem; color: var(--text-muted); margin-top: 2px; }

/* ══════════════════════════════════════════════════════════════════════════════
   MOBILE RESPONSIVE
   ══════════════════════════════════════════════════════════════════════════════ */

.hamburger-btn { display: none; background: none; border: none; color: var(--text-primary); font-size: 1.4rem; cursor: pointer; padding: 4px 8px; border-radius: 4px; }
.hamburger-btn:hover { background: rgba(255,255,255,0.06); }
.mobile-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 998; }
.mobile-overlay.active { display: block; }

/* Tablet: ≤1024px */
@media (max-width: 1024px) {
  .overview-grid { grid-template-columns: repeat(2, 1fr) !important; }
  .overview-grid .ov-card[style*="grid-column:span 2"] { grid-column: span 2; }
  .stat-cards { grid-template-columns: repeat(2, 1fr); }
  .finance-grid { grid-template-columns: repeat(2, 1fr); }
  .api-usage-grid { grid-template-columns: repeat(2, 1fr); }
}

/* Mobile: ≤768px */
@media (max-width: 768px) {
  .hamburger-btn { display: block; }

  .sidebar {
    position: fixed;
    left: -260px;
    top: 0;
    bottom: 0;
    width: 250px;
    z-index: 999;
    transition: left 0.3s ease;
    overflow-y: auto;
  }
  .sidebar.sidebar-open { left: 0; }

  .main-content { margin-left: 0 !important; padding: 12px; }

  .header { padding: 8px 12px; flex-wrap: wrap; gap: 6px; }
  .header-title { font-size: 0.9rem; }
  .header-stats { display: none; }

  .module-header { flex-direction: column; align-items: flex-start; gap: 8px; }
  .module-actions { width: 100%; flex-wrap: wrap; }
  .module-actions .btn { flex: 1; min-width: 0; font-size: 0.7rem; }

  .overview-grid { grid-template-columns: 1fr !important; }
  .overview-grid .ov-card[style*="grid-column:span 2"] { grid-column: span 1 !important; }

  .stat-cards { grid-template-columns: 1fr 1fr; gap: 6px; }
  .stat-card { padding: 10px 8px; }
  .stat-number { font-size: 1.3rem; }

  .finance-grid { grid-template-columns: repeat(2, 1fr); gap: 6px; }
  .finance-value { font-size: 0.9rem; }

  .api-usage-grid { grid-template-columns: 1fr; }

  .comp-calendar .cal-grid,
  .compliance-cal-grid .cal-body { gap: 1px; }
  .cal-cell { min-height: 40px; padding: 2px; font-size: 0.6rem; }
  .cal-event { font-size: 0.5rem; }

  .countdown-grid { grid-template-columns: 1fr; }
  .digest-stats { gap: 6px; }

  .card-header { flex-wrap: wrap; gap: 6px; font-size: 0.82rem; }

  .chart-wrap-sm, .chart-wrap-med { height: 150px !important; }

  /* Floating chat */
  .floating-chat { width: calc(100vw - 24px); right: 12px; bottom: 12px; }
  .floating-chat.open { height: 60vh; }

  /* Search modal */
  .search-modal .modal-content { width: calc(100vw - 24px); margin: 20px auto; }
}

/* Small phone: ≤480px */
@media (max-width: 480px) {
  .stat-cards { grid-template-columns: 1fr; }
  .finance-grid { grid-template-columns: 1fr; }
  .workload-card { flex-direction: column; text-align: center; }
  .module-panel { padding: 10px 8px; }
  .card { border-radius: 6px; }
  .card-header { padding: 8px 10px; font-size: 0.78rem; }
  .btn { padding: 6px 10px; font-size: 0.68rem; min-height: 36px; }
  .form-input { font-size: 0.78rem; padding: 8px 10px; }
}

/* API Usage Dashboard */
.api-usage-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; padding: 12px 16px; }
.api-usage-card { background: rgba(255,255,255,0.02); border: 1px solid var(--border); border-radius: 8px; padding: 12px; }
.api-usage-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.api-usage-name { font-weight: 600; font-size: 0.82rem; text-transform: capitalize; }
.api-usage-badge { font-size: 0.6rem; padding: 2px 6px; border-radius: 10px; color: white; font-weight: 700; }
.api-usage-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; margin-bottom: 8px; }
.api-stat { text-align: center; }
.api-stat-num { display: block; font-size: 0.88rem; font-weight: 700; color: var(--text-primary); }
.api-stat-label { font-size: 0.58rem; color: var(--text-muted); }
.api-usage-gauge { height: 6px; background: rgba(255,255,255,0.06); border-radius: 3px; overflow: hidden; margin-bottom: 4px; }
.api-gauge-bar { height: 100%; border-radius: 3px; transition: width 0.3s; }
.api-gauge-label { font-size: 0.62rem; color: var(--text-muted); text-align: center; }
.api-usage-meta { font-size: 0.6rem; color: var(--text-muted); margin-top: 6px; border-top: 1px solid var(--border); padding-top: 4px; }

/* Weekly Digest */
.digest-card { padding: 4px 0; }
.digest-date { font-size: 0.72rem; font-weight: 600; margin-bottom: 6px; color: var(--accent); }
.digest-stats { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 8px; }
.digest-stat { font-size: 0.68rem; padding: 2px 8px; background: rgba(99,102,241,0.1); border-radius: 12px; }
.digest-text { font-size: 0.78rem; line-height: 1.6; white-space: pre-wrap; }
.digest-actions { display: flex; gap: 6px; margin-top: 8px; padding-top: 6px; border-top: 1px solid var(--border); }

/* ══════════════════════════════════════════════════════════════════════════════
   THEME TOGGLE & LIGHT THEME
   ══════════════════════════════════════════════════════════════════════════════ */

.theme-toggle { background: none; border: 1px solid var(--border); color: var(--text-primary); font-size: 1.1rem; cursor: pointer; padding: 4px 8px; border-radius: 6px; transition: all 0.2s; line-height: 1; margin-right: 8px; }
.theme-toggle:hover { background: rgba(255,255,255,0.06); border-color: var(--accent); }

[data-theme="light"] {
  --bg-primary: #f8fafc;
  --bg-secondary: #f1f5f9;
  --card-bg: #ffffff;
  --card-hover: #f8fafc;
  --border: #e2e8f0;
  --text-primary: #0f172a;
  --text-secondary: #334155;
  --text-muted: #64748b;
  --sidebar-bg: #ffffff;
  --header-bg: #ffffff;
  --accent: #6366f1;
  --accent-hover: #4f46e5;
  --green: #059669;
  --red: #dc2626;
  --orange: #d97706;
}

[data-theme="light"] .sidebar { background: var(--sidebar-bg); border-right: 1px solid var(--border); box-shadow: 2px 0 8px rgba(0,0,0,0.05); }
[data-theme="light"] .header { background: var(--header-bg); border-bottom: 1px solid var(--border); box-shadow: 0 1px 4px rgba(0,0,0,0.05); }
[data-theme="light"] .card, [data-theme="light"] .ov-card { background: var(--card-bg); border-color: var(--border); box-shadow: 0 1px 3px rgba(0,0,0,0.06); }
[data-theme="light"] .card:hover, [data-theme="light"] .ov-card:hover { box-shadow: 0 2px 8px rgba(0,0,0,0.1); }
[data-theme="light"] .card-header { border-bottom-color: var(--border); }
[data-theme="light"] .btn-secondary { background: #e2e8f0; color: #1e293b; border-color: #cbd5e1; }
[data-theme="light"] .btn-secondary:hover { background: #cbd5e1; }
[data-theme="light"] .form-input { background: #f1f5f9; border-color: #cbd5e1; color: #0f172a; }
[data-theme="light"] .form-input:focus { border-color: var(--accent); background: #fff; }
[data-theme="light"] .stat-card { background: var(--card-bg); border-color: var(--border); }
[data-theme="light"] .glow-card { box-shadow: 0 1px 4px rgba(0,0,0,0.08); }
[data-theme="light"] .nav-item { color: var(--text-secondary); }
[data-theme="light"] .nav-item:hover { background: #f1f5f9; color: var(--text-primary); }
[data-theme="light"] .nav-item.active { background: rgba(99,102,241,0.1); color: var(--accent); }
[data-theme="light"] .module-panel { background: var(--bg-primary); }
[data-theme="light"] .login-container { background: var(--bg-primary); }
[data-theme="light"] .login-box { background: var(--card-bg); border-color: var(--border); box-shadow: 0 4px 16px rgba(0,0,0,0.1); }
[data-theme="light"] .floating-chat { background: var(--card-bg); border-color: var(--border); box-shadow: 0 4px 24px rgba(0,0,0,0.15); }
[data-theme="light"] .chat-messages { background: #f1f5f9; }
[data-theme="light"] .chat-msg-assistant { background: var(--card-bg); border-color: var(--border); }
[data-theme="light"] .chat-msg-user { background: rgba(99,102,241,0.1); }
[data-theme="light"] .theme-toggle { border-color: #cbd5e1; }
[data-theme="light"] .theme-toggle:hover { background: #f1f5f9; }
[data-theme="light"] .workload-bar-wrap { background: #e2e8f0; }
[data-theme="light"] .api-usage-card { background: #f8fafc; border-color: var(--border); }
[data-theme="light"] .cal-cell { background: #f8fafc; }
[data-theme="light"] .cal-today { background: rgba(99,102,241,0.1); }
[data-theme="light"] .finance-metric { background: #f8fafc; }
[data-theme="light"] .digest-stat { background: rgba(99,102,241,0.08); }
[data-theme="light"] .modal-content { background: var(--card-bg); }
[data-theme="light"] .search-modal .modal-content { background: var(--card-bg); }

/* ── Notification Center ─────────────────────────────────────────────────── */
.notif-drawer { position: fixed; top: 0; right: 0; bottom: 0; width: 360px; max-width: 90vw; background: var(--card-bg); border-left: 1px solid var(--border); z-index: 1100; box-shadow: -4px 0 24px rgba(0,0,0,0.4); display: flex; flex-direction: column; transition: transform 0.3s; backdrop-filter: blur(12px); }
.notif-drawer.hidden { transform: translateX(100%); pointer-events: none; }
.notif-drawer-inner { display: flex; flex-direction: column; height: 100%; }
.notif-drawer-header { display: flex; justify-content: space-between; align-items: center; padding: 16px; border-bottom: 1px solid var(--border); background: var(--bg-tertiary); }
.notif-drawer-header .btn-icon { color: var(--text-primary); opacity: 0.8; }
.notif-drawer-header .btn-icon:hover { opacity: 1; background: var(--bg-hover); }
.notif-drawer-header h4 { margin: 0; font-size: 0.9rem; }
.notif-list { flex: 1; overflow-y: auto; }
.notif-item { display: flex; gap: 10px; padding: 12px 16px; border-bottom: 1px solid var(--border); cursor: pointer; transition: background 0.2s; }
.notif-item:hover { background: rgba(99, 102, 241, 0.06); }
.notif-unread { background: rgba(99, 102, 241, 0.04); border-left: 3px solid var(--accent); }
.notif-icon { font-size: 1.1rem; flex-shrink: 0; }
.notif-content { flex: 1; min-width: 0; }
.notif-title { font-size: 0.78rem; font-weight: 600; color: var(--text-primary); }
.notif-msg { font-size: 0.72rem; color: var(--text-secondary); margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.notif-time { font-size: 0.65rem; color: var(--text-muted); margin-top: 4px; }

/* ── Nav Reordering & Favorites ──────────────────────────────────────────── */
.nav-fav { font-size: 0.7rem; color: var(--text-muted); cursor: pointer; opacity: 0; transition: opacity 0.2s, color 0.2s; margin-left: auto; padding: 2px 4px; }
.nav-item:hover .nav-fav { opacity: 1; }
.nav-fav-active { color: #f59e0b !important; opacity: 1 !important; }
.nav-fav:hover { color: #f59e0b; }
.nav-dragging { opacity: 0.5; }
.nav-dragover { border-top: 2px solid var(--accent); }

/* PWA / Offline */
.offline-mode::after { content: '📡 OFFLINE'; position: fixed; top: 4px; right: 4px; background: var(--red); color: white; font-size: 0.6rem; font-weight: 700; padding: 2px 8px; border-radius: 4px; z-index: 10000; pointer-events: none; }

/* ── KPI / OKR Tracker ──────────────────────────────────────────────────── */
.kpi-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; padding: 12px; }
.kpi-card { background: var(--card-bg); border: 1px solid var(--border); border-radius: 10px; padding: 12px; text-align: center; transition: transform 0.2s; }
.kpi-card:hover { transform: translateY(-2px); }
.kpi-header { display: flex; align-items: center; gap: 4px; margin-bottom: 8px; font-size: 0.72rem; }
.kpi-project { font-size: 0.8rem; }
.kpi-name { flex: 1; text-align: left; font-weight: 600; color: var(--text-primary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kpi-ring-wrap { position: relative; width: 72px; height: 72px; margin: 0 auto 6px; }
.kpi-ring { width: 100%; height: 100%; transform: rotate(-90deg); }
.kpi-pct { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); font-size: 0.85rem; font-weight: 700; font-family: 'DM Mono', monospace; }
.kpi-values { font-size: 0.68rem; color: var(--text-muted); font-family: 'DM Mono', monospace; }

/* ── Accounting Module ──────────────────────────────────────────────────── */
.acct-overview { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 12px; }
.acct-card { background: var(--card-bg); border: 1px solid var(--border); border-radius: 10px; padding: 16px; text-align: center; }
.acct-card-label { font-size: 0.72rem; color: var(--text-muted); margin-bottom: 6px; }
.acct-card-value { font-size: 1.4rem; font-weight: 700; font-family: 'DM Mono', monospace; }
.acct-card-sub { font-size: 0.68rem; color: var(--text-muted); margin-top: 4px; }
.acct-card-income .acct-card-value { color: var(--green); }
.acct-card-expense .acct-card-value { color: var(--red); }
.acct-card-balance .acct-card-value { color: var(--accent); }
.acct-card-burn .acct-card-value { color: var(--orange); }
.acct-balance-ok { display: flex; align-items: center; gap: 8px; padding: 10px 16px; border-radius: 8px; font-size: 0.82rem; font-weight: 600; background: rgba(16, 185, 129, 0.1); color: var(--green); border: 1px solid rgba(16, 185, 129, 0.3); }
.acct-balance-error { display: flex; align-items: center; gap: 8px; padding: 10px 16px; border-radius: 8px; font-size: 0.82rem; font-weight: 600; background: rgba(239, 68, 68, 0.1); color: var(--red); border: 1px solid rgba(239, 68, 68, 0.3); }
.acct-entry-form { background: var(--card-bg); border: 1px solid var(--border); border-radius: 10px; padding: 16px; }
.acct-form-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.acct-form-grid label { display: block; font-size: 0.7rem; color: var(--text-muted); margin-bottom: 4px; font-weight: 600; }
.acct-charts-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.acct-chart-box { background: var(--card-bg); border: 1px solid var(--border); border-radius: 10px; padding: 16px; position: relative; height: 260px; }
.acct-ledger-wrap { overflow-x: auto; overflow-y: auto; max-height: 60vh; margin-bottom: 16px; }
.acct-ledger { width: 100%; border-collapse: collapse; font-size: 0.78rem; }
.acct-ledger th { padding: 8px 10px; text-align: left; font-size: 0.68rem; font-weight: 600; color: var(--text-muted); border-bottom: 2px solid var(--border); white-space: nowrap; }
.acct-ledger td { padding: 7px 10px; border-bottom: 1px solid var(--border); }
.acct-ledger tr:hover { background: rgba(255,255,255,0.02); }
.acct-amount-in { color: var(--green); font-weight: 600; font-family: 'DM Mono', monospace; }
.acct-amount-out { color: var(--red); font-weight: 600; font-family: 'DM Mono', monospace; }
.acct-running-bal { font-family: 'DM Mono', monospace; font-weight: 600; font-size: 0.76rem; }
.acct-type-badge { display: inline-block; padding: 2px 8px; border-radius: 4px; font-size: 0.68rem; font-weight: 600; }
.acct-type-income { background: rgba(16,185,129,0.15); color: var(--green); }
.acct-type-expense { background: rgba(239,68,68,0.15); color: var(--red); }
.acct-cat-badge { display: inline-block; padding: 2px 6px; border-radius: 4px; font-size: 0.65rem; background: rgba(59,130,246,0.1); color: var(--accent); }
.acct-proj-badge { font-size: 0.7rem; }
.acct-del-btn { background: none; border: none; cursor: pointer; font-size: 0.8rem; opacity: 0.5; transition: opacity 0.2s; }
.acct-del-btn:hover { opacity: 1; }

/* ── Accounting PIN Gate ── */
.acct-pin-gate {
  display: flex; align-items: center; justify-content: center;
  min-height: 60vh; padding: 40px 16px;
}
.acct-pin-modal-overlay {
  position: fixed; inset: 0; z-index: 9999;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,0.6); backdrop-filter: blur(4px);
}
.acct-pin-box {
  background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: 16px; padding: 40px 32px; text-align: center;
  max-width: 380px; width: 100%; box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}
.acct-pin-icon { font-size: 2.5rem; margin-bottom: 12px; }
.acct-pin-box h3 { font-size: 1.1rem; margin-bottom: 4px; }
.acct-pin-inputs { display: flex; gap: 10px; justify-content: center; margin: 16px 0; }
.acct-pin-digit {
  width: 52px; height: 56px; text-align: center; font-size: 1.4rem;
  font-family: 'DM Mono', monospace; font-weight: 700;
  background: var(--bg-input); color: var(--text-primary);
  border: 2px solid var(--border); border-radius: 10px;
  outline: none; transition: border-color 0.2s;
}
.acct-pin-digit:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(59,130,246,0.2); }

/* ── Access Badge ── */
.acct-access-badge {
  display: inline-block; padding: 3px 10px; border-radius: 6px;
  font-size: 0.7rem; font-weight: 600;
}
.acct-access-full { background: rgba(16,185,129,0.15); color: var(--green); }
.acct-access-readonly { background: rgba(245,158,11,0.15); color: var(--orange); }

/* ── Accounting Audit Log ── */
.acct-audit-stats {
  display: flex; gap: 12px; margin-bottom: 14px; flex-wrap: wrap;
}
.acct-audit-stat {
  background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: 8px; padding: 8px 14px; text-align: center; min-width: 70px;
}
.acct-audit-stat-num { display: block; font-size: 1.1rem; font-weight: 700; font-family: 'DM Mono', monospace; color: var(--text-primary); }
.acct-audit-stat-label { font-size: 0.62rem; color: var(--text-muted); }
.acct-audit-fail { color: var(--red) !important; }
.acct-audit-list {
  max-height: 50vh; overflow-y: auto; border: 1px solid var(--border);
  border-radius: 8px; background: var(--bg-secondary);
}
.acct-audit-date {
  font-size: 0.68rem; font-weight: 600; color: var(--text-muted);
  padding: 8px 14px 4px; background: rgba(255,255,255,0.02);
  border-bottom: 1px solid var(--border); text-transform: uppercase; letter-spacing: 0.5px;
}
.acct-audit-item {
  display: flex; align-items: flex-start; gap: 10px; padding: 8px 14px;
  border-bottom: 1px solid rgba(255,255,255,0.03); font-size: 0.78rem;
}
.acct-audit-item:last-child { border-bottom: none; }
.acct-audit-item-fail { background: rgba(239,68,68,0.05); }
.acct-audit-icon { font-size: 0.9rem; flex-shrink: 0; margin-top: 1px; }
.acct-audit-body { flex: 1; line-height: 1.5; }
.acct-audit-user { font-weight: 600; color: var(--text-primary); margin-right: 6px; }
.acct-audit-detail { color: var(--text-secondary); }
.acct-audit-time { display: block; font-size: 0.65rem; color: var(--text-muted); font-family: 'DM Mono', monospace; margin-top: 2px; }

/* ── Competitor Detail Modal ────────────────────────────────────────────── */
.competitor-card:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,.25); }
.comp-detail-overlay { position: fixed; inset: 0; z-index: 10000; background: rgba(0,0,0,.6); backdrop-filter: blur(4px); display: flex; align-items: center; justify-content: center; animation: fadeIn .2s; }
.comp-detail-card { background: var(--bg-primary); border-radius: 14px; width: 90%; max-width: 480px; box-shadow: 0 12px 40px rgba(0,0,0,.4); overflow: hidden; animation: slideUp .25s ease-out; }
.comp-detail-header { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; background: var(--bg-secondary); border-bottom: 1px solid var(--border); }
.comp-detail-close { background: none; border: none; color: var(--text-primary); font-size: 1.4rem; cursor: pointer; padding: 4px 8px; border-radius: 6px; line-height: 1; }
.comp-detail-close:hover { background: var(--bg-tertiary); }
.comp-detail-body { padding: 20px; }
.comp-detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.comp-detail-field { display: flex; flex-direction: column; gap: 2px; font-size: 0.82rem; }
.comp-detail-label { font-size: 0.7rem; text-transform: uppercase; letter-spacing: .5px; color: var(--text-muted); font-weight: 600; }
@keyframes slideUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

@media (max-width: 768px) {
  .acct-overview { grid-template-columns: repeat(2, 1fr); }
  .acct-form-grid { grid-template-columns: 1fr 1fr; }
  .acct-charts-row { grid-template-columns: 1fr; }
  .acct-pin-inputs { gap: 6px; }
  .acct-pin-digit { width: 44px; height: 48px; font-size: 1.2rem; }
  .acct-audit-stats { gap: 6px; }
  .acct-audit-stat { min-width: 60px; padding: 6px 10px; }
  .comp-detail-card { width: 95%; }
  .comp-detail-grid { grid-template-columns: 1fr; }
}

/* ── Live Market Ticker ─────────────────────────────────────────────── */
.live-ticker{display:flex;align-items:center;background:rgba(99,102,241,0.04);border-bottom:1px solid var(--glass-border);height:28px;overflow:hidden;font-family:var(--font-mono);font-size:0.72rem}
.ticker-label{padding:0 12px;font-weight:700;color:var(--accent);background:rgba(99,102,241,0.1);height:100%;display:flex;align-items:center;gap:4px;white-space:nowrap;flex-shrink:0;border-right:1px solid var(--glass-border);letter-spacing:0.5px;font-size:0.65rem}
.ticker-label::before{content:'';width:6px;height:6px;border-radius:50%;background:var(--accent);animation:pulse 2s infinite}
.ticker-track{display:flex;align-items:center;gap:20px;overflow-x:auto;padding:0 12px;white-space:nowrap;flex:1;scrollbar-width:none;-ms-overflow-style:none}
.ticker-track::-webkit-scrollbar{display:none}
.ticker-loading{color:var(--text-muted);font-style:italic}
.ticker-item{display:inline-flex;align-items:center;gap:6px;color:var(--text-secondary)}
.ticker-sym{font-weight:600;color:var(--text-primary);font-size:0.7rem}
.ticker-price{color:var(--text-primary)}
.ticker-change{font-weight:600;font-size:0.68rem;padding:1px 5px;border-radius:3px}
.ticker-change.up{color:#22c55e;background:rgba(34,197,94,0.1)}
.ticker-change.down{color:#ef4444;background:rgba(239,68,68,0.1)}
.ticker-change.flat{color:var(--text-muted)}
.ticker-sep{color:var(--glass-border);font-size:0.5rem}
.ticker-news{display:inline-flex;align-items:center;gap:6px;color:var(--text-muted);max-width:350px;overflow:hidden;text-overflow:ellipsis}
.ticker-news-title{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.ticker-stale{color:var(--yellow);font-style:italic;font-size:0.68rem}
.ticker-metric{display:inline-flex;align-items:center;gap:6px;font-size:0.7rem}
.ticker-metric-label{font-weight:600;color:var(--accent)}
.ticker-metric-val{color:var(--text-primary)}

/* ── SVG Countdown Rings ────────────────────────────────────────────── */
.countdown-rings{display:flex;gap:20px;justify-content:center;align-items:flex-start;flex-wrap:wrap;padding:8px 0}
.countdown-ring-item{display:flex;flex-direction:column;align-items:center;gap:4px}
.countdown-ring-item .ring-project{font-size:0.78rem;font-weight:600;color:var(--text-primary)}
.ring-wrap{display:flex;align-items:center;justify-content:center;position:relative;margin:4px 0}
.progress-ring{width:110px;height:110px}
.ring-bg{fill:none;stroke:var(--border);stroke-width:6}
.ring-fill{fill:none;stroke:var(--accent);stroke-width:6;stroke-linecap:round;transition:stroke-dashoffset 1s ease;transform:rotate(-90deg);transform-origin:center}
.ring-fill.cb-ring{stroke:#0ea5e9}
.ring-fill.ss-ring{stroke:#8b5cf6}
.ring-center{position:absolute;text-align:center}
.ring-num{font-family:var(--font-mono);font-size:1.8rem;font-weight:700;color:var(--accent);line-height:1}
.ring-label{font-size:0.6rem;color:var(--text-muted);margin-top:2px;line-height:1.2}
.countdown-ring-meta{font-size:0.65rem;color:var(--text-muted);text-align:center;line-height:1.5}
.countdown-ring-meta .accent-text{color:var(--accent)}

/* ── Knowledge Graph ────────────────────────────────────────────────── */
.kg-header{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:10px;margin-bottom:12px}
.kg-header h3{font-size:1.1rem;font-weight:700}
.kg-controls{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.kg-search-input{width:180px;padding:4px 10px;font-size:0.75rem;background:var(--bg-input);border:1px solid var(--border);border-radius:var(--radius-sm);color:var(--text-primary);outline:none}
.kg-search-input:focus{border-color:var(--accent)}
.kg-legend{display:flex;flex-wrap:wrap;gap:10px;padding:6px 0;font-size:0.68rem;color:var(--text-muted)}
.kg-legend-item{display:inline-flex;align-items:center;gap:4px}
.kg-legend-dot{width:8px;height:8px;border-radius:50%;flex-shrink:0}
.kg-body{display:flex;gap:12px;height:550px;position:relative;min-height:0}
.kg-graph-container{flex:1;position:relative;background:#060612;border-radius:var(--radius);border:1px solid var(--border);overflow:hidden;min-height:400px}
.kg-placeholder{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;color:var(--text-muted);font-size:0.85rem}
.kg-zoom-controls{position:absolute;top:10px;right:10px;display:none;flex-direction:column;gap:4px;z-index:5}
.kg-zoom-controls button{width:32px;height:32px;border:1px solid var(--border);background:var(--bg-card);color:var(--text-primary);border-radius:var(--radius-sm);cursor:pointer;font-size:1rem;display:flex;align-items:center;justify-content:center}
.kg-zoom-controls button:hover{background:var(--bg-card-hover);border-color:var(--accent)}
.kg-detail-panel{width:280px;background:var(--bg-card);border:1px solid var(--border);border-radius:var(--radius);padding:12px;overflow-y:auto;flex-shrink:0}
.kg-detail-header{font-weight:700;font-size:0.85rem;color:var(--text-primary);margin-bottom:8px;padding-bottom:6px;border-bottom:1px solid var(--border)}
.kg-detail-body{font-size:0.75rem;color:var(--text-secondary);line-height:1.6}
.kg-detail-body .kg-detail-row{display:flex;justify-content:space-between;padding:3px 0}
.kg-detail-body .kg-detail-label{color:var(--text-muted);font-weight:500}
.kg-detail-body .kg-detail-val{color:var(--text-primary);text-align:right}
.kg-stats{font-size:0.68rem;color:var(--text-muted);padding:6px 0;text-align:center}
.kg-fullscreen{position:fixed!important;inset:0!important;z-index:9999;width:100vw!important;height:100vh!important;border-radius:0!important;display:flex!important;flex-direction:column!important;background:var(--bg-primary);padding:10px;box-sizing:border-box;overflow:hidden!important;max-height:none!important}
.kg-fullscreen .kg-header{flex-shrink:0}
.kg-fullscreen .kg-legend{flex-shrink:0}
.kg-fullscreen .kg-body{flex:1!important;height:auto!important;min-height:0!important;overflow:hidden}
.kg-fullscreen .kg-graph-container{min-height:0!important;height:100%!important;flex:1!important}
.kg-fullscreen .kg-detail-panel{max-height:100%;overflow-y:auto}
.kg-fullscreen .kg-stats{flex-shrink:0}
.kg-fs-exit-btn{position:absolute;top:14px;left:14px;z-index:20;padding:8px 18px;background:rgba(239,68,68,0.85);color:#fff;border:none;border-radius:8px;font-size:0.82rem;font-weight:600;cursor:pointer;backdrop-filter:blur(8px);box-shadow:0 2px 12px rgba(0,0,0,0.5);transition:background 0.2s,transform 0.15s}
.kg-fs-exit-btn:hover{background:rgba(239,68,68,1);transform:scale(1.05)}
.kg-minimap{position:absolute;bottom:10px;left:10px;width:160px;height:120px;background:rgba(6,6,18,0.85);border:1px solid rgba(99,102,241,0.3);border-radius:8px;z-index:10;cursor:crosshair;backdrop-filter:blur(6px);box-shadow:0 2px 16px rgba(0,0,0,0.6);display:none;overflow:hidden}
.kg-minimap canvas{display:block;width:100%;height:100%;border-radius:7px}
.kg-minimap-label{position:absolute;top:3px;left:6px;font-size:0.48rem;font-weight:600;color:rgba(165,180,252,0.5);text-transform:uppercase;letter-spacing:0.5px;pointer-events:none}

/* ── KG Detail Visual Cards ── */
.kg-vcard{border-radius:10px;padding:10px;margin-bottom:10px;position:relative;overflow:hidden}
.kg-vcard::before{content:'';position:absolute;inset:0;border-radius:10px;pointer-events:none;border:1px solid rgba(255,255,255,0.08)}
.kg-vcard-project{background:linear-gradient(135deg,rgba(14,165,233,0.18) 0%,rgba(99,102,241,0.10) 100%)}
.kg-vcard-layer{background:linear-gradient(135deg,rgba(34,211,238,0.16) 0%,rgba(99,102,241,0.08) 100%)}
.kg-vcard-domain{background:linear-gradient(135deg,rgba(192,132,252,0.14) 0%,rgba(99,102,241,0.06) 100%)}
.kg-vcard-module{background:linear-gradient(135deg,rgba(168,85,247,0.18) 0%,rgba(99,102,241,0.08) 100%)}
.kg-vcard-advisor{background:linear-gradient(135deg,rgba(236,72,153,0.16) 0%,rgba(168,85,247,0.08) 100%)}
.kg-vcard-risk{background:linear-gradient(135deg,rgba(239,68,68,0.16) 0%,rgba(245,158,11,0.08) 100%)}
.kg-vcard-patent{background:linear-gradient(135deg,rgba(20,184,166,0.16) 0%,rgba(99,102,241,0.08) 100%)}
.kg-vcard-hub{background:linear-gradient(135deg,rgba(99,102,241,0.20) 0%,rgba(14,165,233,0.10) 100%)}
.kg-vcard-feature{background:linear-gradient(135deg,rgba(34,197,94,0.16) 0%,rgba(99,102,241,0.08) 100%)}
.kg-vcard-devstream{background:linear-gradient(135deg,rgba(139,92,246,0.16) 0%,rgba(99,102,241,0.08) 100%)}
.kg-vcard-service{background:linear-gradient(135deg,rgba(59,130,246,0.16) 0%,rgba(99,102,241,0.08) 100%)}
.kg-vcard-title{font-size:0.8rem;font-weight:700;color:var(--text-primary);margin-bottom:6px;display:flex;align-items:center;gap:5px}
.kg-vcard-subtitle{font-size:0.65rem;color:var(--text-muted);margin-bottom:8px}
.kg-tech-badges{display:flex;flex-wrap:wrap;gap:3px;margin-bottom:6px}
.kg-tech-badge{display:inline-block;padding:2px 6px;border-radius:4px;font-size:0.58rem;font-weight:600;background:rgba(99,102,241,0.15);color:#a5b4fc;border:1px solid rgba(99,102,241,0.2)}
.kg-tech-badge.cb{background:rgba(14,165,233,0.15);color:#7dd3fc;border-color:rgba(14,165,233,0.25)}
.kg-tech-badge.ss{background:rgba(139,92,246,0.15);color:#c4b5fd;border-color:rgba(139,92,246,0.25)}
.kg-stat-bar{height:6px;background:rgba(255,255,255,0.06);border-radius:3px;overflow:hidden;margin:3px 0}
.kg-stat-fill{height:100%;border-radius:3px;transition:width 0.6s ease}
.kg-stat-row{display:flex;justify-content:space-between;align-items:center;font-size:0.62rem;color:var(--text-muted);margin-top:2px}
.kg-stat-row .val{color:var(--text-primary);font-weight:600}
.kg-gauge-wrap{display:flex;align-items:center;justify-content:center;margin:4px 0}
.kg-gauge-wrap svg{overflow:visible}
.kg-tag-cloud{display:flex;flex-wrap:wrap;gap:2px;margin:4px 0}
.kg-tag{display:inline-block;padding:1px 5px;border-radius:3px;font-size:0.55rem;background:rgba(255,255,255,0.06);color:var(--text-secondary);border:1px solid rgba(255,255,255,0.05)}
.kg-arch-bar{display:flex;height:8px;border-radius:4px;overflow:hidden;margin:4px 0;gap:1px}
.kg-arch-seg{height:100%;min-width:4px;transition:flex 0.4s ease}
.kg-mini-cards{display:flex;gap:6px;margin:4px 0}
.kg-mini-card{flex:1;padding:6px;border-radius:6px;background:rgba(255,255,255,0.04);border:1px solid rgba(255,255,255,0.06)}
.kg-mini-card .mc-label{font-size:0.55rem;color:var(--text-muted);margin-bottom:2px}
.kg-mini-card .mc-val{font-size:0.72rem;font-weight:700;color:var(--text-primary)}
.kg-strength-bar{display:flex;height:10px;border-radius:5px;overflow:hidden;margin:4px 0}
.kg-strength-seg{height:100%;display:flex;align-items:center;justify-content:center;font-size:0.5rem;font-weight:700;color:rgba(255,255,255,0.8)}
.kg-trend-arrow{display:inline-flex;align-items:center;gap:3px;font-size:0.62rem;font-weight:600;padding:2px 6px;border-radius:4px}
.kg-trend-up{background:rgba(239,68,68,0.15);color:#fca5a5}
.kg-trend-down{background:rgba(34,197,94,0.15);color:#86efac}
.kg-trend-stable{background:rgba(148,163,184,0.12);color:#94a3b8}
.kg-progress-ring{position:relative;display:inline-flex;align-items:center;justify-content:center}
.kg-progress-text{position:absolute;font-size:0.6rem;font-weight:700;color:var(--text-primary)}
.kg-avatar-lg{font-size:1.6rem;margin-right:4px}
.kg-model-badge{display:inline-block;padding:1px 5px;border-radius:3px;font-size:0.52rem;font-weight:600;background:rgba(139,92,246,0.2);color:#c4b5fd;border:1px solid rgba(139,92,246,0.25)}

/* ── Risk Heatmap ── */
.risk-heatmap-wrap{margin:20px 0}
.risk-heatmap-title{font-size:0.82rem;color:var(--text-primary);margin-bottom:12px;font-weight:600}
.risk-heatmap{display:grid;grid-template-columns:auto repeat(5,1fr);gap:3px;max-width:500px}
.risk-hm-label{font-size:0.58rem;color:var(--text-muted);display:flex;align-items:center;justify-content:center;padding:4px 8px;white-space:nowrap}
.risk-hm-cell{aspect-ratio:1;border-radius:4px;display:flex;align-items:center;justify-content:center;font-size:0.62rem;font-weight:700;color:rgba(255,255,255,0.85);cursor:pointer;transition:all 0.2s;min-height:36px;position:relative}
.risk-hm-cell:hover{transform:scale(1.08);z-index:2;box-shadow:0 0 12px rgba(0,0,0,0.4)}
.risk-hm-cell.sev-low{background:rgba(16,185,129,0.25);color:var(--accent)}
.risk-hm-cell.sev-med{background:rgba(251,191,36,0.3);color:var(--yellow)}
.risk-hm-cell.sev-high{background:rgba(245,158,11,0.4);color:var(--orange)}
.risk-hm-cell.sev-crit{background:rgba(239,68,68,0.45);color:var(--red)}
.risk-hm-cell.sev-none{background:var(--bg-secondary);color:var(--text-muted)}
.risk-hm-corner{background:none}

/* ── Think Tank Debate Mode ── */
.tt-debate-section{margin-top:16px}
.tt-debate-intro{margin-bottom:20px}
.tt-debate-ring{display:flex;align-items:center;justify-content:center;gap:20px;padding:24px;background:var(--bg-secondary);border:1px solid var(--border);border-radius:var(--radius)}
.tt-debate-side{font-size:1rem;font-weight:600;padding:12px 24px;border-radius:var(--radius);display:flex;align-items:center;gap:8px}
.tt-debate-side.pro{background:rgba(16,185,129,0.12);color:var(--accent);border:1px solid rgba(16,185,129,0.3)}
.tt-debate-side.con{background:rgba(239,68,68,0.12);color:var(--red);border:1px solid rgba(239,68,68,0.3)}
.tt-debate-vs{font-size:1.3rem;font-weight:800;color:var(--text-muted);letter-spacing:2px}
.tt-debate-results{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-top:20px}
.tt-debate-col{background:var(--bg-secondary);border:1px solid var(--border);border-radius:var(--radius);padding:16px;max-height:500px;overflow-y:auto}
.tt-debate-col.pro{border-top:3px solid var(--accent)}
.tt-debate-col.con{border-top:3px solid var(--red)}
.tt-debate-col h4{margin:0 0 12px;font-size:0.88rem}
.tt-debate-verdict{grid-column:1/-1;background:var(--bg-card);border:1.5px solid var(--accent);border-radius:var(--radius);padding:20px;margin-top:4px}
.tt-debate-verdict h4{color:var(--accent);margin:0 0 10px;font-size:0.92rem}
.tt-debate-entry{padding:12px;margin-bottom:10px;background:var(--bg-card);border-radius:var(--radius);border:1px solid var(--border)}
.tt-debate-entry .engine-name{font-size:0.72rem;color:var(--accent);font-weight:600;margin-bottom:6px}
.tt-debate-entry .debate-text{font-size:0.78rem;color:var(--text-secondary);line-height:1.6}
@media(max-width:768px){.tt-debate-results{grid-template-columns:1fr}}
