

       .comarcas-container {
        border-radius: 5px;
        margin-bottom: 10px;
        max-height: 400px;
        color: #000;
        background-color: #fff;
    }

    /* Comarca item - Solo borde inferior (quitamos el del form-check) */
    .comarca-item {
        margin-bottom: 0;
        padding-left: 0 !important;
        border-bottom: 1px solid #ddd; /* Única línea entre comarcas */
    }

    .comarca-item:last-child {
        border-bottom: none; /* Eliminar borde del último elemento */
    }

    /* Eliminamos el borde del form-check dentro de comarca-item */
    .comarca-item .form-check {
        border-bottom: none !important;
    }

    .comarca-label {
        font-weight: bold;
        cursor: pointer;
        display: flex;
        justify-content: left;
        align-items: center;
        padding: 12px 15px;
        color: #000;
        min-height: 44px;
        box-sizing: border-box;
    }

    /* EL RESTO DE ESTILOS PERMANECE EXACTAMENTE IGUAL */
    .areas-comarca {
        display: none;
        margin-top: 0;
        color: #000;
        background-color: #f2f2f2;
        padding: 0;
        border-top: 1px solid #ddd;
    }

    .area-item {
        color: #000;
        padding: 0;
        border-bottom: 1px solid #e0e0e0;
        min-height: 44px;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }

    .area-item:last-child {
        border-bottom: none;
    }

    .subareas-container {
        display: none;
        margin-top: 0;
        color: #000;
        background-color: #e0e0e0;
        padding: 0;
        border-top: 1px solid #d0d0d0; /* Línea delimitadora superior */
    }

    .subarea-item {
        color: #000;
        padding: 0;
        border-bottom: 1px solid #ccc; /* Línea delimitadora entre subáreas */
        min-height: 44px; /* Altura consistente */
        display: flex;
        flex-direction: column;
        justify-content: center;
    }
    .sub-subareas-container {
        display: none;
        margin-top: 0;
        color: #000;
        background-color: #cccccc;
        padding: 0;
        border-top: 1px solid #bbb;
        margin-left: 0; /* Eliminamos cualquier margen izquierdo */
    }

    .sub-subareas-container .form-check {
        margin: 0;
        padding: 12px 15px 12px 45px; /* Padding izquierdo mayor para indentación visual */
        min-height: 44px;
        display: flex;
        align-items: center;
        border-bottom: 1px solid #aaa;
        position: relative; /* Para el borde completo */
    }

    /* Pseudoelemento para el borde que llega hasta el final */
    .sub-subareas-container .form-check::after {
        content: '';
        position: absolute;
        left: 0;
        right: 0;
        bottom: 0;
        height: 1px;
        background-color: #aaa;
    }

    
    /* Estilos para los elementos de formulario dentro de los contenedores */
    .comarca-item .form-check,
    .area-item .form-check,
    .subarea-item .form-check,
    .sub-subarea-item .form-check {
        margin: 0;
        padding: 12px 15px; /* Padding uniforme */
        min-height: 44px; /* Altura consistente */
        display: flex;
       
    }

    .sub-subareas-container .form-check:last-child {
        border-bottom: none; /* Eliminar borde del último elemento */
    }

    .toggle-icon {
        transition: transform 0.2s ease-in-out;
        color: #000;
        margin-left: auto; /* Alinear a la derecha */
    }

    /* Resto de tus estilos existentes... */
    .comarca-checkbox-container {
        display: flex;
        align-items: center;
        color: #000;
        width: 100%;
    }

    .comarca-checkbox-container label {
        cursor: pointer;
        position: relative;
        color: #000;
    }

    .comarca-checkbox-container input[type="checkbox"] {
        margin-right: 10px;
        cursor: pointer;
    }

    .autocomplete-items {
        position: absolute;
        border-bottom: none;
        border-top: none;
        z-index: 99;
        top: 100%;
        left: 0;
        right: 0;
        background-color: #fff;
        color: #000;
        border: 1px solid #ddd;
        border-top: none;
    }

    .autocomplete-items div {
        padding: 10px;
        cursor: pointer;
        background-color: #fff;
        color: #000;
        border-bottom: 1px solid #eee;
    }

    .autocomplete-items div:hover {
        background-color: #f0f0f0;
        color: #000;
    }

    .autocomplete-active {
        background-color: #ccc !important;
        color: #000 !important;
    }

    .autocomplete-container {
        position: relative;
        padding: 0px 20px;
    }

    .autocomplete-inline {
        position: absolute;
        top: 0;
        left: 100%;
        z-index: 99;
        background-color: #fff;
        min-width: 150px;
        color: #000;
        border: 1px solid #ddd;
    }

    .autocomplete-inline div {
        padding: 10px;
        cursor: pointer;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        color: #000;
        border-bottom: 1px solid #eee;
    }

    .autocomplete-inline div:hover {
        background-color: #f0f0f0;
        color: #000;
    }
  
    .subareas-container{
      border-bottom: 1px solid #eee;

    }
    /* #map {
    position: sticky;
    height: 80vh; 
    width: 100%;
    } */

    /* .fotocasa-modal-styles{
      width: 100% !important;
    } */
    .fc-modal-header-location {
      /* padding: 0px 0px !important; */
    }
    .fc-modal-body{
      width: 100%;
      border: none;
    }
    .form-check-label{
      color: black !important;
      font-size: 12px;
      
    }


  .leaflet-popup-content.custom-property-popup {
    margin: 0 !important;
    padding: 0 !important;
}
#map > div.leaflet-pane.leaflet-map-pane > div.leaflet-pane.leaflet-popup-pane > div > div.leaflet-popup-content-wrapper > div{
    margin: 0.3rem !important;
}
.custom-property-popup .property-panel-card_contents {
    padding: 0 !important;
}

