/*Basic Reset */

*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body{
    background: wheat ;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 1rem;
    font-family: sans-serif;
}


.container{
    background-color: white;
    border-radius: 1rem;
    box-shadow: 0 10ox 30ox rgba(0,0, 0, 0.1);
    width: 100%;
    max-width: 600px;
    overflow: hidden;
    position: relative; 
}

/* Screens */
.screen{
    display: none;
    padding: 2rem;
    text-align: center;
}

.screen.active{
    display: block;
}

/*Start Screen*/

#start-screen h1{
    color: #e86a33;
    margin-bottom: 20px;
    font-size: 2.5rem;
}

#start-screen p{
    color: #666;
    margin-bottom: 30px;
    font-size: 1.1rem;
}

/*Quiz Screen */
.quiz-header{
    margin-bottom: 2rem;
}

#question-text{
    color: #333;
    font-size: 1.5rem;
    margin-bottom: 1rem;
    line-height: 1.4;
}

.quiz-info{
    display: flex;
    justify-content: space-between;
    color: #666;
    margin-bottom: 10px;
}

.answers-container{
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 25px; 
}

.answer-btn{
    background-color: #f8f0e5;
    color: #333;
    border: 2px solid #eadbc8;
    border-radius: 10px; 
    padding: 1rem;
    cursor: pointer;
    text-align: left;
}

.answer-btn:hover{
    background-color: #eadbc8;
    border-color: #dac0ae;
}

.answer-btn.correct{
    background-color: #e6fff0;
    border-color: #a3f0c4;
    color: #28a745;
}

.answer-btn.incorrect{
    background-color: #feb5b5;
    border-color: #ff6961;
    color: red;
}

.progress-bar{
    height: 25px; 
    background-color: #f8f0e5;
    border-radius: 5px;
    overflow: hidden; 
    margin-top: 20px;
}

.progress{
    height: 100%; 
    background-color: #e86a33;
    width: 0%;
    transition: width 0.3s ease;
}

#confetti{
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    overflow: visible;
    z-index: 9999;
}

.confetti{
    position: absolute;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    opacity: 0;
    animation: confetti-fall 5s ease-out forwards;
}

/*Result Screen */

#result-screen h1{
    color: #e86a33; 
    margin-bottom: 30px;
}

.result-info{
    background-color: #f8f0e5;
    border-radius: 10px;
    padding: 20px; 
    margin-bottom: 30px;
}

.result-info p{
    font-size: 1.2rem;
    color: #333;
    margin-bottom: 1rem;
}

#result-message{
    font-size: 1.5rem;
    font-weight: 600; 
    color: #e86a33;
}

button{
    background-color: #e86a33;
    color: white;
    border: none;
    border-radius: 10px; 
    padding: 15px 30px; 
    font-size: 1.1rem;
    cursor: pointer;
}

button:hover{
    background-color: #d45b28;
}

@keyframes confetti-fall{
    0%{
        transform: translateY(-100px) rotate(0deg);
        opacity: 0;
    }
    10%{
        opacity: 1;
    }
    100% {
        transform: translateY(100vh) rotate(720deg);
        opacity: 0;
    }
}

/*Responsive Design */

@media (max-width: 500px){
    /* When we hit 500px and below implement the styles below */

    .screen{
        padding: 1rem;  
    }

    #start-screen h1{
        font-size: 2rem;
    }

    #question-text{
        font-size: 1.3rem;
    }

    answer-btn{
        padding: 12px;
    }

    button{
        padding: 12px 25px;
        font-size: 1rem;
    }
    
}

