:root {
  --bg-dark: #0f1115;
  --bg-card: #16181d;
  --bg-input: #1f2229;
  --text-main: #f1f5f9;
  --text-muted: #94a3b8;
  --accent-blue: #3b82f6;
  --accent-blue-hover: #2563eb;
  --red-bear: #ef4444;
  --red-bear-bg: rgba(239, 68, 68, 0.1);
  --green-bull: #10b981;
  --border-light: rgba(255, 255, 255, 0.08);
  --shadow-glow: 0 4px 30px rgba(59, 130, 246, 0.15);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Inter', -apple-system, sans-serif;
}

html, body {
  max-width: 100vw;
  overflow-x: hidden;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  justify-content: center;
}

/* --- CUSTOM TERMINAL SCROLLBARS --- */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: var(--bg-dark);
}

::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-blue);
}

.app-container {
  width: 100%;
  max-width: 1300px; /* Increased for sidebar */
  padding: 2rem;
}

/* Dashboard Grid */
.dashboard-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 5rem; /* Increased significantly */
  align-items: flex-start;
  width: 100%;
}

.main-content {
  width: 100%;
  max-width: 900px;
}

/* History Sidebar */
.history-sidebar {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: 12px;
  padding: 1.5rem;
  height: calc(100vh - 200px);
  position: sticky;
  top: 2rem;
  display: flex;
  flex-direction: column;
}

.history-sidebar h3 {
  font-size: 0.85rem;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 1.5px;
  margin-bottom: 1.5rem;
}

.history-list {
  flex-grow: 1;
  overflow-y: auto;
  padding-right: 0.5rem;
}

.history-item {
  padding: 1rem;
  background: var(--bg-input);
  border-radius: 12px;
  margin-bottom: 0.75rem;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.2s;
}

.history-item:hover,
.history-item:focus-visible {
  border-left-color: var(--accent-blue);
  background: rgba(59, 130, 246, 0.05);
  outline: none;
  transform: translateX(4px);
}

.history-item-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.history-item .analysis-text {
    font-size: 1.05rem;
    line-height: 1.7;
    color: #cbd5e1;
}

/* Conviction Framework Styles */
.conviction-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 99px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
}

.sentiment-bullish {
}

.sentiment-bearish {
}

.badge-bullish {
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
    border-color: rgba(16, 185, 129, 0.4);
}

.badge-bearish {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
    border-color: rgba(239, 68, 68, 0.4);
}

.bottom-line-summary {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--accent-blue);
    font-style: italic;
}

.history-item .ticker {
    font-weight: 800;
    color: var(--text-main);
    display: block;
}

.free-badge-pill {
    font-size: 0.6rem;
    font-weight: 800;
    color: var(--green-bull);
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.2);
    padding: 1px 4px;
    border-radius: 4px;
    text-transform: uppercase;
}

.history-item .date {
  font-size: 0.7rem;
  color: var(--text-muted);
}

.history-empty {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9rem;
  padding-top: 2rem;
}

/* Activity Feed (Loading State) */
.loading-wrapper {
  display: flex;
  gap: 2.5rem;
  background: var(--bg-card);
  padding: 2.5rem;
  border-radius: 20px;
  border: 1px solid var(--border-light);
}

.spinner-container {
  display: flex;
  justify-content: center;
  align-items: center;
}

.loading-content {
  flex-grow: 1;
}

#dynamic-status-text {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--text-main);
}

.activity-feed {
  height: 120px;
  overflow-y: hidden;
  display: flex;
  flex-direction: column-reverse;
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.activity-line {
  margin-bottom: 0.4rem;
  animation: fadeIn 0.3s ease-out;
}

.activity-line::before {
  content: ">";
  color: var(--accent-blue);
  margin-right: 0.75rem;
}

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

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

header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border-light);
  margin-bottom: 3rem;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.user-info {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
}

#user-email {
  color: var(--text-muted);
  font-size: 0.9rem;
}

#logout-btn {
  background: none;
  border: 1px solid var(--border-light);
  color: var(--text-main);
  padding: 0.3rem 0.8rem;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.8rem;
  transition: all 0.2s ease;
}

#logout-btn:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.3);
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.logo-icon {
  width: 32px;
  height: 32px;
  background-image: url('assets/logo-header.svg');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  transform: translateY(1px); /* Precision visual baseline alignment */
}

.logo h1 {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  -webkit-font-smoothing: antialiased; /* Sharpening the 'Ghost Glitch' */
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  color: #f1f5f9;
}

.logo span {
  color: #4facfe; /* Slightly desaturated version of accent-blue to reduce chromatic aura */
}

/* Grade Sentiment Indicators */
.sentiment-bullish { color: var(--green-bull) !important; }
.sentiment-bearish { color: var(--red-bear) !important; }
.sentiment-neutral { color: var(--text-muted) !important; }

