/* Hallmark · shape: Index-first (the board leads) · genre: modern-minimal · theme: Wayfind (deal 1/3, seed condo-building-own-unit-28c0·9232c8df·2026-11-22·r0) · redesign: full
 * hero: Stage (/), Banner (/unit.html) · nav: edge-aligned, wordmark and links with one cobalt action · footer: a mast, the wordmark over the links · imagery: photographs (the template's demo photos, Unsplash) and drawn sample floor plans · signature: the availability board, an ink plate of unit types and units left set on the building's photograph · wayfind: platform
 * axes: light/mono/cool · posture: committed · contrast: pass · fold: pass · v2.0.0 */
/* Hallmark · pre-emit critique: P4 H5 E4 S5 R4 V5 · weakest: E, a long working page (calculator, table, form); every section is one sign with one job, the board and the table share the ink so availability reads as one system */
/* Hallmark · dropped js/ink.js, basin, .endpaper, .ink-band, img-index-9860e059, "Drag to stir the ink" · the marbled ink was the old theme's signature; the board on the building photo replaces it */
/* Hallmark · dismissed 76 · the Unsplash photos are the template's own demo content, documented in README.txt for buyers to replace */
/* Hallmark · dismissed 23 · amber display figures on ink plates are Wayfind's figure colour (the monthly, the from price), each under 2% of a screen */
/* Hallmark · dismissed F4 · the viewer's arrows and thumbnails are ink controls inside a full-screen dialog, not page buttons; the page has one filled primary */
/* Hallmark · dismissed 69 · prices repeat in the board, the type rows and the unit table, a ledger whose rows repeat by nature */
@import url("./tokens.css");
@import url("./base.css");

/* =========================================================
   THE LINDEN, condo building website template.
   Colours and the font are in css/tokens.css (one place):
   --color-paper (background), --color-ink (text and plates),
   --color-accent (cobalt: buttons, what is live), --color-accent-2 (amber: figures on ink),
   --font-display (Chivo Mono, loaded in each page's <head>).
   ========================================================= */
:root {
  --color-on-ink: oklch(96% 0.005 250);
  --color-on-ink-muted: oklch(80% 0.012 255);
  --header-h: 72px;
}

body { font-variant-numeric: tabular-nums; }
.sprite { position: absolute; width: 0; height: 0; }
svg.i { width: 22px; height: 22px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
h1 { font-size: min(var(--text-display), 4.75rem); line-height: 0.98; }
h2, h3 { line-height: 1; }
small, th, figcaption, dt, label { font-weight: 500; }
.section { padding-block: var(--section-gap); }
.section + .section { padding-top: var(--section-gap-s); }
.band-ink { background: var(--color-ink); color: var(--color-on-ink); padding-block: var(--section-gap-s); }
.band-2 { background: var(--color-paper-2); padding-block: var(--section-gap-s); }
.band-ink :focus-visible, .plate :focus-visible { outline-color: var(--color-accent-2); }
.note { font-size: var(--text-sm); color: var(--color-muted); max-width: 65ch; }

/* ---------- The sign: a head on the left, its line on the right, a bar under both ---------- */
.section-head { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--space-md) var(--gap-columns); align-items: end; padding-bottom: var(--space-lg); margin-bottom: var(--space-2xl); border-bottom: var(--rule-bar) solid currentColor; }
.section-head p { color: var(--color-muted); max-width: 52ch; }
.band-ink .section-head p { color: var(--color-on-ink-muted); }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-xs); min-height: 52px; padding: 0 var(--space-lg); border: var(--rule-bar) solid currentColor; background: transparent; color: var(--color-ink); font: 800 var(--text-sm)/1 var(--font-body); text-decoration: none; white-space: nowrap; cursor: pointer; transition: background-color var(--dur-micro) steps(1), color var(--dur-micro) steps(1), border-color var(--dur-micro) steps(1); }
.btn:hover { background: var(--color-ink); color: var(--color-paper); border-color: var(--color-ink); }
.btn:active { transform: translateY(1px); }
.btn:disabled { cursor: not-allowed; opacity: 0.6; background: var(--color-paper-2); color: var(--color-muted); border-color: var(--color-rule); }
.btn-primary { background: var(--color-accent); border-color: var(--color-accent); color: var(--color-accent-ink); }
.btn-primary:hover { background: var(--color-ink); border-color: var(--color-ink); color: var(--color-paper); }
.btn-line { color: var(--color-ink); }