.property-panel-card_contents_section1 {
    padding: 0 !important;
}

.custom-property-popup .carousel {
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
}

.custom-property-popup .carousel-inner {
    padding: 0 !important;
    margin: 0 !important;
}

.custom-property-popup .carousel-item img {
    width: 100% !important;
    height: 70px !important;
    object-fit: cover;
}

.leaflet-popup-close-button {
    display: none !important;
}

.map-toggle-btn {
  width: 34px;
  padding-top: 5px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: #000;         /* negro */
  background-color: #fff;
  border: 1px solid #ccc;
  text-decoration: none;
}

.map-toggle-btn:hover {
  background-color: #f0f0f0;
  text-decoration: none;
}
.force-hidden {
  display: none !important;
}



    .custom-button {
        width: 100px;    /* Menos ancho */
        height: 45px;
        gap: 5px;   /* Menos alto */
        padding: 10px 10px;  /* Menos padding */
    }
    .container-buttons {
    gap: 5px; /* Añade espacio entre los botones */
    margin-top: 10px; /* Añade un margen superior */
    margin-right: 10px;
}

    .custom-button {
        width: 100px;    /* Menos ancho */
        height: 45px;
        gap: 5px;   /* Menos alto */
        padding: 10px 10px;  /* Menos padding */

    }
    .container-buttons {
    gap: 5px; /* Añade espacio entre los botones */
    margin-top: 10px; /* Añade un margen superior */
    margin-right: 10px;
}

  @media (max-width: 992px) {
  .fotocasa-modal,
  .custom-modal {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    height: 100vh !important;
    max-width: none !important;
    max-height: none !important;
    margin: 0 !important;
    padding: 1rem;
    border-radius: 0 !important;
    overflow-y: auto;
    z-index: 999999;
  }

  .fotocasa-modal .fc-modal-body,
  .custom-modal .modal-body {
    max-height: unset;
  }

  .fotocasa-modal .fc-modal-header,
  .custom-modal .modal-header {
    padding-top: 1rem;
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 10;
  }

  .fotocasa-modal .fc-modal-footer,
  .custom-modal .modal-footer {
    position: sticky;
    bottom: 0;
    background: #fff;
    z-index: 10;
    padding: 1rem 0 0;
  }

  .fc-close-button {
    font-size: 2rem;
    line-height: 1;
  }

  body {
    overflow-x: hidden !important;
  }

  html {
    overflow-x: hidden !important;
  }

  .form-check {
    margin: 0 10px !important;
  }

  .sub-subarea-form-check {
    padding: 10px 15px !important;
  }

  .toggle-icon {
    padding-right: 20px !important;
  }

  /* Evita que contenedores amplios causen scroll */
  #selected-container-municipalities,
  .comarcas-container,
  .areas-comarca,
  .subareas-container,
  .sub-subareas-container,
  .area-item,
  .subarea-item {
    overflow-x: hidden !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }


 #mapContainer {
  padding-bottom: 20px;
  }

  #map {
    position: sticky;
    min-height: 40vh ; 
  }

}


    /* Estilo común para ambos modales (Habitaciones y Baños) */
