/* ============================================================
   MARLYPROPERTIES — hoja de estilos
   Colores y tipografia heredados del diseno original:
   naranja #fb6a19 · azul marino #1a212b · grises #f5f5f5 #ddd
   body Roboto · titulos Lato
   ============================================================ */
:root {
  --orange: #fb6a19;
  --orange-dark: #e05b0e;
  --navy: #1a212b;
  --navy-soft: #27313f;
  --bg-light: #f5f5f5;
  --border: #ddd;
  --text: #333;
  --text-muted: #787878;
  --white: #fff;
  --green: #3c763d;
  --red: #c0392b;
  --amber: #b3820f;
  --radius: 6px;
  --shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
  --shadow-lg: 0 6px 18px rgba(0, 0, 0, 0.18);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Roboto', 'Helvetica Neue', Arial, sans-serif;
  font-weight: 400;
  color: var(--text);
  line-height: 1.6;
  background: var(--white);
}
h1, h2, h3, h4, .logo { font-family: 'Lato', 'Roboto', sans-serif; font-weight: 700; color: var(--navy); }
h1 { font-size: 2.2rem; line-height: 1.2; margin: 0 0 0.4rem; }
h2 { font-size: 1.6rem; margin: 0 0 1rem; }
img { max-width: 100%; display: block; }
a { color: var(--orange); text-decoration: none; }
a:hover { color: var(--orange-dark); }
.container { max-width: 1160px; margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 760px; }
.padded { padding: 54px 0; }
.bg-light { background: var(--bg-light); }
.muted { color: var(--text-muted); }
.center { text-align: center; }
.mt-2 { margin-top: 24px; }

/* ---------- header ---------- */
.site-header { background: var(--white); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 50; }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 12px 0; }
.logo { font-size: 1.4rem; letter-spacing: 0.4px; color: var(--navy); flex-shrink: 0; }
.logo strong { color: var(--orange); }
.logo img { display: block; height: 80px; width: auto; max-width: 300px; }
.main-nav { display: flex; align-items: center; justify-content: flex-end; gap: 24px; flex-wrap: wrap; }
.main-nav a { color: var(--navy); font-weight: 500; }
.main-nav a:hover { color: var(--orange); }
.nav-toggle {
  display: none; position: absolute; top: 50%; right: 14px; transform: translateY(-50%);
  background: none; border: 1px solid var(--border); border-radius: var(--radius);
  font-size: 1.2rem; padding: 4px 10px; cursor: pointer; color: var(--navy); z-index: 51;
}
.lang-switch { font-size: 0.9rem; color: var(--text-muted); }
.lang-switch a { color: var(--text-muted); font-weight: 700; }
.lang-switch a:hover { color: var(--orange); }

