/**
 * Smiley Dynamic Menu Header v3.3.0
 * + Botón APP RUTA PUCÓN integrado
 * Colores: Verde #33cc33, Rojo #ff0000, Amarillo #fbbf24
 */

:root {
    --smiley-green: #33cc33;
    --smiley-red: #ff0000;
    --smiley-yellow: #fbbf24;
    --smiley-dark: #1a202c;
    --smiley-gray: #6b7280;
}

/* ==================== 
   WRAPPER PRINCIPAL
   ==================== */
.smiley-menu-wrapper {
    width: 100%;
    position: relative;
}

.smiley-nav-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
    align-items: center;
    padding: 12px 0;
    background: transparent;
    position: relative;
    z-index: 100;
    min-height: 52px;
    flex-wrap: wrap;
}

/* ==================== 
   BOTONES BASE - Estados por defecto
   ==================== */
.smiley-nav-btn,
.smiley-app-btn,
.smiley-categories-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: white;              /* Por defecto: BLANCO */
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    color: var(--smiley-dark);      /* Por defecto: TEXTO NEGRO */
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    min-height: 48px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    white-space: nowrap;
}

/* Hover genérico para botones inactivos (blancos) */
.smiley-nav-btn:hover,
.smiley-app-btn:hover,
.smiley-categories-btn:hover {
    border-color: var(--smiley-green);
    background: #f9fafb;
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(51, 204, 51, 0.25);
}

/* ==================== 
   ESTADOS ACTIVOS (Verde con texto blanco)
   ==================== */

/* Cualquier botón con clase .active = VERDE */
.smiley-nav-btn.active,
.smiley-app-btn.active,
.smiley-categories-btn.active {
    background: var(--smiley-green);    /* Fondo VERDE */
    color: white;                       /* Texto BLANCO */
    border-color: var(--smiley-green);
    box-shadow: 0 3px 10px rgba(51, 204, 51, 0.3);
}

/* Hover para botones activos (verdes) */
.smiley-nav-btn.active:hover,
.smiley-app-btn.active:hover,
.smiley-categories-btn.active:hover {
    background: #2eb82e;                /* Verde oscuro */
    border-color: #2eb82e;
    box-shadow: 0 4px 14px rgba(51, 204, 51, 0.4);
}

/* ==================== 
   BOTÓN DESCUBRE cuando está abierto
   ==================== */
.smiley-categories-btn.open {
    background: var(--smiley-yellow);   /* Amarillo cuando abre menú */
    border-color: var(--smiley-yellow);
    color: var(--smiley-dark);
    box-shadow: 0 4px 14px rgba(251, 191, 36, 0.4);
}

/* ==================== 
   ICONOS Y TEXTO
   ==================== */
