:root {
  --lets-play-color:  rgb(0, 0, 0);
  --red-box-shadow:     inset 0 -3em 3em rgba(0, 29, 0, 0.3),
                        0 0 0 2px white,
                        .3em 0.3em 2em red;
  --green-box-shadow:     inset 0 -3em 3em rgba(0, 29, 0, 0.3),
                        0 0 0 2px white,
                        .3em 0.3em 2em #00ff00d6;
  --the-eastcode-red: rgb(163, 6, 32);
  --header-green:     #00ff00d6;
}

body.home-page,
body.scores-page,
body.game-page {
  display: flex;
  flex-direction: column;
  height: 100vh;
  margin: 0;
  font-family: monospace;
  background-image: url('../img/cobra.png'), linear-gradient(#0f0f0f 60%, #595b5e 100%);
  background-size: 300px, cover;
  background-position: 102% 130%;
  background-repeat: no-repeat;
}


body {
  display: flex;
  flex-direction: column;
  height: 100vh;
  margin: 0;
  font-family: monospace;
  background: linear-gradient(#0f0f0f 60%, #595b5e 100%);
}

video {
  width: 100%;
  height: 35%;
  object-fit: cover;
  position: fixed;
  bottom: 53%;
  left: 0;
  z-index: -200;
  animation: fadeIn 1s ease-in-out forwards;
}

.confetti {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: fixed;
  bottom: 0%;
  left: 0;
  z-index: -2;
}

header {
  width: 100%;
  color: #353535;
  background-color: #00ff00d6;
  text-align: center;
  box-shadow:
    inset 0 -3em 3em rgba(0, 200, 0, 0.3),
    0 0 0 2px white,
    .3em 0.3em 2em red;
  position: fixed;
  top: 0;
  padding: 20px;
}

ul.nav-ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

ul.nav-ul li {
  display: inline-block;
  margin-right: 30px;
  font-size: 14px;
}

.nav-link a {
  text-decoration: none;
  color: #333;
  font-weight: bold;
}

.nav-link a:hover {
  color: rgb(92, 229, 68);
}


em.name-em {
  color: rgb(163, 6, 32);
  font-family: shadows into light;
  font-weight: 900;
  font-size: 50px;
}

h1.main-heading {
  margin-top: 20px;
  text-align: center;
  font-size: 30px;
}

main {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-top: 110px;
  color: #f0f0f0;
  padding: 20px;
  height: 80vh;
  opacity: 0;
  animation: fadeIn 1s ease-in-out forwards;
}


@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

.about-section,
.team-section,
.play-section {
  margin: 20px 80px 30px 80px;
  text-align: center;
  max-width: 1000px;
}

.high-score {
  width: 600px;
  height: 500px;
  text-align: center;
  margin: 200px auto;
  overflow: hidden;
}

.about-section,
.team-section,
.high-score {
  box-shadow: 3px 3px 2px rgb(191, 197, 191), -.8em -.3em .6em rgb(4, 174, 4);
  padding: 15px 15px 15px 20px;
  background-color: #101010;
}

.about-section h2,
.team-section h2,
.play-section h2 {
  color: rgb(200, 12, 43);
  text-shadow: 1px .5px .2px rgb(154, 68, 68);
  display: inline-block;
  padding-bottom: 10px;
  margin-bottom: 20px;
  font-size: 20px;
}


.about-section p,
.high-score li {
  line-height: 1.2;
  font-size: 18px;
  text-align: justify;
}


.high-score h2 {
  color: rgb(158, 10, 35);
  text-shadow: 1px .5px .2px rgb(144, 94, 94);
  display: inline-block;
  padding-bottom: 10px;
  margin-bottom: 50px;
  font-size: 40px;
  font-weight: 900;
  animation: scrollAnimation 10s linear infinite;
  font-family: shadows into light;
}


.high-score ul {
  list-style: none;
  padding: 0;
  margin: 0;
  animation: scrollAnimation 10s linear infinite;
}

@keyframes scrollAnimation {
  0% {
    transform: translateY(0);
  }

  25% {
    transform: translateY(calc(-100% * 1));
  }

  50% {
    transform: translateY(calc(-100% * 2));
  }

  75% {
    transform: translateY(calc(-100% * 3));
  }

  100% {
    transform: translateY(calc(-100% * 4));
  }
}




.play-section button {
  background-color: rgb(0, 0, 0);
  height: 40px;
  width: 120px;
  border: 2px solid rgb(3, 193, 3);
  border-radius: 10px;
  color: rgb(3, 193, 3);
  font-weight: 600;
  padding: 5px 10px;
  margin: 5px 15px;
  box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
  cursor: pointer;
  animation: pulse 4s infinite;
}

@keyframes pulse {
  0% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.1);
  }

  100% {
    transform: scale(1);
  }
}

.play-section button:active {
  transform: scale(0.95);
  transition: transform 0.1s ease-in-out;
}


.play-section button:hover {
  background-color: rgb(3, 193, 3);
  color: black;
}

