.plugin-klipper-sidebar {
  padding: 1px;
  height: auto;
  border: 1px solid #aaa;
  width: 98%;
  text-align: center;
  word-break: break-all;
  margin: auto;
}

li#navbar_plugin_klipper {
  cursor: pointer;
  max-width: 360px;
  max-height: 80px;
  word-break: break-all;
}

.plugin-klipper-sidebar a {
  padding: 2px 2px;
  text-align: center;
  text-decoration: none;
  display: inline-block;
  cursor: pointer;
}

.plugin-klipper-sidebar a:hover,
.plugin-klipper-sidebar a:active {
  cursor: pointer;
}

.plugin-klipper-log {
  padding: 0px;
  overflow-y: scroll;
  height: 400px;
  border: 1px solid #eee;
  width: 100%;
  word-break: break-all;
}

.plugin-klipper-log .log-item {
  margin: 3px auto 0 auto;
  border: 1px solid #ddd;
  border-radius: 3px;
  background-color: #efefef;
  color: #333;
}

.plugin-klipper-log .error {
  background-color: #eebabb;
}

.plugin-klipper-log .log-item .ts {
  display: inline-block;
  width: 13%;
  height: 100%;
  vertical-align: top;
  font-size: 0.8em;
  padding: 0 0 0 5px;
}

.plugin-klipper-log .log-item .msg {
  display: inline-block;
  width: 84%;
  height: 100%;
}

.clear-btn {
  margin-top: 6px;
  margin-bottom: 6px;
}

#level .controls {
  padding: 1px;
}

ul#klipper-settings {
  margin: 0;
}

#klipper-settings a {
  margin: 5px;
}

#tab_plugin_klipper_main .row-fluid {
  display: flex;
  flex-flow: row wrap;
  align-items: stretch;
}

@media all and (max-width: 940px) {
  #tab_plugin_klipper_main .row-fluid {
    /* On small screens, we are no longer using row direction but column */
    flex-direction: column;
  }
}

#tab_plugin_klipper_main #left-side {
  flex: 3 1;
  padding-right: 10px;
}

#tab_plugin_klipper_main .span8 label {
  float: left;
}

#tab_plugin_klipper_main #right-side {
  flex: 1 1;
  max-width: 200px;
  min-width: 100px;
}

.klipper-row-fluid {
  display: flex;
  flex-flow: row wrap;
  align-items: stretch;
}

.klipper-column-fluid {
  display: flex;
  flex-flow: column nowrap;
  align-items: stretch;
}

.klipper-fluid-item-1 {
  flex: 1 auto;
}

.klipper-fluid-item-2 {
  flex: 2 auto;
}

.klipper-fluid-item-3 {
  flex: 3 auto;
}

.gap {
  justify-content: space-evenly;
}

@media all and (max-width: 940px) {
  .klipper-row-fluid {
    /* On small screens, we are no longer using row direction but column */
    flex-direction: column;
  }
}

#settings_plugin_klipper {
  height: 100%;
  height: -webkit-fill-available;
}

div#klipper_backups_dialog div.modal-body textarea {
  margin-bottom: 0px !important;
  padding-left: 0px !important;
  padding-right: 0px !important;
  box-sizing: border-box;
  height: -webkit-fill-available;
  resize: none;
  width: 100%;
}

/* UIcustomizer fix */
body.UICResponsiveMode #settings_dialog_content {
  height: calc(100% - 60px);
  margin-right: -18px;
  margin-top: 50px;
  width: calc(100% - 15px);
}

div#settings_plugin_klipper form {
  margin: 0px;
  height: 100%;
}

div#settings_plugin_klipper div.tab-content {
  height: calc(100% - 58px);
  overflow: auto;
}

div#settings_plugin_klipper div.tab-footer {
  height: 20px;
  width: 100%;
  top: 10px;
  position: relative;
  border-top: 1px solid #eee;
  padding-top: 3px;
}

div#settings_plugin_klipper div.tab-content div#conf.tab-pane {
  height: 100%;
  min-height: 200px;
  width: 100%;
}

div#settings_plugin_klipper div.tab-content div#conf.tab-pane div.control-group {
  height: 100%;
  margin: 0;
  display: flex;
  flex-direction: column;
}

