/* ==============================================
   Announcement Bar — Frontend Styles
   ============================================== */

#anb-bar {
    --anb-bg:                  #1a1a2e;
    --anb-color:               #ffffff;
    --anb-link-color:          #f0c040;
    --anb-font-size:           15px;
    --anb-font-family:         inherit;
    --anb-font-weight:         500;
    --anb-height:              48px;
    --anb-btn-normal-bg:       #e85425;
    --anb-btn-normal-color:    #ffffff;
    --anb-btn-normal-border:   #e85425;
    --anb-btn-hover-bg:        #e85425;
    --anb-btn-hover-color:     #ffffff;
    --anb-btn-hover-border:    #e85425;
    --anb-btn-pressed-bg:      #c4441d;
    --anb-btn-pressed-color:   #ffffff;
    --anb-btn-pressed-border:  #c4441d;
    --anb-btn-radius:          50px;
    --anb-btn-border-width:    0px;
    --anb-btn-border-type:     none;
    --anb-btn-font-size:       14px;

    display: flex;
    align-items: center;
    justify-content: center;
    background:   var(--anb-bg);
    color:        var(--anb-color);
    font-family:  var(--anb-font-family);
    font-size:    var(--anb-font-size);
    font-weight:  var(--anb-font-weight);
    min-height:   var(--anb-height);
    width:        100%;
    z-index:      99999;
    box-sizing:   border-box;
    padding:      8px 48px 8px 16px;
    line-height:  1.45;
}

/* Position */
#anb-bar.anb-position-top    { top: 0; left: 0; right: 0; }
#anb-bar.anb-position-bottom { bottom: 0; left: 0; right: 0; }
#anb-bar.anb-sticky     { position: fixed; }
#anb-bar:not(.anb-sticky) { position: relative; }

/* Inner layout */
.anb-inner {
    display: flex; align-items: center; justify-content: center;
    width: 100%; max-width: 1200px; margin: 0 auto; gap: 12px;
}
.anb-content {
    display: flex; align-items: center; justify-content: center;
    gap: 8px; flex: 1; flex-wrap: wrap; text-align: center; min-width: 0;
}

/* Icon */
.anb-icon { font-size: 1.2em; line-height: 1; flex-shrink: 0; }

/* Message */
.anb-message { text-align: center; }
.anb-message a {
    color: var(--anb-link-color);
    text-decoration: underline;
    text-underline-offset: 2px;
    opacity: 1;
    transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1), color 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.anb-message a:hover  { opacity: 0.72; }
.anb-message a:active { opacity: 0.5; transition-duration: 0.05s; }

/* CTA button */
.anb-link {
    display:          inline-block;
    background:       var(--anb-btn-normal-bg);
    color:            var(--anb-btn-normal-color) !important;
    text-decoration:  none !important;
    border-width:     var(--anb-btn-border-width);
    border-style:     var(--anb-btn-border-type);
    border-color:     var(--anb-btn-normal-border);
    padding:          4px 14px;
    border-radius:    var(--anb-btn-radius);
    font-size:        var(--anb-btn-font-size);
    font-weight:      700;
    white-space:      nowrap;
    flex-shrink:      0;
    transition:       background .18s, color .18s, border-color .18s, transform .1s;
    cursor:           pointer;
    line-height:      1.5;
}
.anb-link:hover {
    background:   var(--anb-btn-hover-bg);
    color:        var(--anb-btn-hover-color) !important;
    border-color: var(--anb-btn-hover-border);
}
.anb-link:active {
    background:   var(--anb-btn-pressed-bg);
    color:        var(--anb-btn-pressed-color) !important;
    border-color: var(--anb-btn-pressed-border);
    transform:    scale(0.97);
}

/* Close button — anchored to #anb-bar, outside .anb-inner */
.anb-close {
    background:    transparent;
    border:        none;
    color:         var(--anb-color);
    cursor:        pointer;
    font-size:     16px;
    line-height:   1;
    padding:       4px 8px;
    opacity:       .65;
    transition:    opacity .15s, transform .15s;
    position:      absolute;
    right:         8px;
    top:           50%;
    transform:     translateY(-50%);
    border-radius: 3px;
    flex-shrink:   0;
}
.anb-close:hover { opacity: 1; transform: translateY(-50%) scale(1.15); }

/* Hidden */
#anb-bar.anb-hidden { display: none !important; }

/* Entry animations */
#anb-bar.anb-anim-slide-down { animation: anbSlideDown .45s cubic-bezier(0.16,1,0.3,1) both; }
@keyframes anbSlideDown { from { transform: translateY(-100%); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

#anb-bar.anb-anim-slide-up { animation: anbSlideUp .45s cubic-bezier(0.16,1,0.3,1) both; }
@keyframes anbSlideUp { from { transform: translateY(100%); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

#anb-bar.anb-anim-fade-in { animation: anbFadeIn .55s ease both; }
@keyframes anbFadeIn { from { opacity: 0; } to { opacity: 1; } }

#anb-bar.anb-anim-bounce { animation: anbBounce .65s cubic-bezier(0.36,.07,.19,.97) both; }
@keyframes anbBounce {
    0%   { transform: translateY(-100%); opacity: 0; }
    50%  { opacity: 1; }
    65%  { transform: translateY(7px); }
    80%  { transform: translateY(-4px); }
    90%  { transform: translateY(2px); }
    100% { transform: translateY(0); }
}

#anb-bar.anb-anim-zoom-in { transform-origin: top center; animation: anbZoomIn .38s cubic-bezier(0.16,1,0.3,1) both; }
#anb-bar.anb-position-bottom.anb-anim-zoom-in { transform-origin: bottom center; }
@keyframes anbZoomIn { from { transform: scaleY(0); opacity: 0; } to { transform: scaleY(1); opacity: 1; } }

/* WP admin bar compat */
.admin-bar #anb-bar.anb-sticky.anb-position-top { top: 32px; }
@media screen and (max-width: 782px) { .admin-bar #anb-bar.anb-sticky.anb-position-top { top: 46px; } }
