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

/* ========== CSS DESIGN SYSTEM ========== */
:root {
  /* Color System */
  --color-primary-50: #f3e8ff;
  --color-primary-100: #e9d5ff;
  --color-primary-200: #d8b4fe;
  --color-primary-300: #c084fc;
  --color-primary-400: #a855f7;
  --color-primary-500: #9333ea;
  --color-primary-600: #7e22ce;
  --color-primary-700: #6b21a8;
  --color-primary-800: #581c87;
  --color-primary-900: #4c1d95;

  /* Background Colors */
  --bg-primary: #000000;
  --bg-secondary: #080808;
  --bg-tertiary: #0a0a0a;
  --bg-glass: rgba(255, 255, 255, 0.05);
  --bg-glass-dark: rgba(0, 0, 0, 0.3);

  /* Text Colors */
  --text-primary: #ffffff;
  --text-secondary: #e5e7eb;
  --text-tertiary: #9ca3af;
  --text-muted: #6b7280;
  --text-accent: var(--color-primary-600);

  /* Dynamic Colors for Background Transitions */
  --header-text-color: #ffffff;
  --header-text-shadow: none;

  /* Border Colors */
  --border-primary: #1f2123;
  --border-secondary: #374151;
  --border-accent: var(--color-primary-600);
  --border-glass: rgba(126, 34, 206, 0.1);

  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  --shadow-glow: 0 0 30px rgba(126, 34, 206, 0.3);
  --shadow-glow-intense: 0 0 50px rgba(126, 34, 206, 0.5);

  /* Spacing System */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;

  /* Border Radius */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-2xl: 1.5rem;
  --radius-full: 9999px;

  /* Typography */
  --font-primary: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-weight-normal: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;

  /* Transitions */
  --transition-fast: 150ms ease-in-out;
  --transition-normal: 300ms ease-in-out;
  --transition-slow: 500ms ease-in-out;

  /* Z-Index System */
  --z-dropdown: 1000;
  --z-sticky: 1020;
  --z-fixed: 1030;
  --z-modal-backdrop: 1040;
  --z-modal: 1050;
  --z-popover: 1060;
  --z-tooltip: 1070;
}

/* ========== GLOBAL STYLES ========== */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-family: var(--font-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  background-color: var(--bg-primary);
  background-image: radial-gradient(
      circle at 20% 80%,
      rgba(126, 34, 206, 0.03) 0%,
      transparent 50%
    ),
    radial-gradient(
      circle at 80% 20%,
      rgba(168, 85, 247, 0.03) 0%,
      transparent 50%
    ),
    radial-gradient(
      circle at 40% 40%,
      rgba(147, 51, 234, 0.02) 0%,
      transparent 50%
    );
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  transition: background-color 0.6s ease-in-out;
}

/* Hide scrollbar for all major browsers */
/* For Chrome, Safari and Opera */
body::-webkit-scrollbar {
  display: none;
}

/* For IE, Edge and Firefox */
body {
  -ms-overflow-style: none; /* IE and Edge */
  scrollbar-width: none; /* Firefox */
}

/* Floating emoji accents */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
  background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><text y=".9em" font-size="20" opacity="0.1">✨</text></svg>'),
    url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><text y=".9em" font-size="16" opacity="0.08">🚀</text></svg>'),
    url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><text y=".9em" font-size="18" opacity="0.06">🌟</text></svg>');
  background-position: 10% 20%, 90% 80%, 70% 60%;
  background-repeat: no-repeat;
  background-size: 60px 60px, 40px 40px, 50px 50px;
  animation: floatEmoji 20s ease-in-out infinite;
}

@keyframes floatEmoji {
  0%,
  100% {
    transform: translateY(0px);
    opacity: 0.1;
  }
  50% {
    transform: translateY(-10px);
    opacity: 0.15;
  }
}

