@import "app-resources/css/admin-theme.less";

.display-flex {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
}

.flex-direction-row {
  -webkit-box-orient: horizontal;
  -webkit-box-direction: normal;
  -ms-flex-direction: row;
  flex-direction: row;
}

.flex-direction-column {
  -webkit-box-orient: vertical;
  -webkit-box-direction: normal;
  -ms-flex-direction: column;
  flex-direction: column;
}

.align-items-center {
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
}

.align-items-stretch {
  -webkit-box-align: stretch;
  -ms-flex-align: stretch;
  align-items: stretch;
}

.align-items-start {
  -webkit-box-align: start;
  -ms-flex-align: start;
  align-items: flex-start;
}

.align-items-end {
  -webkit-box-align: end;
  -ms-flex-align: end;
  align-items: flex-end;
}

.flex-wrap-nowrap {
  -ms-flex-wrap: nowrap;
  flex-wrap: nowrap;
}

.flex-wrap-wrap {
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;
}

.flex-grow-0 {
  -webkit-box-flex: 0;
    -ms-flex-positive: 0;
  flex-grow: 0;
}

.flex-grow-1 {
  -webkit-box-flex: 1;
    -ms-flex-positive: 1;
  flex-grow: 1;
}

.flex-shrink-0 {
    -ms-flex-negative: 0;
  flex-shrink: 0;
}

.flex-shrink-1 {
    -ms-flex-negative: 1;
  flex-shrink: 1;
}

.flex-basis-p0 {
    -ms-flex-preferred-size: 0%;
    flex-basis: 0%;
}

.flex-basis-p100 {
    -ms-flex-preferred-size: 100%;
    flex-basis: 100%;
}

.flex-0-0-auto {
  flex: 0 0 auto;
}

.flex-0-1-auto {
  flex: 0 1 auto;
}

.flex-1-0-auto {
  flex: 1 0 auto;
}

.flex-1-1-auto {
  flex: 1 1 auto;
}

.justify-content-flex-end {
  -webkit-box-pack: end;
  -ms-flex-pack: end;
  justify-content: flex-end;
}

.justify-content-flex-start {
  -webkit-box-pack: start;
  -ms-flex-pack: start;
  justify-content: flex-start;
}

.justify-content-space-between {
  -webkit-box-pack: justify;
  -ms-flex-pack: justify;
  justify-content: space-between;
}

.justify-content-center {
  -webkit-box-pack: center;
  -ms-flex-pack: center;
  justify-content: center;
}

.flex-row-start-center {
  .display-flex;
  .flex-wrap-nowrap;
  .flex-direction-row;
  .justify-content-flex-start;
  .align-items-center;
}

.flex-row-start-stretch {
    .display-flex;
    .flex-wrap-nowrap;
    .flex-direction-row;
    .justify-content-flex-start;
    .align-items-stretch;
}

.flex-row-center-center {
  .display-flex;
  .flex-wrap-nowrap;
  .flex-direction-row;
    .justify-content-center;
  .align-items-center;
}

.flex-row-center-stretch {
  .display-flex;
  .flex-wrap-nowrap;
  .flex-direction-row;
    .justify-content-center;
  .align-items-stretch;
}

.flex-row-end-center {
    .display-flex;
    .flex-wrap-nowrap;
    .flex-direction-row;
    .justify-content-flex-end;
    .align-items-center;
}

.flex-row-end-stretch {
  .display-flex;
  .flex-wrap-nowrap;
  .flex-direction-row;
  .justify-content-flex-end;
  .align-items-stretch;
}

.flex-column-start-center {
  .display-flex;
  .flex-wrap-nowrap;
  .flex-direction-column;
  .justify-content-flex-start;
  .align-items-center;
}

.flex-column-start-start {
  .display-flex;
  .flex-wrap-nowrap;
  .flex-direction-column;
  .justify-content-flex-start;
  .align-items-start;
}

.flex-column-start-stretch {
  .display-flex;
  .flex-wrap-nowrap;
  .flex-direction-column;
  .justify-content-flex-start;
  .align-items-stretch;
}

.dx-datagrid-empty-rows-view {
    min-height: 100px;
}

.dx-datagrid-1em-min-height {
    min-height: 1em;
}

.is-number {
  font-family: Arial, 'Times New Roman', SimHei, serif;
}

.wrapper {
  width: 100%;
}

@media (max-width: 768px) {
  .navbar-fixed-top {
    position: relative;
  }

  .sidebar-toggler {
    display: none;
  }
}

.main-content {

  .modal-footer {
    text-align: left;
    height: 80px;
    line-height: 80px;
    padding: 0;
  }

  .modal-body label {
    font-weight: normal;
  }

  .modal-header {
    text-align: left;
    height: 60px;
    line-height: 60px;
  }
}

.navbar-header {
  float: none;
}

