.btn {
    border-radius: @button-radius;
}

.panel-heading {
    padding: 6px 10px;
}

.panel-body {
    padding: @panel-padding;
    .clearfix();
}

blockquote {
    font-size: @font-size-base;
}

.pagination-sm > li > a {
    line-height: @line-height-small;
}

.preset {
    text-overflow: ellipsis;
    overflow: hidden !important;
}

.preset > div{
    padding-right: 20px;
}

.modal-header {
  padding: 10px 14px;
  border-bottom: 1px solid @modal-header-border-color;
  min-height: (10px + @modal-title-line-height);
}

.modal-footer {
    margin-top: 10px;
    padding: @panel-padding @panel-padding @panel-padding;
}

.modal-footer .btn.pull-left {
    margin-left: 0;
    margin-right: 0;
}

.table thead > tr > th {
    border-bottom: 1px solid @table-border-color;
    font-weight: normal;
}

.form-group {
  margin-bottom: 12px;
}

.form-group.hidden-cell {
    margin-bottom: 0;
}

.hidden-cell div.field {
    display: none !important;
}

.hidden-cell label.control-label {
    display: none !important;
}

.panel-group .panel + .panel {
    margin-top: 4px;
}

.alert {
    padding: 5px 18px;
}

label {
  margin-bottom: 3px;
}

.table {
    margin-bottom: 10px;
}

.page-header {
  margin: 10px 0;
  border-bottom: 0;
  padding-bottom: 2px;
  min-height: 33px;
}

.modal-header {
    background-color: @default-heading-bg-color;
}

div.list-expanded > ul > li > div.expanded-row > .cell {
    padding-left: 6px;
    padding-right: 3px;
    border-left: 1px solid @default-border-color;
}

div.list-expanded > ul > li > div.expanded-row > .cell:first-child {
    padding-left: 0;
    border-left: 0;
}

.list .checkbox-dropdown {
    margin-right: -10px;
    top: 1px;
    margin-top: -2px;
}

.list .checkbox-dropdown > a {
    padding: 0;
}

.list > table.table td > span.glyphicon,
.list > ul.list-group > li.list-row .cell > span.glyphicon {
    line-height: @line-height-computed;
}

.list > table.table td > span.glyphicon.pull-right,
.list > ul.list-group > li.list-row .cell > span.glyphicon.pull-right {
    margin-left: 5px;
}

table.table > thead th > a {
    color: @gray-light;
}

table.table > thead th {
    color: @gray-light;
}


.cell label,
.filter label {
    color: @gray-light;
    font-weight: normal;
}

.cell > label,
.filter label {
    margin-bottom: 2px;
}


.btn.active {
    box-shadow: none;
}

.navbar-inverse {
    border-bottom-width: 0 !important;
}

@media screen and (min-width: @screen-sm-min) {
    .navbar .navbar-header {
        width: 181px;
    }
}

.navbar .navbar-header a.navbar-brand {
    margin-left: auto;
    margin-right: auto;
}

.navbar-brand {
    padding: 0;
    width: @logo-width;
    height: @logo-height;
}

.navbar img.logo {
    max-height: 100%;
    max-width: 100%;
}

#login.panel .panel-heading {
    border-bottom-width: 0;
}

#login .logo-container {
    width: @logo-width;
    height: @logo-height;
}

#login .logo-container img.logo {
    max-height: 100%;
    max-width: 100%;
}

#global-search-input {
    width: 145px;
    margin-top: 1px;
    padding-right: 10px;
}

.progress.pre-loading {
    margin-top: -50px;
    margin-bottom: 31px;
}

.edit form {
    margin: 0;
}

.button-container {
    padding: 0 0 10px;
}


.margin {
    margin: 8px 0;
}

