/* ==========================================================
   Grupo Terranova site styles (Identidad v2: navy + gold, Plus Jakarta Sans). Loaded after tokens.css.
   The legacy "Wealthome" template stylesheet is retired; this file owns the reset.
========================================================== */

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
body, h1, h2, h3, h4, p, figure, blockquote, dl, dd, ol, ul { margin: 0; }
img, video, iframe { max-width: 100%; }
img { height: auto; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; padding: 0; cursor: pointer; }
address { font-style: normal; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }

/* ---------- Base ---------- */
body {
  background: var(--white);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
}

:focus-visible { outline: var(--focus-ring); outline-offset: 2px; }
.on-ink :focus-visible { outline: var(--focus-ring-on-ink); }

.container-tn {
  width: 100%;
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.skip-link {
  position: absolute;
  left: var(--space-4);
  top: -100px;
  z-index: var(--z-overlay);
  padding: var(--space-3) var(--space-4);
  background: var(--white);
  color: var(--ink);
  font-weight: 600;
  border-radius: var(--radius);
}
.skip-link:focus { top: var(--space-3); }

/* Form honeypot: off-screen, out of the tab order and hidden from assistive tech (aria-hidden) */
.hp-tn {
  position: absolute !important;
  left: -10000px;
  width: 1px; height: 1px;
  overflow: hidden;
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ---------- Buttons ---------- */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 48px;
  padding: 0 22px;
  border: 1.5px solid transparent;
  border-radius: var(--radius);
  font: 600 16px/1 var(--font-body);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease),
              color var(--dur-fast) var(--ease), transform var(--dur-fast) var(--ease);
}
.button:active { transform: scale(0.97); }
.button[disabled] { opacity: 0.6; cursor: progress; transform: none; }
.button img, .button .material-symbols-rounded { width: 20px; height: 20px; font-size: 20px; flex: none; }
.button--sm { min-height: var(--tap-min); padding: 0 16px; font-size: 15px; }

.button--primary { background: var(--ink); color: var(--white); }
.button--primary:hover { background: var(--ink-2); }

.button--secondary { background: var(--white); color: var(--ink); border-color: var(--control-border); }
.button--secondary:hover { background: var(--cool-50); border-color: var(--ink); }

.button--gold { background: var(--gold); color: var(--navy); font-weight: 700; }
.button--gold:hover { background: var(--gold-hover); }

.button--whatsapp { background: var(--whatsapp); color: var(--white); }
.button--whatsapp:hover { background: var(--whatsapp-hover); }

.button--on-ink { background: transparent; color: var(--on-ink); border-color: rgb(var(--white-rgb) / 0.55); }
.button--on-ink:hover { background: var(--ink-2); border-color: var(--on-ink); }

/* ---------- Brand: original Grupo Terranova logo (PNG 500x145, shown at <=64px tall, so always above 2x) ---------- */
.brand {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap-min);
  text-decoration: none;
  flex: none;
}
.brand__logo { display: block; width: auto; height: var(--logo-h, 44px); transition: height var(--dur) var(--ease); }

/* ---------- Header: tall at the top, compact + translucent once scrolled ----------
   The bar shrinks by --header-shrink while margin-bottom grows by the same amount, with the same
   timing, so the header's footprint in the flow never changes and the content does not jump. */
.site-header {
  --header-h: 72px;
  --header-h-compact: 60px;
  --logo-h: 48px;
  --logo-h-compact: 40px;
  --header-shrink: 0px;
  position: sticky;
  top: 0;
  z-index: var(--z-header);
  margin-bottom: var(--header-shrink);
  background: var(--navy);
  color: var(--on-ink);
  transition: margin-bottom var(--dur) var(--ease), background-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.site-header.active {
  --header-shrink: calc(var(--header-h) - var(--header-h-compact));
  --logo-h: var(--logo-h-compact);
  background: rgb(var(--navy-rgb) / 0.86);
  box-shadow: 0 1px 0 rgb(var(--white-rgb) / 0.06), 0 8px 24px rgb(var(--shadow-rgb) / 0.22);
}
@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .site-header.active { -webkit-backdrop-filter: blur(12px) saturate(140%); backdrop-filter: blur(12px) saturate(140%); }
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .site-header.active { background: var(--navy); }
}
@media (prefers-reduced-transparency: reduce) {
  .site-header.active { background: var(--navy); -webkit-backdrop-filter: none; backdrop-filter: none; }
}
.site-header__inner {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--space-5);
  height: calc(var(--header-h) - var(--header-shrink));
  transition: height var(--dur) var(--ease);
}

.site-nav { margin-left: auto; }
.site-nav__list { display: flex; gap: var(--space-1); margin: 0; padding: 0; list-style: none; }
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap-min);
  padding: 0 12px;
  color: var(--on-ink-muted);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius);
  transition: color var(--dur-fast) var(--ease);
}
.site-nav a:hover { color: var(--on-ink); }
.site-nav a[aria-current="page"] {
  color: var(--on-ink);
  text-decoration: underline 2px var(--gold);
  text-underline-offset: 10px;
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: var(--tap-min);
  height: var(--tap-min);
  margin-left: auto;
  color: var(--on-ink);
  border-radius: var(--radius);
}
.nav-toggle .material-symbols-rounded { font-size: 28px; }

@media (min-width: 1024px) {
  .site-header { --header-h: 96px; --header-h-compact: 68px; --logo-h: 64px; --logo-h-compact: 48px; }
}

@media (max-width: 1023px) {
  .nav-toggle { display: inline-flex; }
  .site-header__wa { display: none; }
  .site-nav {
    position: absolute;
    top: 100%;
    left: calc(-1 * var(--gutter));
    right: calc(-1 * var(--gutter));
    display: none;
    margin: 0;
    padding: var(--space-2) var(--gutter) var(--space-5);
    background: var(--ink);
    border-top: 1px solid rgb(var(--white-rgb) / 0.1);
  }
  .site-nav.active { display: block; }
  .site-nav__list { flex-direction: column; gap: 0; }
  .site-nav a { width: 100%; min-height: 52px; padding: 0 var(--space-2); font-size: 18px; }
  .site-nav a[aria-current="page"] { text-underline-offset: 8px; }
}

