form#contact-form-modal {
  display: block;
}

.intospinner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  margin: 0px auto;
  box-shadow: 0 2px 24px #0003;
  border-radius: 16px;
  background: #000000;
  padding: 32px 30px;
  width: 68%;
  max-width: 310px;
  color: #fff !important;
}

#splitview-modal,
.modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  justify-content: center;
  align-items: center;
  z-index: 999999;
  backdrop-filter: blur(5px);
  background: rgba(0, 0, 0, 0.4);
  width: 100vw;
  height: 100vh;
}

/* Caja del Modal */
.modal-content,
.modal-window {
  position: relative;
  animation: modalSlideUp 0.3s ease-out;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  border-radius: 24px;
  background: white;
  padding: 30px;
  width: 90%;
  max-width: 500px;
}

@keyframes modalSlideUp {
  from {
    transform: translateY(30px);
    opacity: 0;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.close-modal {
  position: absolute;
  top: 20px;
  right: 20px;
  cursor: pointer;
  border: none;
  background: none;
  color: #a0aec0;
  font-size: 28px;
}

.modal-result {
  margin: 25px 0;
  border-radius: 20px;
  background: #1a202c;
  padding: 25px;
  color: white;
  text-align: center;
}

.btn-wa-modal {
  display: block;
  border-radius: 12px;
  background: #25d366;
  padding: 15px;
  color: white;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
}

/* CALCULADORA Y OTROS */

/* CALCULADORA */
/* Botón de apertura */
.btn-open-calc {
  display: flex;
  align-items: center;
  gap: 10px;
  transition: all 0.3s;
  cursor: pointer;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #f8fafc;
  padding: var(--space-3) var(--space-4);
  font-weight: 600;
  font-size: var(--text-xs);
}

.btn-open-calc:hover {
  transform: translateY(-2px);
  background: #edf2f7;
}

/* Grid de inputs */
.calc-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}

.calc-field:last-child {
  grid-column: span 2;
}

.input-group {
  display: flex;
  margin-top: 5px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 8px 12px;
}

.input-group input {
  outline: none;
  border: none;
  width: 100%;
  font-weight: 600;
}

.modal-prop-title {
  display: inline-block;
  /* O block, dependiendo de tu estructura */
  vertical-align: bottom;
  max-width: 250px;
  /* Evita que el texto salte a la siguiente línea */
  overflow: hidden;
  /* Esconde lo que sobra */
  text-overflow: ellipsis;
  /* Ajusta este ancho según el tamaño de tu modal */
  white-space: nowrap;
  /* Agrega los "..." al final */
}

.modal-header p {
  display: flex;
  gap: 5px;
  white-space: nowrap;
}

.modal-prop-title {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Contenedor del campo para consistencia */
.calc-field select {
  appearance: none;
  /* Quita la flecha fea por defecto de Windows/Mac */
  -webkit-appearance: none;
  -moz-appearance: none;
  transition: all 0.2s ease;
  cursor: pointer;
  /* Gris muy claro igual que tus inputs */
  border: 1px solid #e2e8f0;
  border-radius: 12px;

  /* Agregamos una flecha personalizada con un SVG en el fondo */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23a0aec0'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
  background-position: right 15px center;
  background-size: 18px;
  background-repeat: no-repeat;
  background-color: #f8fafc;
  padding: 12px 15px;

  width: 100%;
  color: #2d3748;
  font-weight: 600;
  font-size: 15px;
}

/* Efecto al hacer clic o foco */
.calc-field select:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(26, 32, 44, 0.05);
  border-color: #1a202c;
  background-color: #ffffff;
}

/* Estilo para los 'options' (limitado por el navegador, pero ayuda) */
.calc-field select option {
  padding: 10px;
  font-weight: 500;
}

/* Ajuste para el label del select */
.calc-field label {
  display: block;
  margin-bottom: 8px;
  color: #4a5568;
  font-weight: 700;
}

/* Estructura base (Escritorio) */
.calc-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  /* Dos columnas */
  gap: 15px;
  margin-bottom: 20px;
}

