/* =============================================
   WD Maps — Frontend Styles (Leaflet)
   ============================================= */

.wd-maps-wrapper { position: relative; width: 100%; }

/* ---- Canvases ---- */
.wd-map-canvas {
  width: 100%;
  border-radius: 8px;
  overflow: hidden;
  background: #f0f4f8;
  /* Leaflet needs explicit height set via inline style */
}

.wd-map-item   { position: relative; margin-bottom: 32px; }
.wd-map-item:last-child { margin-bottom: 0; }
.wd-map-title  { font-size: 18px; font-weight: 600; margin: 0 0 10px; }

/* Ensure Leaflet marker images load correctly */
.wd-map-canvas .leaflet-default-icon-path { display: none; }

/* ---- Tabs layout ---- */
.wd-maps-layout-tabs .wd-map-item { margin-bottom: 0; }
.wd-maps-tabs-nav {
  display: flex;
  flex-wrap: wrap;
  border-bottom: 2px solid #e2e8f0;
  margin-bottom: 16px;
}
.wd-maps-tab-btn {
  padding: 10px 20px;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  color: #64748b;
  transition: all .2s;
}
.wd-maps-tab-btn:hover  { color: #2271b1; }
.wd-maps-tab-btn.active { color: #2271b1; border-bottom-color: #2271b1; }

/* ---- Slider layout ---- */
.wd-maps-layout-slider .wd-maps-canvases { position: relative; overflow: hidden; }
.wd-maps-slider-nav {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
  justify-content: center;
}
.wd-maps-slider-prev,
.wd-maps-slider-next {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  cursor: pointer;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .15s;
}
.wd-maps-slider-prev:hover,
.wd-maps-slider-next:hover { background: #2271b1; color: #fff; border-color: #2271b1; }
.wd-maps-slider-counter { font-size: 13px; color: #64748b; }

/* ---- Hidden items ---- */
.wd-map-hidden { display: none !important; }

/* =============================================
   TOOLTIP
   ============================================= */
.wd-map-tooltip {
  position: absolute;
  z-index: 1000;
  pointer-events: auto;
  max-width: 290px;
  min-width: 180px;
  animation: wd-tooltip-in .15s ease;
}
@keyframes wd-tooltip-in {
  from { opacity: 0; transform: scale(.95) translateY(4px); }
  to   { opacity: 1; transform: scale(1)  translateY(0); }
}
.wd-map-tooltip-inner {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 8px 32px rgba(0,0,0,.18), 0 2px 8px rgba(0,0,0,.1);
  padding: 14px 16px 12px;
  position: relative;
  border-top: 3px solid #2271b1;
}
.wd-map-tooltip-close {
  position: absolute;
  top: 8px; right: 10px;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 18px;
  color: #94a3b8;
  line-height: 1;
  padding: 0;
  transition: color .15s;
}
.wd-map-tooltip-close:hover { color: #1e293b; }
.wd-map-tooltip-title {
  margin: 0 24px 0 0;
  font-size: 14px;
  font-weight: 700;
  color: #1e293b;
  line-height: 1.3;
}
.wd-map-tooltip-info {
  margin-top: 8px;
  font-size: 13px;
  color: #475569;
  line-height: 1.5;
  white-space: pre-wrap;
}
.wd-map-tooltip-info:empty { display: none; }

/* ---- Tooltip link ---- */
.wd-map-tooltip-link {
  margin-top: 9px;
  padding-top: 8px;
  border-top: 1px solid #f1f5f9;
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 5px;
}
.wd-map-tooltip-link a {
  color: #2271b1;
  text-decoration: none;
  word-break: break-all;
}
.wd-map-tooltip-link a:hover {
  text-decoration: underline;
}