/* ═══════════════════════════════════════════════════════════════════
   RENA — Centered Chat Bubble
   Cinematic hero behind, chat bubble front-and-center
   ═══════════════════════════════════════════════════════════════════ */

*,*::before,*::after{box-sizing:border-box;margin:0;padding:0}

:root{
  color-scheme:dark;
  --bg:#0a0f1a;
  --text:#ffffff;
  --text-muted:rgba(255,255,255,.55);
  --text-subtle:rgba(255,255,255,.35);
  --border:rgba(255,255,255,.1);
  --primary:#c8a951;
  --primary-hover:#d4b96a;
  --chase-core:#fdeab8;
  --bubble-bg:rgba(14,20,34,.92);
  --identity-bg:rgba(14,20,34,1);
  --bubble-border:rgba(255,255,255,.1);
  --input-bg:rgba(255,255,255,.06);
  --input-border:rgba(255,255,255,.1);
  --input-focus:rgba(200,169,81,.35);
  --msg-rena:rgba(20,35,55,.88);
  --msg-user:rgba(200,169,81,.18);
  --footer-bg:rgba(10,15,26,.8);
  --chip-hover-bg:rgba(255,255,255,.14);
  --nav-item-hover-bg:rgba(255,255,255,.06);
  --nav-close-hover-bg:rgba(255,255,255,.08);
  --modal-input-bg:rgba(255,255,255,.05);
  --listing-placeholder-bg:rgba(255,255,255,.03);
  --hero-gradient:linear-gradient(180deg,rgba(10,15,26,.15) 0%,rgba(10,15,26,.2) 50%,rgba(10,15,26,.7) 85%);

  --font:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
  --transition:220ms ease;
  --stage-w:90vw;
}
/* iOS ≤14.4 Safari lacks min(); media-query clamp keeps --stage-w exact so the
   .top-menu-btn right:calc((100vw - var(--stage-w))/4 - 20px) gutter math stays valid. */
@media(min-width:489px){ :root{ --stage-w:440px; } }

/*
  ═══════════════════════════════════════════════════════════════════
  LIGHT THEME — DESIGNED BUT NOT CURRENTLY OFFERED (2026-08-25)
  Dark is the single permanent theme; the nav selector was removed.
  Kept as reference for a future light theme. Re-enable: restore the
  `body.light` variable block (deleted 2026-09-17 — see git history) in
  addition to un-commenting the surface rules below.
  ═══════════════════════════════════════════════════════════════════

  body.light .hero-image{ filter:brightness(.62); }
  body.light .hero-gradient{
    background:linear-gradient(180deg, rgba(245,243,239,.08) 0%, rgba(245,243,239,.16) 50%, rgba(245,243,239,.6) 85%);
  }
  body.light .chat-card{
    background:rgba(255,255,255,.50);
    border:1px solid rgba(0,0,0,.07);
    border-radius:20px;
    padding:14px 12px;
    backdrop-filter:blur(28px);-webkit-backdrop-filter:blur(28px);
    box-shadow:0 10px 44px rgba(0,0,0,.18);
  }
  body.light .bubble-input-row{
    background:rgba(0,0,0,.10);
    border-color:rgba(0,0,0,.16);
    box-shadow:inset 0 1px 3px rgba(0,0,0,.08);
  }
*/
html{font-size:16px;-webkit-text-size-adjust:100%}
body{
  font-family:var(--font);background:var(--bg);color:var(--text);
  line-height:1.6;min-height:100svh;height:100svh;
  overflow:hidden;display:flex;flex-direction:column;
  transition:background var(--transition),color var(--transition);
}

/* ════════════════════════════════════════════
   CINEMATIC HERO
   ════════════════════════════════════════════ */
.hero-cinematic{position:fixed;inset:0;z-index:0}
.hero-image{
  position:absolute;inset:-8%;
  /* rgba(0,0,0,.55) overlay == the old filter:brightness(.45) (0.45 = 1 - 0.55),
     inlined as a background layer so no composited `filter` layer is created.
     Static image — the Ken Burns kb animation was removed (2026-09-18) after
     it jittered fixed-position heroes across iPhone 12/13/14 despite GPU-layer
     promotion. */
  background:
    linear-gradient(rgba(0,0,0,.55),rgba(0,0,0,.55)),
    url('/img/hero-reno.webp') center/cover no-repeat;
}
.hero-gradient{
  position:absolute;inset:0;
  background:var(--hero-gradient);
}

/* ════════════════════════════════════════════
   IDENTITY CLUSTER (CB Logo + Agent Info)
   ════════════════════════════════════════════ */
.identity-cluster{
  position:fixed; top:0; left:50%; transform:translateX(-50%);
  z-index:30; width:90%; max-width:440px;
  display:flex; align-items:center; gap:10px;
  padding:8px 14px;
  /* opaque --identity-bg: top-edge-line fix + rationale → docs/STYLE_REFERENCE.md §7.1 */
  background:var(--identity-bg);
  border:1px solid var(--border);
  border-top:none;
  border-radius:0 0 16px 16px;
}
.identity-cluster > div{min-width:0}
.identity-cluster img{
  width:60px; height:60px; display:block; opacity:1;
  filter:drop-shadow(0 1px 2px rgba(0,0,0,.9)) drop-shadow(0 3px 8px rgba(0,0,0,.65)) drop-shadow(0 6px 18px rgba(0,0,0,.45));
}
.identity-name{
  font-size:12px; font-weight:600; letter-spacing:.02em; color:#fff;
  text-shadow:
    0 1px 3px rgba(0,0,0,.95),
    0 2px 6px rgba(0,0,0,.85);
}
.identity-lic{
  font-size:11px; letter-spacing:.05em; color:rgba(255,255,255,.86);
  text-shadow:0 1px 2px rgba(0,0,0,.95), 0 2px 6px rgba(0,0,0,.85);
}
.identity-more{
  font-size:11px; letter-spacing:.05em; color:rgba(255,255,255,.86);
  text-shadow:0 1px 2px rgba(0,0,0,.95), 0 2px 6px rgba(0,0,0,.85);
  cursor:pointer;
  transform-origin:center;
  animation:
    identity-more-wobble 550ms ease-in-out 1s,
    identity-more-wobble 550ms ease-in-out 8s,
    identity-more-wobble 550ms ease-in-out 15s,
    identity-more-wobble 550ms ease-in-out 22s;
}
/* "[more info]" wobble: four subtle nudges at ~1s/8s/15s/22s after load,
   then stops (four single-iteration animations with staggered delays — no
   JS, no indefinite loop). transform-origin:center rotates in-place.
   Tuning constants + rationale → docs/STYLE_REFERENCE.md §7.2. */
