/* ============================================================================
   WrightHaven Homes — "Find Your Lot" interactive site plan
   ----------------------------------------------------------------------------
   Styles for the Pasture Edge site-plan explorer: a framed, spotlight-on-hover
   site plan with invisible per-lot hit areas, a feathered mask-based scrim,
   a glow + pin + tooltip overlay, a legend that doubles as a filter, a
   horizontal jump-to-lot chip rail, and a lot-detail card (right drawer on
   desktop, bottom sheet on mobile).

   Loaded only on the Pasture Edge page, after the site CSS. Everything is
   namespaced .wh-siteplan / .wh-lotcard so it can't leak into the
   Elementor-generated markup around it.

   Design tokens come from the site-wide :root (see DESIGN.md):
     --wh-ink --wh-green --wh-gold --wh-tan --wh-white --wh-dark-gray
     --wh-font-heading --wh-font-body --wh-radius

   The section sits on the site's dark #141414 background, so all text here
   is light-on-dark with gold/tan accents.

   Behaviour classes toggled by assets/wh-siteplan.js:
     on .wh-siteplan .......... .is-spotlight .is-groupmode .is-filtered
     on .wh-siteplan__lot ..... .is-lit .is-dimmed .is-selected
     on .wh-siteplan__pin ..... .is-focusring
     on .wh-siteplan__chip .... .is-active
     on rail chips ............ .is-dimmed
     on .wh-siteplan__hint .... .is-hidden
     on .wh-lotcard ........... .is-open
     on body .................. .wh-modal-open
   ========================================================================== */

/* ---------------------------------------------------------------------------
   0. Registered custom properties — lets the spotlight hole RETARGET smoothly
      (180ms) when the pointer moves between adjacent lots. Browsers without
      @property simply snap instantly, which is an acceptable fallback (and is
      also the reduced-motion behaviour).
   ------------------------------------------------------------------------- */
@property --wh-spot-x {
  syntax: '<length-percentage>';
  inherits: false;
  initial-value: 50%;
}
@property --wh-spot-y {
  syntax: '<length-percentage>';
  inherits: false;
  initial-value: 50%;
}
@property --wh-spot-rx {
  syntax: '<length-percentage>';
  inherits: false;
  initial-value: 12%;
}
@property --wh-spot-ry {
  syntax: '<length-percentage>';
  inherits: false;
  initial-value: 14%;
}

/* ---------------------------------------------------------------------------
   1. Section-local variables
   ------------------------------------------------------------------------- */
.wh-siteplan,
.wh-lotcard {
  --wh-sp-line: rgba(154, 140, 87, 0.3);        /* gold @ 30% — frame border   */
  --wh-sp-line-soft: rgba(192, 181, 155, 0.16); /* tan @ 16% — hairlines       */
  --wh-sp-matte: #1d1e1e;                       /* one step up from #141414    */
  --wh-sp-matte-2: #232424;
  --wh-sp-text: rgba(255, 255, 255, 0.92);
  --wh-sp-text-dim: rgba(255, 255, 255, 0.6);
  --wh-sp-ease: cubic-bezier(0.22, 0.72, 0.22, 1);
  --wh-sp-glow: rgba(154, 140, 87, 0.55);       /* gold glow core              */
}

.wh-siteplan {
  position: relative;
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 24px 48px;
  font-family: var(--wh-font-body);
  color: var(--wh-sp-text);
}

/* ---------------------------------------------------------------------------
   1b. Button reset — the site's global Elementor kit styles every raw
   <button> with a solid gold fill, 15px/20px padding, and 18px bold
   uppercase text (".elementor-kit-5 button {...}"). That selector's
   specificity (one class + one element) beats a plain single-class
   selector like ".wh-siteplan__chip", so every button in this feature
   (legend chips, chip-rail items, lot-card close/nav) would otherwise
   render with the theme's button chrome instead of this feature's own
   styling. Reset the leaking properties here, once, with !important;
   every component rule below layers its real look on top normally.
   ------------------------------------------------------------------------- */
.wh-siteplan button,
.wh-lotcard button {
  margin: 0 !important;
  font-family: var(--wh-font-body) !important;
  font-weight: 400 !important;
  text-transform: none !important;
  border-radius: 0 !important;
}

/* ---------------------------------------------------------------------------
   2. Legend chips (filter) + legend note
   ------------------------------------------------------------------------- */
