.hs-menu-wrapper .hs-menu-children-wrapper { width: 100%; }

header .mega-menu .hs-menu-depth-1.item--dropdown {
  position: relative;
}

header .mega-menu .hs-menu-item a {
  white-space: nowrap;
}

header .mega-menu .item--mega.hs-menu-depth-1:hover > .hs-menu-children-wrapper {
  visibility: visible;
  opacity: 1;
  display: flex;
}

header .mega-menu .item--dropdown.hs-menu-depth-1:hover > .hs-menu-children-wrapper {
  visibility: visible;
  opacity: 1;
  display: block;
}

header .mega-menu ul li a {
  display: block;
}

header .mega-menu .hs-menu-depth-2 > .hs-menu-children-wrapper {
  opacity: 1 !important;
  left: 0 !important;
  position: relative !important;
}

header .mega-menu .hs-menu-wrapper > ul li.hs-menu-depth-1 > ul > li > ul > li:hover > a {
  background-color: #0085BB;
  color: white !important;
  border-radius: 8px;
}

header .mega-menu .hs-menu-depth-2 > .hs-menu-children-wrapper {
  opacity: 1 !important;
  left: 0 !important;
  position: relative !important;
  flex-direction: column !important;
}

.mega-search__trigger-wrapper {
  position: relative;
  height: 0;
  width: 0;
  right: 70px;
  margin-left: auto;
}

.mega-search__trigger {
  position: relative;
  top: 3px;
  z-index: 2;
}

.mega-search__trigger svg {
  width: 20px;
  height: 20px;
}

.mega-search {
  position: absolute;
  top: 0;
  left: 0;
  visibility: hidden;
  opacity: 0;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  background-color: rgba(0,0,0,0.5);
  height: 100vh;
  width: 100%;
  padding: 16px;
  z-index: 9;
  transition: opacity .2s ease;
}
@media(max-width: 578px) {
  .mega-search {
    width: 100vw;
  }  
}

.mega-search.active {
  visibility: visible;
  opacity: 1;
}

.mega-search__box {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 700px;
  background-color: #ffffff;
  margin-top: 20vh;
  padding: 40px;
}

.mega-search__close-wrapper {
  position: relative;
  width: 0;
  height: 0;
  align-self: flex-end;
}

.mega-search__close {
  position: absolute;
  top: -35px;
  right: -35px;
  background-color: transparent;
  padding: 0;
  border: none;
  cursor: pointer;
}

.mega-search__close svg {
  transform: rotate(45deg);
  width: 30px;
  height: 30px;
}

.mega-search__form {
  display: flex;
  padding: 0 !important;
  background-color: transparent !important;
}

.mega-search__input {
  width: 100%;
}

.mega-search__button-wrapper {
  position: relative;
  width: 0;
  height: 0;
}

.mega-search__box .search-submit {
  position: absolute;
  left: -40px;
  top: 50%;
  background-color: transparent;
  padding: 0;
  border: none;
  cursor: pointer;
}

.mega-search__box .search-submit svg {
  width: 20px;
  height: 20px;
}

@media screen and (min-width: 1101px) {
  .mega-menu .item--mega .hs-menu-children-wrapper {
    flex-direction: row;
    padding-left: calc(50% - calc(1280px/2)) !important;
    padding-right: calc(50% - calc(1280px/2)) !important;
  }
  header .mega-menu .mega-menu__inner {
    display: flex;
    align-items: center;
    justify-content: flex-end;
  }
  .mega-mobile-only {
    display: none;
    visibility: hidden;
  }
  header .mega-menu .hs-menu-depth-1.item--mega > .hs-menu-children-wrapper {
    position: absolute;
    top: 130px;
    left: 0;
    width: 100%;
    visibility: hidden;
    opacity: 0;
    display: none;
  }
  header .mega-menu .hs-menu-depth-1.item--dropdown > .hs-menu-children-wrapper {
    position: absolute;
    top: 100%;
    left: 50% !important;
    transform: translateX(-50%);
    width: auto;
    visibility: hidden;
    opacity: 0;
    display: none;
  }

  header .mega-menu .hs-menu-depth-1 > .hs-menu-children-wrapper {
    background-color: #F8F8F8;
  }

  header .mega-menu .hs-menu-depth-1 > .hs-menu-children-wrapper {
    background-color: #F8F8F8;
    align-items: stretch !important;
  }

  header .mega-menu .item--mega .hs-menu-depth-2 + * {
    padding-left: 20px;
    border-left: 1px solid #D6D6D6;
    margin-left: 20px;
  }
  header .mega-menu .item--dropdown li {
    width: 100%;
  }
}