@keyframes identity-more-wobble{
  0%{transform:rotate(0deg)}
  20%{transform:rotate(-3deg)}
  40%{transform:rotate(3deg)}
  60%{transform:rotate(-2deg)}
  80%{transform:rotate(1.5deg)}
  100%{transform:rotate(0deg)}
}
@media (prefers-reduced-motion: reduce){
  .identity-more{animation:none}
}

/* ════════════════════════════════════════════
   HERO TEXT
   ════════════════════════════════════════════ */
.hero-text{
  position:fixed;top:34%;left:50%;transform:translateX(-50%);
  z-index:2;text-align:center;pointer-events:none;
  transition:opacity 500ms ease,transform 500ms ease;
  width:92%;max-width:440px;
}
.hero-text.fade-up{opacity:0;transform:translate(-50%,-60%)}
.hero-label{
  font-size:clamp(.9rem,3vw,1.3rem);font-weight:300;
  letter-spacing:2.5px;text-transform:uppercase;
  color:#ffffff;line-height:1.7;
  text-shadow:0 2px 8px rgba(0,0,0,.35);
  transition:opacity 450ms ease,transform 450ms ease;
}
.hero-label.swap{opacity:0;transform:translateY(-8px)}

/* ════════════════════════════════════════════
   CHAT BUBBLE STAGE — centered
   ════════════════════════════════════════════ */
.chat-bubble-stage{
  position:fixed;bottom:8%;left:50%;transform:translateX(-50%);
  z-index:10;width:90%;max-width:440px;
  display:flex;flex-direction:column;align-items:center;gap:12px;
  transition:bottom 400ms ease;
}

.chat-card{
  display:flex;flex-direction:column;align-items:center;gap:12px;width:100%;
}

.bubble-greeting{
  font-size:1.005rem;font-weight:600;color:var(--text);
  margin-bottom:12px;text-align:center;
}

.identity-line{
  font-size:.68rem;color:var(--text-subtle);
  text-align:center;margin-bottom:10px;
  letter-spacing:0.01em;
}
.identity-line-franchise{display:none}

.chat-bubble-stage--active{
  bottom:55px;
  transition:bottom 400ms ease;
}
.chat-bubble-stage--active .bubble-greeting{display:none}
.chat-bubble-stage--active .chat-messages{
    max-height:calc(100vh - 180px);order:-1;
  }
.chat-bubble-stage--active .bubble-input{min-height:44px;max-height:90px}

/* ════════════════════════════════════════════
   PRE-INPUT CTA ROW
   ════════════════════════════════════════════ */
@keyframes cta-sizzle-in{
  from{opacity:0;transform:translateY(8px) scale(.94)}
  to{opacity:1;transform:translateY(0) scale(1)}
}
.cta-row{
  display:flex;gap:5px;justify-content:center;flex-wrap:wrap;
  padding:0 2px;
}
.cta-btn{
  opacity:0;
  animation:cta-sizzle-in 420ms cubic-bezier(.2,.8,.2,1) forwards;
  padding:7px 9px;font-size:.7825rem;font-weight:600;
  font-family:var(--font);color:var(--text);
  background:var(--bubble-bg);border:1px solid var(--bubble-border);
  border-radius:14px;cursor:pointer;transition:all var(--transition);
  white-space:nowrap;
}
.cta-btn:nth-child(1){animation-delay:100ms}
.cta-btn:nth-child(2){animation-delay:180ms}
.cta-btn:nth-child(3){animation-delay:260ms}
.cta-btn:nth-child(4){animation-delay:340ms}
.cta-btn:hover{background:var(--chip-hover-bg);color:var(--primary);border-color:var(--primary)}

/* Input row inside bubble — hamburger | input | send */
.bubble-input-row{
  width:100%;
  display:flex;align-items:center;gap:8px;
  background:var(--input-bg);
  border:1px solid var(--input-border);
  border-radius:14px;padding:8px 10px;
  transition:border-color var(--transition);
}
.bubble-input-row:focus-within{border-color:var(--input-focus)}

/* Left icon column — flat glyphs (no circles): menu above phone */
.bubble-icon-col{
  display:flex;flex-direction:column;align-items:center;gap:11px;
  flex-shrink:0;
}
.bubble-menu-btn{
  background:none;border:none;cursor:pointer;padding:0;
  width:25px;height:25px;
  display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;flex-shrink:0;
}
.bubble-menu-btn span{display:block;width:16px;height:1.5px;background:var(--text-muted);border-radius:1px}

