/* ===== MEGA DROPDOWN ===== */
.mega-dropdown {
    position: static !important;
}

.mega-menu {
    position: absolute !important;
    top: 100% !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    background: #0c0d29 !important;
    border: none !important;
    border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 0 !important;
    margin-top: 0 !important;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.7) !important;
}

.mega-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    padding: 28px 40px;
    gap: 0;
}

.mega-col {
    padding: 0 28px;
    border-right: 1px solid rgba(255, 255, 255, 0.07);
}

.mega-col:first-child {
    padding-left: 0;
}

.mega-col-last {
    padding-right: 0;
    border-right: none;
}

.mega-section {
    margin-bottom: 22px;
}

.mega-section:last-child {
    margin-bottom: 0;
}

.mega-section-label {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.13em;
    color: rgba(255, 255, 255, 0.38);
    text-transform: uppercase;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    margin-top: 0;
}

.mega-label-icon {
    width: 13px;
    height: 13px;
    flex-shrink: 0;
}

.mega-item {
    display: flex;
    align-items: flex-start;
    gap: 11px;
    padding: 8px 10px;
    border-radius: 7px;
    text-decoration: none;
    color: #fff;
    transition: background 0.13s ease;
    margin-bottom: 2px;
}

a.mega-item:hover {
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
    text-decoration: none;
}

.mega-item-disabled {
    opacity: 0.5;
    cursor: default;
    pointer-events: none;
}

.mega-item-icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    margin-top: 1px;
}

.mega-item-content {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.mega-item-title {
    font-size: 13.5px;
    font-weight: 600;
    color: #fff;
    line-height: 1.3;
    display: block;
}

a.mega-item:hover .mega-item-title {
    color: #5ba3f5;
}

.mega-item-desc {
    font-size: 11.5px;
    color: rgba(255, 255, 255, 0.45);
    line-height: 1.5;
    display: block;
}

.mega-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 13px 40px;
    background: rgba(255, 255, 255, 0.03);
    border-top: 1px solid rgba(255, 255, 255, 0.07);
}

.mega-footer-text {
    font-size: 12.5px;
    color: rgba(255, 255, 255, 0.42);
}

.mega-footer-link {
    font-size: 13px;
    font-weight: 500;
    color: #5ba3f5;
    text-decoration: none;
    transition: color 0.13s ease;
}

.mega-footer-link:hover {
    color: #85bfff;
    text-decoration: none;
}

@media (max-width: 991.98px) {
    .mega-dropdown {
        position: relative !important;
    }

    .mega-menu {
        position: static !important;
        box-shadow: none !important;
        background: #0c0d29 !important;
        border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
    }

    .mega-grid {
        grid-template-columns: 1fr;
        padding: 12px 8px;
    }

    .mega-col {
        padding: 8px 0;
        border-right: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    }

    .mega-col-last {
        border-bottom: none;
    }

    .mega-footer {
        flex-direction: column;
        gap: 8px;
        text-align: center;
        padding: 12px 8px;
    }
}

/* ===== MEGA DROPDOWN ANIMATIONS ===== */
@keyframes megaPanelIn {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes megaPanelOut {
    from { opacity: 1; transform: translateY(0); }
    to   { opacity: 0; transform: translateY(-6px); }
}

@keyframes megaItemIn {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.mega-menu.show {
    animation: megaPanelIn 220ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.mega-menu-out {
    animation: megaPanelOut 170ms cubic-bezier(0.4, 0, 1, 1) both !important;
}

.mega-menu.show .mega-section {
    animation: megaItemIn 320ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.mega-menu.show .mega-col:nth-child(1) .mega-section:nth-child(1) { animation-delay: 55ms;  }
.mega-menu.show .mega-col:nth-child(2) .mega-section:nth-child(1) { animation-delay: 85ms;  }
.mega-menu.show .mega-col:nth-child(3) .mega-section:nth-child(1) { animation-delay: 115ms; }
.mega-menu.show .mega-col:nth-child(1) .mega-section:nth-child(2) { animation-delay: 95ms;  }
.mega-menu.show .mega-col:nth-child(2) .mega-section:nth-child(2) { animation-delay: 125ms; }
.mega-menu.show .mega-col:nth-child(3) .mega-section:nth-child(2) { animation-delay: 155ms; }

.mega-menu.show .mega-footer {
    animation: megaItemIn 320ms cubic-bezier(0.16, 1, 0.3, 1) both;
    animation-delay: 170ms;
}

@media (prefers-reduced-motion: reduce) {
    .mega-menu.show,
    .mega-menu.show .mega-section,
    .mega-menu.show .mega-footer {
        animation: none;
    }
}