/* ---------- Header and navigation (shared) ---------- */
.site-header { border-bottom: var(--rule-bar) solid var(--color-ink); background: var(--color-paper); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: var(--space-md); min-height: var(--header-h); }
.header-inner > * { flex-shrink: 0; white-space: nowrap; }
.wordmark { font-weight: 800; font-size: var(--text-lg); letter-spacing: -0.02em; color: var(--color-ink); text-decoration: none; }
.wordmark:hover { color: var(--color-accent); }
.site-nav { display: flex; align-items: center; }
.menu-button { display: inline-flex; align-items: center; gap: var(--space-xs); min-height: 44px; padding: 0 var(--space-md); border: var(--rule-bar) solid var(--color-ink); background: var(--color-paper); color: var(--color-ink); font: 800 var(--text-sm) var(--font-body); cursor: pointer; anchor-name: --menu-button; }
.menu-button:hover { background: var(--color-ink); color: var(--color-paper); }
.menu-button:active { transform: translateY(1px); }
.site-menu { list-style: none; margin: 0; padding: var(--space-xs); background: var(--color-paper-3); border: var(--rule-bar) solid var(--color-ink); position: fixed; inset: auto; inset-block-start: 4.5rem; inset-block-start: anchor(--menu-button bottom); inset-inline-end: var(--space-md); inline-size: min(84dvw, 20rem); max-block-size: calc(100dvh - 6rem); margin-block-start: var(--space-xs); overflow: auto; box-shadow: var(--shadow-card); }
.site-menu a { display: flex; align-items: center; min-height: 48px; padding: 0 var(--space-sm); color: var(--color-ink); font-weight: 500; text-decoration: none; }
.site-menu a:hover, .site-menu a[aria-current="page"] { text-decoration: underline var(--rule-bar); text-underline-offset: 0.3em; color: var(--color-accent); }
.site-menu .nav-visit { justify-content: center; margin-top: var(--space-xs); background: var(--color-accent); color: var(--color-accent-ink); font-weight: 800; }
.site-menu .nav-visit:hover { background: var(--color-ink); color: var(--color-paper); text-decoration: none; }
.is-wide .menu-button { display: none; }
.is-wide .site-menu { position: static; display: flex; align-items: center; gap: var(--space-2xs); inline-size: auto; max-inline-size: none; max-block-size: none; overflow: visible; margin: 0; padding: 0; border: 0; background: transparent; box-shadow: none; }
.is-wide .site-menu .nav-visit { margin: 0 0 0 var(--space-sm); min-height: 44px; padding: 0 var(--space-md); }
.is-measuring .site-menu { visibility: hidden; }

/* ---------- Hero: the building and its board ---------- */
.hero { border-bottom: var(--rule-bar) solid var(--color-ink); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--space-3xl); align-items: center; min-height: calc(100svh - var(--header-h)); padding-block: var(--space-2xl); }
.hero-text { display: grid; gap: var(--space-lg); justify-items: start; }
.hero-text .lead { color: var(--color-ink-2); max-width: 36ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: var(--space-sm); margin-top: var(--space-xs); }
.hero-visual { position: relative; padding-bottom: var(--space-2xl); }
.frame { margin: 0; border: var(--rule-bar) solid var(--color-ink); background: var(--color-paper-3); }
.frame > img, .frame > button > img { width: 100%; height: 100%; object-fit: cover; filter: saturate(0.88) contrast(1.1); }
.frame figcaption { padding: var(--space-xs) var(--space-sm); border-top: var(--rule-bar) solid var(--color-ink); font-size: var(--text-sm); }
.hero-photo { aspect-ratio: 4 / 3; display: grid; grid-template-rows: minmax(0, 1fr) auto; }
.hero-photo figcaption { text-align: right; }
.plate { background: var(--color-ink); color: var(--color-on-ink); border: var(--rule-bar) solid var(--color-ink); }
.board { position: absolute; left: calc(var(--space-2xl) * -1); bottom: 0; width: min(29rem, 78%); padding: var(--space-md) var(--space-lg) var(--space-lg); box-shadow: var(--shadow-card); }
.type-list { list-style: none; margin: 0; padding: 0; }
.type-list li + li { border-top: var(--rule-hair) solid var(--color-ink-rule); }
.type-list a { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: var(--space-md); align-items: baseline; min-height: 52px; padding: var(--space-xs) 0; color: var(--color-on-ink); text-decoration: none; }
.type-list a:hover b { text-decoration: underline var(--rule-bar); text-underline-offset: 0.25em; }
.type-list b { font-weight: 800; }
.type-list .from { color: var(--color-on-ink-muted); font-size: var(--text-sm); }
.type-list .left { min-width: 6ch; text-align: right; font-weight: 800; color: var(--color-accent-2); }
.type-list .is-out .left { color: var(--color-on-ink-muted); font-weight: 500; }
.board-note { margin-top: var(--space-sm); font-size: var(--text-sm); color: var(--color-on-ink-muted); max-width: 44ch; }

