/** GeoSV - Modo Presentación */
.header-presentation-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px;
  margin-left: 4px;
  background: var(--bg-panel);
  border: 1px solid var(--border-color);
  border-radius: 999px;
  flex-shrink: 0;
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.header-presentation-pill:hover,
.header-presentation-pill:has(.header-presentation-btn.active) {
  border-color: rgba(250, 92, 0, 0.38);
}

.header-presentation-btn {
  position: relative;
  width: 30px;
  height: 28px;
  flex: 0 0 30px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent !important;
  color: var(--text-muted);
  font-size: 11px;
  transition: color 0.16s ease;
}

.header-presentation-btn i {
  font-size: 11px;
  color: currentColor;
  pointer-events: none;
}

.header-presentation-btn:hover {
  color: var(--text-primary);
}

.header-presentation-btn.active,
.header-presentation-btn[aria-pressed="true"] {
  color: var(--primary);
}

.header-presentation-btn.is-selecting[data-count]::after {
  content: attr(data-count);
  position: absolute;
  right: -2px;
  top: -3px;
  min-width: 13px;
  height: 13px;
  padding: 0 3px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  border-radius: 999px;
  background: var(--primary);
  color: #fff;
  border: 1px solid var(--bg-panel);
  font-size: 8px;
  font-weight: 700;
  line-height: 1;
}

.header-presentation-btn:focus-visible {
  outline: 1px solid var(--primary);
  outline-offset: 1px;
}

/* Durante selección, los overlays originales no interceptan el click: el
   selector transparente del Modo presentación queda como única capa interactiva. */
#map.presentation-mode-selecting .leaflet-interactive,
#map.presentation-mode-selecting .leaflet-marker-icon,
#map.presentation-mode-selecting .leaflet-marker-shadow,
#map.presentation-mode-selecting .leaflet-tooltip,
#map.presentation-mode-selecting .leaflet-popup {
  pointer-events: none !important;
}

#map.presentation-mode-selecting .geosv-presentation-selection-pane,
#map.presentation-mode-selecting .geosv-presentation-selection-pane .leaflet-interactive {
  pointer-events: auto !important;
  cursor: pointer;
}

/* La vista aplicada es deliberadamente de presentación: conserva pan/zoom del
   mapa, pero evita edición, popups y hover accidentales sobre features. */
#map.presentation-mode-applied .leaflet-interactive,
#map.presentation-mode-applied .leaflet-marker-icon,
#map.presentation-mode-applied .leaflet-marker-shadow,
#map.presentation-mode-applied .leaflet-tooltip,
#map.presentation-mode-applied .leaflet-popup {
  pointer-events: none !important;
}