/* ---------- Closing CTA band (above the footer, every page) ---------- */
.cta-tn { padding: var(--space-8) 0; background: var(--cool-50); border-top: 4px solid var(--gold); color: var(--ink); }
.cta-tn__inner { display: grid; gap: var(--space-5); align-items: center; }
@media (min-width: 1024px) { .cta-tn__inner { grid-template-columns: 1fr auto; gap: var(--space-8); } }
.cta-tn__title {
  margin: 0;
  font-family: var(--font-head);
  font-weight: var(--weight-head);
  font-size: var(--fs-h2);
  line-height: var(--lh-head);
  letter-spacing: var(--tracking-head);
  text-wrap: balance;
}
.cta-tn__title .kw { color: var(--gold-text); }
.cta-tn__text { margin-top: var(--space-3); max-width: 48ch; font-size: var(--fs-lead); color: var(--text-muted); }
.cta-tn__actions { display: flex; flex-wrap: wrap; gap: var(--space-3); }
.cta-tn .button { min-height: 52px; padding-inline: var(--space-6); font-size: 17px; }
@media (max-width: 639px) { .cta-tn .button { width: 100%; } }

/* ---------- Mobile sticky contact bar ---------- */
.mobile-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: var(--z-mobile-bar);
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: var(--ink);
  padding-bottom: env(safe-area-inset-bottom);
  box-shadow: 0 -4px 16px rgb(var(--shadow-ink-rgb) / 0.18);
}
.mobile-bar a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 56px;
  color: var(--white);
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
}
.mobile-bar a:focus-visible { outline: var(--focus-ring-on-ink); outline-offset: -4px; }
.mobile-bar img, .mobile-bar .material-symbols-rounded { width: 20px; height: 20px; font-size: 20px; }
.mobile-bar__wa { background: var(--whatsapp); }
.mobile-bar__wa:active { background: var(--whatsapp-hover); }
.mobile-bar__call { background: var(--ink); }
.mobile-bar__call:active { background: var(--ink-2); }

@media (max-width: 767px) {
  body { padding-bottom: calc(56px + env(safe-area-inset-bottom)); }
}
@media (min-width: 768px) {
  .mobile-bar { display: none; }
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--ink);
  color: var(--on-ink-muted);
  padding: var(--space-8) 0 var(--space-5);
  font-size: 15px;
}
.site-footer__grid { display: grid; gap: var(--space-6); }
.site-footer__brand p { max-width: 36ch; margin-top: var(--space-4); line-height: 1.55; }
.site-footer__title {
  margin: 0 0 var(--space-2);
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
}
.site-footer ul { margin: 0; padding: 0; list-style: none; }
.site-footer li { line-height: 1.4; }
.site-footer a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap-min);
  color: var(--on-ink-muted);
  text-decoration: none;
}
.site-footer a:hover { color: var(--on-ink); text-decoration: underline; text-underline-offset: 3px; }
.site-footer .brand__logo { height: 60px; }
.site-footer__meta { display: block; padding-block: var(--space-2); }
.site-footer__legal {
  margin-top: var(--space-7);
  padding-top: var(--space-5);
  border-top: 1px solid rgb(var(--white-rgb) / 0.12);
  font-size: 14px;
}
.placeholder-note { color: var(--gold); font-weight: 600; }

@media (min-width: 768px) {
  .site-footer__grid { grid-template-columns: 1.5fr 1fr 1.3fr 1fr; }
}

/* ---------- Shared section scaffolding ---------- */
.kw { color: var(--gold-text); }
.on-ink .kw { color: var(--gold); }
.section-tn { padding: var(--space-8) 0; }
@media (min-width: 1024px) { .section-tn { padding: var(--space-9) 0; } }
.section-tn--alt { background: var(--cool-50); }
.section-title-tn {
  margin: 0;
  font-family: var(--font-head);
  font-weight: var(--weight-head);
  font-size: var(--fs-h2);
  line-height: var(--lh-head);
  letter-spacing: var(--tracking-head);
  color: var(--ink);
  text-wrap: balance;
}
.section-lead-tn { margin-top: var(--space-4); max-width: 60ch; font-size: var(--fs-lead); color: var(--text-muted); }
.placeholder-tag {
  display: inline-block;
  padding: 1px 6px;
  border: 1px dashed currentColor;
  border-radius: 4px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.5;
  color: var(--gold-text);
  white-space: nowrap;
}
.media-tn { margin: 0; overflow: hidden; border-radius: var(--radius); background: var(--cool-50); }
.media-tn img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Gold rule list marker (no generic icons) */
.checklist-tn { display: grid; gap: var(--space-3); margin: var(--space-5) 0 0; padding: 0; list-style: none; }
.checklist-tn li { position: relative; padding-left: 24px; line-height: 1.45; }
.checklist-tn li::before { content: ""; position: absolute; left: 0; top: 0.7em; width: 12px; height: 2px; background: var(--gold); }

/* Native form controls (the template strips appearance) */
.field-tn label { display: block; margin-bottom: 6px; font-size: 14px; font-weight: 600; color: var(--ink); }
.field-tn input, .field-tn select, .field-tn textarea {
  width: 100%;
  min-height: 48px;
  padding: 10px 14px;
  border: 1.5px solid var(--control-border);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  font: 16px/1.4 var(--font-body);
  transition: border-color var(--dur-fast) var(--ease);
}
.field-tn input, .field-tn select { height: var(--control-h); }
.field-tn select { appearance: none; -webkit-appearance: none; padding-block: 0; padding-right: 44px; cursor: pointer; }
.select-tn { position: relative; }
.select-tn::after {             /* chevron; pointer-events off so the native select still gets every click */
  content: "";
  position: absolute;
  top: 50%;
  right: 18px;
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
}
.select-tn:focus-within::after { border-color: var(--gold-text); }
@media (forced-colors: active) { .select-tn::after { border-color: CanvasText; } }
.field-tn textarea { min-height: 104px; resize: vertical; }
.field-tn input::placeholder, .field-tn textarea::placeholder { color: var(--text-muted); opacity: 1; }
.field-tn input:hover, .field-tn select:hover, .field-tn textarea:hover { border-color: var(--ink); }
.field-tn input:focus-visible, .field-tn select:focus-visible, .field-tn textarea:focus-visible { outline: var(--focus-ring); outline-offset: 1px; border-color: var(--ink); }

