/**
 * Стили для статического профтеста
 * Все вопросы загружены на странице, JavaScript управляет отображением
 */

/* Базовые стили для всех вопросов */
.proftest-question {
    opacity: 0;
    transform: translateX(0);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: opacity, transform;
    pointer-events: none;
}

/* Показываем только активный вопрос */
.proftest-question.active {
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
}

/* Стили для выбранного ответа */
/* .question-answer--selected {
    background-color: #f0f8ff;
    border-color: #007cba;
}

.question-answer--selected .question-answer__number {
    background-color: #007cba;
    color: white;
} */

/* Стили для прогресс-бара */
.quiz-progress {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 20px 0;
    font-size: 16px;
    color: #666;
}

.quiz-progress__current {
    font-weight: bold;
    color: #fff;
}

.quiz-progress__total {
    color: #999;
}

/* Стили для кнопки ответа */
.quiz-btn--answer:disabled {
    cursor: not-allowed;
}

.quiz-btn--answer:not(:disabled) {
    cursor: pointer;
}

/* Стили для загрузки */
.quiz-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    text-align: center;
}

.quiz-loading__spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #007cba;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.quiz-loading__text {
    font-size: 16px;
    color: #666;
    margin: 0;
}

/* Анимация для вариантов ответов */
.question-answer {
    transition: all 0.3s ease;
    transform: translateY(0);
}

.question-answer:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}
@media screen and (max-width: 450px) {
    .question-answer:hover {
        transform: none;
        box-shadow: none;
    }
}

@keyframes questionEnter {
    0% {
        opacity: 0;
        transform: translateX(50px) scale(0.95);
    }
    20% {
        opacity: 0.2;
        transform: translateX(35px) scale(0.96);
    }
    40% {
        opacity: 0.5;
        transform: translateX(20px) scale(0.97);
    }
    60% {
        opacity: 0.8;
        transform: translateX(10px) scale(0.98);
    }
    80% {
        opacity: 0.95;
        transform: translateX(3px) scale(0.99);
    }
    100% {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}

@keyframes questionLeave {
    0% {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
    20% {
        opacity: 0.8;
        transform: translateX(-10px) scale(0.98);
    }
    40% {
        opacity: 0.6;
        transform: translateX(-20px) scale(0.96);
    }
    60% {
        opacity: 0.3;
        transform: translateX(-30px) scale(0.94);
    }
    80% {
        opacity: 0.1;
        transform: translateX(-40px) scale(0.92);
    }
    100% {
        opacity: 0;
        transform: translateX(-50px) scale(0.9);
    }
}

/* Анимация для кнопки ответа */
.quiz-btn--answer {
    transition: all 0.3s ease;
    transform: translateY(0);
}

.quiz-btn--answer:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 124, 186, 0.3);
}

.quiz-btn--answer:disabled {
    cursor: not-allowed;
    transform: none;
}

/* Анимация прогресс-бара */
.proftest-footer__progress {
    transition: width 0.3s ease;
}

/* Плавная анимация для всего контейнера вопросов */
.step-content {
    position: relative;
    /* overflow: hidden; */
    /* min-height: 400px; */
    width: 100%;
}

.step-content .proftest-question {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 1;
}

.step-content .proftest-question.active {
    position: absolute;
    z-index: 2;
}

.step-content .proftest-question.entering {
    z-index: 3;
}

.step-content .proftest-question.leaving {
    z-index: 1;
}

/* Адаптивность */
@media (max-width: 768px) {
    .quiz-progress {
        font-size: 14px;
    }
    
    .quiz-loading {
        padding: 20px 10px;
    }
    
    .quiz-loading__spinner {
        width: 30px;
        height: 30px;
        border-width: 3px;
    }
    
    .quiz-loading__text {
        font-size: 14px;
    }
    
    .step-content {
        min-height: 300px;
    }
}

@media screen and (max-width: 450px) {
    .step-content .proftest-question {
        padding-top: 20px;
        padding-bottom: 20px;
    }
}

/* Скрываем отвеченные вопросы */
.proftest-question.answered {
    display: none !important;
}
