/* Menu mobile (sticky footer) · tema "Animado"
   Uma pílula com brilho desliza até o item ativo; o ícone dá um pulo ao chegar.
   Ligado em Sistema → Configurações → Menu Mobile (menu_mobile_tema = animado). */

.sticky-footer-mobile--animado {
    position: fixed;
    isolation: isolate;
}

.sticky-footer-mobile--animado .sticky-footer-item {
    position: relative;
    z-index: 1;
    -webkit-tap-highlight-color: transparent;
}

/* No tema animado quem marca o ativo é a pílula, não o "encolher" do tema clássico */
.sticky-footer-mobile--animado .sticky-footer-item.active,
.sticky-footer-mobile--animado .sticky-footer-item:active,
.sticky-footer-mobile--animado .sticky-footer-item:focus {
    transform: none;
}

.sticky-footer-mobile--animado .sticky-footer-item:active i,
.sticky-footer-mobile--animado .sticky-footer-item:active svg {
    transform: scale(0.88);
}

.sticky-footer-mobile--animado .sticky-footer-item:focus-visible {
    outline: 3px solid #1d4ed8;
    outline-offset: -3px;
    border-radius: 14px;
}

.sticky-footer-mobile--animado .sticky-footer-item.active {
    font-weight: 700;
}

.mm-indicador {
    position: absolute;
    z-index: 0;
    top: 8px;
    bottom: 8px;
    left: 0;
    width: 0;
    border-radius: 14px;
    background: rgba(15, 23, 42, 0.07);
    background: color-mix(in srgb, var(--cor-primaria, #2d2b52) 14%, transparent);
    overflow: hidden;
    pointer-events: none;
    opacity: 0;
    will-change: transform, width;
}

.mm-indicador.mm-pronto {
    opacity: 1;
}

.mm-indicador.mm-desliza {
    transition: transform 0.38s cubic-bezier(0.22, 1, 0.36, 1), width 0.38s cubic-bezier(0.22, 1, 0.36, 1);
}

/* O brilho: uma faixa clara que cruza a pílula uma vez, a cada chegada */
.mm-indicador::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(105deg, transparent 30%, rgba(255, 255, 255, 0.85) 50%, transparent 70%);
    transform: translateX(-120%);
}

.mm-indicador.mm-brilho::after {
    animation: mm-brilho 0.7s 0.1s ease-out forwards;
}

@keyframes mm-brilho {
    to {
        transform: translateX(120%);
    }
}

.sticky-footer-mobile--animado .sticky-footer-item.mm-pulo i,
.sticky-footer-mobile--animado .sticky-footer-item.mm-pulo svg {
    animation: mm-pulo 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes mm-pulo {
    0% {
        transform: scale(0.8) translateY(2px);
    }

    60% {
        transform: scale(1.18) translateY(-3px);
    }

    100% {
        transform: scale(1) translateY(0);
    }
}

@media (prefers-reduced-motion: reduce) {
    .mm-indicador.mm-desliza {
        transition: none;
    }

    .mm-indicador.mm-brilho::after,
    .sticky-footer-mobile--animado .sticky-footer-item.mm-pulo i,
    .sticky-footer-mobile--animado .sticky-footer-item.mm-pulo svg {
        animation: none;
    }
}
