/*---root styles and font----*/
:root {
    --main-text: "Caveat Brush", cursive;
    --dark-color:rgb(4, 65, 65);
    --light-color:rgb(127, 255, 212);
    --opaque-color:rgba(127, 255, 212, 0.5);
}

* {
    padding: 0;
    margin: 0
;}

/* -------- styles for all pages----*/
body{
    color:var(--dark-color);
    font-family: var(--main-text);
}

a{
   color:var(--dark-color); 
   text-decoration: none;
   font-size: 38px;
}

a:hover{
    font-size: 48px;
    color: rgb(13, 121, 85);
    cursor: pointer;
}

li:hover{
    font-size: 48px;
    color: rgb(255, 170, 52);
    cursor: pointer;
}

/*------main background image of world flags -----*/
.hero{
    background-image: url("../images/hero-image.jpg");
    background-repeat: no-repeat;
    background-size: cover;
}

/* ----------- opaque color over background image-----*/
.opaque{
    background-color:var(--opaque-color);
    height: 100vh;
    position: inherit;
    z-index: 1;
}

/*---------- main playing box with image of map--------*/

.game-area{
    position:relative;
    background-image: url("../images/map-background.jpg");
    box-sizing: content-box;
    border-radius: 15px;
    left:20%;
    width:850px;
    top:3%;
}

/* ---------opaque color over play area image---------*/
.game-area-background{
    background-color:var(--opaque-color);
    position: relative;
    z-index: 1;
    box-sizing: content-box;
    height: 500px;
    border-radius: 15px;
}

/*-------- styling for all buttons ---------*/
button{
    background-color: var(--dark-color);
    color: rgb(153, 229, 243);
    height:50px;
    font-family: var(--main-text);
    text-transform: capitalize;
    font-size: 36px;
    outline:none;
}

/*----------------styles for home page --------------------------------*/
.start-hidden{
    display: none;
}

.play-buttons{
    padding:50px;
}

.nav-button{
    height:60px;
    width:680px;
    background-color: rgba(127, 255, 212, 0.3);
    border:outset 2px #000;
    box-shadow: 10px 10px 10px rgb(0 0 0 / 0.8);
    border-radius: 5px;
    margin:30px;
    cursor:pointer;
    text-align: center;
    font-size: 36px;
    padding-top: 15px;
}

.nav-button:hover{
    height:70px;
    width:700px;
}

#flip{
    margin-bottom: 0;
}

.instructions{
    width:650px;
    background-color: rgba(127, 255, 212, 0.3);
    border:outset 2px #000;
    box-shadow: 10px 10px 10px rgb(0 0 0 / 0.8);
    margin-left: 30px;
    margin-top: 0;
    padding-left: 15px;
    padding-right: 15px;
}

.instructions h2, h3, h4{
    text-align: center;
    padding-top: 20px;
    font-size: 32px;
}

.instructions p{
    font-size: 20px;
    text-align: justify;
}

/*-----styles for level-1 and level-2 pages -----------*/
.wrapper{
    display: flex;
    flex-direction: row;
    columns: auto;
    padding:  20px;
}

ul{
    background-color: rgba(127, 255, 212, 0.2);
    height: 100px;
    width: 700px;
    margin-left: 300px;
    border-radius: 20px;
}

li{
    position: relative;
    display: inline-block;
    font-size: 40px;
    text-transform: capitalize;
    margin-left: 50px;
    text-align: center;
    padding: 20px;

}

h1{
    font-size: 42px;
    font-weight: 300;
    text-align: center;
    padding: 15px;
}

.game-over{
    text-align: center;
    font-size: 38px;
    font-weight: 300;
}

.life-section{
    color:rgb(163, 5, 5);
    font-size:  32px;
    z-index: 2;
}

.life-section i{
    padding: 10px;
}

/*--------styles for level-1 page -----------*/
.game-area-level-1{
    width: 830px;
    height: 320px;
    top:0;
}

.game-area-background-level-1{
    height:320px;
}

#multiple-choice{
    text-align: center;
    font-family: var(--main-text);
    font-size: 32px;
    position: absolute;
    top: 120px;
    left:300px;
    z-index: 2;
}

