:root {
  color-scheme: dark;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #0c110e;
  color: #edf4ed;
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 20rem;
  background:
    radial-gradient(circle at 80% 0%, rgba(132, 165, 110, 0.09), transparent 35rem),
    #0c110e;
}

button,
input,
select {
  font: inherit;
}

.shell {
  height: 100dvh;
}

[hidden] {
  display: none !important;
}

.map {
  position: relative;
  min-height: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #07100b;
  box-shadow: 0 1.5rem 5rem rgba(0, 0, 0, 0.35);
}

#terrain {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  cursor: grab;
  touch-action: none;
}

#terrain:active {
  cursor: grabbing;
}

.map::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(4, 8, 6, 0.08), transparent 20%),
    linear-gradient(0deg, rgba(4, 8, 6, 0.1), transparent 20%);
}

.map-brand,
.controls,
.controls-open,
.compass,
.orbit-control,
.map-information,
.performance-hud {
  position: absolute;
  z-index: 3;
}

.map-brand {
  top: 1.25rem;
  left: 1.25rem;
  display: flex;
  align-items: baseline;
  gap: 0.35rem;
  padding: 0.45rem 0.65rem;
  border: 1px solid rgba(237, 244, 237, 0.14);
  border-radius: 0.65rem;
  background: rgba(9, 15, 11, 0.64);
  color: #c5d0c6;
  font-size: 0.76rem;
  pointer-events: none;
  backdrop-filter: blur(0.75rem);
}

.map-brand h1 {
  margin: 0;
  color: #edf4ed;
  font-size: 0.82rem;
  line-height: inherit;
}

.status {
  display: inline-block;
  width: max-content;
  max-width: 100%;
  margin: 0;
  padding: 0.4rem 0.65rem;
  border: 1px solid rgba(237, 244, 237, 0.17);
  border-radius: 999px;
  background: rgba(9, 15, 11, 0.65);
  color: #c5d0c6;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.7rem;
  backdrop-filter: blur(0.75rem);
}

.status[hidden] {
  display: none;
}

.status[data-kind="ready"] {
  color: #cfe6bf;
}

.status[data-kind="error"] {
  max-width: 31rem;
  border-color: rgba(235, 129, 112, 0.4);
  color: #ffb7aa;
}

.controls {
  top: 1.25rem;
  right: 1.25rem;
  width: min(14rem, calc(100% - 2.5rem));
  padding: 1rem;
  border: 1px solid rgba(237, 244, 237, 0.16);
  border-radius: 0.9rem;
  background: rgba(9, 15, 11, 0.72);
  box-shadow: 0 0.5rem 2rem rgba(0, 0, 0, 0.2);
  max-height: calc(100% - 2.5rem);
  overflow-y: auto;
  backdrop-filter: blur(1rem);
}

.controls-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.9rem;
  color: #edf4ed;
  font-size: 0.82rem;
}

.controls .controls-close {
  width: auto;
  padding: 0.3rem 0.5rem;
  color: #c5d0c6;
  font-size: 0.7rem;
}

.controls-open {
  top: 1.25rem;
  right: 1.25rem;
  padding: 0.55rem 0.75rem;
  border: 1px solid rgba(237, 244, 237, 0.2);
  border-radius: 0.65rem;
  background: rgba(9, 15, 11, 0.76);
  color: #edf4ed;
  cursor: pointer;
  backdrop-filter: blur(0.75rem);
}

.range-control,
.toggle,
.select-control {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  color: #dbe4dc;
  font-size: 0.8rem;
}

