/* ============================================
   APNA TOUR AND TRAVEL — Mobile-Centric Responsive Styles
   Optimized for modern smartphones, tablets & desktop
   ============================================ */

/* ---------- MOBILE ONLY (< 768px) ---------- */
@media (max-width: 767px) {
  body {
    padding-bottom: calc(76px + var(--safe-bottom));
  }

  .container {
    padding: 0 16px;
  }

  /* Section Spacing */
  .section {
    padding: 44px 0;
  }

  .section-header {
    margin-bottom: 24px !important;
  }

  .section-header h2 {
    font-size: clamp(1.5rem, 5.5vw, 1.85rem) !important;
  }

  .section-header p {
    font-size: 0.88rem !important;
  }

  /* Hero Mobile Styling */
  .hero {
    padding: calc(var(--header-height) + 18px) 16px 36px !important;
    text-align: center;
  }


  .hero h1 {
    font-size: clamp(1.7rem, 6.5vw, 2.2rem) !important;
    line-height: 1.25 !important;
    margin-top: 12px !important;
  }

  .hero p {
    font-size: 0.92rem !important;
    margin-top: 10px !important;
  }

  .hero-buttons {
    flex-direction: column;
    width: 100%;
    gap: 10px !important;
    margin-top: 20px !important;
  }

  .hero-buttons .btn {
    width: 100%;
    justify-content: center;
  }

  .hero-stats {
    gap: 12px !important;
    margin-top: 24px !important;
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
  }

  .stat-item {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-md);
    padding: 12px 8px;
  }

  .stat-item h3 {
    font-size: 1.45rem !important;
  }

  .stat-item p {
    font-size: 0.76rem !important;
    margin-top: 2px !important;
  }

  /* Quick Booking Inline Form on Mobile */
  .booking-card {
    padding: 18px 14px !important;
    border-radius: var(--radius-lg) !important;
  }

  .booking-card form {
    grid-template-columns: 1fr !important;
    gap: 12px !important;
  }

  .booking-card .btn {
    width: 100%;
  }

  /* Responsive Grids on Mobile */
  .services-grid,
  .tours-grid,
  .fare-grid,
  .fleet-grid,
  .testimonials-grid,
  .grid-services {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }

  .grid-fares {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 14px !important;
  }

  .grid-fares .fare-card {
    width: 100% !important;
    max-width: 100% !important;
  }


  /* App-Style Horizontal Swipeable Carousel on Mobile */
  .mobile-carousel {
    display: flex !important;
    overflow-x: auto !important;
    scroll-snap-type: x mandatory !important;
    -webkit-overflow-scrolling: touch !important;
    gap: 14px !important;
    padding: 4px 16px 14px !important;
    margin: 0 -16px !important;
    scrollbar-width: none;
  }

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

  .mobile-carousel > * {
    flex: 0 0 84% !important;
    max-width: 320px !important;
    scroll-snap-align: center !important;
    box-sizing: border-box !important;
  }

  .features-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 10px !important;
  }

  .feature-item {
    padding: 14px 10px !important;
  }

  /* Hide floating elements that collide with bottom dock */
  .whatsapp-float {
    display: none !important; /* Replaced by the native bottom dock WhatsApp button */
  }

  .back-to-top {
    bottom: calc(80px + var(--safe-bottom)) !important;
    right: 14px !important;
    left: auto !important;
    width: 40px !important;
    height: 40px !important;
    font-size: 0.85rem !important;
  }

  /* Footer on Mobile */
  .footer-grid {
    grid-template-columns: 1fr !important;
    gap: 28px !important;
  }

  .footer-about {
    text-align: center;
  }

  .footer-contact-info div {
    justify-content: center;
  }

  .footer-links {
    text-align: center;
  }

  .footer-links ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px 14px;
  }

  .footer-links li {
    margin-bottom: 4px;
  }
}

/* ---------- EXTRA SMALL MOBILE (< 360px) ---------- */
@media (max-width: 359px) {
  .logo-text {
    font-size: 1rem;
  }

  .hero h1 {
    font-size: 1.5rem !important;
  }

  .vehicle-selector {
    grid-template-columns: 1fr !important;
  }

  .bottom-bar-btn {
    font-size: 0.82rem;
    padding: 10px 8px;
  }
}

