:root {
  --CatMenuHeight: 66vh
}

.ecommerceNav {
  height: 100%;
  position: relative;
}


.ecommerceNav ::-webkit-scrollbar {
  width: 20px;
}

.ecommerceNav ::-webkit-scrollbar-track {
  background-color: transparent;
}

.ecommerceNav ::-webkit-scrollbar-thumb {
  background-color: var(--accent-color2);
  border-radius: 20px;
  border: 6px solid transparent;
  background-clip: content-box;
}

.CategoriesMenu {
  max-height: 0rem;
  top: 100%;
  box-shadow: 0.2rem 0.3rem 0.6rem rgba(0, 0, 0, 0.2);
  transition: all ease-in-out 0.3s;
}

.ecommerceNav .MenuButton {
  width: 100%;
  font-size: 1.1rem;
  background: var(--accent-color);
  border-radius: calc(var(--b-radius)* 2) calc(var(--b-radius)* 2) 0 0;
  position: relative;
  cursor: pointer;
  height: 3rem;
  color: var(--White);
}

.gap-2 {
  gap: 0.5rem
}

.ecommerceNav .MenuButton:after {
  bottom: 0.2rem;
  content: '';
  width: 0.4rem;
  height: 0.4rem;
  border: solid;
  border-width: 0 0.1rem 0.1rem 0;
  display: inline-block;
  padding: 0.2rem;
  transition: transform 300ms ease-in-out;
  background: transparent;
  transform: rotate(45deg);
  position: relative;
}

.ecommerceNav .MenuButton.active:after {
  transform: rotate(225deg);
}

.CategoriesMenu.active {
  max-height: var(--CatMenuHeight);
}

.CategoriesMenu :where(ul, li) {
  list-style-type: none;
  margin: 0;
  cursor: pointer;
  min-width: 12rem;
}

.CategoriesMenu .navbar-nav {
  overflow: auto;
  height: calc(var(--CatMenuHeight) - 2rem);
}

.CategoriesMenu .navbar-nav .AllProducts,
.CategoriesMenu .navbar-nav .AllProducts:hover {
  background-color: #f0f1f5;
  text-align: center;
  border: 0.1em solid rgba(0, 0, 0, 0.1);
}

.CategoriesMenu .navbar-nav>li {
  padding: 0.5rem 0;
  border-radius: 0.3rem;
  transition: all ease-in-out 0.3s;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--lsilver);
  border-radius: calc(infinity* 0.5px);
  margin-bottom: 0.5rem;
  width: calc(100% - 1rem);
  position: relative;
}

.CategoriesMenu .navbar-nav .parentMenu>a {
  text-align: center;
  display: block;
  width: 100%;
  color: var(--Black);
}

.CategoriesMenu .navbar-nav .parentMenu:hover>a {
  color: var(--White);
}

.CategoriesMenu .navbar-nav .parentMenu:hover::before {
  content: '';
  width: 20%;
  height: 3rem;
  border-right: 0.1rem solid var(--accent-color);
  position: absolute;
  border-radius: calc(infinity * 0.5px);
  right: -0.4rem;
}

.CategoriesMenu .navbar-nav>li:hover {
  background-color: var(--accent-color);
  margin-right: 1rem;
}

.CategoriesMenu .navbar-nav>li .CategoriesMenu .navbar-nav .AllProducts {
  background: var(--accent-color);
  border-radius: 0.3rem;
  text-align: center;
  padding: 0.3rem 0;
}

.CategoriesMenu .navbar-nav>li+.ThisCatAll,
.CategoriesMenu .navbar-nav>li+.ThisCatAll:hover {
  visibility: hidden;
  opacity: 0;
  background: var(--accent-color);
  border-radius: 0.3rem;
}

.CategoriesMenu .navbar-nav>li:hover+.ThisCatAll {
  visibility: visible;
  opacity: 1;
}

.CategoriesMenu .navbar-nav>.dropdown:hover>.dropdown-toggle+.dropdown-menu {
  opacity: 1;
  visibility: visible
}

.CategoriesMenu .navbar-nav>.dropdown>.dropdown-menu {
  position: absolute;
  top: 2rem;
  right: 20%;
  opacity: 0;
  visibility: hidden;
  transition: all ease-in-out 0.2s;
  height: calc(var(--CatMenuHeight) - 4rem);
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  margin-right: 3rem;
  overflow-x: auto;
  width: calc(80% - 4rem);

  >li {
    padding-left: 1rem;
    font-weight: bold;
  }

  .dropdown-menu {
    padding: 0.5rem;

    >li {
      display: flex;
      align-items: center;
      gap: 0.2rem;
      font-weight: normal;

      &.dropdown {
        flex-direction: column;
        align-items: self-start;
      }

      &:before {}
    }
  }
}

.CategoriesMenu a {
  display: block;
  color: rgba(0, 0, 0, 0.7);

}

.submenus {
  background: var(--lsilver);
  border-radius: 1rem;
  padding: 1rem;
}

.submenus .SubMenuBox {
  display: none;
  z-index: 999;
  width: 80%;
  height: 100%;
}

.submenus .SubMenuBox .sub-menu {
  display: flex;
  flex-direction: column;
  height: 100%;
  flex-wrap: wrap;
  max-height: calc(var(--CatMenuHeight) - 2rem);
}

.submenus .SubMenuBox .sub-menu>li>a {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  font-weight: bold
}

.submenus .SubMenuBox .sub-menu>li>a:before {
  content: '';
  width: 0.8rem;
  height: 0.8rem;
  display: block;
  border-radius: 50%;
  border: 0.1rem solid var(--accent-color);
}

.parentMenu:hover+.SubMenuBox {
  display: block;
}

.submenus .SubMenuBox .sub-menu>li .sub-sub-menu {
  padding-right: 1.5rem
}

.CategoriesMenu .ThisCatAll {
  bottom: 1rem;
  left: 1rem;
}

.CategoriesMenu .ThisCatAll a {
  color: var(--accent-color3);
  padding: 0 1rem;
}

.bg-blgsilver {
  background: rgb(240 241 245);
}