/* ---------- Home hero: navy full-bleed, brick grid (repeating SVG), retouched house ---------- */
.hero-tn {
  --house-w: 112vw;
  --glow-size: 130vw;
  --glow-r: 40vw;
  --glow-b: calc(var(--house-w) * 0.55);
  position: relative;
  overflow: hidden;
  isolation: isolate;
  padding: var(--space-6) 0 0;
  background: var(--navy);
  color: var(--on-navy);
}
.hero-tn__grid { display: grid; }
.hero-tn__copy { position: relative; padding-bottom: calc(var(--house-w) * 0.78); }
.hero-tn__title {
  margin: 0;
  font-family: var(--font-head);
  font-weight: var(--weight-head);
  font-size: var(--fs-display);
  line-height: var(--lh-tight);
  letter-spacing: var(--tracking-head);
  color: var(--on-navy);
  text-wrap: balance;
}
.hero-tn__title .kw { color: var(--gold); }
.hero-tn__lead { margin-top: var(--space-4); max-width: 40ch; font-size: var(--fs-lead); color: var(--on-navy-muted); }

.hero-tn__art { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
/* The mask stays still and fades the grid out toward the text; the grid inside it moves (parallax).
   The grid overscans 30% above and 10% below the hero so the parallax shift never uncovers an edge. */
.hero-tn__grid-mask {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 55%);
  mask-image: linear-gradient(to bottom, transparent 0%, #000 55%);
}
.hero-tn__grid-bg {
  position: absolute;
  top: -30%;
  bottom: -10%;
  left: 0;
  right: 0;
  /* Brick grid in --brick: the SVG (same geometry as the retired bg-pattern.png) is only the mask */
  background: var(--brick);
  -webkit-mask: url('../images/brick-grid.svg') right top / 210px 840px repeat;
  mask: url('../images/brick-grid.svg') right top / 210px 840px repeat;
}
.hero-tn__house {
  position: absolute;
  z-index: 2;
  right: -16vw;
  bottom: calc(var(--house-w) * -0.085);  /* bleeds off the bottom edge; the sidewalk (bottom 3.3% of the cut-out) stays out of frame */
  width: var(--house-w);
  max-width: none;
  height: auto;
}
/* Very subtle radial glow centred behind the house */
.hero-tn__art::before {
  content: "";
  position: absolute;
  z-index: 1;
  right: calc(var(--glow-r) - var(--glow-size) / 2);
  bottom: calc(var(--glow-b) - var(--glow-size) / 2);
  width: var(--glow-size);
  aspect-ratio: 1;
  background: radial-gradient(closest-side, rgb(var(--hero-glow-rgb) / 0.55), rgb(var(--navy-3-rgb) / 0.28) 50%, rgb(var(--navy-rgb) / 0) 100%);
}

.search-tn {
  display: grid;
  gap: var(--space-4);
  margin-top: var(--space-6);
  padding: var(--space-5);
  background: var(--white);
  color: var(--ink);
  border-radius: var(--radius);
  box-shadow: var(--shadow-float);
}
.search-tn__submit { width: 100%; align-self: end; min-height: var(--control-h); }

/* "Quiero": segmented radio group (native radios, arrow keys work) */
.segmented-field { min-width: 0; margin: 0; padding: 0; border: 0; }
.segmented-field legend { display: block; margin-bottom: 6px; padding: 0; font-size: 14px; font-weight: 600; color: var(--ink); }
.segmented-tn.segmented-tn--search { display: grid; grid-template-columns: 1fr 1fr; width: 100%; }
.segmented-tn--search span { min-width: 0; min-height: calc(var(--control-h) - 3px); padding: 0 12px; font-size: 16px; }

@media (min-width: 640px) {
  .search-tn { grid-template-columns: 1fr 1fr; }
}
/* Compact hero below desktop so the house shows in the first screen: Ubicación and Buscar share a row */
@media (max-width: 1023px) {
  .hero-tn { padding-top: var(--space-5); }
  .hero-tn__title { font-size: 36px; }
  .hero-tn__lead { margin-top: var(--space-3); font-size: 17px; }
  .search-tn { grid-template-columns: 1fr auto; gap: var(--space-3); margin-top: var(--space-5); padding: var(--space-4); }
  .search-tn > .segmented-field, .search-tn > .field-tn--full { grid-column: 1 / -1; }
  .search-tn__submit { width: auto; padding-inline: var(--space-5); }
}
@media (min-width: 1024px) {
  .hero-tn {
    --house-w: min(58vw, 860px);
    /* House anchored to the content box, not the viewport: it overhangs the container's right edge by
       134px (what it did at 1440) and never sits further right than the old 1% bleed on narrow screens */
    --house-right: max(-1%, calc((100% - var(--container)) / 2 - 134px));
    --glow-size: calc(var(--house-w) * 1.5);
    --glow-r: calc(var(--house-w) * 0.5 + var(--house-right));
    --glow-b: calc(var(--house-w) * 0.5);
    display: flex;
    align-items: center;
    min-height: min(calc(100svh - 96px), 840px);   /* capped so tall monitors keep the 1440x900 rhythm under the nav */
    padding: var(--space-8) 0 var(--space-9);
  }
  .hero-tn__grid { width: 100%; }
  .hero-tn__copy { max-width: 640px; padding-bottom: 0; }
  /* The lead stops before the house's left edge (house = --house-right from the right, width --house-w), with a 48px gap */
  .hero-tn__lead {
    max-width: min(40ch, calc(100vw - max(-1vw, (100vw - var(--container)) / 2 - 134px) - var(--house-w) - max(var(--gutter), (100vw - var(--container)) / 2) - var(--space-7)));
  }
  .hero-tn__grid-mask {
    /* fade toward the copy on the left and toward the nav on top; no hard edge anywhere */
    -webkit-mask-image: linear-gradient(to right, transparent 18%, #000 58%), linear-gradient(to bottom, transparent 0%, #000 30%);
    -webkit-mask-composite: source-in;
    mask-image: linear-gradient(to right, transparent 18%, #000 58%), linear-gradient(to bottom, transparent 0%, #000 30%);
    mask-composite: intersect;
  }
  .hero-tn__house { right: var(--house-right); }
}

[data-parallax] { will-change: transform; }

/* ---------- Amenities band: two real panoramas, full bleed ---------- */
.amenities-tn__grid { display: grid; gap: 4px; background: var(--navy); }
@media (min-width: 1024px) { .amenities-tn__grid { grid-template-columns: 1fr 1fr; } }
.amenities-tn__item { position: relative; margin: 0; }
.amenities-tn__media { aspect-ratio: 1563 / 738; overflow: hidden; background: var(--navy-2); }
.amenities-tn__media img { display: block; width: 100%; height: 100%; object-fit: cover; }
.amenities-tn__item figcaption {
  position: absolute;
  left: var(--gutter);
  bottom: var(--space-4);
  padding: 6px 12px;
  border-radius: var(--radius);
  background: rgb(var(--navy-rgb) / 0.82);
  color: var(--on-navy);
  font-size: var(--fs-small);
  font-weight: 600;
}

/* ---------- Nosotros (owners value proposition) ---------- */
.about-tn__grid { display: grid; gap: var(--space-6); align-items: center; }
.about-tn__media { aspect-ratio: 4 / 3; }
.about-tn__copy p { margin-top: var(--space-4); color: var(--text-muted); }
.about-tn__copy .button { margin-top: var(--space-6); }
@media (min-width: 1024px) {
  .about-tn__grid { grid-template-columns: 2fr 1fr; gap: var(--space-7); }
  /* the copy column is a third of the row (photo keeps two thirds): smaller headline so it sets in 2-3 lines */
  .about-tn__copy .section-title-tn { font-size: clamp(28px, 1.6vw + 11px, 34px); }
}

/* ---------- Listing and property cards ---------- */
#property, #owner-form, #nosotros, #acompanamiento { scroll-margin-top: 80px; }
.listing-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: var(--space-3); }
.listing-count { margin: 0; font-size: 15px; color: var(--text-muted); }
.listing-grid { display: grid; gap: var(--space-6) var(--space-5); margin-top: var(--space-6); }
.listing-grid:focus { outline: none; }
@media (min-width: 640px) { .listing-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .listing-grid { grid-template-columns: repeat(3, 1fr); } }

.property-card { position: relative; display: flex; flex-direction: column; }
.property-card[hidden] { display: none; }
.property-card__media {
  display: block;
  margin: 0;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--cool-50);
}
.property-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--dur) var(--ease); }
.property-card { transition: transform var(--dur) var(--ease); }
.property-card__media { transition: box-shadow var(--dur) var(--ease); }
@media (hover: hover) and (pointer: fine) {
  .property-card:hover { transform: translateY(-4px); }
  .property-card:hover .property-card__media { box-shadow: var(--shadow-raise); }
  .property-card:hover .property-card__media img { transform: scale(1.04); }
}
.property-card:active { transform: scale(0.985); transition-duration: var(--dur-fast); }
@media (prefers-reduced-motion: reduce) {
  .property-card:hover, .property-card:active, .property-card:hover .property-card__media img { transform: none; }
}
.property-card__noimg { display: grid; place-items: center; height: 100%; font-size: 14px; color: var(--text-muted); }
.property-card__body { display: grid; gap: var(--space-1); padding-top: var(--space-4); }
.property-card__title { margin: 0; font-family: var(--font-head); font-weight: 700; font-size: 23px; line-height: 1.2; }
.property-card__title a { color: var(--ink); text-decoration: none; }
.property-card__title a::after { content: ""; position: absolute; inset: 0; border-radius: var(--radius); }  /* whole card is the link */
.property-card__title a:focus-visible { outline: none; }
.property-card:focus-within { outline: var(--focus-ring); outline-offset: 6px; border-radius: var(--radius); }
.property-card:hover .property-card__title a { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.property-card__address { font-style: normal; font-size: 15px; line-height: 1.45; color: var(--text-muted); }
.property-card__price { margin: var(--space-2) 0 0; font-size: 20px; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--ink); }
.property-card__price small { font-size: 14px; font-weight: 400; color: var(--text-muted); }
.property-card__meta { display: flex; flex-wrap: wrap; gap: var(--space-4); margin: var(--space-2) 0 0; padding-top: var(--space-3); border-top: 1px solid var(--cool-100); font-size: 15px; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.property-card__meta b { font-weight: 600; color: var(--ink); }

/* Loading skeleton (reserves layout, no spinner) */
.property-card--skeleton .property-card__body span { display: block; height: 14px; border-radius: 4px; background: var(--cool-50); }
.property-card--skeleton .property-card__body span:nth-child(1) { width: 70%; height: 22px; }
.property-card--skeleton .property-card__body span:nth-child(2) { width: 90%; }
.property-card--skeleton .property-card__body span:nth-child(3) { width: 40%; }
@media (prefers-reduced-motion: no-preference) {
  .property-card--skeleton .property-card__media, .property-card--skeleton .property-card__body span { animation: skeleton-pulse 1.4s ease-in-out infinite; }
}
@keyframes skeleton-pulse { 50% { opacity: 0.55; } }

.listing-error { grid-column: 1 / -1; padding: var(--space-5); background: var(--cool-50); border-radius: var(--radius); color: var(--ink); }

/* Empty state */
.empty-tn { margin-top: var(--space-6); padding: var(--space-7) var(--space-5); background: var(--cool-50); border-radius: var(--radius); border-left: 3px solid var(--gold); }
.empty-tn__title { margin: 0; max-width: 28ch; font-family: var(--font-head); font-weight: var(--weight-head); font-size: 28px; line-height: 1.2; }
.empty-tn p { max-width: 56ch; margin-top: var(--space-3); color: var(--text-muted); }
.empty-tn__actions { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-top: var(--space-5); }
.empty-tn__variant { display: none; }
.empty-tn[data-variant="rent"] .empty-tn__variant--rent,
.empty-tn[data-variant="filters"] .empty-tn__variant--filters { display: block; }

/* ---------- Cómo te acompañamos ---------- */
.acomp-tn__grid { position: relative; display: grid; gap: var(--space-7); margin-top: var(--space-7); align-items: center; }
/* Context label shown only while motion.js pins the block (desktop); decorative, the h2 is the real title */
.acomp-tn__pinlabel {
  position: absolute;
  left: 0;
  bottom: calc(100% + var(--space-4));
  margin: 0;
  padding: 6px 12px;
  border-left: 3px solid var(--gold);
  background: var(--cool-50);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease);
  pointer-events: none;
}
.acomp-tn__grid.is-pinned .acomp-tn__pinlabel { opacity: 1; transform: none; }
@media (min-width: 1024px) { .acomp-tn__grid { grid-template-columns: 1.15fr 0.85fr; } }

