/*
 * The site header: one compact, sticky bar (PublicLayout + MainNavbar ShowBrand).
 * Loaded after NewsTemplate's style.css, whose .navbar.style-1 rules it overrides.
 *
 *   desktop:  [☰] [owl Language In Use]  Home Learn Community …   [account] [theme] [search]
 *   phone:    [☰] [owl Language In Use]                              [search] [account]
 *
 * It replaces the kit's TopNavbar (date + a large centred logo), which on phones was a tall
 * band with only the owl in it, above a second bar with two menu buttons.
 */

.liu-header {
    position: sticky;
    top: 0;
    z-index: 1030;
    background: var(--theme-surface, #fff);
    border-bottom: 1px solid var(--theme-border, #e2e8f0);
    /* Soft edge, visible once content scrolls under the bar. */
    box-shadow: 0 4px 14px -10px rgba(15, 23, 42, .35);
}
.liu-header .navbar.style-1 {
    border-bottom: 0;
}

/* ── Brand ─────────────────────────────────────────────────────────────── */
.navbar-brand-compact {
    display: inline-flex;
    align-items: center;
    gap: .55rem;
    color: inherit;
    text-decoration: none;
    white-space: nowrap;
    margin-right: 1.5rem;
}
.navbar-brand-compact img {
    height: 40px;
    width: auto;
    display: block;
}
/* Same file for light and dark: show one. */
.navbar-brand-compact img.light-none {
    display: none !important;
}
.navbar-brand-compact__name {
    font-family: var(--font-heading, inherit);
    font-weight: 700;
    font-size: 1.15rem;
    letter-spacing: -.01em;
    color: var(--theme-text, #0f172a);
}
.navbar-brand-compact:hover .navbar-brand-compact__name {
    color: var(--color-main, #2563eb);
}

/* ── Desktop bar ───────────────────────────────────────────────────────── */
.liu-header .navbar.style-1 .navbarList-icon {
    margin-right: 1rem !important;
}
.liu-header .navbar.style-1 .mob-nav-toggles {
    flex: 0 0 auto;
}
@media (min-width: 992px) {
    /* The kit's 30px link padding made the bar ~85px tall; 64px is plenty. */
    .liu-header .navbar.style-1 .navbar-nav .nav-item .nav-link {
        padding-top: 21px;
        padding-bottom: 21px;
        margin: 0 4px;
    }
}
/* Between lg and xl the brand name and six menu items don't fit: keep the owl only. */
@media (min-width: 992px) and (max-width: 1279.98px) {
    .navbar-brand-compact__name {
        display: none;
    }
    .navbar-brand-compact {
        margin-right: .75rem;
    }
}

/* ── Phone bar ─────────────────────────────────────────────────────────── */
@media (max-width: 991.98px) {
    .liu-header .navbar.style-1 .mob-nav-toggles {
        width: 100%;
        min-height: 56px;
        padding: .35rem 1rem;
        gap: .75rem;
        justify-content: flex-start !important;
    }
    .liu-header .navbar.style-1 .navbarList-icon {
        margin-right: 0 !important;
    }
    .navbar-brand-compact {
        margin-right: 0;
    }
    .navbar-brand-compact img {
        height: 38px;
    }
    .navbar-brand-compact__name {
        font-size: 1.05rem;
    }
    /* No collapse button any more: the drawer carries the menu on phones. */
    .liu-header .navbar.style-1 .navbar-collapse {
        display: none !important;
    }
}
@media (max-width: 359.98px) {
    .navbar-brand-compact__name {
        display: none;
    }
}

.navbar-mobile-actions {
    gap: .25rem;
}
.liu-mobile-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: inherit;
    font-size: 1.45rem;
    padding: 0;
    text-decoration: none;
}
.liu-mobile-action:hover,
.liu-mobile-action:focus-visible {
    background: var(--theme-primary-light, rgba(37, 99, 235, .08));
}
.liu-mobile-action .user-menu-avatar {
    width: 32px;
    height: 32px;
}

/* ── Drawer: theme switch row ──────────────────────────────────────────── */
.sidebar-popup-style1 .drawer-theme .theme-toggle {
    margin-left: 0 !important;
}

/* ── Dark theme ────────────────────────────────────────────────────────── */
.dark-theme .liu-header {
    box-shadow: 0 4px 14px -10px rgba(0, 0, 0, .8);
}
.dark-theme .navbar-brand-compact__name {
    color: var(--theme-text, #e2e8f0);
}
