/* Feedback Popup Overlay */
#nuv-feedback-popup-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1000;
    animation: fadeIn 0.3s ease-out;
}

#nuv-feedback-popup-overlay.is-visible {
    display: flex;
}

body.theme-dark #nuv-feedback-popup-overlay {
    background: rgba(6, 14, 22, 0.78);
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.nuv-feedback-popup {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    width: 286px;
    min-height: 335px;
    background: #FFFFFF;
    border-radius: 10px;
    box-shadow: -3px 3px 15px 0px #0000002E;
    opacity: 1;
    overflow: hidden;
    animation: slideUp 0.3s ease-out;
}

.nuv-feedback-popup.has-success {
    height: auto;
}

body.theme-dark .nuv-feedback-popup {
    background: #152737;
    border: 1px solid #3b4f5f;
    box-shadow: -3px 3px 18px 0px rgba(0, 0, 0, 0.45);
}

@keyframes slideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.nuv-feedback-popup__header {
    padding: 21px 38px 0;
}

.nuv-feedback-popup__close {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 26px;
    height: 26px;
    padding: 0;
    border: 0;
    background: transparent;
    color: #1B0657;
    font-family: 'Inter Tight', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.2s ease, color 0.2s ease;
}

.nuv-feedback-popup__close:hover,
.nuv-feedback-popup__close:focus {
    background: #F1EFED;
    outline: none;
}

body.theme-dark .nuv-feedback-popup__close {
    color: #F3F0FA;
}

body.theme-dark .nuv-feedback-popup__close:hover,
body.theme-dark .nuv-feedback-popup__close:focus {
    background: #203646;
}

.nuv-feedback-popup__title {
    width: 210px;
    height: 53px;
    margin: 0 auto;
    font-family: 'Source Serif 4', serif;
    font-weight: 500;
    font-size: 24px;
    line-height: 28px;
    letter-spacing: -0.01em;
    text-align: center;
    color: #1B0657;
}

body.theme-dark .nuv-feedback-popup__title {
    color: #F3F0FA;
}

.nuv-feedback-popup__choices {
    display: flex;
    gap: 7px;
    margin-bottom: 16px;
}

.nuv-feedback-choice {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    border: 1px solid #CFC9C2;
    border-radius: 100px;
    background: #fff;
    color: #1B0657;
    font-family: 'Inter Tight', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 15px;
    font-weight: 400;
    width: 124px;
    height: 39px;
    padding: 8px 16px;
    gap: 6px;
    cursor: pointer;
    transition: color 0.3s ease, border-color 0.3s ease;
    box-sizing: border-box;
    line-height: 140%;
    position: relative;
    overflow: hidden;
    z-index: 0;
}

.nuv-feedback-choice::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 100px;
    background-color: #1B0657;
    transform: scaleY(0);
    transform-origin: top;
    transition: transform 0.3s ease;
    z-index: -1;
    pointer-events: none;
}

body.theme-dark .nuv-feedback-choice {
    border-color: #536878;
    background: #203646;
    color: #F3F0FA;
}

body.theme-dark .nuv-feedback-choice::before {
    background-color: #F3F0FA;
}

body.theme-dark .nuv-feedback-choice .nuv-feedback-choice__icon {
    filter: brightness(0) invert(1);
}

.nuv-feedback-choice--negative {
    transition: color 0.3s ease, border-color 0.3s ease;
}

.nuv-feedback-choice--positive {
    transition: color 0.3s ease, border-color 0.3s ease;
}

/* Light theme: hover fills dark from bottom, text/icon go light */
.nuv-feedback-choice--positive:not(.selected):hover,
.nuv-feedback-choice--positive:not(.selected):focus-visible,
.nuv-feedback-choice--negative:not(.selected):hover,
.nuv-feedback-choice--negative:not(.selected):focus-visible {
    border-color: #1B0657;
    color: #F3F0FA;
    background: transparent;
    outline: none;
}

.nuv-feedback-choice--positive:not(.selected):hover::before,
.nuv-feedback-choice--positive:not(.selected):focus-visible::before,
.nuv-feedback-choice--negative:not(.selected):hover::before,
.nuv-feedback-choice--negative:not(.selected):focus-visible::before {
    transform: scaleY(1);
    transform-origin: bottom;
}

.nuv-feedback-choice--positive:not(.selected):hover .nuv-feedback-choice__icon,
.nuv-feedback-choice--positive:not(.selected):focus-visible .nuv-feedback-choice__icon,
.nuv-feedback-choice--negative:not(.selected):hover .nuv-feedback-choice__icon,
.nuv-feedback-choice--negative:not(.selected):focus-visible .nuv-feedback-choice__icon {
    filter: brightness(0) invert(1);
}