/* ========== ENHANCED BUTTON SYSTEM ========== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-xl);
  border: 1px solid transparent;
  border-radius: var(--radius-lg);
  font-family: var(--font-primary);
  font-weight: var(--font-weight-medium);
  text-decoration: none;
  transition: all var(--transition-normal);
  cursor: pointer;
  position: relative;
  overflow: hidden;
  white-space: nowrap;
}

.btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.1),
    transparent
  );
  transition: left var(--transition-slow);
}

.btn:hover::before {
  left: 100%;
}

.btn-primary {
  background: linear-gradient(
    135deg,
    var(--color-primary-600),
    var(--color-primary-500)
  );
  color: var(--text-primary);
  box-shadow: var(--shadow-glow);
}

.btn-primary:hover {
  background: linear-gradient(
    135deg,
    var(--color-primary-500),
    var(--color-primary-400)
  );
  box-shadow: var(--shadow-glow-intense);
  transform: translateY(-2px);
}

.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border-color: var(--border-secondary);
  padding: var(--space-md) var(--space-lg);
}

.btn-secondary:hover {
  background: var(--bg-glass);
  border-color: var(--border-accent);
  color: var(--text-accent);
}

.waitlist-button {
  position: relative;
  padding: 1.2rem 1.5rem;
  background: linear-gradient(135deg, #ffffff, #f8fafc);
  color: #000000;
  border-radius: var(--radius-full);
  font-weight: var(--font-weight-semibold);
  text-transform: uppercase;
  letter-spacing: 0.025em;
  transition: all var(--transition-normal);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  font-size: 0.875rem;
}

.waitlist-button::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(126, 34, 206, 0.1),
    transparent
  );
  transition: left var(--transition-slow);
}

.waitlist-button:hover {
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  background: linear-gradient(135deg, #f8fafc, #ffffff);
}

.waitlist-button:hover::before {
  left: 100%;
}

/* ========== ENHANCED HEADER STYLES ========== */
.logo-container img {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  height: 36px; /* Increased from 32px for better proportion */
  width: 160px; /* Increased from 160px to match height increase */
}

header {
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  transition: all var(--transition-normal);
  /* Ensure proper vertical alignment while maintaining header height */
  align-items: center !important;
  padding-top: 1rem;
  padding-bottom: 1rem;
}

/* Compact waitlist button for navigation */
.nav-waitlist-button {
  padding: 0.8rem 1.3rem !important; /* Increased padding for more substantial look */
  font-size: 0.9rem !important; /* Larger font */
  font-weight: 500 !important; /* Medium weight instead of semibold */
  height: auto !important;
  min-height: auto !important;
}

.nav-waitlist-button:hover {
  transform: translateY(-1px) !important; /* Subtle hover effect */
}

.header-links {
  position: relative;
  padding: 1rem 1.2rem; /* Increased padding for more substantial feel */
  color: var(--text-secondary);
  border-radius: var(--radius-md);
  transition: all var(--transition-normal);
  text-decoration: none;
  font-size: 1rem; /* Standard font size for better presence */
}

.header-links::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 50%;
  width: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    var(--color-primary-500),
    var(--color-primary-400)
  );
  transform: translateX(-50%);
  transition: width var(--transition-normal);
}

.header-links:hover {
  color: var(--text-primary);
  background: var(--bg-glass);
}

.header-links:hover::after {
  width: 80%;
}

/* ========== ENHANCED FEATURE CARDS ========== */
.feature-card-glass {
  position: relative;
  background: linear-gradient(
    145deg,
    rgba(255, 255, 255, 0.95),
    rgba(248, 250, 252, 0.9)
  );
  border: 1px solid rgba(126, 34, 206, 0.2);
  border-radius: var(--radius-2xl);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1),
    0 10px 10px -5px rgba(0, 0, 0, 0.04), 0 0 20px rgba(126, 34, 206, 0.1);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: all var(--transition-normal);
  overflow: hidden;
  color: #000000;
}

.feature-card-glass::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--color-primary-300),
    transparent
  );
}

