section.olafa-fortune.olafa-fortune {
    width: min(1180px, calc(100% - 40px));
    margin: 0 auto 88px;
    padding: 54px 0 0;
    display: block;
    background: #fff;
    color: #000;
    font-family: "regular", Onest, sans-serif;
}

.olafa-fortune *,
.olafa-fortune *::before,
.olafa-fortune *::after {
    box-sizing: border-box;
}

.olafa-fortune__head {
    max-width: 780px;
    margin: 0 auto 42px;
    text-align: center;
}

.olafa-fortune h1 {
    margin: 0 0 22px;
    color: #000;
    font-family: "regular", Onest, sans-serif;
    font-size: 64px;
    font-weight: 300;
    line-height: 1.04;
}

.olafa-fortune__lead {
    max-width: 650px;
    margin: 0 auto;
    color: #3f2e47;
    font-size: 20px;
    font-weight: 300;
    line-height: 1.55;
}

.olafa-fortune__stage {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.olafa-fortune__play {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    gap: 24px;
}

.olafa-fortune__wheel-wrap {
    position: relative;
    width: 620px;
    max-width: 100%;
    aspect-ratio: 1;
}

.olafa-fortune__pointer {
    position: absolute;
    z-index: 4;
    left: 50%;
    top: 0;
    width: 42px;
    height: 58px;
    transform: translateX(-50%);
    background: #270042;
    clip-path: polygon(50% 100%, 0 0, 100% 0);
}

.olafa-fortune__wheel {
    position: absolute;
    z-index: 1;
    inset: 22px;
    border-radius: 50%;
    background: var(--wheel-gradient);
    box-shadow:
        0 24px 72px rgba(63, 46, 71, .16),
        inset 0 0 0 16px #fff,
        inset 0 0 0 17px rgba(96, 77, 105, .16);
    transform: rotate(var(--wheel-rotation, 0deg));
    transition: transform 4.4s cubic-bezier(.12, .7, .06, 1);
    overflow: hidden;
}

.olafa-fortune__wheel::after {
    content: "";
    position: absolute;
    inset: 18px;
    border: 1px solid rgba(255, 255, 255, .72);
    border-radius: 50%;
    pointer-events: none;
}

.olafa-fortune__wheel-labels {
    position: absolute;
    z-index: 2;
    inset: 22px;
    --wheel-label-radius-ratio: .315;
    pointer-events: none;
}

.olafa-fortune__wheel-label {
    position: absolute;
    left: 50%;
    top: 50%;
    display: grid;
    place-items: center;
    width: 136px;
    min-height: 92px;
    transform: translate(-50%, -50%);
    color: var(--sector-text-color, #270042);
    will-change: left, top;
}

.olafa-fortune__wheel-sector-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    min-height: inherit;
    color: inherit;
    font-family: "regular", Onest, sans-serif;
    text-align: center;
}

.olafa-fortune__wheel-sector-media {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .9);
    box-shadow: 0 8px 18px rgba(39, 0, 66, .12);
    color: #270042;
    font-size: 15px;
    font-weight: 700;
    line-height: 1;
}

.olafa-fortune__wheel-sector-media img {
    display: block;
    width: 28px;
    height: 28px;
    object-fit: contain;
    transform: none;
}

.olafa-fortune__wheel-sector-media_text {
    letter-spacing: 0;
}

.olafa-fortune__wheel-sector-label {
    display: block;
    max-width: 100%;
    color: inherit;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.13;
    overflow-wrap: anywhere;
    text-shadow: 0 1px 12px rgba(255, 255, 255, .18);
}

.olafa-fortune__wheel-center {
    position: absolute;
    z-index: 3;
    left: 50%;
    top: 50%;
    display: grid;
    place-items: center;
    width: 142px;
    height: 142px;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 16px 34px rgba(63, 46, 71, .16);
    color: #270042;
    font-family: "regular", Onest, sans-serif;
    font-size: 26px;
    font-weight: 300;
    line-height: 1;
    text-transform: uppercase;
}

.olafa-fortune__spin,
.olafa-fortune__result-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 238px;
    min-height: 46px;
    padding: 10px 24px;
    border: 1px solid transparent;
    border-radius: 999px;
    background-color: #604d69;
    background-image: linear-gradient(90deg, #4776e6 0%, #8e54e9 100%);
    color: #fff;
    font-family: "regular", Onest, sans-serif;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.25;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: opacity .2s ease, transform .2s ease;
}

.olafa-fortune__spin:hover,
.olafa-fortune__result-button:hover {
    color: #fff;
    opacity: .88;
    text-decoration: none;
}

.olafa-fortune__spin:active,
.olafa-fortune__result-button:active {
    transform: translateY(1px);
}

