/*
 * planning-areas.css: GH #4570, the CVSDH planning-area pages.
 *
 * WHY its own file: only a brand with planning areas (CVSDH) links it (the nav, on
 * every page of that brand), so the other four brands load none of it. That is also
 * why the brand palette and fonts below may sit on :root and body: they reach CVSDH
 * pages only. Plain CSS (no Bootstrap additions), mobile first: base rules are the
 * phone layout and min-width blocks widen them. Class names are the ones
 * views/planning_area_fragments.go, planning_area_svg.go and the CVSDH home renderer
 * write.
 *
 * WHY these tokens (GH #4570, mockup v2 2026-11-28, from the owner's pick of the
 * watercolor map, option A): warm paper with navy, matching the map; Cormorant
 * Garamond italic for headings, logo and map labels, and Inter for the body (both
 * linked with this file), the system sans standing in until Inter loads. Spacing in
 * 4px steps.
 */
:root {
  --pa-bg: #faf6ee;
  --pa-panel: #ffffff;
  --pa-ink: #2a2219;
  --pa-muted: #7d6b4f;
  --pa-line: #e8dfcf;
  --pa-accent: #1f3a5f;
  /* WHY (owner 2026-11-29, verbatim: "review all sites for aligment, spacing, deadzones,
     etc"): the label colour on an --pa-accent fill (_global.css .btn-r66-primary); white
     on this navy is 11.5:1, and a brand without --pa-accent gets that rule's dark ink. */
  --pa-accent-ink: #fff;
  --pa-gold: #b8893a;
  --pa-price: #2f5d3a;
  --pa-serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --pa-sans: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
}
body {
  background: var(--pa-bg);
  color: var(--pa-ink);
  font-family: var(--pa-sans);
}
a {
  color: var(--pa-accent);
}

/* The logo is the region's name in the italic serif (nav, mockup v2). */
.pa-logo {
  display: inline-block;
  padding: 8px 0;
  font: italic 600 26px/1.1 var(--pa-serif);
  color: var(--pa-accent);
  white-space: nowrap;
}
.logo-wrapper a:hover .pa-logo,
.logo-wrapper a:focus .pa-logo {
  text-decoration: underline;
}

/* GH #4570 (owner 2026-11-28, verbatim: "CVSDH has a lot of deadspace at the top and
   top-right"): the header of the split-view pages (home, landing, search). WHY: the
   shared header (_global.css) is a fixed-width .container (1170px at 1366, so the nav
   ended 98px short of the right edge over the full-bleed split), the nav's 15px top and
   bottom margins and, from 800px, a 2em margin under it: 100px for a one-line text logo
   at 1366x768, about 125px on a phone. Here it is one full-width flex row, the logo left
   and the tabs right against the edge (wrapping under the logo on a phone), the tabs
   sitting on the split below: about 49px at 1366x768, about 94px on a phone.
   Owner 2026-11-29, verbatim: "review all sites for aligment, spacing, deadzones, etc":
   the one-band flex header itself (logo left, tabs right, the tabs wrapping right-aligned
   beside the logo from 768px) is now every brand's header, in _global.css. WHY only the
   split pages here go full width: the split is full-bleed, so its header spans the
   viewport with the tabs against the right edge; every other page keeps the header at
   its .container width, so the logo starts at the container gutter, where the page's
   content starts (x 113 at 1366px). WHY margin 0: the split fills the viewport right
   under the header (this also zeroes the auto side margins, as width auto needs). */
body:has(> .pa-split) > .logo-menu-wrapper {
  width: auto;
  margin: 0;
}
@media (min-width: 768px) {
  /* Owner 2026-11-29, verbatim: "too much deadspace" and, of SDCF Top Condos, "this
     layout is discomboluated": an image logo (SDCF's badge plus wordmark, 600x193; CTC's
     600x200) is 80px tall on every page, as beside the "Nearby" row, not the shared
     376px width cap's 121-125px, which left a blank band above and below the one-line
     tabs. WHY on every page: the logo keeps one size across the brand's pages. CTH's
     88px (coastal.css, linked after this file) overrides it at equal specificity. The
     text logo (.pa-logo) is no image and keeps its size. */
  body > .logo-menu-wrapper img.mainlogo {
    width: auto;
    height: 80px;
  }
}

.pa-home-head,
.pa-landing-head,
.pa-quick-search,
.pa-areas,
.pa-picker,
.pa-below {
  font-size: 15px;
  line-height: 1.45;
}
.pa-title {
  font: italic 600 30px/1.1 var(--pa-serif);
  color: var(--pa-accent);
  margin: 0 0 6px;
}
.pa-stats {
  margin: 0 0 10px;
  font-weight: 600;
  color: var(--pa-muted);
}
/* The map box: the inline SVG fits it whole (preserveAspectRatio meet); the paper
   colour fills any letterbox so the map reads edge to edge. */
#pa-map {
  position: relative;
  width: 100%;
  height: 340px;
  background: #f7f1e6;
  overflow: hidden;
}
.pa-svg {
  display: block;
  width: 100%;
  height: 100%;
}
/* GH #4570 (owner 2026-11-28: option A "Watercolor"): the reviewed option's palette
   and strokes. Areas are washes (fill set per area by planning_area_svg.go) with a
   soft ink edge. On a landing page (mockup v2) the page's own area is outlined in navy
   and the others dim. */
.pa-shape {
  fill-rule: evenodd;
  fill-opacity: 0.8;
  stroke: #6d5a3f;
  stroke-opacity: 0.55;
  stroke-width: 2;
}
.pa-svg-focus .pa-shape {
  fill-opacity: 0.45;
}
/* GH #4577 (owner 2026-11-28, verbatim: "Change the pacific ocean to light blue in the
   stylized SDCF map"): the sea, a light blue wash on the paper under every area, with
   no edge stroke (the shore is where the areas begin). WHY evenodd: islands are holes
   and stay paper. WHY no pointer events: background, so a click there selects nothing. */
