/*------------------------ main menu ------------------------*/
:root {
  --menu_a_hover: hsl(0, 0%, 95%);
  --text_dark: hsl(210, 50%, 95%);
  --text_shaded_dark: hsl(210, 25%, 75%);
}

.main_menu {
  height: 100%;
  /* 100% Full-height */
  width: 320px;
  /* 0 width - change this with JavaScript */
  position: fixed;
  /* Stay in place */
  z-index: 99999 !important;
  /* Stay on top */
  top: 0;
  /* Stay at the top */
  left: -320px;
  overflow-x: hidden;
  /* Disable horizontal scroll */
  padding-top: 20px;
  /* Place content 20px from the top */
  transition: 1s cubic-bezier(0.68, -0.55, 0.27, 1.55);
  /* 0.5 second transition effect to slide in the user_menu */
  text-align: right;
  backdrop-filter: blur(15px);
}

.main_menu.open {
  left: 0px;
}

/* The main menu links */
.main_menu a {
  padding: 8px 8px 8px 8px;
  text-decoration: none;
  font-size: 24px;
  font-weight: bold;
  display: block;
  transition: 0.3s;
}
.main_menu a,
.main_menu p {
  color: var(--text_shaded_dark);
}

.main_menu a:hover {
  color: var(--menu_a_hover);
}

.main_menu p {
  padding: 8px 8px 8px 8px;
  text-decoration: none;
  display: block;
  transition: 0.3s;
  font-size: 18px;
  font-weight: bold;
  color: var(--text_shaded_dark);
}

/* On smaller screens, where height is less than 450px, change the style of the main_menu (less padding and a smaller font size) */
@media screen and (max-height: 450px) {
  .main_menu {
    padding-top: 15px;
  }

  .main_menu a {
    font-size: 18px;
  }
}

.main_menu_button {
  top: 8px;
  right: 10px;
  z-index: 100000 !important;
  cursor: pointer;
}

.main_menu_button_lines {
  width: 35px;
  height: 5px;
  margin: 3px 0;
  /* 0.5 second transition effect to slide in the user_menu */
  transition: 1s cubic-bezier(0.68, -0.55, 0.27, 1.55);
  transform-origin: right center;
  background: var(--text_dark);
}

.menu_icon {
  width: 18px;
}

/* Das Overlay im Normalzustand: unsichtbar und blockiert keine Klicks */
.menu-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  /* Komplett unsichtbar. Ändere zu 0.4 für einen Dimmer-Effekt */
  background-color: hsla(0, 0%, 0%, 0.4);
  /* Ein Punkt unter dem Hauptmenü, aber über allem anderen */
  z-index: 998;
  /* Standardmäßig komplett deaktiviert */
  display: none;
}

/* Wenn das Menü offen ist, zeigen wir auch das Overlay an */
#mymain_menu.open + .menu-backdrop {
  display: block;
}
