﻿/* Fonts loaded via preload in HTML for better performance */

:root {
  /* Professional & Balanced Color Palette */
  --brand-primary: #bf0000;
  --brand-secondary: #9c88ff;
  --brand-accent: #ff9f73;
  --brand-success: #5fb3d3;
  --brand-warning: #ffbe73;
  --brand-danger: #ff8a80;
  --brand-dark: #2d3436;
  --brand-light: #fdfdfd;
  --brand-purple: #a8a8ff;
  --brand-pink: #ff9eb5;
  --brand-muted: #8e9aaf;
  --brand-calm: #e8f4fd;
  --brand-soft: #f7f9fc;
  
  /* Harmonious Gentle Gradients */
  --gradient-1: linear-gradient(135deg, #e8f5e8 0%, #b8e6b8 50%, #81c784 100%);
  --gradient-2: linear-gradient(135deg, #f3e5f5 0%, #e1bee7 50%, #ce93d8 100%);
  --gradient-3: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 50%, #90caf9 100%);
  --gradient-4: linear-gradient(135deg, #fff3e0 0%, #ffcc02 50%, #ffb300 100%);
  --gradient-5: linear-gradient(135deg, #fce4ec 0%, #f8bbd9 50%, #f48fb1 100%);
  --gradient-6: linear-gradient(135deg, #f1f8e9 0%, #dcedc1 50%, #c5e1a5 100%);
  --gradient-7: linear-gradient(135deg, #e8f4fd 0%, #b3e5fc 50%, #81d4fa 100%);
  --gradient-8: linear-gradient(135deg, #fff8e1 0%, #fff176 50%, #ffee58 100%);
  
  /* Soft Glass Effects */
  --glass-bg: rgba(255, 255, 255, 0.25);
  --glass-border: rgba(255, 255, 255, 0.3);
  --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  
  /* Enhanced Card Styles */
  --card-bg: rgba(255, 255, 255, 0.9);
  --card-hover-bg: rgba(255, 255, 255, 0.95);
  --border-color: rgba(107, 115, 255, 0.12);
  
  /* Gentle Shadows */
  --shadow-soft: 0 2px 16px rgba(0, 0, 0, 0.06);
  --shadow-medium: 0 4px 24px rgba(0, 0, 0, 0.08);
  --shadow-hard: 0 8px 32px rgba(0, 0, 0, 0.12);
  --shadow-glow: 0 0 24px rgba(107, 115, 255, 0.2);
  
  /* Smooth Animation Variables */
  --transition-smooth: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --transition-bounce: all 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  --transition-gentle: all 0.3s ease-out;
  --transition-fast: all 0.15s ease-out;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  overflow-y: scroll;
  overflow-x: hidden;
}

body {
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--brand-soft);
  background-image: 
    radial-gradient(circle at 25% 25%, rgba(107, 115, 255, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 75% 75%, rgba(156, 136, 255, 0.08) 0%, transparent 50%),
    linear-gradient(135deg, var(--brand-calm) 0%, var(--brand-soft) 100%);
  background-attachment: fixed;
  color: var(--brand-dark);
  min-height: 100vh;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Gentle Floating Elements */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(circle at 15% 85%, rgba(107, 115, 255, 0.03) 0%, transparent 40%),
    radial-gradient(circle at 85% 15%, rgba(255, 159, 115, 0.03) 0%, transparent 40%),
    radial-gradient(circle at 50% 50%, rgba(95, 179, 211, 0.02) 0%, transparent 40%);
  pointer-events: none;
  z-index: -1;
  animation: gentleFloat 30s ease-in-out infinite;
}

@keyframes gentleFloat {
  0%, 100% { 
    opacity: 0.3;
    transform: translateY(0px) scale(1);
  }
  50% { 
    opacity: 0.5;
    transform: translateY(-10px) scale(1.02);
  }
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.25rem 0.9rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.35);
  font-weight: 500;
  font-size: 0.85rem;
  letter-spacing: 0.02em;
}

.btn-primary {
  background: #bf0000;
  color: white !important;
  font-weight: 500;
  border-radius: 1.25rem;
  padding: 1rem 2.5rem;
  box-shadow: var(--shadow-soft);
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
  cursor: pointer;
  border: none;
  font-size: 0.95rem;
  letter-spacing: 0.3px;
}

.btn-primary * {
  color: white !important;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
  transition: var(--transition-gentle);
}

.btn-primary:hover::before {
  left: 100%;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 24px rgba(191, 0, 0, 0.3);
  background: #9a0000;
}

.btn-primary:active {
  transform: translateY(0px) scale(0.98);
  transition: var(--transition-fast);
}

.btn-secondary {
  border-radius: 1.25rem;
  padding: 1rem 2.5rem;
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.3px;
  border: 1px solid rgba(107, 115, 255, 0.2);
  color: var(--brand-primary);
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(20px);
  transition: var(--transition-gentle);
  cursor: pointer;
}

.btn-secondary.dark {
  border-color: rgba(45, 52, 54, 0.15);
  color: var(--brand-dark);
  background: rgba(255, 255, 255, 0.8);
}

.btn-secondary:hover {
  border-color: var(--brand-primary);
  color: white;
  background: var(--brand-primary);
  transform: translateY(-1px);
  box-shadow: var(--shadow-soft);
}

.btn-secondary.dark:hover {
  background: var(--brand-dark);
  color: white;
  border-color: var(--brand-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-soft);
}

.glass-panel {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 1.75rem;
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(30px);
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.glass-panel::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(107, 115, 255, 0.3), transparent);
  opacity: 0.8;
}

.glass-panel:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-medium);
  background: var(--card-hover-bg);
  border-color: rgba(107, 115, 255, 0.2);
}

/* Card Hover Effects */
.card-hover {
  transition: var(--transition-smooth);
  cursor: pointer;
}

.card-hover:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: var(--shadow-hard);
}

.card-hover:active {
  transform: translateY(-1px) scale(0.99);
  transition: var(--transition-fast);
}

.stat-chip {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 1rem 1.25rem;
  border-radius: 1rem;
  background: rgba(15, 23, 42, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.feature-icon {
  width: 3rem;
  height: 3rem;
  border-radius: 0.9rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 122, 255, 0.12);
  color: var(--brand-primary);
}

.blur-blob {
  position: absolute;
  width: 280px;
  height: 280px;
  filter: blur(75px);
  opacity: 0.35;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.65), transparent 65%);
  pointer-events: none;
  animation: float 6s ease-in-out infinite;
}

/* Gentle & Calming Animations */
@keyframes float {
  0%, 100% { 
    transform: translateY(0px) rotate(0deg);
  }
  50% { 
    transform: translateY(-8px) rotate(2deg);
  }
}

@keyframes gentlePulse {
  0%, 100% { 
    transform: scale(1);
    opacity: 1;
  }
  50% { 
    transform: scale(1.02);
    opacity: 0.9;
  }
}

@keyframes slideInUp {
  from {
    transform: translateY(40px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes slideInLeft {
  from {
    transform: translateX(-30px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes gentleBounce {
  0% {
    transform: scale(0.95);
    opacity: 0;
  }
  50% {
    transform: scale(1.02);
    opacity: 0.8;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

@keyframes subtleShimmer {
  0% {
    background-position: -1000px 0;
    opacity: 0.3;
  }
  50% {
    opacity: 0.5;
  }
  100% {
    background-position: 1000px 0;
    opacity: 0.3;
  }
}

@keyframes breathe {
  0%, 100% {
    transform: scale(1);
    opacity: 0.8;
  }
  50% {
    transform: scale(1.05);
    opacity: 1;
  }
}

/* Animation Classes */
.animate-float { animation: float 8s ease-in-out infinite; }
.animate-pulse { animation: gentlePulse 3s cubic-bezier(0.4, 0, 0.6, 1) infinite; }
.animate-slideInUp { animation: slideInUp 1s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards; }
.animate-slideInLeft { animation: slideInLeft 1s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards; }
.animate-fadeIn { animation: fadeIn 1.2s ease-out forwards; }
.animate-bounceIn { animation: gentleBounce 1s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards; }
.animate-breathe { animation: breathe 4s ease-in-out infinite; }

/* Gradient Text */
.gradient-text {
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 600;
}

.gradient-text-2 {
  background: linear-gradient(135deg, var(--brand-success), var(--brand-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 600;
}

.gradient-text-calm {
  background: linear-gradient(135deg, var(--brand-muted), var(--brand-primary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 500;
}

/* Gentle Interactive Buttons */
.btn-calm {
  position: relative;
  background: linear-gradient(135deg, var(--brand-success), var(--brand-secondary));
  border: none;
  border-radius: 1.25rem;
  color: white !important;
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.3px;
  padding: 1rem 2.5rem;
  cursor: pointer;
  transition: var(--transition-smooth);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  width: 100%;
  text-align: center;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}

.btn-calm * {
  color: white !important;
}

.btn-calm::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, var(--brand-purple), var(--brand-pink));
  opacity: 0;
  transition: var(--transition-gentle);
}

.btn-calm:hover::before {
  opacity: 1;
}

.btn-calm:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow);
}

.btn-calm:active {
  transform: translateY(0px) scale(0.98);
}

/* Fix responsive grid issues */
.grid {
  display: grid;
  width: 100%;
}

/* Ensure proper mobile responsive layout */
@media (max-width: 640px) {
  .glass-panel {
    padding: 1.5rem;
  }
  
  .btn-primary,
  .btn-calm {
    padding: 0.875rem 1.5rem;
    font-size: 0.9rem;
  }
  
  .text-6xl {
    font-size: 2.5rem;
  }
  
  .text-5xl {
    font-size: 2.25rem;
  }
  
  .text-4xl {
    font-size: 2rem;
  }
  
  .text-3xl {
    font-size: 1.75rem;
  }
}

/* Floating Elements */
.floating {
  animation: float 3s ease-in-out infinite;
}

.floating:nth-child(2) {
  animation-delay: 0.5s;
}

.floating:nth-child(3) {
  animation-delay: 1s;
}

/* Glass Morphism Enhancements */
.glass-morphism {
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(30px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

/* ===== BATCH 1: ENHANCED DESIGN SYSTEM ===== */

/* 1. Enhanced Card Design System */
.enhanced-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 16px;
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.08),
    0 4px 16px rgba(0, 0, 0, 0.04),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.enhanced-card:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 
    0 16px 48px rgba(0, 0, 0, 0.12),
    0 8px 24px rgba(0, 0, 0, 0.08);
}

.enhanced-card-subtle {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
  transition: all 0.2s ease;
}

.enhanced-card-subtle:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
}

/* 2. Loading States and Skeleton UI */
.skeleton {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
  border-radius: 8px;
}

@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.skeleton-text {
  height: 16px;
  margin: 8px 0;
}

.skeleton-title {
  height: 24px;
  width: 60%;
  margin: 12px 0;
}

.skeleton-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
}

.skeleton-card {
  padding: 20px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(0, 0, 0, 0.06);
}

/* 3. Status Badge System */
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.status-active {
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}

.status-pending {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: white;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}

.status-inactive {
  background: linear-gradient(135deg, #6b7280, #4b5563);
  color: white;
  box-shadow: 0 2px 8px rgba(107, 114, 128, 0.3);
}

.status-error {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: white;
  box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3);
}

.status-verified {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  color: white;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

/* 4. Modern Color Palette Variables */
:root {
  --primary-50: #eff6ff;
  --primary-100: #dbeafe;
  --primary-500: #3b82f6;
  --primary-600: #2563eb;
  --primary-700: #1d4ed8;
  
  --success-50: #ecfdf5;
  --success-100: #d1fae5;
  --success-500: #10b981;
  --success-600: #059669;
  
  --warning-50: #fffbeb;
  --warning-100: #fef3c7;
  --warning-500: #f59e0b;
  --warning-600: #d97706;
  
  --error-50: #fef2f2;
  --error-100: #fee2e2;
  --error-500: #ef4444;
  --error-600: #dc2626;
  
  --neutral-50: #f9fafb;
  --neutral-100: #f3f4f6;
  --neutral-500: #6b7280;
  --neutral-600: #4b5563;
  --neutral-700: #374151;
  --neutral-800: #1f2937;
  --neutral-900: #111827;
}

/* 5. Enhanced Typography System */
.heading-xl {
  font-size: 3.75rem;
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.025em;
}

.heading-lg {
  font-size: 3rem;
  line-height: 1.1;
  font-weight: 700;
  letter-spacing: -0.025em;
}

.heading-md {
  font-size: 2.25rem;
  line-height: 1.2;
  font-weight: 600;
  letter-spacing: -0.025em;
}

.heading-sm {
  font-size: 1.875rem;
  line-height: 1.3;
  font-weight: 600;
}

.body-lg {
  font-size: 1.125rem;
  line-height: 1.6;
  font-weight: 400;
}

.body-md {
  font-size: 1rem;
  line-height: 1.5;
  font-weight: 400;
}

.body-sm {
  font-size: 0.875rem;
  line-height: 1.4;
  font-weight: 400;
}

.caption {
  font-size: 0.75rem;
  line-height: 1.3;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ===== BATCH 2: STRUCTURAL & USABILITY ENHANCEMENTS ===== */

/* 6. Enhanced Navigation & Breadcrumbs */
.breadcrumb-container {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  padding: 12px 24px;
  position: sticky;
  top: 0;
  z-index: 40;
}

.nav-secondary {
  display: flex;
  gap: 24px;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.nav-secondary a {
  padding: 8px 16px;
  border-radius: 8px;
  font-weight: 500;
  color: #6b7280;
  transition: all 0.2s ease;
}

.nav-secondary a:hover {
  background: rgba(59, 130, 246, 0.1);
  color: #2563eb;
}

.nav-secondary a.active {
  background: #2563eb;
  color: white;
}

/* 7. Responsive Grid Improvements */
@media (max-width: 768px) {
  .responsive-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  
  .enhanced-card {
    padding: 16px;
    border-radius: 12px;
  }
  
  .enhanced-card:hover {
    transform: translateY(-2px) scale(1.01);
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .responsive-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
}

@media (min-width: 1025px) {
  .responsive-grid {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
  }
}

.mobile-optimized {
  padding: 16px;
}

@media (min-width: 768px) {
  .mobile-optimized {
    padding: 24px;
  }
}

@media (min-width: 1024px) {
  .mobile-optimized {
    padding: 32px;
  }
}

/* 8. Interactive Feedback System */
.interactive-button {
  position: relative;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.interactive-button:before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  transition: width 0.6s, height 0.6s, top 0.6s, left 0.6s;
  transform: translate(-50%, -50%);
  z-index: 0;
}

.interactive-button:active:before {
  width: 300px;
  height: 300px;
}

.interactive-button > * {
  position: relative;
  z-index: 1;
}

.micro-interaction {
  transition: all 0.2s ease;
}

.micro-interaction:hover {
  transform: translateY(-1px);
}

.micro-interaction:active {
  transform: translateY(0px) scale(0.98);
}

.success-feedback {
  animation: success-pulse 0.6s ease;
}

@keyframes success-pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  100% { transform: scale(1); box-shadow: 0 0 0 20px rgba(16, 185, 129, 0); }
}

.error-feedback {
  animation: error-shake 0.5s ease;
}

@keyframes error-shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}

.loading-feedback {
  animation: loading-pulse 1.5s ease-in-out infinite;
}

@keyframes loading-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* 9. Information Hierarchy Improvements */
.data-section {
  background: white;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 16px;
  overflow: hidden;
}

.data-section-header {
  background: linear-gradient(135deg, #f8fafc, #f1f5f9);
  padding: 20px 24px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.data-section-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 4px;
}

.data-section-subtitle {
  font-size: 0.875rem;
  color: #6b7280;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
}

.data-table th {
  background: #f9fafb;
  padding: 12px 16px;
  text-align: left;
  font-weight: 600;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #6b7280;
  border-bottom: 1px solid #e5e7eb;
}

.data-table td {
  padding: 16px;
  border-bottom: 1px solid #f3f4f6;
  font-size: 0.875rem;
  color: #374151;
}

.data-table tbody tr:hover {
  background: #f8fafc;
  transition: background-color 0.2s ease;
}

.data-table tbody tr:hover td {
  color: #1f2937;
}

.data-group {
  margin-bottom: 32px;
}

.data-group:not(:last-child) {
  border-bottom: 2px solid #f3f4f6;
  padding-bottom: 32px;
}

/* 10. Enhanced Dashboard Visual Components */
.dashboard-metric {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.8));
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 16px;
  padding: 24px;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.dashboard-metric:before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #3b82f6, #8b5cf6, #ef4444, #10b981);
  background-size: 200% 100%;
  animation: gradient-shift 3s ease infinite;
}

@keyframes gradient-shift {
  0%, 100% { background-position: 0% 0%; }
  50% { background-position: 100% 0%; }
}

.dashboard-metric:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.metric-value {
  font-size: 2.5rem;
  font-weight: 700;
  color: #1f2937;
  line-height: 1;
  margin-bottom: 8px;
}

.metric-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.metric-change {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: 12px;
  margin-top: 8px;
  display: inline-block;
}

.metric-change.positive {
  background: #ecfdf5;
  color: #059669;
}

.metric-change.negative {
  background: #fef2f2;
  color: #dc2626;
}

.chart-container {
  background: white;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
  border: 1px solid rgba(0, 0, 0, 0.06);
}

.progress-ring {
  transform: rotate(-90deg);
  transition: stroke-dasharray 1s ease-in-out;
}

/* ===== BATCH 3: FORM DESIGN & ACCESSIBILITY ENHANCEMENTS ===== */

/* 11. Enhanced Form Design */
.form-group {
  margin-bottom: 1.5rem;
}

.form-label {
  font-weight: 600;
  font-size: 0.875rem;
  color: #374151;
  margin-bottom: 0.5rem;
  display: block;
}

.form-input {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 500;
  color: #111827;
  background: white;
  transition: all 0.2s ease;
}

.form-input:focus {
  outline: none;
  border-color: #3b82f6;
  background: #eff6ff;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.form-input.error {
  border-color: #ef4444;
  background: #fef2f2;
}

.form-input.success {
  border-color: #10b981;
  background: #ecfdf5;
}

.form-error {
  color: #ef4444;
  font-size: 0.875rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 4px;
}

.form-success {
  color: #10b981;
  font-size: 0.875rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 4px;
}

.form-help {
  color: #6b7280;
  font-size: 0.875rem;
}

.form-checkbox {
  width: 1.125rem;
  height: 1.125rem;
  border: 2px solid #d1d5db;
  border-radius: 4px;
  background: white;
  transition: all 0.2s ease;
  cursor: pointer;
}

.form-checkbox:checked {
  background: #3b82f6;
  border-color: #3b82f6;
}

.form-checkbox:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* 12. Empty State Enhancements */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem;
  text-align: center;
  border: 2px dashed #e5e7eb;
  border-radius: 1rem;
  background: linear-gradient(135deg, #f9fafb, #f3f4f6);
  transition: all 0.3s ease;
}

.empty-state:hover {
  border-color: #d1d5db;
  background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
}

.empty-state-icon {
  width: 4rem;
  height: 4rem;
  margin-bottom: 1rem;
  opacity: 0.6;
}

/* 13. Enhanced Search Components */
.search-input {
  font-size: 1rem;
  font-weight: 500;
}

.search-input:focus {
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

.enhanced-search {
  position: relative;
}

.search-suggestions {
  max-height: 300px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #d1d5db #f9fafb;
}

.search-suggestions::-webkit-scrollbar {
  width: 6px;
}

.search-suggestions::-webkit-scrollbar-track {
  background: #f9fafb;
}

.search-suggestions::-webkit-scrollbar-thumb {
  background: #d1d5db;
  border-radius: 3px;
}

/* 14. Tooltip System */
.tooltip-container {
  position: relative;
  display: inline-block;
}

.tooltip-content {
  position: absolute;
  z-index: 50;
  padding: 8px 12px;
  font-size: 0.875rem;
  color: white;
  background: #1f2937;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  white-space: nowrap;
  max-width: 250px;
  word-wrap: break-word;
  white-space: normal;
}

.tooltip-arrow {
  position: absolute;
  width: 8px;
  height: 8px;
  background: #1f2937;
  transform: rotate(45deg);
}

/* 15. Keyboard Accessibility */
.keyboard-focus-visible {
  outline: 2px solid #3b82f6;
  outline-offset: 2px;
  border-radius: 4px;
}

/* Focus styles for interactive elements */
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid #3b82f6;
  outline-offset: 2px;
}

/* Keyboard navigation helpers */
.skip-link {
  position: absolute;
  top: -40px;
  left: 6px;
  background: #000;
  color: white;
  padding: 8px;
  text-decoration: none;
  border-radius: 4px;
  z-index: 100;
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: 6px;
}

/* Focus indicators for cards and interactive elements */
.enhanced-card:focus-within {
  outline: 2px solid #3b82f6;
  outline-offset: 2px;
}

.micro-interaction:focus-visible {
  outline: 2px solid #3b82f6;
  outline-offset: 2px;
  border-radius: 8px;
}

/* Keyboard shortcuts display */
.keyboard-shortcut {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 6px;
  background: #f3f4f6;
  border: 1px solid #d1d5db;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #374151;
}

.keyboard-shortcut kbd {
  background: #e5e7eb;
  padding: 2px 4px;
  border-radius: 2px;
  font-size: 0.6875rem;
}

/* Enhanced button states for accessibility */
.btn-enhanced {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border: none;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}

.btn-enhanced:focus-visible {
  outline: 2px solid #3b82f6;
  outline-offset: 2px;
}

.btn-enhanced:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none !important;
}

.btn-enhanced:disabled:hover {
  transform: none !important;
}

/* Loading state for buttons */
.btn-enhanced.loading {
  cursor: wait;
  opacity: 0.8;
}

.btn-enhanced.loading::before {
  content: '';
  display: inline-block;
  width: 16px;
  height: 16px;
  margin-right: 8px;
  border: 2px solid currentColor;
  border-top-color: transparent;
  border-radius: 50%;
  animation: button-spin 0.8s linear infinite;
}

@keyframes button-spin {
  to { transform: rotate(360deg); }
}

/* ===== BATCH 4: FINAL POLISH & ANIMATION SYSTEM ===== */

/* 16. Consistent Icon System */
.icon-container {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.icon-badge {
  position: relative;
}

.icon-badge::after {
  content: '';
  position: absolute;
  top: -2px;
  right: -2px;
  width: 8px;
  height: 8px;
  background: #ef4444;
  border: 2px solid white;
  border-radius: 50%;
}

/* 17. Enhanced Notification System */
.notification-toast {
  backdrop-filter: blur(12px);
  animation: toast-slide-in 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes toast-slide-in {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.notification-item {
  cursor: pointer;
  transition: all 0.2s ease;
}

.notification-item:hover {
  transform: translateX(4px);
  box-shadow: -4px 0 8px rgba(59, 130, 246, 0.1);
}

.notification-dropdown {
  animation: dropdown-fade-in 0.2s ease-out;
  transform-origin: top right;
}

@keyframes dropdown-fade-in {
  from {
    opacity: 0;
    transform: scale(0.95) translateY(-10px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

/* 18. Enhanced Sidebar */
.enhanced-sidebar {
  position: relative;
}

.sidebar-container {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 2px 0 12px rgba(0, 0, 0, 0.04);
}

.sidebar-button,
.sidebar-link {
  position: relative;
  overflow: hidden;
}

.sidebar-button:hover,
.sidebar-link:hover {
  transform: translateX(2px);
}

.sidebar-button:active,
.sidebar-link:active {
  transform: translateX(1px) scale(0.98);
}

.sidebar-badge {
  animation: badge-pulse 2s ease-in-out infinite;
}

@keyframes badge-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

.sidebar-toggle {
  transition: all 0.2s ease;
}

.sidebar-toggle:hover {
  transform: scale(1.1);
}

/* 19. Enhanced Header */
.enhanced-header {
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 8px rgba(0, 0, 0, 0.04);
  z-index: 40;
}

.header-search {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.header-search:focus {
  transform: scale(1.02);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

.header-icon-btn {
  position: relative;
  transition: all 0.2s ease;
}

.header-icon-btn:hover {
  transform: translateY(-1px);
}

.header-icon-btn:active {
  transform: translateY(0) scale(0.95);
}

.header-action-btn {
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
}

.header-action-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(59, 130, 246, 0.3);
}

.header-action-btn:active {
  transform: translateY(-1px);
}

.user-menu-btn {
  transition: all 0.2s ease;
}

.user-menu-btn:hover {
  transform: scale(1.02);
}

.user-dropdown {
  animation: dropdown-slide-in 0.2s ease-out;
}

@keyframes dropdown-slide-in {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.user-menu-item {
  transition: all 0.15s ease;
}

.user-menu-item:hover {
  transform: translateX(4px);
}

/* 20. Interactive Animation System */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

.stagger-animation {
  animation-delay: var(--delay, 0ms);
}

.bounce-in {
  animation: bounce-in 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes bounce-in {
  0% {
    opacity: 0;
    transform: scale(0.3) rotate(-10deg);
  }
  50% {
    opacity: 0.8;
    transform: scale(1.05) rotate(-5deg);
  }
  70% {
    opacity: 0.9;
    transform: scale(0.9) rotate(2deg);
  }
  100% {
    opacity: 1;
    transform: scale(1) rotate(0deg);
  }
}

.slide-up {
  animation: slide-up 0.5s ease-out;
}

@keyframes slide-up {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-scale {
  animation: fade-scale 0.4s ease-out;
}

@keyframes fade-scale {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.rotate-in {
  animation: rotate-in 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

@keyframes rotate-in {
  from {
    opacity: 0;
    transform: rotate(-10deg) scale(0.9);
  }
  to {
    opacity: 1;
    transform: rotate(0deg) scale(1);
  }
}

/* Hover effects for cards */
.card-lift {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-lift:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
}

/* Loading animations */
.pulse-slow {
  animation: pulse-slow 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse-slow {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

.shimmer {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* Interactive button effects */
.btn-ripple {
  position: relative;
  overflow: hidden;
}

.btn-ripple::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  transition: width 0.3s, height 0.3s, top 0.3s, left 0.3s;
  transform: translate(-50%, -50%);
}

.btn-ripple:active::before {
  width: 300px;
  height: 300px;
}

/* Smooth page transitions */
.page-enter {
  opacity: 0;
  transform: translateY(20px);
}

.page-enter-active {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 300ms, transform 300ms;
}

.page-exit {
  opacity: 1;
  transform: translateY(0);
}

.page-exit-active {
  opacity: 0;
  transform: translateY(-20px);
  transition: opacity 300ms, transform 300ms;
}

/* Utility animation classes */
.animate-float {
  animation: float 6s ease-in-out infinite;
}

@keyframes float {
  0%, 100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
}

.animate-glow {
  animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
  from {
    box-shadow: 0 0 5px rgba(59, 130, 246, 0.5);
  }
  to {
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.8);
  }
}

/* Enhanced focus states for accessibility */
*:focus-visible {
  outline: 2px solid #3b82f6;
  outline-offset: 2px;
  border-radius: 4px;
  animation: focus-ring 0.2s ease-out;
}

@keyframes focus-ring {
  from {
    outline-width: 0px;
    outline-offset: 4px;
  }
  to {
    outline-width: 2px;
    outline-offset: 2px;
  }
}

/* Neon Effects */
.neon-glow {
  text-shadow: 0 0 20px var(--brand-primary),
               0 0 40px var(--brand-primary),
               0 0 60px var(--brand-primary);
  color: white;
}

/* Calming Form Elements */
.form-input {
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(107, 115, 255, 0.15);
  border-radius: 1rem;
  padding: 1rem 1.5rem;
  color: var(--brand-dark);
  transition: var(--transition-gentle);
  backdrop-filter: blur(20px);
  font-size: 0.95rem;
  line-height: 1.5;
  width: 100%;
  box-sizing: border-box;
}

.form-input:focus {
  outline: none;
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px rgba(107, 115, 255, 0.08);
  background: rgba(255, 255, 255, 0.95);
  transform: translateY(-1px);
}

.form-input::placeholder {
  color: var(--brand-muted);
  opacity: 0.8;
}

/* Gentle Focus States */
.focus-calm:focus {
  outline: none;
  border-color: var(--brand-success);
  box-shadow: 0 0 0 3px rgba(95, 179, 211, 0.1);
}

/* Enhanced Typography */
.text-display {
  font-family: 'Space Grotesk', 'Inter', sans-serif;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.text-balance {
  text-wrap: balance;
}

/* Global Text Overflow Prevention - Aggressive */
.card,
.glass-panel,
[class*="card"],
[class*="panel"] {
  word-wrap: break-word;
  overflow-wrap: anywhere;
  word-break: break-word;
  min-width: 0;
  color: #1f2937;
}

/* Ensure text visibility on all backgrounds */
.text-white {
  color: #ffffff !important;
}

.text-gray-900,
.text-dark-gray {
  color: #1f2937 !important;
}

.text-gray-800 {
  color: #262626 !important;
}

.text-gray-700 {
  color: #404040 !important;
}

.text-gray-600 {
  color: #525252 !important;
}

.text-gray-500 {
  color: #737373 !important;
}

/* Force break extremely long strings everywhere */
h1, h2, h3, h4, h5, h6,
p, span, div, a, button {
  word-wrap: break-word;
  overflow-wrap: anywhere;
}

/* Ensure flex containers can shrink */
.flex,
[class*="flex"] {
  min-width: 0;
}

.flex > *,
[class*="flex"] > * {
  min-width: 0;
}

/* Line clamp utilities for proper text truncation */
.line-clamp-1 {
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  word-break: break-word;
  overflow-wrap: anywhere;
}

.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  word-break: break-word;
  overflow-wrap: anywhere;
}

.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  word-break: break-word;
  overflow-wrap: anywhere;
}

/* Gentle Status Badges */
.badge-success {
  background: linear-gradient(135deg, var(--brand-success), #7dd3fc);
  color: white !important;
  padding: 0.6rem 1.2rem;
  border-radius: 2rem;
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.3px;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: var(--shadow-soft);
  animation: gentlePulse 4s infinite;
}

.badge-success * {
  color: white !important;
}

.badge-warning {
  background: linear-gradient(135deg, var(--brand-warning), #fbbf24);
  color: white !important;
  padding: 0.6rem 1.2rem;
  border-radius: 2rem;
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.3px;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: var(--shadow-soft);
}

.badge-warning * {
  color: white !important;
}

.badge-calm {
  background: linear-gradient(135deg, var(--brand-muted), var(--brand-primary));
  color: white !important;
  padding: 0.6rem 1.2rem;
  border-radius: 2rem;
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.3px;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: var(--shadow-soft);
}

.badge-calm * {
  color: white !important;
}

/* Responsive Enhancements */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

