:root {
  color-scheme: light;
  font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body,
.map {
  width: 100%;
  height: 100%;
  min-height: 320px;
  margin: 0;
}

body {
  overflow: hidden;
  background: #edf0f3;
}

.map {
  position: relative;
  overflow: hidden;
  cursor: grab;
  touch-action: none;
  user-select: none;
}

.map.is-dragging {
  cursor: grabbing;
}

.map-tiles,
.map-shade {
  position: absolute;
  inset: 0;
}

.map-tile {
  position: absolute;
  width: 256px;
  height: 256px;
  max-width: none;
  pointer-events: none;
  -webkit-user-drag: none;
}

.map-shade {
  pointer-events: none;
  background: linear-gradient(180deg, rgba(255,255,255,.05), rgba(82,61,118,.035));
}

.map-marker {
  position: absolute;
  z-index: 4;
  width: 34px;
  height: 44px;
  transform: translate(-50%, -100%);
  filter: drop-shadow(0 4px 5px rgba(47,28,70,.32));
  pointer-events: none;
}

.map-marker::before {
  content: "";
  position: absolute;
  inset: 0 0 10px;
  border-radius: 50% 50% 50% 0;
  background: #563d79;
  transform: rotate(-45deg);
}

.map-marker::after {
  content: "";
  position: absolute;
  top: 9px;
  left: 9px;
  width: 16px;
  height: 16px;
  border: 4px solid #fff;
  border-radius: 50%;
}

.map-marker-label {
  position: absolute;
  z-index: 4;
  transform: translate(-50%, 10px);
  padding: 6px 10px;
  border-radius: 5px;
  background: #fff;
  color: #4e376f;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.3;
  white-space: nowrap;
  box-shadow: 0 3px 12px rgba(52,36,70,.22);
  pointer-events: none;
}

.map-card {
  position: absolute;
  z-index: 6;
  top: 14px;
  left: 14px;
  width: min(360px, calc(100% - 84px));
  padding: 13px 15px 12px;
  border-radius: 8px;
  background: rgba(255,255,255,.97);
  color: #3f3159;
  box-shadow: 0 5px 18px rgba(49,34,67,.2);
  cursor: default;
  user-select: text;
}

.map-card-title {
  margin: 0 0 5px;
  font-size: 17px;
  line-height: 1.35;
}

.map-card-address {
  margin: 0 0 8px;
  color: #635879;
  font-size: 13px;
  line-height: 1.55;
}

.map-card-link {
  color: #ef5800;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

.map-card-link:hover,
.map-card-link:focus-visible {
  text-decoration: underline;
}

.map-controls {
  position: absolute;
  z-index: 7;
  right: 14px;
  bottom: 34px;
  display: grid;
  overflow: hidden;
  border-radius: 7px;
  background: #fff;
  box-shadow: 0 3px 12px rgba(48,34,66,.23);
}

.map-control {
  display: grid;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 0;
  border-bottom: 1px solid #e5e0eb;
  background: #fff;
  color: #513b70;
  cursor: pointer;
  place-items: center;
  font: 700 24px/1 Arial, sans-serif;
}

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

.map-control:hover,
.map-control:focus-visible {
  background: #f4f0f8;
  outline: none;
}

.map-control-home {
  font-size: 19px;
}

.map-attribution {
  position: absolute;
  z-index: 6;
  right: 6px;
  bottom: 5px;
  padding: 2px 5px;
  border-radius: 3px;
  background: rgba(255,255,255,.86);
  color: #5e5765;
  font-size: 11px;
  line-height: 1.3;
  text-decoration: none;
}

@media (max-width: 520px) {
  .map-card {
    top: 10px;
    left: 10px;
    width: calc(100% - 66px);
    padding: 10px 12px;
  }

  .map-card-title {
    font-size: 15px;
  }

  .map-card-address {
    font-size: 12px;
  }

  .map-controls {
    right: 10px;
    bottom: 30px;
  }
}