.bubble-call{
  background:none;border:none;cursor:pointer;padding:0;
  width:25px;height:25px;color:var(--text-muted);
  display:flex;align-items:center;justify-content:center;
  text-decoration:none;flex-shrink:0;
}
.bubble-call:hover{color:var(--primary)}
.bubble-book{
  background:none;border:none;cursor:pointer;padding:0;
  width:25px;height:25px;color:var(--text-muted);
  display:flex;align-items:center;justify-content:center;
  text-decoration:none;flex-shrink:0;
}
.bubble-book:hover{color:var(--primary)}

.top-menu-btn{
  position:fixed;top:20px;right:calc((100vw - var(--stage-w))/4 - 20px);z-index:35;
  width:40px;height:40px;
  background:none;border:none;
  display:flex;flex-direction:column;align-items:center;
  justify-content:center;gap:4px;cursor:pointer;
  filter:drop-shadow(0 1px 2px rgba(0,0,0,.8)) drop-shadow(0 2px 6px rgba(0,0,0,.5));
}
.top-menu-btn::after{
  content:'';position:absolute;inset:-20px;
}
.top-menu-btn span{
  display:block;width:20px;height:2px;
  background:var(--text);border-radius:1px;
}

/* ════════════════════════════════════════════
   HOME BADGE — reusable, one-include component
   ════════════════════════════════════════════ */
.home-badge{
  position:fixed;top:90px;right:20px;z-index:36;
  width:40px;height:40px;border-radius:50%;
  background:var(--primary);color:#fff;
  border:none;
  display:flex;align-items:center;justify-content:center;
  cursor:pointer;text-decoration:none;
  filter:drop-shadow(0 1px 3px rgba(0,0,0,.5)) drop-shadow(0 3px 8px rgba(0,0,0,.35));
  transition:background var(--transition),transform var(--transition);
}
.home-badge:hover{background:var(--primary-hover);transform:scale(1.08)}
.home-badge svg{
  width:18px;height:18px;stroke:#fff;stroke-width:2;
  fill:none;stroke-linecap:round;stroke-linejoin:round;
}

/* ════════════════════════════════════════════
   OPEN HOUSE SIGN-IN FORM
   ════════════════════════════════════════════ */
.openhouse-form-view{
  position:relative;z-index:20;
  display:flex;flex-direction:column;align-items:center;justify-content:flex-start;
  min-height:100svh;padding:calc(77px + 40px) 20px 80px;
}

/* Samsung Internet (Chromium) does not reliably shrink the layout viewport when the
   soft keyboard opens, so the base body's height:100svh + overflow:hidden traps the
   Agent Name field and "No Agent Yet" checkbox behind the keyboard with no way to
   scroll to them (iOS auto-pans, so it is unaffected). Unlock the open-house body the
   same way body.privacy-page / body.hub-page already do: auto height, 100dvh floor,
   scrollable overflow. This makes scrollIntoView (see keepFocusedVisible in the page
   JS) actually scroll the page on Samsung. */
body.openhouse-page{
  overflow-y:auto;
  height:auto;
  min-height:100dvh;
}

/* Staged reveal above the card */
.oh-above{
  text-align:center;margin-bottom:24px;width:100%;max-width:420px;
  padding:0 16px;
}

@media (max-width:440px){
  .oh-above{ margin-bottom:32px; padding:0 12px; }
  .oh-welcome{ font-size:clamp(.7rem,3vw,.85rem); }
  .oh-address-line{ font-size:clamp(1rem,7vw,1.5rem); }
  .oh-card{ padding:24px 18px; }
  .openhouse-form-view{ padding-top:calc(77px + 28px); padding-bottom:60px; }
}

/* Staged reveal — hero-tagline font from .hero-label */
.oh-welcome{
  font-size:clamp(.8rem,2.5vw,1.1rem);font-weight:300;
  letter-spacing:3px;text-transform:uppercase;
  color:#ffffff;text-align:center;line-height:1.4;
  text-shadow:0 2px 8px rgba(0,0,0,.35);
  opacity:1;animation:ohFadeIn 500ms ease 900ms both;
}
.oh-address-line{
  font-size:clamp(1.2rem,5vw,2rem);font-weight:300;
  letter-spacing:1.5px;
  color:#ffffff;text-align:center;line-height:1.3;
  text-shadow:0 2px 10px rgba(0,0,0,.4);
  margin:6px 0 0;opacity:1;
  animation:ohFadeIn 500ms ease 1500ms both;
}
@keyframes ohFadeIn{from{opacity:0}to{opacity:1}}
@keyframes ohRiseIn{
  from{opacity:0;transform:translateY(24px)}
  to{opacity:1;transform:translateY(0)}
}

