/*
 * Navigation drawer — Figma "Navigation" (4730:21203).
 *
 * Replaces the menu band below 1440px: a 350px white panel sliding in from the left, over a scrim.
 * It holds the same entries as the desktop menu, plus the pharmacy chip and the sign-out link the
 * header shows on a wide screen.
 */

.mo-drawer {
    position: fixed;
    z-index: 80;
    inset: 0;
    display: flex;
}

.mo-drawer[hidden] {
    display: none;
}

.mo-drawer__scrim {
    position: absolute;
    inset: 0;
    border: 0;
    background-color: rgb(5 5 5 / 40%);
    cursor: pointer;
}

.mo-drawer__panel {
    position: relative;
    display: flex;
    width: 350px;
    max-width: 90vw;
    flex-direction: column;
    gap: var(--mo-spacing-md);
    overflow-y: auto;
    padding: var(--mo-spacing-lg) var(--mo-margin-body-lr);
    border-radius: 0 var(--mo-radius-md) var(--mo-radius-md) 0;
    background-color: var(--mo-surface-default-white);
}

.mo-drawer__close {
    position: absolute;
    top: var(--mo-spacing-sm);
    right: var(--mo-spacing-sm);
    display: flex;
    padding: 0;
    border: 0;
    background: none;
    color: var(--mo-icon-default-dark);
    cursor: pointer;
}

.mo-drawer__close svg {
    width: var(--mo-scale-300);
    height: var(--mo-scale-300);
}

.mo-drawer__user {
    display: flex;
    align-items: center;
    gap: var(--mo-spacing-xs);
    padding: var(--mo-spacing-xs) var(--mo-scale-250) var(--mo-spacing-xs) var(--mo-spacing-xs);
    border: var(--mo-border-width-xs) solid var(--mo-border-default-medium);
    border-radius: var(--mo-radius-sm);
    background-color: var(--mo-surface-default);
    color: var(--mo-text-default-dark);
    font-size: var(--mo-font-size-body-md);
    font-weight: var(--mo-font-weight-bold);
    line-height: var(--mo-line-height-body-md);
}

.mo-drawer__user svg {
    width: var(--mo-scale-250);
    height: var(--mo-scale-250);
    flex: none;
}

.mo-drawer__list {
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 0;
    list-style: none;
}

.mo-drawer__item + .mo-drawer__item {
    border-top: 1px solid var(--mo-border-default-medium);
}

.mo-drawer__link {
    display: flex;
    height: var(--mo-scale-600);
    align-items: center;
    gap: var(--mo-spacing-xxs);
    padding: var(--mo-spacing-xs);
    border: 0;
    background: none;
    color: var(--mo-text-default-dark);
    font-family: inherit;
    font-size: var(--mo-font-size-body-md);
    font-weight: var(--mo-font-weight-regular);
    line-height: var(--mo-line-height-body-md);
    text-align: left;
    text-decoration: none;
    cursor: pointer;
}

.mo-drawer__link.is-active {
    color: var(--mo-text-action);
    font-weight: var(--mo-font-weight-bold);
}

.mo-drawer__link svg {
    width: var(--mo-scale-200);
    height: var(--mo-scale-200);
    flex: none;
}

.mo-drawer__link[aria-expanded='false'] svg {
    transform: rotate(180deg);
}

.mo-drawer__sublist {
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 0 0 var(--mo-spacing-xs);
    list-style: none;
}

.mo-drawer__sublist[hidden] {
    display: none;
}

.mo-drawer__sublink {
    display: block;
    padding: var(--mo-spacing-xxs) var(--mo-scale-300);
    border-radius: var(--mo-radius-sm);
    color: var(--mo-text-body);
    font-size: var(--mo-font-size-body-sm);
    font-weight: var(--mo-font-weight-medium);
    line-height: var(--mo-line-height-body-sm);
    text-decoration: none;
}

.mo-drawer__sublink.is-active,
.mo-drawer__sublink:hover,
.mo-drawer__sublink:focus-visible {
    color: var(--mo-text-action);
}

.mo-drawer__logout {
    display: flex;
    justify-content: center;
    padding: var(--mo-spacing-xxs);
    border: 0;
    background: none;
    color: var(--mo-text-body);
    font-family: inherit;
    font-size: var(--mo-font-size-body-sm);
    font-weight: var(--mo-font-weight-medium);
    line-height: var(--mo-line-height-body-sm);
    cursor: pointer;
}

.mo-drawer__logout:hover,
.mo-drawer__logout:focus-visible {
    color: var(--mo-text-action);
}

@media (min-width: 1440px) {
    .mo-drawer {
        display: none;
    }
}