.range-control output {
  color: #a6c892;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

input[type="range"] {
  width: 100%;
  margin: 0.7rem 0 1rem;
  accent-color: #9fc879;
}

.toggle {
  justify-content: flex-start;
  margin-bottom: 0.8rem;
}

.toggle input {
  accent-color: #9fc879;
}

.select-control {
  margin: 0.2rem 0 0.9rem;
  color: #dbe4dc;
  font-size: 0.8rem;
}

.select-control select {
  min-width: 7.2rem;
  padding: 0.3rem 0.4rem;
  border: 1px solid rgba(237, 244, 237, 0.2);
  border-radius: 0.45rem;
  background: #172019;
  color: #dbe4dc;
}

.select-control option:disabled {
  color: #6f7a71;
}

.controls button {
  width: 100%;
  padding: 0.55rem 0.75rem;
  border: 1px solid rgba(237, 244, 237, 0.2);
  border-radius: 0.55rem;
  background: rgba(237, 244, 237, 0.08);
  color: inherit;
  cursor: pointer;
}

.controls button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.controls button:hover,
.controls button[aria-pressed="true"],
.controls-open:hover {
  background: rgba(166, 200, 146, 0.2);
}

.location-controls {
  display: grid;
  gap: 0.35rem;
  margin: 0.15rem 0 0.75rem;
  padding: 0.6rem 0;
  border-block: 1px solid rgba(237, 244, 237, 0.12);
}

.location-status {
  min-height: 1em;
  color: #9fac9f;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.66rem;
  line-height: 1.35;
  text-align: center;
}

.sun-controls,
.diagnostics-controls {
  margin: 0.2rem 0 0.9rem;
  padding: 0.55rem 0;
  border-block: 1px solid rgba(237, 244, 237, 0.12);
  color: #dbe4dc;
  font-size: 0.75rem;
}

.sun-controls summary,
.diagnostics-controls summary {
  cursor: pointer;
  color: #cfe6bf;
  font-size: 0.8rem;
}

.diagnostics-controls {
  margin: 0.9rem 0 0;
  border-bottom: 0;
}

.diagnostics-controls .toggle:first-of-type {
  margin-top: 0.75rem;
}

.sun-controls > label:first-of-type {
  display: block;
  margin: 0.7rem 0 0.3rem;
  color: #9fac9f;
}

.sun-controls input[type="datetime-local"] {
  box-sizing: border-box;
  width: 100%;
  padding: 0.35rem;
  border: 1px solid rgba(237, 244, 237, 0.2);
  border-radius: 0.45rem;
  background: #172019;
  color: #dbe4dc;
  color-scheme: dark;
}

.sun-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 0.5rem;
  margin: 0.55rem 0;
}

.sun-actions .toggle {
  margin: 0;
}

.sun-position {
  display: block;
  margin-top: 0.25rem;
  color: #9fac9f;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.67rem;
  line-height: 1.4;
}

.layer-group .toggle {
  margin-bottom: 0.45rem;
}

.poi-category-controls {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.3rem 0.55rem;
  margin: -0.05rem 0 0.9rem 1.45rem;
}

.poi-category-controls label {
  display: flex;
  align-items: center;
  gap: 0.28rem;
  color: #9fac9f;
  font-size: 0.66rem;
}

.poi-category-controls input {
  margin: 0;
  accent-color: #9fc879;
}

.hint {
  margin: 0.75rem 0 0;
  color: #8f9b91;
  font-size: 0.68rem;
  text-align: center;
}

.location-marker {
  --accuracy-diameter: 18px;
  position: absolute;
  z-index: 4;
  left: 50%;
  top: 50%;
  width: var(--accuracy-diameter);
  height: var(--accuracy-diameter);
  transform: translate(-50%, -50%);
  border: 1px solid rgba(108, 180, 255, 0.65);
  border-radius: 50%;
  background: rgba(55, 143, 235, 0.15);
  box-shadow: 0 0 0 1px rgba(7, 16, 11, 0.35);
  pointer-events: none;
}

.location-marker span {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 0.8rem;
  height: 0.8rem;
  transform: translate(-50%, -50%);
  border: 2px solid white;
  border-radius: 50%;
  background: #328ee6;
  box-shadow: 0 0.1rem 0.4rem rgba(0, 0, 0, 0.65);
}

