/* ============================================
   KUESTION - FUTURISTIC DESIGN SYSTEM
   Design Philosophy: Apple + Tesla + MIT Media Lab
   ============================================ */

/* ============================================
   CSS CUSTOM PROPERTIES (Design Tokens)
   ============================================ */

:root {
  /* Brand Colors - Navy Blue Palette */
  --color-primary: #002169;
  --color-primary-dark: #001447;
  --color-primary-light: #003399;
  --color-primary-glow: rgba(0, 33, 105, 0.3);

  /* Accent Colors */
  --color-accent-cyan: #00D4FF;
  --color-accent-electric: #0099FF;
  --color-white: #FFFFFF;
  --color-off-white: #F8F9FA;
  --color-gray-100: #E9ECEF;
  --color-gray-200: #DEE2E6;
  --color-gray-300: #CED4DA;
  --color-gray-600: #6C757D;
  --color-gray-900: #212529;

  /* Gradients */
  --gradient-primary: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-light) 100%);
  --gradient-hero: linear-gradient(135deg, #001447 0%, #002169 50%, #003399 100%);
  --gradient-glow: radial-gradient(circle at 50% 50%, rgba(0, 212, 255, 0.1) 0%, transparent 70%);
  --gradient-glass: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);

  /* Spacing System (8px base) */
  --space-xs: 0.5rem;
  /* 8px */
  --space-sm: 1rem;
  /* 16px */
  --space-md: 1.5rem;
  /* 24px */
  --space-lg: 2rem;
  /* 32px */
  --space-xl: 3rem;
  /* 48px */
  --space-2xl: 4rem;
  /* 64px */
  --space-3xl: 6rem;
  /* 96px */
  --space-4xl: 8rem;
  /* 128px */

  /* Typography Scale */
  --font-family-primary: 'Inter', 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
  --font-family-display: 'Outfit', 'Montserrat', sans-serif;

  --font-size-xs: 0.75rem;
  /* 12px */
  --font-size-sm: 0.875rem;
  /* 14px */
  --font-size-base: 1rem;
  /* 16px */
  --font-size-lg: 1.125rem;
  /* 18px */
  --font-size-xl: 1.25rem;
  /* 20px */
  --font-size-2xl: 1.5rem;
  /* 24px */
  --font-size-3xl: 2rem;
  /* 32px */
  --font-size-4xl: 2.5rem;
  /* 40px */
  --font-size-5xl: 3rem;
  /* 48px */
  --font-size-6xl: 4rem;
  /* 64px */
  --font-size-7xl: 5rem;
  /* 80px */

  /* Font Weights */
  --font-weight-normal: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;
  --font-weight-extrabold: 800;

  /* Shadows & Depth */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  --shadow-glow: 0 0 20px var(--color-primary-glow), 0 0 40px var(--color-primary-glow);
  --shadow-glow-accent: 0 0 20px rgba(0, 212, 255, 0.3), 0 0 40px rgba(0, 212, 255, 0.2);

  /* Glass Morphism */
  --glass-bg: rgba(255, 255, 255, 0.08);
  --glass-border: rgba(255, 255, 255, 0.18);
  --glass-blur: blur(20px);

  /* Border Radius */
  --radius-sm: 0.375rem;
  /* 6px */
  --radius-md: 0.5rem;
  /* 8px */
  --radius-lg: 0.75rem;
  /* 12px */
  --radius-xl: 1rem;
  /* 16px */
  --radius-2xl: 1.5rem;
  /* 24px */
  --radius-full: 9999px;

  /* Animation Timings */
  --duration-fast: 200ms;
  --duration-normal: 300ms;
  --duration-slow: 500ms;
  --duration-slower: 700ms;

  --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-out: cubic-bezier(0, 0, 0.2, 1);
  --ease-in: cubic-bezier(0.4, 0, 1, 1);
  --ease-bounce: cubic-bezier(0.68, -0.55, 0.265, 1.55);

  /* Z-Index Scale */
  --z-base: 1;
  --z-dropdown: 1000;
  --z-sticky: 1020;
  --z-fixed: 1030;
  --z-modal-backdrop: 1040;
  --z-modal: 1050;
  --z-popover: 1060;
  --z-tooltip: 1070;
}

