/* Joe Hoene Realty Team - design system
   Tokens first, then layout, components, page sections, motion. Light and dark themes share one set of names. */
@font-face { font-family: "Fraunces"; font-style: normal; font-weight: 400 700; font-display: swap; src: url("/fonts/fraunces-normal-latin.woff2") format("woff2"); }
@font-face { font-family: "Fraunces"; font-style: italic; font-weight: 400 600; font-display: swap; src: url("/fonts/fraunces-italic-latin.woff2") format("woff2"); }
@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 400 700; font-display: swap; src: url("/fonts/public-sans-latin.woff2") format("woff2"); }
.office-photo { margin: 0 0 18px; }
.office-photo img { display: block; width: 100%; height: auto; border-radius: var(--radius); border: 1px solid var(--line); }
.office-photo figcaption { margin-top: 8px; color: var(--ink-2); font-size: .9rem; }
:root {
  --paper: #f7f3ea; --paper-2: #efe8d8; --surface: #fffdf8; --ink: #15232b; --ink-2: #41525b; --line: #dcd3c0;
  --brick: #b5532f; --brick-2: #8f3d20; --sage: #4f7259; --gold: #d9a441; --sky: #cfe3e8;
  --ok: #2f7d4f; --warn: #a66a00; --bad: #b3261e;
  --shadow-1: 0 1px 2px rgb(21 35 43 / .06), 0 4px 14px rgb(21 35 43 / .06);
  --shadow-2: 0 10px 30px rgb(21 35 43 / .14), 0 2px 6px rgb(21 35 43 / .08);
  --radius: 14px; --radius-sm: 9px; --gutter: clamp(16px, 4vw, 40px); --max: 1180px;
  --font-display: "Fraunces", "Iowan Old Style", Georgia, serif;
  --font-body: "Public Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --ease: cubic-bezier(.2, .7, .2, 1);
  color-scheme: light;
}
:root[data-theme="dark"] {
  --paper: #0f181d; --paper-2: #142028; --surface: #18262e; --ink: #f1ece0; --ink-2: #a9b6bb; --line: #2a3b44;
  --brick: #e0805a; --brick-2: #f09a75; --sage: #86b394; --gold: #e6b85c; --sky: #1d313a;
  --shadow-1: 0 1px 2px rgb(0 0 0 / .3), 0 4px 14px rgb(0 0 0 / .25);
  --shadow-2: 0 14px 40px rgb(0 0 0 / .5);
  color-scheme: dark;
}
@view-transition { navigation: auto; }

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 1rem/1.65 var(--font-body); overflow-x: hidden; transition: background .4s var(--ease), color .4s var(--ease); }
img, svg, canvas { max-width: 100%; display: block; }
a { color: var(--brick); text-underline-offset: 3px; }
a:hover { color: var(--brick-2); }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 600; line-height: 1.12; letter-spacing: -.015em; margin: 0 0 .5em; text-wrap: balance; }
h1 { font-size: clamp(2.3rem, 5.4vw, 4.3rem); }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.6rem); }
h3 { font-size: 1.3rem; }
p { margin: 0 0 1em; text-wrap: pretty; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 4px; }
::selection { background: var(--gold); color: #15232b; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 200; background: var(--ink); color: var(--paper); padding: 10px 16px; border-radius: 8px; }
.skip-link:focus { top: 12px; color: var(--paper); }

/* Layout */
.container { width: min(var(--max), 100% - 2 * var(--gutter)); margin-inline: auto; }
.section { padding-block: clamp(56px, 9vw, 112px); position: relative; }
.section--alt { background: var(--paper-2); }
.section--ink { background: #15232b; color: #f1ece0; --ink: #f1ece0; --ink-2: #b9c4c8; --line: #2d404a; --surface: #1c2d36; }
.section__head { max-width: 720px; margin-bottom: clamp(28px, 4vw, 48px); }
.section__head--split { max-width: none; display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 16px 32px; }
.grid { display: grid; gap: clamp(16px, 2.4vw, 28px); }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 290px), 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); }
.split { display: grid; gap: clamp(24px, 5vw, 64px); grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr)); align-items: start; }
.stack > * + * { margin-top: 1rem; }
.eyebrow { font: 600 .78rem/1 var(--font-body); letter-spacing: .16em; text-transform: uppercase; color: var(--brick); display: inline-flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.eyebrow::before { content: ""; width: 28px; height: 2px; background: currentColor; }
.lead { font-size: clamp(1.05rem, 1.5vw, 1.22rem); color: var(--ink-2); }
.muted { color: var(--ink-2); }
.small { font-size: .875rem; }
.resource-groups { display: grid; gap: clamp(36px, 6vw, 72px); }
.resource-group h2 { margin-bottom: 20px; }
.resource-card { display: flex; flex-direction: column; }
.resource-card .resource-link { margin-top: auto; font-weight: 700; }
.local-toolbar { display: grid; grid-template-columns: 1fr minmax(260px, 420px); align-items: end; gap: 24px; margin-bottom: 40px; }
.distance-note { color: var(--sage); font-size: .8rem; font-weight: 700; margin: 9px 0 0; }
@media (max-width: 700px) { .local-toolbar { grid-template-columns: 1fr; } }
.center { text-align: center; margin-inline: auto; }

/* Buttons */
.btn { --bg: var(--ink); --fg: var(--paper); display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 13px 22px; border-radius: 999px; border: 1.5px solid var(--bg); background: var(--bg); color: var(--fg); font: 600 .95rem/1 var(--font-body); text-decoration: none; cursor: pointer; transition: transform .25s var(--ease), box-shadow .25s var(--ease), background .2s, color .2s; position: relative; overflow: hidden; }
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-2); color: var(--fg); }
.btn:active { transform: translateY(0); }
.btn--primary { --bg: var(--brick); --fg: #fff; }
:root[data-theme="dark"] .btn--primary { --fg: #15232b; }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--ghost:hover { color: var(--ink); border-color: var(--ink); }
.btn--light { --bg: #f7f3ea; --fg: #15232b; }
.btn--sm { padding: 9px 15px; font-size: .85rem; }
.btn[disabled] { opacity: .6; cursor: progress; transform: none; }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 100; background: color-mix(in srgb, var(--paper) 86%, transparent); backdrop-filter: blur(14px) saturate(1.4); border-bottom: 1px solid transparent; transition: border-color .3s, box-shadow .3s; }
.site-header.is-scrolled { border-color: var(--line); box-shadow: var(--shadow-1); }
.site-header__bar { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 10px 28px; min-height: 122px; padding-block: 10px; }
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.brand__mark { width: 42px; height: 42px; flex: none; }
.brand__name { font: 600 1.15rem/1.05 var(--font-display); letter-spacing: -.01em; }
.brand__name small { display: block; font: 600 .62rem/1 var(--font-body); letter-spacing: .2em; text-transform: uppercase; color: var(--brick); margin-top: 5px; }
.nav { display: grid; align-self: stretch; align-content: center; gap: 7px; min-width: 0; }
.nav__primary, .nav__secondary, .nav__tertiary { display:flex; align-items:center; justify-content:center; gap:4px; min-width:0; flex-wrap:wrap; }
.nav__primary { border-bottom:1px solid color-mix(in srgb,var(--line) 75%,transparent); }
.nav__secondary { padding-block:2px; }
.nav__tertiary { gap:1px; padding-top:2px; border-top:1px solid color-mix(in srgb,var(--line) 75%,transparent); }
.nav__link { flex: none; padding: 9px 15px; border-radius: 999px; color: var(--ink); text-decoration: none; font-weight: 600; font-size: .94rem; position: relative; white-space: nowrap; }
.nav__secondary .nav__link { padding:5px 11px; font-size:.84rem; color:var(--ink-2); }
.nav__link--tertiary { padding:4px 7px; color:var(--ink-2); font-size:.7rem; font-weight:600; letter-spacing:.02em; }
.nav__count { display: inline-grid; min-width: 18px; height: 18px; margin-left: 3px; padding-inline: 5px; place-items: center; border-radius: 999px; background: var(--brick); color: #fff; font-size: .68rem; line-height: 1; }
.nav__link::after { content: ""; position: absolute; left: 14px; right: 14px; bottom: 5px; height: 2px; background: var(--brick); transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease); }
.nav__secondary .nav__link::after,.nav__link--tertiary::after { left:8px; right:8px; bottom:1px; height:1.5px; }
.nav__link:hover::after, .nav__link[aria-current="page"]::after { transform: scaleX(1); }
.nav__link:hover { color: var(--ink); }
.header-actions { display: flex; align-items: center; gap: 8px; }
.icon-btn { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; transition: transform .3s var(--ease), border-color .2s; }
.icon-btn:hover { transform: rotate(18deg); border-color: var(--ink); }
.icon-btn svg { width: 19px; height: 19px; }
.theme-toggle .moon, :root[data-theme="dark"] .theme-toggle .sun { display: none; }
:root[data-theme="dark"] .theme-toggle .moon { display: block; }
.nav-toggle { display: none; }
@media (max-width: 1240px) {
  .site-header__bar { display: flex; min-height: 72px; padding-block: 0; }
  .nav-toggle { display: grid; }
  .nav { position: fixed; inset: 72px 0 auto 0; height: calc(100dvh - 72px); max-height: calc(100dvh - 72px); overflow-y: auto; overscroll-behavior: contain; scrollbar-width: none; -ms-overflow-style: none; flex-direction: column; align-items: stretch; gap: 0; padding: 12px var(--gutter) calc(24px + env(safe-area-inset-bottom)); background: var(--paper); border-bottom: 1px solid var(--line); box-shadow: var(--shadow-2); transform: translateY(-12px); opacity: 0; pointer-events: none; transition: transform .3s var(--ease), opacity .2s; }
  .nav::-webkit-scrollbar { display: none; }
  .nav__primary, .nav__secondary, .nav__tertiary { display: flex; flex-direction: column; align-items: stretch; gap: 0; }
  .nav__secondary, .nav__tertiary { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--line); }
  .nav.is-open { transform: none; opacity: 1; pointer-events: auto; }
  .nav__link { padding: 14px 8px; border-bottom: 1px solid var(--line); border-radius: 0; font-size: 1.05rem; }
  .nav__secondary .nav__link { padding:11px 8px; color:var(--ink-2); font-size:.95rem; }
  .nav__link--tertiary { padding:10px 8px; color:var(--ink-2); font-size:.88rem; }
  .nav__link::after { display: none; }
  .header-call span { display: none; }
  .header-call { padding: 12px; }
  body.nav-open { overflow: hidden; }
}
@media (max-width: 520px) {
  .brand { gap: 8px; }
  .brand__mark { width: 38px; height: 38px; }
  .brand__name { font-size: 1rem; }
  .header-actions { gap: 5px; }
  .icon-btn { width: 44px; height: 44px; }
  .nav__link { min-height: 48px; display: flex; align-items: center; }
  .nav__link--secondary { min-height: 44px; }
  .btn--sm, .chip { min-height: 44px; }
  .compare-tray { bottom: calc(78px + env(safe-area-inset-bottom)); width: calc(100vw - 32px); max-width: none; justify-content: space-between; gap: 8px; padding: 10px 12px; border-radius: 16px; }
  .compare-tray .btn { min-height: 42px; padding-inline: 14px; }
  .chat-launcher { right: max(12px, env(safe-area-inset-right)); bottom: max(12px, env(safe-area-inset-bottom)); min-width: 48px; min-height: 48px; padding: 13px 15px; }
  .chat-launcher span { display: none; }
  .chat-panel { right: 12px; bottom: max(12px, env(safe-area-inset-bottom)); width: calc(100vw - 24px); height: min(680px, calc(100dvh - 24px - env(safe-area-inset-bottom))); }
  dialog.modal { width: calc(100vw - 20px); max-height: calc(100dvh - 20px); }
  .modal__head, .modal__body { padding-inline: 14px; }
  .table th, .table td { padding: 10px 12px; }
}

/* Local guide and planning desk */
.listing-feedback { margin-top: 36px; padding: clamp(20px, 3vw, 30px); border: 1px solid var(--line); border-radius: 18px; background: var(--paper); }
.listing-feedback h2 { font-size: 1.3rem; }
.listing-social { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.listing-social a { padding: 7px 11px; border: 1px solid var(--line); border-radius: 999px; font-size: .82rem; font-weight: 700; }
.agent-hero { display: grid; grid-template-columns: minmax(150px, 250px) minmax(0, 1fr); gap: clamp(24px, 5vw, 56px); align-items: center; }
.agent-hero img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 22px; box-shadow: var(--shadow-2); }
.construction-record { margin-top: 28px; padding: clamp(20px, 3vw, 30px); border: 1px solid var(--line); border-radius: 18px; background: var(--surface); }
.construction-record__head { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; margin-bottom: 16px; }
.construction-record h2 { margin: 0; font-size: 1.3rem; }
.construction-record__head span { color: var(--ink-2); font-size: .75rem; font-weight: 700; text-align: right; }
.construction-record dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 0; }
.construction-record dl > div { padding: 15px; border-radius: 12px; background: var(--paper); }
.construction-record dt { color: var(--brick); font-size: .76rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.construction-record dd { margin: 7px 0 0; line-height: 1.5; }
.construction-record > p { margin: 16px 0 0; }
.why-proof { margin-top: 24px; padding: clamp(22px, 3vw, 32px); display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 22px; align-items: center; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); }
.why-proof strong { display: block; margin-top: 5px; font: 700 clamp(1.35rem, 2vw, 1.7rem) var(--font-display); color: var(--ink); }
.why-proof p { margin: 7px 0 0; color: var(--ink-2); }
.why-proof__actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: flex-end; }
.community-picker, .updates-filters { display: flex; flex-wrap: wrap; gap: 9px; }
.community-picker { margin: 26px 0 18px; }
.community-chip, .update-filter, .save-brief, .text-button { border: 1px solid var(--line); background: var(--surface); color: var(--ink); border-radius: 999px; padding: 9px 14px; font: 600 .86rem var(--font-body); cursor: pointer; }
.community-chip.is-active, .update-filter.is-active, .save-brief[aria-pressed="true"] { background: var(--brick); border-color: var(--brick); color: #fff; }
.community-spotlight { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 28px; padding: clamp(24px, 4vw, 42px); border: 1px solid var(--line); border-radius: 20px; background: linear-gradient(120deg, color-mix(in srgb, var(--gold) 14%, var(--surface)), var(--surface)); }
.community-spotlight h3 { max-width: 38ch; margin: 5px 0 10px; font-size: clamp(1.3rem, 2.5vw, 1.8rem); }
.community-spotlight ul, .update-card ul { margin: 12px 0 0; padding-left: 20px; display: grid; gap: 7px; }
.community-spotlight__actions { display: grid; gap: 10px; min-width: 175px; }
.planner-progress > div:first-child { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.text-button { padding: 5px 9px; color: var(--brick); background: transparent; }
.planner-track { height: 9px; border-radius: 999px; background: var(--line); overflow: hidden; margin: 10px 0 18px; }
.planner-track i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--brick), var(--gold)); transition: width .25s var(--ease); }
.move-planner { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; }
.move-planner label { display: flex; align-items: flex-start; gap: 11px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); cursor: pointer; }
.move-planner input { width: 19px; height: 19px; accent-color: var(--brick); flex: none; margin-top: 1px; }
.visit-card { align-self: start; }
.updates-toolbar { display: grid; grid-template-columns: minmax(220px, .8fr) 1.2fr; gap: 16px; align-items: center; margin: 28px 0 16px; }
.updates-search input { width: 100%; min-height: 45px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink); padding: 10px 14px; font: inherit; }
.updates-result { color: var(--ink-2); font-size: .9rem; margin: 0 0 14px; }
.updates-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.update-card { border: 1px solid var(--line); border-radius: 18px; background: var(--surface); padding: 24px; display: flex; flex-direction: column; align-items: flex-start; }
.update-card__top { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.brief-tag { text-transform: capitalize; color: var(--brick); font-size: .75rem; font-weight: 800; letter-spacing: .08em; }
.save-brief { padding: 6px 11px; font-size: .78rem; }
.update-card h3 { margin: 16px 0 8px; }
.update-card p { margin: 0; }
.update-card h4 { margin: 19px 0 0; font-size: .88rem; }
.text-link { margin-top: 20px; color: var(--brick); font-weight: 700; }
.saved-updates { display: grid; gap: 9px; margin-top: 18px; }
.saved-update { display: flex; justify-content: space-between; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); font-weight: 600; }
@media (max-width: 720px) { .community-spotlight, .updates-toolbar, .updates-grid, .why-proof, .construction-record dl, .agent-hero { grid-template-columns: 1fr; } .agent-hero img { max-width: 220px; } .community-spotlight__actions { grid-template-columns: 1fr 1fr; min-width: 0; } .why-proof__actions { justify-content: flex-start; } }
@media (max-width: 420px) { .community-picker, .updates-filters { gap: 7px; } .community-chip, .update-filter { padding: 8px 10px; font-size: .8rem; } .community-spotlight__actions { grid-template-columns: 1fr; } }

