@font-face {
    font-family: Scratch;
    src: url(./assets/img/Scratch.ttf);
}
*{
    box-sizing: border-box;
    margin: 0;
    user-select: none;
    font-family: 'Scratch';
    font-weight: 400;
}
h2{
  font-size: 45px;
    color: white;
    text-shadow: 5px 3px 3px rgba(0,0,0,0.75);
}
.hud{
    display: flex;
    background-color: none;
    /* justify-content: space-around; */
    position: absolute;
    width: 100%;

}
.hud div{
    display: flex;
    justify-content: center;
    align-items: center;
}
.score{
    position: absolute;
    left: 50px;
    top: 5px;
}
#timer{
    position: absolute;
    top: 5px;
    right: 50px;
}
#name{
    position: absolute;
    top: 5px;
    left: 50%;
    right: 50%;
}

body{
    overflow: hidden;
    background-color: black;
}
#overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('./assets/img/fond-terre.png') no-repeat center center fixed;
    background-size: cover;
    opacity: 0;
    transition: opacity 1s; 
    z-index: 9999; 
}
#gameplay {
   

}
#gameplay img{
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    transform: translate(-50%, -50%);
    opacity: 1; /* Opacité initiale */
    transition: opacity 0.5s ease; /* Transition pour le fondu */
}

#gameplay.hidden {
    opacity: 0; /* L'opacité devient 0 pour le fondu */
}