@import url('https://fonts.googleapis.com/css2?family=Roboto&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Oswald:wght@500&display=swap');

html {
    height: 100%;
}

body {
    background-image: url(images/world.png);
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
}

#questionText {
    text-align: center;
    font-size: 2vw;
    color: #ff7e07;
    font-family: 'Roboto', sans-serif;
    margin-top: 4vw;
}

.card-container:hover .card {
    transform: rotateY(180deg);
}

.container {
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-container {
    perspective: 1000px;
    display: flex;
}

.card {
    width: 11vw;
    height: 11vw;
    position: relative;
    transition: all 1s linear;
    transform-style: preserve-3d;
    margin: 0.5vw 0.5vw 0 0;
}

.front-face,
.back-face {
    height: 100%;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.8vw;
    font-family: 'Oswald', sans-serif;
    border-radius: 0.5vw;
    position: absolute;
    text-align: center;
}

.front-face {
    background-color: #f9efe5;
    z-index: 2;
    backface-visibility: hidden;
    color: #ff7e07;
}

.back-face {
    background-color: #ff7e07;
    z-index: 1;
    transform: rotateY(180deg);
    color: #f9efe5;
}

/* Media queries for screen compatibility*/

@media only screen and (min-width: 320px) and (max-width: 481px) {
    #questionText {
        font-size: 7vw;
        margin-top: 15vh;
    }

    .container {
        margin-top: 10vw;
    }

    .card {
        width: 27vw;
        height: 27vw;
    }

    .front-face,
    .back-face {
        font-size: 5vw;
        border-radius: 1.5vw;
    }
}

@media only screen and (min-width: 481px) and (max-width: 769px) and (orientation: landscape) {
    #questionText {
        font-size: 3vw;
        margin-top: 9vh;
    }

    .container {
        margin-top: 5vh;
    }

    .card {
        width: 12vw;
        height: 12vw;
    }

    .front-face,
    .back-face {
        font-size: 2.25vw;
        border-radius: 1vw;
    }
}

@media only screen and (min-width: 769px) and (max-width: 1025px) and (orientation: landscape) {
    #questionText {
        font-size: 3.5vw;
        margin-top: 7vh;
    }

    .container {
        margin-top: 5vh;
    }

    .card {
        width: 15vw;
        height: 15vw;
    }

    .front-face,
    .back-face {
        font-size: 2.5vw;
        border-radius: 1vw;
    }
}

@media only screen and (min-width: 481px) and (max-width: 1025px) and (orientation: portrait) {
    #questionText {
        font-size: 4.5vw;
        margin-top: 7vh;
    }

    .container {
        margin-top: 5vh;
    }

    .card {
        width: 25vw;
        height: 25vw;
    }

    .front-face,
    .back-face {
        font-size: 4vw;
        border-radius: 1.5vw;
    }
}