/* Keytruda Intelligence Platform - Modern Dark Theme & Visual Polish */

:root {
  --font-scale: 1rem;
  --bg-dark-base: #080d1a;
  --bg-dark-card: #0f172a;
  --bg-dark-card-hover: #17233f;
  --border-dark: #1e293b;
  --accent-cyan: #38bdf8;
  --accent-emerald: #10b981;
  --accent-purple: #a855f7;
}

body {
  font-size: var(--font-scale);
  transition: background-color 0.25s ease, color 0.25s ease;
}

/* Default / Dark Theme Styles */
html.dark, body.dark {
  background-color: #080d1a !important;
  color: #f1f5f9 !important;
}

body.dark header {
  background-color: rgba(15, 23, 42, 0.95) !important;
  border-color: #1e293b !important;
  backdrop-filter: blur(12px);
}

body.dark .bg-white {
  background-color: #0f172a !important;
  color: #f1f5f9 !important;
}

body.dark .bg-slate-50 {
  background-color: #131d33 !important;
  color: #e2e8f0 !important;
}

body.dark .bg-slate-100 {
  background-color: #1e293b !important;
  color: #f1f5f9 !important;
}

body.dark .bg-slate-200 {
  background-color: #27364f !important;
  color: #f8fafc !important;
}

body.dark .text-slate-900,
body.dark .text-slate-800 {
  color: #f8fafc !important;
}

body.dark .text-slate-700,
body.dark .text-slate-600 {
  color: #cbd5e1 !important;
}

body.dark .text-slate-500,
body.dark .text-slate-400 {
  color: #94a3b8 !important;
}

body.dark .border-slate-200,
body.dark .border-slate-100 {
  border-color: #1e293b !important;
}

body.dark input,
body.dark select,
body.dark textarea {
  background-color: #131d33 !important;
  color: #f8fafc !important;
  border-color: #2a3a58 !important;
}

body.dark input::placeholder,
body.dark textarea::placeholder {
  color: #64748b !important;
}

body.dark input:focus,
body.dark select:focus {
  border-color: #38bdf8 !important;
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.2) !important;
}

body.dark footer {
  background-color: #0b1120 !important;
  border-color: #1e293b !important;
}

/* Nav Tabs & Active Indicator */
.nav-tab {
  color: #94a3b8;
  position: relative;
  font-weight: 600;
  border-radius: 0.65rem;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-tab:hover {
  color: #38bdf8;
  background-color: rgba(56, 189, 248, 0.1);
}

.nav-tab.active-tab {
  color: #38bdf8 !important;
  background-color: rgba(14, 165, 233, 0.18) !important;
  border: 1px solid rgba(56, 189, 248, 0.35);
  box-shadow: 0 0 15px rgba(56, 189, 248, 0.15);
}

.tab-pane {
  display: none;
  animation: fadeIn 0.25s ease-in-out;
}

.tab-pane.active {
  display: block;
}

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

/* 3D Molecular Viewer & MOA Video Styles */
.molecule-glow {
  box-shadow: 0 0 35px rgba(168, 85, 247, 0.2);
}

.moa-glow {
  box-shadow: 0 0 35px rgba(14, 165, 233, 0.25);
}

.canvas-container {
  position: relative;
  border-radius: 1rem;
  overflow: hidden;
  background: radial-gradient(circle at center, #111a2f 0%, #060a14 100%);
}

/* MOA Stepper Cards */
.moa-step-active {
  border-color: #38bdf8 !important;
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.15) 0%, rgba(15, 23, 42, 0.9) 100%) !important;
  box-shadow: 0 0 20px rgba(56, 189, 248, 0.2);
}

/* Pulse badge */
.pulse-badge {
  position: relative;
}
.pulse-badge::after {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: inherit;
  background: inherit;
  opacity: 0.4;
  animation: pulseGlow 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
  z-index: -1;
}

@keyframes pulseGlow {
  0%, 100% { transform: scale(1); opacity: 0.4; }
  50% { transform: scale(1.15); opacity: 0; }
}

/* Custom Scrollbars */
.no-scrollbar::-webkit-scrollbar {
  display: none;
}
.no-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: #334155;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #475569;
}

/* Modal styling */
.modal-backdrop {
  background-color: rgba(4, 7, 16, 0.85);
  backdrop-filter: blur(8px);
}

/* Chat Drawer Transitions */
#chatDrawer {
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ==============================================================
   RxAudit Lens-Style Floating Dock & Scrollytelling Styles
============================================================== */

/* Floating Bottom Dock Container */
.floating-dock {
  background: rgba(11, 17, 32, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(51, 65, 85, 0.7);
  box-shadow: 0 20px 50px -10px rgba(0, 0, 0, 0.8), 0 0 20px rgba(6, 182, 212, 0.15);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.dock-item {
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  color: #94a3b8;
}

.dock-item:hover {
  color: #f1f5f9;
  transform: translateY(-2px);
}

/* Active Dock Pill - Mint Glowing Capsule like RxAudit Lens */
.dock-item.dock-active {
  background: linear-gradient(135deg, #10b981 0%, #14b8a6 100%);
  color: #022c22 !important;
  font-weight: 700;
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.45), 0 4px 12px rgba(0, 0, 0, 0.3);
  transform: translateY(-2px);
}

.dock-item.dock-active i {
  color: #022c22 !important;
}

/* Scrollytelling Dot Matrix Stage */
.dot-matrix-stage {
  background: radial-gradient(circle at 50% 20%, rgba(15, 23, 42, 0.9) 0%, rgba(8, 13, 26, 0.98) 100%);
  border: 1px solid rgba(30, 41, 59, 0.9);
  position: relative;
  overflow: hidden;
}

/* Command Palette Backdrop */
.cmd-k-backdrop {
  background: rgba(4, 7, 16, 0.8);
  backdrop-filter: blur(12px);
}

