:root {
    --orbe-mobile-nav-height: calc(60px + env(safe-area-inset-bottom, 0px));
}

.mobile-bottom-nav { display: none; }

@media (max-width: 768px) {
    .mobile-bottom-nav {
        position: fixed;
        z-index: 1035;
        inset: auto 0 0;
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        height: var(--orbe-mobile-nav-height);
        padding: 0 max(.375rem, env(safe-area-inset-right)) env(safe-area-inset-bottom) max(.375rem, env(safe-area-inset-left));
        background: #fff;
        pointer-events: none;
    }

    .mobile-bottom-nav.is-ready { background: transparent; }

    .mobile-nav-surface,
    .mobile-nav-orb {
        position: absolute;
        display: none;
    }

    .mobile-bottom-nav.is-ready :is(.mobile-nav-surface, .mobile-nav-orb) { display: block; }

    .mobile-nav-surface {
        inset: 0;
        width: 100%;
        height: 100%;
        filter: drop-shadow(0 -3px 8px #24112d22);
    }

    .mobile-nav-fill { fill: #fff; }

    .mobile-nav-edge {
        fill: none;
        stroke: var(--store-line);
        stroke-width: 1;
    }

    .mobile-nav-orb {
        top: -18px;
        left: -18px;
        width: 36px;
        height: 36px;
        border-radius: 50%;
        background: linear-gradient(145deg, var(--store-chrome-end) -12%, var(--store-chrome-start) 112%);
        box-shadow: 0 2px 8px #27183540, inset 0 1px 0 #ffffff2a;
    }

    .mobile-nav-item {
        position: relative;
        display: flex;
        justify-content: center;
        align-items: end;
        height: 60px;
        min-width: 0;
        padding: 0 0 9px;
        border: 0;
        border-radius: 8px;
        background: transparent;
        color: #554c60;
        font-family: inherit;
        font-size: .6875rem;
        font-weight: 600;
        line-height: 1.25;
        text-align: center;
        text-decoration: none;
        pointer-events: auto;
        -webkit-tap-highlight-color: transparent;
    }

    .mobile-nav-item:focus-visible {
        outline: 2px solid var(--orbe-roxo);
        outline-offset: -3px;
    }

    .mobile-nav-item:is(:hover, :active, [aria-current], .is-selected) { color: var(--orbe-roxo); }

    .mobile-nav-icon {
        position: absolute;
        top: 13px;
        left: 50%;
        display: grid;
        place-items: center;
        width: 24px;
        height: 24px;
        font-size: 18px;
        transform: translateX(-50%);
        transition: transform .15s cubic-bezier(.2, .75, .3, 1), color .15s;
    }

    .mobile-bottom-nav.is-ready .is-selected .mobile-nav-icon {
        color: #fff;
        transform: translate(-50%, -17px);
    }

    #cart-badge-mobile {
        position: absolute;
        top: -4px;
        left: 65%;
        padding: 2px 4px;
        border: 1px solid #fff;
        font-size: 8px;
    }

    #cart-badge-mobile[data-empty] { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    .mobile-nav-icon { transition: none; }
}