#credit-badge {
  background-color: var(--bg-card);
  padding: 0.5rem 1rem;
  border-radius: 20px;
  border: 1px solid var(--border-light);
  font-size: 0.9rem;
  color: var(--text-muted);
}

#credits-count {
  color: var(--text-main);
}

.search-section {
  text-align: center;
  margin-bottom: 4rem;
}

.search-section h2 {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
  background: linear-gradient(to right, #fff, #94a3b8);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.search-section p {
  color: var(--text-muted);
  margin-bottom: 2.5rem;
}

.search-box {
  display: flex;
  gap: 1rem;
  max-width: 600px;
  margin: 0 auto;
}

#ticker-input {
  flex: 1;
  background-color: var(--bg-input);
  border: 1px solid var(--border-light);
  border-radius: 8px;
  padding: 1rem 1.5rem;
  color: var(--text-main);
  font-size: 1.1rem;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

#ticker-input:focus {
  border-color: var(--accent-blue);
  box-shadow: var(--shadow-glow);
}

#submit-btn {
  background-color: var(--accent-blue);
  color: white;
  border: none;
  border-radius: 8px;
  padding: 0 2rem;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s, transform 0.1s;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 160px;
}

#submit-btn:hover {
  background-color: var(--accent-blue-hover);
}

#submit-btn:active {
  transform: scale(0.98);
}

/* Loading States */
.state-container {
  animation: fadeIn 0.4s ease-out forwards;
}

.agent-loaders {
  display: flex;
  justify-content: space-around;
  margin-bottom: 3rem;
}

.agent-loader, .synthesizer-loader {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.spinner {
  width: 24px;
  height: 24px;
  border: 3px solid var(--border-light);
  border-top-color: var(--accent-blue);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

.spinner.glow {
  border-top-color: var(--red-bear);
  box-shadow: 0 0 15px var(--red-bear-bg);
}

/* Results Display */
/* Results Display Refinement */
.result-header {
  margin-bottom: 3.5rem;
}

.ticker-title {
  font-size: 3.5rem;
  font-weight: 900;
  letter-spacing: -2px;
  background: linear-gradient(to right, #fff, #94a3b8);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 0.5rem;
  overflow-wrap: break-word;
  word-break: break-word;
}

.price-at-generation {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 1rem;
  margin-left: 0.2rem;
}

.price-at-generation .price-label {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  color: #64748b;
  text-transform: uppercase;
}

.price-at-generation .price-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: #e2e8f0;
  font-family: 'JetBrains Mono', 'SF Mono', monospace;
  letter-spacing: -0.5px;
}

.grades-row {
  display: flex;
  gap: 2.5rem;
  margin-left: 0.2rem;
}

.grade-item {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--text-muted);
  font-weight: 700;
}

.grade-item span {
  color: #fff;
  margin-left: 0.75rem;
  font-weight: 900;
  font-size: 0.85rem;
}

.metrics-bar {
  display: flex;
  justify-content: space-between;
  background: rgba(31, 34, 41, 0.5);
  padding: 2.5rem;
  border-radius: 20px;
  border: 1px solid var(--border-light);
  margin-bottom: 3rem;
  backdrop-filter: blur(10px);
}

.metric-item {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  align-items: flex-start;
  min-width: 0;
  word-break: break-word;
}

.metric-item span {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 2px;
}

.metric-item strong {
  font-size: 1.6rem;
  color: var(--text-main);
  font-weight: 900;
  letter-spacing: -0.5px;
}

/* Vertical Analysis Stack */
.analysis-stack {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  margin-top: 3rem;
}

.analysis-card {
  background-color: var(--bg-card);
  padding: 2.5rem;
  border-radius: 20px;
  border: 1px solid var(--border-light);
  line-height: 1.8;
  position: relative;
}

.analysis-card h3 {
  margin-bottom: 1.5rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--text-muted);
}

.thesis-card {
  border-left: 4px solid var(--accent-blue);
}

.bear-card {
  border-left: 4px solid var(--red-bear);
  background: linear-gradient(to right, rgba(239, 68, 68, 0.03), transparent);
}

.analysis-text {
  font-size: 1.05rem;
  color: var(--text-main);
}

.bottom-line-wrapper {
  margin-top: 2.5rem;
}

.summary-divider {
  border: none;
  border-top: 1px solid var(--border-light);
  margin-bottom: 2.5rem;
  opacity: 0.6;
}

.bottom-line-label {
  display: block;
  color: var(--red-bear);
  font-weight: 900;
  margin-bottom: 0.75rem;
  font-size: 1.25rem;
  letter-spacing: -0.5px;
}

.catalyst-list {
  list-style: none;
}

