:root {

  --maroon-950: #150705;
  --maroon-900: #1c0906;
  --maroon-800: #2c0f09;
  --maroon-700: #431710;
  --maroon-600: #5c1f15;
  --maroon-500: #7a2c1d;
  --maroon-400: #9c4128;

  --gold-600: #a9824a;
  --gold-500: #c9a15a;
  --gold-400: #dab876;
  --gold-300: #e8cf9c;
  --gold-200: #f2e3c2;

  --cream-50: #faf6f0;
  --cream-100: #f3ebde;

  --ink-900: #17110d;
  --ink-700: #3a2c22;
  --ink-500: #6b5a4c;
  --ink-300: #a89a8c;

  --white: #ffffff;
  --success: #3fae6e;
  --warning: #d99a34;
  --danger: #c94b3f;
  --teal-600: #2b6f77;
  --teal-100: #e2f0ee;

  --bg-body: var(--cream-50);
  --bg-dark: var(--maroon-900);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 24px;
  --radius-pill: 999px;

  --shadow-sm: 0 2px 10px rgba(28, 9, 6, 0.08);
  --shadow-md: 0 10px 30px rgba(28, 9, 6, 0.14);
  --shadow-lg: 0 24px 60px rgba(28, 9, 6, 0.22);
  --shadow-gold: 0 8px 24px rgba(201, 161, 90, 0.35);

  --font-display: "Space Grotesk", "Poppins", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, sans-serif;

  --header-h: 116px;

  --header-h-scrolled: 102px;
  --container-w: 1280px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink-900);
  background: var(--bg-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; font-size: 1rem; min-width: 0; max-width: 100%; }

.header-inner > *, .hero-grid > *, .search-card > *, .type-grid > *,
.property-grid > *, .feature-grid > *, .footer-grid > *, .listing-layout > *,
.detail-layout > *, .spec-grid > *, .amenity-grid > *, .about-grid > *,
.value-grid > *, .contact-layout > *, .form-grid-2 > *, .gallery > * {
  min-width: 0;
}
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  color: var(--maroon-900);
  margin: 0 0 0.5em;
  line-height: 1.15;
  letter-spacing: -0.01em;
}
p { margin: 0 0 1em; }
.container {
  width: 100%;
  max-width: var(--container-w);
  margin: 0 auto;
  padding: 0 24px;
}
section { position: relative; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap;
}