.steps-tn { position: relative; isolation: isolate; display: grid; gap: var(--space-5); margin: 0; padding: 0; list-style: none; counter-reset: step; }
/* Rail behind the step numbers; the gold part grows with scroll (motion.js sets --progress) */
.steps-tn::before, .steps-tn::after { content: ""; position: absolute; z-index: -1; left: 18px; top: 19px; bottom: 19px; width: 2px; }  /* behind the numbers even when a step gets its own stacking context */
.steps-tn::before { background: var(--cool-100); }
.steps-tn::after { background: var(--gold); transform-origin: top; transform: scaleY(var(--progress, 1)); }
.steps-tn li > * { transition: opacity var(--dur) var(--ease); }
.steps-tn.is-scrolly li:not(.is-active) > * { opacity: 0.38; }
.steps-tn.is-scrolly li:not(.is-active)::before { border-color: var(--cool-100); color: var(--text-muted); }
.steps-tn li { position: relative; padding-left: 56px; counter-increment: step; }
.steps-tn li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  z-index: 1;
  border: 1.5px solid var(--gold);
  border-radius: 50%;
  background: var(--white);
  font-family: var(--font-head);
  font-size: 19px;
  color: var(--ink);
  transition: border-color var(--dur) var(--ease), color var(--dur) var(--ease);
}
.steps-tn h3 { margin: 4px 0 0; font-family: var(--font-head); font-weight: 700; font-size: var(--fs-h3); line-height: 1.25; }
.steps-tn p { margin-top: var(--space-1); color: var(--text-muted); max-width: 46ch; }

