/* Nav group */

#nav-group {
  display: flex;
  flex-direction: row;
  width: fit-content;
  z-index: 1000;
}

#overlay {
  background-color: var(--bs-success);
  position: fixed;
  width: 100%;
  height: 100%;
  display: none;
}

/* Collpsed nav */

#sidebar {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 1rem;
  height: 100vh;
  width: 5rem;
  z-index: 900;
  background-color: #ffffff;
  border-right: 1px solid var(--dark3);
  position: fixed;
}

.nav {
  flex-direction: column;
  gap: 8px;
  width: 100%;
}

.nav-item {
  width: fit-content;
}

.nav-link {
  height: 3rem;
  width: 100%;
  border: 1px solid;
  border-radius: 0.75rem;
  gap: 8px;
  display: flex;
  align-items: center;
}

.nav-item {
  width: 100%;
}

/* Logos */

.logo {
  height: 3rem;
}

/* Hover sidebar */

#logo-expanded {
  display: none;
}

.menu-text {
  display: none;
}

#sidebar:hover {
  background-color: var(--bs-primary);
  padding: 1.5rem;
  width: fit-content;
  transition: 300ms ease-in;
}

#sidebar:hover .nav-link {
  color: #f6f7fb;
  width: 100%;
}

#sidebar:hover .menu-text {
  display: block;
}

#sidebar:hover #logo-collapsed {
  display: none;
}

#sidebar:hover #logo-expanded {
  display: block;
}

#sidebar:hover ~ #overlay {
  display: block;
  background-color: #f6f7fb7e;
}

/* Hover buttons */

.nav-link:hover {
  background-color: #ffffff;
}

.nav-link:hover > * {
  color: var(--bs-primary);
}

@media (max-width: 576px) {
  #nav-group {
    position: relative !important;
    z-index: 999999999999999999999999999 !important;
    overflow-y: scroll;
    height: auto;
  }
}

@media (max-width: 576px) {
  #sidebar[aria-expanded="false"] {
    background-color: var(--bs-primary);
    padding: 1.5rem;
    width: fit-content;
    transition: 300ms ease-in;
    overflow-y: scroll;
    height: auto;
  }
}

@media (max-width: 576px) {
  #sidebar[aria-expanded="false"] .nav-link {
    color: #f6f7fb;
    width: 100%;
  }
}

@media (max-width: 576px) {
  #logo-holder {
    padding-bottom: 15%;
  }
}

@media (max-width: 576px) {
  #sidebar[aria-expanded="false"] .menu-text {
    display: block;
  }
}

@media (max-width: 576px) {
  #sidebar[aria-expanded="false"] #logo-collapsed {
    display: none;
  }
}

@media (max-width: 576px) {
  #sidebar[aria-expanded="false"] #logo-expanded {
    display: block;
  }
}

@media (max-width: 576px) {
  #sidebar[aria-expanded="false"] ~ #overlay {
    display: block;
    background-color: #f6f7fb7e;
  }
}

@media (max-width: 576px) {
  .nav {
    flex-grow: 1;
    margin-bottom: 15%;
  }
}

@media (max-width: 576px) {
  .nav-link:hover {
    background-color: #ffffff;
  }
}

@media (max-width: 576px) {
  .nav-link:hover > * {
    color: var(--bs-primary);
  }
}

@media (max-width: 576px) {
  #overlay {
    position: relative;
  }
}