ul.dropdown-menu > li.checkbox {
    margin-left: 0;
    margin-top: 0;
    margin-bottom: 0;
    padding: 3px 0 3px 20px;

    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

ul.dropdown-menu > li.checkbox:last-child {
    margin-bottom: 3px;
}

.page-header h3 {
    margin-top: 0px;
    margin-bottom: 8px;
}

.page-header .breadcrumb-separator {
    padding: 0 6px;
}

.modal-header a {
    color: @text-color;
}

.list-buttons-container > div {
    float: left;
    margin-right: @panel-padding;
}

.list-buttons-container > div.total-count {
    margin-right: 0px;
    float: right;
    padding: 6px 0;
}

.list-container .pagination {
    margin: 0;
}

.floated-row > div  {
    float: left;
    margin-right: @panel-padding;
}

.search-row {
    margin-left: -3px !important;
    margin-right: -3px !important;
}

.search-row > div {
    padding-left: 2px !important;
    padding-right: 2px !important;
}

.btn-icon > span {
    margin: 0 20px;
}

.cell > .field {
    overflow-wrap: break-word;
    word-wrap: break-word;
}

.field .row {
    margin-left: -5px !important;
    margin-right: -5px !important;
}

.field .row > div {
    padding-left: 5px !important;
    padding-right: 5px !important;
    float: left;
}

.field .form-control, .field .btn {
    margin-bottom: 3px;
}

.field .input-group .form-control, .field .input-group .btn {
    margin-bottom: 0;
}

.field .input-group {
    margin-bottom: 3px;
}

.field .link-container {
    margin-bottom: -1px;
}

.field .link-container .list-group-item > div {
    margin: -3px 0 -3px;
}

.field .link-container .list-group-item > div > div {
    margin: 6px 0;
}

.field .link-container .list-group-item .form-control,
.field .link-container .list-group-item .btn {
    margin-top: 1px;
    margin-bottom: 1px;
}

.filter > .form-group .field {
    .link-container {
        font-size: @font-size-small;
    }
    .input-group {
        input {
            font-size: @font-size-small;
            height: @input-height-small;
        }
        button.btn {
            font-size: @font-size-small;
            height: @input-height-small;
        }
    }
}

.field .link
-container .list-group-item .form-control {
    width: 140px !important;
}

.filter .field .link-container .list-group-item a {
    margin-top: 1px;
}

.field .link-container .list-group-item a {
    margin-top: 1px;
}

.field .link-container .list-group-item.link-with-role a {
    margin-top: 6px;
}

.detail-field-container {
    padding: 7px 0;
}

#login.panel > .panel-heading {
    background-color: @login-panel-heading-bg;
    padding: 0;
    margin: -2px;
}

@media screen and (max-width: @screen-sm-min) {
    .modal-dialog {
        margin: 10px 0;
    }
    .modal-dialog .image-container {
        margin-left: -@panel-padding;
        margin-right: -@panel-padding;
    }
}

@media screen and (min-width: @screen-sm-min) {
    .modal-dialog {
        width: 740px !important;
    }
}
@media screen and (min-width: @screen-md-min) {
    .modal-dialog {
        width: 900px !important;
    }
}

table.table > tbody td > .list-row-buttons button {
    position: relative;
    margin-top: 2px;
}

.list-row-buttons span.caret {
    border-top-color: #999;
}

.list > table {
    margin-bottom: 0;
}

.list > ul {
    margin-bottom: 0;
}

.list > table td input[type="checkbox"],
.list > table th input[type="checkbox"] {
    margin: 0;
    position: relative;
    top: 2px;
}

.list > table th input[type="checkbox"] {
    margin: 0;
    position: relative;
    top: 3px !important;
}

.list > table th span.caret {
    border-top-color: #999;
}
.list > table th span.caret-up {
    border-bottom-color: #999;
}

.filter a.remove-filter {
    display: none;
}
.filter:hover a.remove-filter {
    display: block;
}

select[multiple].input-sm {
    height: 90px !important;
}

.input-group-btn > select.form-control {
    position: relative; 
    display: inline-block;
    width: auto;
    vertical-align: middle;
    margin-right: -1px;
}

.input-group-btn:last-child > select.form-control {
    margin-right: 0;
    margin-left: -1px;
}

.input-group .form-control:focus {
    z-index: 3;
}

.panel-body > div > .list-expanded {
    margin-left: -@panel-padding;
    margin-right: -@panel-padding;
}
.panel-body > div > .list {
    margin-left: -@panel-padding;
    margin-right: -@panel-padding;
}
.panel-body > div > .list > table td:first-child,
.panel-body > div > .list > table th:first-child {
    padding-left: @panel-padding;
}
.panel-body > div > .list > table td:last-child,
.panel-body > div > .list > table th:last-child {
    padding-right: @panel-padding;
}

