/* Durchsuchbare Combobox als select2-Ersatz (ID-6535).
   Gemeinsam genutzt vom Kündigungskonfigurator und vom cads-Tarifrechner.

   Das <select> bleibt als Formularfeld erhalten und wird nur visuell versteckt —
   nicht per display:none, damit ein nativer Submit das required-Feld noch
   erreichen könnte. */

select.iim-combobox__select {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

.iim-combobox {
	position: relative;
	width: 100%;
}

.iim-combobox__input {
	width: 100%;
	height: 34px;
	box-sizing: border-box;
	padding: 0 8px;
	border: 1px solid #cccccc;
	background: #ffffff;
}

/* Fehlerzustand aus der Validierung: die Klasse landet auf dem versteckten
   <select>, sichtbar sein muss aber das Eingabefeld daneben. */
select.iim-combobox__select.validation_error + .iim-combobox .iim-combobox__input {
	border: 3px solid #ff0000;
}

.iim-combobox__list {
	position: absolute;
	z-index: 20;
	top: 100%;
	left: 0;
	right: 0;
	max-height: 260px;
	margin: 0;
	padding: 0;
	overflow-y: auto;
	list-style: none;
	border: 1px solid #cccccc;
	border-top: 0;
	background: #ffffff;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.iim-combobox__list[hidden] {
	display: none;
}

.iim-combobox__option,
.iim-combobox__empty {
	margin: 0;
	padding: 6px 8px;
	cursor: pointer;
	line-height: 1.3;
}

.iim-combobox__option.is-active,
.iim-combobox__option:hover {
	background: #336699;
	color: #ffffff;
}

.iim-combobox__option[aria-selected="true"] {
	font-weight: 600;
}

.iim-combobox__empty {
	cursor: default;
	color: #777777;
	font-style: italic;
}