.video-tn { position: relative; margin: 0; aspect-ratio: 4 / 5; overflow: hidden; border-radius: var(--radius); background: var(--ink); }
.video-tn video { width: 100%; height: 100%; object-fit: cover; display: block; }
.video-tn__play {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  place-items: center;
  width: 72px;
  height: 72px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: var(--ink);
  color: var(--white);
  box-shadow: 0 0 0 6px rgb(var(--shadow-ink-rgb) / 0.25);
  transition: background-color var(--dur-fast) var(--ease), transform var(--dur-fast) var(--ease);
}
.video-tn__play .material-symbols-rounded { font-size: 40px; }
.video-tn__play:hover { background: var(--ink-2); }
.video-tn__play:active { transform: translate(-50%, -50%) scale(0.96); }
.video-tn__play:focus-visible { outline: var(--focus-ring-on-ink); outline-offset: 4px; }
.video-tn.playing .video-tn__play { display: none; }

.acomp-tn__extras { display: grid; gap: var(--space-6); margin-top: var(--space-8); padding-top: var(--space-6); border-top: 1px solid var(--cool-100); }
@media (min-width: 768px) { .acomp-tn__extras { grid-template-columns: 1fr 1fr; gap: var(--space-7); } }
.acomp-tn__subtitle { margin: 0 0 var(--space-3); font-family: var(--font-head); font-weight: 700; font-size: var(--fs-h3); }
.acomp-tn__extras p { color: var(--text-muted); max-width: 52ch; }
.chips-tn { display: flex; flex-wrap: wrap; gap: var(--space-2); margin: 0; padding: 0; list-style: none; }
.chips-tn li { padding: 8px 14px; border: 1px solid var(--control-border); border-radius: var(--radius-pill); font-size: 15px; font-weight: 600; color: var(--ink); background: var(--white); }

/* ---------- Desarrollos con los que trabajamos (names as text, no figures) ---------- */
.devs-tn { display: grid; gap: var(--space-6); align-items: center; }
@media (min-width: 1024px) { .devs-tn { grid-template-columns: 1fr 1fr; } }
/* Developer names as type (until the owner has their logos): navy band, large names in rows with a gold index */
.section-tn--navy { background: var(--navy); color: var(--on-navy); }
.section-tn--navy .section-title-tn { color: var(--on-navy); }
.section-tn--navy .section-title-tn .kw { color: var(--gold); }
.section-tn--navy .section-lead-tn { color: var(--on-navy-muted); }
.devs-tn__list { display: grid; margin: 0; padding: 0; list-style: none; counter-reset: dev; }
.devs-tn__list li {
  counter-increment: dev;
  display: flex;
  align-items: baseline;
  gap: var(--space-5);
  padding: var(--space-5) 0;
  border-top: 1px solid rgb(var(--white-rgb) / 0.16);
  font-family: var(--font-head);
  font-size: clamp(40px, 3.4vw + 12px, 72px);
  font-weight: var(--weight-head);
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--on-navy);
}
.devs-tn__list li:last-child { border-bottom: 1px solid rgb(var(--white-rgb) / 0.16); }
.devs-tn__list li::before {
  content: counter(dev, decimal-leading-zero);
  flex: none;
  min-width: 2.2em;           /* names align whatever the digits */
  font-variant-numeric: tabular-nums;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--gold);
}