.poi-layer {
  position: absolute;
  z-index: 2;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.national-osm-label {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 2;
  max-width: 10rem;
  overflow: hidden;
  color: #f7f8ef;
  font-size: 0.68rem;
  font-weight: 650;
  line-height: 1.05;
  text-overflow: ellipsis;
  text-shadow: 0 1px 2px #10130f, 0 0 3px #10130f;
  white-space: nowrap;
  pointer-events: none;
  transform-origin: left bottom;
}

.national-osm-label-place {
  font-size: 0.76rem;
  letter-spacing: 0.015em;
}

.national-osm-label-poi {
  color: #fff0bc;
}

.poi-marker {
  position: absolute;
  left: 0;
  top: 0;
  width: 0;
  height: 0;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  cursor: pointer;
  pointer-events: auto;
  will-change: transform;
}

.poi-marker::before {
  content: "";
  position: absolute;
  width: 1.5rem;
  height: 1.5rem;
  transform: translate(-50%, -50%);
}

.poi-symbol {
  position: absolute;
  left: 0;
  top: 0;
  width: 0.75rem;
  height: 0.75rem;
  transform: translate(-50%, -50%);
  background: #734a08;
  filter:
    drop-shadow(0 0 1px rgba(255, 255, 255, 0.9))
    drop-shadow(0 1px 2px rgba(0, 0, 0, 0.75));
  mask-position: center;
  mask-repeat: no-repeat;
  mask-size: contain;
  opacity: 0;
  transition: filter 120ms ease, opacity 120ms ease, transform 120ms ease;
}

.poi-marker:hover .poi-symbol,
.poi-marker:focus-visible .poi-symbol,
.poi-marker.is-selected .poi-symbol {
  transform: translate(-50%, -50%) scale(1.35);
  filter:
    drop-shadow(0 0 2px rgba(255, 255, 255, 1))
    drop-shadow(0 1px 4px rgba(0, 0, 0, 0.9));
  opacity: 1;
}

.poi-marker:focus-visible {
  outline: none;
}

.poi-marker[data-kind="peak"] .poi-symbol {
  width: 0.5rem;
  height: 0.5rem;
  background: #d08f55;
  mask-image: url("./assets/osm-carto-v6/natural/peak.svg?v=20260814-symbol-mime-1");
}

.poi-marker[data-kind="rock"] .poi-symbol {
  width: 0.6rem;
  height: 0.6rem;
  background: #a06f45;
  clip-path: polygon(18% 78%, 8% 48%, 34% 12%, 74% 20%, 94% 62%, 67% 90%);
  mask-image: none;
}

.poi-marker[data-kind="viewpoint"] .poi-symbol {
  width: 0.875rem;
  height: 0.875rem;
  background: #734a08;
  mask-image: url("./assets/osm-carto-v6/tourism/viewpoint.svg?v=20260814-symbol-mime-1");
}

.poi-marker[data-kind="spring"] .poi-symbol {
  width: 0.75rem;
  height: 0.75rem;
  background: #7abcec;
  mask-image: url("./assets/osm-carto-v6/natural/spring.svg?v=20260814-symbol-mime-1");
}

.poi-marker[data-kind="water"] .poi-symbol {
  width: 0.875rem;
  height: 0.875rem;
  background: #734a08;
  mask-image: url("./assets/osm-carto-v6/amenity/drinking_water.svg?v=20260814-symbol-mime-1");
}

.poi-marker[data-kind="parking"] .poi-symbol {
  width: 0.75rem;
  height: 0.75rem;
  background: #0066b3;
  mask-image: url("./assets/osm-carto-v6/amenity/parking.svg?v=20260814-symbol-mime-1");
}

.poi-marker[data-kind="trailhead"] .poi-symbol {
  width: 0.75rem;
  height: 0.75rem;
  border: 2px solid #0066b3;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.94);
  mask-image: none;
}

.poi-marker[data-kind="trailhead"] .poi-symbol::after {
  content: "";
  position: absolute;
  inset: 2px;
  border-radius: 50%;
  background: #0066b3;
}

.poi-marker[data-kind="shelter"] .poi-symbol {
  width: 0.875rem;
  height: 0.875rem;
  background: #666;
  mask-image: url("./assets/osm-carto-v6/amenity/shelter.svg?v=20260814-symbol-mime-1");
}

.poi-marker[data-source-tag="tourism=alpine_hut"] .poi-symbol {
  background: #0066b3;
  mask-image: url("./assets/osm-carto-v6/tourism/alpinehut.svg?v=20260814-symbol-mime-1");
}

.poi-label {
  position: absolute;
  left: 0.62rem;
  top: -0.55rem;
  max-width: 13rem;
  overflow: hidden;
  color: #222;
  font-size: 0.67rem;
  font-weight: 600;
  line-height: 1.15;
  text-overflow: ellipsis;
  text-shadow:
    -1px -1px 0 rgba(255, 255, 255, 0.92),
    1px -1px 0 rgba(255, 255, 255, 0.92),
    -1px 1px 0 rgba(255, 255, 255, 0.92),
    1px 1px 0 rgba(255, 255, 255, 0.92),
    0 1px 2px rgba(255, 255, 255, 0.75);
  white-space: nowrap;
}

.poi-marker[data-kind="peak"] .poi-label,
.poi-marker[data-kind="rock"] .poi-label,
.poi-marker[data-kind="viewpoint"] .poi-label {
  color: #7d4c22;
}

.poi-marker[data-kind="spring"] .poi-label {
  color: #006b9c;
}

.poi-marker[data-kind="water"] .poi-label {
  color: #734a08;
}

.poi-marker[data-kind="shelter"] .poi-label {
  color: #555;
}

.poi-marker[data-kind="parking"] .poi-label,
.poi-marker[data-kind="trailhead"] .poi-label {
  color: #005a9c;
}

.poi-marker[data-source-tag="tourism=alpine_hut"] .poi-label {
  color: #005a9c;
}

.poi-inspector {
  position: absolute;
  z-index: 4;
  width: min(16.25rem, calc(100% - 1.5rem));
  padding: 1rem;
  border: 1px solid rgba(237, 244, 237, 0.2);
  border-radius: 0.8rem;
  background: rgba(9, 15, 11, 0.92);
  box-shadow: 0 0.75rem 2.5rem rgba(0, 0, 0, 0.42);
  color: #dbe4dc;
  pointer-events: auto;
  backdrop-filter: blur(1rem);
}

.poi-inspector[hidden] {
  display: none;
}

.poi-inspector-close {
  position: absolute;
  top: 0.55rem;
  right: 0.6rem;
  padding: 0.2rem 0.35rem;
  border: 0;
  background: transparent;
  color: #9fac9f;
  font-size: 0.65rem;
  cursor: pointer;
}

.poi-inspector-close:hover,
.poi-inspector-close:focus-visible {
  color: #edf4ed;
}

.poi-inspector-kind {
  margin: 0 3rem 0.25rem 0;
  color: #a6c892;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.poi-inspector h3 {
  margin: 0 2.5rem 0.55rem 0;
  color: #f1f5ef;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.25rem;
  font-weight: 400;
  line-height: 1.05;
}

.poi-inspector-elevation {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0 0 0.65rem;
  color: #b6c0b8;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.65rem;
}

.poi-inspector-elevation span + span::before {
  content: "· ";
}

.poi-inspector-tags {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.2rem 0.65rem;
  margin: 0 0 0.7rem;
  font-size: 0.68rem;
}

.poi-inspector-tags:empty {
  display: none;
}

.poi-inspector-tags dt {
  color: #7f8b81;
}

.poi-inspector-tags dd {
  margin: 0;
  color: #cbd4cc;
}

.poi-inspector a {
  color: #a6c892;
  font-size: 0.68rem;
}

.map-information {
  top: 4.15rem;
  left: 1.25rem;
  display: grid;
  max-width: min(43rem, calc(100% - 18rem));
  gap: 0.4rem;
  pointer-events: none;
}

.map-attribution-line {
  width: fit-content;
  max-width: 100%;
  padding: 0.35rem 0.55rem;
  border: 1px solid rgba(237, 244, 237, 0.12);
  border-radius: 0.55rem;
  background: rgba(9, 15, 11, 0.58);
  color: #8f9b91;
  font-size: 0.62rem;
  line-height: 1.35;
  pointer-events: auto;
  backdrop-filter: blur(0.75rem);
}

.map-attribution-line a {
  color: #a6c892;
}

.map-attribution-line > a:last-child {
  margin-left: 0.45rem;
}

.compass {
  left: 1.25rem;
  bottom: 1.1rem;
  display: grid;
  justify-items: center;
  width: 7.25rem;
  padding: 0.5rem 0.5rem 0.4rem;
  border: 1px solid rgba(237, 244, 237, 0.14);
  border-radius: 0.85rem;
  background: rgba(9, 15, 11, 0.64);
  cursor: pointer;
  user-select: none;
  backdrop-filter: blur(0.75rem);
}

.compass:focus-visible {
  outline: 2px solid #b7dc9e;
  outline-offset: 0.25rem;
}

.compass svg {
  width: 6rem;
  height: 6rem;
  overflow: visible;
}

#compass-ring,
#compass-ns,
#compass-ew {
  fill: none;
  stroke: rgba(220, 234, 213, 0.66);
  stroke-width: 1.4;
  vector-effect: non-scaling-stroke;
}

