/* =============================================================
   1. Tokens
   ============================================================= */
:root {
  --bg:        #f6f1e8;
  --bg-2:      #ece3d3;
  --paper:     #ffffff;
  --ink:       #1c1a17;
  --ink-soft:  #2c2925;
  --ink-mute:  #6f665a;
  --accent:    #2f4a3e;
  --accent-2:  #a8763e;
  --cream:     #f6f1e8;
  --line:      rgba(28,26,23,0.12);
  --line-soft: rgba(28,26,23,0.07);

  --serif: "Cormorant Garamond", "Times New Roman", serif;
  --sans:  "Manrope", "Segoe UI", sans-serif;
  --mono:  "IBM Plex Mono", "Courier New", monospace;

  --ease-out:  cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in:   cubic-bezier(0.7, 0, 0.84, 0);
  --ease-soft: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);

  --gutter: clamp(1.25rem, 4vw, 3rem);
  --radius: 4px;
}

@property --mesh-angle { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
@property --mesh-x     { syntax: "<percentage>"; inherits: false; initial-value: 30%; }
@property --mesh-y     { syntax: "<percentage>"; inherits: false; initial-value: 40%; }

/* =============================================================
   2. Reset & base
   ============================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; }
html {
  -webkit-text-size-adjust: 100%;
  tab-size: 2;
  scroll-behavior: smooth;
  overflow-x: clip;
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  overscroll-behavior-y: none;
}
img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
a { color: inherit; text-decoration: none; }
p { text-wrap: pretty; }
h1, h2, h3, h4 { text-wrap: balance; line-height: 1.05; letter-spacing: -0.01em; font-family: var(--serif); font-weight: 500; }
ul { list-style: none; padding: 0; }
::selection { background: var(--accent); color: var(--cream); }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: fixed; top: -100px; left: 1rem;
  padding: .6rem 1rem; background: var(--ink); color: var(--cream);
  z-index: 9999; border-radius: 8px; font-weight: 600;
}
.skip-link:focus { top: 1rem; }

/* =============================================================
   3. Utilities
   ============================================================= */
.container {
  width: 100%;
  max-width: 1280px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.kicker {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1rem;
  display: inline-block;
}
.kicker-light { color: var(--accent-2); }

.section-head { max-width: 640px; margin-bottom: clamp(2.5rem, 6vw, 4rem); }
.section-head h2 { font-size: clamp(1.9rem, 4vw, 2.8rem); margin-bottom: 0.9rem; }
.section-sub { color: var(--ink-mute); font-size: 1.05rem; }

[data-reveal] {
  opacity: 0; transform: translateY(32px);
  transition: opacity .8s var(--ease-soft), transform .8s var(--ease-soft);
}
[data-reveal].is-revealed { opacity: 1; transform: none; }
[data-reveal][data-split] { opacity: 1; transform: none; }

/* =============================================================
   4. Typography
   ============================================================= */
em { font-style: italic; color: var(--accent); }
.split-word { display: inline-block; will-change: transform, opacity; }

/* =============================================================
   5. Components
   ============================================================= */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: 0.95rem 1.7rem;
  font-family: var(--sans); font-weight: 600; font-size: 0.92rem;
  border-radius: 999px;
  transition: transform .45s var(--ease-soft), box-shadow .45s var(--ease-soft), background-color .3s, color .3s;
  white-space: nowrap;
}
.btn-primary {
  background: var(--accent); color: var(--cream);
  box-shadow: 0 4px 14px rgba(47,74,62,0.18), 0 1px 3px rgba(47,74,62,0.12);
}
.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 22px 44px rgba(47,74,62,0.28), 0 8px 18px rgba(47,74,62,0.2);
}
.btn-primary:active { transform: translateY(-1px); transition-duration: .12s; }
.btn-ghost {
  border: 1px solid var(--line);
  color: var(--ink);
}
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn-small { padding: 0.65rem 1.3rem; font-size: 0.85rem; }

.has-magnetic { display: inline-flex; position: relative; isolation: isolate; }
.magnetic-inner {
  display: inline-flex; align-items: center; justify-content: center; gap: inherit;
  will-change: transform;
  transition: transform .8s var(--ease-soft);
}

/* Cursor */
.cursor {
  position: fixed; top: 0; left: 0;
  pointer-events: none; z-index: 9999;
  display: none;
  mix-blend-mode: difference;
  opacity: 0;
  transition: opacity .25s var(--ease-out);
}
.cursor.is-ready { opacity: 1; }
@media (hover: hover) and (pointer: fine) { .cursor { display: block; } }
.cursor-dot, .cursor-ring { position: fixed; top: 0; left: 0; pointer-events: none; will-change: transform; }
.cursor-dot { width: 5px; height: 5px; margin: -2.5px; background: var(--cream); border-radius: 50%; }
.cursor-ring {
  width: 30px; height: 30px; margin: -15px; border: 1px solid var(--cream); border-radius: 50%;
  transition: width .35s var(--ease-out), height .35s var(--ease-out), margin .35s var(--ease-out);
}
.cursor.is-interactive .cursor-ring { width: 52px; height: 52px; margin: -26px; }
.has-cursor, .has-cursor a, .has-cursor button { cursor: none; }

