@font-face {
  font-family: "Gamer";
  src: url("assets/font/gamer.ttf") format("truetype");
  font-style: normal;
  font-weight: normal;
  font-display: swap;
}

html, body {
    margin: 0;
    padding: 0;
    background-color: #bceeff;
    height: 100%;
    overflow: hidden;
    font-family: "Gamer", monospace;
  }

  body {
    display: flex;
    align-items: center;
    justify-content: center;
    background-image: url("assets/backgrounds/jumper-page-day.png");
    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;
    background-attachment: fixed;
  }

  canvas {
    border: 4px solid #fff;
    image-rendering: pixelated;
    background: #72cdf8;
    max-height: 95vh;
    max-width: 95vw;
    width: auto;
    height: auto;
  }

.controls {
  position: fixed;
  left: 50%;
  bottom: 6px;
  transform: translateX(-50%);
  display: none;
  align-items: end;
  justify-content: space-around;
  gap: clamp(7px, 2.2vw, 24px);
  width: min(94vw, 780px);
  box-sizing: border-box;
  padding: 10px clamp(8px, 2vw, 20px) 7px;
  border: 5px solid #05090c;
  border-radius: 14px;
  background: linear-gradient(#14232d, #08131b);
  box-shadow:
    0 0 0 4px #66747b,
    0 0 0 7px #171d21,
    0 7px 0 7px rgba(0, 0, 0, .72),
    inset 0 0 0 3px #263842,
    inset 0 -8px 14px rgba(0, 0, 0, .45);
  z-index: 5;
  user-select: none;
  touch-action: none;
}

.control-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-width: 0;
}

.key-row {
  display: flex;
  gap: clamp(6px, 1.5vw, 13px);
}

.controls .key {
  min-width: 0;
  width: clamp(43px, 10vw, 68px);
  height: clamp(43px, 10vw, 68px);
  padding: 0;
  border: 4px solid #090d10;
  border-radius: 8px;
  outline: 3px solid #899399;
  outline-offset: -7px;
  background: linear-gradient(145deg, #253039 0 17%, #0b1116 18% 76%, #020406 77%);
  color: #fff;
  font: 700 clamp(21px, 5vw, 34px)/1 "Gamer", monospace;
  text-shadow: 3px 3px 0 #000;
  /*box-shadow:
    0 4px 0 #020304,
    0 6px 0 #768187,
    inset 0 0 0 3px #17232b;*/
  -webkit-tap-highlight-color: transparent;
}

.controls .key:active {
  transform: translateY(4px);
  box-shadow: 0 2px 0 #768187, inset 0 0 0 3px #17232b;
}

.controls .jump {
  width: clamp(76px, 20vw, 126px);
  font-size: clamp(17px, 4.4vw, 29px);
}

.control-label {
  color: #ffd800;
  font: 700 clamp(15px, 4vw, 28px)/1 "Gamer", monospace;
  letter-spacing: 1px;
  text-shadow: 3px 3px 0 #000;
  white-space: nowrap;
}

.audio-key {
  font-family: system-ui, sans-serif !important;
  font-size: clamp(17px, 4vw, 27px) !important;
}

@media (pointer: coarse), (max-width: 800px) {
  .controls {
    display: flex;
  }

  canvas {
    max-height: calc(100vh - 112px);
  }
}

@media (max-width: 520px) {
  .controls {
    gap: 6px;
    padding-inline: 7px;
  }

  .sound-controls .control-label {
    font-size: 13px;
  }
}