.navbar-top-links {
  margin-right: 0;

  li {
    display: inline-block;

    :last-child {
      margin-right: 15px;
    }

    a {
      padding: 15px;
      min-height: 50px;
    }
  }

  .dropdown-menu {
    li {
      display: block;
    }

    li:last-child {
      margin-right: 0;
    }

    li a {
      padding: 3px 20px;
      min-height: 0;

      div {
        white-space: normal;
      }
    }
  }

  .dropdown-messages,
  .dropdown-tasks,
  .dropdown-alerts {
    width: 310px;
    min-width: 0;
  }

  .dropdown-messages {
    margin-left: 5px;
  }

  .dropdown-tasks {
    margin-left: -59px;
  }

  .dropdown-alerts {
    margin-left: -123px;
  }

  .dropdown-user {
    right: 0;
    left: auto;
  }
}

/*
 * Side menu toggler
 */

.menu-toggler {
  display: block;
  float: left;

  .icon-bar {
    display: block;
    width: 22px;
    height: 2px;
    border-radius: 1px;
    background-color: #888;
  }
}

/*
 * Sidebar
 */

#sidebar-area .nav > li.active {
  background-color: rgba(238, 238, 238, 0.38) !important;
}

.sidebar a {
  /*	color: #CACACA; */
  z-index: 1000;
}

.sidebar .nav-second-level,
.sidebar .nav-second-level .nav-third-level {
  /*background-color: #f8f8f8;*/
}

/*
 * Sidebar-closed 
 */
@media (min-width: 768px) {
  body.sidebar-closed .wrapper .sidebar {
    width: 45px;
  }

  body.sidebar-closed .wrapper #sidebar li.sidebar-search:hover .custom-search-form {
    display: table;
  }

  body.sidebar-closed .wrapper #sidebar li.sidebar-search:hover .search-icon {
    display: none;
  }

  body.sidebar-closed .wrapper #sidebar .sidebar-search .custom-search-form {
    display: none;
  }

  body.sidebar-closed .wrapper #sidebar .sidebar-search .search-icon {
    display: table;
    padding-top: 8px;
  }
}

@media (min-width: 768px) {
  .sidebar {
    z-index: 1;
    width: 250px;
  }

  .navbar-top-links .dropdown-messages,
  .navbar-top-links .dropdown-tasks,
  .navbar-top-links .dropdown-alerts {
    margin-left: auto;
  }
}

.nav > li > a {
  color: white !important;
  height: 55px;
}

.login-user {
  /*background-image:url(../../app-resources/images/login-user.png);
  background-repeat:no-repeat;
  -moz-background-size:100% 100%;
  filter:"progid:DXImageTransform.Microsoft.AlphaImageLoader(sizingMethod='scale')";
  background-size:100% 100%;*/
  /*background-color: #ff4d00;*/
  height: 146px;
  padding-top: 2px;
}

.sidebar-closed .login-user {
  /*background-image:url(../../app-resources/images/login-user-copy.png);
  background-repeat:no-repeat;
  -moz-background-size:100% 100%;
  filter:"progid:DXImageTransform.Microsoft.AlphaImageLoader(sizingMethod='scale')";
  background-size:100% 100%;*/
  /*background-color: #ff4d00;*/
  height: 146px;
}

.sidebar-nav {
  font-family: 'Microsoft YaHei Regular', 'Microsoft YaHei', serif;
  font-weight: 400;
  font-style: normal;
  font-size: 15px;
  color: #FFFFFF;
  text-align: left;
}

.sidebar-nav .login-user-below {
  /*background: linear-gradient(to bottom, #ff4d00, #e91e1e);*/
  min-height: 594px;
  /*background-image:url(../../app-resources/images/login-user-below.png);
       background-repeat:no-repeat;
       -moz-background-size:100% 100%;
       filter:"progid:DXImageTransform.Microsoft.AlphaImageLoader(sizingMethod='scale')";
       background-size:255px 100%;   */
  .ps-scrollbar-y-rail {
    z-index: 9999;
    background-color: transparent !important;

    .ps-scrollbar-y {
      background-color: #ffffff !important;
    }
  }
}

.sidebar .sidebar-nav.navbar-collapse {
  padding-right: 0;
  padding-left: 0;
}

.sidebar .sidebar-search {
  padding: 15px;
}

.sidebar .arrow {
  float: right;
}

.sidebar .fa.arrow:before {
  content: "\f105";
}

.sidebar .active > a > .fa.arrow:before {
  content: "\f107";
}

.sidebar a .fa.active-arrow:before {
  content: "\f107";
}

.sidebar .nav-third-level li a {
  padding-left: 52px;
}

@media (min-width: 768px) {
  .sidebar {
    z-index: 1;
    width: 250px;
  }

  .navbar-top-links .dropdown-messages,
  .navbar-top-links .dropdown-tasks,
  .navbar-top-links .dropdown-alerts {
    margin-left: auto;
  }
}

.chat {
  margin: 0;
  padding: 0;
  list-style: none;

  li {
    margin-bottom: 10px;
    padding-bottom: 5px;
    border-bottom: 1px dotted #999;

    .chat-body p {
      margin: 0;
    }
  }

  li.left .chat-body {
    margin-left: 60px;
  }

  li.right .chat-body {
    margin-right: 60px;
  }
}

.panel .slidedown .glyphicon,
.chat .glyphicon {
  margin-right: 5px;
}

