.bg-gradient-primary {
    background: #0069d9;
    background: -moz-linear-gradient(top, #0069d9 0%, #007bff, 100%);
    background: -webkit-linear-gradient(top, #0069d9 0%, #007bff 100%);
    /*background: linear-gradient(to bottom, #0069d9 0%, #007bff 100%);*/
    background: linear-gradient(to bottom, #0069d9 0%, #007bff 100%);
    filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#0069d9', endColorstr='#007bff',GradientType=0 ); /* IE6-9 */
}

.bg-gradient-dark {
    background: rgb(43,65,98);
    background: -moz-linear-gradient(315deg, rgba(43,65,98,1) 0%, rgb(23,35,48) 74%);
    background: -webkit-linear-gradient(315deg, rgba(43,65,98,1) 0%, rgb(23,35,48) 74%);
    background: linear-gradient(315deg, rgba(43,65,98,1) 0%, rgb(23,35,48) 74%);
    filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#2b4162",endColorstr="#12100e",GradientType=1);
}

.bg-gradient-gray {
    background: #6c757d;
    background: -moz-linear-gradient(top, #6c757d 0%, #343a40, 100%);
    background: -webkit-linear-gradient(top, #6c757d 0%, #343a40 100%);
    /*background: linear-gradient(to top, #6c757d 0%, #343a40 100%);*/
    background: linear-gradient(to top, #6c757d 0%, #343a40 100%);
    filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#6c757d', endColorstr='#343a40',GradientType=0 ); /* IE6-9 */    
}

.btn-primary-inverted {
    color: #007bff;
    background-color: #fff;
    border-color: #fff;
}

.btn-outline-primary-inverted {
    color: #fff;
    background-color: transparent;
    border: 1px solid #fff;
}

    .btn-outline-primary-inverted:hover,
    .btn-outline-primary-inverted.active {
        color: #007bff;
        background-color: #fff;
    }

.btn-dark-inverted {
    color: rgb(43,65,98);
    background-color: rgb(23,35,48);
    border-color: rgb(23,35,48);
}

.btn-outline-dark-inverted {
    color: rgb(23,35,48);
    background-color: transparent;
    border: 1px solid rgb(23,35,48);
}

    .btn-outline-dark-inverted:hover,
    .btn-outline-dark-inverted.active {
        color: rgb(43,65,98);
        background-color: rgb(23,35,48);
    }

.dropdown-menu {
}

    .dropdown-menu.bg-dark .dropdown-item:hover {
        background-color: inherit
    }

.dropdown-item i {
    margin-right: 5px;
}

#document-editor-loading-view {
    position: absolute;
    z-index: 99999;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background: rgb(43,65,98);
    background: -moz-linear-gradient(315deg, rgba(43,65,98,1) 0%, rgba(18,16,14,1) 100%);
    background: -webkit-linear-gradient(315deg, rgba(43,65,98,1) 0%, rgba(18,16,14,1) 100%);
    background: linear-gradient(315deg, rgba(43,65,98,1) 0%, rgba(18,16,14,1) 100%);
    filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#2b4162",endColorstr="#12100e",GradientType=1);
}

#document-editor-container{
    position: fixed;
    width: 100%;
    height: 100%;
    left: 0;
    top: 0;
    z-index: -10;
    padding: 0;
}



    #document-editor-container .dropdown-menu {
        color: #fff;
        background-color: #1d2124;
        border-color: #171a1d;
    }

        #document-editor-container .dropdown-menu input {
            background-color: #495057;
            color: #fff;
            border: 1px solid #ced4da;
        }

        #document-editor-container .dropdown-menu a {
            color: #fff;
        }

            #document-editor-container .dropdown-menu a:hover {
                color: #007bff;
                background-color: inherit;
            }

    #document-editor-container .bootstrap-select .no-results {
        background-color: #1d2124;
        color: #fff;
    }

    #document-editor-container .bootstrap-select.is-valid .dropdown-toggle,
    #document-editor-container .was-validated .bootstrap-select select:valid + .dropdown-toggle {
        border-color: #171a1d;
    }

