.th-prp-overlay,
.th-prp-overlay * {
    box-sizing: border-box;
}

.th-prp-overlay {
    position: fixed;
    inset: 0;
    z-index: 2147483000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px;
    background: rgba(5, 13, 31, 0.72);
    opacity: 0;
    visibility: hidden;
    transition: opacity 180ms ease, visibility 180ms ease;
    font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

.th-prp-overlay.th-prp-open {
    opacity: 1;
    visibility: visible;
}

html.th-prp-lock,
body.th-prp-lock {
    overflow: hidden !important;
}

.th-prp-modal {
    position: relative;
    width: min(474px, calc(100vw - 28px));
    max-height: calc(100dvh - 28px);
    overflow: auto;
    padding: 28px 29px 20px;
    border: 1px solid rgba(217, 225, 239, 0.98);
    border-radius: 19px;
    background:
        radial-gradient(circle at 83% 13%, rgba(235, 241, 255, 0.96), transparent 28%),
        #ffffff;
    color: #071633;
    box-shadow: 0 26px 72px rgba(3, 10, 28, 0.34);
    transform: translateY(12px) scale(0.986);
    transition: transform 200ms ease;
    scrollbar-width: thin;
    isolation: isolate;
}

.th-prp-overlay.th-prp-open .th-prp-modal {
    transform: translateY(0) scale(1);
}

.th-prp-modal:focus {
    outline: none;
}

.th-prp-close {
    position: absolute;
    z-index: 5;
    top: 17px;
    right: 18px;
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: #f0f3f9;
    color: #07142e;
    cursor: pointer;
    appearance: none;
    box-shadow: none;
    transition: background 150ms ease, transform 150ms ease;
}

.th-prp-close:hover {
    background: #e6ebf4;
    transform: scale(1.04);
}

.th-prp-close:focus-visible,
.th-prp-upgrade:focus-visible,
.th-prp-later:focus-visible {
    outline: 3px solid rgba(38, 103, 255, 0.3);
    outline-offset: 2px;
}

.th-prp-close svg {
    display: block;
    width: 21px;
    height: 21px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-width: 2.2;
}

.th-prp-hero {
    position: relative;
    min-height: 166px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 188px;
    align-items: end;
    gap: 0;
    padding-top: 44px;
}

.th-prp-copy {
    position: relative;
    z-index: 2;
    min-width: 0;
    padding-bottom: 9px;
}

.th-prp-copy h2 {
    max-width: 250px;
    margin: 0;
    color: #071633;
    font-size: 38px;
    line-height: 1.08;
    letter-spacing: -1.35px;
    font-weight: 780;
    overflow-wrap: normal;
    word-break: normal;
}

.th-prp-art {
    position: relative;
    z-index: 1;
    min-width: 0;
    height: 166px;
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    pointer-events: none;
    user-select: none;
}

.th-prp-illustration {
    display: block !important;
    width: 188px !important;
    height: auto !important;
    max-width: none !important;
    flex: 0 0 auto;
    overflow: visible;
}

.th-prp-description {
    max-width: 100%;
    margin: 7px 0 21px;
    color: #26395d;
    font-size: 16px;
    line-height: 1.58;
    letter-spacing: -0.12px;
}

.th-prp-price {
    color: #2768f4;
    font-weight: 750;
}

.th-prp-benefits {
    overflow: hidden;
    margin: 0 0 20px;
    border: 1px solid #dfe6f1;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.9);
}

.th-prp-benefit {
    min-height: 62px;
    display: flex;
    align-items: center;
    gap: 15px;
    margin: 0 14px;
    color: #0e1a34;
    font-size: 14px;
    line-height: 1.3;
}

.th-prp-benefit + .th-prp-benefit {
    border-top: 1px solid #e4eaf3;
}

.th-prp-benefit-text {
    min-width: 0;
    overflow-wrap: anywhere;
}

.th-prp-icon {
    flex: 0 0 40px;
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: #edf3ff;
    color: #286cf0;
}

.th-prp-icon svg {
    display: block !important;
    width: 24px !important;
    height: 24px !important;
    max-width: none !important;
    overflow: visible;
}

.th-prp-icon svg path {
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.th-prp-icon svg circle {
    fill: currentColor;
    stroke: none;
}

.th-prp-icon:last-child svg path,
.th-prp-benefit:nth-child(3) .th-prp-icon svg path {
    fill: currentColor;
    stroke: currentColor;
    stroke-width: 1;
}

.th-prp-upgrade {
    position: relative;
    width: 100%;
    min-height: 49px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 18px;
    border: 0;
    border-radius: 9px;
    background: linear-gradient(90deg, #2866ec 0%, #2d68ec 42%, #3378f6 100%);
    color: #ffffff;
    box-shadow: 0 8px 20px rgba(42, 105, 237, 0.2);
    cursor: pointer;
    appearance: none;
    font: inherit;
    font-size: 18px;
    line-height: 1.25;
    font-weight: 650;
    transition: transform 150ms ease, box-shadow 150ms ease, filter 150ms ease;
}

.th-prp-upgrade:hover {
    transform: translateY(-1px);
    box-shadow: 0 11px 24px rgba(42, 105, 237, 0.27);
    filter: saturate(1.05);
}

.th-prp-upgrade:disabled {
    cursor: wait;
    opacity: 0.9;
    transform: none;
}

.th-prp-button-lock {
    width: 19px;
    height: 19px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
}

.th-prp-button-lock svg {
    display: block;
    width: 19px;
    height: 19px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.9;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.th-prp-upgrade .th-prp-price {
    color: inherit;
    font-weight: inherit;
}

.th-prp-spinner {
    display: none;
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
    border: 2px solid rgba(255, 255, 255, 0.45);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: th-prp-spin 0.7s linear infinite;
}

.th-prp-upgrade.th-prp-loading .th-prp-button-lock {
    display: none;
}

.th-prp-upgrade.th-prp-loading .th-prp-spinner {
    display: block;
}

@keyframes th-prp-spin {
    to { transform: rotate(360deg); }
}

.th-prp-error {
    display: none;
    margin: 9px 4px 0;
    color: #c82828;
    font-size: 12px;
    line-height: 1.35;
    text-align: center;
}

.th-prp-error:not(:empty) {
    display: block;
}

.th-prp-later {
    display: block;
    margin: 14px auto 0;
    padding: 4px 10px;
    border: 0;
    background: transparent;
    color: #2a3f66;
    cursor: pointer;
    appearance: none;
    font: inherit;
    font-size: 14px;
    line-height: 1.2;
    font-weight: 500;
}

.th-prp-later:hover {
    color: #0d1b38;
    text-decoration: underline;
}

@media (max-width: 540px) {
    .th-prp-overlay {
        padding: 8px;
    }

    .th-prp-modal {
        width: min(382px, calc(100vw - 16px));
        max-height: calc(100dvh - 16px);
        padding: 20px 24px 16px;
        border-radius: 17px;
    }

    .th-prp-close {
        top: 13px;
        right: 14px;
        width: 34px;
        height: 34px;
    }

    .th-prp-close svg {
        width: 18px;
        height: 18px;
    }

    .th-prp-hero {
        min-height: 137px;
        grid-template-columns: minmax(0, 1fr) 128px;
        padding-top: 41px;
    }

    .th-prp-copy {
        padding-bottom: 6px;
    }

    .th-prp-copy h2 {
        max-width: 205px;
        font-size: 30px;
        line-height: 1.07;
        letter-spacing: -1px;
    }

    .th-prp-art {
        height: 132px;
    }

    .th-prp-illustration {
        width: 137px !important;
        transform: translateX(5px);
    }

    .th-prp-description {
        margin: 4px 0 17px;
        font-size: 13.5px;
        line-height: 1.55;
    }

    .th-prp-benefits {
        margin-bottom: 16px;
        border-radius: 10px;
    }

    .th-prp-benefit {
        min-height: 49px;
        gap: 11px;
        margin: 0 11px;
        font-size: 12px;
        line-height: 1.25;
    }

    .th-prp-icon {
        flex-basis: 33px;
        width: 33px;
        height: 33px;
        border-radius: 8px;
    }

    .th-prp-icon svg {
        width: 20px !important;
        height: 20px !important;
    }

    .th-prp-upgrade {
        min-height: 40px;
        padding: 9px 14px;
        border-radius: 8px;
        font-size: 15px;
        gap: 8px;
    }

    .th-prp-button-lock,
    .th-prp-button-lock svg {
        width: 16px;
        height: 16px;
    }

    .th-prp-later {
        margin-top: 11px;
        font-size: 12px;
        font-weight: 600;
    }
}

@media (max-width: 350px) {
    .th-prp-modal {
        padding-left: 18px;
        padding-right: 18px;
    }

    .th-prp-hero {
        grid-template-columns: minmax(0, 1fr) 112px;
    }

    .th-prp-copy h2 {
        font-size: 27px;
    }

    .th-prp-illustration {
        width: 124px !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    .th-prp-overlay,
    .th-prp-modal,
    .th-prp-close,
    .th-prp-upgrade {
        transition: none !important;
    }

    .th-prp-spinner {
        animation-duration: 1.2s;
    }
}