.pa-water path {
  fill: #cfe3ee;
  fill-rule: evenodd;
  pointer-events: none;
}
/* GH #4580: a named water's label (CTC's Lake Michigan, the classless text right after
   the water group) in the area labels' italic serif. WHY: planning_area_svg.go fits it
   to the open water with the serif's character width, but it inherited the wider body
   sans and ran past the map's right edge, unseen while blank bands framed the map and
   cut off once the map column is the map's own width. */
.pa-water + text:not([class]) {
  font-family: var(--pa-serif);
  font-weight: 500;
}
/* A park (owner 2026-11-28, verbatim: "make it green and nonclickable"): a green
   landmark with no link, so no pointer, no hover and no dimming on a landing page. */
.pa-park {
  fill-rule: evenodd;
  fill-opacity: 0.85;
  stroke: #5f7a45;
  stroke-opacity: 0.55;
  stroke-width: 2;
  cursor: default;
}
.pa-area-label.pa-park-label {
  fill: #4a6435;
}
/* Owner 2026-11-29, verbatim: 'add smallprint "Not to scale"': a distorted map's small
   print, and the cutout's caption, in the labels' italic serif (the muted ink is set on
   the text). WHY no pointer events: print, never a target over the area under it. */
.pa-scale-note,
.pa-inset-caption {
  font-family: var(--pa-serif);
  pointer-events: none;
}
/* Owner 2026-11-29, verbatim: "do a cutout for the southwest, enlarged": the panel's
   context areas (cut by the panel, no link) as plain washes like an area at rest; the
   thin frame round the panel and the matching outline on the map, in the edge ink. */
.pa-inset-context {
  fill-rule: evenodd;
  fill-opacity: 0.8;
  stroke: #6d5a3f;
  stroke-opacity: 0.55;
  stroke-width: 2;
  pointer-events: none;
}
.pa-inset-frame,
.pa-inset-outline {
  fill: none;
  stroke: #6d5a3f;
  stroke-width: 1.5;
  pointer-events: none;
}
.pa-inset-outline {
  stroke-dasharray: 5 4;
}
.pa-svg-focus .pa-shape.pa-current {
  fill-opacity: 0.8;
  stroke: var(--pa-accent);
  stroke-opacity: 0.9;
  stroke-width: 4;
}
/* Hover, keyboard focus and the card-to-map sync (.pa-hot) brighten the area. WHY on
   the link: the path's own filter is the wash, which a CSS filter would replace. */
.pa-svg a {
  cursor: pointer;
  transition: filter 0.15s;
}
.pa-svg a:hover,
.pa-svg a:focus,
.pa-svg a.pa-hot {
  filter: brightness(1.07);
}
.pa-svg a:focus {
  outline: none;
}
.pa-svg a:focus-visible .pa-shape {
  stroke: #3b2f22;
  stroke-opacity: 1;
  stroke-width: 5;
}
/* Neighbour slices: a faint wash with a dashed edge; Rancho Bernardo dotted, no fill
   (owner: "add Rancho Bernardo as a dotted-line"). The fade mask hides the far side. */
.pa-slice {
  fill: #e9e0cf;
  stroke: #bfae8f;
  stroke-width: 1.2;
  stroke-dasharray: 6 5;
  opacity: 0.8;
}
.pa-slice.pa-slice-dotted {
  fill: none;
  stroke-dasharray: 1 5;
  stroke-linecap: round;
}
/* GH #4577 (owner 2026-11-28, verbatim: "show I-5 and 162", read as I-5 and SR-163):
   the SDCF freeways over the washes, a paper casing under a thin ink line, round caps
   and joins so the segments read as one road. WHY these widths (user units; the SDCF
   map draws at about half its viewBox width): the line is wide enough that a divided
   freeway's two carriageways, a few units apart, merge into one road. WHY no pointer
   events: a freeway and its shield are landmarks, and the area link under them must
   stay clickable. */
.pa-hwy path {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  pointer-events: none;
}
.pa-hwy-casing {
  stroke: #fbf7ef;
  stroke-opacity: 0.9;
  stroke-width: 10;
}
.pa-hwy-line {
  stroke: #7a6650;
  stroke-opacity: 0.85;
  stroke-width: 4.5;
}
/* The route shields (owner 2026-11-28, verbatim: "I-5 in SDCF map has wrong highway
   symbol (see other maps)"): the standard symbols in the blog ZIP/area cards' colours
   (route66-blogsites scripts/zip_maps.py): an Interstate is the blue shield with the
   red crown band, a white divider and edge; a California state route is the cards'
   green rounded badge with a white edge (zip_maps.py shield(): the other maps win);
   both with white bold numerals. WHY no pointer events: a landmark, so the area link
   under it stays clickable. */
.pa-hwy-shield {
  pointer-events: none;
}
.pa-hwy-shield-i .pa-shield-body {
  fill: #1f4e9c;
}
.pa-hwy-shield-i .pa-shield-band {
  fill: #c8102e;
  stroke: #ffffff;
  stroke-width: 1;
}
.pa-hwy-shield-i .pa-shield-edge {
  fill: none;
  stroke: #ffffff;
  stroke-width: 1.5;
}
.pa-hwy-shield-sr rect {
  fill: #3a7a4a;
  stroke: #ffffff;
  stroke-width: 1.5;
}
.pa-hwy-shield text {
  font-family: var(--pa-sans);
  font-weight: 700;
  fill: #ffffff;
}

