@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&family=Noto+Serif:wght@600;700&display=swap');

:root {
    --service-bg: #090416;
    --service-bg-soft: #18062b;
    --service-card: #f7eef5;
    --service-purple: #4c176c;
    --service-purple-dark: #271039;
    --service-pink: #f04aa4;
    --service-gold: #f2c14e;
    --service-white: #fff8ff;
}

body.service-quiz-open {
    overflow: hidden;
}

.service-quiz-modal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 18px;
    font-family: Manrope, sans-serif;
}

.service-quiz-modal.is-open {
    display: flex;
}

.service-quiz-modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(4, 1, 10, .88);
    backdrop-filter: blur(10px);
}

.service-quiz-shell {
    position: relative;
    z-index: 2;
    width: min(470px, 100%);
    max-height: calc(100vh - 36px);
    overflow-y: auto;
    border: 1px solid rgba(240, 74, 164, .35);
    border-radius: 28px;
    padding: 34px 26px 28px;
    color: var(--service-white);
    background:
        radial-gradient(circle at 84% 8%, rgba(240, 74, 164, .18), transparent 30%),
        radial-gradient(circle at 12% 86%, rgba(92, 34, 132, .35), transparent 35%),
        linear-gradient(180deg, #12071f 0%, #090416 100%);
    box-shadow: 0 30px 90px rgba(0, 0, 0, .62);
}

.service-quiz-shell::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: .24;
    background-image: radial-gradient(circle, #f5b8df 1px, transparent 1px);
    background-size: 42px 42px;
    mask-image: linear-gradient(to bottom, black, transparent 70%);
}

.service-quiz-close {
    position: absolute;
    top: 12px;
    right: 16px;
    z-index: 5;
    border: 0;
    padding: 4px;
    color: #fff;
    background: transparent;
    font-size: 31px;
    line-height: 1;
    cursor: pointer;
}

.service-quiz-progress {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 7px auto 26px;
}

.service-quiz-progress span {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 32px;
    width: 32px;
    height: 32px;
    border: 2px solid #d8b5d0;
    border-radius: 50%;
    background: rgba(36, 16, 47, .92);
    box-shadow: inset 0 0 0 4px rgba(255,255,255,.02);
    transition: border-color .25s ease, box-shadow .25s ease, background .25s ease;
}

.service-quiz-progress span b {
    display: block;
    width: 8px;
    height: 8px;
    margin: 0;
    border-radius: 50%;
    background: #24102f;
    box-shadow: 0 0 0 1px rgba(255,255,255,.05);
    transition: .25s ease;
}

.service-quiz-progress span.is-active {
    border-color: var(--service-gold);
    background: #2b1137;
    box-shadow: 0 0 0 5px rgba(242, 193, 78, .12), 0 0 22px rgba(242, 193, 78, .72), inset 0 0 12px rgba(242,193,78,.08);
}

.service-quiz-progress span.is-active b {
    width: 10px;
    height: 10px;
    background: var(--service-gold);
    box-shadow: 0 0 10px rgba(242,193,78,.95);
}

.service-quiz-progress span.is-complete {
    border-color: #e59dcc;
    background: #371543;
}

.service-quiz-progress span.is-complete b {
    background: #e59dcc;
}

.service-quiz-progress i {
    flex: 1 1 52px;
    max-width: 58px;
    min-width: 34px;
    height: 2px;
    margin: 0 2px;
    background: linear-gradient(90deg, rgba(242,193,78,.95), rgba(229,157,204,.9));
    box-shadow: 0 0 8px rgba(229,157,204,.22);
}

.service-quiz-slide {
    position: relative;
    z-index: 2;
    display: none;
}

.service-quiz-slide.is-active {
    display: block;
    animation: service-slide-in .28s ease;
}

@keyframes service-slide-in {
    from { opacity: 0; transform: translateX(12px); }
    to { opacity: 1; transform: translateX(0); }
}

.service-quiz-slide h2 {
    margin: 0 0 24px;
    text-align: center;
    color: #fff;
    font-family: 'Noto Serif', Georgia, serif;
    font-size: 22px;
    line-height: 1.28;
    font-weight: 700;
}

.service-quiz-options {
    overflow: hidden;
    border-radius: 20px;
    background: var(--service-card);
    box-shadow: 0 14px 34px rgba(0, 0, 0, .28);
}

.service-quiz-option {
    display: grid;
    grid-template-columns: 58px 1fr;
    align-items: center;
    width: 100%;
    min-height: 65px;
    border: 0;
    border-bottom: 1px solid #c7b9c2;
    padding: 8px 18px;
    color: #1d1620;
    background: #faf3f7;
    text-align: left;
    cursor: pointer;
    transition: .18s ease;
}

.service-quiz-option:last-child {
    border-bottom: 0;
}

.service-quiz-option__visual {
    display:flex;align-items:center;justify-content:center;width:42px;height:42px;font-size:30px;line-height:1;
}
.service-quiz-option__visual img,.service-quiz-option__visual svg{display:block;max-width:40px;max-height:40px;width:auto;height:auto}

.service-quiz-option strong {
    font-size: 15px;
    line-height: 1.3;
    font-weight: 800;
}

.service-quiz-option:hover,
.service-quiz-option.is-selected {
    background: linear-gradient(90deg, #fff8fb, #f5dff0);
    box-shadow: inset 5px 0 0 var(--service-pink);
}

.service-quiz-option.is-selected strong {
    color: #7b195d;
}

.service-quiz-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-top: 28px;
}

.service-quiz-actions.is-single {
    grid-template-columns: minmax(170px, 230px);
    justify-content: center;
}

.service-quiz-actions button,
.service-quiz-restart {
    min-height: 52px;
    border: 1px solid #6f397e;
    border-radius: 10px;
    padding: 12px 18px;
    color: #fff;
    background: #12081e;
    font-weight: 800;
    cursor: pointer;
}

.service-quiz-actions .service-quiz-next {
    border-color: #743a87;
    background: linear-gradient(135deg, #35134e, #5f1e7f);
    box-shadow: 0 9px 26px rgba(84, 22, 112, .38);
}

.service-quiz-actions button:hover,
.service-quiz-restart:hover {
    transform: translateY(-1px);
    filter: brightness(1.12);
}

.service-quiz-form.is-loading {
    opacity: .72;
    pointer-events: none;
}

.service-quiz-message {
    display: none;
    position: relative;
    z-index: 2;
    margin: 15px 0 0;
    color: #ffc5e5;
    text-align: center;
    font-size: 13px;
}

.service-quiz-message.is-visible {
    display: block;
}

.service-quiz-result {
    text-align: center;
}

.service-result-image-wrap {
    position: relative;
    display: grid;
    place-items: center;
    min-height: 205px;
    margin: 0 -26px 15px;
    background:
        radial-gradient(circle at center, rgba(240, 74, 164, .26), transparent 58%),
        linear-gradient(180deg, rgba(64, 18, 75, .45), rgba(9, 4, 22, .12));
}

.service-result-image {
    display: block;
    width: 220px;
    max-height: 190px;
    object-fit: contain;
    filter: drop-shadow(0 15px 24px rgba(0, 0, 0, .42));
}

.service-result-title {
    margin: 4px 0 10px;
    color: #fff;
    font-family: 'Noto Serif', Georgia, serif;
    font-size: 20px;
}

.service-result-description {
    margin: 0 auto 18px;
    max-width: 350px;
    color: #eee3f2;
    font-size: 15px;
    line-height: 1.65;
}

.service-result-benefits {
    display: inline-grid;
    gap: 9px;
    margin: 0 auto 22px;
    padding: 0;
    list-style: none;
    text-align: left;
}

.service-result-benefits li {
    position: relative;
    padding-left: 25px;
    color: #fff;
    font-size: 14px;
}

.service-result-benefits li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--service-gold);
}