.oh-card{
  width:100%;max-width:420px;margin:0 auto;
  background:rgba(200,169,81,.06);backdrop-filter:blur(24px);
  -webkit-backdrop-filter:blur(24px);
  border:1px solid rgba(255,255,255,.08);border-radius:16px;
  padding:28px 24px;
  opacity:0;animation:ohRiseIn 450ms ease 400ms forwards;
}
/* backdrop-filter fallback: when neither the standard nor -webkit- prefixed
   property is supported, the card's gold tint is nearly transparent over the
   hero image and reads as flat navy with only a thin outline. Give it an
   intentional warm dark, mostly-opaque background instead (matches the
   body.inputting fallback tone) so text stays legible without the blur. */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))){
  .oh-card{ background:rgba(46,36,20,.92); }
}
.oh-title{display:none}
.oh-address{display:none}
.oh-form{display:flex;flex-direction:column;gap:18px}
.oh-field{display:flex;flex-direction:column;gap:6px}
.oh-label{
  font-size:.78rem;font-weight:600;color:var(--text-muted);
  display:flex;align-items:center;gap:6px;
  text-shadow:0 1px 4px rgba(0,0,0,.5);
}
.oh-required{color:var(--primary);text-shadow:0 1px 4px rgba(0,0,0,.5)}
.oh-hint{font-weight:400;font-size:.72rem;color:var(--text-subtle);text-shadow:0 1px 3px rgba(0,0,0,.4)}
.oh-input{
  width:100%;padding:10px 14px;
  background:rgba(14,20,34,.32);border:1px solid rgba(255,255,255,.12);
  border-radius:10px;color:var(--text);font-size:16px;
  font-family:var(--font);outline:none;
  transition:border-color .2s;
}
.oh-input::placeholder{color:rgba(255,255,255,.35);text-shadow:0 1px 3px rgba(0,0,0,.4)}
.oh-input:focus{border-color:var(--primary)}
.oh-input:disabled{opacity:.4}
.oh-agent-row, .oh-decline-row{
  display:flex;align-items:center;gap:10px;
}
.oh-agent-row .oh-input, .oh-decline-row .oh-input{flex:1}
.oh-check{
  display:flex;align-items:center;gap:6px;
  font-size:.76rem;color:var(--text-muted);
  white-space:nowrap;cursor:pointer;
}
.oh-check input[type="checkbox"]{
  width:16px;height:16px;accent-color:var(--primary);cursor:pointer;
}
.oh-error{
  color:#f87171;font-size:.78rem;text-align:center;
}
.oh-submit{
  width:100%;padding:12px;
  background:var(--primary);color:#0e1422;
  border:none;border-radius:10px;
  font-size:.88rem;font-weight:600;cursor:pointer;
  transition:opacity .2s;
}
.oh-submit:hover{opacity:.9}
.oh-submit:disabled{opacity:.5;cursor:not-allowed}

.openhouse-thankyou-view{
  position:relative;z-index:20;
  min-height:100svh;
}

.oh-radio-row{
  display:flex;align-items:center;gap:20px;
}
.oh-radio{
  display:flex;align-items:center;gap:6px;
  font-size:.84rem;color:var(--text);cursor:pointer;
}
.oh-radio input[type="radio"]{
  width:16px;height:16px;accent-color:var(--primary);cursor:pointer;
}
.oh-textarea{
  resize:vertical;min-height:72px;
  font-family:var(--font);
}

.bubble-input{
  flex:1;border:none;background:transparent;
  font-family:var(--font);font-size:.84rem;color:var(--text);
  resize:none;outline:none;line-height:1.5;
  min-height:40px;max-height:140px;padding:1px 0;
}
.bubble-input::placeholder{color:var(--text-subtle);font-size:14.8px}

.bubble-send{
  flex-shrink:0;width:34px;height:34px;
  border:none;border-radius:50%;background:var(--primary);color:#fff;
  cursor:pointer;display:flex;align-items:center;justify-content:center;
  transition:all var(--transition);
}
.bubble-send:hover{background:var(--primary-hover)}
.bubble-send:disabled{opacity:.3;cursor:not-allowed}

/* ════════════════════════════════════════════
   CHAT MESSAGES (appear above bubble)
   ════════════════════════════════════════════ */
.chat-messages{
  width:100%;max-height:35vh;overflow-y:auto;
  display:flex;flex-direction:column;gap:10px;
  padding:0 2px;scroll-behavior:smooth;
}
.chat-messages::-webkit-scrollbar{width:3px}
.chat-messages::-webkit-scrollbar-thumb{background:rgba(255,255,255,.1);border-radius:2px}

/* ══════════════════════════════════════════════════════════════════
   CHAT FADE OVERLAY — scroll-driven scrim under the header.
   ══════════════════════════════════════════════════════════════════
   Replaces the old mask-image on .chat-messages (which faded the
   container's own top 72px regardless of scroll). This is a fixed
   scrim layered ON TOP of the chat, revealed only when messages
   actually overflow up under the header (see syncFadeOverlay() in
   app.js — it toggles .chat-fade-overlay--visible when
   chatMsgs.scrollHeight > clientHeight, so the fresh/short state
   never shows a box).

   TUNING LEVERS (adjust these, not the JS):
   ─ top:34px            — vertical origin; must align to the header's
                           top edge (.identity-cluster top is 34px).
   ─ height:72px         — how tall the fade band is. Header content is
                           only ~60px (34→94); keep close to that, not
                           a large band (a tall band reads as a box).
   ─ gradient stops       — the 4 rgba() alphas below are the opacity
                           curve, top→bottom. Max is the first stop
                           (currently .55 = ~55% opaque). Lower all four
                           for a lighter vignette; raise for stronger.
                           The multi-stop curve (0/42/75/100%) is the
                           ease-out falloff — keep the shape, not a hard
                           jump, so it reads as a genuine fade.
   ─ opacity/transition   — base opacity:0 + 200ms fade in on --visible;
                           change 200ms to tune the appear speed.
   ─ width:90%;max-width:440px;left:50%;translateX(-50%) — matches the
                           chat-bubble-stage centering; change together
                           if the stage width ever changes.

   RESOLVED (b7a83ac, 2026-08-31): the ghosting issue below (header's OWN
   text/logo not fully obscured in busy-scroll) is FIXED — a dedicated
   always-on card backdrop on .identity-cluster (background:var(--identity-bg)
   opaque, border, radius, padding — backdrop-filter removed 2026-08-31 to
   kill a top-edge blur halo) now sits behind the
   header text independently of this scrim. This scrim remains as-is: the
   scroll-driven darkening layer only, no longer responsible for header
   legibility. (Old note, kept for history: the scrim only darkens, it doesn't
   paint a solid background behind the identity cluster, so bright messages
   could ghost through the header text at high scroll.)
   ══════════════════════════════════════════════════════════════════ */
