/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Lato:wght@400;700&display=swap');

/* Variabili CSS */
:root {
    --primary-blue: #2563EB;
    --accent-orange: #F97316;
    --success-green: #10B981;
    --warning-yellow: #F59E0B;
    --danger-red: #EF4444;
    --light-gray: #F3F4F6;
    --medium-gray: #D1D5DB;
    --dark-gray: #4B5563;
    --text-color: #1F2937;
    --white: #FFFFFF;
    --whatsapp-green: #25D366;
    --font-family: 'Lato', sans-serif;
    --border-radius: 8px;
    --box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --box-shadow-strong: 0 8px 25px rgba(0, 0, 0, 0.15);
}


/*
body {
    font-family: var(--font-family);
    background: linear-gradient(135deg, var(--light-gray) 0%, #E5E7EB 100%);
    color: var(--text-color);
    margin: 0;
    padding: 20px;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: 100vh;
}
*/

.wizard-container {
    background-color: var(--white);
    padding: 30px 40px;
    border-radius: 12px;
    box-shadow: var(--box-shadow-strong);
    max-width: 800px;
    /*width: 100%;*/
    margin: 20px auto;
}

.wizard-header {
    text-align: center;
    margin-bottom: 30px;
    border-bottom: 2px solid var(--light-gray);
    padding-bottom: 25px;
}

.wizard-header h1 {
    color: var(--primary-blue);
    margin-bottom: 5px;
    font-weight: 700;
    font-size: 2.2em;
}

.wizard-header h2 {
    color: var(--accent-orange);
    margin-bottom: 15px;
    font-weight: 600;
    font-size: 1.3em;
}

.wizard-header p {
    color: var(--dark-gray);
    font-size: 1.1em;
    line-height: 1.5;
}

.progress-bar-container {
    width: 100%;
    background-color: var(--medium-gray);
    border-radius: 6px;
    height: 10px;
    margin-top: 20px;
    overflow: hidden;
}

.progress-bar {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, var(--accent-orange), var(--primary-blue));
    border-radius: 6px;
    transition: width 0.4s ease-in-out;
}

.step {
    display: none;
    animation: fadeIn 0.5s ease-in-out;
    margin-bottom: 25px;
}

.step.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

.question-text {
    font-size: 1.3em;
    font-weight: 700;
    margin-bottom: 25px;
    color: var(--primary-blue);
    line-height: 1.4;
}

.options-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 18px;
    border: 2px solid var(--medium-gray);
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.3s ease;
    background-color: var(--white);
}

.option:hover {
    background-color: var(--light-gray);
    border-color: var(--primary-blue);
    transform: translateY(-1px);
}

.option input[type="radio"]:checked + label,
.option input[type="checkbox"]:checked + label {
    font-weight: 600;
}

.option:has(input:checked) {
    background-color: #EBF4FF;
    border-color: var(--primary-blue);
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.2);
}

.option input[type="radio"],
.option input[type="checkbox"] {
    accent-color: var(--primary-blue);
    width: 1.2em;
    height: 1.2em;
    cursor: pointer;
}

.option label {
    flex-grow: 1;
    cursor: pointer;
    color: var(--text-color);
    line-height: 1.5;
}

.option input[type="text"] {
    padding: 10px 12px;
    border: 1px solid var(--medium-gray);
    border-radius: 6px;
    font-size: 0.95em;
    margin-left: 10px;
    flex-grow: 1;
    display: none;
}

.wizard-navigation {
    display: flex;
    justify-content: space-between;
    margin-top: 35px;
    padding-top: 25px;
    border-top: 2px solid var(--light-gray);
}