/* Scroll progress */
.scroll-progress {
  position: fixed; top: 0; left: 0; right: 0; height: 2px;
  z-index: 200; background: transparent; pointer-events: none;
}
.scroll-progress span {
  display: block; height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  transform-origin: 0 0; transform: scaleX(0);
}

/* WhatsApp floating button */
.whatsapp-fab {
  position: fixed;
  right: clamp(1rem, 4vw, 1.5rem);
  bottom: clamp(1rem, 4vw, 1.5rem);
  z-index: 150;
  width: 58px; height: 58px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: #25d366;
  box-shadow: 0 10px 26px rgba(37,211,102,0.4), 0 4px 10px rgba(28,26,23,0.18);
  transition: transform .4s var(--ease-soft), box-shadow .4s var(--ease-soft);
  isolation: isolate;
}
.whatsapp-fab:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 36px rgba(37,211,102,0.5), 0 8px 16px rgba(28,26,23,0.2);
}
.whatsapp-fab svg { width: 26px; height: 26px; fill: #fff; position: relative; z-index: 1; }
.whatsapp-fab-ping {
  position: absolute; inset: 0; border-radius: 50%;
  background: #25d366; z-index: 0;
  animation: whatsappPing 2.6s ease-out infinite;
}
@keyframes whatsappPing {
  0% { transform: scale(1); opacity: .55; }
  100% { transform: scale(1.7); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .whatsapp-fab-ping { animation: none; display: none; }
}

/* WhatsApp chat bubble (appears after a few seconds) */
.wa-bubble {
  position: fixed;
  right: clamp(1rem, 4vw, 1.5rem);
  bottom: calc(clamp(1rem, 4vw, 1.5rem) + 58px + 14px);
  z-index: 150;
  width: min(260px, calc(100vw - 2rem));
  background: #fff;
  color: var(--ink);
  border-radius: 16px 16px 4px 16px;
  box-shadow: 0 14px 34px rgba(28,26,23,0.18), 0 3px 8px rgba(28,26,23,0.1);
  opacity: 0; visibility: hidden;
  transform: translateY(10px) scale(.96);
  transform-origin: 100% 100%;
  transition: opacity .45s var(--ease-soft), transform .45s var(--ease-soft), visibility 0s linear .45s;
}
.wa-bubble.is-visible {
  opacity: 1; visibility: visible;
  transform: none;
  transition: opacity .45s var(--ease-soft), transform .45s var(--ease-soft), visibility 0s;
}
.wa-bubble::after {
  content: "";
  position: absolute; right: 22px; bottom: -7px;
  width: 14px; height: 14px; background: #fff;
  transform: rotate(45deg);
  border-radius: 0 0 3px 0;
}
.wa-bubble-link {
  display: block;
  padding: 1rem 2.2rem 1rem 1.1rem;
  font-size: .9rem; line-height: 1.45;
  color: #4a463f;
}
.wa-bubble-link strong {
  display: block; margin-bottom: .2rem;
  font-weight: 600; color: var(--ink);
}
.wa-bubble-link:hover strong { color: var(--accent); }
.wa-bubble-close {
  position: absolute; top: .35rem; right: .4rem; z-index: 1;
  width: 28px; height: 28px; border-radius: 50%;
  border: 0; background: transparent; cursor: pointer;
  font-size: 1.2rem; line-height: 1; color: #8a857c;
}
.wa-bubble-close:hover { background: var(--bg-2); color: var(--ink); }
html.has-modal-open .wa-bubble { display: none; }

/* =============================================================
   6. Navigation
   ============================================================= */
.nav {
  position: fixed; top: 0; inset-inline: 0; z-index: 100;
  color: var(--cream);
  transition: background-color .4s var(--ease-out), backdrop-filter .4s var(--ease-out), box-shadow .4s var(--ease-out), padding .3s, color .4s var(--ease-out);
}
.nav.is-scrolled { color: var(--ink); }
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  padding-block: 1.4rem;
  transition: padding .3s var(--ease-out);
}
.nav.is-scrolled {
  background: rgba(246,241,232,0.88);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 var(--line);
}
.nav.is-scrolled .nav-inner { padding-block: 0.9rem; }

.nav-logo {
  display: flex; align-items: center; gap: 0.65rem;
}
.brand-mark { width: 30px; height: 30px; flex-shrink: 0; }
.brand-mark path {
  fill: none; stroke: currentColor;
  stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round;
}
.nav-logo-text {
  font-family: var(--serif); font-weight: 600; font-size: 1.3rem;
  letter-spacing: 0.03em;
  display: flex; flex-direction: column; line-height: 1;
}
.nav-logo-text span {
  font-family: var(--mono); font-size: 0.58rem; letter-spacing: 0.18em;
  text-transform: uppercase; color: rgba(246,241,232,0.65); margin-top: 3px; font-weight: 400;
  transition: color .4s var(--ease-out);
}
.nav.is-scrolled .nav-logo-text span { color: var(--ink-mute); }
.footer-brand .nav-logo-text span { color: var(--ink-mute); }
.footer-brand .nav-logo { color: var(--ink); }
.nav-links { display: none; gap: 2.1rem; }
@media (min-width: 960px) { .nav-links { display: flex; } }
.nav-link { position: relative; font-size: 0.94rem; font-weight: 500; padding: 0.25rem 0; }
.nav-link::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px;
  height: 1px; background: currentColor;
  transform: scaleX(0); transform-origin: right;
  transition: transform .45s var(--ease-out);
}
.nav-link:hover::after { transform: scaleX(1); transform-origin: left; }
.nav .btn-small { display: none; }
@media (min-width: 960px) { .nav .btn-small { display: inline-flex; } }