/* Hero */
.hero { position: relative; min-height: min(92vh, 860px); display: grid; align-items: center; overflow: hidden; isolation: isolate; color: #fdf8ec; background: linear-gradient(180deg, #1b3340 0%, #2f5361 38%, #d98a55 78%, #f0c27b 100%); }
:root[data-theme="dark"] .hero { background: linear-gradient(180deg, #070d12 0%, #12242f 45%, #3a3246 80%, #7a4a3c 100%); }
.hero__scene, .hero__canvas, .hero__photo { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; }
.hero__photo { object-fit: cover; }
.hero__photo + .hero__scene { display: none; }
.hero__scene svg { position: absolute; left: -4%; bottom: -2%; width: 108%; height: auto; min-height: 62%; will-change: transform; }
.hero__shade { position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgb(12 24 31 / .72) 0%, rgb(12 24 31 / .35) 55%, transparent 100%); }
.hero__inner { padding-block: 110px 150px; max-width: 760px; }
.hero h1 { color: #fffaf0; text-shadow: 0 2px 30px rgb(0 0 0 / .35); }
.hero h1 em { font-style: italic; font-weight: 400; color: var(--gold); }
.hero .lead { color: #efe6d2; max-width: 56ch; }
.hero .eyebrow { color: #f3c98a; }
.hero__search { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 8px; padding: 8px; border-radius: 22px; background: rgb(255 253 248 / .14); border: 1px solid rgb(255 255 255 / .28); backdrop-filter: blur(16px); max-width: 640px; }
.hero__search select, .hero__search input { flex: 1 1 150px; min-width: 0; padding: 13px 16px; border-radius: 14px; border: 0; background: rgb(255 253 248 / .95); color: #15232b; font: 500 .95rem var(--font-body); }
.hero__scroll { position: absolute; left: 50%; bottom: 26px; translate: -50% 0; width: 26px; height: 42px; border: 2px solid rgb(255 255 255 / .6); border-radius: 14px; }
.hero__scroll::after { content: ""; position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: #fff; animation: scrollcue 1.8s infinite; }
@keyframes scrollcue { 0% { transform: translateY(0); opacity: 1; } 100% { transform: translateY(14px); opacity: 0; } }
.page-hero { padding-block: clamp(56px, 8vw, 104px) clamp(32px, 5vw, 56px); background: radial-gradient(1200px 400px at 80% -10%, color-mix(in srgb, var(--gold) 28%, transparent), transparent 70%), var(--paper-2); border-bottom: 1px solid var(--line); }
.page-hero h1 { font-size: clamp(2.1rem, 4.6vw, 3.4rem); max-width: 18ch; }
.page-hero .lead { max-width: 62ch; }

/* Marquee */
.marquee { overflow: hidden; border-block: 1px solid var(--line); background: var(--surface); padding-block: 16px; mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); }
.marquee__track { display: flex; gap: 48px; width: max-content; animation: marquee 38s linear infinite; font: 500 1.1rem var(--font-display); color: var(--ink-2); white-space: nowrap; }
.marquee__track span::after { content: "✦"; margin-left: 48px; color: var(--brick); font-size: .8em; }
.marquee:hover .marquee__track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* Cards */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(20px, 2.6vw, 30px); box-shadow: var(--shadow-1); transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .2s; }
.card--hover:hover { transform: translateY(-5px); box-shadow: var(--shadow-2); border-color: color-mix(in srgb, var(--brick) 40%, var(--line)); }
.card__icon { width: 50px; height: 50px; border-radius: 14px; display: grid; place-items: center; background: color-mix(in srgb, var(--brick) 13%, transparent); color: var(--brick); margin-bottom: 16px; }
.card__icon svg { width: 25px; height: 25px; }
.card h3 { margin-bottom: .35em; }
.card p:last-child { margin-bottom: 0; }
.tilt { transform-style: preserve-3d; will-change: transform; }

.listing-card { display: flex; flex-direction: column; padding: 0; overflow: hidden; color: inherit; text-decoration: none; position: relative; }
.listing-card__media { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: var(--sky); }
.listing-card__media img, .listing-card__media svg { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.listing-card:hover .listing-card__media img, .listing-card:hover .listing-card__media svg { transform: scale(1.06); }
.listing-card__badges { position: absolute; left: 12px; top: 12px; display: flex; flex-wrap: wrap; gap: 6px; z-index: 2; }
.badge { padding: 5px 10px; border-radius: 999px; font: 700 .68rem/1 var(--font-body); letter-spacing: .08em; text-transform: uppercase; background: #15232b; color: #fdf8ec; }
.badge--active { background: var(--ok); color: #fff; }
.badge--pending { background: var(--warn); color: #fff; }
.badge--sold { background: #15232b; color: #f0c27b; }
.badge--unverified { background: var(--warn); color: #fff; } /* active listing whose source falls short of the MIBOR office page; see server/routes/listings.js can_show_as_active */
.badge--new { background: var(--gold); color: #15232b; }
.fav-btn { position: absolute; right: 12px; top: 12px; z-index: 3; width: 38px; height: 38px; border-radius: 50%; border: 0; display: grid; place-items: center; background: rgb(255 253 248 / .92); color: #15232b; cursor: pointer; transition: transform .25s var(--ease); }
.fav-btn:hover { transform: scale(1.12); }
.fav-btn svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 2; }
.fav-btn[aria-pressed="true"] { color: #c62f3d; }
.fav-btn[aria-pressed="true"] svg { fill: currentColor; animation: pop .35s var(--ease); }
@keyframes pop { 50% { transform: scale(1.35); } }
.listing-card__body { padding: 18px 20px 20px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.listing-card__price { font: 600 1.5rem/1.1 var(--font-display); }
.listing-card__addr { font-weight: 600; }
.listing-card__city { color: var(--ink-2); font-size: .92rem; }
.facts { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 8px 0 0; padding: 12px 0 0; list-style: none; border-top: 1px solid var(--line); font-size: .9rem; color: var(--ink-2); }
.facts strong { color: var(--ink); font-weight: 600; }
.photo-note { position: absolute; right: 10px; bottom: 10px; z-index: 2; font-size: .68rem; padding: 4px 8px; border-radius: 6px; background: rgb(21 35 43 / .7); color: #fdf8ec; }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 24px; }
.stat__num { font: 600 clamp(2.2rem, 4.5vw, 3.4rem)/1 var(--font-display); color: var(--gold); font-variant-numeric: tabular-nums; }
.stat__label { color: var(--ink-2); font-size: .92rem; margin-top: 8px; }

/* Steps */
.steps { counter-reset: step; display: grid; gap: 18px; padding: 0; margin: 0; list-style: none; }
.steps li { counter-increment: step; position: relative; padding: 20px 20px 20px 76px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.steps li::before { content: counter(step, decimal-leading-zero); position: absolute; left: 20px; top: 18px; font: 600 1.7rem/1 var(--font-display); color: var(--brick); }
.steps h3 { font-size: 1.1rem; margin-bottom: .2em; }
.steps p { margin: 0; color: var(--ink-2); font-size: .95rem; }

/* Tabs */
.tabs__list { display: flex; gap: 6px; padding: 6px; border-radius: 999px; background: var(--paper-2); border: 1px solid var(--line); width: fit-content; max-width: 100%; overflow-x: auto; scrollbar-width: none; position: relative; }
.section--alt .tabs__list { background: var(--surface); }
.tabs__tab { position: relative; z-index: 1; padding: 11px 20px; border: 0; border-radius: 999px; background: transparent; color: var(--ink-2); font: 600 .93rem var(--font-body); cursor: pointer; white-space: nowrap; transition: color .25s; }
.tabs__tab[aria-selected="true"] { color: var(--paper); }
.tabs__glider { position: absolute; z-index: 0; top: 6px; bottom: 6px; left: 0; width: 0; border-radius: 999px; background: var(--ink); transition: transform .4s var(--ease), width .4s var(--ease); }
.tabs__panel { padding-top: clamp(24px, 4vw, 44px); animation: panel-in .5s var(--ease); }
.tabs__panel[hidden] { display: none; }
@keyframes panel-in { from { opacity: 0; transform: translateY(14px); } }

/* Forms */
.form { display: grid; gap: 16px; }
.form__row { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); }
.field { display: grid; gap: 6px; }
.field__label { font-weight: 600; font-size: .88rem; }
.field__label .opt { font-weight: 400; color: var(--ink-2); }
.field__input { width: 100%; padding: 13px 15px; border-radius: var(--radius-sm); border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); font: 400 1rem var(--font-body); transition: border-color .2s, box-shadow .2s; }
.field__input:focus { outline: 0; border-color: var(--brick); box-shadow: 0 0 0 4px color-mix(in srgb, var(--brick) 18%, transparent); }
textarea.field__input { min-height: 120px; resize: vertical; }
.field__error { color: var(--bad); font-size: .84rem; min-height: 0; }
.field.is-invalid .field__input { border-color: var(--bad); }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: .86rem; color: var(--ink-2); }
.check input { width: 18px; height: 18px; margin-top: 3px; accent-color: var(--brick); flex: none; }
.hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.form__status { padding: 14px 16px; border-radius: var(--radius-sm); font-weight: 500; display: none; }
.form__status.is-ok { display: block; background: color-mix(in srgb, var(--ok) 14%, transparent); color: var(--ok); }
.form__status.is-bad { display: block; background: color-mix(in srgb, var(--bad) 12%, transparent); color: var(--bad); }

/* Filters */
.filters { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); padding: 18px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-1); }
.filters .field__input { padding: 11px 13px; font-size: .93rem; }
.result-bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; margin: 22px 0; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { padding: 8px 14px; border-radius: 999px; border: 1.5px solid var(--line); background: transparent; color: var(--ink); font: 600 .84rem var(--font-body); cursor: pointer; transition: all .2s; }
.chip:hover { border-color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.empty { text-align: center; padding: 56px 20px; border: 2px dashed var(--line); border-radius: var(--radius); color: var(--ink-2); }

/* Compare tray */
.compare-tray { position: fixed; left: 50%; bottom: 18px; translate: -50% 140%; z-index: 90; display: flex; align-items: center; gap: 14px; padding: 12px 14px 12px 20px; border-radius: 999px; background: #15232b; color: #fdf8ec; box-shadow: var(--shadow-2); transition: translate .45s var(--ease); max-width: calc(100vw - 110px); }
.compare-tray.is-open { translate: -50% 0; }
dialog.modal { border: 0; border-radius: var(--radius); padding: 0; background: var(--surface); color: var(--ink); width: min(960px, calc(100vw - 32px)); box-shadow: var(--shadow-2); }
dialog.modal::backdrop { background: rgb(10 18 23 / .6); backdrop-filter: blur(4px); }
.modal__head { display: flex; justify-content: space-between; align-items: center; padding: 18px 22px; border-bottom: 1px solid var(--line); }
.modal__head h2 { font-size: 1.4rem; margin: 0; }
.modal__body { padding: 22px; overflow: auto; max-height: 72vh; }

/* Tables */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th, .table td { padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.table th { font: 600 .74rem var(--font-body); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); background: var(--paper-2); white-space: nowrap; }
.table tr:last-child td { border-bottom: 0; }

/* Listing detail */
.gallery { display: grid; gap: 8px; grid-template-columns: 2fr 1fr 1fr; grid-template-rows: repeat(2, minmax(0, 1fr)); height: clamp(260px, 46vw, 520px); border-radius: var(--radius); overflow: hidden; }
.gallery__item { position: relative; border: 0; padding: 0; background: var(--sky); cursor: zoom-in; overflow: hidden; }
.gallery__item:first-child { grid-row: span 2; }
.gallery__item img, .gallery__item svg { width: 100%; height: 100%; object-fit: cover; transition: transform .7s var(--ease); }
.gallery__item:hover img { transform: scale(1.05); }
.gallery__more { position: absolute; inset: 0; display: grid; place-items: center; background: rgb(21 35 43 / .6); color: #fff; font: 600 1.1rem var(--font-display); }
.gallery--single { grid-template-columns: 1fr; grid-template-rows: 1fr; }
@media (max-width: 700px) { .gallery { grid-template-columns: 1fr 1fr; height: auto; grid-template-rows: auto; } .gallery__item { aspect-ratio: 4/3; } .gallery__item:first-child { grid-column: span 2; grid-row: auto; } .gallery__item:nth-child(n+4) { display: none; } }
.lightbox { position: fixed; inset: 0; z-index: 300; background: rgb(8 14 18 / .95); display: none; grid-template-rows: auto 1fr auto; color: #fff; }
.lightbox.is-open { display: grid; }
.lightbox__bar { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; }
.lightbox__stage { display: grid; place-items: center; min-height: 0; padding: 0 56px; }
.lightbox__stage img { max-height: 100%; max-width: 100%; object-fit: contain; border-radius: 6px; }
.lightbox__nav { position: absolute; top: 50%; translate: 0 -50%; }
.lightbox__nav--prev { left: 10px; } .lightbox__nav--next { right: 10px; }
.lightbox .icon-btn { background: rgb(255 255 255 / .12); border-color: transparent; color: #fff; }
.detail-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px 32px; align-items: end; margin: 28px 0; }
.detail-price { font: 600 clamp(2rem, 4vw, 3rem)/1 var(--font-display); }
.fact-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.fact-grid div { background: var(--surface); padding: 16px 18px; }
.fact-grid dt { font-size: .74rem; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); }
.fact-grid dd { margin: 4px 0 0; font: 600 1.2rem var(--font-display); }
.feature-list { columns: 2 220px; padding-left: 1.1em; }
.feature-list li { margin-bottom: 6px; break-inside: avoid; }
.nearby-places { margin-top: 32px; padding: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper-2); }
.nearby-places h2 { font-size: 1.3rem; margin-bottom: 6px; }
.nearby-places ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 16px 0 0; padding: 0; list-style: none; }
.nearby-places li { display: grid; gap: 1px; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface); font-size: .86rem; }
.nearby-places li span { color: var(--ink-2); }
@media (max-width: 520px) { .nearby-places ul { grid-template-columns: 1fr; } }
.sticky-card { position: sticky; top: 96px; }
.notice { padding: 14px 16px; border-radius: var(--radius-sm); border-left: 4px solid var(--gold); background: color-mix(in srgb, var(--gold) 14%, transparent); font-size: .9rem; }
.home-workspace { display:grid; grid-template-columns:minmax(0,.92fr) minmax(0,1.08fr); gap:clamp(20px,3vw,34px); align-items:start; }
.home-workspace__brief h3 { font-size:clamp(1.3rem,2vw,1.8rem); margin:.28rem 0 .65rem; }
.home-workspace__facts { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:10px; margin:18px 0; }
.home-workspace__fact { padding:11px; border:1px solid var(--line); border-radius:var(--radius-sm); background:color-mix(in srgb,var(--surface) 86%,var(--sage) 14%); }
.home-workspace__fact strong,.home-workspace__fact span { display:block; }
.home-workspace__fact span { color:var(--ink-2); font-size:.78rem; margin-top:3px; }
.server-status { display:inline-flex; align-items:center; gap:6px; color:var(--ink-2); font-size:.77rem; font-weight:700; white-space:nowrap; text-decoration:none; }
.server-status i,[data-server-status] i { width:8px; height:8px; border-radius:50%; background:var(--gold); box-shadow:0 0 0 3px color-mix(in srgb,var(--gold) 19%,transparent); flex:0 0 auto; }
.server-status.is-online i,[data-server-status].is-online i { background:#25885b; box-shadow:0 0 0 3px color-mix(in srgb,#25885b 19%,transparent); }
.server-status.is-offline i,[data-server-status].is-offline i { background:var(--brick); box-shadow:0 0 0 3px color-mix(in srgb,var(--brick) 19%,transparent); }
.footer-privacy { max-width:82ch; line-height:1.55; }
.market-perspective { margin-top:34px; padding:clamp(20px,3vw,30px); border:1px solid var(--line); border-radius:var(--radius); background:color-mix(in srgb,var(--sage) 10%,var(--surface)); }
.market-perspective h2 { margin:.25rem 0 .65rem; font-size:clamp(1.35rem,2vw,1.75rem); }
.market-perspective__stats { display:flex; flex-wrap:wrap; gap:1px; margin:18px 0; border:1px solid var(--line); border-radius:var(--radius-sm); overflow:hidden; background:var(--line); }
.market-perspective__stats div { flex:1 1 145px; padding:12px; background:var(--surface); }.market-perspective__stats strong,.market-perspective__stats span { display:block; }.market-perspective__stats span { font-size:.78rem;color:var(--ink-2); }
.market-perspective__chart { margin:14px 0; background:var(--surface); border:1px solid var(--line); border-radius:var(--radius-sm); padding:8px; }.market-perspective__chart svg { width:100%; height:auto; color:var(--ink-2); font:11px var(--font-body); }.market-perspective__legend { display:flex; flex-wrap:wrap; gap:8px 14px; font-size:.82rem; }.market-perspective__legend span { display:flex; align-items:center; gap:5px; }.market-perspective__legend i { width:10px; height:10px; border-radius:50%; }
.status-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:18px; margin-bottom:24px; }
.status-card h2 { font-size:clamp(1.25rem,2vw,1.7rem); margin:.35rem 0 .5rem; }

/* Team */
.agent { display: grid; grid-template-columns: 96px 1fr; gap: 20px; align-items: start; }
.agent__avatar { width: 96px; height: 96px; border-radius: 50%; display: grid; place-items: center; font: 600 2rem var(--font-display); color: #fdf8ec; background: linear-gradient(135deg, var(--brick), #15232b); object-fit: cover; }
.agent__profile { margin-top: 14px; border-top: 1px solid var(--line); padding-top: 12px; }
.agent__profile summary { cursor: pointer; color: var(--ink); font-weight: 700; }
.agent__profile-body { margin-top: 12px; }
.agent__metrics { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.agent__metric { display: grid; gap: 3px; padding: 10px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--paper-2); font-size: .82rem; }
.agent__metric span { color: var(--ink-2); }
.agent__transactions { display: grid; gap: 6px; margin: 8px 0 0; padding: 0; list-style: none; }
.agent__transactions li { display: grid; gap: 2px; padding: 8px 10px; border-left: 3px solid var(--gold); background: var(--paper-2); font-size: .84rem; }
.agent__transactions span, .agent__transactions small { color: var(--ink-2); }
@media (max-width: 520px) { .agent__metrics { grid-template-columns: 1fr; } }
.tag-row { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0; padding: 0; list-style: none; }
.tag-row li { padding: 5px 11px; border-radius: 999px; background: var(--paper-2); border: 1px solid var(--line); font-size: .8rem; }
@media (max-width: 520px) { .agent { grid-template-columns: 1fr; } }

/* Calculators */
.calc { display: grid; gap: clamp(20px, 4vw, 48px); grid-template-columns: repeat(auto-fit, minmax(min(100%, 330px), 1fr)); align-items: start; }
.range { width: 100%; accent-color: var(--brick); }
.calc__result { position: sticky; top: 96px; }
.big-number { font: 600 clamp(2.4rem, 5vw, 3.6rem)/1 var(--font-display); color: var(--brick); font-variant-numeric: tabular-nums; }
.breakdown { display: grid; gap: 8px; margin: 18px 0 0; padding: 0; list-style: none; }
.breakdown li { display: flex; justify-content: space-between; gap: 12px; padding-bottom: 8px; border-bottom: 1px dashed var(--line); font-size: .94rem; }
.breakdown li span:first-child { display: inline-flex; align-items: center; gap: 8px; }
.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }

/* Footer */
.site-footer { background: #10191e; color: #c4cdd0; padding-block: 64px 28px; font-size: .93rem; }
.site-footer a { color: #f1ece0; text-decoration: none; }
.site-footer a:hover { color: var(--gold); }
.site-footer .footer-heading { color: #fff; font: 600 .8rem var(--font-body); letter-spacing: .14em; text-transform: uppercase; margin-bottom: 14px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.footer-grid { display: grid; gap: 36px; grid-template-columns: 1.6fr repeat(4, 1fr); }
@media (max-width: 820px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-legal { margin-top: 44px; padding-top: 22px; border-top: 1px solid #25343c; display: grid; gap: 10px; font-size: .8rem; color: #aeb8bc; }
.footer-credit a { text-decoration: underline; text-underline-offset: 2px; }
.eho { display: flex; gap: 12px; align-items: center; }
.eho svg { width: 40px; height: 40px; flex: none; color: #c4cdd0; }
.footer-credit { opacity: .75; }

/* Chat */
.chat-launcher { position: fixed; right: 18px; bottom: 18px; z-index: 120; display: inline-flex; align-items: center; gap: 10px; padding: 14px 20px 14px 16px; border: 0; border-radius: 999px; background: var(--brick); color: #fff; font: 600 .95rem var(--font-body); box-shadow: var(--shadow-2); cursor: pointer; transition: transform .3s var(--ease); }
:root[data-theme="dark"] .chat-launcher { color: #15232b; }
.chat-launcher:hover { transform: translateY(-3px) scale(1.03); }
.chat-launcher svg { width: 22px; height: 22px; }
.chat-launcher::before { content: ""; position: absolute; inset: 0; border-radius: inherit; border: 2px solid var(--brick); animation: ping 2.6s infinite; }
@keyframes ping { 0% { transform: scale(1); opacity: .7; } 70%, 100% { transform: scale(1.35, 1.7); opacity: 0; } }
.chat-panel { position: fixed; right: 18px; bottom: 18px; z-index: 130; width: min(400px, calc(100vw - 24px)); height: min(620px, calc(100dvh - 36px)); display: grid; grid-template-rows: auto 1fr auto; border-radius: 20px; overflow: hidden; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-2); transform-origin: bottom right; transition: transform .35s var(--ease), opacity .25s; }
.chat-panel[hidden] { display: grid; transform: scale(.6) translateY(40px); opacity: 0; pointer-events: none; visibility: hidden; }
.chat-head { display: flex; align-items: center; gap: 12px; padding: 14px 16px; background: #15232b; color: #fdf8ec; }
.chat-head__avatar { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--brick); color: #fff; flex: none; }
.chat-head__title { font: 600 1rem var(--font-display); line-height: 1.2; }
.chat-head__sub { font-size: .74rem; color: #b9c4c8; display: flex; align-items: center; gap: 6px; }
.chat-head__sub i { width: 7px; height: 7px; border-radius: 50%; background: #9aa; }
.chat-head__sub i.is-on { background: #55d38a; box-shadow: 0 0 0 3px rgb(85 211 138 / .25); }
.chat-head .icon-btn { margin-left: auto; width: 34px; height: 34px; background: transparent; border-color: #38505c; color: #fdf8ec; }
.chat-log { overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 10px; scroll-behavior: smooth; background: var(--paper); }
.chat-msg { max-width: 86%; padding: 10px 14px; border-radius: 16px; font-size: .93rem; line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere; animation: panel-in .3s var(--ease); }
.chat-msg--bot { align-self: flex-start; background: var(--surface); border: 1px solid var(--line); border-bottom-left-radius: 5px; }
.chat-msg--user { align-self: flex-end; background: #15232b; color: #fdf8ec; border-bottom-right-radius: 5px; }
.chat-msg--tool { align-self: flex-start; font-size: .76rem; color: var(--ink-2); padding: 2px 6px; background: transparent; }
.chat-msg a { font-weight: 600; }
.typing { display: inline-flex; gap: 4px; padding: 4px 0; }
.typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--ink-2); animation: blink 1.2s infinite; }
.typing i:nth-child(2) { animation-delay: .15s; } .typing i:nth-child(3) { animation-delay: .3s; }
@keyframes blink { 0%, 60%, 100% { opacity: .25; transform: none; } 30% { opacity: 1; transform: translateY(-3px); } }
.chat-suggest { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 16px 10px; background: var(--paper); }
.chat-suggest .chip { font-size: .78rem; padding: 6px 11px; background: var(--surface); }
.chat-form { display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--line); background: var(--surface); }
.chat-form textarea { flex: 1; resize: none; height: 46px; max-height: 120px; padding: 12px 14px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--paper); color: var(--ink); font: 400 .95rem var(--font-body); }
.chat-form textarea:focus { outline: 0; border-color: var(--brick); }
.chat-form textarea[disabled] { opacity: .6; cursor: not-allowed; }
.chat-form button { width: 46px; height: 46px; border-radius: 14px; border: 0; background: var(--brick); color: #fff; display: grid; place-items: center; cursor: pointer; flex: none; }
.chat-form button[disabled] { opacity: .5; cursor: not-allowed; }
.chat-offline { padding: 10px 16px; font-size: .82rem; line-height: 1.4; background: var(--surface); border-top: 1px solid var(--line); color: var(--ink-2); }
.chat-offline a { color: inherit; }
.chat-fine { padding: 0 14px 10px; font-size: .68rem; color: var(--ink-2); background: var(--surface); line-height: 1.35; }

/* Toast */
.toast { position: fixed; left: 50%; bottom: 84px; translate: -50% 30px; z-index: 400; padding: 12px 20px; border-radius: 999px; background: #15232b; color: #fdf8ec; font-weight: 500; font-size: .92rem; opacity: 0; pointer-events: none; transition: all .35s var(--ease); box-shadow: var(--shadow-2); }
.toast.is-on { opacity: 1; translate: -50% 0; }

/* Motion: scroll reveal + cursor glow */
[data-reveal] { opacity: 0; transform: translateY(28px); transition: opacity .8s var(--ease), transform .8s var(--ease); transition-delay: calc(var(--i, 0) * 80ms); }
[data-reveal="left"] { transform: translateX(-36px); } [data-reveal="right"] { transform: translateX(36px); } [data-reveal="zoom"] { transform: scale(.94); }
[data-reveal].is-in { opacity: 1; transform: none; }
.no-js [data-reveal] { opacity: 1; transform: none; }
.glow { position: fixed; z-index: 0; width: 520px; height: 520px; margin: -260px 0 0 -260px; border-radius: 50%; pointer-events: none; background: radial-gradient(circle, color-mix(in srgb, var(--gold) 16%, transparent), transparent 62%); opacity: 0; transition: opacity .5s; }
body.has-pointer .glow { opacity: 1; }
main, .site-header, .site-footer { position: relative; z-index: 1; }
.site-header { z-index: 100; }
.scroll-progress { position: fixed; top: 0; left: 0; height: 3px; width: 100%; transform: scaleX(0); transform-origin: left; background: linear-gradient(90deg, var(--brick), var(--gold)); z-index: 150; }

.cta-band { border-radius: clamp(18px, 3vw, 32px); padding: clamp(32px, 6vw, 72px); background: radial-gradient(700px 300px at 90% 0%, rgb(217 164 65 / .35), transparent 70%), #15232b; color: #fdf8ec; display: grid; gap: 20px; position: relative; overflow: hidden; }
.cta-band h2 { color: #fffaf0; max-width: 20ch; margin: 0; }
.cta-band p { color: #cfd8da; max-width: 56ch; margin: 0; }

/* Guide hub and tour planning */
.guide-hub-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.guide-hub-card { min-height: 270px; padding: clamp(24px, 4vw, 42px); border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); display: flex; flex-direction: column; align-items: flex-start; gap: 16px; box-shadow: var(--shadow-1); }
.guide-hub-card h2 { font-size: clamp(1.55rem, 2.5vw, 2.2rem); margin: 0; }
.guide-hub-card p { margin: 0; color: var(--ink-2); max-width: 48ch; }
.guide-hub-card .btn-row { margin-top: auto; }
.guide-path { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; padding: 1px; margin: 28px 0 0; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.guide-path li { background: var(--surface); padding: 22px; display: grid; gap: 8px; }
.guide-path span { color: var(--ink-2); font-size: .92rem; line-height: 1.5; }
.tour-steps { display: grid; gap: 12px; margin-top: 20px; }
.tour-steps p { margin: 0; padding: 14px 16px; border-left: 3px solid var(--gold); background: var(--surface); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.public-feedback { display: grid; gap: 10px; margin: 18px 0; }
.public-feedback h3 { margin: 0; font-size: 1.05rem; }
.public-feedback__item { padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); }
.public-feedback__item > div { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.public-feedback__item .badge { font-size: .68rem; }
.public-feedback__item p { margin: 8px 0 0; white-space: pre-wrap; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  [data-reveal] { opacity: 1; transform: none; }
  .glow, .hero__canvas { display: none; }
  @view-transition { navigation: none; }
}
@media print { .site-header, .site-footer, .chat-launcher, .chat-panel, .glow, .compare-tray { display: none !important; } body { background: #fff; color: #000; } }

/* ---- Narrow-screen grid safety ----
   Percentages inside minmax() can't always resolve during intrinsic sizing, which lets a
   multi-column track keep its ideal width and push the page sideways on small screens.
   Collapsing to one column below 720px and letting grid children shrink fixes it for every
   grid on the site without touching each page's markup. */
.split > *, .calc > *, .grid > *, .form__row > *, .filters > *, .stats > *, .guide-layout > * { min-width: 0; }
/* [data-reveal="left|right"] starts life translated 36px sideways, which counts as page
   overflow until the element animates in. overflow-x: clip contains it without creating a
   scroll container the way overflow: hidden would (that would break position: sticky inside). */
.section, .page-hero, main { overflow-x: clip; }
@media (max-width: 720px) {
  .split, .calc, .grid--2, .grid--3, .grid--4, .form__row, .filters, .guide-layout, .home-workspace, .status-grid { grid-template-columns: 1fr; }
  .home-workspace__facts { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .calc__result, .sticky-card, .guide-toc { position: static; }
  .feature-list { columns: 1; }
  .guide-hub-grid, .guide-path { grid-template-columns: 1fr; }
}

/* Kept after the component definitions so these Android controls win the cascade. */
@media (max-width: 520px) {
  .compare-tray { bottom: calc(78px + env(safe-area-inset-bottom)); width: calc(100vw - 32px); max-width: none; justify-content: space-between; gap: 8px; padding: 10px 12px; border-radius: 16px; }
  .compare-tray .btn { min-height: 42px; padding-inline: 14px; }
  .chat-launcher { right: max(12px, env(safe-area-inset-right)); bottom: max(12px, env(safe-area-inset-bottom)); min-width: 48px; min-height: 48px; padding: 13px 15px; }
  .chat-launcher span { display: none; }
  .chat-panel { right: 12px; bottom: max(12px, env(safe-area-inset-bottom)); width: calc(100vw - 24px); height: min(680px, calc(100dvh - 24px - env(safe-area-inset-bottom))); }
  dialog.modal { width: calc(100vw - 20px); max-height: calc(100dvh - 20px); }
  .modal__head, .modal__body { padding-inline: 14px; }
  .table th, .table td { padding: 10px 12px; }
}