.wh-siteplan__legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 10px;
}

.wh-siteplan__chip {
  appearance: none !important;
  -webkit-appearance: none !important;
  display: inline-flex !important;
  align-items: center;
  gap: 7px;
  padding: 8px 16px !important;
  background: transparent !important;
  border: 1px solid var(--wh-sp-line-soft) !important;
  border-radius: 999px !important;
  color: var(--wh-sp-text-dim) !important;
  font-family: var(--wh-font-body);
  font-size: 13px !important;
  letter-spacing: 0.06em;
  text-transform: uppercase !important;
  cursor: pointer;
  transition: color 0.18s var(--wh-sp-ease),
              border-color 0.18s var(--wh-sp-ease),
              background-color 0.18s var(--wh-sp-ease);
}

.wh-siteplan__chip span {
  font-size: 11px;
  color: var(--wh-tan);
  opacity: 0.85;
}

.wh-siteplan__chip:hover {
  color: var(--wh-white) !important;
  border-color: var(--wh-gold) !important;
}

.wh-siteplan__chip.is-active {
  color: var(--wh-ink) !important;
  background: var(--wh-gold) !important;
  border-color: var(--wh-gold) !important;
}

.wh-siteplan__chip.is-active span {
  color: var(--wh-ink);
  opacity: 0.75;
}

.wh-siteplan__chip:focus-visible {
  outline: 2px solid var(--wh-gold);
  outline-offset: 2px;
}

.wh-siteplan__legend-note {
  min-height: 1.4em;             /* reserve the line so the frame never jumps */
  margin: 0 0 16px;
  font-size: 13px;
  line-height: 1.4;
  color: var(--wh-tan);
  opacity: 0;
  transition: opacity 0.18s var(--wh-sp-ease);
}

.wh-siteplan__legend-note.is-visible { opacity: 1; }

/* ---------------------------------------------------------------------------
   3. The framed stage
   ------------------------------------------------------------------------- */
.wh-siteplan__frame {
  position: relative;
  border: 1px solid var(--wh-sp-line);
  border-radius: var(--wh-radius);
  background: var(--wh-sp-matte);
  padding: 14px;                                 /* dark matte around the plan */
}

.wh-siteplan__scroll {
  overflow: hidden;             /* desktop: everything fits, nothing to pan   */
  border-radius: var(--wh-radius);
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: var(--wh-sp-line) transparent;
}

.wh-siteplan__stage {
  position: relative;
  isolation: isolate;           /* keep the screen-blend glow inside the plan */
  line-height: 0;
}

.wh-siteplan__img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--wh-radius);
}

/* --- overlay layers (stacked over the image) ----------------------------- */

/* Scrim: a dark veil punched through by a feathered radial-gradient mask.
   The mask hole follows the hovered lot via the four registered custom
   properties above; JS only ever writes those properties + toggles the
   .is-spotlight / .is-groupmode / .is-filtered classes on .wh-siteplan. */
.wh-siteplan__scrim {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: rgba(10, 10, 10, 0.62);
  opacity: 0;
  --wh-spot-x: 50%;
  --wh-spot-y: 50%;
  --wh-spot-rx: 12%;
  --wh-spot-ry: 14%;
  -webkit-mask-image: radial-gradient(
    ellipse var(--wh-spot-rx) var(--wh-spot-ry) at var(--wh-spot-x) var(--wh-spot-y),
    transparent 0%, transparent 55%, rgba(0, 0, 0, 0.85) 85%, #000 100%
  );
  mask-image: radial-gradient(
    ellipse var(--wh-spot-rx) var(--wh-spot-ry) at var(--wh-spot-x) var(--wh-spot-y),
    transparent 0%, transparent 55%, rgba(0, 0, 0, 0.85) 85%, #000 100%
  );
  transition: opacity 0.22s var(--wh-sp-ease),
              --wh-spot-x 0.18s var(--wh-sp-ease),
              --wh-spot-y 0.18s var(--wh-sp-ease),
              --wh-spot-rx 0.18s var(--wh-sp-ease),
              --wh-spot-ry 0.18s var(--wh-sp-ease);
}

.wh-siteplan.is-spotlight .wh-siteplan__scrim { opacity: 1; }

/* Group / filter modes: the scrim is only lightly dimmed and has NO hole —
   the matched lots' own glows (see .is-lit below) sit above it instead. */
