body, html {
  height: 100%;
  margin: 0;
  padding: 0;
}

body {
  display: flex;
  flex-direction: row;
}

body.vertical {
  flex-direction: column;
}

.map {
  flex: 1;
  min-width: 0;
  min-height: 0;
}

#controls {
  position: fixed;
  top: 10px;
  right: 10px;
  z-index: 10;
  display: flex;
  gap: 10px;
}

#controls button {
  width: 50px;
  height: 50px;
  padding: 9px;
  border: none;
  border-radius: 8px;
  background: #fff;
  color: #333;
  opacity: 0.5;
  cursor: pointer;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
  transition: opacity 0.15s;
}

#controls button:hover,
#controls button:focus-visible {
  opacity: 0.9;
}

#controls svg {
  width: 100%;
  height: 100%;
  display: block;
}

#newLocationButton.busy svg {
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* The layout button shows the layout you'll switch to */
body.vertical #controls .icon-rows,
body:not(.vertical) #controls .icon-columns {
  display: none;
}
