//@import "../var.experience_simple.less";
@import "../bootstrap/mixins";


//@form-inputs-background-color:              @light;                 // Цвет фона элементов ввода
//@form-inputs-border-color:                  @lighten-gray;          // Цвет обводки элементов ввода
//@form-inputs-font-color:                    @dark-blue;             // Цвет шрифта элементов формы
//@form-inputs-font-size:                     @font-size-small;       // Размер шрифта элементов формы

.form-inputs-view() {
    font-size: @form-inputs-font-size !important;
    color: @form-inputs-font-color;
    background-color: @form-inputs-background-color;
    border-color: @form-inputs-border-color !important;
    border-radius: @form-inputs-border-radius;
}

input, textarea, .input-group-addon {
    .form-inputs-view();
}

/** Уберём внутреннюю тень
____________________________*/
.form-control {
    box-shadow: none !important;
}

table.form-control {
    table-layout: fixed;
    line-height: 20px;
    .input-container {
        width: 100%;
        input {
            width: 100%;
            border-bottom: 1px dotted #1c374c;
            .sized();
        }
    }
}

/** Цвет иконок
____________________________*/
.input-group-addon {
//    background-color: @white !important;
    .fa {
        color: @form-inputs-icon;
    }
}

textarea {
    white-space: -moz-pre-wrap;
    white-space: -o-pre-wrap;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.info-container {
    .clearfix();
    margin-bottom: 8px;
    margin-right: 6px;
    color: @main-gray;
    cursor: pointer;
}

/** Радиус углов элементов форм
____________________________*/
.form-control, .input-group-addon, .markItUpHeader {
    .form-inputs-view();
}
.selecter.bottom.open .selecter-selected,
.selecter .selecter-options {
    .form-inputs-view();
}
.selecter.open .selecter-selected,
.selecter.cover .selecter-options .selecter-item.first,
.selecter.cover.open .selecter-selected,
.selecter.bottom.open .selecter-options {
    .form-inputs-view();
}
.selecter.cover .selecter-options,
.selecter.bottom.cover.open .selecter-selected,
.selecter.bottom.cover.open .selecter-options,
.selecter .selecter-selected,
.selecter.multiple .selecter-options {
    .form-inputs-view();

}
.selecter-selected {
    background-color: @form-inputs-background-color !important;
}

.charming-datepicker input {
    background-color: @form-inputs-background-color !important;
}

/** Кнопки сворачиваемых блоков на странице создания топика
_________________________________________________*/
.toggle-block a, .toggle-link {
    font-size: @font-size-small;
//    text-decoration: none;
//    border-bottom: 1px dashed @blue !important;
//    &.active, &:hover {
//        border-bottom: 1px dashed @red !important;
//    }
}



/** Подписи под элементами управления
_________________________________________________*/
.control-notice {
    font-size: @form-inputs-notice-font-size;
}

/** Корректировка шапки редактора
_________________________________________________*/
.markItUpHeader {
    background-color: @white !important;
    .float {
        border-bottom: 1px solid @form-inputs-border-color !important;
    }

}

/** Аплоадер фотографий
_________________________________________________*/
.js-alto-topic-uploader .js-alto-multi-uploader-list:last-child {
    margin-bottom: 12px;
}
.js-alto-topic-uploader .js-files-container {
    max-height: 373px;
    overflow-y: scroll;
    overflow-x: hidden;
    margin-bottom: 6px;
}
.js-alto-multi-uploader-list .js-file-name {
    overflow: hidden;
    text-align: center;
    font-size: 10px;
}
.js-alto-multi-uploader-list .progress {
    margin-bottom: 0 !important;
}
.js-alto-multi-uploader-form, .js-alto-topic-uploader-form {
    position: relative;

    .js-add {
        position: relative;
        overflow: hidden;
    }

    canvas {
        width: 100%;
    }

    .js-file-delete {
        position: absolute;
        top: -6px;
        right: 17px;
        z-index: 999;
        color: @red;
        font-size: 20px;
        opacity: 0;
        cursor: pointer;
        -webkit-transition: opacity .1s ease-in;
        -moz-transition: opacity .1s ease-in;
        transition: opacity .1s ease-in;
    }
    .js-file-reload {
        position: absolute;
        top: -6px;
        left: 17px;
        z-index: 999;
        color: @green;
        font-size: 20px;
        opacity: 0;
        cursor: pointer;
        -webkit-transition: opacity .1s ease-in;
        -moz-transition: opacity .1s ease-in;
        transition: opacity .1s ease-in;
    }

    .progress {
        margin-bottom: 0;
    }

    .js-file-name {
        overflow: hidden;
        text-align: center;
        font-size: 10px;
    }

    .js-file-tpl:hover .js-file-delete,
    .js-file-tpl:hover .js-file-reload {
        opacity: 1;
    }

    .js-file-rotate {
        position: absolute;
        top: 33%;
        left: 50%;
        margin: -16px 0 0 -16px;
        width: 32px;
        height: 32px;
        cursor: pointer;
    }

    .js-file-rotate i {
        font-size: 36px;
    }

    input {
        position: absolute;
        top: -10px;
        left: -10px;
        z-index: 2;
        overflow: hidden;
        font-size: 50px !important;
        opacity: 0;
        cursor: pointer;
        -moz-opacity: 0;
    }
}

.js-uploader-picker {
    padding: 12px;
    border: 1px dashed @main-gray;
}

.js-uploader-picker-hover {
    border: 1px dashed @yellow;
    background: lighten(@yellow, 30);
}

.progress, .progress-bar {
    border: 0;
    border-radius: 0;
}

.photo-preview-state, .js-uploader-item-delete {
    font-size: @font-size-small;
}

.add-photo {
    margin-bottom: 0;
}


/*  Кнопки
_____________________________________________________________*/
.btn {
    // padding-vertical/padding-horizontal//fontsize/line-heigth/border-radius
    .button-size(10px; 12px; @font-size-small; 20px; 0);
    padding: 10+1 12+1;
    border: 0;
}

.btn-light, .btn-default {
    outline: none;
    // color/background/border
    .button-variant(~"@{form-btn-primary-font-color} !important"; @form-btn-primary-background; @form-btn-primary-background);
    border-radius: 0;
    font-size: @form-btn-primary-font-size;

    &:hover,
    &:focus,
    &:active,
    &.active,
    .open .dropdown-toggle & {
        border-color: @form-btn-primary-active-background;
        background-color: @form-btn-primary-active-background;
    }
}

.open .btn-default {
    background-color: @light-gray !important;
}

.btn-blue, .btn-primary {
    outline: none;
    .button-variant(~"@{form-btn-default-font-color} !important"; @main-gray; darken(@main-gray, 5%));
    border-radius: 0;
    font-size: @form-btn-primary-font-size;
}

.btn-gray{
    i {
        color: @form-btn-gray-font-color !important;
        margin-right: 4px;
    }
    outline: none;
    .button-variant(~"@{form-btn-gray-font-color} !important"; @form-btn-gray-background-color; @form-btn-gray-background-active-color);
    border-radius: 0;
    font-size: @form-btn-primary-font-size;
}

.input-group-addon .btn, .input-group-addon.btn  {
    padding: 7px 12px 6px 12px !important;
}
.modal .input-group-addon.btn-file {
    background-color: @form-inputs-background-color !important;
    border-color: @form-inputs-border-color !important;
    border: 1px solid @form-inputs-border-color  !important;
    border-radius: 0 @form-inputs-border-radius @form-inputs-border-radius 0 !important;
    border-left: 0 !important;

}

.fileinput .form-control {
    white-space: nowrap;
    position: relative;
    line-height: 19px;
    overflow: hidden;
    .fileinput-filename {
        width: 100%;
        text-overflow: ellipsis;
        padding-right: 12px;
    }
}