/* ---------- Lead forms (owner form, visit form) ---------- */
.owner-tn { display: grid; gap: var(--space-7); align-items: start; }
@media (min-width: 1024px) { .owner-tn { grid-template-columns: 0.9fr 1.1fr; gap: var(--space-8); } }
.owner-tn__next-title { margin: var(--space-6) 0 var(--space-3); font-family: var(--font-head); font-weight: 700; font-size: var(--fs-h3); }
.owner-tn__next { display: grid; gap: var(--space-3); margin: 0; padding-left: 22px; color: var(--ink); }
.owner-tn__next li::marker { color: var(--gold-text); font-weight: 600; }
.owner-tn__alt { margin-top: var(--space-6); color: var(--text-muted); }
.owner-tn__alt a, .check-tn a, .form-status-link { color: var(--gold-text); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }

.form-tn { display: grid; gap: var(--space-5); padding: var(--space-5); background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow-raise); }
@media (min-width: 768px) { .form-tn { padding: var(--space-6); } }
.form-tn__two { display: grid; gap: var(--space-5); }
@media (min-width: 640px) { .form-tn__two { grid-template-columns: 1fr 1fr; } }
.form-tn__submit { width: 100%; }
@media (min-width: 640px) { .form-tn__submit { width: auto; justify-self: start; min-width: 200px; } }
.form-tn__actions { display: flex; flex-wrap: wrap; gap: var(--space-3); }

.form-tn__fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
.form-tn__legend { margin-bottom: 6px; padding: 0; font-size: 14px; font-weight: 600; color: var(--ink); }
.segmented-tn { display: inline-grid; grid-auto-flow: column; gap: 0; border: 1.5px solid var(--control-border); border-radius: var(--radius); overflow: hidden; }
.segmented-tn label { position: relative; margin: 0; font-size: inherit; cursor: pointer; }  /* reset .field-tn label when nested */
.segmented-tn input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; min-height: 0; margin: 0; padding: 0; cursor: pointer; }
.segmented-tn span { display: flex; align-items: center; justify-content: center; min-width: 112px; min-height: 46px; padding: 0 20px; font-weight: 600; color: var(--ink); transition: background-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease), transform var(--dur-fast) var(--ease); }
.segmented-tn label:active span { transform: scale(0.97); }
.segmented-tn label + label span { border-left: 1.5px solid var(--control-border); }
.segmented-tn input:checked + span { background: var(--ink); color: var(--white); }
.segmented-tn input:focus-visible + span { outline: var(--focus-ring); outline-offset: -4px; }

.field-tn__optional { font-weight: 400; color: var(--text-muted); }
.field-tn__help { margin-top: 6px; font-size: 14px; color: var(--text-muted); }
.phone-tn { display: grid; grid-template-columns: auto 1fr; }
.phone-tn__prefix { display: flex; align-items: center; padding: 0 12px; border: 1.5px solid var(--control-border); border-right: 0; border-radius: var(--radius) 0 0 var(--radius); background: var(--cool-50); font-weight: 600; color: var(--ink); }
.phone-tn input { border-radius: 0 var(--radius) var(--radius) 0; }

.check-tn { display: grid; grid-template-columns: auto 1fr; gap: var(--space-3); align-items: start; font-size: 15px; line-height: 1.5; color: var(--ink); cursor: pointer; }
.check-tn input { width: 22px; height: 22px; margin: 1px 0 0; accent-color: var(--ink); cursor: pointer; }

/* Submission status (success / error), shared with the hotfix markup */
.form-status[hidden] { display: none; }
.form-status { margin: 0; padding: 14px 16px; border-left: 3px solid var(--gold); border-radius: 0 var(--radius) var(--radius) 0; background: var(--cool-50); font-size: 16px; line-height: 1.5; color: var(--ink); }
.form-status.is-error { border-left-color: var(--error); }
.form-status p { margin: 0; }
.form-status-link { display: inline-block; margin-top: 6px; }
.form-status-link:hover, .owner-tn__alt a:hover, .check-tn a:hover { color: var(--ink); }
.owner-tn__next li { list-style: decimal; padding-left: 4px; }

/* ---------- Property detail ---------- */
#visit-form { scroll-margin-top: 80px; }
.detail-tn { padding: var(--space-5) 0 var(--space-8); }
.back-tn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  min-height: var(--tap-min);
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
}
.back-tn:hover { text-decoration: underline; text-underline-offset: 3px; }
.back-tn .material-symbols-rounded { font-size: 20px; }

.gallery-tn { display: grid; gap: var(--space-3); margin-top: var(--space-3); }
.gallery-tn__main { position: relative; display: block; width: 100%; padding: 0; border: 0; border-radius: var(--radius); overflow: hidden; cursor: zoom-in; background: var(--cool-50); aspect-ratio: 16 / 10; }
.gallery-tn__main img, .gallery-tn__tile img { width: 100%; height: 100%; object-fit: cover; transition: transform 300ms var(--ease); }
.gallery-tn__count {
  position: absolute;
  right: var(--space-3);
  bottom: var(--space-3);
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  background: rgb(var(--navy-rgb) / 0.82);
  color: var(--on-navy);
  font-size: var(--fs-small);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.gallery-tn__side { display: none; }
.gallery-tn__tile { position: relative; display: block; width: 100%; padding: 0; border: 0; overflow: hidden; border-radius: var(--radius); background: var(--cool-50); cursor: zoom-in; }
.gallery-tn__more {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgb(var(--navy-rgb) / 0.62);
  color: var(--on-navy);
  font-weight: 700;
}
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .gallery-tn__main:hover img, .gallery-tn__tile:hover img { transform: scale(1.03); }
}
@media (min-width: 1024px) {
  /* Mosaic: main photo + two stacked tiles; the thumbs row stays for the full set */
  .gallery-tn { grid-template-columns: 2fr 1fr; }
  .gallery-tn__main { aspect-ratio: auto; height: clamp(360px, 38vw, 540px); }
  .gallery-tn__side { display: grid; grid-template-rows: 1fr 1fr; gap: var(--space-3); height: clamp(360px, 38vw, 540px); }
  .gallery-tn__side:empty { display: none; }
  .gallery-tn__thumbs { grid-column: 1 / -1; }
  .gallery-tn:has(.gallery-tn__tile) .gallery-tn__thumbs { display: none; }  /* the mosaic + lightbox cover every photo */
  .gallery-tn__count { display: none; }
}
.gallery-tn__thumbs { display: flex; gap: var(--space-2); overflow-x: auto; padding-bottom: var(--space-1); scroll-snap-type: x mandatory; }
.gallery-tn__thumb { flex: 0 0 auto; width: 112px; aspect-ratio: 4 / 3; padding: 0; border: 0; border-radius: var(--radius); overflow: hidden; cursor: zoom-in; scroll-snap-align: start; background: var(--cool-50); }
.gallery-tn__thumb img { width: 100%; height: 100%; object-fit: cover; transition: opacity var(--dur-fast) var(--ease); }
.gallery-tn__thumb:hover img { opacity: 0.85; }
@media (min-width: 768px) { .gallery-tn__thumb { width: 140px; } }