#document-editor-side-menu-container {
    /*width: 336px;*/
    width: 392px;
    border-left: 1px #ccc;
    right: 0;
}

    #document-editor-side-menu-container .document-editor-title {
        position: absolute;
        width: calc(100% - 56px);
        height: 56px;
        line-height: 56px;
        /* border-left: 2px solid black; */
        padding-left: 15px;
        font-size: 20px;
        font-weight: 600;
        text-overflow: ellipsis;
        white-space: nowrap;
        overflow: hidden;
    }

    #document-editor-side-menu-container .document-editor-tab-bar {
        float: right;
        width: 56px;
        height: 100%;
        background-color: #1d2124;
    }

        #document-editor-side-menu-container .document-editor-tab-bar button {
            float: left;
            height: 56px;
            width: 56px;
            border-radius: 0;
            background-color: #1d2124;
            color: #fff;
        }

            #document-editor-side-menu-container .document-editor-tab-bar button.active {
                background-color: #343a40;
            }

            #document-editor-side-menu-container .document-editor-tab-bar button i {
                font-size: 23px;
            }

            #document-editor-side-menu-container .document-editor-tab-bar button[data-view-type='4'] i {
                font-size: 21px;
            }

            #document-editor-side-menu-container .document-editor-tab-bar button[data-view-type='99'] i {
                font-size: 28px;
            }

            #document-editor-side-menu-container .document-editor-tab-bar button:focus {
                box-shadow: none;
            }

            #document-editor-side-menu-container .document-editor-tab-bar button:hover {
                color: #fff;
                background-color: #343a40;
                border-color: #343a40;
            }

            /* Separate the close button from the rest of the buttons */
            #document-editor-side-menu-container .document-editor-tab-bar button:first-of-type {
                background-color: #343a40;
                margin-bottom: 54px;
            }

                #document-editor-side-menu-container .document-editor-tab-bar button:first-of-type:hover {
                    background-color: #1d2124;
                }

#document-editor-side-menu-container {

}

    #document-editor-side-menu-container .dbqde-side-menu-container {
        margin-top: 56px;
        width: calc(100% - 56px);
        height: calc(100% - 56px);
    }

    #document-editor-side-menu-container .form-control,
    #document-editor-side-menu-container .form-check-input {
        background-color: #495057;
        color: #fff;
        border: 1px solid #ced4da;
    }

        #document-editor-side-menu-container .form-control.disabled,
        #document-editor-side-menu-container .form-check-input.disabled {
            cursor: not-allowed;
            pointer-events: none;
        }

        #document-editor-side-menu-container .form-control:focus {
            background-color: #495057;
            color: #fff;
            border-color: #fff;
            outline: 0;
            box-shadow: 0 0 0 0.2rem rgba(0,123,255,.25);
        }

    #document-editor-side-menu-container .was-validated .form-control:valid {
        border: 1px solid #ced4da;
        background: 0 none;
        padding-right: 12px;
    }

        #document-editor-side-menu-container .was-validated .form-control:valid:focus {
            border: 1px solid #ced4da;
        }

    #document-editor-side-menu-container .form-control-plaintext {
        color: #bbb;
    }

    #document-editor-side-menu-container .form-control option {
        background-color: #495057
    }

.document-editor-category-title {
    height: 54px;
    line-height: 54px;
    padding: 0 15px;
    font-weight: 500;
    font-size: 16px;
    text-transform: uppercase;
    color: #fff;
    background-color: #1d2124;
    border-color: #171a1d;
    position: relative;
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
}

    .document-editor-category-title .document-editor-category-title-buttons {
        position: absolute;
        top: calc(0px - 100%);
        right: 15px;
        opacity: 0;
    }

        .document-editor-category-title .document-editor-category-title-buttons button {
            margin-right: 5px;
        }

.document-editor-scrollview {
    background-color: #1d2124 !important;
    border-color: #171a1d !important;
    border-radius: 5px;
}

    .document-editor-scrollview .scrollview-content {
        margin: 5px;
        overflow-y: auto;
        height: calc(100% - 10px);
    }

#editor-elements-container {
    height: calc(100% - 56px);
    overflow-y: auto;
}

    #editor-elements-container .editor-elements-row {
        padding: 7.5px;
    }

        #editor-elements-container .editor-elements-row .editor-element-col {
            padding: 7.5px;
        }