.incorrect{
    background-color: rgba(0, 180, 235, 0.8);
    width:220px;
    margin:10px;
    cursor: pointer;
    border-radius: 5px;
}

#next{
    margin-top: 110px;
}

.game-over-done{
    background-color: rgba(30, 128, 0, 0.6);
}
.game-over-out{
    background-color: rgba(255, 40, 0, 0.6);
}

.game-over-done, .game-over-out{
    position: relative;
    right:180px;
    width:600px;
    font-weight: 300;
    border:outset 2px #000;
    box-shadow: 10px 10px 10px rgb(0 0 0 / 0.8);
    border-radius: 5px;
}

.score-section-level-1 h3{
    font-size: 32px;
    text-align: center;
    font-weight: 300;
    background-color:rgba(127, 255, 212, 0.4);
    border-radius: 15px;
    width:300px;
    margin-left: 50px;
    margin-top: 10px;
    padding:30px;
}

.lives-section-level-1{
    background-color: rgba(127, 255, 212, 0.4);
    padding: 10px;
    width:450px;
    text-align: center;
    border-radius: 15px;
    margin-top: -100px;
    margin-left: 750px;
    font-size: 28px;
}

/*--------styles for level-2 page -----------*/

.game-area-level-2{
    width: 830px;
    height: 35vh;
    max-height: 450px;
}

.game-area-background-level-2{
    width: 830px;
    height: 35vh;
    max-height: 450px;
}

input{
    height:50px;
    width: 250px;
    text-transform: capitalize;
    position: relative;
    font-family: var(--main-text);
    font-size: 36px;
    background-color:#7fffd4;
    border-radius: 5px;
    border: none;
    margin-left: 250px;
}

input:focus{
    outline: none;
}

.score-section-level-2 h3{
    font-size: 32px;
    bottom:50px;
    text-align: center;
    font-weight: 300;
    background-color: rgba(127, 255, 212, 0.4);
    border-radius: 15px;
    width:400px;
    margin-left: 120px;
    padding:30px;
}


.lives-section-level-2{
    background-color: rgba(127, 255, 212, 0.4);
    text-align: center;
    padding: 20px;
    position: relative;
    border-radius: 15px;
    margin-top: 50px;
    left: 440px;
    top: 80px;
    width:350px;
    font-size: 28px;
}

/*----------styles for javascript DOM elements----------*/
#correct-message-box, #incorrect-message-box{
    text-align: center;
    font-family:var(--main-text);
    font-weight: 300;
    font-size: 25px;
    padding:25px;
    position: relative;
    left:-300px;
    height: 30px;
    width:780px;
    border-radius: 10px;
    border:outset 2px #000;
    box-shadow: 10px 10px 10px rgb(0 0 0 / 0.8);
}

#correct-message-box-level-2, #incorrect-message-box-level-2{
    text-align: center;
    font-family:var(--main-text);
    font-weight: 300;
    font-size: 25px;
    padding:25px;
    position: relative;
    left:0px;
    height: 30px;
    width:780px;
    border-radius: 10px;
    border:outset 2px #000;
    box-shadow: 10px 10px 10px rgb(0 0 0 / 0.8);
}

@keyframes message-change {
    from{background-color: rgba(0, 128, 0, 0.7);}
    to {background-color: rgba(0, 250, 0, 0.7);}
}

#correct-message-box{
    animation-name: message-change;
    animation-duration: 5s;
    background-color: rgba(0, 250, 0, 0.7);
    color: rgba(0, 100, 0, 0.7);
}

#correct-message-box-level-2{
    animation-name: message-change;
    animation-duration: 5s;
    background-color: rgba(0, 250, 0, 0.7);
    color: rgba(0, 100, 0, 0.7);
}

@keyframes wrong-message-change {
    from{background-color: rgba(180, 180, 0, 0.7);}
    to {background-color: rgba(255, 0, 0, 0.7);}
}

#incorrect-message-box{
    animation-name: wrong-message-change;
    animation-duration: 5s;
    background-color: rgba(255, 0, 0, 0.7);
}

#incorrect-message-box-level-2{
    animation-name: wrong-message-change;
    animation-duration: 5s;
    background-color: rgba(255, 0, 0, 0.7);
}


