/* global css */

:root{
    --text: #0F0670;
    --buttonBg: #FE786D;
    font-size: 16px;
}

*{
    padding: 0;
    margin: 0;
    box-sizing: border-box;
    font-family: 'Montserrat', monospace;
}

html,body{
    height: 100vh;
    width: 100vw;
}

/* animation*/
@keyframes showResult{
    from{
        opacity: 0;
        color: #FE786D;
    }
    to{
        opacity: 1;
        color: var(--text)
    }
}

/* landing page css */

.container{
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-direction: column;
}

.container main{
    height: 100%;
    text-align: center;
    padding: 1rem;
    position: relative;

    display: flex;
    flex-direction: column;
    justify-content: space-evenly;
}

.container main h1{
    font-family: Lobster, sans-serif;
    font-size: 3.8rem;
    margin-top: 2rem;

    color: var(--text);
}

.container main p{
    font-size: 1.5rem;

    color: var(--text);
}

.container main img{
    width: max(40vw, 350px);
}

.container section{
    height: 80vh;
    width: 100%;
    box-sizing: border-box;
    padding: 1.5rem;
    display: flex;
    justify-content: center;
    flex-direction: column;
    
    background: #4F52FF;

    text-align: center;
}

.container section h2{
    font-size: 2rem;
    font-weight: 400;
    color: #fff;
    margin: 0 auto 20px auto;
}

.container section small{
    color: #fff;
}

.container section input{
    width: 80%;
    height: 2.2rem;
    display: block;
    border: 0;
    margin: 10px auto;
    border-radius: 30px;

    padding: 5px;
    color: #7d7d7d;
}

.container section input:focus, button:focus{
    outline: none;
}

.container section button{
    width: 80%;
    height: 2.5rem;
    display: block;
    margin: 10px auto;
    border: 0;
    border-radius: 30px;
    padding: 5px;

    color: #FFF;
    background: var(--buttonBg);

    font-size: 1.2rem;
    font-weight: 600;

    cursor: pointer;
}

/* modal css */

.modalClosed{
    display: none;
}

.modalOpen{
    position: fixed;
    top: 0;
    bottom: 0;
    right: 0;
    left: 0;
    z-index: 999;

    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;

    background: rgba(0,0,0,0.5);
}

.modalOpen .content{
    background: #fff;
    border-radius: 30px;
    padding: 2rem;
    position: relative;
}

.modalOpen .content strong{
    color: var(--text);
    position: absolute;
    top: 10px;
    right: 10px;

    cursor: pointer;
}

.modalOpen .content p{
    font-size: 1.5rem;
    margin: 10px; 
}

.modalOpen .content .result{
    background: url("/assets/winner.svg");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    height: 5rem;

    color: var(--text);
    font-size: 2rem;
    font-family: Lobster, sans-serif;

    animation-name: showResult;
    animation-duration: 3s;
}

.modalOpen .content button{
    width: 80%;
    height: 2.2rem;
    display: block;
    margin: 5px auto;
    border: 0;
    border-radius: 30px;
    padding: 5px;

    color: #FFF;
    background: var(--buttonBg);

    font-weight: 600;

    cursor: pointer;
}



@media(min-width: 1200px){
    :root{
        font-size: 18px;
    }

    .container{
        display: flex;
        align-items: center;
        justify-content: space-between;
        flex-direction: row;
    }

    .container section{
        background: #4F52FF;
        height: 70vh;
        width: 50vw;
        border-radius: 30px 0 0 30px;
    }

    .container section h2{
        max-width: 35vw;
    }

}

@media(min-width: 1500px){
    :root{
        font-size: 20px;
    }
}

@media(min-width: 1800px){
    :root{
        font-size: 22px;
    }
}