.wh-siteplan.is-groupmode .wh-siteplan__scrim,
.wh-siteplan.is-filtered .wh-siteplan__scrim {
  opacity: 0.55;
  -webkit-mask-image: none;
  mask-image: none;
}

/* Glow: a warm gold radial that rides the spotlight, screen-blended so it
   brightens the plan underneath rather than painting over it. */
.wh-siteplan__glow {
  position: absolute;
  z-index: 3;
  left: 50%;
  top: 50%;
  width: 12%;
  height: 14%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  border-radius: 50%;
  background: radial-gradient(closest-side, var(--wh-sp-glow), rgba(154, 140, 87, 0) 72%);
  mix-blend-mode: screen;
  opacity: 0;
  transition: opacity 0.22s var(--wh-sp-ease),
              left 0.18s var(--wh-sp-ease),
              top 0.18s var(--wh-sp-ease),
              width 0.18s var(--wh-sp-ease),
              height 0.18s var(--wh-sp-ease);
}

.wh-siteplan.is-spotlight .wh-siteplan__glow { opacity: 1; }
.wh-siteplan.is-groupmode .wh-siteplan__glow,
.wh-siteplan.is-filtered .wh-siteplan__glow { opacity: 0; } /* single glow off in group modes */

/* Pin: a small gold SQUARE at the lot's centre (matches the square lot
   markers on the plan art). Gains a ring when keyboard-focused. */
.wh-siteplan__pin {
  position: absolute;
  z-index: 4;
  left: 50%;
  top: 50%;
  width: 12px;
  height: 12px;
  transform: translate(-50%, -50%);
  pointer-events: none;
  border-radius: 1px;
  background: rgba(154, 140, 87, 0.92);
  border: 1.5px solid rgba(255, 248, 220, 0.95);
  box-shadow:
    0 0 0 1px rgba(20, 20, 20, 0.45),
    0 0 10px rgba(154, 140, 87, 0.7);
  opacity: 0;
  transition: opacity 0.22s var(--wh-sp-ease),
              left 0.18s var(--wh-sp-ease),
              top 0.18s var(--wh-sp-ease);
}

.wh-siteplan.is-spotlight .wh-siteplan__pin { opacity: 1; }
.wh-siteplan.is-groupmode .wh-siteplan__pin,
.wh-siteplan.is-filtered .wh-siteplan__pin { opacity: 0; }
/* Sold lots keep their red S square — hide the gold pin over them. */
.wh-siteplan.is-spotlight.is-sold-spotlight .wh-siteplan__pin { opacity: 0; }

.wh-siteplan__pin.is-focusring {
  box-shadow:
    0 0 0 1px rgba(20, 20, 20, 0.45),
    0 0 0 4px rgba(154, 140, 87, 0.55),
    0 0 14px rgba(154, 140, 87, 0.85);
}

/* Tooltip: JS builds the contents and positions it above (or below, when the
   lot is near the top edge) the hovered lot. */
.wh-siteplan__tooltip {
  position: absolute;
  z-index: 6;
  max-width: 240px;
  padding: 10px 14px;
  pointer-events: none;
  background: rgba(20, 20, 20, 0.94);
  border: 1px solid var(--wh-sp-line);
  border-radius: var(--wh-radius);
  line-height: 1.4;
  transform: translate(-50%, calc(-100% - 10px));
  opacity: 0;
  transition: opacity 0.18s var(--wh-sp-ease);
}

.wh-siteplan__tooltip.is-visible { opacity: 1; }
.wh-siteplan__tooltip.is-below { transform: translate(-50%, 10px); }

.wh-siteplan__tooltip-lot {
  display: block;
  font-family: var(--wh-font-heading);
  font-weight: 300;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 15px;
  color: var(--wh-white);
  white-space: nowrap;
}

.wh-siteplan__tooltip-note {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  color: var(--wh-sp-text-dim);
}

/* Type badge — shared between tooltip, lot card, and legend note */
.wh-siteplan__badge {
  display: inline-block;
  margin-top: 6px;
  padding: 2px 9px;
  border: 1px solid var(--wh-gold);
  border-radius: 999px;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--wh-gold);
  white-space: nowrap;
}