.feature-card-glass h3 {
  color: #1f2937;
  font-weight: var(--font-weight-bold);
}

.feature-card-glass p {
  color: #374151;
  line-height: 1.7;
}

.feature-button {
  color: var(--text-accent);
  font-weight: var(--font-weight-semibold);
  text-decoration: none;
  transition: all var(--transition-normal);
  position: relative;
}

.feature-button:hover {
  color: var(--color-primary-500);
  transform: translateX(4px);
}

/* ========== ENHANCED GRADIENT TEXT ========== */
.gradient-text {
  background: linear-gradient(
    135deg,
    var(--color-primary-200) 0%,
    var(--color-primary-400) 25%,
    var(--color-primary-600) 50%,
    var(--color-primary-400) 75%,
    var(--color-primary-200) 100%
  );
  background-size: 200% 200%;
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: gradientShift 4s ease-in-out infinite;
  /* Fix text clipping by adding padding and ensuring proper line height */
  padding: 0.1rem 0;
  line-height: 1.1;
  /* Ensure the gradient extends beyond text bounds */
  position: relative;
}

@keyframes gradientShift {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

/* ========== ENHANCED DASHBOARD STYLES ========== */
#dashboard {
  transition: all var(--transition-slow);
  transform: perspective(1000px) rotateX(8deg) scale(0.95);
  filter: drop-shadow(0 25px 50px rgba(0, 0, 0, 0.4));
  cursor: pointer;
  background: linear-gradient(
    145deg,
    rgba(126, 34, 206, 0.1),
    rgba(147, 51, 234, 0.05)
  );
  border-radius: var(--radius-2xl);
  border: 1px solid rgba(126, 34, 206, 0.2);
}

#dashboard:hover {
  transform: perspective(1000px) rotateX(0deg) scale(1);
  filter: drop-shadow(0 30px 60px rgba(0, 0, 0, 0.5));
  box-shadow: 0 0 50px rgba(126, 34, 206, 0.3);
}

#dashboard img {
  border-radius: var(--radius-2xl);
  width: 100%;
  height: auto;
  min-height: 400px;
  object-fit: cover;
  transition: all var(--transition-slow);
}

/* Mobile responsive styles for dashboard image */
@media (max-width: 768px) {
  #dashboard img {
    object-fit: contain;
    min-height: 250px;
    max-height: 350px;
  }

  .logo-container img {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    height: 24px; /* Increased from 32px for better proportion */
    width: 130px; /* Increased from 160px to match height increase */
  }

  #dashboard {
    transform: perspective(1000px) rotateX(4deg) scale(0.98);
    margin-top: 2rem !important; /* Reduce top margin on mobile */
  }

  #dashboard:hover {
    transform: perspective(1000px) rotateX(0deg) scale(1);
  }

  /* Adjust dashboard container spacing on mobile */
  .tw-mt-20 {
    margin-top: 3rem !important;
  }
}

/* Extra small devices (phones in portrait) */
@media (max-width: 480px) {
  #dashboard img {
    min-height: 200px;
    max-height: 280px;
  }

  #dashboard {
    margin-top: 1.5rem !important;
  }

  .tw-mt-20 {
    margin-top: 2rem !important;
  }
}

.hero-img-bg-grad {
  background: radial-gradient(
    circle,
    var(--color-primary-600) 0%,
    transparent 70%
  );
  filter: blur(60px);
  opacity: 0.3;
}

/* ========== ENHANCED FAQ STYLES ========== */
.faq {
  background: var(--bg-glass);
  border: 1px solid var(--border-primary);
  border-radius: var(--radius-xl);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: all var(--transition-normal);
}

.faq:hover {
  border-color: var(--border-glass);
  box-shadow: var(--shadow-lg);
}

.faq-accordion {
  padding: var(--space-lg);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: var(--font-weight-medium);
  color: var(--text-primary);
  transition: color var(--transition-normal);
}

.faq-accordion:hover {
  color: var(--text-accent);
}