#compass-ns {
  stroke: rgba(239, 176, 111, 0.82);
}

#compass-ew {
  stroke-dasharray: 2.5 3;
}

#compass-north-arrow {
  fill: #ed9d61;
  stroke: rgba(255, 231, 205, 0.75);
  stroke-width: 0.8;
  vector-effect: non-scaling-stroke;
}

.compass text {
  fill: #dce8d7;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 8px;
  font-weight: 700;
  text-anchor: middle;
  dominant-baseline: central;
}

#compass-n {
  fill: #f1a466;
}

#compass-heading {
  color: #aeb9b0;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.62rem;
  letter-spacing: 0.08em;
}

.orbit-control {
  left: 50%;
  bottom: 1.15rem;
  width: 4.5rem;
  height: 4.5rem;
  padding: 0;
  transform: translateX(-50%);
  border: 1px solid rgba(224, 238, 218, 0.46);
  border-radius: 50%;
  background:
    radial-gradient(circle at 34% 28%, rgba(239, 250, 225, 0.82), rgba(140, 181, 112, 0.58) 22%, rgba(38, 70, 46, 0.86) 66%, rgba(9, 18, 12, 0.96));
  box-shadow:
    inset -0.65rem -0.8rem 1.2rem rgba(0, 0, 0, 0.55),
    0 0.55rem 1.6rem rgba(0, 0, 0, 0.38);
  color: #f2f7ed;
  cursor: grab;
  touch-action: none;
  user-select: none;
  backdrop-filter: blur(0.75rem);
}

