* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;     /* get rid of the margins around the page to make it looks nicer*/
}

section {
    height: 100vh;              /*set the height of our display*/
    background-color: rgba(58, 0, 52, 0.53);   /*change the background color to purple-blue*/
    font-family: sans-serif;    /*change the font*/
}

.score{
    color: rgb(236, 236, 236);  /*change the color of the score font*/
    height: 20vh;
    display: flex;
    justify-content: space-around;  /*make sure the score board goes horizontally*/
    align-items: center;   /*keep the score in the center of the screen*/
}

.score h2{
    font-size: 30px;  /*bigger the font size*/
}

.score p {
    text-align: center;
    padding: 10px;
    font-size: 25px;
}

.intro {
    color: rgb(224, 224, 224);
    height: 50vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-around;
    transition: opacity 0.5s ease;  /*make the hands stop to show the result*/
}

.intro h1{
    font-size: 50px;   /*change the font of the big title*/
}

.intro button,
.match button {  /*match the two hands so they share same coding which I wrote*/
    width: 100px;
    height: 45px;
    background: none;    /*design the "let's play" button*/
    border: none;
    color: rgb(224, 224, 224);
    font-size: 20px ;
    background: rgba(57, 78, 117, 0.69);
    border-radius: 3px;
    cursor: pointer;
}

.match{
    position: absolute;    /*during the actual match, center the two hands in the middle of the screen*/
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);   /*move the hands up to the intro area*/
    transition: opacity 0.5s ease 0.5s;  /*make the hands stop to show the result*/
}

.winner{
    color: rgb(224, 224, 224);   /*design the "Choose an option" line*/
    text-align: center;
    font-size: 50px;
}

.hands,
.options {
    display: flex;    /*change the hands to horizontal position*/
    justify-content: space-around;
    align-items: center;  /*put the hands in the center of the screen*/
}

.player-hand{
    transform: rotateY(180deg); /*rotate the hand so they are facing each other like what actual players will do*/
}

div.fadeOut{       /*fade the intro part out*/
    opacity: 0;
    pointer-events: none;  /*can't click on the pointer any more*/
}

div.fadeIn{         /*fade the intro part in*/
    opacity: 1;
    pointer-events: all;   /*make it doable to click the pointer*/
}

@keyframes shakePlayer{    /*create animation: moving the hand up and down during the match*/
    0%{
        transform: rotateY(180deg) translateY(0px);   /*keep the rotation on the left hand*/
    }
    15%{
        transform: rotateY(180deg) translateY(-50px);
    }
    25%{
        transform: rotateY(180deg) translateY(0px);
    }
    35%{
        transform: rotateY(180deg) translateY(-50px);
    }
    50%{
        transform: rotateY(180deg) translateY(0px);
    }
    65%{
        transform: rotateY(180deg) translateY(-50px);
    }
    75%{
        transform: rotateY(180deg) translateY(0px);
    }
    85%{
        transform: rotateY(180deg) translateY(-50px);
    }
    100%{
        transform: rotateY(180deg) translateY(0px);
    }
}

@keyframes shakeComputer { /*create animation: moving the hand up and down during the match*/
    0% {
        transform: translateY(0px); /*don't do the rotation on the right hand since it's not rotated originally*/
    }
    15% {
        transform: translateY(-50px);
    }
    25% {
        transform: translateY(0px);
    }
    35% {
        transform: translateY(-50px);
    }
    50% {
        transform: translateY(0px);
    }
    65% {
        transform: translateY(-50px);
    }
    75% {
        transform: translateY(0px);
    }
    85% {
        transform: translateY(-50px);
    }
    100% {
        transform: translateY(0px);
    }
}