.custom-select-wrapper {
  position: relative;
  display: inline-block;
  width: auto;
}

.custom-selected {
  padding: 0.4rem 0.6rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  background: white;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%; /* Hacer que el botón ocupe todo el ancho */
  white-space: nowrap; /* Evitar que el texto se mueva a la siguiente línea */
  gap: 15px;
}

.custom-modal {
  display: none;
  position: absolute;
  top: 100%;
  z-index: 999;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 0.25rem;
  margin-top: 0.25rem;
  box-shadow: 0 0.25rem 1rem rgba(0, 0, 0, 0.1);
  left: 0; /* Asegúrate de que el modal esté alineado correctamente */
}

@media (min-width: 991px) {
  .modal-beds, .modal-baths {
    width: 300px !important; /* Modal en vista de escritorio */
  }
}



.modal-header,
.modal-footer {
  padding: 0.5rem 1rem;
  border-bottom: 1px solid #eee;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-footer {
  border-top: 1px solid #eee;
}

.modal-body {
  padding: 0.5rem 1rem;
}

.room-options, .bath-options {
  display: flex;
  flex-wrap: wrap;
  margin-bottom: 0.5rem;
}

.option-btn {
  flex: 1;
  padding: 0.5rem;
  border: 1px solid #ccc;
  background: #f8f9fa;
  border-radius: 4px;
  cursor: pointer;
  text-align: center;
}