button {
  background-color: rgb(157, 255, 127);
  height: 50px;
  width: 100px;
  border-radius: 10px;
  padding: 10px;
  margin: 10px 10px 25px 10px;
  box-shadow: 5px 1px 3px rgb(0, 0, 0);
  cursor: pointer;
}

.start:active,
.stop:active {
  transform: scale(0.95);
  transition: transform 0.1s ease-in-out;
}

.start {
  color: white;
  background-color: #00ff00ae;
  border: 3px solid #067106ae;
  font-weight: 900;
}

.stop {
  color: white;
  background-color: red;
  border: 3px solid rgb(140, 13, 13);
  font-weight: 700;
}

.game-card {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 30px;
}

#gameCanvas {
  border: 2px solid white;
  margin-left: 20%;
  box-shadow: rgba(168, 168, 168, 0.35) 0px 10px 20px;
}

/* LETS PLAY PLAYER-NAME ELEMENT */
h1#player-name {
  font-size: 22px;
  font-weight: 500;
  background: #000;
  border: 2px solid white;
  border-bottom: none;
  box-shadow: rgba(168, 168, 168, 0.35) 0px 10px 20px;
  padding: 10px;
  color: #dbdbdb;
}

#player-name strong {
  color: var(--header-green);
  text-shadow: 2px 2px 2px var(--the-eastcode-red);
  font-style: italic;
  font-family: shadows into light;
  font-size: 28px;
}

.score-container {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  width: 20%;
}

.score-box {
  width: 150px;
  height: 60px;
  margin-bottom: 20px;
  border: 2px solid black;
  background-color: black;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  box-shadow: inset 0 0 5px 5px rgb(120, 121, 131);
  font-size: 15px;
}

canvas {
  border: 1px solid #fff;
  background-color: #000;
}

footer {
  background-color: #00ff00d1;
  padding: 10px;
  text-align: center;
  border-top: 2px solid white;
  position: fixed;
  bottom: 0;
  width: 100%;
  color: #353535;
}

.tutorial-container {
  text-align: center;
  padding: 20px;
  background-color: #101010;
  box-shadow: 3px 3px 2px rgb(144, 158, 144), -1em 0 .6em green;
  color: white;
  line-height: 2.0;
  display: none;
}

.tutorial-container h2 {
  color: rgb(200, 12, 43);
  font-weight: 600;
  font-size: 16px;
}

.toggle-tutorial {
  background-color: rgb(0, 0, 0);
  height: 40px;
  width: 120px;
  border: 2px solid rgb(3, 193, 3);
  border-radius: 10px;
  color: rgb(3, 193, 3);
  font-weight: 600;
  padding: 5px 10px;
  margin: 5px 15px;
  box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
  cursor: pointer;
  font-size: 15px;
}

.toggle-tutorial:hover {
  background-color: rgb(3, 193, 3);
  color: black;
}

.toggle-tutorial:active {
  transform: scale(0.95);
  transition: background-color 0.3s, color 0.3s;
}

/* Animation for Team Members*/
.rotating-text-wrapper {
  height: 10vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.rotating-text-wrapper p {
  font-size: 16px;
  margin: 0;
  padding: 0.3em;
  color: #fff;
  text-shadow: rgb(255, 204, 0) 1px 0 7px;
  box-shadow: 0 10px 10px rgba(0, 0, 0, 0.2);
  animation-duration: 10s;
  animation-iteration-count: infinite;
  opacity: 0;
}


.rotating-text-wrapper p:nth-child(1) {

  animation-name: rotating-text-1;
}

@keyframes rotating-text-1 {
  0% {
    transform: translateY(200%);
  }

  20% {
    transform: translateY(100%);
    opacity: 1;
  }

  21% {
    opacity: 0;
  }
}

.rotating-text-wrapper p:nth-child(2) {

  animation-name: rotating-text-2;
}

@keyframes rotating-text-2 {
  20% {
    transform: translateY(100%);
    opacity: 0;
  }

  40% {
    transform: translateY(0);
    opacity: 1;
  }

  41% {
    opacity: 0;
  }
}

.rotating-text-wrapper p:nth-child(3) {

  animation-name: rotating-text-3;
}

@keyframes rotating-text-3 {
  40% {
    transform: translateY(0);
    opacity: 0;
  }

  60% {
    transform: translateY(-100%);
    opacity: 1;
  }

  61% {
    transform: translateY(-100%);
    opacity: 0;
  }
}

.rotating-text-wrapper p:nth-child(4) {
  animation-name: rotating-text-4;
}

@keyframes rotating-text-4 {
  60% {
    transform: translateY(0);
    opacity: 0;
  }

  80% {
    transform: translateY(-150%);
    opacity: 1;
  }

  81% {
    opacity: 0;
  }
}

.rotating-text-wrapper p:nth-child(5) {

  animation-name: rotating-text-5;
}

@keyframes rotating-text-5 {
  80% {
    transform: translateY(-100%);
    opacity: 0;
  }

  99% {
    transform: translateY(-250%);
    opacity: 1;
  }

  100% {
    opacity: 0;
    transform: translateY(-250%);
  }
}
