/* ====================================
   ANNOUNCEMENT BAR STYLES
   Modern, minimal announcement bar inspired by high-end fashion e-commerce
   ==================================== */

/* Main announcement bar container */
.announcement-bar {
/*    background-color: var(--grey-black);
    color: #ffffff;*/
    width: 100%;
    padding: 12px 20px;
    text-align: center;
    font-family: var(--font-default);
    position: relative;
    z-index: 100;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: background-color 0.5s ease-in-out;
}

/* Announcement content wrapper */
.announcement-bar__content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* Announcement text */
.announcement-bar__text {
    font-size: 14px;
    letter-spacing: 0.5px;
    line-height: 1.4;
    margin: 0;
    text-transform: uppercase;
}

/* Make <p> from Rich Editor inline so the "Details" link flows on the same line
   as the last line of text. <br> inside still works for line breaks. */
.announcement-bar .announcement-bar__text p {
    display: inline;
    margin: 0;
    padding: 0;
}

/* Link styling — continues inline after last line of text */
.announcement-bar__link {
/*    color: #ffffff;*/
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-thickness: 1px;
    font-weight: 500;
    transition: opacity 0.2s ease;
    margin-left: 8px;
    white-space: nowrap;
}

.announcement-bar__link:hover {
    opacity: 0.8;
/*    color: #ffffff;*/
}

/* Multiple messages slider — vertical slide-up transition */
.announcement-bar__slider {
    position: relative;
    overflow: hidden;
    width: 100%;
}

.announcement-bar__slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    opacity: 0;
    transform: translateY(100%);
    transition: transform 0.5s ease-in-out, opacity 0.4s ease-in-out;
    pointer-events: none;
}

/* Active slide — visible at natural position */
.announcement-bar__slide.active {
    position: relative;
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

/* Entering state — start below (set by JS before reflow, then removed to trigger transition) */
.announcement-bar__slide.entering {
    position: relative;
    opacity: 0;
    transform: translateY(100%);
}

/* Exiting state — slide up and out */
.announcement-bar__slide.exiting {
    position: absolute;
    opacity: 0;
    transform: translateY(-100%);
}

/* Close button - ynakim.com style */
.announcement-bar__close {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
/*    color: #ffffff;*/
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.2s ease-in-out;
    padding: 8px;
    width: 30px;
    height: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    -webkit-appearance: none;
    -moz-appearance: none;
}

.announcement-bar__close svg {
    width: 14px;
    height: 14px;
    display: block;
}

.announcement-bar__close:hover {
    opacity: 1;
}

.announcement-bar__close:focus {
    outline: none;
    opacity: 1;
}

.announcement-bar__close:active {
    opacity: 0.8;
}

/* Responsive design */
@media (max-width: 768px) {
    .announcement-bar {
        padding: 10px 50px 10px 15px;
    }

    .announcement-bar__text {
        font-size: 14px;
        letter-spacing: 0.3px;
    }

    .announcement-bar__close {
        right: 15px;
        width: 28px;
        height: 28px;
        padding: 6px;
    }

    .announcement-bar__close svg {
        width: 12px;
        height: 12px;
    }
}

@media (max-width: 480px) {
    .announcement-bar {
        padding: 8px 12px;
    }

    .announcement-bar__text {
        font-size: 14px;
    }
}

/* Alternative color schemes (can be toggled via classes) */
.announcement-bar--dark-grey {
  /*  background-color: #2c2c2c;*/
}

.announcement-bar--brand {
/*    background-color: var(--red, #e74c3c);*/
}

.announcement-bar--white {
    /*background-color: #ffffff;
    color: #000000;*/
    border-bottom: 1px solid #e0e0e0;
}

.announcement-bar--white .announcement-bar__link {
    /*color: #000000;*/
}

.announcement-bar--white .announcement-bar__close {
   /* color: #000000;*/
}
