.home-river-map-art {
  aspect-ratio: 2.5;
  background: #eae5d2;
  container-type: inline-size;
  isolation: isolate;
}

.home-planner-feature-copy h1 { scroll-margin-top: 120px; }

.home-river-map-art > .home-map-terrain {
  position: absolute;
  inset: 0;
  height: 100%;
}

.home-river-map .home-river-map-places > li { position: static; padding: 0; transform: none; }
.home-river-map .home-river-map-places > li::before { content: none; }

.home-map-sight {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.home-map-landmark {
  position: absolute;
  top: var(--art-y);
  left: var(--art-x);
  width: var(--art-width);
  height: auto;
  transform: translate(-50%, -50%);
  transition: filter 150ms ease;
  pointer-events: auto;
  user-select: none;
}

.home-map-pin,
.home-map-city,
.home-map-gorge {
  position: absolute;
  top: var(--y);
  left: var(--x);
  line-height: 1.24;
  white-space: nowrap;
  paint-order: stroke fill;
  -webkit-text-stroke: 1.65px #f7edda;
}

.home-map-pin {
  z-index: 1;
  display: grid;
  place-items: center;
  min-width: 30px;
  min-height: 29px;
  padding: 3px 4px;
  color: #213d36;
  font-size: clamp(11px, 2.18cqw, 16px);
  font-weight: 700;
  pointer-events: auto;
}

.home-map-pin::before {
  position: absolute;
  top: var(--dot-y, 50%);
  left: var(--dot-x, 50%);
  width: 8px;
  height: 8px;
  transform: translate(-50%, -50%);
  border: 1px solid #fff6e3;
  border-radius: 50%;
  background: #a13528;
  content: "";
}

.home-map-above .home-map-pin { --dot-y: 100%; transform: translate(-50%, -100%); padding-bottom: 9px; }
.home-map-below .home-map-pin { --dot-y: 0%; transform: translateX(-50%); padding-top: 9px; }
.home-map-right .home-map-pin { --dot-x: 0%; transform: translateY(-50%); padding-left: 8px; }
.home-map-left .home-map-pin { --dot-x: 100%; transform: translate(-100%, -50%); padding-right: 8px; }

.home-map-sight:is(:hover, :focus-visible) .home-map-pin { z-index: 2; color: #842f20; }
.home-map-sight:is(:hover, :focus-visible) .home-map-pin span { text-decoration: underline; text-underline-offset: 3px; }
.home-map-sight:is(:hover, :focus-visible) .home-map-landmark { filter: drop-shadow(0 0 3px #fff6d7); }
.home-map-sight:focus-visible { outline: none; }
.home-map-sight:focus-visible .home-map-pin { outline: 2px solid #842f20; border-radius: 2px; }

.home-map-city,
.home-map-gorge {
  transform: translate(-50%, -50%);
  font-family: "Noto Serif SC", "Songti SC", SimSun, serif;
  font-weight: 700;
  pointer-events: none;
}

.home-map-city { color: #173c33; font-size: clamp(14px, 3.05cqw, 22px); }
.home-map-city:first-of-type { transform: translate(0, -50%); }
.home-map-gorge { color: #733e2c; font-size: clamp(10px, 1.82cqw, 14px); }

@media (max-width: 640px) {
  .home-river-map-art { aspect-ratio: 2.12; }
  .home-map-pin { min-height: 26px; }
  .home-map-sight[data-scenic="cq-yunyang-001"] .home-map-pin { padding-top: 25px; }
  .home-map-city:first-of-type { margin-left: -4px; }
}

@media (prefers-reduced-motion: reduce) {
  .home-map-landmark { transition: none; }
}