.checkbox-exact {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.option-btn.active {
  border: 2px solid #28a745;
  color: #28a745;
  background: #eafbea;
  font-weight: bold;
}

 /* Estilo común para los modales (ya existente) */
.custom-modal {
  display: none;
  position: absolute;
  top: 100%;
  z-index: 999;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 0.25rem;
  margin-top: 0.25rem;
  box-shadow: 0 0.25rem 1rem rgba(0, 0, 0, 0.1);
  left: 0;
}

/* Modal en vista de escritorio */
@media (min-width: 991px) {
  .modal-price {
    width: 300px !important; /* Modal en vista de escritorio */
  }
}

@media (min-width: 991px) {
  .modal-price {
    width: 300px !important; /* Modal en vista de escritorio */
  }
}

/* Modal en dispositivos móviles */


/* Encabezado y pie de modal */
.modal-header,
.modal-footer {
  padding: 0.5rem 1rem;
  border-bottom: 1px solid #eee;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-footer {
  border-top: 1px solid #eee;
}

.modal-body {
  padding: 0.5rem 1rem;
}

/* Estilo para el rango de precios */
.price-range {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem; /* Espacio entre los inputs */
}

.price-range .form-group {
  flex: 1; /* Ambos inputs ocupan el mismo ancho */
  display: flex;
  flex-direction: column;
  margin-bottom: 1rem;
}

.price-range input {
  width: 100%; /* Asegura que el input ocupe todo el espacio disponible */
  padding: 0.5rem;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.custom-selected {
  padding: 0.4rem 0.6rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  background: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  width: auto;
  white-space: nowrap;
}

/* Estilos adicionales para el comportamiento de los botones */
.custom-selected i {
  font-size: 0.9rem; /* Ajuste del icono */
}

/* Estilos para el modal de precio */

.modal-footer {
  display: flex;
  justify-content: flex-end;
}

.modal-footer .btn {
  padding: 0.5rem 1rem;
}

  
.fotocasa-select-wrapper {
  position: relative;
}

.fotocasa-selected-container {
  border: 1px solid #ced4da;
  padding: 0.4rem 0.6rem;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-radius: 0.25rem;
  background-color: #fff;
  height: calc(1.5em + 0.75rem + 2px);
}

.fotocasa-selected-container .placeholder-mls {
  background-color: white;
}


.fotocasa-modal {
  width: 500px;
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background-color: #fff;
  border: 1px solid #ced4da;
  border-top: none;
  z-index: 1000;
  border-radius: 0.25rem;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
  margin-top: 0.2rem;
}

.fotocasa-modal-small{
  width: 300px !important;
}

.fotocasa-modal.open {
  display: block;
}


.fc-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
 
  /* padding: 0.75rem 1rem; */
  border-bottom: 1px solid #dee2e6;
}
.header-modal{
 padding: 0.5rem 1rem;
}

.fc-modal-header h5 {
  margin-bottom: 0;
  font-size: 1rem;
}

.fc-close-button {
  background: none;
  border: none;
  color: #6c757d;
  font-size: 1.5rem;
  cursor: pointer;
  opacity: 0.5;
}

.fc-close-button:hover {
  opacity: 0.75;
}

.fc-modal-body {
  padding: 0.75rem 1rem;
}

.fc-option {
  margin-bottom: 0.5rem;
}

.fc-option input {
  margin-right: 0.5rem;
}

.fc-modal-footer {
  padding: 0.75rem 1rem;
  border-top: 1px solid #dee2e6;
  display: flex;
  justify-content: flex-end;
}

/* Anchos responsivos personalizados */

  .custom-geometry-label {
  pointer-events: none;
  text-align: center;
}

.geometry-name-label {
  background-color: #1ab394;
  white-space: nowrap;
  color: white; /* hace el texto invisible */
  font-weight: bold;
  padding: 2px 8px;
  border-radius: 4px;
  box-shadow: 0 0 0 1px rgba(0,0,0,0.1); /* opcional para mejor visibilidad */
}

  .toggle-header {
    cursor: pointer;
    margin: 6px 0;
}

.toggle-icon {
    float: right;
    font-size: 0.9em;
    color: #888;
}
.form-check-input {
  margin-right: 20px;
}

.form-check .form-check-input {
  margin-left: 0 !important;
}
.fc-option label{
color: #344767;
}

.option-btn {
  padding: 6px 12px;
  border: 1px solid #ccc;
  border-radius: 6px;
  background-color: #fff;
  cursor: pointer;
  transition: all 0.2s;
}

.option-btn.active {
  background-color: #1ab394;
  color: white;
  border-color: #1ab394;
}

.option-btn.custom-bed-input {
  display: flex;
  align-items: center;
  justify-content: center;
}

.custom-bed-field {
  border: none;
  background: transparent;
  outline: none;
  width: 50px;
  text-align: center;
  font-weight: bold;
  color: inherit;
  font-size: 1rem;
}
.areas-comarca,
.subareas-container,
.sub-subareas-container {
  display: none;
}

  input[type="number"].custom-bed-field {
    padding-right: 1rem; /* espacio interno para que el placeholder no toque las flechas */
    box-sizing: border-box; /* asegura que el padding no rompa el tamaño */
    height: 38px; /* opcional: asegurar altura visible */
    width: 100px; /* opcional: puedes ajustar según diseño */
  }

  /* Esto elimina flechas en algunos navegadores para que puedas controlar su posición si lo deseas */
  input[type="number"]::-webkit-inner-spin-button,
  input[type="number"]::-webkit-outer-spin-button {
    margin-left: 0.3rem; /* empuja un poco las flechas a la izquierda */
  }

    .pagination a {
        color: black;
        float: left;
        padding: 8px 16px;
        text-decoration: none;
    }

    .active a {
        background: #1ab3944a !important;
    }

    .bg-secondary {
        background-color: #1ab394 !important;
    }
    .header-map-view{
        display: inline-block;
        background: #1ab394;
        margin: 0px 0px 0px 0px;
        padding: 7px 15px;
    }
    .header-map-view:hover{
        opacity: 0.8;
    }
    .tag{
        border: 2px solid #1ab394;
        border-radius: 30px;
        padding: 3px 12px;
        font-size: 8px;
        font-weight: bold;
        margin-right: 5px;
        cursor: pointer;
    }
    .tag:hover{
        background: #1ab394;
        color: #fff;
        -moz-transform: scale(1.03);
        -webkit-transform: scale(1.03);
        -o-transform: scale(1.03);
        -ms-transform: scale(1.03);
        transform: scale(1.03);
    }

    @media (max-width: 992px) {
      /* .row {
        flex-direction: column;
        margin: 0;
        
      } */
     

      .row.mt-4 {
        width: 107%; margin-left: -3.5%;
      }

      .row.size-style-format {
        width: 107%; margin-left: -3.5%;
      }

      .col-md-3, .col-md-2, .col-md-2, .col-md-2, .col-md-12 {
        width: 100%;
        max-width: 100%;
        flex: 0 0 100%;
        margin: 0;
      }

      .form-group, .btn-group, .form-check {
        width: 100%;
      }

     
      .form-control, .form-control-alternative, .form-select {
        margin-bottom: 10px;
      }

      .card-body.p-3{
        width: 100%;
        margin: 0 auto; /* Centra el div */
        
      }

     

      .input-group-text.text-body{
        height: 40px;
      }
    }

    @media (min-width: 768px) and (max-width: 1199px) {
      .modal-dialog {
        margin: 10px auto;
        width: 80%;
        max-width: none;
      }

      .modal-content {
        padding: 10px;
      }

      .row, .col-md-6 {
        margin: 0;
        padding: 0;
        width: 100%;
      }

      .table-responsive, .table {
        margin-bottom: 0;
        width: 100%;
        table-layout: auto;
      }

      .list-group-item {
        padding: 0.5rem;
      }

      .card {
        margin-bottom: 1rem;
      }
    }


       .comarcas-container {
        border-radius: 5px;
        margin-bottom: 10px;
        max-height: 400px;
        color: #000;
        background-color: #fff;
    }

    /* Comarca item - Solo borde inferior (quitamos el del form-check) */
    .comarca-item {
        margin-bottom: 0;
        padding-left: 0 !important;
        border-bottom: 1px solid #ddd; /* Única línea entre comarcas */
    }

    .comarca-item:last-child {
        border-bottom: none; /* Eliminar borde del último elemento */
    }

    /* Eliminamos el borde del form-check dentro de comarca-item */
    .comarca-item .form-check {
        border-bottom: none !important;
    }

    .comarca-label {
        font-weight: bold;
        cursor: pointer;
        display: flex;
        justify-content: left;
        align-items: center;
        padding: 12px 15px;
        color: #000;
        min-height: 44px;
        box-sizing: border-box;
    }

    /* EL RESTO DE ESTILOS PERMANECE EXACTAMENTE IGUAL */
    .areas-comarca {
        display: none;
        margin-top: 0;
        color: #000;
        background-color: #f2f2f2;
        padding: 0;
        border-top: 1px solid #ddd;
    }

    .area-item {
        color: #000;
        padding: 0;
        border-bottom: 1px solid #e0e0e0;
        min-height: 44px;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }

    .area-item:last-child {
        border-bottom: none;
    }

    .subareas-container {
        display: none;
        margin-top: 0;
        color: #000;
        background-color: #e0e0e0;
        padding: 0;
        border-top: 1px solid #d0d0d0; /* Línea delimitadora superior */
    }

    .subarea-item {
        color: #000;
        padding: 0;
        border-bottom: 1px solid #ccc; /* Línea delimitadora entre subáreas */
        min-height: 44px; /* Altura consistente */
        display: flex;
        flex-direction: column;
        justify-content: center;
    }
    .sub-subareas-container {
        display: none;
        margin-top: 0;
        color: #000;
        background-color: #cccccc;
        padding: 0;
        border-top: 1px solid #bbb;
        margin-left: 0; /* Eliminamos cualquier margen izquierdo */
    }

    .sub-subareas-container .form-check {
        margin: 0;
        padding: 12px 15px 12px 45px; /* Padding izquierdo mayor para indentación visual */
        min-height: 44px;
        display: flex;
        align-items: center;
        border-bottom: 1px solid #aaa;
        position: relative; /* Para el borde completo */
    }

    /* Pseudoelemento para el borde que llega hasta el final */
    .sub-subareas-container .form-check::after {
        content: '';
        position: absolute;
        left: 0;
        right: 0;
        bottom: 0;
        height: 1px;
        background-color: #aaa;
    }

    
    /* Estilos para los elementos de formulario dentro de los contenedores */
    .comarca-item .form-check,
    .area-item .form-check,
    .subarea-item .form-check,
    .sub-subarea-item .form-check {
        margin: 0;
        padding: 12px 15px; /* Padding uniforme */
        min-height: 44px; /* Altura consistente */
        display: flex;
       
    }

    .sub-subareas-container .form-check:last-child {
        border-bottom: none; /* Eliminar borde del último elemento */
    }

    .toggle-icon {
        transition: transform 0.2s ease-in-out;
        color: #000;
        margin-left: auto; /* Alinear a la derecha */
    }

    /* Resto de tus estilos existentes... */
    .comarca-checkbox-container {
        display: flex;
        align-items: center;
        color: #000;
        width: 100%;
    }

    .comarca-checkbox-container label {
        cursor: pointer;
        position: relative;
        color: #000;
    }

    .comarca-checkbox-container input[type="checkbox"] {
        margin-right: 10px;
        cursor: pointer;
    }

    .autocomplete-items {
        position: absolute;
        border-bottom: none;
        border-top: none;
        z-index: 99;
        top: 100%;
        left: 0;
        right: 0;
        background-color: #fff;
        color: #000;
        border: 1px solid #ddd;
        border-top: none;
    }

    .autocomplete-items div {
        padding: 10px;
        cursor: pointer;
        background-color: #fff;
        color: #000;
        border-bottom: 1px solid #eee;
    }

    .autocomplete-items div:hover {
        background-color: #f0f0f0;
        color: #000;
    }

    .autocomplete-active {
        background-color: #ccc !important;
        color: #000 !important;
    }

    .autocomplete-container {
        position: relative;
        padding: 0px 20px;
    }

    .autocomplete-inline {
        position: absolute;
        top: 0;
        left: 100%;
        z-index: 99;
        background-color: #fff;
        min-width: 150px;
        color: #000;
        border: 1px solid #ddd;
    }

    .autocomplete-inline div {
        padding: 10px;
        cursor: pointer;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        color: #000;
        border-bottom: 1px solid #eee;
    }

    .autocomplete-inline div:hover {
        background-color: #f0f0f0;
        color: #000;
    }
  
    .subareas-container{
      border-bottom: 1px solid #eee;

    }
    /* #map {
    position: sticky;
    height: 80vh; 
    width: 100%;
    } */

    /* .fotocasa-modal-styles{
      width: 100% !important;
    } */
    .fc-modal-header-location {
      /* padding: 0px 0px !important; */
    }
    .fc-modal-body{
      width: 100%;
      border: none;
    }
    .form-check-label{
      color: black !important;
      font-size: 12px;
      
    }


  .leaflet-popup-content.custom-property-popup {
    margin: 0 !important;
    padding: 0 !important;
}
#map > div.leaflet-pane.leaflet-map-pane > div.leaflet-pane.leaflet-popup-pane > div > div.leaflet-popup-content-wrapper > div{
    margin: 0.3rem !important;
}
.custom-property-popup .property-panel-card_contents {
    padding: 0 !important;
}

