/*
 * vtiger look and compatibility for Select2 4.0.13 (INC3989428).
 * Load after select2.min.css. Works with select2-compat.js, which adds the
 * Select2 3.x class names used by the skins and module scripts.
 */

/* 3.x hid the original element with display:none; validationEngine (prettySelect) relies on it */
select.select2-hidden-accessible,
input.select2-hidden-accessible {
	display: none !important;
}

/* containers sit inline like 3.x and take widths from copied classes (span*, row-fluid) */
.select2-container {
	vertical-align: middle;
}
.select2-container.hide {
	display: none !important;
}
.select2-container.row-fluid {
	width: 100%;
}

/* single select: same height/look as 3.2 + vtiger skins */
.select2-container--default .select2-selection--single {
	height: 28px;
	border: 1px solid #dddddd;
	border-radius: 2px;
	background: #ffffff;
	font-size: 14px;
	letter-spacing: 0.01em;
	color: #2b2b2b;
}
.select2-container--default .select2-selection--single .select2-selection__rendered {
	line-height: 26px;
	padding-left: 8px;
	color: #2b2b2b;
}
.select2-container--default .select2-selection--single .select2-selection__arrow {
	height: 26px;
}

/* multi select: 3.2 sizing */
.select2-container--default .select2-selection--multiple {
	min-height: 28px;
	border: 1px solid #dddddd;
	border-radius: 2px;
	cursor: text;
}
.select2-container--default.select2-container--focus .select2-selection--multiple {
	border: 1px solid #5897fb;
}
.select2-container--default .select2-selection--multiple .select2-selection__rendered {
	padding: 0 5px;
}
.select2-container--default .select2-selection--multiple .select2-selection__choice {
	margin: 3px 5px 3px 0;
	padding: 3px 5px 3px 5px;
	line-height: 13px;
	color: #333333;
	border: 1px solid #aaaaaa;
	border-radius: 3px;
	background-color: #e4e4e4;
	cursor: move;
}
.select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
	margin-right: 4px;
}
/* the label is wrapped in a <div> for the 3.x scripts (li.select2-search-choice div) */
.select2-container--default .select2-selection--multiple .select2-selection__choice > div {
	display: inline;
}
.select2-container--default .select2-selection--multiple .select2-search--inline .select2-search__field {
	margin-top: 4px;
	min-width: 200px;
}

/* disabled (UI only, value still submitted) */
.select2-container--default.select2-container--disabled .select2-selection--single,
.select2-container--default.select2-container--disabled .select2-selection--multiple {
	background-color: #eeeeee;
	cursor: default;
}

/* dropdown */
.select2-dropdown {
	border-color: #dddddd;
	border-radius: 0 0 2px 2px;
}
.select2-results__option {
	padding: 3px 7px 4px;
	line-height: 1.4;
}
.select2-results__option .select2-result-label {
	display: block;
}
.select2-container--default .select2-results__group {
	padding: 4px 6px;
	font-weight: bold;
}
.select2-container--default .select2-results > .select2-results__options {
	max-height: 200px;
}
.select2-container--default .select2-results__option[aria-disabled=true] {
	color: #999999;
}
.select2-dropdown .select2-results__message {
	padding: 1px 10px;
}
.select2-search--dropdown .select2-search__field {
	height: 26px;
	padding: 4px;
	border: 1px solid #dddddd;
	box-shadow: none;
}

/* vtiger list view filter: action icons inside dropdown rows (white icons on the highlighted row) */
.select2-result-label .filterActionImgs {
	margin-top: 3px;
	float: right;
}
.select2-results__option--highlighted .select2-result-label i {
	background-image: url("../../bootstrap/img/glyphicons-halflings-white.png");
}
