* {
  margin: 0;
  padding: 0;
  font-family: "Poppins", sans-serif;
}

.gbg {
  background: linear-gradient(-45deg, #ee7752, #e73c7e, #23a6d5, #23d5ab);
  background-size: 400% 400%;
  animation: gradientBG 15s ease infinite;
  color: #ffffff;
}
@keyframes gradientBG {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}
body {
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: space-evenly;
  align-items: center;
}

.main-container {
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: space-evenly;
  align-items: center;
}

.heading {
  font-size: 5rem;
  margin-bottom: 2rem;
}

#name-container {
  display: flex;
  justify-content: center;
  align-items: center;
}

.players {
  height: 70vh;
  width: 35vw;
  display: flex;
  flex-direction: column;
  justify-content: space-evenly;
  align-items: center;
  background-color: rgba(222, 217, 217, 0.171);
  border-radius: 2rem;
  box-shadow: 0 0 20px black;
  backdrop-filter: blur(6px);
  margin-bottom: 4rem;
}

.name {
  font-size: 2.5rem;
}

.players input {
  width: 40vw;
  background: transparent;
  box-shadow: 0 0 1rem rgba(0, 0, 0, 0.3);
  font-size: 1.2rem;
  border: none;
  border-radius: 1rem;
  padding: 20px;
}
.players input::placeholder {
  color: lightgray;
}
.players button {
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
}

#turn-indicator {
  font-size: 1.3rem;
  position: relative;
  bottom: 50px;
  color: white;
}
.container {
  height: 60vh;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  position: relative;
  bottom: 40px;
}

.game {
  height: 60vmin;
  width: 60vmin;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 1.5vmin;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  transition: 0.5s ease;
}

.box {
  height: 18vmin;
  width: 18vmin;
  font-size: 8vmin;
  font-weight: 600;
  border: none;
  border-radius: 0.8rem;
  box-shadow: 0 0 1rem rgba(0, 0, 0, 0.8);
  transition: transform 0.2s ease, background-color 0.3s ease;
}
.box:hover {
  transform: scale(1.04);
  background-color: rgba(255, 255, 255, 0.3);
}
.box:active {
  transform: scale(0.95);
}

button {
  transition: all 0.3s ease;
}
button:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 10px rgba(255, 255, 255, 0.3);
}

.btn {
  padding: 1rem;
  font-size: 1.5rem;
  background: transparent;
  border: none;
  color: white;
  border-radius: 10px;
  cursor: pointer;
  box-shadow: 0 0 1rem rgba(0, 0, 0, 0.3);
  transition: transform 0.2s ease, box-shadow 0.3s ease;
}

.btn:hover {
  transform: scale(1.02);
  box-shadow: 0 0 1rem rgba(0, 0, 0, 0.8);
}

.btn:active {
  transform: scale(0.95);
}

#reset-btn {
  position: relative;
  bottom: 10px;
}

.msg-container p {
  font-size: 6vmin;
  margin: 3rem;
}

.msg-container {
  height: 100vh;
  width: 100vw;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}
#msg {
  height: 80vh;
  width: 60vw;
  background-color: rgba(222, 217, 217, 0.171);
  border-radius: 2rem;
  box-shadow: 0 0 20px black;
  backdrop-filter: blur(10px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}
.hide {
  display: none;
}

.winner-text {
  font-size: 2rem;
  font-weight: bold;
  color: white;
}

@media (max-width: 480px) {
  .heading {
    font-size: 10vmin;
    margin-top: 6vh;
  }

  .players {
    margin-top: 1rem;
    width: 75vw;
    height: 60vh;
    padding: 2rem 1rem;
  }
  .players .name {
    font-size: 1.8rem;
  }

  .players input {
    width: 60vw;
    font-size: 1.2rem;
    padding: 12px;
  }
  .players button {
    font-size: 1rem;
  }
  #turn-indicator {
    font-size: 1.1rem;
    bottom: 10px;
  }
  .game {
    height: 70vmin;
    width: 70vmin;
    gap: 1.7vmin;
  }

  .box {
    height: 20vmin;
    width: 20vmin;
    font-size: 9vmin;
  }

  .btn {
    font-size: 4.5vmin;
    padding: 0.8rem 1.2rem;
  }

  #msg {
    width: 80vw;
    height: 70vh;
  }

  .msg-container p {
    font-size: 6vmin;
  }
}

@media (min-width: 481px) and (max-width: 900px) {
  .heading {
    font-size: 8vmin;
    margin-top: 5vh;
  }

  .players {
    width: 60vw;
    height: 65vh;
  }
  .players .name {
    font-size: 2.3rem;
  }

  .players input {
    width: 45vw;
    font-size: 1.4rem;
  }

  #turn-indicator {
    font-size: 1.4rem;
    bottom: 20px;
  }
  .game {
    height: 60vmin;
    width: 60vmin;
  }

  .box {
    height: 18vmin;
    width: 18vmin;
    font-size: 8vmin;
  }

  .btn {
    font-size: 3vmin;
  }

  #msg {
    width: 70vw;
    height: 70vh;
  }
}

@media (min-width: 901px) {
  .heading {
    font-size: 5rem;
  }

  .players {
    width: 35vw;
    height: 70vh;
  }

  .players input {
    width: 50vmin;
  }

  #turn-indicator {
    font-size: 1.3rem;
    bottom: 50px;
  }

  .game {
    width: 60vmin;
    height: 60vmin;
  }
}