@media screen and (max-width:943px) {

    /* -------- styles for all pages----*/
    .game-area{
        position:relative;
        background-image: url("../images/map-background.jpg");
        box-sizing: content-box;
        left: 55px;
        top: 200px;
        margin-left: 0px;
        margin-right: 0px;
        height: 700px;
        width: 700px;
        border-radius: 15px;
    }
    
    .game-area-background{
        background-color: rgba(127, 255, 212, 0.7);
        position: relative;
        z-index: 1;
        box-sizing: content-box;
        width: 700px;
        height: 700px;
    }
    
    button{
        height:50px;
        font-size: 32px;
        outline:none;
    }

    /*-----styles for home page -----------*/
    
    .play-buttons{
        padding:20px;
    }
    
    .nav-button{
        height:100px;
        width:550px;
        border:outset 2px #000;
        box-shadow: 10px 10px 10px rgb(0 0 0 / 0.8);
        border-radius: 5px;
        margin:50px;
        cursor:pointer;
    }

    .nav-button:hover{
        background-color: var(--opaque-color);
        width:550px;
    }

    .instructions{
        width:550px;
        margin-left: 50px;
    }

    /*--------styles for level 1 page----------*/
    ul{
        margin-left: 40px;
    }
    .game-area-level-1{
        width: 700px;
        height: 650px;
        border-radius: 15px;
        top:0;
    }
    
    .game-area-background-level-1{
        height:650px;
    }

    #multiple-choice{
        left:160px;
    }

    .game-over-done, .game-over-out{
        right:100px;
    }

    .incorrect{
        height:80px;
        width:350px;
        padding-top:40px;
        left:180px;
        border-radius: 15px;
        font-size: 36px;
    }

    #next {
        margin-top: 10px;
        left: 520px;
        position: relative;
        top: 550px;
    }

    .lives-section-level-1{
        position: relative;
        left:180px;
        top:30px;
        margin:0;
    }

    /*----------styles for level 2 page -------*/
    .game-area-level-2{
        width: 700px;
        height: 450px;
        border-radius: 15px;
        top:50px;
        position: relative;
    }
    
    .game-area-background-level-2{
        height:450px;
        position: relative;
        top:0px;
    }

    #play-area{
        width:500px;
    }

    button{
        width: 160px;
        height: 70px;
        position: relative;
        font-size: 22px;
        top: 60px;
        left: 280px;
    }

    input{
        width:500px;
        height:100px;
        margin-left: 100px;
    }

    #next{
        margin-left:0px;
    }

    .lives-section-level-2{
        left:200px;
        top:200px;
    }

    #correct-message-box, #correct-message-box-level-2{
        left:-50px;
        width: 450px;
        margin-left: 25px;
    }

    #incorrect-message-box, #incorrect-message-box-level-2{
        left:-50px;
        width:450px;
        height: 70px;
    }

    #incorrect-message-box-level-2, #correct-message-box-level-2{
        left:100px;
    }

    #next button{
        top:-500px;
        left:-250px;
    }
}