.olafa-fortune__spin:disabled {
    cursor: default;
    opacity: .58;
    transform: none;
}

.olafa-fortune__status {
    min-height: 22px;
    color: #604d69;
    font-size: 15px;
    font-weight: 300;
    line-height: 1.45;
    text-align: center;
}

.olafa-fortune__status.is-error {
    color: #9b3042;
}

.olafa-fortune__result {
    width: min(760px, 100%);
    margin: 30px auto 0;
    padding: 30px;
    border: 1px solid #eadfed;
    border-radius: 8px;
    background: #f9f4f5;
    color: #000;
    text-align: center;
}

.olafa-fortune__result[hidden] {
    display: none;
}

.olafa-fortune__result h2 {
    margin: 0 0 16px;
    color: #270042;
    font-family: "regular", Onest, sans-serif;
    font-size: 30px;
    font-weight: 300;
    line-height: 1.2;
}

.olafa-fortune__result p {
    margin: 0;
    color: #3f2e47;
    font-size: 17px;
    font-weight: 300;
    line-height: 1.55;
}

.olafa-fortune__coupon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 22px 0 0;
    padding: 12px 18px;
    border: 1px solid #dfd0e4;
    border-radius: 999px;
    background: #fff;
    color: #270042;
    font-size: 17px;
    font-weight: 300;
    line-height: 1.35;
}

.olafa-fortune__coupon strong {
    margin-left: 6px;
    font-weight: 700;
}

.olafa-fortune__terms {
    max-width: 660px;
    margin: 22px auto 0 !important;
    color: #604d69 !important;
    font-size: 14px !important;
    font-weight: 300 !important;
    line-height: 1.55 !important;
}

.olafa-fortune__result-button {
    margin-top: 24px;
}

.olafa-fortune__sectors {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin: 42px 0 0;
}

.olafa-fortune__sector {
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    min-height: 76px;
    padding: 15px 16px;
    border: 1px solid #eadfed;
    border-radius: 8px;
    background: #fff;
}

.olafa-fortune__sector-visual {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border: 2px solid var(--sector-color);
    border-radius: 50%;
    background: #fff;
    color: #270042;
    font-size: 15px;
    font-weight: 700;
    line-height: 1;
}

.olafa-fortune__sector-visual img {
    display: block;
    width: 26px;
    height: 26px;
    object-fit: contain;
}

.olafa-fortune__sector-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    color: #000;
    font-size: 15px;
    font-weight: 300;
    line-height: 1.35;
}

.olafa-fortune__sector-text small {
    color: #927c9c;
    font-size: 13px;
    font-weight: 300;
    line-height: 1.25;
}

.olafa-fortune__note {
    max-width: 860px;
    margin: 28px auto 0;
    color: #604d69;
    font-size: 15px;
    font-weight: 300;
    line-height: 1.55;
    text-align: center;
}

.olafa-fortune__promotion a {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.olafa-fortune__history {
    width: 100%;
    margin: 46px auto 0;
    padding-top: 34px;
    border-top: 1px solid #eadfed;
}

.olafa-fortune__history-head {
    max-width: 680px;
    margin: 0 auto 24px;
    text-align: center;
}

.olafa-fortune__history-head h2 {
    margin: 0 0 10px;
    color: #270042;
    font-family: "regular", Onest, sans-serif;
    font-size: 34px;
    font-weight: 300;
    line-height: 1.18;
}

.olafa-fortune__history-head p,
.olafa-fortune__history-empty {
    margin: 0;
    color: #604d69;
    font-size: 15px;
    font-weight: 300;
    line-height: 1.55;
}

.olafa-fortune__history-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.olafa-fortune__history-list[hidden],
.olafa-fortune__history-empty[hidden] {
    display: none;
}

.olafa-fortune__history-item {
    display: grid;
    grid-template-rows: auto auto 1fr auto;
    gap: 12px;
    min-height: 190px;
    padding: 22px;
    border: 1px solid #eadfed;
    border-radius: 8px;
    background: #fff;
    color: #000;
}

.olafa-fortune__history-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.olafa-fortune__history-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 5px 10px;
    border: 1px solid #eadfed;
    border-radius: 999px;
    background: #f9f4f5;
    color: #604d69;
    font-size: 13px;
    font-weight: 300;
    line-height: 1.25;
}

.olafa-fortune__history-item h3 {
    margin: 0;
    color: #270042;
    font-family: "regular", Onest, sans-serif;
    font-size: 22px;
    font-weight: 300;
    line-height: 1.25;
}

.olafa-fortune__history-coupon {
    align-self: start;
    color: #3f2e47;
    font-size: 15px;
    font-weight: 300;
    line-height: 1.45;
}

.olafa-fortune__history-coupon strong {
    font-weight: 700;
}

