body {
  margin: 0;
  height: 100%;
}

html,
body {
  height: 100%;
  overflow: hidden;
}
html {
  background: radial-gradient(ellipse, #1b2735 0%, #090a0f 100%);
}

#app {
  min-height: 100%;
  position: relative;
  z-index: 9999;
  height: 100%;
  width: 100%;
}

/* PLAYER */

#player {
  width: 120px;
  height: 150px;
  background-size: contain;
  position: absolute;
  bottom: 20px;
  left: calc(50% - 75px);
  transition: all 0.3s ease-out;
  background-repeat: no-repeat;
  background-position: center;
  z-index: 9998;
}

#player.skin1 {
  background-image: url(../images/space-ship-1.png);
}

#player.skin2 {
  background-image: url(../images/space-ship-2.png);
}

#player.skin3 {
  background-image: url(../images/space-ship-3.png);
}

/* BULLET */

.bullet {
  position: absolute;
  top: 60%;
  left: calc(50% - 2px);
  width: 4px;
  height: 20px;
  background-color: #fff;
  border-radius: 6px/10px;
  box-shadow: 0px 0px 10px, 0px 0px 2px inset;
  animation: glow 1.5s linear infinite;
  z-index: 9998;
}

@keyframes glow {
  from {
    color: lime;
    box-shadow: 0px 0px 9px lime;
  }

  50% {
    color: lime;
    box-shadow: 0px 0px 18px lime;
  }

  to {
    color: lime;
    box-shadow: 0px 0px 9px lime;
  }
}

/* BOMB */

.bomb {
  position: absolute;
  top: -100px;
  width: 50px;
  height: 50px;
  background-color: #fff;
  border-radius: 50%;
  box-shadow: 0px 0px 10px, 0px 0px 2px inset;
  animation: glow 1.5s linear infinite;
  z-index: 9997;
}

.bomb.boom {
  width: 250px;
  height: 250px;
  transition: 0.3s;
  background-image: url(../images/electrical-discharge.gif);
  background-repeat: no-repeat;
  background-position: center;
  background-size: cover;
}

/* ENEMY */

.enemy {
  width: 130px;
  height: 150px;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  position: absolute;
  top: -150px;
  left: calc(50% - 75px);
  transition: all 0.3s ease-out;
  z-index: 9996;
}

.enemy.skin1.boom {
  background-image: url(../images/boom.gif);
  background-repeat: no-repeat;
  background-position: center;
}
.enemy.skin2.boom {
  background-image: url(../images/boom-3.gif);
  background-repeat: no-repeat;
  background-position: center;
}

.enemy.skin1 {
  background-image: url(../images/enemy1.png);
}

.enemy.skin2 {
  background-image: url(../images/enemy2.png);
}

/* ASTEROID */

.asteroid {
  width: 100px;
  height: 65px;
  background-image: url(../images/asteroid1.png);
  position: absolute;
  top: -150px;
  left: 40%;
  transition: all 0.3s ease-out;
  transform: rotate(36deg);
  z-index: 9995;
}

.asteroid.boom {
  background-image: url(../images/boom-2.gif);
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
}

.asteroid-small {
  width: 65px;
  height: 33px;
  background-image: url(../images/asteroid1.png);
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  position: absolute;
  top: -150px;
  left: 40%;
  transition: all 0.3s ease-out;
  transform: rotate(36deg);
  z-index: 9994;
}

.asteroid-small.boom {
  background-image: url(../images/spaceship-life.svg);
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
}

/* START/END GAME WINDOWS */

.start-game,
.end-game {
  width: 400px;
  height: 300px;
  background: #020001;
  border-radius: 10px;
  position: absolute;
  top: calc(50% - 150px);
  left: calc(50% - 200px);
  box-shadow: rgba(255, 255, 255, 0.05) 0px 4px 16px,
    rgba(255, 255, 255, 0.05) 0px 8px 32px;
  padding: 20px;
  z-index: 9999;
}

.end-game {
  height: 330px;
  top: calc(50% - 165px);
}

.start-game h1,
.end-game h1,
.result {
  margin: 10px auto;
  font-family: monospace;
  text-align: center;
  font-size: 28px;
  color: #c004c0;
  text-shadow: rgba(2, 0, 1, 0.5) 1px 1px 3px;
}

