.ng-menu {
    position: fixed;
    z-index: 880;
    inset: 0;
    display: grid;
    visibility: hidden;
    align-items: end;
    pointer-events: none;
}

.ng-menu.is-open {
    visibility: visible;
    pointer-events: auto;
}

.ng-menu__backdrop {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    background: rgba(0, 0, 0, .34);
    opacity: 0;
    transition: opacity 180ms ease;
}

.ng-menu.is-open .ng-menu__backdrop {
    opacity: 1;
}

.ng-menu__sheet {
    position: relative;
    z-index: 1;
    width: min(100%, 720px);
    max-height: min(72vh, 680px);
    margin: 0 auto;
    padding: 10px 18px calc(112px + env(safe-area-inset-bottom, 0px));
    overflow-y: auto;
    overscroll-behavior: contain;
    background: #fff;
    border-radius: 26px 26px 0 0;
    box-shadow: 0 -16px 45px rgba(0, 0, 0, .15);
    transform: translateY(104%);
    transition: transform 220ms cubic-bezier(.2,.8,.2,1);
}

.ng-menu.is-open .ng-menu__sheet {
    transform: translateY(0);
}

.ng-menu__handle {
    width: 44px;
    height: 5px;
    margin: 0 auto 14px;
    background: #d7d7d7;
    border-radius: 999px;
}

.ng-menu__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--ng-border);
}

.ng-menu__eyebrow {
    margin: 0 0 2px;
    color: var(--ng-accent);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .08em;
}

.ng-menu__header h2 {
    margin: 0;
    font-size: 30px;
    line-height: 1.1;
}

.ng-menu__close {
    min-height: 44px;
    padding: 0 14px;
    border: 1px solid var(--ng-border);
    border-radius: 999px;
    background: #fff;
    color: #111;
    font-weight: 700;
}

.ng-menu__links {
    display: grid;
    gap: 8px;
    padding-top: 16px;
}

.ng-menu__links a {
    display: flex;
    min-height: 54px;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 13px 15px;
    background: #fafafa;
    border: 1px solid #ededed;
    border-radius: 15px;
    color: #111;
    font-size: 17px;
    font-weight: 750;
    text-decoration: none;
}

.ng-menu__links a span:last-child {
    color: var(--ng-accent);
    font-size: 25px;
    line-height: 1;
}

.ng-menu__empty {
    margin: 6px 0 0;
    padding: 18px;
    background: #fafafa;
    border-radius: 15px;
    color: var(--ng-muted);
    text-align: center;
}

body.ng-menu-open {
    overflow: hidden;
}

@media (max-width: 374px) {
    .ng-menu__sheet {
        padding-right: 13px;
        padding-left: 13px;
        border-radius: 22px 22px 0 0;
    }

    .ng-menu__header h2 {
        font-size: 27px;
    }
}

@media (min-width: 768px) {
    .ng-menu {
        padding: 24px;
        align-items: center;
    }

    .ng-menu__sheet {
        max-height: min(78vh, 720px);
        padding: 14px 24px 28px;
        border-radius: 26px;
        transform: translateY(24px) scale(.98);
        opacity: 0;
    }

    .ng-menu.is-open .ng-menu__sheet {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

@media (prefers-reduced-motion: reduce) {
    .ng-menu__backdrop,
    .ng-menu__sheet {
        transition: none;
    }
}
