html, body {
  margin: 0;
  padding: 0;
  overflow: hidden; /* ⛔ prevent scrollbars */
  height: 100%;
  width: 100%;
}

.main6 {
  height: 100vh;
  width: 100%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

#map {
  height: 100%;
  width: 100%;
  position: absolute;
  top: 0;
  left: 0;
  /* z-index: 1; */
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);

}

#sidebar {
  position: absolute;
  top: 0;
  left: 0;
  width: 300px;
  height: 100%;
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(12px);
  box-shadow: 4px 0 10px rgba(0, 0, 0, 0.1);
  padding: 20px;
  transition: transform 0.3s ease-in-out;
  transform: translateX(0);
  z-index: 999;
}

#sidebar.hidden {
  transform: translateX(-100%);
}

#sidebar h2 {
  margin-top: 0;
}

#close-sidebar {
  position: absolute;
  top: 10px;
  right: 10px;
  background: transparent;
  border: none;
  font-size: 20px;
  cursor: pointer;
  color: black;
}

body.dark-theme #sidebar {
  background: rgba(20, 20, 20, 0.6);
  color: #eee;
}

body.dark-theme #close-sidebar {
  color: white;
}

body.dark-theme #theme-toggle {
  background: #222;
  color: #fff;
}

body.dark-theme #map {
  filter: brightness(0.95);
}

#theme-toggle {
  position: absolute;
  top: 15px;
  right: 15px;
  background: #fff;
  border-radius: 8px;
  padding: 6px 10px;
  cursor: pointer;
  z-index: 1000;
  font-size: 18px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.leaflet-control-zoom {
  bottom: 20px;
  right: 20px;
  top: unset;
  left: unset;
  position: absolute !important;
  z-index: 999;
}


@media (max-width: 768px) {
  #sidebar {
    width: 100%;
    height: 40%;
    bottom: 0;
    top: unset;
    left: 0;
    right: 0;
    transform: translateY(0);
    transition: transform 0.3s ease-in-out;
  }

  #sidebar.hidden {
    transform: translateY(100%);
  }

  #close-sidebar {
    top: 10px;
    right: 15px;
  }
}