/*
 * LMS version 1.11-git
 *
 *  (C) Copyright 2001-2019 LMS Developers
 *
 *  Please, see the doc/AUTHORS for more information about authors!
 *
 *  This program is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License Version 2 as
 *  published by the Free Software Foundation.
 *
 *  This program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with this program; if not, write to the Free Software
 *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
 *  USA.
 *
 *  $Id$
 */

/*
	jQuery-UI
*/

.ui-widget.ui-widget-content {
  border: 1px solid @darkbrown;
}

.ui-tabs {
  .ui-tabs-nav {
    border-top: 0;
    border-right: 0;
    border-bottom: 1px dotted grey;
    border-bottom-right-radius: 0;
    margin-right: 0.4em
  }
  &.ui-widget.ui-widget-content {
    border: 0;
  }
  &.ui-widget-content {
    background-color: transparent;
  }
  .ui-widget-header {
    background-color: transparent;
    padding: 0;
  }
  .ui-tabs-panel {
    border: 1px dotted grey;
    border-top: none;
    border-top-left-radius: 0;
  }
  .ui-tab {
    .alert,
    &.lms-ui-error,
    &:invalid {
      box-shadow: @error-box-shadow !important;
      &:focus {
        box-shadow: @error-box-shadow-focus !important;
      }
    }
    &.lms-ui-warning {
      box-shadow: @warning-box-shadow !important;
      &:focus {
        box-shadow: @warning-box-shadow-focus !important;
      }
    }

    &.ui-tabs-tab {
      background-color: #CEBD9B;
      box-shadow: none;
      margin-left: -0.1em;
    }

    &.ui-tabs-active {
      .ui-tabs-anchor {
        color: black;
        font-weight: bold;
        outline: none;
      }
      &.ui-tabs-tab {
        background-color: #DFD5BD;
        border: 1px dotted grey;
        border-bottom: none;
        box-shadow: unset;
      }
      &:focus {
        border: 1px solid #615847;
        border-bottom: none;
        //outline: none;
      }
    }
  }
}

.ui-widget-overlay {
  opacity: .5;
}

.ui-state-default,
.ui-widget-content .ui-state-default,
.ui-widget-header .ui-state-default,
.ui-button,
html .ui-button.ui-state-disabled:hover,
html .ui-button.ui-state-disabled:active {
  padding: 0em 1em;
  border: 1px solid @darkbrown;
  background-color: @light;
}

.ui-state-default,
.ui-widget-content .ui-state-default {
  padding: 0;
  text-align: center;
}

.ui-state-hover,
.ui-widget-content .ui-state-hover,
.ui-widget-header .ui-state-hover,
.ui-state-focus,
.ui-widget-content .ui-state-focus,
.ui-widget-header .ui-state-focus,
.ui-button:hover,
.ui-button:focus {
  box-shadow: inset 1px 1px 3px 0px rgba(0, 0, 0, 0.6);
  background-color: @light;
  border: 1px solid @darkbrown;
  outline: none;
  color: black;
}

.ui-selectmenu-text {
  padding-top: 2px;
}

.ui-selectmenu-button.ui-button {
  min-width: 20em;
  width: auto;
}

.ui-state-highlight,
.ui-widget-content .ui-state-highlight,
.ui-widget-header .ui-state-highlight {
  background-color: #fffa90;
}

.ui-state-active,
.ui-widget-content .ui-state-active,
.ui-widget-header .ui-state-active,
.ui-button:active,
.ui-button:focus,
.ui-button.ui-state-active:hover {
  box-shadow: inset 1px 1px 4px 0px rgba(0, 0, 0, 0.4);
  background: @dark;
  border: 1px solid @darkbrown;
}

.ui-dialog {
  background-color: @dark;
  .ui-dialog-content {
    background-color: @dark;
  }
  .ui-dialog-buttonpane {
    background-color: @dark;
    border-top: 0;
    padding-right: 6px;

    button {
      font-weight: bold;
    }
  }
}

.ui-dialog-content {
  background-color: @dark;
}

.ui-dialog-titlebar {
  background-color: @superdark;
  border: 1px solid @superdark;
  color: @dialog-title;
}

.ui-dialog-buttonpane .ui-dialog-buttonset {
  width: 100%;
  text-align: center;
}

.ui-tooltip {
  background-color: @light;
  &.lms-ui-error {
    color: @error-text;
  }
  &.lms-ui-warning {
    color: @warning-text;
  }
}

.ui-datepicker {
  background-color: @superdark;
}

.ui-datepicker-header {
  background-color: @dark;
  border: 1px solid @dark;
}

.ui-datepicker-calendar {
  background-color: @dark;
}

.ui-datepicker .ui-datepicker-buttonpane {
  border-top: 1px solid black;
  margin-top: 0;
}

.ui-datepicker-trigger {
  border: none;
  background: none;
  margin-left: 0.3em;
  padding: 0;
}

input[disabled] + .ui-datepicker-trigger {
  color: @blend !important;
  cursor: no-drop;

  &:before {
    color: @blend !important;
  }
}

.ui-tooltip.voipaccountinfo,
.ui-tooltip.invoiceinfo,
.ui-tooltip.docnumber,
.ui-tooltip.customerinfo,
.ui-tooltip.nodelist,
.ui-tooltip.ewxnodelist,
.ui-tooltip.customerassignmentinfo,
.ui-tooltip.rtticketinfo,
.ui-tooltip.nodegroupinfo,
.ui-tooltip.netdevlist,
.ui-tooltip.documentview {
  padding: 0;
}

.ui-dialog.documentviewdialog {
  min-width: 200px;
  min-height: 35px;
  position: absolute;
}

.ui-dialog-content.documentviewdialog {
  padding: 0 !important;
  min-width: 200px;
  min-height: 35px;
}

.fileupload-progress-dialog .ui-dialog-titlebar {
  display: none;
}

.ui-progressbar {
  position: relative !important;
  background-color: @light;
  .ui-progressbar-value {
    background-color: @superdark;
    border-color: @superdark;
  }
}

.ui-selected {
  background-color: @highlight;
}

.ui-slider.ui-widget-content {
  background-color: @lucid;
}

.ui-slider-range {
  background-color: @dark;
  text-align: center;
  overflow: hidden;
  cursor: default;
}

.ui-slider-handle.ui-state-default {
  background-color: @superdark;
  margin-top: 2px
}

.ui-slider-horizontal {
  height: 1em;
}

.ui-selectmenu-optgroup {
  background-color: #ebe4d6 !important;
}

.ui-menu-item {
  background-color: #ebe4d6 !important;
  .ui-state-active,
  .ui-state-active:hover {
    color: white;
    background-color: #4a90d9 !important;
  }
  [class*="lms-ui-icon"] {
    padding-right: 0.5em;
  }
}

.ui-sortable-handle {
  cursor: grab;
}

.ui-menu.ui-autocomplete {
  max-width: 40%;

  .ui-menu-item:not(:last-child) {
    border-bottom: @dotted-line;
  }
}

.ui-button.lms-ui-button > i {
  margin-right: 0.3em;
}
