/* ============================================================
   Jungle UI — VC Intelligence Platform
   World-class Dashboard Architecture
   ============================================================ */

/* ---- Reset & Base ---- */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  /* Core Palette (True Dark) */
  --bg-primary: #0A0A0A;
  --bg-secondary: #0F0F0F;
  --bg-tertiary: #141414;
  --bg-card: #141414;
  --bg-card-hover: #1A1A1A;
  --bg-glass: rgba(20, 20, 20, 0.7);
  --bg-modal: rgba(10, 10, 10, 0.95);

  /* Borders (Subtle, strictly for structure) */
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-dim: rgba(255, 255, 255, 0.12);
  --border-medium: rgba(255, 255, 255, 0.18);
  --border-accent: rgba(99, 102, 241, 0.3);

  /* Text Hierarchy */
  --text-primary: #EDEDED;
  --text-secondary: #888888;
  --text-tertiary: #666666;
  --text-muted: #444444;

  /* Functional Semantic Colors */
  --accent-emerald: #10B981;  /* Positive / Growth */
  --accent-amber: #F59E0B;    /* Warning / Stale */
  --accent-red: #EF4444;      /* Critical / Negative */
  --accent-indigo: #6366F1;   /* Brand / Primary Action */
  
  /* Extended Palette (Use sparingly for badges only) */
  --accent-teal: #14B8A6;
  --accent-blue: #3B82F6;
  --accent-purple: #8B5CF6;
  --accent-pink: #EC4899;
  --accent-orange: #F97316;

  /* Tier Gradients */
  --tier-hot: linear-gradient(135deg, #EF4444, #F97316);
  --tier-warm: linear-gradient(135deg, #F59E0B, #EAB308);
  --tier-watch: linear-gradient(135deg, #6366F1, #8B5CF6);

  /* Shadows (Removed heavy shadows, keeping only functional glows) */
  --shadow-sm: none;
  --shadow-md: none;
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.8);
  --shadow-glow-emerald: 0 0 15px rgba(16, 185, 129, 0.15);
  --shadow-glow-indigo: 0 0 15px rgba(99, 102, 241, 0.15);

  /* Spacing Grid (4px basis) */
  --sidebar-width: 256px;
  --header-height: 64px;

  /* Transitions (Zero latency feel) */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --transition-fast: 100ms var(--ease-out);
  --transition-med: 200ms var(--ease-out);
  --transition-slow: 400ms var(--ease-out);

  /* Radius (Tighter radius for enterprise feel) */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
}

html {
  font-size: 16px;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background: var(--bg-primary);
  color: var(--text-primary);
  overflow: hidden;
  height: 100vh;
}

/* ---- App Layout ---- */
.app {
  display: flex;
  height: 100vh;
  overflow: hidden;
  background: var(--bg-primary);
}

/* ---- Sidebar (Minimalist Stripe style) ---- */
.sidebar {
  width: var(--sidebar-width);
  min-width: var(--sidebar-width);
  background: var(--bg-secondary);
  border-right: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  z-index: 100;
  transition: transform var(--transition-med);
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 24px 20px 20px;
  border-bottom: 1px solid var(--border-subtle);
}

.brand-icon {
  font-size: 24px;
  filter: drop-shadow(0 0 10px rgba(99, 102, 241, 0.3));
}

.brand-name {
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

.brand-sub {
  font-size: 0.65rem;
  color: var(--text-secondary);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-top: 2px;
}

/* Nav Items */
.sidebar-nav {
  flex: 1;
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  overflow-y: auto;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.85rem;
  transition: all var(--transition-fast);
  position: relative;
}

.nav-item:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.03);
}

.nav-item.active {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.08);
  font-weight: 600;
}

.nav-icon {
  font-size: 1.1rem;
  opacity: 0.8;
}

.nav-item.active .nav-icon {
  color: var(--accent-indigo);
  opacity: 1;
}

.nav-badge {
  margin-left: auto;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: var(--radius-md);
  background: rgba(99, 102, 241, 0.15);
  color: var(--accent-indigo);
}

.nav-badge.pulse {
  animation: pulse-badge 2s infinite;
  background: rgba(245, 158, 11, 0.15);
  color: var(--accent-amber);
}

@keyframes pulse-badge {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.6;
  }
}

.sidebar-footer {
  padding: 16px 20px;
  border-top: 1px solid var(--border-subtle);
}

.date-display {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.date-label {
  font-size: 0.68rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 600;
}

.date-value {
  font-size: 0.82rem;
  color: var(--text-secondary);
  font-family: 'JetBrains Mono', monospace;
}

/* ---- Main Content ---- */
.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-width: 0;
}

/* Header */
.main-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  height: var(--header-height);
  min-height: var(--header-height);
  border-bottom: 1px solid var(--border-subtle);
  background: rgba(10, 10, 10, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  gap: 16px;
  flex-wrap: wrap;
  z-index: 50;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.page-title {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

.header-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.search-container {
  display: flex;
  align-items: center;
  background: var(--bg-secondary);
  border: 1px solid var(--border-dim);
  border-radius: var(--radius-sm);
  padding: 0 12px;
  transition: all var(--transition-fast);
  height: 36px;
}

.search-container:focus-within {
  border-color: var(--accent-indigo);
  background: var(--bg-tertiary);
}

.search-icon {
  font-size: 0.85rem;
  margin-right: 8px;
  color: var(--text-secondary);
}

.search-input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.85rem;
  width: 240px;
}

.search-input::placeholder {
  color: var(--text-muted);
}

.filter-group {
  display: flex;
  gap: 8px;
}

.filter-select {
  background: var(--bg-secondary);
  border: 1px solid var(--border-dim);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 500;
  height: 36px;
  padding: 0 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  outline: none;
  transition: all var(--transition-fast);
  -webkit-appearance: none;
}

.filter-select:hover {
  background: var(--bg-tertiary);
}

.filter-select:focus {
  border-color: var(--accent-indigo);
}

/* ---- Content Area ---- */
.content-area {
  flex: 1;
  overflow-y: auto;
  padding: 32px 40px;
  scroll-behavior: smooth;
  background: var(--bg-primary);
}

.content-area::-webkit-scrollbar {
  width: 6px;
}

.content-area::-webkit-scrollbar-track {
  background: transparent;
}

.content-area::-webkit-scrollbar-thumb {
  background: var(--border-medium);
  border-radius: 3px;

}

.content-area::-webkit-scrollbar-thumb:hover {
  background: var(--border-medium);
}

/* ---- Stats Bar ---- */
.stats-bar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
  margin-bottom: 24px;
  animation: fadeInUp 0.4s var(--ease-out);
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  transition: all var(--transition-fast);
  display: flex;
  flex-direction: column;
}