html.is-loading, html.is-loading body { overflow: hidden; height: 100%; }
.page-loader {
  position: fixed; inset: 0; z-index: 9999;
  display: flex; align-items: center; justify-content: center;
  background: var(--maroon-950);
  opacity: 1; visibility: visible;
  transition: opacity .5s ease, visibility .5s ease;
}
.page-loader.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.page-loader-inner { display: flex; flex-direction: column; align-items: center; gap: 28px; }
.page-loader-logo {
  width: 220px; max-width: 55vw; height: auto;
  animation: pageLoaderPulse 1.7s ease-in-out infinite;
}
.page-loader-bar {
  display: block; width: 140px; height: 3px; border-radius: 3px;
  background: rgba(255,255,255,0.14); overflow: hidden; position: relative;
}
.page-loader-bar::after {
  content: ""; position: absolute; top: 0; left: -40%; height: 100%; width: 40%;
  border-radius: 3px; background: linear-gradient(90deg, var(--gold-400), var(--gold-600));
  animation: pageLoaderBar 1.3s ease-in-out infinite;
}
@keyframes pageLoaderPulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.05); opacity: .82; }
}
@keyframes pageLoaderBar {
  0% { left: -40%; }
  100% { left: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .page-loader-logo { animation: none; }
  .page-loader-bar::after { animation: none; left: 0; width: 100%; }
}

.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-display);
  font-size: 0.78rem; font-weight: 600; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--gold-600);
}
.eyebrow::before {
  content: ""; width: 26px; height: 2px; background: var(--gold-500); display: inline-block;
}
.section-head { max-width: 640px; margin-bottom: 48px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head h2 { font-size: clamp(1.8rem, 3vw, 2.6rem); }
.section-head p { color: var(--ink-500); font-size: 1.05rem; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 14px 28px; border-radius: var(--radius-pill);
  font-weight: 600; font-size: 0.95rem; border: 1px solid transparent;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background 0.25s var(--ease), color .25s var(--ease);
  white-space: nowrap;
}
.btn-primary {
  background: linear-gradient(135deg, var(--gold-500), var(--gold-600));
  color: var(--maroon-950); box-shadow: var(--shadow-gold);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 32px rgba(201,161,90,.45); }
.btn-outline {
  background: transparent; border-color: rgba(255,255,255,0.35); color: var(--white);
}
.btn-outline:hover { background: rgba(255,255,255,0.12); }
.btn-dark {
  background: var(--maroon-900); color: var(--white);
}
.btn-dark:hover { background: var(--maroon-800); transform: translateY(-2px); }
.btn-ghost {
  background: rgba(67,23,16,0.06); color: var(--maroon-800);
}
.btn-ghost:hover { background: rgba(67,23,16,0.12); }
.btn-sm { padding: 9px 18px; font-size: 0.85rem; }
.btn-block { width: 100%; }
.btn-whatsapp { background: #25D366; color: #fff; }
.btn-whatsapp:hover { background: #1ebe5a; transform: translateY(-2px); }

.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 500;
  height: var(--header-h);
  display: flex; align-items: center;
  background: rgba(28, 9, 6, 0.35);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  transition: background 0.3s var(--ease), box-shadow 0.3s var(--ease), height .3s var(--ease);
}
.site-header.is-scrolled {
  background: rgba(20, 8, 6, 0.92);
  box-shadow: 0 8px 30px rgba(0,0,0,0.25);
  height: var(--header-h-scrolled);
}

.header-inner {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px;
}
.brand { display: flex; align-items: center; gap: 12px; justify-self: center; }
.brand img { height: 106px; width: auto; transition: height .3s var(--ease); }
.site-header.is-scrolled .brand img { height: 92px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-text strong { font-family: var(--font-display); color: var(--white); font-size: 1.05rem; letter-spacing: 0.01em; }
.brand-text span { font-size: 0.68rem; color: var(--gold-300); text-transform: uppercase; letter-spacing: 0.12em; }

.desktop-nav, .lang-inline { display: none; }

.nav-toggle {
  justify-self: start;
  display: flex; background: rgba(255,255,255,0.08); border: none; color: #fff; cursor: pointer;
  width: 44px; height: 44px; border-radius: 12px; align-items: center; justify-content: center; font-size: 1.2rem;
  transition: background .2s;
}
.nav-toggle:hover { background: rgba(255,255,255,0.16); }

.lang-switcher { position: relative; justify-self: end; }
.lang-toggle {
  display: flex; align-items: center; justify-content: center; gap: 4px; background: rgba(255,255,255,0.08); border: none;
  color: #fff; cursor: pointer; width: 44px; height: 44px; padding: 0; border-radius: var(--radius-pill);
  font-weight: 600; font-size: 0.85rem; letter-spacing: 0.02em; transition: background .2s;
}
.lang-toggle:hover { background: rgba(255,255,255,0.16); }
.lang-toggle .lang-code { min-width: 1.6em; text-align: center; }
.lang-toggle i { font-size: 0.7rem; transition: transform .2s; }
.lang-switcher.open .lang-toggle i,
.lang-menu.open ~ .lang-toggle i { transform: rotate(180deg); }
.lang-menu {
  position: absolute; top: calc(100% + 10px); right: 0; min-width: 170px;
  background: var(--white); border-radius: var(--radius-md); box-shadow: var(--shadow-md);
  padding: 8px; opacity: 0; visibility: hidden; transform: translateY(-8px);
  transition: opacity .2s, transform .2s, visibility .2s; z-index: 600;
}
.lang-menu.open { opacity: 1; visibility: visible; transform: translateY(0); }
.lang-option {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%;
  background: none; border: none; text-align: left; cursor: pointer; font-family: inherit;
  font-size: 0.92rem; font-weight: 500; color: var(--ink-700); padding: 10px 12px; border-radius: var(--radius-sm);
  transition: background .15s;
}
.lang-option:hover { background: var(--maroon-50, rgba(67,23,16,0.06)); }
.lang-option.active { color: var(--maroon-800); font-weight: 700; }
.lang-option i { color: var(--gold-400); font-size: 0.8rem; }

.nav-overlay {
  position: fixed; inset: 0; background: rgba(10,4,3,0.55); z-index: 2999;
  opacity: 0; visibility: hidden; transition: opacity .35s, visibility .35s;
}
.nav-overlay.open { opacity: 1; visibility: visible; }
.main-nav {
  position: fixed; top: 0; right: 0; bottom: 0; width: min(360px, 86vw); z-index: 3000;
  background: rgba(20,8,6,0.98); backdrop-filter: blur(14px);
  display: flex; flex-direction: column; gap: 4px; padding: 100px 28px 32px;
  transform: translateX(100%); transition: transform .35s var(--ease); overflow-y: auto;
}
.main-nav.open { transform: translateX(0); }
.nav-close {
  position: absolute; top: 22px; right: 22px; width: 40px; height: 40px; border-radius: 10px;
  background: rgba(255,255,255,0.08); border: none; color: #fff; font-size: 1.1rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center; transition: background .2s;
}
.nav-close:hover { background: rgba(255,255,255,0.16); }
.main-nav a {
  color: rgba(255,255,255,0.86); font-weight: 500; font-size: 1.05rem;
  padding: 14px 10px; border-radius: var(--radius-sm); position: relative;
  transition: color .2s, background .2s;
}
.main-nav a:hover, .main-nav a.active { color: var(--gold-300); background: rgba(255,255,255,0.06); }
.main-nav .nav-cta { margin-top: auto; text-align: center; }

@media (min-width: 1280px) {
  .nav-toggle, .lang-switcher { display: none; }
  .header-inner {
    display: flex; justify-content: space-between; align-items: center; position: relative;
  }
  .desktop-nav, .lang-inline { display: flex; align-items: center; }
  .desktop-nav { gap: 13px; }
  .desktop-nav a {
    color: rgba(255,255,255,0.82); font-size: 0.72rem; font-weight: 600;
    text-transform: uppercase; letter-spacing: 0.04em; padding: 6px 2px; position: relative;
    white-space: nowrap; transition: color .2s;
  }
  .desktop-nav a::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 2px;
    background: var(--gold-300); transform: scaleX(0); transform-origin: center;
    transition: transform .2s var(--ease);
  }
  .desktop-nav a:hover, .desktop-nav a.active { color: var(--white); }
  .desktop-nav a:hover::after, .desktop-nav a.active::after { transform: scaleX(1); }

  .brand { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); }

  .lang-inline { gap: 8px; }
  .lang-inline-option {
    color: rgba(255,255,255,0.7); font-size: 0.82rem; font-weight: 600; letter-spacing: 0.03em;
    transition: color .2s;
  }
  .lang-inline-option:hover { color: var(--white); }
  .lang-inline-option.active { color: var(--gold-300); }
  .lang-sep { color: rgba(255,255,255,0.35); font-size: 0.8rem; }
}

.hero {
  position: relative; min-height: 100vh; display: flex; align-items: center;
  background: var(--maroon-950);
  color: var(--white); overflow: hidden; padding-top: var(--header-h);

  padding-bottom: 64px;
}

.hero-bg {
  position: absolute; inset: 0; z-index: 0;
  background-image:
    linear-gradient(120deg, rgba(21,7,5,0.92) 0%, rgba(28,9,6,0.82) 42%, rgba(44,15,9,0.58) 72%, rgba(21,7,5,0.88) 100%),
    url('../img/hero-bg-algarrobo.webp');
  background-size: cover, cover;
  background-position: center, center;
  animation: hero-pan 26s ease-in-out infinite alternate;
  will-change: transform;
}
@keyframes hero-pan {
  from { transform: scale(1.06) translate3d(0, 0, 0); }
  to   { transform: scale(1.16) translate3d(-1.4%, -1%, 0); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-bg { animation: none; }
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background-image: linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
                     linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(to bottom, black, transparent 85%);
}
.hero::after {
  content: ""; position: absolute; width: 900px; height: 900px; border-radius: 50%;
  right: -280px; top: -280px; z-index: 1;
  background: radial-gradient(circle, rgba(201,161,90,0.35), transparent 70%);
  filter: blur(10px);
  animation: float-glow 12s ease-in-out infinite alternate;
}
@keyframes float-glow {
  from { transform: translate(0,0) scale(1); }
  to { transform: translate(-40px, 40px) scale(1.08); }
}
.hero-grid {
  position: relative; z-index: 2; display: grid; grid-template-columns: 1.1fr 0.9fr;
  gap: 48px; align-items: center; width: 100%;
}
.hero-copy .eyebrow { color: var(--gold-300); }
.hero-copy .eyebrow::before { background: var(--gold-300); }
.hero-copy h1 {
  color: var(--white); font-size: clamp(2.4rem, 5vw, 4rem); margin: 14px 0 20px;
}
.hero-copy h1 em { font-style: normal; color: var(--gold-400); }
.hero-copy p { color: rgba(255,255,255,0.78); font-size: 1.15rem; max-width: 520px; }
.hero-cta { display: flex; gap: 16px; margin: 28px 0 40px; flex-wrap: wrap; }

.hero-stats { display: flex; flex-wrap: nowrap; gap: clamp(20px, 3vw, 36px); }
.hero-stats .stat { min-width: 0; }
.hero-stats .stat strong {
  display: block; font-family: var(--font-display); font-size: 2rem; color: var(--gold-300);
}
.hero-stats .stat span { font-size: 0.82rem; color: rgba(255,255,255,0.65); text-transform: uppercase; letter-spacing: 0.08em; }

.hero-scroll-cue {

  position: absolute; left: 50%; bottom: 96px; z-index: 2; transform: translateX(-50%);
  width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,0.75); border: 1px solid rgba(255,255,255,0.3);
  animation: scroll-cue-bounce 2.2s ease-in-out infinite;
}
.hero-scroll-cue:hover { color: var(--gold-300); border-color: var(--gold-300); }
@keyframes scroll-cue-bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-scroll-cue { animation: none; }
}