/* ---------- Unit types: one row each, the plan as the picture ---------- */
.types { display: grid; }
.type-row { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); grid-template-rows: auto minmax(0, 1fr); column-gap: var(--space-3xl); row-gap: var(--space-xl); align-items: start; padding-block: var(--space-2xl); border-top: var(--rule-hair) solid var(--color-rule); }
.type-row > figure { grid-column: 1; grid-row: 1 / 3; }
.type-row > div { grid-column: 2; }
.type-row > div:last-child { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--space-lg); align-items: end; padding-top: var(--space-lg); border-top: var(--rule-bar) solid var(--color-ink); }
.type-row:first-child { border-top: 0; padding-top: 0; }
.type-row h3 { font-size: var(--text-section); }
.price-line { display: flex; flex-wrap: wrap; gap: var(--space-2xs) var(--space-lg); margin-top: var(--space-md); font-size: var(--text-lg); color: var(--color-ink-2); }
.price-line b { font-weight: 800; color: var(--color-ink); }
.type-row figure { margin: 0; border: var(--rule-bar) solid var(--color-ink); background: var(--color-paper-3); aspect-ratio: 4 / 3; }
.type-row figure img { width: 100%; height: 100%; object-fit: contain; padding: var(--space-md); }
.type-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-md) var(--space-lg); margin: 0; }
.type-facts dt { font-size: var(--text-sm); color: var(--color-muted); }
.type-facts dd { margin: 0; font-weight: 800; }

/* ---------- Availability: the departure board ---------- */
.filters { display: flex; flex-wrap: wrap; align-items: end; gap: var(--space-md) var(--space-lg); margin-bottom: var(--space-md); }
.filters label { display: grid; gap: var(--space-2xs); font-size: var(--text-sm); }
.filters select { min-height: 48px; min-width: 13rem; padding: 0 var(--space-sm); border: var(--rule-bar) solid var(--color-on-ink); border-radius: 0; background: var(--color-ink); color: var(--color-on-ink); font: inherit; font-size: var(--text-md); cursor: pointer; }
.filters .check { display: flex; align-items: center; gap: var(--space-xs); min-height: 48px; cursor: pointer; }
.filters .check input { width: 20px; height: 20px; margin: 0; accent-color: var(--color-accent-2); }
.table-count { min-height: 1.5em; margin-bottom: var(--space-sm); font-size: var(--text-sm); color: var(--color-on-ink-muted); }
.table-wrap { overflow-x: auto; }
.table-wrap:focus-visible { outline-offset: 4px; }
.units-table { width: 100%; min-width: 46rem; border-collapse: collapse; }
.units-table th, .units-table td { padding: var(--space-sm) var(--space-sm) var(--space-sm) 0; text-align: left; white-space: nowrap; }
.units-table thead th { border-bottom: var(--rule-bar) solid currentColor; font-size: var(--text-sm); color: var(--color-on-ink-muted); }
.units-table tbody th, .units-table tbody td { border-bottom: var(--rule-hair) solid var(--color-ink-rule); }
.units-table tbody th { font-weight: 800; font-size: var(--text-lg); }
.units-table td:nth-child(5), .units-table td:nth-child(6) { font-weight: 800; color: var(--color-accent-2); }
.units-table tr.is-taken th, .units-table tr.is-taken td { color: var(--color-on-ink-muted); font-weight: 500; }
.units-table tr.is-taken td:not(:last-child) { text-decoration: line-through 1px; }
.state { display: inline-block; padding: var(--space-3xs) var(--space-xs); border: var(--rule-bar) solid transparent; font-weight: 800; font-size: var(--text-sm); }
.state.is-available { background: var(--color-accent-2); color: var(--color-ink); }
.state.is-reserved { border-color: currentColor; }
.state.is-sold, .state.is-rented { font-weight: 500; }

