/* ============================================================
   HOMEPAGE — hero, search bar, category strip and the two-column band.
   Loaded by index.html after app.css, which still owns the listing rows,
   cards and footer this builds on top of.

   Layout note: content runs to a single reused gutter rather than a capped
   centred column, so a wide monitor does not read as dead margin.
   ============================================================ */
/* the homepage inherits the site container (css/site.css --page-max /
   --page-gutter) and keeps its own aliases for the rules below */
:root { --page-gutter: 20px; --page-max: 1560px;
         --bx-gutter: var(--page-gutter); --bx-max: var(--page-max); }

/* ---- 1. nav on white ---------------------------------------- */
#desktop-gate .dgn-wrap {
  position: sticky; top: 0; z-index: 50;
  background: #fff; border-bottom: 1px solid var(--grid, #E5E7EB);
  padding: 0;
}
#desktop-gate .dgn { box-shadow: none; }
/* The logo size and the nav's padding now live in css/site.css, so every page
   gets them — they were homepage-only, which is why the links sat at a
   different x here than everywhere else. */
#desktop-gate .dgn,
#desktop-gate .dg-listings,
#desktop-gate .dg-row,
/* The legal block belongs on the same rail as the rest of the footer. It was
   left behind on the older 1200px container while .dg-footer-inner moved to
   the homepage's, so the logo and the link columns sat 55px left of the CREA
   notice underneath them — the only page where the footer failed to line up
   with itself. .dg-footer-bottom is nested inside legal and follows it. */
#desktop-gate .dg-footer-legal,
#desktop-gate .dg-footer-inner {
  width: min(var(--bx-max), calc(100% - 2 * var(--bx-gutter)));
  max-width: none;
}

