* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ALL */

body {
    font-family: "Schoolbell", system-ui;
    font-weight: 400;
    font-style: normal;
    background-color: #7BB55A;
    background-image: url(../img/background.png);
    background-blend-mode: normal;
    background-size: contain;
}

/* NAV */

nav {
    text-align: center;
}

nav>ul {
    list-style-type: none;
    display: flex;
    justify-content: space-between;
    padding: 1.5%;
    background-color: #6ba549;
    opacity: 90%;
}

a {
    color: #ffffff;
    text-decoration: none;
    font-family: "Schoolbell", sans-serif;
    font-weight: 400;
    font-style: normal;
    font-size: 3vmin;
}

a:hover {
    text-decoration: underline;
    font-style: italic;
}

/* HEADER + MAIN */

h1 {
    font-family: "Schoolbell", system-ui;
    font-weight: 400;
    font-style: normal;
    text-align: center;
    font-size: 10vmin;
    margin: 5vmin 10vmin 0;
    color: #ffffff;
    background-color: #7BB55A;
}

p {
    text-align: center;
    padding: 5vmin;
}

header {
    display: block;
}

#message {
    text-align: center;
    /* font-size: 30px;
    margin-bottom: 20px; */
    padding: 0;
}

#message img {
    max-width: 15vmin;
}

.case {
    background-size: contain;
    background-repeat: no-repeat;
}

#grille {
    width: 60vmin;
    height: 60vmin;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    margin: auto;
    border: solid #A50505 1vmin;
}

#grille .case {
    border: solid #A50505 1vmin;
    /* border-radius: 5px; */
    display: grid;
    place-items: center;
}

#red {
    background-color: #E55050;
    background-origin: content-box;
    padding: 1vmin;
}

#red:hover {
    background-color: #be3535;
}

#white {
    background-color: #f9f9f9;
    background-origin: content-box;
    padding: 1vmin;
}

#white:hover {
    background-color: #dbdfe3;
}

button {
    font-family: "Schoolbell", cursive;
    font-weight: 400;
    font-style: normal;
    padding: 2vmin;
    margin: 3vmin;
    border-radius: 80px;
    font-size: 3.5vmin;
    background-color: #E1C49B;
    color: #8e7656;
    border-color: #AF9168;
    border-style: dashed;
    border-width: 0.7vmin;
    box-shadow: #4b3e2c 4px 4px 6px;
}

button:hover {
    background-color: #fce0b8;
}

/* WINNER/TIE PAGE */

#winnerS,
#winnerA,
#tie {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(11, 40, 10, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.6s ease;
    z-index: 1000;
}

#winnerS.active,
#winnerA.active,
#tie.active {
    opacity: 1;
    pointer-events: auto;
}

.win {
    display: flex;
    flex-direction: column;
    align-items: center;
}

img#win {
    width: 35vmin;
    position: absolute;
    bottom: 16vmin;
    right: 12vmin;
}

img#tied {
    width: 70vmin;
    position: absolute;
    bottom: 23vmin;
    right: 0vmin;
}

img.star {
    width: 65vmin;
    animation: spin 5s ease;
    z-index: -10;
    position: relative;
}

figure {
    position: relative;
    display: inline;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}