/* Labels: the italic serif with a paper halo, the "N from $pK" line in a small sans. */
.pa-area-label,
.pa-slice-label {
  font-family: var(--pa-serif);
  font-style: italic;
  font-weight: 500;
  fill: #3b2f22;
  paint-order: stroke;
  stroke: rgba(247, 241, 230, 0.8);
  stroke-width: 5px;
  stroke-linejoin: round;
}
/* An area label is never a pointer target: the area's shape under it is the link. */
.pa-area-label {
  pointer-events: none;
}
/* Callouts (owner 2026-11-28, verbatim: "in SDCF mapp, use "callouts" on the shapes
   that are too small to label inline"): a thin ink leader from a dot in the area to
   its label outside it. WHY the hit area: the label keeps pointer events none, so the
   invisible block box behind it takes the click for the callout's area link. Hover
   and the card sync (.pa-hot) turn the label and leader navy, as a slice label does;
   no brightness filter, which would only wash the ink. */
.pa-callout-leader {
  fill: none;
  stroke: #3b2f22;
  stroke-opacity: 0.75;
  stroke-width: 1.2;
}
.pa-callout-dot {
  fill: #3b2f22;
}
.pa-callout-hit {
  fill: none;
  pointer-events: all;
}
.pa-callout:hover .pa-area-label,
.pa-callout.pa-hot .pa-area-label {
  fill: var(--pa-accent);
}
.pa-callout:hover .pa-callout-leader,
.pa-callout.pa-hot .pa-callout-leader {
  stroke: var(--pa-accent);
  stroke-opacity: 1;
}
.pa-svg a.pa-callout:hover,
.pa-svg a.pa-callout:focus,
.pa-svg a.pa-callout.pa-hot {
  filter: none;
}
/* A neighbour label is its own link (GH #4570 mockup v2, owner: "Make the surroundings
   clickable"), so it takes the pointer. */
.pa-slice-label {
  font-size: 32px;
  fill: #7d6b4f;
  letter-spacing: 0.02em;
  stroke-width: 6px;
  pointer-events: auto;
}
/* GH #4570 mockup v2: a neighbour slice or label opens that neighbourhood's search. */
.pa-nb {
  cursor: pointer;
}
/* WHY all: the dotted slice's fill is none, so without it only its stroke is hit. */
.pa-slice.pa-slice-dotted {
  pointer-events: all;
}
/* Hover, keyboard focus and the slice-label sync (.pa-hot) darken the slice as in the
   mockup, and turn its label navy; the .pa-stat line keeps its own fill. */
.pa-nb:hover .pa-slice,
.pa-nb:focus-visible .pa-slice,
.pa-nb.pa-hot .pa-slice {
  opacity: 1;
  fill: #e2d4b8;
}
.pa-nb:hover .pa-slice-label,
.pa-nb.pa-hot .pa-slice-label {
  fill: var(--pa-accent);
}
/* WHY: the area brightness rule above targets every map link; a neighbour darkens
   instead, so it must not also brighten. */
.pa-svg a.pa-nb:hover,
.pa-svg a.pa-nb:focus,
.pa-svg a.pa-nb.pa-hot {
  filter: none;
}
.pa-area-label .pa-stat,
.pa-slice-label .pa-stat {
  font-family: var(--pa-sans);
  font-style: normal;
  font-weight: 600;
  fill: #6d5a3f;
}
.pa-slice-label .pa-stat {
  font-size: 17px;
  fill: #8f7d60;
}
/* The paper grain overlays the whole map; clicks pass through to the links below. */
.pa-paper {
  pointer-events: none;
}
/* GH #4570 mockup v2 (page.tpl.html .pin): a listing pin is a gold dot with a white
   ring, grown from r 8 to 12 while it or its result card is hovered (.pa-hot, set by
   planning-area-map.js). NOTE (owner 2026-11-29, verbatim: "show info on mouse-over the
   circle"): the pin takes pointer events, so hovering it shows its tooltip instead of
   the area link's "Columbia" title, and a click opens its listing. WHY visiblePainted:
   only the dot itself is the target, so a click on bare area beside it still opens
   the area. */
.pa-pin {
  fill: var(--pa-gold);
  stroke: #ffffff;
  stroke-width: 2.5;
  pointer-events: visiblePainted;
  cursor: pointer;
  transition: r 0.15s;
}
.pa-pin.pa-hot {
  r: 12px;
}
/* Owner 2026-11-29, verbatim: "show info on mouse-over the circle": the one pin
   tooltip, on the stylized map (planning-area-map.js, inside #pa-map) and on the street
   map (Leaflet's tooltip with className pa-tip). WHY the panel and ink on a soft shadow:
   legible over the watercolour and over the street tiles alike. WHY pre-line: the text
   is planningAreaPinTip's lines (price, beds / baths and square feet, address), so
   each breaks with no markup, and its first line, the price, is set bold in the price
   green. WHY max-content capped: an absolute box shrinks to its containing block, and
   Leaflet's tooltip pane has no width, so without it every word would wrap. WHY no
   pointer events: the tooltip never covers the pin it names as a target. */
.pa-tip,
.leaflet-tooltip.pa-tip {
  position: absolute;
  z-index: 2;
  width: max-content;
  max-width: min(16rem, calc(100% - 12px));
  padding: 6px 9px;
  background: var(--pa-panel);
  border: 1px solid var(--pa-line);
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(42, 34, 25, 0.22);
  color: var(--pa-ink);
  font: 400 13px/1.35 var(--pa-sans);
  white-space: pre-line;
  pointer-events: none;
}
.pa-tip::first-line {
  font-weight: 700;
  color: var(--pa-price);
}
/* WHY a fixed cap on the street map: the percentage would resolve against the
   zero-width tooltip pane. planning-area-street-map.js keeps it inside the map. */
