/* 
   FOUNDATION FOOTBALL ACADEMY - RESPONSIVE DESIGN SYSTEM
   This file handles all screen sizes to ensure a premium experience on mobile.
*/

/* =============================================
   1. TABLET & SMALL LAPTOPS (Max 1024px)
   ============================================= */
@media (max-width: 1024px) {
    :root {
        --header-height: 70px;
    }

    .navbar-menu {
        gap: 15px;
    }

    .nav-link {
        font-size: 0.8rem;
    }

    .hero-text-champions {
        font-size: 15vw;
    }
}

/* =============================================
   2. MOBILE NAVIGATION BREAKPOINT (Max 900px)
   ============================================= */
@media (max-width: 900px) {
    /* Navbar Visibility */
    .navbar-menu, 
    .nav-divider, 
    .nav-actions .action-btn:not(#mobileToggle),
    .nav-actions .user-profile {
        display: none !important;
    }

    .hamburger {
        display: flex !important;
        flex-direction: column;
        justify-content: space-between;
        width: 30px;
        height: 20px;
        background: transparent;
        border: none;
        cursor: pointer;
        padding: 0;
        z-index: 1100;
    }

    .hamburger span {
        width: 100%;
        height: 3px;
        background-color: currentColor;
        border-radius: 10px;
        transition: all 0.3s cubic-bezier(0.645, 0.045, 0.355, 1);
    }

    /* Hamburger Animation States */
    .hamburger.active span:nth-child(1) {
        transform: translateY(8.5px) rotate(45deg);
    }

    .hamburger.active span:nth-child(2) {
        opacity: 0 !important;
    }

    .hamburger.active span:nth-child(3) {
        transform: translateY(-8.5px) rotate(-45deg);
    }

    /* Mobile Overlay Menu */
    .mobile-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(13, 26, 18, 0.98);
        backdrop-filter: blur(15px);
        -webkit-backdrop-filter: blur(15px);
        z-index: 1050;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 80px 20px;
        gap: 20px;
        transform: translateX(100%);
        transition: transform 0.5s cubic-bezier(0.77, 0, 0.175, 1);
    }

    .mobile-overlay.active {
        transform: translateX(0);
    }

    .mobile-link {
        font-family: var(--font-heading);
        font-size: 2.5rem;
        color: #fff;
        text-transform: uppercase;
        letter-spacing: 2px;
        transition: all 0.3s ease;
        opacity: 0;
        transform: translateY(20px);
    }

    .mobile-overlay.active .mobile-link {
        opacity: 1;
        transform: translateY(0);
    }

    .mobile-link.active {
        color: var(--color-accent);
    }

    /* Dashboard Stacking */
    .metrics-grid, 
    .metrics-row {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 15px;
    }

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

    .dash-header {
        padding: 10px 15px;
    }

    .header-center {
        display: none !important;
    }

    /* Hero Responsive */
    .hero-text-champions {
        font-size: 18vw;
        line-height: 0.9;
    }

    .hero-stats-bar {
        padding: 20px;
        gap: 20px;
        border-radius: 24px;
        margin-bottom: 30px;
    }

    .ticker-val {
        font-size: 1.8rem;
    }

    .ticker-label {
        font-size: 0.6rem;
    }

    .stat-sep {
        height: 20px;
    }

    /* Layout Grids */
    .why-layout {
        grid-template-columns: 1fr;
        gap: 40px;
    }

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

    .ticker-container {
        flex-direction: column;
        gap: 40px;
    }

    .ticker-divider {
        display: none;
    }
}

/* =============================================
   3. SMALL TABLETS & PHONES (Max 768px)
   ============================================= */
@media (max-width: 768px) {
    /* Dashboard Sidebar & Layout */
    body.dashboard-body {
        flex-direction: column;
    }

    .dash-sidebar {
        width: 100% !important;
        height: auto !important;
        position: static !important;
        border-right: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }

    .dash-sidebar.collapsed {
        display: none;
    }

    .sidebar-top {
        padding: 10px 20px;
    }

    .sidebar-menu {
        display: none;
    }

    .dash-main {
        height: auto;
        overflow: visible;
    }

    .dash-content {
        padding: 20px 15px;
    }

    .metrics-grid, 
    .metrics-row {
        grid-template-columns: 1fr !important;
    }

    .header-right {
        gap: 5px;
    }

    .header-icons .icon-btn:not(:last-child) {
        display: none;
    }

    .header-title {
        font-size: 1.1rem;
    }

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

    .hero-text-forging {
        font-size: 1.5rem;
        letter-spacing: 3px;
    }

    .hero-text-onetouch-wrapper {
        font-size: 0.9rem;
        letter-spacing: 3px;
    }

    .hero-stats-bar {
        flex-direction: row;
        justify-content: space-evenly;
        width: 100%;
        max-width: 400px;
        margin: 0 auto 40px;
    }

    .hero-stat:nth-child(n+4), 
    .stat-sep:nth-child(n+3) {
        display: none;
    }

    .hero-ctas {
        flex-direction: column;
        width: 100%;
        max-width: 280px;
        margin: 0 auto;
    }

    .btn {
        width: 100%;
        text-align: center;
        padding: 16px 20px;
    }

    /* Footer Mobile */
    .footer-main {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-links {
        justify-content: center;
        gap: 30px;
    }

    .footer-brand {
        align-items: center;
    }

    .f-logo {
        justify-content: center;
    }

    /* Dashboard Specific Mobile */
    .dash-table-wrapper {
        margin: 0 -15px;
        padding: 0 15px;
    }

    /* Auth Pages */
    .auth-form-area {
        padding: 20px !important;
    }

    .auth-card {
        padding: 30px 20px !important;
    }

    .back-home {
        top: 15px !important;
        left: 15px !important;
        padding: 8px 15px !important;
        font-size: 0.8rem !important;
    }
}

/* =============================================
   4. SMALL PHONES (Max 480px)
   ============================================= */
@media (max-width: 480px) {
    .hero-text-champions {
        font-size: 22vw;
    }

    .hero-stats-bar {
        background: transparent;
        border: none;
        backdrop-filter: none;
    }

    .logo-main {
        font-size: 1.3rem;
    }

    .logo-sub {
        font-size: 0.55rem;
    }

    .marquee-text {
        font-size: 0.75rem;
        padding: 0 30px;
    }

    .navbar {
        padding: 0 20px;
    }

    .section-header {
        margin-bottom: 40px;
    }
}