@media (max-width: 1100px) {
  .hero-scroll-cue { display: none; }
}

.hero-visual { position: relative; animation: hero-float 6s ease-in-out infinite; }
.hero-card {
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.14);
  backdrop-filter: blur(18px); border-radius: var(--radius-lg); padding: 10px;
  box-shadow: var(--shadow-lg); transform: rotate(1.5deg);
}
.hero-card img { border-radius: 18px; width: 100%; aspect-ratio: 4/3.1; object-fit: cover; }

@keyframes hero-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-visual { animation: none; }
}
.hero-badge {
  position: absolute; bottom: -26px; left: -26px; background: var(--white);
  color: var(--maroon-900); border-radius: var(--radius-md); padding: 16px 20px;
  box-shadow: var(--shadow-lg); display: flex; align-items: center; gap: 14px;
  max-width: 260px;
}
.hero-badge .icon {
  width: 46px; height: 46px; border-radius: 12px; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--gold-400), var(--gold-600)); color: var(--maroon-950); font-size: 1.2rem; flex-shrink: 0;
}
.hero-badge strong { display: block; font-family: var(--font-display); font-size: 1.05rem; }
.hero-badge span { font-size: 0.8rem; color: var(--ink-500); }

.search-panel {
  position: relative; z-index: 3; margin-top: -64px;
}
.search-card {
  background: var(--white); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
  padding: 22px; display: grid; grid-template-columns: repeat(5, 1fr) auto; gap: 14px; align-items: end;
  border: 1px solid rgba(67,23,16,0.06);
}
.search-tabs { display: flex; gap: 8px; margin-bottom: 16px; }
.search-tab {
  padding: 8px 18px; border-radius: var(--radius-pill); background: rgba(67,23,16,0.05);
  font-weight: 600; font-size: 0.88rem; color: var(--ink-500); border: none;
}
.search-tab.active { background: var(--maroon-900); color: var(--white); }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field label { font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink-500); font-weight: 600; }
.field select, .field input {
  border: 1px solid rgba(67,23,16,0.14); border-radius: var(--radius-sm);
  padding: 12px 14px; background: var(--cream-50); color: var(--ink-900);
  width: 100%; min-width: 0;
}
.field select:focus, .field input:focus { outline: 2px solid var(--gold-500); outline-offset: 1px; }
.search-card .btn-primary { padding: 14px 22px; }

.search-general-row { display: flex; gap: 12px; align-items: flex-end; }
.search-general-row .field { flex: 1; }
.search-general-row .btn-primary { flex-shrink: 0; }

.search-advanced-toggle {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 10px;
  background: none; border: none; padding: 14px 0 0; margin: 4px 0 0; text-align: left;
  font-family: inherit; color: var(--ink-500); font-size: 0.86rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.04em; cursor: pointer;
  border-top: 1px dashed rgba(67,23,16,0.14);
}
.search-advanced-toggle:hover { color: var(--maroon-900); }
.search-advanced-toggle span { display: flex; align-items: center; gap: 8px; }
.search-advanced-icon { font-size: 0.8rem; transition: transform 0.25s ease; }
.search-card.search-advanced-open .search-advanced-icon { transform: rotate(180deg); }

.search-advanced-panel { overflow: hidden; max-height: 0; transition: max-height 0.3s ease; }
.search-advanced-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; padding-top: 16px; }

