*,
*::before,
*::after {
    box-sizing: border-box;
}

/* Banner Styles */
#promo-banner {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 32px;
    background: var(--accent-cyan);
    color: #000;
    z-index: 9999;
    /* Above everything else */
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transform: translateY(-100%);
    /* Start hidden */
    transition: transform 0.5s ease;
    /* Prevent multi-line */
    white-space: nowrap;
    overflow: hidden;
    padding: 0 15px;
}

#promo-banner.visible {
    transform: translateY(0);
}

#promo-banner a {
    color: inherit;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    height: 100%;
    justify-content: center;
    /* Ensure link doesn't wrap either */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

#promo-banner a:hover {
    text-decoration: underline;
    background: rgba(255, 255, 255, 0.1);
}

/* Adjust layout when banner is active */
body.has-banner {
    padding-top: 32px;
    /* Push content down */
}

body.has-banner .main-header {
    margin-top: 32px;
    /* Push fixed header down */
    transition: margin-top 0.5s ease;
}

/* Adjust Fixed Brand Lockup (Logo+Text) Position */
/* Adjust Fixed Brand Lockup (Logo+Text) Position */
body.has-banner.scrolled .brand-lockup,
body.has-banner.automatic-header .brand-lockup,
body.has-banner.skip-intro .brand-lockup,
body.has-banner.header-reached .brand-lockup {
    /* Add banner height to the standard header top position */
    top: calc(var(--header-top) + var(--banner-height, 32px)) !important;
}

/* Reset for Subpages:
   Since .subpage-header has a transform (Containing Block), the logo moves naturally with the header's margin-top.
   Therefore, we DO NOT need the extra offset calculation here. Use standard position. */
body.has-banner.subpage .brand-lockup {
    top: var(--header-top) !important;
}

/* On mobile, maybe make banner smaller or scrollable? */
@media (max-width: 600px) {
    #promo-banner {
        font-size: 0.7rem;
        /* Slightly smaller for mobile single-line */
        height: 32px;
        /* Force same height as desktop */
        line-height: 32px;
        padding: 0 10px;
    }

    #promo-banner a {
        display: flex;
        /* Maintain flex for single line */
        white-space: nowrap;
    }

    body.has-banner {
        padding-top: 32px;
    }

    body.has-banner .main-header {
        margin-top: 32px;
    }

    body.has-banner.scrolled .brand-lockup,
    body.has-banner.automatic-header .brand-lockup {
        top: calc(var(--header-top) + 32px);
    }
}