:root { color-scheme: light; --teal: #0B6E6E; --ink: #1C2423; --muted: rgba(28,36,35,.55); --line: rgba(28,36,35,.08); --bg: #F3F7F6; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 15px/1.4 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  padding-bottom: calc(72px + env(safe-area-inset-bottom));
}
button, input { font: inherit; }
.bar {
  position: sticky; top: 0; z-index: 6;
  display: flex; align-items: center; gap: 4px; min-height: 52px;
  padding: 6px 52px; background: rgba(243,247,246,.94);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}
.bar .titles { flex: 1; min-width: 0; text-align: center; padding: 0 4px; }
.bar .titles strong { display: block; font-size: 16px; font-weight: 800; }
.bar .titles small { display: block; color: var(--muted); font-size: 12px; margin-top: 1px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.loc-btn {
  position: absolute; top: 50%; right: 6px; transform: translateY(-50%);
  width: 40px; height: 40px; padding: 0; border: 0; border-radius: 12px;
  background: transparent; color: var(--teal);
  display: grid; place-items: center; cursor: pointer;
}
.loc-btn svg { width: 24px; height: 24px; }
.loc-btn:hover { background: color-mix(in srgb, var(--teal) 10%, transparent); }
.loc-btn:disabled { opacity: .5; cursor: wait; }
body .php-nearby-menu { z-index: 7; }
.page { max-width: 720px; margin: 0 auto; }
.toolbar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  padding: 10px 12px 0;
}
.chips { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.chip {
  height: 34px; padding: 0 14px; border-radius: 999px; border: 1.5px solid #E3EBE9;
  background: #fff; color: var(--ink); font-weight: 700; font-size: 13px; cursor: pointer;
}
.chip.on { background: color-mix(in srgb, var(--teal) 12%, #fff); border-color: var(--teal); color: var(--teal); }
.search-box {
  display: flex; align-items: center; gap: 8px; width: 100%;
  height: 44px; padding: 0 12px; border-radius: 12px; background: #fff;
  border: 1.5px solid #E3EBE9;
}
.search-box svg { width: 20px; height: 20px; color: var(--muted); flex: none; }
.search-box input { flex: 1; min-width: 0; border: 0; outline: none; background: transparent; }
.search-box:focus-within { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(11,110,110,.14); }
.pane-map, .pane-list, .pane-name { display: none; }
body[data-mode="nearby"][data-view="map"] .pane-map { display: block; }
body[data-mode="nearby"][data-view="list"] .pane-list { display: block; }
body[data-mode="name"] .pane-name { display: block; }
body[data-mode="name"] .chips-nearby { display: none; }
body[data-mode="nearby"] .search-name { display: none; }
.map-wrap {
  position: relative;
  margin: 10px 12px 0;
  border-radius: 16px;
  overflow: hidden;
  border: 1.5px solid #E3EBE9;
  background: #fff;
  box-shadow: 0 4px 16px rgba(4, 32, 30, .06);
}
#nearby-map {
  width: 100%; height: 100%; min-height: 280px;
  background: #E7EEEC;
}
body[data-mode="nearby"][data-view="map"] .page {
  display: flex; flex-direction: column;
  height: calc(100dvh - 53px - 64px - env(safe-area-inset-bottom));
  padding-bottom: 0;
}
body[data-mode="nearby"][data-view="map"] { padding-bottom: calc(64px + env(safe-area-inset-bottom)); }
body[data-mode="nearby"][data-view="map"] .pane-map { display: flex; flex-direction: column; flex: 1; min-height: 0; }
body[data-mode="nearby"][data-view="map"] .map-wrap { flex: 1; min-height: 0; }
@media (min-width: 1100px) and (hover: hover) and (pointer: fine) {
  body[data-mode="nearby"][data-view="map"] .page { height: calc(100% - 53px); padding-bottom: 8px; }
}
.map-locate {
  position: absolute; left: 12px; bottom: 12px; z-index: 2;
  width: 44px; height: 44px; border: 1.5px solid rgba(255,255,255,.9);
  border-radius: 14px; background: var(--teal); color: #fff;
  box-shadow: 0 4px 14px rgba(4, 32, 30, .22);
  display: grid; place-items: center; cursor: pointer;
}
.map-locate svg { width: 22px; height: 22px; }
.map-locate:disabled { opacity: .6; cursor: wait; }
.map-msg {
  display: grid; place-items: center; height: 100%;
  color: var(--muted); font-weight: 600; padding: 24px; text-align: center;
}
.status {
  padding: 8px 16px 0; color: var(--muted); font-size: 13px; font-weight: 600;
}
.status.is-err { color: #B42318; }
.pond-list { display: flex; flex-direction: column; gap: 8px; padding: 12px 12px 24px; }
.pond-card {
  display: flex; align-items: stretch; gap: 0; background: #fff;
  border: 1px solid var(--line); border-radius: 14px; overflow: hidden;
}
.pond-card > a.main {
  flex: 1; min-width: 0; display: flex; gap: 10px; padding: 10px 8px 10px 10px;
  align-items: center;
}
.pond-card .cover {
  width: 56px; height: 56px; border-radius: 10px; object-fit: cover;
  background: #E7EEEC; flex: none;
}
.pond-card .ph {
  width: 56px; height: 56px; border-radius: 10px; flex: none;
  display: grid; place-items: center; background: #E7EEEC; font-size: 22px;
}
.pond-card .meta { min-width: 0; flex: 1; }
.pond-card .name { font-weight: 800; font-size: 15px; }
.pond-card .addr {
  margin-top: 2px; color: var(--muted); font-size: 13px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.pond-card .sub { margin-top: 2px; color: var(--teal); font-size: 12.5px; font-weight: 700; }
.pond-card .dir {
  flex: none; width: 48px; border: 0; border-left: 1px solid var(--line);
  background: #fff; color: var(--teal); cursor: pointer;
  display: grid; place-items: center;
}
.pond-card .dir svg { width: 22px; height: 22px; }
.pond-card .dir:disabled { opacity: .35; cursor: default; }
.empty, .loading {
  padding: 28px 16px; text-align: center; color: var(--muted); font-weight: 600;
}
.more {
  display: block; width: calc(100% - 24px); margin: 0 12px 20px; height: 44px;
  border: 0; border-radius: 12px; background: #fff; border: 1px solid var(--line);
  color: var(--ink); font-weight: 700; cursor: pointer;
}
.more[hidden] { display: none; }