/* ============================================
   GLOBAL RESET & BASE STYLES
   ============================================ */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Mobile Optimization: Remove tap delay */
a,
button,
.btn {
  touch-action: manipulation;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-family-primary);
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-normal);
  line-height: 1.6;
  color: var(--color-gray-900);
  background-color: var(--color-white);
  overflow-x: hidden;
}

/* ============================================
   TYPOGRAPHY
   ============================================ */

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-family-display);
  font-weight: 800;
  /* Increased to Extra Bold */
  line-height: 1.1;
  /* Tighter line height for large text */
  margin-bottom: var(--space-md);
  color: var(--color-primary);
  letter-spacing: -0.02em;
  /* Tighter spacing for modern look */
}

h1 {
  font-size: clamp(3.5rem, 6vw, 5rem);
  /* Significantly larger */
}

h2 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  /* Significantly larger */
}

h3 {
  font-size: clamp(2rem, 4vw, 3rem);
  /* Significantly larger */
}

h4 {
  font-size: var(--font-size-3xl);
}

h5 {
  font-size: var(--font-size-2xl);
}

h6 {
  font-size: var(--font-size-xl);
}

p {
  margin-bottom: var(--space-md);
  color: var(--color-gray-600);
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--duration-fast) var(--ease-out);
}

a:hover {
  color: var(--color-primary-light);
}

/* ============================================
   NAVIGATION
   ============================================ */

.nav-container {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: var(--z-sticky);
  transition: all var(--duration-normal) var(--ease-out);
}

.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-md) var(--space-2xl);
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--glass-border);
}

.nav.scrolled {
  background: rgba(255, 255, 255, 0.98);
  box-shadow: var(--shadow-md);
}

.nav-logo {
  display: flex;
  align-items: center;
  transition: transform var(--duration-fast) var(--ease-out);
  filter: drop-shadow(0 2px 4px rgba(0, 33, 105, 0.1));
}

.nav-logo img {
  height: 60px;
  width: auto;
  display: block;
}

.nav-logo:hover {
  transform: scale(1.05);
  filter: drop-shadow(0 4px 8px rgba(0, 33, 105, 0.2));
}

.nav-menu {
  display: flex;
  gap: var(--space-xl);
  list-style: none;
  align-items: center;
}

.nav-link {
  font-weight: var(--font-weight-medium);
  font-size: var(--font-size-base);
  color: var(--color-gray-900);
  position: relative;
  padding: var(--space-xs) 0;
  transition: color var(--duration-fast) var(--ease-out);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient-primary);
  transition: width var(--duration-normal) var(--ease-out);
}

.nav-link:hover {
  color: var(--color-primary);
}

.nav-link:hover::after {
  width: 100%;
}

.nav-link.active {
  color: var(--color-primary);
}

.nav-link.active::after {
  width: 100%;
}

