/* ===== RESET & VARIABLES - DARK MODE READY ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

/* Light Mode Variables (Default) */
:root {
  --primary: #00A86B;
  --primary-light: #97E971;
  --primary-gradient: linear-gradient(135deg, #00A86B 0%, #97E971 100%);
  --background: #f8fafc;
  --surface: rgba(255, 255, 255, 0.8);
  --surface-heavy: rgba(255, 255, 255, 0.95);
  --text-primary: #1e293b;
  --text-secondary: #475569;
  --text-tertiary: #64748b;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.04), 0 4px 12px rgba(0,0,0,0.02);
  --shadow-md: 0 8px 24px rgba(0,0,0,0.04), 0 12px 32px rgba(0,0,0,0.02);
  --shadow-lg: 0 20px 40px rgba(0,0,0,0.05), 0 32px 64px rgba(0,0,0,0.02);
  --radius-sm: 12px;
  --radius-md: 20px;
  --radius-lg: 32px;
  --blur: blur(20px);
  --spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --hero-gradient-start: #1e293b;
  --hero-gradient-end: #00A86B;
  --body-bg-start: #9ae66e;
  --body-bg-mid: #eaf7e3;
  --body-bg-mid2: #f4fcf1;
  --body-bg-end: #ffffff;
}

/* Dark Mode Variables */
@media (prefers-color-scheme: dark) {
  :root {
    --background: #0f172a;
    --surface: rgba(30, 41, 59, 0.8);
    --surface-heavy: rgba(30, 41, 59, 0.95);
    --text-primary: #f1f5f9;
    --text-secondary: #cbd5e1;
    --text-tertiary: #94a3b8;
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.3), 0 4px 12px rgba(0,0,0,0.2);
    --shadow-md: 0 8px 24px rgba(0,0,0,0.4), 0 12px 32px rgba(0,0,0,0.3);
    --shadow-lg: 0 20px 40px rgba(0,0,0,0.5), 0 32px 64px rgba(0,0,0,0.4);
    --hero-gradient-start: #f1f5f9;
    --hero-gradient-end: #00A86B;
    --body-bg-start: #0a3a2a;
    --body-bg-mid: #0f172a;
    --body-bg-mid2: #0f172a;
    --body-bg-end: #0f172a;
  }
}

/* Force Dark Mode Class */
.dark-mode {
  --background: #0f172a;
  --surface: rgba(30, 41, 59, 0.8);
  --surface-heavy: rgba(30, 41, 59, 0.95);
  --text-primary: #f1f5f9;
  --text-secondary: #cbd5e1;
  --text-tertiary: #94a3b8;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.3), 0 4px 12px rgba(0,0,0,0.2);
  --shadow-md: 0 8px 24px rgba(0,0,0,0.4), 0 12px 32px rgba(0,0,0,0.3);
  --shadow-lg: 0 20px 40px rgba(0,0,0,0.5), 0 32px 64px rgba(0,0,0,0.4);
  --hero-gradient-start: #f1f5f9;
  --hero-gradient-end: #00A86B;
  --body-bg-start: #0a3a2a;
  --body-bg-mid: #0f172a;
  --body-bg-mid2: #0f172a;
  --body-bg-end: #0f172a;
}

/* ===== BASE STYLES ===== */
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: linear-gradient(to bottom, var(--body-bg-start) 0%, var(--body-bg-mid) 40%, var(--body-bg-mid2) 70%, var(--body-bg-end) 100%);
  color: var(--text-primary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  min-height: 100vh;
}

/* iPhone-style blur header */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  padding: 16px 24px;
  background: var(--surface-heavy);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  border-bottom: 1px solid var(--border-light, rgba(0,0,0,0.05));
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
}

.logo-image {
  height: 40px;
  width: auto;
  transition: all 0.3s var(--spring);
}

.logo:hover .logo-image {
  transform: scale(1.05);
  opacity: 0.9;
}

.logo:active .logo-image {
  transform: scale(0.95);
}