.type-grid {
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 18px;
}
.type-card {
  background: var(--white); border-radius: var(--radius-md); padding: 26px 18px;
  text-align: center; box-shadow: var(--shadow-sm); border: 1px solid rgba(67,23,16,0.06);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .25s;
}
.type-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: var(--gold-400); }
.type-card .icon-wrap {
  width: 58px; height: 58px; margin: 0 auto 14px; border-radius: 16px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--maroon-700), var(--maroon-900)); color: var(--gold-300); font-size: 1.4rem;
}
.type-card strong { display: block; font-family: var(--font-display); font-size: 0.95rem; color: var(--maroon-900); }
.type-card span { font-size: 0.78rem; color: var(--ink-500); }

.section-alt { background: var(--maroon-950); color: var(--white); padding: 96px 0; }
.section-alt .section-head h2 { color: var(--white); }
.section-alt .section-head p { color: rgba(255,255,255,0.68); }
.section { padding: 96px 0; }

.property-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.property-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }

.property-card {
  background: var(--white); border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow-sm); border: 1px solid rgba(67,23,16,0.06);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
  display: flex; flex-direction: column; height: 100%;
}
.property-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-lg); }
.property-card .thumb { position: relative; aspect-ratio: 4/3; overflow: hidden; background: var(--maroon-900); }
.property-card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.property-card:hover .thumb img { transform: scale(1.08); }
.thumb-tags { position: absolute; top: 14px; left: 14px; display: flex; gap: 8px; }
.thumb-fav { position: absolute; top: 14px; right: 14px; }

.reserved-ribbon {
  position: absolute; top: 30px; right: -48px;
  width: 190px; transform: rotate(45deg); text-align: center;
  background: var(--maroon-900); color: var(--gold-300);
  padding: 7px 0; font-size: 0.74rem; font-weight: 800;
  letter-spacing: 0.06em; text-transform: uppercase;
  box-shadow: 0 4px 14px rgba(0,0,0,0.3);
}

.badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px;
  border-radius: var(--radius-pill); font-size: 0.72rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.04em;
}
.badge-venta { background: var(--maroon-900); color: var(--gold-300); }
.badge-arriendo { background: var(--gold-500); color: var(--maroon-950); }
.badge-traspaso { background: var(--teal-600); color: var(--teal-100); }
.badge-featured { background: var(--white); color: var(--maroon-900); }
.badge-success { background: rgba(63,174,110,0.15); color: #2c8055; }
.badge-warning { background: rgba(217,154,52,0.16); color: #a06f1c; }
.badge-danger { background: rgba(201,75,63,0.15); color: #a3382d; }
.badge-neutral { background: rgba(107,90,76,0.14); color: var(--ink-500); }

.property-card .body { padding: 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.property-card .price { font-family: var(--font-display); font-size: 1.4rem; color: var(--maroon-900); }
.property-card .price small { font-size: 0.7rem; color: var(--ink-500); font-weight: 500; margin-left: 6px; }

.property-card h3 { font-size: 1.08rem; margin: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.property-card h3 .ref-badge { font-size: 0.62rem; padding: 3px 9px; font-weight: 700; }
.property-card .location { display: flex; align-items: center; gap: 6px; font-size: 0.86rem; color: var(--ink-500); }
.property-card .location i { color: var(--gold-600); }
.property-specs { display: flex; gap: 16px; padding-top: 10px; border-top: 1px dashed rgba(67,23,16,0.14); margin-top: auto; }
.property-specs span { display: flex; align-items: center; gap: 6px; font-size: 0.82rem; color: var(--ink-700); }
.property-specs i { color: var(--gold-600); }

.feature-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px; }
.feature-card {
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--radius-md); padding: 28px; backdrop-filter: blur(6px);
}
.feature-card .icon-wrap {
  width: 52px; height: 52px; border-radius: 14px; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--gold-400), var(--gold-600)); color: var(--maroon-950); font-size: 1.25rem; margin-bottom: 16px;
}
.feature-card h3 { color: var(--white); font-size: 1.05rem; }
.feature-card p { color: rgba(255,255,255,0.65); font-size: 0.92rem; margin: 0; }

.cta-band {
  background: linear-gradient(120deg, var(--maroon-700), var(--maroon-900));
  border-radius: var(--radius-lg); padding: 60px; color: var(--white);
  display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap;
  position: relative; overflow: hidden;
}
.cta-band::after {
  content: ""; position: absolute; right: -60px; top: -60px; width: 260px; height: 260px; border-radius: 50%;
  background: radial-gradient(circle, rgba(201,161,90,0.4), transparent 70%);
}
.cta-band h2 { color: var(--white); font-size: 1.8rem; max-width: 480px; margin: 0 0 8px; }
.cta-band p { color: rgba(255,255,255,0.7); margin: 0; max-width: 460px; }
.cta-actions { display: flex; gap: 14px; position: relative; z-index: 1; }

.site-footer { background: var(--maroon-950); color: rgba(255,255,255,0.7); padding: 70px 0 0; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 40px; padding-bottom: 50px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.footer-brand img { height: 44px; margin-bottom: 16px; }
.footer-brand p { font-size: 0.9rem; color: rgba(255,255,255,0.55); max-width: 280px; }
.social-row { display: flex; gap: 10px; margin-top: 16px; }
.social-row a {
  width: 38px; height: 38px; border-radius: 50%; background: rgba(255,255,255,0.08);
  display: flex; align-items: center; justify-content: center; transition: background .2s;
}
.social-row a:hover { background: var(--gold-500); color: var(--maroon-950); }
.footer-col h4 { color: var(--white); font-size: 0.95rem; margin-bottom: 18px; }
.footer-col ul li { margin-bottom: 10px; }
.footer-col a { font-size: 0.9rem; color: rgba(255,255,255,0.6); transition: color .2s; }
.footer-col a:hover { color: var(--gold-300); }
.footer-col .contact-item { display: flex; gap: 10px; align-items: flex-start; font-size: 0.9rem; margin-bottom: 14px; min-width: 0; }
.footer-col .contact-item span { overflow-wrap: anywhere; }
.footer-col .contact-item i { color: var(--gold-400); margin-top: 3px; }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center; padding: 22px 0; font-size: 0.82rem;
  color: rgba(255,255,255,0.45); flex-wrap: wrap; gap: 10px;
}
.footer-bottom a { color: rgba(255,255,255,0.6); }

.whatsapp-float {
  position: fixed; right: 26px; bottom: 26px; z-index: 900;
  display: flex; align-items: center; gap: 12px;
}
.whatsapp-bubble {
  background: var(--white); color: var(--ink-900); padding: 10px 16px; border-radius: var(--radius-pill);
  box-shadow: var(--shadow-md); font-size: 0.85rem; font-weight: 600;
  opacity: 0; transform: translateX(10px); transition: all .3s var(--ease); pointer-events: none;
  white-space: nowrap;
}
.whatsapp-float:hover .whatsapp-bubble, .whatsapp-float.show-bubble .whatsapp-bubble {
  opacity: 1; transform: translateX(0);
}
.whatsapp-btn {
  width: 62px; height: 62px; border-radius: 50%; background: #25D366; color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 1.7rem;
  box-shadow: 0 10px 30px rgba(37,211,102,0.45); position: relative;
  animation: wa-pulse 2.6s infinite;
}
@keyframes wa-pulse {
  0% { box-shadow: 0 0 0 0 rgba(37,211,102,0.55); }
  70% { box-shadow: 0 0 0 16px rgba(37,211,102,0); }
  100% { box-shadow: 0 0 0 0 rgba(37,211,102,0); }
}
.whatsapp-close {
  position: absolute; top: -6px; right: -6px; background: var(--maroon-900); color: #fff;
  width: 20px; height: 20px; border-radius: 50%; font-size: 0.65rem; display: none;
  align-items: center; justify-content: center; border: none;
}

.whatsapp-menu {
  position: absolute; right: 0; bottom: calc(100% + 14px);
  background: var(--white); border-radius: var(--radius-md); box-shadow: var(--shadow-md);
  padding: 8px; min-width: 190px; display: flex; flex-direction: column; gap: 2px;
  opacity: 0; visibility: hidden; transform: translateY(8px); transition: all .2s var(--ease);
}
.whatsapp-menu.open { opacity: 1; visibility: visible; transform: translateY(0); }
.whatsapp-menu-option {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--radius-sm);
  color: var(--ink-900); font-size: 0.9rem; font-weight: 600; white-space: nowrap;
}
.whatsapp-menu-option:hover { background: var(--maroon-50, rgba(67,23,16,0.06)); }
.whatsapp-menu-flag { font-size: 1.15rem; line-height: 1; }