.leaflet-tooltip.pa-tip {
  max-width: 16rem;
}
/* WHY no arrow: the stylized map's tooltip has none, and the street map's may be
   shifted off the pin's line to stay inside the map. WHY 18px from the pin's centre:
   clear of the lit pin's 12px radius, as on the stylized map. */
.leaflet-tooltip.pa-tip:before {
  display: none;
}
.leaflet-tooltip-right.pa-tip {
  margin-left: 18px;
}
.leaflet-tooltip-left.pa-tip {
  margin-left: -18px;
}

/* Home: the search row under the H1 (mockup v2); its extra fields sit behind "More
   filters". GH #4570 (owner: "deadspace at the top and top-right"): 12px over the H1,
   not 20px, now that the header sits directly on the split. */
.pa-home-head {
  padding-top: 12px;
}
/* The home sub-line is regular weight (mockup v2 page.tpl.html sets 400 on it). */
.pa-home-head .pa-stats {
  font-weight: 400;
}
.pa-quick-search {
  margin: 0 0 18px;
}
/* Owner 2026-11-29, verbatim: "review all sites for aligment, spacing, deadzones, etc":
   WHY no 560px cap: on the SDCF and CVSDH home the field stopped at x 1276 while the
   area cards under it ran to 1350 (DEV 1366px, run premerge-dba458bbf); the row now
   fills the listings column to the cards' edge. */
.pa-search {
  display: flex;
  gap: 8px;
}
.pa-search input {
  flex: 1 1 auto;
  min-width: 0;
  height: 44px;
  padding: 10px;
  border: 1px solid var(--pa-line);
  border-radius: 6px;
  background: var(--pa-panel);
  box-shadow: none;
}
/* WHY: on CTH, search-map.js swaps #keywords for Google's <gmp-place-autocomplete>,
   which the input rule above misses; as .form-control (width 100%, min-width auto) it
   would not shrink, and on CI DEV california-dev (premerge-beb06c4decb087cd3eb757a4fbe5cc554642b986,
   https://cth.cal-dev.us1.click/ at 390px) it pushed Search out to a 463px-wide page. */
.pa-search gmp-place-autocomplete {
  flex: 1 1 auto;
  min-width: 0;
}
.pa-search-go {
  min-height: 44px;
  padding: 10px 16px;
  border: 0;
  border-radius: 6px;
  background: var(--pa-accent);
  color: #ffffff;
  font-weight: 600;
}
.pa-search-go:hover,
.pa-search-go:focus {
  background: #16304f;
  color: #ffffff;
}
.pa-more {
  margin: 8px 0 0;
}
.pa-more > summary {
  display: inline-block;
  min-height: 44px;
  padding: 12px 0;
  cursor: pointer;
  color: var(--pa-accent);
}
.pa-section-title {
  font: italic 600 22px/1.2 var(--pa-serif);
  color: var(--pa-accent);
  margin: 0 0 12px;
}

/* Area cards (mockup v2): white panels on the paper, the name in the italic serif,
   the "N from $pK" line, a one-line teaser. */
.pa-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
  padding: 0;
  margin: 0 0 24px;
  list-style: none;
}
/* WHY min-width 0: a grid item defaults to its content's width, and the one-line
   teaser would otherwise stretch every column past the container. */
