* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;
  overflow: hidden;
  background: #1a1a1a;
}

#map-wrapper {
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  position: relative;
}

#map {
  /* Worst-case: extreme aspect ratio (e.g. 32:9 ultrawide) at 90° rotation
     Make it a square where side = vw + vh to guarantee full coverage
     at any rotation angle and any aspect ratio */
  width: calc(100vw + 100vh);
  height: calc(100vw + 100vh);
  position: absolute;
  /* Center the oversized map within the wrapper */
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  transform-origin: center center;
}

#speed {
  position: fixed;
  bottom: 24px;
  left: 24px;
  background: rgba(0, 0, 0, 0.75);
  color: #fff;
  font-family: 'SF Mono', 'Fira Code', 'Consolas', monospace;
  font-size: 28px;
  font-weight: 700;
  padding: 12px 20px;
  border-radius: 8px;
  z-index: 1000;
  min-width: 120px;
  text-align: center;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.leaflet-control-attribution {
  font-size: 9px !important;
}