.nav-burger {
  display: grid; gap: 5px; width: 32px; height: 24px; align-content: center;
}
@media (min-width: 960px) { .nav-burger { display: none; } }
.nav-burger span { display: block; height: 1.5px; background: currentColor; transition: transform .35s var(--ease-soft), opacity .3s, background-color .4s; }
.nav-burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

.nav-mobile {
  position: fixed; inset: 0; z-index: 160;
  background: var(--ink); color: var(--cream);
  display: grid; place-items: center;
  clip-path: inset(0 0 100% 0);
  transition: clip-path .65s var(--ease-soft);
}
.nav-mobile[data-open="true"] { clip-path: inset(0); }
.nav-mobile nav { display: flex; flex-direction: column; gap: 2rem; text-align: center; }
.nav-mobile a { font-family: var(--serif); font-size: 2rem; }
@media (min-width: 960px) { .nav-mobile { display: none; } }

/* =============================================================
   7. Hero
   ============================================================= */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex; align-items: center;
  padding-top: 6rem;
  padding-bottom: 7rem;
  overflow: clip;
}
.hero-bg { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.hero-bg img {
  width: 100%; height: 100%; object-fit: cover;
  transform: scale(1.06);
  animation: heroAmbientZoom 26s ease-in-out infinite alternate;
}
@keyframes heroAmbientZoom {
  from { transform: scale(1.06) translate3d(0,0,0); }
  to   { transform: scale(1.15) translate3d(-1%,-1%,0); }
}
.hero-tint {
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(20,24,21,0.62) 0%, rgba(20,24,21,0.66) 55%, rgba(20,24,21,0.85) 100%),
    linear-gradient(90deg, rgba(20,24,21,0.4) 0%, transparent 70%);
}
.hero-inner { position: relative; z-index: 1; max-width: 760px; }
.hero-title {
  font-size: clamp(2.6rem, 6.4vw, 5rem);
  color: var(--cream);
  margin-bottom: 1.4rem;
  max-width: 16ch;
}
.hero-title em { color: var(--cream); font-style: italic; }
.hero-sub {
  color: rgba(246,241,232,0.86);
  font-size: clamp(1.02rem, 1.6vw, 1.2rem);
  max-width: 46ch;
  margin-bottom: 2.2rem;
}
.hero-brand {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  margin-bottom: clamp(1.8rem, 5vw, 3rem);
  color: var(--cream);
  text-shadow: 0 2px 18px rgba(0,0,0,0.5);
}
.hero-brand strong {
  font-family: var(--serif); font-weight: 600;
  font-size: clamp(2.6rem, 9vw, 5.2rem);
  letter-spacing: 0.14em; line-height: 1;
  padding-left: 0.14em;
}
.hero-brand span {
  font-family: var(--mono); font-size: clamp(0.7rem, 1.8vw, 1rem);
  letter-spacing: 0.5em; text-transform: uppercase;
  margin-top: 0.8rem; padding-left: 0.5em;
}
.hero-inner .kicker {
  color: var(--cream);
  text-shadow: 0 1px 12px rgba(0,0,0,0.55), 0 1px 3px rgba(0,0,0,0.7);
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; }
.hero-actions .btn-ghost {
  border-color: rgba(246,241,232,0.45); color: var(--cream);
}
.hero-actions .btn-ghost:hover { border-color: var(--cream); background: rgba(246,241,232,0.1); color: var(--cream); }

.quick-filter-wrap {
  position: relative;
  z-index: 5;
  display: flex;
  justify-content: center;
  margin-top: clamp(-4.5rem, -8vw, -3.25rem);
  margin-bottom: clamp(2rem, 5vw, 3.5rem);
}
.quick-filter {
  width: min(920px, 100%);
  background: var(--paper);
  border-radius: 18px;
  box-shadow: 0 30px 70px -20px rgba(28,26,23,0.35), 0 10px 24px -10px rgba(28,26,23,0.2);
  padding: 1.5rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}