.smiley-nav-btn .icon,
.smiley-app-btn .icon,
.smiley-categories-btn .icon {
    font-size: 20px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.smiley-nav-btn .text,
.smiley-app-btn .text,
.smiley-categories-btn .text {
    font-size: 15px;
    line-height: 1.2;
}

/* ==================== 
   MENÚ DESPLEGABLE
   ==================== */
.smiley-menu-content {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    margin-top: 12px;
    width: auto;
    max-width: 700px;
    min-width: 600px;
    overflow: visible;
    z-index: 9999;
    background: white;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    border-radius: 14px;
    display: none;
}

/* Ocultar toggle interno del mega-menu */
.smiley-menu-content .smiley-mega-menu .menu-toggle {
    display: none !important;
}

/* Mostrar dropdown directamente */
.smiley-menu-content .smiley-mega-menu .mega-menu-dropdown {
    display: block !important;
    position: static !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
    width: 100% !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    margin: 0 !important;
    padding: 28px 32px !important;
}

.smiley-menu-content .smiley-mega-menu .mega-menu-content {
    display: grid !important;
    width: 100% !important;
    gap: 40px !important;
}

.smiley-menu-content .smiley-mega-menu .menu-column {
    min-width: 0 !important;
}

/* ==================== 
   RESPONSIVE TABLET
   ==================== */
@media (max-width: 1200px) {
    .smiley-nav-buttons {
        gap: 10px;
    }
    
    .smiley-menu-content {
        max-width: 90%;
        min-width: 500px;
    }
}

@media (max-width: 1024px) {
    .smiley-nav-btn,
    .smiley-app-btn,
    .smiley-categories-btn {
        padding: 10px 16px;
        font-size: 14px;
        min-height: 44px;
    }
    
    .smiley-nav-btn .icon,
    .smiley-app-btn .icon,
    .smiley-categories-btn .icon {
        font-size: 18px;
    }
    
    .smiley-nav-btn .text,
    .smiley-app-btn .text,
    .smiley-categories-btn .text {
        font-size: 14px;
    }
}

/* ==================== 
   RESPONSIVE MÓVIL
   ==================== */
@media (max-width: 768px) {
    .smiley-nav-buttons {
        gap: 8px;
        padding: 10px;
        justify-content: center;
    }
    
    .smiley-nav-btn,
    .smiley-app-btn,
    .smiley-categories-btn {
        padding: 9px 14px;
        font-size: 13px;
        min-height: 42px;
        gap: 6px;
    }
    
    .smiley-nav-btn .icon,
    .smiley-app-btn .icon,
    .smiley-categories-btn .icon {
        font-size: 16px;
    }
    
    .smiley-nav-btn .text,
    .smiley-app-btn .text,
    .smiley-categories-btn .text {
        font-size: 13px;
    }
    
    /* APP button: Ocultar texto en móvil muy pequeño */
    .smiley-app-btn .text {
        display: none;
    }
    
    .smiley-app-btn .icon {
        font-size: 20px;
    }
    
    /* Menú fullscreen en móvil */
    .smiley-menu-content {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        transform: none;
        max-width: 100%;
        min-width: 100%;
        margin: 0;
        border-radius: 0;
        overflow-y: auto;
    }
    
    .smiley-menu-content .smiley-mega-menu .mega-menu-dropdown {
        padding: 80px 20px 40px !important;
    }
}

/* ==================== 
   MÓVIL MUY PEQUEÑO
   ==================== */
@media (max-width: 480px) {
    .smiley-nav-buttons {
        gap: 6px;
    }
    
    .smiley-nav-btn,
    .smiley-app-btn,
    .smiley-categories-btn {
        padding: 8px 12px;
        font-size: 12px;
        min-height: 40px;
    }
    
    /* Todos los textos ocultos, solo iconos */
    .smiley-nav-btn .text,
    .smiley-categories-btn .text {
        display: none;
    }
    
    .smiley-nav-btn .icon,
    .smiley-app-btn .icon,
    .smiley-categories-btn .icon {
        font-size: 22px;
    }
}

/* ==================== 
   ACCESIBILIDAD
   ==================== */
.smiley-nav-btn:focus,
.smiley-app-btn:focus,
.smiley-categories-btn:focus {
    outline: 3px solid var(--smiley-yellow);
    outline-offset: 2px;
}

/* Animaciones suaves */
@media (prefers-reduced-motion: reduce) {
    .smiley-nav-btn,
    .smiley-app-btn,
    .smiley-categories-btn {
        transition: none;
    }
}

/* ==================== 
   ESTADOS ESPECIALES
   ==================== */

/* Cuando hay 4 botones, ajustar gap en desktop */
.smiley-nav-buttons:has(.smiley-app-btn) {
    gap: 14px;
}

/* Badge "NUEVO" opcional para el botón APP */
.smiley-app-btn::after {
    content: '';
    /* Puedes activar un badge "NUEVO" aquí si lo necesitas */
}

/* ==================== 
   BOTÓN APP - Sin icono, más compacto
   ==================== */
.smiley-app-btn {
    padding: 12px 24px;              /* Más compacto sin icono */
    gap: 0;                          /* Sin gap entre elementos */
    min-width: auto;                 /* Ancho automático */
}

.smiley-app-btn .icon {
    display: none;                   /* Ocultar icono */
}

.smiley-app-btn .text {
    font-size: 15px;

/* ========================================
   AJUSTE ALTURA HEADER - 80px
   ======================================== */

/* Reducir altura del wrapper del menú a 80px */
.smiley-menu-wrapper {
    min-height: 80px;
    max-height: 80px;
}

/* Ajustar padding vertical de los botones */
.smiley-nav-buttons {
    min-height: 80px;
    padding: 16px 0;
    align-items: center;
}

/* Los botones mantienen su altura pero se centran mejor */
.smiley-nav-btn,
.smiley-app-btn,
.smiley-categories-btn {
    min-height: 48px;  /* Mantener altura original */
}