.cookie-banner {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 950;
  background: var(--maroon-950); box-shadow: 0 -10px 30px rgba(0,0,0,0.25);
  transform: translateY(100%); transition: transform .4s var(--ease);
}
.cookie-banner.is-visible { transform: translateY(0); }
.cookie-banner-inner {
  max-width: var(--container-w); margin: 0 auto; padding: 22px 24px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
}
.cookie-banner p { margin: 0; font-size: 0.9rem; color: rgba(255,255,255,0.82); max-width: 640px; }

.cookie-banner p a { color: var(--gold-400); }
.cookie-banner-actions { display: flex; gap: 12px; flex-shrink: 0; flex-wrap: wrap; }
body.has-cookie-banner .whatsapp-float { display: none; }
@media (max-width: 640px) {
  .cookie-banner-inner { padding: 18px; }
  .cookie-banner-actions { width: 100%; }
  .cookie-banner-actions .btn { flex: 1; }
}

.page-hero {

  padding: calc(var(--header-h) + 42px) 0 60px;
  background: radial-gradient(ellipse at 20% 0%, var(--maroon-600), var(--maroon-950) 65%);
  color: var(--white);
}
.page-hero h1 { color: var(--white); font-size: clamp(2rem, 4vw, 2.8rem); }

.page-hero-compact { padding: calc(var(--header-h) + 22px) 0 22px; }

.page-hero-compact .breadcrumb { margin-bottom: 0; }
.section-property-detail { padding-top: 30px; }
.breadcrumb { display: flex; gap: 8px; align-items: center; font-size: 0.86rem; color: rgba(255,255,255,0.6); margin-bottom: 42px; }
.breadcrumb a:hover { color: var(--gold-300); }

.listing-layout { display: grid; grid-template-columns: 300px 1fr; gap: 34px; align-items: start; }
.filters-card {
  background: var(--white); border-radius: var(--radius-lg); padding: 26px;
  box-shadow: var(--shadow-sm); border: 1px solid rgba(67,23,16,0.06); position: sticky; top: calc(var(--header-h) + 20px);

}
.filters-card h3 { font-size: 1.05rem; display: flex; align-items: center; gap: 8px; }
.filters-toggle {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 10px;
  background: none; border: none; padding: 0; margin: 0 0 0.5em; text-align: left;
  font-family: var(--font-display); color: var(--maroon-900); font-size: 1.05rem; font-weight: 700;
  line-height: 1.15; letter-spacing: -0.01em;
}
.filters-toggle span { display: flex; align-items: center; gap: 8px; }
.filters-toggle-icon { display: none; font-size: 0.85rem; color: var(--ink-500); transition: transform 0.25s ease; flex-shrink: 0; }
.filter-group { margin-bottom: 20px; }
.filter-group label { display: block; font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--ink-500); font-weight: 700; margin-bottom: 8px; }
.filter-group select, .filter-group input {
  width: 100%; border: 1px solid rgba(67,23,16,0.14); border-radius: var(--radius-sm); padding: 11px 13px; background: var(--cream-50);
}
.filter-range { display: flex; gap: 10px; }
.chip-group { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  padding: 8px 14px; border-radius: var(--radius-pill); background: rgba(67,23,16,0.05); font-size: 0.82rem;
  border: 1px solid transparent; color: var(--ink-700); font-weight: 600;
  appearance: none; -webkit-appearance: none; display: inline-block; line-height: 1.2; text-decoration: none; font-family: inherit;
}
.chip.active { background: var(--maroon-900); color: var(--white); }

