/* static/css/components/announcement-banner.css
   Mobile-first responsive announcement banner.
   ============================================================ */

/* ── Base (mobile) — stacked column layout ── */
.ann-banner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 48px;
    padding: 10px 40px 10px 16px; /* right clearance for close btn */
    gap: 8px;
    background: #000;
    box-sizing: border-box;
    position: sticky;
    top: 0;
    z-index: 1000;
    text-align: center;
}

.ann-banner__text {
    color: #fff;
    font-family: 'Poppins', sans-serif;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.4;
}

.ann-banner__cta {
    display: inline-flex;
    height: 28px;
    padding: 0 16px;
    justify-content: center;
    align-items: center;
    border-radius: 35px;
    background: #fff;
    border: none;
    cursor: pointer;
    flex-shrink: 0;
    color: #353535;
    font-family: 'Poppins', sans-serif;
    font-size: 11px;
    font-weight: 500;
    line-height: normal;
    white-space: nowrap;
    transition: opacity 0.2s ease;
}

.ann-banner__cta:hover {
    opacity: 0.85;
}

.ann-banner__close {
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    line-height: 0;
    position: absolute;
    right: 8px;
    top: 10px; /* aligns with top of text on mobile */
}

/* ── Tablet (≥ 560px) — single row ── */
@media (min-width: 560px) {
    .ann-banner {
        flex-direction: row;
        min-height: 48px;
        padding: 7px 44px 7px 16px;
        gap: 16px;
        text-align: left;
    }

    .ann-banner__text {
        font-size: 13px;
        flex: 1;
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .ann-banner__close {
        top: 50%;
        transform: translateY(-50%);
    }
}

/* ── Desktop (≥ 768px) — centered, full text ── */
@media (min-width: 768px) {
    .ann-banner {
        justify-content: center;
        padding: 7px 60px;
        gap: 24px;
    }

    .ann-banner__text {
        font-size: 14px;
        flex: 0 1 auto;
        overflow: visible;
        text-overflow: unset;
        white-space: nowrap;
    }

    .ann-banner__cta {
        font-size: 12px;
        padding: 0 20px;
    }

    .ann-banner__close {
        right: 20px;
    }
}