.panel-body > .no-margin {
    margin: -@panel-padding;
}

.panel-body .no-side-margin {
    margin-left: -@panel-padding;
    margin-right: -@panel-padding;

    > table td:first-child,
    > table th:first-child {
        padding-left: @panel-padding;
    }

    > table td:last-child,
    > table th:last-child {
        padding-right: @panel-padding;
    }
}

.panel-body .no-bottom-margin {
    margin-bottom: -@panel-padding;
}

.table.less-padding > thead > tr > th,
.table.less-padding > tbody >tr > th,
.table.less-padding > tfoot >tr > th,
.table.less-padding > thead >tr > td,
.table.less-padding > tbody >tr > td,
.table.less-padding > tfoot >tr > td {
    padding: @table-cell-padding @table-cell-padding/2 @table-cell-padding @table-cell-padding/2;
}

.panel > .panel-body > .list-container > .list > .list-group {
    > .list-group-item {
        border-width: 0;
        border-bottom-width: 1px;
    }
    > li.list-group-item:first-child {
        border-top-width: 1px;
    }
    > li.list-group-item:last-child {
        border-bottom-width: 0;
    }
}


.record {
    .panel-warning {
        > .panel-heading {
            background-color: @state-warning-border;
            .btn-warning {
                color: @panel-warning-text;
                background-color: @state-warning-border;
                border-color: @state-warning-border;
            }
        }
    }
    .panel-danger {
        > .panel-heading {
            background-color: @state-danger-border;
            .btn-danger {
                color: @panel-danger-text;
                background-color: @state-danger-border;
                border-color: @state-danger-border;
            }
        }
    }
    .panel-info {
        border-color: @state-info-bg;
        > .panel-heading {
            color: @panel-info-text;
            background-color: @state-info-bg;
            .btn-info {
                color: @panel-info-text;
                background-color: @state-info-bg;
                border-color: @state-info-bg;
            }
        }
    }
    .panel-success {
        > .panel-heading {
            background-color: @state-success-border;
            .btn-success {
                color: @panel-success-text;
                background-color: @state-success-border;
                border-color: @state-success-border;
            }
        }
    }
}

table.no-margin {
    margin-bottom: 0;
}

.list-expanded > .show-more {
    padding: 0px;
    margin-top: -1px;
}

.list-expanded > li.show-more > .btn {
    margin-left: -1px;
    margin-right: -4px;
}

.list-expanded > ul > li .list-row-buttons {
    margin-right: -12px;
    margin-top: -10px;
}

.show-more > .btn {
    border-radius: 0;
    border-width: 0;
    border-color: #e0e0e0;
}

.panel-body > div:first-child > .list-expanded:first-child {
    margin-top: -@panel-padding;
}
.panel-body > div:last-child > .list-expanded:last-child {
    margin-bottom: -@panel-padding;
}

.panel-body > div:first-child > .list:first-child {
    margin-top: -@panel-padding;
}
.panel-body > div:last-child > .list:last-child {
    margin-bottom: -@panel-padding;
}

.expanded-row {
    white-space: nowrap;

    overflow: hidden;
}

#notifications-panel .expanded-row {
    white-space: normal;
    overflow: hidden;
}

#notifications-panel .right {
    padding-top: 5px;
}

.expanded-row .cell {
    display: inline-block;
}

.caret-up {
    display: inline-block;
    width: 0;
    height: 0;
    margin-left: 2px;
    vertical-align: middle;
    border-bottom: 4px solid #000;
    border-right: 4px solid transparent;
    border-top: 0 dotted;
    border-left: 4px solid transparent;
    content: "";
}

.list > table {
    table-layout: fixed;
}

.list > table td,
table.list th {
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
}

.list > table td > div.field {
    white-space: normal;
}

.list > table td.cell[data-name="buttons"] {
    overflow: visible;
}

td.cell[data-name="buttons"] > .btn-group {
    margin-top: -8px;
    margin-bottom: -8px;
    margin-right: -10px;
}

.dashboard-header .dashboard-buttons {
    margin-left: 10px;
}

.panel.dashlet > .panel-heading > .menu-container {
    margin-top: -8px;
    right: -10px;
}

