/**
 * Стили для результатов профтеста
 * Разные стили для разных типов профессий
 */

/* Базовые стили для всех типов профессий */
/* 
 * Стили для страницы результатов профориентационного теста
 * Модульный подход - импортирует только необходимые стили
 */

/* Базовые стили */
@import "../common/variables.css";
@import "../common/reset.css";
@import "../common/fonts.css";
@import "../common/buttons.css";

/* Импорт стилей для результатов */
/* @import url("quiz-header.css"); */

.results-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 1;
    pointer-events: none;
    background-color: #294ea1;
    background-blend-mode: color-burn;
    background-position: 50% 100%;
    background-size: 4000px;
    opacity: 0;
}

.results-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.05;
}

.results-title_panel-info {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #3465d5;
    border-radius: 24px;
    padding: 16px 32px;
    min-width: 258px;
    height: 58px;
    text-align: center;
    font-family: var(--font-family);
    font-weight: 400;
    font-size: 24px;
    line-height: 110%;
    color: #fff;
    margin: 0 auto 40px;
}

.results-title {
    font-family: var(--font-family);
    font-weight: 700;
    font-size: 56px;
    line-height: 110%;
    text-align: center;
    color: #fff;
    margin: 0 auto 40px;
}

/* Стили для страницы результатов профтеста */
.results-page {
    min-height: 100vh;
    min-height: 100dvh;
    background: #294ea1;
    position: relative;
    overflow-x: hidden;
    padding-top: 140px;
}

.results-wrapper {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.results-proftest .results-wrapper {
    max-width: 794px;
    margin: 0 auto;
    position: relative;
    padding-bottom: 120px;
}

.results-title_panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
    max-width: 365px;
    margin: 0 auto;

    .img-wrapper {
        width: 100%;
        max-width: 360px;

        img {
            max-width: 100%;
        }
    }
}

.results-content {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    position: relative;
}

.professions-container .results-content__item {
    display: grid;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    grid-template-columns: 1fr 1fr;
}

.results-content__item-text {
    font-family: var(--font-family);
    font-weight: 400;
    font-size: 26px;
    line-height: 140%;
    letter-spacing: -0.02em;
    text-align: center;
    color: #fff;
    max-width: 890px;
    margin: 0 auto;

    span {
        font-weight: 700;
        color: #FFAD2B;
    }

    a {
        text-decoration: underline;
        transition: all 0.3s ease;
        color: #fff;
    }

    a:hover {
        text-decoration: none;
    }
}

.results-content__buttons {
    max-width: 690px;
    margin: 40px auto;
    display: flex;
    gap: 20px;
    justify-content: space-between;
    align-items: center;

    .btn--primary {
        flex: 1;
        gap: 16px;
        justify-content: center;
    }
}

.results-content__item-img {
    width: 100%;
    max-width: 390px;

    img {
        max-width: 100%;
        transform: translateY(6px);
    }
}

.results-content__item-title {
    font-family: var(--font-family);
    font-weight: 700;
    font-size: 32px;
    line-height: 120%;
    color: #fff;
}

.results-content__item-title--mobile {
    display: none;
}

.results-content__panel {
    box-shadow: 0 0 30px 0 rgba(41, 78, 161, 0.1);
    background: rgba(255, 255, 255, 0.2);
    border-radius: 32px;
    padding: 32px 32px 56px;
    width: 100%;
}

.results-content__panel-text {
    font-family: var(--font-family);
    font-weight: 400;
    font-size: 20px;
    line-height: 140%;
    color: #fff;
}

.results-content__panel-text p {
    margin-bottom: 1rem;
    padding: 0;
    font-family: var(--font-family);
    font-weight: 400;
    font-size: 20px;
    line-height: 140%;
    color: #fff;
}

.results-content__panel-text p:last-child {
    margin-bottom: 0;
}

.results-content__panel-buttons {
    display: flex;
    gap: 16px;
    justify-content: space-between;
    align-items: center;
    margin-top: 32px;

    .btn {
        color: #fff;
    }

    .btn--primary {
        flex: 1;
    }
}

.results-proftest .results-content__panel-buttons {
    .btn--primary {
        justify-content: center;
    }
}

.results-footer {
    margin-top: 140px;
    border-radius: 24px;
    padding: 40px 40px 56px;
    width: 100%;
    background: rgba(14, 49, 127, 0.6);
    margin-bottom: 120px;
    max-width: 996px;
    margin-left: auto;
    margin-right: auto;
}