.pa-card {
  min-width: 0;
}
.pa-card a {
  display: block;
  height: 100%;
  min-height: 44px;
  padding: 14px;
  background: var(--pa-panel);
  border: 1px solid var(--pa-line);
  border-radius: 8px;
  text-decoration: none;
  color: inherit;
}
.pa-card-name {
  margin: 0 0 4px;
  font: italic 600 21px/1.2 var(--pa-serif);
  color: var(--pa-accent);
}
/* GH #4570: the card's "N from $pK" line, the map label's figure. */
.pa-card-stat {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: var(--pa-ink);
}
.pa-card-summary {
  display: block;
  font-size: 13px;
  color: var(--pa-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pa-card a:hover,
.pa-card a:focus,
.pa-card.pa-hot a {
  outline: 2px solid var(--pa-gold);
}

/* Chips: one row that wraps (mockup v2), each a pill with its "N from $pK". */
.pa-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 16px;
  padding: 0;
}
.pa-chip {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  margin: 0;
  padding: 5px 11px;
  background: var(--pa-panel);
  border: 1px solid var(--pa-line);
  border-radius: 999px;
  font-size: 13px;
  font-weight: normal;
  color: var(--pa-ink);
  white-space: nowrap;
  text-decoration: none;
}
.pa-chip:hover,
.pa-chip:focus {
  border-color: var(--pa-accent);
  text-decoration: none;
}
/* Picker toggle chips: the real checkbox stays focusable but is drawn as the chip. */
.pa-picker fieldset {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 0 8px;
  margin: 0 0 16px;
  padding: 0;
  border: 0;
  min-width: 0;
}
/* /search picker chips stay on ONE row that scrolls sideways: wrapped, SDCF's area
   chips pushed the listings below the fold (CI DEV california-dev
   premerge-1a32687f13bb6b959d7e81eae722c1cb404f4001: SDCF/unit-number-search-card
   "did not paint its photo", SDCF/search-result 183 < 195 photo cells). The landing
   pages' .pa-area-nav chips keep wrapping. The row itself is the shared .pa-chip-row
   below (views writePlanningAreaChipRowOpen), as on the "Nearby" row. */

/* Owner 2026-11-29, verbatim: "the pills behave awkardly in horizontal scroll": the one
   chip row the "Nearby" row and the /search picker share. WHY each:
   - the row takes the space its flex parent leaves (flex 1 1 0) and min-width 0, so it
     never widens its form, column or page; only .pa-chips scrolls, and overscroll
     contain keeps a trackpad flick at its end from scrolling anything behind it;
   - snap (proximity: a flick still glides) lands a pill at the start, the 32px scroll
     padding clearing the fade and the "scroll back" button there;
   - no scrollbar: the 6px track under one 32px row read as a broken page; touch,
     trackpad, shift-wheel, keyboard focus and the buttons all still scroll it;
   - the edge fades only where pills remain (.pa-more-start / .pa-more-end, set by
     planning-area-chips.js; without script there is no fade, nothing hides a pill);
   - the 4px block padding, taken back by the negative margin, keeps a focused chip's
     outline inside the scroller, which clips both axes;
   - position relative makes the scroller each chip's offsetParent, which the script's
     selected-pill centring reads. */
/* Owner 2026-11-29, verbatim: "review all sites for aligment, spacing, deadzones, etc":
   WHY the row is a flex line of ‹ scroller ›: the buttons used to sit absolutely over
   the scroller's ends, so the last pill ran under the "scroll on" button and was cut
   hard at the Update button (DEV 1366px, run premerge-dba458bbf: "Streeterville 209
   from $159" behind Update with the › missing while .pa-more-end said more follow).
   As flex items each button takes its own 28px before Update, and the scroller's fade
   ends just before it. */
.pa-chip-row {
  --pa-fade-start: 0px;
  --pa-fade-end: 0px;
  position: relative;
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1 1 0;
  min-width: 0;
}
.pa-chip-row.pa-more-start {
  --pa-fade-start: 32px;
}
.pa-chip-row.pa-more-end {
  --pa-fade-end: 32px;
}
.pa-chip-row > .pa-chips {
  position: relative;
  flex: 1 1 0;
  min-width: 0;
  flex-wrap: nowrap;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x proximity;
  scroll-padding-inline: 32px;
  scrollbar-width: none;
  margin: -4px 0;
  padding: 4px 0;
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 var(--pa-fade-start), #000 calc(100% - var(--pa-fade-end)), transparent 100%);
  mask-image: linear-gradient(to right, transparent 0, #000 var(--pa-fade-start), #000 calc(100% - var(--pa-fade-end)), transparent 100%);
}
.pa-chip-row > .pa-chips::-webkit-scrollbar {
  display: none;
}
.pa-chip-row .pa-chip {
  scroll-snap-align: start;
}
/* The ‹ › buttons at the row's ends: one viewport of pills a click. WHY per side: a
   button shows only where pills remain past that end (the script's classes), so a row
   that fits shows none. WHY on every pointer now (owner 2026-11-29, verbatim: "review
   all sites for aligment, spacing, deadzones, etc"): the hover-and-fine-pointer gate
   kept them off because a button over the row covered a pill on touch; beside the
   scroller it covers nothing, and it tells every visitor more areas follow. */
.pa-chip-nav {
  display: none;
  flex: 0 0 28px;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0 0 2px;
  border: 1px solid var(--pa-line);
  border-radius: 50%;
  background: var(--pa-panel);
  box-shadow: 0 1px 3px rgba(42, 34, 25, 0.2);
  color: var(--pa-accent);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}
.pa-chip-nav:hover {
  border-color: var(--pa-accent);
}
.pa-chip-row.pa-more-start > .pa-chip-prev,
.pa-chip-row.pa-more-end > .pa-chip-next {
  display: flex;
}
.pa-picker legend {
  flex: 0 0 100%;
  font-size: 12px;
  font-weight: bold;
  border: 0;
  margin: 0 0 4px;
  color: var(--pa-muted);
}
.pa-toggle {
  position: relative;
  cursor: pointer;
}
.pa-toggle input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}
.pa-toggle:has(input:checked),
.pa-chip.pa-chip-on {
  background: var(--pa-accent);
  border-color: var(--pa-accent);
  color: #ffffff;
}
.pa-toggle:has(input:focus-visible) {
  outline: 2px solid var(--pa-ink);
  outline-offset: 2px;
}
/* A chip's "N from $pK", quieter than the name. */
.pa-chip-count {
  margin-left: 6px;
  color: inherit;
  opacity: 0.7;
}
.pa-area-nav .pa-chips {
  margin: 0 0 16px;
}
.pa-chip-go {
  flex: 0 0 auto;
  min-height: 32px;
  border: 0;
  border-radius: 999px;
  background: var(--pa-accent);
  color: #ffffff;
}
/* Owner 2026-11-29, verbatim: "bring \"Nearby areas\" to the newly empty area at the top,
   fully horizontal (pillboxes to top the right of the \"Nearby\" heading": the "Nearby"
   row (views planningAreaNearbyRow). Phone first: its own line under the header, the
   heading then one chip row that scrolls sideways, so it never grows past one line.
   WHY nowrap and scroll, not wrap: one tidy row, the same .pa-chip-row as the /search
   picker. */
.pa-nearby {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  margin: 0;
  padding: 4px 15px;
  font-size: 13px;
}
.pa-nearby-title {
  flex: 0 0 auto;
  font: italic 600 20px/1 var(--pa-serif);
  color: var(--pa-accent);
}
/* WHY: a brand-area chip shares the map area's data-slug, so planning-area-map.js marks
   it .pa-hot while its area is hovered, and the reverse. */
.pa-nearby .pa-chip.pa-hot {
  border-color: var(--pa-accent);
}
/* GH #4570: an empty landing page's honest empty state (the mockup's dashed box). */
.pa-empty {
  margin: 16px 0;
  padding: 28px;
  border: 1px dashed var(--pa-line);
  border-radius: 8px;
  text-align: center;
  color: var(--pa-muted);
}
.pa-empty-title {
  display: block;
  margin: 0 0 6px;
  font: italic 600 21px/1.2 var(--pa-serif);
  color: var(--pa-accent);
}
/* On a CVSDH search page the search summary reads as a plain line over the chips. */
#main:has(.pa-picker) > .well.pageHeading {
  background: none;
  border: 0;
  box-shadow: none;
  padding: 0;
  margin: 0 0 8px;
}