.editor-element-category-header {
    border-top:  rgb(43,65,98);
    border-bottom:  rgb(43,65,98);
}

    .editor-element-category-header:first-child {
        border-top: 0;
    }

    .editor-element-category-header i {
        margin-right: 15px;
    }

.editor-element {
    position: relative;
    overflow: hidden;
    width: 65.25px;
    height: 65.25px;
    border: 2px solid #007bff !important;
    background: transparent !important;
    padding: 0 5px !important;
    text-overflow: ellipsis;
    clear: both;
}

    .editor-element i {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        margin-top: 0px;
        font-size: 20px;
        padding: 10px;
        width: 100%;
    }

    .editor-element .element-type-name {
        position: absolute;
        bottom: 2px;
        left: 5px;
        right: 5px;
        font-size: 11px;
        text-overflow: ellipsis;
        overflow: hidden;
        white-space: nowrap;
    }

.editor-element-document-template {
    overflow: hidden;
    width: 100%;
    border: 2px solid #007bff !important;
    background: transparent !important;
    font-size: 12px !important;
}

    .editor-element-document-template i {
        margin: 5px 8px 5px 0;
    }

.col-fixed {
    position: fixed;
    height: 100%;
    z-index: 1;
}

.col-offset-392 {
    padding-right: 392px;
    z-index: 0;
}

.is-dragover {
  background-color: grey;
}

/*******************************
 *      Toolbar Styling        *
 *******************************/
.dbqde-toolbar-container {
    height: 56px;
}

    .dbqde-toolbar-container .dbqde-toolbar-functions-container {
        float: left;
        line-height: 56px;
        margin: 0 15px;
    }

    .dbqde-toolbar-container .dbqde-toolbar-version-container {
        float: right;
        line-height: 56px;
        margin: 0 15px;
    }

        .dbqde-toolbar-container .dbqde-toolbar-version-container .dbqde-toolbar-version-function-button {
            margin-left: 15px;
        }

/*******************************
  *   Document Tags Styling    *
 *******************************/

.document-tags-control-container {

}

    .document-tags-control-container .dbqde-document-tags-empty {
        margin: 15px;
    }

    .document-tags-control-container .card {
        background-color: inherit;
        border: 0 none;
    }

        .document-tags-control-container .card .card-header {
            margin: 0;
            padding: 0;
        }

            .document-tags-control-container .card .card-header button {
                color: #fff !important;
                background-color: #1d2124 !important;
                border-color: #171a1d !important;
                height: 54px;
                width: 100%;
                padding: 0 15px;
                text-align: left;
                box-shadow: none !important;
                border-radius: 0;
            }

                .document-tags-control-container .card .card-header button i  {
                    float: right;
                    margin-top: 3px;
                }

                .document-tags-control-container .card .card-header button[data-toggle="collapse"] .fa:before {
                    content: "\f078";
                }

                .document-tags-control-container .card .card-header button[data-toggle="collapse"].collapsed .fa:before {
                    content: "\f054";
                }

        .document-tags-control-container .card .card-body {
            padding: 0;
        }



.dbqde-document-tags-header {
    font-size: 16px !important;
    line-height: 36px;
    border: 0 none !important;
    font-weight: normal;
    border-radius: 0 !important;
    margin: 0 !important;
}

.dbqde-document-tags-scrollview {
    height: 300px;
    margin: 15px;
    padding: 0 !important;
}

.dbqde-document-tags-container {

}


.dbqde-document-tags-container .dbqde-document-tag {
    clear: both;
    color: #fff;
    height: 35px;
}

    .dbqde-document-tags-container .dbqde-document-tag .dbqde-document-tag-name {
        line-height: 35px;
        font-size: 14px;
        text-overflow: ellipsis;
        overflow: hidden;
        white-space: nowrap;
        float: left;
        max-width: 215px;
    }

    .dbqde-document-tags-container .dbqde-document-tag .dbqde-switch {
        float: right;
        margin-top:5px;
    }



/*******************************
 *   Function button styles    *
 *******************************/