.chat-fade-overlay{
  position:fixed;top:34px;left:50%;transform:translateX(-50%);
  width:90%;max-width:440px;height:72px;z-index:29;
  pointer-events:none;
  opacity:0;transition:opacity 200ms ease;
  background:linear-gradient(to bottom,
    rgba(10,15,26,.55) 0%,
    rgba(10,15,26,.32) 42%,
    rgba(10,15,26,.12) 75%,
    rgba(10,15,26,0) 100%);
}
.chat-fade-overlay--visible{opacity:1}

.msg-rena,.msg-user{animation:in 280ms ease;max-width:88%}
@keyframes in{from{opacity:0;transform:translateY(6px)}to{opacity:1;transform:translateY(0)}}

.msg-rena{align-self:flex-start}
.msg-rena .msg-bubble{
  background:var(--msg-rena);border:1px solid var(--border);
  border-radius:16px 16px 16px 4px;padding:10px 14px;
  font-size:.925rem;line-height:1.55;color:var(--text);
  backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px);
}

.msg-user{align-self:flex-end}
.msg-user .msg-bubble{
  background:rgba(200,169,81,.25);border:1px solid var(--border);
  border-radius:16px 16px 4px 16px;padding:10px 14px;
  font-size:.925rem;line-height:1.55;color:var(--text);
  backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px);
}
/* No-blur fallback: without backdrop-filter the busy hero shows through the
   25% gold and white text gets noisy, so raise opacity to the AA ceiling —
   .27 holds 4.5:1 against the brightest hero region (a rare edge case). */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))){
  .msg-user .msg-bubble{ background:rgba(200,169,81,.27); }
}

/* ── Inline links inside chat bubbles ─────────────────
   <a> tags generated inline in addRenaMsg() HTML (PM company
   links in rentPM/rentBridge/area-drill-down, tel:/sms: links in
   escalation_handoff). Scoped to .msg-bubble so no risk of leaking
   to global link defaults. :not(.ichip) keeps chip-links (View full
   details) completely unaffected — they're .ichip already and
   text-decoration:none + chip styling rules win by specificity. */
.msg-bubble a:not(.ichip){
  color:var(--primary);
  text-decoration:underline;
  text-decoration-color:rgba(200,169,81,.4);
  text-underline-offset:3px;
  transition:color var(--transition),text-decoration-color var(--transition);
}
.msg-bubble a:not(.ichip):hover{
  color:var(--primary-hover);
  text-decoration-color:var(--primary-hover);
}
.msg-bubble a:not(.ichip):visited{
  color:var(--primary);
}

/* Disclosure-bubble link — light/near-white (a neutral system notice inside
   the user-style gold bubble), deliberately distinct from the themed gold
   link treatment above. Dark is the single active theme, so near-white is safe. */
.msg-user .msg-bubble a.disclosure-link{
  color:rgba(255,255,255,.92);
  text-decoration-color:rgba(255,255,255,.45);
}
.msg-user .msg-bubble a.disclosure-link:hover{color:#fff;text-decoration-color:#fff}

/* Intelligent chips */
.msg-chips{display:flex;flex-wrap:wrap;gap:5px;margin-top:8px}
.ichip{
  padding:5px 11px;font-size:.7625rem;font-family:var(--font);font-weight:500;
  color:var(--text);background:var(--input-bg);
      border:1px solid var(--input-border);border-radius:14px;
  cursor:pointer;text-decoration:none;transition:all var(--transition);white-space:nowrap;
}
.ichip:hover{background:var(--chip-hover-bg);color:var(--primary);border-color:var(--primary)}
.ichip--inert{color:var(--text-muted);pointer-events:none;cursor:default}
.ichip--inert .chase-glow{display:none}

/* ── Chase-glow (2026-08-31) ─────────────────────────────
   Replaces the old conic-gradient sheen. A two-layer SVG
   stroke (blurred glow + crisp core) travels the pill outline
   counter-clockwise. Path is generated per-element in app.js
   (pillPath) and normalized via pathLength="1" so dasharray/
   dashoffset are unitless fractions — fully size-independent.
   Applies to capture-gate chips (.ichip--action, set by
   renderChips) and homepage CTAs (.cta-btn).
   Mechanics + tuning rationale → docs/STYLE_REFERENCE.md §7.4 (glow) / §7.3 (wobble). */
.ichip--action,
.cta-btn{
  position:relative;
}
.chase-glow{
  position:absolute;inset:0;width:100%;height:100%;
  overflow:visible;pointer-events:none;
}
.chase-glow path{fill:none;stroke:var(--primary);stroke-dasharray:0 1;}
.chase-glow .cg-glow{
  stroke-width:2;stroke-opacity:.25;filter:blur(0.4px);
  animation:chase-glow 2.6s linear infinite;
}
.chase-glow .cg-core{
  stroke-width:0.9;stroke-opacity:1;stroke:var(--chase-core);
  animation:chase-glow 2.6s linear infinite;
}
@keyframes chase-glow {
  0%   { stroke-dashoffset: 0;     stroke-dasharray: 0.03 0.97; animation-timing-function: ease-in; }
  15%  { stroke-dashoffset: 0.176; stroke-dasharray: 0.18 0.82; animation-timing-function: linear; }
  30%  { stroke-dashoffset: 0.353; stroke-dasharray: 0.34 0.66; animation-timing-function: linear; }
  45%  { stroke-dashoffset: 0.529; stroke-dasharray: 0.50 0.50; animation-timing-function: linear; }
  55%  { stroke-dashoffset: 0.647; stroke-dasharray: 0.50 0.50; animation-timing-function: linear; }
  70%  { stroke-dashoffset: 0.824; stroke-dasharray: 0.25 0.75; animation-timing-function: ease-out; }
  85%  { stroke-dashoffset: 1.0;   stroke-dasharray: 0.03 0.97; }
  100% { stroke-dashoffset: 1.0;   stroke-dasharray: 0.03 0.97; }
}
@media (prefers-reduced-motion: reduce){
  .chase-glow .cg-glow,
  .chase-glow .cg-core{
    animation:none;
  }
}

/* ════════════════════════════════════════════
   TYPING PILL
   ════════════════════════════════════════════ */
.typing-pill{
  display:flex;align-items:center;gap:5px;
  background:var(--bubble-bg);border:1px solid var(--bubble-border);
  border-radius:18px;padding:8px 16px;
  backdrop-filter:blur(12px);
  animation:fade-up 200ms ease;
}
@keyframes fade-up{from{opacity:0;transform:translateY(4px)}to{opacity:1;transform:translateY(0)}}
.typing-pill span{width:5px;height:5px;border-radius:50%;background:var(--text-muted);display:block;
  animation:dot-p 1.3s infinite ease-in-out;}
.typing-pill span:nth-child(2){animation-delay:.2s}
.typing-pill span:nth-child(3){animation-delay:.4s}
@keyframes dot-p{0%,60%,100%{opacity:.3}30%{opacity:1}}

/* ════════════════════════════════════════════
   GLASS FOOTER
   ════════════════════════════════════════════ */
.glass-footer{
  position:fixed;bottom:0;left:0;right:0;z-index:8;
  text-align:center;padding:6px 16px 8px;
  font-size:.504rem;color:var(--text-muted);
  background:var(--footer-bg);
  backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);
}
.glass-footer .footer-sub-line{
  display:block;
  font-size:1em;
  color:var(--text-subtle);
  margin-top:2px;
}
.footer-caret-btn{display:inline-flex;align-items:center;justify-content:center;background:none;border:none;color:inherit;cursor:pointer;padding:0 4px 0 0;vertical-align:-1px}
.footer-caret-btn.open svg{transform:rotate(180deg)}
.footer-caret-btn svg{transition:transform 300ms ease}
#glassFooter{cursor:pointer}