/* Owner 2026-11-28, verbatim: "this entire area is a waste of space ... compress it
   somehow to start the photos further up": the listings column's toolbar. WHY each:
   the heading and "revise search" share one 14px line; the picker's legend is kept for
   assistive technology but not drawn (the chips name the areas); Save Search, the
   compare bar and the sort select share one wrapping row at button height, so the
   photos start about three rows higher. The heading, picker and alert keep a full
   row each. */
.pa-split-list #main {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
  padding-top: 10px;
}
/* WHY min-width 0 (owner 2026-11-29, verbatim: "the pills behave awkardly in horizontal
   scroll"): a flex item's automatic minimum is its min-content width, and the picker
   form's is its whole nowrap chip row, so the form grew past the column; its chip row
   then had nothing to scroll and a sideways swipe scrolled the whole listings column,
   cards sliding under the map (CTC DEV, https://ctc.chi-dev.us1.click/search with East
   Village selected). At 0 the form is the column's width and the row scrolls inside it. */
.pa-split-list #main > * {
  flex: 0 0 100%;
  min-width: 0;
}
.pa-split-list #main > .well.pageHeading {
  background: none;
  border: 0;
  box-shadow: none;
  padding: 0;
  margin: 0;
  font-size: 14px;
}
.pa-split-list .pa-picker fieldset {
  margin: 0;
}
.pa-split-list .pa-picker legend {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.pa-split-list #main > [class*="col-"] {
  flex: 0 0 auto;
  width: auto;
  float: none;
  margin: 0;
  padding: 0;
}
/* Owner 2026-11-29, verbatim: "review all sites for aligment, spacing, deadzones, etc":
   the sort select moved into the toolbar's .search-tools group with Save Search
   (search-continuity.css lays it out on every brand), so the former #main > .sort-by
   order and height rules here matched nothing and are gone. */
.pa-split-list #main > [class*="col-"] .btn {
  padding: 4px 10px;
  font-size: 13px;
}
.pa-split-list .list-results .found {
  margin: 4px 0 6px;
}
/* GH #4549: the promoted "Found" h1 (search_result.css .search-heading) takes the same margin. */
.pa-split-list .list-results .found p,
.pa-split-list .list-results .found h1 {
  margin: 0;
}

/* Landing page: the heading block carries the area's numbers, so the result list's
   own "Found N listings" line and the "revise search" link above it are dropped there.
   WHY every direct link of #main: _header_body nests the "revise search" <a> inside
   #revise-toggle's <a>, which the HTML parser splits into sibling links. */
.pa-landing-head ~ .list-results .found,
.pa-landing-head ~ #main > a {
  display: none;
}
/* GH #4570 (owner: "deadspace at the top and top-right"): 12px, as on the home page. */
.pa-landing-head {
  padding-top: 12px;
}
/* Owner 2026-11-29, verbatim: "chicago needs filters in that empty space": the landing
   head's compact filter row (views writeSearchFilterRow) on the numbers' line,
   pushed right into the blank band under the sort select. WHY a wrapping flex row: the
   H1 keeps a whole line (from 768px its right padding still clears the select), the
   numbers and the filters share the next line when they fit, and when they do not the
   filters drop whole to a line of their own; nothing ever scrolls sideways. WHY only
   with the row (:has): an area with nothing for sale writes none, and its head keeps
   its block layout. WHY no ::before/::after: Bootstrap's .container clearfix
   pseudo-elements would be flex items and take a gap each. */
.pa-landing-head:has(> .pa-filters) {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  column-gap: 16px;
}
.pa-landing-head:has(> .pa-filters)::before,
.pa-landing-head:has(> .pa-filters)::after {
  content: none;
}
.pa-landing-head:has(> .pa-filters) > .pa-title {
  flex: 0 0 100%;
}
.pa-landing-head:has(> .pa-filters) > .pa-stats {
  flex: 0 1 auto;
}
/* The row's own look (small controls, wrapping, the phone line) is in
   search-continuity.css, which every brand's search page links (owner 2026-11-29,
   verbatim: "basic bed/bath/price filters are universally needed"). Here only its place
   in the landing head: pushed right into the blank band under the sort select, clear of
   the cards below. */
.pa-landing-head > .pa-filters {
  margin: 0 0 10px auto;
}
/* Phones: the row's own full line under the numbers, flush left. */
@media (max-width: 767.99px) {
  .pa-landing-head > .pa-filters {
    margin-left: 0;
  }
}

/* GH #4570 (owner: "change the layout to be more like zillow: map on the left,
   listings on the right"): the split view on the home, landing and search pages
   (planningAreaHomeHero, planningAreaSearchSplitOpen). Phone first: the map stacks on
   top at a fixed height (mockup v2: 340px), the listings below. */
.pa-split-map {
  position: relative;
  background: #f7f1e6;
  border-bottom: 1px solid var(--pa-line);
}
/* Owner 2026-11-29 ("the pills behave awkardly in horizontal scroll"): the listings
   column never scrolls sideways, whatever a child's width; only a chip row does. WHY
   clip: it creates no scroller, so on a phone the page keeps its one vertical scroll;
   from 768px, beside the column's overflow-y auto, it computes to hidden, which a wheel
   or trackpad cannot scroll. The "Nearby" row gets the same guard for the page header. */