/* Mobile Menu Toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--space-xs);
}

.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--color-primary);
  transition: all var(--duration-normal) var(--ease-out);
}

/* ============================================
   BUTTONS
   ============================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  padding: var(--space-md) var(--space-xl);
  font-family: var(--font-family-primary);
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-semibold);
  text-align: center;
  border: none;
  border-radius: var(--radius-xl);
  cursor: pointer;
  transition: all var(--duration-normal) var(--ease-out);
  position: relative;
  overflow: hidden;
  text-decoration: none;
}

.btn::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width var(--duration-slow) var(--ease-out),
    height var(--duration-slow) var(--ease-out);
}

.btn:hover::before {
  width: 300px;
  height: 300px;
}

.btn-primary {
  background: var(--gradient-primary);
  color: var(--color-white);
  box-shadow: var(--shadow-md);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-xl), var(--shadow-glow);
}

.btn-secondary {
  background: var(--color-white);
  color: var(--color-primary);
  border: 2px solid var(--color-primary);
}

.btn-secondary:hover {
  background: var(--color-primary);
  color: var(--color-white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-ghost {
  background: transparent;
  color: var(--color-white);
  border: 2px solid var(--color-white);
}

.btn-ghost:hover {
  background: var(--color-white);
  color: var(--color-primary);
  transform: translateY(-2px);
}

.btn-white-shadow {
  background: var(--color-white);
  color: var(--color-primary);
  border: 2px solid var(--color-white);
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
}

.btn-white-shadow:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.6);
  background: var(--color-white);
  color: var(--color-primary);
}

.btn-lg {
  padding: var(--space-lg) var(--space-2xl);
  font-size: var(--font-size-lg);
}

.btn-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  padding: 0;
  border-radius: var(--radius-full);
}

/* ============================================
   HERO SECTION
   ============================================ */

.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  /* Dynamic viewport height for mobile browsers */
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  overflow: hidden;
  padding: 0;
  /* Remove padding to allow full canvas coverage */
  width: 100%;
  /* Mobile optimizations */
  -webkit-overflow-scrolling: touch;
  /* Smooth scrolling on iOS */
}

/* Hero Canvas for Auto-Play Animation */
.hero-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 10;
  opacity: 1;
  /* Mobile optimizations */
  touch-action: pan-y pinch-zoom;
  /* Allow vertical scrolling and pinch zoom */
  -webkit-touch-callout: none;
  /* Disable image save popup on iOS */
  user-select: none;
  /* Prevent text selection on canvas */
  -webkit-user-select: none;
  /* Performance optimizations */
  will-change: auto;
  /* Let browser optimize */
  image-rendering: auto;
  /* Smooth image rendering */
  -webkit-transform: translateZ(0);
  /* Hardware acceleration for iOS */
  transform: translateZ(0);
}

/* Hero Overlay CTA */
.hero-overlay-cta {
  position: absolute;
  bottom: 6rem;
  /* Placed exactly above the scroll indicator (which is at 2rem) */
  left: 42%;
  transform: translateX(-50%);
  z-index: 20;
  animation: fadeInUp 0.8s ease-out 1s both;
  /* Delay appearance slightly */
  width: auto;
  display: flex;
  justify-content: center;
}

.pulsed-btn {
  box-shadow: 0 0 0 0 rgba(0, 33, 105, 0.7);
  animation: pulse-shadow 2s infinite;
  white-space: nowrap;
  padding: 1rem 2rem;
  font-size: 1rem;
}

@keyframes pulse-shadow {
  0% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(0, 33, 105, 0.7);
  }

  70% {
    transform: scale(1.05);
    box-shadow: 0 0 0 10px rgba(0, 33, 105, 0);
  }

  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(0, 33, 105, 0);
  }
}

/* Mobile check: Adjust button position if needed on small screens */
@media (max-width: 768px) {
  .hero-overlay-cta {
    bottom: 18%;
    width: auto;
  }

  .hero-overlay-cta .btn {
    width: auto;
    padding: 0.8rem 1.5rem;
    font-size: 0.95rem;
  }
}

.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  z-index: 20;
  opacity: 0.7;
  transition: opacity 0.3s ease;
  pointer-events: none;
  /* Let clicks pass through */
}

.scroll-text {
  font-size: 0.875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-gray-600);
  /* Dark gray for white bg */
  font-weight: 500;
  opacity: 0.8;
}

.scroll-arrow {
  width: 24px;
  height: 24px;
  border-right: 2px solid var(--color-primary);
  /* Primary blue for white bg */
  border-bottom: 2px solid var(--color-primary);
  /* Primary blue for white bg */
  transform: rotate(45deg);
  animation: bounce 2s infinite;
  opacity: 0.8;
}

