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

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
}

body {
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 249, 205, 0.12), transparent 42%),
    linear-gradient(180deg, #76d6ef 0%, #8fdbb8 56%, #172321 100%);
}

.game-shell {
  position: fixed;
  inset: 0;
  overflow: hidden;
  touch-action: none;
}

#game {
  display: block;
  width: 100vw;
  height: 100vh;
}

.touch-pad {
  position: fixed;
  left: max(18px, env(safe-area-inset-left));
  bottom: max(18px, env(safe-area-inset-bottom));
  display: flex;
  gap: 12px;
  pointer-events: auto;
}

.jump-pad {
  position: fixed;
  right: max(18px, env(safe-area-inset-right));
  bottom: max(18px, env(safe-area-inset-bottom));
  pointer-events: auto;
}

.pad-button {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.32);
  border-radius: 50%;
  color: rgba(255, 255, 255, 0.94);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.24), rgba(255, 255, 255, 0.09)),
    rgba(9, 22, 28, 0.42);
  box-shadow:
    0 18px 40px rgba(20, 36, 35, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  cursor: pointer;
}

.pad-button:active,
.pad-button.is-pressed {
  transform: translateY(2px) scale(0.98);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.12)),
    rgba(10, 49, 60, 0.56);
}

.jump-button {
  width: 68px;
  height: 68px;
}

.pad-button svg {
  width: 34px;
  height: 34px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 3.2;
}

@media (hover: hover) and (pointer: fine) {
  .touch-pad {
    opacity: 0.74;
    transition: opacity 160ms ease;
  }

  .touch-pad:hover {
    opacity: 1;
  }
}

@media (max-width: 640px) {
  .pad-button {
    width: 58px;
    height: 58px;
  }

  .jump-button {
    width: 62px;
    height: 62px;
  }

  .pad-button svg {
    width: 31px;
    height: 31px;
  }
}