@media (min-width: 720px) {
  .quick-filter {
    grid-template-columns: 1fr 1fr 1.4fr auto;
    align-items: end;
    padding: 1.6rem 1.8rem;
  }
}
.qf-field { display: flex; flex-direction: column; gap: 0.4rem; }
.qf-field label {
  font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--ink-mute);
}
.qf-field select, .qf-field input {
  font: inherit; font-size: 0.96rem; color: var(--ink);
  border: 1px solid var(--line); border-radius: 10px;
  padding: 0.7rem 0.85rem;
  background: var(--paper);
  transition: border-color .3s;
}
.qf-field select:focus, .qf-field input:focus { border-color: var(--accent); }
.qf-submit { width: 100%; }
@media (min-width: 720px) { .qf-submit { width: auto; } }

/* =============================================================
   8. Sections
   ============================================================= */

/* Stats strip */
.stats-strip { padding-block: clamp(1rem, 2vw, 1.5rem) clamp(3rem, 6vw, 4rem); background: var(--bg); }
.stats-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem 1.5rem;
  border-top: 1px solid var(--line); padding-top: 2.5rem;
}
@media (min-width: 720px) { .stats-grid { grid-template-columns: repeat(4, 1fr); } }
.stat { display: flex; flex-direction: column; gap: 0.4rem; }
.stat-value { font-family: var(--serif); font-size: clamp(2.2rem, 4.2vw, 3.2rem); font-weight: 600; color: var(--accent); }
.stat-label { font-size: 0.85rem; color: var(--ink-mute); max-width: 18ch; }

/* Marquee */
.marquee { overflow: hidden; position: relative; background: var(--accent); padding-block: 1.1rem; }
.marquee-track { display: inline-flex; gap: 1.4rem; white-space: nowrap; will-change: transform; }
.marquee-track span {
  font-family: var(--serif); font-style: italic; font-size: 1.15rem;
  color: rgba(246,241,232,0.9);
}

/* Manifesto */
.manifesto { padding-block: clamp(2rem, 4vw, 3.5rem) clamp(2.5rem, 5vw, 4rem); }
.manifesto-grid {
  display: grid; grid-template-columns: 1fr; gap: 1.5rem;
}
@media (min-width: 960px) {
  .manifesto-grid {
    grid-template-columns: 0.9fr 1.6fr 1.3fr;
    align-items: start;
    gap: 3rem;
  }
}
.manifesto-num { display: flex; flex-direction: column; gap: 0.6rem; }
.manifesto-num span { font-family: var(--serif); font-size: 3.2rem; color: var(--accent-2); line-height: 1; }
.manifesto-num p { font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-mute); }
.manifesto-text .lede {
  font-family: var(--serif); font-size: clamp(1.4rem, 2.6vw, 1.85rem); font-style: italic;
  color: var(--ink-soft); margin-bottom: 1.3rem; line-height: 1.35;
}
.manifesto-text p + p { margin-top: 1.1rem; color: var(--ink-mute); }
.manifesto-figure { border-radius: 14px; overflow: hidden; aspect-ratio: 16/10; }
@media (min-width: 960px) { .manifesto-figure { aspect-ratio: 4/5; } }
.manifesto-figure img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease-soft); }
.manifesto-figure:hover img { transform: scale(1.06); }

/* Listings */
.listings { padding-block: clamp(3.5rem, 7vw, 5rem) clamp(0.5rem, 2vw, 1.5rem); }
.listings + .listings { border-top: 1px solid var(--line); }
.section-bar { display: flex; align-items: flex-end; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap; margin-bottom: clamp(2rem, 5vw, 3rem); }
.section-bar .section-head { margin-bottom: 0; }
.carousel { position: relative; }
.carousel-btn {
  position: absolute; top: 9.3rem; z-index: 4;
  width: 48px; height: 48px; border-radius: 50%;
  display: grid; place-items: center;
  background: rgba(255,255,255,0.94); color: var(--ink);
  box-shadow: 0 8px 24px rgba(28,26,23,0.25);
  transition: background-color .3s, color .3s, opacity .3s, transform .3s;
}
.carousel-btn[data-carousel-prev] { left: 0.6rem; }
.carousel-btn[data-carousel-next] { right: 0.6rem; }
@media (min-width: 1280px) {
  .carousel-btn[data-carousel-prev] { left: -0.4rem; }
  .carousel-btn[data-carousel-next] { right: -0.4rem; }
}
.carousel-btn svg { width: 18px; height: 18px; }
.carousel-btn:hover:not(:disabled) { background: var(--accent); color: var(--cream); transform: scale(1.06); }
.carousel-btn:disabled { opacity: 0; pointer-events: none; }
.listing-grid {
  display: flex; gap: 1.4rem;
  overflow-x: auto; overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--gutter);
  margin-inline: calc(-1 * var(--gutter));
  padding: 1.2rem var(--gutter) 2.6rem;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.listing-grid::-webkit-scrollbar { display: none; }
.listing-grid > .listing-card { flex: 0 0 min(340px, 82vw); scroll-snap-align: start; }
@media (min-width: 720px) { .listing-grid { gap: 1.8rem; } .listing-grid > .listing-card { flex-basis: 360px; } }

