/*
 * SonarQube
 * Copyright (C) 2009-2016 SonarSource SA
 * mailto:contact AT sonarsource DOT com
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 3 of the License, or (at your option) any later version.
 *
 * 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
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with this program; if not, write to the Free Software Foundation,
 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
 */
@import (reference) "variables";
@import (reference) "mixins";
@import (reference) "components/ui";
@import (reference) "init/links";

// deprecated since 5.1

// use `.page-title` instead
.page_title {
  .clearfix;
  margin-bottom: 10px;
}

.loading {
  background: url("../images/loading.gif") no-repeat 4px 2px;
  color: #444;
  padding: 3px 25px;
}

// use `.text-right` instead
.right {
  text-align: right;
}

// use `.text-left` instead
.left {
  text-align: left;
}

// use `.text-center` instead
.center {
  text-align: center;
}

// use `.text-top` instead
.top {
  vertical-align: top;
}

// use `.text-bottom` instead
.bottom {
  vertical-align: bottom;
}

// use `.text-middle` instead
.middle {
  vertical-align: middle;
}

.clear {
  height: 0;
  clear: both;
}

// use `.note` instead
.subtitle {
  color: @secondFontColor;
  font-size: @smallFontSize;
}

.crossout {
  text-decoration: line-through;
}

.notes {
  color: #777;
  font-size: 11px;
  margin-bottom: 10px;
  background-color: #EFEFEF;
  border: 1px solid #cdcdcd;
  line-height: 16px;
  height: 16px;
  padding: 2px 4px;
}

// use `.alert.alert-warning` instead
.warning, .modal-warning {
  margin: 0 0 8px;
  padding: 5px 8px;
  border: 2px solid #faebcc;
  background-color: #fcf8e3;
  color: #8a6d3b;
}

// use `.alert.alert-danger` instead
.error, .modal-error {
  margin: 0 0 8px;
  padding: 5px 8px;
  border: 1px solid #ebccd1;
  background-color: #f2dede;
  color: #a94442;
}

// use `.alert.alert-success` or `.alert.alert-info` instead
.notice, .modal-notice, .info {
  margin: 0 0 8px;
  padding: 5px 8px;
  border: 1px solid #bce8f1;
  background-color: #d9edf7;
  color: #31708f;
}

div.operations {
  float: right;
  margin: 0;
}

ul.operations {
  float: right;
  height: 20px;
  line-height: 20px;
  list-style-type: none;
  margin: 0;
  background-color: #EFEFEF;
  border: 1px solid #cdcdcd;
  border-radius: 3px;
  -moz-border-radius: 3px;
  -webkit-border-radius: 3px;
}

ul.operations li {
  float: left;
  margin: 0;
  padding: 0 8px;
  font-size: 85%;
  border-right: 1px solid #cdcdcd;
}

ul.operations li.selected {
  background-color: #d4d4d4;
}

ul.operations li.last {
  border-right-width: 0;
}

ul.operations li a {
  .link-base-color;
}

ul.operations li img {
  vertical-align: middle;
  margin-right: 5px;
}

th.operations, td.operations {
  text-align: right;
}

.doc h2 {
  margin-top: 8px;
}

.doc p {
  margin: 8px 0;
}

.doc pre, pre.code {
  color: #777;
  background-color: #EFEFEF;
  padding: 10px;
  margin: 10px 0;
  border: 1px dashed #777;
  font-size: 93%;
  line-height: 1.5em;
}

.doc li {
  list-style: disc outside;
  padding: 2px;
}

.doc ul {
  list-style: none outside;
  padding-left: 30px;
}

.rulename, .rulename a {
  color: #444;
  font-weight: 600;
}

.rulename a:hover {
  text-decoration: underline;
}

.source_title {
  padding: 10px 5px;
}

.source_title span.h1 {
  font-size: 16px;
  margin-right: 10px;
}

.source_links {
  font-size: 11px;
}

.global_violations {
  width: 100%;
}

.global_violations > tbody > tr > td {
  padding-bottom: 10px;
}

.global_violations td {
  padding: 3px 0;
}

.global_violations td img, #source_title img {
  vertical-align: text-bottom;
}

.tab_header {
  padding: 5px 10px;
}

.tab_header td {
  padding-right: 7px;
}

.tab_header td.name {
  text-align: left;
  white-space: nowrap;
}

.tab_header td.value {
  text-align: right;
  white-space: nowrap;
  font-weight: bold;
}

.extension-close {
  position: absolute;
  top: 5px; right: 10px;
}

.source_options {
  margin-top: 5px;
  padding-top: 5px;
  border-top: 1px solid #ddd;
  font-size: 85%;
}

.source_options td {
  background: url("../images/sep12.png") no-repeat scroll 0 50% transparent;
  padding: 0 10px;
}

.source_options td.first {
  background: none;
  padding: 0 10px 0 0;
}

div.autocomplete {
  position: absolute;
  width: 600px;
  right: 10px;
  top: 10px;
  background-color: #fff;
  border: 1px solid #ccc;
  margin: 0;
  padding: 0;
  color: #111;
  line-height: 18px;
  box-shadow: 10px 10px 20px rgba(0, 0, 0, 0.5);
  z-index: @dropdown-menu-z-index;
}

