/* FIT24 - Responsive (Tablet & Mobile) */

/* Tablet (max-width: 1024px) */
@media (max-width: 1024px) {
  .hero-content { padding: 0 30px; }
  .section-title { font-size: clamp(2.5rem, 6vw, 4rem); }
  .about { grid-template-columns: 1fr; gap: 50px; }
  .classes-grid { grid-template-columns: repeat(2, 1fr); }
  .pricing-header { padding: 60px 40px 0; }
  .pricing-body { padding: 0 40px 60px; }
  .pricing-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .hero-title { font-size: clamp(4rem, 10vw, 8rem); }
}

/* Tablet (max-width: 768px) */
@media (max-width: 768px) {
  body { cursor: default; scroll-padding-top: 10px !important; }
  html { scroll-padding-top: 10px !important; }
  a, button, input, select { cursor: pointer; }

  /* Mobile navbar: semi-transparent dark background + blur for contrast */
  .navbar-fit24 {
    padding-left: 1rem; padding-right: 1rem;
    background: rgba(5, 5, 5, 0.88) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
  }
  .navbar-fit24.scrolled {
    background: rgba(5, 5, 5, 0.96) !important;
  }
  .navbar-fit24 .container-fluid { padding-left: 0; padding-right: 0; }
  .navbar-fit24 .navbar-brand { margin-right: 0.5rem; }
  .navbar-fit24 .navbar-brand img { height: 50px !important; }
  /* Hamburger: white border and icon, rounded button */
  .navbar-fit24 .navbar-toggler {
    padding: 0.5rem 0.75rem; margin-left: auto;
    border: 2px solid white;
    background: rgba(0, 0, 0, 0.25);
  }
  .navbar-fit24 .navbar-toggler:hover {
    border-color: white;
    background: rgba(0, 0, 0, 0.4);
  }
  .navbar-fit24 .navbar-toggler-icon {
    filter: brightness(0) invert(1);
  }
  /* Full-width dropdown panel when menu is open – dark background, no overlap with hero */
  .navbar-fit24 .navbar-collapse {
    padding-top: 0; padding-bottom: 0;
    margin-left: -1rem; margin-right: -1rem;
    margin-top: 0.75rem;
    background: transparent;
  }
  .navbar-fit24 .navbar-collapse.show {
    background: rgba(5, 5, 5, 0.98);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 1.25rem 1rem 1.75rem;
    margin-left: -1rem;
    margin-right: -1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5);
  }
  .navbar-fit24 .navbar-collapse .navbar-nav {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }
  .navbar-fit24 .navbar-collapse .nav-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  }
  .navbar-fit24 .navbar-collapse .nav-item:last-of-type { border-bottom: none; }
  /* Vertical spacing for touch-friendly links */
  .navbar-fit24 .nav-link {
    padding: 0.85rem 1rem !important;
    font-size: 0.9rem;
    letter-spacing: 2px;
  }

  .hero {
    min-height: 100svh; min-height: 100dvh;
    padding-top: 120px; padding-bottom: 56px;
    flex-direction: column; align-items: center; justify-content: flex-start;
  }
  /* Tablet: neon FIT24 neatly visible */
  .hero-bg { background-position: 15% 50%; background-size: cover; }
  .hero-content {
    padding: 0 1.5rem; margin-top: 0; max-width: 100%;
    text-align: center; display: flex; flex-direction: column; align-items: center;
  }
  .hero-title {
    font-size: clamp(2.5rem, 11vw, 5rem);
    line-height: 0.95; text-align: center; margin-bottom: 1.25rem;
    letter-spacing: 1px;
  }
  .hero-sub {
    font-size: clamp(0.95rem, 2.5vw, 1rem); max-width: 100%; text-align: center;
    margin-left: auto; margin-right: auto; margin-bottom: 1.75rem;
    line-height: 1.6;
  }
  .hero-actions {
    display: flex; flex-direction: row; flex-wrap: wrap; justify-content: center; align-items: center; gap: 1rem;
  }
  .hero-actions .btn-primary,
  .hero-actions .btn-ghost { max-width: 280px; }
  .hero-stats {
    position: relative; bottom: auto; right: auto; margin-top: 2.5rem; padding: 0 1rem;
    display: flex; flex-wrap: wrap; justify-content: center; align-items: center;
    gap: 2rem; animation: none; opacity: 1;
    width: 100%; max-width: 360px; margin-left: auto; margin-right: auto;
  }
  .stat { text-align: center; }
  .stat-num { font-size: clamp(1.75rem, 5vw, 2.2rem); }
  .stat-label { margin-top: 0.25rem; }
  .scroll-hint { display: none; }
  .ticker { font-size: 8rem; }

  section { padding: 64px 20px; }
  #trainers { padding-top: 100px; padding-bottom: 64px; }
  .section-title { font-size: clamp(2rem, 8vw, 3rem); margin-bottom: 40px; }
  .marquee-track span { font-size: 0.9rem; padding: 0 20px; }

  .about { gap: 40px; }
  .about-visual { aspect-ratio: 4/3; }
  .about-badge { right: 0; }
  .features-grid { grid-template-columns: 1fr; }

  .classes-grid { grid-template-columns: 1fr; }
  .class-card { aspect-ratio: 16/9; }
  .class-card-content { padding: 20px; }
  .class-card-icon { font-size: 1.8rem; margin-bottom: 8px; }
  .class-name { font-size: 1.5rem; }
  .class-desc { font-size: 0.8rem; }

  .pricing-header { padding: 48px 20px 0; }
  .pricing-body { padding: 0 20px 56px; }
  .pricing-grid { grid-template-columns: 1fr; gap: 20px; max-width: 420px; margin-left: auto; margin-right: auto; }
  .plan-card { padding: 28px 24px; min-height: 0; }
  .plan-card .plan-label { margin-bottom: 12px; }
  .plan-card .plan-period { margin-bottom: 20px; }
  .plan-card .plan-features { margin-bottom: 24px; }
  .plan-card .plan-features li { padding: 10px 0; font-size: 0.85rem; }
  .recommended-plan { transform: none; box-shadow: 0 8px 32px rgba(253, 224, 71, 0.25); }
  .plan-card:hover { transform: none; }
  .plan-price { font-size: 4rem; }

  .testi-section { padding: 80px 24px; }
  .testi-carousel-wrapper { padding: 0 56px; }
  .testi-card { flex: 0 0 calc(50% - 12px); min-width: calc(50% - 12px); padding: 28px 24px; }

  .cta-section { padding: 64px 20px; }
  .cta-actions { flex-direction: column; align-items: center; }
  .cta-actions .btn-white { max-width: 280px; width: 100%; text-align: center; }
  .hero-actions .btn-primary { width: auto; min-width: 160px; text-align: center; }
  .hero-actions .btn-ghost { width: auto; }
  .btn-white, .btn-primary { text-align: center; }

  #contact { padding: 64px 20px !important; }
  #contact > div:last-child {
    display: grid !important; grid-template-columns: 1fr !important; gap: 20px !important;
    max-width: 100% !important; margin: 0 !important;
  }
  #contact > div:last-child > a { display: block !important; width: 100% !important; }
  #contact > div:last-child > div,
  #contact > div:last-child > a > div { height: auto !important; padding: 32px 24px !important; }

  footer { padding: 48px 20px 24px; padding-right: 80px; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; margin-bottom: 40px; }
  .footer-brand p { max-width: 100%; }
  .footer-bottom { flex-direction: column; gap: 10px; text-align: center; padding-top: 24px; padding-bottom: 80px; padding-right: 80px; }
  .footer-col ul li { margin-bottom: 18px; }

  .chat-window {
    left: 16px !important;
    right: 16px !important;
    width: auto !important;
    max-width: none !important;
    bottom: 88px !important;
    max-height: calc(100svh - 120px) !important;
    border-radius: 16px !important;
  }
  .chat-window__inner { padding: 20px !important; }
  .chat-toggle { bottom: 20px !important; right: 20px !important; width: 52px !important; height: 52px !important; }
  .chat-toggle i { font-size: 26px !important; }

  #gallery { padding: 64px 15px !important; }
  .arena-header { padding: 0 20px; margin-bottom: 24px; flex-wrap: wrap; gap: 16px; }
  .arena-carousel-wrapper { padding: 0 20px; }
  .arena-nav-btn--side { display: none; }
  .arena-nav-bottom { display: flex; justify-content: center; gap: 16px; padding: 20px 0 0; margin-top: 8px; }
  .arena-nav-btn--bottom { position: static; transform: none; width: auto; min-width: 120px; height: 48px; padding: 0 24px; font-family: 'Poppins', sans-serif; font-weight: 600; font-size: 0.85rem; letter-spacing: 1px; touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
  .arena-nav-btn--bottom i { margin: 0 6px; font-size: 0.8rem; }
  .arena-item { flex: 0 0 260px; width: 260px; min-width: 260px; }
  .gallery-lightbox__close { top: 16px; right: 16px; width: 48px; height: 48px; font-size: 1.2rem; }
  .gallery-lightbox__nav { width: 48px; height: 48px; font-size: 1rem; }
  .gallery-lightbox__nav--prev { left: 12px; }
  .gallery-lightbox__nav--next { right: 12px; }

  .schedule-header { flex-direction: column; align-items: flex-start; gap: 16px; }
  .day-btn { padding: 8px 14px; font-size: 0.65rem; }
  .schedule-table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .schedule-table th, .schedule-table td { padding: 12px 16px; white-space: nowrap; }

  .modal-content { padding: 28px 20px; }
  .modal-title { font-size: 2rem; }
}

