/* Footer Styles - Clean separation between desktop and mobile */

/* Global Footer Styles */
.footer {
    background: #1a1a1a;
    color: white;
    padding: 3rem 0 1rem;
    margin-top: 4rem;
    direction: ltr;
    width: 100% !important;
    max-width: none !important;
}

.footer * {
    direction: ltr;
}

.footer-container {
    max-width: 1100px !important;
    margin: 0 auto !important;
    padding: 0 2rem !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

/* Override any container rules from home.html */
.footer-container[class*="container"] {
    max-width: 1100px !important;
}

/* Override the specific footer-container rule from home.html line 261 */
.footer .footer-container {
    max-width: 1100px !important;
}


.footer-bottom {
    border-top: 1px solid #333;
    padding-top: 1rem;
    text-align: center;
}

.footer-copyright {
    color: #999;
    font-size: 0.9rem;
}

/* Footer brand and link styles - global */
.footer-brand h3 .cbs {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2563eb;
}

.footer-link {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: #ff6b6b;
}

/* Desktop Footer Styles */
@media (min-width: 1025px) {
    .footer-content {
        display: grid !important;
        grid-template-columns: 1fr 0.8fr 0.3fr !important;
        column-gap: 0 16rem !important;
        row-gap: 2rem !important;
        margin-bottom: 2rem !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .footer-brand {
        grid-column: 1;
    }

    .footer-brand h3 {
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }

    .footer-brand p {
        color: #ccc;
        line-height: 1.6;
        white-space: nowrap;
    }

    .footer-contact {
        grid-column: 2;
        text-align: center;
    }

    /* Hebrew alignment for contact section */
    html[lang="he"] .footer-contact {
        text-align: center !important;
    }

    .footer-contact h4 {
        font-size: 1.2rem;
        margin-bottom: 1rem;
        color: white;
    }

    .footer-contact p {
        color: #ccc;
        margin-bottom: 0.5rem;
        text-align: center;
    }

    .phone-number {
        white-space: nowrap;
        text-align: center;
    }

    .footer-contact a {
        color: #ff6b6b;
        text-decoration: none;
        transition: color 0.3s ease;
    }

    .footer-contact a:hover {
        color: #ff5252;
    }

    .footer-menu {
        grid-column: 3;
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
    }

    .footer-menu li {
        list-style: none;
    }

    /* RTL Desktop Styles */
    html[dir="rtl"] .footer-contact p:has(a[href^="tel:"]) {
        direction: ltr;
        text-align: center;
    }

    html[dir="rtl"] .footer-contact p:contains("+972") {
        direction: ltr;
        text-align: center;
        unicode-bidi: embed;
    }

    html[dir="rtl"] .footer-contact p.phone-number,
    html[dir="rtl"] .footer-contact p:has(.phone-number) {
        direction: ltr;
        text-align: center;
    }

    html[dir="rtl"] .footer-contact p {
        direction: ltr;
        text-align: center;
        unicode-bidi: embed;
    }
    
    /* Desktop Hebrew Footer Styles */
    html[lang="he"] .footer-contact {
        text-align: center;
    }
    
    /* Hebrew phone number centering in desktop */
    html[lang="he"] .footer-contact p.phone-number {
        text-align: center !important;
    }
    
    html[lang="he"] .footer-contact .phone-number {
        text-align: center !important;
    }
    
    html[lang="he"] .footer-contact p:contains("+972") {
        text-align: center !important;
    }
    
    html[lang="he"] .footer-menu {
        align-items: flex-end;
    }
}

/* Mobile and Tablet Footer Styles - All devices under 1025px */
@media (max-width: 1024px) {
    .footer-content {
        display: flex;
        flex-direction: column;
        gap: 2rem;
        text-align: center;
    }
    
    .footer-brand h3 {
        font-size: 1.3rem;
        margin-bottom: 0.5rem;
    }
    
    .footer-brand p {
        font-size: 0.9rem;
        max-width: 100%;
    }
    
    .footer-contact {
        text-align: center;
    }
    
    .footer-contact h4 {
        font-size: 1.1rem;
        margin-bottom: 0.75rem;
    }
    
    .footer-contact p {
        font-size: 0.9rem;
        word-break: break-all;
        margin-bottom: 0.4rem;
    }
    
    .footer-contact a {
        font-size: 0.9rem;
        display: inline-block;
        margin-top: 0.5rem;
    }
    
    .footer-menu {
        display: flex;
        flex-direction: row;
        justify-content: center;
        flex-wrap: wrap;
        gap: 0.75rem 1rem;
    }
    
    .footer-menu li {
        list-style: none;
    }
    
    .footer-link {
        font-size: 0.9rem;
    }
    
    .footer-container {
        padding: 0 1rem;
    }
    
    /* Mobile Hebrew Styles */
    html[lang="he"] .footer-contact {
        text-align: center;
    }
    
    html[lang="he"] .footer-contact h4,
    html[lang="he"] .footer-contact p,
    html[lang="he"] .footer-contact a {
        text-align: center;
    }
    
    html[lang="he"] .footer-contact p.phone-number {
        text-align: center !important;
    }
    
    /* Additional Hebrew phone number centering */
    html[lang="he"] .footer-contact p:contains("+972") {
        text-align: center !important;
    }
    
    html[lang="he"] .footer-contact p:has(.phone-number) {
        text-align: center !important;
    }
}

/* Language switching for footer */
html[lang="he"] .lang-en {
    display: none;
}
html[lang="he"] .lang-he {
    display: inline;
}