/*media query for mobile*/
@media screen and (max-width:600px){

    .game-area-index, .game-area-background-index{
        height:900px;
    }

    .nav-button{
        height:80px;
        width:300px;
        margin: 30px;
    }
    .nav-button:hover{
        background-color: var(--opaque-color);
        width:300px;
    }

    .instructions{
        width:300px;
    }

    /*----------- styles for level 1 page-----*/
    ul{
        height: 50px;
        padding-bottom:10px;
        font-size: 24px;
        margin-left: 0px;
    }

    li{
        margin:0px;
        width:70px;
        height:20px;
        font-size: 22px;
    }

    li a{
        margin:0px;
        width:70px;
        height:20px;
        font-size: 22px;
    }

    .game-area-level-1{
        background-image: url("../images/map-background.jpg");
        left: 15px;
        width: 200px;
        border-radius: 15px;
        width: 400px;
        height: 600px;
    }

    .game-area-background-level-1{
        width: 400px;
        height: 600px;
    }

    h1{
        font-size: 38px;
    }

    .incorrect-choice{
        position: absolute;
        top:250px;
    }

    .incorrect{
        background-color: rgba(0, 180, 235, 0.8);
        height:60px;
        width:300px;
        margin:10px;
        padding:0px;
        cursor: pointer;
        position: relative;
        left: 50px;
        border-radius: 5px;
    }
    button{
        width: 160px;
        height: 70px;
        position: relative;
        font-size: 22px;
        top: -200px;
        left: 120px;
    }

    .lives-section-level-1{
        width: 330px;
        left: 50px;
        top: 0px;
    }

    /*----------- styles for level 1 page-----*/
    .game-area-level-2{
        background-image: url("../images/map-background.jpg");
        left: 15px;
        width: 200px;
        border-radius: 15px;
        width: 400px;
        height: 400px;
    }

    .game-area-background-level-2{
        width: 400px;
        height: 400px;
    }

    #multiple-choice{
        left:0px;
    }

    #next{
        left: 120px;
        top: 350px;
    }

    /* ------ styles for level 2 ----*/

    input{
        width:330px;
        height:80px;
        margin-left: 30px;
    }

    #submit button{
        position: relative;
        top:50px;
    }

    .score-section-level-2 h3{
        margin-left: 0px;
        width:340px;
    }

    .lives-section-level-2{
        left:20px;
    }

    #correct-message-box, #incorrect-message-box{
        width: 300px;
        margin-left: 30px;
    }

    #next-level-2 button{
        top:-500px;
    }
}
/*media query for  small mobile*/
@media screen and (max-width:390px){
    .hero{
        width:102vw;
    }

    .game-area{
        background-image: url("../images/map-background.jpg");

    }

    .game-area-index{
        left: 25px;
        border-radius: 15px;
        width: 300px;
        height: 900px;
    }

    .game-area-background-index{
        width: 300px;
        height: 900px;
    }

    .nav-button{
        height:80px;
        width:300px;
        margin: 30px;
    }
    .nav-button:hover{
        background-color: var(--opaque-color);
        width:300px;
    }

    .instructions{
        width:300px;
    }

    /*----------- styles for level 1 page-----*/
    ul{
        height: 50px;
        padding-bottom:10px;
        font-size: 24px;
        margin-left: 0px;
    }

    li{
        margin:0px;
        width:70px;
        height:20px;
        font-size: 22px;
    }

    li a{
        margin:0px;
        width:70px;
        height:20px;
        font-size: 22px;
    }
   
    /*-----styles for level 1 page----*/
    .game-area-level-1{
        background-image: url("../images/map-background.jpg");
        left: 20px;
        border-radius: 15px;
        width: 350px;
        height: 500px;
    }

    .game-area-background-level-1{
        width: 350px;
        height: 500px;
    }

    h1{
        font-size: 28px;
    }

    .incorrect-choice{
        position: absolute;
        top:150px;
    }

    .incorrect{
        background-color: rgba(0, 180, 235, 0.8);
        height:60px;
        font-size: 28px;
        width:280px;
        margin:10px;
        padding:0px;
        cursor: pointer;
        position: relative;
        left: 30px;
        border-radius: 5px;
    }
    button{
        width: 160px;
        height: 70px;
        position: relative;
        font-size: 22px;
        top: -150px;
        left: 120px;
    }
    .score-section-level-1{
        position: relative;
        left:20px;
        width:300px;
    }

    .score-section-level-1 h3{
        margin-left: 0;
        width:280px;
    }

    .lives-section-level-1{
        width: 330px;
        left: 20px;
        top: 0px;
    }

    #multiple-choice{
        left:0px;
    }

    #next{
        left: 100px;
        top: 330px;
    }

    /*----------- styles for level 2 page-----*/
    .game-area-level-2{
        background-image: url("../images/map-background.jpg");
        left: 20px;
        width: 200px;
        border-radius: 15px;
        width: 350px;
        height: 350px;
    }

    .game-area-background-level-2{
        width: 350px;
        height: 350px;
    }

    input{
        width:280px;
        height:80px;
        margin-left: 20px;
    }

    #submit button{
        margin-right: 50px;
        right: 0px;
        left: 100px;
    }

    .score-section-level-2 h3{
        margin-left: 30px;
        width:240px;
    }

    .lives-section-level-2{
        left:50px;
        width: 240px;
        top:150px;
    }

    #correct-message-box, #incorrect-message-box{
        width: 300px;
        margin-left: 30px;
    }

    #next-level-2 button{
        top:-500px;
    }
}