.chat-panel .panel-body {
  height: 350px;
  overflow-y: scroll;
}

.login-panel {
  margin-top: 25%;
}

.flot-chart {
  display: block;
  height: 400px;
}

.flot-chart-content {
  width: 100%;
  height: 100%;
}

.dataTables_wrapper {
  position: relative;
  clear: both;
}

table.dataTable thead {
  .sorting,
  .sorting_asc,
  .sorting_desc,
  .sorting_asc_disabled,
  .sorting_desc_disabled {
    background: 0 0;
  }

  .sorting_asc:after {
    content: "\f0de";
    float: right;
    font-family: "fontawesome", serif;
  }

  .sorting_desc:after {
    content: "\f0dd";
    float: right;
    font-family: "fontawesome", serif;
  }

  .sorting:after {
    content: "\f0dc";
    float: right;
    font-family: "fontawesome", serif;
    color: rgba(50, 50, 50, .5);
  }
}

.show-grid {
  margin: 15px 0;

  [class^=col-] {
    padding-top: 10px;
    padding-bottom: 10px;
    border: 1px solid #ddd;
    background-color: #efe9e9 !important;
  }
}

.huge {
  font-size: 40px;
}

.panel-green {
  border-color: #5cb85c;

  .panel-heading {
    border-color: #5cb85c;
    color: #fff;
    background-color: #5cb85c;
  }

  a {
    color: #5cb85c;

    :hover {
      color: #3d8b3d;
    }
  }
}

.panel-red {
  border-color: #d9534f;

  .panel-heading {
    border-color: #d9534f;
    color: #fff;
    background-color: #d9534f;
  }

  a {
    color: #d9534f;

    :hover {
      color: #b52b27;
    }
  }
}

.panel-yellow {
  border-color: #f0ad4e;

  .panel-heading {
    border-color: #f0ad4e;
    color: #fff;
    background-color: #f0ad4e;
  }

  a {
    color: #f0ad4e;

    :hover {
      color: #df8a13;
    }
  }
}

footer.main-footer {
  padding: 10px 0 10px 10px;
  height: 50px;
  border-top: 1px solid #dddddd;
  font-size: 12px;
  margin-left: -30px;
  margin-right: -30px;
  margin-top: 0;
  background-color: #f5f4f0;
  display: block;
}

footer.main-footer {
  .footer-text {
    display: inline-block;
    margin-top: 7px;
    float: left;
  }

  .go-up {
    float: right;
    margin-top: 0;
    margin-right: 30px;
    display: none;
    /* need height judgement feature*/
  }
}

.text-bold {
  font-weight: 600 !important;
}

.chart {
  height: 220px;
}

/* 统一样式 */

html, body, .admin-wrapper {
  height: 100%;
  padding: 0;
  margin: 0;
}

@bgcolor-common: @color-light-gray;
@border-color: @color-light-gray-e4;

@container-ml: 10px;
@container-mr: 10px;
@container-mt: 5px;
@container-mb: 15px;
@header-height: 60px;

.admin-wrapper {

  .navbar-default {
    background-color: transparent;
    border-color: transparent !important;
  }

  .navbar {
    height: 100%;
    position: fixed;
    top: 0;
    left: 0;

    .sidebar {
      height: 100%;

      .nav-left {
        width: 250px;
        height: 60px;
        background-color: #D04A02 !important;
      }

      .sidebar-nav, .sidebar-nav .login-user-below {
        height: 100%;
      }
    }
  }

  .page-wrapper {
    margin-left: 250px;
    background-color: white;
    height: 100%;
    //母版页的容器
    .main-content {
      height: 100%;
      //.main-content 下有唯一的根标签
      > * {
        height: 100%;
        /*background-color: @bgcolor-common;*/
        //每页的导航头
        .menu-header {
          background-color: white;
          height: @header-height;
          //左侧标题
          .menu-title {
            width: 200px;
            height: 40px;
            padding: 18px 0 0 30px;
            font-size: medium;
            display: inline-block;
            float: left;
          }

          .menu-dropdown-title {
            width: 200px;
            height: 40px;
            padding: 18px 0 0 30px;
            font-size: medium;
            display: inline-block;
            float: left;
          }

          .menu-dropdown {
            display: inline-block;
            margin-top: 13px;

            .dropdown .btn-default {
              width: 150px;
              border-radius: 27px;
              height: 33px;
              background-color: @color-orange-deep;
              color: white;

              &:hover {
                background-color: @color-orange-primary;
              }
            }
          }
          //右侧日志图标
          .menu-log {
            padding-left: 20px;
            padding-top: 10px;
            display: inline-block;
            float: right;
            margin-right: 15px;
          }
        }
        //下面内容容器
        .content-container {
          height: calc(~"100% - (@{header-height} + @{container-mt} + @{container-mb})");
                    margin-left: @container-ml;
                    margin-right: @container-mr;
                    margin-top: @container-mt;
                    margin-bottom: @container-mb;
        }
      }
    }
  }

  .page-sidebar-minified {
    margin-left: 70px;
  }
}

.hyper-link {
  cursor: pointer;
  color: #6699cc;
}