.property-panel-card_contents_section1 {
    padding: 0 !important;
}

.custom-property-popup .carousel {
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
}

.custom-property-popup .carousel-inner {
    padding: 0 !important;
    margin: 0 !important;
}

.custom-property-popup .carousel-item img {
    width: 100% !important;
    height: 70px !important;
    object-fit: cover;
}

.leaflet-popup-close-button {
    display: none !important;
}

.map-toggle-btn {
  width: 34px;
  padding-top: 5px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: #000;         /* negro */
  background-color: #fff;
  border: 1px solid #ccc;
  text-decoration: none;
}

.map-toggle-btn:hover {
  background-color: #f0f0f0;
  text-decoration: none;
}
.force-hidden {
  display: none !important;
}


    .custom-button {
        width: 100px;    /* Menos ancho */
        height: 45px;
        gap: 5px;   /* Menos alto */
        padding: 10px 10px;  /* Menos padding */
    }
    .container-buttons {
    gap: 5px; /* Añade espacio entre los botones */
    margin-top: 10px; /* Añade un margen superior */
    margin-right: 10px;
}

    .custom-button {
        width: 100px;    /* Menos ancho */
        height: 45px;
        gap: 5px;   /* Menos alto */
        padding: 10px 10px;  /* Menos padding */

    }
    .container-buttons {
    gap: 5px; /* Añade espacio entre los botones */
    margin-top: 10px; /* Añade un margen superior */
    margin-right: 10px;
}

  @media (max-width: 992px) {
  .fotocasa-modal,
  .custom-modal {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    height: 100vh !important;
    max-width: none !important;
    max-height: none !important;
    margin: 0 !important;
    padding: 1rem;
    border-radius: 0 !important;
    overflow-y: auto;
    z-index: 999999;
  }

  .fotocasa-modal .fc-modal-body,
  .custom-modal .modal-body {
    max-height: unset;
  }

  .fotocasa-modal .fc-modal-header,
  .custom-modal .modal-header {
    padding-top: 1rem;
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 10;
  }

  .fotocasa-modal .fc-modal-footer,
  .custom-modal .modal-footer {
    position: sticky;
    bottom: 0;
    background: #fff;
    z-index: 10;
    padding: 1rem 0 0;
  }

  .fc-close-button {
    font-size: 2rem;
    line-height: 1;
  }

  body {
    overflow-x: hidden !important;
  }

  html {
    overflow-x: hidden !important;
  }

  .form-check {
    margin: 0 10px !important;
  }

  .sub-subarea-form-check {
    padding: 10px 15px !important;
  }

  .toggle-icon {
    padding-right: 20px !important;
  }

  /* Evita que contenedores amplios causen scroll */
  #selected-container-municipalities,
  .comarcas-container,
  .areas-comarca,
  .subareas-container,
  .sub-subareas-container,
  .area-item,
  .subarea-item {
    overflow-x: hidden !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }


 #mapContainer {
  padding-bottom: 20px;
  }

  #map {
    position: sticky;
    min-height: 40vh ; 
  }

}
    /* Estilo común para ambos modales (Habitaciones y Baños) */