.stat-card:hover {
  border-color: var(--border-medium);
  background: var(--bg-card-hover);
}

.stat-label {
  font-size: 0.68rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
  margin-bottom: 8px;
}

.stat-value {
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  font-family: 'JetBrains Mono', monospace;
  color: var(--text-primary);
}

.stat-value.emerald { color: var(--accent-emerald); }
.stat-value.blue { color: var(--accent-blue); }
.stat-value.orange { color: var(--accent-orange); }
.stat-value.pink { color: var(--accent-pink); }
.stat-value.purple { color: var(--accent-purple); }
.stat-value.amber { color: var(--accent-amber); }

.stat-change {
  font-size: 0.72rem;
  margin-top: 6px;
  display: flex;
  align-items: center;
  gap: 4px;
  font-weight: 500;
}

.stat-change.positive { color: var(--accent-emerald); }
.stat-change.negative { color: var(--accent-red); }

/* ---- Deal Cards ---- */
.deal-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  animation: fadeInUp 0.4s var(--ease-out);
}

.deal-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  cursor: pointer;
  transition: all var(--transition-fast);
  position: relative;
  overflow: hidden;
}

.deal-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: 2px;
  border-radius: 2px 0 0 2px;
  opacity: 0;
  transition: opacity var(--transition-fast);
}

.deal-card.tier-hot::before {
  background: var(--tier-hot);
  opacity: 1;
}

.deal-card.tier-warm::before {
  background: var(--tier-warm);
  opacity: 1;
}

.deal-card.tier-watch::before {
  background: var(--tier-watch);
  opacity: 0.6;
}

.deal-card:hover {
  border-color: var(--border-medium);
  background: var(--bg-card-hover);
  /* Removed X-translation to maintain grid alignment */
}

.deal-rank {
  font-size: 1.2rem;
  font-weight: 700;
  font-family: 'JetBrains Mono', monospace;
  color: var(--text-muted);
  text-align: center;
  min-width: 32px;
}

.deal-card.tier-hot .deal-rank {
  color: var(--accent-orange);
}

.deal-info {
  min-width: 0;
}

.deal-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 2px;
}

.deal-logo {
  font-size: 1.2rem;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-tertiary);
  border-radius: var(--radius-sm);
}

.deal-name {
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

.deal-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
  flex-wrap: wrap;
}

.deal-tag {
  font-size: 0.65rem;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(99, 102, 241, 0.12);
  color: var(--accent-indigo);
  letter-spacing: 0.02em;
}

.deal-tag.sector-consumer {
  background: rgba(236, 72, 153, 0.12);
  color: var(--accent-pink);
}

.deal-tag.sector-b2b {
  background: rgba(59, 130, 246, 0.12);
  color: var(--accent-blue);
}

.deal-tag.geo {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-secondary);
}

.deal-signals {
  display: flex;
  gap: 4px;
  align-items: center;
}

.signal-dot {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-dim);
  transition: all var(--transition-fast);
  position: relative;
}

.signal-dot.hot {
  border-color: var(--accent-emerald);
}

.signal-dot:hover {
  border-color: var(--border-medium);
  z-index: 2;
}

.signal-dot .tooltip {
  display: none;
  position: absolute;
  bottom: calc(100% + 4px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-secondary);
  color: var(--text-primary);
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  font-size: 0.7rem;
  font-weight: 500;
  white-space: nowrap;
  border: 1px solid var(--border-dim);
  box-shadow: var(--shadow-lg);
  z-index: 10;
}

.signal-dot:hover .tooltip {
  display: block;
}

.deal-score-container {
  text-align: center;
  min-width: 50px;
}

.deal-score {
  font-size: 1.4rem;
  font-weight: 700;
  font-family: 'JetBrains Mono', monospace;
  line-height: 1;
}

.deal-score.score-hot {
  color: var(--accent-emerald);
}

.deal-score.score-warm {
  color: var(--accent-amber);
}

.deal-score.score-watch {
  color: var(--accent-indigo);
}

/* ---- Circular Company Avatar ---- */
.company-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 800;
  flex-shrink: 0;
  letter-spacing: 0;
}

/* ---- Kanban Board ---- */
.kanban-board {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 16px;
  align-items: flex-start;
}

.kanban-board::-webkit-scrollbar { height: 4px; }
.kanban-board::-webkit-scrollbar-track { background: transparent; }
.kanban-board::-webkit-scrollbar-thumb { background: var(--border-medium); border-radius: 2px; }

.kanban-col {
  flex: 0 0 210px;
  background: var(--bg-secondary);
  border-radius: 10px;
  border: 1px solid var(--border-subtle);
  padding: 10px;
  max-height: 620px;
  overflow-y: auto;
  scrollbar-width: thin;
}

.kanban-col::-webkit-scrollbar { width: 3px; }
.kanban-col::-webkit-scrollbar-thumb { background: var(--border-medium); border-radius: 2px; }

.kanban-col-header {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  background: var(--bg-secondary);
  z-index: 1;
}

.kanban-dot {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 800;
  flex-shrink: 0;
}

