/* Global fallback variables for top banner */
:root {
    --top-banner-bg: #007bff;
    --primary-color: #007bff;
    --white: #ffffff;
}

/* Top Contact Banner Styles */
.top-contact-banner {
    background-color: var(--top-banner-bg, var(--primary-color, #007bff));
    color: var(--white, #ffffff);
    padding: 0.5rem 0;
    font-size: 0.875rem;
    position: relative;
    width: 100%;
    z-index: 1049;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.top-banner-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.top-banner-left,
.top-banner-center,
.top-banner-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.top-banner-left {
    flex: 1;
    justify-content: flex-start;
}

.top-banner-center {
    flex: 1;
    justify-content: center;
    text-align: center;
}

.top-banner-right {
    flex: 1;
    justify-content: flex-end;
}

.contact-link,
.social-link {
    color: var(--white, #ffffff) !important;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    transition: all 0.2s ease;
    opacity: 0.9;
}

.contact-link:hover,
.social-link:hover {
    color: rgba(255, 255, 255, 0.7) !important;
    opacity: 1;
    transform: translateY(-1px);
}

.contact-link:hover svg,
.social-link:hover svg,
.contact-link:hover svg use,
.social-link:hover svg use {
    fill: rgba(255, 255, 255, 0.7) !important;
    stroke: rgba(255, 255, 255, 0.7) !important;
    color: rgba(255, 255, 255, 0.7) !important;
}

.banner-text {
    font-weight: 500;
    letter-spacing: 0.3px;
}

.social-link svg,
.contact-link svg {
    color: #ffffff !important;
    fill: none !important;
    stroke: #ffffff !important;
}

.social-link svg use,
.contact-link svg use {
    stroke: #ffffff !important;
    color: #ffffff !important;
    fill: none !important;
}

.social-link svg *,
.contact-link svg * {
    fill: none !important;
    stroke: #ffffff !important;
    color: #ffffff !important;
}

.social-link .icon,
.contact-link .icon {
    color: #ffffff !important;
    fill: none !important;
}

/* Comprehensive fix for all top banner icons - especially circular ones */
.top-contact-banner a,
.top-contact-banner .social-link,
.top-contact-banner .contact-link {
    color: #ffffff !important;
    background-color: transparent !important;
}

/* Force all child elements to be white */
.top-contact-banner a *,
.top-contact-banner .social-link *,
.top-contact-banner .contact-link *,
.top-contact-banner svg,
.top-contact-banner .icon,
.top-contact-banner i {
    color: #ffffff !important;
    stroke: #ffffff !important;
    fill: none !important;
    background-color: transparent !important;
}

/* Ensure all SVG elements have no fill */
.top-contact-banner svg *,
.top-contact-banner svg path,
.top-contact-banner svg circle,
.top-contact-banner svg rect,
.top-contact-banner svg polygon,
.top-contact-banner svg line {
    fill: none !important;
    stroke: #ffffff !important;
}

/* Target any button-like or circular elements */
.top-contact-banner [class*="btn"],
.top-contact-banner [class*="circle"],
.top-contact-banner [style*="border-radius"],
.top-contact-banner [style*="background"] {
    background-color: transparent !important;
    color: #ffffff !important;
    border-color: #ffffff !important;
}

.top-contact-banner [class*="btn"] *,
.top-contact-banner [class*="circle"] *,
.top-contact-banner [style*="border-radius"] *,
.top-contact-banner [style*="background"] * {
    color: #ffffff !important;
    stroke: #ffffff !important;
}

/* Super specific overrides for stubborn icons */
.top-contact-banner,
.top-contact-banner * {
    --icon-color: #ffffff !important;
    --text-color: #ffffff !important;
    --primary-color: #ffffff !important;
}

/* Override any Bootstrap or framework icon colors */
.top-contact-banner .fa,
.top-contact-banner .fas,
.top-contact-banner .far,
.top-contact-banner .fab,
.top-contact-banner .icon,
.top-contact-banner [class*="icon-"] {
    color: #ffffff !important;
}

/* Force white for any possible icon library */
.top-contact-banner .material-icons,
.top-contact-banner .mdi,
.top-contact-banner [class*="mdi-"] {
    color: #ffffff !important;
}

/* Navbar stays fixed at top, no gap with banner */
.webcommerce-navbar {
    position: sticky !important;
    top: 0 !important;
    margin-top: 0 !important;
}

/* Hide default navbar spacer when top banner is present */
.navbar-spacer {
    display: none !important;
}

/* Responsive adjustments */
@media (max-width: 991.98px) {
    .top-banner-content {
        flex-wrap: wrap;
        justify-content: center;
        text-align: center;
    }

    .top-banner-left,
    .top-banner-center,
    .top-banner-right {
        flex: 0 0 auto;
        width: auto;
    }

    .top-banner-center {
        order: -1;
        width: 100%;
        margin-bottom: 0.25rem;
    }
}

@media (max-width: 767.98px) {
    .top-contact-banner {
        font-size: 0.75rem;
        padding: 0.375rem 0;
    }

    .top-banner-content {
        gap: 0.5rem;
        justify-content: center;
    }

    /* Hide contact/hotline and social icons on mobile */
    .top-banner-left,
    .top-banner-right {
        display: none !important;
    }

    /* Show only center text on mobile */
    .top-banner-center {
        width: 100%;
        flex: 1;
    }

    .banner-text {
        font-size: 0.75rem;
    }
}

@media (max-width: 575.98px) {
    .top-banner-center {
        font-size: 0.7rem;
    }

    .banner-text {
        font-size: 0.7rem;
    }
}
