/* test-simulatore.css - Stile per il simulatore di test d'ingresso */
.test-container {
    padding: 2rem 3rem;
    max-width: 1200px;
    margin: 0 auto;
    min-height: calc(100vh - 4rem);
}

.test-header {
    text-align: center;
    margin-bottom: 2rem;
}

.test-header h1 {
    font-size: 2.2rem;
    color: #1e293b;
    margin-bottom: 0.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.test-header p {
    font-size: 1.1rem;
    color: #64748b;
    max-width: 600px;
    margin: 0 auto;
}

/* Filtri */
.test-filter {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 0.5rem 1.5rem;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s;
}

.filter-btn:hover, .filter-btn.active {
    background: #4361ee;
    color: white;
    border-color: #4361ee;
}

.test-selection {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.selection-card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: transform 0.2s, box-shadow 0.2s;
}

.selection-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.card-icon {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.card-icon i {
    font-size: 2rem;
    color: #4361ee;
}

.card-icon.private {
    background: #fff1f2;
}

.card-icon.private i {
    color: #f43f5e;
}

.selection-card h3 {
    font-size: 1.4rem;
    color: #1e293b;
    margin-bottom: 1rem;
}

.selection-card p {
    color: #64748b;
    margin-bottom: 1.5rem;
    line-height: 1.5;
    font-weight: 500;
}

.selection-card ul {
    text-align: left;
    margin-bottom: 2rem;
    color: #64748b;
    width: 100%;
}

.selection-card li {
    margin-bottom: 0.5rem;
    padding-left: 0.5rem;
    font-size: 0.9rem;
}

.selection-card li::before {
    content: "•";
    color: #4361ee;
    font-weight: bold;
    display: inline-block;
    width: 1em;
    margin-left: -1em;
}

.selection-card[data-type="private"] li::before {
    color: #f43f5e;
}

.test-preparation {
    background: white;
    padding: 2.5rem;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    margin-bottom: 2rem;
}

.preparation-content h2 {
    text-align: center;
    color: #1e293b;
    margin-bottom: 2rem;
    font-size: 1.8rem;
}

.test-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.info-box {
    background: #f8fafc;
    padding: 1.5rem;
    border-radius: 8px;
    text-align: center;
}

.info-box i {
    font-size: 2rem;
    color: #4361ee;
    margin-bottom: 1rem;
}

.info-box h4 {
    color: #1e293b;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.info-box p {
    color: #64748b;
}

.preparation-actions {
    display: flex;
    justify-content: center;
    gap: 1rem;
}

.test-interface {
    background: white;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    margin-bottom: 2rem;
    overflow: hidden;
}

.test-header-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 2rem;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
}

.test-progress {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1;
}

.progress-bar {
    width: 200px;
    height: 8px;
    background: #e2e8f0;
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: #4361ee;
    border-radius: 4px;
    transition: width 0.3s ease;
}

#progress-text {
    font-size: 0.9rem;
    color: #64748b;
}

.test-timer {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    color: #1e293b;
    background: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    border: 1px solid #e2e8f0;
}

.question-container {
    padding: 2rem;
}

.question-number {
    font-size: 1.1rem;
    color: #64748b;
    margin-bottom: 0.5rem;
}

.question-text {
    font-size: 1.2rem;
    color: #1e293b;
    margin-bottom: 2rem;
    line-height: 1.5;
    font-weight: 500;
}

.options-container {
    margin-bottom: 2rem;
}

.option-item {
    display: flex;
    align-items: center;
    padding: 1rem 1.25rem;
    margin-bottom: 0.75rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.option-item:hover {
    background: #eef2ff;
    border-color: #c7d2fe;
}

.option-item.selected {
    background: #e0e7ff;
    border-color: #4361ee;
}

.option-letter {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
    font-weight: 600;
    color: #64748b;
    flex-shrink: 0;
}

.option-item.selected .option-letter {
    background: #4361ee;
    color: white;
}

.option-text {
    color: #1e293b;
}

.question-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    color: #475569;
    cursor: pointer;
    transition: all 0.2s;
}

.nav-btn:hover:not(:disabled) {
    background: #eef2ff;
    color: #4361ee;
}

.nav-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