.kanban-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 8px 10px;
  margin-bottom: 6px;
  cursor: pointer;
  transition: border-color var(--transition-fast), background var(--transition-fast);
}

.kanban-card:hover {
  border-color: var(--border-medium);
  background: var(--bg-card-hover);
}

.kanban-card:last-child { margin-bottom: 0; }

.deal-score-label {
  font-size: 0.55rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 700;
  margin-top: 2px;
}

.deal-tier-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  min-width: 80px;
  justify-content: center;
}

.deal-tier-badge.tier-hot {
  background: rgba(239, 68, 68, 0.15);
  color: var(--accent-red);
}

.deal-tier-badge.tier-warm {
  background: rgba(245, 158, 11, 0.15);
  color: var(--accent-amber);
}

.deal-tier-badge.tier-watch {
  background: rgba(99, 102, 241, 0.15);
  color: var(--accent-indigo);
}

/* ---- Mini Sparkline ---- */
.sparkline-container {
  min-width: 80px;
  height: 24px;
}

.sparkline-container svg {
  width: 80px;
  height: 24px;
}

/* ---- Context Drawer (Right Side) ---- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  z-index: 1000;
  display: none;
  justify-content: flex-end; /* Align drawer to the right */
  animation: fadeIn 0.2s ease;
}

.modal-overlay.active {
  display: flex;
}

.modal-content {
  background: var(--bg-secondary);
  border-left: 1px solid var(--border-subtle);
  width: 100%;
  max-width: 600px;
  height: 100vh;
  overflow-y: auto;
  box-shadow: -10px 0 40px rgba(0, 0, 0, 0.5);
  animation: slideInRight 0.3s var(--ease-out);
  display: flex;
  flex-direction: column;
}

@keyframes slideInRight {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}

.modal-content::-webkit-scrollbar {
  width: 5px;
}

.modal-content::-webkit-scrollbar-track {
  background: transparent;
}

.modal-content::-webkit-scrollbar-thumb {
  background: var(--border-dim);
  border-radius: 3px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 32px 16px;
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  background: var(--bg-secondary);
  z-index: 2;
}

.modal-title {
  display: flex;
  align-items: center;
  gap: 12px;
}

.modal-title .deal-logo {
  font-size: 1.6rem;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
}

.modal-title h3 {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}
.modal-title .sub {
  font-size: 0.75rem;
  color: var(--text-secondary);
  margin-top: 2px;
}

.modal-close {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-dim);
  color: var(--text-secondary);
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1rem;
  transition: all var(--transition-fast);
}

.modal-close:hover {
  background: rgba(239, 68, 68, 0.15);
  border-color: var(--accent-red);
  color: var(--accent-red);
}

.modal-body {
  padding: 32px;
  flex: 1;
}

/* Modal Sections */
.modal-section {
  margin-bottom: 32px;
}

.modal-section-title {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 8px;
}

/* Radar Chart */
.radar-chart-container {
  display: flex;
  justify-content: center;
  padding: 16px 0;
}

.radar-chart-container svg {
  max-width: 320px;
  max-height: 320px;
}

/* Score Breakdown */
.score-breakdown {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.score-dim {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
}

.score-dim-label {
  flex: 1;
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.score-dim-bar {
  width: 60px;
  height: 4px;
  background: var(--bg-primary);
  border-radius: 2px;
  overflow: hidden;
}

.score-dim-bar-fill {
  height: 100%;
  border-radius: 2px;
  transition: width 0.8s var(--ease-out);
}

.score-dim-val {
  font-size: 0.85rem;
  font-weight: 700;
  font-family: 'JetBrains Mono', monospace;
  min-width: 28px;
  text-align: right;
  color: var(--text-primary);
}

/* Founders */
.founders-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.founder-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
  transition: all var(--transition-fast);
}

.founder-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-medium);
}

.founder-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-secondary);
  border: 1px solid var(--border-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-primary);
  flex-shrink: 0;
}

.founder-name {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
}

.founder-role {
  font-size: 0.75rem;
  color: var(--text-secondary);
  font-weight: 500;
  margin-top: 2px;
}

.founder-pedigree {
  font-size: 0.75rem;
  color: var(--text-tertiary);
  margin-top: 2px;
}

/* Signals Grid */
.signals-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.signal-card {
  padding: 12px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
  transition: all var(--transition-fast);
}

.signal-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-medium);
}

.signal-card-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.signal-card-icon {
  font-size: 1rem;
}

.signal-card-label {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.signal-card-score {
  font-size: 1rem;
  font-weight: 700;
  font-family: 'JetBrains Mono', monospace;
  color: var(--text-primary);
}

.signal-card-detail {
  font-size: 0.75rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Thesis Box */
.thesis-box {
  background: rgba(16, 185, 129, 0.03);
  border: 1px solid rgba(16, 185, 129, 0.2);
  border-radius: var(--radius-sm);
  padding: 16px;
}

.thesis-box p {
  font-size: 0.82rem;
  line-height: 1.6;
  color: var(--text-primary);
}

/* ---- Section: Valuation Intelligence ---- */
.valuation-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.val-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
}

.val-card-title {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 12px;
}

.val-company {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid var(--border-subtle);
}

.val-company:last-child {
  border-bottom: none;
}

.val-company-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
}

.val-company-sub {
  font-size: 0.7rem;
  color: var(--text-secondary);
}

.val-tag {
  font-size: 0.65rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  letter-spacing: 0.02em;
}

.val-tag.overpriced {
  background: rgba(239, 68, 68, 0.15);
  color: var(--accent-red);
}

.val-tag.fair {
  background: rgba(16, 185, 129, 0.15);
  color: var(--accent-emerald);
}

.val-tag.underpriced {
  background: rgba(59, 130, 246, 0.12);
  color: var(--accent-blue);
}

/* ---- Section: Thesis Tracker ---- */
.thesis-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.thesis-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  transition: all var(--transition-fast);
}

