@import url('https://fonts.googleapis.com/css2?family=Nunito&display=swap');

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 62.5%;
}

body {
  font-family: 'Nunito', sans-serif;
  font-weight: 400;
  color: #333;
  background-image: linear-gradient(to top left, #cbbf6a 0%, #bf472e 100%);
  height: 100vh;
  position: relative;
}

/* === LAYOUT === */
main {
  display: flex;
  height: 80vh;
  width: 70rem;
  background-color: rgba(255, 255, 255, 0.35);
  backdrop-filter: blur(200px);
  filter: blur();
  box-shadow: 0 3rem 5rem rgba(0, 0, 0, 0.25);
  border-radius: 9px;
  overflow: inherit;
  margin: 10vh auto;
}

/*=== GUIDE GAME ===*/
.close-modal {
  position: absolute;
  top: 1.2rem;
  right: 2rem;
  font-size: 5rem;
  color: #333;
  cursor: pointer;
  border: none;
  background: none;
}

h1 {
  font-size: 2.5rem;
  margin-bottom: 2rem;
}

p {
  font-size: 1.8rem;
}
h2 {
  margin-top: 2rem;
}
li {
  font-size: 1.6rem;
}

/* -------------------------- */
/* CLASSES TO MAKE MODAL WORK */

.modal {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 70vw;
  height: 50vh;
  overflow: scroll;
  background-color: white;
  padding: 3rem;
  border-radius: 5px;
  box-shadow: 0 3rem 5rem rgba(0, 0, 0, 0.3);
  z-index: 10;
}

.overlay {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(3px);
  z-index: 5;
}

/*=== END OF GUIDE ===*/
.player {
  flex: 50%;
  padding: 5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: all 0.75s;
}
.rootReactVNB {
  width: 0vw;
  position: fixed;
  z-index: 2000000000;
  display: flex;
  flex-direction: column;
  min-height: 0;
  top: 0px;
  left: 0px;
}
/* === ELEMENTS === */
.name {
  position: relative;
  font-size: 2rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  word-spacing: 2px;
  font-weight: 300;
  margin-bottom: 1rem;
}

.score {
  font-size: 3.5rem;
  font-weight: 300;
  color: #d54b19;
  margin-bottom: auto;
}

.player--active {
  background-color: rgba(255, 255, 255, 0.4);
}
.player--active .name {
  font-weight: 700;
}
.player--active .score {
  font-weight: 400;
}

.player--active .current {
  opacity: 1;
}

.current {
  background-color: #d54b19;
  opacity: 0.8;
  border-radius: 9px;
  color: #fff;
  width: 65%;
  padding: 1.2rem;
  text-align: center;
  transition: all 0.75s;
}

.current-label {
  text-transform: uppercase;
  margin-bottom: 0.5rem;
  font-size: 1.3rem;
  color: #f9cbb1;
}
.current-score {
  font-size: 2.5rem;
}

/* === ABSOLUTE POSITIONED ELEMENTS === */
.btn {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  color: #444;
  background: none;
  border: none;
  font-family: inherit;
  font-size: 1.5rem;
  text-transform: uppercase;
  cursor: pointer;
  font-weight: 400;
  transition: all 0.2s;

  background-color: white;
  background-color: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(10px);

  padding: 0.7rem 2.5rem;
  border-radius: 50rem;
  box-shadow: 0 1.75rem 3.5rem rgba(0, 0, 0, 0.1);
}

.btn--new {
  top: 4rem;
}
.btn--roll {
  top: 24rem;
}
.btn--hold {
  top: 30rem;
}
.btn:active {
  transform: translate(-50%, 3px);
  box-shadow: 0 1rem 2rem rgba(0, 0, 0, 0.15);
}
.btn:focus {
  outline: none;
}

.dice {
  position: absolute;
  left: 50%;
  top: 14rem;
  transform: translateX(-50%);
  height: 7rem;
  box-shadow: 0 2rem 5rem rgba(0, 0, 0, 0.2);
}

.player--winner {
  background-color: #3b3b3b;
}
.trophy {
  position: absolute;
  height: 10rem;
  width: auto;
}
.trophy_0 {
  right: 68%;
  top: 14rem;
}
.trophy_1 {
  left: 68%;
  top: 14rem;
}
.player--winner .name {
  font-weight: 700;
  color: #d54b19;
}
.btn--guide {
  position: fixed;
  top: 80%;
}

.hidden {
  display: none;
}

@media only screen and (max-width: 900px) {
  body {
    position: inherit;
    background-repeat: no-repeat;
    height: 100vh;
  }
  main {
    flex-direction: column-reverse;
    overflow: unset;
    height: 70%;
    width: 70%;
    margin: 35% auto;
  }
  .btn {
    position: fixed;
    left: 50%;
  }
  .btn--new {
    top: -8%;
    left: 50%;
  }
  .btn--guide {
    top: -15%;
    left: 50%;
  }
  .btn--roll {
    top: 105%;
    left: 50%;
  }
  .btn--hold {
    top: 112%;
    left: 50%;
  }
  .dice {
    top: 48%;
  }
  .player {
    padding: 12%;
  }
  .name {
    margin-top: 4rem;
  }
}

@media only screen and (max-width: 600px) {
  main {
    height: 70%;
    width: 80%;
    margin: 60% auto;
  }
  .dice {
    height: 5rem;
    top: 48%;
  }
  .player {
    padding: 3%;
  }
  .score {
    font-size: 3.5rem;
    margin-bottom: 3%;
  }
  .name {
    margin-top: 4rem;
  }
  .current {
    width: 35%;
    padding: 1%;
  }
  .btn--new {
    top: -5%;
    left: 50%;
  }
  .btn--guide {
    top: -12%;
    left: 50%;
  }
  .btn--roll {
    top: 105%;
    left: 50%;
  }
  .btn--hold {
    top: 110%;
    left: 50%;
  }
}
@media only screen and (max-width: 400px) {
  body {
    position: inherit;
    background-repeat: no-repeat;
    height: 100vh;
  }
  main {
    height: 70%;
    width: 80%;
    margin: 70% auto;
  }
  .btn--new {
    top: -5%;
    left: 50%;
  }
  .btn--guide {
    top: -10%;
    left: 50%;
  }
  .btn--roll {
    top: 105%;
    left: 50%;
  }
  .btn--hold {
    top: 110%;
    left: 50%;
  }
  .dice {
    height: 5rem;
  }
}
