
/* =========================
   RESET BASE
========================= */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* =========================
   BODY
========================= */
body {
    background: linear-gradient(135deg, #e6e9f0, #eef1f5);
    font-family: 'Roboto', sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    color: #333;
}

/* =========================
   NAVBAR
========================= */
nav {
    width: 100%;
    max-width: 900px;
    margin-bottom: 20px;
}

nav ul {
    display: flex;
    justify-content: center;
    list-style: none;
}

nav ul li a {
    text-decoration: none;
    color: #fff;
    font-weight: 600;
    padding: 10px 20px;
    background: #1f2937;
    border-radius: 6px;
    transition: all 0.3s ease;
}

nav ul li a:hover {
    background: #374151;
    transform: translateY(-2px);
}

/* =========================
   CARD PRINCIPALE
========================= */
.content {
    width: 100%;
    max-width: 750px;
    background: #ffffff;
    padding: 35px;
    border-radius: 12px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
}

h1 {
    text-align: center;
    margin-bottom: 30px;
    font-weight: 700;
    color: #111827;
}

/* =========================
   DOMANDE
========================= */
.domanda {
    margin-bottom: 25px;
    text-align: left;
}

.titolo {
    display: block;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 10px;
    color: #1e3a8a;
}

.risposta label {
    display: block;
    margin-bottom: 8px;
    cursor: pointer;
    padding: 6px 8px;
    border-radius: 6px;
    transition: background 0.2s;
}

.risposta label:hover {
    background-color: #f3f4f6;
}

input[type="radio"] {
    margin-right: 8px;
}

/* =========================
   BOTTONE
========================= */
button {
    width: 100%;
    margin-top: 15px;
    padding: 12px;
    background-color: #2563eb;
    border: none;
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

button:hover {
    background-color: #1e40af;
    transform: translateY(-2px);
}

/* =========================
   RISULTATO
========================= */
#result {
    margin-top: 20px;
    padding: 15px;
    border-radius: 8px;
    text-align: center;
    font-weight: bold;
    display: hidden;
}



.alert {
    background-color: #fee2e2;
    color: #b91c1c;
    border: 1px solid #fca5a5;
     display: block ;
}

.success {
    background-color: #dcfce7;
    color: #166534;
    border: 1px solid #86efac;
     display: block ;
}

/* =========================
   FOOTER
========================= */
footer {
    margin-top: 40px;
    font-size: 14px;
    color: #6b7280;
    text-align: center;
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 768px) {
    .content {
        padding: 25px;
    }

    h1 {
        font-size: 22px;
    }
}

@media (max-width: 480px) {
    body {
        padding: 10px;
    }

    .content {
        padding: 20px;
    }

    button {
        font-size: 14px;
    }
}
