/**
 * Ideal Home Appliances - Responsive CSS Stylesheet
 * Handles Breakpoints: 1200px, 991px, 768px, 480px
 * Ensures zero horizontal overflow, fluid touch targets, and accessible interactions.
 */

/* ==========================================================================
   Desktop Narrow / Small Laptops (<= 1200px)
   ========================================================================== */
@media (max-width: 1200px) {
  .category-grid {
    grid-template-columns: repeat(3, 1fr);
  }

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

  .hero-highlights-strip {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .trust-pillars-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }

  .footer-top-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }

  .mega-menu {
    width: 95vw;
    padding: 1.5rem 1.25rem 1rem;
  }

  .mega-menu-grid {
    gap: 1.25rem;
  }

  .mega-menu-col:not(:last-child) {
    padding-right: 1rem;
  }
}

/* ==========================================================================
   Tablets & Mobile Viewports (<= 991px)
   ========================================================================== */
@media (max-width: 991px) {

  /* Announcement bar */
  .announcement-inner {
    flex-direction: column;
    text-align: center;
    gap: 0.25rem;
  }

  .announcement-links {
    display: none;
  }

  /* Header adjustments */
  .header-inner {
    height: 72px;
  }

  .brand-logo-img {
    height: 42px;
  }

  .desktop-nav {
    display: none;
  }

  .mobile-nav-toggle {
    display: flex;
  }

  .header-actions .header-phone-link {
    display: none;
  }

  /* Hero Section */
  .hero-banner-wrapper {
    min-height: 420px;
  }

  .hero-content {
    max-width: 100%;
    padding: 2.5rem 1.75rem;
  }

  /* Hero Slider Section */
  .hero-slide-card {
    min-height: unset;
    height: auto;
    aspect-ratio: 1100 / 600;
  }

  .hero-slider-stage {
    padding: 0 0.5rem;
  }

  .hero-slide-content {
    padding: 2.25rem 1.5rem;
  }

  .hero-slider-nav {
    width: 40px;
    height: 40px;
  }

  .hero-slider-prev {
    left: 10px;
  }

  .hero-slider-next {
    right: 10px;
  }

  /* Category Grid */
  .category-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
  }

  /* Editorial Split Section */
  .editorial-wrapper {
    grid-template-columns: 1fr;
  }

  .editorial-media-side {
    height: 360px;
    min-height: 360px;
    order: -1;
  }

  .editorial-content-side {
    padding: 2.25rem 1.75rem;
  }

  /* Showroom Section */
  .showroom-card-wrapper {
    grid-template-columns: 1fr;
  }

  .showroom-media {
    min-height: 280px;
    order: -1;
  }

  .showroom-info {
    padding: 2.25rem 1.75rem;
  }

  /* Modal Popup */
  .promo-modal-box {
    grid-template-columns: 1fr;
    max-width: 480px;
  }

  .promo-modal-media {
    display: none;
  }

  .promo-modal-content {
    padding: 2.25rem 1.75rem;
  }
}

/* ==========================================================================
   Mobile Phones (<= 768px)
   ========================================================================== */
@media (max-width: 768px) {
  .hero-highlights-strip {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .category-grid {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .product-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .trust-pillars-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .showroom-details-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .footer-top-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: 0.75rem;
  }

  .footer-bottom-links {
    justify-content: center;
  }

  .hero-cta-group {
    flex-direction: column;
    width: 100%;
  }

  .hero-cta-group .btn {
    width: 100%;
  }

  /* Hero Slider Mobile (<= 768px) */
  .hero-slide-card {
    min-height: unset;
    height: auto;
    aspect-ratio: 1100 / 600;
  }

  .hero-swiper {
    padding: 0.25rem 0 2.25rem;
  }

  .hero-slider-pagination {
    bottom: 0.25rem;
  }

  .hero-slider-nav {
    display: none;
  }

  .hero-slide-cta {
    flex-direction: column;
    width: 100%;
  }

  .hero-pill-btn,
  .hero-whatsapp-pill {
    width: 100%;
    justify-content: center;
  }

  .hero-slide-title {
    font-size: 1.85rem;
  }

  .hero-slide-desc {
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
  }

  .floating-actions-container {
    bottom: 1.25rem;
    right: 1.25rem;
    gap: 0.5rem;
  }

  .scroll-to-top-btn {
    width: 44px;
    height: 44px;
  }

  .scroll-to-top-btn svg {
    width: 20px;
    height: 20px;
  }

  .floating-whatsapp {
    width: 45px;
    height: 45px;
  }

  .floating-whatsapp svg {
    width: 25px;
    height: 25px;
  }

  .floating-action-btn {
    width: 42px;
    height: 42px;
  }

  .floating-action-btn svg {
    width: 19px;
    height: 19px;
  }

}

/* ==========================================================================
   Small Mobile Phones (<= 480px)
   ========================================================================== */
@media (max-width: 480px) {
  .header-inner {
    height: 64px;
  }

  .brand-logo-img {
    height: 36px;
  }

  /* Compact WhatsApp Header button on small phones */
  #headerWhatsAppCTA span {
    display: none;
  }

  #headerWhatsAppCTA {
    padding: 0.5rem;
    min-width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
  }

  #headerWhatsAppCTA svg {
    margin: 0;
    width: 20px;
    height: 20px;
  }

  .mobile-drawer {
    width: min(340px, 92vw);
  }

  .btn {
    padding: 0.75rem 1.25rem;
    font-size: 0.95rem;
  }

  .hero-content {
    padding: 2rem 1.25rem;
  }

  .hero-slide-card {
    min-height: unset;
    height: auto;
    aspect-ratio: 1100 / 600;
    border-radius: 12px;
  }

  .hero-slide-content {
    padding: 2.25rem 1rem 3.25rem;
  }

  .hero-slide-title {
    font-size: 1.6rem;
  }

  .editorial-media-side {
    height: 260px;
    min-height: 260px;
  }

  .editorial-actions {
    flex-wrap: wrap;
    gap: 0.75rem;
  }

  .editorial-actions .btn {
    width: 100%;
  }
}

/* ==========================================================================
   Reduced Motion Preferences
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .whatsapp-pulse {
    display: none !important;
  }
}