html {
  height: 100dvh;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

body {
  height: 100%;
  margin: 0;
  user-select: none;
}

#canvas {
  image-rendering: pixelated;
  display: block;
  width: 100%;
  height: 100%;
}

#fps,
#fullscreen,
#github {
  position: fixed;
  border-radius: 100px;
  background-color: #e5e6e7;
  z-index: 2;
  box-shadow: 0 1px 8px #99999980;
  display: flex;
  justify-content: center;
  align-items: center;
  line-height: 16px;
  font-size: 13px;
}

#fps {
  left: 16px;
  top: 16px;
  padding: 3px 12px 4px;
}

#fullscreen {
  cursor: pointer;
  right: 16px;
  top: 16px;
  min-width: 42px;
  width: 42px;
  height: 42px;
  padding: 6px;
  box-sizing: border-box;
}

#github {
  right: 16px;
  bottom: 16px;
  min-width: 48px;
  width: 48px;
  height: 48px;
  transition: transform 0.4s ease, background-color 0.4s ease;
  padding: 10px;
  box-sizing: border-box;
}

#github:hover {
  transform: translateY(-4px);
  background-color: #dadbdc;
}

@media screen and (max-width: 600px) {
  #fps {
    left: 10px;
    top: 12px;
    padding: 3px 10px;
    font-size: 11px;
    line-height: 12px;
  }

  #fullscreen {
    right: 10px;
    top: 12px;
    min-width: 30px;
    width: 30px;
    height: 30px;
    padding: 4px;
  }

  #github {
    right: 10px;
    bottom: 12px;
    min-width: 30px;
    width: 30px;
    height: 30px;
    padding: 6px;
  }
}

@media only screen and (orientation: portrait) {
  html {
    display: flex;
    justify-content: center;
    align-items: center;
  }

  body {
    width: 100dvh;
    height: 100dvw;
    -webkit-transform: rotate(90deg);
    -moz-transform: rotate(90deg);
    -o-transform: rotate(90deg);
    -ms-transform: rotate(90deg);
    transform: rotate(90deg);
  }

  #canvas {
    width: 100dvh;
    height: 100dvw;
  }
}
