/* === Escritorio === */
.search-dropdown {
  position: relative;
  max-width: 700px;
  margin: 0 auto;
}

.search-dropdown input {
  width: 100%;
  padding: 10px;
  font-size: 16px;
  box-sizing: border-box;
  background-color: white !important;
  color: black;
}

.search-results {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: #f9f9f9;
  max-height: 200px;
  overflow-y: auto;
  z-index: 1000;
  list-style: none;
  margin: 0;
  padding: 0;
}

.search-results li {
  padding: 10px;
  border-bottom: 1px solid #ddd;
}

.search-results li a {
  color: #333;
  text-decoration: none;
}

.search-results li:hover {
  background: #eee;
}

/* === Móvil (Modal) === */
.modal-buscador {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: grey;
  /*opacity: 0.95; /* 50% de transparencia */
  z-index: 9999;
  padding: 1rem;
  overflow-y: auto;
}

.modal-buscador.active {
  display: block;
}

.modal-content {
  max-width: 100%;
  margin: 0 auto;
  padding: 15px 0;
}

@media (max-width: 480px) {
  .modal-content {
    max-width: 98%;
  }
}


.close-results {
  display: none; /* Oculto por defecto */
  font-size: 18px;
  background: transparent;
  border: none;
  color: #333;
  margin-bottom: 1rem;
  cursor: pointer;
}

.modal-content input {
  width: 95%;
  padding: 10px;
  font-size: 16px;
  margin: 0 auto 1rem;
  box-sizing: border-box;
}

.modal-buscador .search-results {
  position: static;
  max-height: none;
  border: 1px solid #ccc;
  width: 95%;
  margin: auto;
}

/* === VISIBILIDAD POR DISPOSITIVO === */

/* Por defecto (escritorio) */
.boton-buscar-mobile {
  display: none;
}

#desktopDropdown {
  display: block;
}

.close-results {
  display: none;
}

/* En móvil */
@media (max-width: 768px) {
  .boton-buscar-mobile {
    display: block;
    margin: 1rem auto;
    padding: 10px 20px;
    font-size: 16px;
  }

  #desktopDropdown {
    display: none;
  }

  .close-results {
    display: block;
  }
}


.boton-buscar-mobile{
  border-radius: 4px; /* Aplica el borde redondeado */
}