.faq-accordion i {
  transition: transform var(--transition-normal);
}

.faq-accordion.active i {
  transform: rotate(45deg);
}

.faq .content {
  max-height: 0;
  overflow: hidden;
  padding: 0 var(--space-lg);
  transition: max-height var(--transition-normal),
    padding var(--transition-normal);
}

.faq .content p {
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 0.75rem;
}

/* ========== ENHANCED ANIMATIONS ========== */
@keyframes breathe {
  0%,
  100% {
    transform: scale(1);
    opacity: 0.8;
  }
  50% {
    transform: scale(1.02);
    opacity: 1;
  }
}

.word-animation-complete.show {
  animation: breathe 4s ease-in-out infinite;
}

/* ========== ENHANCED FOOTER ========== */
footer {
  background: linear-gradient(to top, var(--bg-secondary), var(--bg-primary));
  border-top: 1px solid var(--border-primary);
}

.footer-link {
  color: var(--text-tertiary);
  text-decoration: none;
  transition: all var(--transition-normal);
  position: relative;
}

.footer-link::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--text-accent);
  transition: width var(--transition-normal);
}

.footer-link:hover {
  color: var(--text-primary);
}

.footer-link:hover::after {
  width: 100%;
}

/* ========== RESPONSIVE ENHANCEMENTS ========== */
@media (max-width: 768px) {
  :root {
    --space-md: 0.75rem;
    --space-lg: 1.25rem;
    --space-xl: 1.75rem;
  }

  .waitlist-button {
    padding: 0.625rem 1.5rem;
    font-size: 0.8rem;
  }

  .btn {
    padding: var(--space-sm) var(--space-lg);
    font-size: 0.875rem;
  }

  /* --- Consistent Heading Margins --- */
  .section-header {
    margin-bottom: 2rem !important; /* Slightly reduced spacing on mobile */
  }

  /* Mobile-specific section spacing adjustments */
  main > section {
    padding-top: 4rem !important; /* Reduced padding on mobile for better proportions */
    padding-bottom: 4rem !important;
  }

  main > section:not(#hero-section)::before {
    top: 1.5rem; /* Adjust divider position for mobile */
  }
}

/* ========== ACCESSIBILITY ENHANCEMENTS ========== */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Focus styles for better accessibility */
button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 2px solid var(--color-primary-400);
  outline-offset: 2px;
}

/* ========== UTILITY CLASSES ========== */
.animate-fade-in {
  animation: fadeIn 0.6s ease-out;
}

.animate-slide-up {
  animation: slideUp 0.6s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

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

/* ========== MOBILE MENU BUTTON STYLING ========== */
#collapse-btn {
  position: fixed;
  right: 1.5rem;
  z-index: 1001; /* Above the overlay */
  background: transparent;
  margin-top: 7.5px;
  border: none;
  width: 48px;
  height: 48px;
  display: none; /* Hidden on desktop */
}

@media (max-width: 1024px) {
  #collapse-btn {
    display: flex;
    align-items: center;
    justify-content: center;
  }
}

#collapse-btn i {
  position: absolute; /* Place icons on top of each other */
  font-size: 2rem;
  color: #fff;
  transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Default state: show menu icon, hide close icon */
#collapse-btn .icon-close {
  opacity: 0;
  transform: rotate(-90deg) scale(0.5);
}

/* Active state: hide menu icon, show close icon */
body.mobile-menu-active #collapse-btn .icon-menu {
  opacity: 0;
  transform: rotate(90deg) scale(0.5);
}

body.mobile-menu-active #collapse-btn .icon-close {
  opacity: 1;
  transform: rotate(0deg) scale(1);
}

/* Animate nav items when menu opens */
.collapsible-header.show #collapsed-header-items .header-links,
.collapsible-header.show #collapsed-header-items .waitlist-button {
  animation: fadeInUp 0.6s ease-out forwards;
}

.collapsible-header.show #collapsed-header-items .header-links:nth-child(1) {
  animation-delay: 0.1s;
}