.catalyst-list li {
  position: relative;
  padding-left: 2rem;
  margin-bottom: 1.2rem;
  color: var(--text-main);
  font-size: 1.05rem;
}

.catalyst-list li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--accent-blue);
  font-weight: 900;
}

.disclaimer-footer {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-light);
  color: #64748b;
  font-size: 0.8rem;
  line-height: 1.5;
  text-align: center;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* Public pSEO Page Styles */
.public-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
}

.public-badge {
  background-color: var(--accent-blue-hover);
  color: white;
  padding: 0.3rem 0.8rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
}

.public-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: 3rem;
}

.stat-box {
  background-color: var(--bg-card);
  padding: 1.5rem;
  border-radius: 12px;
  border: 1px solid var(--border-light);
  text-align: center;
}

.stat-box label {
  display: block;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.stat-box strong {
  font-size: 1.5rem;
  color: var(--text-main);
}

.public-description {
  margin-bottom: 4rem;
  line-height: 1.7;
}

.public-description h3 {
  margin-bottom: 1rem;
  color: var(--text-muted);
  font-size: 1.1rem;
}

.conversion-hook {
  position: relative;
  background-color: #12141a;
  border: 1px dashed var(--border-light);
  border-radius: 16px;
  padding: 3rem;
  text-align: center;
  overflow: hidden;
}

.hook-content {
  position: relative;
  z-index: 2;
}

.hook-content h3 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
  color: var(--text-main);
}