.results-footer__title {
    font-family: var(--font-family);
    font-weight: 700;
    font-size: 32px;
    line-height: 120%;
    color: #fff;
    margin-bottom: 20px;
}

.results-footer__content {
    font-family: var(--font-family);
    font-weight: 400;
    font-size: 20px;
    line-height: 140%;
    color: #fff;
}

.results-footer__content p {
    padding: 0;
    margin-bottom: 1rem;
}

.results-footer__content p:last-child {
    margin-bottom: 0;
}

.results-footer__content a {
    text-decoration: underline;
    transition: all 0.3s ease;
}

.results-footer__content a:hover {
    text-decoration: none;
}

.results-footer_column:first-child {
    border-right: 1px solid #fff;
}

.results-footer_column {
    flex: 1;
}

.results-footer_colum,
.results-footer_column p {
    font-family: var(--font-family);
    font-weight: 400;
    font-size: 20px;
    line-height: 140%;
    letter-spacing: -0.03em;
    text-align: center;
    color: #fff;
}

.results-footer_column p {
    max-width: 330px;
    width: 100%;
    padding: 0;
    margin: 0 auto;
}

.results-footer_column .btn {
    max-width: 330px;
    margin: 40px auto 0;
    justify-content: center;
}

.results-footer_column-social {
    width: 216px;
    height: 56px;
    display: flex;
    align-items: center;
    gap: 24px;
    justify-content: space-between;
    margin: 40px auto 0;

    a {
        width: 56px;
        height: 56px;
        display: flex;
        align-items: center;
        justify-content: center;

        img {
            width: 100%;
            height: 100%;
            object-fit: contain;
        }
    }
}

.results-footer_row {
    display: flex;
    justify-content: space-between;
}

.results-footer__light {
    background: rgba(255, 255, 255, 0.2);
}

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
    .results-title {
        font-size: 2rem;
    }

    .results-content__item-title {
        font-size: 1.25rem;
    }

    .results-content__panel {
        padding: 1.5rem;
        margin: 1rem;
    }

    .results-content__panel-buttons {
        flex-direction: column;
        align-items: center;
    }

    .results-content__panel-buttons .btn {
        width: 100%;
        max-width: 300px;
    }

    .results-footer {
        padding: 1.5rem;
        margin: 1rem;
    }

    .results-footer__title {
        font-size: 1.25rem;
    }
}

/*  */

/* Адаптивные стили */
@media (max-width: 768px) {
    .results-proftest .results-wrapper {
        padding: 1rem 0;
    }

    .results-proftest .results-content__item-title {
        font-size: 1.5rem;
        line-height: 1.3;
    }
}

/* Анимации */
.results-proftest .results-content__item {
    animation: fadeInUp 0.8s ease-out;
}

.results-proftest .results-content__panel {
    animation: fadeInUp 1s ease-out 0.2s both;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}


@media (max-width:450px) {
    .results-content__item-title {
        display: none;
    }

    .results-content__item-title--mobile {
        display: block;
        margin-bottom: 1em;
    }

    .results-proftest .results-wrapper {
        padding-bottom: 40px;
    }

    .results-footer_row {
        flex-direction: column;
    }

    .results-footer_column:first-child {
        border: none;
        padding-bottom: 30px;
        border-bottom: 1px solid #fff;
        margin-bottom: 30px;
    }

    .results-content__buttons {
        display: flex;
        flex-direction: column;
    }

    .results-content__item-text {
        font-size: 20px;
        line-height: 1.4;
    }

    .results-footer {
        width: 100%;
        min-width: auto;
        margin: 0 0 50px;
    }

    .results-content {
        padding: 0 20px;
    }

    .professions-container .results-content__item {
        display: flex;
        flex-direction: column;

    }

    .results-proftest .results-content__panel {
        margin: 16px auto;
    }

    .results-page {
        padding-top: 90px;

        .results-title_panel-info {
            font-weight: 400;
            font-size: 16px;
            line-height: 140%;
            text-align: center;
            height: 46px;
            border-radius: 24px;
            padding: 12px 24px;
            width: max-content;
            min-width: 180px;
            margin: 0 auto 16px;
        }

        .results-title {
            font-weight: 700;
            font-size: 32px;
            line-height: 110%;
            text-align: center;
        }

        .results-proftest .results-content__item-title {
            font-weight: 700;
            font-size: 20px;
            line-height: 140%;
            letter-spacing: -0.03em;
        }

        .results-content__panel-text p {
            font-weight: 400;
            font-size: 16px;
            line-height: 140%;
            letter-spacing: -0.03em;
        }

        .results-content__panel-buttons .btn {
            text-align: center;
            display: flex;
            justify-content: center;
            align-items: center;
            width: 100%;
            max-width: 100%;
        }
    }
}

