/* ==========================================================================
   SSGI Responsive Media Queries (responsive.css)
   ========================================================================== */

/* Laptop & Large Tablets (<= 1200px) */
@media (max-width: 1200px) {
  .hero-content {
    gap: 2.5rem;
  }
  .lightbox-prev {
    left: 10px;
  }
  .lightbox-next {
    right: 10px;
  }
}

/* Tablets (<= 1024px) */
@media (max-width: 1024px) {
  .main-nav {
    display: none;
  }

  .header-actions {
    display: flex !important;
    align-items: center !important;
    gap: 0.75rem !important;
  }

  /* Admission button stays visible beside the hamburger menu on tablet & mobile */
  .header-actions .btn-enquire,
  .header-actions .btn-admission {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    padding: 0.5rem 1.15rem;
    min-height: 40px;
    white-space: nowrap;
  }

  .hamburger {
    display: flex;
  }

  .hero-content {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-text {
    max-width: 100%;
    margin: 0 auto;
  }

  .hero-badge {
    margin: 0 auto 1.25rem auto;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-features-list {
    justify-content: center;
  }

  .hero-media {
    max-width: 600px;
    margin: 0 auto;
  }

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

  .stat-item:nth-child(2) {
    border-right: none;
  }

  .stat-item:nth-child(1),
  .stat-item:nth-child(2) {
    border-bottom: 1px solid var(--border);
  }

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

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

  .video-thumb {
    height: 380px;
  }
}

/* Medium Tablets & Large Phones (<= 768px) */
@media (max-width: 768px) {
  :root {
    --container-padding: 1rem;
  }

  .section {
    padding: 2.75rem 0;
  }

  .section.bg-light + .section.bg-light {
    padding-top: 0.25rem;
  }

  .section-sm {
    padding: 2rem 0;
  }

  .section-lg {
    padding: 3.75rem 0;
  }

  /* Topbar visible normally on mobile, hidden only when scrolled 25% */
  .topbar.mobile-hidden {
    display: none !important;
  }

  .header-inner,
  .site-header.scrolled .header-inner {
    height: 70px;
  }

  .site-logo {
    margin-left: -0.5rem;
  }

  .site-logo img,
  .site-header.scrolled .site-logo img {
    height: 44px;
  }

  .hero-section {
    padding: 4rem 0 3.5rem 0;
  }

  .hero-image-wrapper img {
    height: 360px;
  }

  .floating-card {
    padding: 0.75rem 1rem;
  }

  .floating-card-1 {
    bottom: 1rem;
    left: 0;
  }

  .floating-card-2 {
    top: 1rem;
    right: 0;
  }

  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }

  .form-grid-2 {
    grid-template-columns: 1fr;
  }

  .form-wrapper {
    padding: 2rem 1.5rem;
  }

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

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

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

  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.25rem;
  }

  .video-thumb {
    height: 300px;
  }

  .play-button {
    width: 64px;
    height: 64px;
  }

  .play-button svg {
    width: 24px;
    height: 24px;
  }
}

/* Small Phones (<= 480px) */
@media (max-width: 480px) {
  .site-logo img {
    height: 38px;
  }

  .header-actions {
    gap: 0.5rem !important;
  }

  .header-actions .btn-enquire,
  .header-actions .btn-admission {
    font-size: 0.8rem !important;
    padding: 0.45rem 0.85rem !important;
    min-height: 38px !important;
  }

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

  .stat-item {
    border-right: none !important;
    border-bottom: 1px solid var(--border);
    padding: 1.5rem 1rem;
  }

  .stat-item:last-child {
    border-bottom: none;
  }

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

  .hero-image-wrapper img {
    height: 280px;
  }

  .floating-card {
    display: none; /* remove floating cards on tiny screens to avoid overlap */
  }

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

  .gallery-filter-wrap {
    gap: 0.5rem;
  }

  .gallery-filter-btn {
    padding: 0.5rem 1.15rem;
    font-size: 0.85rem;
  }

  .lightbox {
    padding: 1rem;
  }

  .lightbox-btn {
    width: 40px;
    height: 40px;
  }

  .lightbox-prev {
    left: 4px;
  }

  .lightbox-next {
    right: 4px;
  }

  .lightbox-close {
    top: -45px;
    right: 0;
  }

  .back-to-top {
    bottom: 5rem;
    right: 1.15rem;
    width: 40px;
    height: 40px;
  }

  .floating-whatsapp {
    bottom: 1.15rem !important;
    right: 1.15rem !important;
    width: 52px !important;
    height: 52px !important;
  }

  .floating-whatsapp .whatsapp-icon {
    width: 30px !important;
    height: 30px !important;
  }
}

/* Extra Small Phones (<= 360px) */
@media (max-width: 360px) {
  html {
    font-size: 14px;
  }

  .header-actions {
    gap: 0.35rem !important;
  }

  .header-actions .btn-enquire,
  .header-actions .btn-admission {
    font-size: 0.75rem !important;
    padding: 0.35rem 0.65rem !important;
    min-height: 36px !important;
  }

  .btn {
    padding: 0.75rem 1.25rem;
  }

  .form-wrapper {
    padding: 1.5rem 1rem;
  }
}
