/* ------------------------------------------------------------------
   On-screen controls for touch devices
   ------------------------------------------------------------------ */

.touch {
  position: fixed;
  inset: 0;
  z-index: 5;
  pointer-events: none;
  display: none;
}

.touch.visible {
  display: block;
}

.touch-stick-zone {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 55%;
  height: 60%;
  pointer-events: auto;
  touch-action: none;
}

.touch-stick {
  position: absolute;
  left: 110px;
  top: calc(100% - 130px);
  width: 120px;
  height: 120px;
  margin: -60px 0 0 -60px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 0 0 3px rgba(255, 255, 255, 0.25);
  opacity: 0.35;
  transition: opacity 0.15s;
  pointer-events: none;
}

.touch-stick.active {
  opacity: 1;
}

.touch-knob {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 56px;
  height: 56px;
  margin: -28px 0 0 -28px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff, #b9a8ff);
  box-shadow: 0 0 0 3px var(--ink);
}

.touch-btn {
  position: absolute;
  pointer-events: auto;
  touch-action: none;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.12);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 60%;
  box-shadow: inset 0 0 0 3px rgba(255, 255, 255, 0.35), 0 6px 0 rgba(0, 0, 0, 0.3);
  transition: transform 0.08s;
}

.touch-btn.pressed {
  transform: scale(0.9);
  background-color: rgba(255, 210, 63, 0.35);
}

.touch-bomb {
  right: 24px;
  bottom: 30px;
  width: 96px;
  height: 96px;
  background-color: rgba(255, 122, 69, 0.35);
}

.touch-action {
  right: 132px;
  bottom: 22px;
  width: 64px;
  height: 64px;
}

.touch-pause {
  position: absolute;
  right: 50px;
  bottom: 150px;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: 12px;
  background: rgba(27, 19, 48, 0.7);
  pointer-events: auto;
}

.touch-pause i {
  width: 6px;
  height: 18px;
  border-radius: 2px;
  background: #fff;
}