.mega-menu--toggle {
  cursor: pointer;
}

.hs-menu-item > .submenu-trigger {
  display: none;
}
@media (max-width:992px){
  .mega-menu.active > .mega-menu__inner{
  top:35%!important;
  }
}
@media screen and (max-width: 1100px) {
  .mega-menu:not(.active) {
    display: none;
    visibility: hidden;
    opacity: 0;
  }
  .mega-menu--toggle.toggle--open {
    width: max-content;
    margin-left: auto;
    text-align: right;
    cursor: pointer;
  }

  .mega-menu.active {
    position: fixed;
    top: 0;
    left: 0;
    background-color: white;
    padding: 30px;
    z-index: 999;
    width: 100%;
    height: 100%;
  }
  .mega-menu.active > .mega-menu__inner {
    position: absolute;
    top: 50%;
    left: 50%;
    padding: 30px;
    transform: translate(-50%,-50%);
    width: min(700px, 80%);
  }
  .mega-menu--toggle.toggle--close.mega-mobile-only {
    text-align: right;
    margin-bottom: 40px;
  }
  .hs-menu-wrapper ul {
    flex-direction: column;
  }
  .mega-menu__cta {
    text-align: center;
    margin: 30px auto;
  }
  .mega-menu__cta > * {
    width: 100%;
  }
  header .mega-menu .hs-menu-wrapper > ul li.hs-menu-depth-1 > .hs-menu-children-wrapper {
    display: none;
  }
  header .mega-menu .hs-menu-wrapper > ul li.hs-menu-depth-1 > ul > li > ul {
    display: none;
  }
  header .mega-menu .hs-menu-wrapper > ul li.hs-menu-depth-1 > .hs-menu-children-wrapper {
    padding: 1rem;
    background-color: transparent !important;
  }
  header .mega-menu .hs-menu-wrapper > ul li.hs-menu-depth-1 > .hs-menu-children-wrapper > li {
    border: none;
  }
  .hs-menu-item {
    position: relative;
  }
  .mega-menu {
    padding: 0 !important;
  }
  .hs-menu-item > .hs-menu-children-wrapper {
    position: relative;
    transition: max-height .5s ease-in-out, , padding .5s ease-in-out;
  }
  .hs-menu-children-wrapper {
    max-height: 0;
    height: auto;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    display: block;
    padding: 0 !important;
  }
  .hs-menu-item.active > .hs-menu-children-wrapper {
    max-height: 1000px;
    opacity: 1 !important;
    visibility: visible;
    padding: 0 0 1rem 1rem !important;
    display: block !important;
  }
  .mega-menu.active>.mega-menu__inner {
    padding: 0 !important;
  }
  .hs-menu-item > .submenu-trigger {
    display: inline;
    position: absolute;
    top: 0;
    right: 0;
    font-size: 30px;
    transition: transform .5s ease-in-out;
    line-height: 1rem;
    cursor: pointer;
  }
  .hs-menu-item.active > .submenu-trigger {
    transform: rotate(45deg);
  }
  .hs-menu-item:not(.hs-item-has-children) .submenu-trigger {
    display: none;
  }
  .mega-desktop-only {
    display: none;
  }
}

.hs-menu-item.hs-menu-depth-3 .submenu-trigger {
  display: none;
}

.mega-menu__cta button.button {
  margin: 0 !important;
}