@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Space+Grotesk:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;700&display=swap');

:root {
  --base-bg: #F8FAFC;
  --card-bg: #FFFFFF;
  --card-border: rgba(59, 130, 246, 0.15);
  --accent-cyan: #3B82F6;
  --accent-green: #10B981;
  --alert-red: #EF4444;
  --warning-amber: #F59E0B;
  --text-primary: #1E293B;
  --text-secondary: #64748B;
  --glass-bg: rgba(255, 255, 255, 0.8);
  --glass-blur: blur(12px);
  --sidebar-width: 260px;
  --topbar-height: 70px;
}

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

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--base-bg);
  background-image: 
    linear-gradient(rgba(59, 130, 246, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(59, 130, 246, 0.05) 1px, transparent 1px);
  background-size: 40px 40px;
  color: var(--text-primary);
  height: 100vh;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: 'Space Grotesk', sans-serif;
  letter-spacing: -0.02em;
}

.mono {
  font-family: 'JetBrains Mono', monospace;
}

/* Glassmorphism Utility */
.glass {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
}

/* Glow Effects */
.glow-cyan {
  box-shadow: 0 8px 24px rgba(59, 130, 246, 0.15);
}

.glow-green {
  box-shadow: 0 8px 24px rgba(16, 185, 129, 0.15);
}

.glow-red {
  box-shadow: 0 8px 24px rgba(239, 68, 68, 0.15);
}

.glow-amber {
  box-shadow: 0 8px 24px rgba(245, 158, 11, 0.15);
}

.glow-text-cyan {
  text-shadow: 0 0 4px rgba(59, 130, 246, 0.2);
}

/* Common Layout Components */
.dashboard-container {
  display: flex;
  height: 100vh;
  width: 100vw;
}

.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  height: 100vh;
  position: relative;
  overflow: hidden;
}

.page-container {
  flex: 1;
  padding: 24px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--card-border) transparent;
}

.page-container::-webkit-scrollbar {
  width: 6px;
}

.page-container::-webkit-scrollbar-thumb {
  background: var(--card-border);
  border-radius: 10px;
}

/* Grid Layouts */
.stats-bar {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.main-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr 1fr;
  gap: 24px;
  height: calc(100% - 140px);
}

.main-grid > * {
  min-width: 0;
}

/* Pulse Animation */
@keyframes pulse-red {
  0% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.5); opacity: 0.5; }
  100% { transform: scale(1); opacity: 1; }
}

.pulse-dot-red {
  width: 8px;
  height: 8px;
  background-color: var(--alert-red);
  border-radius: 50%;
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.3);
  animation: pulse-red 2s infinite ease-in-out;
}

@keyframes pulse-cyan {
  0% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.5); opacity: 0.5; }
  100% { transform: scale(1); opacity: 1; }
}

.pulse-dot-cyan {
  width: 8px;
  height: 8px;
  background-color: var(--accent-cyan);
  border-radius: 50%;
  box-shadow: 0 0 10px rgba(59, 130, 246, 0.3);
  animation: pulse-cyan 2s infinite ease-in-out;
}

@keyframes scanline {
  0% { transform: translateY(-100%); }
  100% { transform: translateY(100vh); }
}

.scanline {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(to bottom, transparent, rgba(59, 130, 246, 0.05), transparent);
  animation: scanline 8s linear infinite;
  pointer-events: none;
  z-index: 100;
}

/* Scrollbar Hide for specific panels if needed */
.no-scrollbar::-webkit-scrollbar {
  display: none;
}
.no-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.hover-glow {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.hover-glow:hover {
  border-color: var(--accent-cyan) !important;
  box-shadow: 0 12px 32px rgba(59, 130, 246, 0.12);
  transform: translateY(-2px);
}

.spin-slow {
  animation: spin 8s linear infinite;
}

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

.status-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  position: relative;
}

.status-pulse::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 50%;
  background: inherit;
  animation: pulse-ring 1.5s cubic-bezier(0.24, 0, 0.38, 1) infinite;
}

@keyframes pulse-ring {
  0% { transform: scale(1); opacity: 0.8; }
  100% { transform: scale(3.5); opacity: 0; }
}

.spin {
  animation: spin 1s linear infinite;
}

.table-row-hover {
  transition: all 0.2s ease;
}

.table-row-hover:hover {
  background: rgba(59, 130, 246, 0.04) !important;
}

.input-glow:focus {
  outline: none;
  border-color: var(--accent-cyan) !important;
  box-shadow: 0 0 10px rgba(59, 130, 246, 0.15);
}

/* Global Dropdown Styling */
select, select option {
  color: var(--text-primary);
  background-color: var(--card-bg);
}