div.autocomplete ul {
  list-style-type: none;
  margin: 0;
  padding: 0;
}

div.autocomplete ul li {
  list-style-type: none;
  display: block;
  margin: 0;
  padding: 3px 5px;
  cursor: pointer;
  color: #333;
  line-height: 18px;
  height: 18px;
  vertical-align: middle;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

div.autocomplete div.q {
  font-size: 93%;
  color: #777;
  width: 90px;
  text-align: right;
  margin-right: 5px;
  display: inline-block;

  /* For IE 7 */
  zoom: 1;
  *display: inline;
}

div.autocomplete ul li img {
  vertical-align: middle;
}

div.autocomplete ul li.selected {
  background-color: @lightBlue;
}

div.autocomplete strong {
  font-weight: bold;
}

div.autocompleteNote {
  color: #777;
  font-size: 85%;
  background-color: #EFEFEF;
  border-top: 1px solid #CCC;
  padding: 1px 10px;
}

.color_OK {
  border: 2px solid #85bb43 !important;
  color: #85bb43 !important;
}

.color_WARN {
  border: 2px solid #f90 !important;
  color: #f90 !important;
}

.color_ERROR {
  border: 2px solid #d4333f !important;
  color: #d4333f !important;
}

.admin-page-title {
  margin-bottom: 0;
}

.admin-page-description {
  font-size: 85%;
  font-weight: normal;
  margin-bottom: 25px;
}

.red-button {
  color: #990000 !important;
}

.red-button:hover {
  color: #FFFFFF !important;
  border: solid 1px #CD504A !important;
  background: #B33630 !important;
  background: -webkit-gradient(linear, left top, left bottom, from(#DC5F59), to(#B33630)) !important;
  background: -moz-linear-gradient(top, #DC5F59, #B33630) !important;
  filter: progid:DXImageTransform.Microsoft.gradient(startColorstr = '#DC5F59', endColorstr = '#B33630') !important;
}

.red-button:active {
  color: #FFFFFF !important;
  border: solid 1px #CD504A !important;
  background: #B33630 !important;
  background: -webkit-gradient(linear, left top, left bottom, from(#AC2F29), to(#D35650)) !important;
  background: -moz-linear-gradient(top, #AC2F29, #D35650) !important;
  filter: progid:DXImageTransform.Microsoft.gradient(startColorstr = '#AC2F29', endColorstr = '#D35650') !important;
}

.red-button[disabled] {
  position: relative;
  top: 0;
  text-shadow: 1px 1px 0 #FFFFFF;
  color: #BBBBBB;
  border: solid 1px #DDD;
  background: #EBEBEB;
  background: -webkit-gradient(linear, left top, left bottom, from(#FFFFFF), to(#E1E1E1));
  background: -moz-linear-gradient(top, #FFFFFF, #E1E1E1);
  filter: progid:DXImageTransform.Microsoft.gradient(startColorstr = '#FFFFFF', endColorstr = '#E1E1E1');
  cursor: default;
}

a.external {
  background: url('../images/links/external.png') no-repeat 100% 0;
  padding: 0 16px 0 0;
}

.fav {
  display: inline-block;
  background: url('../images/star.png') no-repeat 100% 0;
  width: 16px;
  height: 16px;
  vertical-align: text-bottom;
}

.notfav {
  display: inline-block;
  background: url('../images/star_off.png') no-repeat 100% 0;
  width: 16px;
  height: 16px;
  vertical-align: text-bottom;
}

/* DUPLICATIONS */

.duplications {
  max-width: 100%;
}

.duplications td.item {
  text-align: right;
  vertical-align: top;
  padding: 0;
}

.duplications td.item p {
  padding: 3px 5px;
}

.duplications td.fileItem {
  text-align: left;
  vertical-align: top;
  padding: 0;
  white-space: nowrap;
}

.duplications td.fileItem p {
  padding: 3px 5px;
}

.duplications td.item p.selected, .duplications td.fileItem p.selected {
  background-color: #EFEFEF;
  border-top: 1px solid #DDD;
  border-bottom: 1px solid #DDD;
  padding: 3px 5px;
}

.duplications td.fileItem p.selected a {
  text-decoration: none;
}

.duplications td.sourceItem {
  padding: 0;
  background-color: #EFEFEF;
  border: 1px solid #DDD;
  border-left: none;
}

.duplications td.sourceItem p {
  padding: 3px;
}

.duplicationsMessage {
  padding: 10px;
}

.discussion {
  width: 100%;
  border: 1px solid #DDDDDD;
}

.discussionComment.first {
  border-top: none;
}

.discussionComment {
  background-color: #EFEFEF;
  border-top: 1px solid #DDDDDD;
  line-height: 1.5em;
  margin: 0;
  padding: 5px 10px;

  h4 {
    font-size: 90%;
    margin-bottom: 2px;
  }

  h4 img {
    vertical-align: sub;
  }

  ol li {
    list-style: decimal inside;
  }

  ul li {
    list-style: square inside;
  }

  pre {
    padding: 10px;
    border: 1px dashed #DDD;
    color: #444;
    font-size: 12px;
  }
}

div.comment-excerpt {
  background-color: transparent;
  margin-top: 5px;
  margin-bottom: 5px;
  color: #777777;
  font-size: 90%;
}