/* --- the invisible lot hit-areas -----------------------------------------
   !important throughout: the site's global Elementor kit styles every raw
   <button> with a solid gold background + 15px/20px padding + 18px bold
   uppercase text (".elementor-kit-5 button {...}"). That rule's specificity
   (one class + one element) beats a plain ".wh-siteplan__lot" class selector,
   so without !important every one of these 40 hotspots renders as a solid
   gold box instead of an invisible hit-area.

   Available lots: invisible parcel hit-targets. On hover/spotlight the gold
   pin (dot) + scrim appear — no always-on squares. Sold lots keep a red
   outlined S box (see .is-sold below). */
.wh-siteplan__lot {
  position: absolute !important;
  z-index: 5 !important;
  appearance: none !important;
  -webkit-appearance: none !important;
  margin: 0 !important;
  padding: 0 !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 2px !important;
  cursor: pointer !important;
  font-size: 0 !important;
  line-height: 0 !important;
  -webkit-tap-highlight-color: transparent;
  transition: background-color 0.18s var(--wh-sp-ease),
              border-color 0.18s var(--wh-sp-ease),
              box-shadow 0.18s var(--wh-sp-ease);
}

/* Hover / selected / lit: no full-parcel box (angled clip-paths made those
   look skewed). Signal is the axis-aligned gold SQUARE pin (::after + the
   shared .wh-siteplan__pin), matching the square lot markers on the plan. */
.wh-siteplan__lot:hover {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

.wh-siteplan__lot:hover::after {
  opacity: 1;
}

/* Selected lot (detail card open) — square pin stays on */
.wh-siteplan__lot.is-selected {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

.wh-siteplan__lot.is-selected::before,
.wh-siteplan__lot.is-selected::after { opacity: 1; }

/* Deliberately no outline here: keyboard focus is surfaced by the identical
   spotlight + a ringed pin (see .is-focusring), which is far more visible on
   the busy plan than a rectangle outline would be. */
.wh-siteplan__lot:focus { outline: none; }
.wh-siteplan__lot:focus-visible { outline: none; }

/* Soft radial glow behind the square pin (legend filter / hover). */
.wh-siteplan__lot::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: 28px;
  height: 28px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: radial-gradient(closest-side, var(--wh-sp-glow), rgba(154, 140, 87, 0) 72%);
  mix-blend-mode: screen;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s var(--wh-sp-ease);
}

/* Gold square pin — same proportions as the sold S-boxes / plan markers. */
.wh-siteplan__lot::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: 12px;
  height: 12px;
  transform: translate(-50%, -50%);
  border-radius: 1px;
  background: rgba(154, 140, 87, 0.92);
  border: 1.5px solid rgba(255, 248, 220, 0.95);
  box-shadow:
    0 0 0 1px rgba(20, 20, 20, 0.45),
    0 0 10px rgba(154, 140, 87, 0.7);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s var(--wh-sp-ease),
              transform 0.16s var(--wh-sp-ease),
              box-shadow 0.16s var(--wh-sp-ease);
}

.wh-siteplan__lot:hover::after,
.wh-siteplan__lot.is-selected::after {
  transform: translate(-50%, -50%) scale(1.15);
  box-shadow:
    0 0 0 1px rgba(20, 20, 20, 0.45),
    0 0 14px rgba(154, 140, 87, 0.9);
}

.wh-siteplan__lot.is-lit::before,
.wh-siteplan__lot.is-lit::after { opacity: 1; }

/* Lit lots (legend hover / type filter): pulse the square pin, not a parcel box. */
@keyframes wh-lot-pulse {
  0%, 100% {
    box-shadow:
      0 0 0 1px rgba(20, 20, 20, 0.45),
      0 0 8px rgba(154, 140, 87, 0.55);
  }
  50% {
    box-shadow:
      0 0 0 2px rgba(154, 140, 87, 0.65),
      0 0 16px rgba(154, 140, 87, 0.9);
  }
}

.wh-siteplan__lot.is-lit {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  animation: none;
}
.wh-siteplan__lot.is-lit::after {
  animation: wh-lot-pulse 1.6s ease-in-out infinite;
}

/* Poly clip-path stays for hit-testing only; never draw a skewed outline. */
.wh-siteplan__lot.wh-lot--poly:hover,
.wh-siteplan__lot.wh-lot--poly.is-selected,
.wh-siteplan__lot.wh-lot--poly.is-lit {
  border: 0 !important;
  box-shadow: none !important;
  background: transparent !important;
}