/* ════════════════════════════════════════════
   NAV PANEL
   ════════════════════════════════════════════ */
.nav-panel{
  position:fixed;bottom:0;left:0;right:0;z-index:300;
  max-height:55vh;border-radius:18px 18px 0 0;
  background:var(--bubble-bg);border-top:1px solid var(--border);
  backdrop-filter:blur(30px);display:flex;flex-direction:column;
  animation:slide-up 280ms ease;box-shadow:0 -8px 32px rgba(0,0,0,.5);
}
@keyframes slide-up{from{transform:translateY(100%)}to{transform:translateY(0)}}
.nav-header{padding:18px 16px;border-bottom:1px solid var(--border);display:flex;align-items:center;justify-content:space-between}
.nav-title{font-size:.92rem;font-weight:600}
.nav-close{background:none;border:none;color:var(--text-muted);font-size:1rem;cursor:pointer;width:30px;height:30px;border-radius:50%;display:flex;align-items:center;justify-content:center}
.nav-close:hover{background:var(--nav-close-hover-bg)}
.nav-body{padding:10px;display:flex;flex-direction:column;gap:2px}
.nav-item{display:flex;align-items:center;justify-content:space-between;padding:12px 14px;border-radius:8px;background:none;border:none;color:var(--text);font-size:.84rem;font-family:var(--font);cursor:pointer;width:100%;text-align:left}
.nav-item:hover{background:var(--nav-item-hover-bg)}
.nav-call{color:var(--primary);font-weight:600}
.nav-book{color:var(--primary);font-weight:600}

/* ════════════════════════════════════════════
   MODALS
   ════════════════════════════════════════════ */
