:root {
  --dusksunset: #c497ff;
  --dusksky: #85bbff;
  --skyblue: #88d5fe;
  --seafoam: #83ffcd;
  --highlight: #83ffcd;
  --blue: #009ee0;
  --blue-highlight: #11AFF1;
  --blue-clear: #009ee000;
  --green-correct: #48a700;
  --green-correct-highlight: #66e803;
  --red-incorrect: #fe4c4c;
  --button-glass: #FFFFFFAA;
  --button-glass-highlight: #FFFFFFCC;
  --table-stripe: #FFFFFF33;
  --ui-outline: #eadeff;
  --text: #333;
  --text-highlight: #666;
}

/*-----------------------------
  General Styles
  ----------------------------- */

body {
  font-family: 'Source Sans Pro', sans-serif;
  background: linear-gradient(var(--dusksunset),var(--dusksky));
}

h1 {
  margin-bottom: 20px;
  font-size: 24px;
  font-weight: 900;
  color: var(--text);
}

.lite-button {
  display: inline-block;
  background-color: var(--button-glass);
  text-decoration: none;
  font-weight: bold;
  color: var(--text);
  padding: 10px;
  border-radius: 30px;
  margin: 0 10px;
  border-width: 0px;
  width: 20%;
  min-width: 120px;
  max-width: 200px;
  cursor: pointer;
}

.lite-button:hover {
  background-color: var(--button-glass-highlight);
  color: var(--text-highlight);
}

.std-button {
  display: inline-block;
  background-color: var(--blue);
  text-decoration: none;
  font-weight: bold;
  color: white;
  padding: 10px;
  border-radius: 30px;
  margin: 0 10px;
  border-width: 0px;
  cursor: pointer;
  width: 20%;
  min-width: 120px;
  max-width: 200px;
}

.std-button:hover {
  background-color: var(--blue-highlight);
}


/*-----------------------------
  Header / Top Bar Styles
  ----------------------------- */

header {
  position: relative;
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 10px 0;
}

header.ui-hidden {
  display: none;
}

#time-bar-container {
  position: relative;
  display: flex;
  justify-content: flex-start;
  height: 10px;
  border-radius: 10px;
  flex: 1 0 0;
  margin: 0 10px 0 -15px;
  background-color: var(--blue);
}

#time-bar {
  height: 10px;
  border-radius: 10px;
  background-color: white;
  width: 0%;
  transition: 1s;
  transition-timing-function: linear;
}

#time-bar.no-transition {
  transition: 0s;
}

#time-left {
  z-index: 2;
  margin: 10px;
  color: white;
  font-size: 24px;
  font-weight: bold;
  display: block;
  width: 70px;
  height: 70px;
  border-radius: 70px;
  text-align: center;
  line-height: 70px;
  background-color: var(--blue);
  animation-name: none;
  animation-iteration-count: 1;
  animation-duration: 0.4s;
}

#time-left::before {
  display: none;
}

@keyframes incorrect-pulse {
  0% {
    background-color: var(--red-incorrect);
  }
  100% {
    background-color: var(--blue);
  }
}

/*-----------------------------
  Main Styles 1: Info Screens
  ----------------------------- */

main {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 10px 0;
}

#info {
  font-size: 18px;
  font-weight: lighter;
  text-align: center;
  line-height: 1.25;
  width: 90%;
  max-width: 600px;
  margin-top: 20px;
}

#start-quiz, #submit-score {
  margin-top: 20px;
}

/*-----------------------------
  Main Styles 2: Quiz Screens
  ----------------------------- */

#ready-countdown {
  position: relative;
  top: 100px;
  font-weight: 900;
  color: var(--text);
  font-size: 48px;
  text-align: center;
  animation-name: none;
  animation-iteration-count: 1;
  animation-duration: 1s;
}

@keyframes ready-countdown-flash {
  0% {
    color: white;
  }
  100% {
    color: var(--text);
  }
}

#question-block {
  width: 90%;
  min-width: 120px;
  max-width: 600px;
}

#question-prompt {
  font-size: 18px;
  font-weight: lighter;
  text-align: left;
  line-height: 1.25;
  margin: 20px 0;
}

.question-answer {
  display: block;
  background-color: var(--blue);
  text-decoration: none;
  font-weight: bold;
  color: white;
  padding: 10px;
  border-radius: 30px;
  border-width: 0px;
  cursor: pointer;
  width: 100%;
  min-width: 120px;
  max-width: 600px;
  margin-top:10px;
}

.question-answer:hover {
  background-color: var(--blue-highlight);
}

.correct-card {
  position: absolute;
  z-index: 3;
  left: 30%;
  color: white;
  background-color: var(--green-correct);
  font-size: 24px;
  font-weight: 900;
  padding: 20px;
  width: 40%;
  text-align: center;
  border-radius: 20px;
  animation-name: fade-up;
  animation-timing-function: linear;
  animation-duration: 0.4s;
  opacity: 1;
  transform: translateY(-30px);
}

@keyframes fade-up {
  0% {
    opacity: 1;
    transform: translateY(0px);
    background-color: var(--green-correct-highlight);
  }
  100% {
    opacity: 0;
    transform: translateY(-30px);
    background-color: var(--green-correct);
  }
}

/*-----------------------------
  Main Styles 3: Hiscore Screens
  ----------------------------- */

#initial-form {
  margin-top: 20px;
  color: var(--text);
  font-family: 'Source Sans Pro', sans-serif;
  font-size: 18px;
}

#initial-form div {
  font-weight: 900;
  margin: 10px;
}

#initial-form input[type=text] {
  padding: 5px;
  margin: 10px;
  border-radius: 10px;
}

#initial-validation-alert.ui-hidden {
  display: none;
}

#hiscore-table {
  table-layout: fixed;
  width: 90%;
  text-align: center;
  border-collapse: collapse;
  color: var(--text);
  font-family: 'Source Sans Pro', sans-serif;
  font-size: 18px;
  margin-bottom: 10px;
}

#hiscore-table thead {
  font-weight: 900;
}

#hiscore-table thead tr th {
  padding: 10px;
}

#hiscore-table tbody {
  font-weight: 300;
}

#hiscore-table tbody tr td {
  padding: 10px;
}

#hiscore-table tbody tr:nth-child(odd) {
  background-color: var(--table-stripe);
}

#hiscore-table tbody tr#current-score {
  background-color: var(--blue);
  animation-name: my-score-pulse;
  animation-iteration-count: infinite;
  animation-duration: 1.0s;
  animation-timing-function: linear;
  color: white;
  font-weight: 900;
}

@keyframes my-score-pulse {
  0% {
    background-color: var(--blue);
  }
  50% {
    background-color: var(--blue-highlight);
  }
  100% {
    background-color: var(--blue);
  }
}

#button-box {
  width: 90%;
  display: flex;
  justify-content: center;
}

#return-to-start, #clear-hiscores {
  margin-top: 20px;
}

/*-----------------------------
  Media Queries
  ----------------------------- */

@media screen and (max-width: 450px) {

  #time-left {
    position: absolute;
    left: calc(50% - 35px);
    top: 20px;
    margin: -10px 0px 0px 0px;
    background-color: transparent;

  }

  #time-bar-container {
    margin: -15px 0px 0px 0px;
  }

  @keyframes incorrect-pulse {

  }

  

}