.panel.dashlet > .panel-heading > .panel-title {
    cursor: default;
}

.panel.dashlet {
    height: inherit;
}
.dashlet-container {
    overflow-y: hidden;
}

.panel.dashlet > .panel-body {
    overflow-y: auto;
    overflow-x: hidden;
}

.dashlets.grid-stack {
    .panel.dashlet {
        margin-bottom: 0;
    }

    .grid-stack-item {
        .dashlet {
            height: 100%;
            .dashlet-body {
                height: ~"calc(100% - 29px)";
            }
        }
    }

    .ui-resizable-handle:before {
        content: '' !important;
    }
}

.grid-stack.grid-stack-4 {
    .grid-stack-item[data-gs-width="4"]  { width: 100% }
    .grid-stack-item[data-gs-width="3"]  { width: 75% }
    .grid-stack-item[data-gs-width="2"]  { width: 50% }
    .grid-stack-item[data-gs-width="1"]  { width: 25% }

    .grid-stack-item[data-gs-x="3"]  { left: 75% }
    .grid-stack-item[data-gs-x="2"]  { left: 50% }
    .grid-stack-item[data-gs-x="1"]  { left: 25% }
}

.panel-heading > .btn-group {
    top: -7px;
    right: -11px;
}

.list-container + .button-container {
    margin-top: 6px;
    padding-bottom: 0;
}

.list-expanded > li > .right > .btn-group {
    top: -7px;
    right: -11px;
}

.panel.note-editor {
    border: 1px solid @input-border;
    border-width: 1px;
}

.note-editor .note-toolbar {
    border-bottom: 0 !important;
    background-color: transparent;
}

.note-editor .panel-heading {
    padding: 0px 5px 2px 5px;
}

.note-editor .panel-heading > .btn-group {
    right: 0;
    top: 0;
}

.panel-body.no-padding {
    padding-left: 0 !important;
    padding-top: 0 !important;
    padding-right: 0 !important;
    padding-bottom: 0 !important;
}

.panel {
    border-width: 2px;
}

.panel-heading > .btn-group > .btn {
    border-radius: 0 !important;
}

.list > table thead > th {
    border-top-width: 1px !important;
}

.show-more > .btn-block {
    text-align: left;
    padding-left: @panel-padding;
}