/* Small mobile (max-width: 480px) */
@media (max-width: 480px) {
  /* Navbar: same semi-transparent + blur; compact logo and toggle */
  .navbar-fit24 { padding-left: 1rem; padding-right: 1rem; }
  .navbar-fit24 .navbar-brand img { height: 44px !important; }
  .navbar-fit24 .navbar-toggler { padding: 0.45rem 0.6rem; }
  .navbar-fit24 .navbar-collapse.show { padding: 1rem 1rem 1.5rem; }
  .navbar-fit24 .nav-link { padding: 0.8rem 1rem !important; }
  #trainers { padding-top: 96px; padding-bottom: 48px; }

  .hero {
    padding-top: 100px; padding-bottom: 52px;
    min-height: 100svh; min-height: 100dvh;
    justify-content: flex-start;
  }
  /* Mobile: neon FIT24 neatly visible */
  .hero-bg { background-position: 14% 50%; background-size: cover; }
  .hero-content { padding: 0 1.25rem; }
  .hero-title {
    font-size: clamp(2.25rem, 13vw, 3.75rem);
    line-height: 0.95; margin-bottom: 1rem;
    letter-spacing: 0.5px;
  }
  .hero-sub {
    font-size: clamp(0.875rem, 2.5vw, 0.95rem);
    margin-bottom: 1.5rem; line-height: 1.6;
  }
  .hero-actions {
    flex-direction: column; align-items: center; gap: 0.75rem;
    width: 100%; max-width: 280px; margin-left: auto; margin-right: auto;
  }
  .hero-actions .btn-primary,
  .hero-actions .btn-ghost {
    width: 100%; max-width: 260px; padding: 1rem 1.5rem; font-size: 0.75rem;
    text-align: center; display: block;
  }
  .hero-stats {
    flex-direction: row; flex-wrap: wrap; justify-content: center; align-items: center;
    gap: 1.5rem; margin-top: 2rem; padding: 0 1rem;
    max-width: 100%; width: 100%;
  }
  .stat { text-align: center; min-width: 0; }
  .stat-num { font-size: clamp(1.5rem, 7vw, 1.85rem); }
  .stat-label { font-size: 0.6rem; margin-top: 0.2rem; }

  .section-title { font-size: clamp(2rem, 11vw, 2.8rem); }
  .pricing-header { padding: 40px 16px 0; }
  .pricing-body { padding: 0 16px 48px; }
  .pricing-grid { max-width: 100%; gap: 16px; }
  .plan-card { padding: 24px 20px; }
  .plan-card .plan-label { margin-bottom: 10px; }
  .plan-card .plan-period { margin-bottom: 16px; }
  .plan-card .plan-features { margin-bottom: 20px; }
  .plan-card .plan-features li { padding: 8px 0; font-size: 0.82rem; }
  .plan-price { font-size: 3.5rem; }
  .trainer-name { font-size: 1.8rem; }
  .trainer-exp-badge { margin-bottom: 8px; padding: 6px 12px; font-size: 0.9rem; }
  .marquee-track span { font-size: 0.85rem; padding: 0 16px; }
  .arena-carousel-wrapper { padding: 0 16px; }
  .arena-nav-btn--bottom { min-width: 100px; height: 44px; padding: 0 20px; font-size: 0.8rem; }
  .arena-item { flex: 0 0 240px; width: 240px; min-width: 240px; }
  .gallery-lightbox__content { max-width: 96vw; max-height: 88vh; padding: 56px 12px 12px; }
  .gallery-lightbox__close { top: 12px; right: 12px; width: 44px; height: 44px; font-size: 1.1rem; }
  .gallery-lightbox__nav { width: 44px; height: 44px; font-size: 0.95rem; }
  .gallery-lightbox__nav--prev { left: 8px; }
  .gallery-lightbox__nav--next { right: 8px; }
  .testi-section { padding: 64px 16px; }
  .testi-carousel-wrapper { padding: 0 40px; }
  .testi-card { flex: 0 0 calc(100vw - 80px); min-width: calc(100vw - 80px); max-width: 400px; padding: 24px 20px; }
  .testi-carousel-btn { width: 48px; height: 48px; font-size: 1rem; }
}

@media (max-width: 1024px) {
  .trainers-container { padding: 0 24px !important; }
  .trainer-img { aspect-ratio: 4/3; }
}
@media (max-width: 768px) {
  .trainers-container { padding: 0 16px !important; }
  .trainer-img { aspect-ratio: 4/3; }
  .trainer-info { padding: 24px; }
  .trainer-name { font-size: 1.8rem; }
}
@media (max-width: 480px) {
  .trainers-container { padding: 0 12px !important; }
  .trainer-img { aspect-ratio: 1/1; }
  .trainer-info { padding: 20px; }
  .trainer-name { font-size: 1.6rem; }
}