.service-result-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 54px;
    border-radius: 8px;
    color: #24120a;
    background: linear-gradient(180deg, #ffd875, #eba83c);
    box-shadow: 0 10px 28px rgba(242, 193, 78, .25);
    text-decoration: none;
    font-weight: 900;
}

.service-quiz-restart {
    width: 100%;
    margin-top: 13px;
    border-color: #bb8a24;
    color: #f1c449;
}

@media (max-width: 767px) {
    .service-quiz-modal {
        padding: 0;
        align-items: stretch;
    }

    .service-quiz-shell {
        width: 100%;
        max-height: 100vh;
        min-height: 100vh;
        border: 0;
        border-radius: 0;
        padding: 28px 18px 22px;
    }

    .service-quiz-progress {
        margin-top: 18px;
    }

    .service-quiz-progress i {
        width: clamp(34px, 12vw, 52px);
    }

    .service-quiz-slide h2 {
        font-size: 22px;
        margin-bottom: 20px;
    }

    .service-quiz-option {
        grid-template-columns: 52px 1fr;
        min-height: 63px;
        padding: 8px 15px;
    }

    .service-quiz-option__visual {font-size:27px;width:38px;height:38px;}

    .service-quiz-actions {
        position: sticky;
        bottom: 0;
        padding-top: 18px;
        background: linear-gradient(180deg, transparent, #090416 30%);
    }
}