.listing-card {
  --rx: 0deg; --ry: 0deg;
  background: var(--paper);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 1px 0 var(--line-soft);
  transition: transform .15s var(--ease-out), box-shadow .5s var(--ease-soft);
}
.listing-card.has-tilt {
  transform: perspective(1400px) rotateX(var(--rx)) rotateY(var(--ry));
  transform-style: preserve-3d;
}
.listing-card:hover {
  box-shadow:
    0 50px 90px -30px rgba(47,74,62,0.28),
    0 20px 40px -15px rgba(28,26,23,0.18);
}
.listing-media { position: relative; display: block; aspect-ratio: 4/3; overflow: hidden; }
.card-img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease-soft), filter .5s; }
.listing-card:hover .card-img { transform: scale(1.08); filter: saturate(1.1) brightness(1.02); }
.listing-tag {
  position: absolute; top: 1rem; left: 1rem;
  font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.08em; text-transform: uppercase;
  padding: 0.4rem 0.75rem; border-radius: 999px;
  background: rgba(246,241,232,0.92); color: var(--ink);
  backdrop-filter: blur(6px);
}
.listing-tag-venta { color: var(--accent); }
.listing-tag-alquiler { color: var(--accent-2); }
.listing-media::after {
  content: "Ver galería";
  position: absolute; left: 50%; bottom: 1rem; transform: translate(-50%, 8px);
  font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.06em; text-transform: uppercase;
  padding: 0.55rem 1.1rem; border-radius: 999px;
  background: rgba(28,26,23,0.72); color: var(--cream);
  opacity: 0; transition: opacity .35s var(--ease-out), transform .35s var(--ease-out);
  pointer-events: none;
}
.listing-card:hover .listing-media::after { opacity: 1; transform: translate(-50%, 0); }
.listing-body { padding: 1.6rem; transform: translateZ(30px); }
.listing-price { font-family: var(--serif); font-size: 1.55rem; font-weight: 600; color: var(--ink); margin-bottom: 0.3rem; }
.listing-price span { font-family: var(--sans); font-size: 0.95rem; font-weight: 500; color: var(--ink-mute); }
.listing-title { font-size: 1.2rem; margin-bottom: 0.35rem; }
.listing-loc { color: var(--ink-mute); font-size: 0.92rem; margin-bottom: 1rem; }
.listing-specs { display: flex; flex-wrap: wrap; gap: 0.5rem 1rem; margin-bottom: 1.2rem; }
.listing-specs li {
  font-family: var(--mono); font-size: 0.74rem; color: var(--ink-mute);
  padding-right: 1rem; border-right: 1px solid var(--line);
}
.listing-specs li:last-child { border-right: 0; padding-right: 0; }
.listing-link { font-size: 0.9rem; font-weight: 600; color: var(--accent); position: relative; }
.listing-link::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 1px; background: currentColor;
  transform: scaleX(0); transform-origin: right; transition: transform .4s var(--ease-out);
}
.listing-link:hover::after { transform: scaleX(1); transform-origin: left; }

/* Services */
.services { padding-block: clamp(5rem, 9vw, 7.5rem); background: var(--ink); color: var(--cream); position: relative; overflow: clip; }
.section-head-light h2 { color: var(--cream); }
.services-grid { display: grid; grid-template-columns: 1fr; gap: 2rem; }
@media (min-width: 720px) { .services-grid { grid-template-columns: repeat(3, 1fr); gap: 2.4rem; } }
.service-card {
  padding: 2rem 1.8rem; border: 1px solid rgba(246,241,232,0.14); border-radius: 16px;
  transition: border-color .4s, transform .5s var(--ease-soft), background-color .4s;
}
.service-card:hover { border-color: rgba(196,154,91,0.4); background: rgba(246,241,232,0.03); transform: translateY(-6px); }
.service-icon { display: inline-flex; width: 44px; height: 44px; color: var(--accent-2); margin-bottom: 1.3rem; }
.service-icon svg { width: 100%; height: 100%; }
.service-card h3 { color: var(--cream); font-size: 1.25rem; margin-bottom: 0.6rem; }
.service-card p { color: rgba(246,241,232,0.68); font-size: 0.96rem; }

/* Testimonials */
.testimonials { padding-block: clamp(5rem, 9vw, 7.5rem); }
.testi-track { position: relative; min-height: 220px; }
.testi-card {
  position: absolute; inset: 0;
  opacity: 0; pointer-events: none;
  transition: opacity .35s var(--ease-soft);
  max-width: 760px;
}
.testi-card.is-active { opacity: 1; pointer-events: auto; position: relative; }
.testi-card p {
  font-family: var(--serif); font-style: italic; font-size: clamp(1.4rem, 3vw, 2rem);
  color: var(--ink-soft); margin-bottom: 1.3rem; line-height: 1.4;
}
.testi-card footer { font-size: 0.92rem; color: var(--ink-mute); }
.testi-card footer strong { color: var(--ink); }
.testi-dots { display: flex; gap: 0.6rem; margin-top: 2rem; }
.testi-dots button { width: 8px; height: 8px; border-radius: 50%; background: var(--line); transition: background .3s, width .3s; }
.testi-dots button.is-active { background: var(--accent); width: 22px; border-radius: 999px; }

