/* ========================================
   Quiqqy - Main Stylesheet
   ======================================== */

/* ----------------------------------------
   Reset & Base Styles
   ---------------------------------------- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Figtree', sans-serif;
  overflow-x: hidden;
}

/* ----------------------------------------
   Scroll Animations
   ---------------------------------------- */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s ease-out;
}

.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

.animate-on-scroll.delay-100 { transition-delay: 0.1s; }
.animate-on-scroll.delay-200 { transition-delay: 0.2s; }
.animate-on-scroll.delay-300 { transition-delay: 0.3s; }
.animate-on-scroll.delay-400 { transition-delay: 0.4s; }

/* Smooth scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.8s ease;
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* ----------------------------------------
   Navigation
   ---------------------------------------- */
.nav-link {
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: #6c42ff;
  transition: width 0.3s ease;
}

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

/* ----------------------------------------
   Buttons
   ---------------------------------------- */
.btn-primary {
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: left 0.5s ease;
}

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

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(108, 66, 255, 0.3);
}

.btn-secondary {
  transition: all 0.3s ease;
}

.btn-secondary:hover {
  background-color: #6c42ff;
  color: white;
  transform: translateY(-2px);
}

/* ----------------------------------------
   Cards
   ---------------------------------------- */
/* Feature Cards */
.feature-card {
  transition: all 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
  border-color: #6c42ff;
}

/* Pricing Cards */
.pricing-card {
  transition: all 0.4s ease;
}

.pricing-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
}

.pricing-card.featured {
  transform: scale(1.02);
}

.pricing-card.featured:hover {
  transform: scale(1.02) translateY(-10px);
}

/* ----------------------------------------
   Image Effects
   ---------------------------------------- */
.image-hover {
  transition: all 0.5s ease;
}

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

/* ----------------------------------------
   Tabs
   ---------------------------------------- */
.tab-btn {
  transition: all 0.3s ease;
  cursor: pointer;
}

.tab-btn.active {
  background-color: #6c42ff;
  color: white;
}

.tab-btn:hover:not(.active) {
  background-color: #e5e5e5;
}

/* Tab content animations */
.tab-content {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.4s ease-out;
}

.tab-content.active {
  opacity: 1;
  transform: translateY(0);
}

.tab-content.hidden {
  display: none;
}

.tab-content.showing {
  display: grid;
}

/* ----------------------------------------
   FAQ Accordion
   ---------------------------------------- */
.faq-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out;
}

.faq-item.active .faq-content {
  max-height: 200px;
}

.faq-icon {
  transition: transform 0.3s ease;
}

.faq-item.active .faq-icon {
  transform: rotate(45deg);
}

/* ----------------------------------------
   Carousel
   ---------------------------------------- */