.thesis-card:hover {
  border-color: var(--border-medium);
  background: var(--bg-card-hover);
}

.thesis-card.accelerating {
  border-left: 3px solid var(--accent-emerald);
}

.thesis-card.saturated {
  border-left: 3px solid var(--accent-amber);
}

.thesis-card.whitespace {
  border-left: 3px solid var(--accent-indigo);
}

.thesis-card-emoji {
  font-size: 1.6rem;
  margin-bottom: 8px;
}

.thesis-card-title {
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--text-primary);
}

.thesis-card-desc {
  font-size: 0.72rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.thesis-card-status {
  margin-top: 8px;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.thesis-card-status.up {
  color: var(--accent-emerald);
}

.thesis-card-status.flat {
  color: var(--accent-amber);
}

.thesis-card-status.down {
  color: var(--accent-red);
}

/* ---- Section: Portfolio ---- */
.portfolio-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.portfolio-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  display: grid;
  grid-template-columns: auto 1fr repeat(4, auto);
  align-items: center;
  gap: 16px;
  transition: all var(--transition-fast);
}

.portfolio-card:hover {
  border-color: var(--border-medium);
  background: var(--bg-card-hover);
}

.portfolio-logo {
  font-size: 1.4rem;
}

.portfolio-info-name {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
}

.portfolio-info-sub {
  font-size: 0.72rem;
  color: var(--text-secondary);
}

.portfolio-metric {
  text-align: right;
  min-width: 75px;
}

.portfolio-metric-value {
  font-size: 1rem;
  font-weight: 700;
  font-family: 'JetBrains Mono', monospace;
  color: var(--text-primary);
}

.portfolio-metric-label {
  font-size: 0.65rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}

.health-indicator {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 4px;
}

.health-indicator.green {
  background: rgba(16, 185, 129, 0.15);
  color: var(--accent-emerald);
}

.health-indicator.yellow {
  background: rgba(245, 158, 11, 0.15);
  color: var(--accent-amber);
}

.health-indicator.red {
  background: rgba(239, 68, 68, 0.15);
  color: var(--accent-red);
}

/* ---- Power Moves ---- */
.power-timeline {
  position: relative;
  padding-left: 24px;
}

.power-timeline::before {
  content: '';
  position: absolute;
  left: 8px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--border-subtle);
}

.power-event {
  position: relative;
  padding: 14px 18px;
  margin-bottom: 12px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
}

.power-event:hover {
  border-color: var(--border-medium);
  background: var(--bg-card-hover);
}

.power-event::before {
  content: '';
  position: absolute;
  left: -20px;
  top: 20px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-indigo);
  border: 2px solid var(--bg-primary);
}

.power-event:nth-child(even)::before {
  background: var(--accent-emerald);
}

.power-event:nth-child(3n)::before {
  background: var(--accent-amber);
}

.power-event-type {
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 4px;
}

.power-event-title {
  font-size: 0.88rem;
  font-weight: 600;
  margin-bottom: 4px;
  color: var(--text-primary);
}

.power-event-desc {
  font-size: 0.75rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.power-event-implication {
  margin-top: 8px;
  padding: 8px 12px;
  background: rgba(245, 158, 11, 0.08);
  border-left: 2px solid var(--accent-amber);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 0.75rem;
  color: var(--text-primary);
  font-weight: 500;
}

.power-event-time {
  font-size: 0.65rem;
  color: var(--text-muted);
  font-family: 'JetBrains Mono', monospace;
  margin-top: 8px;
}

/* ---- Pattern Engine ---- */
.pattern-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.pattern-column {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
}

.pattern-column-title {
  font-size: 0.8rem;
  font-weight: 700;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-primary);
}

.pattern-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border-subtle);
}

.pattern-item:last-child {
  border-bottom: none;
}

.pattern-check {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.6rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.pattern-check.win {
  background: rgba(16, 185, 129, 0.15);
  color: var(--accent-emerald);
}

.pattern-check.fail {
  background: rgba(239, 68, 68, 0.15);
  color: var(--accent-red);
}

.pattern-text {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.pattern-text strong {
  color: var(--text-primary);
  font-weight: 600;
}

/* Checklist */
.checklist-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 16px;
}

.checklist-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  color: var(--text-secondary);
  transition: all var(--transition-fast);
}

.checklist-item:hover {
  border-color: var(--accent-emerald);
  background: rgba(16, 185, 129, 0.05);
  color: var(--text-primary);
}

.checklist-icon {
  font-size: 1rem;
}

/* ---- Daily Briefing ---- */
.briefing-container {
  max-width: 720px;
  margin: 0 auto;
}

.briefing-date {
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-family: 'JetBrains Mono', monospace;
  margin-bottom: 24px;
  text-align: center;
}

.briefing-section {
  margin-bottom: 32px;
}

.briefing-section-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 8px;
}

.briefing-section-emoji {
  font-size: 1.2rem;
}

.briefing-section-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-primary);
}

.briefing-section-count {
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--accent-emerald);
  background: rgba(16, 185, 129, 0.15);
  padding: 2px 8px;
  border-radius: var(--radius-sm);
}

.briefing-item {
  padding: 12px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  margin-bottom: 8px;
  transition: all var(--transition-fast);
}

.briefing-item:hover {
  border-color: var(--border-medium);
  background: var(--bg-card-hover);
}

.briefing-item-title {
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--text-primary);
}