.detail-tn__layout { display: grid; gap: var(--space-7); margin-top: var(--space-6); align-items: start; }
@media (min-width: 1024px) { .detail-tn__layout { grid-template-columns: minmax(0, 1fr) 360px; gap: var(--space-8); } }

.detail-tn__chips { display: flex; flex-wrap: wrap; gap: var(--space-2); margin: 0; }
.chip-tn { display: inline-flex; align-items: center; min-height: 30px; padding: 0 12px; border: 1px solid var(--control-border); border-radius: var(--radius-pill); font-size: 14px; font-weight: 600; color: var(--ink); }
.chip-tn[hidden] { display: none; }
.chip-tn--status { border-color: var(--ink); background: var(--ink); color: var(--white); }
.detail-tn__title { margin: var(--space-4) 0 0; font-family: var(--font-head); font-weight: var(--weight-head); font-size: var(--fs-h2); line-height: 1.15; letter-spacing: -0.01em; }
.detail-tn__address { margin-top: var(--space-2); font-style: normal; color: var(--text-muted); }

.facts-tn { display: flex; flex-wrap: wrap; gap: var(--space-6); margin: var(--space-6) 0 0; padding: var(--space-5) 0; border-block: 1px solid var(--cool-100); }
.facts-tn div[hidden] { display: none; }
.facts-tn dt { font-size: 14px; color: var(--text-muted); }
.facts-tn dd { margin: 2px 0 0; font-family: var(--font-head); font-size: 28px; font-weight: 700; line-height: 1.1; letter-spacing: var(--tracking-head); font-variant-numeric: tabular-nums; }

.detail-tn__block { margin-top: var(--space-7); }
.detail-tn__h2 { margin: 0 0 var(--space-3); font-family: var(--font-head); font-weight: 700; font-size: var(--fs-h3); }
.detail-tn__desc { max-width: 68ch; white-space: pre-line; }
.detail-tn__delivery { margin-top: var(--space-3); font-weight: 600; }
.checklist-tn--cols { margin-top: 0; }
@media (min-width: 768px) { .checklist-tn--cols { grid-template-columns: 1fr 1fr; column-gap: var(--space-6); } }
.detail-tn__nearby { margin: 0 0 var(--space-4); padding-left: 20px; color: var(--text-muted); }
.detail-tn__nearby li { list-style: disc; }

.map-tn { position: relative; aspect-ratio: 16 / 10; overflow: hidden; border-radius: var(--radius); background: var(--cool-50); }
.map-tn iframe { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; border: 0; display: block; opacity: 0; transition: opacity var(--dur) var(--ease); }
.map-tn.is-loaded iframe { opacity: 1; }
.map-tn__fallback {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-5);
  text-align: center;
  border: 1px solid var(--cool-100);
  border-radius: var(--radius);
  background: var(--cool-50);
}
.map-tn__fallback .material-symbols-rounded { font-size: 36px; color: var(--gold-text); }
.map-tn__place { max-width: 36ch; font-weight: 700; color: var(--ink); }
.map-tn__hint { font-size: var(--fs-small); color: var(--text-muted); }
.map-tn__link { margin-top: var(--space-4); }
.map-tn__link[hidden] { display: none; }

.contact-card-tn { display: grid; gap: var(--space-3); padding: var(--space-5); border: 1px solid var(--cool-100); border-top: 4px solid var(--gold); border-radius: var(--radius); background: var(--white); box-shadow: var(--shadow-raise); }
@media (min-width: 1024px) { .contact-card-tn { position: sticky; top: 96px; } }
.contact-card-tn__label { margin: 0; font-size: 13px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--gold-text); }
.contact-card-tn__price { margin: 0 0 var(--space-2); font-family: var(--font-head); font-size: 32px; font-weight: var(--weight-head); line-height: 1.1; letter-spacing: var(--tracking-head); font-variant-numeric: tabular-nums; }
.contact-card-tn .button { width: 100%; }
.contact-card-tn__note { margin: var(--space-2) 0 0; font-size: 14px; color: var(--text-muted); }

/* Unavailable / load-error state */
.unavailable-tn { max-width: 640px; margin: var(--space-7) 0 var(--space-6); padding: var(--space-7) var(--space-6); border-left: 3px solid var(--gold); border-radius: var(--radius); background: var(--cool-50); }
.unavailable-tn[hidden] { display: none; }
.unavailable-tn__icon { font-size: 40px; color: var(--ink); }
.unavailable-tn__title { margin: var(--space-3) 0 0; font-family: var(--font-head); font-weight: var(--weight-head); font-size: var(--fs-h2); line-height: 1.15; }
.unavailable-tn__text { margin-top: var(--space-3); color: var(--text-muted); }
.unavailable-tn__actions { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-top: var(--space-5); }