/* ==========================================================================
   Оптимизированные стили для мгновенной загрузки результатов
   ========================================================================== */

/* Скрытые блоки профессий */
.profession-block {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    position: absolute;
    width: 100%;
    left: 0;
    top: 0;
}

/* Анимация появления профессии */
.profession-block.revealing {
    opacity: 1;
    transform: translateY(0);
    position: relative;
}

/* Анимация элементов контента */
.profession-block .animate-in {
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.4s ease;
}

.profession-block .animate-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Сообщение об отсутствии результатов */
.no-results-message {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    opacity: 0;

    .wrap-image {
        width: 100%;
        max-width: 380px;
        margin: 0 auto;
        display: flex;
        align-items: center;
        justify-content: center;

        img {
            width: 100%;
            max-width: 100%;
        }
    }
}

.no-results-content {
    text-align: center;
    border-radius: 24px;
    padding: 40px 40px 56px;
    transform: translateY(20px);
    transition: all 0.6s ease;
    background: rgba(255, 255, 255, 0.2);
    margin: 0 0 60px 0;
}

.no-results-message.visible {
    opacity: 1;
    transform: translateY(0);
}

.no-results-content h2 {
    color: #fff;
    margin-bottom: 20px;
    font-size: 28px;
    font-weight: 600;
}

.no-results-content p {
    font-family: var(--font-family);
    font-weight: 400;
    font-size: 20px;
    line-height: 140%;
    letter-spacing: -0.03em;
    text-align: center;
    color: #fff;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.no-results-content .btn {
    font-family: var(--font-family);
    font-weight: 500;
    font-size: 20px;
    line-height: 120%;
    transition: all 0.3s ease;
    background: var(--color-primary-red);
    color: var(--color-white);
    box-shadow: var(--shadow-light);
    overflow: hidden;
    position: relative;
    transition: all 0.3s ease;
    cursor: pointer;
    border-radius: 50px;
    height: 56px;
    padding: 16px 24px;
    text-align: center;
    display: flex;
    justify-content: center;
    max-width: fit-content;
    margin: 30px auto 0;
}

/* Профессиональные изображения с оптимизацией загрузки */
.profession-image {
    width: 100%;
    max-width: 100%;
    height: auto;
    pointer-events: none;
}

/* Предотвращение смещения контента при загрузке */
.professions-container {
    position: relative;
    min-height: 600px;
    /* Фиксированная высота для предотвращения скачков */

    img {
        width: 100%;
        pointer-events: none;
    }
}

/* Оптимизация производительности */
.profession-block:not(.revealing) {
    will-change: auto;
}

.profession-block.revealing {
    will-change: transform, opacity;
}

/* Анимация кнопок */
.results-content__panel-buttons .btn {
    animation: fadeInUp 0.6s ease forwards;
    animation-delay: 0.8s;
    opacity: 0;
    transform: translateY(20px);
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Улучшенная типографика для результатов */
/* .results-content__item-title {
    font-size: 24px;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 20px;
    color: #1a1a1a;
}

.results-content__panel-text {
    font-size: 16px;
    line-height: 1.6;
    color: #4a4a4a;
    margin-bottom: 30px;
} */

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
    .no-results-content h2 {
        font-size: 24px;
    }

    .no-results-content p {
        font-size: 16px;
    }

    .results-content__item-title {
        font-size: 20px;
    }

    .professions-container {
        min-height: 500px;
    }
}

@media screen and (max-width:450px) {
    .results-title_panel {
        .img-wrapper {
            width: 100%;
            max-width: 244px;
            margin-bottom: -5px;
            margin-top: 15px;
        }
    }

    .no-results-message .wrap-image {
        max-width: 320px;
        margin: 0 auto;
    }

    .no-results-content {
        padding: 24px 16px 40px;
    }

    .no-results-content .btn {
        width: 100%;
        max-width: 100%;
    }
    .professions-container {
        min-height: fit-content;
    }
}