.survey-required-label{
    display:flex;
    align-items:center;
    gap:10px;
    cursor:pointer;
    width:max-content;
    margin:0;
    font-weight:500;
}

.survey-required-checkbox{
    appearance:none;
    -webkit-appearance:none;

    width:20px !important;
    min-width:20px !important;
    max-width:20px !important;

    height:20px !important;
    min-height:20px !important;
    max-height:20px !important;

    padding:0 !important;
    margin:0 !important;

    border:2px solid #aaa;
    border-radius:5px;

    background:#fff;

    cursor:pointer;

    position:relative;

    flex:0 0 20px;
    box-sizing:border-box;
}

.survey-required-checkbox:checked{
    background:#4285f4;
    border-color:#4285f4;
}

.survey-required-checkbox:checked::after{
    content:"";

    position:absolute;

    left:5px;
    top:1px;

    width:6px;
    height:11px;

    border:solid #fff;
    border-width:0 2px 2px 0;

    transform:rotate(45deg);
}

.number-question-settings{

    margin-top:25px;

}


.number-settings-title{

    margin:0 0 8px 0;

    font-size:20px;

    font-weight:600;

    color:#263238;

}


.number-settings-description{

    margin:0 0 25px 0;

    font-size:14px;

    line-height:1.6;

    color:#667085;

}


.number-setting-group{

    margin-bottom:22px;

}


.number-setting-label{

    display:block;

    margin-bottom:8px;

    font-size:15px;

    font-weight:600;

    color:#344054;

}


.number-setting-optional{

    font-size:13px;

    font-weight:400;

    color:#98a2b3;

}


.number-setting-input{

    width:100%;

    min-height:44px;

    padding:10px 13px;

    border:1px solid #d0d5dd;

    border-radius:8px;

    background:#fff;

    color:#1d2939;

    font-size:15px;

    box-sizing:border-box;

    transition:
        border-color .2s ease,
        box-shadow .2s ease;

}


.number-setting-input:focus{

    outline:none;

    border-color:#667eea;

    box-shadow:
        0 0 0 3px rgba(
            102,
            126,
            234,
            .12
        );

}


.number-setting-input::placeholder{

    color:#98a2b3;

}


.number-setting-hint{

    margin-top:6px;

    font-size:13px;

    line-height:1.5;

    color:#98a2b3;

}

/* ==================================================
   NUMBER SURVEY VIEW
================================================== */

.survey-number-answer-wrap{
    width:100%;
    max-width:600px;
}


/* ==================================================
   ПОЛЕ ЧИСЛОВОЇ ВІДПОВІДІ
================================================== */

.survey-number-answer-input{
    width:100%;
    box-sizing:border-box;

    padding:12px 14px;

    border:1px solid #d5d9df;
    border-radius:8px;

    background:#fff;

    color:#222;

    font-size:16px;
    line-height:1.4;

    outline:none;

    transition:
        border-color .2s ease,
        box-shadow .2s ease;
}


.survey-number-answer-input:focus{
    border-color:#4a90e2;

    box-shadow:
        0 0 0 3px rgba(74,144,226,.12);
}


.survey-number-answer-input:hover{
    border-color:#b8bec7;
}


/* ==================================================
   ПОПЕРЕДЖЕННЯ ПРО MIN / MAX
================================================== */

.survey-number-answer-warning{
    display:flex;
    align-items:center;

    gap:9px;

    margin-top:10px;

    padding:10px 12px;

    border:1px solid #f0d58a;
    border-radius:7px;

    background:#fff8df;

    color:#735b13;

    font-size:14px;
    line-height:1.45;
}


/* ==================================================
   ІКОНКА ПОПЕРЕДЖЕННЯ
================================================== */

.survey-number-answer-warning-icon{
    flex:0 0 20px;

    width:20px;
    height:20px;

    display:flex;
    align-items:center;
    justify-content:center;

    border-radius:50%;

    background:#e6b800;

    color:#fff;

    font-size:13px;
    font-weight:700;

    line-height:1;
}


/* ==================================================
   MOBILE
================================================== */

@media(max-width:600px){

    .survey-number-answer-wrap{
        max-width:100%;
    }

    .survey-number-answer-input{
        font-size:16px;
    }

    .survey-number-answer-warning{
        font-size:13px;
    }

}

.survey-preview-answer-error{
    margin-top:18px;
    padding:12px 15px;
    border:1px solid #dc3545;
    border-radius:8px;
    background:#f8d7da;
    color:#842029;
    font-size:15px;
    font-weight:500;
    line-height:1.5;
}


