:root {
  --color-primary: #295d6b;
  --color-primary-dark: #1b3e48;
  --color-accent: #ed956f;
  --color-whatsapp: #25d366;
  --color-bg-soft: #f6f8fa;
  --radius: .6rem;
}

body {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: #212529;
  background-color: #fff;
}

a { color: inherit; }

.text-primary { color: var(--color-primary) !important; }
.bg-primary { background-color: var(--color-primary) !important; }
.bg-accent { background-color: var(--color-accent) !important; }
.btn-primary {
  background-color: var(--color-primary);
  border-color: var(--color-primary);
}
.btn-primary:hover, .btn-primary:focus {
  background-color: var(--color-primary-dark);
  border-color: var(--color-primary-dark);
}
.btn-outline-primary {
  color: var(--color-primary);
  border-color: var(--color-primary);
}
.btn-outline-primary:hover {
  background-color: var(--color-primary);
  border-color: var(--color-primary);
}

.navbar-brand { font-size: 1.35rem; padding-top: 0; padding-bottom: 0; }
.header-logo { height: 52px; width: auto; display: block; }
.footer-logo {
  height: 60px;
  width: auto;
  display: block;
  background: #fff;
  border-radius: .5rem;
  padding: .5rem .75rem;
}

.nav-link {
  font-weight: 500;
  color: #33465c;
}
.nav-link:hover { color: var(--color-primary); }

/* --- Hero / buscador --- */
.hero {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
  color: #fff;
  padding: 4.5rem 0 6rem;
}
.hero h1 { font-weight: 700; }
.hero-subtitulo { color: rgba(255,255,255,.85); }

.buscador-card {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: 0 1rem 3rem rgba(0,0,0,.15);
  padding: 1.5rem;
  margin-top: -3.5rem;
  position: relative;
  z-index: 2;
}

/* --- Tarjetas de inmuebles --- */
.tarjeta-inmueble {
  border: 1px solid #e9ecef;
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform .15s ease, box-shadow .15s ease;
}
.tarjeta-inmueble:hover {
  transform: translateY(-4px);
  box-shadow: 0 .75rem 1.5rem rgba(20,50,74,.12);
}
.tarjeta-imagen {
  position: relative;
  aspect-ratio: 4 / 3;
  background-color: #e9ecef;
  overflow: hidden;
}
.tarjeta-imagen .card-img-top {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.tarjeta-imagen-vacia {
  width: 100%;
  height: 100%;
}
.badge-operacion {
  position: absolute;
  top: .6rem;
  left: .6rem;
}
.badge-estado {
  position: absolute;
  top: .6rem;
  right: .6rem;
}
.caracteristicas li:not(:last-child)::after {
  content: "•";
  margin-left: .5rem;
  color: #adb5bd;
}

/* --- Banner de Reels (home) --- */
.reels-banner {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.1rem 1.25rem;
  border-radius: var(--radius);
  background: linear-gradient(115deg, var(--color-primary) 0%, var(--color-accent) 100%);
  color: #fff;
  text-decoration: none;
  box-shadow: 0 .6rem 1.5rem rgba(237, 149, 111, .3);
  transition: transform .15s ease, box-shadow .15s ease;
}
.reels-banner:hover {
  color: #fff;
  transform: translateY(-3px);
  box-shadow: 0 .9rem 2rem rgba(237, 149, 111, .4);
}
.reels-banner-play {
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: rgba(255,255,255,.25);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: reels-pulso 2s ease-in-out infinite;
}
@keyframes reels-pulso {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255,255,255,.35); }
  50% { box-shadow: 0 0 0 10px rgba(255,255,255,0); }
}
.reels-banner-texto {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  line-height: 1.3;
}
.reels-banner-badge {
  align-self: flex-start;
  font-size: .68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  background: rgba(255,255,255,.9);
  color: var(--color-primary-dark);
  border-radius: 1rem;
  padding: .1rem .5rem;
  margin-bottom: .3rem;
}
.reels-banner-texto strong {
  font-size: 1.05rem;
}
.reels-banner-sub {
  font-size: .85rem;
  opacity: .92;
}
.reels-banner-flecha {
  flex-shrink: 0;
  opacity: .85;
}
@media (max-width: 575.98px) {
  .reels-banner-sub { display: none; }
}

/* --- Sección destacados / sobre nosotros --- */
.seccion { padding: 4rem 0; }
.seccion-alt { background-color: var(--color-bg-soft); }

/* --- Filtros de listado --- */
.filtros-card {
  border-radius: var(--radius);
  border: 1px solid #e9ecef;
}

/* --- Detalle de inmueble --- */
.detalle-carousel .carousel-item img {
  width: 100%;
  height: 460px;
  object-fit: cover;
  border-radius: var(--radius);
}
@media (max-width: 767.98px) {
  .detalle-carousel .carousel-item img { height: 280px; }
}
.mapa-embed {
  width: 100%;
  height: 320px;
  border: 0;
  border-radius: var(--radius);
}
.ficha-caracteristicas .item {
  border: 1px solid #e9ecef;
  border-radius: var(--radius);
  padding: 1rem;
  text-align: center;
}

/* --- Botón flotante WhatsApp --- */
.whatsapp-flotante {
  position: fixed;
  bottom: 1.25rem;
  right: 1.25rem;
  width: 56px;
  height: 56px;
  background-color: var(--color-whatsapp);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 .5rem 1.25rem rgba(0,0,0,.25);
  z-index: 1030;
  transition: transform .15s ease;
}
.whatsapp-flotante:hover { transform: scale(1.08); color: #fff; }

/* --- Footer --- */
.footer-site {
  background-color: var(--color-primary-dark);
}
.footer-links a {
  color: rgba(255,255,255,.75);
  text-decoration: none;
  display: inline-block;
  padding: .15rem 0;
}
.footer-links a:hover { color: #fff; }
.text-light-50 { color: rgba(255,255,255,.6); }
.footer-social {
  color: rgba(255,255,255,.8);
  display: inline-flex;
}
.footer-social:hover { color: #fff; }
.footer-bottom {
  background-color: #081521;
  color: rgba(255,255,255,.55);
}
