@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap');

.ndc-feedback-wrap,
.ndc-feedback-wrap * {
    box-sizing: border-box;
}

.ndc-feedback-wrap {
    width: 100%;
    max-width: 820px;
    margin: 0 auto;
    padding: 20px 16px 40px;
    font-family: 'Poppins', Arial, sans-serif;
    color: #050505;
}

.ndc-feedback-form {
    width: 100%;
}

.ndc-feedback-section {
    margin-bottom: 54px;
}

.ndc-feedback-section h2 {
    margin: 0 0 30px;
    color: #050505;
    font-size: 28px;
    line-height: 1.25;
    font-weight: 500;
    letter-spacing: -0.02em;
}

.ndc-feedback-grid {
    display: grid;
    gap: 42px 24px;
    align-items: start;
}

.ndc-feedback-grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ndc-feedback-field {
    width: 100%;
}

.ndc-feedback-field-full {
    margin-top: 42px;
}

.ndc-feedback-label {
    display: block;
    margin-bottom: 8px;
    color: #050505;
    font-size: 16px;
    line-height: 1.45;
    font-weight: 400;
}

.ndc-feedback-label span {
    color: #ff2d2d;
    font-weight: 700;
}

.ndc-feedback-field input[type='text'],
.ndc-feedback-field input[type='email'],
.ndc-feedback-field input[type='tel'],
.ndc-feedback-field input[type='date'],
.ndc-feedback-field textarea {
    width: 100%;
    min-height: 42px;
    padding: 10px 12px;
    border: 1px solid #dddddd;
    border-radius: 5px;
    background: #ffffff;
    color: #050505;
    font-family: 'Poppins', Arial, sans-serif;
    font-size: 15px;
    line-height: 1.4;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.ndc-feedback-field textarea {
    min-height: 110px;
    resize: vertical;
}

.ndc-feedback-field input:focus,
.ndc-feedback-field textarea:focus {
    border-color: #4e2ce5;
    box-shadow: 0 0 0 3px rgba(78, 44, 229, 0.12);
}

.ndc-feedback-rating-field {
    margin-top: 42px;
}

.ndc-score-options {
    display: inline-flex;
    flex-wrap: wrap;
    overflow: hidden;
    border: 1px solid #dddddd;
    border-radius: 5px;
    background: #ffffff;
}

.ndc-score-option {
    position: relative;
    display: flex;
    min-width: 44px;
    min-height: 42px;
    cursor: pointer;
    border-right: 1px solid #dddddd;
    color: #050505;
    font-size: 14px;
    font-weight: 400;
}

.ndc-score-option:last-child {
    border-right: 0;
}

.ndc-score-option input {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.ndc-score-option span {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 42px;
    padding: 0 14px;
    transition: background 0.2s ease, color 0.2s ease;
}

.ndc-score-option:hover span,
.ndc-score-option input:checked + span {
    background: #4e2ce5;
    color: #ffffff;
}

.ndc-feedback-matrix-block {
    margin-bottom: 42px;
}

.ndc-feedback-matrix-block:last-child {
    margin-bottom: 0;
}

.ndc-feedback-matrix-title {
    margin-bottom: 14px;
}

.ndc-feedback-matrix {
    display: grid;
    grid-template-columns: minmax(150px, 1.3fr) repeat(4, minmax(90px, 1fr));
    width: 100%;
    border-bottom: 1px solid #dddddd;
    overflow-x: auto;
}

.ndc-feedback-matrix-header,
.ndc-feedback-matrix-row-label,
.ndc-feedback-radio-cell {
    min-height: 50px;
    display: flex;
    align-items: center;
    border-top: 1px solid #dddddd;
    color: #050505;
    font-size: 14px;
    line-height: 1.4;
}

.ndc-feedback-matrix-header {
    justify-content: center;
    font-weight: 400;
    text-align: center;
}

.ndc-feedback-matrix-row-label {
    justify-content: flex-start;
    padding: 0 16px;
    font-weight: 400;
}

.ndc-feedback-radio-cell {
    position: relative;
    justify-content: center;
    cursor: pointer;
}

.ndc-feedback-radio-cell input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.ndc-feedback-custom-radio {
    width: 17px;
    height: 17px;
    border: 1.5px solid #8c8c8c;
    border-radius: 50%;
    background: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.ndc-feedback-custom-radio::after {
    content: '';
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #4e2ce5;
    transform: scale(0);
    transition: transform 0.2s ease;
}

.ndc-feedback-radio-cell:hover .ndc-feedback-custom-radio,
.ndc-feedback-radio-cell input:checked + .ndc-feedback-custom-radio {
    border-color: #4e2ce5;
    box-shadow: 0 0 0 3px rgba(78, 44, 229, 0.12);
}

.ndc-feedback-radio-cell input:checked + .ndc-feedback-custom-radio::after {
    transform: scale(1);
}

.ndc-feedback-submit-row {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    margin-top: 24px;
}

.ndc-feedback-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 46px;
    padding: 12px 27px;
    border: 0;
    border-radius: 5px;
    background: #512be8;
    color: #ffffff;
    font-family: 'Poppins', Arial, sans-serif;
    font-size: 14px;
    line-height: 1;
    font-weight: 700;
    text-transform: uppercase;
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.ndc-feedback-submit:hover,
.ndc-feedback-submit:focus {
    background: #3f20c4;
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(81, 43, 232, 0.22);
}

.ndc-feedback-submit-icon {
    font-size: 13px;
    line-height: 1;
}

.ndc-feedback-alert {
    margin-bottom: 24px;
    padding: 14px 16px;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.5;
}

.ndc-feedback-alert-success {
    border: 1px solid #bfe7ce;
    background: #effaf3;
    color: #176b32;
}

.ndc-feedback-alert-error {
    border: 1px solid #ffc7c7;
    background: #fff0f0;
    color: #b42318;
}

.screen-reader-text {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

@media (max-width: 768px) {
    .ndc-feedback-wrap {
        padding: 18px 14px 34px;
    }

    .ndc-feedback-section {
        margin-bottom: 42px;
    }

    .ndc-feedback-section h2 {
        margin-bottom: 22px;
        font-size: 24px;
    }

    .ndc-feedback-grid-2 {
        grid-template-columns: 1fr;
    }

    .ndc-feedback-grid {
        gap: 22px;
    }

    .ndc-feedback-field-full,
    .ndc-feedback-rating-field {
        margin-top: 28px;
    }

    .ndc-score-options {
        display: grid;
        grid-template-columns: repeat(6, minmax(0, 1fr));
        width: 100%;
        overflow: hidden;
    }

    .ndc-score-option {
        min-width: 0;
        border-right: 1px solid #dddddd;
        border-bottom: 1px solid #dddddd;
    }

    .ndc-score-option:nth-child(6n) {
        border-right: 0;
    }

    .ndc-score-option:nth-last-child(-n+5) {
        border-bottom: 0;
    }

    .ndc-score-option span {
        padding: 0 8px;
    }

    .ndc-feedback-matrix {
        grid-template-columns: minmax(130px, 1.1fr) repeat(4, minmax(76px, 1fr));
    }

    .ndc-feedback-matrix-header,
    .ndc-feedback-matrix-row-label,
    .ndc-feedback-radio-cell {
        min-height: 46px;
        font-size: 13px;
    }

    .ndc-feedback-matrix-row-label {
        padding: 0 12px;
    }
}

@media (max-width: 520px) {
    .ndc-feedback-section h2 {
        font-size: 22px;
    }

    .ndc-feedback-label {
        font-size: 15px;
    }

    .ndc-score-options {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .ndc-score-option:nth-child(6n) {
        border-right: 1px solid #dddddd;
    }

    .ndc-score-option:nth-child(4n) {
        border-right: 0;
    }

    .ndc-score-option:nth-last-child(-n+5) {
        border-bottom: 1px solid #dddddd;
    }

    .ndc-score-option:nth-last-child(-n+3) {
        border-bottom: 0;
    }

    .ndc-feedback-matrix {
        grid-template-columns: 1fr;
        border: 1px solid #dddddd;
        border-radius: 8px;
        overflow: hidden;
    }

    .ndc-feedback-matrix-header {
        display: none;
    }

    .ndc-feedback-matrix-row-label {
        min-height: auto;
        padding: 12px 14px;
        border-top: 0;
        background: #fafafa;
        font-weight: 600;
    }

    .ndc-feedback-radio-cell {
        min-height: 44px;
        justify-content: flex-start;
        gap: 10px;
        padding: 0 14px;
    }

    .ndc-feedback-radio-cell .screen-reader-text {
        position: static !important;
        width: auto;
        height: auto;
        margin: 0;
        overflow: visible;
        clip: auto;
        white-space: normal;
        color: #050505;
        font-size: 14px;
    }

    .ndc-feedback-submit-row,
    .ndc-feedback-submit {
        width: 100%;
    }
}
