/* ===== Quiz Screen ===== */
.quiz-screen {
    animation: fadeIn 0.4s ease;
}

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

.quiz-header {
    display: flex;
    align-items: center;
    gap: 2rem;
    padding: 1.25rem 1.5rem;
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    margin-bottom: 2rem;
}

.back-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1rem;
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-family: inherit;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.back-btn svg {
    width: 18px;
    height: 18px;
}

.back-btn:hover {
    background: var(--bg-card);
    color: var(--text-primary);
    border-color: var(--accent);
}

.quiz-info {
    flex: 1;
}

.quiz-info h2 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.progress-container {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.progress-bar {
    flex: 1;
    height: 8px;
    background: var(--bg-card);
    border-radius: 4px;
    overflow: hidden;
    max-width: 300px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--gradient-start), var(--gradient-end));
    border-radius: 4px;
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.progress-text {
    font-family: var(--font-mono);
    font-size: 0.875rem;
    color: var(--text-muted);
    white-space: nowrap;
}

.score-display {
    text-align: center;
    padding: 0.75rem 1.5rem;
    background: var(--bg-card);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}

.score-label {
    display: block;
    font-size: 0.625rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-bottom: 0.25rem;
}

.score-value {
    font-family: var(--font-mono);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent-green);
}

/* ===== Question Container ===== */
.question-container {
    background: var(--bg-secondary);
    border-radius: var(--radius-xl);
    border: 1px solid var(--border-color);
    padding: 2.5rem;
    margin-bottom: 1.5rem;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from { opacity: 0; transform: translateX(30px); }
    to { opacity: 1; transform: translateX(0); }
}

.question-number {
    display: inline-block;
    padding: 0.375rem 1rem;
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1.25rem;
}

.question-text {
    font-size: 1.25rem;
    font-weight: 500;
    line-height: 1.7;
    margin-bottom: 2rem;
    color: var(--text-primary);
}

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

.option-btn {
    display: flex;
    align-items: center;
    gap: 1rem;
    width: 100%;
    padding: 1.125rem 1.5rem;
    background: var(--bg-card);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 1rem;
    text-align: left;
    cursor: pointer;
    transition: all 0.2s ease;
}

.option-btn:hover:not(.selected):not(.correct):not(.incorrect) {
    background: var(--bg-card-hover);
    border-color: var(--accent);
    transform: translateX(8px);
}

.option-letter {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: var(--bg-secondary);
    border-radius: 50%;
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--text-secondary);
    flex-shrink: 0;
    transition: all 0.2s ease;
}

.option-btn:hover .option-letter {
    background: var(--accent);
    color: var(--bg-primary);
}

.option-text {
    flex: 1;
}

.option-btn.selected {
    background: rgba(167, 139, 250, 0.15);
    border-color: var(--accent);
}

.option-btn.selected .option-letter {
    background: var(--accent);
    color: var(--bg-primary);
}

.option-btn.correct {
    background: rgba(34, 197, 94, 0.15);
    border-color: var(--accent-green);
}

.option-btn.correct .option-letter {
    background: var(--accent-green);
    color: var(--bg-primary);
}

.option-btn.incorrect {
    background: rgba(239, 68, 68, 0.15);
    border-color: var(--accent-red);
}

.option-btn.incorrect .option-letter {
    background: var(--accent-red);
    color: white;
}

.option-btn.disabled {
    cursor: not-allowed;
    opacity: 0.7;
}

/* ===== Quick Result Feedback ===== */
.feedback-icon {
    margin-left: auto;
    font-size: 1.25rem;
    font-weight: 700;
    animation: popIn 0.3s ease;
}

.feedback-icon.correct {
    color: var(--accent-green);
}

.feedback-icon.incorrect {
    color: var(--accent-red);
}

@keyframes popIn {
    0% { transform: scale(0); opacity: 0; }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); opacity: 1; }
}

.quick-feedback-message {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-top: 1.5rem;
    padding: 1rem 2rem;
    border-radius: var(--radius-md);
    font-size: 1.25rem;
    font-weight: 600;
    animation: slideUp 0.3s ease;
}

.quick-feedback-message.correct {
    background: rgba(34, 197, 94, 0.15);
    border: 2px solid var(--accent-green);
    color: var(--accent-green);
}

.quick-feedback-message.incorrect {
    background: rgba(239, 68, 68, 0.15);
    border: 2px solid var(--accent-red);
    color: var(--accent-red);
}

.quick-feedback-message .feedback-emoji {
    font-size: 1.5rem;
}

.quick-feedback-message .auto-next {
    font-size: 0.9rem;
    font-weight: 400;
    opacity: 0.8;
    margin-left: 0.5rem;
    animation: pulse-fade 0.6s ease infinite;
}

@keyframes pulse-fade {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

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

/* Quick Result Toggle Button */
.quick-result-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-family: inherit;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.quick-result-toggle:hover {
    background: var(--bg-card-hover);
    border-color: var(--accent);
}

.quick-result-toggle.active {
    background: rgba(167, 139, 250, 0.15);
    border-color: var(--accent);
    color: var(--accent);
}

.quick-result-toggle svg {
    width: 18px;
    height: 18px;
}