.hook-content p {
  color: var(--text-muted);
  margin-bottom: 2rem;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

.btn-primary {
  background-color: var(--accent-blue);
  color: white;
  border: none;
  border-radius: 8px;
  padding: 1rem 2rem;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(59, 130, 246, 0.4);
}

.blurred-preview {
  position: absolute;
  bottom: -20px;
  left: 0;
  right: 0;
  padding: 2rem;
  filter: blur(8px);
  opacity: 0.3;
  pointer-events: none;
}

.blurred-line {
  height: 12px;
  background-color: var(--text-muted);
  margin-bottom: 10px;
  border-radius: 4px;
}

/* Terminal UI */
.terminal-window {
  background-color: #000;
  border-radius: 8px;
  border: 1px solid #333;
  overflow: hidden;
  font-family: 'Courier New', Courier, monospace;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  margin-bottom: 2rem;
}

.terminal-header {
  background-color: #1a1b20;
  padding: 0.5rem 1rem;
  display: flex;
  align-items: center;
  border-bottom: 1px solid #333;
}

.terminal-dots {
  display: flex;
  gap: 6px;
  margin-right: 15px;
}

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

.dot.red { background-color: #ff5f56; }
.dot.yellow { background-color: #ffbd2e; }
.dot.green { background-color: #27c93f; }

.terminal-title {
  color: #888;
  font-size: 0.8rem;
  letter-spacing: 1px;
}

.terminal-body {
  padding: 1.5rem;
  min-height: 180px;
  max-height: 300px;
  overflow-y: auto;
  color: #4ade80;
  font-size: 0.95rem;
  line-height: 1.6;
}

.terminal-msg {
  margin-bottom: 8px;
  opacity: 0;
  animation: fadeIn 0.3s forwards;
}

.terminal-msg::before {
  content: "> ";
  color: #888;
}

.terminal-loader {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 1rem 1.5rem;
  background-color: #0a0a0c;
  border-top: 1px solid #222;
  color: #fff;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
}


/* Tooltips */
.label-with-tooltip {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.tooltip-icon {
  font-size: 0.65rem;
  color: var(--text-muted);
  cursor: help;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
  border: 1px solid var(--border-light);
  border-radius: 50%;
}

.tooltip-text {
  visibility: hidden;
  width: 220px;
  background-color: #1a1c23;
  color: #fff;
  text-align: left;
  border-radius: 8px;
  padding: 0.8rem;
  position: absolute;
  z-index: 100;
  bottom: 125%;
  left: 50%;
  transform: translateX(-50%);
  opacity: 0;
  transition: opacity 0.3s;
  font-size: 0.75rem;
  text-transform: none;
  font-weight: 400;
  border: 1px solid var(--border-light);
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  line-height: 1.4;
  pointer-events: none;
}

.tooltip-icon:hover .tooltip-text {
  visibility: visible;
  opacity: 1;
}

/* Action Buttons */
.report-actions {
  display: flex;
  justify-content: center;
  margin-top: 3rem;
  padding-bottom: 2rem;
}

.secondary-btn {
  background: transparent;
  border: 1px solid var(--border-light);
  color: var(--text-muted);
  padding: 0.8rem 1.8rem;
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.secondary-btn:hover {
  background: var(--bg-input);
  color: #fff;
  border-color: var(--accent-blue);
  transform: translateY(-2px);
}

/* Mobile Responsiveness Improvements */
@media (max-width: 900px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .history-sidebar {
    height: auto;
    position: relative;
    top: 0;
    order: 2; /* Move history below main search on mobile */
  }

  .main-content {
    order: 1;
  }

  .metrics-bar {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    padding: 1.5rem;
  }
  
  .ticker-title {
    font-size: 2.5rem;
  }

  .grades-row {
    flex-direction: column;
    gap: 0.5rem;
  }
}

@media (max-width: 480px) {
  .metrics-bar {
    display: grid !important; 
    grid-template-columns: 1fr 1fr !important;
    gap: 1rem !important;
    padding: 1rem !important;
  }

  .app-container {
    padding: 1rem;
  }
}

/* Base Modal Overlay — All modals */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(15, 17, 21, 0.85);
  backdrop-filter: blur(8px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.2s ease-out forwards;
  padding: 1rem;
}

/* Upgrade Modal — Proper Structure */
.upgrade-modal-card {

  max-width: 860px !important;
  padding: 0 !important;
  display: flex;
  flex-direction: column;
  max-height: 90vh; /* Never exceed viewport height */
  overflow: hidden; /* Clip, let inner body scroll */
}

.upgrade-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 2rem;
  border-bottom: 1px solid var(--border-light);
  flex-shrink: 0; /* NEVER shrink — always visible */
  background: var(--bg-card);
  border-radius: 16px 16px 0 0;
}

.upgrade-modal-header h2 {
  font-size: 1.3rem;
  font-weight: 700;
  margin: 0;
}

.upgrade-close-btn {
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  color: var(--text-main);
  padding: 0.6rem 1.2rem !important;
  font-size: 0.9rem !important;
  font-weight: 700;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
  flex-shrink: 0;
}

.upgrade-close-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--text-muted);
}

.upgrade-modal-body {
  overflow-y: auto; /* THIS is where scrolling happens */
  padding: 1.5rem 2rem 2.5rem;
  -webkit-overflow-scrolling: touch; /* Smooth scroll on iOS */
}


/* Pricing Grid */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.pricing-card {
  border: 1px solid var(--border-light);
  border-radius: 12px;
  padding: 2rem;
  background: var(--bg-dark);
  text-align: center;
  display: flex;
  flex-direction: column;
}

.pricing-card-featured {
  border: 2px solid var(--accent-blue);
  background: rgba(59, 130, 246, 0.05);
  position: relative;
  box-shadow: var(--shadow-glow);
}

.pricing-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent-blue);
  color: white;
  padding: 0.4rem 1.2rem;
  border-radius: 99px;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08rem;
  text-transform: uppercase;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.pricing-tier-name {
  margin-bottom: 1.5rem;
  color: var(--text-main);
  font-size: 1.3rem;
  font-weight: 700;
}

.pricing-price-container {
  margin-bottom: 0.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
}

.pricing-strikethrough {
  text-decoration: line-through;
  color: var(--text-muted);
  font-size: 1rem;
  opacity: 0.5;
  font-weight: 600;
}

.pricing-price {
  font-size: 2.8rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1;
}

.pricing-currency {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 500;
  margin-left: 4px;
}

.pricing-period {
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 1.5rem;
}

.pricing-note {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-style: italic;
  margin-bottom: 1.5rem;
  line-height: 1.4;
  opacity: 0.7;
}

.pricing-features {
  list-style: none;
  padding: 0;
  margin-bottom: 2rem;
  text-align: left;
  font-size: 0.9rem;
  color: var(--text-main);
  flex-grow: 1;
}

.pricing-features li {
  margin-bottom: 0.8rem;
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  line-height: 1.4;
}

.pricing-features li::before {
  content: "✓";
  color: var(--accent-blue);
  font-weight: 800;
  flex-shrink: 0;
}

.pricing-card .btn-primary {
  width: 100%;
  padding: 0.8rem !important;
  font-weight: 700 !important;
}

/* Mobile: Stack pricing cards vertically */
@media (max-width: 800px) {
  .pricing-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

.modal-card {
  background: var(--bg-card);
  border: 1px solid rgba(59, 130, 246, 0.2);
  border-radius: 16px;
  padding: 2.5rem;
  max-width: 480px;
  width: 100%;
  text-align: center;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), var(--shadow-glow);
  animation: fadeIn 0.3s ease-out forwards;
  /* Ensure it doesn't get clipped — flex-shrink: 0 keeps it from collapsing */
  flex-shrink: 0;
}

.modal-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.modal-card h2 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.modal-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.5;
  margin-bottom: 2rem;
}

.modal-actions {
  display: flex;
  justify-content: center;
  gap: 1rem;
}

.btn-secondary {
  background: transparent;
  border: 1px solid var(--border-light);
  color: var(--text-main);
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.2s ease;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.2);
}


