/* ============================================================
   Locations page: hero strip, chips, search, Leaflet light theme
   ============================================================ */

.page-hero {
  padding-top: 3rem;
  padding-bottom: 0.4rem;
  background:
    radial-gradient(46rem 22rem at 0% -30%, rgba(239, 231, 250, 0.9) 0%, transparent 60%),
    radial-gradient(36rem 20rem at 100% -20%, rgba(255, 184, 28, 0.12) 0%, transparent 55%),
    var(--bg);
}

.locator { padding-top: 1.4rem; }

.state-filter { margin-bottom: 1rem; }

.state-chip {
  border: 1px solid transparent;
  cursor: pointer;
  font-family: var(--font-body);
}
.state-chip.is-active {
  background: var(--purple);
  color: #fff;
}

.locator-toolbar {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.75rem;
  margin: 0.4rem 0 0.6rem;
}

#autoComplete {
  width: 100%;
  height: 48px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--lavender-deep);
  background: var(--surface);
  color: var(--ink);
  padding: 0 1.25rem;
  font-family: var(--font-body);
  font-size: 0.98rem;
  outline: none;
  box-shadow: var(--shadow-sm);
}
#autoComplete::placeholder { color: var(--ink-soft); }
#autoComplete:focus {
  border-color: var(--purple);
  box-shadow: 0 0 0 3px rgba(92, 45, 145, 0.18);
}

.map-info { margin: 0 0 0.75rem; font-size: 0.9rem; }

#map {
  position: relative;
  width: 100%;
  min-height: 68vh;
  border-radius: var(--radius);
  border: 1px solid var(--lavender-deep);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  z-index: 1;
}

/* ── Leaflet chrome ────────────────────────────────────────── */

.leaflet-container { font-family: var(--font-body); }

.leaflet-bar { border: none !important; box-shadow: var(--shadow-md) !important; }
.leaflet-bar a {
  background: var(--surface) !important;
  color: var(--purple) !important;
  border-bottom-color: var(--lavender) !important;
}
.leaflet-bar a:hover { background: var(--lavender) !important; }

.leaflet-control-scale-line {
  background: rgba(255, 255, 255, 0.85) !important;
  color: var(--ink-body) !important;
  border-color: var(--lavender-deep) !important;
}

.leaflet-popup-content-wrapper, .leaflet-popup-tip {
  background: var(--surface);
  color: var(--ink-body);
  border: 1px solid var(--lavender-deep);
  box-shadow: var(--shadow-md);
}
.leaflet-popup-content { margin: 0.85rem 0.95rem; min-width: 220px; }

.titleKMAC {
  color: var(--purple-brand);
  font-size: 1rem;
  font-weight: 800;
  margin: 0 0 0.3rem;
  display: block;
}

.popupMeta {
  display: block;
  color: var(--ink-soft);
  font-size: 0.9rem;
  line-height: 1.4;
  margin-bottom: 0.25rem;
}

.linkKMAC {
  display: inline-flex;
  margin: 0.3rem 0.5rem 0 0;
  color: #fff !important;
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: var(--radius-pill);
  padding: 0.3rem 0.7rem;
  background: var(--purple);
}
.linkKMAC:hover { background: var(--purple-deep); }

.kmac-pin {
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.85), 0 6px 14px rgba(64, 32, 100, 0.35);
}
.kmac-pin-hq {
  background: radial-gradient(circle at 30% 30%, var(--gold), var(--orange));
  border: 2px solid #fff;
}
.kmac-pin-store {
  background: radial-gradient(circle at 30% 30%, #9A66D6, var(--purple-deep));
  border: 2px solid #fff;
}

/* ── autoComplete.js results ───────────────────────────────── */

[id^="autoComplete_list_"] {
  margin: 0.45rem 0 0;
  padding: 0.35rem;
  list-style: none;
  border: 1px solid var(--lavender-deep);
  border-radius: var(--radius-sm);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  max-height: 320px;
  overflow-y: auto;
  position: relative;
  z-index: 40;
}

[id^="autoComplete_result_"] {
  padding: 0.6rem 0.7rem;
  border-radius: 9px;
  cursor: pointer;
}
[id^="autoComplete_result_"][aria-selected="true"],
[id^="autoComplete_result_"]:hover { background: var(--lavender); }

.kmac-highlight {
  color: var(--purple-deep);
  background: rgba(255, 184, 28, 0.35);
  padding: 0 0.1rem;
  border-radius: 4px;
}

@media (max-width: 760px) {
  .locator-toolbar { grid-template-columns: 1fr; }
  #map { min-height: 60vh; }
}
