/****************************
* Dizayner Yoqubov Shaxzod  *
*  Tel: + 99 894 588-56-56  *
*   Tg: @Yoqubov_Shaxzod    *
*      Site: yoqubov.uz     *
****************************/

.section-quiz {
    padding: 8rem 0;
    background: linear-gradient(0deg, transparent, var(--color-background2), transparent);
}

.quiz {}

.quiz h2 {}

.quiz-wrapper {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.quiz-wrapper>* {
    margin-top: 24px;
}

.quiz-author {
    display: flex;
    align-items: center;
}

.quiz-author--guest {
    align-self: flex-end;
}

.quiz-wrapper>*+.quiz-author {
    margin-top: 36px;
}

.quiz-author__avatar {
    background: #fff;
    --size: 70px;
    width: var(--size);
    height: var(--size);
    border-radius: 50%;
    overflow: hidden;
    margin: 0 10px 0 0;
    box-shadow: 2px 2px 10px rgb(167 96 244 / 26%);
}

.quiz-author__avatar img {
    display: block;
    width: 100%;
}

.quiz-author__content {}

.quiz-author__content-name {
    font-size: 1.2rem;
    font-weight: 600;
    margin: 0 0 4px 0;
}

.quiz-author__content-post {}

.quiz-quest {
    line-height: 150%;
}

.quiz-answer {
    line-height: 150%;
    align-self: flex-end;
}

.quiz-card-outer {
    display: flex;
    width: 100%;
}

.quiz-card {
    background: var(--color-white);
    -webkit-box-shadow: 0 5px 47px rgba(119, 96, 255, .1);
    box-shadow: 0 5px 47px rgba(119, 96, 255, .1);
    border-radius: 40px;
    padding: 12px 24px;
    animation: 0.4s ease-in-out alternate new-message;
}

@keyframes new-message {
    0% {
        transform: translateX(-5%);
        opacity: 0;
    }

    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

.quiz-card--invert {
    background: var(--color-accent-primary);
    color: #fff;
    margin: 0 0 0 auto;
}

.quiz-sending {
    display: flex;
    align-items: center;
    line-height: 150%;
}

.quiz-sending span {
    margin: 0 6px 0 0;
}

.quiz-sending-dots {
    display: flex;
    gap: 0 6px;
    align-items: center;
    animation: 0.4s ease-in-out alternate new-message;
}

.quiz-sending__dot {
    background: var(--color-accent-primary);
    width: 12px;
    height: 12px;
    border-radius: 50%;
    transform: scale(0);
    animation: 0.4s ease-in-out infinite alternate scale-dots;
}

.quiz-sending__dot:nth-child(2) {
    animation-delay: 0.2s;
}

.quiz-sending__dot:nth-child(3) {
    animation-delay: 0.4s;
}

.quiz-popup {
    background: var(--color-white);
    -webkit-box-shadow: 0 5px 47px rgba(119, 96, 255, .1);
    box-shadow: 0 5px 47px rgba(119, 96, 255, .1);
    position: fixed;
    left: 0;
    bottom: 0;
    z-index: 9999999;
    padding: 24px 12px 24px 24px;
    width: 420px;
    border-radius: 0 20px 0 0;
}

.quiz-popup-inner {
    height: 540px;
    overflow: auto;
    padding: 0 12px 0 0;
}

.quiz-popup-inner::-webkit-scrollbar {
    width: 4px;
}

.quiz-popup-inner::-webkit-scrollbar-track {
    background-color: white;
}

.quiz-popup-inner::-webkit-scrollbar-thumb {
    background: rgb(115 92 255);
    border-radius: 2px;
}

@keyframes scale-dots {
    0% {
        transform: scale(0);
    }

    100% {
        transform: scale(1);
    }
}

.quiz-radio,
.quiz-checkbox {}

.calculator__radio label span {
    line-height: 22px;
}

.quiz__container .calculator__checkbox label {
    line-height: 22px;
}

.quiz-checkbox .callback-calculator__button {
    cursor: pointer;
    margin: 24px 0 0 0;
}

.quiz:not(.can-send) .callback-calculator {
    display: none;
}

.quiz .callback-calculator {
    margin: 48px 0 0 0;
}

.quiz .callback-calculator__form {
    margin: 0 auto;
    text-align: center;
    flex: 0 1 792px;
}

.quiz-close {
    position: absolute;
    display: block;
    top: 12px;
    right: 12px;
    fill: #735cff;
    cursor: pointer;
    background: #fff;
    border-radius: 50%;
}

.section-quiz:not(.section-quiz--fixed) .quiz-close {
    display: none;
}

.quiz-close svg {
    display: block;
    width: 18px;
    height: 18px;
}

.quiz-close__text {
    display: none;
    position: relative;
}

.quiz-close__text:after {
    content: "";
    position: absolute;
    top: 4px;
    right: -20px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #0f0;
    animation: 1s cubic-bezier(0.4, 0, 1, 1) infinite online-consult;
}

.section-quiz--fixed-hidden .quiz-close__text {
    display: inline-block;
    height: 18px;
    font-weight: 600;
}

@keyframes online-consult {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 #0f06;
    }

    70% {
        transform: scale(1);
        box-shadow: 0 0 0 10px rgba(0, 0, 0, 0);
    }

    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(0, 0, 0, 0);
    }
}