.olafa-fortune__history-link {
    justify-self: start;
    align-self: end;
    color: #604d69;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.35;
    text-decoration: underline;
    text-underline-offset: 4px;
}

.olafa-fortune__history-link:hover {
    color: #270042;
}

.olafa-fortune__history-empty {
    max-width: 680px;
    margin: 0 auto;
    padding: 20px;
    border: 1px solid #eadfed;
    border-radius: 8px;
    background: #f9f4f5;
    text-align: center;
}

.olafa-fortune__admin {
    max-width: 860px;
    margin: 24px auto 0;
    color: #604d69;
    font-size: 13px;
    font-weight: 300;
    line-height: 1.45;
    text-align: center;
}

.olafa-fortune__admin p {
    margin: 0 0 10px;
    color: #604d69;
    font-size: 13px;
    font-weight: 300;
    line-height: 1.45;
}

.olafa-fortune__admin-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 14px;
}

.olafa-fortune__admin a {
    color: #604d69;
    font-size: 13px;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.olafa-fortune__admin a:hover {
    color: #270042;
}

.olafa-fortune__message {
    margin: 48px 0 0;
    padding: 22px;
    border-radius: 8px;
    background: #f9f4f5;
    color: #3f2e47;
    font-size: 16px;
    font-weight: 300;
    line-height: 1.5;
}

.olafa-fortune__message_error {
    border: 1px solid rgba(155, 48, 66, .28);
    color: #9b3042;
}

@media (max-width: 1080px) {
    section.olafa-fortune.olafa-fortune {
        padding-top: 42px;
    }

    .olafa-fortune h1 {
        font-size: 48px;
    }

    .olafa-fortune__wheel-wrap {
        width: 540px;
    }

    .olafa-fortune__sectors {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    section.olafa-fortune.olafa-fortune {
        width: calc(100% - 24px);
        margin-bottom: 56px;
        padding-top: 32px;
    }

    .olafa-fortune__head {
        margin-bottom: 30px;
        text-align: left;
    }

    .olafa-fortune h1 {
        margin-bottom: 16px;
        font-size: 34px;
        line-height: 1.08;
    }

    .olafa-fortune__lead {
        font-size: 17px;
        line-height: 1.5;
    }

    .olafa-fortune__wheel-wrap {
        width: 350px;
    }

    .olafa-fortune__pointer {
        width: 32px;
        height: 44px;
    }

    .olafa-fortune__wheel {
        inset: 13px;
        box-shadow:
            0 18px 48px rgba(63, 46, 71, .14),
            inset 0 0 0 10px #fff,
            inset 0 0 0 11px rgba(96, 77, 105, .16);
    }

    .olafa-fortune__wheel::after {
        inset: 12px;
    }

    .olafa-fortune__wheel-labels {
        inset: 13px;
        --wheel-label-radius-ratio: .31;
    }

    .olafa-fortune__wheel-label {
        width: 86px;
        min-height: 64px;
    }

    .olafa-fortune__wheel-center {
        width: 96px;
        height: 96px;
        font-size: 19px;
    }

    .olafa-fortune__wheel-sector-content {
        gap: 5px;
    }

    .olafa-fortune__wheel-sector-media {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }

    .olafa-fortune__wheel-sector-media img {
        width: 20px;
        height: 20px;
    }

    .olafa-fortune__wheel-sector-label {
        font-size: 10px;
        line-height: 1.08;
    }

    .olafa-fortune__spin,
    .olafa-fortune__result-button {
        width: 100%;
        min-width: 0;
        font-size: 16px;
    }

    .olafa-fortune__result {
        padding: 24px 18px;
        text-align: left;
    }

    .olafa-fortune__result h2 {
        font-size: 24px;
    }

    .olafa-fortune__result p {
        font-size: 16px;
    }

    .olafa-fortune__coupon {
        width: 100%;
        border-radius: 8px;
        font-size: 16px;
    }

    .olafa-fortune__sectors {
        grid-template-columns: 1fr;
        margin-top: 34px;
    }

    .olafa-fortune__sector {
        min-height: 68px;
    }

    .olafa-fortune__note {
        text-align: left;
    }

    .olafa-fortune__history {
        margin-top: 36px;
        padding-top: 28px;
    }

    .olafa-fortune__history-head {
        text-align: left;
    }

    .olafa-fortune__history-head h2 {
        font-size: 26px;
    }

    .olafa-fortune__history-list {
        grid-template-columns: 1fr;
    }

    .olafa-fortune__history-item {
        min-height: 0;
        padding: 18px;
    }

    .olafa-fortune__history-meta span {
        border-radius: 8px;
    }

    .olafa-fortune__history-empty {
        text-align: left;
    }
}
