html,
body {
  height: 100%;
  margin: 0;
  padding: 0;
  font-family: Arial, Helvetica, sans-serif;
}

#map {
  height: 100%;
  width: 100%;
}

.control-panel {
  background: #ffffff;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);
  box-sizing: border-box;
  left: 12px;
  max-height: calc(100vh - 24px);
  overflow: auto;
  padding: 14px;
  position: absolute;
  top: 12px;
  width: min(360px, calc(100vw - 24px));
  z-index: 1000;
}

.control-panel h1 {
  font-size: 18px;
  line-height: 1.2;
  margin: 0 0 12px;
}

.form-row {
  margin-bottom: 10px;
}

label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 4px;
}

.slider-label {
  align-items: center;
  display: flex;
  justify-content: space-between;
}

.slider-value {
  color: #52606d;
  font-size: 13px;
  font-weight: 400;
}

input,
textarea,
button {
  box-sizing: border-box;
  font: inherit;
  width: 100%;
}

input,
textarea {
  border: 1px solid #b8c0c8;
  border-radius: 4px;
  padding: 8px;
}

input[type="range"] {
  padding: 8px 0;
}

textarea {
  min-height: 112px;
  resize: vertical;
}

.actions {
  display: grid;
  gap: 8px;
  grid-template-columns: 1fr 1fr;
}

button {
  background: #164b7a;
  border: 0;
  border-radius: 4px;
  color: #ffffff;
  cursor: pointer;
  font-weight: 700;
  padding: 9px 10px;
}

button.secondary {
  background: #5d6875;
}

button:disabled {
  cursor: wait;
  opacity: 0.7;
}

.status {
  color: #2d3748;
  font-size: 13px;
  line-height: 1.35;
  margin-top: 10px;
  min-height: 18px;
}

.status.error {
  color: #b42318;
}

.rail-status {
  color: #52606d;
  font-size: 12px;
  line-height: 1.35;
  margin-top: 8px;
}

.leaflet-control-layers label {
  align-items: center;
  display: flex;
  gap: 6px;
  margin: 0;
  white-space: nowrap;
}

.leaflet-control-layers input {
  margin: 0;
  width: auto;
}

.leaflet-control-layers span {
  align-items: center;
  display: inline-flex;
}

.clear-overlap-control button {
  background: #ffffff;
  border: 0;
  border-radius: 2px;
  box-shadow: 0 1px 5px rgba(0, 0, 0, 0.65);
  color: #222222;
  cursor: pointer;
  font: 13px/1.2 Arial, Helvetica, sans-serif;
  padding: 7px 9px;
  width: auto;
}

.clear-overlap-control button:hover {
  background: #f4f4f4;
}

.clear-overlap-control.is-hidden {
  display: none;
}

.popup-override {
  border-top: 1px solid #d0d7de;
  margin-top: 8px;
  padding-top: 8px;
}

.popup-override label {
  align-items: center;
  display: flex;
  font-size: 12px;
  font-weight: 400;
  gap: 6px;
  margin: 0 0 6px;
}

.popup-override input[type="checkbox"] {
  width: auto;
}

.popup-override input[type="range"] {
  width: 170px;
}

.popup-override-slider.is-hidden {
  display: none;
}

.popup-override.is-hidden {
  display: none;
}