.carousel-container {
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.carousel-container::-webkit-scrollbar {
  display: none;
}

.carousel-item {
  scroll-snap-align: start;
  flex-shrink: 0;
}

/* ----------------------------------------
   Integration Grid
   ---------------------------------------- */
.integration-item {
  transition: all 0.3s ease;
}

.integration-item:hover {
  transform: scale(1.1);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

/* ----------------------------------------
   Play Button Animation
   ---------------------------------------- */
.play-button {
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(108, 66, 255, 0.4);
  }
  50% {
    transform: scale(1.05);
    box-shadow: 0 0 0 20px rgba(108, 66, 255, 0);
  }
}

/* ----------------------------------------
   Gradient Text
   ---------------------------------------- */
.gradient-text {
  background: linear-gradient(135deg, #6c42ff 0%, #9b7aff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ----------------------------------------
   Stats
   ---------------------------------------- */
.stat-number {
  display: inline-block;
}

/* ----------------------------------------
   Table (Pricing Page)
   ---------------------------------------- */
.table-row {
  transition: background-color 0.2s ease;
}

.table-row:hover {
  background-color: #fafafa;
}

/* Check/X icon animations */
.check-icon,
.x-icon {
  transition: transform 0.2s ease;
}

.table-row:hover .check-icon {
  transform: scale(1.2);
}

/* ----------------------------------------
   AI Reservation Page
   ---------------------------------------- */
/* Voice wave animation */
.voice-wave {
  display: flex;
  align-items: center;
  gap: 3px;
  height: 40px;
}

.voice-wave span {
  width: 4px;
  background: linear-gradient(to top, #6c42ff, #9b7aff);
  border-radius: 2px;
  animation: wave 1s ease-in-out infinite;
}

.voice-wave span:nth-child(1) { animation-delay: 0s; height: 20px; }
.voice-wave span:nth-child(2) { animation-delay: 0.1s; height: 35px; }
.voice-wave span:nth-child(3) { animation-delay: 0.2s; height: 25px; }
.voice-wave span:nth-child(4) { animation-delay: 0.3s; height: 40px; }
.voice-wave span:nth-child(5) { animation-delay: 0.4s; height: 30px; }
.voice-wave span:nth-child(6) { animation-delay: 0.5s; height: 20px; }
.voice-wave span:nth-child(7) { animation-delay: 0.6s; height: 35px; }

@keyframes wave {
  0%, 100% { transform: scaleY(0.5); }
  50% { transform: scaleY(1); }
}

/* Pulse ring for phone icon */
.pulse-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid #6c42ff;
  animation: pulseRing 2s ease-out infinite;
}

@keyframes pulseRing {
  0% { transform: scale(1); opacity: 1; }
  100% { transform: scale(1.5); opacity: 0; }
}

/* Floating phone animation */
.floating-phone {
  animation: floatPhone 4s ease-in-out infinite;
}

@keyframes floatPhone {
  0%, 100% { transform: translateY(0) rotate(-5deg); }
  50% { transform: translateY(-15px) rotate(5deg); }
}

/* Gradient border */
.gradient-border {
  position: relative;
  background: linear-gradient(white, white) padding-box,
              linear-gradient(135deg, #6c42ff, #9b7aff) border-box;
  border: 2px solid transparent;
}

/* Stats counter card (AI Reservation) */
.stat-card {
  background: linear-gradient(135deg, rgba(108, 66, 255, 0.05), rgba(155, 122, 255, 0.1));
}

/* ----------------------------------------
   Product Dropdown Menu
   ---------------------------------------- */
.nav-dropdown {
  position: relative;
}

.nav-dropdown-trigger {
  display: flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}

.nav-dropdown-trigger svg {
  transition: transform 0.3s ease;
}

.nav-dropdown:hover .nav-dropdown-trigger svg {
  transform: rotate(180deg);
}

.nav-dropdown-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  min-width: 720px;
  background: white;
  border-radius: 24px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  padding: 24px;
  margin-top: 16px;
  z-index: 100;
}

.nav-dropdown:hover .nav-dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

/* Dropdown bridge to prevent menu from closing */
.nav-dropdown::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  height: 20px;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.product-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 16px;
  border-radius: 16px;
  transition: all 0.2s ease;
  text-decoration: none;
}

.product-item:hover {
  background: #f5f5f5;
}

.product-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.product-icon svg {
  width: 24px;
  height: 24px;
}

.product-info h4 {
  font-weight: 600;
  color: #222024;
  margin-bottom: 4px;
  font-size: 15px;
}

.product-info p {
  font-size: 13px;
  color: #666;
  line-height: 1.4;
}

.product-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  background: linear-gradient(135deg, #6c42ff, #9b7aff);
  color: white;
  font-size: 10px;
  font-weight: 600;
  border-radius: 4px;
  margin-left: 8px;
  text-transform: uppercase;
}

/* Mobile menu styles */
.mobile-menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 40;
}

.mobile-menu-overlay.active {
  opacity: 1;
  visibility: visible;
}

.mobile-menu {
  position: fixed;
  top: 0;
  right: -100%;
  width: 100%;
  max-width: 400px;
  height: 100%;
  background: white;
  transition: right 0.3s ease;
  z-index: 50;
  overflow-y: auto;
  padding: 24px;
}

.mobile-menu.active {
  right: 0;
}

.mobile-product-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 12px;
  text-decoration: none;
  transition: background 0.2s ease;
}

.mobile-product-item:hover {
  background: #f5f5f5;
}

.mobile-product-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.mobile-product-icon svg {
  width: 20px;
  height: 20px;
}

/* Hamburger menu button */
.hamburger-btn {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  cursor: pointer;
}

.hamburger-btn span {
  width: 24px;
  height: 2px;
  background: #222024;
  transition: all 0.3s ease;
}