.briefing-item-body {
  font-size: 0.75rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.briefing-item.contrarian {
  border-left: 3px solid var(--accent-orange);
  background: rgba(249, 115, 22, 0.04);
}

.briefing-item.alert {
  border-left: 3px solid var(--accent-red);
  background: rgba(239, 68, 68, 0.04);
}

.briefing-item.spicy {
  border-left: 3px solid var(--accent-pink);
  background: rgba(236, 72, 153, 0.04);
}

/* ---- Animations ---- */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-15px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideOutRight {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(100%);
  }
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.spin-animation {
  display: inline-block;
  animation: spin 1s linear infinite;
}

.animated-item {
  animation: fadeInUp 0.3s var(--ease-out) both;
}

.animated-item:nth-child(1) { animation-delay: 0.02s; }
.animated-item:nth-child(2) { animation-delay: 0.04s; }
.animated-item:nth-child(3) { animation-delay: 0.06s; }
.animated-item:nth-child(4) { animation-delay: 0.08s; }
.animated-item:nth-child(5) { animation-delay: 0.10s; }
.animated-item:nth-child(6) { animation-delay: 0.12s; }
.animated-item:nth-child(7) { animation-delay: 0.14s; }
.animated-item:nth-child(8) { animation-delay: 0.16s; }
.animated-item:nth-child(9) { animation-delay: 0.18s; }
.animated-item:nth-child(10) { animation-delay: 0.20s; }

/* ---- Section Title ---- */
.section-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.section-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
}

.section-subtitle {
  font-size: 0.75rem;
  color: var(--text-secondary);
}

/* Insight Box */
.insight-box {
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  margin-bottom: 12px;
  font-size: 0.8rem;
  line-height: 1.5;
}

.insight-box.positive {
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.2);
  color: var(--accent-emerald);
}

.insight-box.warning {
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.2);
  color: var(--accent-amber);
}

.insight-box.info {
  background: rgba(99, 102, 241, 0.08);
  border: 1px solid rgba(99, 102, 241, 0.2);
  color: var(--accent-indigo);
}

.insight-emoji {
  margin-right: 6px;
}

/* ---- Deck Analyzer ---- */
.deck-upload-zone {
  border: 2px dashed var(--border-medium);
  border-radius: var(--radius-xl);
  padding: 48px 32px;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-med);
  background: var(--bg-card);
  position: relative;
}

.deck-upload-zone:hover,
.deck-upload-zone.dragover {
  border-color: var(--accent-emerald);
  background: var(--accent-emerald-glow);
  box-shadow: var(--shadow-glow-emerald);
}

.deck-upload-zone .upload-icon {
  font-size: 3rem;
  margin-bottom: 12px;
  display: block;
  filter: grayscale(0.4);
}

.deck-upload-zone:hover .upload-icon {
  filter: grayscale(0);
}

.deck-upload-zone .upload-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.deck-upload-zone .upload-subtitle {
  font-size: 0.82rem;
  color: var(--text-tertiary);
}

.deck-upload-zone .upload-btn {
  display: inline-block;
  margin-top: 16px;
  padding: 10px 28px;
  background: linear-gradient(135deg, var(--accent-emerald), var(--accent-teal));
  color: var(--bg-primary);
  font-weight: 700;
  font-size: 0.85rem;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.deck-upload-zone .upload-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(16, 185, 129, 0.3);
}

.deck-upload-zone input[type="file"] {
  display: none;
}

/* Uploaded Decks Grid */
.decks-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 16px;
  margin-top: 24px;
}

.deck-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 20px 22px;
  transition: all var(--transition-fast);
  backdrop-filter: blur(8px);
  position: relative;
  overflow: hidden;
}

.deck-card:hover {
  border-color: var(--border-medium);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.deck-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.deck-card-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
}

.deck-card-icon.pdf {
  background: rgba(239, 68, 68, 0.12);
}

.deck-card-icon.ppt {
  background: rgba(249, 115, 22, 0.12);
}

.deck-card-name {
  font-size: 0.95rem;
  font-weight: 700;
}

.deck-card-meta {
  display: flex;
  gap: 6px;
  margin-top: 3px;
}

.deck-card-timestamp {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-family: 'JetBrains Mono', monospace;
}

/* Deck Score Ring */
.deck-overall-score {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-left: auto;
}

.score-ring {
  width: 56px;
  height: 56px;
  position: relative;
}

.score-ring svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.score-ring .bg {
  fill: none;
  stroke: var(--bg-primary);
  stroke-width: 4;
}

.score-ring .progress {
  fill: none;
  stroke-width: 4;
  stroke-linecap: round;
  transition: stroke-dashoffset 1s var(--ease-out);
}

.score-ring-value {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  font-weight: 800;
  font-family: 'JetBrains Mono', monospace;
}

/* Deck Rating Rows */
.deck-ratings {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}

.deck-rating-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 0;
}

.deck-rating-label {
  font-size: 0.75rem;
  color: var(--text-secondary);
  width: 110px;
  flex-shrink: 0;
}

.deck-rating-bar {
  flex: 1;
  height: 6px;
  background: var(--bg-primary);
  border-radius: 3px;
  overflow: hidden;
}

.deck-rating-bar-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.8s var(--ease-out);
}

.deck-rating-val {
  font-size: 0.78rem;
  font-weight: 700;
  font-family: 'JetBrains Mono', monospace;
  min-width: 20px;
  text-align: right;
}

/* Deck Verdict */
.deck-verdict {
  margin-top: 14px;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  font-size: 0.78rem;
  line-height: 1.5;
}

.deck-verdict.pass {
  background: var(--accent-emerald-glow);
  border: 1px solid rgba(16, 185, 129, 0.2);
  color: var(--accent-emerald);
}

.deck-verdict.review {
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.2);
  color: var(--accent-amber);
}

.deck-verdict.skip {
  background: var(--accent-red-glow);
  border: 1px solid rgba(239, 68, 68, 0.15);
  color: var(--accent-red);
}

.deck-action-btns {
  display: flex;
  gap: 8px;
  margin-top: 14px;
}

.deck-action-btn {
  flex: 1;
  padding: 8px 0;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 700;
  text-align: center;
  cursor: pointer;
  border: 1px solid var(--border-dim);
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  transition: all var(--transition-fast);
}

.deck-action-btn:hover {
  border-color: var(--accent-emerald);
  color: var(--accent-emerald);
}

