:root {
  color-scheme: dark;
  font-family: system-ui, sans-serif;
  background: #17162e;
  color: #ece9f7;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  overflow: hidden;
}

#world {
  position: fixed;
  inset: 0;
}

#world canvas {
  display: block;
  width: 100%;
  height: 100%;
  touch-action: none;
  cursor: grab;
}

#world canvas:active { cursor: grabbing; }

.render-unavailable {
  display: grid;
  place-items: center;
  padding: 24px;
  text-align: center;
}

.controls {
  display: flex;
  gap: 15px;
  position: fixed;
  inset: auto auto max(14px, env(safe-area-inset-bottom)) 50%;
  transform: translateX(-50%);
  padding: 5px 12px;
  margin: 0;
  border: 1px solid #a7a4e43b;
  border-radius: 9px;
  background: #121322df;
  box-shadow: 0 3px 18px #07071577;
}

.controls label {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  font-weight: 550;
  white-space: nowrap;
}

.controls input {
  width: clamp(48px, 15vw, 85px);
  height: 24px;
  margin: 0;
  accent-color: #f286dd;
}

.controls label + label input { accent-color: #6ad4ea; }

.controls input:focus-visible {
  outline: 2px solid #e9e0ff;
  outline-offset: 3px;
  border-radius: 4px;
}

@media (max-height: 430px) and (orientation: landscape) {
  .controls {
    inset: auto max(8px, env(safe-area-inset-right)) max(6px, env(safe-area-inset-bottom)) auto;
    transform: none;
  }
}