.klipper-settings-tab {
  height: 100%;
  width: 100%;
}

#settings_plugin_klipper .m-0 {
  margin: 0;
}

#settings_plugin_klipper .scroll-y {
  overflow-y: scroll;
}

#settings_plugin_klipper table {
  table-layout: unset !important;
}

#settings_plugin_klipper .table-fixed thead th {
  position: sticky;
  top: 0;
  background-color: rgba(12, 5, 5, 0.85);
  color: rgb(200, 200, 200);
}

#settings_plugin_klipper .pagination-mini {
  margin: 5;
}

div#klipper_editor {
  height: 80%;
  display: flex;
  flex-flow: column;
}

@media (max-width: 979px) {

  div#klipper_editor.modal {
    height: unset !important;
  }
  
}

div#klipper_editor .modal-header {
  height: 6px;
}

div#klipper_editor .modal-body {
  overflow: auto;
  min-height: 300px;
  display: flex;
  flex-flow: column;
  flex-grow: 1;
}

.klipper-btn-group {
  display: inline-block;
}

div#klipper_editor .modal-body label.checkbox {
  display: unset;
}

div#klipper_editor .modal-body input[type="text"] {
  margin-bottom: 0px !important;
}

div#klipper_editor .modal-body input[type="checkbox"] {
  float: unset;
  margin-left: unset;
  vertical-align: unset;
}

div#klipper_editor .modal-body .editor-controls {
  flex: 0 auto 50px;
}

div#klipper_editor .flex-end {
  align-self: flex-end;
}

div#klipper_editor div.conf-editor {
  width: 99%;
  width: calc(100% - 4px);
  margin-top: 5px;
  overflow: auto;
  flex-grow : 1;
}

div#klipper_editor div.conf-editor div#plugin-klipper-config {
  font-family: monospace;
  overflow: auto;
}

.ace_editor {
  margin: auto;
  height: 200px;
  width: 100%;
}

/* div#settings_plugin_klipper.tab-pane.active form.form-horizontal div.tab-content div#conf.tab-pane.active button.btn.btn-small ,div#klipper_editor button.btn.btn-small{
   width: 30%;
   display: inline-block;
   margin: 0px 2px 2px 2px;
} */

/*checkboxes*/
div#settings_plugin_klipper.tab-pane.active form.form-horizontal div.tab-content div.tab-pane.active input.inline-checkbox,
div#klipper_editor input.inline-checkbox {
  vertical-align: -0.2em;
}

div#settings_plugin_klipper.tab-pane.active form.form-horizontal div.tab-content div.tab-pane.active label.inline,
div#klipper_editor .inline {
  display: inline;
}

div#settings_plugin_klipper.tab-pane.active form.form-horizontal div.tab-content div.tab-pane.active div.controls input.controls-checkbox {
  margin-top: 8px;
}

/*macros*/
div#settings_plugin_klipper.tab-pane.active form.form-horizontal div.tab-content div#macros.tab-pane.active div div#item.control-group label.control-label {
  width: 80px;
}

#macros #item.control-group {
  margin-bottom: 2px;
  border: 2px solid #ccc;
  border-radius: 3px;
  background-color: #eeeeee;
  color: #333;
  padding-bottom: 2px;
  padding-top: 2px;
}

#klipper_graph_dialog {
  width: 90%;
}

#klipper_graph_dialog .full-sized-box {
  width: 100%;
  margin: 0 auto;
}

#klipper_graph_dialog form {
  margin: 0;
}

#klipper_graph_dialog select {
  width: auto;
}

#klipper_graph_dialog .graph-footer {
  bottom: 0;
}

#klipper_graph_dialog input {
  display: inline-block;
}

#klipper_graph_dialog .status-label {
  display: block;
  position: absolute;
  margin: 5px 0 0 10px;
}

#klipper_graph_dialog .fill-checkbox {
  display: block;
  position: absolute;
  top: 0%;
  left: 50%;
}

#klipper_graph_dialog .help-inline {
  display: block;
  position: absolute;
  top: 0px;
}

#klipper_graph_canvas {
  margin-top: 15px;
}