.deck-action-btn.primary {
  background: linear-gradient(135deg, var(--accent-emerald), var(--accent-teal));
  color: var(--bg-primary);
  border: none;
}

.deck-action-btn.primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 12px rgba(16, 185, 129, 0.3);
}

/* ---- Integrations Hub ---- */
.integrations-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 20px;
}

.integration-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: all var(--transition-fast);
}

.integration-card:hover {
  border-color: var(--border-medium);
  box-shadow: var(--shadow-md);
}

.integration-card-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
}

.integration-logo {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  flex-shrink: 0;
}

.integration-logo.gmail {
  background: rgba(234, 67, 53, 0.12);
}

.integration-logo.streak {
  background: rgba(255, 152, 0, 0.12);
}

.integration-logo.supabase {
  background: rgba(62, 207, 142, 0.12);
}

.integration-logo.team {
  background: rgba(99, 102, 241, 0.12);
}

.integration-name {
  font-size: 1rem;
  font-weight: 700;
}

.integration-desc {
  font-size: 0.75rem;
  color: var(--text-tertiary);
  margin-top: 2px;
}

.integration-status {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 6px;
}

.integration-status.connected {
  background: var(--accent-emerald-glow);
  color: var(--accent-emerald);
}

.integration-status.disconnected {
  background: var(--bg-tertiary);
  color: var(--text-muted);
}

.integration-status.pending {
  background: rgba(245, 158, 11, 0.08);
  color: var(--accent-amber);
}

.integration-body {
  margin-top: 4px;
}

.integration-input-group {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}

.integration-input {
  flex: 1;
  padding: 10px 14px;
  background: var(--bg-primary);
  border: 1px solid var(--border-dim);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  outline: none;
  transition: border-color var(--transition-fast);
}

.integration-input:focus {
  border-color: var(--accent-emerald);
}

.integration-input::placeholder {
  color: var(--text-muted);
}

.integration-connect-btn {
  padding: 10px 20px;
  background: linear-gradient(135deg, var(--accent-emerald), var(--accent-teal));
  color: var(--bg-primary);
  font-weight: 700;
  font-size: 0.78rem;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.integration-connect-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 12px rgba(16, 185, 129, 0.3);
}

.integration-connect-btn.google {
  background: #fff;
  color: #333;
  border: 1px solid #ddd;
  display: flex;
  align-items: center;
  gap: 8px;
}

.integration-connect-btn.google:hover {
  background: #f5f5f5;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.integration-connect-btn.streak-btn {
  background: linear-gradient(135deg, #FF9800, #FF5722);
}

.integration-features {
  display: grid;
  gap: 6px;
  margin-top: 12px;
}

.integration-feature {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
  color: var(--text-secondary);
  padding: 6px 0;
}

.integration-feature-icon {
  color: var(--accent-emerald);
  font-size: 0.85rem;
}

/* Sync Log */
.sync-log {
  margin-top: 12px;
  padding: 10px 14px;
  background: var(--bg-primary);
  border-radius: var(--radius-sm);
  font-size: 0.72rem;
  font-family: 'JetBrains Mono', monospace;
  color: var(--text-tertiary);
  max-height: 120px;
  overflow-y: auto;
}

.sync-log-entry {
  padding: 3px 0;
  border-bottom: 1px solid var(--border-dim);
}

.sync-log-entry:last-child {
  border-bottom: none;
}

.sync-log-time {
  color: var(--text-muted);
  margin-right: 8px;
}

.sync-log-ok {
  color: var(--accent-emerald);
}

.sync-log-warn {
  color: var(--accent-amber);
}

/* Team Members */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.team-member-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  background: var(--bg-primary);
  border: 1px solid var(--border-dim);
  border-radius: var(--radius-md);
}

.team-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.75rem;
  color: #fff;
  flex-shrink: 0;
}

.team-member-name {
  font-size: 0.82rem;
  font-weight: 600;
}

.team-member-role {
  font-size: 0.68rem;
  color: var(--text-muted);
}

.team-invite-form {
  display: flex;
  gap: 8px;
  margin-top: 14px;
}

/* ---- Responsive ---- */
@media (max-width: 1100px) {
  .main-header {
    flex-wrap: wrap;
    height: auto;
    min-height: var(--header-height);
    padding: 12px 24px;
  }

  .filter-group {
    display: none;
  }

  .deal-card {
    /* compact layout already handles mobile */
  }

  .deal-grid {
    grid-template-columns: 1fr;
  }

  .deal-signals {
    display: none;
  }

  .valuation-grid,
  .thesis-grid,
  .pattern-columns,
  .score-breakdown,
  .signals-grid,
  .checklist-grid {
    grid-template-columns: 1fr;
  }

  .portfolio-card {
    grid-template-columns: auto 1fr auto auto;
    gap: 14px;
  }

  .portfolio-metric:nth-child(n+5) {
    display: none;
  }
}

@media (max-width: 768px) {
  .sidebar {
    position: fixed;
    transform: translateX(-100%);
    z-index: 200;
    height: 100vh;
    box-shadow: var(--shadow-lg);
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .menu-toggle {
    display: flex;
  }

  .search-input {
    width: 140px;
  }

  .header-right {
    width: 100%;
  }

  .deal-card {
    grid-template-columns: 1fr auto;
    gap: 12px;
  }

  .deal-rank {
    display: none;
  }

  .sparkline-container {
    display: none;
  }

  .portfolio-card {
    grid-template-columns: auto 1fr;
    gap: 10px;
  }

  .portfolio-metric {
    display: none;
  }

  .portfolio-card>div:last-child {
    grid-column: 1 / -1;
  }

  .decks-grid,
  .integrations-grid {
    grid-template-columns: 1fr;
  }

  .briefing-container {
    max-width: 100%;
  }

  .deck-upload-zone {
    padding: 32px 20px;
  }

  .team-invite-form {
    flex-wrap: wrap;
  }

  .integration-input-group {
    flex-wrap: wrap;
  }

  .content-area {
    padding: 16px;
  }

  .stats-bar {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
}

@media (max-width: 480px) {
  .stats-bar {
    grid-template-columns: 1fr;
  }

  .page-title {
    font-size: 1rem;
  }

  .search-input {
    width: 100px;
  }
}

/* ============================================================
   PHASE 3: MODULE STYLES
   ============================================================ */

/* Nav Divider */
.nav-divider {
  height: 1px;
  background: var(--border-color);
  margin: 12px 16px;
  opacity: 0.5;
}

/* Prep Selector */
.prep-selector {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  margin-bottom: 16px;
}

.prep-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  white-space: nowrap;
}

.prep-select {
  flex: 1;
  min-width: 280px;
}

/* Phase 3 Grid */
.phase3-grid {
  display: flex;
  gap: 16px;
  margin-top: 16px;
}

.phase3-panel {
  flex: 1;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 20px;
}

.phase3-panel-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-color);
}