.modal-overlay{position:fixed;inset:0;z-index:200;background:rgba(0,0,0,.6);display:flex;align-items:center;justify-content:center;padding:16px;backdrop-filter:blur(4px);animation:fade-in 200ms ease}
@keyframes fade-in{from{opacity:0}to{opacity:1}}
.modal-card,.bio-card{background:var(--bubble-bg);border:1px solid var(--border);border-radius:18px;padding:22px;max-width:360px;width:100%;position:relative;backdrop-filter:blur(24px);animation:modal-up 280ms ease}
@keyframes modal-up{from{transform:translateY(20px);opacity:0}to{transform:translateY(0);opacity:1}}
.bio-card{text-align:center}
.bio-headshot{width:96px;height:96px;border-radius:50%;overflow:hidden;margin:0 auto 12px;border:2px solid var(--primary);display:flex;align-items:center;justify-content:center;}
.bio-headshot-img{width:100%;height:100%;object-fit:cover;object-position:center;border-radius:50%;}
.bio-name{font-size:1.1rem;font-weight:700;margin-bottom:2px}
.bio-license{font-size:.74rem;color:var(--text-muted)}
.bio-firm{font-size:.78rem;color:var(--text-muted);margin-bottom:6px}
.bio-ack{font-size:.68rem;color:var(--text-subtle);font-style:italic;margin-bottom:6px}
.bio-body{max-height:40vh;overflow-y:auto;padding-right:2px}
.bio-body::-webkit-scrollbar{width:3px}
.bio-body::-webkit-scrollbar-thumb{background:rgba(255,255,255,.1);border-radius:2px}
.bio-divider{border:none;border-top:1px solid var(--border);margin:10px auto;width:30px}
.bio-text{font-size:.8rem;line-height:1.5;color:var(--text-muted);margin-bottom:5px}
.modal-title{font-size:1.05rem;font-weight:700;margin-bottom:6px}
.modal-body{font-size:.82rem;color:var(--text-muted);line-height:1.55;margin-bottom:12px}
.modal-form{display:flex;flex-direction:column;gap:8px}
.modal-input{width:100%;padding:10px 14px;font-size:.85rem;font-family:var(--font);border:1px solid var(--border);border-radius:10px;background:var(--modal-input-bg);color:var(--text)}
.modal-input:focus{outline:none;border-color:var(--primary)}
.modal-error{font-size:.72rem;color:#f87171;padding:5px 10px;background:rgba(248,113,113,.1);border-radius:8px;border:1px solid rgba(248,113,113,.3)}
.modal-submit{padding:10px 20px;font-size:.85rem;font-weight:600;font-family:var(--font);color:#fff;background:var(--primary);border:none;border-radius:10px;cursor:pointer}
.modal-submit:hover{background:var(--primary-hover)}
.modal-submit:disabled{opacity:.4;cursor:not-allowed}
.modal-note{font-size:.64rem;color:var(--text-subtle);margin-top:8px;text-align:center}
.modal-close{position:absolute;top:8px;right:8px;width:26px;height:26px;border:none;border-radius:50%;background:transparent;color:var(--text-muted);font-size:.9rem;cursor:pointer;display:flex;align-items:center;justify-content:center}
.modal-close:hover{background:var(--nav-close-hover-bg)}

/* ════════════════════════════════════════════
   LISTING CARD
   ════════════════════════════════════════════ */
.listing-card-inline{border:1px solid var(--border);border-radius:10px;overflow:hidden;margin-top:6px}
.listing-card-inline .listing-photo{width:100%;height:140px;object-fit:cover;display:block}
.listing-card-inline .listing-photo--placeholder{background:var(--listing-placeholder-bg);display:flex;align-items:center;justify-content:center;color:var(--text-muted);font-size:.74rem;height:100px}
.listing-card-inline .listing-body{padding:8px}
.listing-card-inline .listing-price{font-size:1rem;font-weight:700}
.listing-card-inline .listing-address{font-size:.8rem;font-weight:600;margin:1px 0}
.listing-card-inline .listing-city{font-size:.68rem;color:var(--text-muted)}
.listing-card-inline .listing-specs{display:flex;gap:10px;margin:5px 0}
.listing-card-inline .listing-spec{text-align:center}
.listing-card-inline .listing-spec-val{font-weight:600;font-size:.8rem}
.listing-card-inline .listing-spec-lbl{font-size:.6rem;color:var(--text-muted)}
.listing-card-inline .listing-mls{font-size:.7rem;color:var(--text-subtle);margin:2px 0}
.listing-card-inline .listing-mls-icon{display:inline-block;width:20px;height:20px;vertical-align:middle;margin-left:6px;background:var(--text-subtle);border-radius:3px;flex-shrink:0}
.listing-card-inline .listing-attribution{font-size:.68rem;color:var(--text-subtle);margin:8px 0 0;padding-top:8px;border-top:1px solid var(--border);line-height:1.5}
.listing-card-inline .listing-disclaimer{font-size:.64rem;color:var(--text-subtle);margin:4px 0 0;line-height:1.5}

/* ════════════════════════════════════════════
   UTILITY + A11Y
   ════════════════════════════════════════════ */
.skip-link{position:absolute;top:-100px;left:12px;z-index:400;padding:6px 14px;background:var(--primary);color:#fff;border-radius:6px;font-weight:600;font-size:.76rem;text-decoration:none}
.skip-link:focus{top:8px}
[hidden]{display:none!important}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);border:0}

@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation-duration:.01ms!important;transition-duration:.01ms!important}}

/* ── Identity-cluster tab: sub-536px hamburger seat ────────────────
   Below 536px the right gutter beside the flush-top card is too narrow
   (16-20px) for the 40px menu button to sit clear, so the hamburger
   moves INSIDE the card's own box, right-aligned (standard mobile
   header: brand left, menu right). Interior padding (14px) matches the
   card's horizontal padding; the card's right padding reserves the
   hamburger footprint (40px) + gap so wrapped text never runs under it.
   ≥536px keeps the gutter-centered position (base .top-menu-btn rule). */
@media(max-width:535px){
  .identity-cluster{padding-right:calc(14px + 40px + 8px)}
  .top-menu-btn{right:calc((100vw - var(--stage-w))/2 + 14px)}
}

@media(min-width:640px){
  :root{--stage-w:460px}
  .chat-bubble-stage{max-width:460px}
  .identity-cluster{max-width:460px}
  .hero-text{top:30%}
  .hero-label{font-size:clamp(1rem,3.5vw,1.4rem)}
  .identity-line{font-size:.72rem;color:var(--text-muted)}
  .identity-line-franchise{display:inline}
}

/* ════════════════════════════════════════════
   STATIC CONTENT PAGE (privacy.html)
   ════════════════════════════════════════════ */
