:root {
  --bg-top: #bde7ff;
  --bg-bottom: #6bc6ff;
  --panel: rgba(255, 255, 255, 0.7);
  --ink: #04233f;
  --sand: #d6bb79;
  --seaweed: #1d8f5a;
  --button: #0d5c8f;
  --button-pressed: #083b5c;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  font-family: "Trebuchet MS", "Verdana", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, 0.65), transparent 30%),
    linear-gradient(180deg, var(--bg-top), var(--bg-bottom));
}

body {
  overflow: hidden;
}

.app {
  position: relative;
  width: 100vw;
  height: 100vh;
}

#game {
  width: 100%;
  height: 100%;
  display: block;
  background: linear-gradient(180deg, #c8f0ff 0%, #70cbff 65%, #4ba8e8 100%);
  touch-action: none;
}

.overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  padding: 18px;
  pointer-events: none;
}

.overlay .touch-controls {
  pointer-events: auto;
}

.touch-controls {
  display: flex;
  gap: 12px;
  width: min(100%, 360px);
}

.touch-controls button {
  flex: 1;
  border: 0;
  border-radius: 16px;
  padding: 14px 18px;
  font: inherit;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: white;
  background: var(--button);
  box-shadow: inset 0 -4px 0 rgba(0, 0, 0, 0.18);
}

.touch-controls button:active,
.touch-controls button.is-pressed {
  background: var(--button-pressed);
  transform: translateY(1px);
}

@media (max-width: 640px) {
  .overlay {
    padding: 12px;
  }

  .touch-controls {
    width: 100%;
  }
}
