.nps-widget,
.nps-widget * {
    box-sizing: border-box;
}

.nps-widget[hidden],
.nps-widget [hidden] {
    display: none !important;
}

.nps-widget {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 9999;
    width: min(700px, calc(100vw - 48px));
    font-family: "Manrope", Arial, sans-serif;
    opacity: 0;
    visibility: hidden;
    transform: translateY(18px);
    transition: opacity .25s ease, transform .25s ease, visibility .25s ease;
}

.nps-widget.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nps-widget__panel {
    position: relative;
    min-height: 225px;
    overflow: hidden;
    padding: 24px 160px 24px 24px;
    border: 1px solid rgba(0, 0, 0, .04);
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .12), 0 0 2px rgba(0, 0, 0, .15);
}

.nps-widget__close {
    position: absolute;
    top: 24px;
    right: 24px;
    z-index: 3;
    display: flex;
    width: 36px;
    height: 36px;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 1px solid #BDBDBD;
    border-radius: 50%;
    background: transparent;
    color: #BDBDBD;
    font: 300 28px/1 Arial, sans-serif;
    cursor: pointer;
    transition: color .2s ease, border-color .2s ease, background-color .2s ease;
}

.nps-widget__close:hover {
    border-color: #FF6B35;

    color: #FF6B35;
    outline: none;
}

.nps-widget__content {
    position: relative;
    z-index: 2;
}

.nps-widget__title {
    max-width: 516px;
    margin: 0 0 32px;
    color: #000;
    font-size: 22px;
    font-weight: 700;
    line-height: 1.23;
    letter-spacing: -.4px;
}

.nps-widget__ratings {
    display: flex;
    flex-wrap: nowrap;
    gap: 12px;
}

.nps-widget__rating {
    display: flex;
    flex: 0 0 36px;
    width: 36px;
    height: 36px;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 1px solid #f2f3f5;
    border-radius: 50%;
    background: #f2f3f5;
    color: #000;
    font: 500 18px/1.2 "Manrope", Arial, sans-serif;
    cursor: pointer;
    transition: color .2s ease, border-color .2s ease, background-color .2s ease;
}

.nps-widget__rating:hover,
.nps-widget__rating:focus-visible,
.nps-widget__rating.is-selected {
    border-color: #ff6b35;
    background: #ff6b35;
    color: #fff;
    outline: none;
}

.nps-widget__rating:disabled {
    cursor: default;
    opacity: .7;
}

.nps-widget__labels {
    display: flex;
    max-width: 516px;
    justify-content: space-between;
    margin-top: 8px;
    color: rgba(0, 0, 0, .4);
    font-size: 15px;
    font-weight: 500;
    line-height: 18px;
}

.nps-widget__labels span:last-child {
    text-align: right;
}

.nps-widget__submit {
    display: none;
}

.nps-widget__error {
    margin: 8px 0 0;
    color: #b42318;
    font-size: 13px;
    line-height: 18px;
}

.nps-widget__desktop-image {
    position: absolute;
    top: 0;
    right: 0;
    z-index: 1;
    width: 136px;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
}

.nps-widget__desktop-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.nps-widget__mobile-image {
    display: none;
}

.nps-widget__thanks {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #000;
    text-align: left;
}

.nps-widget__thanks-image {
    flex: 0 0 72px;
    width: 72px;
    height: 52px;
    object-fit: contain;
}

.nps-widget__thanks-text {
    display: flex;
    min-width: 0;
    flex-direction: column;
}

.nps-widget__thanks strong {
    font-size: 17px;
    font-weight: 600;
    line-height: 1.3;
}

.nps-widget__thanks span {
    margin-top: 3px;
    color: rgba(0, 0, 0, .52);
    font-size: 13px;
    line-height: 1.4;
}

@media (max-width: 767.98px) {
    .nps-widget {
        right: auto;
        bottom: 12px;
        left: 50%;
        width: min(328px, calc(100vw - 24px));
        transform: translate(-50%, 18px);
    }

    .nps-widget.is-visible {
        transform: translate(-50%, 0);
    }

    .nps-widget__panel {
        min-height: 494px;
        padding: 24px;
        border: 0;
        border-radius: 24px;
    }

    .nps-widget__close {
        top: 24px;
        right: 24px;
    }

    .nps-widget__mobile-image {
        display: block;
        width: 186px;
        height: 124px;
        margin: 0 auto 10px;
    }

    .nps-widget__mobile-image img {
        width: 100%;
        height: 100%;
        object-fit: contain;
    }

    .nps-widget__title {
        margin: 0 0 24px;
        padding: 0;
        font-size: 22px;
        line-height: 27px;
        text-align: center;
    }

    .nps-widget__ratings {
        max-width: 280px;
        justify-content: center;
        flex-wrap:wrap;
        gap: 10px;
        margin: 0 auto;
    }

    .nps-widget__labels {
        max-width: 280px;
        margin: 14px auto 0;
        font-size: 14px;
    }

    .nps-widget__submit {
        display: flex;
        width: 100%;
        height: 43px;
        align-items: center;
        justify-content: center;
        margin-top: 32px;
        padding: 10px;
        border: 0;
        border-radius: 15px;
        background: #ff6b35;
        color: #fff;
        font: 600 14px/22px "Manrope", Arial, sans-serif;
        cursor: pointer;
        transition: opacity .2s ease, background-color .2s ease;
    }

    .nps-widget__submit:hover,
    .nps-widget__submit:focus-visible {
        background: #e85a27;
        outline: none;
    }

    .nps-widget__submit:disabled {
        cursor: default;
        opacity: .45;
    }

    .nps-widget__error {
        text-align: center;
    }

    .nps-widget__desktop-image {
        display: none;
    }
}

@media (max-width: 359.98px) {
    .nps-widget {
        bottom: 8px;
        width: calc(100vw - 16px);
    }

    .nps-widget__panel {
        padding-right: 18px;
        padding-left: 18px;
    }

    .nps-widget__ratings {
        gap: 8px;
    }
}

.nps-widget.is-thanks {
    width: min(360px, calc(100vw - 48px));
}

.nps-widget.is-thanks .nps-widget__panel {
    min-height: 0;
    padding: 16px 52px 16px 18px;
    border-radius: 16px;
}

.nps-widget.is-thanks .nps-widget__close {
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    font-size: 24px;
}

@media (max-width: 767.98px) {
    .nps-widget.is-thanks {
        width: min(328px, calc(100vw - 24px));
    }

    .nps-widget.is-thanks .nps-widget__panel {
        min-height: 0;
        padding: 16px 48px 16px 16px;
        border-radius: 16px;
    }

    .nps-widget__thanks-image {
        flex-basis: 64px;
        width: 64px;
        height: 48px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .nps-widget,
    .nps-widget__rating,
    .nps-widget__close,
    .nps-widget__submit {
        transition: none;
    }
}
