/* Header menu between 992px and 1399px: keep the expanded menu inside the container
 * (it overflowed the viewport at 992-1024px once the menu had 8 items) and keep
 * each submenu caret right after its label instead of on a line of its own. */
@media (min-width: 992px) and (max-width: 1399.98px) {
    header.navbar #navbarNav .navbar-nav {
        justify-content: flex-end;
        gap: 0.65rem;
        padding-left: 0.5rem !important;
    }
    header.navbar #navbarNav .navbar-nav > .nav-item {
        flex: 0 0 auto;
        width: min-content; /* multi-word labels sit on two even lines; no leftover gaps */
        line-height: 1.25;
        text-align: center;
        white-space: nowrap; /* no break between a label and its caret */
    }
    header.navbar #navbarNav .navbar-nav > .nav-item > .nav-link.d-inline-block {
        display: inline !important;
        padding: 0 0.15rem 0 0.45rem;
        white-space: normal;
        font-size: 0.9rem;
    }
    header.navbar #navbarNav .navbar-nav > .nav-item > .bi-caret-down {
        display: inline !important;
        margin-left: 0.2rem;
        margin-right: 0.3rem !important;
        font-size: 0.7rem;
    }
    header.navbar #navbarNav .navbar-nav > .nav-item > .bi-caret-down::before {
        display: inline; /* an inline-block glyph would add a line-break opportunity */
    }
    header.navbar #navbarNav .navbar-nav > .nav-item > .sub-menu {
        text-align: left;
        white-space: normal;
    }
}
@media (min-width: 992px) and (max-width: 1199.98px) {
    header.navbar > .container > a > img {
        width: 48px;
        height: 48px;
    }
    header.navbar #siteTitleLink {
        margin-left: 0.4rem !important;
        margin-right: 0.25rem !important;
        font-size: 1.2rem !important;
    }
    header.navbar #navbarNav .navbar-nav > .nav-item > .nav-link.d-inline-block {
        padding-left: 0.3rem;
        font-size: 0.85rem;
    }
}
