:root {
  --map-fill: #f5f5f2;
  --map-stroke: #4b4d4c;
  --map-stroke-width: 0.6px;
  --map-hover-fill: #b29f7b;
  --map-hover-opacity: 0.7;
  --map-active-fill: #dd383d;
  --map-active-opacity: 0.9;
  --map-active-stroke: #9e2429;
  --map-active-stroke-width: 1.2px;
  --line: #dedfda;
  --ink: #1f2220;
  --muted: #656a67;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  color: var(--ink);
  background: transparent;
  font-family: Inter, "SF Pro Text", "Helvetica Neue", Arial, sans-serif;
}

button {
  color: inherit;
  font: inherit;
}

.embed {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 12px;
}

.map-shell {
  width: min(100%, 980px);
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
}

.map-viewport {
  position: relative;
  width: 100%;
  height: min(78vh, 760px);
  min-height: min(78vh, 760px);
  overflow: hidden;
  touch-action: none;
  background: #fff;
}

#map-container {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
}

#map-container svg {
  width: 100%;
  height: 100%;
  display: block;
  cursor: grab;
}

.map-shell[data-dragging="true"] #map-container svg {
  cursor: grabbing;
}

#map-container svg .st0,
#map-container svg .st1,
#map-container svg path,
#map-container svg polygon {
  fill: var(--map-fill) !important;
  stroke: var(--map-stroke) !important;
  stroke-width: var(--map-stroke-width) !important;
  fill-opacity: 0.86 !important;
  vector-effect: non-scaling-stroke;
}

#map-container svg [data-active="true"] {
  fill: var(--map-active-fill) !important;
  stroke: var(--map-active-stroke) !important;
  stroke-width: var(--map-active-stroke-width) !important;
  fill-opacity: var(--map-active-opacity) !important;
}

#map-container svg [data-hidden="true"] {
  display: none;
}

#map-container svg [data-code]:hover:not([data-active="true"]) {
  fill: var(--map-hover-fill) !important;
  fill-opacity: var(--map-hover-opacity) !important;
}

.map-controls {
  position: absolute;
  top: 14px;
  right: 14px;
  overflow: hidden;
  display: grid;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 6px 18px rgba(31, 34, 32, 0.1);
}

.map-controls button {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  padding: 0;
  background: #fff;
  border: 0;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  font-size: 22px;
}

.map-controls button:last-child {
  border-bottom: 0;
}

.map-controls button:hover {
  background: #f4f6f4;
}

.map-controls svg {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.map-help {
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: space-around;
  gap: 14px;
  padding: 8px 14px;
  color: var(--muted);
  border-top: 1px solid var(--line);
  font-size: 11px;
}

@media (max-width: 560px) {
  .embed {
    padding: 0;
  }

  .map-shell {
    border: 0;
    border-radius: 0;
  }

  .map-viewport {
    height: calc(100vh - 44px);
    min-height: calc(100vh - 44px);
  }

  .map-help span:nth-child(2) {
    display: none;
  }
}
