#travel-map {
  --map-border: #3b515d;
  --map-surface: #1c282f;
  --map-text: #f0f7f4;
  margin: 18px 0 22px;
  overflow: hidden;
  border: 1px solid var(--map-border);
  border-radius: 15px;
  background: var(--map-surface);
  color: var(--map-text);
}

.light #travel-map {
  --map-border: #acbec4;
  --map-surface: #edf4f3;
  --map-text: #172f32;
}

.map-heading, .map-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px 20px;
  flex-wrap: wrap;
  padding: 12px 16px;
}

.map-heading h3, .map-footer p { margin: 0; }
.map-heading h3 { font-size: 1rem; }
.map-footer { font-size: .82rem; }
.map-footer a { color: inherit; }

.map-viewport {
  position: relative;
  height: clamp(290px, 39vw, 455px);
  overflow: hidden;
  border-block: 1px solid var(--map-border);
  background: #142a35;
}

.map-viewport canvas {
  display: block;
  width: 100%;
  height: 100%;
  cursor: grab;
  touch-action: pan-y;
}

.map-viewport canvas:active { cursor: grabbing; }
.map-markers { position: absolute; inset: 0; pointer-events: none; }
.map-controls { position: absolute; right: 12px; top: 12px; display: grid; gap: 5px; }
.map-controls button, .map-markers button {
  display: grid;
  place-items: center;
  min-width: 32px;
  min-height: 32px;
  padding: 2px;
  border: 1px solid #7c9fa6;
  border-radius: 8px;
  background: #18313b;
  color: white;
  font-size: 1rem;
  line-height: 1;
}

.map-controls button:disabled { opacity: .45; cursor: default; }
.map-controls button:not(:disabled):hover, .map-controls button:not(:disabled):focus-visible { background: #2b545b; }
.map-markers button {
  position: absolute;
  translate: -50% -50%;
  min-width: 30px;
  min-height: 30px;
  border: 2px solid #e8fff8;
  border-radius: 50%;
  background: #0a5d52;
  box-shadow: 0 2px 7px #0d242d;
  font-size: .7rem;
  font-weight: 700;
  pointer-events: auto;
}

.map-markers button:hover, .map-markers button:focus-visible {
  z-index: 1;
  background: #126f63;
  outline: 2px solid white;
  outline-offset: 2px;
}

.map-markers button[hidden] { display: none; }