.input-group:focus-within {
  box-shadow: 0 0 0 1px #1a202c;
  border-color: #1a202c;
}

@media (max-width: 600px) {

  /* Forzamos la columna única sin excepciones */
  .calc-grid {
    display: flex !important;
    flex-direction: column !important;
    gap: 20px !important;
    /* Más aire entre campos */
  }

  /* El contenedor del input ($ + número) */
  .input-group {
    display: flex !important;
    align-items: center !important;
    transition: border-color 0.2s;
    border: 1px solid #e2e8f0 !important;
    border-radius: 12px !important;
    background: #f8fafc !important;
    padding: 0 15px !important;
    height: 55px !important;
  }

  /* El símbolo $ se queda quieto a la izquierda */
  .input-group span {
    /* Ancho fijo para que todos los $ se alineen */
    display: inline-block;
    margin-right: 12px !important;
    width: 15px !important;
    color: #1a202c !important;
    font-weight: 800 !important;
  }

  /* El número ocupa el resto del espacio y se alinea a la izquierda */
  .input-group input {
    flex: 1 !important;
    outline: none !important;
    border: none !important;
    background: transparent !important;
    padding: 0 !important;
    font-weight: 600 !important;
    font-size: 16px !important;
    text-align: left !important;
  }

  /* Alineamos el dropdown para que mida lo mismo */
  .calc-field select {
    width: 100% !important;
    height: 55px !important;
  }
}

.calc-field label {
  display: block;
  margin-bottom: 8px;
  color: #4a5568;
  font-weight: 700;
  font-size: 14px;
}

p.modal-subtitle {
  display: -webkit-box;
  padding-bottom: 0.8rem;
  -webkit-line-clamp: 2;
  font-size: 14px;
  line-height: 1.3;
  -webkit-box-orient: vertical;
  margin-bottom: 16px;
  height: 37px;
  overflow: hidden;
}

.modal-result h2 {
  margin: 0px;
}

.modal-result {
  font-size: 12px;
  line-height: 1.5;
}

/* ---------------- */
/* Estilos para el modal de filtro */
/* ---------------- */
#modal-btn-pop-filtro {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  animation: fadeInBackground 0.3s ease-out;
  background-color: rgba(0, 0, 0, 0.45);
  width: 100vw;
  height: 100dvh;
}

#modal-btn-pop-filtro.active {
  display: flex;
}

/* Animación para que el fondo no aparezca de golpe */
@keyframes fadeInBackground {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

/* Evitar que se pierda el scroll si el modal es muy alto en pantallas pequeñas */
@media (max-width: 600px) {
  #modal-btn-pop-filtro {
    align-items: flex-end;
    /* En móvil, el modal puede subir desde abajo */
  }
}

/* -------- */
/* Scroll interno para que el Header y Footer se queden fijos */
#modal-filtros-content {
  /* Estructura Interna */
  display: flex;
  /* Posicionamiento y Tamaño */
  position: relative;
  flex-direction: column;
  /* Corta el contenido que sobresale de los bordes redondeados */

  /* Animación de entrada */
  animation: modalSlideUp 0.3s cubic-bezier(0.2, 0, 0, 1);
  /* Ancho ideal para escritorio */
  margin: 2rem auto;
  /* Bordes redondeados modernos */
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.25);
  border-radius: 28px;
  /* Para que no se salga de la pantalla */

  /* Diseño y Fondo */
  background-color: #ffffff;
  width: 100%;
  max-width: 600px;
  max-height: 90dvh;
  overflow: hidden;
}

/* Scroll interno para que el Header y Footer se queden fijos */
#modal-filtros-content .filter-scroll-area {
  flex: 1;
  padding: 0 24px;
  overflow-y: auto;
  scrollbar-color: #ddd transparent;
  scrollbar-width: thin;
}

