.mobile-header {
    z-index: 1040;
}

.sidebar {
  width: 280px;
  flex-shrink: 0;
}

#sidebarMenu {
    z-index: 1050;
    background-color: var(--bs-body-bg);
}

@media (max-width: 767.98px) {
    #sidebarMenu {
        position: relative;
        width: 100%;
    }
}

@media (min-width: 768px) {
    #sidebarMenu {
        position: fixed;
        top: 0;
        bottom: 0;
        left: 0;
        overflow-y: auto;
    }
}

.btn-toggle {
  padding: .375rem .75rem;
  font-weight: 600;
  color: var(--bs-body-color);
  background-color: transparent;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  text-align: left;
}

.btn-toggle:hover,
.btn-toggle:focus {
  color: var(--bs-emphasis-color);
  background-color: var(--bs-tertiary-bg);
}

.btn-toggle:not([data-bs-toggle="collapse"])::after {
    display: none !important;
}

.btn-toggle[data-bs-toggle="collapse"]::after {
  width: 1em;
  height: 1em;
  content: "";
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23333'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708 z'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-size: 1rem;
  transition: transform .35s ease;
  transform-origin: center;
}

[data-bs-theme="dark"] .btn-toggle[data-bs-toggle="collapse"]::after {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708 z'/%3e%3c/svg%3e");
}

.btn-toggle[aria-expanded="true"] {
  color: var(--bs-emphasis-color);
}

.btn-toggle[aria-expanded="true"]::after {
  transform: rotate(-180deg);
}

.btn-toggle-nav a {
  padding: .25rem 0.5rem;
  margin-top: .125rem;
  margin-left: 1rem;
  display: block;
}

.btn-toggle-nav a:hover,
.btn-toggle-nav a:focus {
    color: var(--bs-primary) !important;
}

/* Extreem specifieke selector om Bootstrap te overrulen voor de actieve pagina (hoofd- en sublinks) */
#sidebarMenu a.active-page,
#sidebarMenu a.link-body-emphasis.active-page {
    color: var(--bs-primary) !important;
}