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

.nps-survey-page {
    min-height: calc(100vh - 144px);
    min-height: calc(100dvh - 144px);
    margin-left: 0 !important;
    padding: clamp(24px, 4vw, 52px) 16px;
    background:
        radial-gradient(circle at 8% 4%, rgba(38, 160, 139, .12), transparent 27%),
        linear-gradient(180deg, #f3f9f8 0%, #f8fafb 48%, #fff 100%);
    color: #304b57;
    font-family: "Open Sans", sans-serif;
}

.nps-icon-sprite {
    position: absolute;
    overflow: hidden;
    width: 0;
    height: 0;
}

.nps-survey {
    width: min(100%, 1080px);
    margin: 0 auto;
}

.nps-survey__header {
    margin-bottom: 26px;
    text-align: center;
}

.nps-survey__eyebrow {
    margin: 0 0 7px;
    color: var(--mepso-green-dark);
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.nps-survey__header h1 {
    margin: 0;
    color: #123f5a;
    font-family: "Poppins", sans-serif;
    font-size: clamp(1.65rem, 4vw, 2.5rem);
    font-weight: 700;
    line-height: 1.2;
}

.nps-survey__context {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    justify-content: center;
    gap: 10px;
    margin-top: 18px;
}

.nps-survey__context > span {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    gap: 8px;
    padding: 9px 14px;
    border: 1px solid #d4e4e7;
    border-radius: 999px;
    background: rgba(255, 255, 255, .88);
    color: #526a73;
    font-size: .86rem;
    box-shadow: 0 5px 16px rgba(24, 88, 124, .06);
}

.nps-survey__context i {
    color: var(--mepso-green-dark);
}

.nps-survey__context strong {
    color: #18587c;
    font-weight: 700;
}

.nps-survey__context small {
    color: #6b7d84;
    font-size: .78rem;
}

.nps-survey__location-copy {
    display: inline-flex;
    min-width: 0;
    align-items: baseline;
    gap: 8px;
}

.nps-survey__form {
    margin: 0;
}

.nps-survey-alert {
    display: grid;
    overflow: hidden;
    align-items: start;
    max-height: 180px;
    padding: 15px 18px;
    margin: 0 0 18px;
    border: 1px solid;
    border-radius: 14px;
    box-shadow: 0 8px 22px rgba(24, 88, 124, .08);
    grid-template-columns: auto 1fr;
    gap: 12px;
    opacity: 1;
    transform: translateY(0);
    transition: opacity .22s ease, transform .22s ease, max-height .32s ease,
        padding .32s ease, margin .32s ease, border-width .32s ease;
}

.nps-survey-alert.is-dismissing {
    max-height: 0;
    padding-top: 0;
    padding-bottom: 0;
    margin-bottom: 0;
    border-width: 0;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-6px);
}

.nps-survey-alert > i {
    margin-top: 3px;
    font-size: 1.15rem;
}

.nps-survey-alert > span,
.nps-survey-alert strong,
.nps-survey-alert strong + span {
    display: block;
}

.nps-survey-alert strong {
    color: #234653;
    font-family: "Poppins", sans-serif;
    font-size: .95rem;
    font-weight: 600;
}

.nps-survey-alert strong + span {
    margin-top: 2px;
    color: #526a73;
    font-size: .86rem;
}

.nps-survey-alert--success {
    border-color: #a8ddc8;
    background: #edfaf5;
    color: #087f57;
}

.nps-survey-alert--warning {
    border-color: #f2d29a;
    background: #fff9ed;
    color: #b25e13;
}

.nps-survey-alert--error {
    border-color: #efb4ae;
    background: #fff4f2;
    color: #b42318;
}

@media (prefers-reduced-motion: reduce) {
    .nps-survey-alert {
        transition-duration: .01ms;
    }
}

.nps-rating,
.nps-survey-details {
    border: 1px solid #dce8ea;
    background: rgba(255, 255, 255, .97);
    box-shadow: 0 18px 45px rgba(24, 88, 124, .1);
}

.nps-rating {
    min-width: 0;
    padding: clamp(25px, 4vw, 46px);
    margin: 0;
    border-radius: 22px;
}

.nps-rating legend {
    width: 100%;
    padding: 0;
    margin: 0 0 30px;
    color: #123f5a;
    font-family: "Poppins", sans-serif;
    font-size: clamp(1.35rem, 3vw, 2rem);
    font-weight: 600;
    line-height: 1.3;
    text-align: center;
}

.nps-rating__options {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 14px;
}

.nps-rating-option {
    --rating-color: #087f72;
    position: relative;
    min-width: 0;
}

.nps-rating-option--very-unhappy { --rating-color: #c92b2b; }
.nps-rating-option--unhappy { --rating-color: #e56d16; }
.nps-rating-option--neutral { --rating-color: #dda20a; }
.nps-rating-option--happy { --rating-color: #339555; }
.nps-rating-option--very-happy { --rating-color: #087f57; }

.nps-rating-option input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.nps-rating-option label {
    display: flex;
    min-height: 184px;
    align-items: center;
    justify-content: center;
    padding: 20px 10px 15px;
    margin: 0;
    border: 1px solid #d8e2e5;
    border-radius: 16px;
    background: #fff;
    color: var(--rating-color);
    cursor: pointer;
    flex-direction: column;
    transition: border-color 170ms ease, box-shadow 170ms ease, transform 170ms ease, background-color 170ms ease;
}

.nps-rating-option label:hover {
    border-color: var(--rating-color);
    box-shadow: 0 10px 24px rgba(24, 88, 124, .1);
    transform: translateY(-2px);
}

.nps-rating-option input:focus-visible + label {
    outline: 3px solid rgba(238, 122, 38, .48);
    outline-offset: 3px;
}

.nps-rating-option input:checked + label {
    border-color: var(--rating-color);
    background: #f0faf7;
    box-shadow: 0 0 0 2px rgba(38, 160, 139, .16), 0 12px 25px rgba(24, 88, 124, .1);
}

.nps-rating-option__face {
    position: relative;
    display: grid;
    width: 88px;
    height: 88px;
    place-items: center;
}

.nps-rating-option__face svg {
    width: 82px;
    height: 82px;
    overflow: visible;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 3;
}

.nps-rating-option__face .nps-face-fill {
    fill: currentColor;
    stroke: none;
}

.nps-rating-option__face .nps-face-mouth {
    fill: rgba(8, 127, 87, .12);
}

.nps-rating-option__face > i {
    position: absolute;
    top: -3px;
    right: -3px;
    display: grid;
    width: 27px;
    height: 27px;
    border: 3px solid #fff;
    border-radius: 50%;
    background: var(--mepso-green-dark);
    color: #fff;
    font-size: .68rem;
    opacity: 0;
    place-items: center;
    transform: scale(.65);
    transition: opacity 150ms ease, transform 150ms ease;
}

.nps-rating-option input:checked + label .nps-rating-option__face > i {
    opacity: 1;
    transform: scale(1);
}

.nps-rating-option__label {
    margin-top: 11px;
    color: #294856;
    font-size: .88rem;
    font-weight: 700;
    line-height: 1.3;
    text-align: center;
}

.nps-rating__description {
    min-height: 24px;
    margin: 23px 0 0;
    color: #60757d;
    font-size: .92rem;
    font-weight: 600;
    text-align: center;
}

.nps-rating__description.is-selected {
    color: var(--mepso-green-dark);
}

.nps-rating__description.is-error {
    color: #b42318;
}

.nps-survey-details {
    padding: clamp(24px, 4vw, 40px);
    margin-top: 18px;
    border-radius: 20px;
}

.nps-survey-details.is-revealing {
    animation: npsReveal .32s ease-out both;
}

.nps-survey-details h2 {
    margin: 0 0 25px;
    color: #164f5a;
    font-family: "Poppins", sans-serif;
    font-size: clamp(1.2rem, 2.5vw, 1.55rem);
    font-weight: 600;
}

.nps-field + .nps-field {
    margin-top: 20px;
}

.nps-field label {
    display: block;
    margin-bottom: 7px;
    color: #294856;
    font-size: .88rem;
    font-weight: 700;
}

.nps-field label span {
    color: #73858c;
    font-weight: 500;
}

.nps-field__control {
    position: relative;
}

.nps-field__control > i {
    position: absolute;
    z-index: 1;
    top: 50%;
    left: 17px;
    color: var(--mepso-green-dark);
    font-size: 1rem;
    pointer-events: none;
    transform: translateY(-50%);
}

.nps-field__control--textarea > i {
    top: 17px;
    transform: none;
}

.nps-field input,
.nps-field textarea {
    display: block;
    width: 100%;
    border: 1px solid #cbdadd;
    border-radius: 11px;
    background: #fff;
    color: #294856;
    font-family: "Open Sans", sans-serif;
    font-size: .94rem;
    outline: 0;
    transition: border-color 160ms ease, box-shadow 160ms ease;
}

.nps-field input {
    min-height: 52px;
    padding: 11px 16px 11px 47px;
}

.nps-field textarea {
    min-height: 118px;
    padding: 14px 16px 14px 47px;
    resize: vertical;
}

.nps-field input:focus,
.nps-field textarea:focus {
    border-color: var(--mepso-green-dark);
    box-shadow: 0 0 0 3px rgba(38, 160, 139, .16);
}

.nps-field input::placeholder,
.nps-field textarea::placeholder {
    color: #8c9ba0;
}

.nps-survey__submit {
    display: flex;
    width: min(100%, 650px);
    min-height: 54px;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 22px;
    margin: 26px auto 0;
    border: 0;
    border-radius: 11px;
    background: linear-gradient(100deg, var(--mepso-green-dark), var(--mepso-green));
    box-shadow: 0 10px 24px rgba(8, 127, 114, .22);
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    transition: box-shadow 160ms ease, filter 160ms ease, transform 160ms ease;
}

.nps-survey__submit:hover {
    box-shadow: 0 13px 28px rgba(8, 127, 114, .3);
    color: #fff;
    filter: brightness(1.04);
    transform: translateY(-1px);
}

.nps-survey__submit:disabled {
    box-shadow: none;
    cursor: wait;
    filter: saturate(.65);
    opacity: .72;
    transform: none;
}

.nps-survey__submit:focus-visible {
    outline: 3px solid rgba(238, 122, 38, .5);
    outline-offset: 3px;
}

.nps-survey__privacy {
    margin: 14px 0 0;
    color: #718188;
    font-size: .8rem;
    text-align: center;
}

.nps-survey__privacy i {
    margin-right: 5px;
    color: var(--mepso-green-dark);
}

@keyframes npsReveal {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 767.98px) {
    .nps-survey-page {
        min-height: 0;
        padding: 24px 10px 34px;
    }

    .nps-survey__header {
        margin-bottom: 18px;
    }

    .nps-survey__eyebrow {
        font-size: .67rem;
    }

    .nps-survey__context {
        display: grid;
        margin-top: 14px;
        grid-template-columns: 1fr;
        gap: 7px;
    }

    .nps-survey__context > span {
        min-height: 40px;
        justify-content: center;
        padding: 8px 12px;
        border-radius: 12px;
    }

    .nps-survey__location-copy {
        align-items: flex-start;
        flex-direction: column;
        gap: 1px;
        text-align: left;
    }

    .nps-rating {
        padding: 24px 10px 20px;
        border-radius: 18px;
    }

    .nps-rating legend {
        padding: 0 8px;
        margin-bottom: 23px;
    }

    .nps-rating__options {
        gap: clamp(5px, 2vw, 10px);
    }

    .nps-rating-option label {
        min-height: 0;
        padding: 0;
        border: 0;
        background: transparent;
        box-shadow: none;
    }

    .nps-rating-option label:hover {
        border: 0;
        box-shadow: none;
        transform: none;
    }

    .nps-rating-option input:checked + label {
        border: 0;
        background: transparent;
        box-shadow: none;
    }

    .nps-rating-option__face {
        width: clamp(48px, 15vw, 64px);
        height: clamp(48px, 15vw, 64px);
        border-radius: 50%;
        transition: background-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
    }

    .nps-rating-option__face svg {
        width: clamp(44px, 14vw, 60px);
        height: clamp(44px, 14vw, 60px);
        stroke-width: 3.2;
    }

    .nps-rating-option input:checked + label .nps-rating-option__face {
        background: #f0faf7;
        box-shadow: 0 0 0 2px var(--rating-color), 0 7px 17px rgba(24, 88, 124, .12);
        transform: translateY(-2px);
    }

    .nps-rating-option__face > i {
        top: -5px;
        right: -4px;
        width: 23px;
        height: 23px;
        font-size: .58rem;
    }

    .nps-rating-option__label {
        position: absolute;
        overflow: hidden;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        border: 0;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
    }

    .nps-rating__description {
        min-height: 26px;
        padding: 0 8px;
        margin-top: 21px;
        font-size: .9rem;
    }

    .nps-survey-details {
        padding: 24px 14px 19px;
        border-radius: 18px;
    }

    .nps-survey-details h2 {
        margin-bottom: 21px;
    }

    .nps-survey__submit {
        width: 100%;
    }
}

@media (max-width: 359.98px) {
    .nps-survey-page {
        padding-right: 6px;
        padding-left: 6px;
    }

    .nps-rating {
        padding-right: 7px;
        padding-left: 7px;
    }

    .nps-rating__options {
        gap: 3px;
    }

    .nps-rating-option__face {
        width: 48px;
        height: 48px;
    }

    .nps-rating-option__face svg {
        width: 45px;
        height: 45px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .nps-rating-option label,
    .nps-rating-option__face,
    .nps-rating-option__face > i,
    .nps-field input,
    .nps-field textarea,
    .nps-survey__submit {
        transition: none;
    }

    .nps-survey-details.is-revealing {
        animation: none;
    }
}