.collapsible-header.show #collapsed-header-items .header-links:nth-child(2) {
  animation-delay: 0.2s;
}

.collapsible-header.show #collapsed-header-items .header-links:nth-child(3) {
  animation-delay: 0.3s;
}

.collapsible-header.show #collapsed-header-items .waitlist-button {
  animation-delay: 0.4s;
}

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

/* ========== GLOBAL MOBILE NAVIGATION SYSTEM ========== */

/* 1. Body State: Controls everything when the menu is active */
body.mobile-menu-active {
  overflow: hidden; /* Prevent background scroll */
}

/* 2. Menu Overlay: Full-screen, glass effect */
.collapsible-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100dvh;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(25px) saturate(180%);
  -webkit-backdrop-filter: blur(25px) saturate(180%);
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.4s;
  display: flex;
  align-items: center;
  justify-content: center;
}

body.mobile-menu-active .collapsible-header {
  opacity: 1;
  visibility: visible;
}

/* 3. Navigation Links Container */
#mobile-menu-overlay nav {
  text-align: center;
}

/* 4. Individual Links: Clean, with underline hover effect */
#mobile-menu-overlay .header-links {
  display: block;
  padding: 1rem;
  margin: 0.5rem 0;
  font-size: 1.5rem;
  font-weight: 500;
  color: #fff;
  text-decoration: none;
  position: relative;
  transition: color 0.3s ease;
  opacity: 0;
  transform: translateY(15px);
  animation-fill-mode: forwards;
}

#mobile-menu-overlay .header-links::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0%;
  height: 2px;
  background-color: var(--color-primary-400);
  transition: width 0.3s ease;
}

#mobile-menu-overlay .header-links:hover,
#mobile-menu-overlay .header-links:focus {
  color: var(--color-primary-300);
}

#mobile-menu-overlay .header-links:hover::after,
#mobile-menu-overlay .header-links:focus::after {
  width: 50%;
}

/* 5. Waitlist Button */
#mobile-menu-overlay .waitlist-button {
  display: inline-flex;
  margin-top: 1.5rem;
  padding: 0.75rem 2rem;
  background: var(--color-primary-500);
  color: #fff;
  border-radius: 9999px;
  font-size: 1.1rem;
  font-weight: 600;
  transition: all 0.3s ease;
  opacity: 0;
  transform: translateY(15px);
  animation-fill-mode: forwards;
}

#mobile-menu-overlay .waitlist-button:hover {
  background: var(--color-primary-400);
  transform: translateY(10px) scale(1.05); /* Combined transform */
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

/* 6. Staggered Animation for Menu Items */
@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

body.mobile-menu-active #mobile-menu-overlay .header-links,
body.mobile-menu-active #mobile-menu-overlay .waitlist-button {
  animation: fadeInUp 0.5s ease forwards;
}

body.mobile-menu-active #mobile-menu-overlay .header-links:nth-child(1) {
  animation-delay: 0.1s;
}
body.mobile-menu-active #mobile-menu-overlay .header-links:nth-child(2) {
  animation-delay: 0.2s;
}
body.mobile-menu-active #mobile-menu-overlay .header-links:nth-child(3) {
  animation-delay: 0.3s;
}
body.mobile-menu-active #mobile-menu-overlay .waitlist-button {
  animation-delay: 0.4s;
}

/* ========== MOBILE & RESPONSIVE STYLES ========== */