/* Filtered-out lots: unlit and dim, but still clickable per spec. */
.wh-siteplan.is-filtered .wh-siteplan__lot.is-dimmed { opacity: 0.35; }

/* --- pan hint (mobile) ---------------------------------------------------- */
.wh-siteplan__hint {
  display: none;
  position: absolute;
  left: 50%;
  bottom: 26px;
  transform: translateX(-50%);
  z-index: 7;
  margin: 0;
  padding: 6px 14px;
  background: rgba(20, 20, 20, 0.8);
  border: 1px solid var(--wh-sp-line-soft);
  border-radius: 999px;
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--wh-tan);
  white-space: nowrap;
  pointer-events: none;
  transition: opacity 0.4s var(--wh-sp-ease);
}

.wh-siteplan__hint.is-hidden { opacity: 0; }

/* ---------------------------------------------------------------------------
   4. Chip rail — jump-to-lot
   ------------------------------------------------------------------------- */
.wh-siteplan__rail-label {
  margin: 18px 2px 0;
  font-family: var(--wh-font-body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--wh-sp-text-dim);
  transition: color 0.18s var(--wh-sp-ease);
}

.wh-siteplan__rail-label.is-active { color: var(--wh-gold); }

.wh-siteplan__chiprail {
  display: flex;
  gap: 8px;
  margin-top: 8px;
  padding: 4px 2px 10px;
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--wh-sp-line) transparent;
}

.wh-siteplan__railchip {
  flex: 0 0 auto;
  appearance: none !important;
  -webkit-appearance: none !important;
  width: 36px;
  height: 36px;
  padding: 0 !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  background: transparent !important;
  border: 1px solid var(--wh-sp-line-soft) !important;
  border-radius: 50% !important;
  color: var(--wh-sp-text-dim) !important;
  font-family: var(--wh-font-body);
  font-size: 13px !important;
  cursor: pointer;
  transition: color 0.18s var(--wh-sp-ease),
              border-color 0.18s var(--wh-sp-ease),
              background-color 0.18s var(--wh-sp-ease),
              opacity 0.18s var(--wh-sp-ease);
}

.wh-siteplan__railchip:hover {
  color: var(--wh-ink) !important;
  background: var(--wh-gold) !important;
  border-color: var(--wh-gold) !important;
}

.wh-siteplan__railchip:focus-visible {
  outline: 2px solid var(--wh-gold);
  outline-offset: 2px;
}

.wh-siteplan__railchip.is-dimmed { opacity: 0.3; }

/* ---------------------------------------------------------------------------
   5. Lot card — right drawer (desktop) / bottom sheet (mobile)
   ------------------------------------------------------------------------- */
.wh-lotcard {
  position: fixed;
  inset: 0;
  z-index: 9990;
  font-family: var(--wh-font-body);
  color: var(--wh-sp-text);
}

.wh-lotcard__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 10, 10, 0.6);
  opacity: 0;
  transition: opacity 0.25s var(--wh-sp-ease);
}

.wh-lotcard.is-open .wh-lotcard__backdrop { opacity: 1; }

.wh-lotcard__panel {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 380px;
  max-width: 92vw;
  display: flex;
  flex-direction: column;
  background: var(--wh-sp-matte);
  border-left: 1px solid var(--wh-sp-line);
  transform: translateX(100%);
  transition: transform 0.3s var(--wh-sp-ease);
  overflow: hidden;
}

.wh-lotcard.is-open .wh-lotcard__panel { transform: translateX(0); }

.wh-lotcard__close {
  position: absolute;
  top: 10px;
  right: 12px;
  z-index: 3;
  appearance: none !important;
  -webkit-appearance: none !important;
  width: 36px;
  height: 36px;
  padding: 0 !important;
  background: rgba(20, 20, 20, 0.7) !important;
  border: 1px solid var(--wh-sp-line-soft) !important;
  border-radius: 50% !important;
  color: var(--wh-white) !important;
  font-size: 20px !important;
  line-height: 1;
  cursor: pointer;
  transition: border-color 0.18s var(--wh-sp-ease), color 0.18s var(--wh-sp-ease);
}

.wh-lotcard__close:hover { border-color: var(--wh-gold) !important; color: var(--wh-gold) !important; }

.wh-lotcard__close:focus-visible,
.wh-lotcard__nav button:focus-visible {
  outline: 2px solid var(--wh-gold);
  outline-offset: 2px;
}