.pa-split-list,
.pa-nearby {
  overflow-x: clip;
}
/* The result cards as white panels on the paper (mockup v2), gold-outlined on hover
   and, through the pin sync's .pa-hot (GH #4570), while keyboard focus is inside. */
.pa-split-list .result-card {
  background: var(--pa-panel);
  border: 1px solid var(--pa-line);
  border-radius: 8px;
  overflow: hidden;
}
.pa-split-list .result-card:hover,
.pa-split-list .result-card.pa-hot {
  outline: 2px solid var(--pa-gold);
}
.pa-below {
  margin-top: 24px;
}

/* Detail: the listing's planning area is one Geographic Areas line. */
.pa-detail-link {
  font-weight: bold;
}

/* Phone-width sticky Call / Message bar; the page keeps room for it at its end. */
.pa-callbar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
  display: flex;
  gap: 8px;
  padding: 8px 16px;
  background: var(--pa-panel);
  border-top: 1px solid var(--pa-line);
}
.pa-callbar .btn {
  flex: 1 1 0;
  min-height: 44px;
  padding-top: 11px;
}
body:has(.pa-callbar) {
  padding-bottom: 64px;
}
/* WHY: the floating compare pill (search_result.css) rides above the call bar instead of
   covering its Call / Message buttons; the bar is hidden from 768px, where the pill's
   own bottom offset applies again. */
@media (max-width: 767.99px) {
  body:has(.pa-callbar) .r66-compare-selection {
    bottom: 72px;
  }
}
html:has(.pa-callbar) {
  scroll-padding-bottom: 64px;
}

/* Phone-width nav: one row. WHY: below 1280px every tab is icon-only, and this brand's
   eight tabs at Bootstrap's 15px side padding (48px each, plus the profile caret) wrap
   to two rows inside a 390px phone's 360px container. 10px a side (38px a tab, the
   same padding _global.css gives every brand from 1280px) fits ~316px on one row and
   keeps each target above WCAG 2.5.8's 24px. Wider screens keep the shared padding. */
@media (max-width: 599px) {
  .nav-wrapper .nav-tabs > li > a {
    padding-left: 10px;
    padding-right: 10px;
  }
  .pa-logo {
    font-size: 22px;
  }
}