@media (max-width: 768px) {
  /* --- Global Typography --- */

  /* Make the main hero heading larger and more impactful on mobile */
  #hero-heading {
    font-size: 2.6rem; /* ~45px */
    line-height: 1.3;
    padding: 0.5rem 0; /* Add more padding on mobile */
  }

  /* Increase size for sub-headings and key text */
  h2,
  .sm\:tw-text-4xl {
    font-size: 2.1rem;
    line-height: 1.2;
  }

  p,
  .tw-text-lg,
  .sm\:tw-text-xl {
    font-size: 1.05rem; /* ~17px for better readability */
    line-height: 1.65;
  }

  /* --- Hero Section Buttons --- */

  /* Make buttons thumb-sized and easy to tap */
  #hero-section .waitlist-button,
  #hero-section .btn-secondary {
    padding: 0.9rem 1.25rem;
    font-size: 0.95rem;
    min-width: 140px;
    text-align: center;
    flex-shrink: 0;
  }

  /* --- Feature Card Alignment --- */

  /* Allow feature cards to grow with their content to prevent overflow */
  #more-features .feature-card {
    height: auto;
    min-height: 15rem; /* Set a min-height for alignment */
  }

  /* --- Footer Adjustments --- */
  .footer {
    text-align: center; /* Center footer text on mobile */
  }

  .footer .tw-grid {
    gap: 2.5rem; /* Increase gap for better spacing */
  }
}

/* ========== GLOBAL TYPOGRAPHY & LAYOUT ========== */

/* --- Section Spacing & Separators --- */
main > section {
  padding-top: 6rem !important; /* Override Tailwind padding with !important */
  padding-bottom: 6rem !important;
  position: relative;
}

/* Subtle separator line for all sections except the hero section */
main > section:not(#hero-section)::before {
  content: "";
  position: absolute;
  top: 2rem; /* Position divider with consistent offset */
  left: 50%;
  transform: translateX(-50%);
  width: 80%;
  max-width: 1000px;
  height: 1px;
  background: linear-gradient(
    to right,
    transparent,
    rgba(255, 255, 255, 0.1),
    transparent
  );
  transition: background 0.6s ease-in-out;
}

/* Change divider color when background is white */
body.white-background main > section:not(#hero-section)::before {
  background: linear-gradient(
    to right,
    transparent,
    rgba(0, 0, 0, 0.1),
    transparent
  );
}

/* --- Consistent Heading Margins --- */
.section-header {
  margin-bottom: 3rem !important; /* Consistent bottom spacing - override Tailwind */
  margin-top: 0 !important; /* Remove top margin - let section padding handle spacing */
}

.section-header h2 {
  margin-bottom: 0.5rem !important; /* Override any Tailwind margin classes */
}

/* Mobile adjustments for section spacing */
@media (max-width: 768px) {
  main > section {
    padding-top: 4rem !important; /* Reduced padding on mobile for better proportions */
    padding-bottom: 4rem !important;
  }

  main > section:not(#hero-section)::before {
    top: 1.5rem; /* Adjust divider position for mobile */
  }

  .section-header {
    margin-bottom: 2rem !important; /* Slightly reduced spacing on mobile */
  }
}

/* ========== ENHANCED "MORE FEATURES" CARDS ========== */

#more-features .feature-card {
  text-align: center;
  transition: all 0.3s ease;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(168, 85, 247, 0.15);
  display: flex;
  flex-direction: column;
  justify-content: flex-start; /* Align content to the top */
  padding: 2rem 1.5rem;
  /* Default glow effect */
  box-shadow: 0 0 15px rgba(168, 85, 247, 0.08),
    0 0 25px rgba(168, 85, 247, 0.05);
}

/* On hover, intensify the glowing effect */
#more-features .feature-card:hover {
  transform: translateY(-8px);
  border-color: rgba(168, 85, 247, 0.4);
  box-shadow: 0 0 25px rgba(168, 85, 247, 0.15),
    0 0 40px rgba(168, 85, 247, 0.12), 0 0 60px rgba(168, 85, 247, 0.08);
}

/* Center the content inside the card */
#more-features .feature-card .tw-flex-col {
  align-items: center;
}

/* Make the heading bigger */
#more-features .feature-card h3 {
  font-size: 1.4rem; /* Larger heading */
  font-weight: 600;
  margin-bottom: 0.75rem;
}

