.CategClass div:first-child {
    height: auto !important;
    /*width: 98%;*/
}

div#idn-sections-pane {
    max-height: 310px;
    overflow-y: auto;
    margin-bottom: 5px;
    background: #F0F0F0;
    width: 98%;
    vertical-align: top;
    /*line-height: 25px;*/
}

/* Стили для кроссворд формы */
.cross-form-container {
    width: 100%;
    max-width: 700px;
    box-sizing: border-box;
    margin: 0 auto;
}

.cross-form-row {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 15px;
    /*justify-content: center;*/
}

.cross-form-label {
    width: 80px;
    padding: 8px 10px 8px 0;
    /*text-align: right;*/
}

.cross-form-field {
    flex: 1;
    min-width: 200px;
    padding: 8px 0;
    display: flex;
    /*justify-content: center;*/
}

.cross-form-input {
    width: 100%;
    max-width: 100%;
    padding: 5px;
    box-sizing: border-box;
    text-align: left;
}

.cross-source-option {
    margin-bottom: 10px;
    display: block;
    /*text-align: center;*/
}

.cross-source-label {
    font-size: 16px;
    font-weight: bold; /* Добавлено */
}

.cross-form-label label {
    font-weight: bold; /* Добавлено — для всех label внутри .cross-form-label */
}

/* Стили для выпадающих списков */
.cross-form-field select {
    margin: 0 auto;
    display: block;
    text-align: left;
    width: 100%;
    max-width: 100%;
}

.sections-loader, .sections-pane {
    margin: 10px 0;
    /*text-align: center;*/
}

.ad-container {
    margin: 10px 0;
    text-align: center;
}

.button-container {
    margin: 15px 0;
    width: 100%;
    display: flex;
    /*justify-content: center;*/
}

.CategClass {
    max-width: 100%;
    overflow: hidden;
    box-sizing: border-box;
}

/* Центрирование файлового input */
input[type="file"] {
    margin: 0 auto;
    display: block;
}

/* Текст в option по левому краю */
select option {
    text-align: left;
    direction: ltr;
}

/* Выравнивание выбранного значения по правому краю (работает везде) */
#idn-wordcount {
    text-align: right;
}

/* Попытка выровнять опции в выпадающем списке (работает в Firefox и частично в других) */
#idn-wordcount option {
    text-align: right;
    direction: rtl;
    text-align-last: right;
}

/* Специальные стили для строки "Число слов" — всегда в одной строке */
#idn-wordcount-row {
    flex-wrap: nowrap; /* Запрещаем перенос на новую строку */
    align-items: center;
}

#idn-wordcount-row .cross-form-label {
    flex: 0 0 auto;
    width: auto;
    min-width: 120px; /* Компактная, но читаемая ширина */
    padding-right: 10px;
    text-align: left;
}

#idn-wordcount-row .cross-form-field {
    flex: 1;
    min-width: auto;
    justify-content: flex-start;
}

#idn-wordcount-row .cross-form-field select {
    max-width: 60px; /* Ограничиваем ширину select, чтобы не растягивался */
    text-align: right;
}

@media (max-width: 768px) {
    .cross-form-row {
        align-items: center;
    }

    .cross-form-label {
        width: 100%;
        text-align: center;
        padding: 8px 0;
    }

    .cross-form-field {
        width: 100%;
        justify-content: center;
    }

    .cross-form-field select {
        width: 100%;
        max-width: none;
    }

    #idn-wordcount-row {
        flex-direction: row !important;
        align-items: center;
    }

    #idn-wordcount-row .cross-form-label {
        width: auto;
        flex: 0 0 120px;
        text-align: left;
        padding: 8px 10px 8px 0;
    }

    #idn-wordcount-row .cross-form-field {
        flex: 1;
        min-width: auto;
        justify-content: flex-start;
    }

    #idn-wordcount {
        max-width: 60px;
        text-align: right;
    }
}
#idn-sections-pane li {
    display: flex;
    align-items: center;
}

#idn-sections-pane label {
    display: flex;
    justify-content: space-between;
    width: 100%;
}

#idn-sections-pane .section-name {
    text-align: left;
}

#idn-sections-pane .section-count {
    text-align: right;
    margin-left: 10px;
}



#idn-sections-pane > li > input {
    float: left;
    margin-top: 1px;

}

#idn-sections-pane > li:hover {
    background-color: #FFF09E;
}

#idn-sections-pane > li > label {
    display: block;
    margin-left: 1.7em;
    margin-top: 0px;
    /*margin-top:0.25em;*/
}

#idn-sections-pane > li {
    list-style-type: none;
    /* Убираем маркеры */
    padding-top: 4px;
    padding-bottom: 4px;
}

/*.chkLabel input { float: left; margin-top:0.5em;}*/
/*.chkLabel label { display: block; margin-left: 1.5em;}*/

.cross_cat_selector {
    padding-bottom: 0px;
}


.sharedBlock {

}

.SharedMessageBlock {
    display: none;
    text-align: center;
    font: bold 16px Arial;
    padding: 11px 0;
}

.SharedForm {

}

.clr {
    clear: both;
}

td.FillTD label {
    float: left;
    width: 114px;
    margin: 3px 0 0 0;
}

td.FillTD input {
    float: left;
    width: 250px
}

.HistoryButton {
    border: 0px;
    background: none;
    font-weight: bold;
    cursor: pointer;
    text-decoration: none;
    color: black !important;
    padding: 0 20px 0 0
}

.HistoryButtonActive {
    color: blue !important;;
}

.HistoryForm {
    display: inline;
}