#mark-question.marked {
    background: #fffbeb;
    border-color: #f59e0b;
    color: #f59e0b;
}

#mark-question.marked i {
    color: #f59e0b;
}

.test-controls {
    padding: 1.5rem 2rem;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    display: flex;
    justify-content: center;
    gap: 1rem;
}

.test-results {
    background: white;
    padding: 2.5rem;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.results-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.results-header h2 {
    color: #1e293b;
    margin-bottom: 0.5rem;
    font-size: 1.8rem;
}

.results-header p {
    color: #64748b;
}

.results-content {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.score-card {
    display: flex;
    align-items: center;
    gap: 3rem;
    justify-content: center;
    flex-wrap: wrap;
}

.score-circle {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: #f1f5f9;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 8px solid #e0e7ff;
}

#final-score {
    font-size: 2.5rem;
    font-weight: 700;
    color: #4361ee;
}

.score-circle small {
    color: #64748b;
    font-size: 0.9rem;
}

.score-details {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

.detail-label {
    color: #64748b;
}

.detail-value {
    font-weight: 600;
    color: #1e293b;
}

.results-breakdown h3,
.results-comparison h3 {
    color: #1e293b;
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.breakdown-charts {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.chart-item {
    background: #f8fafc;
    padding: 1.5rem;
    border-radius: 8px;
}

.chart-title {
    color: #1e293b;
    margin-bottom: 1rem;
    font-weight: 600;
}

.chart-bar {
    height: 8px;
    background: #e2e8f0;
    border-radius: 4px;
    margin-bottom: 0.5rem;
    overflow: hidden;
}

.chart-fill {
    height: 100%;
    background: #4361ee;
    border-radius: 4px;
}

.chart-stats {
    display: flex;
    justify-content: space-between;
    color: #64748b;
    font-size: 0.9rem;
}

.results-comparison p {
    color: #64748b;
    margin-bottom: 1.5rem;
}

.comparison-chart {
    margin-bottom: 1rem;
}

.comparison-bar {
    height: 30px;
    background: linear-gradient(90deg, #ef4444 0%, #f59e0b 50%, #10b981 100%);
    border-radius: 15px;
    position: relative;
    margin-bottom: 0.5rem;
}

.user-position {
    width: 4px;
    height: 40px;
    background: #1e293b;
    position: absolute;
    top: -5px;
    border-radius: 2px;
}

.comparison-labels {
    display: flex;
    justify-content: space-between;
    color: #64748b;
    font-size: 0.9rem;
}

.results-actions {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Pulsanti */
.btn-primary {
    background-color: #4361ee;
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary:hover {
    background-color: #3a56d4;
}

.btn-secondary {
    background-color: #f1f5f9;
    color: #475569;
    border: 1px solid #e2e8f0;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-secondary:hover {
    background-color: #e2e8f0;
    color: #1e293b;
}

/* Responsive */
@media (max-width: 1024px) {
    .test-container {
        padding: 1.5rem 2rem;
    }
    
    .test-header h1 {
        font-size: 2rem;
    }
    
    .test-selection {
        grid-template-columns: 1fr;
        max-width: 500px;
        margin-left: auto;
        margin-right: auto;
    }
}

@media (max-width: 768px) {
    .test-container {
        padding: 1rem;
    }
    
    .test-header {
        margin-bottom: 1.5rem;
    }
    
    .test-header h1 {
        font-size: 1.8rem;
    }
    
    .test-header p {
        font-size: 1rem;
    }
    
    .test-info {
        grid-template-columns: 1fr;
    }
    
    .test-header-bar {
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
    }
    
    .test-progress {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
    }
    
    .progress-bar {
        width: 100%;
    }
    
    .question-navigation {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .score-card {
        flex-direction: column;
        gap: 2rem;
        text-align: center;
    }
    
    .detail-item {
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }
    
    .results-actions {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .test-container {
        padding: 0.8rem;
    }
    
    .test-header h1 {
        font-size: 1.6rem;
    }
    
    .selection-card {
        padding: 1.5rem;
    }
    
    .test-preparation,
    .test-results {
        padding: 1.5rem;
    }
    
    .question-container {
        padding: 1.5rem;
    }
    
    .test-controls {
        flex-direction: column;
    }
}