.logo-text {
  font-size: 24px;
  font-weight: 700;
  background: var(--primary-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.5px;
}

@media (max-width: 768px) {
  .logo-image {
    height: 32px;
  }
  
  .logo-text {
    font-size: 20px;
  }
}

/* Navigation with iOS-style interactions */
nav {
  display: flex;
  gap: 8px;
}

nav a {
  padding: 10px 18px;
  border-radius: 40px;
  font-weight: 500;
  font-size: 15px;
  color: var(--text-secondary);
  transition: all 0.2s ease;
  text-decoration: none;
}

nav a:hover {
  background: rgba(0,0,0,0.04);
}

@media (prefers-color-scheme: dark) {
  nav a:hover {
    background: rgba(255,255,255,0.08);
  }
}

.dark-mode nav a:hover {
  background: rgba(255,255,255,0.08);
}

nav a.active-link {
  background: var(--primary);
  color: white;
}

/* iPhone-style hamburger */
.hamburger {
  display: none;
  width: 44px;
  height: 44px;
  border: none;
  background: rgba(0,0,0,0.04);
  border-radius: 30px;
  font-size: 20px;
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.hamburger:active {
  background: rgba(0,0,0,0.08);
  transform: scale(0.96);
}

/* ===== HERO SECTION ===== */
.hero {
  padding: 80px 24px 40px;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
  animation: fadeUp 1s var(--spring) forwards;
  opacity: 0;
  transform: translateY(20px);
}

.hero h1 {
  font-size: clamp(32px, 6vw, 52px);
  font-weight: 700;
  letter-spacing: -1px;
  line-height: 1.2;
  margin-bottom: 20px;
  background: linear-gradient(135deg, var(--hero-gradient-start) 0%, var(--hero-gradient-end) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero p {
  font-size: 18px;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ===== CARD GRID ===== */
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  padding: 20px 24px 40px;
  max-width: 1200px;
  margin: 0 auto;
}

/* iPhone-style cards */
.card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 32px 24px;
  box-shadow: var(--shadow-sm);
  transition: all 0.4s var(--spring);
  border: 1px solid var(--border-light, rgba(0,0,0,0.02));
  backdrop-filter: var(--blur);
  opacity: 0;
  transform: translateY(30px);
  position: relative;
  overflow: hidden;
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--primary-gradient);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.card:hover::before {
  opacity: 1;
}

.card.animate {
  opacity: 1;
  transform: translateY(0);
}

.card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: var(--shadow-lg);
}

.card img {
  width: 56px;
  height: 56px;
  margin-bottom: 24px;
  filter: drop-shadow(0 4px 8px rgba(0,168,107,0.2));
}

.card h2 {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--text-primary);
}

.card ul {
  list-style: none;
  margin: 20px 0;
}

.card li {
  padding: 8px 0;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
}

.card li::before {
  content: '✓';
  color: var(--primary);
  font-weight: 600;
  font-size: 16px;
}

.card p {
  color: var(--text-secondary);
  margin: 20px 0;
  font-size: 15px;
  line-height: 1.6;
}

/* iPhone-style buttons */
.btn-primary {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 40px;
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  background: var(--primary);
  color: white;
  transition: all 0.2s ease;
  box-shadow: 0 4px 12px rgba(0,168,107,0.2);
  border: none;
  cursor: pointer;
  margin: 4px;
}

.btn-primary:active {
  transform: scale(0.96);
  box-shadow: 0 2px 6px rgba(0,168,107,0.3);
}

.btn-primary.outline {
  background: transparent;
  color: var(--primary);
  box-shadow: inset 0 0 0 1.5px rgba(0,168,107,0.3);
}

.btn-primary.outline:active {
  background: rgba(0,168,107,0.04);
}

.action-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

/* ===== STATS SECTION ===== */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  padding: 40px 24px 60px;
  max-width: 1000px;
  margin: 0 auto;
}