.survey-number-answer-error:not([hidden]){
    display:block;
}

.survey-date-answer-wrapper {
    width: 100%;
    max-width: 500px;
}

.survey-date-answer-input-wrap {
    position: relative;
    width: 100%;
}

.survey-date-answer-input {
    width: 100%;
    height: 46px;
    padding: 0 48px 0 14px;

    border: 1px solid #ced4da;
    border-radius: 8px;

    background: #fff;

    color: #212529;

    font-size: 15px;

    outline: none;

    cursor: pointer;

    box-sizing: border-box;

    transition:
        border-color .2s ease,
        box-shadow .2s ease;
}

.survey-date-answer-input:focus {
    border-color: #80bdff;

    box-shadow:
        0 0 0 3px rgba(
            0,
            123,
            255,
            .12
        );
}

.survey-date-answer-input-wrap
.survey-date-answer-calendar-icon {

    position: absolute;

    right: 14px;
    top: 50%;

    transform: translateY(-50%);

    font-size: 19px;

    pointer-events: none;
}


.survey-date-answer-info {
    margin-top: 12px;
    padding: 14px 16px;
    background: #fff3cd;
    border: 1px solid #ffe69c;
    border-radius: 8px;
    color: #664d03;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.survey-date-answer-info-item {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.survey-date-answer-info-label {
    font-size: 17px;
    font-weight: 600;
}

.survey-date-answer-info-date {
    font-size: 18px;
    font-weight: 700;
    color: #664d03;
}


.survey-date-answer-warning {

    display: flex;

    align-items: center;

    gap: 8px;

    margin-top: 8px;

    padding: 9px 12px;

    border-radius: 7px;

    background: #fff3cd;

    border: 1px solid #ffe69c;

    color: #856404;

    font-size: 14px;
}

.survey-date-answer-warning-icon {

    display: inline-flex;

    align-items: center;
    justify-content: center;

    width: 20px;
    height: 20px;

    flex-shrink: 0;

    border-radius: 50%;

    background: #ffc107;

    color: #fff;

    font-weight: 700;

    font-size: 13px;
}


/* =========================================================
   РОЗМІТКА СТОРІНКИ ОПИТУВАННЯ
========================================================= */

.survey-page .question-layout {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 220px !important;
    gap: 30px !important;
    align-items: start !important;
}


/* Основний блок із питаннями */

.survey-page .question-layout .left-block {
    grid-column: 1 !important;
    min-width: 0;
    width: 100%;
}


/* Правий блок */

.survey-page .question-layout .right-block {
    grid-column: 2 !important;
    grid-row: 1 !important;

    width: 220px !important;
    min-width: 220px !important;

    position: sticky;
    top: 20px;

    align-self: start;
}


/* =========================================================
   КНОПКА НАСТУПНОЇ СТОРІНКИ
========================================================= */

.next-page-btn.next-page-disabled {
    background: #f6c98d !important;
    color: #fff !important;
    border-color: #f6c98d !important;

    cursor: not-allowed !important;
    opacity: 0.8;

    pointer-events: none;
}


/* Майбутні питання */

.passtest-nav-btn.nav-disabled {
    opacity: 0.45;
    cursor: not-allowed;
    pointer-events: none;
}

.next-page-disabled{
    background:#f6c27a !important;
    color:#fff !important;
    border-color:#f6c27a !important;
    opacity:0.75;
    cursor:not-allowed !important;
    pointer-events:none;
}

@media (max-width: 900px) {

    .survey-page .question-layout {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }

    /* Навігація та інформація — зверху */
    .survey-page .question-layout .right-block {
        grid-column: 1 !important;
        grid-row: 1 !important;

        width: 100% !important;
        min-width: 0 !important;

        position: static !important;
    }

    /* Питання — під навігацією */
    .survey-page .question-layout .left-block {
        grid-column: 1 !important;
        grid-row: 2 !important;

        width: 100% !important;
    }

}

.survey-number-server-error{
    display: flex;
    align-items: flex-start;
    gap: 10px;

    margin-top: 12px;
    margin-bottom: 12px;

    padding: 12px 15px;

    border: 1px solid #dc3545;
    border-radius: 8px;

    background: #fff1f2;
    color: #b42318;

    font-size: 14px;
    line-height: 1.4;
}

.survey-number-server-error-icon{
    flex: 0 0 auto;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 22px;
    height: 22px;

    border-radius: 50%;

    background: #dc3545;
    color: #fff;

    font-weight: 700;
    font-size: 14px;
}

.survey-number-server-error-text{
    flex: 1;
}