/* CTA / Contact */
.cta-contact {
  position: relative; overflow: clip;
  background: var(--ink); color: var(--cream);
  padding-block: clamp(5rem, 10vw, 8rem);
}
.cta-halo {
  position: absolute; inset: -30% -10% -30% -10%;
  background: radial-gradient(45% 40% at 25% 30%, rgba(168,118,62,0.35), transparent 70%),
              radial-gradient(40% 35% at 80% 70%, rgba(47,74,62,0.5), transparent 70%);
  filter: blur(90px);
  pointer-events: none;
}
.cta-grid { position: relative; display: grid; grid-template-columns: 1fr; gap: 3rem; }
@media (min-width: 960px) { .cta-grid { grid-template-columns: 1fr 1fr; gap: 4rem; } }
.cta-copy h2 { color: var(--cream); font-size: clamp(2rem, 4.5vw, 3rem); margin-bottom: 1.1rem; }
.cta-sub { color: rgba(246,241,232,0.72); max-width: 42ch; margin-bottom: 2rem; }
.cta-contact-list { display: flex; flex-direction: column; gap: 0.6rem; }
.cta-contact-list a { font-size: 1.05rem; border-bottom: 1px solid transparent; transition: border-color .3s; }
.cta-contact-list a:hover { border-color: var(--accent-2); }
.cta-contact-list li { color: rgba(246,241,232,0.72); font-size: 0.95rem; }

.cta-form-wrap { position: relative; }
.cta-form {
  display: flex; flex-direction: column; gap: 1.3rem;
  transition: opacity .55s var(--ease-out), transform .55s var(--ease-soft);
}
.cta-form.is-sent { opacity: 0; transform: translateY(-12px); pointer-events: none; }
.field { position: relative; }
.field input, .field textarea {
  width: 100%; font: inherit; color: var(--cream);
  padding: 1.3rem 0.2rem 0.5rem; border: 0; border-bottom: 1px solid rgba(246,241,232,0.3);
  background: transparent; resize: none;
  transition: border-color .3s;
}
.field input:focus, .field textarea:focus { border-color: var(--accent-2); }
.field label {
  position: absolute; left: 0.2rem; top: 1.3rem;
  pointer-events: none; transition: all .25s var(--ease-out);
  color: rgba(246,241,232,0.55); font-size: 1rem;
}
.field input:focus + label, .field input:not(:placeholder-shown) + label,
.field textarea:focus + label, .field textarea:not(:placeholder-shown) + label {
  top: 0.1rem; font-size: 0.68rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent-2);
}
.cta-submit { position: relative; margin-top: 0.6rem; align-self: flex-start; }
.cta-form-spinner, .cta-form-check {
  position: absolute; inset: 0; display: grid; place-items: center;
  opacity: 0; pointer-events: none;
}
.cta-form.is-sending .cta-form-label { opacity: 0; }
.cta-form.is-sending .cta-form-spinner { opacity: 1; }
.cta-form-spinner::after {
  content: ""; width: 16px; height: 16px;
  border: 1.5px solid rgba(246,241,232,0.35); border-top-color: var(--cream);
  border-radius: 50%; animation: spin .9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.cta-form-check path {
  stroke: currentColor; stroke-width: 2; fill: none;
  stroke-dasharray: 1; stroke-dashoffset: 1;
  transition: stroke-dashoffset .55s var(--ease-out);
}
.cta-success {
  position: absolute; left: 0; top: 0; right: 0;
  opacity: 0; pointer-events: none; transform: translateY(10px);
  transition: opacity .8s var(--ease-out) .1s, transform .8s var(--ease-soft) .1s;
}
.cta-success.is-visible { opacity: 1; pointer-events: auto; transform: none; }
.cta-success h3 { color: var(--cream); font-size: 1.8rem; margin-bottom: 0.6rem; }
.cta-success p { color: rgba(246,241,232,0.75); }

/* =============================================================
   9. Footer
   ============================================================= */
.site-footer { background: var(--bg-2); padding-top: clamp(3.5rem, 7vw, 5rem); }
.footer-grid {
  display: grid; grid-template-columns: 1fr; gap: 1.5rem;
  padding-bottom: 3rem; border-bottom: 1px solid var(--line);
}
@media (min-width: 720px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; } }
.footer-brand p { color: var(--ink-mute); margin-top: 0.9rem; font-size: 0.92rem; max-width: 30ch; }
.footer-nav { display: flex; flex-direction: column; gap: 0.7rem; }
.footer-nav a, .footer-contact a { font-size: 0.94rem; }
.footer-nav a:hover, .footer-contact a:hover { color: var(--accent); }
.footer-contact { display: flex; flex-direction: column; gap: 0.7rem; font-size: 0.92rem; color: var(--ink-mute); }
.footer-bottom {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.8rem;
  padding-block: 1.6rem; font-size: 0.8rem; color: var(--ink-mute);
}
.footer-credits a { text-decoration: underline; text-underline-offset: 2px; }

