.quiz {
    min-height: calc(100vh - 78px);

    padding: 48px 0 80px;

    background:
        radial-gradient(
            circle at 15% 38%,
            rgba(227, 39, 45, .045),
            transparent 26rem
        ),
        linear-gradient(
            180deg,
            #f8f9fc 0%,
            #ffffff 100%
        );
}


/* ============================================================
   HEADER
============================================================ */

.quiz__header {
    max-width: 980px;

    margin: 0 auto;

    display: flex;
    align-items: flex-end;
    justify-content: space-between;

    gap: 30px;
}


.quiz__header h1 {
    margin: 0;

    color: var(--navy);

    font-size: 32px;
    line-height: 1.15;

    letter-spacing: -.025em;
}


.quiz__subtitle {
    margin-top: 8px;

    color: var(--muted);

    font-size: 14px;
}


.quiz__counter {
    display: flex;
    align-items: baseline;

    gap: 6px;

    color: var(--muted);

    font-size: 15px;
}


.quiz__counter strong {
    color: var(--navy);

    font-size: 27px;
}


/* ============================================================
   COMPLETED FLOW STEP
============================================================ */

.learning-flow__step.is-complete {
    color: var(--navy);
}


.learning-flow__step.is-complete
.learning-flow__number {

    border-color: var(--navy);

    color: #fff;
    background: var(--navy);
}


.learning-flow__line.is-complete {
    background: var(--navy);
}


/* ============================================================
   MAIN STAGE
============================================================ */

.quiz__stage {
    max-width: 930px;

    margin: 0 auto;

    display: grid;

    grid-template-columns:
        220px
        minmax(0, 560px);

    justify-content: center;
    align-items: center;

    gap: 48px;
}


/* ============================================================
   COACH
============================================================ */

.quiz-coach {
    position: relative;

    min-height: 320px;

    display: flex;
    align-items: flex-end;
    justify-content: center;
}


.quiz-coach__avatar {
    display: block;

    width: 100%;
    max-width: 220px;
    height: auto;
}


.quiz-coach__bubble {
    position: absolute;

    top: 0;
    right: -20px;

    width: 175px;

    padding: 14px 16px;

    border: 1px solid var(--line);
    border-radius: 20px;

    background: #fff;

    box-shadow:
        0 10px 26px
        rgba(16, 33, 61, .10);

    color: var(--navy);

    font-size: 14px;
    font-weight: 700;
    line-height: 1.4;
}


.quiz-coach__bubble::after {
    content: "";

    position: absolute;

    left: 28px;
    bottom: -11px;

    width: 20px;
    height: 20px;

    background: #fff;

    border-right: 1px solid var(--line);
    border-bottom: 1px solid var(--line);

    transform: rotate(45deg);
}


/* ============================================================
   QUESTION CARD
============================================================ */

.quiz-card {
    padding: 38px 38px 32px;

    border: 1px solid var(--line);
    border-radius: 28px;

    background: #fff;

    box-shadow:
        0 24px 60px
        rgba(16, 33, 61, .12);
}


.quiz-card__label {
    color: var(--accent);

    font-size: 11px;
    font-weight: 900;

    letter-spacing: .12em;

    text-align: center;
}


.quiz-card__area {
    margin-top: 8px;

    color: var(--muted);

    font-size: 12px;
    font-weight: 700;

    text-align: center;
}


.quiz-card__definition {
    margin: 30px auto 32px;

    max-width: 480px;

    color: var(--navy);

    font-size: 21px;
    line-height: 1.55;

    text-align: center;
}


/* ============================================================
   ANSWERS
============================================================ */

.quiz-answers {
    display: grid;

    grid-template-columns:
        1fr 1fr;

    gap: 12px;
}


.quiz-answer {
    min-height: 72px;

    padding: 14px 18px;

    border: 1px solid #d7dce5;
    border-radius: 15px;

    background: #fff;

    color: var(--navy);

    cursor: pointer;

    font-size: 14px;
    font-weight: 800;
    line-height: 1.3;

    text-align: left;

    transition:
        border-color .17s ease,
        background-color .17s ease,
        transform .17s ease,
        box-shadow .17s ease;
}


.quiz-answer:hover:not(:disabled) {
    border-color: var(--accent);

    transform:
        translateY(-1px);

    box-shadow:
        0 8px 20px
        rgba(16, 33, 61, .07);
}


.quiz-answer:disabled {
    cursor: default;
}


.quiz-answer.is-correct {
    border-color: #239b56;

    background: #eefaf3;

    color: #14783e;
}


.quiz-answer.is-wrong {
    border-color: var(--accent);

    background: #fff1f1;

    color: var(--accent);
}


/* ============================================================
   FEEDBACK
============================================================ */

