* {
  margin: 0;
  box-sizing: border-box;
}

:root {
  --main-bg-color: #000;
  --main-color: #fff;
}

html {
  font-family: 'Orbitron', Arial, Helvetica, sans-serif;
}

body {
  margin: 0;
  padding: 0;
  background-color: var(--main-bg-color);
  color: var(--main-color);
  min-height: 100vh;
  width: 100%;
  display: flex;
  flex-flow: column nowrap;
}

input,
button {
  font-family: inherit;
  outline: none;
}

p,
h1,
h2 {
  margin: 0;
  padding: 0;
}

.link,
.link:hover,
.link:active,
.link:focus {
  color: var(--main-color);
  text-decoration: underline;
}

.link:hover,
.link:active,
.link:focus {
  filter: brightness(75%);
  outline: none;
}

.link--github {
  padding: 0 5px;
}

.container {
  margin: 0;
  padding: 10px 0;
  width: 100%;
  flex: 1;
  display: flex;
  flex-flow: column nowrap;
  justify-content: center;
  align-items: center;
}

.row {
  display: flex;
  flex-flow: row wrap;
  align-content: center;
}

.col {
  display: flex;
  flex-flow: column nowrap;
}

.mh-auto {
  margin-left: auto;
  margin-right: auto;
}

.footer {
  height: 24px;
  width: 100%;
  padding: 4px 16px;
  margin: 0 auto;
  display: flex;
  flex-flow: row nowrap;
  align-items: center;
  justify-content: flex-end;
  background-color: var(--main-bg-color);
}

.game {
  width: 800px;
  height: 600px;
  margin: 0px auto;
  border: 2px solid #ffffe2;
}

.scoreboard {
  display: flex;
  flex-flow: column nowrap;
  max-height: 600px;
  width: 300px;
  padding: 20px;
}

@media (max-width: 1220px) {
  .scoreboard {
    width: 800px;
    margin: 0 auto;
  }
}

#scoreboardList {
  list-style-type: none;
  background: linear-gradient(#141414, #101010, #070707);
  padding-left: 0;
  flex: 1;
}

.scoreboard__score {
  display: flex;
  flex-flow: row nowrap;
  padding: 12px 4px;
}

.scoreboard__score__user {
  flex-basis: 70%;
}

.scoreboard__score__value {
  flex-basis: 30%;
}

.scoreboard__header {
  text-decoration: underline;
}

#scoreboardError {
  color: red;
}

.hidden {
  visibility: hidden;
}

.gone {
  display: none;
}

#userbox {
  height: 100px;
  width: 100%;
  padding: 12px;
  display: flex;
  flex-flow: column nowrap;
  row-gap: 10px;
}

.btn-md {
  font-size: 16px;
}

.btn-fancy {
  width: fit-content;
  height: fit-content;
  border: 1px solid rgba(0, 0, 0, 0.4);
  border-radius: 5px;
  outline: none;
  background: linear-gradient(#7ad468, #61b350);
  color: #fff;
  text-shadow: -1px -1px 0 rgba(0, 0, 0, 0.4), 1px -1px 0 rgba(0, 0, 0, 0.4),
    -1px 1px 0 rgba(0, 0, 0, 0.4), 1px 1px 0 rgba(0, 0, 0, 0.4);
}

.btn-fancy:hover,
.btn-fancy:active {
  background: linear-gradient(#3ea729, #419131);
}

.mode {
  width: 100%;
  height: 10%;
}

.mode__info {
  width: 100%;
  height: 100%;
  text-shadow: -1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000,
    1px 1px 0 #000;
  text-align: center;
  display: flex;
  flex-flow: row nowrap;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}

.mode__info--hidden {
  visibility: hidden;
}

.life,
.clock,
.score {
  flex-grow: 1;
  flex-basis: 0;
}

.gameplay {
  width: 100%;
  height: 70%;
  position: relative;
}

.menu {
  width: 100%;
  height: 100%;
  z-index: 100;
  position: absolute;
  background-color: rgba(128, 128, 128, 0.8);
  display: flex;
  flex-flow: column nowrap;
  align-items: center;
  justify-content: center;
}

.menu--hidden {
  display: none;
}

.menu__heading {
  text-align: center;
  text-transform: uppercase;
  color: #fff;
  text-shadow: -1px -1px 0 rgba(0, 0, 0, 0.4), 1px -1px 0 rgba(0, 0, 0, 0.4),
    -1px 1px 0 rgba(0, 0, 0, 0.4), 1px 1px 0 rgba(0, 0, 0, 0.4);
  width: 100%;
  margin-bottom: 20px;
}

.menu__heading--large {
  font-size: 40px;
}

.menu__heading--medium {
  font-size: 30px;
}

.menu__options {
  display: flex;
  flex-flow: column nowrap;
  row-gap: 12px;
  align-items: center;
  justify-content: center;
}

.menu__button {
  width: fit-content;
  height: fit-content;
  border: 1px solid rgba(0, 0, 0, 0.4);
  border-radius: 5px;
  outline: none;
  background: linear-gradient(#7ad468, #61b350);
  color: #fff;
  text-shadow: -1px -1px 0 rgba(0, 0, 0, 0.4), 1px -1px 0 rgba(0, 0, 0, 0.4),
    -1px 1px 0 rgba(0, 0, 0, 0.4), 1px 1px 0 rgba(0, 0, 0, 0.4);
  font-size: 36px;
}

.menu__button:focus,
.menu__button:hover,
.menu__button:active {
  background: linear-gradient(#3ea729, #419131);
}

.menu__button--hidden {
  display: none;
}

.target-area {
  width: 100%;
  height: 100%;
  display: grid;
  grid-template-columns: repeat(4, 200px);
  grid-template-rows: 100%;
  overflow: hidden;
}

.target {
  align-self: start;
  justify-self: center;

  position: relative;
  pointer-events: none;

  display: inline-flex;
  flex-flow: column nowrap;

  justify-content: center;
  align-items: center;
}

.controls {
  width: 100%;
  height: 20%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.game-input {
  width: 80%;
  height: 40px;
  border: 1px solid rgba(0, 0, 0, 0.4);
  border-radius: 5px;
  font-size: 20px;
  text-align: center;
  text-transform: uppercase;
}

.game-input--hidden {
  opacity: 0;
}

.instructions {
  width: 100%;
  padding: 15px;
  text-align: center;
}

.instructions__text {
  font-size: 20px;
}

.difficulty {
  display: flex;
  flex-flow: row nowrap;
  column-gap: 10px;
}

input[type="radio"].difficulty__radio {
  appearance: none;
  border: 0px;
  width: 0px;
  height: 0px;
}

.difficulty__label {
  width: fit-content;
  height: fit-content;
  border: 1px solid rgba(0, 0, 0, 0.4);
  border-radius: 5px;
  outline: none;
  background: linear-gradient(#337227, #143f0c);
  color: #fff;
  text-shadow: -1px -1px 0 rgba(0, 0, 0, 0.4), 1px -1px 0 rgba(0, 0, 0, 0.4),
    -1px 1px 0 rgba(0, 0, 0, 0.4), 1px 1px 0 rgba(0, 0, 0, 0.4);
  font-size: 36px;
}

input[type="radio"]:checked.difficulty__radio + .difficulty__label {
  background: linear-gradient(#7ad468, #61b350);
}
