/*  ############## */
/*  ### GENERAL ### */
/*  ############## */

/**
 * Стиль placeholder'а в IE по умолчанию не информативен.
 * Исправим на стиль, который использует bootstrap 4.
 */
:-ms-input-placeholder {
    color: #636c72 !important;
    font-weight: normal !important;
}

input::-ms-clear {
    display: none;
}

input:disabled {
    background-color: #eee;
    opacity: 1;
    cursor: not-allowed;
}

.ext-js-panel {
    padding: 5px;
    border: 1px solid #d0d0d0;
    background-color: #f1f1f1;
}

.textarea {
    overflow: auto;
    margin: 0;
    background-color: white;
    height: 6.25em;
}

.main-textarea {
    display: block;
    font-size: .875em;
    min-height: 2em;
    width: 100%;
    padding: 2px;
    border: 1px solid #a9a9a9;
    resize: vertical;
    transition: box-shadow .5s ease-out, border-color .5s ease-out;
}

.textarea > p {
    margin: 0;
}

.main-textarea:hover {
    border-color: #ddd;
    transition: border-color .25s ease-out;
}

.main-textarea:focus {
    outline: none;
    border-color: #333;
    transition: border-color .25s ease-out;
}

.main-textarea.invalid {
    box-shadow: inset 0 0 2px 0 rgb(210, 0, 20);
    border-color: rgb(210, 0, 20);
    transition: box-shadow .25s ease-out, border-color .25s ease-out;
}

.checkbox-container {
    display: block;
    margin: 1em 0;
}

.checkbox-wrapper {
    /*margin: 0 2px;*/
}

.checkbox-wrapper > input.main-checkbox {
    position: absolute; /* take it out of document flow */
    opacity: 0; /* hide it */
}

.checkbox-wrapper > input.main-checkbox + label {
    position: relative;
    cursor: pointer;
    margin: 0;
    padding: 0;
    font-weight: bold;
}

.checkbox-wrapper > input.main-checkbox + label:before {
    content: '';
    margin-right: 10px;
    display: inline-block;
    vertical-align: middle;
    width: 20px;
    height: 20px;
    background: white;
    border: 1px solid #bbb;
}

.checkbox-wrapper > input.main-checkbox:hover + label:before {
    background: #714e9a;
}

.checkbox-wrapper > input.main-checkbox:focus + label:before {
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.12);
}

.checkbox-wrapper > input.main-checkbox:checked + label:before {
    background: #714e9a;
}

.checkbox-wrapper > input.main-checkbox:checked + label:after {
    content: '';
    position: absolute;
    left: 5px;
    top: 10px;
    background: white;
    width: 2px;
    height: 2px;
    box-shadow: 2px 0 0 white,
    4px 0 0 white,
    4px -2px 0 white,
    4px -4px 0 white,
    4px -6px 0 white,
    4px -8px 0 white;
    -webkit-transform: rotate(45deg);
    transform: rotate(45deg);
}

.checkbox-wrapper > input.main-checkbox:disabled + label {
    color: #b8b8b8;
    cursor: auto;
}

.checkbox-wrapper > input.main-checkbox:disabled + label:before {
    box-shadow: none;
    background: #ddd;
}

select + .input {
    position: relative;
    display: inline-block;
}

select + .input > input {
    outline: none;
    box-shadow: none;
    width: calc(100% - 1.75em);
    border-right: none !important;
}

select + .input > input[readonly] {
    cursor: pointer;
}

select + .input > .button-toggle {
    width: 1.75em;
    position: absolute;
    top: 0;
    bottom: 0;
    right: 0;
    margin-right: 0;
    padding: 0;
}

.ui-combobox-disabled > * {
    background-color: #eee;
    opacity: 1;
    cursor: not-allowed;
}

.err-label {
    display: inline-block;
    position: absolute;
    text-align: left;
    font-size: .85em;
    font-weight: bold;
    white-space: normal;
    color: orangered;
    border-radius: 5px;
    margin-right: 15px;
    padding: 1px 4px;
}

.err-label > .err-label__inner {
    display: inline-block;
    line-height: normal;
    vertical-align: middle;
}

.input-container__item > input[type="file"] {
    width: 0.1px;
    height: 0.1px;
    opacity: 0;
    overflow: hidden;
    position: absolute;
    z-index: -1;
}

.input-container__item > input[type="file"] + label {
    cursor: pointer;
}

.input-container__item > input[type="file"]:focus + label {
    outline: -webkit-focus-ring-color auto 5px;
}

.property-list {
    margin: 0 auto;
    padding: .3em .25em 1.25em;
}

.property-list > li {
    list-style: none;
    overflow: hidden;
    margin: .25em 0;
    padding: .3em;
    display: flex;
    flex-flow: row wrap;
    align-items: center;
    justify-content: space-between;
}

.property-list > li .property-label {
    text-align: right;
    width: 38%;
    margin: 0 2% 0 0;
}

.property-list > li .property-value {
    box-sizing: border-box;
    flex-grow: 1;
}

.input-style-survey {
    height: 2.5em;
    padding: 0.25em 0.5em;
    color: #555;
    background-color: #fff;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);
    transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;
}

.input-style-survey:focus {
    box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 8px rgba(102, 175, 233, 0.6);
    border-color: #66afe9;
    outline: 0;
}

.ui-autocomplete {
    font-size: .8em;
    max-height: 33%;
    overflow-x: hidden;
    overflow-y: auto;
    padding: 2px 0;
    box-shadow: 0 0 3px #aaa;
    z-index: 1051;
}

@media (max-width: 480px) {
    .err-label {
        display: none;
    }
    .input-container__item.flexible {
        display: -webkit-flex;
        display: flex;
        flex-direction: column;
        text-align: left !important;
    }
    .input-container__item.item-row {
        flex-direction: column;
        align-items: normal;
    }
}