/* Dark theme: hover fills light from bottom, text/icon go dark */
body.theme-dark .nuv-feedback-choice--negative:not(.selected):hover,
body.theme-dark .nuv-feedback-choice--negative:not(.selected):focus-visible,
body.theme-dark .nuv-feedback-choice--positive:not(.selected):hover,
body.theme-dark .nuv-feedback-choice--positive:not(.selected):focus-visible {
    background: transparent;
    border-color: #F3F0FA;
    color: #1B0657;
}

body.theme-dark .nuv-feedback-choice--negative:not(.selected):hover::before,
body.theme-dark .nuv-feedback-choice--negative:not(.selected):focus-visible::before,
body.theme-dark .nuv-feedback-choice--positive:not(.selected):hover::before,
body.theme-dark .nuv-feedback-choice--positive:not(.selected):focus-visible::before {
    transform: scaleY(1);
    transform-origin: bottom;
}

body.theme-dark .nuv-feedback-choice--negative:not(.selected):hover .nuv-feedback-choice__icon,
body.theme-dark .nuv-feedback-choice--negative:not(.selected):focus-visible .nuv-feedback-choice__icon,
body.theme-dark .nuv-feedback-choice--positive:not(.selected):hover .nuv-feedback-choice__icon,
body.theme-dark .nuv-feedback-choice--positive:not(.selected):focus-visible .nuv-feedback-choice__icon {
    filter: none;
}

.nuv-feedback-choice:focus,
.nuv-feedback-choice.selected {
    border: 2px solid #1B0657;
    background: #F3F0FA;
    outline: none;
}

.nuv-feedback-choice.selected::before {
    transform: scaleY(0) !important;
}

/* Keep positive selected colors explicit so they never inherit hover/base icon filters. */
.nuv-feedback-choice--positive.selected {
    color: #1B0657;
}

.nuv-feedback-choice--positive.selected .nuv-feedback-choice__icon {
    filter: none;
}

.nuv-feedback-choice--negative.selected {
    color: #1B0657;
}

.nuv-feedback-choice--negative.selected .nuv-feedback-choice__icon {
    filter: none;
}

body.theme-dark .nuv-feedback-choice:focus,
body.theme-dark .nuv-feedback-choice.selected {
    border-color: #BFD0DC;
    background: #2A4356;
    color: #FFFFFF;
}

body.theme-dark .nuv-feedback-choice:focus .nuv-feedback-choice__icon,
body.theme-dark .nuv-feedback-choice.selected .nuv-feedback-choice__icon {
    filter: brightness(0) invert(1);
}

body.theme-dark .nuv-feedback-choice--positive.selected {
    color: #FFFFFF;
}

body.theme-dark .nuv-feedback-choice--positive.selected .nuv-feedback-choice__icon {
    filter: brightness(0) invert(1);
}

body.theme-dark .nuv-feedback-choice--negative.selected {
    color: #FFFFFF;
}

body.theme-dark .nuv-feedback-choice--negative.selected .nuv-feedback-choice__icon {
    filter: brightness(0) invert(1);
}

.nuv-feedback-choice__icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    margin-bottom: 3px;
}

.nuv-feedback-popup__form {
    padding: 18px 15px 12px;
}

.nuv-feedback-popup__options {
    margin: 0;
}

.nuv-feedback-option__content {
    display: block;
    position: relative;
}

.nuv-feedback-option__textarea {
    display: block;
    width: 253px;
    height: 108px;
    min-height: 108px;
    border: 0;
    border-radius: 5px;
    background: #F1EFED;
    color: #1B0657;
    font-size: 14px;
    font-family: 'Inter Tight', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-weight: 400;
    line-height: 1;
    padding: 12px 13px 24px;
    resize: none;
    box-sizing: border-box;
}

.nuv-feedback-option__counter {
    position: absolute;
    right: 11px;
    bottom: 9px;
    font-family: 'Inter Tight', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 11px;
    line-height: 1;
    color: #7C738F;
    pointer-events: none;
}

body.theme-dark .nuv-feedback-option__counter {
    color: #9FB2C1;
}

body.theme-dark .nuv-feedback-option__textarea {
    background: #0F1F2C;
    border: 1px solid #3F5362;
    color: #F3F0FA;
}

.nuv-feedback-option__textarea::placeholder {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-weight: 400;
    font-size: 12px;
    line-height: 100%;
    letter-spacing: 0%;
    color: #1B0657;
}

body.theme-dark .nuv-feedback-option__textarea::placeholder {
    color: #9FB2C1;
}

.nuv-feedback-popup__actions {
    display: flex;
    justify-content: center;
    margin-top: 16px;
}

.nuv-feedback-popup__alert {
    margin-top: 8px;
    padding: 8px 12px;
    border-radius: 6px;
    background: #FFF0F0;
    border: 1px solid #E8CCCC;
    color: #8B1A1A;
    font-family: 'Inter Tight', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.4;
    text-align: center;
}