.listing-toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; flex-wrap: wrap; gap: 14px; }
.listing-toolbar .count { color: var(--ink-500); font-size: 0.92rem; }
.listing-toolbar select { border: 1px solid rgba(67,23,16,0.14); border-radius: var(--radius-sm); padding: 10px 14px; background: var(--white); }

.pagination { display: flex; justify-content: center; gap: 8px; margin-top: 48px; }
.pagination a, .pagination span {
  width: 42px; height: 42px; border-radius: 12px; display: flex; align-items: center; justify-content: center;
  background: var(--white); border: 1px solid rgba(67,23,16,0.12); font-weight: 600; color: var(--ink-700);
}
.pagination a:hover { border-color: var(--gold-500); color: var(--maroon-900); }
.pagination .active { background: var(--maroon-900); color: var(--white); border-color: var(--maroon-900); }

.empty-state { text-align: center; padding: 80px 20px; color: var(--ink-500); }
.empty-state i { font-size: 2.6rem; color: var(--gold-500); margin-bottom: 16px; }

.gallery {
  display: flex; gap: 12px;
  width: 100%;
  aspect-ratio: var(--gallery-ratio, 2.4) / 1;
  max-height: 76vh;
  border-radius: var(--radius-lg); overflow: hidden;
}
.gallery .main-shot { position: relative; flex: 67 0 0; overflow: hidden; cursor: zoom-in; }
.gallery .main-shot img { width: 100%; height: 100%; object-fit: cover; display: block; }

.gallery .gallery-hint {
  position: absolute; right: 14px; bottom: 14px; z-index: 2;
  display: flex; align-items: center; gap: 8px;
  background: rgba(21,7,5,0.7); color: var(--white);
  padding: 8px 16px; border-radius: 999px;
  font-size: 0.82rem; font-weight: 600;
  backdrop-filter: blur(2px);
  pointer-events: none;
}
.gallery .side-shots { flex: 33 0 0; display: flex; flex-direction: column; gap: 12px; }
.gallery .side-shots > div { position: relative; overflow: hidden; cursor: zoom-in; flex: 1 1 0; }

.gallery .side-shots img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery .more-overlay {
  position: absolute; inset: 0; background: rgba(28,9,6,0.6); color: #fff;
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 1.1rem;
}

.detail-layout { display: grid; grid-template-columns: 1fr 380px; gap: 40px; margin-top: 22px; align-items: start; }
.detail-main { min-width: 0; }
.detail-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; flex-wrap: wrap; margin-bottom: 24px; }

.detail-head-info {
  min-width: 0; display: grid; grid-template-columns: 1fr auto;
  column-gap: 12px; row-gap: 12px;
  grid-template-areas: "badges share" "title title" "location location";
}
.detail-badges { grid-area: badges; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.detail-head h1 { grid-area: title; font-size: clamp(1.6rem, 3vw, 2.2rem); line-height: 1.28; }
.detail-price { font-family: var(--font-display); font-size: 2rem; color: var(--maroon-900); white-space: nowrap; }
.detail-location { grid-area: location; color: var(--ink-500); display: flex; align-items: center; gap: 8px; margin-bottom: 0; }

@media (min-width: 641px) {

  .detail-head-info { grid-template-areas: "badges badges" "title share" "location location"; }
}

.share-wrap { grid-area: share; position: relative; align-self: center; justify-self: end; }
@media (min-width: 641px) {
  .share-wrap { align-self: start; margin-top: 4px; }
}
.share-btn {
  width: 40px; height: 40px; border-radius: 50%; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(67,23,16,0.06); border: 1px solid rgba(67,23,16,0.14);
  color: var(--maroon-800); font-size: 1rem; cursor: pointer; padding: 0;
  transition: background .2s, color .2s, transform .2s;
}
.share-btn:hover, .share-btn:focus-visible { background: var(--gold-500); color: var(--maroon-950); transform: translateY(-1px); }
.share-btn-tooltip {
  position: absolute; top: calc(100% + 8px); right: 0; z-index: 2;
  background: var(--maroon-950); color: var(--white); font-size: 0.78rem;
  padding: 6px 12px; border-radius: 999px; white-space: nowrap;
  opacity: 0; transform: translateY(-4px); pointer-events: none;
  transition: opacity .2s, transform .2s;
}
.share-btn-tooltip.is-visible { opacity: 1; transform: translateY(0); }

.spec-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin: 30px 0; }
.spec-item {
  background: var(--white); border: 1px solid rgba(67,23,16,0.08); border-radius: var(--radius-md);
  padding: 18px; text-align: center; min-width: 0;
}
.spec-item i { font-size: 1.3rem; color: var(--gold-600); margin-bottom: 8px; display: block; }
.spec-item strong { display: block; font-family: var(--font-display); font-size: 1.15rem; }
.spec-item span { font-size: 0.78rem; color: var(--ink-500); }

.detail-section { margin: 40px 0; }

.detail-main > .detail-section:first-child { margin-top: 20px; }
.detail-section h2 { font-size: 1.3rem; }
.amenity-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.amenity-item { display: flex; align-items: center; gap: 10px; font-size: 0.92rem; color: var(--ink-700); }
.amenity-item i { color: var(--gold-600); width: 22px; text-align: center; }

.map-frame { border-radius: var(--radius-md); overflow: hidden; border: 1px solid rgba(67,23,16,0.1); height: 320px; }
.map-frame iframe { width: 100%; height: 100%; border: 0; }

