* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

:root {
  --bg: #f6f7f9;
  --paper: #ffffff;
  --ink: #0b1320;
  --muted: #6b7280;
  --brand: #10b981;
  --line: #e5e7eb;
  --shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  --r: 14px;
}

body {
  font-family: "Montserrat", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
}

/* ===== TÍTULO ELEGANTE ===== */
#titulo-propiedad {
  font-size: clamp(2.2rem, 3vw, 2.8rem);
  font-weight: 800;
  color: #0b1320;
  text-transform: capitalize;
  letter-spacing: 0.5px;
  text-align: left;
  position: relative;
  margin-bottom: 1.4rem;
  background: linear-gradient(90deg, var(--brand) 0%, #0ea76c 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

#titulo-propiedad::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -8px;
  width: 120px;
  height: 5px;
  background: linear-gradient(90deg, var(--brand) 0%, #0ea76c 100%);
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}
/* ===== CONTENEDOR PRINCIPAL ===== */
#detalle {
  max-width: 1280px;
  margin: 2.5rem auto;
  padding: 2.5rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r);
  box-shadow: var(--shadow);
  display: grid;
  grid-template-columns: minmax(0, 480px) minmax(0, 1.8fr);
  gap: 56px;
  align-items: start;
}

#detalle h1 {
  grid-column: 1 / -1;
  font-size: clamp(1.7rem, 2.4vw, 2.2rem);
  font-weight: 800;
  margin-bottom: 0.25rem;
}

/* ===== GALERÍA ===== */
.galeria-viewport {
  position: relative;
  border-radius: var(--r);
  overflow: hidden;
  background: #fff;
  box-shadow: 0 6px 18px rgba(2, 6, 23, 0.06);
  aspect-ratio: 3 / 4;
  width: 100%;
  max-height: 580px;
}

.galeria-track {
  width: 100%;
  height: 100%;
}

.galeria-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 12px;
}

/* ===== GALERÍA MÁS GRANDE ===== */
.galeria-viewport {
  position: relative;
  border-radius: var(--r);
  overflow: hidden;
  background: #fff;
  box-shadow: 0 10px 28px rgba(2, 6, 23, 0.08);
  aspect-ratio: 3 / 4; /* MÁS ALTA QUE ANCHA */
  width: 100%;
  height: auto;
  max-height: 680px; /* más grande verticalmente */
}

.galeria-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: var(--r);
}

/* ===== BOTONES DE GALERÍA ===== */

.galeria-viewport {
position: relative
overflow: hidden
}
.galeria-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.9);
  border: none;
  color: #0b1320;
  font-size: 1.8rem;
  font-weight: 700;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  box-shadow: 0 6px 18px rgba(0,0,0,0.18);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease, color .2s ease;
  z-index: 5;
}

.galeria-btn.prev {
  left: 14px;
}

.galeria-btn.next {
  right: 14px;
}

.galeria-btn:hover {
  background: var(--brand);
  color: #fff;
  transform: translateY(-50%) scale(1.08);
  box-shadow: 0 10px 22px rgba(0,0,0,0.25);
}

/* ===== PUNTOS DE GALERÍA ===== */
.galeria-dots {
  position: absolute;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 4;
}

.galeria-dots button {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(0,0,0,0.18);
  padding: 0;
  cursor: pointer;
  transition: transform .2s ease, background .2s ease, border-color .2s ease;
}

.galeria-dots button:hover {
  transform: scale(1.15);
}

.galeria-dots [aria-current="true"] {
  background: var(--brand);
  border-color: transparent;
}


