* {
  box-sizing: border-box;
}

html, body {
  height: 100%;
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

header {
  padding: 0.75rem 1rem;
  background: #0b3d91;
  color: #fff;
}

header h1 {
  margin: 0 0 0.25rem 0;
  font-size: 1.25rem;
}

header p {
  margin: 0;
  font-size: 0.9rem;
  opacity: 0.9;
}

.app-layout {
  display: flex;
  height: calc(100vh - 4.5rem);
}

#map {
  flex: 1;
  height: 100%;
}

.sidebar {
  width: 240px;
  flex-shrink: 0;
  background: #f7f8fa;
  border-right: 1px solid #ddd;
  padding: 1rem 0.85rem;
  overflow-y: auto;
  font-size: 0.9rem;
}

.sidebar__section {
  margin-bottom: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.sidebar__label {
  font-weight: 600;
  color: #333;
}

.sidebar__select {
  padding: 0.4rem;
  border-radius: 4px;
  border: 1px solid #ccc;
  font-size: 0.9rem;
}

.sidebar__checkbox {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  cursor: pointer;
}

.sidebar__hint {
  font-size: 0.75rem;
  color: #888;
  font-style: italic;
  margin-left: auto;
}

.sidebar__button {
  padding: 0.5rem 0.75rem;
  border: none;
  border-radius: 4px;
  background: #0b3d91;
  color: #fff;
  cursor: pointer;
  font-size: 0.9rem;
}

.sidebar__button:hover {
  background: #0a3480;
}

.sidebar__status {
  font-size: 0.8rem;
  color: #555;
  margin: 0;
  min-height: 1.1em;
}

.sidebar__slider-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding-left: 0.1rem;
}

.sidebar__slider {
  width: 100%;
  accent-color: #2980b9;
}

.sidebar__slider-group .sidebar__status {
  font-weight: 600;
  color: #2980b9;
}

/* Facility markers (schools, hospitals) - see js/facilities.js */

.facility-icon {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
  position: relative;
}

.facility-icon--school {
  border: 2px solid #2ea043;
  font-size: 14px;
}

.facility-icon--hospital {
  border: 2px solid #e3342f;
}

.facility-icon--hospital::before,
.facility-icon--hospital::after {
  content: '';
  position: absolute;
  background: #e3342f;
}

.facility-icon--hospital::before {
  width: 12px;
  height: 3px;
}

.facility-icon--hospital::after {
  width: 3px;
  height: 12px;
}

@media (max-width: 640px) {
  .app-layout {
    flex-direction: column;
    height: auto;
  }

  .sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid #ddd;
  }

  #map {
    height: 70vh;
  }
}
