.map-hero h1 { font-size:clamp(2.15rem,5vw,3.7rem); }
.map-main { padding-block:20px 34px; }
.map-controls { display:flex;flex-wrap:wrap;align-items:end;gap:10px 14px; }
.map-controls label { display:grid;gap:4px;color:var(--muted);font-size:.88rem;font-weight:650; }
.map-controls select { width:min(210px,85vw);height:39px;border:1px solid #d9d5e5;border-radius:7px;background:#fff;color:var(--ink);padding:5px 8px;font:inherit; }
.map-actions { display:flex;gap:6px; }
#map-count,.map-note { margin:11px 0;color:var(--muted);font-size:.86rem;line-height:1.5; }
.map-layout { display:grid;grid-template-columns:minmax(0,2.3fr) minmax(270px,1fr);gap:14px;align-items:start; }
.map-frame,.map-listings { border:1px solid var(--border);background:#fff;box-shadow:var(--shadow);border-radius:12px;overflow:hidden; }
#job-map { height:clamp(410px,62vh,680px);background:#dceaf4;isolation:isolate; }
#job-map .leaflet-container { font-family:inherit; }
#job-map .leaflet-control-attribution { background:#fffffff0;font-size:11px; }
.job-pin { display:grid;place-items:center;border:2px solid white;border-radius:100%;background:#57418dad;color:white;font:750 12px system-ui,sans-serif;box-shadow:0 2px 5px #311d556b;white-space:nowrap; }
.job-pin.cluster { background:#493078; }
.job-pin.selected { background:#7a325f;outline:2px solid #7a325f; }
.job-pin:focus-visible { outline:3px solid #211042;outline-offset:2px; }
.map-listings { padding:14px 15px; }
.map-listings h2 { font-size:1.13rem;overflow-wrap:anywhere; }
.map-listings .list-note { color:var(--muted);font-size:.86rem;line-height:1.45;margin-top:6px; }
.map-listings ol { display:grid;gap:0;list-style:none;padding:0;margin:9px 0; }
.map-listings li { display:grid;gap:3px;padding:7px 0;border-bottom:1px solid var(--border); }
.map-listings li a { color:var(--ink);font-weight:670;font-size:.87rem;line-height:1.3;overflow-wrap:anywhere; }
.map-listings li small { color:var(--muted);font-size:.76rem; }
.map-pagination { display:flex;align-items:center;justify-content:space-between;gap:6px;color:var(--muted);font-size:.78rem; }
@media(max-width:850px){.map-layout{grid-template-columns:1fr}#job-map{height:clamp(360px,57vh,590px)}}

:root{--map-land:#f8faf7;--map-border:#93a8b8;--map-region:#bbc8ce}
[data-theme="dark"]{--map-land:#30394f;--map-border:#7884a0;--map-region:#5a6783}
[data-theme="dark"] :is(.map-frame,.map-listings,.map-controls select){
  background:var(--white);border-color:var(--border);
}
[data-theme="dark"] #job-map{background:#151e33}
[data-theme="dark"] #job-map .leaflet-control-attribution{background:var(--white);color:var(--muted)}
[data-theme="dark"] #job-map .leaflet-bar a{background:var(--white);color:var(--ink);border-color:var(--border)}
[data-theme="dark"] #job-map .leaflet-bar a:hover{background:var(--lavender)}
[data-theme="dark"] #job-map .leaflet-bar a.leaflet-disabled{color:var(--muted)}
[data-theme="dark"] .job-pin{background:#6049a0;border-color:#e5d9ff}
[data-theme="dark"] .job-pin.cluster{background:#5c439b}
[data-theme="dark"] .job-pin.selected{background:#833963;outline-color:#ebadd1}
[data-theme="dark"] .job-pin:focus-visible{outline-color:#c5b3ff}

.map-location-search {
  position: relative;
  width: min(300px, 100%);
}

.map-location-field {
  position: relative;
  margin-top: 4px;
}

.map-location-field input {
  width: 100%;
  height: 39px;
  padding: 5px 52px 5px 8px;
  border: 1px solid var(--border);
  border-radius: 7px;
  color: var(--ink);
  background: var(--white);
}

#clear-map-place {
  position: absolute;
  inset-inline-end: 8px;
  top: 50%;
  transform: translateY(-50%);
}

.map-suggestions {
  position: absolute;
  z-index: 5;
  inset-inline: 0;
  top: calc(100% + 4px);
  margin: 0;
  padding: 5px;
  max-height: 256px;
  overflow: auto;
  list-style: none;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--white);
  box-shadow: var(--shadow);
  color: var(--ink);
  font-size: .9rem;
}

.map-suggestions li,
#map-no-suggestions {
  padding: 8px;
}

.map-suggestions li {
  cursor: pointer;
  border-radius: 5px;
}

.map-suggestions li:hover,
.map-suggestions li[aria-selected="true"] {
  background: var(--lavender);
  color: var(--ink);
}

.map-layout.list-view {
  grid-template-columns: minmax(0, 1fr);
}