@keyframes bounce {

  0%,
  20%,
  50%,
  80%,
  100% {
    transform: translateY(0) rotate(45deg);
  }

  40% {
    transform: translateY(-10px) rotate(45deg);
  }

  60% {
    transform: translateY(-5px) rotate(45deg);
  }
}


.hero-content {
  position: relative;
  z-index: 10;
  max-width: 1000px;
  text-align: center;
  color: var(--color-gray-900);
}

.hero-title {
  color: var(--color-gray-900);
  margin-bottom: var(--space-lg);
  font-weight: 800;
  /* Extra bold */
  font-size: clamp(3.5rem, 6vw, 5.5rem);
  /* Much larger */
  letter-spacing: -0.02em;
  animation: fadeInUp 0.8s var(--ease-out) 0.2s both;
}

.hero-equation-wrapper {
  margin: var(--space-xl) 0 var(--space-md);
}

.hero-equation {
  font-size: clamp(3rem, 10vw, 6rem);
  font-weight: var(--font-weight-extrabold);
  color: var(--color-primary);
  letter-spacing: 0.05em;
  line-height: 1.2;
  animation: fadeInUp 0.8s var(--ease-out) 0.3s both;
  text-shadow: 0 4px 20px rgba(0, 33, 105, 0.15);
  margin-bottom: var(--space-md);
}

.hero-tagline {
  font-size: clamp(1.75rem, 4vw, 3rem);
  font-weight: var(--font-weight-bold);
  color: var(--color-primary);
  margin-bottom: var(--space-md);
  animation: fadeInUp 0.8s var(--ease-out) 0.4s both;
  letter-spacing: -0.01em;
}

.hero-subtitle {
  font-size: clamp(1.25rem, 3vw, 2rem);
  color: var(--color-gray-600);
  margin-bottom: var(--space-lg);
  animation: fadeInUp 0.8s var(--ease-out) 0.45s both;
}

.hero-subtitle .highlight {
  color: var(--color-primary);
  font-weight: var(--font-weight-semibold);
}

.hero-description {
  font-size: clamp(0.95rem, 2vw, 1.125rem);
  color: var(--color-gray-600);
  max-width: 650px;
  margin: 0 auto var(--space-md);
  line-height: 1.7;
  animation: fadeInUp 0.8s var(--ease-out) 0.5s both;
}

.hero-subjects {
  font-size: clamp(1.125rem, 2.5vw, 1.5rem);
  color: var(--color-gray-500);
  font-weight: var(--font-weight-medium);
  margin-bottom: var(--space-2xl);
  animation: fadeInUp 0.8s var(--ease-out) 0.55s both;
  letter-spacing: 0.02em;
}

.hero-cta {
  display: flex;
  gap: var(--space-md);
  justify-content: center;
  flex-wrap: wrap;
  animation: fadeInUp 0.8s var(--ease-out) 0.6s both;
}

/* Geometric Shapes */
.geometric-shape {
  position: absolute;
  opacity: 0.08;
  animation: float 25s ease-in-out infinite;
  z-index: 3;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent-cyan));
  filter: blur(60px);
}

.shape-1 {
  top: 10%;
  left: 10%;
  width: 400px;
  height: 400px;
  animation-delay: 0s;
}

.shape-2 {
  top: 50%;
  right: 10%;
  width: 350px;
  height: 350px;
  animation-delay: 5s;
}

.shape-3 {
  bottom: 10%;
  left: 30%;
  width: 300px;
  height: 300px;
  animation-delay: 10s;
}

/* ============================================
   CARDS & GLASS MORPHISM
   ============================================ */

.card {
  background: var(--color-white);
  border-radius: var(--radius-2xl);
  padding: var(--space-xl);
  box-shadow: var(--shadow-lg);
  transition: all var(--duration-normal) var(--ease-out);
  position: relative;
  overflow: hidden;
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-2xl);
}

