/* Hero Section */
.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: relative;
    z-index: 1;
}

.hero-content {
    max-width: 600px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 2rem;
    padding: 3rem 2.5rem;
    text-align: center;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
}

.hero-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, rgba(255, 255, 255, 0.1) 0%, transparent 100%);
    z-index: 1;
}

.hero-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: #1e3a8a;
    margin-bottom: 1.5rem;
    letter-spacing: -0.025em;
    line-height: 1.2;
    position: relative;
    z-index: 2;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: #6b7280;
    margin-bottom: 1.5rem;
    font-weight: 400;
    position: relative;
    z-index: 2;
}

.hero-cta {
    font-size: 2rem;
    font-weight: 700;
    color: #db2777;
    margin-bottom: 2.5rem;
    letter-spacing: -0.025em;
    position: relative;
    z-index: 2;
}

.cta-button {
    background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 100%);
    color: white;
    border: none;
    padding: 1rem 2.5rem;
    font-size: 1.25rem;
    font-weight: 700;
    border-radius: 0.75rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 10px 25px rgba(30, 58, 138, 0.3);
    position: relative;
    z-index: 2;
    overflow: hidden;
}

.cta-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(30, 58, 138, 0.4);
}

.cta-button:hover::before {
    left: 100%;
}

/* Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 1rem;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-container {
    background: white;
    border-radius: 1.5rem;
    width: 100%;
    max-width: 880px;
    max-height: 90vh;
    overflow: hidden;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.9) translateY(20px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-overlay.active .modal-container {
    transform: scale(1) translateY(0);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 100%);
    color: white;
}

.modal-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
    color:#fff
}

.close-button {
    background: none;
    border: none;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    padding: 0;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.close-button:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.1);
}

.modal-content {
    padding: 4rem;
    max-height: calc(90vh - 100px);
    overflow-y: auto;
}

/* Quiz Styles in Modal */
.quiz-header {
    margin-bottom: 2rem;
}

.progress-bar {
    width: 100%;
    height: 0.75rem;
    background: linear-gradient(90deg, #e5e7eb 0%, #d1d5db 100%);
    border-radius: 9999px;
    margin-bottom: 1rem;
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #db2777 0%, #be185d 50%, #9d174d 100%);
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 9999px;
    box-shadow: 0 2px 8px rgba(219, 39, 119, 0.3);
}

.progress-text {
    text-align: center;
    font-size: 0.875rem;
    color: #6b7280;
    font-weight: 500;
}

.category-header {
    padding: 50px;
    border-radius: 0.75rem;
    margin-bottom: 1.5rem;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.category-header.casa { 
    background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 100%);
}
.category-header.mobilita { 
    background: linear-gradient(135deg, #059669 0%, #10b981 100%);
}
.category-header.lifestyle { 
    background: linear-gradient(135deg, #d97706 0%, #f59e0b 100%);
}

.category-title {
    
    font-weight: 700;
    letter-spacing: 0.05em;
    color: #fff;
        padding: 0;
    margin: 0;
}

.category-header span {
    font-size: 1.25rem;
}

.question-section {
    margin-bottom: 2rem;
}

.question-text {
    font-size: 3rem;
    font-weight: 600;
    color: #1e3a8a;
    margin-bottom: 1.5rem;
    text-align: center;
    line-height: 1.4;
}

.options {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.option-button {
    width: 100%;
    padding: 0.875rem 1.25rem;
    border: 2px solid #e5e7eb;
    border-radius: 0.5rem;
    background: white;
    text-align: left;
    font-weight: 400;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 1.2rem;
    color: #374151;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.option-button:hover {
    border-color: #3b82f6;
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

.navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1.5rem;
    border-top: 1px solid #e5e7eb;
}

.nav-button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1rem;
    border: 1px solid #1e3a8a;
    border-radius: 0.5rem;
    background: white;
    color: #1e3a8a;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.875rem;
    font-weight: 500;
}

.nav-button:hover:not(:disabled) {
    background: #1e3a8a;
    color: white;
}

.nav-button:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.category-text {
    font-weight: 500;
    color: #6b7280;
    font-size: 0.875rem;
}

/* Results Styles in Modal */
.results-header {
    text-align: center;
    margin-bottom: 2rem;
}

.results-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1e3a8a;
    margin-bottom: 1rem;
}

.total-score {
    font-size: 2.5rem;
    font-weight: 900;
    background: linear-gradient(135deg, #db2777 0%, #be185d 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.result-card {
    padding: 1.25rem;
    border-radius: 0.75rem;
    text-align: center;
    border-left: 4px solid;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.result-card.casa {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    border-left-color: #3b82f6;
}

.result-card.mobilita {
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
    border-left-color: #10b981;
}

.result-card.lifestyle {
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
    border-left-color: #f59e0b;
}

.result-header {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.5rem;
    gap: 0.5rem;
}

.result-header h4 {
    font-weight: 700;
    font-size: 0.875rem;
    letter-spacing: 0.05em;
}

.casa .result-header h4 { color: #1d4ed8; }
.mobilita .result-header h4 { color: #047857; }
.lifestyle .result-header h4 { color: #b45309; }

.result-score {
    font-size: 1.5rem;
    font-weight: 700;
}

.casa .result-score { color: #1d4ed8; }
.mobilita .result-score { color: #047857; }
.lifestyle .result-score { color: #b45309; }

.comparison-section {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    padding: 1.5rem;
    border-radius: 0.75rem;
    margin-bottom: 2rem;
    border: 1px solid #e2e8f0;
}

.comparison-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.75rem;
    font-weight: 600;
    font-size: 0.875rem;
}

.comparison-row:last-of-type {
    margin-bottom: 1rem;
}

.comparison-bar {
    width: 100%;
    height: 0.75rem;
    background: linear-gradient(90deg, #e5e7eb 0%, #d1d5db 100%);
    border-radius: 9999px;
    margin-bottom: 1rem;
    overflow: hidden;
}

.comparison-fill {
    height: 100%;
    border-radius: 9999px;
    transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.comparison-fill.good { 
    background: linear-gradient(90deg, #10b981 0%, #059669 100%);
}
.comparison-fill.bad { 
    background: linear-gradient(90deg, #ef4444 0%, #dc2626 100%);
}

.comparison-text {
    text-align: center;
    font-size: 0.875rem;
    font-weight: 600;
}

.tips-section {
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
    padding: 1.5rem;
    border-radius: 0.75rem;
    border-left: 4px solid #f59e0b;
    margin-bottom: 2rem;
}

.tips-title {
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 1rem;
    color: #92400e;
}

.tips-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.tip-item {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
}

.modal-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.restart-button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 100%);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    border: none;
    font-weight: 600;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.3s;
}

.restart-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(30, 58, 138, 0.3);
}

.secondary-button {
    padding: 0.75rem 1.5rem;
    border: 2px solid #6b7280;
    border-radius: 0.5rem;
    background: white;
    color: #6b7280;
    font-weight: 600;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.3s;
}

.secondary-button:hover {
    background: #6b7280;
    color: white;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .hero-content {
        padding: 2rem 1.5rem;
        margin: 1rem;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-cta {
        font-size: 1.5rem;
    }
    
    .modal-container {
        max-width: 95vw;
        max-height: 95vh;
    }
    
    .modal-content {
        padding: 1rem;
    }
    
    .results-grid {
        grid-template-columns: 1fr;
    }
    
    .modal-actions {
        flex-direction: column;
    }
    
    .option-button {
        font-size: 0.875rem;
        padding: 0.75rem 1rem;
    }
    
    .question-text {
        font-size: 1rem;
    }
}