.autocomplete-suggestions { border: 1px solid #999; background: #FFF; cursor: default; overflow: auto; -webkit-box-shadow: 1px 4px 3px rgba(50, 50, 50, 0.64); -moz-box-shadow: 1px 4px 3px rgba(50, 50, 50, 0.64); box-shadow: 1px 4px 3px rgba(50, 50, 50, 0.64); }
.autocomplete-suggestion { padding: 2px 5px; white-space: nowrap; overflow: hidden; }
.autocomplete-selected { background: #F0F0F0; }
.autocomplete-suggestions strong { font-weight: normal; color: #3399FF; }

.gray-box {
    background-color: @gray-lighter;
    margin: 0 5px 3px 0;
    padding: 3px 3px 3px 5px;
}

.gray-box .preview {
    overflow: hidden;
    display: inline-block;
}

.attachment-preview {
    display: inline-block;
    vertical-align: top;
    margin: 3px 6px 3px 0;
}

.field > .attachment-preview {
    overflow: hidden;
}

.attachment-block {
    display: block;
    vertical-align: top;
}

.stick-sub {
    position: fixed;
    top: 0;
    margin: 44px 0 0;
    z-index: 4;
}

.stick-sub.button-container {
    background-color: @body-bg;
    padding: 3px @container-padding*2 3px 0;
    width: 100%;
}

@media screen and (max-width: @screen-sm-min) {
    .stick-sub {
        margin-top: 0;
    }
}

@font-face {
     font-family: Open Sans;
     src: url('../fonts/open-sans-regular.eot?') format('eot'),
          url('../fonts/open-sans-regular.woff') format('woff'),
          url('../fonts/open-sans-regular.ttf')  format('truetype'),
          url('../fonts/open-sans-regular.svg#svgFontName') format('svg');
}

.badge-circle {
    width:8px;
    height:8px;
    border-radius: 4px;
    text-align: center;
    display: table-cell;
    font-size: 5px;
    line-height: 8px;
    text-align: center;
    background-color: @main-gray;
}

.badge-circle.badge-circle-danger {
    background-color: @brand-danger;
}
.badge-circle.badge-circle-warning {
    background-color: @brand-warning;
}

.danger.glyphicon {
    color: @brand-danger;
}

.warning.glyphicon {
    color: @brand-warning;
}


body > footer {
    background-color: @gray-lighter;
}


body > footer > p {
    padding: 6px @panel-padding;
}
body > footer > p.credit {
    margin: 0;
}
body > footer > p,
body > footer > p a,
body > footer > p a:hover,
body > footer > p a:active,
body > footer > p a:visited {
    color: @gray;
}

.navbar-right {
    margin-right: -2px !important;
}

.navbar-collapse {
    overflow-x: hidden !important;
}

.navbar-form.global-search-container {
    padding-left: 0;
    padding-right: 0;
}

#global-search-panel > .panel > .panel-body {
    max-height: 294px;
    overflow-y: auto;
    overflow-x: hidden;
    padding-bottom: @panel-padding;
}

#notifications-panel > .panel > .panel-body {
    max-height: 294px;
    overflow-y: auto;
    overflow-x: hidden;
}

@media screen and (max-width: @screen-sm-min) {
    .list {
        width: auto;
        overflow-y: hidden;
        overflow-x: scroll;
    }
    .list.list-expanded {
        width: auto;
        overflow-x: hidden;
    }
    .list > table {
        min-width: @screen-sm-min;
    }
}


.modal.in .modal.in {
    overflow: visible !important;
    overflow-y: visible !important;
}

.record .middle > .panel:first-child {
    margin-top: 0;
    border-top-width: 2px;
}

.record .middle > .panel {
    margin-top: -1 * @line-height-computed;
    border-top-width: 0;
    > .panel-heading {
        .btn-group {
            top: -6px;
            .btn {
                border-top-width: 0;
            }
        }
    }
}

.panel.sticked,
.panel.sticked {
    margin-top: -1 * @line-height-computed;
    border-top-width: 0;
    > .panel-heading {
        .btn-group {
            top: -6px;
            .btn {
                border-top-width: 0;
            }
        }
    }
}

.stream-head-container {
    padding-bottom: 3px;
}

.stream-head-text-container {
    padding-left: 26px;
}

.stream-head-container > img.avatar {
    display: inline-block;
    margin-top: -3px;
    margin-right: 3px;
    margin-bottom: -2px;
}

.stream-head-container .internal-badge {
    position: absolute; top: 34px; left: 19px;
}

.stream-head-container .internal-badge > span {
    color: @brand-danger;
}

img.avatar.avatar-link {
    display: inline-block;
    margin-top: -2px;
    margin-right: 3px;
}

stream-head-text-container .span {
    overflow-wrap: break-word;
    word-wrap: break-word;
}

.stream-post-container .cell-post {
    overflow-wrap: break-word;
    word-wrap: break-word;
}

.stream-post-container,
.stream-attachments-container,
.stream-details-container,
.stream-subject-container,
{
    padding: 2px 0 5px 26px;
}

.link-container .list-group-item {
    padding: @padding-base-vertical @padding-base-horizontal;
    line-height: @line-height-computed;
}

.list-group-item {
    background-color: transparent;
}

.note-editable blockquote {
    font-size: @font-size-base;
}

.legend-container table td {
    padding: 2px 2px;
    line-height: 1em;
}

.textcomplete-item a {
    cursor: default;
}

.complext-text a {
    word-wrap: break-word;
}

#popup-notifications-container {
    overflow-y: auto;
    overflow-x: hidden;

    right: 0px;
    bottom: 0px;
    position: fixed;
    height: auto;
    z-index: 1000;

    float: right;
}

.popup-notification {
    width: 400px;
    padding: 14px;
    background-color: @panel-bg;
    border: 2px solid @main-gray;
    margin-top: 10px;
}

.popup-notification a.close{
    margin-top: -8px;
    margin-right: -3px;
}

.popup-notification-default {
    border-color: @gray-light;
}

.popup-notification-danger {
    border-color: @brand-danger;
}

.popup-notification-warning {
    border-color: @brand-warning;
}

.popup-notification-primary {
    border-color: @brand-primary;
}