/* Zoomed crop of the site plan on the selected lot only (background-image
   position/size computed by JS from the lot's bbox). Clean crop — no reticle. */
.wh-lotcard__zoom {
  position: relative;
  overflow: hidden;
  flex: 0 0 240px;
  background-color: var(--wh-sp-matte-2);
  background-repeat: no-repeat;
  border-bottom: 1px solid var(--wh-sp-line);
}

/* Reticle retired — card zoom is a pure crop of the lot (no gold frame /
   dimming scrim). Keep the node in the DOM for older markup; hide it. */
.wh-lotcard__reticle {
  display: none !important;
}

.wh-lotcard__body {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 22px 24px 18px;
}

.wh-lotcard__header { margin-bottom: 14px; }

.wh-lotcard__title {
  margin: 0;
  font-family: var(--wh-font-heading);
  font-weight: 300;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 26px;
  color: var(--wh-white);
}

.wh-lotcard__type {
  margin: 10px 0 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--wh-sp-text-dim);
}

.wh-lotcard__disclosure {
  margin: 0 0 18px;
  padding-top: 14px;
  border-top: 1px solid var(--wh-sp-line-soft);
  font-size: 11.5px;
  line-height: 1.55;
  color: var(--wh-sp-text-dim);
}

/* Real home renderings, pulled from Walk the Street's own DOM — any of these
   16 designs can be discussed for this lot (per the disclosure above), so
   the strip is identical for every lot, not lot-specific inventory. */
.wh-lotcard__homes { margin-bottom: 18px; }

.wh-lotcard__homes-label {
  margin: 0 0 10px;
  font-family: var(--wh-font-heading);
  font-weight: 300;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 12px;
  color: var(--wh-sp-text-dim);
}

.wh-lotcard__homes-strip {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: thin;
  scrollbar-color: var(--wh-sp-line) transparent;
}

.wh-lotcard__home {
  /* was a <button> (scroll-to-street-card); now an <a> to the model's page */
  display: block;
  flex: 0 0 auto;
  width: 92px;
  appearance: none !important;
  -webkit-appearance: none !important;
  background: transparent !important;
  border: 0 !important;
  padding: 0 !important;
  cursor: pointer;
  text-align: left;
  text-decoration: none;
}

.wh-lotcard__home-img {
  display: block;
  width: 92px;
  height: 66px;
  object-fit: cover;
  border-radius: 3px;
  border: 1px solid var(--wh-sp-line-soft);
  transition: border-color 0.18s var(--wh-sp-ease);
}

.wh-lotcard__home:hover .wh-lotcard__home-img,
.wh-lotcard__home:focus-visible .wh-lotcard__home-img {
  border-color: var(--wh-gold);
}