.start-game button,
.end-game button {
  background-image: linear-gradient(
    92.88deg,
    #c23cc2 9.16%,
    #c519c5 43.89%,
    #c004c0 64.72%
  );
  border-radius: 15px;
  border-style: none;
  box-sizing: border-box;
  color: #ffffff;
  cursor: pointer;
  font-family: monospace;
  font-size: 20px;
  font-weight: 500;
  height: 3rem;
  padding: 0 1.3rem;
  text-align: center;
  text-shadow: rgba(2, 0, 1, 0.5) 1px 1px 3px;
  transition: all 0.5s;
  touch-action: manipulation;
  margin: 20px auto;
  display: block;
}

.start-game button:hover,
.start-game button:focus,
.end-game button:hover,
.end-game button:focus {
  box-shadow: rgba(255, 255, 255, 0.5) 1px 1px 8px,
    rgba(255, 255, 255, 0.3) 1px 1px 10px;
  transition-duration: 0.1s;
}

.start-game .skins {
  display: flex;
}

.start-game .select-skin {
  width: 30%;
  height: 150px;
  margin: 5px;
  border: 2px solid #c004c0;
  background-repeat: no-repeat;
  background-size: contain;
  background-position: center;
  cursor: pointer;
}

.start-game .select-skin:hover,
.start-game .select-skin:focus {
  border: 2px solid lime;
  box-shadow: rgba(255, 255, 255, 0.5) 1px 1px 8px,
    rgba(255, 255, 255, 0.3) 1px 1px 10px;
  transition-duration: 0.1s;
}

.start-game .select-skin.skin-1 {
  background-image: url(../images/space-ship-1.png);
}

.start-game .select-skin.skin-2 {
  background-image: url(../images/space-ship-2.png);
}

.start-game .select-skin.skin-3 {
  background-image: url(../images/space-ship-3.png);
}

.start-game .skins input {
  display: none;
}

.start-game .skins input[type="radio"]:checked + label {
  border: 2px solid lime;
}

.end-game svg {
  fill: #c004c0;
  margin: 0 auto;
  display: block;
  width: 150px;
  height: 150px;
}

.end-game img {
  margin: 0 auto;
  display: block;
  width: 400px;
  height: 150px;
}

.game-elements {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
}

/* MENU */

.menu .sound svg {
  width: 50px;
  height: 50px;
  margin: 10px;
  fill: #fff;
}

.menu .sound {
  cursor: pointer;
}

.menu {
  display: flex;
  justify-content: space-between;
  position: relative;
  z-index: 9999;
}

.menu .lifes {
  display: flex;
  margin: 10px;
}
.menu .lifes span {
  background-image: url(../images/spaceship-life.svg);
  width: 50px;
  height: 50px;
  display: block;
  background-repeat: no-repeat;
  background-size: contain;
}

.menu .score {
  color: #fff;
  font-family: monospace;
  font-size: 42px;
  font-weight: 700;
  -webkit-text-stroke: 0.5px #000000;
  margin-top: 10px;
  right: 80px;
  position: absolute;
  z-index: 9999;
}

/* PLANETS */

.planet {
  position: absolute;
  top: -500px;
  left: 30px;
  transition: all 0.3s ease-out;
  z-index: 1;
  background-size: contain;
}

.planet.skin-1 {
  width: 500px;
  height: 500px;
  background-image: url(../images/planet1.png);
}

.planet.skin-2 {
  width: 300px;
  height: 300px;
  background-image: url(../images/planet2.png);
}

.planet.skin-3 {
  width: 450px;
  height: 450px;
  background-image: url(../images/death-star.png);
}

.planet.skin-4 {
  width: 130px;
  height: 130px;
  background-image: url(../images/planet3.png);
}

/* ARROWS */

.arrow-left {
  position: absolute;
  bottom: 30px;
  right: 30px;
  transition: all 0.3s ease-out;
  width: 100px;
  height: 100px;
  background-image: url(../images/iconizer-arrow_left_circle_icon.svg);
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  opacity: 0.3;
  z-index: 9999;
}

.arrow-right {
  position: absolute;
  bottom: 30px;
  left: 30px;
  transition: all 0.3s ease-out;
  width: 100px;
  height: 100px;
  background-image: url(../images/iconizer-arrow_right_circle_icon.svg);
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  opacity: 0.3;
  z-index: 9999;
}

/* HELPERS */

.hidden {
  display: none;
}
