/* style.css */

html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  background: transparent;
  overflow: hidden;
  font-family: "Segoe UI", Roboto, sans-serif;
  user-select: none;
}

.leaflet-control-attribution {
  display: none !important;
}

#map-window {
  width: 1024px;
  height: 896px;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border-radius: 20px;
  border: 13px solid #1d1d1d;
  background: #000;
  overflow: hidden;
  display: none;
  flex-direction: column;
  z-index: 9999;
  opacity: 0;
  transition: opacity 0.25s ease;
}
#map-window.show {
  display: flex;
  opacity: 1;
}

#map {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  z-index: 1;
}

#menu-btn,
#legend-toggle,
#close-btn {
  position: absolute;
  width: 36px; height: 36px;
  display: inline-flex;
  align-items: center; justify-content: center;
  background: rgba(30,30,30,0.8);
  border: none;
  border-radius: 6px;
  color: #f0f0f0;
  font-size: 18px;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.1s ease;
  z-index: 10000;
  user-select: none;
}
#menu-btn      { top: 12px; left: 12px; }
#legend-toggle { top: 12px; left: 56px; }
#close-btn     { top: 12px; right: 12px; }

#menu {
  position: absolute;
  top: 56px; left: 12px;
  width: 220px;
  background: rgba(0,0,0,0.6);
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.5);
  transform-origin: top left;
  transform: scaleY(0);
  transition: transform 0.2s ease;
  z-index: 10000;
}
#menu.open { transform: scaleY(1); }
#menu h3 {
  margin: 8px;
  color: #fff;
  font-size: 16px;
  user-select: none;
}
#menu ul {
  list-style: none;
  margin: 0;
  padding: 0 8px 8px;
}
#menu .style-option {
  width: 100%;
  text-align: left;
  margin: 4px 0;
  padding: 6px 8px;
  background: rgba(30,30,30,0.7);
  border: none;
  border-radius: 6px;
  color: #fff;
  cursor: pointer;
  transition: background 0.15s ease;
}
#menu .style-option:hover {
  background: rgba(62,166,255,0.3);
}

#legend {
  position: absolute;
  top: 56px; 
  right: 0;
  width: 200px;
  height: 50%;
  background: rgba(0,0,0,0.6);
  color: #fff;
  display: flex;
  flex-direction: column;
  border-top-left-radius: 20px;
  border-bottom-left-radius: 20px;
  overflow: hidden;
  transform: translateX(100%);
  transition: transform 0.2s ease;
  z-index: 10000;
}
#legend.open { transform: translateX(0); }

#legend-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(30,30,30,0.9);
  padding: 6px 8px;
  border-top-left-radius: 20px;
  user-select: none;
}
#legend-header span {
  font-weight: 600;
  font-size: 15px;
  user-select: none;
}
#legend-header #legend-close {
  background: none;
  border: none;
  color: #fff;
  font-size: 18px;
  cursor: pointer;
}

#legend-list {
  list-style: none;
  margin: 0;
  padding: 8px;
  overflow-y: auto;
  flex: 1;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,0.8) rgba(0,0,0,0.3);
}
#legend-list::-webkit-scrollbar {
  width: 6px;
}
#legend-list::-webkit-scrollbar-track {
  background: rgba(0,0,0,0.3);
  border-radius: 3px;
}
#legend-list::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,0.8);
  border-radius: 3px;
}
#legend-list li {
  display: flex;
  align-items: center;
  padding: 6px 0;
  cursor: pointer;
  transition: background 0.15s ease;
}
#legend-list li:hover {
  background: rgba(62,166,255,0.2);
}
#legend-list li img {
  width: 20px; height: 20px;
  margin-right: 8px;
}
#legend-list li span {
  flex: 1;
  font-size: 14px;
  user-select: none;
}

#legend-footer {
  display: none;
}

.poi-popup .leaflet-popup-content-wrapper {
  background: rgba(30,30,30,0.95);
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.5);
}
.poi-popup .leaflet-popup-content {
  color: #fff;
  text-align: center;
}

button {
  font-family: inherit;
}