/* ---------- botones ---------- */
.btn {
  display: inline-block; padding: 11px 22px; border: 1px solid transparent;
  border-radius: var(--radius); font-family: inherit; font-size: 1rem; cursor: pointer;
  text-align: center; transition: background 0.2s, color 0.2s;
}
.btn-primary { background: var(--orange); color: var(--white); }
.btn-primary:hover { background: var(--orange-dark); color: var(--white); }
.btn-outline { background: transparent; color: var(--orange); border-color: var(--orange); }
.btn-outline:hover { background: var(--orange); color: var(--white); }
.btn-dark { background: var(--navy); color: var(--white); }
.btn-dark:hover { background: var(--navy-soft); color: var(--white); }
.btn-sm { padding: 8px 14px; font-size: 0.9rem; }
.btn-block { display: block; width: 100%; }
.wa-link { font-weight: 600; color: #25d366; }

/* ---------- hero ---------- */
.hero {
  background: linear-gradient(120deg, var(--navy) 0%, #2b3a4d 60%), var(--navy);
  color: var(--white); padding: 90px 0 80px;
}
.hero h1 { color: var(--white); font-size: 2.6rem; max-width: 760px; }
.hero p { font-size: 1.15rem; color: #cfd6e0; max-width: 640px; }
.hero .btn-primary { margin-top: 14px; }
.hero .accent { color: var(--orange); }

/* ---------- grid de tarjetas ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 22px; }
.card {
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow); color: inherit; display: block;
  transition: transform 0.15s, box-shadow 0.15s;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); color: inherit; }
.card-img { position: relative; aspect-ratio: 3 / 2; background: var(--bg-light); }
.card-img img { width: 100%; height: 100%; object-fit: cover; }
.card-body { padding: 14px 16px 16px; }
.town { color: var(--text-muted); font-size: 0.85rem; }
.card-title { color: var(--navy); font-weight: 700; font-size: 1.05rem; margin: 2px 0 4px; }
.meta { color: var(--text-muted); font-size: 0.9rem; }
.price { color: var(--orange); font-weight: 700; font-size: 1.2rem; margin-top: 6px; }
.card-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; }
.why-ico {
  width: 46px; height: 46px; border-radius: 50%; background: var(--navy); color: var(--white);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.35rem; font-weight: 700; margin-bottom: 12px; line-height: 1;
}
.why-card .card-body { padding: 22px 20px 20px; }

/* ---------- badges / tags ---------- */
.tag {
  display: inline-block; background: var(--bg-light); border: 1px solid var(--border);
  color: var(--text); border-radius: 999px; padding: 2px 10px; font-size: 0.78rem; margin: 2px 4px 2px 0;
}
.badge { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 0.8rem; color: var(--white); }
.badge.available { background: var(--green); }
.badge.reserved { background: var(--amber); }
.badge.sold { background: var(--red); }
.badge.market { background: var(--orange); }
.card .badge { position: absolute; top: 10px; left: 10px; }
.card .badge + .badge { left: auto; right: 10px; }
.flex-between { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.detail-tags { margin-top: 8px; }

/* ---------- filtros ---------- */
.filters {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px;
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 16px; box-shadow: var(--shadow); margin-bottom: 26px;
}
.filters select, .filters input {
  width: 100%; padding: 9px 10px; border: 1px solid var(--border); border-radius: var(--radius);
  font: inherit; background: var(--white); color: var(--text);
}
.filters label { font-size: 0.8rem; color: var(--text-muted); display: block; margin-bottom: 3px; }
.filters .btn { align-self: end; }

/* ---------- ficha / detalle ---------- */
.detail-header { background: var(--bg-light); padding: 34px 0; border-bottom: 1px solid var(--border); }
.detail-hdr-flex { display: flex; justify-content: space-between; gap: 20px; align-items: flex-start; flex-wrap: wrap; }
.price.big { font-size: 1.9rem; }
.detail-layout { display: grid; grid-template-columns: 1fr 320px; gap: 28px; align-items: start; }
.gallery { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 20px; }
.gallery img { border-radius: var(--radius); aspect-ratio: 3/2; object-fit: cover; }
.feature-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin: 18px 0; }
.feature { background: var(--bg-light); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px; text-align: center; }
.feature strong { display: block; color: var(--orange); font-size: 1.25rem; }
.feature span { font-size: 0.85rem; color: var(--text-muted); }
.side-box { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.side-box h3 { margin: 6px 0 14px; }
.big-number { font-size: 2.6rem; color: var(--orange); font-weight: 700; line-height: 1; }
.status-available { color: var(--green); font-weight: 600; margin: 8px 0; }

/* ---------- breadcrumb ---------- */
.breadcrumb { max-width: 1160px; margin: 0 auto; padding: 16px 20px 0; font-size: 0.88rem; color: var(--text-muted); }
.breadcrumb a { color: var(--text-muted); }
.breadcrumb .sep { margin: 0 6px; }

/* ---------- formularios ---------- */
.lead-form { display: grid; gap: 12px; margin: 20px 0; }
.lead-form input, .lead-form textarea {
  width: 100%; padding: 11px 12px; border: 1px solid var(--border); border-radius: var(--radius);
  font: inherit; background: var(--white); color: var(--text);
}
.lead-form .btn { justify-self: start; }
.form-msg { font-weight: 600; color: var(--green); }
.form-msg.error { color: var(--red); }

/* ---------- footer ---------- */
.site-footer { background: var(--navy); color: #cfd6e0; padding: 40px 0 0; margin-top: 0; }
.site-footer .logo { color: var(--white); }
.site-footer .logo img { display: block; height: 48px; mix-blend-mode: multiply; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 26px; padding-bottom: 28px; }
.footer-grid a { display: block; color: #cfd6e0; margin: 4px 0; }
.footer-grid a:hover { color: var(--orange); }
.footer-bottom { border-top: 1px solid #39424f; padding: 14px 20px; font-size: 0.85rem; color: #9aa4b1; }

/* ---------- aviso de cookies (RGPD) ---------- */
.cookie-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 90;
  background: var(--white); border-top: 1px solid var(--border);
  box-shadow: 0 -4px 16px rgba(26, 33, 43, 0.12);
}
.cookie-inner {
  max-width: 1160px; margin: 0 auto; padding: 13px 20px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.cookie-msg { margin: 0; font-size: 0.88rem; color: var(--text); flex: 1 1 340px; }
.cookie-actions { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.cookie-link { color: var(--orange); font-weight: 600; font-size: 0.88rem; }
.cookie-link:hover { color: var(--orange-dark); }
.cookie-actions .btn { padding: 8px 20px; }

/* ---------- WhatsApp / llamar flotantes ---------- */
.wa-float {
  position: fixed; right: 18px; bottom: 18px; z-index: 60;
  background: #25d366; color: #fff; border-radius: 999px; padding: 14px 18px;
  box-shadow: var(--shadow-lg); font-weight: 700; font-family: 'Lato', sans-serif;
}
.wa-float:hover { color: #fff; filter: brightness(1.05); }
.call-float {
  position: fixed; right: 18px; bottom: 78px; z-index: 60;
  background: var(--orange); color: #fff; border-radius: 999px; padding: 14px 18px;
  box-shadow: var(--shadow-lg); font-weight: 700; font-family: 'Lato', sans-serif;
}
.call-float:hover { color: #fff; filter: brightness(1.05); }

/* acciones de contacto directo (detalle: llamar / WhatsApp) */
.side-actions { display: grid; gap: 10px; margin-top: 14px; }
.side-actions .btn-block { padding: 11px 12px; }

/* ---------- utilidades ---------- */
.demo-note {
  background: #fff7e6; border: 1px dashed #e0a800; color: #7a5b00;
  border-radius: var(--radius); padding: 10px 14px; margin-bottom: 18px; font-size: 0.88rem;
}

/* ---------- responsive ---------- */
@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .header-inner { padding: 10px 0; }
  .logo img { height: 52px; }
  .main-nav {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    background: var(--white); border-bottom: 1px solid var(--border);
    flex-direction: column; padding: 12px 20px; gap: 14px; align-items: flex-start;
  }
  .main-nav.open { display: flex; }
  .detail-layout { grid-template-columns: 1fr; }
  h1 { font-size: 1.8rem; }
  .hero { padding: 56px 0 48px; }
  .hero h1 { font-size: 2rem; }
}