.custom-select-wrapper {
  position: relative;
  display: inline-block;
  width: auto;
}

.custom-selected {
  padding: 0.4rem 0.6rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  background: white;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%; /* Hacer que el botón ocupe todo el ancho */
  white-space: nowrap; /* Evitar que el texto se mueva a la siguiente línea */
  gap: 15px;
}

.custom-modal {
  display: none;
  position: absolute;
  top: 100%;
  z-index: 999;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 0.25rem;
  margin-top: 0.25rem;
  box-shadow: 0 0.25rem 1rem rgba(0, 0, 0, 0.1);
  left: 0; /* Asegúrate de que el modal esté alineado correctamente */
}

@media (min-width: 991px) {
  .modal-beds, .modal-baths {
    width: 300px !important; /* Modal en vista de escritorio */
  }
}



.modal-header,
.modal-footer {
  padding: 0.5rem 1rem;
  border-bottom: 1px solid #eee;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-footer {
  border-top: 1px solid #eee;
}

.modal-body {
  padding: 0.5rem 1rem;
}

.room-options, .bath-options {
  display: flex;
  flex-wrap: wrap;
  margin-bottom: 0.5rem;
}

.option-btn {
  flex: 1;
  padding: 0.5rem;
  border: 1px solid #ccc;
  background: #f8f9fa;
  border-radius: 4px;
  cursor: pointer;
  text-align: center;
}