@media (max-width: 768px) {
  .hamburger-btn {
    display: flex;
  }

  .nav-dropdown-menu {
    display: none;
  }
}

/* ----------------------------------------
   Integrations Page
   ---------------------------------------- */
.integration-card {
  background: white;
  border-radius: 16px;
  padding: 24px;
  transition: all 0.3s ease;
  border: 1px solid #e5e7eb;
}

.integration-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(108, 66, 255, 0.15);
  border-color: #6c42ff;
}

.integration-logo {
  width: 64px;
  height: 64px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 12px;
  color: white;
  margin-bottom: 16px;
}

.category-badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  border-radius: 50px;
  font-size: 13px;
  font-weight: 600;
}

.category-section {
  display: none;
}

.category-section.active {
  display: block;
}

/* Integrations page tab buttons (override default) */
.integrations-tabs .tab-btn {
  padding: 12px 28px;
  border-radius: 50px;
  font-weight: 600;
  transition: all 0.3s ease;
  cursor: pointer;
  border: 2px solid transparent;
}

.integrations-tabs .tab-btn.active {
  background: #6c42ff;
  color: white;
}

.integrations-tabs .tab-btn:not(.active) {
  background: white;
  color: #222024;
  border-color: #e5e7eb;
}

.integrations-tabs .tab-btn:not(.active):hover {
  border-color: #6c42ff;
  color: #6c42ff;
}

/* ----------------------------------------
   Get Started Page - Forms
   ---------------------------------------- */
.form-input {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  font-size: 16px;
  transition: all 0.2s ease;
  background: white;
}

.form-input:focus {
  outline: none;
  border-color: #6c42ff;
  box-shadow: 0 0 0 4px rgba(108, 66, 255, 0.1);
}

.form-input::placeholder {
  color: #9ca3af;
}

.form-label {
  display: block;
  font-weight: 500;
  color: #222024;
  margin-bottom: 8px;
  font-size: 14px;
}

.form-group {
  margin-bottom: 20px;
}

.checkbox-custom {
  width: 20px;
  height: 20px;
  border: 2px solid #e5e7eb;
  border-radius: 6px;
  appearance: none;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.checkbox-custom:checked {
  background: #6c42ff;
  border-color: #6c42ff;
}

.checkbox-custom:checked::after {
  content: '';
  position: absolute;
  left: 6px;
  top: 2px;
  width: 5px;
  height: 10px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

/* Progress Steps */
.progress-step {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 14px;
  transition: all 0.3s ease;
}

.progress-step.active {
  background: #6c42ff;
  color: white;
}

.progress-step.completed {
  background: #22c55e;
  color: white;
}

.progress-step.inactive {
  background: #e5e7eb;
  color: #9ca3af;
}

.progress-line {
  height: 3px;
  flex: 1;
  background: #e5e7eb;
  margin: 0 8px;
}

.progress-line.active {
  background: #6c42ff;
}

.progress-line.completed {
  background: #22c55e;
}

/* Feature Check List */
.feature-check {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #f3f4f6;
}

.feature-check:last-child {
  border-bottom: none;
}

/* ----------------------------------------
   Quiqqy Drive Page - Bento Grid
   ---------------------------------------- */
.bento-card {
  background: white;
  border-radius: 24px;
  padding: 32px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid rgba(0,0,0,0.05);
  position: relative;
  overflow: hidden;
}

.bento-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 25px 50px -12px rgba(0,0,0,0.1);
}

.bento-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent-color), var(--accent-light));
  opacity: 0;
  transition: opacity 0.3s ease;
}

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

.bento-card .stat-number {
  font-size: 4rem;
  font-weight: 800;
  line-height: 1;
  background: linear-gradient(135deg, var(--accent-color), var(--accent-light));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.icon-wrapper {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  transition: transform 0.3s ease;
}

.bento-card:hover .icon-wrapper {
  transform: scale(1.1) rotate(-5deg);
}

.feature-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 16px;
}

.progress-bar {
  height: 8px;
  background: #e5e7eb;
  border-radius: 4px;
  overflow: hidden;
  margin-top: 16px;
}

.progress-fill {
  height: 100%;
  border-radius: 4px;
  width: 0;
  animation: fillProgress 1.5s ease-out forwards;
}

@keyframes fillProgress {
  to { width: var(--progress); }
}