.stat-card {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 28px 20px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light, rgba(0,0,0,0.02));
  transition: all 0.4s var(--spring);
  opacity: 0;
  transform: scale(0.9);
}

.stat-card.animate {
  opacity: 1;
  transform: scale(1);
}

.stat-card:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: var(--shadow-md);
}

.stat-card img {
  width: 44px;
  height: 44px;
  margin-bottom: 16px;
  filter: drop-shadow(0 4px 8px rgba(0,168,107,0.15));
}

.stat-card h3 {
  font-size: 28px;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 8px;
  letter-spacing: -0.5px;
}

.stat-card p {
  color: var(--text-tertiary);
  font-size: 14px;
  font-weight: 500;
}

/* ===== NEWSLETTER ===== */
.newsletter-section {
  max-width: 800px;
  margin: 40px auto 60px;
  padding: 0 24px;
}

.newsletter-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 48px 40px;
  box-shadow: var(--shadow-md);
  text-align: center;
  border: 1px solid var(--border-light, rgba(0,0,0,0.02));
}

.newsletter-icon {
  width: 64px;
  height: 64px;
  background: rgba(0,168,107,0.1);
  border-radius: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  color: var(--primary);
  font-size: 28px;
}

.newsletter-card h2 {
  font-size: 28px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.newsletter-card p {
  font-size: 16px;
  color: var(--text-secondary);
  margin-bottom: 28px;
}

.newsletter-form {
  display: flex;
  gap: 12px;
  max-width: 500px;
  margin: 0 auto;
}

.newsletter-input {
  flex: 1;
  padding: 16px 20px;
  border: 1.5px solid var(--border-light, rgba(0,0,0,0.08));
  border-radius: 40px;
  font-size: 16px;
  transition: all 0.2s;
  background: var(--background);
  color: var(--text-primary);
}

.newsletter-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(0,168,107,0.1);
}

.newsletter-button {
  padding: 16px 32px;
  background: var(--primary-gradient);
  border: none;
  border-radius: 40px;
  color: white;
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s;
}

.newsletter-button:active {
  transform: scale(0.96);
}

