:root {
  --bg: #0b0f19;
  --surface: #111827;
  --surface-2: #1f2937;
  --text: #f3f4f6;
  --text-secondary: #9ca3af;
  --accent: #22d3ee;
  --accent-2: #818cf8;
  --danger: #f87171;
  --radius: 16px;
  --shadow: 0 10px 30px rgba(0,0,0,0.35);
}

* { box-sizing: border-box; }
html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  line-height: 1.45;
}

.app {
  max-width: 980px;
  margin: 0 auto;
  padding: 24px;
}

.header {
  text-align: center;
  padding: 48px 12px 24px;
}
.header h1 {
  margin: 0 0 8px;
  font-size: clamp(28px, 5vw, 42px);
  letter-spacing: -0.02em;
}
.header p {
  margin: 0 0 20px;
  color: var(--text-secondary);
  font-size: 16px;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: none;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #0b0f19;
  font-weight: 700;
  font-size: 16px;
  padding: 14px 22px;
  border-radius: 999px;
  cursor: pointer;
  box-shadow: var(--shadow);
  transition: transform .08s ease, box-shadow .2s ease;
}
.btn-primary:hover { transform: translateY(-1px); }
.btn-primary:active { transform: translateY(0); }
.btn-primary[disabled] {
  opacity: .7;
  cursor: not-allowed;
}

.spinner {
  display: inline-block;
  width: 18px;
  height: 18px;
  border: 3px solid rgba(11,15,25,.25);
  border-top-color: #0b0f19;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.status {
  margin-top: 14px;
  min-height: 24px;
  color: var(--text-secondary);
  font-size: 14px;
}
.status.error { color: var(--danger); }

.results { margin-top: 8px; }

.card {
  background: var(--surface);
  border: 1px solid rgba(255,255,255,.06);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow);
}
.card h2 {
  margin: 0 0 12px;
  font-size: 16px;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: .08em;
}

.map-card {
  position: relative;
  padding: 0;
  overflow: hidden;
  margin-bottom: 16px;
}
#map {
  width: 100%;
  height: 380px;
  background: #0b0f19;
}
.map-overlay {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 400;
}
.badge {
  display: inline-block;
  background: rgba(0,0,0,.6);
  color: #fff;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,.1);
}

.grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}
@media (max-width: 720px) {
  .grid { grid-template-columns: 1fr; }
  #map { height: 280px; }
}

.kv-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.kv-grid.small { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 520px) {
  .kv-grid, .kv-grid.small { grid-template-columns: repeat(2, 1fr); }
}

.kv {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.kv-key {
  font-size: 12px;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: .06em;
}
.kv-value {
  font-size: 16px;
  font-weight: 600;
  word-break: break-word;
}

.place {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 10px;
  line-height: 1.35;
}
.hint {
  font-size: 13px;
  color: var(--text-secondary);
  margin: -6px 0 10px;
}

.footer {
  text-align: center;
  padding: 28px 12px 40px;
  color: var(--text-secondary);
  font-size: 13px;
}

.leaflet-container {
  background: #0b0f19;
  font-family: inherit;
}
