/* GPX QR Tracker — [gpx_map_all] Map */

.gpxqr-map-all-root {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.gpxqr-ma-map {
  width: 100%;
  height: 100%;
}

/* ── Loading overlay ── */
.gpxqr-ma-loading {
  position: absolute;
  bottom: 16px; left: 50%;
  transform: translateX(-50%);
  background: rgba(26,26,46,0.88);
  color: #c0c8e8;
  font-size: 13px;
  padding: 8px 18px;
  border-radius: 20px;
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,0.1);
  z-index: 500;
  pointer-events: none;
  white-space: nowrap;
}

/* ── Popup wrapper ── */
.gpxqr-ma-popup-wrap .leaflet-popup-content-wrapper {
  padding: 0;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 30px rgba(0,0,0,0.25);
  border: none;
}
.gpxqr-ma-popup-wrap .leaflet-popup-content {
  margin: 0;
  width: 260px !important;
}
.gpxqr-ma-popup-wrap .leaflet-popup-tip {
  background: #fff;
}

/* ── Popup content ── */
.gpxqr-ma-popup {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.gpxqr-ma-popup-img {
  width: 100%;
  height: 130px;
  object-fit: cover;
  display: block;
}
.gpxqr-ma-popup-body {
  padding: 12px 14px 14px;
}
.gpxqr-ma-popup-acts {
  font-size: 16px;
  margin-bottom: 4px;
  line-height: 1;
}
.gpxqr-ma-popup-name {
  font-size: 15px;
  font-weight: 700;
  color: #1a1a3a;
  padding-left: 8px;
  margin-bottom: 8px;
  line-height: 1.3;
}
.gpxqr-ma-popup-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 10px;
}
.gpxqr-ma-badge {
  font-size: 11px;
  font-weight: 500;
  background: #f0f1ff;
  color: #5058c0;
  border: 1px solid #dde0ff;
  border-radius: 20px;
  padding: 2px 8px;
  white-space: nowrap;
}
.gpxqr-ma-popup-btn {
  display: block;
  text-align: center;
  color: #fff !important;
  text-decoration: none !important;
  border-radius: 8px;
  padding: 9px;
  font-size: 13px;
  font-weight: 600;
  transition: opacity .15s;
}
.gpxqr-ma-popup-btn:hover {
  opacity: 0.88;
  text-decoration: none !important;
}

/* ── Distance range slider (shared with tracks-list) ── */
.gpxqr-ma-filter {
  background: rgba(26,26,46,0.92);
  padding: 10px 14px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  flex-shrink: 0;
}
.gpxqr-ma-filter-inner {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
}
.gpxqr-ma-filter-lbl {
  font-size: 13px; font-weight: 600; color: #a0a8e0;
  white-space: nowrap;
}
.gpxqr-ma-filter-val {
  font-size: 13px; font-weight: 700; color: #7c83ff;
  min-width: 90px;
}
.gpxqr-ma-slider-wrap {
  position: relative; flex: 1; min-width: 160px; height: 20px;
}
.gpxqr-ma-slider {
  position: absolute; width: 100%;
  -webkit-appearance: none; appearance: none;
  height: 4px; background: transparent; outline: none;
  pointer-events: none; top: 50%; transform: translateY(-50%);
}
.gpxqr-ma-slider::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 18px; height: 18px; border-radius: 50%;
  background: #7c83ff; border: 2px solid #fff;
  cursor: pointer; pointer-events: all;
  box-shadow: 0 1px 4px rgba(0,0,0,0.3);
}
.gpxqr-ma-slider::-moz-range-thumb {
  width: 18px; height: 18px; border-radius: 50%;
  background: #7c83ff; border: 2px solid #fff;
  cursor: pointer; pointer-events: all;
}
.gpxqr-ma-slider-track {
  position: absolute; left: 0; right: 0; top: 50%;
  transform: translateY(-50%); height: 4px;
  background: rgba(255,255,255,0.12); border-radius: 2px;
  pointer-events: none;
}
.gpxqr-ma-slider-range {
  position: absolute; top: 0; bottom: 0;
  background: #7c83ff; border-radius: 2px;
}

/* ── POI pins на [gpx_map_all] ── */
.gpxqr-ma-poi-pin {
  width: 34px; height: 34px;
  border-radius: 50%;
  border: 2px solid #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 17px;
  box-shadow: 0 2px 8px rgba(0,0,0,.4);
  cursor: pointer;
  transition: transform .15s;
}
.gpxqr-ma-poi-pin:hover { transform: scale(1.15); }

/* ── 360° modal (shared with app.css) ── */
.gpxqr-360-modal {
  position: fixed; inset: 0; z-index: 99999;
  background: rgba(0,0,0,0.92);
  display: none;
  flex-direction: column;
  align-items: stretch;
}
.gpxqr-360-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px;
  background: rgba(0,0,0,0.6);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  flex-shrink: 0;
}
.gpxqr-360-title {
  font-size: 15px; font-weight: 600; color: #fff;
  font-family: system-ui, sans-serif;
}
.gpxqr-360-close {
  background: none; border: none; color: #aaa;
  font-size: 22px; cursor: pointer; padding: 0 4px;
  line-height: 1;
}
.gpxqr-360-close:hover { color: #fff; }
#gpxqr-360-viewer {
  flex: 1;
  width: 100%;
  min-height: 0;
}