/* Cache Upsell Banner */
.cache-banner {
  background: rgba(59, 130, 246, 0.06);
  border: 1px solid rgba(59, 130, 246, 0.15);
  border-radius: 10px;
  padding: 1rem 1.5rem;
  margin-bottom: 1.5rem;
  animation: fadeIn 0.3s ease-out;
}

.cache-banner-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

#cache-banner-text {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.btn-force-refresh {
  background: transparent;
  border: 1px solid var(--accent-blue);
  color: var(--accent-blue);
  padding: 0.5rem 1rem;
  border-radius: 8px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-force-refresh:hover {
  background: rgba(59, 130, 246, 0.1);
  box-shadow: 0 0 12px rgba(59, 130, 246, 0.2);
}

.cache-volatility {
  margin-top: 0.6rem;
  font-size: 0.8rem;
  color: var(--red-bear);
  padding-top: 0.6rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* Onboarding Chips */
.onboarding-section {
  text-align: center;
  margin-top: -2rem;
  margin-bottom: 3rem;
  animation: fadeIn 0.5s ease-out forwards;
}

.onboarding-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.chip-row {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.ticker-chip {
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  color: var(--text-main);
  padding: 0.6rem 1.5rem;
  border-radius: 20px;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.ticker-chip:hover {
  border-color: var(--accent-blue);
  background: rgba(59, 130, 246, 0.08);
  box-shadow: 0 0 15px rgba(59, 130, 246, 0.2);
  transform: translateY(-2px);
}

.onboarding-steps {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.step-arrow {
  color: var(--accent-blue);
  font-weight: 700;
}

/* Blurred Report Preview (pSEO) */
.report-preview-mock {
  margin-top: 2rem;
  filter: blur(10px);
  opacity: 0.25;
  user-select: none;
  pointer-events: none;
  text-align: left;
  padding: 0 2rem;
}

.preview-grades {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.preview-grade-badge {
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  padding: 0.4rem 1rem;
  border-radius: 8px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-main);
}

.preview-section-title {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
  border-left: 3px solid var(--red-bear);
  padding-left: 0.75rem;
}

.preview-text-line {
  height: 14px;
  background: var(--text-muted);
  border-radius: 4px;
  margin-bottom: 8px;
}
/* Sentiment Gauges */
.sentiment-row {
  display: flex;
  gap: 2rem;
  margin: 1.5rem 0;
}


/* Search & Autocomplete Refinement */
#ticker-input {
  position: relative;
  z-index: 10;
}

.search-box {
  position: relative;
}

.autocomplete-results {
  position: absolute;
  top: 110%;
  left: 0;
  right: 0;
  background: rgba(15, 17, 21, 0.75);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.7), 
              0 0 15px rgba(59, 130, 246, 0.1); /* Subtle blue glow */
  z-index: 1000;
  max-height: 400px;
  overflow-y: auto;
  display: none;
}

.autocomplete-item {
  padding: 0.75rem 1.25rem;
  cursor: pointer;
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 12px;
  transition: background 0.2s;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

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

.autocomplete-item:hover,
.autocomplete-item.highlighted {
  background: rgba(59, 130, 246, 0.15);
  outline: none;
}

/* Global Focus Indicators */
:focus-visible {
  outline: 2px solid var(--accent-blue);
  outline-offset: 2px;
  box-shadow: 0 0 10px rgba(59, 130, 246, 0.3);
}

.autocomplete-fallback {
  border-top: 1px dashed var(--border-light);
  background: rgba(255, 255, 255, 0.02);
}

.autocomplete-fallback span {
  font-style: italic;
  color: var(--accent-blue) !important;
}

.autocomplete-item strong {
  color: var(--text-bright);
  font-family: 'Courier New', Courier, monospace;
  width: 60px;
  display: inline-block;
  flex-shrink: 0;
}

.autocomplete-item span {
  color: var(--text-muted);
  font-size: 0.85rem;
}

/* --- TERMINAL MOBILE RESPONSIVENESS (max-width: 600px) --- */
@media (max-width: 600px) {
  /* 1. Header Collapse */
  header {
    flex-direction: column !important;
    gap: 1.5rem !important;
    padding: 1rem !important;
    text-align: center !important;
    align-items: center !important;
  }
  .user-info {
    width: 100% !important;
    flex-wrap: wrap !important;
    justify-content: center !important;
  }
  .logo {
    justify-content: center !important;
  }
  
  /* 2. Search Box Stacking */
  .search-box {
    flex-direction: column !important;
    gap: 0.8rem !important;
    width: 100% !important;
  }
  #ticker-input {
    width: 100% !important;
  }
  #submit-btn {
    width: 100% !important;
    padding: 1.2rem !important;
  }

  /* 3. Status Bar & Layout Consolidation */
  .app-container {
    padding: 1rem !important;
  }
  .dashboard-grid {
    grid-template-columns: 1fr !important;
    gap: 2rem !important;
    display: flex !important;
    flex-direction: column !important;
  }
  .history-sidebar {
    position: static !important;
    height: auto !important;
    order: 2 !important; /* Move history explicitly to bottom */
    width: 100% !important;
  }
  .main-content {
    order: 1 !important;
    width: 100% !important;
  }
  
  /* 4. Onboarding & Cache banners */
  .chip-row {
    flex-wrap: wrap !important;
    justify-content: center !important;
  }
  .cache-banner-content {
    flex-direction: column !important;
    text-align: center !important;
    gap: 1rem !important;
  }
  .result-header {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 1rem !important;
  }
}

/* --- PRICING MODAL MOBILE (max-width: 600px) --- */
@media (max-width: 600px) {
  /* Restructured modal ensures sticky header and inner scroll, so we no longer need these hacks */
  #upgrade-modal .modal-card {
    width: 95% !important;
    height: auto !important;
  }
}