.nuv-feedback-popup__alert[hidden] {
    display: none;
}

body.theme-dark .nuv-feedback-popup__alert {
    background: #2C1A1A;
    border-color: #5C3030;
    color: #F5BFBF;
}

.nuv-feedback-popup__submit {
    width: 253px;
    height: 40px;
    border-radius: 100px;
    border: 1px solid #160850;
    background: #fff;
    color: #160850;
    font-family: 'Inter Tight', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 15px;
    font-weight: 400;
    line-height: 140%;
    letter-spacing: 0%;
    padding: 8px 16px;
    gap: 6px;
    cursor: pointer;
    transition: color 0.3s ease, border-color 0.3s ease;
    box-sizing: border-box;
    position: relative;
    overflow: hidden;
    z-index: 0;
}

.nuv-feedback-popup__submit::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 100px;
    background-color: #160850;
    transform: scaleY(0);
    transform-origin: top;
    transition: transform 0.3s ease;
    z-index: -1;
    pointer-events: none;
}

body.theme-dark .nuv-feedback-popup__submit {
    border-color: #8EA4B6;
    background: #203646;
    color: #F3F0FA;
}

body.theme-dark .nuv-feedback-popup__submit::before {
    background-color: #F3F0FA;
}

.nuv-feedback-popup__submit:hover,
.nuv-feedback-popup__submit:focus {
    background: transparent;
    border-color: #160850;
    color: #F3F0FA;
    outline: none;
}

.nuv-feedback-popup__submit:hover::before,
.nuv-feedback-popup__submit:focus::before {
    transform: scaleY(1);
    transform-origin: bottom;
}

.nuv-feedback-popup__submit:disabled,
.nuv-feedback-popup__submit:disabled:hover,
.nuv-feedback-popup__submit:disabled:focus {
    background: #F1EFED;
    border-color: #CFC9C2;
    color: #7C738F;
    cursor: wait;
    opacity: 0.75;
}

body.theme-dark .nuv-feedback-popup__submit:hover,
body.theme-dark .nuv-feedback-popup__submit:focus {
    background: transparent;
    border-color: #F3F0FA;
    color: #1B0657;
}

body.theme-dark .nuv-feedback-popup__submit:hover::before,
body.theme-dark .nuv-feedback-popup__submit:focus::before {
    transform: scaleY(1);
    transform-origin: bottom;
}

body.theme-dark .nuv-feedback-popup__submit:disabled,
body.theme-dark .nuv-feedback-popup__submit:disabled:hover,
body.theme-dark .nuv-feedback-popup__submit:disabled:focus {
    background: #203646;
    border-color: #536878;
    color: #9FB2C1;
}

.nuv-feedback-popup__success {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 34px 15px 36px;
    box-sizing: border-box;
    text-align: center;
}

.nuv-feedback-popup__success[hidden] {
    display: none;
}

.nuv-feedback-popup__success-message {
    margin: 0 0 28px;
    color: #1B0657;
    font-family: 'Inter Tight', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.4;
}

body.theme-dark .nuv-feedback-popup__success-message {
    color: #F3F0FA;
}

.nuv-feedback-popup__ok {
    width: 160px;
    height: 40px;
    border-radius: 100px;
    border: 1px solid #160850;
    background: #fff;
    color: #160850;
    font-family: 'Inter Tight', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 15px;
    font-weight: 400;
    line-height: 140%;
    padding: 8px 16px;
    cursor: pointer;
    transition: color 0.3s ease, border-color 0.3s ease;
    box-sizing: border-box;
    position: relative;
    overflow: hidden;
    z-index: 0;
}

.nuv-feedback-popup__ok::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 100px;
    background-color: #160850;
    transform: scaleY(0);
    transform-origin: top;
    transition: transform 0.3s ease;
    z-index: -1;
    pointer-events: none;
}

body.theme-dark .nuv-feedback-popup__ok {
    border-color: #8EA4B6;
    background: #203646;
    color: #F3F0FA;
}

body.theme-dark .nuv-feedback-popup__ok::before {
    background-color: #F3F0FA;
}

.nuv-feedback-popup__ok:hover,
.nuv-feedback-popup__ok:focus {
    background: transparent;
    border-color: #160850;
    color: #F3F0FA;
    outline: none;
}

.nuv-feedback-popup__ok:hover::before,
.nuv-feedback-popup__ok:focus::before {
    transform: scaleY(1);
    transform-origin: bottom;
}

body.theme-dark .nuv-feedback-popup__ok:hover,
body.theme-dark .nuv-feedback-popup__ok:focus {
    background: transparent;
    border-color: #F3F0FA;
    color: #1B0657;
}

body.theme-dark .nuv-feedback-popup__ok:hover::before,
body.theme-dark .nuv-feedback-popup__ok:focus::before {
    transform: scaleY(1);
    transform-origin: bottom;
}