/* ---- 2. full-width shallow hero ------------------------------ */
.bx-hero-wrap { position: relative; }
.bx-hero {
  position: relative; isolation: isolate; overflow: hidden; color: #fff;
  /* the ground the photo's opacity resolves against */
  background: #03241B;
  /* Placeholder hero (2026-10-22): no photo yet — Eddie is supplying one and
     the client's listing photos are not to be used here. A dark-blue gradient
     carries the copy until then; swap the photo in and this layer sits under it. */
  background-image:
    radial-gradient(ellipse 60% 120% at 85% 20%, rgba(106, 161, 142, 0.55) 0%, rgba(106, 161, 142, 0) 70%),
    radial-gradient(ellipse 50% 90% at 10% 100%, rgba(106, 161, 142, 0.28) 0%, rgba(106, 161, 142, 0) 70%),
    linear-gradient(135deg, #064031 0%, #03241B 100%);
  /* shallow on purpose: 1280×~330 on a laptop, so the fold lands on the
     first row of homes rather than on the bottom of a photo */
  height: clamp(280px, 26vw, 360px);
}
.bx-hero-photo {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: center 46%; z-index: 0;
  /* The photo stays fully opaque. The even darkening it used to get from
     opacity: 0.6 now comes from a flat layer in the scrim instead — visually
     identical (60% of the image over #03241B is the same result as 40% of
     #03241B over the image), but it does not rely on the renderer blending a
     semi-transparent image against its parent's background, which is exactly
     where this fell over and painted the whole hero black. */
}
.bx-hero-scrim {
  position: absolute; inset: 0; z-index: 1;
  /* Centred copy needs a centred scrim. The old left-edge gradient darkened the
     wrong third of the photo and left the headline sitting on bright balcony
     green. A soft radial keeps the darkening under the text and lets the
     building read at both edges. */
  background:
    radial-gradient(ellipse 70% 90% at 50% 45%, rgba(3, 36, 27, 0.34) 0%, rgba(3, 36, 27, 0.10) 68%, rgba(3, 36, 27, 0) 100%),
    linear-gradient(0deg, rgba(3, 36, 27, 0.20) 0%, rgba(3, 36, 27, 0) 42%),
    /* the flat 40% that replaces the photo's old opacity */
    linear-gradient(0deg, rgba(3, 36, 27, 0.4), rgba(3, 36, 27, 0.4));
}
.bx-hero-copy {
  /* Spanning left-to-right rather than sitting at left:50%. An absolutely
     positioned box anchored at 50% can only ever be half the hero wide, which
     silently wrapped the one-line headline no matter how high max-width went. */
  position: absolute; top: 50%; left: 0; right: 0; z-index: 2;
  /* -54% with the subhead back: centres the two-element stack optically rather
     than geometrically, so it does not sit low against the search bar below. */
  transform: translateY(-54%);
  text-align: center;
  padding: 0 var(--bx-gutter);
}
/* The H1 is the small line above the slogan: it says what the page is about
   ("Your Next Home. Done Right." named no place and no topic), while the
   slogan keeps the big visual headline as a plain paragraph. */
.bx-hero-copy .bx-hero-kicker {
  font-size: clamp(12px, 1.05vw, 14px); font-weight: 700; line-height: 1.3;
  letter-spacing: 0.12em; text-transform: uppercase; margin: 0 0 10px;
  color: rgba(255, 255, 255, 0.92); text-shadow: 0 1px 20px rgba(0, 0, 0, 0.35);
}
.bx-hero-copy .bx-hero-title {
  /* Zillow's hero weight: heavy, large, tight leading, tight tracking. 800 is
     the heaviest real cut available here — 900 would synthesise and smear. */
  font-size: clamp(34px, 4.4vw, 58px); font-weight: 800; line-height: 1.02;
  letter-spacing: -0.03em; margin: 0 0 12px; text-shadow: 0 2px 30px rgba(0, 0, 0, 0.3);
  color: #fff;
}
.bx-hero-copy .bx-hero-title .dot { color: var(--orange); }
.bx-hero-copy .bx-hero-sub {
  /* scaled up with the headline — the old 15.5px was set against a 46px h1 and
     reads as a caption under this one */
  font-size: clamp(14px, 1.35vw, 18px); line-height: 1.5; margin: 0;
  color: rgba(255, 255, 255, 0.92); text-shadow: 0 1px 20px rgba(0, 0, 0, 0.35);
}
.bx-hero-play {
  display: inline-flex; align-items: center; gap: 9px; cursor: pointer;
  font-family: inherit; font-weight: 600; font-size: 12.5px; color: #fff;
  background: rgba(3, 36, 27, 0.42); border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px; padding: 6px 15px 6px 6px; backdrop-filter: blur(6px);
  transition: background 0.18s ease;
}
.bx-hero-play:hover { background: rgba(3, 36, 27, 0.6); }
.bx-hero-play-orb { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: #fff; color: #1c1c1c; }
.bx-hero-play-orb svg { width: 12px; height: 12px; }

@media (max-width: 760px) {
}

/* ---- 4 + 5. two columns: categories & first row | promo -------
   The sample puts its promo panel level with the category icons, not below
   them, so the grid starts at the icon row rather than under it. */
.bx-main {
  width: min(var(--bx-max), calc(100% - 2 * var(--bx-gutter))); margin: 22px auto 0;
  display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 32px; align-items: stretch;
}
.bx-main-left { min-width: 0; }

.bx-cats {
  display: flex; align-items: center; gap: 12px;
  border-bottom: 1px solid rgba(51, 51, 51, 0.08);
}
.bx-cats-scroll {
  /* space-between so the last chip lands on the column's right edge, level
     with the row's ‹ › arrows below it. Left to its natural width the strip
     stopped ~47px short and left a gap that read as broken alignment. The gap
     property is the minimum spacing, which takes over once the chips overflow
     and the row scrolls instead. */
  flex: 1; display: flex; justify-content: space-between; gap: 6px;
  overflow-x: auto; scrollbar-width: none; scroll-snap-type: x proximity;
  overscroll-behavior-x: contain;
  /* Both axes: pan-x alone stopped a vertical page swipe that began on the
     strip. See .dg-row-scroll in css/app.css. */
  touch-action: pan-x pan-y;
}
.bx-cats-scroll::-webkit-scrollbar { display: none; }
.bx-cat {
  flex: 0 0 auto; scroll-snap-align: start; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; gap: 7px;
  min-width: 78px; padding: 12px 10px 14px;
  font-family: inherit; font-size: 12px; font-weight: 500; color: #6f7069;
  /* these are <a> now, not <button> — they navigate to a filtered search page */
  text-decoration: none; white-space: nowrap;
  background: none; border: 0; border-bottom: 2px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}
.bx-cat svg { width: 24px; height: 24px; opacity: 0.75; }
.bx-cat:hover { color: #1c1c1c; }
.bx-cat:hover svg { opacity: 1; }
.bx-cat.is-active { color: var(--red-text); border-bottom-color: var(--orange); }
.bx-cat.is-active svg { opacity: 1; }
/* hidden by script when the strip does not overflow — belt and braces, in case
   a later display rule outranks the attribute's default styling */
.bx-cats-more[hidden] { display: none; }
/* Orange with a white arrow. As a white circle on a white strip it read as
   decoration, and people did not know there was more to the right — which
   mattered rather a lot once it started working. */
.bx-cats-more {
  flex: 0 0 auto; width: 40px; height: 40px; border-radius: 50%; cursor: pointer;
  background: var(--orange-deep); border: 1px solid var(--orange-deep); color: #fff;
  font-size: 18px; line-height: 1; display: grid; place-items: center;
  box-shadow: 0 2px 8px rgba(106, 161, 142, .3);
}
.bx-cats-more:hover { background: var(--orange-deep, #6AA18E); border-color: var(--orange-deep, #6AA18E); }

/* the moved row loses its own outer gutter — the column provides it */
/* Reserve the row's height before it arrives.

   js/home.js lifts the first listing row out of #dg-rows and into this slot
   once app.js has painted. Until that happens the slot is empty, so the whole
   page below it jumped down by ~306px the moment the row landed — a 0.329
   cumulative layout shift on desktop, three times Google's 0.1 threshold and
   a Core Web Vitals failure. Mobile scored 0 because this two-column band is
   desktop-only, which is what gave the cause away.

   306px is the measured height of the rendered row: a 53px head plus a 239px
   card grid plus the gap. min-height, not height, so a taller row still
   grows — it just never starts from nothing. */
.bx-band-main { margin-top: 22px; min-height: 306px; }
.bx-band-main .dg-row { width: 100%; margin: 0; padding: 0; }
.bx-band-main .dg-row-head { padding: 0; }
/* The rows below scroll horizontally, so a card clipped at the right edge reads
   as "more this way". This one cannot scroll — the sidebar sits where the rest
   of the row would go — so a sliver there is just a widow. Fit whole cards to
   the column instead and drop any that do not fit.

   Scoped to the width where that sidebar actually IS beside it. .bx-main goes
   to a single column at 1000px, and this rule was applying at every width
   regardless: on a phone the container is one 188px column wide, so the card
   stretched to fill it and grid-auto-rows:0 collapsed the other seven to
   nothing. Trending showed exactly one home, at 335px, above bands showing
   1.7 at 188px — one page, two card sizes. Below 1001px it now inherits the
   same row the bands use. */
@media (min-width: 1001px) {
  .bx-band-main .dg-row-scroll {
    padding: 0;
    grid-auto-flow: row;
    grid-template-columns: repeat(auto-fill, minmax(188px, 1fr));
    grid-template-rows: auto;
    grid-auto-rows: 0;
    overflow: hidden;
  }
}

.bx-promo {
  /* Bottom-aligned with the listing row rather than running past it.
     height:0 keeps the promo from contributing to the grid row, so the row
     is sized by the categories + row on the left; min-height then fills it.
     Sticky is gone with it — there is nothing left to scroll past. */
  height: 0; min-height: 100%; overflow: hidden;
  display: flex; flex-direction: column;
  background: #EEF5F2; border-radius: 22px; padding: 22px 22px 20px;
  border: 1px solid rgba(106, 161, 142, 0.14);
}
/* the tile card sits against the bottom edge, so both columns end level */
.bx-promo-eyebrow { font-size: 14px; font-weight: 600; color: var(--red-text); }
.bx-promo h3 { font-size: 20px; line-height: 1.2; letter-spacing: -0.01em; margin: 3px 0 6px; color: #1c1c1c; }
.bx-promo > p { font-size: 13.5px; line-height: 1.5; color: #4e4f4f; margin: 0 0 4px; }
.bx-promo-cta {
  font-family: inherit; font-weight: 600; font-size: 13.5px; color: #fff; cursor: pointer;
  background: var(--orange-deep); border: 0; border-radius: 999px; padding: 10px 18px;
  transition: background 0.18s ease;
}
.bx-promo-cta:hover { background: #064031; }
.bx-promo-card {
  /* An inset card floating inside the panel. It now fills whatever is left
     under the text rather than being pinned to the bottom with dead space
     above it — the tiles take that space, which is worth more than a gap.
     Padding matches the panel's own, so the ring of space around the tiles
     reads the same as the ring around the text above them. */
  margin: 12px 0 0; padding: 16px;
  flex: 1 1 auto; display: flex; flex-direction: column; min-height: 0;
  background: #fff; border-radius: 16px;
  box-shadow: 0 10px 30px -18px rgba(3, 36, 27, 0.4);
}
.bx-promo-card-title { font-size: 14px; font-weight: 600; line-height: 1.3; color: #1c1c1c; margin: 0 0 10px; }
/* Two rows of three now. Square tiles overran the card's fixed height (it is
   pinned to the listing row beside it), so the crops are slightly landscape —
   which suits these photographs anyway. */
.bx-promo-tiles {
  display: grid; grid-template-columns: repeat(3, 1fr); grid-template-rows: 1fr 1fr;
  gap: 10px 8px; flex: 1 1 auto; min-height: 0;
}
.bx-promo-tiles a {
  display: flex; flex-direction: column; gap: 6px; min-height: 0;
  text-decoration: none; font-size: 12px; font-weight: 500; color: #4e4f4f;
}
.bx-promo-tiles a:hover { color: var(--red-text); }
/* no fixed ratio: each photo takes the height its row gives it, so the tiles
   grow with the card instead of leaving a gap beneath them */
.bx-promo-tile-img {
  display: block; flex: 1 1 auto; min-height: 64px; border-radius: 10px;
  background: #F3F4F6 center/cover no-repeat;
}

/* the remaining rows come after the band, as before. app.css gives
   .dg-listings a 190px top pad (for the old overhanging panel) and 56px side
   pads inside a 1240px cap; both fight the thin-gutter layout, so the rows
   are put on the same gutter as everything else. */
#desktop-gate .dg-listings { max-width: none; padding-left: 0; padding-right: 0; }
/* the band row is a .dg-row that lost its own 40px bottom margin, so the gap to
   the next section has to come from here to match the row-to-row rhythm below */
#dg-rows { padding-top: 40px; }
#dg-results { padding-top: 24px; }
#desktop-gate .dg-row { width: 100%; }

/* ---- responsive ------------------------------------------------ */
@media (max-width: 1000px) {
  .bx-main { grid-template-columns: 1fr; gap: 20px; }
  /* stacked: let it size to its own content again */
  .bx-promo { height: auto; min-height: 0; }
  /* .bx-band-main's 306px is sized to roughly match the promo card sitting
     BESIDE it in the two-column desktop layout — the row needs to be that
     tall so the stretched promo card has somewhere to reach. Once they stack
     instead of sitting side by side that reason is gone, and the row's own
     content (as few as 2-3 cards on a phone) is well under it, leaving dead
     space below the cards before the promo card starts. Confirmed: 321px box
     around 254px of actual row content, 67px of nothing. */
  .bx-band-main { min-height: 0; }
}
@media (max-width: 900px) {
  :root { --bx-gutter: 20px; }
  .bx-hero { height: clamp(260px, 44vw, 320px); }
}
@media (max-width: 560px) {
  .bx-hero { height: 300px; }
  .bx-hero-copy { padding: 0 18px; }
}

/* the band row pages by hiding cards (js/home.js); [hidden] has to beat the
   grid item's display for that to do anything */
.bx-band-main .dg-card[hidden] { display: none; }
/* a chevron that cannot go further reads as disabled rather than broken */
.bx-band-main ~ * [data-nav][disabled],
#bx-band-main .dg-row-nav button[disabled],
.bx-main-left .dg-row-nav button[disabled] { opacity: 0.35; cursor: default; }

/* ---- Edmonton neighbourhoods (feed/build_home_neighbourhoods.py) ----------
   The Tier 1 neighbourhoods in the served HTML, grouped by area. Area groups
   flow through columns rather than a grid: Central holds eighteen and
   Northwest one, and a grid would leave the short groups floating in space. */
.hn {
  width: min(var(--bx-max), calc(100% - 2 * var(--bx-gutter)));
  margin: 8px auto 56px; padding-top: 32px;
  border-top: 1px solid rgba(51, 51, 51, 0.08);
}
.hn-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.hn-head h2 { font-size: 24px; font-weight: 700; letter-spacing: -0.01em; color: #1c1c1c; text-wrap: balance; }
.hn-sub { margin-top: 4px; max-width: 41.11em; font-size: 14px; line-height: 1.55; color: #5f5f66; }
.hn-all {
  flex: 0 0 auto; font-size: 14px; font-weight: 600; color: #1c1c1c;
  text-decoration: underline; text-underline-offset: 3px; white-space: nowrap;
}
.hn-all:hover { color: var(--red-text); }
.hn-areas { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; align-items: stretch; margin-bottom: 22px; }
.hn-col { display: flex; flex-direction: column; gap: 22px; min-width: 0; }
/* the last card in a column takes up the slack, so all three columns end level */
.hn-col > .hn-area:last-child { flex: 1 1 auto; }
.hn-area {
  display: flex; flex-direction: column;
  margin: 0; padding: 16px 18px 14px;
  background: #fff; border: 1px solid rgba(51, 51, 51, 0.08); border-radius: 16px;
}
.hn-area h3 { font-size: 16px; font-weight: 700; }
.hn-area h3 a { color: #1c1c1c; text-decoration: none; }
.hn-area h3 a:hover { color: var(--red-text); }
.hn-area-sub { margin: 2px 0 8px; font-size: 12.5px; color: #737373; font-variant-numeric: tabular-nums; }
.hn-area ul { list-style: none; margin: 0; padding: 0; }
.hn-area li {
  display: flex; align-items: baseline; justify-content: space-between; gap: 12px;
  padding: 7px 0; border-top: 1px solid rgba(51, 51, 51, 0.06); font-size: 14px;
}
.hn-area li a { color: #1c1c1c; font-weight: 500; text-decoration: none; }
.hn-area li a:hover { color: var(--red-text); text-decoration: underline; text-underline-offset: 3px; }
/* (the link used to be pinned to the card's foot; see .hn-area-more below) */
.hn-area ul { margin-bottom: 10px; }
.hn-area-more {
  /* Directly under its list (it used to be pinned to the card's foot). A card
     stretched to its column's height now ends with quiet space below the link,
     not a hole between the list and the link. */
  margin-top: 0; padding-top: 10px; border-top: 1px solid rgba(51, 51, 51, 0.06);
  font-size: 13px; font-weight: 600; color: var(--red-text); text-decoration: none;
}
.hn-area-more::after { content: " \2192"; }
.hn-area-more:hover { text-decoration: underline; text-underline-offset: 3px; }
.hn-area li span { flex: 0 0 auto; font-size: 12.5px; color: #737373; font-variant-numeric: tabular-nums; }
.hn-more ul { list-style: none; margin: 6px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.hn-more a {
  display: inline-block; padding: 8px 14px; border-radius: 999px; font-size: 13px; font-weight: 500;
  color: #1c1c1c; background: #fff; border: 1px solid rgba(51, 51, 51, 0.14); text-decoration: none;
}
.hn-more a:hover { border-color: var(--red-text); color: var(--red-text); }
.hn a:focus-visible { outline: 2px solid var(--red-text); outline-offset: 2px; border-radius: 4px; }
@media (max-width: 1000px) {
  .hn-areas { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  /* two columns of three groups: stretching would leave one card hollow */
  .hn-col > .hn-area:last-child { flex: 0 0 auto; }
}
@media (max-width: 760px) {
  .hn-areas { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .hn-col { gap: 16px; }
  .hn { margin-bottom: 36px; padding-top: 24px; }
  .hn-head { flex-direction: column; align-items: flex-start; gap: 8px; }
  .hn-head h2 { font-size: 21px; }
  .hn-area { padding: 14px 14px 8px; border-radius: 14px; }
}
/* Phones: two columns inside each area, figures under the name, so all 36
   stay visible without the section running three screens long. */
@media (max-width: 560px) {
  .hn-area ul { display: grid; grid-template-columns: 1fr 1fr; column-gap: 14px; }
  .hn-area li { display: block; padding: 7px 0; }
  .hn-area li a { display: block; font-size: 13.5px; line-height: 1.3; }
  .hn-area li span { display: block; margin-top: 1px; font-size: 12px; }
}

/* ---- Hero B: the VistaHaven shape (Eddie, 2026-10-22) -------------------
   A rounded card inset on the page gutter, photo behind, copy on the left,
   the search bar inside the card and the agent pill bottom-right. The
   .bx-hero rules above are the first version and are unused now. */
.vh-wrap { width: min(var(--bx-max), calc(100% - 2 * var(--bx-gutter))); margin: 14px auto 0; }
.vh-hero {
  /* overflow stays visible so the agent pill can straddle the bottom edge, as
     on the reference; the photo and scrim clip themselves to the radius */
  position: relative; isolation: isolate; overflow: visible; color: #fff;
  /* bottom-right is square: the agent tab covers that corner, and a rounded
     corner clipped the white tab and left a navy hairline along its curve */
  border-radius: 28px 28px 0 28px; background: #03241B;
  display: flex; flex-direction: column;
  /* height comes from the content: a shorter, wider card shows more of the
     photo's width, which is what lets the house sit right of the copy */
}
/* the <picture> around the photo takes no part in layout */
/* border-radius passes through it, or the photo's "inherit" below finds nothing */
.vh-hero picture { display: contents; border-radius: inherit; }
.vh-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 100% 0%; z-index: 0; border-radius: inherit; }
.vh-scrim {
  position: absolute; inset: 0; z-index: 1; border-radius: inherit;
  background:
    /* brand green wash behind the copy, gone before the house (Eddie, 2026-10-29) */
    /* angled so the fade leans away from the sky at the top (2026-11-02) */
    linear-gradient(60deg, rgba(6, 56, 42, 0.94) 0%, rgba(6, 56, 42, 0.88) 30%, rgba(6, 56, 42, 0.45) 40%, rgba(6, 56, 42, 0) 50%),
    linear-gradient(180deg, rgba(3, 36, 27, 0.10) 0%, rgba(3, 36, 27, 0) 22%),
    linear-gradient(0deg, rgba(3, 36, 27, 0.65) 0%, rgba(3, 36, 27, 0.08) 34%, rgba(3, 36, 27, 0) 50%);
}
/* Typography pass (2026-10-22). One text column, left-aligned, 560px
   wide; every element below carries the size, weight and spacing from that
   brief. Vertical rhythm: eyebrow 16 headline 24 subhead 32 stats. */
.vh-copy {
  position: relative; z-index: 2; flex: 1 1 auto;
  padding: clamp(36px, 4.2vw, 64px) clamp(20px, 5vw, 80px) 0;
  max-width: none;
}
.vh-copy > * { max-width: 560px; }
.vh-kicker {
  font-size: 13px; font-weight: 600; line-height: 1.2; letter-spacing: 0.12em; text-transform: uppercase;
  color: #fff; margin: 0 0 16px;
}
.vh-title {
  font-size: clamp(40px, 5vw, 64px); font-weight: 800; line-height: 0.97; letter-spacing: -0.02em;
  text-transform: uppercase; margin: 0 0 24px; text-wrap: balance;
}
.vh-title .dot { color: var(--blue-300, #6AA18E); }
.vh-sub { font-size: 19px; font-weight: 500; line-height: 1.5; max-width: 520px; color: rgba(255, 255, 255, 0.9); margin: 0; }
/* "street-level" is one word to a reader; it must not break at its hyphen */
.vh-sub .nb { white-space: nowrap; }
.vh-cta, .vh-meet {
  display: inline-flex; align-items: center; gap: 12px; text-decoration: none;
  border-radius: 999px; background: #fff; color: #1c1c1c; font-weight: 600; font-size: 15px;
}
.vh-cta { padding: 8px 8px 8px 20px; min-height: 48px; }
.vh-cta:hover, .vh-meet:hover { background: var(--grey-100, #F3F4F6); }
.vh-orb { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: #1c1c1c; color: #fff; flex: none; }
.vh-orb svg { width: 14px; height: 14px; }
.vh-stats { list-style: none; display: flex; flex-wrap: wrap; gap: 18px 48px; margin: 32px 0 0; padding: 0; }
.vh-stats b { display: block; font-size: 40px; font-weight: 700; letter-spacing: -0.01em; line-height: 1; font-variant-numeric: tabular-nums; }
.vh-stats b::after { content: "+"; font-size: 20px; font-weight: 700; line-height: 1; vertical-align: top; margin-left: 2px; color: var(--blue-300, #6AA18E); }
.vh-stats li:nth-child(n+2) b::after { content: ""; }
.vh-stats span { display: block; margin-top: 6px; font-size: 14px; font-weight: 500; line-height: 1.3; color: rgba(255, 255, 255, 0.82); }
/* The agent tab: a white panel notched into the card's bottom-right corner,
   as on the reference. The two pseudo-elements are the concave fillets where
   the tab meets the card's right edge and bottom edge. */
/* Eddie in the photo (2026-10-28). Stands on the card's floor at the right,
   under the copy and the search bar in the stacking order, with his name and
   rating set in white beside his jacket as on the sample. Shown from 1100px:
   narrower, the figure would run into the headline, and the notched tab
   further down does the job instead. */
.vh-ed { display: none; }
@media (min-width: 1100px) {
  .vh-wrap .vh-hero { border-radius: 28px; }
  .vh-wrap .vh-tab { display: none; }
  .vh-wrap .vh-hero .se-wrap { padding-bottom: 56px; }
  /* z-index auto: no stacking context of its own, so the photo (1) stays
     under the search bar's wrapper (2) and the caption (3) stays above it */
  .vh-ed {
    display: block; position: absolute; z-index: auto; bottom: 0;
    right: clamp(24px, 4vw, 72px); height: 64.5%;
    color: #fff;
  }
  .vh-ed-photo {
    position: relative; z-index: 1;
    display: block; height: 100%; width: auto;
    filter: drop-shadow(0 18px 36px rgba(0, 0, 0, 0.35));
    /* the shadow must stop at the card's floor, not spill onto the page */
    clip-path: inset(-80px -80px 0 -80px);
  }
  /* above the search bar's wrapper (z-index 2), which spans the card's
     width and would otherwise take the clicks meant for this link */
  /* centred over his torso (Eddie, 2026-11-01): on his chest, above the
     line of the search bar, until the card is wide enough for the bar to
     end before the caption starts; from 1400px it drops onto the jacket */
  .vh-ed-cap {
    position: absolute; z-index: 3; left: 50%; bottom: 43%;
    transform: translateX(-50%);
    display: flex; flex-direction: column; align-items: center; gap: 6px; white-space: nowrap;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6), 0 1px 12px rgba(0, 0, 0, 0.55);
  }
  .vh-ed-cap { color: #fff; text-decoration: none; }
  .vh-ed-name { font-size: 21px; font-weight: 700; letter-spacing: -0.01em; }
  .vh-ed-rating { display: flex; align-items: center; gap: 6px; font-size: 14px; color: rgba(255, 255, 255, 0.9); }
  .vh-ed-rating em { font-style: normal; font-weight: 700; color: #fff; }
  .vh-ed-cap:hover .vh-ed-name, .vh-ed-cap:focus-visible .vh-ed-name { text-decoration: underline; text-underline-offset: 3px; }
}
/* The bar sizes to its fields (886px); capped at 900px from 1280px. */
@media (min-width: 1280px) {
  .vh-wrap .vh-hero .se-wrap .searchbar { max-width: 900px; }
  .vh-ed-cap { bottom: 38%; }
}
@media (min-width: 1400px) {
  .vh-ed-cap { bottom: 16%; }
}
.vh-tab {
  position: absolute; right: -1px; bottom: -1px; z-index: 3;
  display: flex; align-items: center; gap: 14px;
  padding: 20px 31px 21px 22px;
  background: #fff; color: #1c1c1c; text-decoration: none;
  border-top-left-radius: 28px;
}
.vh-tab::before, .vh-tab::after {
  content: ""; position: absolute; width: 28px; height: 28px;
  background: radial-gradient(circle at 0 0, transparent 27.5px, #fff 28px);
}
.vh-tab::before { right: 1px; top: -28px; }
.vh-tab::after { left: -28px; bottom: 0; }
.vh-tab-avatar { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; display: block; box-shadow: 0 0 0 3px #fff, 0 0 0 4px var(--grid, #E5E7EB); }
.vh-tab-txt { display: flex; flex-direction: column; gap: 4px; line-height: 1.2; }
.vh-tab-txt b { font-size: 17px; font-weight: 700; letter-spacing: -0.01em; }
.vh-tab-rating { font-size: 14px; color: #555; display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.vh-tab-rating em { font-style: normal; font-weight: 600; color: #1c1c1c; }
.vh-stars { color: #F59E0B; font-size: 16px; letter-spacing: 1px; line-height: 1; }
.vh-tab:hover b { text-decoration: underline; text-underline-offset: 3px; }
/* room under the bar for the agent tab in the corner */
/* one left rail: the search title and the bar's edge line up with the
   kicker, headline and stats above them, and the bar ends on the same right
   margin */
.vh-hero .se-wrap { position: relative; z-index: 2; margin: 40px 0 0; padding: 0 clamp(20px, 5vw, 80px) 112px; }
.vh-hero .se-wrap .searchbar-title {
  width: auto; margin: 0; padding: 0 0 10px; color: #fff;
  font-size: 13px; font-weight: 600; line-height: 1.2; letter-spacing: 0.1em; text-transform: uppercase;
}
.vh-hero .se-wrap .searchbar { width: auto; margin: 0; background: rgba(255, 255, 255, 0.97); border-color: transparent; box-shadow: 0 24px 60px -24px rgba(0, 0, 0, 0.6); }
/* chip-style category icons (alternate set) */
.bx-cat svg {
  width: 40px; height: 40px; padding: 9px; border-radius: 12px; box-sizing: border-box;
  background: var(--grey-100, #F3F4F6); color: var(--blue-900, #064031); opacity: 1;
  transition: background 0.15s ease, color 0.15s ease;
}
.bx-cat:hover svg { background: #EEF5F2; }
.bx-cat.is-active svg { background: #EEF5F2; color: var(--blue-500, #6AA18E); }
.bx-cat { gap: 8px; padding: 10px 10px 12px; }

/* narrower cards run the headline further across, so the wash reaches further */
@media (min-width: 761px) and (max-width: 1279px) {
  .vh-scrim {
    background:
      linear-gradient(60deg, rgba(6, 56, 42, 0.94) 0%, rgba(6, 56, 42, 0.88) 36%, rgba(6, 56, 42, 0.5) 50%, rgba(6, 56, 42, 0) 62%),
      linear-gradient(180deg, rgba(3, 36, 27, 0.10) 0%, rgba(3, 36, 27, 0) 22%),
      linear-gradient(0deg, rgba(3, 36, 27, 0.65) 0%, rgba(3, 36, 27, 0.08) 34%, rgba(3, 36, 27, 0) 50%);
  }
}
@media (max-width: 760px) {
  .vh-wrap { margin-top: 10px; }
  .vh-hero { min-height: 0; border-radius: 22px; }
  .vh-tab { right: auto; bottom: auto; }
  /* A phone card is far taller than it is wide, so a photo covering all of it
     shows only a sliver of the house. The phone's own shot fills the top of the
     card under the same wash as desktop, then fades into the card's green. */
  .vh-hero { background: #06382A; }
  .vh-photo { inset: 0 0 auto 0; height: 560px; object-position: 50% 50%; border-radius: 22px 22px 0 0; }
  .vh-scrim {
    inset: 0 0 auto 0; height: 561px; border-radius: 22px 22px 0 0;
    background:
      linear-gradient(90deg, rgba(6, 56, 42, 0.94) 0%, rgba(6, 56, 42, 0.85) 45%, rgba(6, 56, 42, 0.5) 80%, rgba(6, 56, 42, 0.18) 100%),
      linear-gradient(0deg, #06382A 0%, rgba(6, 56, 42, 0) 40%);
  }
  .vh-copy { padding: 34px 20px 0; }
  .vh-kicker { font-size: 12px; }
  .vh-title { font-size: 40px; }
  .vh-sub { font-size: 16px; }
  /* three columns on a phone too; the first label wraps to two lines */
  .vh-stats { display: grid; grid-template-columns: repeat(3, minmax(0, auto)); justify-content: start; gap: 14px 22px; }
  .vh-stats b { font-size: 30px; }
  .vh-stats b::after { font-size: 15px; }
  .vh-stats span { font-size: 13px; }
  /* on a phone the tab becomes a plain white card in the flow, under the search bar */
  .vh-tab { position: relative; right: auto; bottom: auto; height: auto; margin: 0 20px 20px; padding: 14px 18px; border-radius: 18px; }
  .vh-tab::before, .vh-tab::after { display: none; }
  /* the longer caption and the review count must stay inside the white tab */
  .vh-tab-txt { min-width: 0; }
  .vh-tab-txt b { text-wrap: balance; }
  .vh-tab-rating { flex-wrap: wrap; }
  .vh-hero .se-wrap { padding: 0 20px 12px; order: 2; }
  .vh-tab { order: 3; }
  .vh-hero .se-wrap .searchbar-title { padding-left: 0; }
}
/* The hero's search bar is the quick version: price, neighbourhood, beds and
   baths. Size and Must have stay on /search.html, and Area is hidden because
   every quadrant but the south is empty on this site. Hidden fields send
   nothing (js/search-bar.js only sets a param for a filled field), and the
   generated markup is untouched, so feed/build_search_entry.py can keep
   rewriting it. The bar sizes to its fields and stops short of the agent tab
   instead of stretching the neighbourhood box across the card. */
.vh-hero .sb-field:has(#se-size),
.vh-hero .sb-field:has(#se-area),
.vh-hero .sb-field:has(#se-feature) { display: none; }
/* The suggestion list sits inside the hero, whose text is white: without this
   the names were white on the list's white ground and looked like no list. */
.vh-hero .sb-ac { color: var(--ink, #1c1c1c); }
/* wider than the 168px field, so a name and its count share a line */
@media (min-width: 761px) { .vh-hero .sb-ac { right: auto; width: 280px; } }
.vh-hero .sb-ac em { flex: none; font-style: normal; font-size: 12px; color: var(--ink-3, #737373); white-space: nowrap; }
@media (min-width: 761px) {
  .vh-hero .se-wrap .searchbar { width: fit-content; max-width: 100%; gap: 12px; flex-wrap: nowrap; padding-left: 20px; padding-right: 16px; }
  .vh-hero .sb-range input { width: 84px; }
  /* a real width, not a flex-basis: fit-content above sizes the bar from its
     items' widths, and a basis alone left it 20px short of the Search button */
  .vh-hero .sb-field:has(#se-hood) { flex: none; width: 168px; }
  .vh-hero .sb-field:has(#se-hood) input { width: 100%; min-width: 0; }
  .vh-hero .sb-field input, .vh-hero .sb-field select { min-width: 96px; }
  .vh-hero .sb-go { flex: none; padding: 10px 26px; }
}


/* Bar and agent tab on one row, bottom edges level, where they fit side by
   side (bar 886px from the left rail, tab about 355px from the right edge).
   Below 1380px they would collide, so the bar stays above the tab there. */
@media (min-width: 1380px) {
  .vh-hero .se-wrap { padding-bottom: 21px; }
}

/* ---- homepage nav over the hero, desktop only (2026-11-03) ------
   The hero runs to the top of the page and the nav sits on it, white on a
   green fade, turning solid green once the page scrolls (js/home.js adds
   .is-scrolled). From 1100px, where Eddie's photo appears in the hero; below
   that the menu is too tight for it and the white header stays. Reserves a fixed 88px so the hero can
   slide under it by exactly that much. */
@media (min-width: 1100px) {
  #desktop-gate .dgn-wrap {
    height: 88px; margin-bottom: -88px; padding: 0; display: flex; align-items: center;
    border-bottom: 0;
    background: linear-gradient(180deg, rgba(6, 56, 42, 0.72) 0%, rgba(6, 56, 42, 0) 100%);
  }
  #desktop-gate .dgn-wrap.is-scrolled { background: #064031; }
  /* The bar keeps its site.css box, only without the white pill, so the logo
     and the button land where they do on every other page. */
  #desktop-gate .dgn {
    background: none; border-color: transparent;
    backdrop-filter: none; -webkit-backdrop-filter: none;
  }
  #desktop-gate .dgn-logo img.dgn-wordmark { content: url("../assets/brand/logo-eddie-gebran-light.png"); }
  #desktop-gate .dgn-logo .dgn-powered { color: #fff; }
  #desktop-gate .dgn-links > li > a,
  #desktop-gate .dgn-links > li > button { color: #fff; text-shadow: 0 1px 6px rgba(0, 0, 0, 0.35); }
  #desktop-gate .dgn-links > li > a:hover,
  #desktop-gate .dgn-links > li > button:hover { color: #CFE3DB; }
  #desktop-gate .dgn .dgn-cta { background: #fff; color: #064031; }
  #desktop-gate .dgn-phone { color: #fff; text-shadow: 0 1px 6px rgba(0, 0, 0, 0.35); }
  #desktop-gate .dgn-phone:hover { color: #CFE3DB; }
  #desktop-gate .dgn .dgn-orb { background: #064031; color: #fff; }
  .vh-wrap { width: 100%; margin: 0; }
  .vh-wrap .vh-hero { border-radius: 0; }
  /* --hero-rail is the logo's left edge: the nav's gutter, or its margin once
     the page passes --page-max (the flat bar has no side padding).
     The hero's text and search bar sit on it. */
  .vh-hero { --hero-rail: max(var(--page-gutter), (100% - var(--page-max)) / 2); }
  .vh-copy {
    padding-top: calc(88px + clamp(28px, 3vw, 48px));
    padding-left: var(--hero-rail);
  }
  .vh-hero .se-wrap { padding-left: var(--hero-rail); }
}

/* Phones and small tablets: the same bar width as site.css, which this file's
   #desktop-gate .dgn rule otherwise overrides, so the logo does not jump
   sideways between the homepage and the rest of the site. */
@media (max-width: 859px) {
  #desktop-gate .dgn-wrap { padding-top: 0; }
  #desktop-gate .dgn { width: calc(100% - 2 * 16px); }
}
/* site.css narrows its gutter to 16px up to 900px; this file keeps 20px. */
@media (min-width: 860px) and (max-width: 900px) {
  #desktop-gate .dgn { width: calc(100% - 32px); }
}
/* The hero is an inset card here, 20px from the page edge, so its text sits
   the rest of the way in to the logo. */
@media (min-width: 860px) and (max-width: 1099px) {
  .vh-copy { padding-left: 23px; }
  .vh-hero .se-wrap { padding-left: 23px; }
}
@media (min-width: 860px) and (max-width: 900px) {
  .vh-copy { padding-left: 19px; }
  .vh-hero .se-wrap { padding-left: 19px; }
}

/* The MLS® number box under the hero's search bar sits on the green photo. */
.vh-hero .sb-mls label { color: #fff; text-shadow: 0 1px 6px rgba(0, 0, 0, 0.35); }
.vh-hero .sb-mls button { background: rgba(255, 255, 255, 0.95); }

/* The hero's search title wraps to two lines on most phones, and on a 412px
   one it fits on one only once Geist arrives, so the form under it jumped up
   15px as the font loaded (layout shift 0.15, 2026-11-14 audit). Hold two
   lines on phones either way. */
@media (max-width: 480px) { .vh-hero .searchbar-title { min-height: 41px; } }

/* ---- universal search (2026-11-18) -------------------------------------
   One box plus three chips, replacing the hero's six-field bar and the MLS®
   row (feed/directory.py universal_search_html(), js/universal-search.js).
   The wrapper keeps .se-wrap so the hero's padding and rails above still
   place it. 880px wide at most: the old bar was 886px, and from 1380px the
   agent tab shares the row. */
.vh-hero .us {
  position: relative; max-width: 880px; padding: 10px; border-radius: 22px;
  background: rgba(255, 255, 255, 0.97); color: var(--ink, #1c1c1c);
  box-shadow: 0 24px 60px -24px rgba(0, 0, 0, 0.6);
}
.us-row { display: flex; gap: 10px; align-items: stretch; }
.us-box { position: relative; flex: 1; min-width: 0; display: flex; align-items: center;
  background: var(--grey-100, #F3F4F6); border-radius: 14px; }
.us-box svg { position: absolute; left: 17px; width: 20px; height: 20px; color: var(--ink-3, #737373); pointer-events: none; }
.us-box input { width: 100%; min-width: 0; border: 0; background: transparent; font: inherit; font-size: 17px;
  color: var(--ink, #1c1c1c); padding: 17px 14px 17px 48px; border-radius: 14px; outline: none; }
.us-box input::placeholder { color: var(--ink-3, #737373); }
.us-box:focus-within { background: #fff; box-shadow: inset 0 0 0 2px var(--blue-900, #064031); }
.us-go { flex: none; border: 0; border-radius: 999px; background: var(--blue-900, #064031); color: #fff;
  font: inherit; font-size: 16px; font-weight: 700; padding: 0 30px; min-height: 48px; cursor: pointer; }
.us-go:hover { background: #0a5541; }
.us-go:focus-visible { outline: 2px solid var(--blue-500, #6AA18E); outline-offset: 2px; }

.us-filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 10px 4px 2px; }
.us-chip { position: relative; }
.us-chip select { appearance: none; -webkit-appearance: none; border: 1px solid var(--grid, #E5E7EB);
  background: #fff; border-radius: 999px; font: inherit; font-size: 14px; font-weight: 500;
  color: var(--ink, #1c1c1c); padding: 9px 32px 9px 14px; min-height: 40px; cursor: pointer; }
.us-chip::after { content: ""; position: absolute; right: 13px; top: 50%; width: 6px; height: 6px; margin-top: -5px;
  border-right: 1.6px solid currentColor; border-bottom: 1.6px solid currentColor; transform: rotate(45deg);
  pointer-events: none; color: var(--ink-2, #4b5563); }
.us-chip select.is-set { border-color: var(--blue-900, #064031); background: #EEF5F2; color: var(--blue-900, #064031); }
.us-more { margin-left: auto; font-size: 14px; font-weight: 600; color: var(--blue-900, #064031);
  text-decoration: none; padding: 9px 8px; }
.us-more:hover { text-decoration: underline; text-underline-offset: 3px; }

.us-ac { position: absolute; left: 10px; right: 10px; top: calc(100% - 4px); z-index: 20;
  background: #fff; border: 1px solid var(--grid, #E5E7EB); border-radius: 16px; padding: 6px 0;
  box-shadow: 0 18px 50px -12px rgba(0, 0, 0, 0.35); max-height: min(440px, 60vh); overflow: auto;
  overscroll-behavior: contain; text-align: left; }
.us-ac[hidden] { display: none; }
.us-grp { font-size: 11.5px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--ink-3, #737373); padding: 10px 18px 4px; }
.us-opt { display: flex; align-items: center; gap: 12px; padding: 9px 18px; min-height: 44px;
  color: inherit; text-decoration: none; }
.us-opt:hover, .us-opt.is-on { background: #EEF5F2; }
.us-ico { flex: none; width: 30px; height: 30px; border-radius: 9px; background: var(--grey-100, #F3F4F6);
  color: var(--blue-900, #064031); display: grid; place-items: center; }
.us-ico svg { width: 16px; height: 16px; }
.us-txt { min-width: 0; display: flex; flex-direction: column; }
.us-main { font-size: 15px; font-weight: 600; overflow-wrap: anywhere; }
.us-main mark { background: none; color: var(--blue-900, #064031); text-decoration: underline; text-underline-offset: 3px; }
.us-sub { font-size: 13px; color: var(--ink-3, #737373); }
.us-right { margin-left: auto; padding-left: 8px; font-size: 13px; font-weight: 600; color: var(--ink-2, #4b5563); white-space: nowrap; }
.us-foot { padding: 12px 18px; font-size: 14px; color: var(--ink-3, #737373); }

@media (max-width: 640px) {
  .us-row { flex-direction: column; }
  .us-go { padding: 13px; }
  .us-box input { font-size: 16px; padding-top: 15px; padding-bottom: 15px; }   /* 16px: no iOS focus zoom */
  .us-chip select { font-size: 16px; padding-right: 30px; }
  .us-more { margin-left: 0; }
  .us-ac { top: 72px; }   /* under the box, over the Search button */
}