/* --- AUTH / LOGIN PAGE MOBILE --- */
@media (max-width: 480px) {
  .auth-container {
    padding: 1rem !important;
  }

  .auth-card {
    padding: 1.5rem 1.25rem !important;
    border-radius: 12px !important;
  }

  .auth-header h1 {
    font-size: 1.5rem !important;
  }

  .btn-oauth {
    font-size: 0.9rem !important;
    padding: 0.65rem !important;
  }
}

/* --- TOS PAGE MOBILE --- */
@media (max-width: 600px) {
  .tos-container {
    margin: 1rem auto !important;
    padding: 1.5rem 1.25rem !important;
    border-radius: 8px !important;
  }

  .tos-container h1 {
    font-size: 1.5rem !important;
  }

  .tos-container h2 {
    font-size: 1rem !important;
  }
}

/* --- LANDING PAGE HERO MOBILE REFINEMENTS --- */
@media (max-width: 480px) {
  .feature-grid {
    grid-template-columns: 1fr !important;
    gap: 1.5rem !important;
  }

  .feature-card {
    padding: 1.5rem !important;
  }

  .feature-title {
    font-size: 1.3rem !important;
  }

  .section-title {
    font-size: 2rem !important;
  }

  .features-section {
    padding: 2rem 1.25rem 4rem !important;
  }
}

/* --- TOAST NOTIFICATION SYSTEM --- */
.toast-container {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    pointer-events: none;
}

.toast {
    pointer-events: auto;
    min-width: 300px;
    max-width: 450px;
    padding: 1rem 1.25rem;
    background: rgba(22, 24, 29, 0.85); /* Glassmorphism Base */
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), var(--shadow-glow);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-main);
    font-size: 0.9rem;
    line-height: 1.4;
    animation: toast-slide-in 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.15) forwards;
    transition: all 0.3s ease;
}

.toast.toast-exit {
    opacity: 0;
    transform: translateX(100px);
}

.toast-icon {
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Toast States */
.toast-error {
    border-left: 4px solid var(--red-bear);
    box-shadow: 0 8px 32px rgba(239, 68, 68, 0.15);
}
.toast-error .toast-icon { color: var(--red-bear); }

.toast-success {
    border-left: 4px solid var(--green-bull);
    box-shadow: 0 8px 32px rgba(16, 185, 129, 0.15);
}
.toast-success .toast-icon { color: var(--green-bull); }

.toast-info {
    border-left: 4px solid var(--accent-blue);
}
.toast-info .toast-icon { color: var(--accent-blue); }

@keyframes toast-slide-in {
    from {
        opacity: 0;
        transform: translateX(50px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}

@media (max-width: 600px) {
    .toast-container {
        bottom: 1rem;
        right: 1rem;
        left: 1rem;
    }
    .toast {
        min-width: 0;
        width: 100%;
    }
}

/* Institutional Execution Log Feed */
.activity-feed {
    margin-top: 1.5rem;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 0.85rem;
    color: var(--text-muted);
    background: rgba(15, 17, 21, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    padding: 1rem;
    height: 160px;
    overflow-y: hidden;
    position: relative;
    text-align: left;
}

.activity-feed::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 40px;
    background: linear-gradient(to top, rgba(15, 17, 21, 0.9), transparent);
    pointer-events: none;
}

.activity-line {
    margin-bottom: 0.5rem;
    animation: typing-fade-in 0.3s ease forwards;
}

.sys-prefix {
    color: var(--accent-blue);
    font-weight: 600;
    margin-right: 0.5rem;
}

@keyframes typing-fade-in {
    from { opacity: 0; transform: translateX(-10px); }
    to { opacity: 1; transform: translateX(0); }
}

/* Invalidation Tripwire Box */
.tripwire-box {
    margin-top: 2rem;
    padding: 1.5rem;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.05), transparent);
    border-left: 4px solid var(--red-bear);
    border-radius: 0 12px 12px 0;
}

.tripwire-label {
    display: block;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--red-bear);
    margin-bottom: 0.75rem;
    font-weight: 800;
}