/* Lightbox (ink overlay; photo overlays are an allowed use of ink) */
.lightbox-tn { position: fixed; inset: 0; z-index: var(--z-overlay); display: grid; place-items: center; padding: var(--space-8) var(--space-4); }
.lightbox-tn[hidden] { display: none; }
.lightbox-tn__backdrop { position: absolute; inset: 0; background: rgb(var(--navy-rgb) / 0.94); }
@media (prefers-reduced-motion: no-preference) {
  .lightbox-tn:not([hidden]) .lightbox-tn__backdrop { animation: lb-fade var(--dur) var(--ease); }
  .lightbox-tn:not([hidden]) .lightbox-tn__content { animation: lb-rise 320ms var(--ease); }
}
@keyframes lb-fade { from { opacity: 0; } }
@keyframes lb-rise { from { opacity: 0; transform: translateY(12px) scale(0.98); } }
.lightbox-tn__content { position: relative; margin: 0; max-width: min(1200px, 100%); text-align: center; }
.lightbox-tn__content img { max-width: 100%; max-height: 78vh; border-radius: var(--radius); touch-action: pan-y pinch-zoom; user-select: none; -webkit-user-drag: none; }  /* horizontal swipes go to property.js */
.lightbox-tn__caption { margin-top: var(--space-3); color: var(--on-ink-muted); font-size: 14px; font-variant-numeric: tabular-nums; }
.lightbox-tn__btn { position: absolute; z-index: 1; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: var(--ink); color: var(--white); border: 1px solid rgb(var(--white-rgb) / 0.25); }
.lightbox-tn__btn { transition: background-color var(--dur-fast) var(--ease), scale var(--dur-fast) var(--ease); }
.lightbox-tn__btn:hover { background: var(--ink-2); }
.lightbox-tn__btn:active { scale: 0.94; }  /* individual property: keeps the translateY centring of prev/next */
.lightbox-tn__btn:focus-visible { outline: var(--focus-ring-on-ink); outline-offset: 3px; }
.lightbox-tn__btn .material-symbols-rounded { font-size: 28px; }
.lightbox-tn__close { top: var(--space-4); right: var(--space-4); }
.lightbox-tn__prev { left: var(--space-4); top: 50%; transform: translateY(-50%); }
.lightbox-tn__next { right: var(--space-4); top: 50%; transform: translateY(-50%); }
@media (max-width: 767px) {
  .lightbox-tn__prev, .lightbox-tn__next { top: auto; bottom: var(--space-5); transform: none; }
}
.gallery-tn__thumbs { scrollbar-width: thin; scrollbar-color: var(--control-border) transparent; }
.gallery-tn__thumbs::-webkit-scrollbar { height: 6px; }
.gallery-tn__thumbs::-webkit-scrollbar-track { background: transparent; }
.gallery-tn__thumbs::-webkit-scrollbar-thumb { background: var(--control-border); border-radius: 3px; }

/* ---------- Legal pages ---------- */
.legal-tn { padding: var(--space-7) 0 var(--space-9); }
.legal-tn__inner { max-width: calc(760px + 2 * var(--gutter)); }
.legal-tn__title { margin: 0; font-family: var(--font-head); font-weight: var(--weight-head); font-size: var(--fs-h2); line-height: 1.15; }
.legal-tn__updated { margin-top: var(--space-2); color: var(--text-muted); font-size: 15px; }
.legal-tn h2 { margin: var(--space-7) 0 var(--space-3); font-family: var(--font-head); font-weight: 700; font-size: var(--fs-h3); line-height: 1.25; scroll-margin-top: 88px; }
.legal-tn p, .legal-tn ul { max-width: 68ch; margin-top: var(--space-3); }
.legal-tn ul { padding-left: 22px; }
.legal-tn li { list-style: disc; margin-top: var(--space-2); }
.legal-tn a { color: var(--gold-text); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.legal-tn a:hover { color: var(--ink); }

/* ---------- 404 ---------- */
.notfound-tn { padding: var(--space-9) 0; }
.notfound-tn__inner { max-width: calc(720px + 2 * var(--gutter)); }
.notfound-tn__mark { width: 48px; height: auto; }
.notfound-tn__title { margin: var(--space-5) 0 0; font-family: var(--font-head); font-weight: var(--weight-head); font-size: var(--fs-display); line-height: 1.05; letter-spacing: var(--tracking-head); }
.notfound-tn__text { max-width: 52ch; margin-top: var(--space-4); font-size: var(--fs-lead); color: var(--text-muted); }
.notfound-tn__actions { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-top: var(--space-6); }
.site-footer a { min-width: var(--tap-min); }  /* short labels ("Inicio") still get a 44px target */

/* Mobile detail: price + "Agenda una visita" right after the title and key facts, not after the map */
@media (max-width: 1023px) {
  .detail-tn__layout { display: flex; flex-direction: column; gap: 0; }
  .detail-tn__main { display: contents; }
  .detail-tn__head { order: 1; }
  .facts-tn { order: 2; }
  .detail-tn__aside { order: 3; margin-top: var(--space-6); }
  .detail-tn__block { order: 4; }
}

/* ---------- High contrast (prefers-contrast: more): stronger borders and text, solid header ---------- */
@media (prefers-contrast: more) {
  :root {
    --control-border: var(--navy);
    --cool-100: var(--hc-cool-100);
    --text-muted: var(--hc-text-muted);
    --on-navy-muted: var(--hc-on-navy-muted);
  }
  .site-header, .site-header.active {
    background: var(--navy);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    box-shadow: 0 2px 0 var(--gold);
  }
  .site-nav a { color: var(--on-navy); }
  .field-tn input, .field-tn select, .field-tn textarea, .segmented-tn, .button--secondary, .phone-tn__prefix { border-width: 2px; }
  .segmented-tn label + label span { border-left-width: 2px; }
  .search-tn, .contact-card-tn, .form-tn, .map-tn__fallback { outline: 2px solid var(--navy); outline-offset: -2px; }
  .property-card__media, .gallery-tn__main, .gallery-tn__tile { outline: 1px solid var(--navy); outline-offset: -1px; }
  .button--on-ink { border-color: var(--on-navy); }
  .amenities-tn__item figcaption, .gallery-tn__count { background: var(--navy); }
}
