/* ============================================
   MOBILE FOOTER - CONTACT US SECTION OPTIMIZATION
   Mobile Only (max-width: 767px)
   Desktop/Tablet: UNCHANGED
   ============================================ */

@media (max-width: 767px) {
    
    /* ============================================
       FOOTER SPACING REDUCTION
       ============================================ */
    
    /* Reduce footer top padding */
    footer {
        padding-top: clamp(25px, 5vw, 35px) !important;
        padding-bottom: clamp(15px, 3vw, 20px) !important;
        margin-top: clamp(25px, 5vw, 35px) !important;
    }
    
    /* Reduce footer grid spacing */
    .footer-grid {
        padding-bottom: clamp(15px, 3vw, 20px) !important;
        gap: clamp(20px, 4vw, 25px) !important;
    }
    
    /* Reduce footer column spacing */
    .footer-col {
        margin-bottom: clamp(20px, 4vw, 25px) !important;
        padding-bottom: clamp(15px, 3vw, 20px) !important;
    }
    
    /* Reduce footer column heading spacing */
    .footer-col h3 {
        margin-bottom: clamp(12px, 2.5vw, 16px) !important;
        padding-bottom: clamp(6px, 1.5vw, 8px) !important;
        font-size: clamp(16px, 4vw, 18px) !important;
    }
    
    /* ============================================
       CONTACT US SECTION - ORGANIZATION
       ============================================ */
    
    /* Contact Us Column - Compact Layout (Last Column) */
    .footer-col:last-child {
        width: 100% !important;
        margin-bottom: clamp(15px, 3vw, 20px) !important;
    }
    
    /* Contact Us Heading */
    .footer-col:last-child h3 {
        font-size: clamp(17px, 4.2vw, 19px) !important;
        margin-bottom: clamp(10px, 2vw, 14px) !important;
        text-align: center;
        width: 100%;
    }
    
    /* Contact Us List - Organized Layout */
    .footer-col:last-child ul,
    .footer-col:last-child .contact-list {
        list-style: none;
        padding: 0;
        margin: 0;
        display: flex;
        flex-direction: column;
        gap: clamp(8px, 1.8vw, 12px) !important;
    }
    
    /* Contact Us List Items - Compact */
    .footer-col:last-child li,
    .footer-col:last-child .contact-list li {
        margin-bottom: 0 !important;
        padding-bottom: clamp(6px, 1.2vw, 8px) !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
        display: flex;
        align-items: flex-start;
        gap: clamp(8px, 2vw, 12px);
        font-size: clamp(13px, 3.2vw, 14px) !important;
        line-height: 1.5 !important;
    }
    
    /* Contact Us Icons - Smaller, Aligned */
    .footer-col:last-child li i,
    .footer-col:last-child .contact-list li i {
        font-size: clamp(14px, 3.5vw, 16px) !important;
        width: clamp(18px, 4.5vw, 22px) !important;
        min-width: clamp(18px, 4.5vw, 22px) !important;
        text-align: center;
        color: var(--primary-red, #c62828) !important;
        margin-top: 2px;
        flex-shrink: 0;
    }
    
    /* Contact Us Text - Organized */
    .footer-col:last-child li span,
    .footer-col:last-child li a,
    .footer-col:last-child .contact-list li span,
    .footer-col:last-child .contact-list li a {
        flex: 1;
        word-wrap: break-word;
        overflow-wrap: break-word;
        color: #aaa;
        text-decoration: none;
    }
    
    /* Contact Us Links - Touch Friendly */
    .footer-col:last-child li a,
    .footer-col:last-child .contact-list li a {
        min-height: 44px;
        display: flex;
        align-items: center;
        padding: clamp(4px, 1vw, 6px) 0;
    }
    
    /* Contact Us Links Hover */
    .footer-col:last-child li a:hover,
    .footer-col:last-child .contact-list li a:hover {
        color: var(--primary-red, #c62828) !important;
        padding-left: clamp(5px, 1.2vw, 8px);
        transition: all 0.3s ease;
    }
    
    /* ============================================
       CONTACT US - SPECIFIC ITEMS ORGANIZATION
       ============================================ */
    
    /* Address - Multi-line Support */
    .footer-col:last-child li:has(i.fa-map-marker-alt),
    .footer-col:last-child li:has(i.fa-map-marker),
    .footer-col:last-child .contact-list li:has(i.fa-map-marker-alt),
    .footer-col:last-child .contact-list li:has(i.fa-map-marker) {
        flex-direction: column;
        align-items: flex-start;
        gap: clamp(6px, 1.5vw, 8px);
    }
    
    .footer-col:last-child li:has(i.fa-map-marker-alt) i,
    .footer-col:last-child li:has(i.fa-map-marker) i,
    .footer-col:last-child .contact-list li:has(i.fa-map-marker-alt) i,
    .footer-col:last-child .contact-list li:has(i.fa-map-marker) i {
        align-self: flex-start;
        margin-top: 4px;
    }
    
    .footer-col:last-child li:has(i.fa-map-marker-alt) span,
    .footer-col:last-child li:has(i.fa-map-marker-alt) a,
    .footer-col:last-child li:has(i.fa-map-marker) span,
    .footer-col:last-child li:has(i.fa-map-marker) a,
    .footer-col:last-child .contact-list li:has(i.fa-map-marker-alt) span,
    .footer-col:last-child .contact-list li:has(i.fa-map-marker-alt) a,
    .footer-col:last-child .contact-list li:has(i.fa-map-marker) span,
    .footer-col:last-child .contact-list li:has(i.fa-map-marker) a {
        width: 100%;
        line-height: 1.6;
    }
    
    /* Phone - Multiple numbers support - Single Line */
    .footer-col:last-child li:has(i.fa-phone-alt),
    .footer-col:last-child li:has(i.fa-phone),
    .footer-col:last-child .contact-list li:has(i.fa-phone-alt),
    .footer-col:last-child .contact-list li:has(i.fa-phone) {
        flex-direction: row !important;
        align-items: center !important;
        flex-wrap: nowrap !important;
        gap: clamp(8px, 2vw, 12px) !important;
    }
    
    /* Phone Numbers - Single Line, compact (no stretch) - 2 spaces between numbers */
    .footer-col:last-child li .phone-numbers,
    .footer-col:last-child .contact-list li .phone-numbers {
        display: inline-flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        gap: 0 !important;
        align-items: center !important;
        justify-content: flex-start !important;
        width: auto !important;
    }
    
    .footer-col:last-child li .phone-numbers a,
    .footer-col:last-child .contact-list li .phone-numbers a {
        flex: 0 0 auto !important;
        display: inline-flex !important;
        align-items: center !important;
        white-space: nowrap !important;
        margin: 0 !important;
        margin-right: 0 !important;
        font-size: clamp(13px, 3.2vw, 14px) !important;
        padding: 0 !important;
        min-height: 28px !important;
        text-decoration: none !important;
        color: #aaa !important;
        border-radius: 4px !important;
        transition: all 0.3s ease !important;
    }
    
    .footer-col:last-child li .phone-numbers a:hover,
    .footer-col:last-child .contact-list li .phone-numbers a:hover {
        color: var(--primary-red, #c62828) !important;
        background: rgba(198, 40, 40, 0.1) !important;
    }
    
    .footer-col:last-child li .phone-sep,
    .footer-col:last-child .contact-list li .phone-sep {
        margin: 0 0.25em !important;
        padding: 0 !important;
        flex-shrink: 0 !important;
    }
    
    /* Phone Icon - No wrap */
    .footer-col:last-child li:has(i.fa-phone-alt) i,
    .footer-col:last-child li:has(i.fa-phone) i,
    .footer-col:last-child .contact-list li:has(i.fa-phone-alt) i,
    .footer-col:last-child .contact-list li:has(i.fa-phone) i {
        flex-shrink: 0 !important;
        margin: 0 !important;
    }
    
    /* Email - Row layout */
    .footer-col:last-child li:has(i.fa-envelope),
    .footer-col:last-child .contact-list li:has(i.fa-envelope) {
        flex-direction: row;
        align-items: center;
    }
    
    /* ============================================
       ALL FOOTER COLUMNS - SPACING REDUCTION
       ============================================ */
    
    /* Footer Links - Reduced Spacing */
    .footer-links {
        margin-top: clamp(8px, 2vw, 12px) !important;
    }
    
    .footer-links li {
        margin-bottom: clamp(6px, 1.5vw, 10px) !important;
        padding-bottom: clamp(4px, 1vw, 6px) !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
    }
    
    .footer-links li a {
        font-size: clamp(13px, 3.2vw, 14px) !important;
        line-height: 1.5 !important;
        padding: clamp(4px, 1vw, 6px) 0;
        min-height: 44px;
        display: flex;
        align-items: center;
    }
    
    /* ============================================
       FOOTER COPYRIGHT - SPACING REDUCTION
       ============================================ */
    
    .footer-bottom,
    footer .container:last-child {
        padding-top: clamp(15px, 3vw, 20px) !important;
        padding-bottom: clamp(10px, 2vw, 15px) !important;
        margin-top: clamp(15px, 3vw, 20px) !important;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .footer-bottom p,
    footer .container:last-child p {
        font-size: clamp(12px, 3vw, 13px) !important;
        margin: 0;
        padding: clamp(5px, 1.2vw, 8px) 0;
        text-align: center;
        line-height: 1.4;
    }
    
    /* ============================================
       FOOTER SOCIAL ICONS - SPACING REDUCTION
       ============================================ */
    
    /* Social Icons Container in Contact Us - Reduced spacing */
    .footer-col:last-child > div[style*="margin-top: 20px"],
    .footer-col:last-child > div[style*="border-top"] {
        margin-top: clamp(6px, 1.5vw, 10px) !important;
        padding-top: clamp(5px, 1.2vw, 8px) !important;
        margin-bottom: clamp(5px, 1.2vw, 8px) !important;
        padding-bottom: clamp(5px, 1.2vw, 8px) !important;
    }
    
    /* Reduce spacing between social icons div and copyright section */
    .footer-grid + .copyright {
        margin-top: clamp(5px, 1.5vw, 10px) !important;
        padding-top: clamp(8px, 2vw, 12px) !important;
    }
    
    /* Reduce spacing after social icons container */
    .footer-col:last-child > div[style*="display: flex"][style*="justify-content: center"] {
        margin-bottom: clamp(3px, 1vw, 6px) !important;
    }
    
    /* Social Icons Flex Container */
    .footer-col:last-child div[style*="display: flex"][style*="gap: 15px"],
    .footer-col:last-child div[style*="justify-content: center"] {
        gap: clamp(10px, 2.5vw, 15px) !important;
    }
    
    /* Social Icons Links */
    .footer-col:last-child div[style*="display: flex"] a,
    .footer-col:last-child a[href*="facebook"],
    .footer-col:last-child a[href*="instagram"],
    .footer-col:last-child a[href*="twitter"],
    .footer-col:last-child a[href*="youtube"],
    .footer-col:last-child a[href*="pinterest"] {
        width: clamp(36px, 9vw, 40px) !important;
        height: clamp(36px, 9vw, 40px) !important;
        min-width: clamp(36px, 9vw, 40px) !important;
        min-height: clamp(36px, 9vw, 40px) !important;
        font-size: clamp(16px, 4vw, 18px) !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
    }
}

/* ============================================
   VERY SMALL SCREENS (max-width: 480px)
   ============================================ */

@media (max-width: 480px) {
    /* Further reduce spacing for social icons container */
    .footer-col:last-child > div[style*="margin-top: 20px"],
    .footer-col:last-child > div[style*="border-top"] {
        margin-top: clamp(4px, 1vw, 8px) !important;
        padding-top: clamp(4px, 1vw, 6px) !important;
        margin-bottom: clamp(3px, 0.8vw, 5px) !important;
        padding-bottom: clamp(3px, 0.8vw, 5px) !important;
    }
    
    /* Further reduce spacing between social icons and copyright */
    .footer-grid + .copyright {
        margin-top: clamp(3px, 1vw, 6px) !important;
        padding-top: clamp(6px, 1.5vw, 10px) !important;
    }
    
    /* Further reduce spacing after social icons container */
    .footer-col:last-child > div[style*="display: flex"][style*="justify-content: center"] {
        margin-bottom: clamp(2px, 0.8vw, 4px) !important;
    }
}
