/* -------------------------------- 
Menu Base
-------------------------------- */

.display-menu{
    width: auto;
    display: none;
    opacity: 0;
}

.align-menu{
  width: 100%;
  display: flex;
}

@media only screen and (max-width: 920px) {
    
    .display-menu{
        width: 100%;
    }
    
    .columns{
        flex-wrap: nowrap;
    }
}

.sub-menu{
  -webkit-animation: swing-in-top-fwd 0.5s cubic-bezier(0.175, 0.885, 0.320, 1.275) both;
	        animation: swing-in-top-fwd 0.5s cubic-bezier(0.175, 0.885, 0.320, 1.275) both;
}

.wc-block-mini-cart__empty-cart-wrapper p{
    margin-bottom: 20px;
}

/* -------------------------------- 
Menu Responsive
-------------------------------- */
/* --- Desktop --- */

.menu-desktop {
    display: flex;
    gap: 2rem;
}

.menu-desktop ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
}

.menu-desktop ul li {
    position: relative;
}

.menu-desktop ul li a {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;  
    padding: 0.5rem 1rem;
    color: #eee;
    text-decoration: none;
    transition: all 0.4s ease;
    white-space: nowrap;
}

.menu-desktop ul li a:hover {
    background-color: transparent;
}

/* Dropdown submenu */
.menu-desktop ul li ul {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: #000000a3;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    min-width: 180px;
    border-radius: 4px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
    z-index: 1000;
    padding: 0.5rem 0;
    -webkit-animation: swing-in-top-fwd 0.5s cubic-bezier(0.175, 0.885, 0.320, 1.275) both;
	        animation: swing-in-top-fwd 0.5s cubic-bezier(0.175, 0.885, 0.320, 1.275) both;
}

.menu-desktop ul li:hover > ul {
    display: block;
}

.menu-desktop ul li ul li a {
    padding: 0.5rem 1rem;
    color: #ddd;
}

.menu-desktop ul li ul li a:hover {
    background-color: transparent;
}

/* Subsubmenu */
.menu-desktop ul li ul li ul {
    top: 0;
    left: 100%;
}

/* --- Mobile --- */

.menu-mobile {
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    height: 100dvh;
    overflow-y: auto;
    position: fixed;
    width: 100%;
    top: 0;
    left: 0;
    z-index: 1666;
}

.mobile-bg{
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: .8;
    z-index: -1;
}

.menu-mobile ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.menu-mobile ul li {
    position: relative;
    margin-bottom: 1rem;
}

.menu-mobile ul li a {
    color: white;
    text-decoration: none;
    display: inline-block;
    width: calc(100% - 2.5rem);
    vertical-align: middle;
}

.menu-mobile ul li .submenu-toggle {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 2rem;
    font-size: 1.5rem;
    color: white;
    background: transparent;
    border: none;
    cursor: pointer;
    user-select: none;
    line-height: 1.6rem;
    display: flex;
    align-items: flex-start;
}

/* Ocultar submenús por defecto */
.menu-mobile ul li ul {
    display: none;
    padding-left: 1rem;
    margin-top: 0.5rem;
}

/* Cuando está abierto */
.menu-mobile ul li.open > ul {
    display: block;
    -webkit-animation: swing-in-top-fwd 0.5s cubic-bezier(0.175, 0.885, 0.320, 1.275) both;
	        animation: swing-in-top-fwd 0.5s cubic-bezier(0.175, 0.885, 0.320, 1.275) both;
}

.menu-desktop .menu-item-has-children{
    backface-visibility: hidden;
    transform-style: preserve-3d;
}

.menu-desktop .menu-item-has-children > a svg[data-lucide] {
    transition: transform 0.4s ease;
    transform-origin: center;
    perspective: 400px; /* opcional, más realismo */
}

/* Rotar el ícono al pasar el mouse o al abrir */
.menu-desktop .menu-item-has-children:hover > a svg[data-lucide] {
    transform: translateY(6px)
}

.menu-mobile-header{
    padding: .8rem;
    border-bottom: 1px solid white;
}

.menu-mobile-header a{
	margin:auto;
	width:auto;
}

.menu-mobile-header a img{
    height: 100%;
    width: auto;
    max-height: 50px;
}

.menu-mobile-header-padding{
    padding: 1rem;
    height: calc(100dvh - 80px);
    overflow: auto;
}

/* Mostrar menú desktop solo en pantallas grandes */
@media (min-width: 1024px) {
    .menu-desktop {
        display: flex;
    }

    #menu-toggle {
        display: none; /* ocultar botón mobile en desktop */
    }

    .menu-mobile {
        display: none !important; /* asegurarse que el menú mobile no se muestre */
    }
}

/* Mostrar menú mobile solo en pantallas pequeñas */
@media (max-width: 1023px) {
    .menu-desktop {
        display: none;
    }

    #menu-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        background: transparent;
        border: none;
        font-size: 2rem;
        cursor: pointer;
        position: fixed;
        top: 1rem;
        right: 1rem;
        z-index: 1100;
        padding: 16px;
    }

    #menu-close {
        background: transparent;
        border: none;
        font-size: 2rem;
        position: absolute;
        top: 25px;
        right: 25px;
        z-index: 1100;
    }
}


/* -------------------------------- 
Menu Animations
-------------------------------- */

@-webkit-keyframes swing-in-top-fwd {
  0% {
    -webkit-transform: rotateX(-100deg);
            transform: rotateX(-100deg);
    -webkit-transform-origin: top;
            transform-origin: top;
    opacity: 0;
  }
  100% {
    -webkit-transform: rotateX(0deg);
            transform: rotateX(0deg);
    -webkit-transform-origin: top;
            transform-origin: top;
    opacity: 1;
  }
}
@keyframes swing-in-top-fwd {
  0% {
    -webkit-transform: rotateX(-100deg);
            transform: rotateX(-100deg);
    -webkit-transform-origin: top;
            transform-origin: top;
    opacity: 0;
  }
  100% {
    -webkit-transform: rotateX(0deg);
            transform: rotateX(0deg);
    -webkit-transform-origin: top;
            transform-origin: top;
    opacity: 1;
  }
}