/* =============================================================
   Property detail modal
   ============================================================= */
html.has-modal-open > body > :not(dialog) {
  pointer-events: none !important;
}
html.has-modal-open .cursor { display: none; }
html.has-modal-open.has-cursor,
html.has-modal-open.has-cursor a,
html.has-modal-open.has-cursor button {
  cursor: auto;
}

.property-modal {
  pointer-events: auto;
  position: fixed; inset: 0; margin: auto;
  width: min(920px, calc(100% - 2rem));
  max-height: calc(100% - 3rem);
  padding: 0; border: 0; border-radius: 18px;
  background: var(--paper); color: var(--ink);
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  box-shadow: 0 40px 90px -20px rgba(0,0,0,0.4);
}
.property-modal::backdrop {
  background: rgba(20, 18, 15, 0.6);
  backdrop-filter: blur(4px);
}
.property-modal[open] {
  display: flex;
  flex-direction: column;
  animation: pmIn .4s var(--ease-out);
}
@media (min-width: 800px) {
  .property-modal[open] {
    flex-direction: row;
    height: min(640px, calc(100% - 3rem));
    overflow-y: hidden;
  }
}
@keyframes pmIn {
  from { opacity: 0; transform: scale(0.97) translateY(8px); }
  to   { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .property-modal[open] { animation: none; }
}

.pm-close {
  position: absolute; top: 1rem; right: 1rem; z-index: 3;
  width: 38px; height: 38px; border-radius: 50%;
  display: grid; place-items: center;
  background: rgba(28,26,23,0.55); color: var(--cream);
  transition: background-color .3s;
}
.pm-close:hover { background: rgba(28,26,23,0.8); }
.pm-close svg { width: 16px; height: 16px; }

.pm-gallery {
  position: relative; background: var(--bg-2);
  width: 100%; aspect-ratio: 4 / 3; flex: 0 0 auto;
}
@media (min-width: 800px) {
  .pm-gallery { aspect-ratio: auto; width: auto; height: 100%; flex: 1 1 50%; }
}
.pm-gallery-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pm-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 38px; height: 38px; border-radius: 50%;
  display: grid; place-items: center;
  background: rgba(255,255,255,0.85); color: var(--ink);
  transition: background-color .3s, transform .3s;
}
.pm-arrow:hover { background: var(--paper); transform: translateY(-50%) scale(1.06); }
.pm-arrow svg { width: 18px; height: 18px; }
.pm-arrow-prev { left: 0.9rem; }
.pm-arrow-next { right: 0.9rem; }
.pm-dots {
  position: absolute; left: 50%; bottom: 0.9rem; transform: translateX(-50%);
  display: flex; gap: 0.4rem;
}
.pm-dots span {
  width: 6px; height: 6px; border-radius: 50%;
  background: rgba(255,255,255,0.55); transition: background-color .3s, width .3s;
}
.pm-dots span.is-active { background: var(--paper); width: 16px; border-radius: 999px; }

.pm-body {
  flex: 1 1 auto;
  padding: 1.8rem clamp(1.4rem, 3vw, 2.2rem);
}
@media (min-width: 800px) {
  .pm-body {
    min-height: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
  }
}
.pm-tag {
  font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.08em; text-transform: uppercase;
  padding: 0.35rem 0.7rem; border-radius: 999px; background: var(--bg-2); color: var(--accent);
  display: inline-block; margin-bottom: 0.9rem;
}
.pm-title { font-size: 1.5rem; margin-bottom: 0.3rem; }
.pm-loc { color: var(--ink-mute); font-size: 0.95rem; margin-bottom: 0.9rem; }
.pm-price { font-family: var(--serif); font-size: 1.7rem; font-weight: 600; margin-bottom: 1rem; }
.pm-price span { font-family: var(--sans); font-size: 1rem; font-weight: 500; color: var(--ink-mute); }
.pm-specs { display: flex; flex-wrap: wrap; gap: 0.5rem 1rem; margin-bottom: 1.2rem; }
.pm-specs li {
  font-family: var(--mono); font-size: 0.76rem; color: var(--ink-mute);
  padding-right: 1rem; border-right: 1px solid var(--line);
}
.pm-specs li:last-child { border-right: 0; padding-right: 0; }
.pm-desc { color: var(--ink-soft); font-size: 0.98rem; line-height: 1.65; margin-bottom: 1.6rem; }
.pm-actions { display: flex; flex-wrap: wrap; gap: 0.9rem; }

