* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.game-board {
    width: 100%;
    height: 600px;
    border-bottom: 20px solid #257c1a;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
    background: linear-gradient(#b7e8fc, #E0F6FF);
}

.pipe {
    position: absolute;
    bottom: 0;
    width: 80px;
    right: -80px;
    animation: pipe-animation 1.5s infinite linear;
}

.mario {
    width: 150px;
    position: absolute;
    bottom: 0;
}

.jump {
    animation: jump 500ms ease-out;
}

.clouds {
    position: absolute;
    width: 550px;
    animation: clouds-animation 20s infinite linear;
}

.game-over-modal {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: rgb(255, 255, 255);
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    border: 3px solid #832626;
}

.modal-content h2 {
    color: #e22f2f;
    margin-bottom: 15px;
    font-size: 2em;
}

.modal-content button {
    background: #257c1a;
    color: white;
    border: none;
    padding: 15px 30px;
    font-size: 1.2em;
    border-radius: 5px;
    cursor: pointer;
    margin-top: 15px;
}

.modal-content button:hover {
    background: #1f6a15;
}

/* keyframe to put moviment, setting where is gonna start which is right 0 position and end at right 100% outside the game board */
@keyframes pipe-animation { 
    from {
        right: -80px;
    }

    to {
        right: 100%;
    }
}

/* keyframe to set the jumps... starting with 0% instead of using positions like the pipe-animation bc then we can set the position inside the percentage. if mario is in a position of 0% then his bottom will be 0 as well, 50% mario will be at the top, that's the jump, and 100% is the end of the animation which is bottom 0 again. the setting of 40% and 60% in between is just to create a delay during the jump with mario in the air */
@keyframes jump {
    0% {
        bottom: 0;
    }

    40% {
        bottom: 180px;
    }

    50% {
        bottom: 180px;
    }

    60% {
        bottom: 180px;
    }

    100% {
        bottom: 0;
    }
}

/* keyframe for the clouds */
@keyframes clouds-animation {
    from {
        right: -550px;
    }

    to {
        right: 100%;
    }
}