.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 4px;
    margin-left: auto;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 3px;
    background: var(--paper);
    color: var(--navy);
    cursor: pointer
}

.menu-toggle span {
    width: 18px;
    height: 2px;
    background: currentColor;
    transition: transform .18s ease, opacity .18s ease
}

.menu-toggle[aria-expanded="true"] span:first-child {
    transform: translateY(6px) rotate(45deg)
}

.menu-toggle[aria-expanded="true"] span:nth-child(2) {
    opacity: 0
}

.menu-toggle[aria-expanded="true"] span:last-child {
    transform: translateY(-6px) rotate(-45deg)
}

header {
    border-bottom: 0
}

header::after {
    position: absolute;
    right: max(22px, calc((100% - 1160px) / 2));
    bottom: 0;
    left: max(22px, calc((100% - 1160px) / 2));
    height: 1px;
    background: #102b3f14;
    content: ''
}

@media(max-width:850px) {
    html.has-menu-toggle .menu-toggle {
        display: inline-flex
    }

    html.has-menu-toggle .links {
        display: none;
        overflow: visible;
        padding: 0
    }

    html.has-menu-toggle .links.is-open {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px
    }

    html.has-menu-toggle .links a:not(.btn) {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 44px;
        padding: 8px 10px;
        border: 1px solid var(--line);
        border-radius: 3px;
        background: var(--paper);
        text-align: center;
        white-space: nowrap
    }

    html.has-menu-toggle .links .btn {
        grid-column: 1 / -1;
        min-height: 44px;
        justify-content: center;
        white-space: nowrap
    }
}

@media(max-width:540px) {
    .top {
        display: none
    }

    .brand small {
        display: block;
        margin-top: 3px;
        font-size: 8px;
        letter-spacing: .12em;
        line-height: 1.2;
        white-space: nowrap
    }

    .brand strong {
        font-size: 15px;
        white-space: nowrap
    }

    header::after {
        right: 14px;
        left: 14px
    }

    html.has-menu-toggle .links.is-open {
        grid-template-columns: repeat(2, minmax(0, 1fr))
    }
}

@media(prefers-reduced-motion:reduce) {
    .menu-toggle span {
        transition: none
    }
}