/* ------------------------------------------- /
/  Product Mega Menu Styles                    /
/  WooCommerce Category Column View menu       /
/  This is for the Header menu                 /
/ ------------------------------------------- */

/* Container for the entire column view */
#wc-column-view-container {
    display: flex; /* Enables the column layout */
    overflow-x: auto; /* Allows horizontal scrolling if columns exceed screen width */
    border: 1px solid #ddd;
    background-color: rgb(249, 249, 249, 0.5);
    white-space: nowrap; /* Prevent columns from wrapping */
    align-items: stretch; /* Forces all columns to be equal height */
    min-height: 400px; /* Optional: Sets a minimum height for the menu */
}

/* Style for each category column */
.wc-category-column {
	flex: 0 0 25%;
    border-right: 1px solid #ddd;
    min-height: 100%; /* Ensure it fills the flex container's height */
    overflow-y: auto; /* Enable vertical scrolling within the column */
    padding: 10px 0;
    list-style: none; /* Remove default list style */
}

/* First column dark background */
.wc-category-column:first-child {
	background-color: hsl(218, 98%, 19%);
}

/* Second column (30% opacity) */
.wc-category-column:nth-child(2) {
    background-color: hsla(218, 98%, 19%, 0.3);
}

/* Third column (20% opacity) */
.wc-category-column:nth-child(3) {
    background-color: hsla(218, 98%, 19%, 0.2);
}

/* Fourth column (10% opacity) */
.wc-category-column:nth-child(4) {
    background-color: hsla(218, 98%, 19%, 0.1);
}

.wc-category-column:last-child {
    border-right: none;
}

/* Column Heading Style */
.wc-category-column .wc-column-heading {
    margin: 0 0 10px 0;
    padding: 0 15px;
    font-size: 18px !important;
    font-weight: 700;
    line-height: 1.4;
    color: #00245d !important;
}

/* First column heading white */
.wc-category-column:first-child .wc-column-heading {
    color: #ffffff !important;
}

/* Style for the list inside the column */
.wc-category-column ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

/* Style for individual category items */
.wc-category-column li.category-item {
    padding: 8px 15px;
    cursor: pointer;
	color: #00245d;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.1s ease;
}

.wc-category-column li.category-item a {
	color: #00245d !important;
}

/* First column text white */
.wc-category-column:first-child li.category-item a {
	color: #ffffff !important;
}

/* First column hover/selected: invert colors */
.wc-category-column:first-child li.category-item:hover,
.wc-category-column:first-child li.category-item.selected {
    background-color: #ffffff;
}

.wc-category-column:first-child li.category-item:hover a,
.wc-category-column:first-child li.category-item.selected a {
    color: #01235e !important;
}

.wc-category-column:first-child li.category-item:hover .arrow-indicator,
.wc-category-column:first-child li.category-item.selected .arrow-indicator {
    color: #01235e !important;
}

.wc-category-column li.category-item:hover {
    background-color: #e5e5e5;
}

/* Style for the selected category item */
.wc-category-column li.category-item.selected {
	background-color: #f0f0f0;
}

.wc-category-column li.category-item.selected a {
	color: #95c93d!important;
	font-weight: 700;
}

.wc-category-column li.category-item.selected .arrow-indicator {
    color: #95c93d; /* Ensure arrow is visible on selected item */
}

/* Style for the indicator arrow */
.wc-category-column .arrow-indicator {
    font-size: 18px!important;
	font-weight: 700;
    margin-left: 10px;
    color: #00245d; /* Light grey arrow */
}

/* First column arrow white */
.wc-category-column:first-child .arrow-indicator {
	color: #ffffff;
}

/* "SEE ALL" Badge Style */
.wc-category-column li.category-item.see-all-item {
    margin-top: 10px;
    background-color: transparent !important; /* Ensure generic hover doesn't bleed */
}

.wc-category-column li.category-item.see-all-item a {
    display: inline-block;
    background-color:  hsl(218, 98%, 19%);
    color: #ffffff !important;
    font-size: 11px;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.2s ease;
}

.wc-category-column li.category-item.see-all-item:hover {
    background-color: transparent !important;
}

.wc-category-column li.category-item.see-all-item:hover a {
     background-color: #497637; /* Green on hover */
     color: #ffffff !important;
     text-decoration: none;
}


/* ------------------------------------------- /
/         Mobile Styles for Mega Menu         /
/ ------------------------------------------- */

@media screen and (max-width: 800px) {
    #wc-column-view-container {
        display: block; /* Stack handling manually for visibility control */
        overflow-x: hidden;
    }

    .wc-category-column {
        display: none; /* Hide all columns by default */
        width: 100%; /* Full width */
        flex: none;
        border-right: none;
        min-height: auto;
    }

    .wc-category-column.is-visible {
        display: block; /* Only show active/visible column */
    }

    /* Add a back button for navigation */
    .wc-category-mobile-back {
        display: block;
        padding: 10px 15px;
        background-color: #e5e5e5;
        color: #00245d;
        cursor: pointer;
        font-weight: bold;
        margin-bottom: 10px;
    }
    
    .wc-category-mobile-back:before {
        content: "← ";
    }
}

/* force submenus to be higher than everything */
.dsm-submenu-container {
	z-index: 9999 !important;
}
/* force search to be lower than submenus */
.et_pb_section_4_tb_header, .et_pb_section_5_tb_header {
    z-index: 0 !important;
}

/* force menu down below the logo */
.dsm_mega_menu_0_tb_header .dsm-root-menu .dsm-mega-menu-item:not(.dsm-native-menu) .dsm-submenu-container {
    padding-top: 30px !important;
}