.sidebar-card {
  background: var(--white); border-radius: var(--radius-lg); padding: 26px; box-shadow: var(--shadow-md);
  border: 1px solid rgba(67,23,16,0.06); position: sticky; top: calc(var(--header-h) + 20px);
}
.agent-mini { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; padding-bottom: 20px; border-bottom: 1px solid rgba(67,23,16,0.1); }
.agent-mini .avatar {
  width: 54px; height: 54px; border-radius: 50%; background: linear-gradient(135deg, var(--maroon-700), var(--maroon-900));
  display: flex; align-items: center; justify-content: center; color: var(--gold-300); font-size: 1.3rem; flex-shrink: 0;
}
.agent-mini strong { display: block; }
.agent-mini span { font-size: 0.82rem; color: var(--ink-500); }
.sidebar-card .btn { margin-bottom: 10px; }

.contact-form .field { margin-bottom: 14px; }
.contact-form textarea { min-height: 100px; resize: vertical; width: 100%; border: 1px solid rgba(67,23,16,0.14); border-radius: var(--radius-sm); padding: 12px 14px; background: var(--cream-50); }
.contact-form label { font-size: 0.78rem; text-transform: uppercase; color: var(--ink-500); font-weight: 700; letter-spacing: .04em; display:block; margin-bottom:6px;}
.contact-form input { width: 100%; }
.form-note { font-size: 0.76rem; color: var(--ink-300); margin-top: 10px; }

.related-props { margin-top: 60px; }

.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.about-visual { position: relative; }
.about-visual img { border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); }
.stat-float {
  position: absolute; bottom: -24px; right: -24px; background: var(--maroon-900); color: var(--white);
  border-radius: var(--radius-md); padding: 20px 26px; box-shadow: var(--shadow-lg);
}
.stat-float strong { display: block; font-family: var(--font-display); font-size: 1.8rem; color: var(--gold-300); }
.stat-float span { font-size: 0.78rem; color: rgba(255,255,255,0.7); }

.value-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 40px; }
.value-card { text-align: center; padding: 10px; }
.value-card .icon-wrap {
  width: 60px; height: 60px; margin: 0 auto 16px; border-radius: 50%;
  background: linear-gradient(135deg, var(--gold-400), var(--gold-600)); display: flex; align-items: center; justify-content: center; color: var(--maroon-950); font-size: 1.4rem;
}
.value-card h3 { color: var(--white); margin: 0 0 8px; }

.legal-content h2 { font-size: 1.25rem; margin: 1.6em 0 0.6em; }
.legal-content h2:first-of-type { margin-top: 0.6em; }
.legal-content p { color: var(--ink-700); line-height: 1.7; }
.legal-content ul { list-style: disc; padding-left: 1.4em; margin: 0 0 1em; }
.legal-content li { margin-bottom: 0.4em; line-height: 1.6; }
.legal-content table { font-size: 0.92rem; }