.checkbox-exact {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.option-btn.active {
  border: 2px solid #28a745;
  color: #28a745;
  background: #eafbea;
  font-weight: bold;
}

 /* Estilo común para los modales (ya existente) */
.custom-modal {
  display: none;
  position: absolute;
  top: 100%;
  z-index: 999;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 0.25rem;
  margin-top: 0.25rem;
  box-shadow: 0 0.25rem 1rem rgba(0, 0, 0, 0.1);
  left: 0;
}

/* Modal en vista de escritorio */
@media (min-width: 991px) {
  .modal-price {
    width: 300px !important; /* Modal en vista de escritorio */
  }
}

@media (min-width: 991px) {
  .modal-price {
    width: 300px !important; /* Modal en vista de escritorio */
  }
}

/* Modal en dispositivos móviles */


/* Encabezado y pie de modal */
.modal-header,
.modal-footer {
  padding: 0.5rem 1rem;
  border-bottom: 1px solid #eee;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-footer {
  border-top: 1px solid #eee;
}

.modal-body {
  padding: 0.5rem 1rem;
}

/* Estilo para el rango de precios */
.price-range {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem; /* Espacio entre los inputs */
}

.price-range .form-group {
  flex: 1; /* Ambos inputs ocupan el mismo ancho */
  display: flex;
  flex-direction: column;
  margin-bottom: 1rem;
}

.price-range input {
  width: 100%; /* Asegura que el input ocupe todo el espacio disponible */
  padding: 0.5rem;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.custom-selected {
  padding: 0.4rem 0.6rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  background: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  width: auto;
  white-space: nowrap;
}

/* Estilos adicionales para el comportamiento de los botones */
.custom-selected i {
  font-size: 0.9rem; /* Ajuste del icono */
}

/* Estilos para el modal de precio */

.modal-footer {
  display: flex;
  justify-content: flex-end;
}

.modal-footer .btn {
  padding: 0.5rem 1rem;
}

  
.fotocasa-select-wrapper {
  position: relative;
}

.fotocasa-selected-container {
  border: 1px solid #ced4da;
  padding: 0.4rem 0.6rem;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-radius: 0.25rem;
  background-color: #fff;
  height: calc(1.5em + 0.75rem + 2px);
}

.fotocasa-selected-container .placeholder-mls {
  background-color: white;
}


.fotocasa-modal {
  width: 500px;
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background-color: #fff;
  border: 1px solid #ced4da;
  border-top: none;
  z-index: 1000;
  border-radius: 0.25rem;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
  margin-top: 0.2rem;
}

.fotocasa-modal-small{
  width: 300px !important;
}

.fotocasa-modal.open {
  display: block;
}


.fc-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
 
  /* padding: 0.75rem 1rem; */
  border-bottom: 1px solid #dee2e6;
}
.header-modal{
 padding: 0.5rem 1rem;
}

.fc-modal-header h5 {
  margin-bottom: 0;
  font-size: 1rem;
}

.fc-close-button {
  background: none;
  border: none;
  color: #6c757d;
  font-size: 1.5rem;
  cursor: pointer;
  opacity: 0.5;
}

.fc-close-button:hover {
  opacity: 0.75;
}

.fc-modal-body {
  padding: 0.75rem 1rem;
}

.fc-option {
  margin-bottom: 0.5rem;
}

.fc-option input {
  margin-right: 0.5rem;
}

.fc-modal-footer {
  padding: 0.75rem 1rem;
  border-top: 1px solid #dee2e6;
  display: flex;
  justify-content: flex-end;
}



/* Anchos responsivos personalizados */





  .custom-geometry-label {
  pointer-events: none;
  text-align: center;
}

.geometry-name-label {
  background-color: #1ab394;
  white-space: nowrap;
  color: white; /* hace el texto invisible */
  font-weight: bold;
  padding: 2px 8px;
  border-radius: 4px;
  box-shadow: 0 0 0 1px rgba(0,0,0,0.1); /* opcional para mejor visibilidad */
}

  .toggle-header {
    cursor: pointer;
    margin: 6px 0;
}

.toggle-icon {
    float: right;
    font-size: 0.9em;
    color: #888;
}
.form-check-input {
  margin-right: 20px;
}

.form-check .form-check-input {
  margin-left: 0 !important;
}
.fc-option label{
color: #344767;
}


.option-btn {
  padding: 6px 12px;
  border: 1px solid #ccc;
  border-radius: 6px;
  background-color: #fff;
  cursor: pointer;
  transition: all 0.2s;
}

.option-btn.active {
  background-color: #1ab394;
  color: white;
  border-color: #1ab394;
}

.option-btn.custom-bed-input {
  display: flex;
  align-items: center;
  justify-content: center;
}

.custom-bed-field {
  border: none;
  background: transparent;
  outline: none;
  width: 50px;
  text-align: center;
  font-weight: bold;
  color: inherit;
  font-size: 1rem;
}
.areas-comarca,
.subareas-container,
.sub-subareas-container {
  display: none;
}

  input[type="number"].custom-bed-field {
    padding-right: 1rem; /* espacio interno para que el placeholder no toque las flechas */
    box-sizing: border-box; /* asegura que el padding no rompa el tamaño */
    height: 38px; /* opcional: asegurar altura visible */
    width: 100px; /* opcional: puedes ajustar según diseño */
  }

  /* Esto elimina flechas en algunos navegadores para que puedas controlar su posición si lo deseas */
  input[type="number"]::-webkit-inner-spin-button,
  input[type="number"]::-webkit-outer-spin-button {
    margin-left: 0.3rem; /* empuja un poco las flechas a la izquierda */
  }


    label{
        color:white
    }
    .btn-primary:hover, .btn.bg-gradient-primary:hover {
  background-color: #4a8d80 !important;
  border-color: #4a8d80 !important;
}
.bg-secondary {
    background-color: #1ab394 !important;
}

.row {
  overflow: visible; /* Necesario para que sticky funcione */
}

.sticky-wrapper {
  position: sticky;
  top: 90px;
}

.tag {
  border: 2px solid #1ab394;
  border-radius: 30px;
  padding: 3px 12px;
  font-size: 8px;
  font-weight: bold;
  margin-right: 5px;
  cursor: pointer;
}

section {
    overflow-x: visible !important;
    height: auto !important;
  }
/* .row {
--bs-gutter-x: 1.2rem !important;
} */


  .circle-marker {
  width: 15px;
  height: 15px;
  background-color: #ff7300;
  border-radius: 50%;
  border: 2px solid white;
  box-shadow: 0 0 2px rgba(0, 0, 0, 0.3);
}

.circle-marker-selected {
  width: 15px;
  height: 15px;
  background-color: #33ff00;
  border-radius: 50%;
  border: 2px solid white;
  box-shadow: 0 0 2px rgba(0, 0, 0, 0.3);
}

  .circle-icon-wrapper {
  background: transparent;
  border: none;
}



@media(max-width:480px){
    .btn-sm{
        font-size:10px;
        padding: 0.5rem 0.5rem;
    }
    .card-header{
        padding-inline:0 !important;        
        padding-bottom:0 !important;
        text-align:center;
        flex-direction:column
    }
}