/* css/ensayos.css */
.ensayo-wrapper {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

.ensayo-header {
    text-align: center;
    margin-bottom: 30px;
    padding: 30px;
    background: var(--gradient-card);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border);
}

.ensayo-header h2 {
    font-size: 2rem;
    font-weight: 800;
    color: var(--nav-bg);
    margin-bottom: 10px;
}

.ensayo-header p {
    color: var(--text-muted);
    font-size: 1.1rem;
}

.level-selector-container {
    background: white;
    padding: 30px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
    text-align: center;
    margin-bottom: 40px;
}

.form-select {
    width: 100%;
    max-width: 300px;
    padding: 12px 15px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 1rem;
    color: var(--text);
    margin-bottom: 20px;
    outline: none;
    transition: var(--transition);
}

.form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.question-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 20px 25px;
    margin-bottom: 15px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    animation: fadeInUp 0.5s ease;
}

.question-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.question-text {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 15px;
    line-height: 1.4;
}

.options-container {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.option-label {
    display: flex;
    align-items: center;
    padding: 10px 15px;
    background: var(--bg-main);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
    text-transform: none; /* override global label style */
    letter-spacing: normal;
}

.option-label:hover {
    background: #f1f5f9;
    border-color: #cbd5e1;
}

.option-label input[type="radio"] {
    margin-right: 12px;
    transform: scale(1.2);
    cursor: pointer;
    width: auto; /* override global input width: 100% */
    padding: 0;
    box-shadow: none;
}

.option-text {
    font-size: 0.95rem;
    color: var(--text);
}

/* States for evaluation */
.option-label.correct-option {
    background: #dcfce7;
    border-color: #16a34a;
    color: #166534;
}

.option-label.incorrect-option {
    background: #fee2e2;
    border-color: #dc2626;
    color: #991b1b;
}

.feedback {
    margin-top: 20px;
    padding: 15px;
    border-radius: var(--radius-md);
    background: #f8fafc;
    border-left: 4px solid var(--primary);
}

.feedback-correct {
    color: #16a34a;
    font-weight: 700;
    margin-bottom: 5px;
    font-size: 1.1rem;
}

.feedback-incorrect {
    color: #dc2626;
    font-weight: 700;
    margin-bottom: 5px;
    font-size: 1.1rem;
}

.explanation {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.5;
    margin-top: 5px;
}

#results-area {
    text-align: center;
    padding: 40px;
    background: white;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border);
    margin-bottom: 40px;
    animation: fadeInUp 0.6s ease;
}

.score-circle {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: var(--gradient-primary);
    color: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px auto;
    box-shadow: var(--shadow-blue);
}

.score-number {
    font-size: 1.5rem;
    font-weight: 600;
}

.score-percent {
    font-size: 2.5rem;
    font-weight: 800;
    line-height: 1;
}

.score-message {
    font-size: 1.2rem;
    color: var(--text);
    margin-bottom: 20px;
    font-weight: 500;
}

.submit-container {
    text-align: center;
    margin: 40px 0;
}
