/* CSS Responsivo para Menu e Footer da Central */
/* Este arquivo deve ser incluído em todas as páginas da central */

/* ============================================
   MENU RESPONSIVO
   ============================================ */

/* Mostrar botão hambúrguer no mobile */
@media (max-width: 860px) {
    .nav__toggle {
        display: flex !important;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        font-size: 1.3rem;
        z-index: 10000;
        position: relative;
    }

    /* Botão X ao lado do hambúrguer (só aparece quando o menu está aberto) */
    .nav__toggle--close{
        display: none !important;
        margin-left: 8px;
        z-index: 10001;
    }
    html.nav-is-open .nav__toggle--close{
        display: flex !important;
    }

    .nav__list {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        width: 100% !important;
        height: 100vh !important;
        max-height: 100vh !important;
        min-height: 100vh !important;
        background: linear-gradient(180deg, rgba(7,10,18,.98), rgba(7,10,18,.95)) !important;
        backdrop-filter: blur(20px) !important;
        flex-direction: column !important;
        align-items: stretch !important;
        padding: 70px 20px 20px 20px !important;
        gap: 8px !important;
        overflow-y: auto !important;
        z-index: 9999 !important;
        display: flex !important;
        transform: translateX(-100%) !important;
        transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1) !important;
        box-shadow: 4px 0 24px rgba(0,0,0,.4) !important;
        margin: 0 !important;
        box-sizing: border-box !important;
        opacity: 0;
        pointer-events: none;
    }

    .nav__list.is-open {
        transform: translateX(0) !important;
        opacity: 1 !important;
        pointer-events: auto !important;
    }

    .nav__item {
        width: 100%;
    }

    .nav__link {
        width: 100%;
        justify-content: space-between;
        padding: 14px 16px;
        border-radius: 12px;
        border: 1px solid rgba(255,255,255,.08);
        transition: all 0.2s ease;
        cursor: pointer;
        user-select: none;
        -webkit-tap-highlight-color: transparent;
    }

    .nav__link:hover {
        background: rgba(255,255,255,.06);
        border-color: rgba(255,255,255,.12);
    }

    .nav__item--dropdown > .nav__link {
        padding-right: 12px;
        cursor: pointer !important;
        pointer-events: auto !important;
    }

    .nav__link--btn {
        cursor: pointer !important;
        pointer-events: auto !important;
    }

    /* Ícone de seta do dropdown com animação */
    .nav__item--dropdown > .nav__link .la-angle-down {
        transition: transform 0.3s ease;
    }

    .nav__item--dropdown.is-open > .nav__link .la-angle-down {
        transform: rotate(180deg);
    }

    /* Dropdown no mobile - override completo dos estilos desktop */
    .nav__item--dropdown .dropdown {
        position: static !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: auto !important;
        margin-top: 8px !important;
        border: 1px solid rgba(255,255,255,.08) !important;
        background: rgba(13,18,32,.6) !important;
        border-radius: 12px !important;
        padding: 0 !important;
        display: block !important;
        opacity: 0 !important;
        max-height: 0 !important;
        overflow: hidden !important;
        visibility: hidden !important;
        box-shadow: none !important;
        left: auto !important;
        right: auto !important;
        top: auto !important;
        transition: opacity 0.25s ease, max-height 0.3s ease, padding 0.3s ease, margin 0.3s ease, visibility 0s 0.3s !important;
    }

    .nav__item--dropdown.is-open .dropdown,
    .nav__item--dropdown.is-open > .dropdown {
        opacity: 1 !important;
        max-height: 600px !important;
        padding: 8px !important;
        visibility: visible !important;
        transition: opacity 0.25s ease, max-height 0.3s ease, padding 0.3s ease, margin 0.3s ease, visibility 0s 0s !important;
    }

    /* Garantir que apenas o is-open funcione no mobile */
    .nav__item--dropdown:not(.is-open) .dropdown {
        opacity: 0 !important;
        max-height: 0 !important;
        visibility: hidden !important;
        padding: 0 !important;
    }

    .nav__item--align-right > .dropdown {
        left: 0 !important;
        right: auto !important;
    }

    /* Carrinho no mobile */
    .nav__item--cart {
        margin-top: auto !important;
        padding-top: 16px !important;
        border-top: 1px solid rgba(255,255,255,.1) !important;
    }

    .nav__cart {
        width: 100% !important;
        height: 48px !important;
        justify-content: center !important;
        font-size: 1rem !important;
        margin-left: 0 !important;
    }

    .nav__cart i {
        font-size: 1.4rem !important;
    }

    .nav__cartBadge {
        top: -4px !important;
        right: auto !important;
        left: calc(50% + 16px) !important;
    }
}

/* Ajustes para telas muito pequenas */
@media (max-width: 480px) {
    .topbar__inner {
        padding: 12px 0;
    }

    .brand__logo {
        height: 24px;
    }

    .nav__toggle {
        padding: 8px;
        font-size: 1.2rem;
    }

    .nav__list {
        padding: 70px 16px 16px 16px !important;
    }

    .nav__user-name {
        display: none; /* Ocultar texto "Olá, Nome" em telas muito pequenas */
    }
}

/* ============================================
   FOOTER RESPONSIVO
   ============================================ */

@media (max-width: 980px) {
    .footer__inner {
        flex-direction: column;
        gap: 30px;
    }

    .footer__left,
    .footer__center,
    .footer__right {
        flex: 1 1 100%;
        min-width: 100%;
    }

    .footer__links {
        gap: 20px;
    }

    .footer__links-group {
        flex: 1 1 calc(50% - 10px);
        min-width: calc(50% - 10px);
    }
}

@media (max-width: 580px) {
    .footer {
        padding: 40px 0 20px;
    }

    .footer__inner {
        gap: 24px;
    }

    .footer__logo {
        max-height: 36px;
    }

    .footer__tagline {
        font-size: .85rem;
    }

    .footer__links {
        flex-direction: column;
        gap: 24px;
    }

    .footer__links-group {
        flex: 1 1 100%;
        min-width: 100%;
    }

    .footer__social-links {
        justify-content: flex-start;
    }

    .footer__bottom-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .footer__badges {
        width: 100%;
        justify-content: flex-start;
    }
}

/* ============================================
   AJUSTES GERAIS PARA MOBILE
   ============================================ */

@media (max-width: 860px) {
    .container {
        padding-left: 16px;
        padding-right: 16px;
    }

    /* Garantir que o menu não sobreponha conteúdo */
    main {
        padding-top: 0;
    }
}