/* ===== FOOTER STYLES - DARK MODE READY ===== */
.ios-footer {
  background: var(--surface);
  padding: 48px 24px 32px;
  border-top: 1px solid var(--border-light, rgba(0,0,0,0.03));
  color: var(--text-tertiary);
  font-size: 14px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

/* App Download Section */
.app-download-section {
  max-width: 800px;
  margin: 0 auto 32px;
}

.app-download-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
  background: var(--primary-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.app-download-subtitle {
  font-size: 16px;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

/* App Badges - iOS style */
.app-badges {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.app-badge {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 12px 24px;
  background: #000;
  border-radius: 14px;
  text-decoration: none;
  transition: all 0.3s var(--spring);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  min-width: 180px;
}

.app-badge:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(0,0,0,0.15);
}

.app-badge:active {
  transform: scale(0.98);
}

/* App Store specific */
.app-badge.app-store {
  background: #000;
}

/* Google Play specific */
.app-badge.google-play {
  background: #1a1a1a;
}

.app-badge-icon {
  font-size: 32px;
  color: white;
}

.app-badge-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.app-badge-small {
  font-size: 10px;
  color: rgba(255,255,255,0.7);
  letter-spacing: 0.5px;
}

.app-badge-large {
  font-size: 18px;
  font-weight: 600;
  color: white;
  letter-spacing: -0.3px;
}

/* QR Code */
.qr-code-container {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 16px;
}

.qr-code {
  width: 48px;
  height: 48px;
  background: var(--background);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  font-size: 24px;
  border: 1px solid var(--border-light, rgba(0,0,0,0.05));
  transition: all 0.3s ease;
}

.qr-code:hover {
  transform: scale(1.05);
  box-shadow: var(--shadow-md);
}

.qr-code-text {
  font-size: 14px;
  color: var(--text-secondary);
  font-weight: 500;
}

/* Divider */
.footer-divider {
  height: 1px;
  background: linear-gradient(90deg, 
    transparent, 
    rgba(0,168,107,0.2), 
    rgba(0,168,107,0.3), 
    rgba(0,168,107,0.2), 
    transparent
  );
  margin: 32px auto;
  max-width: 600px;
}

/* Footer Links */
.footer-links {
  margin-bottom: 24px;
  display: flex;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  font-size: 15px;
  transition: all 0.2s ease;
  padding: 4px 8px;
  border-radius: 20px;
}

.footer-links a:hover {
  color: var(--primary);
  background: rgba(0,168,107,0.05);
}

.footer-links a.active-link {
  background: var(--primary);
  color: white;
}

/* Social Icons */
.social-icons {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-bottom: 24px;
}

.social-icons .social-icon {
  width: 44px;
  height: 44px;
  background: rgba(0,0,0,0.02);
  border-radius: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-size: 18px;
  text-decoration: none;
  transition: all 0.3s var(--spring);
  border: 1px solid var(--border-light, rgba(0,0,0,0.02));
}

.social-icons .social-icon:hover {
  transform: translateY(-4px);
  background: var(--primary);
  color: white;
  box-shadow: 0 8px 16px rgba(0,168,107,0.2);
}

.social-icons .social-icon:active {
  transform: scale(0.92);
}

/* Copyright */
.copyright {
  font-size: 13px;
  color: var(--text-tertiary);
  letter-spacing: 0.3px;
}

/* ===== MOBILE STYLES ===== */
@media (max-width: 768px) {
  header {
    padding: 12px 20px;
  }

  .hamburger {
    display: flex;
    align-items: center;
    justify-content: center;
  }

  nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--surface-heavy);
    backdrop-filter: var(--blur);
    -webkit-backdrop-filter: var(--blur);
    flex-direction: column;
    padding: 8px 16px 20px;
    gap: 4px;
    border-bottom: 1px solid var(--border-light, rgba(0,0,0,0.05));
    transform: translateY(-20px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s var(--spring);
    pointer-events: none;
  }

  nav.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
    pointer-events: all;
  }

  nav a {
    width: 100%;
    text-align: center;
    padding: 14px;
    border-radius: 30px;
  }

  .hero {
    padding: 60px 20px 30px;
  }

  .features {
    grid-template-columns: 1fr;
    padding: 20px;
  }

  .stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    padding: 20px;
  }

  .stat-card {
    padding: 20px 12px;
  }

  .stat-card h3 {
    font-size: 22px;
  }
  
  .app-badge {
    min-width: 140px;
    padding: 10px 16px;
  }
  
  .app-badge-icon {
    font-size: 28px;
  }
  
  .app-badge-large {
    font-size: 16px;
  }
  
  .footer-links {
    gap: 12px;
  }
  
  .footer-links a {
    font-size: 13px;
  }
  
  .social-icons .social-icon {
    width: 40px;
    height: 40px;
    font-size: 16px;
  }
  
  .newsletter-card {
    padding: 32px 24px;
  }
  
  .newsletter-form {
    flex-direction: column;
  }
  
  .newsletter-button {
    width: 100%;
  }
}

/* ===== ANIMATIONS ===== */
@keyframes fadeUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scaleIn {
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* iOS-style haptic feedback simulation */
.btn-primary, .hamburger, nav a, .triggerHaptic {
  touch-action: manipulation;
}

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

/* iPhone-style loading state simulation */
.loading {
  opacity: 0;
  animation: none;
}

/* Prevent text selection on interactive elements */
.btn-primary, nav a, .hamburger {
  user-select: none;
  -webkit-user-select: none;
}

/* Dark mode specific overrides for app badges */
@media (prefers-color-scheme: dark) {
  .app-badge {
    background: #1a1a2e;
  }
  .app-badge.app-store,
  .app-badge.google-play {
    background: #1a1a2e;
  }
}

.dark-mode .app-badge,
.dark-mode .app-badge.app-store,
.dark-mode .app-badge.google-play {
  background: #1a1a2e;
}