
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: linear-gradient(135deg, #ffe78f, #90f7b3, #ffffff);
    background-size: 300% 300%;
    animation: gradientAnimation 12s ease infinite;

    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;

    font-family: "Poppins", sans-serif;
}

/* Fade-in animation */
@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.96); }
    to   { opacity: 1; transform: scale(1); }
}

/* Background animation */
@keyframes gradientAnimation {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Hidden class (JS toggles) */
.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: scale(0.95);
    transition: 0.35s ease;
}

/* ===================================================================
   LEVEL SELECTION SCREEN
=================================================================== */

.board {
    width: 100%;
    min-height: 100vh;

    display: flex;
    justify-content: center;
    align-items: center;

    position: absolute;
    top: 0;
    left: 0;
}

.container {
    background: rgba(255, 255, 255, 0.25);
    padding: 45px;
    width: 420px;

    border-radius: 22px;
    backdrop-filter: blur(14px);
    border: 2px solid rgba(255, 255, 255, 0.35);

    text-align: center;
    animation: fadeIn 0.5s ease;

    box-shadow: 0px 10px 32px rgba(0,0,0,0.25);
}

.container h1 {
    font-size: 30px;
    font-weight: 800;
    margin-bottom: 35px;
    color: #000000;
    text-shadow: 1px 1px 4px rgba(0,0,0,0.25);
}

.dificulty-levels {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.inputs label {
    display: flex;
    align-items: center;
    gap: 14px;

    background: rgba(255, 255, 255, 0.35);
    padding: 18px 22px;
    border-radius: 14px;
    cursor: pointer;

    border: 2px solid transparent;
    transition: 0.25s ease;

    font-size: 20px;
    font-weight: 600;
}

.inputs label:hover {
    background: rgba(255, 255, 255, 0.55);
    transform: translateY(-3px);
    box-shadow: 0px 4px 16px rgba(0,0,0,0.2);
}

.inputs input[type="radio"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

#start {
    margin-top: 40px;
    width: 100%;
    padding: 16px 0;

    font-size: 18px;
    font-weight: 700;

    color: white;
    background: #0072ff;

    border: none;
    border-radius: 14px;

    cursor: pointer;
    transition: 0.25s ease;
    box-shadow: 0px 5px 18px rgba(0,0,0,0.25);
}

#start:hover {
    background: #0057d8;
    transform: translateY(-3px);
}

#start:active {
    transform: scale(0.96);
}


/* ===================================================================
   QUIZ SCREEN
=================================================================== */

.wrapper {
    width: 100%;
    min-height: 100vh;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;

    position: absolute;
    top: 0;
    left: 0;

    transition: 0.4s ease;
}

.quiz {
    width: 550px;

    background: rgba(255, 255, 255, 0.22);
    padding: 50px;

    border-radius: 24px;
    backdrop-filter: blur(18px);

    border: 2px solid rgba(255,255,255,0.45);
    box-shadow: 0px 8px 32px rgba(0,0,0,0.25);
    animation: fadeIn 0.45s ease-out;
    visibility: hidden;
    position: absolute;
}

.quiz.show{
    width: 550px;

    background: rgba(255, 255, 255, 0.22);
    padding: 50px;

    border-radius: 24px;
    backdrop-filter: blur(18px);

    border: 2px solid rgba(255,255,255,0.45);
    box-shadow: 0px 8px 32px rgba(0,0,0,0.25);
    animation: fadeIn 0.45s ease-out;
visibility: visible;
}

.question {
    font-size: 28px;
    font-weight: 800;
    color: #000;
    text-align: center;

    margin-bottom: 35px;
    text-shadow: 1px 1px 4px rgba(0,0,0,0.3);
}

.answers {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.answer {
    background: rgba(255, 255, 255, 0.35);
    padding: 18px 22px;

    font-size: 20px;
    font-weight: 600;

    border-radius: 14px;

    cursor: pointer;
    transition: 0.3s ease-in-out;

    border: 2px solid transparent;
    text-align: center;
}

/* Hover Glow */
.answer:hover {
    background: rgba(255, 255, 255, 0.55);
    transform: translateY(-3px) scale(1.02);

    box-shadow: 0px 0px 18px 5px rgba(255, 215, 0, 0.65),
                0px 0px 30px rgba(255, 215, 0, 0.45);
}

/* Correct Answer */
.correct {
    background: rgba(0, 160, 55, 0.9) !important;
    color: white !important;

    border-color: white;
    box-shadow: 0px 0px 18px rgba(0,255,0,0.85);
}

/* Wrong Answer */
.wrong {
    background: rgba(200, 0, 0, 0.9) !important;
    color: white !important;

    border-color: white;
    box-shadow: 0px 0px 18px rgba(255,0,0,0.85);
}

/* Disable clicks after answering */
.disabled {
    pointer-events: none;
    opacity: 0.6;
}


/* ===================================================================
   FINAL RESULT SCREEN
=================================================================== */

.finalBoard {
    width: 550px;

    background: rgba(255, 255, 255, 0.25);
    padding: 50px;

    border-radius: 26px;
    backdrop-filter: blur(14px);

    border: 2px solid rgba(255, 255, 255, 0.35);
    box-shadow: 0px 6px 35px rgba(0,0,0,0.25);

    text-align: center;
    animation: fadeIn 0.4s ease;

    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.finalBoard h1 {
    font-size: 34px;
    color: #000;
    font-weight: 900;

    margin-bottom: 25px;
    text-shadow: 1px 1px 4px rgba(0,0,0,0.3);
}

.scores {
    display: inline-block;
    font-size: 36px;
    color: #ffd700;

    font-weight: 900;
    margin-left: 8px;

    text-shadow: 0px 0px 12px rgba(255,215,0,0.8);
}

/* Restart Button */
#restart {
    padding: 16px 32px;
    font-size: 20px;
    font-weight: 700;

    color: white;
    background: rgba(0, 110, 255, 0.85);
    border: none;

    border-radius: 16px;
    cursor: pointer;

    transition: 0.3s ease-in-out;
}

#restart:hover {
    background: rgba(0, 110, 255, 1);
    transform: translateY(-3px) scale(1.04);

    box-shadow: 0px 0px 16px 4px rgba(255, 215, 0, 0.65),
                0px 0px 28px rgba(255, 215, 0, 0.45);
}