.wh-lotcard__home-name {
  display: block;
  margin-top: 5px;
  font-size: 11px;
  color: var(--wh-sp-text-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.wh-lotcard__ctas {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.wh-lotcard__cta {
  display: block;
  padding: 12px 18px;
  border-radius: var(--wh-radius);
  text-align: center;
  text-decoration: none;
  font-size: 13px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transition: background-color 0.18s var(--wh-sp-ease),
              color 0.18s var(--wh-sp-ease),
              border-color 0.18s var(--wh-sp-ease);
}

.wh-lotcard__cta--primary {
  background: var(--wh-gold);
  color: var(--wh-ink);
  border: 1px solid var(--wh-gold);
}

.wh-lotcard__cta--primary:hover { background: var(--wh-tan); border-color: var(--wh-tan); }

.wh-lotcard__cta--secondary {
  background: transparent;
  color: var(--wh-tan);
  border: 1px solid var(--wh-tan);
}

.wh-lotcard__cta--secondary:hover { color: var(--wh-white); border-color: var(--wh-white); }

.wh-lotcard__nav {
  flex: 0 0 auto;
  display: flex;
  border-top: 1px solid var(--wh-sp-line-soft);
}

.wh-lotcard__nav button {
  flex: 1 1 50%;
  appearance: none;
  -webkit-appearance: none;
  padding: 12px 0;
  background: transparent;
  border: 0;
  color: var(--wh-tan);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  transition: background-color 0.18s var(--wh-sp-ease), color 0.18s var(--wh-sp-ease);
}

.wh-lotcard__nav button:hover { background: var(--wh-sp-matte-2); color: var(--wh-white); }
.wh-lotcard__nav button + button { border-left: 1px solid var(--wh-sp-line-soft); }

/* Body scroll lock while the lot card is open */
body.wh-modal-open { overflow: hidden; }

/* ---------------------------------------------------------------------------
   6. Responsive: mobile pannable stage + bottom-sheet lot card
   ------------------------------------------------------------------------- */
@media (max-width: 767px) {
  .wh-siteplan { padding: 0 14px 36px; }
  .wh-siteplan__frame { padding: 8px; }

  /* The plan becomes pannable: the stage keeps a readable minimum width and
     the wrapper scrolls horizontally. width:0 + min-width:100% zeroes the
     scroller's intrinsic width contribution — without it the 900px stage
     propagates up through the Elementor flex ancestors (flex min-width:auto)
     and stretches the WHOLE PAGE to ~1114px instead of panning inside the
     frame. */
  .wh-siteplan { max-width: 100%; min-width: 0; }
  .wh-siteplan__scroll {
    overflow: auto;
    width: 0;
    min-width: 100%;
  }
  .wh-siteplan__stage { min-width: 900px; }

  .wh-siteplan__hint { display: block; }

  /* No hover on touch, so invisible hotspots read as a dead image. Repurpose
     each lot's ::after pin as an always-visible numbered SQUARE marker so
     every tappable zone is obvious and matches the square sold/hover pins. */
  .wh-siteplan__lot::after {
    content: attr(data-wh-lot);
    width: 22px;
    height: 22px;
    border-radius: 1px;
    font-size: 11px !important;
    line-height: 20px !important;
    text-align: center;
    background: rgba(20, 20, 20, 0.82);
    color: var(--wh-tan);
    border: 1.5px solid rgba(255, 248, 220, 0.7);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
    opacity: 1;
  }

  /* Lit / selected markers flip gold (still square) */
  .wh-siteplan__lot.is-lit::after,
  .wh-siteplan__lot.is-selected::after {
    background: rgba(154, 140, 87, 0.95);
    color: var(--wh-ink);
    border-color: rgba(255, 248, 220, 0.95);
    box-shadow: 0 0 12px rgba(154, 140, 87, 0.8);
  }

  /* Lot card becomes a bottom sheet */
  .wh-lotcard__panel {
    top: auto;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    max-width: none;
    height: 70vh;
    max-height: 70dvh;
    border-left: 0;
    border-top: 1px solid var(--wh-sp-line);
    border-radius: 10px 10px 0 0;
    transform: translateY(100%);
  }

  .wh-lotcard.is-open .wh-lotcard__panel { transform: translateY(0); }

  .wh-lotcard__zoom { flex-basis: 180px; }
}

/* ---------------------------------------------------------------------------
   7. Reduced motion — collapse every transition to instant. JS also zeroes
      its own hover delays and uses instant (non-smooth) scrolls.
   ------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .wh-siteplan *,
  .wh-siteplan *::before,
  .wh-siteplan *::after,
  .wh-lotcard *,
  .wh-lotcard *::before,
  .wh-lotcard *::after,
  .wh-lotcard__backdrop,
  .wh-lotcard__panel,
  .wh-siteplan__scrim,
  .wh-siteplan__glow,
  .wh-siteplan__pin {
    transition: none !important;
    animation: none !important;
  }
  .wh-siteplan__scroll { scroll-behavior: auto !important; }
}

/* ==========================================================================
   Picker mode — only active when the site-plan is embedded in the floor-plan
   build flow ([data-wh-siteplan-picker]). Standalone Pasture Edge never sets
   these classes, so it is visually unchanged.
   ========================================================================== */
/* Sold lots: always-visible red SQUARE with "S" — same square language as
   the gold hover pins and the lot markers printed on the plan. */
.wh-siteplan__lot.is-sold {
  /* Fixed px size so the marker is a true square regardless of stage aspect */
  width: 16px !important;
  height: 16px !important;
  min-width: 16px !important;
  min-height: 16px !important;
  aspect-ratio: auto !important;
  margin: 0 !important;
  padding: 0 !important;
  background: rgba(190, 44, 44, 0.95) !important;
  border: 1.5px solid rgba(255, 255, 255, 0.95) !important;
  border-radius: 1px !important;
  box-shadow:
    0 0 0 1px rgba(20, 20, 20, 0.45),
    0 0 10px rgba(190, 44, 44, 0.55) !important;
  cursor: not-allowed !important;
  /* Kill any leftover parcel clip-path so the box stays axis-aligned.
     Centring uses inline transform: translate(-50%, -50%) from JS. */
  clip-path: none !important;
  -webkit-clip-path: none !important;
}

.wh-siteplan:not([data-wh-siteplan-picker]) .wh-siteplan__lot.is-sold {
  cursor: default !important;
}

/* No gold hover pin on sold — red S square is the only marker.
   Keep translate(-50%,-50%) from the inline style so the square stays centred. */
.wh-siteplan__lot.is-sold:hover {
  background: rgba(190, 44, 44, 0.95) !important;
  border: 1.5px solid rgba(255, 255, 255, 0.95) !important;
  box-shadow:
    0 0 0 1px rgba(20, 20, 20, 0.45),
    0 0 10px rgba(190, 44, 44, 0.55) !important;
}
.wh-siteplan__lot.is-sold::before,
.wh-siteplan__lot.is-sold::after {
  content: none !important;
  display: none !important;
  opacity: 0 !important;
  animation: none !important;
}

.wh-siteplan__soldtag {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 6;
  padding: 0;
  border-radius: 0;
  background: transparent;
  color: #fff;
  font-family: var(--wh-font-body);
  font-weight: 800;
  line-height: 1;
  letter-spacing: 0;
  text-transform: uppercase;
  white-space: nowrap;
  pointer-events: none;
  font-size: 0;
}
.wh-siteplan__soldtag::before {
  content: 'S';
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0;
  color: #fff;
  text-shadow: 0 0 2px rgba(0, 0, 0, 0.55);
}
.wh-siteplan__badge--sold {
  border-color: #be2c2c !important;
  background: #be2c2c !important;
  color: #fff !important;
}

/* In-progress status retired — hide any leftover tags/styles if markup
   still carries the attribute from an older deploy. */
.wh-siteplan__lot.is-in-progress {
  /* In-progress retired — treat like any available lot */
  cursor: pointer !important;
}
.wh-siteplan__progresstag,
.wh-siteplan__badge--progress {
  display: none !important;
}
.wh-siteplan__railchip.is-sold {
  opacity: 0.55;
  text-decoration: line-through;
}

.wh-siteplan__lot.is-committed {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}
.wh-siteplan__lot.is-committed::after {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.25);
  box-shadow:
    0 0 0 2px rgba(154, 140, 87, 0.65),
    0 0 16px rgba(154, 140, 87, 0.85);
}
.wh-lotcard__cta.is-disabled {
  opacity: 0.5;
  pointer-events: none;
}
/* Don't dim the whole map on hover in picker mode. The explorer's spotlight
   scrim darkens everything but the hovered lot — great for "exploring", but in
   a PICKER it reads as the map breaking/going dark every time you move the
   mouse. The per-lot :hover gold outline + the tooltip already say "this lot",
   and every other lot stays visible for scanning. Standalone Pasture Edge
   (no picker attr) keeps its spotlight. */
.wh-siteplan[data-wh-siteplan-picker].is-spotlight .wh-siteplan__scrim { opacity: 0 !important; }
.wh-siteplan[data-wh-siteplan-picker] .wh-siteplan__glow { display: none !important; }

/* ==========================================================================
   Picker mode, mobile — show the WHOLE plan fit-to-width instead of the
   pannable 900px keyhole, so buyers can see every lot at once in the build
   flow. Lot selection still works by tapping a lot or via the numbered chip
   rail. Gated to [data-wh-siteplan-picker], so the standalone Pasture Edge
   explorer keeps its designed pan UX untouched.
   ========================================================================== */
@media (max-width: 767px) {
  .wh-siteplan[data-wh-siteplan-picker] .wh-siteplan__scroll {
    overflow: hidden;
    width: auto;
    min-width: 0;
  }
  .wh-siteplan[data-wh-siteplan-picker] .wh-siteplan__stage { min-width: 0; }
  .wh-siteplan[data-wh-siteplan-picker] .wh-siteplan__hint { display: none; }
  /* Markers are sized for the 900px stage; at fit-to-width they'd overlap, so
     shrink them for the overview. Lot detail is one tap (or a chip) away. */
  .wh-siteplan[data-wh-siteplan-picker] .wh-siteplan__lot::after {
    width: 17px;
    height: 17px;
    font-size: 9px !important;
    line-height: 15px !important;
  }
}
