/**
 * Mega Menu V2 - Frontend Styles
 * Styles for the frontend tabbed mega menu display
 */

/* ============================================================================
   MENU WRAPPER & LAYOUT
   ============================================================================ */

.mega-menu-v2-wrapper {
    display: flex;
    gap: 20px;
    margin: 16px 0;
    flex-grow: 1;
}

/* ============================================================================
   TABS (LEFT SIDE)
   ============================================================================ */

.mega-menu-v2-tabs {
    display: flex;
    flex-direction: column;
    min-width: 180px;
    margin-top: 16px;
    width: 215px;
    justify-content: space-between;
}

.mega-menu-v2-tabs-inner {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.mega-menu-v2-tab[type=button] {
    padding: 10px 0px;
    background: 0;
    border: 0;
    border-radius: 0px;
    text-align: left;
    font-size: 14px;
    font-weight: 600;
    color: #000c5e;
    transition: all .3s ease;
    border-bottom: solid 1px #000c5e ;
}

.mega-menu-v2-tab[type=button]:last-child {
    border-bottom: none;
}

.mega-menu-v2-tab[type=button]:hover {
    background: 0;
    color: #000c5e;
}

.mega-menu-v2-tab[type=button].active {
    font-size: 16px;
    font-weight: 700;
    background: 0;
    color: #000c5e;
}


 /* Button styling */
.mega-menu-v2-tabs .watch-button {
    color: #000c5e;
    padding: 0;
    font-size: 14px;
    font-weight: 600;
    border: none;
}
         
/* Overlay styling */
 .media-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}
        
/* Media popup container */
 .media-popup {
    position: relative;
    width: 80%;
    max-width: 800px;
}
        
/* Video iframe responsive container */
 .video-container {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    height: 0;
    overflow: hidden;
}
        
 .video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}
        
/* Close button */
 .close-button {
    position: absolute;
    top: -40px;
    right: 0;
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
}
        
/* Media row styling */
.mega-menu-v2-tabs .media-row {
    padding: 10px 0;
    
    cursor: pointer;
    display: flex;
    justify-content: flex-start;
    border-radius: 0;
    align-items: center;
    gap: 5px;
}
.mega-menu-v2-tabs a {
    border-bottom: 1px solid #000c5e;
    display: flex;
}

.mega-menu-v2-tabs .media-row img {
    height: 8px;
}

/* ============================================================================
   CONTENT AREA (RIGHT SIDE)
   ============================================================================ */

.mega-menu-v2-content {
    flex: 1;
}

.mega-menu-v2-panel {
    display: none;
}

.mega-menu-v2-panel.active {
    display: flex;
    justify-content: flex-end;
}
/* ============================================================================
   MENU GRID
   ============================================================================ */

.mega-menu-v2-content .mega-menu-grid {
    display: grid;
    gap: 40px 0px;
    margin: 0;
    padding: 0;
    border-bottom: 0;
}

/* Grid column variations */
.mega-menu-grid[data-columns="2"] {
    grid-template-columns: repeat(2, 1fr);
}

.mega-menu-grid[data-columns="3"] {
    grid-template-columns: repeat(3, 1fr);
}

.mega-menu-grid[data-columns="4"] {
    grid-template-columns: repeat(4, 1fr);
}

.mega-menu-grid[data-columns="5"] {
    grid-template-columns: repeat(5, 1fr);
}

/* ============================================================================
   MENU ITEMS
   ============================================================================ */

.mega-menu-v2-content .mega-menu-item {
    position: relative;
    overflow: hidden;
    width: 100%;
    padding: 12px;
}

.mega-menu-v2-content .mega-menu-item a {
    display: flex;
    flex-direction: column-reverse;
    gap: 12px;
    justify-content: flex-end;
}

.mega-menu-v2-content .mega-menu-link {
    display: block;
    text-decoration: none;
    color: inherit;
    height: 100%;
}

.mega-menu-v2-content .mega-menu-item:hover .mega-menu-image-wrapper {
    box-shadow: 2px 5px 10px rgba(0, 0, 0, .1);
}

/* ============================================================================
   ITEM IMAGES
   ============================================================================ */

.mega-menu-v2-content .mega-menu-image-wrapper {
    position: relative;
    width: 100%;
    overflow: hidden;
    background: #f5f5f5;
    height: 160px;
    border-radius: 8px;
    transition: box-shadow 0.3s ease;
}

.mega-menu-v2-content .mega-menu-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100% !important;
    object-fit: cover;
}

/* ============================================================================
   NEW BADGE OVERLAY
   ============================================================================ */

.mega-menu-badge-new {
    position: absolute;
    top: -10px;
    right: -40px;
    background: #000c5e;
    color: #fff;
    padding: 25px 40px 5px;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    transform: rotate(45deg);
    z-index: 10;
}

/* ============================================================================
   ITEM TEXT
   ============================================================================ */

.mega-menu-v2-content .mega-menu-text {
    padding-bottom: 0px;
    display: flex;
    justify-content: space-between;
    gap: 10px;
    align-items: flex-start;
}

.mega-menu-v2-content .mega-menu-text img {
    width: 10px;
    margin-right: 5px;
}

.mega-menu-v2-content .mega-menu-title {
    color: #000527;
    font-family: Poppins, sans-serif;
    font-size: 16px;
    font-style: normal;
    font-weight: 700;
    line-height: 120%;
}

.mega-menu-v2-content span.mega-menu-title img {
    width: 7px;
    margin-left: 6px;
}

.mega-menu-v2-content .mega-menu-link:hover .mega-menu-title {
    text-decoration: underline;
}

/* ============================================================================
   RESPONSIVE DESIGN
   ============================================================================ */

/* Tablet and below */
@media (max-width: 768px) {
    .mega-menu-v2-wrapper {
        flex-direction: column;
    }
    
    .mega-menu-v2-tabs {
        flex-direction: row;
        overflow-x: auto;
        min-width: auto;
    }
    
    .mega-menu-v2-tab {
        white-space: nowrap;
    }
    
    .mega-menu-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 15px;
    }
}

/* Mobile */
@media (max-width: 480px) {
    .mega-menu-grid {
        grid-template-columns: 1fr !important;
        gap: 10px;
    }
}