.tripwire-text {
    font-size: 1.1rem;
    color: var(--text-main);
    line-height: 1.6;
}

/* Stress-Test Matrix */
.stress-matrix-container {
    margin-top: 3rem;
    width: 100%;
    overflow-x: auto;
}

.stress-matrix-table {
    width: 100%;
    border-collapse: collapse;
    background: rgba(31, 34, 41, 0.4);
    border-radius: 12px;
    overflow: hidden;
}

.stress-matrix-table th {
    background: rgba(255, 255, 255, 0.03);
    padding: 1rem;
    text-align: left;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.stress-matrix-table td {
    padding: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    vertical-align: top;
}

.stress-matrix-table tr:last-child td {
    border-bottom: none;
}

.scenario-name {
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
}

.scenario-target {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    font-weight: 800;
    color: var(--accent-blue);
    white-space: nowrap;
}

.scenario-rationale {
    font-size: 0.9rem;
    color: #94a3b8;
    line-height: 1.5;
}

/* Reverse-DCF Reality Gauge (For Implied Growth vs Sector) */
.reality-gauge-container {
    margin-top: 1rem;
    background: rgba(15, 17, 21, 0.5);
    padding: 1.25rem 1rem 1rem;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.05);
}

.gauge-title {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-muted);
    margin-bottom: 1.75rem;
    font-weight: 600;
}

.gauge-track-wrapper {
    position: relative;
    padding-bottom: 1.75rem; /* room for bottom labels */
}

.gauge-track {
    width: 100%;
    height: 6px;
    background: #334155;
    border-radius: 3px;
    position: relative;
}

.gauge-marker {
    position: absolute;
    top: -4px;
    width: 4px;
    height: 14px;
    background: #fff;
    border-radius: 2px;
    z-index: 2;
    transform: translateX(-50%);
}

.gauge-marker-sector {
    background: #94a3b8;
    height: 10px;
    top: -2px;
    z-index: 1;
}

.gauge-fill {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    border-radius: 3px;
    background: linear-gradient(to right, var(--accent-blue), var(--red-bear));
}

/* Floating labels that follow their marker's position */
.gauge-floating-label {
    position: absolute;
    top: 18px; /* below the track */
    font-size: 0.7rem;
    transform: translateX(-50%);
    white-space: nowrap;
    line-height: 1;
}

.gauge-label-implied {
    color: #fff;
    font-weight: 700;
}

.gauge-label-sector {
    color: #94a3b8;
    font-weight: 600;
}

.gauge-micro-copy {
    margin-top: 0.75rem;
    font-size: 0.8rem;
    color: #94a3b8;
    line-height: 1.5;
    font-style: italic;
}

/* -----------------------------------------------------------
   Mobile-First UX Adjustments (Max-width 768px)
   ----------------------------------------------------------- */
@media (max-width: 768px) {
    /* 1. Matrix: Card Stacking */
    .stress-matrix-table,
    .stress-matrix-table thead,
    .stress-matrix-table tbody,
    .stress-matrix-table th,
    .stress-matrix-table td,
    .stress-matrix-table tr {
        display: block;
    }
    
    /* Hide the horizontal table header visually */
    .stress-matrix-table thead tr {
        display: none;
    }
    
    /* Treat each row as a vertical card */
    .stress-matrix-table tr {
        background: rgba(255, 255, 255, 0.02);
        margin-bottom: 1rem;
        border-radius: 8px;
        padding: 1rem;
        border: 1px solid rgba(255, 255, 255, 0.05);
    }
    
    /* Reset TD padding since TR holds it */
    .stress-matrix-table td {
        padding: 0;
        border: none;
        margin-bottom: 0.5rem;
    }
    
    .stress-matrix-table td:last-child {
        margin-bottom: 0;
    }

    /* Emphasize the Scenario Name inside the card */
    .scenario-name {
        font-size: 1.1rem;
        display: block;
        margin-bottom: 0.25rem;
        white-space: normal; /* Override desktop nowrap */
    }
    
    /* Emphasize the Target Price */
    .scenario-target {
        font-size: 1rem;
        display: block;
        margin-bottom: 0.75rem;
        white-space: normal; /* Override desktop nowrap */
    }

    /* 2. Growth Gauge: Axis Offsetting */
    .gauge-track {
        height: 8px;
    }
    
    .gauge-marker {
        height: 16px;
    }
    
    .gauge-marker-sector {
        height: 12px;
    }
    
    .gauge-label-implied {
        top: auto !important;
        bottom: 16px !important;
    }
    
    .tripwire-box {
        padding: 1.25rem 1.5rem 1.25rem 1.75rem;
    }
    
    .tripwire-text {
        font-size: max(1.1rem, 16px);
    }
}