/* Tablet and up: no call bar; the split view side by side. */
@media (min-width: 768px) {
  .pa-callbar {
    display: none;
  }
  body:has(.pa-callbar) {
    padding-bottom: 0;
  }
  html:has(.pa-callbar) {
    scroll-padding-bottom: 0;
  }
  .pa-title {
    font-size: 34px;
  }
  .pa-home .pa-title {
    font-size: 40px;
  }

  /* GH #4570 split view (mockup v2, page.tpl.html: the map column a little wider).
     WHY one viewport: the owner requires the map never to be chopped below the fold,
     so the body is a column whose header rows keep their height and whose split
     takes exactly what is left; the map fits that whole (meet) and only the list
     column scrolls. The body's other children (nav, call bar, scripts) keep their own
     height. */
  body:has(> .pa-split) {
    display: flex;
    flex-direction: column;
    height: 100vh;
    height: 100dvh;
    overflow: hidden;
  }
  body:has(> .pa-split) > * {
    flex: none;
  }
  /* WHY flex basis 0 and min-height 0: the split fills the remaining height and may
     shrink below its content, which the list column then scrolls. */
  /* GH #4580 (owner 2026-11-28, verbatim: "this layout is not optimal, too much dead
     space"): the map column is as wide as the map needs at the split's height, never
     wider than the old 1.05fr share; the list takes the rest. WHY: a fixed share left
     a tall map (CTC, 589x917) in the middle third with blank paper bands both sides
     and squeezed the cards, while a wide map (SDCF, CVSDH) still fills its share
     exactly as before. WHY a size container: its cqh/cqw units give the map the
     split's own height and width; the split's size comes from the body column and the
     viewport, never from its content, so size containment changes nothing else. */
  body:has(> .pa-split) > .pa-split {
    flex: 1 1 0;
    min-height: 0;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: stretch;
    container-type: size;
  }
  /* WHY width auto at full height: the SVG has a viewBox and no width or height, so
     its width follows its own aspect ratio, and the auto column takes that width. The
     cap is the old 1.05fr of 2.05fr; a capped map fits whole (meet), pinned to the
     column's top (YMin, owner 2026-11-29), so its spare paper falls below it. */
  .pa-split .pa-svg {
    width: auto;
    height: 100cqh;
    max-width: calc(100cqw * 1.05 / 2.05);
  }
  /* WHY: the Leaflet street map has no aspect ratio of its own, so it keeps the old
     share outright; without it the auto column would collapse to nothing. */
  .pa-split #pa-map.pa-street-map {
    width: calc(100cqw * 1.05 / 2.05);
  }
  /* The map column stretches to the split's full height beside the list. */
  .pa-split-map {
    position: relative;
    height: auto;
    margin: 0;
    border-bottom: 0;
    border-right: 1px solid var(--pa-line);
    overflow: hidden;
  }
  .pa-split #pa-map {
    height: 100%;
  }
  /* The list column is the one scroller, so the map stays in view. */
  .pa-split-list {
    min-height: 0;
    overflow-y: auto;
  }
  /* WHY width auto: Bootstrap's .container fixes a page-wide width at each
     breakpoint, which would overflow the half-width column. */
  .pa-split-list .container {
    width: auto;
  }
  /* Owner 2026-11-29, verbatim: "align top" (the landing page's sort select sat alone on
     a row under the area heading). On a landing page the select is the toolbar's only
     member, so it moves up to the heading's top-right corner: the column is its
     containing block, and the offsets mirror the heading's 12px top padding and the
     .container's 15px gutter. WHY the title's right padding: a long area name wraps
     before it reaches the select. Search pages, which have no .pa-landing-head, are
     unchanged; phones keep the select on its own row under the heading. */
  .pa-split-list:has(> .pa-landing-head) {
    position: relative;
  }
  .pa-landing-head ~ #main {
    position: static;
  }
  .pa-landing-head ~ #main > .search-tools {
    position: absolute;
    top: 12px;
    right: 15px;
  }
  .pa-split-list .pa-landing-head .pa-title {
    padding-right: 210px;
  }
  /* The result cards as a grid in the column (mockup v2 page.tpl.html .grid: two
     columns, one only in the phone frame). WHY grid, not the Bootstrap columns: their
     percentage widths and the breakpoint clearfix divs assume a page-wide row. Floats,
     widths, the clearfix divs and the row's clearfix pseudo-elements (which a grid
     would lay out as items) are neutralised here only.
     Owner 2026-11-30, verbatim: "broken layout at cortez hill search result on 4k
     browser", then "perhaps all \"non-4\" are broken?" / "non 4 wide results": WHY a
     card minimum and not a fixed two: a fixed two drew two ~950px cards a row in the
     ~1960px listings column at 3840px. Columns of at least 360px each (the card
     minimum coastal.css already gives CTH's two other layouts) fill the column, so a
     card keeps one size as the screen widens: 2 at 1920px, 3 at 2560px, 5 at 3840px on
     SDCF. WHY never under two (min with half the row, less half the 14px gap and 1px
     of rounding slack): a column narrower than 734px still lays two cards side by
     side. Any listings column under 1108px (three 360px tracks and two gaps) gets
     exactly two equal 1fr tracks, as before, so the reviewed 1280-1440px layouts and
     tablets are unchanged pixel for pixel. */
  .pa-split-list .list-results .row {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(360px, calc(50% - 8px)), 1fr));
    gap: 14px;
  }
  .pa-split-list .list-results .row::before,
  .pa-split-list .list-results .row::after {
    content: none;
  }
  .pa-split-list .list-results .result-wrap {
    float: none;
    width: auto;
  }
  /* Owner 2026-11-30, verbatim: "broken layout at cortez hill search result on 4k
     browser" and "cth too": WHY !important: from 1580px _global.css re-shows
     .hidden-lg with display block !important (its xl band, where DMV's floated
     col-xl-3 cards break a row every fourth card), which beat the plain rule here, so
     the renderer's every-fourth-card clearfix (template_search_result_search_result.go)
     took a grid cell and left a blank hole after every fourth card on every brand that
     links this file (SDCF, CVSDH, CTC, CTH), from 1580px up. Below 1580px every
     clearfix was already hidden, so this changes nothing there. DMV links no
     planning-areas.css and keeps its floats. */
  .pa-split-list .list-results .clearfix {
    display: none !important;
  }

  /* Owner 2026-11-29, verbatim: "SDCF still has a searious unused deadspace problem.
     Shift up the logo and menuvar (flush), then bring \"Nearby areas\" to the newly
     empty area at the top": on a page with the "Nearby" row the header is a grid on the
     body itself: the logo left across two rows, the tabs flush at the top right, the
     row under them, the split below. WHY display contents on the header: its logo and
     tabs become the body grid's items, so the row (a body child after the header) can
     sit beside the logo with no change to the shared nav markup. WHY only with the row:
     the other split pages (CTH, a brand with no place to offer) keep their flex header,
     and CTH's wide pages reset the body to plain flow (coastal.css). This rule comes
     after the split rules above, so its display wins at equal specificity. */
  body:has(> .pa-nearby) {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    grid-template-rows: auto auto minmax(0, 1fr);
  }
  body:has(> .pa-nearby) > .logo-menu-wrapper {
    display: contents;
  }
  /* WHY: the shared nav's clearfix div would take a grid cell. */
  body:has(> .pa-nearby) > .clearfix {
    display: none;
  }
  /* The logo centred down both header rows, 15px in from the edge as the container
     placed it. */
  body:has(> .pa-nearby) > .logo-menu-wrapper > .logo-wrapper {
    grid-column: 1;
    grid-row: 1 / 3;
    align-self: center;
    padding: 0 0 0 15px;
  }
  /* WHY 80px: the tab row and the chip row together, so an image logo (SDCF's badge
     plus wordmark, 600x193; CTC's 600x200) fills the two rows instead of the shared
     376px width cap's 121px, which left a blank band under the tabs; display block
     drops the inline image's descender gap. As CTH's 88px logo (coastal.css). The flex
     header above gives the same 80px on the brand's other pages (owner 2026-11-29,
     "this layout is discomboluated"); this rule keeps the grid's own block display. */
  body:has(> .pa-nearby) > .logo-menu-wrapper img.mainlogo {
    display: block;
    width: auto;
    height: 80px;
    max-width: none;
  }
  /* The tabs flush at the top right. */
  body:has(> .pa-nearby) > .logo-menu-wrapper > .nav-wrapper {
    grid-column: 2;
    grid-row: 1;
    align-self: start;
    padding-right: 15px;
  }
  body:has(> .pa-nearby) > .logo-menu-wrapper .nav {
    margin: 0;
  }
  /* The row in the space under the tabs, beside the logo. */
  body:has(> .pa-nearby) > .pa-nearby {
    grid-column: 2;
    grid-row: 2;
    align-self: center;
    padding: 4px 15px 4px 16px;
  }
  /* The split takes the full width and the rest of the viewport. */
  body:has(> .pa-nearby) > .pa-split {
    grid-column: 1 / -1;
    grid-row: 3;
  }
}