body.privacy-page{
  overflow-y:auto;
  height:auto;
  min-height:100dvh;
  display:block;
}
.privacy-content{
  position:relative;
  z-index:1;
  max-width:640px;
  margin:0 auto;
  padding:110px 20px 140px;
}
.privacy-card{
  background:var(--bubble-bg);
  border:1px solid var(--border);
  border-radius:18px;
  padding:24px 26px;
  backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px);
}
.privacy-content .back-link{
  display:inline-block;
  margin-bottom:16px;
  font-size:.78rem;
  color:var(--primary);
  text-decoration:none;
}
.privacy-content .back-link:hover{color:var(--primary-hover);text-decoration:underline}
.privacy-content h1{font-size:1.4rem;font-weight:700;color:var(--text);margin-bottom:4px}
.privacy-content .privacy-meta{font-size:.76rem;color:var(--text-subtle);margin-bottom:22px;line-height:1.6}
.privacy-content h2{
  font-size:1.02rem;font-weight:600;color:var(--text);
  margin:26px 0 10px;padding-bottom:6px;border-bottom:1px solid var(--border);
}
.privacy-content h3{font-size:.9rem;font-weight:600;color:var(--text);margin:20px 0 8px}
.privacy-content p{font-size:.88rem;color:var(--text-muted);line-height:1.7;margin-bottom:12px}
.privacy-content ul{margin:0 0 12px 20px;padding:0;font-size:.88rem;color:var(--text-muted);line-height:1.7}
.privacy-content li{margin-bottom:6px}
.privacy-content a{color:var(--primary);text-decoration:underline;text-decoration-color:rgba(200,169,81,.4);text-underline-offset:3px}
.privacy-content a:hover{color:var(--primary-hover)}
.privacy-content strong{color:var(--text)}
.privacy-note{
  background:var(--msg-user);
  border:1px solid var(--border);
  border-radius:10px;
  padding:10px 14px;
  font-size:.82rem;
  color:var(--text);
  line-height:1.6;
  margin:14px 0;
}
.privacy-contact{font-size:.9rem;color:var(--text-muted);line-height:1.8}

/* ════════════════════════════════════════════
   CONTENT HUB (dark navy/gold, long-form scrolling)
   Pinned identity-cluster header + in-flow scrolling footer.
   ════════════════════════════════════════════ */
body.hub-page{overflow-y:auto;height:auto;min-height:100dvh;display:block}
.hub-content{position:relative;z-index:1;max-width:720px;margin:0 auto;padding:110px 20px 48px}
.hub-footer{position:relative;z-index:1;text-align:center;padding:20px 16px 32px;font-size:.72rem;color:var(--text-muted);border-top:1px solid var(--border)}
.hub-footer-subline{display:block;font-size:.9em;color:var(--text-subtle);margin-top:2px}
.hub-content .pilot{display:inline-block;font-size:12px;letter-spacing:.04em;text-transform:uppercase;color:var(--primary);border:1px solid var(--primary);border-radius:3px;padding:3px 8px;margin-bottom:16px}
.hub-content h1{font-size:30px;line-height:1.2;margin:0 0 4px;color:var(--text)}
.hub-content h2{font-size:15px;text-transform:uppercase;letter-spacing:.05em;color:var(--text-muted);margin:32px 0 12px}
.hub-content h3.snapshot-group{font-size:13px;text-transform:uppercase;letter-spacing:.05em;color:var(--text-muted);margin:20px 0 8px;font-weight:600}
.hub-content .asof{color:var(--text-muted);font-size:14px;margin:0 0 16px}
.hub-content .disclaimer{font-size:13px;color:var(--text-muted);background:var(--input-bg);border:1px solid var(--border);border-radius:6px;padding:12px 14px;margin:0 0 20px}
.hub-content .card{background:var(--bubble-bg);border:1px solid var(--border);border-radius:8px;padding:20px}
.hub-content .stat{display:flex;justify-content:space-between;align-items:baseline;padding:10px 0;border-bottom:1px solid var(--border);gap:16px}
.hub-content .stat:last-child{border-bottom:none}
.hub-content .stat .v{font-weight:600;font-size:18px;text-align:right;color:var(--text)}
.hub-content .stat .sub{display:block;font-size:12px;font-weight:400;color:var(--text-muted);margin-top:2px}
.hub-content .stat .l{color:var(--text-muted);font-size:14px}
.hub-content .note{font-size:12.5px;color:var(--text-muted);margin-top:8px}
.hub-content ul.mix,.hub-content ul.list{list-style:none;padding:0;margin:0}
.hub-content ul.mix li,.hub-content ul.list li{display:flex;justify-content:space-between;padding:8px 0;border-bottom:1px solid var(--border)}
.hub-content ul.mix li:last-child,.hub-content ul.list li:last-child{border-bottom:none}
.hub-content ul.list li .l{color:var(--text)}
.hub-content ul.list li .v{color:var(--text-muted)}
.hub-content .hwr{border-left:3px solid var(--primary);background:var(--msg-user);padding:12px 14px;border-radius:0 6px 6px 0;margin:14px 0}
.hub-content .hwr .tag{display:block;font-size:11px;letter-spacing:.04em;text-transform:uppercase;color:var(--primary);font-weight:600;margin-bottom:6px}
.hub-content .hwr p{margin:0 0 6px;color:var(--text)}
.hub-content .hwr .aka{font-style:italic}
.hub-content .faq{margin:8px 0 0}
.hub-content .faq .q{font-weight:600;margin:10px 0 2px;color:var(--text)}
.hub-content .faq .a{margin:0;color:var(--text-muted)}
.hub-content .mapwrap{margin:10px 0}

/* ── Hub chrome: hamburger INSIDE the card at ALL widths ──────────────
   DELIBERATE DIVERGENCE from index.html/openhouse.html, scoped to hub pages
   only. On the main site the hamburger is gutter-centered on desktop and only
   moves inside the identity cluster below 536px. The hub seats it inside the
   card's top-right corner at EVERY width, reusing the <536px formula
   (right:calc((100vw - var(--stage-w))/2 + 14px)) plus the card's right-padding
   reservation. Do NOT "fix" this back to the base gutter-centered rule — the
   divergence is intentional (Grady's decision, 2026-09-28). */
body.hub-page .identity-cluster{
  padding-right:calc(14px + 40px + 8px);
}
body.hub-page .top-menu-btn{
  right:calc((100vw - var(--stage-w))/2 + 14px);
}
