/* ==============================================================================
   PREM KUTI DARBAR TRUST - RESPONSIVE STYLESHEET
   Comprehensive Support: 320px, 375px, 414px, 768px, 992px, 1200px, 1440px
   ============================================================================== */

/* ------------------------------------------------------------------------------
   1. TABLETS & SMALL LAPTOPS (<= 1100px)
   ------------------------------------------------------------------------------ */
@media screen and (max-width: 1100px) {
  .footer-grid {
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 2.5rem;
  }

  .footer-grid .footer-contact-col {
    grid-column: 1 / -1;
  }

  .contact-layout {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
}

/* ------------------------------------------------------------------------------
   2. TABLETS & MEDIUM SCREENS (<= 992px)
   ------------------------------------------------------------------------------ */
@media screen and (max-width: 992px) {
  :root {
    --header-height: 80px;
  }

  .desktop-nav,
  .header-cta-group .btn {
    display: none;
  }

  .menu-toggle-btn {
    display: flex;
  }

  .section {
    padding: 3.8rem 0;
  }

  .page-hero-banner {
    padding-top: calc(var(--header-height) + 2.5rem);
    padding-bottom: 3rem;
  }

  /* Split feature 2-column rows collapse to single stacked column */
  .feature-split-grid,
  .feature-split-grid.reverse-desktop {
    grid-template-columns: 1fr !important;
    gap: 2.25rem !important;
    margin-bottom: 3.5rem !important;
  }

  .feature-split-grid > * {
    order: initial !important;
  }

  .feature-img-wrap {
    max-width: 100%;
    margin-top: 0.5rem;
  }

  .feature-img-wrap img {
    max-height: 380px;
  }

  .cards-grid-3 {
    grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
    gap: 1.5rem;
  }

  .cards-grid-4 {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
  }

  .stats-banner-wrap {
    padding: 3rem 1.75rem;
  }

  .hero-section {
    padding-top: calc(var(--header-height) + 2rem);
    padding-bottom: 4rem;
  }

  .custom-cursor-dot,
  .custom-cursor-ring {
    display: none !important;
  }

  /* Universal safety override for any inline grids on tablets & phones */
  div[style*="grid-template-columns: 1fr 1fr"],
  div[style*="grid-template-columns:1fr 1fr"],
  div[style*="grid-template-columns: 1fr 1fr 1fr"] {
    grid-template-columns: 1fr !important;
    gap: 2rem !important;
  }
}

/* ------------------------------------------------------------------------------
   3. MOBILE PHONES (<= 768px)
   ------------------------------------------------------------------------------ */
@media screen and (max-width: 768px) {
  .container {
    padding-left: 1.25rem;
    padding-right: 1.25rem;
  }

  .page-hero-banner {
    padding-top: calc(var(--header-height) + 2rem);
    padding-bottom: 2.5rem;
  }

  .page-hero-banner h1 {
    font-size: 1.95rem;
    line-height: 1.25;
  }

  .page-hero-banner p {
    font-size: 1rem !important;
  }

  .hero-title {
    font-size: 2.2rem;
  }

  .hero-description {
    font-size: 1rem;
    margin-bottom: 2rem;
  }

  .hero-btn-group {
    flex-direction: column;
    width: 100%;
    gap: 0.85rem;
  }

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

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

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

  .contact-form-wrap {
    padding: 2rem 1.25rem;
  }

  .contact-info-panel {
    padding: 2rem 1.25rem;
  }

  .cards-grid-4 {
    grid-template-columns: 1fr;
  }

  .events-grid,
  .members-grid,
  .gallery-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .lightbox-modal {
    padding: 1rem;
  }

  .lightbox-img-wrap {
    max-height: 350px;
  }

  .lightbox-caption-wrap {
    padding: 1rem 1.25rem;
  }
}

/* ------------------------------------------------------------------------------
   4. SMALL PHONES (<= 480px)
   ------------------------------------------------------------------------------ */
@media screen and (max-width: 480px) {
  :root {
    --header-height: 72px;
  }

  .brand-title {
    font-size: 0.98rem;
  }

  .brand-subtitle {
    font-size: 0.7rem;
  }

  .brand-emblem {
    width: 36px;
    height: 36px;
  }

  .brand-emblem svg {
    width: 18px;
    height: 18px;
  }

  .section-title {
    font-size: 1.65rem;
  }

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

  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .events-grid {
    grid-template-columns: 1fr;
  }

  .members-grid {
    grid-template-columns: 1fr;
  }

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

  .footer-developer-credit {
    width: 100%;
    max-width: 380px;
    justify-content: center;
    text-align: center;
    flex-wrap: wrap;
    padding: 8px 14px;
    font-size: 0.8rem;
  }

  .footer-bottom-links {
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
  }

  .mobile-nav-drawer {
    max-width: 100%;
  }

  .gold-sparkle-heading {
    font-size: 1.6rem;
    line-height: 1.25;
  }

  .stardust-wrapper {
    padding: 0.25rem 0.5rem;
  }
}

/* ------------------------------------------------------------------------------
   5. ULTRA-COMPACT SCREENS (<= 340px)
   ------------------------------------------------------------------------------ */
@media screen and (max-width: 340px) {
  .hero-title {
    font-size: 1.85rem;
  }

  .card-icon-frame {
    width: 56px;
    height: 56px;
  }

  .islamic-card {
    padding: 1.75rem 1.25rem;
  }

  .brand-title {
    font-size: 0.88rem;
  }
}