.popup-notification-success {
    border-color: @brand-success;
}

.popup-notification-info {
    border-color: @brand-info;
}

.popup-notification h4 {
    margin-top: 0px;
}

.popup-notification-default h4 {
    color: @gray-light;
}

.popup-notification-danger h4 {
    color: @brand-danger;
}

.popup-notification-warning h4 {
    color: @brand-warning;
}

.popup-notification-primary h4 {
    color: @brand-primary;
}

.popup-notification-success h4 {
    color: @brand-success;
}

.popup-notification .cell {
    margin-bottom: 5px;
}


@media screen and (max-width: @screen-sm-min) {
    #popup-notifications-container {
        width: 100%;
    }
    .popup-notification {
        width: auto;
    }
}

.list-group-tree {
    border: 0;
}
.list-group-tree > li {
    border: 0;
    padding: 0 0 0 @panel-padding;
}

.list-group-tree > li .cell {
    padding: 2px 0;
}

.list-group-side {
    border: 0;
}
.list-group-side > li {
    border: 0;
    padding: 5px 0 5px (@container-padding - 3px);
    margin-left: -(@container-padding);
    border-left: 3px solid transparent;
}

.list-group-side > li.selected {
    border-color: @brand-danger;
}

.list-group-side a:hover,
.list-group-side a:focus,
.list-group-tree a:hover,
.list-group-tree a:focus {
    text-decoration: none;
}

.list-group-side > li .cell {
    padding: 2px 0;
}

.list-group-side li.selected a.side-link,
.list-group-side li.selected a:hover.side-link,
.list-group-side li.selected a:active.side-link,
.list-group-side li.selected a:visited.side-link,
.list-group-side li.selected a:focus.side-link {
    color: @brand-danger;
    font-weight: bold;
}

.text-bold {
    font-weight: 800;
}

.email-address-create-dropdown .btn {
    position: relative;
    top: -1px;
    padding: 0 4px;
    margin: 0;
    margin-bottom: 0;
    border: 0;
}

#main > .calendar-container {
    margin-top: 10px;
}

#notifications-panel {
    position: absolute;
    width: 600px;
    z-index: 1001;
    right: 0;
    left: auto;
}

#global-search-panel {
    position: absolute;
    width: 500px;
    z-index: 1001;
    right: 0;
    left: auto;
}

h5 {
    font-weight: bold;
    margin-top: 9px;
    margin-bottom: 9px;
}

.post-container .internal-mode-switcher {
    color: @gray-light;
    margin-left: 10px;
    display: inline-block;
    position: relative;
    top: 2px;
}

.post-container .internal-mode-switcher.enabled {
    color: @link-color;
}

.post-control .attachments {
    width: 270px;
}

.post-container .attachments {
    width: 270px;
}



.dynamic-logic-expression-container {
    div.item-list {
        margin-left: 30px;
    }
    div.item-list > div {
        margin: 0 0 10px 0;
    }
    div.group-head {
        line-height: 33px;
    }
    .dynamic-logic-edit-item-row {
        > div {
            line-height: 33px;
        }
    }
}

.dynamic-logic-options {
    a.remove-option-list,
    a.add-option-list {
        line-height: 33px;
    }
    .option-list-item-header {
        margin-top: -10px;
    }

    .dynamic-logic-options-list-container {
        margin-bottom: 0;
    }
}

@media screen and (min-width: @screen-sm-min) {
    #global-search-panel {
        margin-top: 5px;
    }
}

@media screen and (max-width: @screen-sm-min) {
    #notifications-panel {
        position: fixed;
        width: 100%;
        top: 0;
        right: none;
        left: 0;
        margin-right: 10px;
    }

    #global-search-panel {
        position: fixed;
        width: 100%;
        top: 0;
        right: none;
        left: 0;
        margin-right: 10px;
    }

    .navbar-form.global-search-container {
        padding-left: 8px;
        padding-right: 8px;
    }

    .navbar-form.global-search-container > .input-group {
        margin-left: 14px;
    }

    #global-search-input {
        width: 100%;
    }

    #header .navbar-right > li {
        display: inline-block;
    }

    #header .navbar-right > li.notifications-badge-container {
        display: inline-block;
        float: right;
    }
}
