@font-face {
  font-family: Heebo;
  src: url("fonts/Heebo-SemiBold.ttf");
}

body {
    font-family: Heebo, 'Franklin Gothic Medium', 'Arial Narrow', Arial, sans-serif; 
    color: white; 
    size: 3rem;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.unselectable {
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  -khtml-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

#game {
  background-color: #111;
  height: 400px;
  margin: 0 auto;
  overflow: hidden;
  position: relative;
  text-align: center;
  width: 400px;
  z-index: 0;
}
  
.interactiveText {
  color: white;
  font-size: 3rem;
  position: relative;
  text-decoration: none;
  top: 4rem;
  z-index: 1; 
  animation-duration: 2s;
  animation-timing-function: linear;
  animation-name: pulse;
  animation-direction: alternate;
  animation-iteration-count: infinite;
}

.pulse {
  animation-duration: 2s;
  animation-timing-function: linear;
  animation-name: pulse;
  animation-direction: alternate;
  animation-iteration-count: infinite; 
}

.countdownText {
  position: absolute;
  color: white;
  z-index: 20;
  font-size: 5rem;
  width: 400px;
  margin-top: 140px;
  animation: 1s 4 forwards countdownIntoScreen;
}

@keyframes countdownIntoScreen {
  from {
    transform: scale(2, 2);
    opacity: 0;
  }
  to {
    transform: scale(1, 1);
    opacity: 1;
  }
}

@keyframes fadeOut {
  from {
    opacity: 1;
  }
  to {
    opacity: 0;
  }
}

.playerTextContainer {
  margin: 0;
  position: absolute;
  width: 400px;
  height: 400px; 
  z-index: 20; 
}

.setupLine {
  width: 100%; 
  height: 12.5%; 
  text-align: center;
  font-size: 30px; 
}

.setupOption {
  margin-top: -15px; 
  margin-left: 10px; 
  margin-right: 10px; 
  width: 30%; 
  height: 100%;
  display: inline-block;
  color: white; 
  text-decoration: none;
}

.setupTitle {
  margin-top: 12.5px; 
  height: auto; 
}

.setupText {
  top: 25px; 
  height: auto;
  transform: translateY(-50%);
}

.selectedSetupText {
  color: yellow; 
}

.add {
  width: 50px;
  height:100%; 
  background-image: url("add.png");
}

.sub {
  height:100%; 
  width: 50px;
  background-image: url("sub.png");
}

.centeredText {
  margin: 0;
  position: absolute;
  top: 50%;
  width: 400px;
  transform: translate(0%, -50%);
  color: white;
  font-size: 2.5rem;
  text-decoration: none;
  z-index: 20; 
}

.endText {
  font-size: 32px;
  animation-duration: 10s;
  animation-timing-function: linear;
  animation-name: fadeInOut;
  animation-direction: alternate;
  animation-iteration-count: infinite; 
}

.roundOver {
  animation-duration: 1s;
  animation-timing-function: linear;
  animation-name: roundOverEffect;
  animation-direction: alternate;
  animation-iteration-count: infinite; 
}

@keyframes roundOverEffect {
  0% {
    color: red;
  }
  50% {
    color: blue;
  }
  100% {
    color: white;
  }
}

.fadeInOut {
  animation-duration: 10s;
  animation-timing-function: linear;
  animation-name: fadeInOut;
  animation-direction: alternate;
  animation-iteration-count: infinite;
}

@keyframes fadeInOut {
  0% {
    opacity: 0;
  }
  20% {
    opacity: 1;
  }
  80% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}

.endText:hover {
    color: yellow;
}

.interactiveText:hover {
    color: yellow;
}

@keyframes pulse {
  from {
    opacity: 1; 
  }
  to {
    opacity: 0.5;
  }
}

.player1 {
  background-color: #ff66cc;
}

.player2 {
  background-color: #1a66ff; 
}

.player3 {
  background-color: rgb(213, 50, 0); 
}

.player4 {
  background-color: rgb(30, 190, 0); 
}

.snakeChunk {
  width: 25px;
  height: 25px;
  position: absolute;
  z-index: -2;
  
  animation-duration: 2s;
  animation-timing-function: linear;
  animation-name: pulse;
  animation-direction: alternate;
  animation-iteration-count: infinite;
}

.snakeHead {
  background-image: url("head_1.png");
}

.image {
  background-repeat: no-repeat;
  background-size: cover;
  image-rendering: pixelated;
}

.destroyed {
  z-index: -3;
  animation: destroyedAnim 1000ms linear infinite, vibrateAnim 40ms infinite alternate;
}

@keyframes destroyedAnim {
  0% {
    opacity: 1;
  }
  10% {
    background-color: red;
  }
  30% {
    background-color: orangered;
  }
  30% {
    background-color: yellow;
  }
  40% {
    background-color: white;
  }
  50% {
    background-color: darkblue;
  }
  100% {
    opacity: 0;
  }
}

.vibrate {
  animation-duration: 40ms;
  animation-timing-function: linear;
  animation-name: vibrateAnim;
  animation-direction: alternate;
  animation-iteration-count: infinite;
}

@keyframes vibrateAnim {
  from {
    transform: scale(0.8, 0.8);
  }
  to {
    transform: scale(1.1, 1.1);
  }
}

.food {
  width: 12.5px;
  height: 12.5px;
  margin-left: 6.25px;
  margin-top: 6.25px; 
  position: absolute;
  z-index: -2;
  background-color: gray;
  animation-duration: 4s;
  animation-timing-function: linear;
  animation-name: rotateAnim;
  animation-direction: forward;
  animation-iteration-count: infinite;
}

@keyframes rotateAnim {
  from {
    transform: rotate(0deg);
  } 
  to {
    transform: rotate(360deg);
  }
}

.fadeOut {
  animation-duration: 4ms;
  animation-timing-function: ease-in-out;
  animation-name: fadeOutAnim;
  animation-direction: normal;
  animation-iteration-count: 1;
} 

@keyframes fadeOutAnim {
  from {
    opacity: 1;
  }
  to {
    opacity: 0;
  }
}