/* ===== TARJETA DERECHA ===== */
.detalle-info {
  background: linear-gradient(180deg, #ffffff 0%, #fafbfc 100%);
  border: 2px solid #e3e6ea;
  border-radius: 18px;
  padding: 40px 50px;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
  display: flex;
  flex-direction: column;
  gap: 1.4rem;
  width: 100%;
  min-width: 0;
}

/* Control de saltos y ajuste de texto */
.detalle-info,
.detalle-info * {
  overflow-wrap: anywhere;
  word-break: normal;
  white-space: normal;
  line-height: 1.7;
}

/* Etiquetas y valores */
.detalle-info p {
  display: grid; !important
  grid-template-columns: 125px minmax(0, 1fr);
  gap: 10px;
  align-items: baseline;
  margin: 0;
  max-width: 100%;
}

.detalle-info p strong {
  font-weight: 800;
  color: #0f172a;
grid-template-columns: 200px minmax(0, 1fr);
gap: 30px;

}

/* ===== DESCRIPCIÓN ===== */
#detalle-descripcion {
  display: block;
  width: 100%;
  margin-top: 1.4rem;
  padding-top: 1.2rem;
  border-top: 1px dashed #e5e7eb;
  color: #374151;
  font-size: 0.97rem;
  line-height: 1.8;
  white-space: pre-line;
  max-width: 100%;
}

#detalle-descripcion > p {
  display: block;
  width: 100%;
}

/* ===== BOTONES ===== */
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1.6rem;
}

.btn {
  display: inline-block;
  text-decoration: none;
  padding: 0.75rem 1.3rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  text-align: center;
  transition: 0.2s;
  border: 1px solid transparent;
}

.btn.primary {
  background: var(--brand);
  color: #fff;
}

.btn.ghost {
  background: transparent;
  border: 1px solid var(--brand);
  color: var(--brand);
}

.btn.primary:hover {
  filter: brightness(0.93);
}

.btn.ghost:hover {
  background: var(--brand);
  color: #fff;
}

/* ===== WHATSAPP FLOAT ===== */
#whatsapp-float {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 60px;
  height: 60px;
  background: #25D366;
  border-radius: 50%;
  box-shadow: 0 16px 40px -5px rgba(37, 211, 102, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  text-decoration: none;
  transition: transform 0.2s;
}

#whatsapp-float:hover {
  transform: scale(1.08);
}

#whatsapp-float svg {
  width: 32px;
  height: 32px;
}

/* ===== FOOTER ===== */
.site-footer {
  background: #222;
  color: #ccc;
  padding: 3rem 2rem 1rem;
  margin-top: 4rem;
}

.footer-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 5rem;
  max-width: 1100px;
  margin: auto;
}

.footer-title {
  font-size: 1.1rem;
  margin-bottom: 1rem;
  color: #fff;
}

.footer-links li,
.footer-contact li {
  list-style: none;
  margin-bottom: 0.6rem;
}

.footer-links a {
  text-decoration: none;
  color: #bbb;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: #fff;
}

.footer-brand {
  font-size: 50px;
  font-weight: bold;
  color: #fff;
  margin-bottom: 10px;
}

.footer-bottom {
  border-top: 1px solid #444;
  margin-top: 2rem;
  padding-top: 1rem;
  text-align: center;
  font-size: 0.85rem;
  color: #aaa;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  #detalle {
    grid-template-columns: 420px 1fr;
    gap: 32px;
  }
}

@media (max-width: 900px) {
  #detalle {
    display: block;
    padding: 1.25rem;
  }

  .galeria-viewport {
    aspect-ratio: 4 / 3;
    max-height: 380px;
  }

  .detalle-info {
    margin-top: 1.5rem;
    max-width: 100%;
  }
}

@media (max-width: 520px) {
  .detalle-info p {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  #detalle h1 {
    margin-bottom: 0.6rem;
  }
}

/* ===== OVERRIDES (forzar ancho y texto fluido) ===== */
#detalle {
  grid-template-columns: minmax(0, 480px) minmax(0, 2fr) !important;
  gap: 60px !important;
}

#detalle .detalle-info p {
  grid-template-columns: 125px minmax(0, 1fr) !important;
  gap: 10px !important;
  max-width: 100% !important;
}

#detalle #detalle-descripcion {
  max-width: 100% !important;
  line-height: 1.8 !important;
  white-space: pre-line !important;
}

#detalle .detalle-info,
#detalle .detalle-info * {
  min-width: 0 !important;
  overflow-wrap: anywhere !important;
  word-break: normal !important;
  white-space: normal !important;
}