/* Style the icon container and the icon itself */
#more-features .feature-card .icon-container {
  margin-bottom: 1.5rem;
  font-size: 2.5rem;
  transition: all 0.3s ease;
}

#more-features .feature-card:hover .icon-container {
  transform: scale(1.1);
}

/* --- Respective Icon Colors with Glow --- */
.icon-primary {
  color: #a855f7;
  text-shadow: 0 0 20px #a855f7;
}
.icon-warning {
  color: #facc15;
  text-shadow: 0 0 20px #facc15;
}
.icon-error {
  color: #f87171;
  text-shadow: 0 0 20px #f87171;
}
.icon-info {
  color: #60a5fa;
  text-shadow: 0 0 20px #60a5fa;
}
.icon-success {
  color: #4ade80;
  text-shadow: 0 0 20px #4ade80;
}

/* ========== SCROLL-BASED BACKGROUND TRANSITION ========== */
body {
  background: var(--bg-primary);
  /* No transition needed - JavaScript handles gradual color change */
}

/* Update header background and make navigation black when background is white */
body.white-background header {
  background: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

body.white-background .header-links {
  color: #ffffff;
}

body.white-background .header-links:hover {
  color: #e5e7eb;
}

body.white-background .waitlist-button {
  background: linear-gradient(135deg, #ffffff, #f8fafc);
  color: #000000;
  border: 1px solid rgba(0, 0, 0, 0.1);
}

/* Update section header text color when background is white */
body.white-background .section-header-glass h2,
body.white-background .section-header-glass span,
body.white-background #features-heading,
body.white-background #more-features-heading {
  color: #000000 !important;
}

/* Ensure Tailwind text-white is overridden on white background */
body.white-background .tw-text-white,
body.white-background h2.tw-text-white,
body.white-background .section-header-glass.tw-text-white,
body.white-background .section-header-glass h2.tw-text-white,
body.white-background #features-heading,
body.white-background #more-features-heading {
  color: #000000 !important;
}

/* ========== SOCIAL MEDIA ICONS WITH GLOW EFFECTS ========== */
.social-icon {
  /* Default glow effect */
  box-shadow: 0 0 10px rgba(168, 85, 247, 0.2), 0 0 20px rgba(168, 85, 247, 0.1);
  border: 1px solid rgba(168, 85, 247, 0.3);
}

.social-icon:hover {
  /* Enhanced glow on hover */
  box-shadow: 0 0 15px rgba(168, 85, 247, 0.4), 0 0 25px rgba(168, 85, 247, 0.3),
    0 0 35px rgba(168, 85, 247, 0.2);
  border: 1px solid rgba(168, 85, 247, 0.5);
  transform: translateY(-2px) scale(1.05);
}

.social-icon i {
  /* Add glow to the icon itself */
  filter: drop-shadow(0 0 3px rgba(168, 85, 247, 0.6));
}

.social-icon:hover i {
  /* Enhanced icon glow on hover */
  filter: drop-shadow(0 0 5px rgba(168, 85, 247, 0.8));
}

/* ========== CLEAN SECTION HEADERS (NO BACKGROUND) ========== */
.section-header-glass {
  /* Clean header without any background effects */
  background: transparent;
  border: none;
  box-shadow: none;
  transition: all 0.3s ease;
}

.section-header-glass h2 {
  margin-bottom: 4px !important;
  color: var(
    --header-text-color,
    #ffffff
  ) !important; /* Use CSS custom property */
  /* Dynamic text shadow for optimal visibility during transition */
  text-shadow: var(
    --header-text-shadow,
    0 0 20px rgba(0, 0, 0, 0.8),
    0 0 40px rgba(0, 0, 0, 0.6)
  );
}

.section-header-glass h2,
.section-header-glass span {
  /* Remove transition - JavaScript handles smooth color change */
  color: var(
    --header-text-color,
    #ffffff
  ) !important; /* Use CSS custom property */
  /* Dynamic text shadow for optimal visibility during transition */
  text-shadow: var(
    --header-text-shadow,
    0 0 20px rgba(0, 0, 0, 0.8),
    0 0 40px rgba(0, 0, 0, 0.6)
  );
}

