/* Correção de contraste para campos select */
/* Este arquivo sobrescreve a opacidade problemática do style.css */

/* Campos select gerais */
.advance__search--select {
  opacity: 1 !important;
  color: #495057 !important;
}

/* Campos select dentro dos containers de filtro */
.advance__two--search__items .advance__search--select {
  opacity: 1 !important;
  color: #495057 !important;
}

/* Opções dos campos select */
.advance__search--select option {
  opacity: 1 !important;
  color: #495057 !important;
  background-color: #ffffff !important;
}

.advance__search--select option:hover {
  background-color: #f8f9fa !important;
}

.advance__search--select option:checked {
  background-color: #e9ecef !important;
  color: #495057 !important;
}

/* Campos select específicos do filtro */
.advance__search--select[name="tipo"],
.advance__search--select[name="dormitorio"],
.advance__search--select[name="bairro"] {
  opacity: 1 !important;
  color: #495057 !important;
  background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%) !important;
  border: 2px solid #e9ecef !important;
  border-radius: 12px !important;
  padding: 12px 16px !important;
  font-size: 14px !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05) !important;
  cursor: pointer !important;
  appearance: none !important;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linecap='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e") !important;
  background-position: right 12px center !important;
  background-repeat: no-repeat !important;
  background-size: 16px !important;
  padding-right: 40px !important;
}

/* Estados de foco e hover */
.advance__search--select[name="tipo"]:focus,
.advance__search--select[name="dormitorio"]:focus,
.advance__search--select[name="bairro"]:focus {
  border-color: var(--color-hover) !important;
  box-shadow: 0 0 0 3px rgba(245, 169, 83, 0.1) !important;
  outline: none !important;
  transform: translateY(-1px) !important;
}

.advance__search--select[name="tipo"]:hover,
.advance__search--select[name="dormitorio"]:hover,
.advance__search--select[name="bairro"]:hover {
  border-color: #ced4da !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08) !important;
}

/* Garantir que o texto seja sempre visível */
.advance__search--select,
.advance__search--select option,
.advance__search--select optgroup {
  color: #495057 !important;
  background-color: #ffffff !important;
}

/* Estilos para campos select com valores selecionados */
.advance__search--select:not([value=""]),
.advance__search--select:not([value="0"]) {
  color: #495057 !important;
  font-weight: 500 !important;
}

/* Estilos específicos para Select2 - tipos e bairros */
#tipoSelect, #bairroSelect {
  color: #495057 !important;
  background-color: #ffffff !important;
}

/* Container do Select2 */
.select2-container--default .select2-selection--multiple {
  background-color: #ffffff !important;
  border: 2px solid #e9ecef !important;
  border-radius: 12px !important;
  color: #495057 !important;
}

/* Texto renderizado no Select2 */
.select2-container--default .select2-selection--multiple .select2-selection__rendered {
  color: #495057 !important;
}

/* Placeholder do Select2 */
.select2-container--default .select2-selection--multiple .select2-selection__placeholder {
  color: #6c757d !important;
}

/* Campo de busca do Select2 */
.select2-container--default .select2-selection--multiple .select2-search__field {
  color: #495057 !important;
  background-color: transparent !important;
}

/* Opções do dropdown do Select2 */
.select2-container--default .select2-results__option {
  color: #495057 !important;
  background-color: #ffffff !important;
}

/* Opção destacada no dropdown */
.select2-container--default .select2-results__option--highlighted[aria-selected] {
  background-color: #f8f9fa !important;
  color: #495057 !important;
}

/* Opção selecionada no dropdown */
.select2-container--default .select2-results__option[aria-selected=true] {
  background-color: #e9ecef !important;
  color: #495057 !important;
}

/* Dropdown do Select2 */
.select2-dropdown {
  background-color: #ffffff !important;
  border: 2px solid #e9ecef !important;
  color: #495057 !important;
}

/* Responsividade */
@media only screen and (max-width: 767px) {
  .advance__search--select[name="tipo"],
  .advance__search--select[name="dormitorio"],
  .advance__search--select[name="bairro"] {
    padding: 10px 14px !important;
    border-radius: 10px !important;
    font-size: 13px !important;
  }
  
  #tipoSelect, #bairroSelect {
    font-size: 13px !important;
  }
  
  .select2-container--default .select2-selection--multiple {
    font-size: 13px !important;
  }
  
  .select2-container--default .select2-selection--multiple .select2-selection__choice {
    font-size: 11px !important;
    padding: 3px 6px !important;
  }
}

/* ESTILOS ESPECÍFICOS PARA AS TAGS/CHOICES SELECIONADAS */
/* Tags individuais que aparecem na caixa após seleção */
.select2-container--default .select2-selection--multiple .select2-selection__choice {
  background-color: #f8f9fa !important;
  border: 1px solid #e9ecef !important;
  border-radius: 6px !important;
  color: #495057 !important;
  font-size: 12px !important;
  font-weight: 500 !important;
  padding: 4px 8px !important;
  margin: 2px 4px 2px 0 !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1) !important;
  transition: all 0.3s ease !important;
}

/* Hover nas tags */
.select2-container--default .select2-selection--multiple .select2-selection__choice:hover {
  background-color: #e9ecef !important;
  color: #495057 !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15) !important;
}

/* Botão de remover (X) nas tags */
.select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
  color: #6c757d !important;
  margin-right: 6px !important;
  font-weight: bold !important;
  transition: all 0.3s ease !important;
}

/* Hover no botão de remover */
.select2-container--default .select2-selection--multiple .select2-selection__choice__remove:hover {
  color: #dc3545 !important;
  transform: scale(1.1) !important;
}

/* Texto dentro das tags */
.select2-container--default .select2-selection--multiple .select2-selection__choice span {
  color: #495057 !important;
}

/* Garantir que o texto das tags seja sempre preto */
.select2-container--default .select2-selection--multiple .select2-selection__choice {
  color: #495057 !important;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice * {
  color: #495057 !important;
} 