/* ============================================
   MEGA MENU - GTrack Módulos Categorizados
   5 Columnas con iconos y descripciones
   ============================================ */

/* Container del Mega Menu */
.wsmenu > .wsmenu-list > li.mega-menu-parent > .wsmegamenu.mega-menu-modules {
    width: 100%;
    left: 0;
    padding: 30px 0;
    background: #fff;
    border-radius: 0 0 16px 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    border-top: 3px solid var(--primary-color, #3b82f6);
}

/* Grid de 5 columnas */
.mega-menu-modules .row {
    display: flex;
    flex-wrap: wrap;
}

.mega-menu-modules .col {
    flex: 0 0 20%;
    max-width: 20%;
    padding: 0 15px;
}

/* Columnas del Mega Menu */
.mega-menu-column {
    border-right: 1px solid #f0f4f8;
    padding-bottom: 20px;
}

.mega-menu-column:last-child {
    border-right: none;
}

/* Títulos de Categoría */
.mega-menu-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: #1a1a2e;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid #3b82f6;
}

.mega-menu-title span {
    font-size: 18px;
    color: #3b82f6;
    width: 24px;
    text-align: center;
}

/* Lista de Links */
.mega-menu-modules .link-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.mega-menu-modules .link-list li {
    border-bottom: none !important;
    margin-bottom: 4px;
}

.mega-menu-modules .link-list li a {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px 12px;
    font-size: 14px;
    font-weight: 500;
    color: #444;
    border-radius: 8px;
    transition: all 0.25s ease;
    text-decoration: none;
}