.surveySaveError{

    display: none;

    margin-top: 15px;
    margin-bottom: 12px;

    padding: 12px 15px;

    background: #fdeaea;

    border: 1px solid #dc3545;

    border-left: 4px solid #dc3545;

    border-radius: 6px;

    color: #b02a37;

    font-size: 14px;
    line-height: 1.4;

}

/* ==================================================
   RATING VIEW — CARD
================================================== */

.survey-rating-view-card{
    width:100%;
    box-sizing:border-box;

    padding:24px 26px;
    margin-top:20px;

    border-radius:14px;

    background:#ffffff;

    border:1px solid #e4e7ec;

    box-shadow:
        0 2px 8px rgba(16,24,40,0.05);
}


/* ==================================================
   TITLE
================================================== */

.survey-rating-view-title{
    font-size:18px;
    font-weight:600;

    color:#1d2939;

    margin-bottom:20px;
}


/* ==================================================
   CURRENT ROW
================================================== */

.survey-rating-view-current-row{
    width:100%;

    display:flex;
    align-items:center;
    justify-content:space-between;

    gap:20px;

    margin-bottom:24px;
}


/* ==================================================
   CURRENT LABEL
================================================== */

.survey-rating-view-current-label{
    font-size:15px;
    font-weight:500;

    color:#475467;
}


/* ==================================================
   CURRENT VALUE
================================================== */

.survey-rating-view-current-value{
    min-width:52px;
    height:40px;

    padding:0 14px;

    display:inline-flex;
    align-items:center;
    justify-content:center;

    box-sizing:border-box;

    border-radius:10px;

    background:#f2f4f7;

    border:1px solid #d0d5dd;

    color:#101828;

    font-size:18px;
    font-weight:700;

    line-height:1;

    transition:
        background-color .12s ease,
        transform .08s ease;
}


/* ==================================================
   SLIDER WRAPPER
================================================== */

.survey-rating-view-slider-wrapper{
    width:100%;

    box-sizing:border-box;
}


/* ==================================================
   RANGE SLIDER
================================================== */

.survey-rating-view-slider{
    display:block;

    width:100%;
    max-width:100%;

    height:8px;

    margin:0;
    padding:0;

    cursor:pointer;

    appearance:none;
    -webkit-appearance:none;

    background:linear-gradient(
        to right,
        #2563eb 0%,
        #2563eb 0%,
        #e4e7ec 0%,
        #e4e7ec 100%
    );

    border-radius:999px;

    outline:none;
}


/* ==================================================
   CHROME / EDGE — TRACK
================================================== */

.survey-rating-view-slider::-webkit-slider-runnable-track{

    width:100%;
    height:8px;

    border-radius:999px;

    background:transparent;
}


/* ==================================================
   CHROME / EDGE — THUMB
================================================== */

.survey-rating-view-slider::-webkit-slider-thumb{

    appearance:none;
    -webkit-appearance:none;

    width:22px;
    height:22px;

    margin-top:-7px;

    border:none;
    border-radius:50%;

    background:#2563eb;

    cursor:pointer;

    box-shadow:
        0 2px 6px rgba(37,99,235,0.35);

    transition:
        transform .12s ease,
        box-shadow .12s ease;
}


/* ==================================================
   HOVER
================================================== */

.survey-rating-view-slider:hover::-webkit-slider-thumb{

    transform:scale(1.08);

    box-shadow:
        0 3px 9px rgba(37,99,235,0.42);
}


/* ==================================================
   FIREFOX — TRACK
================================================== */

.survey-rating-view-slider::-moz-range-track{

    width:100%;
    height:8px;

    border-radius:999px;

    background:#e4e7ec;
}


/* ==================================================
   FIREFOX — PROGRESS
================================================== */

.survey-rating-view-slider::-moz-range-progress{

    height:8px;

    border-radius:999px;

    background:#2563eb;
}


/* ==================================================
   FIREFOX — THUMB
================================================== */

.survey-rating-view-slider::-moz-range-thumb{

    width:22px;
    height:22px;

    border:none;
    border-radius:50%;

    background:#2563eb;

    cursor:pointer;

    box-shadow:
        0 2px 6px rgba(37,99,235,0.35);
}


/* ==================================================
   SCALE
================================================== */

.survey-rating-view-scale{

    width:100%;

    display:flex;

    align-items:center;
    justify-content:space-between;

    margin-top:10px;
}


/* ==================================================
   SCALE VALUES
================================================== */

.survey-rating-view-scale-min,
.survey-rating-view-scale-max{

    font-size:16px;
    font-weight:600;

    color:#667085;
}


