/* Keep section headings below the compact navigation. */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

.home-header.is-compact {
    position: fixed !important;
    top: 0;
    left: 0;
    background: #26264b;
    box-shadow: 0 3px 16px #0003;
}

.home-header.is-compact::after,
.home-header.is-compact .top-header,
.home-header.is-compact .group,
.home-header.is-compact .search-icon,
.home-header.is-compact .search-form {
    display: none !important;
}

.home-header.is-compact .navbar {
    min-height: 64px;
    padding-top: 8px;
    padding-bottom: 8px;
    flex-wrap: nowrap;
}

.home-header.is-compact .navbar-brand {
    flex-shrink: 0;
    padding: 0;
    margin-right: 20px;
}

.home-header.is-compact .navbar-brand img {
    width: 90px;
    max-height: 42px;
    object-fit: contain;
}

.home-header.is-compact .navbar-collapse {
    display: flex !important;
    flex-basis: auto;
    min-width: 0;
    height: auto !important;
    overflow-x: auto;
}

.home-header.is-compact .navbar-nav {
    flex-direction: row;
    flex-wrap: nowrap;
}

.home-header.is-compact .nav-item {
    flex-shrink: 0;
}

.home-header.is-compact .nav-link {
    padding: 8px 10px;
    font-size: 14px;
    white-space: nowrap;
}

.home-header .nav-link:focus-visible,
.home-header .navbar-brand:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 3px;
}

@media (max-width: 767.98px) {
    /* Keep the original mobile navbar and its hamburger menu at the top. */
    .home-header {
        position: fixed !important;
        top: 0;
        left: 0;
    }

    .home-header .top-header,
    .home-header::after {
        display: none !important;
    }

    .home-header .navbar-collapse {
        max-height: calc(100dvh - 80px);
        overflow-y: auto;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}