/* Estilo para navegadores Webkit (Chrome/Safari) */
#modal-filtros-content .filter-scroll-area::-webkit-scrollbar {
  width: 6px;
}

#modal-filtros-content .filter-scroll-area::-webkit-scrollbar-thumb {
  border-radius: 10px;
  background: #ddd;
}

/* Animación suave */
@keyframes modalSlideUp {
  from {
    transform: translateY(40px);
    opacity: 0;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Ajuste para dispositivos móviles */
@media (max-width: 640px) {
  #modal-filtros-content {
    margin: 0;
    border-radius: 0;
    max-width: 100%;
    height: 100%;
    /* Pantalla completa en móvil */
    max-height: 100dvh;
    /* O bordes solo arriba si prefieres estilo "drawer" */
  }
}

/* Encabezado */
.filter-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #f0f0f0;
  padding: 24px;
}

.filter-header h3 {
  margin: 0;
  font-weight: 800;
  font-size: 1.1rem;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

/* Área de contenido con scroll suave */
.filter-scroll-area {
  padding: 24px;
  overflow-y: auto;
  scrollbar-width: thin;
}

/* Secciones */
.filter-section {
  margin-bottom: 0.6rem;
}

.section-label {
  display: block;
  margin-bottom: 16px;
  color: #1a1a1a;
  font-weight: 700;
  font-size: 0.95rem;
}

/* Chips de Amenidades */
.chips-container {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.modern-chip {
  cursor: pointer;
}

.modern-chip input {
  display: none;
}

.chip-content {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid #e2e8f0;
  border-radius: 100px;
  background: #fff;
  padding: 6px 12px;
  font-size: 13px;
}

/* Estado Activo: Cuando el checkbox está marcado */
.modern-chip input:checked+.chip-content,
.modern-chip.active .chip-content {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  border-color: #000;
  background: #000;
  color: #fff;
}

/* Rangos de Precio y Hab */
.modern-ranges {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 15px;
}

.range-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.range-group label {
  color: #64748b;
  font-weight: 600;
  font-size: 12px;
}

.range-group input {
  transition: border-color 0.2s;
  outline: none;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 12px 16px;
  font-size: 15px;
}

.range-group input:focus {
  border-color: #000;
  background: #f8fafc;
}

/* Botón Ver Más */
.expand-btn {
  cursor: pointer;
  margin-top: 10px;
  border: none;
  border-radius: 12px;
  background: #f1f5f9;
  padding: 10px 20px;
  font-weight: 600;
  font-size: 13px;
}

/* Footer Fijo */
.filter-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid #f0f0f0;
  background: #fff;
  padding: 20px 24px;
}

.apply-btn {
  transition: transform 0.1s ease;
  cursor: pointer;
  border: none;
  border-radius: 14px;
  background: #000;
  padding: 14px 30px;
  color: #fff;
  font-weight: 700;
}

.apply-btn:active {
  transform: scale(0.96);
}

.clear-btn {
  cursor: pointer;
  border: none;
  background: none;
  color: #64748b;
  font-weight: 600;
  font-size: 14px;
  text-decoration: underline;
}

/* Botón de cerrar (X) */
.close-btn {
  display: flex;
  justify-content: center;
  align-items: center;
  transition: all 0.2s ease;
  cursor: pointer;
  margin: 0;
  /* Fondo gris muy tenue */
  border: none;
  border-radius: 50%;
  background: #f5f5f5;
  padding: 0;
  /* Lo hace circular */
  width: 36px;
  height: 36px;
  color: #1a1a1a;
  font-size: 24px;
  line-height: 1;
}

/* Efecto al pasar el mouse */
.close-btn:hover {
  transform: scale(1.1);
  background-color: #e0e0e0;
  /* Crece un poquito */
}

/* Efecto al hacer clic */
.close-btn:active {
  transform: scale(0.95);
  background-color: #d0d0d0;
}