.section-quiz--fixed-hidden svg {
    display: none;
}

.section-quiz--fixed-hidden .quiz-close {
    left: 12px;
    right: unset;
    width: 100%;
    text-align: center;
    padding: 0 20px 0 0;
}

/*--- FIXED ---*/
@media (min-width: 1280px) {
    .section-quiz--fixed .quiz__container {
        padding: 38px 12px 24px 24px;
        max-width: unset;
        position: fixed;
        left: 0;
        bottom: 0;
        z-index: 99999;
        width: 310px;
        background: var(--color-white);
        -webkit-box-shadow: 0 5px 47px rgba(119, 96, 255, .1);
        box-shadow: 0 5px 47px rgba(119, 96, 255, .1);
        border-radius: 0 20px 0 0;
        animation: 0.15s ease-in-out alternate show-popup-quiz;
        transition: 0.15s;
    }

    .section-quiz--fixed .quiz {
        height: 420px;
        overflow: auto;
        padding: 0 12px 0 0;
    }

    @keyframes show-popup-quiz {
        0% {
            transform: translateX(-120%);
        }

        100% {
            transform: translateX(0);
        }
    }

    .section-quiz--fixed-hidden .quiz__container {

        transform: translateY(444px);
    }

    .section-quiz--fixed .quiz::-webkit-scrollbar {
        width: 4px;
    }

    .section-quiz--fixed .quiz::-webkit-scrollbar-track {
        background-color: white;
    }

    .section-quiz--fixed .quiz::-webkit-scrollbar-thumb {
        background: rgb(115 92 255);
        border-radius: 2px;
    }

    .section-quiz--fixed .quiz-radio,
    .section-quiz--fixed .quiz-checkbox {
        padding: 24px;
        min-width: 100%;
    }

    .section-quiz--fixed .calculator__callback {
        padding: 24px;
    }

    .section-quiz--fixed .callback-calculator__box {
        display: block;
    }

    .section-quiz--fixed .callback-calculator__box>* {
        width: 100%;
        margin: 10px 0 0 0;
        max-width: unset;
    }

    .section-quiz--fixed .quiz-author__avatar {
        --size: 50px;
    }

    .section-quiz--fixed .quiz-author__content-name {
        font-size: 1rem;
    }

    .section-quiz--fixed .quiz-author__content-post {
        font-size: 14px;
    }

    .section-quiz--fixed .quiz-card {
        font-size: 14px;
    }

    .section-quiz--fixed .calculator__radio label span {
        font-size: 14px;
        line-height: 22px;
    }

    .section-quiz--fixed .checkbox__label>span {
        font-size: 14px;
    }

    .section-quiz--fixed .callback-calculator__input input {
        font-size: 14px;
    }

    .section-quiz--fixed .callback-calculator__button {
        font-size: 14px;
    }
}

@media (max-width: 1279px) {
    .section-quiz--fixed {
        height: auto !important;
    }
}

@media (max-width: 767px) {

    .quiz-radio,
    .quiz-checkbox {
        width: 100%;
    }

    .quiz .callback-calculator__box {
        flex-wrap: wrap;
    }

    .quiz .callback-calculator__box>* {
        width: 100%;
        flex: 100%;
        max-width: unset;
        margin-right: 0;
    }

    .quiz .callback-calculator__box>*+* {
        margin-top: 24px;
    }
}

/****************************
* Dizayner Yoqubov Shaxzod  *
*  Tel: + 99 894 588-56-56  *
*   Tg: @Yoqubov_Shaxzod    *
*      Site: yoqubov.uz     *
****************************/