.card-glass {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  background-image: var(--gradient-glass);
}

.card-glass:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.28);
}

.card-icon {
  width: 64px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient-primary);
  border-radius: var(--radius-xl);
  margin: 0 auto var(--space-md);
  /* Centered horizontally */
  font-size: var(--font-size-3xl);
  color: var(--color-white);
  box-shadow: var(--shadow-glow);
}

.card-title {
  font-size: var(--font-size-2xl);
  margin-bottom: var(--space-sm);
  color: var(--color-primary);
}

.card-description {
  color: var(--color-gray-600);
  line-height: 1.7;
}

/* ============================================
   SECTIONS
   ============================================ */

.section {
  padding: var(--space-4xl) var(--space-lg);
  position: relative;
}

.section-dark {
  background: var(--color-primary);
  color: var(--color-white);
}

.section-dark h2,
.section-dark h3,
.section-dark .card-title {
  color: var(--color-white);
}

.section-dark p,
.section-dark .card-description {
  color: var(--color-off-white);
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.section-header {
  text-align: center;
  margin-bottom: var(--space-3xl);
}

.section-title {
  font-size: clamp(3rem, 5vw, 4.5rem);
  /* Significantly larger */
  font-weight: 800;
  /* Extra bold */
  margin-bottom: var(--space-md);
  letter-spacing: -0.02em;
}

.section-subtitle {
  font-size: var(--font-size-lg);
  color: var(--color-gray-600);
  max-width: 700px;
  margin: 0 auto;
}

.section-dark .section-subtitle {
  color: var(--color-off-white);
}

/* ============================================
   GRIDS
   ============================================ */

.grid {
  display: grid;
  gap: var(--space-xl);
}

.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.grid-4 {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

/* ============================================
   FOOTER
   ============================================ */

.footer {
  background: var(--color-primary-dark);
  color: var(--color-white);
  padding: var(--space-3xl) var(--space-lg) var(--space-lg);
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--space-2xl);
  max-width: 1200px;
  margin: 0 auto var(--space-2xl);
}

.footer-section h4 {
  color: var(--color-white);
  margin-bottom: var(--space-md);
}

.footer-section p,
.footer-section a {
  color: var(--color-gray-200);
  margin-bottom: var(--space-sm);
}

.footer-section a:hover {
  color: var(--color-accent-cyan);
}

.footer-bottom {
  text-align: center;
  padding-top: var(--space-lg);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--color-gray-300);
}

/* ============================================
   ANIMATIONS
   ============================================ */

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes float {

  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }

  25% {
    transform: translateY(-20px) rotate(5deg);
  }

  50% {
    transform: translateY(-10px) rotate(-5deg);
  }

  75% {
    transform: translateY(-30px) rotate(3deg);
  }
}

@keyframes pulse {

  0%,
  100% {
    opacity: 0.5;
  }

  50% {
    opacity: 0.8;
  }
}

@keyframes shimmer {
  0% {
    background-position: -1000px 0;
  }

  100% {
    background-position: 1000px 0;
  }
}

/* Scroll Reveal Animation */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all var(--duration-slower) var(--ease-out);
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 1200px) {
  :root {
    --space-4xl: 6rem;
    --space-3xl: 4rem;
  }
}

