/* =========================================================
   banner.css — Slide-in notification banner
   All styles external. No inline or internal CSS used.
   ========================================================= */

/* ── Container: fixed to viewport, starts below navbar ── */
#banner-zone {
    position: fixed;
    top: 74px;              /* navbar height (64px) + 10px gap */
    right: 12px;
    z-index: 10010; /* must be above scanner modal (10000) */
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
    pointer-events: none;
    width: 360px;
    max-width: calc(100vw - 24px);
}

/* ── Individual banner card ── */
.banner {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 12px 16px;
    border-radius: 12px;
    pointer-events: all;
    transform: translateX(110%);
    opacity: 0;
    transition: transform 0.42s cubic-bezier(0.22, 1, 0.36, 1),
                opacity 0.30s ease;
}

.banner.banner--show {
    transform: translateX(0);
    opacity: 1;
}

.banner.banner--hide {
    transform: translateX(110%);
    opacity: 0;
}

/* ── Colour variants ── */
.banner--success {
    background-color: #16a34a;
}

.banner--error {
    background-color: #dc2626;
}

.banner--warning {
    background-color: #d97706;
}

.banner--info {
    background-color: #1a73e8;
}

/* ── Icon wrapper ── */
.banner__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 20px;
    height: 20px;
}

.banner__icon svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: #ffffff;
    stroke-width: 2.2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* ── Text body ── */
.banner__body {
    flex: 1;
    min-width: 0;
}

.banner__title {
    margin: 0;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.3;
    color: #ffffff;
}

.banner__message {
    margin: 2px 0 0;
    font-size: 12px;
    line-height: 1.3;
    color: rgba(255, 255, 255, 0.82);
}

/* ── Close button ── */
.banner__close {
    background: none;
    border: none;
    cursor: pointer;
    padding: 2px;
    flex-shrink: 0;
    color: rgba(255, 255, 255, 0.70);
    font-size: 16px;
    line-height: 1;
    transition: color 0.15s ease;
}

.banner__close:hover {
    color: #ffffff;
}

.banner__close:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.6);
    border-radius: 4px;
}

/* ── Responsive: full width on small screens ── */
@media (max-width: 420px) {
    #banner-zone {
        right: 8px;
        left: 8px;
        width: auto;
    }
}
