/* MODULE: map – Interaktive Karte (map.html + Mini-Maps) */

/* Leaflet Overlay/SVG zurücksetzen – base.css setzt global svg{width:20px;height:20px}
   was Leaflets Polyline-Overlay auf 20x20 quetscht und unsichtbar macht. */
.leaflet-container svg,
.leaflet-pane svg,
.leaflet-overlay-pane svg {
  width: auto;
  height: auto;
  fill: none;
  stroke-width: initial;
}
.leaflet-overlay-pane svg path {
  fill: none;
}

.map-page-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px 20px 60px;
}
.map-page-header {
  text-align: center;
  margin-bottom: 20px;
}
.map-page-header h1 {
  font-family: var(--font-display);
  font-size: 36px;
  letter-spacing: 0.04em;
  margin: 0 0 6px;
  color: var(--text);
}
.map-page-header p {
  color: var(--text-muted);
  font-size: 14px;
  margin: 0;
}
.map-full-wrap {
  position: relative;
  width: 100%;
  height: 70vh;
  min-height: 480px;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: var(--bg-2);
}
.map-full {
  width: 100%;
  height: 100%;
}
.map-legend {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin: 16px 0 0;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--text-muted);
}
.map-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.map-legend-dot {
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.2);
}
.map-legend-dot--red    { background: #E53935; }
.map-legend-dot--orange { background: #FF6B00; }

/* Events-Seiten-Karte (events.html – oberhalb der Event-Liste) */
.events-map-wrap {
  max-width: 1200px;
  margin: 0 auto 32px;
  padding: 0 20px;
}
.events-map-wrap--hidden { display: none; }
.events-map {
  width: 100%;
  height: 420px;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: var(--bg-2);
}
.events-map-hint {
  text-align: center;
  font-size: 12px;
  color: var(--text-muted);
  margin: 10px 0 0;
}
@media (max-width: 768px) {
  .events-map { height: 320px; }
}

/* Rideouts-Treffpunkte-Karte (app.html – Geplante Rideouts Subseite) */
.rideouts-map-wrap {
  margin: 24px auto 32px;
  max-width: 620px;
  padding: 0 16px;
}
.rideouts-map-label {
  text-align: center;
  margin: 0;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.rideouts-map-title {
  font-family: var(--font-display);
  font-size: 26px;
  letter-spacing: 0.04em;
  text-align: center;
  color: var(--text);
  margin: 4px 0 14px;
}
.rideouts-map {
  width: 100%;
  height: 340px;
  border-radius: var(--radius-lg, 16px);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg-2);
  box-shadow: var(--shadow);
}
@media (max-width: 480px) {
  .rideouts-map { height: 280px; }
  .rideouts-map-title { font-size: 22px; }
}

/* Mini-Karte (z.B. auf event-detail.html) */
.mini-map-wrap {
  margin: 20px 0;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: var(--bg-2);
}
.mini-map {
  width: 100%;
  height: 280px;
}

/* Pin-Icons (divIcon) */
.mb-map-pin {
  background: transparent !important;
  border: none !important;
}
.mb-map-pin-dot {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 3px solid #fff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
}

/* Popup Overrides */
.leaflet-popup-content-wrapper {
  border-radius: 8px;
}
.leaflet-popup-content {
  font-family: var(--font-body, Inter, sans-serif);
  font-size: 13px;
  margin: 10px 14px;
}

@media (max-width: 768px) {
  .map-full-wrap { height: 60vh; min-height: 360px; }
  .map-page-header h1 { font-size: 28px; }
  .mini-map { height: 220px; }
}