.mega-menu-modules .link-list li a:hover {
    background: linear-gradient(135deg, #f0f7ff 0%, #e8f4ff 100%);
    color: #3b82f6;
    transform: translateX(4px);
}

.mega-menu-modules .link-list li a > span {
    font-size: 18px;
    color: #94a3b8;
    transition: color 0.25s ease;
    margin-top: 2px;
    flex-shrink: 0;
}

.mega-menu-modules .link-list li a:hover > span {
    color: #3b82f6;
}

/* Contenido del link */
.mega-menu-modules .link-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.mega-menu-modules .link-content strong {
    font-size: 14px;
    font-weight: 600;
    color: #1a1a2e;
    transition: color 0.25s ease;
}

.mega-menu-modules .link-list li a:hover .link-content strong {
    color: #3b82f6;
}

.mega-menu-modules .link-content small {
    font-size: 11px;
    font-weight: 400;
    color: #94a3b8;
    line-height: 1.3;
}

/* Footer del Mega Menu */
.mega-menu-footer {
    margin-top: 25px;
    padding: 20px 0 0;
    border-top: 1px solid #f0f4f8;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
}

.mega-menu-footer p {
    margin: 0;
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

.mega-menu-footer .btn {
    padding: 10px 24px;
    font-size: 13px;
    font-weight: 600;
}

/* ============================================
   RESPONSIVE: Tablet (< 1200px)
   ============================================ */
@media (max-width: 1199px) {
    .mega-menu-modules .col {
        flex: 0 0 33.333%;
        max-width: 33.333%;
        margin-bottom: 25px;
    }

    .mega-menu-column:nth-child(3) {
        border-right: none;
    }

    .mega-menu-column:nth-child(4),
    .mega-menu-column:nth-child(5) {
        border-right: 1px solid #f0f4f8;
    }

    .mega-menu-column:nth-child(5) {
        border-right: none;
    }
}

/* ============================================
   RESPONSIVE: Mobile (< 992px)
   ============================================ */
@media (max-width: 991px) {
    .wsmenu > .wsmenu-list > li.mega-menu-parent > .wsmegamenu.mega-menu-modules {
        position: relative;
        width: 100% !important;
        left: auto !important;
        padding: 0 !important;
        border-radius: 0;
        box-shadow: none;
        border-top: none;
        background: #f8fafc;
    }

    .mega-menu-modules .container {
        padding: 0;
    }

    .mega-menu-modules .row {
        display: block;
    }

    .mega-menu-modules .col {
        flex: 0 0 100%;
        max-width: 100%;
        padding: 0;
    }

    .mega-menu-column {
        border-right: none;
        border-bottom: 1px solid #e5e7eb;
        padding: 15px 20px;
        margin-bottom: 0;
    }

    .mega-menu-column:last-child {
        border-bottom: none;
    }

    .mega-menu-title {
        margin-bottom: 12px;
        padding-bottom: 8px;
        font-size: 11px;
    }

    .mega-menu-modules .link-list li a {
        padding: 8px 0;
    }

    .mega-menu-modules .link-content small {
        display: none;
    }

    .mega-menu-footer {
        flex-direction: column;
        gap: 12px;
        padding: 20px;
        background: #fff;
    }

    .mega-menu-footer .btn {
        width: 100%;
    }
}

/* ============================================
   ANIMACIONES
   ============================================ */
.wsmenu > .wsmenu-list > li.mega-menu-parent > .wsmegamenu.mega-menu-modules {
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
}

.wsmenu > .wsmenu-list > li.mega-menu-parent:hover > .wsmegamenu.mega-menu-modules {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* ============================================
   TEMAS DE COLOR POR CATEGORÍA
   ============================================ */

/* Operación - Azul */
.mega-menu-column:nth-child(1) .mega-menu-title {
    border-bottom-color: #3b82f6;
}
.mega-menu-column:nth-child(1) .mega-menu-title span {
    color: #3b82f6;
}
.mega-menu-column:nth-child(1) .link-list li a:hover {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
}
.mega-menu-column:nth-child(1) .link-list li a:hover > span,
.mega-menu-column:nth-child(1) .link-list li a:hover .link-content strong {
    color: #3b82f6;
}

/* Cumplimiento - Verde */
.mega-menu-column:nth-child(2) .mega-menu-title {
    border-bottom-color: #10b981;
}
.mega-menu-column:nth-child(2) .mega-menu-title span {
    color: #10b981;
}
.mega-menu-column:nth-child(2) .link-list li a:hover {
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
}
.mega-menu-column:nth-child(2) .link-list li a:hover > span,
.mega-menu-column:nth-child(2) .link-list li a:hover .link-content strong {
    color: #10b981;
}

/* Personas - Púrpura */
.mega-menu-column:nth-child(3) .mega-menu-title {
    border-bottom-color: #8b5cf6;
}
.mega-menu-column:nth-child(3) .mega-menu-title span {
    color: #8b5cf6;
}
.mega-menu-column:nth-child(3) .link-list li a:hover {
    background: linear-gradient(135deg, #f5f3ff 0%, #ede9fe 100%);
}
.mega-menu-column:nth-child(3) .link-list li a:hover > span,
.mega-menu-column:nth-child(3) .link-list li a:hover .link-content strong {
    color: #8b5cf6;
}

/* Finanzas - Naranja */
.mega-menu-column:nth-child(4) .mega-menu-title {
    border-bottom-color: #f59e0b;
}
.mega-menu-column:nth-child(4) .mega-menu-title span {
    color: #f59e0b;
}
.mega-menu-column:nth-child(4) .link-list li a:hover {
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
}
.mega-menu-column:nth-child(4) .link-list li a:hover > span,
.mega-menu-column:nth-child(4) .link-list li a:hover .link-content strong {
    color: #f59e0b;
}

/* Inteligencia - Cian */
.mega-menu-column:nth-child(5) .mega-menu-title {
    border-bottom-color: #06b6d4;
}
.mega-menu-column:nth-child(5) .mega-menu-title span {
    color: #06b6d4;
}
.mega-menu-column:nth-child(5) .link-list li a:hover {
    background: linear-gradient(135deg, #ecfeff 0%, #cffafe 100%);
}
.mega-menu-column:nth-child(5) .link-list li a:hover > span,
.mega-menu-column:nth-child(5) .link-list li a:hover .link-content strong {
    color: #06b6d4;
}

/* ============================================
   WHATSAPP FLOATING BUTTON
   ============================================ */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    z-index: 9999;
    transition: all 0.3s ease;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(37, 211, 102, 0.5);
}

.whatsapp-float span {
    font-size: 32px;
    color: #fff;
}

@media (max-width: 768px) {
    .whatsapp-float {
        bottom: 20px;
        right: 20px;
        width: 55px;
        height: 55px;
    }

    .whatsapp-float span {
        font-size: 28px;
    }
}