@media (max-width: 768px) {
  .nav {
    padding: var(--space-md) var(--space-lg);
  }

  .nav-menu {
    position: fixed;
    top: 70px;
    left: -100%;
    flex-direction: column;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    width: 100%;
    padding: var(--space-xl);
    box-shadow: var(--shadow-lg);
    transition: left var(--duration-normal) var(--ease-out);
    gap: var(--space-md);
  }

  .nav-menu.active {
    left: 0;
  }

  .nav-toggle {
    display: flex;
  }

  .hero {
    padding: var(--space-2xl) var(--space-md);
  }

  .hero-cta {
    flex-direction: column;
    align-items: center;
  }

  .hero {
    padding: 0;
    min-height: 100vh;
    min-height: 100svh;
    /* Small viewport height for mobile */
    height: 100vh;
    height: 100svh;
  }

  .hero-canvas {
    /* Optimize canvas for mobile performance */
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
  }

  .section {
    padding: var(--space-2xl) var(--space-md);
  }

  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  :root {
    --space-3xl: 3rem;
    --space-2xl: 2rem;
  }

  .btn {
    width: 100%;
  }

  .hero {
    /* Force full viewport on very small screens */
    position: relative;
    min-height: 100vh;
    min-height: 100svh;
    max-height: 100vh;
    max-height: 100svh;
  }

  .hero-canvas {
    /* Further optimize for small mobile devices */
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
  }

  .hero-equation {
    font-size: 2.5rem;
  }
}

/* Landscape mobile optimization */
@media (max-width: 900px) and (max-height: 500px) and (orientation: landscape) {
  .hero {
    min-height: 100vh;
    height: 100vh;
  }
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

.text-center {
  text-align: center;
}

.text-left {
  text-align: left;
}

.text-right {
  text-align: right;
}

.mt-sm {
  margin-top: var(--space-sm);
}

.mt-md {
  margin-top: var(--space-md);
}

.mt-lg {
  margin-top: var(--space-lg);
}

.mt-xl {
  margin-top: var(--space-xl);
}

.mb-sm {
  margin-bottom: var(--space-sm);
}

.mb-md {
  margin-bottom: var(--space-md);
}

.mb-lg {
  margin-bottom: var(--space-lg);
}

.mb-xl {
  margin-bottom: var(--space-xl);
}

.flex {
  display: flex;
}

.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.flex-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.gap-sm {
  gap: var(--space-sm);
}

.gap-md {
  gap: var(--space-md);
}

.gap-lg {
  gap: var(--space-lg);
}

.gap-xl {
  gap: var(--space-xl);
}

/* ============================================
   WHATSAPP FLOATING NOTIFICATION
   ============================================ */

.whatsapp-float {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: var(--z-fixed);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  background: #25D366;
  border-radius: var(--radius-lg);
  padding: var(--space-sm) var(--space-md);
  box-shadow: var(--shadow-xl), 0 0 30px rgba(37, 211, 102, 0.3);
  opacity: 0;
  transform: translateY(100px) scale(0.8);
  transition: all 0.4s var(--ease-out);
  pointer-events: none;
}

.whatsapp-float.show {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: all;
  animation: whatsappPulse 2s ease-in-out infinite;
}

.whatsapp-button {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  text-decoration: none;
  color: white;
  font-weight: var(--font-weight-semibold);
  transition: transform 0.2s var(--ease-out);
}

.whatsapp-button:hover {
  transform: scale(1.05);
}

.whatsapp-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: white;
  padding: 2px;
}

.whatsapp-text {
  font-size: var(--font-size-base);
  white-space: nowrap;
}

.whatsapp-close {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: white;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  transition: all 0.2s var(--ease-out);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  flex-shrink: 0;
}

.whatsapp-close:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: rotate(90deg);
}

@keyframes whatsappPulse {

  0%,
  100% {
    box-shadow: var(--shadow-xl), 0 0 30px rgba(37, 211, 102, 0.3);
  }

  50% {
    box-shadow: var(--shadow-2xl), 0 0 40px rgba(37, 211, 102, 0.5);
  }
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .whatsapp-float {
    bottom: 20px;
    right: 20px;
    padding: var(--space-xs) var(--space-sm);
  }

  .whatsapp-text {
    font-size: var(--font-size-sm);
  }

  .whatsapp-icon {
    width: 35px;
    height: 35px;
  }
}

@media (max-width: 480px) {
  .whatsapp-float {
    bottom: 15px;
    right: 15px;
  }

  .whatsapp-text {
    display: none;
  }

  .whatsapp-button {
    padding: 4px;
  }
}