/* ==========================================================================
   Public site design (2030): loaded last on every public page, never in the admin area.
   One layer on top of styles.css / admin.css / the page stylesheets, so the whole look can be
   switched off by removing its <link> tags. Brand: Monte (forest green) sobre Hueso (bone), gold.
   Order: tokens → header → buttons → cards → forms → page banners → chips and labels → listing
   cards → property page → map page → agents → contact / about / legal → footer.
   ========================================================================== */
:root {
  --site-bg: #ece7dd;
  --site-surface: #ffffff;
  --site-line: #d6d0c3;
  --site-chip: #f4f0e8;
  --site-field: #f7f4ee;
  --site-deep: #232d27;
  --site-radius: 20px;
  --site-shadow-sm: 0 1px 2px rgba(35, 45, 39, 0.06), 0 4px 14px rgba(35, 45, 39, 0.06);
  --site-shadow-lg: 0 2px 6px rgba(35, 45, 39, 0.08), 0 24px 60px rgba(35, 45, 39, 0.18);
}

body {
  background: var(--site-bg);
}

/* ---------- Header: pill links, gold sign-in ---------- */
.site-header {
  background: var(--color-ink);
}
.site-header .nav-links {
  gap: 4px;
}
.site-header .nav-links a {
  padding: 8px 14px;
  border: 0;
  border-radius: 999px;
  color: rgba(236, 231, 221, 0.8);
  transition: background 160ms ease, color 160ms ease;
}
.site-header .nav-links a:hover {
  color: var(--color-white);
  background: rgba(255, 255, 255, 0.08);
}
.site-header .nav-links a[aria-current='page'] {
  color: var(--color-white);
  background: rgba(255, 255, 255, 0.12);
}
.site-header #profile-mount .btn-outline {
  white-space: nowrap;
  border: 0;
  border-radius: 999px;
  background: var(--color-gold);
  color: var(--site-deep);
  font-weight: 700;
  padding: 8px 18px;
}
.site-header #profile-mount .btn-outline:hover {
  background: var(--color-gold-soft);
}
@media (max-width: 600px) {
  .site-header #profile-mount .btn-outline {
    padding: 6px 12px;
    font-size: 0.8rem;
    min-height: 34px;
  }
}
@media (max-width: 1300px) {
  .site-header .nav-links {
    gap: var(--space-2);
  }
  .site-header .nav-links a {
    display: block;
    padding: 12px 16px;
  }
}

/* ---------- Buttons: pills ---------- */
.btn {
  border-radius: 999px;
}
.btn-primary {
  color: var(--site-deep);
  font-weight: 700;
}
.btn-ghost {
  background: var(--site-surface);
  border-color: var(--site-line);
}
.btn-ghost:hover {
  background: var(--site-surface);
  border-color: var(--color-ink);
}

/* ---------- Cards: white, rounded, a soft shadow instead of a border ---------- */
.info-card,
.benefit-card,
.directory-reason-card,
.agent-stat-card,
.agent-sold-card,
.founder-card,
.value-card,
.legal-page .legal-section,
main .admin-card {
  background: var(--site-surface);
  border: 0;
  border-radius: var(--site-radius);
  box-shadow: var(--site-shadow-sm);
}
.info-card h3,
.info-card h2 {
  font-weight: 700;
}

/* ---------- Forms: soft fields with a gold focus ring ---------- */
main .field input,
main .field select,
main .field textarea {
  background: var(--site-field);
  border: 1px solid var(--site-line);
  border-radius: 14px;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}
main .field input:focus,
main .field select:focus,
main .field textarea:focus {
  border-color: var(--color-gold);
  box-shadow: 0 0 0 3px rgba(201, 162, 39, 0.25);
  outline: none;
}

/* ---------- Page banners (map, agents, attractions, contact, about) ---------- */
.map-page-header,
.contact-hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(90% 140% at 100% 0%, rgba(201, 162, 39, 0.22) 0%, rgba(201, 162, 39, 0) 55%),
    var(--color-ink);
  padding: clamp(36px, 6vw, 64px) 0 clamp(30px, 5vw, 48px);
}
.map-page-header h1,
.contact-hero h1 {
  font-size: clamp(1.9rem, 3.6vw, 2.8rem);
  font-weight: 600;
  line-height: 1.08;
  color: var(--color-white);
}
.map-page-header p,
.contact-hero p {
  color: rgba(236, 231, 221, 0.82);
}

/* ---------- Chips and quiet labels ---------- */
.province-chip,
.canton-chip,
.category-chip {
  border-radius: 999px;
}
.map-page-header .province-chip {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.22);
  color: var(--color-white);
}
.map-page-header .province-chip:hover {
  background: rgba(255, 255, 255, 0.18);
}
.map-page-header .province-chip[aria-pressed='true'] {
  background: var(--color-gold);
  border-color: var(--color-gold);
  color: var(--site-deep);
}
/* Status labels on public cards whisper: sentence case, small, on a light pill. */
.property-card .badge,
.result-card .badge,
.gallery-wrap .badge,
.property-top .badge {
  letter-spacing: 0;
  text-transform: none;
  font-weight: 600;
  font-size: 0.72rem;
  padding: 3px 10px;
}

/* ---------- Listing cards (similar homes, favorites, agent listings) ---------- */
.property-card {
  border: 0;
  border-radius: var(--site-radius);
  box-shadow: var(--site-shadow-sm);
  transition: transform 260ms cubic-bezier(0.2, 0.7, 0.2, 1), box-shadow 260ms ease;
}
.property-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--site-shadow-lg);
}
.property-card .property-price,
.result-card .property-price {
  font-family: var(--font-body);
  font-weight: 800;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}
/* The record code (PROP88) is for agents, not buyers: off the public cards. */
.property-card .result-global-id,
.result-card .result-global-id {
  display: none;
}

/* ---------- Property page ---------- */
.breadcrumb {
  font-size: 0.85rem;
}
.gallery-hero-grid {
  border-radius: 24px;
  overflow: hidden;
}
.property-top h1 {
  font-size: clamp(1.6rem, 3vw, 2.3rem);
  font-weight: 600;
  line-height: 1.1;
}
.property-top .property-price {
  font-family: var(--font-body);
  font-size: clamp(1.7rem, 2.6vw, 2.1rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}
.property-ids {
  color: var(--color-text-muted);
  font-size: 0.78rem;
}
/* Key facts as a row of tiles (rooms, baths, parking, m², type). */
.spec-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 0;
  padding: 0;
  margin: var(--space-4) 0 var(--space-5);
  border: 0;
  border-radius: 18px;
  background: var(--site-surface);
  box-shadow: var(--site-shadow-sm);
  overflow: hidden;
}
.spec-strip .spec {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  min-width: 0;
  padding: 14px 18px;
  font-weight: 700;
  font-size: 0.98rem;
  color: var(--color-ink);
  overflow-wrap: anywhere;
}
.spec-strip .spec + .spec {
  box-shadow: inset 1px 0 0 var(--site-line);
}
.spec-strip .spec svg {
  width: 18px;
  height: 18px;
  color: var(--color-gold);
}
.detail-layout {
  gap: clamp(24px, 3.5vw, 44px);
}
.detail-layout h2 {
  font-weight: 600;
  font-size: 1.3rem;
}
/* "What it offers" as a grid of tiles with gold icons. */
.amenity-tags {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 10px;
}
.amenity-tag {
  justify-content: flex-start;
  gap: 10px;
  min-width: 0;
  padding: 12px 14px;
  border-radius: 14px;
  background: var(--site-surface);
  border: 1px solid var(--site-line);
  font-size: 0.9rem;
  font-weight: 500;
}
.amenity-tag svg {
  color: var(--color-gold);
  flex: none;
}
.booking-day.is-selected,
.booking-time.is-selected {
  background: var(--color-ink);
  border-color: var(--color-ink);
  color: var(--color-white);
}
.contact-quick-btn {
  border-radius: 999px;
}
.favorite-btn {
  background: var(--site-surface);
  box-shadow: var(--site-shadow-sm);
}
.investor-calc input {
  border-radius: 12px;
  background: var(--site-field);
}
#property-mini-map {
  border-radius: 16px;
  overflow: hidden;
}
.related-links a {
  border-radius: 999px;
}

/* ---------- Property page: the listing's team on the contact card ----------
   property.html contactTeamHTML: the publishing agent's bubble in front (gold ring), the
   collaborating agents' bubbles tucked behind it. Hovering or focusing the stack fans it open and
   names each agent; every bubble opens that agent's profile. Sizes in rem so they grow with the
   phone's text size; the stack never shrinks the name beside it (min-width: 0 on the text). */