#sectionsLoader {
    display: none;
}

#chk_on_input {
    display: none;
    position: relative;
    top: 3px;
}

#chk_off_input {
    position: relative;
    display: none;
}

.slink {
    cursor: pointer !important;
    color: #737373;
    padding: 8px;
    border: 1px solid #737373;
    background-color: #FFF;
}

#frm_on_off > input:checked + label {
    background-color: lightyellow;
    border: 1px solid #737373;
    cursor: default;
}


#chk_on_label {
    margin-right: 10px;
}

.alpha_del {
    font-size: 14px;
    font-weight: bold;
    margin-top: 15px;
}

.leftcount {
    margin-right: 3px;
}

.cat_centeridze {
    padding-right: 5px;
}

.animation_picture {
    opacity: 0;
    position: absolute;
    left: 32px;
}

.CrossImage {
    min-width: 200px;
}

.adsense_cross_vopr {
    display: block;
    float: left;
    margin: 3px 20px 3px 3px;
    width: 300px;
    height: 600px;
}

.rklm_cross {
    margin: 0 auto;
}

.adsense_cross_wide {
    width: 728px;
    height: 90px;
}

.adsense_cross_form {
    /*	width: 728px;
        height: 90px;*/
    padding: 10px 0 10px 0;
}

.adsense_cross_hist {
    padding-top: 10px;
}

.cat_centeridze {
    width: 50%;
    vertical-align: top;
}

.cat_centeridze div {
    margin-bottom: 6px;
}

.cat_centeridze div .leftcount {
    float: left;
}

.cat_centeridze div a {
    /*        display:block;*/
}

.send_button {
    margin: 0 5px;
    cursor: pointer;
}

#form_cross_creat {
    border-collapse: collapse;
    width: 100%;
    margin-top: 20px;
}

#form_cross_creat td {
    border: 1px solid graytext;
    text-align: center;
    padding: 3px;
}

.list_pay {
    background-color: lightgreen;
}

.CrossImage {
    min-width: 300px;
}

#idn-wordcount, #idn-form-words {
    font-size: 26px;
}

.button-helper {
    display: inline-block;
    vertical-align: middle;
    height: 100%;
    width: 0px;

}

img.img_text.show {
    vertical-align: middle;
    padding: 2px 2px;
    width: 40px;
}

.img_link {
    text-decoration: none; /* Убирает подчеркивание */
}

.image-button {
    opacity: 0.3;
    float: left;
    height: 45px;
    /*background: #eee;*/
    line-height: 18px;
    display: inline-block;
    vertical-align: middle;
    zoom: 1;
}

.button-text {
    opacity: 0;
    display: none;
    /*line-height: 20px;*/
}

.additional_buttons {
    position: absolute;
    z-index: 3;
    /*width: 700px;*/
}

.additional_buttons .active {
    opacity: 1;
    background: white;
}

.additional_buttons .active .button-text {
    opacity: 1;
    display: inline;
}

#cross_field {
    margin-top: 20px;
    margin-left: 14px;
}


#grid_div img {
    margin-left: 14px;
}

@media (max-width: 700px) {
    #grid_div img {
        margin-left: 0px;
    }
}


select#idn-category {
    width: 100%;
}

.mobile {
    display: inline-block;
    float: left;
}

.mobile div {
    opacity: 1 !important;
}

.mobile .img_text {
    opacity: 0.8 !important;
}

.mobile .image-button {
    vertical-align: middle;
}

.mobile .image-button .button-text {
    opacity: 1 !important;
    width: 260px;
    vertical-align: middle;
}

/*    .mobile .button-text{
        opacity: 1;
        display: inline;
    }*/
.mobile .additional_buttons {
    /*position: relative;*/
    left: 0;
}

.mobile .button-text {
    /*display: none !important;*/
    display: none;
    opacity: 1;
    width: 600px;
    background: #efefef;
    padding: 3px;
    border: solid 1px #232323ee;
}





#cross_field {
    margin-left: 14px;
}

.FillPassBlock {
    margin: 5px;
}

td.cross_source_list {
    line-height: 2em;
}


.preview_cross_table {
    border: 1px solid graytext;
    text-align: center;
    /*width: 5%;*/
    /*white-space: nowrap;*/
}

.no_wrap_cell {
    white-space: nowrap;
}


.cross_image_block {
    position: relative;
    display: inline-block;
}

#idn-cross-img-fill {
    transition: opacity 0.3s ease; /* плавное переключение */
}



.cross-container {
    position: relative;
    display: inline-block;
}

.image-wrapper {
    position: relative;
    display: inline-block;
}


#cross_field {
    position: relative;
    display: inline-block;
}

#setka {
    position: absolute;
    background-image: url(/img/square.png);
    z-index: 2;
    padding: 20px 19px;
    color: #004183;
    opacity: 0.2;
    border: 1px solid #004183;
    margin-left: -20px;
    margin-top: -20px;
    pointer-events: none;
}

#CrossTableBlock {
    padding: 10px 20px 10px 10px;
}

.questions-container {
    margin-top: 20px;
    line-height: 26px;
}


#frm_on_off {
    text-align: center;
    padding-bottom: 20px;
    padding-top:15px;
}

.passwordRtf {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none; /* убираем подчёркивание, если нужно */
    color: inherit; /* наследуем цвет текста родителя */
    margin-bottom: 20px;
}

.passwordRtf:hover {
    color: #007acc; /* пример hover-эффекта */
}

.rtf-icon {
    width: 40px;
    height: auto;
    flex-shrink: 0;
}