@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800;900&family=Inter:wght@300;400;500;600;700;800;900&display=swap');

:root {
  /* Premium Vibrant Color Palette */
  --bg-main: #f8fafc; /* Soft Gray */
  --bg-alt: #f1f5f9;
  --bg-gradient: linear-gradient(135deg, #ffffff 0%, #f1f5f9 100%);
  --bg-mesh: radial-gradient(at 0% 0%, rgba(29, 78, 216, 0.05) 0px, transparent 50%),
             radial-gradient(at 100% 0%, rgba(79, 70, 229, 0.05) 0px, transparent 50%),
             radial-gradient(at 0% 100%, rgba(5, 150, 105, 0.03) 0px, transparent 50%),
             radial-gradient(at 100% 100%, rgba(220, 38, 38, 0.03) 0px, transparent 50%);
  
  --surface: rgba(255, 255, 255, 0.85);
  --surface-alt: rgba(248, 250, 252, 0.7);
  --glass-white: rgba(255, 255, 255, 0.9);
  --glass-border: rgba(226, 232, 240, 0.8);
  --border: rgba(226, 232, 240, 0.9);

  /* Color Palette Fixes */
  --cbse-blue: #1d4ed8; /* Royal Blue */
  --cbse-saffron: #4f46e5; /* Indigo */
  --cbse-green: #059669; /* Emerald */
  
  --success: #059669; /* Emerald */
  --warning: #d97706; /* Amber */
  --danger: #dc2626; /* Soft Red */
  --info: #2563eb;

  /* Premium Semantic Mapping */
  --primary: #1d4ed8; /* Royal Blue */
  --primary-glow: rgba(29, 78, 216, 0.15);
  --accent: #4f46e5; /* Indigo */
  --secondary: #059669; /* Emerald */
  
  /* Typography */
  --font-main: 'Inter', sans-serif;
  --font-heading: 'Outfit', sans-serif;

  /* Design Tokens - Soft UI */
  --shadow-sm: 0 2px 4px rgba(15, 23, 42, 0.05);
  --shadow-md: 0 8px 16px -2px rgba(15, 23, 42, 0.08), 0 2px 4px -1px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 20px 25px -5px rgba(15, 23, 42, 0.1), 0 10px 10px -5px rgba(15, 23, 42, 0.04);
  --shadow-soft: 0 12px 30px rgba(15, 23, 42, 0.03);
  --shadow-glass: 0 8px 32px 0 rgba(15, 23, 42, 0.06);
  --shadow-magic: 0 0 30px rgba(29, 78, 216, 0.1);
  
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 30px;

  /* Text Colors */
  --text-main: #0f172a;
  --text-muted: #334155;
  --text-light: #64748b;
  
  --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  --iridescent: linear-gradient(to right, #1d4ed8, #4f46e5, #059669, #d97706);
}

body {
  width: 100%;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--font-main);
  background-color: var(--bg-main);
  background-image: var(--bg-mesh), var(--bg-gradient);
  background-attachment: fixed;
  color: var(--text-main);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
}

/* PREMIUM ANIMATIONS */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes slideInRight {
  from { opacity: 0; transform: translateX(30px); }
  to { opacity: 1; transform: translateX(0); }
}

.animate-fade-up {
  animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* RIPPLE EFFECT */
.btn-premium {
  position: relative;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-premium:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-premium::after {
  content: "";
  background: rgba(255, 255, 255, 0.3);
  display: block;
  position: absolute;
  border-radius: 50%;
  padding-top: 240%;
  padding-left: 240%;
  margin-top: -120%;
  margin-left: -120%;
  opacity: 0;
  transition: all 1s;
}

.btn-premium:active::after {
  width: 0;
  opacity: 1;
  transition: 0s;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* =========================
     UNICORN UTILITIES
     ========================= */
.magic-panel {
  background: var(--glass-white);
  backdrop-filter: blur(25px) saturate(200%);
  -webkit-backdrop-filter: blur(25px) saturate(200%);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-magic);
}

.iridescent-text {
  background: var(--iridescent);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.magnetic {
  transition: var(--transition);
}

.magnetic:hover {
  transform: translateY(-8px) scale(1.03);
  filter: drop-shadow(0 10px 20px rgba(142, 84, 233, 0.2));
}

/* =========================
     LAYOUT UTILITIES
     ========================= */
.container {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 2rem;
  width: 100%;
  box-sizing: border-box;
}

section {
  padding: 120px 0;
  position: relative;
  overflow: hidden;
}

.section-header {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 5rem;
}

.section-title {
  font-family: var(--font-heading);
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  font-weight: 900;
  color: var(--cbse-blue);
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  line-height: 1.2;
}

.section-subtitle {
  font-size: 1.15rem;
  color: var(--text-muted);
  line-height: 1.6;
  font-weight: 500;
}

/* =========================
     BUTTONS
     ========================= */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.8rem 1.6rem;
  border-radius: var(--radius-md);
  font-weight: 600;
  text-decoration: none;
  position: relative;
  overflow: hidden;
  transition: var(--transition);
  cursor: pointer;
  border: none;
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.35), transparent 60%);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.btn:active::before {
  opacity: 1;
}

#core-modules,
#how-it-works,
#solutions-by-level,
#system-roles,
#who-we-help,
#home-cta {
  scroll-margin-top: 110px;
}

/* Avatar and Table User Cells */
.avatar-sm {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--border, rgba(226, 232, 240, 0.9));
  flex-shrink: 0;
}

.user-cell {
  display: flex;
  align-items: center;
  gap: 12px;
}