.contact-owner--team {
  flex-wrap: wrap;
  gap: 10px 14px;
  margin-bottom: var(--space-3);
}
/* Beside the bubbles while there's room; below them on a narrow screen or with large text. */
.contact-owner--team .contact-owner-text {
  flex: 1 1 8rem;
}
.agent-stack {
  display: flex;
  align-items: center;
  flex: none;
  padding: 3px 0 3px 3px;
}
.agent-bubble {
  --bubble: 2.75rem;
  position: relative;
  display: inline-grid;
  place-items: center;
  width: var(--bubble);
  height: var(--bubble);
  margin-left: calc(var(--bubble) * -0.3);
  border-radius: 50%;
  background: linear-gradient(140deg, var(--color-ink) 0%, #4c6a55 55%, var(--color-gold) 140%);
  box-shadow: 0 0 0 3px var(--site-surface), 0 6px 16px -6px rgba(35, 45, 39, 0.45);
  color: var(--site-bg);
  text-decoration: none;
  transition: margin 380ms cubic-bezier(0.22, 1.2, 0.36, 1), transform 220ms ease, box-shadow 220ms ease;
}
.agent-bubble:first-child { margin-left: 0; }
/* The publisher sits on top; each collaborator a step further back. */
.agent-bubble:nth-child(1) { z-index: 5; }
.agent-bubble:nth-child(2) { z-index: 4; }
.agent-bubble:nth-child(3) { z-index: 3; }
.agent-bubble:nth-child(4) { z-index: 2; }
.agent-bubble:nth-child(n + 5) { z-index: 1; }
/* Pinned to the bubble: a grid cell gives a percentage height nothing to resolve against. */
.agent-bubble img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  border-radius: 50%;
  object-fit: cover;
}
.agent-bubble-initials {
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}
/* The publishing agent: a little larger, with a gold ring between the photo and the card. */
.agent-bubble.is-lead {
  --bubble: 3.25rem;
  box-shadow: 0 0 0 2px var(--site-surface), 0 0 0 4px var(--color-gold), 0 10px 22px -8px rgba(35, 45, 39, 0.5);
}
.agent-bubble--more {
  background: var(--site-chip);
  color: var(--color-ink);
  font-size: 0.8rem;
  font-weight: 700;
}
/* Fan the stack open on hover / keyboard focus so each face is seen whole. */
.agent-stack:hover .agent-bubble:not(:first-child),
.agent-stack:focus-within .agent-bubble:not(:first-child) {
  margin-left: 6px;
}
a.agent-bubble:hover,
a.agent-bubble:focus-visible {
  transform: translateY(-3px);
  z-index: 6;
  outline: none;
  box-shadow: 0 0 0 3px var(--site-surface), 0 0 0 5px var(--color-gold), 0 14px 26px -10px rgba(35, 45, 39, 0.55);
}
/* The name in a small glass pill above the bubble (the link itself carries the spoken name). */
.agent-bubble-tip {
  position: absolute;
  bottom: calc(100% + 10px);
  left: 50%;
  transform: translate(-50%, 4px);
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(35, 45, 39, 0.88);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: var(--color-white);
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition: opacity 160ms ease, transform 160ms ease;
}
/* "+N" names every folded collaborator: a wrapping pill, never wider than a phone allows. */
.agent-bubble--more .agent-bubble-tip {
  width: max-content;
  max-width: min(240px, 70vw);
  white-space: normal;
  text-align: center;
  border-radius: 12px;
}
.agent-bubble--more:focus-visible {
  outline: 2px solid var(--color-gold);
  outline-offset: 2px;
}
.agent-bubble:hover .agent-bubble-tip,
.agent-bubble:focus-visible .agent-bubble-tip {
  opacity: 1;
  transform: translate(-50%, 0);
}
.contact-team-line {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 0 0 var(--space-2);
  padding: 10px 12px;
  border-radius: 14px;
  background: var(--site-chip);
  color: var(--color-text-muted);
  font-size: 0.86rem;
  line-height: 1.4;
}
.contact-team-line svg {
  flex: none;
  width: 1.1em;
  height: 1.1em;
  margin-top: 0.12em;
  color: var(--color-gold);
}
.contact-team-line span { min-width: 0; overflow-wrap: anywhere; }
.contact-team-line a {
  color: var(--color-ink);
  font-weight: 600;
  text-decoration: none;
}
.contact-team-line a:hover,
.contact-team-line a:focus-visible {
  color: var(--color-gold);
  text-decoration: underline;
}
/* The agent's card (property.html initAgentPeek): opened by a bubble or a collaborator's name. */
.agent-peek {
  position: fixed;
  /* Above the cookie bar (styles.css, 2000): the visitor just opened it. */
  z-index: 2100;
  width: min(340px, calc(100vw - 32px));
  max-height: min(70vh, 480px);
  max-height: min(70dvh, 480px);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 20px;
  border-radius: var(--site-radius);
  background: var(--site-surface);
  border: 1px solid var(--site-line);
  box-shadow: var(--site-shadow-lg);
  opacity: 0;
  transform: translateY(6px) scale(0.98);
  transform-origin: top center;
  transition: opacity 180ms ease, transform 220ms cubic-bezier(0.22, 1.2, 0.36, 1);
}
.agent-peek.is-open {
  opacity: 1;
  transform: none;
}
.agent-peek-close {
  position: absolute;
  top: 10px;
  right: 10px;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--site-chip);
  color: var(--color-ink);
  cursor: pointer;
}
.agent-peek-close svg { width: 14px; height: 14px; }
.agent-peek-close:hover,
.agent-peek-close:focus-visible { background: var(--site-line); outline: none; }
.agent-peek-head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-right: 36px;
}
.agent-peek-photo {
  position: relative;
  flex: none;
  display: inline-grid;
  place-items: center;
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  background: linear-gradient(140deg, var(--color-ink) 0%, #4c6a55 55%, var(--color-gold) 140%);
  color: var(--site-bg);
  box-shadow: 0 0 0 2px var(--site-surface), 0 0 0 4px var(--color-gold);
}
.agent-peek-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  border-radius: 50%;
  object-fit: cover;
}
.agent-peek-who {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.agent-peek-role {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-gold);
}
.agent-peek-name {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  font-size: 1.1rem;
  line-height: 1.25;
  color: var(--color-ink);
}
.agent-peek-name > span:first-child { min-width: 0; overflow-wrap: anywhere; }
.agent-peek-known,
.agent-peek-facts {
  font-size: 0.82rem;
  color: var(--color-text-muted);
  overflow-wrap: anywhere;
}
.agent-peek-bio {
  margin: 14px 0 16px;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--color-text);
  white-space: pre-line;
  overflow-wrap: anywhere;
  display: -webkit-box;
  -webkit-line-clamp: 7;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.agent-peek-bio.is-empty { color: var(--color-text-muted); font-style: italic; }
.agent-peek-profile {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  border-radius: 999px;
}
.agent-peek-profile svg { width: 16px; height: 16px; }
.agent-peek-loading {
  margin: 0;
  padding: 18px 0;
  text-align: center;
  color: var(--color-text-muted);
}
/* Phone: a sheet along the bottom of the screen, clear of the home indicator. */
.agent-peek.is-sheet {
  left: 0;
  right: 0;
  bottom: 0;
  top: auto;
  width: auto;
  max-height: 80vh;
  max-height: 80dvh;
  padding-bottom: calc(20px + env(safe-area-inset-bottom));
  padding-left: calc(20px + env(safe-area-inset-left));
  padding-right: calc(20px + env(safe-area-inset-right));
  border-radius: var(--site-radius) var(--site-radius) 0 0;
  transform: translateY(24px);
  transform-origin: bottom center;
}
.agent-peek.is-sheet.is-open { transform: none; }
@media (horizontal-viewport-segments: 2) {
  .agent-peek.is-sheet { right: auto; width: env(viewport-segment-width 0 0); }
}
@media (prefers-reduced-motion: reduce) {
  .agent-peek { transition: none; }
}

/* Touch screens: no hover, so the stack stays a little more open and no name pill appears. */
@media (hover: none) {
  .agent-bubble { margin-left: calc(var(--bubble) * -0.22); }
  .agent-bubble-tip { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .agent-bubble, .agent-bubble-tip { transition: none; }
  a.agent-bubble:hover, a.agent-bubble:focus-visible { transform: none; }
}

/* Home search: the place suggestions drop down only while the visitor types (index.html
   suggest()); the browser's own ▼ for a suggestion list never shows on the box. */
.home-search-field input::-webkit-calendar-picker-indicator { display: none !important; }

/* ---------- Map page: results left as a card grid, the map right and in view ---------- */
@media (min-width: 961px) {
  /* The map stays in view, as tall as the screen allows, while the results scroll beside it. */
  .map-layout.map-explorer #cr-map {
    height: calc(100vh - 140px); height: calc(100dvh - 140px);
    min-height: 460px;
    max-height: 820px;
  }
}
.results-panel h2 {
  font-weight: 600;
}
.results-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr));
  gap: 16px;
}
.result-card {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: var(--site-radius);
  background: var(--site-surface);
  box-shadow: var(--site-shadow-sm);
  transition: transform 240ms cubic-bezier(0.2, 0.7, 0.2, 1), box-shadow 240ms ease;
}
.result-card:hover,
.result-card.is-highlighted {
  transform: translateY(-3px);
  border-color: transparent;
  box-shadow: var(--site-shadow-lg);
}
.result-card img {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  max-width: 100%;
  border-radius: 0;
}
.result-card .result-body {
  padding: 12px 14px 14px;
}
.result-card .verified-badge {
  top: 10px;
  right: 10px;
}
.map-panel #cr-map {
  border-radius: var(--site-radius);
  box-shadow: var(--site-shadow-sm);
}
@media (min-width: 961px) {
  .map-layout.map-explorer {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  }
  .map-layout.map-explorer .results-panel {
    order: -1;
  }
}

/* ---------- Agents directory ---------- */
.dir-search {
  position: relative;
  max-width: 720px;
  margin-top: var(--space-4);
}
.dir-search-icon {
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-text-muted);
  display: flex;
}
.dir-search-icon svg {
  width: 20px;
  height: 20px;
}
.dir-search input {
  width: 100%;
  min-height: 56px;
  padding: 0 22px 0 52px;
  border: 0;
  border-radius: 999px;
  background: var(--site-surface);
  color: var(--color-ink);
  font: inherit;
  font-size: 1rem;
  box-shadow: var(--site-shadow-lg);
}
.dir-search input:focus {
  outline: none;
  box-shadow: 0 0 0 3px var(--color-gold), var(--site-shadow-lg);
}
.dir-filters {
  margin-top: var(--space-4);
}
#directory-grid {
  margin: var(--space-4) 0 var(--space-6);
}
.dir-why {
  margin-bottom: var(--space-7);
}
#directory-grid .property-card .thumb {
  aspect-ratio: 1 / 1;
  height: auto;
}
#directory-grid .property-card .body {
  gap: 6px;
}
#directory-grid .property-card .body {
  display: flex;
  flex-direction: column;
}
.dir-card-contact {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 4px;
}
.dir-card-line {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  color: var(--color-text-muted);
  font-size: 0.85rem;
  text-decoration: none;
}
.dir-card-line span {
  min-width: 0;
  overflow-wrap: anywhere;
}
.dir-card-line:hover {
  color: var(--color-ink);
}
.dir-card-line svg {
  width: 15px;
  height: 15px;
  flex: none;
  color: var(--color-gold);
}
.dir-card-reveal {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  align-self: stretch;
  min-width: 0;
}
.dir-card-reveal span { min-width: 0; overflow-wrap: anywhere; }
.dir-card-reveal svg { width: 15px; height: 15px; flex: none; }
.dir-card-profile {
  margin-top: auto;
  align-self: stretch;
}
#directory-grid .property-card .dir-card-contact + .dir-card-profile,
#directory-grid .property-card .property-address + .dir-card-profile,
#directory-grid .property-card .dir-card-langs + .dir-card-profile {
  margin-top: 12px;
}
/* The languages an agent speaks: a row of flags under the location (names on hover and for
   screen readers: app.js spokenLanguagesHTML). */
.dir-card-langs { margin: 0; font-size: 1.3rem; }
.dir-card-langs .lang-chips { gap: 6px; }
.dir-filters .lang-select { font-family: "Twemoji Country Flags", var(--font-body); }
.dir-filters .field[hidden] { display: none; }
.dir-filters select {
  background: var(--site-surface);
  border-radius: 999px;
}
#directory-grid .agent-name-line {
  font-size: 1.05rem;
  font-weight: 700;
}
.directory-reason-card {
  padding: var(--space-4);
}
.directory-reason-icon {
  color: var(--color-gold);
}

/* ---------- Guides, articles and price pages (server-written, market.html) ---------- */
.market-page {
  max-width: none;
}
.market-page > h1 {
  font-size: clamp(1.9rem, 3.6vw, 2.8rem);
  font-weight: 600;
  line-height: 1.08;
}
.market-cards {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr));
  gap: 18px;
}
.market-card {
  border: 0;
  border-radius: var(--site-radius);
  box-shadow: var(--site-shadow-sm);
  padding: 22px 22px 20px;
  transition: transform 240ms cubic-bezier(0.2, 0.7, 0.2, 1), box-shadow 240ms ease;
}
.market-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--site-shadow-lg);
}
.market-card h3 {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 1.05rem;
  line-height: 1.3;
}
.market-card h3 a {
  color: var(--color-ink);
  text-decoration: none;
}
.market-card h3 a:hover {
  color: #8a6a12;
}
.market-card p {
  color: var(--color-text-muted);
  font-size: 0.92rem;
}