/* The unit page's table sits on paper: the same board in paper colours. */
.unit-page .units-table thead th, .unit-page .table-count { color: var(--color-muted); }
.unit-page .units-table tbody th, .unit-page .units-table tbody td { border-bottom-color: var(--color-rule); }
.unit-page .units-table td:nth-child(5), .unit-page .units-table td:nth-child(6) { color: var(--color-ink); }
.unit-page .units-table tr.is-taken th, .unit-page .units-table tr.is-taken td { color: var(--color-muted); }

/* ---------- The building: photos, then amenities as rows ---------- */
.photo-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 2.5fr) minmax(0, 2.5fr); grid-template-rows: 300px 300px; gap: var(--space-md); margin-bottom: var(--section-gap-s); }
.photo-grid .frame { display: grid; grid-template-rows: minmax(0, 1fr) auto; }
.photo-grid .frame:first-child { grid-row: 1 / 3; }
.photo-grid .frame:nth-child(2) { grid-column: 2 / 4; }
.amenity-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: var(--gap-columns); }
.amenity-list li { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: var(--space-md); align-items: baseline; padding-block: var(--space-md); border-bottom: var(--rule-hair) solid var(--color-rule); }
.amenity-list b { font-weight: 800; }
.amenity-list span { color: var(--color-muted); }

/* ---------- Location: the map and the way out ---------- */
.location-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--gap-columns); align-items: start; }
.map svg { width: 100%; height: auto; background: var(--color-paper-3); }
.map figcaption strong { font-weight: 800; margin-right: var(--space-xs); }
.m-streets { fill: none; stroke: var(--color-ink); stroke-width: 1; opacity: 0.4; }
.m-bank { fill: none; stroke: var(--color-paper-2); stroke-width: 46; stroke-linecap: round; }
.m-river { fill: none; stroke: var(--color-accent); stroke-width: 30; stroke-linecap: round; }
.m-labels { font: 800 14px var(--font-display); fill: var(--color-ink); }
.m-park { fill: var(--color-paper-2); stroke: var(--color-ink); stroke-width: 2; }
.m-arrow { fill: none; stroke: var(--color-ink); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.m-pin { fill: var(--color-ink); }
.m-here { font: 800 18px var(--font-display); fill: var(--color-ink); paint-order: stroke; stroke: var(--color-paper-3); stroke-width: 5; }
.nearby { list-style: none; margin: 0; padding: var(--space-xs) var(--space-lg); }
.nearby li { display: flex; justify-content: space-between; gap: var(--space-md); align-items: baseline; padding-block: var(--space-md); }
.nearby li + li { border-top: var(--rule-hair) solid var(--color-ink-rule); }
.nearby li span:last-child { font-weight: 800; color: var(--color-accent-2); white-space: nowrap; }

/* ---------- Payments: the form, and the monthly as a sign ---------- */
.calc-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--gap-columns); align-items: start; }
.calc-form, .visit-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-md) var(--space-lg); }
.field { display: grid; gap: var(--space-2xs); align-content: start; }
.field.wide { grid-column: 1 / -1; }
.field label { font-size: var(--text-sm); }
.field small { font-size: var(--text-sm); color: var(--color-muted); }
.field input, .field select, .field textarea { width: 100%; min-height: 48px; padding: 0 var(--space-sm); border: var(--rule-bar) solid var(--color-ink); border-radius: 0; background: var(--color-paper-3); color: var(--color-ink); font: inherit; font-size: var(--text-md); }
.field textarea { min-height: 112px; padding-block: var(--space-sm); resize: vertical; }
.field input:hover, .field select:hover, .field textarea:hover { background: var(--color-paper); }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { outline: var(--rule-bar) solid var(--color-focus); outline-offset: 2px; }
.field input:disabled, .field select:disabled { cursor: not-allowed; opacity: 0.6; background: var(--color-paper-2); }
.results { padding: var(--space-lg); display: grid; gap: var(--space-lg); }
.result-big { display: grid; gap: var(--space-xs); }
.result-big span { font-size: var(--text-sm); color: var(--color-on-ink-muted); }
.result-big strong { font-weight: 800; font-size: var(--text-display-s); line-height: 1; color: var(--color-accent-2); letter-spacing: -0.03em; overflow-wrap: break-word; }
.result-rows { margin: 0; }
.result-rows div { display: flex; justify-content: space-between; gap: var(--space-md); padding-block: var(--space-sm); border-top: var(--rule-hair) solid var(--color-ink-rule); }
.result-rows dt { color: var(--color-on-ink-muted); font-size: var(--text-sm); }
.result-rows dd { margin: 0; font-weight: 800; text-align: right; }
.results .note { color: var(--color-on-ink-muted); }