.orbit-control::before {
  content: "";
  position: absolute;
  inset: 0.55rem -0.35rem;
  border: 1px solid rgba(218, 236, 205, 0.42);
  border-radius: 50%;
  transform: rotate(-18deg);
}

.orbit-control span {
  position: relative;
  z-index: 1;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-shadow: 0 0.1rem 0.4rem rgba(0, 0, 0, 0.8);
}

.orbit-control:active {
  cursor: grabbing;
}

.orbit-control:focus-visible {
  outline: 2px solid #b7dc9e;
  outline-offset: 0.25rem;
}

.terrain-facts {
  display: grid;
  gap: 0.28rem;
  margin-top: 0.65rem;
}

.terrain-facts span {
  color: #8f9b91;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.62rem;
  line-height: 1.3;
}

.performance-hud {
  left: 9.5rem;
  bottom: 1.1rem;
  width: min(25rem, calc(100% - 26rem));
  padding: 0.65rem;
  border: 1px solid rgba(237, 244, 237, 0.2);
  border-radius: 0.65rem;
  background: rgba(5, 10, 7, 0.86);
  box-shadow: 0 0.5rem 2rem rgba(0, 0, 0, 0.28);
  color: #dbe4dc;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.66rem;
  line-height: 1.35;
  backdrop-filter: blur(0.75rem);
}