.quiz-feedback {
    margin-top: 20px;

    padding: 15px 18px;

    border-radius: 14px;

    text-align: center;
}


.quiz-feedback.is-correct {
    background: #eefaf3;

    color: #14783e;
}


.quiz-feedback.is-wrong {
    background: #fff1f1;

    color: #a91c22;
}


.quiz-feedback__title {
    font-weight: 900;
}


.quiz-feedback__text {
    margin-top: 3px;

    font-size: 13px;
}


.quiz-next {
    width: 100%;

    margin-top: 15px;
}


.quiz-next[hidden],
.quiz-feedback[hidden] {
    display: none !important;
}


/* ============================================================
   RESULT
============================================================ */

.quiz-result {
    max-width: 850px;

    margin: 20px auto 0;

    padding: 38px 42px;

    display: grid;

    grid-template-columns:
        240px
        minmax(0, 1fr);

    align-items: center;

    gap: 40px;

    border: 1px solid var(--line);
    border-radius: 28px;

    background: #fff;

    box-shadow:
        0 22px 55px
        rgba(16, 33, 61, .10);
}


.quiz-result[hidden] {
    display: none !important;
}


.quiz-result__avatar img {
    width: 100%;
    height: auto;
}


.quiz-result__content h2 {
    margin: 0 0 20px;

    color: var(--navy);

    font-size: 34px;
}


.quiz-result__score {
    display: flex;
    align-items: baseline;

    gap: 9px;
}


.quiz-result__score strong {
    color: var(--accent);

    font-size: 42px;
    line-height: 1;
}


.quiz-result__score span {
    color: var(--muted);

    font-size: 13px;
}


.quiz-result__content > p {
    margin: 18px 0 0;

    color: var(--muted);

    line-height: 1.6;
}


/* ============================================================
   RESULT METRICS
============================================================ */

.quiz-result__journey {
    margin: 28px 0;

    display: grid;

    grid-template-columns:
        repeat(3, 1fr);

    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}


.quiz-result__journey > div {
    padding: 16px 8px;

    text-align: center;
}


.quiz-result__journey > div + div {
    border-left: 1px solid var(--line);
}


.quiz-result__journey strong {
    display: block;

    color: var(--navy);

    font-size: 23px;
}


.quiz-result__journey span {
    color: var(--muted);

    font-size: 10px;

    text-transform: uppercase;
}


/* ============================================================
   UNLOCK CTA
============================================================ */

.quiz-result__unlock {
    padding: 22px;

    border-radius: 18px;

    background:
        rgba(227, 39, 45, .045);
}


.quiz-result__unlock h3 {
    margin: 0;

    color: var(--navy);

    font-size: 21px;
}


.quiz-result__unlock p {
    margin: 8px 0 18px;

    color: var(--muted);

    font-size: 14px;
    line-height: 1.5;
}


.quiz-result__cta {
    width: 100%;
}


.quiz-result__signin {
    margin-top: 12px;

    color: var(--muted);

    font-size: 12px;

    text-align: center;
}


.quiz-result__signin a {
    color: var(--accent);

    font-weight: 800;
}


/* ============================================================
   MISSING SESSION
============================================================ */

.quiz-missing {
    max-width: 560px;

    margin: 80px auto;

    padding: 45px;

    border: 1px solid var(--line);
    border-radius: 24px;

    background: #fff;

    text-align: center;

    box-shadow: var(--shadow);
}


.quiz-missing[hidden] {
    display: none !important;
}


.quiz-missing h2 {
    margin-top: 0;
}


.quiz-missing p {
    margin-bottom: 24px;

    color: var(--muted);
}


/* ============================================================
   MOBILE
============================================================ */

@media (max-width: 700px) {

    .quiz {
        padding:
            28px 0
            55px;
    }


    .quiz__header h1 {
        font-size: 24px;
    }


    .quiz__stage {
        display: flex;
        flex-direction: column;

        gap: 8px;
    }


    .quiz-coach {
        width: 100%;
        min-height: 130px;

        justify-content: flex-start;
    }


    .quiz-coach__avatar {
        width: 125px;
    }


    .quiz-coach__bubble {
        top: 8px;
        left: 115px;
        right: auto;

        width: 165px;
    }


    .quiz-card {
        width: 100%;

        padding: 30px 20px 24px;

        border-radius: 22px;
    }


    .quiz-card__definition {
        margin:
            24px auto
            28px;

        font-size: 18px;
    }


    .quiz-answers {
        grid-template-columns: 1fr;
    }


    .quiz-answer {
        min-height: 58px;
    }


    .quiz-result {
        padding: 28px 22px;

        display: flex;
        flex-direction: column;

        text-align: center;
    }


    .quiz-result__avatar {
        max-width: 180px;
    }


    .quiz-result__score {
        justify-content: center;
    }

}