/* ---------- Visit ---------- */
.visit-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--space-3xl); align-items: start; }
.visit-text { display: grid; gap: var(--space-lg); }
.visit-text .lead { color: var(--color-ink-2); }
.office { list-style: none; margin: 0; padding: 0; border-top: var(--rule-bar) solid var(--color-ink); }
.office li { display: grid; grid-template-columns: 9rem minmax(0, 1fr); gap: var(--space-md); padding-block: var(--space-sm); border-bottom: var(--rule-hair) solid var(--color-rule); }
.office small { font-size: var(--text-sm); color: var(--color-muted); }
.office strong, .office a { font-weight: 800; }
.office a:hover { color: var(--color-accent); }
.visit-form .btn { justify-self: start; }

/* ---------- Footer: the wordmark over the links ---------- */
.site-footer { border-top: var(--rule-bar) solid var(--color-ink); padding-block: var(--space-2xl) var(--space-xl); }
.foot-name { font-weight: 800; font-size: min(var(--text-display), 4.75rem); line-height: 0.98; letter-spacing: -0.03em; margin-bottom: var(--space-xl); overflow-wrap: break-word; }
.foot-grid { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 3fr) minmax(0, 3fr); gap: var(--gap-columns); padding-top: var(--space-lg); border-top: var(--rule-hair) solid var(--color-rule); }
.foot-head { font-size: var(--text-sm); font-weight: 500; letter-spacing: 0; color: var(--color-muted); margin-bottom: var(--space-xs); }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-2xs); }
.site-footer a { text-decoration: none; }
.site-footer a:hover { text-decoration: underline; color: var(--color-accent); }
.foot-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-xs) var(--space-lg); margin-top: var(--space-xl); font-size: var(--text-sm); color: var(--color-muted); }

/* ---------- Unit type page ---------- */
.unit-page { padding-bottom: var(--section-gap); }
.crumbs { display: flex; flex-wrap: wrap; gap: var(--space-xs); padding-block: var(--space-lg); font-size: var(--text-sm); color: var(--color-muted); }
.crumbs a { color: var(--color-muted); }
.crumbs a:hover { color: var(--color-accent); }
.unit-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--space-lg) var(--gap-columns); align-items: end; padding-bottom: var(--space-xl); margin-bottom: var(--space-xl); border-bottom: var(--rule-bar) solid var(--color-ink); }
.unit-head .sub { margin-top: var(--space-md); font-size: var(--text-lead); color: var(--color-ink-2); }
.unit-price { display: grid; gap: var(--space-2xs); padding: var(--space-md) var(--space-lg); min-width: 18rem; }
.unit-price small { font-size: var(--text-sm); color: var(--color-on-ink-muted); }
.unit-price strong { font-weight: 800; font-size: var(--text-display-s); line-height: 1; letter-spacing: -0.03em; color: var(--color-accent-2); }
.unit-price span { font-size: var(--text-sm); }