.performance-hud-header,
.performance-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.45rem;
}

.performance-hud-header strong {
  color: #edf4ed;
  font-size: 0.72rem;
}

.performance-hud-header span {
  margin-left: auto;
  color: #a6c892;
}

.performance-hud-header .performance-close {
  padding: 0.22rem 0.38rem;
  border: 1px solid rgba(237, 244, 237, 0.18);
  border-radius: 0.3rem;
  background: rgba(237, 244, 237, 0.08);
  color: #c5d0c6;
  font-size: 0.62rem;
  cursor: pointer;
}

#performance-chart {
  display: block;
  width: 100%;
  height: 3.4rem;
  margin: 0.42rem 0;
  border-radius: 0.25rem;
  background: rgba(255, 255, 255, 0.035);
}

.performance-grid {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 0.15rem 0.6rem;
}

.performance-grid > span {
  color: #829086;
}

.performance-grid output {
  min-width: 0;
  overflow-wrap: anywhere;
  color: #dbe4dc;
}

.performance-actions {
  justify-content: flex-end;
  margin-top: 0.55rem;
}

.performance-actions button {
  padding: 0.25rem 0.42rem;
  border: 1px solid rgba(237, 244, 237, 0.18);
  border-radius: 0.3rem;
  background: rgba(237, 244, 237, 0.08);
  color: #dbe4dc;
  cursor: pointer;
}

.performance-actions button:hover,
.performance-actions button[aria-pressed="true"] {
  background: rgba(166, 200, 146, 0.2);
}

@media (max-width: 44rem) {
  body {
    min-width: 0;
    overscroll-behavior: none;
  }

  .map-brand {
    top: max(0.7rem, env(safe-area-inset-top));
    left: max(0.7rem, env(safe-area-inset-left));
  }

  .controls-open {
    top: max(0.7rem, env(safe-area-inset-top));
    right: max(0.7rem, env(safe-area-inset-right));
    min-height: 2.75rem;
  }

  .controls {
    top: auto;
    right: max(0.7rem, env(safe-area-inset-right));
    bottom: max(0.7rem, env(safe-area-inset-bottom));
    left: max(0.7rem, env(safe-area-inset-left));
    width: auto;
    max-height: min(72dvh, calc(100% - 5rem));
    padding: 0.8rem;
    overscroll-behavior: contain;
  }

  .controls button {
    min-height: 2.65rem;
  }

  .controls .controls-close {
    min-height: 2.3rem;
  }

  .map-information {
    top: calc(max(0.7rem, env(safe-area-inset-top)) + 3.35rem);
    right: max(0.7rem, env(safe-area-inset-right));
    left: max(0.7rem, env(safe-area-inset-left));
    max-width: none;
  }

  .map-attribution-line {
    max-width: min(100%, 32rem);
    padding: 0.28rem 0.4rem;
    font-size: 0.54rem;
    line-height: 1.25;
  }

  .compass {
    left: max(0.7rem, env(safe-area-inset-left));
    bottom: max(0.7rem, env(safe-area-inset-bottom));
    transform: scale(0.82);
    transform-origin: left bottom;
  }

  .orbit-control {
    bottom: max(0.85rem, env(safe-area-inset-bottom));
    width: 3.9rem;
    height: 3.9rem;
  }

  .performance-hud {
    right: max(0.7rem, env(safe-area-inset-right));
    bottom: max(0.7rem, env(safe-area-inset-bottom));
    left: max(0.7rem, env(safe-area-inset-left));
    width: auto;
    max-height: calc(100dvh - 1.4rem - env(safe-area-inset-top) - env(safe-area-inset-bottom));
    overflow-y: auto;
  }
}
