/* ========================================
   Responsive Footer CSS - Mobile Optimization
   ======================================== */

/* Mobile Layout: 3-Column Compact Grid (≤768px) */
@media (max-width: 450px) {
    .footer-social {
        display: flex;
        flex-wrap: wrap;
        gap: 10px;
        justify-content: center;
    }
}

@media (max-width: 768px) {
    /* Override the inline styles for footer grid */
    .footer-grid {
        display: grid !important;
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 25px !important;
        margin-bottom: 30px !important;
        align-items: start !important;
    }
    
    /* Footer columns styling */
    .footer-column {
        padding: 0 10px;
        text-align: center;
    }
        
    
    /* Adjust heading sizes for mobile - make them similar size */
    .footer-heading {
        font-size: 11px !important;
        margin-bottom: 18px !important;
        letter-spacing: 0.8px !important;
        font-weight: 700 !important;
        white-space: nowrap !important;
    }
    
    /* Center align footer links */
    .footer-links {
        align-items: center !important;
        gap: 12px !important;
    }
    
    /* Adjust link styling for mobile */
    .footer-link {
        font-size: 13px !important;
        padding: 4px 0 !important;
        display: block !important;
        white-space: nowrap !important;
    }
    
    /* Center social icons in a horizontal row */
    .social-icons {
        justify-content: center !important;
        gap: 12px !important;
        flex-wrap: nowrap !important;
    }
    
    /* Adjust social icon sizes */
    .social-link {
        width: 40px !important;
        height: 40px !important;
        font-size: 20px !important;
    }
    
    /* Reduce footer padding for compactness */
    footer {
        padding: 45px 0 25px 0 !important;
        margin-top: 40px !important;
    }
    
    /* Footer container padding */
    footer > div {
        padding: 0 20px !important;
    }
    
    /* Copyright section - spans full width */
    footer > div > div:last-child {
        padding-top: 25px !important;
        margin-top: 15px !important;
        border-top: 1px solid rgba(255,255,255,0.2) !important;
    }
    
    /* Copyright text */
    footer p {
        font-size: 13px !important;
    }
}

/* Extra Small Devices (≤480px) */
@media (max-width: 480px) {
    /* Maintain 3-column layout but with even tighter spacing */
    .footer-grid {
        gap: 15px !important;
        margin-bottom: 25px !important;
    }
    
    .footer-column {
        padding: 0 5px;
    }
    
    /* Further reduce heading size */
    .footer-heading {
        font-size: 9px !important;
        margin-bottom: 15px !important;
        letter-spacing: 0.6px !important;
    }
    
    /* Smaller link text */
    .footer-link {
        font-size: 11px !important;
        padding: 3px 0 !important;
    }
    
    /* Tighter social icon spacing */
    .social-icons {
        gap: 8px !important;
    }
    
    /* Smaller social icons */
    .social-link {
        width: 35px !important;
        height: 35px !important;
        font-size: 18px !important;
    }
    
    /* More compact footer padding */
    footer {
        padding: 35px 0 20px 0 !important;
    }
    
    footer > div {
        padding: 0 10px !important;
    }
    
    /* Copyright section adjustment */
    footer > div > div:last-child {
        padding-top: 20px !important;
        margin-top: 12px !important;
    }
    
    footer p {
        font-size: 11px !important;
    }
}

/* Small Tablets (481px - 600px) - Optimize for medium mobile */
@media (min-width: 481px) and (max-width: 600px) {
    .footer-heading {
        font-size: 10px !important;
    }
    
    .footer-link {
        font-size: 12px !important;
    }
    
    .social-link {
        width: 38px !important;
        height: 38px !important;
    }
}

/* Tablet/Medium Devices (769px - 992px) - Keep Desktop Layout */
@media (min-width: 769px) and (max-width: 992px) {
    .footer-grid {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 40px !important;
    }
    
    .footer-heading {
        font-size: 15px !important;
    }
    
    .footer-link {
        font-size: 14px !important;
    }
}

/* Desktop - Maintain Original Layout (>992px) */
@media (min-width: 993px) {
    /* Desktop keeps the original inline styles - no overrides needed */
}

/* Smooth Transitions */
.footer-grid,
.footer-column,
.footer-links,
.social-icons {
    transition: all 0.3s ease;
}

/* Disable hover animations on mobile for better touch experience */
@media (max-width: 768px) {
    .footer-link:hover,
    .footer-link:active {
        padding-left: 0 !important;
        border-bottom-color: transparent !important;
    }
    
    .social-link:hover,
    .social-link:active {
        transform: scale(1.05) !important;
    }
}

/* Ensure grid columns are equal width and aligned at top */
@media (max-width: 768px) {
    .footer-column:nth-child(1),
    .footer-column:nth-child(2),
    .footer-column:nth-child(3) {
        min-height: auto;
        vertical-align: top;
    }
}