.contact-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; }
.contact-info-card, .contact-form-card { min-width: 0; }
.contact-info-card {
  background: var(--maroon-950); color: var(--white); border-radius: var(--radius-lg); padding: 40px;
}
.contact-info-card h3 { color: var(--white); }
.contact-info-item { display: flex; gap: 16px; padding: 18px 0; border-bottom: 1px solid rgba(255,255,255,0.08); min-width: 0; }
.contact-info-item > div { min-width: 0; overflow-wrap: anywhere; }
.contact-info-item .icon-wrap {
  width: 44px; height: 44px; border-radius: 12px; background: rgba(201,161,90,0.15); color: var(--gold-400);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.contact-form-card {
  background: var(--white); border-radius: var(--radius-lg); padding: 40px; box-shadow: var(--shadow-md);
  border: 1px solid rgba(67,23,16,0.06);
}
.form-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.alert { padding: 14px 18px; border-radius: var(--radius-sm); font-size: 0.92rem; margin-bottom: 18px; display:flex; gap:10px; align-items:flex-start; }
.alert-success { background: rgba(63,174,110,0.12); color: #2c8055; border: 1px solid rgba(63,174,110,0.3); }
.alert-error { background: rgba(201,75,63,0.12); color: #a3382d; border: 1px solid rgba(201,75,63,0.3); }

.reveal { opacity: 1; transform: none; }
.js .reveal {
  opacity: 0; transform: translateY(28px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
}
.js .reveal.in-view { opacity: 1; transform: translateY(0); }
.reveal-delay-1 { transition-delay: .08s; }
.reveal-delay-2 { transition-delay: .16s; }
.reveal-delay-3 { transition-delay: .24s; }
.reveal-delay-4 { transition-delay: .32s; }

.lightbox {
  position: fixed; inset: 0; background: rgba(10,4,3,0.94); z-index: 2000;
  display: none; align-items: center; justify-content: center; padding: 40px;
}
.lightbox.open { display: flex; }
.lightbox img { max-width: 92vw; max-height: 84vh; border-radius: 12px; }
.lightbox-close, .lightbox-prev, .lightbox-next {
  position: absolute; background: rgba(255,255,255,0.1); color: #fff; border: none;
  width: 48px; height: 48px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.2rem;
}
.lightbox-close { top: 24px; right: 24px; }
.lightbox-prev { left: 24px; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 24px; top: 50%; transform: translateY(-50%); }
.lightbox-counter { position: absolute; bottom: 24px; left: 50%; transform: translateX(-50%); color: rgba(255,255,255,0.7); font-size: 0.85rem; }

@media (min-width: 1101px) {
  .filters-panel { max-height: none !important; overflow: visible !important; }

  .filters-card { max-height: calc(100vh - var(--header-h-scrolled) - 40px); overflow-y: auto; }
}

@media (min-width: 1101px) and (max-height: 860px) {
  .filters-card { padding: 18px 22px; }
  .filters-card h3, .filters-toggle { font-size: 0.95rem; }
  .filter-group { margin-bottom: 11px; }
  .filter-group label { font-size: 0.72rem; margin-bottom: 4px; }
  .filter-group select, .filter-group input { padding: 8px 11px; }
  .chip-group { gap: 6px; }
  .chip { padding: 6px 11px; font-size: 0.78rem; }
  .filters-card .btn { padding: 10px 20px; font-size: 0.88rem; }
  .filters-card .btn-ghost.btn-block { margin-top: 6px !important; }
}

@media (min-width: 1101px) and (max-height: 700px) {
  .filters-card { padding: 14px 18px; }
  .filters-card h3, .filters-toggle { font-size: 0.88rem; }
  .filter-group { margin-bottom: 7px; }
  .filter-group label { font-size: 0.68rem; margin-bottom: 2px; }
  .filter-group select, .filter-group input { padding: 6px 10px; }
  .chip-group { gap: 4px; }
  .chip { padding: 5px 10px; font-size: 0.74rem; }
  .filters-card .btn { padding: 8px 18px; font-size: 0.84rem; }
  .filters-card .btn-ghost.btn-block { margin-top: 4px !important; }
}

@media (max-width: 1100px) {

  .hero { min-height: auto; padding-top: calc(var(--header-h) + 60px); padding-bottom: 130px; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { display: none; }
  .search-panel { margin-top: -70px; }
  .search-card { grid-template-columns: repeat(3, 1fr); }
  .search-advanced-grid { grid-template-columns: repeat(2, 1fr); }
  .property-grid { grid-template-columns: repeat(2, 1fr); }
  .type-grid { grid-template-columns: repeat(3, 1fr); }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .listing-layout { grid-template-columns: 1fr; }
  .filters-card { position: static; }

  .filters-toggle { cursor: pointer; margin-bottom: 0; }
  .filters-toggle-icon { display: block; }
  .filters-panel { overflow: hidden; max-height: 0; transition: max-height 0.3s ease; }
  .filters-card.filters-open .filters-toggle { margin-bottom: 0.9em; }
  .filters-card.filters-open .filters-toggle-icon { transform: rotate(180deg); }
  .detail-layout { grid-template-columns: 1fr; }
  .sidebar-card { position: static; }
  .about-grid { grid-template-columns: 1fr; }
  .contact-layout { grid-template-columns: 1fr; }
  .value-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 860px) {
  .main-nav { width: min(320px, 88vw); padding-top: 90px; }

  .hero { padding-top: calc(var(--header-h) + 42px); padding-bottom: 90px; }

  .hero-bg {
    background-image:
      linear-gradient(120deg, rgba(21,7,5,0.92) 0%, rgba(28,9,6,0.82) 42%, rgba(44,15,9,0.58) 72%, rgba(21,7,5,0.88) 100%),
      url('../img/hero-bg-algarrobo-mobile.webp');
  }
  .search-panel { margin-top: -48px; }
  .search-card { grid-template-columns: 1fr 1fr; }
  .search-advanced-grid { grid-template-columns: 1fr 1fr; }

  .gallery { flex-direction: column; aspect-ratio: unset; max-height: none; gap: 12px; }
  .gallery .main-shot {
    flex: 0 0 auto;
    width: 100%;
    aspect-ratio: var(--main-ratio, 1.4);
    max-height: 50vh;
  }
  .gallery .main-shot img { width: 100%; height: 100%; object-fit: cover; display: block; }
  .gallery .side-shots {
    flex: 0 0 auto;
    align-self: stretch;
    flex-direction: row;
    aspect-ratio: var(--side-ratio, 1.6) / 1;
  }
  .gallery .side-shots > div { flex: var(--ratio, 1) 1 0; }
  .cta-band { flex-direction: column; text-align: center; padding: 40px 26px; }
  .cta-actions { justify-content: center; flex-wrap: wrap; }
}

@media (max-width: 640px) {
  .container { padding: 0 18px; }
  .property-grid, .property-grid.cols-2 { grid-template-columns: 1fr; }
  .type-grid { grid-template-columns: repeat(2, 1fr); }
  .feature-grid { grid-template-columns: 1fr; }
  .value-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 30px; }
  .search-panel { margin-top: -30px; }
  .search-card { grid-template-columns: 1fr; padding: 18px; }
  .search-advanced-grid { grid-template-columns: 1fr; }

  .search-general-row { flex-direction: column; align-items: stretch; }
  .search-general-row .btn-primary { width: 100%; justify-content: center; }
  .spec-grid { grid-template-columns: repeat(2, 1fr); }
  .amenity-grid { grid-template-columns: 1fr 1fr; }

  .detail-head { flex-direction: column; align-items: stretch; gap: 16px; margin-bottom: 20px; }
  .detail-price { align-self: flex-end; }
  .gallery .gallery-hint { padding: 6px 12px; font-size: 0.74rem; right: 10px; bottom: 10px; gap: 6px; }

  .detail-head h1 { margin-top: 12px; margin-bottom: 10px; }

  .page-hero-compact { padding: calc(var(--header-h) + 10px) 0 7px; }
  .page-hero-compact .breadcrumb { margin-bottom: 0; font-size: 0.78rem; }
  .form-grid-2 { grid-template-columns: 1fr; }
  .hero { min-height: auto; padding-top: calc(var(--header-h) + 30px); padding-bottom: 60px; }

  .hero-stats { flex-direction: column; align-items: flex-start; gap: 18px; }
  .whatsapp-float { right: 16px; bottom: 16px; }
  .whatsapp-btn { width: 56px; height: 56px; font-size: 1.5rem; }
  .whatsapp-bubble { display: none; }
  section, .section, .section-alt { padding: 64px 0; }

  .section-property-detail { padding-top: 32px; }
  .stat-float { right: 0; bottom: -16px; padding: 14px 18px; }
  .brand img { height: 56px; }
  .site-header.is-scrolled .brand img { height: 50px; }
}

@media (max-width: 400px) {
  .brand img { height: 43px; }
  .site-header.is-scrolled .brand img { height: 38px; }
}

@media (max-width: 359px) {
  .brand img { height: 37px; }
  .site-header.is-scrolled .brand img { height: 32px; }
}