.gallery { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr); grid-template-rows: repeat(2, minmax(0, 1fr)); gap: var(--space-xs); height: clamp(320px, 42vw, 600px); }
.gallery .photo { position: relative; display: block; width: 100%; height: 100%; padding: 0; border: var(--rule-bar) solid var(--color-ink); background: var(--color-paper-2); cursor: zoom-in; overflow: hidden; }
.gallery .photo img { width: 100%; height: 100%; object-fit: cover; filter: saturate(0.88) contrast(1.1); }
.gallery .photo:hover { border-color: var(--color-accent); }
.gallery .photo:active { transform: translateY(1px); }
.gallery .photo:first-child { grid-row: span 2; }
.gallery .photo:only-child { grid-column: 1 / -1; }
.gallery .photo:nth-child(2):last-child { grid-column: span 2; grid-row: span 2; }
.gallery .photo:nth-child(2):nth-last-child(2), .gallery .photo:nth-child(3):last-child { grid-column: span 2; }
.gallery .photo:nth-child(4):last-child { grid-column: span 2; }
.gallery .more { position: absolute; right: var(--space-sm); bottom: var(--space-sm); padding: var(--space-xs) var(--space-sm); background: var(--color-ink); color: var(--color-on-ink); font-weight: 800; font-size: var(--text-sm); }

.plans-block { display: grid; grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); column-gap: var(--gap-columns); align-items: end; padding-block: var(--space-3xl) var(--space-xl); }
.plans-block > h2 { grid-column: 1 / -1; margin-bottom: var(--space-xl); }
.plans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-lg); }
.plans:has(> .plan-sheet + .plan-sheet) { grid-column: 1 / -1; }
.plans:has(> .plan-sheet:only-child) { grid-template-columns: minmax(0, 1fr); }
.plan-sheet { margin: 0; border: var(--rule-bar) solid var(--color-ink); background: var(--color-paper-3); }
.plan-open { display: block; width: 100%; padding: var(--space-lg); border: 0; background: none; cursor: zoom-in; }
.plan-open img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: contain; }
.plan-open:hover { background: var(--color-paper); }
.plan-open:active { transform: translateY(1px); }
.plan-sheet figcaption { padding: var(--space-xs) var(--space-sm); border-top: var(--rule-bar) solid var(--color-ink); font-weight: 800; font-size: var(--text-sm); }
.plans-block .note { margin-top: var(--space-md); }
.plans:has(> .plan-sheet:only-child) + .note { margin: 0; padding-bottom: var(--space-md); border-bottom: var(--rule-bar) solid var(--color-ink); }
.unit-page .units-table { min-width: 40rem; }

.unit-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--space-3xl); align-items: start; padding-top: var(--space-2xl); border-top: var(--rule-bar) solid var(--color-ink); }
.unit-copy h2 { font-size: var(--text-2xl); margin: var(--space-2xl) 0 var(--space-md); }
.unit-copy h2:first-child { margin-top: 0; }
.prose { display: grid; gap: var(--space-md); color: var(--color-ink-2); }
.features { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: var(--space-lg); }
.features li { padding-block: var(--space-sm); border-bottom: var(--rule-hair) solid var(--color-rule); }
.side { display: grid; gap: var(--space-lg); }
.side .visit-form { margin-top: var(--space-xl); padding-top: var(--space-xl); border-top: var(--rule-bar) solid var(--color-ink); }
.side .visit-form h2 { font-size: var(--text-2xl); }