.btn {
    padding: 12px 30px;
    border: none;
    border-radius: var(--border-radius);
    font-size: 1em;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn:active {
    transform: scale(0.98);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-blue), #1E40AF);
    color: var(--white);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #1E40AF, #1D4ED8);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

.btn-secondary {
    background-color: var(--medium-gray);
    color: var(--dark-gray);
}

.btn-secondary:hover {
    background-color: #9CA3AF;
    transform: translateY(-1px);
}

.btn-large {
    padding: 16px 40px;
    font-size: 1.1em;
}

/* STILI PER I RISULTATI NEL NUOVO FORMATO */
.results-container {
    padding: 0;
    border: none;
    margin-top: 30px;
    background-color: transparent;
}

.results-header {
    background: linear-gradient(135deg, var(--primary-blue), #1E40AF);
    color: var(--white);
    padding: 25px;
    border-radius: 12px 12px 0 0;
    text-align: center;
}

.results-header h2 {
    margin-bottom: 10px;
    font-size: 1.8em;
}

.results-header p {
    margin-bottom: 0;
    font-size: 1.05em;
    opacity: 0.9;
}

.advice-list {
    margin: 0;
    display: grid;
    gap: 0;
    background-color: var(--white);
}

.advice-card {
    padding: 25px;
    border-bottom: 1px solid var(--light-gray);
    border-left: 5px solid var(--accent-orange);
    position: relative;
    transition: all 0.3s ease;
}

.advice-card:hover {
    background-color: #FAFAFA;
    transform: translateX(5px);
}

.advice-card:last-child {
    border-bottom: none;
    border-radius: 0 0 12px 12px;
}

.advice-card h3 {
    margin-top: 0;
    margin-bottom: 15px;
    color: var(--primary-blue);
    font-size: 1.3em;
    display: flex;
    align-items: center;
    gap: 8px;
}

.advice-card .user-answer {
    margin-bottom: 20px;
    padding: 12px 18px;
    background-color: #F0F9FF;
    border-radius: 8px;
    border-left: 3px solid var(--primary-blue);
    font-size: 1.05em;
    line-height: 1.5;
}

.advice-card .user-answer strong {
    color: var(--primary-blue);
}

.advice-help {
    margin-top: 20px;
}

.advice-help h4 {
    margin-top: 0;
    margin-bottom: 10px;
    color: var(--accent-orange);
    font-size: 1.1em;
    font-weight: 700;
}

.advice-help p {
    margin-bottom: 0;
    line-height: 1.6;
    text-align: left;
    color: var(--text-color);
}

/* SEZIONE CTA PRINCIPALE */
.cta-section {
    background: linear-gradient(135deg, #F8FAFC, var(--light-gray));
    padding: 30px;
    border-radius: 12px;
    margin-top: 30px;
    text-align: center;
}

.main-cta {
    margin-bottom: 25px;
}

.main-cta h3 {
    color: var(--primary-blue);
    margin-bottom: 10px;
    font-size: 1.4em;
}

.main-cta p {
    color: var(--dark-gray);
    margin-bottom: 20px;
    font-size: 1.1em;
}

.cta-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-bottom: 20px;
}

.secondary-cta {
    padding-top: 20px;
    border-top: 1px solid var(--medium-gray);
}

.secondary-cta h4 {
    color: var(--primary-blue);
    margin-bottom: 8px;
}

.secondary-cta p {
    color: var(--dark-gray);
    font-size: 0.95em;
    line-height: 1.4;
}

#restartBtn {
    display: block;
    margin: 25px auto 0 auto;
}

/* RESPONSIVE */
@media (max-width: 768px) {
    .wizard-container {
        padding: 20px;
        margin: 10px;
    }

    .wizard-header h1 {
        font-size: 1.8em;
    }

    .wizard-header h2 {
        font-size: 1.1em;
    }

    .question-text {
        font-size: 1.2em;
    }

    .wizard-navigation {
        flex-direction: column-reverse;
        gap: 10px;
    }

    .btn {
        width: 100%;
    }

    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }

    .cta-buttons .btn {
        width: 100%;
        max-width: 300px;
    }

    .advice-card h3 {
        font-size: 1.1em;
    }

    .advice-card .user-answer {
        font-size: 0.95em;
        padding: 10px 15px;
    }

    .advice-help h4 {
        font-size: 1em;
    }

    .advice-help p {
        font-size: 0.95em;
    }
}