/* Talking Points */
.talking-point {
  padding: 12px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.talking-point:last-child {
  border-bottom: none;
}

.tp-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--accent-blue);
  margin-bottom: 4px;
}

.tp-text {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* IC Objections */
.objection-item {
  padding: 12px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.objection-item:last-child {
  border-bottom: none;
}

.objection-q {
  font-size: 0.82rem;
  color: var(--accent-red);
  font-style: italic;
  margin-bottom: 6px;
}

.objection-a {
  font-size: 0.82rem;
  color: var(--accent-green);
  padding-left: 12px;
  border-left: 2px solid var(--accent-green);
  line-height: 1.5;
}

/* Risk Matrix */
.risk-matrix-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.risk-item {
  padding: 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
}

.risk-name {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.risk-tags {
  display: flex;
  gap: 6px;
}

.risk-tag {
  font-size: 0.68rem;
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: 600;
}

.prob-high,
.impact-high {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
}

.prob-medium,
.impact-medium {
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
}

.prob-low,
.impact-low {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
}

/* IC Memo */
.memo-container {
  position: relative;
}

.memo-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  margin-bottom: 16px;
}

.memo-body {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 24px 28px;
  margin-bottom: 16px;
}

.memo-content {
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  color: var(--text-secondary);
  white-space: pre-wrap;
  line-height: 1.7;
  background: none;
  border: none;
  margin: 0;
  padding: 0;
}

.memo-radar {
  display: flex;
  justify-content: center;
  padding: 20px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
}

/* Fundraising Radar */
.radar-stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}

.stat-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 16px 20px;
  text-align: center;
}

.stat-card-value {
  font-size: 1.8rem;
  font-weight: 800;
}

.stat-card-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Signal Feed */
.signal-feed {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.signal-item {
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.02);
  border-radius: 8px;
  transition: background 0.2s;
}

.signal-item:hover {
  background: rgba(255, 255, 255, 0.05);
}

.signal-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.signal-icon {
  font-size: 1.1rem;
}

.signal-company {
  font-size: 0.85rem;
  color: var(--text-primary);
}

.signal-date {
  margin-left: auto;
  font-size: 0.72rem;
  color: var(--text-muted);
}

.signal-body {
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-bottom: 8px;
  line-height: 1.4;
}

.signal-footer {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.signal-tag {
  font-size: 0.7rem;
  padding: 3px 8px;
  border-radius: 6px;
  font-weight: 600;
}

/* Geo Heat Bars */
.geo-heat-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.geo-heat-item {
  display: flex;
  align-items: center;
  gap: 10px;
}

.geo-name {
  font-size: 0.8rem;
  color: var(--text-secondary);
  min-width: 80px;
}

.geo-bar-wrap {
  flex: 1;
  height: 8px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
  overflow: hidden;
}

.geo-bar {
  height: 100%;
  background: var(--accent-green);
  border-radius: 4px;
  transition: width 0.5s ease;
}

.geo-count {
  font-size: 0.75rem;
  color: var(--text-muted);
  min-width: 50px;
  text-align: right;
}

/* CRM Cards */
.crm-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.crm-card {
  padding: 16px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  transition: all 0.2s;
}

.crm-card:hover {
  border-color: var(--accent-blue);
  background: rgba(99, 102, 241, 0.03);
}

.crm-overdue {
  border-left: 3px solid var(--accent-red);
}

.crm-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.crm-name {
  font-size: 0.9rem;
  color: var(--text-primary);
  display: block;
}

.crm-role {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.crm-strength {
  font-size: 0.9rem;
  color: var(--accent-orange);
  letter-spacing: 2px;
}

.crm-meta-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 8px;
}

.crm-meta {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.crm-notes {
  font-size: 0.78rem;
  color: var(--text-secondary);
  margin-top: 4px;
  line-height: 1.4;
}

/* Follow-up Queue */
.followup-queue {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.followup-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.02);
  border-radius: 8px;
  flex-wrap: wrap;
  gap: 4px;
}

.followup-urgent {
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.2);
}

.followup-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-primary);
}

.followup-company {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.followup-when {
  font-size: 0.72rem;
  font-weight: 600;
}

/* Intro Network */
.intro-network {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.intro-source {
  display: flex;
  justify-content: space-between;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.02);
  border-radius: 6px;
}

.intro-name {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.intro-count {
  font-size: 0.72rem;
  color: var(--accent-blue);
  font-weight: 600;
}

/* Network Map */
.network-svg-wrap {
  width: 100%;
  max-height: 560px;
  overflow: hidden;
}

.network-svg {
  width: 100%;
  height: auto;
}

/* Co-Investor List */
.coinvestor-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.coinvestor-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.02);
  border-radius: 8px;
}

.coinvestor-rank {
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--text-muted);
  min-width: 28px;
}

.coinvestor-info {
  flex: 1;
}

.coinvestor-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-primary);
}