/* ---------- TABLET (768px to 1023px) ---------- */
@media (min-width: 768px) and (max-width: 1023px) {
  body {
    padding-bottom: 0;
  }

  .mobile-bottom-bar {
    display: none !important;
  }

  .whatsapp-float {
    bottom: 24px;
    right: 20px;
  }

  .back-to-top {
    bottom: 24px;
    left: 20px;
  }

  .services-grid,
  .grid-services {
    grid-template-columns: repeat(2, 1fr) !important;
  }

  .fare-grid,
  .fleet-grid {
    grid-template-columns: repeat(3, 1fr) !important;
  }

  .tours-grid {
    grid-template-columns: repeat(2, 1fr) !important;
  }

  .features-grid {
    grid-template-columns: repeat(3, 1fr) !important;
  }

  .testimonials-grid {
    grid-template-columns: repeat(2, 1fr) !important;
  }

  .footer-grid {
    grid-template-columns: repeat(2, 1fr) !important;
  }

  .booking-modal {
    align-items: center;
  }

  .booking-modal-content {
    border-radius: var(--radius-lg);
    max-height: 85vh;
  }

  .sheet-handle {
    display: none;
  }
}

/* ---------- MOBILE & TABLET (< 1024px) Navigation ---------- */
@media (max-width: 1023px) {
  .nav-menu {
    display: none !important;
  }

  .nav-toggle {
    display: flex !important;
  }

  .nav-mobile-actions {
    display: flex !important;
  }
}

/* ---------- DESKTOP (1024px+) ---------- */
@media (min-width: 1024px) {
  body {
    padding-bottom: 0;
  }

  .container {
    padding: 0 24px;
  }

  .hero {
    padding: calc(var(--header-height) + 60px) 24px 80px;
  }

  .hero h1 {
    font-size: 3.2rem;
  }

  .section {
    padding: 70px 0;
  }

  .section-header h2 {
    font-size: 2.4rem;
  }

  /* Desktop Nav */
  .nav-menu {
    display: flex !important;
    position: static;
    flex-direction: row;
    background: none;
    box-shadow: none;
    padding: 0;
    height: auto;
    overflow: visible;
  }

  .nav-toggle,
  .nav-mobile-actions,
  .nav-drawer,
  .drawer-backdrop,
  .mobile-bottom-bar,
  .sheet-handle,
  .carousel-dots {
    display: none !important;
  }

  .whatsapp-float {
    bottom: 24px;
    right: 24px;
    display: flex !important;
  }

  .back-to-top {
    bottom: 24px;
    left: 24px;
  }

  /* Desktop Grids */
  .services-grid,
  .grid-services {
    grid-template-columns: repeat(4, 1fr) !important;
  }

  .fare-grid,
  .fleet-grid,
  .mobile-carousel {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 24px !important;
    overflow: visible !important;
    padding: 0 !important;
    margin: 0 !important;
  }

  .mobile-carousel > * {
    flex: none !important;
    max-width: none !important;
  }

  .tours-grid {
    grid-template-columns: repeat(3, 1fr) !important;
  }

  .features-grid {
    grid-template-columns: repeat(3, 1fr) !important;
  }

  .testimonials-grid {
    grid-template-columns: repeat(3, 1fr) !important;
  }

  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr 1fr !important;
  }

  .booking-modal {
    align-items: center;
  }

  .booking-modal-content {
    border-radius: var(--radius-lg);
    max-height: 85vh;
  }

  .booking-buttons {
    flex-direction: row;
  }
}

/* ---------- PRINT STYLES ---------- */
@media print {
  .navbar, .footer, .whatsapp-float, .back-to-top,
  .mobile-bottom-bar, .booking-modal, .cta-section,
  .nav-drawer, .drawer-backdrop {
    display: none !important;
  }
  body { padding: 0; color: #000; }
  .hero { min-height: auto; padding: 40px 20px; }
}