.float-icon {
  position: absolute;
  opacity: 0.1;
  animation: floatSlow 6s ease-in-out infinite;
}

@keyframes floatSlow {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-10px) rotate(5deg); }
}

.bento-card-dark {
  background: linear-gradient(to bottom right, #16a34a, #15803d) !important;
  border: none !important;
}

.bento-card-dark h3,
.bento-card-dark p,
.bento-card-dark span {
  color: white !important;
  opacity: 1 !important;
}

.bento-card-dark p {
  color: rgba(255, 255, 255, 0.9) !important;
}

/* ----------------------------------------
   AI Builders Page
   ---------------------------------------- */
/* Animated gradient background */
.hero-gradient {
  background: linear-gradient(135deg, #0a0a0f 0%, #1a1a2e 50%, #16213e 100%);
  position: relative;
  overflow: hidden;
}

.hero-gradient::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background:
    radial-gradient(circle at 20% 80%, rgba(108, 66, 255, 0.15) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(0, 212, 255, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 40% 40%, rgba(139, 92, 246, 0.08) 0%, transparent 40%);
  animation: gradientRotate 20s linear infinite;
}

@keyframes gradientRotate {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Grid pattern overlay */
.grid-pattern {
  background-image:
    linear-gradient(rgba(108, 66, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(108, 66, 255, 0.03) 1px, transparent 1px);
  background-size: 60px 60px;
}

/* Glowing border cards */
.glow-card {
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.glow-card:hover {
  border-color: rgba(108, 66, 255, 0.5);
  box-shadow: 0 0 40px rgba(108, 66, 255, 0.15);
  transform: translateY(-4px);
}

/* Terminal style code block */
.terminal {
  background: #0d0d0d;
  border: 1px solid #2a2a2a;
  font-family: 'JetBrains Mono', monospace;
}

.terminal-header {
  background: #1a1a1a;
  border-bottom: 1px solid #2a2a2a;
}

.terminal-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

/* Typing animation for code */
.code-line {
  overflow: hidden;
  white-space: nowrap;
  animation: typeCode 2s steps(40) forwards;
  opacity: 0;
}

.code-line:nth-child(1) { animation-delay: 0.5s; }
.code-line:nth-child(2) { animation-delay: 1.5s; }
.code-line:nth-child(3) { animation-delay: 2.5s; }
.code-line:nth-child(4) { animation-delay: 3.5s; }

@keyframes typeCode {
  0% { width: 0; opacity: 1; }
  100% { width: 100%; opacity: 1; }
}

/* Floating elements */
.float-element {
  animation: floatSmooth 6s ease-in-out infinite;
}

.float-element:nth-child(2) { animation-delay: 1s; }
.float-element:nth-child(3) { animation-delay: 2s; }

@keyframes floatSmooth {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-20px) rotate(3deg); }
}

/* Earnings counter */
.earnings-display {
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 30px rgba(34, 197, 94, 0.5);
}

/* Process timeline */
.timeline-line {
  background: linear-gradient(to bottom, #6c42ff, #00d4ff);
}

/* Benefit cards with gradient borders */
.benefit-card {
  position: relative;
  background: white;
  border-radius: 24px;
  overflow: hidden;
}

.benefit-card::before {
  content: '';
  position: absolute;
  inset: 0;
  padding: 2px;
  background: linear-gradient(135deg, #6c42ff, #00d4ff);
  border-radius: 24px;
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask-composite: exclude;
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  opacity: 0;
  transition: opacity 0.3s ease;
}

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

/* Stats pulse */
.stat-pulse {
  animation: statPulse 2s ease-in-out infinite;
}

@keyframes statPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

/* Scroll reveal animations */
.reveal-up {
  opacity: 0;
  transform: translateY(60px);
  transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-up.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-scale {
  opacity: 0;
  transform: scale(0.9);
  transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-scale.visible {
  opacity: 1;
  transform: scale(1);
}

/* CTA button with animated gradient */
.cta-gradient {
  background: linear-gradient(135deg, #6c42ff, #9b7aff, #00d4ff);
  background-size: 200% 200%;
  animation: gradientShift 3s ease infinite;
}

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

/* ----------------------------------------
   Restaurant Communities Page
   ---------------------------------------- */
/* Warm gradient hero */
.community-hero {
  background: linear-gradient(135deg, #fff7ed 0%, #fef3c7 50%, #fce7f3 100%);
  position: relative;
}

.community-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 30% 70%, rgba(251, 146, 60, 0.15) 0%, transparent 50%),
    radial-gradient(circle at 70% 30%, rgba(236, 72, 153, 0.1) 0%, transparent 50%);
}

/* Organic blob shapes */
.blob {
  border-radius: 42% 58% 70% 30% / 45% 45% 55% 55%;
  animation: morphBlob 8s ease-in-out infinite;
}

.blob-2 {
  border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
  animation: morphBlob 10s ease-in-out infinite reverse;
}

@keyframes morphBlob {
  0%, 100% { border-radius: 42% 58% 70% 30% / 45% 45% 55% 55%; }
  50% { border-radius: 58% 42% 30% 70% / 55% 55% 45% 45%; }
}

/* Community card with warm gradient border */
.community-card {
  background: white;
  border-radius: 24px;
  position: relative;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.community-card::before {
  content: '';
  position: absolute;
  inset: 0;
  padding: 2px;
  background: linear-gradient(135deg, #fb923c, #ec4899);
  border-radius: 24px;
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask-composite: exclude;
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  opacity: 0;
  transition: opacity 0.4s ease;
}

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

.community-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 25px 50px -12px rgba(251, 146, 60, 0.2);
}

/* Connected dots pattern */
.connected-pattern {
  background-image: radial-gradient(circle, #fb923c 1px, transparent 1px);
  background-size: 24px 24px;
}

/* Route animation */
.route-line {
  stroke-dasharray: 1000;
  stroke-dashoffset: 1000;
  animation: drawRoute 3s ease forwards;
}

@keyframes drawRoute {
  to { stroke-dashoffset: 0; }
}

/* Savings counter */
.savings-badge {
  background: linear-gradient(135deg, #22c55e, #16a34a);
  animation: pulseSavings 2s ease-in-out infinite;
}

@keyframes pulseSavings {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

/* Restaurant avatars stack */
.avatar-stack {
  display: flex;
}

.avatar-stack > * {
  margin-left: -12px;
  transition: all 0.3s ease;
}

.avatar-stack > *:first-child {
  margin-left: 0;
}

.avatar-stack:hover > * {
  margin-left: 4px;
}

.avatar-stack > *:first-child:hover {
  margin-left: 0;
}

/* Map visualization */
.map-container {
  background: linear-gradient(135deg, #fef3c7, #fff7ed);
  border-radius: 24px;
  position: relative;
  overflow: hidden;
}

.map-dot {
  width: 12px;
  height: 12px;
  background: #fb923c;
  border-radius: 50%;
  position: absolute;
  animation: mapPulse 2s ease-in-out infinite;
}

.map-dot::after {
  content: '';
  position: absolute;
  inset: -4px;
  border: 2px solid #fb923c;
  border-radius: 50%;
  animation: mapRing 2s ease-in-out infinite;
}

@keyframes mapPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.2); }
}

@keyframes mapRing {
  0% { transform: scale(1); opacity: 1; }
  100% { transform: scale(2); opacity: 0; }
}

/* Stat cards with warm colors */
.warm-stat {
  background: linear-gradient(135deg, rgba(251, 146, 60, 0.1), rgba(236, 72, 153, 0.05));
  border: 1px solid rgba(251, 146, 60, 0.2);
}

/* Feature icons */
.feature-icon-warm {
  background: linear-gradient(135deg, #fed7aa, #fecaca);
}

/* Testimonial cards with photos */
.testimonial-card {
  background: white;
  border-radius: 24px;
  transition: all 0.3s ease;
}

.testimonial-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

/* Subscription model cards */
.subscription-card {
  background: white;
  border: 2px solid #e5e7eb;
  border-radius: 20px;
  transition: all 0.3s ease;
}

.subscription-card:hover {
  border-color: #fb923c;
}

.subscription-card.popular {
  border-color: #fb923c;
  position: relative;
}

.subscription-card.popular::before {
  content: 'Most Popular';
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, #fb923c, #ec4899);
  color: white;
  padding: 4px 16px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}

/* Animated delivery vehicle */
.delivery-vehicle {
  animation: driveAlong 8s linear infinite;
}

@keyframes driveAlong {
  0% { transform: translateX(-100%) rotate(0deg); }
  25% { transform: translateX(100%) rotate(0deg); }
  25.1% { transform: translateX(100%) rotate(180deg); }
  50% { transform: translateX(-100%) rotate(180deg); }
  50.1% { transform: translateX(-100%) rotate(0deg); }
  75% { transform: translateX(100%) rotate(0deg); }
  75.1% { transform: translateX(100%) rotate(180deg); }
  100% { transform: translateX(-100%) rotate(180deg); }
}

/* Reveal animations */
.reveal-left {
  opacity: 0;
  transform: translateX(-60px);
  transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.reveal-right {
  opacity: 0;
  transform: translateX(60px);
  transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-right.visible {
  opacity: 1;
  transform: translateX(0);
}

/* ----------------------------------------
   Horizontal Scrollable Cards
   ---------------------------------------- */
/* Hide scrollbar but keep functionality */
.scrollbar-hide {
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.scrollbar-hide::-webkit-scrollbar {
  display: none;
}

/* Bounce X animation for scroll indicator */
@keyframes bounce-x {
  0%, 100% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(8px);
  }
}

.animate-bounce-x {
  animation: bounce-x 1.5s ease-in-out infinite;
}

/* ----------------------------------------
   Mobile Menu
   ---------------------------------------- */
.mobile-menu {
  position: fixed;
  top: 72px;
  left: 0;
  right: 0;
  bottom: 0;
  height: calc(100vh - 72px);
  height: calc(100dvh - 72px);
  background: white;
  z-index: 40;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-20px);
  transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1),
              visibility 0.3s cubic-bezier(0.4, 0, 0.2, 1),
              transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
}

.mobile-menu.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.mobile-menu-content {
  padding: 1rem 1.5rem 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  min-height: 100%;
  height: auto;
}

.mobile-menu-section {
  border-bottom: 1px solid #f3f4f6;
  padding-bottom: 0.5rem;
  flex-shrink: 0;
}

.mobile-menu-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 1rem 0;
  font-size: 1.125rem;
  font-weight: 600;
  color: #1a1a1a;
  background: none;
  border: none;
  cursor: pointer;
}

.mobile-menu-header svg {
  color: #9ca3af;
}

.mobile-menu-header.active svg {
  transform: rotate(180deg);
}

.mobile-submenu {
  display: none;
  padding-left: 0.5rem;
  padding-bottom: 0.75rem;
}

.mobile-submenu.active {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  animation: slideDown 0.3s ease;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.mobile-menu-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  border-radius: 12px;
  transition: background 0.2s ease;
}

.mobile-menu-item:hover,
.mobile-menu-item:active {
  background: #f9fafb;
}

.mobile-menu-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.mobile-menu-icon svg {
  width: 20px;
  height: 20px;
}

.mobile-menu-item span:nth-child(2) {
  font-weight: 500;
  color: #1a1a1a;
  flex: 1;
}

.mobile-badge {
  font-size: 10px;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
  background: linear-gradient(135deg, #6c42ff, #9b7aff);
  color: white;
}

.mobile-badge-new {
  font-size: 10px;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
  background: linear-gradient(135deg, #22c55e, #16a34a);
  color: white;
}

.mobile-menu-link {
  display: block;
  padding: 1rem 0;
  font-size: 1.125rem;
  font-weight: 600;
  color: #1a1a1a;
  border-bottom: 1px solid #f3f4f6;
  transition: color 0.2s ease;
  flex-shrink: 0;
}

.mobile-menu-link:hover {
  color: #6c42ff;
}

.mobile-menu-cta {
  margin-top: 1.5rem;
  padding-top: 1rem;
  padding-bottom: env(safe-area-inset-bottom, 1rem);
  flex-shrink: 0;
}

/* Prevent body scroll when mobile menu is open */
body.mobile-menu-open {
  overflow: hidden;
  position: fixed;
  width: 100%;
  height: 100%;
}

/* Ensure mobile menu displays on small screens */
@media (max-width: 767px) {
  .mobile-menu {
    display: block;
  }

  .mobile-menu.active {
    display: block;
  }
}

@media (min-width: 768px) {
  .mobile-menu {
    display: none !important;
  }
}
