body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #f5f5f5;
  color: #222;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background: #ffffff;
  border-bottom: 1px solid #ddd;
}

.logo {
  font-weight: 600;
  letter-spacing: 1px;
}

.add-place-btn {
  padding: 8px 12px;
  border-radius: 6px;
  border: none;
  background: #4a4a4a;
  color: #fff;
  cursor: pointer;
  font-size: 14px;
}

.main {
  padding: 16px;
  max-width: 960px;
  margin: 0 auto;
}

.address-section {
  margin-bottom: 16px;
}

.address-label {
  display: block;
  margin-bottom: 8px;
  font-size: 14px;
}

.address-row {
  display: flex;
  gap: 8px;
}

.address-input {
  flex: 1;
  padding: 8px 10px;
  border-radius: 6px;
  border: 1px solid #ccc;
  font-size: 14px;
}

.primary-btn {
  padding: 8px 16px;
  border-radius: 6px;
  border: none;
  background: #4a4a4a;
  color: #fff;
  cursor: pointer;
  font-size: 14px;
}

.error-text {
  margin-top: 4px;
  color: #c00000;
  font-size: 13px;
}

.section-title {
  margin: 16px 0 8px;
  font-size: 16px;
}

.categories-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.category-btn {
  padding: 8px 6px;
  font-size: 12px;
  border-radius: 6px;
  border: none;
  background: #4a4a4a;
  color: #fff;
  cursor: pointer;
  text-align: center;
}

.category-btn.active {
  background: #c00000;
}

.results-section {
  margin-top: 16px;
}

.results-header {
  margin-bottom: 8px;
  font-size: 14px;
  font-weight: 500;
}

.results-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 12px;
}

.result-item {
  padding: 6px 8px;
  background: #ffffff;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
}

.result-item.selected {
  border: 1px solid #c00000;
}

.place-details {
  padding: 10px;
  background: #ffffff;
  border-radius: 6px;
  font-size: 14px;
}

.place-details-row {
  margin-bottom: 4px;
}

.show-on-map-btn {
  margin-top: 8px;
  padding: 8px 12px;
  border-radius: 6px;
  border: none;
  background: #c00000;
  color: #fff;
  cursor: pointer;
  font-size: 14px;
}

/* Мобильная адаптация */
@media (max-width: 600px) {
  .categories-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .address-row {
    flex-direction: column;
  }

  .primary-btn {
    width: 100%;
  }
}
/* Спиннер загрузки */
.loading-overlay {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 24px;
  color: #666;
  font-size: 14px;
}

.spinner {
  width: 20px;
  height: 20px;
  border: 3px solid #ddd;
  border-top-color: #4a4a4a;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Radius selector */
.radius-selector {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 0 12px;
  flex-wrap: wrap;
}
.radius-label {
  font-size: 14px;
  color: #555;
}
.radius-btn {
  padding: 6px 16px;
  border: 1px solid #1a73e8;
  border-radius: 20px;
  background: #fff;
  color: #1a73e8;
  font-size: 13px;
  cursor: pointer;
}
.radius-btn.active {
  background: #1a73e8;
  color: #fff;
}