/* ---------- Contact, about, legal ---------- */
.legal-page .legal-section {
  padding: clamp(20px, 3vw, 32px);
  margin-bottom: var(--space-4);
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--color-ink);
}

/* ---------- Type: Cinzel for page titles only ----------
   Cinzel is all capitals, so on every small heading it shouted. Page titles (h1) and the home's
   big section titles keep it; every other heading, card name and footer title reads in Inter. */
main h2, main h3, main h4,
.site-footer h2, .site-footer h3, .site-footer h4,
.province-card-body strong {
  font-family: var(--font-body);
  font-weight: 700;
  letter-spacing: -0.01em;
}
main h1,
.home-latest-head h2,
.home-provinces h2,
.list-with-us-banner h2 {
  font-family: var(--font-display);
  letter-spacing: 0;
}

/* ---------- "¿Por qué con un agente?" (the Agentes menu, app.js showWhyAgent) ----------
   A centred card on a computer, a sheet from the bottom on a phone; the middle scrolls. */
.why-agent {
  width: min(680px, calc(100% - 32px));
  max-height: 88vh; max-height: 88dvh;
  padding: 0;
  border: 0;
  border-radius: 24px;
  background: var(--color-white, #fff);
  color: var(--color-text);
  box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.45);
  overflow: hidden;
}
.why-agent[open] { display: flex; flex-direction: column; }
.why-agent::backdrop { background: rgba(23, 30, 26, 0.55); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.why-agent-head {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 12px;
  padding: 24px 24px 16px;
  background: #2f3b34; color: #fff;
}
.why-agent-head h2 { min-width: 0; margin: 0; color: #fff; font-family: var(--font-display); font-size: clamp(1.25rem, 3vw, 1.6rem); line-height: 1.2; }
.why-agent-x {
  flex: none; display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border: 0; border-radius: 999px;
  background: rgba(255, 255, 255, 0.12); color: #fff; cursor: pointer;
}
.why-agent-x svg { width: 18px; height: 18px; }
.why-agent-body { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding: 20px 24px 8px; -webkit-overflow-scrolling: touch; }
.why-agent-intro { margin: 0 0 18px; font-size: 1rem; line-height: 1.55; }
.why-agent-points { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; }
.why-agent-points li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 14px; align-items: start; }
.why-agent-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 12px;
  background: rgba(201, 162, 39, 0.14); color: #8a6d12;
}
.why-agent-icon svg { width: 20px; height: 20px; }
.why-agent-points h3 { margin: 2px 0 4px; font-family: var(--font-body); font-weight: 700; font-size: 1rem; letter-spacing: -0.01em; color: var(--color-ink); }
.why-agent-points p { margin: 0; font-size: 0.92rem; line-height: 1.55; color: var(--color-text-muted); }
.why-agent-duty {
  margin: 22px 0 0; padding: 16px 18px; border-radius: 16px;
  background: #e4ded2; border-left: 4px solid var(--color-gold, #c9a227);
}
.why-agent-duty h3 {
  display: flex; align-items: center; gap: 8px; margin: 0 0 6px;
  font-family: var(--font-body); font-weight: 700; font-size: 1rem; letter-spacing: -0.01em; color: var(--color-ink);
}
.why-agent-duty h3 svg { flex: none; width: 20px; height: 20px; color: #8a6d12; }
.why-agent-duty p { margin: 0; font-size: 0.92rem; line-height: 1.55; }
.why-agent-duty ul { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 8px; }
.why-agent-duty li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 8px; align-items: start; font-size: 0.9rem; line-height: 1.5; }
.why-agent-duty li svg { width: 16px; height: 16px; margin-top: 3px; color: #2f7a4f; }
.why-agent-note { margin: 12px 0 8px; font-size: 0.78rem; color: var(--color-text-muted); }
.why-agent-foot {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 24px calc(14px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid rgba(47, 59, 52, 0.12);
}
.why-agent-skip { display: inline-flex; align-items: center; gap: 8px; font-size: 0.86rem; color: var(--color-text-muted); cursor: pointer; }
.why-agent-skip input { width: 16px; height: 16px; accent-color: #2f3b34; }
.why-agent-foot .btn { display: inline-flex; align-items: center; gap: 8px; }
.why-agent-foot .btn svg { width: 16px; height: 16px; }
@media (max-width: 560px) {
  .why-agent { width: 100%; max-width: 100%; margin: auto 0 0; border-radius: 22px 22px 0 0; max-height: 92vh; max-height: 92dvh; }
  .why-agent-head, .why-agent-body, .why-agent-foot { padding-left: 16px; padding-right: 16px; }
  .why-agent-foot .btn { flex: 1 1 100%; justify-content: center; }
}
.sell-dialog-free { display: inline-flex; align-items: center; gap: 8px; min-width: 0; font-size: 0.86rem; color: var(--color-text-muted); }
.sell-dialog-free svg { flex: none; width: 18px; height: 18px; color: #2f7a4f; }

/* ---------- Map page on a computer: the map runs to the screen's edge (like Zillow) ----------
   Results on the left at the page's gutter; the map fills the rest of the width, flush with the
   right edge, and the full height under the sticky header, staying put while the list scrolls. */
@media (min-width: 961px) {
  .map-layout.map-explorer {
    max-width: none;
    margin: 0;
    padding: 0 0 0 clamp(16px, 3vw, 48px);
    gap: clamp(16px, 2vw, 28px);
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr);
    align-items: start;
  }
  .map-layout.map-explorer .results-panel {
    padding: var(--space-5) 0 var(--space-7);
  }
  .map-layout.map-explorer .map-panel {
    position: sticky;
    top: var(--site-header-h, 73px);
    align-self: start;
  }
  .map-layout.map-explorer #cr-map {
    height: calc(100vh - var(--site-header-h, 73px)); height: calc(100dvh - var(--site-header-h, 73px));
    min-height: 460px;
    max-height: none;
    border: 0;
    border-left: 1px solid var(--site-line);
    border-radius: 0;
    box-shadow: none;
  }
  /* The legend floats over the map's bottom-left corner instead of sitting below it. */
  .map-layout.map-explorer .map-legend {
    position: absolute;
    left: 12px;
    bottom: 28px; /* clears the map credits line */
    right: 64px;
    z-index: 500;
    width: fit-content;
    max-width: calc(100% - 76px);
    margin: 0;
    padding: 8px 12px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
  }
}

/* ---------- Contact page: "¿Cómo le podemos ayudar?" — five quiet choices ---------- */
.contact-choose-hero h1 { margin-bottom: 8px; }
.contact-choose-section { padding-top: var(--space-6); }
.contact-choose {
  max-width: 720px;
  margin: 0 auto;
  display: grid;
  gap: 12px;
}
.contact-choice {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 16px 18px;
  border-radius: 18px;
  background: var(--site-surface, #fff);
  border: 1px solid var(--site-line, rgba(47, 59, 52, 0.12));
  color: var(--color-ink);
  text-decoration: none;
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}
.contact-choice:hover,
.contact-choice:focus-visible {
  border-color: var(--color-gold, #c9a227);
  box-shadow: var(--site-shadow-sm, 0 6px 18px -10px rgba(0, 0, 0, 0.25));
  transform: translateY(-1px);
}
.contact-choice-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 14px;
  background: rgba(201, 162, 39, 0.14); color: #8a6d12;
}
.contact-choice-icon svg { width: 22px; height: 22px; }
.contact-choice-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.contact-choice-text strong { font-size: 1.02rem; font-weight: 700; }
.contact-choice-text small { font-size: 0.86rem; color: var(--color-text-muted); }
.contact-choice-go { display: inline-flex; color: var(--color-text-muted); }
.contact-choice-go svg { width: 18px; height: 18px; transition: transform 160ms ease; }
.contact-choice:hover .contact-choice-go svg { transform: translateX(3px); color: var(--color-ink); }

/* ---------- Planes (contact.html): pricing first, then the client choices ----------
   Dark hero with a gold glow; the three plan cards rise over its lower edge. Sales Agent is the
   featured card (gold ring, ribbon), Broker the premium dark card. Prices come from /api/pricing
   (contact.js). In the store apps the plan sections are hidden (data-purchase). */
.plans-hero {
  position: relative;
  overflow: hidden;
  background: radial-gradient(120% 90% at 50% 0%, #34443a 0%, var(--site-deep) 62%);
  color: var(--color-white);
  padding: 72px 0 196px;
  text-align: center;
  isolation: isolate;
}
.plans-hero-glow {
  position: absolute;
  inset: auto -20% -40% -20%;
  height: 80%;
  background: radial-gradient(50% 60% at 50% 50%, rgba(201, 162, 39, 0.28), rgba(201, 162, 39, 0) 70%);
  z-index: -1;
  pointer-events: none;
}
.plans-hero::before {
  /* A faint grid that fades out toward the bottom. */
  content: '';
  position: absolute;
  inset: 0;
  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;
  -webkit-mask-image: linear-gradient(180deg, #000 0%, transparent 75%);
  mask-image: linear-gradient(180deg, #000 0%, transparent 75%);
  z-index: -1;
  pointer-events: none;
}
.plans-hero-inner { display: flex; flex-direction: column; align-items: center; gap: 18px; min-width: 0; }
.plans-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  max-width: 100%;
  padding: 7px 16px;
  border-radius: 999px;
  border: 1px solid rgba(228, 199, 101, 0.35);
  background: rgba(255, 255, 255, 0.06);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: var(--color-gold-soft);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.04em;
}
.plans-eyebrow svg { width: 15px; height: 15px; flex: none; }
.plans-hero h1 {
  margin: 0;
  max-width: 900px;
  font-size: clamp(2rem, 5.4vw, 3.6rem);
  line-height: 1.08;
  color: var(--color-white);
  background: linear-gradient(180deg, #ffffff 30%, #efdc9c 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  overflow-wrap: anywhere;
}
.plans-lead {
  margin: 0;
  max-width: 640px;
  font-size: clamp(1rem, 1.6vw, 1.15rem);
  line-height: 1.6;
  color: rgba(236, 231, 221, 0.82);
}
.plans-promo {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
  max-width: 100%;
  margin-top: 6px;
  padding: 8px 10px 8px 8px;
  border-radius: 999px;
  background: rgba(201, 162, 39, 0.14);
  border: 1px solid rgba(228, 199, 101, 0.4);
  color: var(--color-white);
  font-size: 0.92rem;
}
.plans-promo[hidden] { display: none; }
.plans-promo-badge {
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--color-gold);
  color: var(--site-deep);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.plans-promo-text { min-width: 0; text-align: left; }

.plans-section { position: relative; margin-top: -148px; padding-bottom: var(--space-6); }
.plans-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  align-items: stretch;
}
.plan-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 32px 28px 30px;
  border-radius: 28px;
  background: var(--site-surface);
  border: 1px solid var(--site-line);
  box-shadow: var(--site-shadow-lg);
  color: var(--color-text);
  transition: transform 220ms ease, box-shadow 220ms ease;
}
.plan-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 28px;
  right: 28px;
  height: 4px;
  border-radius: 0 0 6px 6px;
  background: linear-gradient(90deg, #8fb29a, #b9cfb9);
}
.plan-card:hover { transform: translateY(-4px); }
.plan-head { display: flex; align-items: center; gap: 12px; min-width: 0; }
.plan-icon {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: rgba(47, 59, 52, 0.07);
  color: var(--color-ink);
}
.plan-icon svg { width: 22px; height: 22px; }
.plan-name {
  margin: 0;
  min-width: 0;
  font-family: var(--font-body);
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  text-transform: none;
}
.plan-for { margin: 14px 0 0; color: var(--color-text-muted); font-size: 0.95rem; line-height: 1.5; min-height: 2.9em; }
.plan-price {
  display: flex;
  align-items: flex-start;
  gap: 4px;
  margin-top: 22px;
  min-height: 4.4rem;
  font-variant-numeric: tabular-nums;
}
.plan-price-currency { margin-top: 0.55rem; font-size: 1.5rem; font-weight: 700; }
.plan-price-amount { font-size: clamp(2.6rem, 6vw, 3.9rem); font-weight: 800; line-height: 1; letter-spacing: -0.04em; }
.plan-price-per { white-space: nowrap; align-self: flex-end; margin-bottom: 0.45rem; color: var(--color-text-muted); font-size: 0.98rem; font-weight: 500; }
.plan-price-note { margin: 6px 0 0; color: var(--color-text-muted); font-size: 0.84rem; line-height: 1.45; }
.plan-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 22px;
  min-height: 52px;
  padding: 12px 20px;
  font-weight: 700;
  text-align: center;
  border: 1.5px solid var(--color-ink);
  background: transparent;
  color: var(--color-ink);
  transition: background 160ms ease, color 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}
.plan-cta:hover,
.plan-cta:focus-visible { background: var(--color-ink); color: var(--color-white); }
.plan-includes { margin: 26px 0 12px; font-size: 0.8rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--color-text-muted); }
.plan-features { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.plan-features li { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 10px; align-items: start; font-size: 0.95rem; line-height: 1.45; }
.plan-features li svg {
  width: 22px;
  height: 22px;
  padding: 4px;
  border-radius: 999px;
  background: rgba(31, 122, 77, 0.12);
  color: var(--color-success);
}

/* Featured: Sales Agent. */
.plan-card--featured {
  border: 2px solid var(--color-gold);
  box-shadow: 0 2px 6px rgba(35, 45, 39, 0.08), 0 30px 70px rgba(201, 162, 39, 0.28);
  transform: translateY(-14px);
}
.plan-card--featured:hover { transform: translateY(-18px); }
.plan-card--featured::before { background: linear-gradient(90deg, #c9a227, #efd27a); }
.plan-card--featured .plan-icon { background: rgba(201, 162, 39, 0.16); color: #8a6d12; }
.plan-card--featured .plan-cta { border-color: var(--color-gold); background: var(--color-gold); color: var(--site-deep); box-shadow: 0 10px 24px -10px rgba(201, 162, 39, 0.8); }
.plan-card--featured .plan-cta:hover,
.plan-card--featured .plan-cta:focus-visible { background: var(--color-gold-soft); border-color: var(--color-gold-soft); color: var(--site-deep); }
.plan-ribbon {
  position: absolute;
  top: -15px;
  left: 50%;
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: calc(100% - 32px);
  padding: 6px 14px;
  border-radius: 999px;
  background: linear-gradient(90deg, #c9a227, #e4c765);
  color: var(--site-deep);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  white-space: nowrap;
  box-shadow: 0 8px 18px -8px rgba(201, 162, 39, 0.9);
}
.plan-ribbon svg { width: 13px; height: 13px; flex: none; }

/* Premium: Broker. */
.plan-card--broker {
  background: radial-gradient(120% 70% at 100% 0%, rgba(201, 162, 39, 0.18), rgba(201, 162, 39, 0) 60%), var(--site-deep);
  border-color: rgba(228, 199, 101, 0.28);
  color: rgba(236, 231, 221, 0.92);
}
.plan-card--broker::before { background: linear-gradient(90deg, #e4c765, #ffffff); opacity: 0.85; }
.plan-card--broker .plan-name,
.plan-card--broker .plan-price-amount,
.plan-card--broker .plan-price-currency { color: var(--color-white); }
.plan-card--broker .plan-for,
.plan-card--broker .plan-price-note,
.plan-card--broker .plan-price-per,
.plan-card--broker .plan-includes { color: rgba(236, 231, 221, 0.7); }
.plan-card--broker .plan-icon { background: rgba(228, 199, 101, 0.14); color: var(--color-gold-soft); }
.plan-card--broker .plan-cta { border-color: var(--color-gold-soft); color: var(--color-gold-soft); }
.plan-card--broker .plan-cta:hover,
.plan-card--broker .plan-cta:focus-visible { background: var(--color-gold-soft); color: var(--site-deep); }
.plan-card--broker .plan-features li svg { background: rgba(228, 199, 101, 0.16); color: var(--color-gold-soft); }

.plans-trust {
  list-style: none;
  margin: 40px auto 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 14px;
}
.plans-trust li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid var(--site-line);
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--color-ink);
}
.plans-trust svg { width: 16px; height: 16px; flex: none; color: var(--color-success); }

/* The Broker plan's professional cadastral map, put forward under the plans (contact.html). */
.plans-spotlight {
  max-width: 980px;
  margin: 32px auto 0;
  display: grid;
  grid-template-columns: minmax(0, 200px) minmax(0, 1fr);
  gap: 24px;
  align-items: center;
  padding: 24px;
  border-radius: 24px;
  background: var(--site-surface);
  border: 1px solid var(--site-line);
  box-shadow: var(--site-shadow-sm);
}
.plans-spotlight-visual { display: flex; justify-content: center; min-width: 0; }
.plans-spotlight-visual svg { width: 100%; max-width: 200px; height: auto; }
.psv-ground { fill: #e9efe3; }
.psv-sea { fill: #9fc3dd; }
.psv-strip { fill: none; stroke: #f57c00; stroke-opacity: 0.35; stroke-width: 16; }
.psv-coast { fill: none; stroke: #0d47a1; stroke-width: 1.6; }
.psv-lot { fill: rgba(230, 0, 126, 0.12); stroke: #e6007e; stroke-width: 2.4; stroke-linejoin: round; }
.psv-vertex { fill: #fff; stroke: #e6007e; stroke-width: 1.4; }
.psv-label { font: 700 8px var(--font-body, sans-serif); fill: #1b1b1b; text-anchor: middle; paint-order: stroke; stroke: #fff; stroke-width: 2.4px; }
.psv-measure { stroke: #1b1b1b; stroke-width: 1.2; stroke-dasharray: 3 2; }
.plans-spotlight-body { min-width: 0; }
.plans-spotlight-badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--color-gold-soft, #f3e7bf);
  color: var(--site-deep);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.plans-spotlight-title { margin: 10px 0 6px; font-size: 1.35rem; color: var(--site-deep); }
.plans-spotlight-lead { margin: 0 0 12px; color: var(--color-text-muted, #5b655f); }
.plans-spotlight-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.plans-spotlight-list li { display: flex; gap: 10px; align-items: flex-start; min-width: 0; line-height: 1.45; }
.plans-spotlight-list li > span:last-child { min-width: 0; overflow-wrap: anywhere; }
.plans-spotlight-list svg { width: 18px; height: 18px; flex: none; margin-top: 2px; color: var(--color-success); }
.plans-spotlight-note { margin: 12px 0 0; font-size: 0.82rem; color: var(--color-text-muted, #5b655f); }
@media (max-width: 640px) {
  .plans-spotlight { grid-template-columns: minmax(0, 1fr); padding: 18px; gap: 16px; }
}
:root[data-theme="dark"] .plans-spotlight { background: var(--site-surface); }

.plans-compare {
  max-width: 980px;
  margin: 32px auto 0;
  border-radius: 24px;
  background: var(--site-surface);
  border: 1px solid var(--site-line);
  box-shadow: var(--site-shadow-sm);
  overflow: hidden;
}
.plans-compare > summary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 56px;
  padding: 14px 20px;
  cursor: pointer;
  list-style: none;
  font-weight: 700;
  color: var(--color-ink);
  text-align: center;
}
.plans-compare > summary::-webkit-details-marker { display: none; }
.plans-compare-chev { display: inline-flex; transition: transform 200ms ease; }
.plans-compare-chev svg { width: 18px; height: 18px; }
.plans-compare[open] .plans-compare-chev { transform: rotate(180deg); }
.plans-compare-scroll { overflow-x: auto; border-top: 1px solid var(--site-line); }
.plans-compare-table { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 0.92rem; }
.plans-compare-table col:first-child,
.plans-compare-table th:first-child { width: 46%; }
.plans-compare-table th,
.plans-compare-table td { padding: 12px 14px; border-bottom: 1px solid var(--site-chip); text-align: center; vertical-align: middle; overflow-wrap: break-word; hyphens: auto; }
/* The feature names stay in view while a narrow screen scrolls the three plan columns. */
.plans-compare-table tbody th,
.plans-compare-table thead th:first-child { position: sticky; left: 0; z-index: 1; background: var(--site-surface); }
.plans-compare-table thead th:first-child { z-index: 2; }
.plans-compare-table thead th { position: sticky; top: 0; background: var(--site-surface); font-size: 0.86rem; font-weight: 800; color: var(--color-ink); }
.plans-compare-table tbody th { text-align: left; font-weight: 500; color: var(--color-text); hyphens: manual; overflow-wrap: normal; }
.plans-compare-table tbody tr:last-child > * { border-bottom: 0; }
.plans-compare-table .is-featured { background: rgba(201, 162, 39, 0.08); }
.plans-yes { display: inline-flex; color: var(--color-success); }
.plans-yes svg { width: 18px; height: 18px; }
.plans-no { color: #a9a597; }

.plans-faq { padding: var(--space-6) 0 0; }
.plans-faq-inner { max-width: 820px; }
.plans-faq h2 { text-align: center; margin: 0 0 24px; font-size: clamp(1.5rem, 3vw, 2rem); }
.plans-faq-list { display: grid; gap: 12px; }
.plans-faq-item { border-radius: 18px; background: var(--site-surface); border: 1px solid var(--site-line); }
.plans-faq-item > summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  min-height: 56px;
  padding: 16px 20px;
  cursor: pointer;
  list-style: none;
  font-weight: 700;
  color: var(--color-ink);
}
.plans-faq-item > summary::-webkit-details-marker { display: none; }
.plans-faq-plus { position: relative; width: 20px; height: 20px; }
.plans-faq-plus::before,
.plans-faq-plus::after { content: ''; position: absolute; left: 3px; right: 3px; top: 9px; height: 2px; border-radius: 2px; background: currentColor; transition: transform 200ms ease; }
.plans-faq-plus::after { transform: rotate(90deg); }
.plans-faq-item[open] .plans-faq-plus::after { transform: rotate(0deg); }
.plans-faq-item > p { margin: 0; padding: 0 20px 18px; color: var(--color-text-muted); line-height: 1.6; }

.plans-others { padding-top: var(--space-6); }
.plans-others-head { max-width: 720px; margin: 0 auto 24px; text-align: center; }
.plans-others-head h2 { margin: 0 0 8px; font-size: clamp(1.5rem, 3vw, 2rem); }
.plans-others-head p { margin: 0; color: var(--color-text-muted); }
.plans-others .contact-choose { max-width: 980px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
html:not([data-store-app]) .contact-choice--app-only { display: none; }

.plans-cta { padding: 0 0 var(--space-7); }
.plans-cta-inner {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: 56px 24px;
  border-radius: 32px;
  text-align: center;
  background: radial-gradient(80% 120% at 50% 120%, rgba(201, 162, 39, 0.35), rgba(201, 162, 39, 0) 60%), var(--site-deep);
  color: var(--color-white);
}
.plans-cta-inner h2 { margin: 0; color: var(--color-white); font-size: clamp(1.6rem, 3.6vw, 2.4rem); overflow-wrap: anywhere; }
.plans-cta-inner p { margin: 0; max-width: 560px; color: rgba(236, 231, 221, 0.8); }
.plans-cta-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 8px; }
.plans-cta-actions .btn { min-height: 50px; padding: 12px 26px; font-weight: 700; }
.plans-cta-ghost { border: 1.5px solid rgba(255, 255, 255, 0.35); background: transparent; color: var(--color-white); }
.plans-cta-ghost:hover,
.plans-cta-ghost:focus-visible { background: rgba(255, 255, 255, 0.1); color: var(--color-white); }

/* The store apps sell no plans: the hero no longer has cards rising over it. */
html[data-store-app] .plans-hero { padding-bottom: 64px; }
html[data-store-app] .plans-others { padding-top: var(--space-5); }

@media (max-width: 1080px) {
  .plans-grid { grid-template-columns: minmax(0, 1fr); max-width: 560px; margin: 0 auto; gap: 28px; }
  .plan-card--featured,
  .plan-card--featured:hover { transform: none; }
  .plan-for { min-height: 0; }
}
@media (max-width: 760px) {
  .plans-hero { padding: 48px 0 172px; }
  .plans-others .contact-choose { grid-template-columns: minmax(0, 1fr); }
  .plan-card { padding: 30px 20px 24px; border-radius: 24px; }
  .plans-compare-table { font-size: 0.8rem; }
  .plans-compare-table col:first-child,
  .plans-compare-table th:first-child { width: 34%; }
  .plans-compare-table th,
  .plans-compare-table td { padding: 10px 4px; }
  .plans-compare-table tbody th { padding-left: 12px; }
  .plans-cta-inner { padding: 44px 20px; border-radius: 24px; }
}
@media (max-width: 359px) {
  /* Folded phones: the plan columns scroll beside the pinned feature names. */
  .plans-compare-table { min-width: 340px; }
}
@media (prefers-reduced-motion: reduce) {
  .plan-card,
  .plan-cta,
  .plans-compare-chev,
  .plans-faq-plus::before,
  .plans-faq-plus::after { transition: none; }
  .plan-card:hover,
  .plan-card--featured:hover { transform: none; }
}

/* ---------- Map result cards: swipe the photos right in the list (app.js initCardGalleries) ---------- */
.result-card .result-body {
  display: flex;
  flex-direction: column;
  color: inherit;
  text-decoration: none;
}
.result-card:hover .home-card-nav,
.result-card .home-card-nav:focus-visible {
  opacity: 1;
  transform: translateY(-50%) scale(1);
}
.result-card .home-card-nav:disabled {
  opacity: 0;
  pointer-events: none;
}
.result-card .firesell-badge,
.result-card > .verified-badge {
  z-index: 3;
}
/* Phones and tablets: the map stays edge to edge, the list keeps the 16px side gutter. */
@media (max-width: 960px) {
  .map-layout.map-explorer .results-panel {
    padding-inline: 16px;
  }
}

/* Agent profile: the agent's own company and website under their role line. */
.agent-profile-company, .agent-profile-website { display: flex; align-items: center; gap: 6px; margin: 2px 0; min-width: 0; overflow-wrap: anywhere; }
.agent-profile-company svg, .agent-profile-website svg { width: 16px; height: 16px; flex: 0 0 auto; }
.agent-profile-company-logo { display: block; max-width: min(100%, 250px); max-height: 90px; height: auto; object-fit: contain; margin: 6px 0; }
.agent-profile-known-as { margin: 0 0 4px; font-style: italic; color: var(--color-text-muted); overflow-wrap: anywhere; }

/* Listing page price comparison: the "why at the median" info icon next to the verdict. The tip
   spans the verdict line instead of hanging off the icon, so it never runs off a narrow screen. */
.price-compare-verdict { position: relative; }
.price-compare .price-compare-why { position: static; vertical-align: middle; margin-left: 2px; cursor: help; }
.price-compare .price-compare-why .info-tooltip-text { left: 0; right: 0; width: auto; max-width: none; bottom: calc(100% + 8px); }
/* The listings compared, folded under the verdict: one row each, wrapping on a phone. */
.price-compare-list { margin: var(--space-3) 0 0; border-top: 1px solid var(--color-border); padding-top: var(--space-3); }
.price-compare-list summary { cursor: pointer; font-weight: 600; font-size: 0.92rem; color: var(--color-ink); }
.price-compare-list ul { list-style: none; margin: var(--space-2) 0 0; padding: 0; max-height: min(60vh, 420px); max-height: min(60dvh, 420px); overflow-y: auto; }
.price-compare-item { display: flex; flex-direction: column; gap: 2px; min-width: 0; padding: 8px 0; border-bottom: 1px solid var(--color-border); }
.price-compare-item:last-child { border-bottom: 0; }
.price-compare-item a { min-width: 0; overflow-wrap: anywhere; font-size: 0.92rem; }
.price-compare-item-meta { min-width: 0; overflow-wrap: anywhere; font-size: 0.84rem; color: var(--color-text-muted); }
.price-compare-item-meta strong { color: var(--color-ink); }
.price-compare-sold { display: inline-block; margin-left: 4px; padding: 0 6px; border-radius: 999px; background: var(--color-ink); color: #fff; font-size: 0.72rem; font-weight: 600; vertical-align: 1px; }
.price-compare-more { margin: 6px 0 0; font-size: 0.8rem; color: var(--color-text-muted); }

/* ---------- Servicios: the sponsors' photos (contractors.js, contractor-profile.js) ----------
   Cards: the shared swipeable gallery (app.js initCardGalleries), arrows on hover. */
.ct-card .home-card-slide { color: inherit; text-decoration: none; }
.ct-card:hover .home-card-nav,
.ct-card .home-card-nav:focus-visible {
  opacity: 1;
  transform: translateY(-50%) scale(1);
}
.ct-card .home-card-nav:disabled {
  opacity: 0;
  pointer-events: none;
}
/* Each card photo fills the 4:3 frame, no empty edges (contractors.js photosHTML); the upper part
   is kept, where faces and a flyer's title usually are. */
.ct-slide {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--color-cream-dim, #efe8da);
}
.ct-card .ct-slide .thumb {
  width: 100%;
  height: 100%;
  aspect-ratio: auto;
  object-fit: cover;
  object-position: center 25%;
}
/* A tall photo (a phone shot held upright, a flyer; app.js fitTallPhotos) is shown whole over a
   blurred, darkened copy of itself instead of being cut. Cards and the sponsor's page alike. */
.ct-slide.is-tall, .cp-slide.is-tall { background: #1f2823; }
.photo-tall-bg {
  position: absolute;
  inset: -8%;
  width: 116%;
  height: 116%;
  object-fit: cover;
  filter: blur(26px) saturate(1.15) brightness(0.62);
  pointer-events: none;
}
.ct-card .ct-slide.is-tall .thumb,
.cp-slide.is-tall .cp-gallery-img {
  position: relative;
  object-fit: contain;
  object-position: center;
  background: none;
}
.cp-slide.is-tall .cp-gallery-img { filter: drop-shadow(0 12px 28px rgba(0, 0, 0, 0.45)); }

/* A sponsor's page: a big slider whose photos fill the frame, no empty edges (cover, kept to their
   upper part, where faces and a flyer's title usually are); a tap opens the full-screen viewer,
   which shows each photo whole (contractor-profile.js galleryHTML / initShowcase). Thumbnails
   below. */
.cp-gallery-wrap { margin: 0 0 var(--space-4); min-width: 0; }
.cp-gallery {
  border-radius: 20px;
  overflow: hidden;
  background: var(--color-cream-dim, #efe8da);
  box-shadow: 0 18px 40px -22px rgba(47, 59, 52, 0.6), 0 2px 6px rgba(47, 59, 52, 0.08);
  isolation: isolate;
  aspect-ratio: 4 / 3;
  max-height: 78vh;
  max-height: 78svh;
}
.cp-gallery .home-card-track { height: 100%; }
.cp-slide { position: relative; height: 100%; overflow: hidden; }
.cp-slide-open {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: zoom-in;
}
.cp-slide-open:focus-visible { outline: 3px solid var(--color-gold); outline-offset: -6px; }
.cp-gallery-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 25%;
}
.cp-gallery .home-card-nav {
  opacity: 0.92;
  transform: translateY(-50%) scale(1);
  width: 44px;
  height: 44px;
}
.cp-gallery .home-card-nav:hover { transform: translateY(-50%) scale(1.08); }
.cp-gallery .home-card-nav:disabled { opacity: 0; pointer-events: none; }
.cp-gallery .home-card-dots { bottom: 14px; gap: 6px; }
.cp-gallery .home-card-dots span { width: 8px; height: 8px; transition: width 220ms ease, background 220ms ease; }
.cp-gallery .home-card-dots span.is-active { width: 22px; border-radius: 999px; transform: none; }
.home-card-count {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--color-ink, #2f3b34);
  font-size: 0.8rem;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
  pointer-events: none;
}
.cp-expand {
  position: absolute;
  left: 12px;
  top: 12px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(20, 26, 23, 0.55);
  backdrop-filter: blur(6px);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 600;
  pointer-events: none;
}
.cp-expand svg { width: 14px; height: 14px; flex: none; }
/* The thumbnails: one row that scrolls sideways when there are many. */
.cp-thumbs {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  padding: 2px;
  overflow-x: auto;
  scrollbar-width: thin;
  overscroll-behavior-x: contain;
}
.cp-thumb {
  flex: 0 0 auto;
  width: 84px;
  aspect-ratio: 4 / 3;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 10px;
  overflow: hidden;
  background: #1f2823;
  cursor: pointer;
  opacity: 0.6;
  transition: opacity 160ms ease, border-color 160ms ease;
}
.cp-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.cp-thumb:hover, .cp-thumb:focus-visible { opacity: 1; }
.cp-thumb.is-active { opacity: 1; border-color: var(--color-gold); }
@media (max-width: 600px) {
  .cp-gallery { aspect-ratio: 4 / 5; border-radius: 16px; }
  .cp-thumb { width: 64px; }
  .cp-expand span { display: none; }
}
@media (hover: hover) and (min-width: 601px) {
  .cp-expand { opacity: 0; transition: opacity 160ms ease; }
  .cp-gallery:hover .cp-expand { opacity: 1; }
}
/* The full-screen viewer. */
html.cp-viewer-open { overflow: hidden; }
.cp-viewer {
  width: 100vw;
  max-width: 100vw;
  height: 100vh;
  height: 100dvh;
  max-height: 100dvh;
  margin: 0;
  padding: max(56px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) max(40px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left));
  border: 0;
  background: rgba(12, 16, 14, 0.94);
  color: #fff;
}
.cp-viewer[open] { display: flex; align-items: center; justify-content: center; }
.cp-viewer::backdrop { background: rgba(12, 16, 14, 0.94); }
.cp-viewer-img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 6px; }
.cp-viewer-close, .cp-viewer-nav {
  position: absolute;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  cursor: pointer;
}
.cp-viewer-close:hover, .cp-viewer-nav:hover { background: rgba(255, 255, 255, 0.26); }
.cp-viewer-close svg, .cp-viewer-nav svg { width: 22px; height: 22px; }
.cp-viewer-close { top: max(10px, env(safe-area-inset-top)); right: max(10px, env(safe-area-inset-right)); }
.cp-viewer-nav { top: 50%; transform: translateY(-50%); }
.cp-viewer-nav[data-dir='-1'] { left: max(10px, env(safe-area-inset-left)); }
.cp-viewer-nav[data-dir='1'] { right: max(10px, env(safe-area-inset-right)); }
.cp-viewer-count {
  position: absolute;
  bottom: max(12px, env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.85rem;
  font-weight: 600;
  opacity: 0.85;
}
@media (hover: none) { .cp-viewer-nav { display: none; } }
@media (prefers-reduced-motion: reduce) {
  .cp-thumb { transition: none; }
}

/* ---------- Property page: "See all N photos" + the photo tour ----------
   The listing's photos on one scrolling page (property.html photoTourHTML): a wide photo, then
   two side by side, and so on. Tapping one opens the one-by-one viewer (.gallery-modal) on top. */
/* The buttons on the photos (tours, "See all N photos") are small dark glass chips: they say
   what is there without covering the house. */
.gallery-all-btn,
.gallery-wrap .tour-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 32px;
  padding: 0 12px 0 10px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  background: rgba(18, 24, 20, 0.42);
  -webkit-backdrop-filter: blur(12px) saturate(1.3);
  backdrop-filter: blur(12px) saturate(1.3);
  color: #fff;
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1;
  white-space: nowrap;
  box-shadow: none;
  cursor: pointer;
  transition: background-color 180ms ease, border-color 180ms ease;
}
.gallery-wrap .tour-pill-3d { background: rgba(18, 24, 20, 0.42); color: #fff; }
.gallery-all-btn svg,
.gallery-wrap .tour-pill svg { width: 14px; height: 14px; flex: none; color: #fff; opacity: 0.92; }
.gallery-all-btn:hover,
.gallery-wrap .tour-pill:hover { background: rgba(18, 24, 20, 0.62); border-color: rgba(255, 255, 255, 0.32); }
.gallery-all-btn:focus-visible,
.gallery-wrap .tour-pill:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.gallery-wrap .tour-pills { top: calc(var(--space-4) + 12px); left: 12px; gap: 6px; }
.gallery-all-btn {
  position: absolute;
  right: 12px;
  bottom: calc(var(--space-4) + 12px);
  z-index: 2;
  max-width: calc(100% - 24px);
}
.gallery-all-btn span { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.gallery-all-short { display: none; }
/* Wider screens: the chip is the "see all" — the last thumbnail stays a plain photo instead of
   a second, darker "See all" with its own count under it. */
@media (min-width: 561px) {
  .gallery-wrap:has(.gallery-all-btn) .gallery-more-overlay { display: none; }
}
/* Phones: the gallery is a swipeable row; the chip sits on the first photo, bottom left, and
   just counts the photos. */
@media (max-width: 560px) {
  .gallery-all-btn,
  .gallery-wrap .tour-pill { height: 28px; padding: 0 10px 0 8px; font-size: 0.74rem; }
  .gallery-all-btn { right: auto; left: 10px; bottom: calc(var(--space-4) + 10px); }
  .gallery-wrap .tour-pills { top: calc(var(--space-4) + 10px); left: 10px; }
  .gallery-all-long { display: none; }
  .gallery-all-short { display: inline; }
}

.photo-tour {
  position: fixed;
  inset: 0;
  z-index: 990;
  height: 100vh;
  height: 100dvh;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  background: var(--site-bg);
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 260ms ease, transform 380ms cubic-bezier(0.2, 0.8, 0.2, 1);
}
.photo-tour.is-open { opacity: 1; transform: none; }
.photo-tour[hidden] { display: none; }

.photo-tour-bar {
  position: sticky;
  top: 0;
  z-index: 3;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: calc(12px + env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) 12px max(16px, env(safe-area-inset-left, 0px));
  background: rgba(236, 231, 221, 0.82);
  -webkit-backdrop-filter: blur(20px) saturate(1.5);
  backdrop-filter: blur(20px) saturate(1.5);
  border-bottom: 1px solid rgba(35, 45, 39, 0.08);
}
.photo-tour-close,
.photo-tour-contact {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 42px;
  min-width: 42px;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  transition: transform 180ms ease, background-color 180ms ease, box-shadow 180ms ease;
}
.photo-tour-close {
  padding: 8px 16px 8px 12px;
  border: 1px solid var(--site-line);
  background: var(--site-surface);
  color: var(--site-deep);
  box-shadow: var(--site-shadow-sm);
}
.photo-tour-close svg,
.photo-tour-contact svg { width: 18px; height: 18px; flex: none; }
.photo-tour-close:hover { transform: translateX(-2px); }
.photo-tour-contact {
  padding: 8px 18px;
  border: 0;
  background: var(--color-gold);
  color: var(--site-deep);
  box-shadow: 0 4px 14px rgba(201, 162, 39, 0.35);
}
.photo-tour-contact:hover { background: var(--color-gold-soft); transform: translateY(-1px); }
.photo-tour-contact[hidden] { display: none; }
.photo-tour-close:focus-visible,
.photo-tour-contact:focus-visible { outline: 3px solid var(--color-gold); outline-offset: 2px; }
.photo-tour-heading { min-width: 0; }
.photo-tour-heading h2 {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--site-deep);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.photo-tour-heading p {
  margin: 1px 0 0;
  color: var(--color-text-muted);
  font-size: 0.8rem;
  font-variant-numeric: tabular-nums;
}
/* How far down the photos the visitor is: a thin green-to-gold line under the bar. */
.photo-tour-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  pointer-events: none;
}
.photo-tour-progress > span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--color-success), var(--color-gold));
  transform: scaleX(0);
  transform-origin: left center;
}

.photo-tour-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  max-width: 1180px;
  margin: 0 auto;
  padding: 24px max(32px, env(safe-area-inset-right, 0px)) calc(48px + env(safe-area-inset-bottom, 0px)) max(32px, env(safe-area-inset-left, 0px));
}
.photo-tour-item {
  position: relative;
  display: block;
  width: 100%;
  min-width: 0;
  aspect-ratio: 4 / 3;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 20px;
  overflow: hidden;
  isolation: isolate;
  cursor: zoom-in;
  scroll-margin-top: calc(84px + env(safe-area-inset-top, 0px));
  background: linear-gradient(110deg, #e1dbce 30%, #eee9df 50%, #e1dbce 70%);
  background-size: 220% 100%;
  animation: photoTourShimmer 1.5s linear infinite;
  box-shadow: var(--site-shadow-sm);
}
.photo-tour-item:has(> .is-loaded) { animation: none; background: #d8d2c5; }
.photo-tour-item.is-wide { grid-column: 1 / -1; aspect-ratio: 16 / 10; }
.photo-tour-item img,
.photo-tour-item video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.025);
  transition: opacity 450ms ease, transform 700ms cubic-bezier(0.2, 0.7, 0.2, 1);
}
.photo-tour-item img.is-loaded,
.photo-tour-item video.is-loaded { opacity: 1; transform: none; }
@media (hover: hover) {
  .photo-tour-item:hover img.is-loaded,
  .photo-tour-item:hover video.is-loaded { transform: scale(1.035); }
}
/* A 360° photo shown flat in the grid: only its middle slice (about a room's width, away from the
   stretched floor and sky), so it reads like an ordinary photo. The whole panorama opens in the
   viewer. `translate` (not `transform`) centres it, so the fade-in and hover zoom still apply. */
.photo-tour-item img.is-pano,
.gallery-cell img.is-pano {
  position: absolute;
  top: 50%;
  left: 50%;
  width: auto;
  max-width: none;
  height: 240%;
  translate: -50% -50%;
}
.photo-tour-item:focus-visible { outline: 3px solid var(--color-gold); outline-offset: 3px; }
/* A caption reads on a soft shade at the bottom of its photo. */
.photo-tour-item:has(.photo-tour-caption)::after {
  content: '';
  position: absolute;
  inset: auto 0 0 0;
  z-index: 1;
  height: 45%;
  background: linear-gradient(to top, rgba(15, 20, 17, 0.6), transparent);
  pointer-events: none;
}
.photo-tour-caption {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 14px;
  z-index: 2;
  color: #fff;
  font-family: var(--font-body);
  font-size: 0.88rem;
  font-weight: 600;
  line-height: 1.35;
  text-align: left;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.4);
  overflow-wrap: anywhere;
}
.photo-tour-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  padding: 4px 11px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  color: var(--site-deep);
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  pointer-events: none;
}
.photo-tour-badge--play {
  top: 50%;
  left: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  padding: 0;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  color: var(--site-deep);
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.3);
}
.photo-tour-badge--play svg { width: 24px; height: 24px; margin-left: 3px; }
@keyframes photoTourShimmer {
  from { background-position: 120% 0; }
  to { background-position: -120% 0; }
}

/* Tablets and small laptops. */
@media (max-width: 900px) {
  .photo-tour-grid { gap: 12px; padding-left: max(20px, env(safe-area-inset-left, 0px)); padding-right: max(20px, env(safe-area-inset-right, 0px)); }
}
/* Phones: square pairs and a 3:2 wide photo, buttons shrink to their icons. */
@media (max-width: 560px) {
  .photo-tour-bar { gap: 10px; }
  .photo-tour-grid {
    gap: 8px;
    padding: 12px max(12px, env(safe-area-inset-right, 0px)) calc(32px + env(safe-area-inset-bottom, 0px)) max(12px, env(safe-area-inset-left, 0px));
  }
  .photo-tour-item { aspect-ratio: 1 / 1; border-radius: 16px; scroll-margin-top: calc(76px + env(safe-area-inset-top, 0px)); }
  .photo-tour-item.is-wide { aspect-ratio: 3 / 2; }
  .photo-tour-caption { left: 12px; right: 12px; bottom: 10px; font-size: 0.8rem; }
  .photo-tour-item:not(.is-wide) .photo-tour-caption {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .photo-tour-close { padding: 0; }
  .photo-tour-close span,
  .photo-tour-contact span {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }
  .photo-tour-contact { padding: 0; }
}
/* Phones: the one-by-one viewer fills the screen edge to edge (no small box on black). */
@media (max-width: 720px) {
  .gallery-modal { padding: 0; }
  .gallery-modal-close { top: calc(12px + env(safe-area-inset-top, 0px)); right: max(12px, env(safe-area-inset-right, 0px)); }
  .gallery-modal .gallery-viewport { border-radius: 0; background: transparent; }
  .gallery-modal .gallery-slide-img { aspect-ratio: auto; height: 78vh; height: 78dvh; background: transparent; }
  .gallery-modal .gallery-caption { color: rgba(255, 255, 255, 0.85); padding: 0 16px; }
  .gallery-modal .gallery-counter { bottom: 12px; }
}
/* Dual-screen phones: the tour and the viewer stay on the first screen, clear of the hinge. */
@media (horizontal-viewport-segments: 2) {
  .photo-tour, .gallery-modal { right: auto; width: env(viewport-segment-width 0 0); }
}
@media (vertical-viewport-segments: 2) {
  .photo-tour, .gallery-modal { bottom: auto; height: env(viewport-segment-height 0 0); }
}
@media (prefers-reduced-motion: reduce) {
  .photo-tour, .photo-tour-item img, .photo-tour-item video, .gallery-all-btn { transition: none; }
  .photo-tour { transform: none; }
  .photo-tour-item { animation: none; }
  .photo-tour-item img, .photo-tour-item video { transform: none; }
}

/* ---------- Listing page: the brochure button (property.html brochureHTML, seo-render.js) ---------- */
.property-brochure {
  margin: var(--space-3) 0;
}
.property-brochure-btn {
  max-width: 100%;
  white-space: normal;
  text-align: left;
}
.property-brochure-btn span {
  min-width: 0;
  overflow-wrap: anywhere;
}

/* ---------- ¿Cuánto vale mi propiedad? (home-value.html) ---------- */
.hv-page { padding-top: var(--space-6); padding-bottom: var(--space-6); max-width: 920px; }
.hv-page h1 { margin: 6px 0 8px; font-size: clamp(1.7rem, 4vw, 2.4rem); }
.hv-lead { margin: 0 0 var(--space-4); color: var(--color-text-muted); max-width: 62ch; font-size: 1.02rem; }
.hv-form {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr));
  gap: 0 var(--space-3);
  padding: var(--space-4);
  border-radius: var(--site-radius);
  background: var(--site-surface);
  box-shadow: var(--site-shadow-sm);
}
.hv-form .field { min-width: 0; }
.hv-form select, .hv-form input { width: 100%; font-size: 1rem; min-height: 44px; }
.hv-form .field[hidden] { display: none; }
.hv-actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: var(--space-2); }
.hv-actions .btn { min-height: 48px; }
.hv-form .form-error { grid-column: 1 / -1; margin: var(--space-2) 0 0; }
.hv-result { margin-top: var(--space-4); }
.hv-card { padding: var(--space-4); border-radius: var(--site-radius); background: var(--site-surface); box-shadow: var(--site-shadow-sm); min-width: 0; }
.hv-card h2 { margin: 0 0 6px; font-size: 1.2rem; }
.hv-card--empty p { margin: 0; color: var(--color-text-muted); }
.hv-label { margin: 0; font-size: 0.85rem; font-weight: 700; color: var(--color-text-muted); text-transform: uppercase; letter-spacing: 0.04em; }
.hv-value { margin: 4px 0; font-family: var(--font-body); font-size: clamp(2rem, 6vw, 3rem); font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.hv-range { margin: 0; font-weight: 600; }
.hv-basis { margin: 8px 0 var(--space-3); color: var(--color-text-muted); font-size: 0.92rem; max-width: 70ch; }
.hv-sources { margin: 0 0 var(--space-3); color: var(--color-text-muted); font-size: 0.85rem; overflow-wrap: anywhere; }
.hv-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 var(--space-3); padding: 0; list-style: none; }
.hv-chips li { padding: 4px 12px; border-radius: 999px; background: var(--site-chip); font-size: 0.84rem; font-weight: 600; }
.hv-sub { margin: var(--space-3) 0 var(--space-2); font-size: 1rem; }
.hv-examples { margin: 0 0 var(--space-3); padding: 0; list-style: none; display: grid; gap: 10px; }
.hv-examples li { display: flex; flex-direction: column; gap: 2px; min-width: 0; padding-bottom: 10px; border-bottom: 1px solid var(--site-line); }
.hv-examples a, .hv-examples span { overflow-wrap: anywhere; }
.hv-ex-meta { font-size: 0.84rem; color: var(--color-text-muted); }
.hv-disclaimer { margin: var(--space-3) 0 0; font-size: 0.82rem; color: var(--color-text-muted); max-width: 75ch; }

/* The ⓘ beside a listing detail's label (Año de remodelación): the bubble spans the detail's own
   box instead of centring on the icon, so it never runs off a 375 px screen. */
.detail-rows > div { position: relative; min-width: 0; }
.detail-rows .field-info { position: static; }
.detail-rows .field-info-text { left: 0; right: 0; width: auto; max-width: none; transform: none; }

/* "Publicado por" under the title with collaborators (property.html listedByHTML): the same
   stack as the contact card, small enough to sit on the line; the text wraps beside it. */
.property-listed-team {
  align-items: center;
  flex-wrap: wrap;
  row-gap: 6px;
}
.property-listed-team > span:last-child { min-width: 0; flex: 1 1 12rem; }
.agent-stack--sm { padding: 2px 0 2px 2px; }
.agent-stack--sm .agent-bubble { --bubble: 1.75rem; box-shadow: 0 0 0 2px var(--site-surface), 0 3px 8px -4px rgba(35, 45, 39, 0.45); }
.agent-stack--sm .agent-bubble.is-lead { --bubble: 2rem; box-shadow: 0 0 0 1.5px var(--site-surface), 0 0 0 3px var(--color-gold); }
.agent-stack--sm .agent-bubble-initials { font-size: 0.62rem; }
.agent-stack--sm .agent-bubble--more { font-size: 0.66rem; }
.agent-stack--sm:hover .agent-bubble:not(:first-child),
.agent-stack--sm:focus-within .agent-bubble:not(:first-child) { margin-left: 3px; }
.property-listed-with a { font-weight: 600; color: inherit; }

/* Text a person typed with line breaks (a listing's description, an agent's bio) shows them as typed:
   one break is a new line, a blank line a gap, like the box they wrote it in. */
.text-multiline {
  white-space: pre-line;
  overflow-wrap: anywhere;
}

/* ---------- Lista de espera (contact.html while Settings › Stripe › "Mostrar planes" is off) ----------
   The server marks <html data-plans="waitlist|open"> (server/plans-visibility.js): in waitlist mode
   the plan sections are hidden and the waitlist shows; otherwise the waitlist is hidden. */
html[data-plans="waitlist"] .plans-hero,
html[data-plans="waitlist"] #plans,
html[data-plans="waitlist"] .plans-faq,
html[data-plans="waitlist"] .plans-cta { display: none; }
html:not([data-plans="waitlist"]) .wl,
html:not([data-plans="waitlist"]) .wl-preview { display: none; }

.wl {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  background: radial-gradient(120% 90% at 20% 0%, #3a4c40 0%, var(--site-deep) 60%);
  color: var(--color-white);
  padding: clamp(40px, 7vw, 88px) 0 clamp(48px, 8vw, 104px);
}
.wl::before {
  content: '';
  position: absolute;
  inset: 0;
  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;
  -webkit-mask-image: radial-gradient(80% 70% at 30% 20%, #000 0%, transparent 80%);
  mask-image: radial-gradient(80% 70% at 30% 20%, #000 0%, transparent 80%);
  z-index: -1;
  pointer-events: none;
}
.wl-bg { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.wl-orb { position: absolute; border-radius: 50%; filter: blur(60px); opacity: 0.55; animation: wl-float 14s ease-in-out infinite; }
.wl-orb--a { width: 420px; height: 420px; left: -120px; top: -140px; background: rgba(201, 162, 39, 0.45); }
.wl-orb--b { width: 360px; height: 360px; right: -100px; bottom: -160px; background: rgba(76, 106, 85, 0.75); animation-delay: -5s; }
.wl-orb--c { width: 220px; height: 220px; right: 30%; top: 10%; background: rgba(239, 220, 156, 0.22); animation-delay: -9s; }
@keyframes wl-float {
  0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(30px, 24px, 0) scale(1.08); }
}

.wl-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
}
.wl-copy { display: flex; flex-direction: column; align-items: flex-start; gap: 20px; min-width: 0; }
.wl-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  max-width: 100%;
  padding: 7px 16px 7px 12px;
  border-radius: 999px;
  border: 1px solid rgba(228, 199, 101, 0.4);
  background: rgba(255, 255, 255, 0.06);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: var(--color-gold-soft);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.wl-pulse { position: relative; width: 10px; height: 10px; flex: none; border-radius: 50%; background: #5fd38d; }
.wl-pulse::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid #5fd38d;
  animation: wl-ping 1.8s cubic-bezier(0, 0, 0.2, 1) infinite;
}
@keyframes wl-ping { 0% { transform: scale(0.6); opacity: 0.9; } 100% { transform: scale(1.9); opacity: 0; } }
.wl-title {
  margin: 0;
  font-size: clamp(2rem, 5.2vw, 3.5rem);
  line-height: 1.08;
  color: var(--color-white);
  overflow-wrap: anywhere;
}
.wl-rotator { display: block; min-height: 1.15em; }
.wl-rotator-word {
  display: inline-block;
  background: linear-gradient(90deg, #efdc9c 0%, var(--color-gold) 60%, #f6e7b5 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  transition: opacity 0.35s ease, transform 0.35s ease;
}
.wl-rotator-word.is-out { opacity: 0; transform: translateY(0.35em); }
.wl-lead { margin: 0; max-width: 560px; font-size: clamp(1rem, 1.6vw, 1.15rem); line-height: 1.6; color: rgba(236, 231, 221, 0.85); }
.wl-perks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.wl-perks li { display: flex; align-items: center; gap: 12px; min-width: 0; color: rgba(255, 255, 255, 0.92); }
.wl-perk-icon {
  display: inline-flex; align-items: center; justify-content: center; flex: none;
  width: 34px; height: 34px; border-radius: 10px;
  background: rgba(201, 162, 39, 0.16); border: 1px solid rgba(228, 199, 101, 0.35); color: var(--color-gold-soft);
}
.wl-perk-icon svg { width: 17px; height: 17px; }
.wl-social { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; margin: 4px 0 0; color: rgba(236, 231, 221, 0.9); font-weight: 600; }
.wl-social[hidden] { display: none; }
.wl-social-faces { display: inline-flex; }
.wl-social-faces span {
  width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--site-deep); margin-left: -8px;
  background: linear-gradient(140deg, #efdc9c, var(--color-gold));
}
.wl-social-faces span:first-child { margin-left: 0; background: linear-gradient(140deg, #8fb79a, #4c6a55); }
.wl-social-faces span:nth-child(3) { background: linear-gradient(140deg, #d9cfbd, #9a8f7a); }
.wl-social-faces span:nth-child(4) { background: linear-gradient(140deg, #6f8f78, #2f3b34); }

.wl-card {
  position: relative;
  scroll-margin-top: 88px;
  min-width: 0;
  background: var(--site-surface);
  color: var(--color-text);
  border-radius: 24px;
  padding: clamp(20px, 3.4vw, 34px);
  box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(228, 199, 101, 0.35);
}
.wl-card::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(140deg, rgba(228, 199, 101, 0.9), rgba(228, 199, 101, 0) 40%, rgba(228, 199, 101, 0) 60%, rgba(228, 199, 101, 0.7));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}
.wl-card-title { margin: 0 0 16px; font-size: 1.35rem; color: var(--color-ink); }
.wl-progress { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.wl-progress-bar { flex: 1 1 auto; min-width: 0; height: 6px; border-radius: 999px; background: var(--site-chip); overflow: hidden; }
.wl-progress-bar span {
  display: block; height: 100%; width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, #4c6a55, var(--color-gold));
  transition: width 0.45s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.wl-progress-text { flex: none; font-size: 0.78rem; font-weight: 700; color: var(--color-text-muted); white-space: nowrap; }
.wl-card .field input:not(.phone-number-input) { width: 100%; }
.wl-card .phone-field { width: 100%; min-width: 0; }
.wl-card .phone-number-input { flex: 1 1 auto; min-width: 0; }
.wl-field-hint { display: block; min-height: 1em; margin-top: 4px; font-size: 0.8rem; color: var(--color-text-muted); }
.wl-field-hint.is-ok { color: var(--color-success); }
.wl-fieldset { border: 0; margin: 0 0 16px; padding: 0; min-width: 0; }
.wl-fieldset legend { padding: 0; margin-bottom: 10px; font-weight: 600; font-size: 0.92rem; color: var(--color-ink); }
.wl-choices { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.wl-choice { position: relative; display: block; min-width: 0; cursor: pointer; margin: 0; }
.wl-choice input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.wl-choice-box {
  display: flex; align-items: center; gap: 10px; min-width: 0; height: 100%;
  padding: 12px; border-radius: 14px;
  border: 1.5px solid var(--site-line); background: var(--site-field);
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}
.wl-choice:hover .wl-choice-box { border-color: var(--color-gold); transform: translateY(-1px); }
.wl-choice input:focus-visible + .wl-choice-box { outline: 2px solid var(--color-gold); outline-offset: 2px; }
.wl-choice input:checked + .wl-choice-box {
  border-color: var(--color-gold);
  background: linear-gradient(140deg, rgba(239, 220, 156, 0.35), rgba(255, 255, 255, 0.9));
  box-shadow: 0 8px 22px -12px rgba(201, 162, 39, 0.9);
}
.wl-choice-icon {
  display: inline-flex; align-items: center; justify-content: center; flex: none;
  width: 34px; height: 34px; border-radius: 10px; background: var(--site-surface); color: var(--color-ink);
  border: 1px solid var(--site-line); transition: background 0.2s ease, color 0.2s ease;
}
.wl-choice-icon svg { width: 17px; height: 17px; }
.wl-choice input:checked + .wl-choice-box .wl-choice-icon { background: var(--color-ink); color: var(--color-gold-soft); border-color: var(--color-ink); }
.wl-choice-text { min-width: 0; font-size: 0.9rem; font-weight: 600; line-height: 1.3; color: var(--color-ink); overflow-wrap: anywhere; }
.wl-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.wl-chip { position: relative; margin: 0; cursor: pointer; max-width: 100%; }
.wl-chip input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.wl-chip-box {
  display: inline-flex; align-items: center; gap: 6px; max-width: 100%;
  padding: 8px 14px; border-radius: 999px;
  border: 1.5px solid var(--site-line); background: var(--site-chip);
  font-size: 0.86rem; font-weight: 600; color: var(--color-ink);
  transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
}
.wl-chip-box svg { width: 15px; height: 15px; flex: none; }
.wl-chip-box span { min-width: 0; overflow-wrap: anywhere; }
.wl-chip:hover .wl-chip-box { border-color: var(--color-gold); }
.wl-chip input:focus-visible + .wl-chip-box { outline: 2px solid var(--color-gold); outline-offset: 2px; }
.wl-chip input:checked + .wl-chip-box { background: var(--color-ink); border-color: var(--color-ink); color: var(--color-white); }
.wl-source-other { margin: 10px 0 0; }
.wl-source-other[hidden] { display: none; }
.wl-trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.wl-submit {
  position: relative; overflow: hidden;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; min-height: 52px; font-size: 1rem; border-radius: 14px;
}
.wl-submit::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, 0.35) 50%, transparent 70%);
  transform: translateX(-100%);
  animation: wl-shine 3.2s ease-in-out infinite;
  pointer-events: none;
}
@keyframes wl-shine { 0%, 55% { transform: translateX(-100%); } 100% { transform: translateX(100%); } }
.wl-submit-arrow svg { width: 18px; height: 18px; transition: transform 0.2s ease; }
.wl-submit:hover .wl-submit-arrow svg { transform: translateX(4px); }
.wl-submit[disabled] { opacity: 0.7; cursor: progress; }
.wl-fineprint { margin: 10px 0 0; font-size: 0.8rem; text-align: center; color: var(--color-text-muted); }

.wl-done { text-align: center; padding: 8px 0; outline: none; }
.wl-done[hidden] { display: none; }
.wl-done-check { display: inline-flex; width: 76px; height: 76px; margin-bottom: 12px; }
.wl-done-check svg { width: 100%; height: 100%; }
.wl-done-check circle { fill: none; stroke: var(--color-gold); stroke-width: 3; stroke-dasharray: 152; stroke-dashoffset: 152; animation: wl-draw 0.7s ease forwards; }
.wl-done-check path { fill: none; stroke: var(--color-ink); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 40; stroke-dashoffset: 40; animation: wl-draw 0.45s 0.55s ease forwards; }
@keyframes wl-draw { to { stroke-dashoffset: 0; } }
.wl-done-title { margin: 0 0 8px; font-size: 1.6rem; color: var(--color-ink); }
.wl-done-spot {
  display: inline-block; margin: 0 0 12px; padding: 6px 16px; border-radius: 999px;
  background: var(--color-ink); color: var(--color-gold-soft); font-weight: 800; letter-spacing: 0.02em;
}
.wl-done-spot[hidden] { display: none; }
.wl-done-text { margin: 0 auto 18px; max-width: 420px; color: var(--color-text-muted); line-height: 1.55; }
.wl-share-label { margin: 0 0 10px; font-weight: 600; color: var(--color-ink); font-size: 0.9rem; }
.wl-share { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.wl-share-btn { display: inline-flex; align-items: center; gap: 8px; border-radius: 999px; }
.wl-share-btn svg { width: 17px; height: 17px; }

.wl-confetti { position: absolute; inset: 0; overflow: hidden; pointer-events: none; border-radius: inherit; }
.wl-confetti i {
  position: absolute; top: -12px; width: 8px; height: 14px; border-radius: 2px;
  animation: wl-fall var(--d, 1.8s) cubic-bezier(0.2, 0.6, 0.4, 1) forwards;
}
@keyframes wl-fall {
  0% { transform: translate3d(0, 0, 0) rotate(0); opacity: 1; }
  100% { transform: translate3d(var(--x, 0), 520px, 0) rotate(var(--r, 540deg)); opacity: 0; }
}

.wl-preview { padding: clamp(40px, 6vw, 72px) 0; }
.wl-preview-head { text-align: center; max-width: 640px; margin: 0 auto 24px; }
.wl-preview-head h2 { margin: 0 0 8px; font-size: clamp(1.5rem, 3vw, 2.1rem); }
.wl-preview-head p { margin: 0; color: var(--color-text-muted); }
.wl-tabs {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 8px;
  margin: 0 auto 22px; padding: 6px; border-radius: 999px; width: fit-content; max-width: 100%;
  background: var(--site-surface); box-shadow: var(--site-shadow-sm);
}
.wl-tab {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px;
  padding: 8px 18px; border: 0; border-radius: 999px; background: transparent;
  font: inherit; font-weight: 600; color: var(--color-text-muted); cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}
.wl-tab svg { width: 17px; height: 17px; flex: none; }
.wl-tab:hover { color: var(--color-ink); }
.wl-tab:focus-visible { outline: 2px solid var(--color-gold); outline-offset: 2px; }
.wl-tab[aria-selected="true"] { background: var(--color-ink); color: var(--color-white); }
.wl-panel { outline: none; }
.wl-features { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.wl-feature {
  min-width: 0; padding: 22px; border-radius: var(--site-radius);
  background: var(--site-surface); box-shadow: var(--site-shadow-sm);
  border: 1px solid transparent;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  animation: wl-rise 0.45s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}
.wl-feature:nth-child(2) { animation-delay: 0.06s; }
.wl-feature:nth-child(3) { animation-delay: 0.12s; }
.wl-feature:nth-child(4) { animation-delay: 0.18s; }
.wl-feature:hover { transform: translateY(-3px); box-shadow: var(--site-shadow-lg); border-color: rgba(201, 162, 39, 0.5); }
.wl-feature-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 42px; height: 42px; margin-bottom: 12px; border-radius: 12px;
  background: linear-gradient(140deg, var(--color-ink) 0%, #4c6a55 70%, var(--color-gold) 160%); color: var(--color-gold-soft);
}
.wl-feature-icon svg { width: 20px; height: 20px; }
.wl-feature h3 { margin: 0 0 6px; font-size: 1.02rem; color: var(--color-ink); overflow-wrap: anywhere; }
.wl-feature p { margin: 0; font-size: 0.9rem; line-height: 1.5; color: var(--color-text-muted); overflow-wrap: anywhere; }
@keyframes wl-rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.wl-preview-cta { display: flex; justify-content: center; margin-top: 26px; }

@media (max-width: 980px) {
  .wl-features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .wl-inner { grid-template-columns: minmax(0, 1fr); }
  .wl-copy { align-items: stretch; }
  .wl-badge { align-self: flex-start; }
}
@media (max-width: 480px) {
  .wl-choices { grid-template-columns: minmax(0, 1fr); }
  .wl-features { grid-template-columns: minmax(0, 1fr); }
  .wl-tabs { border-radius: 18px; width: 100%; }
  .wl-tab { flex: 1 1 calc(50% - 8px); justify-content: center; padding: 8px 10px; }
}
@media (prefers-reduced-motion: reduce) {
  .wl-orb, .wl-pulse::after, .wl-submit::after, .wl-feature, .wl-confetti i { animation: none; }
  .wl-done-check circle, .wl-done-check path { animation: none; stroke-dashoffset: 0; }
  .wl-rotator-word, .wl-choice-box, .wl-feature, .wl-progress-bar span { transition: none; }
}
