* {
    cursor: url("img/rouge bleu.png"), auto;
}

body {
    background: red;
    margin: 0;
    font-family: Arial, sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
}

#game {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin: 0 auto;
    padding-left: 100px;
    
}

.card {
    width: 120px;
    height: 160px; 
    background: #c6f8ff;
    border-radius: 20px;
    position: relative;
    transform-style: preserve-3d;
    transition: transform .5s;
    transition:all ease .2s;
    
}

.card.flipped {
    transform: rotateY(180deg);
}

.front, .back {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 20px;
    backface-visibility: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: bold;
    font-size: 22px;
}


.front {
    background-size: cover;
    background-position: center;
    /* Ne pas mettre de background blanc ni de transform ici */
}

.back {
    font-family: Impact, 'Arial Narrow Bold', sans-serif;
   /*  transform: rotate(270deg); */
    color: red;
    font-size: 20px;
    writing-mode: vertical-rl;
text-orientation:sideways-right;
  /*   width: 40%;
    height: 140%; */
}

.card.flipped .back {
    visibility: hidden;
}


/* La rotation doit être appliquée uniquement quand la carte est retournée */
.card .front {
    /* rien ici, voir ci-dessus */
}
.card.flipped .front {
    transform: rotateY(180deg);
}

/* Popup BRAVO */
#popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.85);
    display: flex;
    justify-content: center;
    align-items: center;
    visibility: hidden;
}

#popup.show {
    visibility: visible;
}

.popup-box {
    background: red;
    padding: 60px;
    text-align: center;
    border-radius: 80px;
    max-width: 800px;
}

.popup-title {
    font-family: Impact, Haettenschweiler, 'Arial Narrow Bold', sans-serif;
    font-size: 130px;
    color: #c6f8ff;
}

.btn {
    background: #c6f8ff;
    color: red;
    border: none;
    padding: 18px 40px;
    margin-top: 25px;
    border-radius: 40px;
    font-size: 22px;
    font-family: "paysage";
    font-weight: 900;
    font-style: normal;
    
}