.function-button {
    display: inline-block;
    width: 30px;
    height: 30px;
    cursor: pointer;
    border-radius: 50%;
    font-weight: 400;
    text-align: center;
    white-space: nowrap;
    vertical-align: middle;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    border: 1px solid transparent;
    font-size: 1rem;
    line-height: 0.4;
    transition: color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out;
}

    .function-button i {
        font-size: 12px;
    }

    .function-button:focus {
        outline: none;
        box-shadow: none;
    }

 /*******************************
  *      Scrollbar styles       *
  *******************************/   

.scrollbar-dark::-webkit-scrollbar-track {
    -webkit-box-shadow: inset 0 0 6px rgba(0,0,0,0.3);
    background-color: #3c3c3c;
}

.scrollbar-dark::-webkit-scrollbar {
    width: 6px;
    background-color: #3c3c3c;
}

.scrollbar-dark::-webkit-scrollbar-thumb {
    background-color: #1d2124;
}

/*******************************
  * Loading spinner *
  *******************************/   

.loading-spinner {
    display: block;
    position: relative;
    left: 50%;
    top: 50%;
    width: 150px;
    height: 150px;
    margin: -75px 0 0 -75px;
    border-radius: 50%;
    border: 3px solid transparent;
    border-top-color: #6497b1;
    -webkit-animation: spin 2s linear infinite;
    animation: spin 2s linear infinite;
}
.loading-spinner:before {
    content: "";
    position: absolute;
    top: 5px;
    left: 5px;
    right: 5px;
    bottom: 5px;
    border-radius: 50%;
    border: 3px solid transparent;
    border-top-color: #03396c;
    -webkit-animation: spin 3s linear infinite;
    animation: spin 3s linear infinite;
}
.loading-spinner:after {
    content: "";
    position: absolute;
    top: 15px;
    left: 15px;
    right: 15px;
    bottom: 15px;
    border-radius: 50%;
    border: 3px solid transparent;
    border-top-color: #005b96;
    -webkit-animation: spin 1.5s linear infinite;
    animation: spin 1.5s linear infinite;
}
@-webkit-keyframes spin {
    0%   {
        -webkit-transform: rotate(0deg);
        -ms-transform: rotate(0deg);
        transform: rotate(0deg);
    }
    100% {
        -webkit-transform: rotate(360deg);
        -ms-transform: rotate(360deg);
        transform: rotate(360deg);
    }
}
@keyframes spin {
    0%   {
        -webkit-transform: rotate(0deg);
        -ms-transform: rotate(0deg);
        transform: rotate(0deg);
    }
    100% {
        -webkit-transform: rotate(360deg);
        -ms-transform: rotate(360deg);
        transform: rotate(360deg);
    }
}

/*********************************
  *    Custom Switch Slider      *
  ********************************/

.dbqde-switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 24px;
}

    .dbqde-switch input {
        opacity: 0;
        width: 0;
        height: 0;
    }

.dbqde-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    -webkit-transition: .4s;
    transition: .4s;
    border-radius: 24px;
}

    .dbqde-slider:before {
        position: absolute;
        content: "";
        height: 16px;
        width: 16px;
        left: 4px;
        bottom: 4px;
        background-color: white;
        -webkit-transition: .4s;
        transition: .4s;
        border-radius: 50%;
    }

input:checked + .dbqde-slider {
    background-color: #2196F3;
}

input:focus + .dbqde-slider {
    box-shadow: 0 0 1px #2196F3;
}

input:checked + .dbqde-slider:before {
    -webkit-transform: translateX(34px);
    -ms-transform: translateX(34px);
    transform: translateX(34px);
}

/*********************************
  *    Version state styling     *
  ********************************/

/* 
    Tab Bar 
    * 
    Disable the editor elements tab for non-draft versions
    Disable the properties tab when state is not 215 = DidSelectElement
*/
#document-editor-container:not([data-document-version-state='0']) .document-editor-tab-bar button[data-view-type='0'],
#document-editor-container:not([data-document-editor-state='215']) .document-editor-tab-bar button[data-view-type='1'] {
    /* Colors and opacity values have been directly copied from the bootstrap disabled styling */
    color: #fff;
    background-color: #343a40;
    border-color: #343a40;
    opacity: .65;
    pointer-events: none;
}