/* -----------------------------------------------------------
   Demo Mode Utilities
   ----------------------------------------------------------- */

body.demo-mode-active .app-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    padding: 2rem 1rem;
}

body.demo-mode-active .dashboard-grid {
    display: block;
    width: 100%;
}

body.demo-mode-active .history-sidebar {
    display: none !important;
}

body.demo-mode-active .main-content {
    margin: 0 auto !important;
    width: 100%;
    max-width: 900px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

#submit-btn {
    min-height: 52px;
}

.demo-blur {
    filter: blur(8px);
    user-select: none;
    pointer-events: none;
    opacity: 0.5;
    transition: filter 0.5s ease-in, opacity 0.5s ease-in;
}

.inline-paywall {
    position: absolute;
    bottom: 25%;
    left: 50%;
    transform: translate(-50%, 50%);
    background: rgba(15, 17, 21, 0.95);
    border: 1px solid var(--accent-blue);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    width: 90%;
    max-width: 500px;
    z-index: 10;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8), 0 0 20px rgba(59, 130, 246, 0.2);
    backdrop-filter: blur(4px);
}

.inline-paywall h3 {
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
    color: var(--text-main);
}

.inline-paywall p {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
    line-height: 1.5;
}
.summary-box {
    background: rgba(255, 255, 255, 0.05);
    border-left: 3px solid var(--accent-gray);
    padding: 1.25rem;
    margin-top: 1rem;
    margin-bottom: 1.5rem;
    border-radius: 4px;
}

/* Accessibility Improvements */
.retail-card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-light);
    border-left: 4px solid rgba(59, 130, 246, 0.4); /* Muted institutional blue */
    box-shadow: none;
}

.retail-card p {
    font-weight: 500; /* Institutional 'font-medium' feel */
}

.retail-icon {
    filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.5));
}

.jargon-term {
    border-bottom: 1px dotted var(--accent-blue);
    cursor: help;
    position: relative;
    display: inline-block;
    color: inherit;
    transition: color 0.2s;
}

.jargon-term:hover {
    color: var(--accent-blue);
}

/* Sleek Tooltip styling */
.jargon-term .tooltip-box {
    display: block;
    visibility: hidden;
    width: 260px;
    background-color: #1a1b20;
    color: #f1f5f9;
    text-align: left;
    border: 1px solid rgba(59, 130, 246, 0.5);
    border-radius: 10px;
    padding: 14px;
    position: absolute;
    z-index: 1000;
    bottom: 140%;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    opacity: 0;
    transition: opacity 0.2s ease-out, transform 0.2s ease-out, visibility 0.2s;
    font-size: 0.85rem;
    line-height: 1.5;
    font-weight: 400;
    box-shadow: 0 15px 35px rgba(0,0,0,0.6), 0 0 15px rgba(59, 130, 246, 0.1);
    pointer-events: none;
    backdrop-filter: blur(8px);
}

.jargon-term:hover .tooltip-box,
.jargon-term.active-tooltip .tooltip-box {
    visibility: visible;
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* Tooltip Arrow */
.jargon-term .tooltip-box::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -6px;
    border-width: 6px;
    border-style: solid;
    border-color: rgba(59, 130, 246, 0.5) transparent transparent transparent;
}

@media (max-width: 600px) {
    .jargon-term .tooltip-box {
        position: fixed;
        bottom: 2rem;
        top: auto;
        left: 50%;
        width: 90vw;
        max-width: 350px;
        z-index: 10000;
        transform: translateX(-50%) translateY(20px);
    }
    
    .jargon-term:hover .tooltip-box,
    .jargon-term.active-tooltip .tooltip-box {
        transform: translateX(-50%) translateY(0);
    }

    .jargon-term .tooltip-box::after {
        display: none;
    }
}

/* Responsive Markdown Tables */
.analysis-text table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border: 1px solid var(--border-light);
    border-radius: 8px;
    background: rgba(0,0,0,0.2);
}

.analysis-text th, .analysis-text td {
    padding: 0.75rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    text-align: left;
    white-space: nowrap;
}

.analysis-text th {
    background: rgba(255, 255, 255, 0.05);
    font-weight: 600;
    color: var(--text-muted);
}