/* ==================================================
   MOBILE
================================================== */

@media(max-width:600px){

    .survey-rating-view-card{

        padding:20px 18px;

    }


    .survey-rating-view-current-row{

        gap:12px;

    }


    .survey-rating-view-current-label{

        font-size:14px;

    }


    .survey-rating-view-current-value{

        min-width:48px;
        height:38px;

        font-size:17px;

    }


    .survey-rating-view-slider{

        height:8px;

    }

}

/* =========================================================
   АНОНІМНЕ ОПИТУВАННЯ
========================================================= */

.survey-anonymous-notice{
    width:100%;
    box-sizing:border-box;

    margin:0 0 22px 0;
    padding:16px 20px;

    background:#fff3cd;
    border:1px solid #ffe08a;
    border-left:5px solid #f0ad00;

    border-radius:10px;

    color:#664d03;

    font-size:18px;
    line-height:1.55;

    box-shadow:
        0 2px 6px rgba(0,0,0,0.06);
}

.survey-anonymous-notice-inner{
    display:flex;
    align-items:flex-start;
    gap:12px;
}

.survey-anonymous-notice-icon{
    flex:0 0 auto;

    width:28px;
    height:28px;

    display:flex;
    align-items:center;
    justify-content:center;

    background:#f0ad00;
    color:#fff;

    border-radius:50%;

    font-size:16px;
    font-weight:700;
}

.survey-anonymous-notice-text{
    flex:1;
}

.survey-anonymous-notice-title{
    display:block;

    margin-bottom:3px;

    font-weight:700;
    color:#5f4700;
}

.survey-anonymous-notice-description{
    display:block;

    font-weight:400;
    color:#664d03;
}

.survey-statistics-notice {
    margin-top: 30px;
    margin-bottom: 20px;
    padding: 15px 20px;
    background: #fff8d6;
    border: 1px solid #f0c36d;
    border-radius: 8px;
    color: #856404;
    font-size: 17px;
    font-weight: 500;
    line-height: 1.5;
}

.finish-survey-disabled{
    opacity:0.5;
    cursor:not-allowed;
    pointer-events:none;
    user-select:none;
}

.anonymous-checkbox-disabled{

    color:#999;

}


.anonymous-checkbox-disabled input{

    cursor:not-allowed;

    opacity:0.5;

}


.anonymous-checkbox-warning{

    display:block;

    margin-top:6px;

    font-size:13px;

    color:#999;

}

/* ==================================================
   SURVEY VIEW — ВІДПОВІДІ
================================================== */

.survey-view-answer-line {
    margin-bottom: 6px;
}

.survey-view-no-answer {
    color: #777;
}


/* ==================================================
   КНОПКА СТАТИСТИКИ
================================================== */

.survey-results-button {
    display: inline-block;
    margin-top: 15px;
    padding: 10px 16px;

    border: 0;
    border-radius: 7px;

    background: #3498db;
    color: #fff;

    font-size: 15px;
    font-weight: 600;

    cursor: pointer;

    transition:
        background 0.2s ease,
        transform 0.1s ease;
}

.survey-results-button:hover {
    background: #2980b9;
}

.survey-results-button:active {
    transform: translateY(1px);
}


/* ==================================================
   ПРИХОВАНІ ДАНІ СТАТИСТИКИ
================================================== */

.survey-statistics-data {
    display: none;
}


/* ==================================================
   МОДАЛЬНЕ ВІКНО
================================================== */

.survey-results-modal {
    display: none;

    position: fixed;

    z-index: 99999;

    left: 0;
    top: 0;

    width: 100%;
    height: 100%;

    background: rgba(0, 0, 0, 0.55);

    align-items: center;
    justify-content: center;

    padding: 20px;

    box-sizing: border-box;
}

.survey-results-modal.survey-results-modal-open {
    display: flex;
}


/* ==================================================
   КОНТЕНТ МОДАЛКИ
================================================== */


.survey-results-modal-content {

    position: relative;

    width: 100%;

    max-width: 650px;

    max-height: 80vh;

    overflow-y: auto;

    overflow-x: hidden;

    background: #fff;

    border-radius: 12px;

    padding: 30px;

    box-sizing: border-box;

    box-shadow:
        0 10px 40px rgba(0, 0, 0, 0.25);
}


/* ==================================================
   ЗАГОЛОВОК
================================================== */

.survey-results-modal-title {
    margin: 0 45px 25px 0;

    font-size: 24px;
    line-height: 1.3;
}


/* ==================================================
   КНОПКА ЗАКРИТТЯ
================================================== */