.coinvestor-deals {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.coinvestor-count {
  font-size: 1.2rem;
  font-weight: 800;
}

/* Syndicate Suggestions */
.syndicate-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.syndicate-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.02);
  border-radius: 6px;
}

.syndicate-deal {
  font-size: 0.8rem;
  color: var(--text-primary);
}

.syndicate-partners {
  font-size: 0.72rem;
  color: var(--accent-indigo);
  font-weight: 600;
}

/* Phase 3 Responsive */
@media (max-width: 900px) {
  .phase3-grid {
    flex-direction: column;
  }

  .risk-matrix-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .radar-stats-row {
    grid-template-columns: repeat(2, 1fr);
  }

  .memo-actions {
    flex-direction: column;
    gap: 10px;
  }
}

/* ============================================================
   PHASE 4-5: ADDITIONAL MODULE STYLES
   ============================================================ */

/* Competitive Table */
.comp-table-wrap {
  overflow-x: auto;
}

.comp-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
}

.comp-table th {
  text-align: left;
  padding: 10px 12px;
  color: var(--text-muted);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid var(--border-color);
}

.comp-table td {
  padding: 10px 12px;
  color: var(--text-secondary);
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.comp-row-jv {
  background: rgba(16, 185, 129, 0.08);
}

.comp-row-jv td {
  color: var(--accent-green);
  font-weight: 600;
}

.comp-overlap {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
  padding: 2px 8px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.75rem;
}

/* SWOT Grid */
.swot-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.swot-box {
  padding: 14px;
  border-radius: 10px;
}

.swot-box ul {
  margin: 0;
  padding-left: 16px;
}

.swot-box li {
  font-size: 0.78rem;
  color: var(--text-secondary);
  margin-bottom: 4px;
  line-height: 1.4;
}

.swot-label {
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.swot-s {
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.2);
}

.swot-s .swot-label {
  color: #10b981;
}

.swot-w {
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.2);
}

.swot-w .swot-label {
  color: #ef4444;
}

.swot-o {
  background: rgba(99, 102, 241, 0.08);
  border: 1px solid rgba(99, 102, 241, 0.2);
}

.swot-o .swot-label {
  color: #6366f1;
}

.swot-t {
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.2);
}

.swot-t .swot-label {
  color: #f59e0b;
}

/* Deal Velocity */
.velocity-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.velocity-item {}

.velocity-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}

.velocity-deal {
  font-size: 0.85rem;
  color: var(--text-primary);
}

.velocity-stage {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-left: auto;
}

.velocity-days {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent-blue);
  min-width: 30px;
  text-align: right;
}

.velocity-bar-wrap {
  display: flex;
  height: 12px;
  border-radius: 6px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.03);
}

.velocity-segment {
  height: 100%;
  transition: width 0.5s ease;
}

.velocity-legend {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--border-color);
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.7rem;
  color: var(--text-muted);
}

.legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

/* Funnel */
.funnel-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.funnel-step {
  position: relative;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.02);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  overflow: hidden;
}

.funnel-bar {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  border-radius: 6px;
  opacity: 0.15;
  z-index: 0;
}

.funnel-label {
  position: relative;
  z-index: 1;
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.funnel-count {
  position: relative;
  z-index: 1;
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--accent-purple);
}

/* Admin Panel */
.admin-notice {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.2);
  border-radius: 10px;
  margin-bottom: 16px;
  font-size: 0.82rem;
  color: var(--accent-orange);
}

.admin-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.admin-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 20px;
  transition: all 0.2s;
}

.admin-card:hover {
  border-color: var(--accent-blue);
}

.admin-connected {
  border-color: rgba(16, 185, 129, 0.3);
  background: rgba(16, 185, 129, 0.03);
}

.admin-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}

.admin-icon {
  font-size: 1.5rem;
}

.admin-name {
  font-size: 0.9rem;
  color: var(--text-primary);
  display: block;
}

.admin-status {
  font-size: 0.7rem;
}

.status-connected {
  color: var(--accent-green);
}

.status-disconnected {
  color: var(--text-muted);
}

.admin-desc {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin: 0 0 6px;
  line-height: 1.4;
}

.admin-howto {
  font-size: 0.72rem;
  color: var(--accent-blue);
  margin: 0 0 12px;
  line-height: 1.4;
  padding: 6px 10px;
  background: rgba(99, 102, 241, 0.06);
  border-radius: 6px;
  border-left: 2px solid var(--accent-blue);
}

.admin-fields {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
}

.admin-field-label {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-weight: 600;
  margin-bottom: 2px;
  display: block;
}

.admin-input {
  width: 100%;
  padding: 8px 12px;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  color: var(--text-primary);
  font-size: 0.8rem;
  font-family: 'Inter', sans-serif;
  outline: none;
  transition: border 0.2s;
  box-sizing: border-box;
}

.admin-input:focus {
  border-color: var(--accent-blue);
}

.admin-save-btn {
  width: 100%;
  padding: 8px;
  background: var(--accent-blue);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
  font-family: 'Inter', sans-serif;
}

.admin-save-btn:hover {
  background: var(--accent-indigo);
}

/* Activity Log */
.log-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 12px;
}

.activity-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.activity-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.02);
  border-radius: 8px;
  transition: background 0.2s;
}

.activity-item:hover {
  background: rgba(255, 255, 255, 0.04);
}

.activity-icon {
  font-size: 1.1rem;
  min-width: 24px;
  text-align: center;
}

.activity-info {
  flex: 1;
}

.activity-msg {
  font-size: 0.82rem;
  color: var(--text-primary);
  display: block;
}

.activity-time {
  font-size: 0.7rem;
  color: var(--text-muted);
}

/* Phase 4-5 Responsive */
@media (max-width: 900px) {
  .admin-grid {
    grid-template-columns: 1fr;
  }

  .swot-grid {
    grid-template-columns: 1fr;
  }

  .comp-table {
    font-size: 0.7rem;
  }
}