/* Credits page */
.page-credits { padding: clamp(2rem, 5vw, 4rem) var(--gutter); max-width: 760px; margin-inline: auto; }
.page-credits h1 { font-size: 2rem; margin-block: 1.5rem 2rem; }
.page-credits .masthead a { font-weight: 600; color: var(--accent); }
.credits-list { display: flex; flex-direction: column; gap: 1rem; }
.credits-list li { padding-bottom: 1rem; border-bottom: 1px solid var(--line); font-size: 0.92rem; color: var(--ink-mute); }
.credits-list a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }

/* =============================================================
   10. Responsive tune-ups
   ============================================================= */
@media (max-width: 539px) {
  .hero { padding-top: 5rem; }
  .stats-grid { padding-top: 2rem; }
}

/* =============================================================
   11. Reduced motion — only intrusive effects
   ============================================================= */
@media (prefers-reduced-motion: reduce) {
  .hero-bg img { animation: none !important; }
  .marquee-track { animation-duration: 90s !important; }
}

/* =============================================================
   Search results page
   ============================================================= */
.results-page { padding-block: clamp(6rem, 12vw, 8rem) clamp(3rem, 6vw, 5rem); min-height: 70vh; }
.results-back { font-size: 0.9rem; font-weight: 600; color: var(--accent); display: inline-block; margin-bottom: 1.6rem; }
.results-back:hover { text-decoration: underline; text-underline-offset: 3px; }
.results-head { margin-bottom: 2rem; }
.results-head h1 { font-size: clamp(2rem, 5vw, 3.2rem); margin-bottom: 0.9rem; }
.results-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 0.8rem 1.2rem; color: var(--ink-mute); font-size: 0.95rem; }
.results-chips { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.results-chips span {
  font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.06em; text-transform: uppercase;
  padding: 0.35rem 0.75rem; border-radius: 999px; background: var(--bg-2); color: var(--accent);
}
.results-refine { width: 100%; margin-bottom: clamp(2rem, 5vw, 3.2rem); box-shadow: 0 1px 0 var(--line), 0 12px 30px -18px rgba(28,26,23,0.25); }
.results-grid { display: grid; grid-template-columns: 1fr; gap: 1.6rem; }
@media (min-width: 720px) { .results-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .results-grid { grid-template-columns: repeat(3, 1fr); gap: 1.8rem; } }
.results-empty { grid-column: 1 / -1; text-align: center; padding: clamp(2.5rem, 7vw, 4.5rem) 1rem; border: 1px dashed var(--line); border-radius: 16px; }
.results-empty h3 { font-size: clamp(1.4rem, 3vw, 1.9rem); margin-bottom: 0.7rem; }
.results-empty p { color: var(--ink-mute); max-width: 46ch; margin: 0 auto 1.6rem; }
.results-empty-actions { display: flex; flex-wrap: wrap; gap: 0.9rem; justify-content: center; }

/* Team */
.team { padding-block: clamp(1.8rem, 4vw, 2.6rem); border-top: 1px solid var(--line); }
.team-head { margin-bottom: 1.4rem; text-align: center; }
.team-head .kicker { margin-bottom: 0.4rem; }
.team-head h2 { font-size: clamp(1.15rem, 2.6vw, 1.5rem); }
.team-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.6rem; max-width: 560px; margin-inline: auto; }
.team-card { text-align: center; }
.team-card img { width: clamp(52px, 15vw, 84px); aspect-ratio: 1; object-fit: cover; border-radius: 50%; margin-inline: auto; background: var(--bg-2); box-shadow: 0 0 0 2px var(--bg), 0 0 0 3px var(--line); }
.team-card figcaption { display: flex; flex-direction: column; gap: 0.1rem; margin-top: 0.55rem; }
.team-card strong { font-family: var(--serif); font-size: clamp(0.82rem, 2.6vw, 1rem); font-weight: 600; line-height: 1.15; }
.team-card span { font-family: var(--mono); font-size: clamp(0.5rem, 1.6vw, 0.6rem); letter-spacing: 0.05em; text-transform: uppercase; color: var(--ink-mute); line-height: 1.3; }

/* Services — compact */
.services { padding-block: clamp(2.2rem, 5vw, 3.5rem); }
.services .section-head { margin-bottom: 1.4rem; }
.services .section-head h2 { font-size: clamp(1.35rem, 3vw, 1.9rem); margin-bottom: 0; }
.services .kicker { margin-bottom: 0.5rem; }
.services-grid { gap: 0.7rem; }
@media (min-width: 720px) { .services-grid { gap: 1rem; } }
.service-card { padding: 1rem 1.1rem; display: grid; grid-template-columns: 34px 1fr; column-gap: 0.9rem; align-items: start; border-radius: 12px; }
.service-icon { width: 34px; height: 34px; margin: 0; grid-row: span 2; }
.service-card h3 { font-size: 1.05rem; margin-bottom: 0.2rem; }
.service-card p { font-size: 0.86rem; line-height: 1.5; }
.service-card:hover { transform: translateY(-3px); }
@media (min-width: 720px) {
  .service-card { grid-template-columns: 1fr; padding: 1.2rem 1.3rem; }
  .service-icon { grid-row: auto; margin-bottom: 0.7rem; }
}
