body {
  margin: 0;
  padding: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: black;
  font-family: sans-serif;
  font-size: 14px;
  overflow: hidden;
  user-select: none;
}

#scoreContainer {
  position: absolute;
  z-index: 10;
  color: white;
  font-size: 17px;
  left: 14px;
  top: 14px;
  margin: 0;
  display: none;
  pointer-events: none;
  user-select: none;
}

#startScreen {
  width: 80%;
  height: 80%;
  margin: 0 auto;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 20;
  background: rgba(0, 0, 0, 0.5);
  border-radius: 16px;
  box-shadow: inset 0 0 10px rgba(0, 0, 0, 1);
}

.startScreenContainer {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 40px;
}

.startScreenBg {
  background-image: url('./img/wave.png');
  width: 100%;
  height: 100%;
  background-size: cover;
  display: flex;
  align-items: center;
  justify-content: center;
}

.restartScreenBg {
  background-image: url('./img/wave.png');
  width: 100%;
  height: 100%;
  background-size: cover;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 11px;
}

.starshipStartScreen {
  width: 50%;
  animation: bounce 1s infinite alternate;
}

@keyframes bounce {
  0% {
    transform: translateY(0);
  }
  100% {
    transform: translateY(-10px);
  }
}

.takeOff {
  transition: transform 2s ease;
  transform: translateY(-1000px);
}

.starshipStartScreenContainer {
  width: 100%;
  height: 100%;
}

.startScreenSx {
  width: 33%;
}

.startScreenCenter {
  width: 33% !important;
}

.startScreenSx {
  width: 33%;
}

#startButton {
  cursor: pointer;
  position: relative;
  display: inline-block;
  transition: transform 0.3s;
}

#startButton2 {
  cursor: pointer;
  position: relative;
  display: none;
  transition: transform 0.3s;
}

#startButton:hover,
#startButton2:hover,
#restartButton:hover {
  transform: scale(1.1);
}

#textStart {
  position: absolute;
  font-weight: bold;
  color: #222;
  top: 46%;
  transform: translate(-50%, -50%);
  left: 50%;
}

#restartScreen {
  width: 80%;
  height: 80%;
  margin: 0 auto;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 20;
  background: rgba(0, 0, 0, 0.5);
  border-radius: 16px;
  box-shadow: inset 0 0 10px rgba(0, 0, 0, 1);
  display: none;
}

#parentDiv {
  text-align: center;
  overflow: hidden;
}

canvas {
  margin: 0 auto;
  padding: 0;
  background-image: url('./img/bg.jpg');
  background-repeat: repeat-x;
  background-position: 0 0;
  height: 100vh;
  overflow: hidden;
  animation: scrollBackground 140s linear infinite;
}

@keyframes scrollBackground {
  to {
    background-position: 0 100%;
  }
}

#restartText {
  position: absolute;
  color: #222;
  font-weight: bold;
  top: 46%;
  transform: translate(-50%, -50%);
  left: 50%;
}

#restartButton {
  cursor: pointer;
  position: relative;
  display: inline-block;
  transition: transform 0.3s;
}

#gameOverText {
  color: white;
  font-size: 24px;
}

#finalScore {
  color: white;
  margin: 0;
  font-size: 48px;
}

#pointsText {
  color: white;
  margin-top: 0;
}

#buttonsContainer {
  display: flex;
  position: fixed;
  right: 20px;
  gap: 5px;
  top: 20px;
  z-index: 100;
}

#volumeButton,
#githubButton {
  width: 40px;
  height: 40px;
  cursor: pointer;
  transition: transform 0.3s;
}

#volumeButton img,
#githubButton img {
  width: 100%;
}

#volumeButton:hover,
#githubButton:hover {
  transform: scale(1.1);
}

#volumeStop {
  pointer-events: none;
  position: absolute;
  margin-top: 16px;
  width: 42px;
  height: 6px;
  rotate: 40deg;
  background-color: red;
  display: none;
}
