/**
 * Announcement Bar Styles
 * 
 * @package ChildTheme_Clean
 */

.announcement-bar {
    width: 100%;
    background-color: var(--primary-color, #245c2a);
    color: white;
    text-align: center;
    padding: 0.75rem 1rem;
    box-shadow: none;
    border: none;
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 1001 !important;
    transform: none !important;
    opacity: 1 !important;
    visibility: visible !important;
    line-height: 1.2;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: var(--announcement-bar-height-desktop, 45px);
    margin: 0 !important;
}

/* Account for WordPress admin bar - move announcement bar directly below it */
.admin-bar .announcement-bar {
    top: 32px !important;
    z-index: 1001 !important; /* Keep original z-index, below admin bar */
}

@media (min-width: 783px) {
    .admin-bar .announcement-bar {
        top: 46px !important;
    }
}

.announcement-bar.hidden {
    display: none !important;
    visibility: hidden !important;
}

.announcement-content {
    font-size: 0.875rem;
    font-weight: 500;
    letter-spacing: 0.05em;
}


@media (max-width: 1024px) {
    .announcement-bar {
        padding: 0.375rem 0.75rem;
        height: var(--announcement-bar-height-mobile, 32px) !important;
        min-height: var(--announcement-bar-height-mobile, 32px);
        max-height: var(--announcement-bar-height-mobile, 32px);
        margin-bottom: 0 !important;
        border-bottom: none !important;
        box-shadow: none !important;
        box-sizing: border-box !important;
        line-height: 1.2;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .announcement-content {
        font-size: 0.75rem;
        font-weight: 500;
        letter-spacing: 0.05em;
        line-height: 1;
    }
    
    /* Hide announcement bar on mobile when search is active */
    body.search-active-mobile .announcement-bar {
        display: none !important;
        visibility: hidden !important;
    }
    
    /* Ensure no gap between announcement bar and header */
    .announcement-bar + .site-header,
    .announcement-bar ~ .site-header {
        margin-top: 0 !important;
        padding-top: 0 !important;
    }
}