.menubox {
  display: flex;
  flex-wrap: nowrap;
  flex-direction: row;
  justify-content: flex-end;
  align-items: center;
  position: relative;
}

.logo, .logo svg {
  max-height: 100px;
  min-height: 3em;
  display: block;
}

.menubox #menu-toggle {
  display: none;
}

.menubox nav {
  position: fixed;
  top: 210px;
  left: 0px;
  overflow-y: auto;
  z-index: -1;
  height: calc(100vh - 120px)
}

/* Menu-Schaltfläche */
.menu-toggle-label {
  position: absolute;
  top: -25px;
  right: 0;
  width: 50px;
  height: 50px;
  background-size: 55px;
  background-position: center center;
  background-repeat: no-repeat;
  z-index: 20;
  cursor: pointer;
}

.menu-toggle-label {
  background-image: url('../images/icons/menu.svg');
}

#menu-toggle:checked ~ .menu-toggle-label {
  background-image: url('../images/icons/close.svg');
}

/* menuboxsmenü 1. Ebene */
.menubox nav > ul {
  position: relative;
  visibility: collapse;
  display: table-row;
  font-family: "Jost";
  text-transform: uppercase;
  font-size: 1.1rem;
}

#menu-toggle:checked ~ nav {
  z-index: 20;
}

#menu-toggle:checked ~ nav > ul {
  visibility: visible;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  background: var(--color-secondary-light);
  opacity: 1;
  transition: visibility 0s, opacity 0.5s linear;
  position: relative;
  width: 100vw;
  list-style-position: inside;
  margin: 0;
  padding: 20px;
  padding-bottom: 120px;
  height: auto;
  min-height: 500px;
  overflow: auto;
  z-index: 20;
}

/* @media (max-width: 699px) {
  .menubox:focus-within nav {
    z-index: 20;
  }

  .menubox:focus-within nav > ul {
    visibility: visible;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    background: var(--color-secondary-light);
    opacity: 1;
    transition: visibility 0s, opacity 0.5s linear;
    position: relative;
    width: 100vw;
    list-style-position: inside;
    margin: 0;
    padding: 20px;
    height: auto;
    min-height: 500px;
    overflow: auto;
    z-index: 20;
  }
} */
.menubox input:checked ~ label a {
  color: #fff;
  float: left;
}

.menubox nav > ul > li {
  list-style: none;
  font-size: 1.2em;
  line-height: 1.8;
  font-weight: 400;
  margin-top: 10px;
  align-items: left;
  display: flex;
  flex-direction: column;
}

/* .menubox nav > ul > li:first-of-type {
    margin-top: 120px
    } */
.menubox ul.sub-menu {
  padding-left: 1em;
}

.sub-menu > li {
  font-size: 0.8em;
  list-style: none;
  margin-left: 0;
  line-height: 1.8;
  display: flex;
  flex-direction: row;
  justify-content: flex-start;
  align-items: center;
  padding: 10px 0;
}

.sub-menu > li object {
  width: 1.5em;
  margin-right: 0.8em;
}

@media (min-width: 900px) {
  .menubox nav {
    position: relative;
    top: inherit;
    left: inherit;
    z-index: 20;
    height: auto;
    overflow: unset;
  }

  .menubox nav > ul {
    display: flex;
    visibility: visible;
    font-size: 1.1rem;
  }

  .menu-toggle-label, #menu-toggle {
    display: none;
  }

  /* .menubox input:checked ~ nav > ul {
      flex-direction: row;
      padding: 4vw;
    }
    .menubox input:checked ~ label a {
    float: none;
    } */
  .menubox nav > ul > li {
    font-size: 0.9em;
    padding-left: 10px;
    position: relative;
  }

  .menubox nav > ul > li:first-of-type {
    margin-top: 10px
  }

  .sub-menu {
    display: none;
    grid-template-columns: repeat(2, 1fr);
    width: 550px;
    padding: 0 40px 20px;
    margin-right: 0;
    position: absolute;
    top: 1.7em;
    right: 0px;
    border-top: 20px #fff solid;
    background: #e7e7e7;
    z-index: 7;
    transition: 0.35s filter;
  }

  .sub-menu::before {
    content: " ";
    position: absolute;
    bottom: 100%;
    /* At the bottom of the tooltip */
    right: 0;
    margin-left: -15px;
    border-width: 15px;
    border-style: solid;
    border-color: transparent transparent #e7e7e7 transparent;
  }

  li:hover .sub-menu, li a:focus + .sub-menu, li:focus-within .sub-menu {
    display: grid;
    padding-left: auto;
  }

  /* .current-menu-item .sub-menu {
      display: block;
    } */
  .sub-menu > li {
    padding: 20px 20px 0 0;
    padding-left: 0px;
    font-size: 0.9em;
    line-height: unset;
    border-left: 0;
    margin-left: 0;
  }

  #menu-item-2506 a, #menu-item-2512 a {
    background: var(--color-secondary-light);
    padding: 0 10px;
    border-radius: 5px;
  }
}

.current-menu-parent > a {
  color: var(--color-primary-dark);
}

.sub-menu li a {
  display: flex;
  align-items: center;
}

.sub-menu li a::before {
  content: "";
  display: inline-block;
  position: relative;
  bottom: auto;
  width: 1.5em;
  height: 1.5em;
  margin-right: .8em;
  background-repeat: no-repeat;
  background-size: cover;
}

#menu-item-943 a::before, #menu-item-2387 a::before {
  background-image: url("../images/icons/webdesign.svg");
}

#menu-item-942 a::before, #menu-item-2383 a::before {
  background-image: url("../images/icons/seo.svg");
}

#menu-item-1112 a::before, #menu-item-2384 a::before {
  background-image: url("../images/icons/online-strategie.svg");
}

#menu-item-1262 a::before, #menu-item-2388 a::before {
  background-image: url("../images/icons/content-marketing.svg");
}

#menu-item-1170 a::before, #menu-item-2389 a::before {
  background-image: url("../images/icons/branding2.svg");
}

#menu-item-1788 a::before, #menu-item-2386 a::before {
  background-image: url("../images/icons/digitale-loesungen.svg");
}

#menu-item-1822 a::before, #menu-item-2382 a::before {
  background-image: url("../images/icons/sicherheit.svg");
}

#menu-item-1363 a::before, #menu-item-2385 a::before {
  background-image: url("../images/icons/kurse.svg");
}

#menu-item-1087 a::before, #menu-item-943 a::before {
  background-image: url("../images/icons/wappen-netjutant.svg");
}

#menu-item-2242 a::before, #menu-item-943 a::before {
  background-image: url("../images/icons/chiemgau.svg");
}

#menu-item-1088 a::before, #menu-item-943 a::before {
  background-image: url("../images/icons/blog.svg");
}

#menu-item-1442 a::before, #menu-item-2607 a::before {
  background-image: url("../images/icons/digitalisierung.svg");
}

#menu-item-1441 a::before, #menu-item-2392 a::before {
  background-image: url("../images/icons/personalsuche.svg");
}

#menu-item-1446 a::before, #menu-item-2391 a::before {
  background-image: url("../images/icons/ki.svg");
}

#menu-item-1786 a::before, #menu-item-2390 a::before {
  background-image: url("../images/icons/internet-der-dinge.svg");
}

#menu-item-1787 a::before, #menu-item-2606 a::before {
  background-image: url("../images/icons/nachhaltigkeit.svg");
}