.survey-results-modal-close {
    position: absolute;

    right: 15px;
    top: 10px;

    width: 38px;
    height: 38px;

    border: 0;

    background: transparent;

    color: #555;

    font-size: 32px;
    line-height: 38px;

    cursor: pointer;

    border-radius: 6px;
}

.survey-results-modal-close:hover {
    background: #f0f0f0;
    color: #222;
}

.survey-results-option img {

    display: block;

    width: auto;

    max-width: 100%;

    height: auto;

    box-sizing: border-box;

    margin: 10px 0;
}




/* ==================================================
   СПИСОК РЕЗУЛЬТАТІВ
================================================== */

.survey-results-modal-body {

    width: 100%;

    max-width: 100%;

    min-width: 0;

    overflow-x: hidden;

    box-sizing: border-box;
}


/* ==================================================
   РЯДОК ВАРІАНТА
================================================== */

.survey-results-row {

    display: flex;

    align-items: flex-start;

    justify-content: space-between;

    gap: 20px;

    width: 100%;

    max-width: 100%;

    min-width: 0;

    box-sizing: border-box;

    padding: 13px 0;

    border-bottom: 1px solid #e5e5e5;

    overflow: hidden;
}

.survey-results-row:last-child {
    border-bottom: 0;
}


/* ==================================================
   ТЕКСТ ВАРІАНТА
================================================== */

.survey-results-option {

    flex: 1;

    min-width: 0;

    max-width: 100%;

    font-size: 17px;

    line-height: 1.45;

    overflow-wrap: anywhere;

    word-break: break-word;

}



/* ==================================================
   КІЛЬКІСТЬ
================================================== */

.survey-results-count {

    flex: 0 0 45px;

    min-width: 45px;

    text-align: right;

    font-size: 18px;

    font-weight: 700;
}

.survey-view-html-answer {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;

    overflow-wrap: break-word;
    word-break: break-word;
}

.survey-view-html-answer img {
    display: block;

    max-width: 100%;
    height: auto;

    box-sizing: border-box;

    margin: 10px 0;
}

.survey-view-html-answer figure {
    max-width: 100%;
    margin: 10px 0;
    box-sizing: border-box;
}


.survey-view-html-answer figure img {
    max-width: 100%;
    height: auto;
}

.survey-view-html-answer table {
    max-width: 100%;
    width: auto;

    border-collapse: collapse;

    overflow-wrap: break-word;
}


/* ==================================================
   ДОВГІ ПОСИЛАННЯ / ТЕКСТ
================================================== */

.survey-view-html-answer a {
    overflow-wrap: anywhere;
}


.survey-view-html-answer p {
    margin-top: 0;
    margin-bottom: 10px;
}

/* ==================================================
   НЕМАЄ РЕЗУЛЬТАТІВ
================================================== */

.survey-results-empty {
    padding: 15px 0;

    color: #777;

    font-size: 16px;
}


/* ==================================================
   МОБІЛЬНА ВЕРСІЯ
================================================== */

@media (max-width: 600px) {

    .survey-results-modal-content {
        padding: 22px;

        max-height: 85vh;
    }

    .survey-results-modal-title {
        font-size: 21px;
    }

    .survey-results-option {
        font-size: 16px;
    }

    .survey-results-count {
        font-size: 17px;
    }

}

.survey-bulk-actions{
    display:flex;
    gap:15px;
    margin-bottom:20px;
}

.survey-select-all-btn{
    padding:10px 20px;
    border:none;
    border-radius:8px;
    background:#3498db;
    color:#fff;
    cursor:pointer;
}

.survey-delete-selected-btn{
    padding:10px 20px;
    border:none;
    border-radius:8px;
    background:#f7d8a8;
    color:#fff;
    cursor:not-allowed;
    opacity:0.6;
    transition:0.2s;
}

.survey-delete-selected-btn.active{
    background:#f39c12;
    opacity:1;
    cursor:pointer;
}

.survey-delete-btn{
    
    padding:8px 15px;
    border:none;
    border-radius:6px;
    background:#e74c3c;
    color:white;
    font-weight: bold;
    cursor:pointer;
    height:50px;
    width:150px;
}

.survey-delete-btn:hover{
    background:#c0392b;
}

.survey-attempt-checkbox{
    width:18px;
    height:18px;
    cursor:pointer;
}

/* ==================================================
   ЗОБРАЖЕННЯ З CKEDITOR В ОПИСІ ОПИТУВАННЯ
================================================== */

.survey-attempts-description img {
    max-width: 100%;
    height: auto;
    box-sizing: border-box;
}