/* === Existing CSS === */
.main-dropdown-menu {
    display: inline-block;
    min-width: 25%;
    background: #eeece0;
    position: relative;
    top: 0px;
    padding-top: 10px;
    min-height:325px;
}

.sub-dropdown-menu {
    display: inline-block;
    position: relative;
}

.main-dropdown-menu > .dd-list a {
    display: block;
    padding: 8px 8px 8px 8px;
    margin-bottom: 5px;
    text-align: right;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    text-decoration: none;
    color: #000;
    margin-right: 0px;
}

.main-dropdown-menu > .dd-list > .sub-dropdown-menu {
    display: none;
    background-color: transparent;
    position: absolute;
    top: 0;
    bottom: 0;
    left: 100%;
    height: 100%;
    min-width: 100%;
    list-style: none;
    padding: 10px 0px 30px 0px;
    margin-top: auto;
    margin-bottom: auto;
    align-items: stretch;
}

.main-dropdown-menu .dd-list .sub-dropdown-menu .dd-list > a {
    /* background-color: white; */
    font-size: 14px;
    font-weight: 600;
    text-align: left;
    padding: 2px 8px 2px 15px;
    margin: 0px;
    color: #000000;
    font-weight: bold;
}

.main-dropdown-menu .dd-list .sub-dropdown-menu .dd-list > a:hover {
    background-color: #ffffff;  /* pick your hover background */
    color: #000000;                /* hover text color */
}

.main-dropdown-menu .dd-list:hover .sub-dropdown-menu {
    display: block;
}

.main-dropdown-menu > .dd-list > .sub-dropdown-menu > .dd-list > .sub-sub-dropdown-menu {
    display: none;
    position: absolute;
    top: 0;
    bottom: 0;
    left: 100%;
    height: 100%;
    min-width: 100%;
    list-style: none;
    padding: 10px 0px 30px 0px;
    margin-top: auto;
    margin-bottom: auto;
}

.main-dropdown-menu > .dd-list > .sub-dropdown-menu > .dd-list:hover .sub-sub-dropdown-menu {
    display: block;
}

/* === FIXES TO WORK WITH NAVBAR === */

/* Bootstrap show/hide hook */
.navbar .dropdown-menu {
  display: none;
  margin-top: 0;
  border: none;
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
  z-index: 1021; /* sit above other content */
}

.navbar .dropdown.show > .dropdown-menu {
  display: block;
}

/* Mega menu full width under a position-static parent */
.navbar .dropdown.position-static > .dropdown-menu.main-dropdown-menu {
  left: 0;
  right: 0;
  width: 100%;
  border-radius: 0;
  top: 100%;
}

/* Optional: smoother feel on desktop hover */
@media (min-width: 992px) {
  .navbar .dropdown-menu {
    transform: translateY(8px);
    opacity: 0;
    visibility: hidden;
    transition: transform 160ms ease, opacity 160ms ease, visibility 160ms;
  }
  .navbar .dropdown.show > .dropdown-menu {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
}

/* Mega menu link hover styling */
h3 a:hover,
ul li a:hover {
  text-decoration: none;
}

ul li a {
  color: black;
}

ul li a:hover,
ul li:hover {
  color: red;
}

/* Mega menu wrapper (full width dropdown) */
.dropdown-menu.mega-menu {
  left: 0 !important;
  right: 0 !important;
  width: 100%;
  margin-top: 0;
  border: none;
  border-radius: 0;
  background: transparent;
}

/* Prevent dropdown from hiding instantly */
.dropdown:hover>.dropdown-menu {
  display: block;
}
