@import url("https://fonts.googleapis.com/css2?family=Open+Sans:wght@400;500;600;700&display=swap");

.fade {
  transition: opacity 1s 1s ease;
}

.container-box {
  margin: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 500px;
  /* gap: 70px; */
  padding: 30px 5px;
  background: #29678b;
  border-radius: 10px;
  justify-content: space-between;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}
.start-hang {
  width: 100%;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  /* background: grey; */
}
.start-button-div {
  flex: 1;
  position: relative;
  left: 20px;
}
.start-button {
  padding: 7px 13px;
  color: #030a83;
  background-color: #fff;
}

.start-button:hover,
.start-button:active,
.start-button:focus {
  background-color: #eee;
  color: #030a83;
}

.hangman-box {
  flex: 2.5;
  margin-top: 25px;
  margin-bottom: 30px;
}
.hangman-box img {
  user-select: none;
  max-width: 150px;
}

.game-box h3 {
  text-align: center;
  font-size: 1.3rem;
  color: #e6e5e5;
}
.game-box .hint-div {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: unset;
}

.game-box .hint-div b {
  color: #ffffff;
  font-size: 1.4rem;
}

.game-box .guesses-left-text b {
  color: #f31c04;
  font-size: 1.4rem;
}

.game-box .word-display {
  margin-top: 20px;
  gap: 10px;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  /* align-items: last baseline; */
}
.word-display .letter {
  width: 20px;
  height: 30px;
  line-height: 30px;
  font-size: 2rem;
  text-align: center;
  font-weight: 600;
  border-bottom: 3px solid #fff;
}
.word-display .letter.guessed {
  border-color: transparent;
  color: #fff;
}

.game-box .keyboard {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
  margin-top: 20px;
  justify-content: center;
}
:where(.game-modal, .keyboard) button {
  color: #fff;
  border: none;
  outline: none;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 4px;
  /* text-transform: uppercase; */
  background: #030a83;
}
.keyboard button {
  padding: 12px;
  width: calc(100% / 7 - 5px);
}
.keyboard button[disabled] {
  pointer-events: none;
  opacity: 0.6;
}
:where(.game-modal, .keyboard) button:hover {
  background: #303aea;
}

@media (min-width: 500px) {
  .container-box {
    padding: 30px 15px;
  }
  .game-box .hint-div {
    justify-content: space-around;
    align-items: baseline;
  }
}

@media (min-width: 782px) {
  .container-box {
    margin: auto;
    padding: 30px;
    flex-direction: column;
    align-items: center;
  }
  .hangman-box img {
    /* max-width: 200px; */
  }
}
