:root {
  color-scheme: light;
  --shell: #f7f8f2;
  --paper: #fffef9;
  --ink: #182c2b;
  --muted: #506261;
  --line: #dce6db;
  --teal: #175c55;
  --sea: #cfe9ed;
  --land: #f3f5e6;
  --park: #e0ebd4;
  --road: #bdc7bb;
  --small-road: #d8ded0;
  --major-road: #99aaa0;
  --river: #a1d0d9;
  --shadow: 0 12px 32px #20382c0b;
  --body: -apple-system, BlinkMacSystemFont, "PingFang SC", "Noto Sans CJK SC", "Microsoft YaHei", sans-serif;
  --display: "Songti SC", "Noto Serif CJK SC", "STSong", "SimSun", serif;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: var(--shell); font: 16px/1.55 var(--body); }
[hidden] { display: none !important; }
button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; color: inherit; cursor: pointer; }
a { color: var(--teal); text-underline-offset: .2em; }
:focus-visible { outline: 3px solid #217b70; outline-offset: 3px; }
h1, h2, h3, p { margin: 0; }
.site {
  width: min(100%, 1320px); margin-inline: auto;
  padding: 24px max(16px, env(safe-area-inset-right)) max(40px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
}
.masthead { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 20px; margin-bottom: 18px; }
.masthead h1 { font: 800 clamp(2rem, 5.4vw, 3.5rem)/1.16 var(--display); letter-spacing: -.055em; }
.masthead p { font-size: .875rem; color: var(--muted); }
.masthead p span { padding-inline: .22rem; color: #879793; }
.areas { display: flex; gap: 7px; align-items: center; margin: 0 0 12px; padding: 4px 4px 7px; overflow-x: auto; scrollbar-width: thin; }
.areas button {
  flex: 0 0 auto; min-height: 44px; padding: 7px 13px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--paper); color: var(--ink); font-size: .875rem; font-weight: 600; white-space: nowrap;
}
.areas button[aria-pressed="true"] { background: var(--teal); color: white; border-color: var(--teal); }
.layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, 315px); gap: 15px; align-items: start; }
.map-card { border: 1px solid var(--line); background: var(--paper); border-radius: 17px; box-shadow: var(--shadow); overflow: hidden; }
.stage {
  position: relative; overflow: hidden; isolation: isolate; touch-action: none; cursor: grab;
  height: clamp(390px, 56vh, 650px); background: var(--sea);
}
.stage.dragging { cursor: grabbing; }
.stage canvas, .overlay { position: absolute; inset: 0; width: 100%; height: 100%; }
.overlay { pointer-events: none; }
.label {
  position: absolute; white-space: nowrap; transform: translate(-50%, -50%); font-size: .8rem; font-weight: 650; line-height: 1.1;
  color: #263b36; text-shadow: 1px 0 #fffefa, -1px 0 #fffefa, 0 1px #fffefa, 0 -1px #fffefa;
}
.label.water { color: #35606a; letter-spacing: .09em; }
.label.road { color: #546754; font-size: .74rem; font-weight: 500; }
.label.transport::before { content: "●"; margin-right: .28em; font-size: .65em; }
.pin {
  --pin-color: var(--teal);
  position: absolute; z-index: 1; padding: 0; width: 38px; height: 38px; border: 0; background: transparent;
  transform: translate(-50%, -50%); display: grid; place-items: center; pointer-events: auto;
}
.pin span {
  display: grid; place-items: center; width: 26px; min-height: 26px; border-radius: 999px;
  background: var(--paper); border: 2px solid var(--pin-color); color: #142e2c;
  box-shadow: 0 1px 6px #163d3a25; font: 750 .78rem/1 var(--body);
}
.pin.cluster span {
  width: auto; min-width: 34px; min-height: 34px; padding: 0 4px; border: 2px solid #fffef9;
  background: var(--pin-color); color: white; font-weight: 750;
}
.pin.approx span { border-style: dashed; }
.pin.paused span { border-color: #7c8582; color: #4d5955; }
.pin.current { z-index: 2; }
.pin.current span { background: var(--teal); color: white; border: 2px solid white; box-shadow: 0 0 0 2px var(--teal); }
.compass, .scale { position: absolute; z-index: 3; left: 13px; color: #213d38; font-size: .73rem; font-weight: 650; pointer-events: none; }
.compass { top: 11px; }
.compass span { font-size: 1.04rem; }
.scale { bottom: 12px; border-bottom: 2px solid #213d38; white-space: nowrap; text-shadow: 0 0 4px #fffefa; }
.map-actions {
  z-index: 3; position: absolute; right: 10px; bottom: 10px; display: flex; padding: 2px;
  background: var(--paper); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 3px 9px #263b361f;
}
.map-actions button { min-width: 44px; min-height: 44px; background: transparent; border: 0; border-radius: 8px; font-weight: 650; font-size: 1.18rem; }
.map-actions button + button { border-left: 1px solid #e2e9dd; }
.map-actions button[data-action="reset"] { padding-inline: 10px; font-size: .79rem; }
.map-foot { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 2px 10px; padding: 9px 13px; color: var(--muted); font-size: .75rem; }
.map-foot a { color: var(--muted); }

.directory { min-width: 0; max-height: clamp(430px, 61vh, 690px); overflow: auto; border: 1px solid var(--line); border-radius: 17px; background: var(--paper); box-shadow: var(--shadow); }
.directory-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 13px 15px 8px; }
.directory-head h2 { font-size: 1.12rem; letter-spacing: -.02em; }
.place-count { color: var(--muted); font-size: .79rem; white-space: nowrap; }
.place-list { padding: 0 11px 10px; }
.place-group h3 { padding: 9px 4px 5px; color: var(--muted); font-size: .76rem; font-weight: 650; }
.place-group ul { list-style: none; margin: 0; padding: 0; }
.place-group li + li { border-top: 1px solid #eef0e8; }
.place-row { width: 100%; display: grid; grid-template-columns: 25px minmax(0, 1fr) 13px; align-items: center; gap: 9px; min-height: 54px; border: 0; background: transparent; border-radius: 9px; text-align: left; padding: 7px 4px; }
.place-row[aria-pressed="true"], .place-row:hover, .map-actions button:hover, .close:hover { background: #edf3ea; }
.place-number { display: grid; place-items: center; min-height: 25px; border: 1px solid var(--pin-color); color: var(--pin-color); border-radius: 50%; font-weight: 730; font-size: .75rem; }
.place-text { display: grid; gap: 1px; }
.place-text strong { font-size: .9rem; font-weight: 680; }
.place-sub { color: var(--muted); font-size: .75rem; }
.chevron { color: var(--muted); }
.detail { padding: 14px 15px 16px; background: #edf4ea; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.detail-head { display: flex; align-items: start; justify-content: space-between; gap: 8px; margin-bottom: 7px; }
.detail-area { color: var(--teal); font-weight: 690; font-size: .76rem; }
.detail h2 { font-size: 1.15rem; line-height: 1.28; margin-top: 4px; }
.close { flex: none; min-width: 44px; min-height: 44px; margin: -4px -5px 0 0; border-radius: 9px; border: 0; background: transparent; font-size: 1.45rem; }
.detail p + p { margin-top: 5px; }
.address { font-size: .9rem; }
.food { color: var(--muted); font-size: .83rem; }
.note { color: #6c4b2c; font-size: .81rem; margin-top: 8px; }
.detail-actions { display: flex; gap: 6px 12px; flex-wrap: wrap; align-items: center; margin-top: 11px; }
.amap-button { display: inline-flex; justify-content: center; align-items: center; gap: 7px; min-height: 44px; padding: 7px 13px; border-radius: 10px; background: var(--teal); color: white; font-size: .875rem; font-weight: 650; text-decoration: none; }
.amap-button:hover { background: #104b46; }
.alt-link { display: inline-flex; align-items: center; min-height: 44px; font-size: .83rem; }
.fallback { padding-top: 12px; }
.fallback li { margin-bottom: 6px; }

@media (pointer: coarse) {
  .pin { width: 44px; height: 44px; }
}
@media (max-width: 760px) {
  .site { padding-top: 18px; }
  .masthead { margin-bottom: 10px; gap: 4px 12px; }
  .masthead p { font-size: .8rem; }
  .layout { grid-template-columns: minmax(0, 1fr); gap: 11px; }
  .stage { height: clamp(250px, 78vw, 390px); }
  .areas { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); padding-inline: 2px; overflow: visible; }
  .areas button { padding-inline: 4px; white-space: normal; font-size: .82rem; line-height: 1.2; }
  .directory { max-height: none; }
}
@media (max-width: 378px) {
  .masthead { display: grid; }
  .masthead h1 { font-size: 2rem; }
  .map-foot { padding-inline: 10px; font-size: .69rem; }
}
