@import url('https://fonts.googleapis.com/css2?family=Lato:ital,wght@0,100;0,300;0,400;0,700;0,900;1,100;1,300;1,400;1,700;1,900&family=Luckiest+Guy&display=swap');

body {
    font-family: "Luckiest Guy", cursive;
    font-size: 1em;
}

.player, .totalScore, .text-current, .currentScore, .rolldice, .hold {
    text-align: center; 
    color: #333333;
}

.player, .totalScore, .rolldice-btn, .newgame, .rolldice, .hold {
    text-shadow: 2px 2px 6px rgba(255, 255, 255, 0.8);
}

.inline, .newgame, .btn, .rolldice, .hold {
    display: inline-block;
}

.img, .current {
    height: 100%;
    width: 100%;
}

.img {
    background: #ffffff90;
    border-radius: 22px;
}

.dice {
    margin-top: 10%;
    height: 75px;
    width: 100px;
}

.butn {
  padding: 20px 40px;
  font-weight: bold;
  text-transform: uppercase;
  border: 2px solid rgba(255, 255, 255, 0.8);
  border-radius: 50px;
  color: #FFFFFF;
  background: linear-gradient(135deg, #FACC15, #8B5CF6) !important;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
}

.butn:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4);
}

.new-game-btn {
  font-size: 24px;
}

#rollDiceBtn {
    margin-bottom: 20px;;
}

#sound-icon {
    cursor: pointer;
    position: fixed;
    top : 15px;
    left: 15px;
    background-color: #D72638;
    border-color: #D72638;
}

.new-game-btn {
    margin-top: 20px;
    margin-bottom : 30px;
}

.current-bloc {
    border: 3px solid white;
    box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.2);
}

.current {
    max-height: 100px;
    margin-top: 30%;

}

.current1 {
    background: #333333;
}

.current2 {
    background: #333333;
}

.player {
    font-size: 1.5em;
    font-weight: 600;
}

.bi-dot {
    height: 8vw;
    width: 8vw;
    color: #D72638;
}

.totalScore {
    font-size: 1.2em;
    color: #D72638;
}

.newgame {
    margin-top : 15%;
    margin-bottom: 15%;
    font-size: 1.2em;
    font-weight: 700;
    color: #333333;
}

.players {
    margin-bottom: 10%;
}

.currentScore {
    color: white;
    font-size: 3em;
}
  
.text-current {
    color: white;
    font-size: 20px;
}

.totalScore {
    font-size: 3em;
}


/* Pop-up winner et règles du jeu*/
.modal-win, .modal-rules {
    display: none;
}

.modal-back {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba( 0, 0, 0, .25 )
}

.modal-container {
    position: fixed;
    top: 50%;
    left: 50%;
    padding: 25px;
    background: white;
    transform: translate(-50%, -50%);
    border-radius: 50px;
    box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.4);
}

.modalText, .rules-title {
    text-align: center;
    padding-left: 3vw;
    padding-right: 3vw;
}

.modalText {
    font-size: 0.4em;
    font-family: "Lato", sans-serif;
}

.rules-title {
    color: #D72638;
    padding-bottom: 1vw;
    font-weight: bold;
}

#modal-close {
    padding: 10vw;
}


#btn-rules {
    position: fixed;
    top : 15px;
    right: 15px;
    background-color: #D72638;
    border-color: #D72638;
}

.bi-controller, .bi-volume-up-fill, .bi-volume-mute-fill {
    width : 4vw;
    height: 4vw;
}

#modal-close2, #modal-close1 {
    border: 1px solid #333333;
    border-radius: 10px;
    background: #333333;
    color: white;
    font-weight: bold;
    margin-left: 19vw;
    margin-top: 2vw;
    padding: 0.5vw 1vw;
    text-decoration: none;
    font-family: "Lato", sans-serif;
}

#modal-close2:hover, #modal-close1:hover {
    background: #606060;
    border: 1px solid #333333;
}

/* Animation du dé */
.anim {
    animation: shake 0.6s cubic-bezier(.36,.07,.19,.97) both;
    transform: translate3d(0, 0, 0);
    backface-visibility: hidden;
    perspective: 1000px;
  }

@keyframes shake {
    0%{
        transform: rotate(8deg);
    }
    30%{
        transform: rotate(-8deg);
    }
    60%{
        transform: rotate(8deg);
    }
    100%{
        transform: rotate(0deg);
    }
}

.anim2 {
    animation: shake2 0.6s cubic-bezier(.36,.07,.19,.97) both;
    transform: translate3d(0, 0, 0);
    backface-visibility: hidden;
    perspective: 1000px;  
}

@keyframes shake2 {
    10%, 90% {
      transform: translate3d(-1px, 0, 0);
    } 
    20%, 80% {
      transform: translate3d(2px, 0, 0);
    }
    30%, 50%, 70% {
      transform: translate3d(-4px, 0, 0);
    }
    40%, 60% {
      transform: translate3d(4px, 0, 0);
    }
  }

  

/* Appareils petits (460px et plus) */
@media (min-width: 460px) {
    .newgame {
        margin-bottom: 15%;
    }

    .players {
        margin-bottom: 20%;
    }

    .current {
        margin-top: 0%;
    }

    .modalText {
        font-size: 0.6em;
    }
}

/* Appareils moyens (tablettes, 768px et plus)*/
@media (min-width: 768px) { 
    .newgame {
        margin-top: 5%;
    }
    
    .dice {
        height: 125px;
        width: 175px;
    }
    
    
    .player {
        font-size: 2.3em;
    }
    
    .totalScore {
        font-size: 3em;
    }
    
    .current-bloc {
        max-width: 200px;
    }
    
    .current1 {
        margin-left: 8%;
    }
    
    .current2 {
        margin-right: 8%;
    }
    
    .text-button {
        font-size: 1.2em;
    }
    
    .currentScore {
        font-size: 4em;
    }
    
    .players, .newgame {
        margin-bottom: 10%;
    }

    .modalText {
        font-size: 0.8em;
    }
 }

/* Grands appareils (ordinateurs de bureau, 992px et plus)*/
@media (min-width: 992px) {
    .newgame {
        margin-top: 2%;
    }

    .dice {
        height: 150px;
        width: 200px;
        margin-top: 5%;
    }
    
    .player {
        font-size: 3em;
    }
    
    .totalScore {
        font-size: 5em;
    }
    
    .current-bloc {
        max-width: 200px;
    }
    
    .current {
        margin-top: 10%;
    }

    .current1 {
        margin-left: 12%;
    }
    
    .current2 {
        margin-right: 12%;
    }
    
    .text-button {
        font-size: 1.5em;
    }
    
    .currentScore {
        font-size: 4em;
    }
    
    .players, .newgame {
        margin-bottom: 4%;
    }

    .modalText {
        font-size: 1em;
    }
 }

 #rotate-warning {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 9999;
    width: 100vw;
    height: 100vh;
    background: #000000dd;
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    font-size: 5rem;
}