/* ========== MOBILE FOCUS EFFECTS (INTERSECTION OBSERVER) ========== */
/* Add focus class that applies hover effects on mobile when element is centered */
@media (max-width: 768px) {
  /* More features cards focus effect */
  #more-features .feature-card.mobile-focused {
    transform: translateY(-8px);
    border-color: rgba(168, 85, 247, 0.4);
    box-shadow: 0 0 25px rgba(168, 85, 247, 0.15),
      0 0 40px rgba(168, 85, 247, 0.12), 0 0 60px rgba(168, 85, 247, 0.08);
  }

  #more-features .feature-card.mobile-focused .icon-container {
    transform: scale(1.1);
  }

  /* Dashboard focus effect */
  #dashboard.mobile-focused {
    transform: perspective(1000px) rotateX(0deg) scale(1);
    filter: drop-shadow(0 30px 60px rgba(0, 0, 0, 0.5));
    box-shadow: 0 0 50px rgba(126, 34, 206, 0.3);
  }

  /* Social icons focus effect */
  .social-icon.mobile-focused {
    box-shadow: 0 0 15px rgba(168, 85, 247, 0.4),
      0 0 25px rgba(168, 85, 247, 0.3), 0 0 35px rgba(168, 85, 247, 0.2);
    border: 1px solid rgba(168, 85, 247, 0.5);
    transform: translateY(-2px) scale(1.05);
  }

  .social-icon.mobile-focused i {
    filter: drop-shadow(0 0 5px rgba(168, 85, 247, 0.8));
  }
}

.section-header-glass h2,
.section-header-glass span {
  transition: color 0.6s ease-in-out;
}

/* Legacy section header glow for backwards compatibility */
.section-header-glow {
  /* Default glow border effect */
  box-shadow: 0 0 20px rgba(168, 85, 247, 0.3), 0 0 40px rgba(168, 85, 247, 0.2),
    0 0 60px rgba(168, 85, 247, 0.1);
  border: 1px solid rgba(168, 85, 247, 0.4);
  transition: all 0.3s ease;
}

.section-header-glow:hover {
  /* Enhanced glow on hover */
  box-shadow: 0 0 25px rgba(168, 85, 247, 0.4), 0 0 50px rgba(168, 85, 247, 0.3),
    0 0 80px rgba(168, 85, 247, 0.2);
  border: 1px solid rgba(168, 85, 247, 0.6);
  transform: translateY(-2px);
}

/* ========== EMAIL POPOVER STYLES ========== */
#email-popover {
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

#email-popover .tw-relative {
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(147, 51, 234, 0.3);
  box-shadow: 0 0 30px rgba(126, 34, 206, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

#email-popover input:focus {
  box-shadow: 0 0 0 2px rgba(147, 51, 234, 0.2),
    0 0 10px rgba(147, 51, 234, 0.3);
}

#email-popover button[type="submit"]:hover {
  box-shadow: 0 4px 20px rgba(147, 51, 234, 0.4),
    0 0 20px rgba(147, 51, 234, 0.3);
}

#email-popover button[type="submit"]:focus {
  box-shadow: 0 0 0 3px rgba(147, 51, 234, 0.3),
    0 4px 20px rgba(147, 51, 234, 0.4);
}

#close-popover:hover {
  transform: scale(1.1);
  color: #ffffff;
}

/* Spinner animation for loading state */
@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.tw-animate-spin {
  animation: spin 1s linear infinite;
}

/* Enhanced mobile responsiveness for popover */
@media (max-width: 640px) {
  #email-popover .tw-relative {
    margin: 1rem;
    padding: 2rem 1.5rem;
    max-width: calc(100vw - 2rem);
  }

  #email-popover h3 {
    font-size: 1.5rem;
  }

  #email-popover p {
    font-size: 0.875rem;
  }
}
