:root {
  --ink: #1a1a19;
  --ink-muted: #5e5e5a;
  --surface: #fcfcfb;
  --border: #d9d8d3;
  --accent: #1c5cab;
  --error: #a3262c;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; font: 14px/1.4 system-ui, -apple-system, "Segoe UI", sans-serif; color: var(--ink); }
#map { position: absolute; inset: 0; }
#panel {
  position: absolute; top: 12px; left: 12px; width: 300px; max-width: calc(100vw - 24px);
  background: var(--surface); border: 1px solid var(--border); border-radius: 8px;
  padding: 14px 16px; box-shadow: 0 2px 10px rgba(0,0,0,.12);
}
h1 { margin: 0 0 2px; font-size: 18px; letter-spacing: .01em; }
p { margin: 6px 0; }
.muted { color: var(--ink-muted); font-size: 12px; }
.hint { font-size: 13px; }
.error { color: var(--error); font-size: 13px; }
.row { display: flex; gap: 10px; margin: 10px 0 6px; }
.row label { flex: 1; display: flex; flex-direction: column; font-size: 12px; color: var(--ink-muted); }
.row input { margin-top: 2px; font: inherit; padding: 4px 6px; border: 1px solid var(--border); border-radius: 4px; background: #fff; }
.slider { display: block; margin: 8px 0 4px; font-size: 13px; }
.slider output { font-weight: 600; }
.slider input { width: 100%; margin-top: 4px; accent-color: var(--accent); }
#legend { display: flex; height: 14px; border-radius: 3px; overflow: hidden; margin: 8px 0 2px; }
#legend span { flex: 1; }
#legend-labels { display: flex; justify-content: space-between; font-size: 11px; color: var(--ink-muted); }
details { margin-top: 8px; font-size: 12px; color: var(--ink-muted); }
summary { cursor: pointer; }
.maplibregl-marker { cursor: grab; }
@media (max-width: 480px) {
  #panel { top: auto; bottom: 12px; left: 12px; right: 12px; width: auto; }
}