/* ---------- Photo and floor plan viewer ---------- */
.viewer { width: 100%; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: var(--color-ink); color: var(--color-on-ink); }
.viewer::backdrop { background: var(--color-ink); }
.viewer[open] { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
.viewer-top { display: flex; align-items: center; justify-content: space-between; gap: var(--space-md); padding: var(--space-sm) var(--space-md); border-bottom: var(--rule-hair) solid var(--color-ink-rule); }
.viewer-title { font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.viewer-count { font-weight: 800; color: var(--color-accent-2); white-space: nowrap; }
.viewer-close { min-height: 44px; padding: 0 var(--space-md); border: var(--rule-bar) solid var(--color-on-ink); background: none; color: var(--color-on-ink); font: 800 var(--text-sm) var(--font-body); cursor: pointer; }
.viewer-close:hover { background: var(--color-on-ink); color: var(--color-ink); }
.viewer-close:active { transform: translateY(1px); }
.viewer :focus-visible { outline-color: var(--color-accent-2); }
.viewer-stage { position: relative; min-height: 0; }
.viewer-track { list-style: none; margin: 0; padding: 0; display: flex; height: 100%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.viewer-track::-webkit-scrollbar { display: none; }
.viewer-track li { flex: 0 0 100%; display: grid; grid-template: minmax(0, 1fr) / minmax(0, 1fr); scroll-snap-align: center; padding: var(--space-md); }
.viewer-track img { width: 100%; height: 100%; object-fit: contain; }
.viewer-floor-plans .viewer-track img { background: var(--color-paper-3); padding: var(--space-md); }
.viewer-nav { position: absolute; inset: 50% var(--space-md) auto; display: flex; justify-content: space-between; pointer-events: none; z-index: var(--z-raised); }
.viewer-nav button { pointer-events: auto; width: 52px; height: 52px; display: grid; place-items: center; border: var(--rule-bar) solid var(--color-on-ink); background: var(--color-ink); color: var(--color-on-ink); cursor: pointer; transform: translateY(-50%); }
.viewer-nav button:hover { background: var(--color-on-ink); color: var(--color-ink); }
.viewer-nav button:disabled { cursor: not-allowed; opacity: 0.35; background: var(--color-ink-2); color: var(--color-on-ink-muted); }
.viewer-nav svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2; }
.viewer-thumbs { display: flex; gap: var(--space-xs); overflow-x: auto; padding: var(--space-sm) var(--space-md); border-top: var(--rule-hair) solid var(--color-ink-rule); }
.viewer-thumbs button { flex: none; width: 72px; height: 52px; padding: 0; border: var(--rule-bar) solid transparent; background: var(--color-ink-2); cursor: pointer; }
.viewer-thumbs button[aria-current="true"] { border-color: var(--color-accent-2); }
.viewer-thumbs button:hover { border-color: var(--color-on-ink-muted); }
.viewer-thumbs img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- Narrow screens ---------- */
@media (max-width: 60rem) {
  .hero-grid, .location-grid, .calc-grid, .visit-grid, .unit-grid { grid-template-columns: minmax(0, 1fr); gap: var(--space-xl); }
  .hero-grid { min-height: 0; }
  .hero-visual { padding-bottom: 0; }
  .board { position: static; width: auto; box-shadow: none; border-top: 0; }
  .section-head { grid-template-columns: minmax(0, 1fr); }
  .type-row { grid-template-columns: minmax(0, 1fr); grid-template-rows: none; }
  .type-row > figure, .type-row > div { grid-column: 1; grid-row: auto; }
  .type-row > div:last-child { grid-template-columns: minmax(0, 1fr); align-items: start; }
  .photo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: 260px 200px 200px; }
  .photo-grid .frame:first-child { grid-column: 1 / -1; grid-row: auto; }
  .photo-grid .frame:nth-child(2) { grid-column: auto; }
  .photo-grid .frame:nth-child(4) { grid-column: 1 / -1; }
  .amenity-list, .features { grid-template-columns: minmax(0, 1fr); }
  .foot-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .foot-grid > p { grid-column: 1 / -1; }
  .unit-head { grid-template-columns: minmax(0, 1fr); }
  .plans-block, .plans, .plans:has(> .plan-sheet:only-child) { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 40rem) {
  .type-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .calc-form, .visit-form { grid-template-columns: minmax(0, 1fr); }
  .gallery { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-rows: 240px 120px; height: auto; }
  .gallery .photo:first-child { grid-column: 1 / -1; grid-row: auto; }
  .gallery .photo:nth-child(n + 4) { display: none; }
  .gallery .photo:nth-child(3) { display: block; }
  .unit-price { min-width: 0; }
  .office li { grid-template-columns: minmax(0, 1fr); gap: var(--space-2xs); }
  .filters select { min-width: 0; width: 100%; }
  .filters label { flex: 1 1 100%; }
}