/* Function Buttons */
#document-editor-container:not([data-document-version-state='0']) .function-button:not(.version-function-button):not(.dbqde-document-tags-function-button):not(.dbqde-function-button-toolbar),
#document-editor-container:not([data-document-version-state='0']) .dbqde-element-function-button:not(.dbqde-element-collapse-button) {
    opacity: 0 !important;
    pointer-events: none;
}

/* Element Styles */
#document-editor-container:not([data-document-version-state='0']) .document-style {
    pointer-events: none;
}

/* Visibility Expressions */
#document-editor-container:not([data-document-version-state='0']) .element-visibility-expressions-toolbar {
    display: none;
}

/* Attribute Control */
#document-editor-container:not([data-document-version-state='0']) #element-attributes-control-container .dbq-card {
    display: none !important;
}

#document-editor-container:not([data-document-version-state='0']) #element-attributes-container .dbq-folder-document-picker,
#document-editor-container:not([data-document-version-state='0']) #element-attributes-container .box.has-advanced-upload {
    opacity: 0.65;
    pointer-events: none;
}

/*********************************
  * Element create state styling *
  ********************************/
/*
    EditorState 100 = WillCreateTopic
    EditorState 200 = WillCreateElement
*/
#document-editor-container[data-document-editor-state='100'] #dbqde-elements-list,
#document-editor-container[data-document-editor-state='200'] #dbqde-elements-list {
    background-color: #444 !important;
}

    #document-editor-container[data-document-editor-state='100'] #dbqde-elements-list input,
    #document-editor-container[data-document-editor-state='200'] #dbqde-elements-list input,
    #document-editor-container[data-document-editor-state='100'] #dbqde-elements-list select,
    #document-editor-container[data-document-editor-state='200'] #dbqde-elements-list select,
    #document-editor-container[data-document-editor-state='100'] #dbqde-elements-list textarea,
    #document-editor-container[data-document-editor-state='200'] #dbqde-elements-list textarea {
        background-color: #a1a1a1 !important;
        border-color: #a1a1a1 !important;
    }

        #document-editor-container[data-document-editor-state='100'] #dbqde-elements-list input[type='checkbox'],
        #document-editor-container[data-document-editor-state='200'] #dbqde-elements-list input[type='checkbox'] {
            opacity: 0.5; /* Checkboxes ignore the background color. It still looks disabled by turning down the opacity */
        }

    #document-editor-container[data-document-editor-state='200'] #dbqde-elements-list .dbqde-element-selected {
        background-color: white !important;
    }

    #document-editor-container[data-document-editor-state='100'] #dbqde-elements-list .custom-file-label,
    #document-editor-container[data-document-editor-state='200'] #dbqde-elements-list .custom-file-label {
        background-color: #a1a1a1 !important;
        border-color: #a1a1a1 !important;
    }

#document-editor-container[data-document-editor-state='100'] .dbqde-elements-sortable-list,
#document-editor-container[data-document-editor-state='200'] .dbqde-elements-sortable-list {
    pointer-events: none;
}

#document-editor-container[data-document-editor-state='100'] .document-editor-tab-bar button:not([data-view-type='99']),
#document-editor-container[data-document-editor-state='200'] .document-editor-tab-bar button:not([data-view-type='99']) {
    /* Colors and opacity values have been directly copied from the bootstrap disabled styling */
    color: #fff;
    background-color: #343a40;
    border-color: #343a40;
    opacity: .65;
    pointer-events: none;
}

#document-editor-container[data-document-editor-state='100'] #topics-container li,
#document-editor-container[data-document-editor-state='200'] #topics-container li {
    pointer-events: none;
}

#document-editor-container[data-document-editor-state='100'] #topics-container .dbq-button,
#document-editor-container[data-document-editor-state='200'] #topics-container .dbq-button {
    /* Colors and opacity values have been directly copied from the bootstrap disabled styling */
    color: #fff;
    background-color: #007bff;
    border-color: #007bff;
    opacity: .65;
    pointer-events: none;
}
