/* ==========================================================================
   LuxLens showcase: app styles
   ========================================================================== */

:root {
  --bg: #0c0c0b;
  --surface: #151513;
  --surface-2: #1d1c19;
  --surface-3: #262521;
  --line: rgba(255, 255, 255, .08);
  --line-2: rgba(255, 255, 255, .14);
  --text: #f4f1ea;
  --muted: #a39d92;
  --faint: #6f6a61;
  --gold: #c9a46a;
  --gold-2: #dcbb85;
  --wa: #25d366;

  --serif: "Instrument Serif", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;

  --max: 1200px;
  --pad: clamp(16px, 3.4vw, 32px);
  --top-h: 68px;
  --bottom-h: 0px;
  /* One set of sizes used everywhere, so every tab feels the same */
  --r-lg: 20px;      /* big panels: hero, free-trial box, dialogs */
  --r: 14px;         /* cards, slider, video, banners */
  --r-sm: 10px;      /* photo tiles, inputs */
  --gap: 12px;       /* between photos and cards */
  --section: 48px;   /* space above each new section */
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--bg); }
html.no-scroll { overflow: hidden; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  padding-bottom: var(--bottom-h);
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { font-weight: 500; }
em { font-style: italic; }
svg { width: 20px; height: 20px; flex: none; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; border-radius: 6px; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--pad); }

.eyebrow {
  font-size: 11.5px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase;
  color: var(--gold);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 48px; padding: 0 22px; border-radius: 999px;
  font-size: 14.5px; font-weight: 600; white-space: nowrap;
  transition: background-color .2s, color .2s, border-color .2s, transform .15s;
  border: 1px solid transparent;
}
.btn:active { transform: scale(.98); }
.btn-sm { height: 40px; padding: 0 18px; font-size: 13.5px; }
.btn-block { width: 100%; }
.btn-gold { background: var(--gold); color: #15130f; }
.btn-gold:hover { background: var(--gold-2); }
.btn-dark { background: #15130f; color: var(--text); }
.btn-dark:hover { background: #000; }
.btn-ghost { border-color: var(--line-2); color: var(--text); }
.btn-ghost:hover { background: rgba(255,255,255,.06); }
.btn .caret { width: 16px; height: 16px; margin-right: -4px; transition: transform .2s; }
.btn[aria-expanded="true"] .caret { transform: rotate(180deg); }

.icon-btn {
  width: 42px; height: 42px; border-radius: 50%;
  display: grid; place-items: center;
  background: rgba(255,255,255,.08); color: var(--text);
  transition: background-color .2s;
}
.icon-btn:hover { background: rgba(255,255,255,.16); }

.badge {
  display: inline-flex; align-items: center; gap: 6px; flex: none;
  height: 28px; padding: 0 12px 0 9px; border-radius: 999px;
  background: rgba(201,164,106,.12); color: var(--gold);
  font-size: 12px; font-weight: 600; letter-spacing: .01em; white-space: nowrap;
}
.badge svg { width: 14px; height: 14px; }

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  height: 28px; padding: 0 11px; border-radius: 999px;
  background: var(--surface-3); color: var(--muted);
  font-size: 12px; font-weight: 500; white-space: nowrap;
}
/* Same look as the Our work section buttons */
.chip-btn { height: 38px; padding: 0 16px; font-size: 13.5px; color: var(--muted); background: none; border: 1px solid var(--line); transition: color .2s, border-color .2s; }
.chip-btn:hover { color: var(--text); border-color: var(--line-2); }
.chip-count { color: var(--muted); font-variant-numeric: tabular-nums; }

/* ---------- Top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 30;
  background: rgba(12,12,11,.82);
  backdrop-filter: saturate(1.6) blur(18px); -webkit-backdrop-filter: saturate(1.6) blur(18px);
  border-bottom: 1px solid var(--line);
  padding-top: env(safe-area-inset-top);
}
.topbar-inner {
  max-width: var(--max); margin: 0 auto; padding: 0 var(--pad);
  height: var(--top-h);
  display: flex; align-items: center; gap: 16px;
}
.brand { display: flex; align-items: center; height: 100%; flex: none; }
.brand-logo { height: 32px; width: auto; }
.brand-word { display: inline-flex; align-items: center; gap: 9px; font-family: var(--serif); font-size: 25px; line-height: 1; letter-spacing: .01em; }
.brand-mark { width: 22px; height: 22px; border-radius: 50%; border: 1.5px solid var(--text); position: relative; }
.brand-mark::after { content: ""; position: absolute; inset: 5.5px; border-radius: 50%; background: var(--gold); }

.for-pill {
  font-size: 12px; font-weight: 500; color: var(--muted);
  padding: 5px 11px; border-radius: 999px; border: 1px solid var(--line-2);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 220px;
}

.for-pill.has-logo { display: inline-flex; align-items: center; gap: 12px; padding: 0; border: 0; overflow: visible; max-width: none; }
.for-x { font-size: 15px; color: var(--faint); font-weight: 400; }
.for-logo { display: inline-flex; align-items: center; height: 34px; padding: 6px 12px; border-radius: 999px; background: #f4f1ea; }
.for-logo.dark { background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line-2); }
.for-logo img { height: 22px; width: auto; max-width: 132px; object-fit: contain; display: block; }
.for-logo.square { padding: 3px; border-radius: 9px; }
.for-logo.square img { height: 28px; border-radius: 6px; }

.tabs { display: flex; gap: 4px; margin: 0 auto; background: var(--surface); padding: 4px; border-radius: 999px; border: 1px solid var(--line); }
.tabs a {
  height: 36px; padding: 0 16px; border-radius: 999px;
  display: inline-flex; align-items: center; white-space: nowrap;
  font-size: 13.5px; font-weight: 500; color: var(--muted);
  transition: color .2s, background-color .2s;
}
.tabs a:hover { color: var(--text); }
.tabs a.active { background: var(--surface-3); color: var(--text); }

.topbar-actions { display: flex; align-items: center; gap: 16px; flex: none; }
.site-link { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); }
.site-link svg { width: 14px; height: 14px; }
.site-link:hover { color: var(--text); }

/* ---------- Screens ---------- */
.screen { display: none; padding: 28px 0 72px; }
.screen.active { display: block; animation: screenIn .35s var(--ease); }
@keyframes screenIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; margin-bottom: 24px; }
.panel-head h1 { font-family: var(--serif); font-weight: 400; font-size: clamp(2.1rem, 4.4vw, 3.2rem); line-height: 1.02; letter-spacing: -.01em; }
.panel-head p { margin-top: 10px; color: var(--muted); max-width: 46em; }

.block-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: var(--section) 0 16px; }

/* Every section heading on every tab */
.block-head h2, .plan-tier-head h2, .price-section h2, .trial-head h2 {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(1.75rem, 2.8vw, 2.25rem); line-height: 1.05; letter-spacing: -.005em;
}

/* ---------- Photo tiles & placeholders ---------- */
.ph {
  position: relative; display: block; overflow: hidden;
  background: var(--surface-2);
  aspect-ratio: 3 / 2;
  border-radius: var(--r-sm);
  width: 100%;
}
.ph img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .5s var(--ease), transform .8s var(--ease); }
.ph.loaded img { opacity: 1; }
.ph-empty {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  color: var(--faint); text-align: center; padding: 10px;
  background:
    radial-gradient(120% 90% at 30% 20%, rgba(201,164,106,.07), transparent 60%),
    repeating-linear-gradient(135deg, rgba(255,255,255,.018) 0 12px, transparent 12px 24px),
    var(--surface-2);
  border: 1px dashed rgba(255,255,255,.08);
  border-radius: inherit;
}
.ph-empty svg { width: 26px; height: 26px; opacity: .7; }
.ph-label { font-size: 12px; font-weight: 500; color: var(--muted); }
.ph-file { font-size: 10.5px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; color: var(--faint); word-break: break-all; }
.ph.loaded .ph-empty, .ph.has-preview .ph-empty { display: none; }
.ph.has-preview { background-size: cover; background-position: center; }
.ph-cap {
  position: absolute; left: 10px; bottom: 10px; z-index: 1;
  font-size: 11.5px; font-weight: 500; padding: 5px 10px; border-radius: 999px;
  background: rgba(12,12,11,.6); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.ph.missing .ph-cap { display: none; }
.gallery .ph-cap { max-width: calc(100% - 20px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

button.tile { cursor: default; }
button.tile.loaded { cursor: zoom-in; }
button.tile.loaded:hover img { transform: scale(1.04); }

.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); }
.gallery-wide { grid-template-columns: repeat(2, 1fr); }
.gallery-wide .ph { aspect-ratio: 4 / 3; }
.gallery-plans { grid-template-columns: repeat(2, 1fr); }
.gallery-plans .ph { aspect-ratio: 4 / 3; background: #fff; }
.gallery-plans .ph img { object-fit: contain; }
.gallery-plans button.tile.loaded:hover img { transform: scale(1.02); }
.gallery-plans .ph-cap { background: rgba(12,12,11,.78); }

/* Floor plans: standard (included) and Lux (upgrade) tiers */
/* Both tiers get the same divider and spacing */
.plan-tier { margin-top: var(--section); padding-top: 28px; border-top: 1px solid var(--line); }
.plan-tier:first-of-type { margin-top: 0; }
.plan-tier-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 16px; }
.plan-tier-head p { margin-top: 8px; color: var(--muted); max-width: 46em; }
.badge-upgrade { background: var(--gold); color: #15130f; }
.plans-standard .gallery-plans,
.plans-lux .gallery-plans { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; }
.incl-plan { background: #fff; }
.incl-plan img { object-fit: contain; padding: 6px; }

/* ---------- Home ---------- */
.hero {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg); overflow: hidden;
}
/* Layered photo: photo → agency name → cut-out house in front */
.stage { position: relative; aspect-ratio: 1942 / 809; overflow: hidden; background: var(--surface); isolation: isolate; }
.stage-photo, .stage-house {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: var(--pos-x, 50%) 50%;
}
.stage-house { z-index: 2; pointer-events: none; }
/* Moved by the scroll parallax in app.js (photo and house always move together) */
.stage-photo, .stage-house { transform-origin: 50% 100%; will-change: transform; }
.stage-name {
  position: absolute; z-index: 1; left: 0; right: 0; bottom: 47%;
  display: flex; justify-content: center;
  pointer-events: none; user-select: none;
  will-change: transform;
}
.stage-name span {
  font-family: "Anton", "Impact", "Arial Narrow", sans-serif;
  text-transform: uppercase; line-height: .8; letter-spacing: .005em; white-space: nowrap;
  /* The gradient only paints inside this box, and the tight line-height would
     slice off the tops of the letters, so pad it out (and pull it back) */
  padding: .16em .04em .06em; margin: -.16em -.04em -.06em;
  color: #f4f1ea;
  opacity: 0; transform: translateY(6%);
  /* Solid white at the top, turning see-through towards the bottom so the
     sky shows through and the letters melt into the scene */
  background: linear-gradient(180deg, rgba(255,255,255,1) 0%, rgba(255,255,255,.96) 35%, rgba(255,255,255,.72) 70%, rgba(255,255,255,.38) 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  transition: opacity .9s var(--ease), transform 1.1s var(--ease);
}
.stage-name.fitted span { opacity: 1; transform: none; }
.stage-shade {
  position: absolute; inset: auto 0 -2px 0; height: 46%; z-index: 3; pointer-events: none;
  background: linear-gradient(to bottom,
    transparent 0%,
    color-mix(in srgb, var(--surface) 30%, transparent) 30%,
    color-mix(in srgb, var(--surface) 82%, transparent) 62%,
    var(--surface) 86%);
}
.stage-pill {
  position: absolute; z-index: 4; top: clamp(14px, 2vw, 22px); left: clamp(14px, 2vw, 22px);
  display: inline-flex; align-items: center; gap: 10px;
  padding: 6px 16px 6px 6px; border-radius: 999px;
  font-size: 13.5px; font-weight: 500; color: #fff;
  background: rgba(18, 17, 15, .32);
  border: 1px solid rgba(255, 255, 255, .2);
  -webkit-backdrop-filter: blur(16px) saturate(1.3); backdrop-filter: blur(16px) saturate(1.3);
  box-shadow: 0 8px 30px rgba(0, 0, 0, .18);
}
.pill-avatar { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--gold); color: #15130f; font-weight: 600; font-size: 13px; }
.pill-dot { width: 8px; height: 8px; margin: 0 2px 0 8px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 4px rgba(201, 164, 106, .25); }
.pill-sep { width: 1px; height: 14px; background: rgba(255, 255, 255, .35); }
.pill-hi { font-weight: 600; }
.pill-logo { display: inline-flex; align-items: center; height: 26px; margin-right: -4px; padding: 4px 9px; border-radius: 999px; background: #f4f1ea; }
.pill-logo.dark { background: rgba(0, 0, 0, .45); }
.pill-logo img { height: 18px; width: auto; max-width: 96px; object-fit: contain; display: block; }
.pill-logo.square { padding: 2px; border-radius: 7px; }
.pill-logo.square img { height: 22px; border-radius: 5px; }
@media (prefers-reduced-motion: reduce) {
  .tour-pano, .tour-start-ring::after { animation: none; } .stage-name span { transition: none; transform: none; } }

.hero-body {
  position: relative; z-index: 4; margin-top: clamp(-64px, -4.4vw, -32px);
  padding: 0 clamp(28px, 4vw, 52px) clamp(28px, 4vw, 44px);
  display: grid; grid-template-columns: 1.1fr 1fr; gap: 20px 48px; align-items: end;
}
.hero-title { font-family: var(--serif); font-weight: 400; font-size: clamp(2.4rem, 4.4vw, 3.8rem); line-height: .98; letter-spacing: -.015em; margin-top: 14px; overflow-wrap: anywhere; }
.hero-title em { color: var(--gold); }
.hero-text { margin-top: 18px; color: var(--muted); font-size: 16px; max-width: 30em; }
.hero-text strong { color: var(--text); font-weight: 500; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }

.incl-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: var(--gap); }
.incl-card {
  display: flex; flex-direction: column;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
  overflow: hidden;
  transition: border-color .2s, transform .25s var(--ease);
}
.incl-card:hover { border-color: var(--line-2); transform: translateY(-2px); }
.incl-img { aspect-ratio: 4 / 3; border-radius: 0; }
.incl-img .ph-empty { border: 0; }
.incl-body { display: flex; gap: 10px; align-items: flex-start; padding: 14px 14px 16px; position: relative; flex: 1; }
.incl-check { width: 22px; height: 22px; border-radius: 50%; background: var(--gold); color: #15130f; display: grid; place-items: center; flex: none; margin-top: 1px; }
.incl-check svg { width: 13px; height: 13px; }
.incl-body h3 { font-size: 15px; font-weight: 600; line-height: 1.3; }
.incl-body p { font-size: 13px; color: var(--muted); margin-top: 4px; line-height: 1.45; }
.incl-chev { display: none; }

/* Home: optional extras */
.extra-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }
.extra-card {
  display: flex; flex-direction: column; gap: 14px; padding: 22px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
  transition: border-color .2s, transform .25s var(--ease);
}
.extra-card:hover { border-color: rgba(201,164,106,.5); transform: translateY(-2px); }
.extra-icon { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; color: var(--gold); background: rgba(201,164,106,.12); border: 1px solid rgba(201,164,106,.3); }
.extra-icon svg { width: 22px; height: 22px; }
.extra-text h3 { font-size: 16px; font-weight: 600; }
.extra-text p { font-size: 13.5px; color: var(--muted); margin-top: 4px; line-height: 1.5; }
.extra-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: auto; padding-top: 14px; border-top: 1px solid var(--line); }
.extra-foot strong { font-family: var(--serif); font-weight: 400; font-size: 1.6rem; line-height: 1; white-space: nowrap; }
.extra-link { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 600; color: var(--gold); white-space: nowrap; }
.extra-link svg { width: 15px; height: 15px; }

.trial {
  margin-top: var(--section);
  display: grid; grid-template-columns: 1fr 1.4fr auto; gap: 28px; align-items: center;
  padding: clamp(24px, 3vw, 36px);
  border-radius: var(--r-lg);
  background:
    radial-gradient(90% 140% at 0% 0%, rgba(201,164,106,.16), transparent 55%),
    var(--surface);
  border: 1px solid rgba(201,164,106,.25);
}
.trial-head h2 { margin-top: 8px; }
.trial-head h2 em { color: var(--gold); }
.trial-head p:last-child { color: var(--muted); margin-top: 8px; font-size: 14px; }
.trial-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; counter-reset: s; }
.trial-steps li { counter-increment: s; display: flex; flex-direction: column; gap: 2px; padding-left: 40px; position: relative; }
.trial-steps li::before {
  content: counter(s); position: absolute; left: 0; top: 0;
  width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--gold); color: var(--gold);
  display: grid; place-items: center; font-family: var(--serif); font-size: 16px;
}
.trial-steps strong { font-size: 14px; font-weight: 600; }
.trial-steps span { font-size: 12.5px; color: var(--muted); }

/* ---------- Services ---------- */
.subtabs-wrap {
  position: sticky; top: calc(var(--top-h) + env(safe-area-inset-top)); z-index: 20;
  background: rgba(12,12,11,.86);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
  margin: -28px 0 28px;
}
.subtabs {
  max-width: var(--max); margin: 0 auto; padding: 12px var(--pad);
  display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none;
}
.subtabs::-webkit-scrollbar { display: none; }
.subtabs a {
  flex: none; height: 38px; padding: 0 16px; border-radius: 999px;
  display: inline-flex; align-items: center;
  font-size: 13.5px; font-weight: 500; color: var(--muted);
  border: 1px solid var(--line);
  transition: all .2s;
}
.subtabs a:hover { color: var(--text); border-color: var(--line-2); }
.subtabs a.active { background: var(--text); color: var(--bg); border-color: var(--text); }

/* Before/after slider */
.compare-after .ph-empty { padding-left: 50%; }
.compare-before .ph-empty { padding-right: 50%; }
.compare {
  position: relative; aspect-ratio: 3 / 2; border-radius: var(--r-lg); overflow: hidden;
  user-select: none; -webkit-user-select: none; touch-action: pan-y; cursor: ew-resize;
  background: var(--surface-2);
}
.compare-layer { position: absolute; inset: 0; }
.compare-layer .ph { height: 100%; aspect-ratio: auto; border-radius: 0; }
.compare-before { clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.compare-before .ph-empty { background: repeating-linear-gradient(135deg, rgba(255,255,255,.03) 0 12px, transparent 12px 24px), #24221e; }
.compare img { -webkit-user-drag: none; user-select: none; -webkit-user-select: none; pointer-events: none; }
.compare { -webkit-tap-highlight-color: transparent; -webkit-touch-callout: none; }
/* Clicks/taps glide to the spot; dragging follows the pointer exactly */
.compare.glide .compare-before { transition: clip-path .35s var(--ease); }
.compare.glide .compare-handle { transition: left .35s var(--ease); }
/* The "it moves" hint sweep after the photos load */
.compare.sweep .compare-before { transition: clip-path .45s cubic-bezier(.45,0,.2,1); }
.compare.sweep .compare-handle { transition: left .45s cubic-bezier(.45,0,.2,1); }
/* Soft pulse on the handle until it's first used */
.compare-knob::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(255,255,255,.55); opacity: 0;
}
.compare.hint-pulse .compare-knob::after { animation: knob-pulse 2s 1.4s ease-out infinite; }
@keyframes knob-pulse { 0% { opacity: 1; box-shadow: 0 0 0 0 rgba(255,255,255,.55); } 80%, 100% { opacity: 0; box-shadow: 0 0 0 16px rgba(255,255,255,0); } }
.compare-handle {
  position: absolute; top: 0; bottom: 0; left: var(--pos); width: 2px; margin-left: -1px;
  background: #fff; box-shadow: 0 0 12px rgba(0,0,0,.4); pointer-events: none;
}
.compare-knob {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: 46px; height: 46px; border-radius: 50%;
  background: #fff; color: #15130f;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 24px rgba(0,0,0,.35);
  transition: transform .2s var(--ease);
}
.compare.dragging .compare-knob { transform: translate(-50%, -50%) scale(1.08); }
.compare-knob svg { width: 16px; height: 16px; margin: 0 -2px; }
.compare-tag {
  position: absolute; top: 14px; z-index: 2; pointer-events: none;
  font-size: 11px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
  padding: 6px 11px; border-radius: 999px; background: rgba(12,12,11,.65);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.tag-before { left: 14px; }
.tag-after { right: 14px; background: var(--gold); color: #15130f; }
.compare input[type="range"] {
  position: absolute; inset: auto 0 0 0; width: 100%; height: 100%; opacity: 0; margin: 0;
  pointer-events: none; /* pointer handled by JS; range kept for keyboard & screen readers */
}
.compare input[type="range"]:focus-visible + * , .compare:focus-within { outline: 2px solid var(--gold); outline-offset: 3px; }
.hint { font-size: 12.5px; color: var(--faint); margin: 10px 0 18px; }

/* Declutter: one big slider, centred and sized to fit the screen, with a
   strip of every room's photo underneath (a swipe strip on phones). */
.declutter { width: min(100%, clamp(560px, calc((100vh - 280px) * 1.5), 1136px)); margin: 0 auto; }
.declutter .hint { text-align: center; margin: 12px 0 16px; }
.pair-thumbs { display: grid; grid-template-columns: repeat(var(--n, 5), minmax(0, 1fr)); gap: var(--gap); }
.pair-thumb { text-align: left; opacity: .55; transition: opacity .2s; }
.pair-thumb:hover { opacity: .85; }
.pair-thumb.active { opacity: 1; }
.pair-thumb .ph { outline: 2px solid transparent; outline-offset: 2px; transition: outline-color .2s; }
.pair-thumb.active .ph { outline-color: var(--gold); }
.pair-thumb .ph-empty svg { width: 18px; height: 18px; }
.pair-thumb .ph-file { display: none; }
.pair-thumb > span { display: block; margin-top: 8px; font-size: 13px; font-weight: 500; color: var(--muted); }
.pair-thumb.active > span { color: var(--text); }

.chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 16px 16px; }

.back { display: inline-flex; align-items: center; gap: 4px; font-size: 13.5px; color: var(--muted); margin-bottom: 14px; margin-left: -4px; }
.back svg { width: 18px; height: 18px; }
.back:hover { color: var(--text); }
.jump {
  position: sticky; top: calc(var(--top-h) + env(safe-area-inset-top)); z-index: 10;
  display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none;
  padding: 12px 0; margin-bottom: 8px;
  background: linear-gradient(var(--bg) 75%, transparent);
}
.jump::-webkit-scrollbar { display: none; }
.video-box { position: relative; aspect-ratio: 16 / 9; border-radius: var(--r); overflow: hidden; background: var(--surface-2); max-width: 980px; }
.video-box iframe, .video-box video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; border: 1px dashed rgba(255,255,255,.08); }
.play-dot { width: 64px; height: 64px; border-radius: 50%; background: rgba(255,255,255,.08); display: grid; place-items: center; color: var(--muted); }
.play-dot svg { width: 26px; height: 26px; margin-left: 3px; }

/* Video tab: cover image with a play button; the Vimeo player loads on tap */
/* Vertical videos: three across on desktop, a swipe row on phones */
.video-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); align-items: start; }
.video-box.portrait { max-width: 360px; }
.video-grid .video-box { max-width: none; border-radius: var(--r-lg); }
/* 360° tours: one big tour per row, with a full screen button */
.tour-tips { list-style: none; margin: -6px 0 8px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.tour-tips li {
  display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 14px 0 11px;
  border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 13px; color: var(--muted);
}
.tour-tips svg { width: 16px; height: 16px; color: var(--gold); }
.tour-item { padding-top: 34px; }
.tour-item + .tour-item { margin-top: 22px; border-top: 1px solid var(--line); }
.tour-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.tour-head h2 { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.tour-head h2 span { font-family: var(--sans); font-size: 14px; color: var(--muted); }
.tour-fs { gap: 8px; flex: none; }
.tour-fs svg { width: 16px; height: 16px; }
.tour-frame {
  position: relative; overflow: hidden; border-radius: var(--r-lg); background: #000;
  height: clamp(460px, calc(100dvh - 260px), 760px);
  border: 1px solid var(--line);
}
.tour-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* Tour cover: wide panorama drifting side to side, gold "Step inside" button */
.tour-cover { isolation: isolate; cursor: pointer; }
.tour-pano {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%;
  opacity: 0; transform: scale(1.04); transition: opacity .6s ease, transform 1.2s var(--ease);
  animation: pano-drift 38s ease-in-out infinite alternate;
}
.tour-cover.has-cover .tour-pano { opacity: 1; transform: none; }
@keyframes pano-drift { from { object-position: var(--from, 25%) 50%; } to { object-position: var(--to, 75%) 50%; } }
.tour-pano-empty { position: absolute; inset: 0; background: radial-gradient(circle at 50% 40%, #2a251d, #0b0a08); }
.tour-shade {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(circle at center, rgba(8,7,5,.55) 0, rgba(8,7,5,.3) 160px, rgba(8,7,5,0) 300px),
    radial-gradient(ellipse at center, rgba(0,0,0,.05) 0%, rgba(0,0,0,.35) 70%),
    linear-gradient(to top, rgba(8,7,5,.8), rgba(8,7,5,0) 45%);
}
.tour-start {
  position: absolute; inset: 0; z-index: 2; width: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px;
  color: #fff; text-align: center;
}
.tour-start-ring {
  position: relative; width: 88px; height: 88px; border-radius: 50%;
  display: grid; place-items: center; background: var(--gold); color: #15130f;
  box-shadow: 0 12px 44px rgba(0,0,0,.45); transition: transform .25s ease;
}
.tour-start-ring svg { width: 40px; height: 40px; }
.tour-start-ring::after {
  content: ""; position: absolute; inset: -8px; border-radius: 50%;
  border: 1.5px solid rgba(201,164,106,.7); animation: tour-ring 2.4s ease-out infinite;
}
@keyframes tour-ring { 0% { transform: scale(.9); opacity: .9; } 100% { transform: scale(1.35); opacity: 0; } }
.tour-start:hover .tour-start-ring { transform: scale(1.06); }
.tour-start-text { display: grid; gap: 4px; text-shadow: 0 2px 16px rgba(0,0,0,.6); }
.tour-start-text strong { font-family: var(--serif); font-weight: 400; font-size: 30px; line-height: 1.1; }
.tour-start-text small { font-size: 13.5px; color: rgba(255,255,255,.8); }
.tour-chip {
  position: absolute; left: 16px; bottom: 16px; z-index: 2; pointer-events: none;
  display: inline-flex; align-items: center; gap: 7px; height: 32px; padding: 0 13px 0 10px; border-radius: 999px;
  font-size: 12.5px; font-weight: 600; color: #fff; background: rgba(0,0,0,.5); border: 1px solid rgba(255,255,255,.14);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.tour-chip svg { width: 16px; height: 16px; color: var(--gold); }
/* Once tapped: the tour fades in over the cover */
.tour-cover iframe { z-index: 3; opacity: 0; transition: opacity .5s ease; }
.tour-cover.loaded iframe { opacity: 1; }
.tour-cover.started { cursor: default; }
.tour-cover.started .tour-start { pointer-events: none; }
.tour-cover.started .tour-start-ring::after { animation: none; }
.tour-cover.started .tour-start-text small { visibility: hidden; }
.tour-cover.started .tour-start-text small::after { content: "Loading…"; visibility: visible; display: block; }

/* Full-screen tour viewer */
.tour-viewer[open] {
  width: 100vw; height: 100vh; height: 100dvh; max-width: none; max-height: none;
  display: grid; grid-template-rows: auto 1fr; background: #050505;
  animation: fade .2s var(--ease); overflow: hidden;
}
.tour-viewer::backdrop { background: #050505; }
.tv-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: calc(10px + env(safe-area-inset-top)) 16px 10px 20px;
}
.tv-bar p { display: flex; align-items: baseline; gap: 10px; min-width: 0; font-family: var(--serif); font-size: 21px; }
.tv-bar p svg { width: 20px; height: 20px; color: var(--gold); align-self: center; flex: none; }
.tv-bar p span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tv-bar p small { font-family: var(--sans); font-size: 13px; color: var(--muted); white-space: nowrap; }
.tv-stage { position: relative; margin: 0 12px 12px; border-radius: 12px; overflow: hidden; background: #000; margin-bottom: calc(12px + env(safe-area-inset-bottom)); }
.tv-stage iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-facade { cursor: pointer; isolation: isolate; }
.video-facade img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .4s, transform .6s ease; }
.video-facade.has-cover img { opacity: 1; }
.video-facade:hover img { transform: scale(1.03); }
.video-shade { position: absolute; inset: 0; background: radial-gradient(circle at center, rgba(0,0,0,.05), rgba(0,0,0,.45)); pointer-events: none; }
.video-play {
  position: absolute; left: 50%; top: 50%; width: 76px; height: 76px; margin: -38px 0 0 -38px;
  border-radius: 50%; display: grid; place-items: center;
  background: var(--gold); color: #15130f; box-shadow: 0 10px 40px rgba(0,0,0,.45);
  transition: transform .25s ease;
}
.video-play svg { width: 30px; height: 30px; margin-left: 4px; }
.video-facade:hover .video-play { transform: scale(1.08); }
.video-time {
  position: absolute; right: 14px; bottom: 14px; padding: 4px 9px; border-radius: 999px;
  font-size: 12px; font-weight: 600; color: #fff; background: rgba(0,0,0,.6);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.video-time:empty { display: none; }
  margin-top: var(--section); display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap;
  padding: clamp(20px, 2.6vw, 28px); border-radius: var(--r-lg);
  background: radial-gradient(90% 140% at 0% 0%, rgba(201,164,106,.16), transparent 55%), var(--surface);
  border: 1px solid rgba(201,164,106,.25);
}

/* ---------- Pricing ---------- */
.free-banner {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding: 16px 16px 16px 22px; border-radius: var(--r);
  background: var(--gold); color: #15130f; margin-bottom: 24px;
}
.free-banner strong { font-weight: 700; }
.free-banner span { font-size: 14px; }

.tiers { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: var(--gap); }
.tier {
  position: relative; display: flex; flex-direction: column; padding: 26px 24px 24px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
}
.tier-flag {
  position: absolute; top: -11px; left: 24px;
  font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 999px; background: var(--gold); color: #15130f;
}
.tier h3 { font-size: 17px; font-weight: 600; line-height: 1.35; min-height: 2.7em; }
.tier-price { font-family: var(--serif); font-size: 3rem; line-height: 1; margin-top: 14px; }
.vat { font-family: var(--sans); font-size: 13px; font-weight: 500; color: var(--muted); margin-left: 6px; letter-spacing: 0; }
.tier-epc .vat { font-size: 12px; font-weight: 500; margin-left: 4px; }
.price-head .vat-note { color: var(--text); font-weight: 500; }
.tier-body { flex: 1; margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--line); }
/* "Add an EPC +£60" strip at the foot of each package */
.tier-epc {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin-top: 20px; padding: 11px 14px; border-radius: var(--r-sm);
  background: rgba(201,164,106,.14); border: 1px solid rgba(201,164,106,.4);
  font-size: 13.5px; font-weight: 600; color: var(--text);
}
.tier-epc b { font-size: 15px; font-weight: 700; color: var(--gold); white-space: nowrap; }
.tier-plus { font-size: 13px; color: var(--muted); margin-bottom: 10px; }
.tier-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.tier-list li { display: flex; align-items: center; gap: 9px; font-size: 13.5px; }
.tier-list svg { width: 16px; height: 16px; color: var(--gold); flex: none; }

.price-section + .price-section { margin-top: var(--section); }
.price-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px 20px; flex-wrap: wrap; margin-bottom: 20px; }
.price-head p { font-size: 13.5px; color: var(--muted); }

/* Build your own (price builder) */
.pb-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: var(--gap); align-items: start; }
.pb-main { display: grid; gap: 22px; padding: 24px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); }
.pb-groups { display: grid; gap: 20px; }
.pb-group h3 { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); margin-bottom: 10px; }
.pb-opts { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 8px; }
.pb-opt {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 10px;
  min-height: 52px; padding: 10px 14px 10px 12px; border-radius: var(--r-sm); text-align: left;
  background: var(--surface-2); border: 1px solid var(--line-2); color: var(--text);
  transition: border-color .2s, background-color .2s;
}
.pb-opt:hover { border-color: rgba(201,164,106,.5); }
.pb-check { width: 22px; height: 22px; border-radius: 7px; display: grid; place-items: center; border: 1.5px solid var(--line-2); color: transparent; transition: background-color .2s, border-color .2s, color .2s; }
.pb-check svg { width: 14px; height: 14px; }
.pb-name { font-size: 14px; font-weight: 600; line-height: 1.25; }
.pb-price { font-size: 13.5px; font-weight: 600; color: var(--muted); white-space: nowrap; }
.pb-opt[aria-pressed="true"] { border-color: var(--gold); background: linear-gradient(180deg, rgba(201,164,106,.14), rgba(201,164,106,.06)), var(--surface-2); }
.pb-opt[aria-pressed="true"] .pb-check { background: var(--gold); border-color: var(--gold); color: #15130f; }
.pb-opt[aria-pressed="true"] .pb-price { color: var(--gold-2); }
.pb-opt.covered { cursor: default; opacity: .75; border-style: dashed; }
.pb-opt.covered .pb-price { font-size: 12px; font-weight: 500; color: var(--muted); }
.pb-rows { display: flex; flex-wrap: wrap; gap: 14px 28px; padding-top: 20px; border-top: 1px solid var(--line); }
.pb-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.pb-label { font-size: 14px; font-weight: 600; }
.pb-size button { height: 36px; padding: 0 14px; font-size: 13px; }
.pb-stepper { display: inline-flex; align-items: center; gap: 4px; padding: 4px; border-radius: 999px; background: rgba(0,0,0,.35); border: 1px solid var(--line); }
.pb-stepper button { width: 34px; height: 34px; border-radius: 50%; font-size: 18px; color: var(--text); background: var(--surface-3); }
.pb-stepper button:hover { background: var(--gold); color: #15130f; }
.pb-count { min-width: 34px; text-align: center; font-weight: 600; font-variant-numeric: tabular-nums; }
.pb-summary {
  position: sticky; top: calc(var(--top-h) + 16px); display: grid; gap: 12px; padding: 24px; border-radius: var(--r);
  background: radial-gradient(120% 90% at 100% 0%, rgba(201,164,106,.16), transparent 60%), var(--surface);
  border: 1px solid rgba(201,164,106,.45);
}
.pb-kicker { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--gold); }
.pb-total { font-family: var(--serif); font-size: 3.4rem; line-height: 1; margin-top: -4px; }
.pb-lines { list-style: none; margin: 4px 0 0; padding: 12px 0 0; border-top: 1px solid var(--line); display: grid; gap: 8px; }
.pb-lines li { display: flex; justify-content: space-between; gap: 12px; font-size: 13.5px; color: var(--muted); }
.pb-lines b { color: var(--text); font-weight: 600; white-space: nowrap; }
.pb-empty { color: var(--faint) !important; }
.pb-save { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--gold-2); }
.pb-save svg { width: 16px; height: 16px; flex: none; }
.pb-month { font-size: 13.5px; color: var(--muted); padding-top: 12px; border-top: 1px solid var(--line); }
.pb-month b { color: var(--text); }
.pb-summary .btn { margin-top: 4px; }
.pb-summary .btn:disabled { opacity: .45; pointer-events: none; }
.pb-free { font-size: 12.5px; color: var(--muted); text-align: center; }
.pb-mini { display: none; }

/* The builder's pick, shown in the booking form */
.form-pick { display: flex; align-items: flex-start; gap: 10px; margin: -4px 0 16px; padding: 11px 12px 11px 14px; border-radius: var(--r-sm); background: rgba(201,164,106,.12); border: 1px solid rgba(201,164,106,.4); font-size: 13.5px; line-height: 1.45; }
.form-pick small { display: block; font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--gold); margin-bottom: 2px; }
.form-pick span { flex: 1; }
.form-pick-x { flex: none; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; color: var(--muted); }
.form-pick-x:hover { color: var(--text); background: rgba(255,255,255,.08); }
.form-pick-x svg { width: 14px; height: 14px; }

/* Property size switch above the packages */
.size-panel {
  display: flex; align-items: center; gap: 12px 20px; flex-wrap: wrap;
  margin-bottom: 28px; padding: 16px 18px 16px 22px; border-radius: var(--r);
  border: 1px solid rgba(201,164,106,.5);
  background: linear-gradient(90deg, rgba(201,164,106,.12), rgba(201,164,106,.03)), var(--surface);
}
.size-q { font-size: 16px; font-weight: 600; }
.size-switch { display: inline-flex; padding: 4px; gap: 4px; border-radius: 999px; background: rgba(0,0,0,.35); border: 1px solid var(--line); }
.size-switch button {
  height: 40px; padding: 0 18px; border-radius: 999px;
  font-size: 14px; font-weight: 500; color: var(--muted); white-space: nowrap;
  transition: background-color .2s, color .2s;
}
.size-switch button:hover { color: var(--text); }
.size-switch button[aria-checked="true"] { background: var(--gold); color: #15130f; font-weight: 600; }
.size-over { font-size: 13px; color: var(--muted); margin-left: auto; }
.tier-amount { display: inline-block; }

/* Photos & floor plan: "Need an EPC too?" with a hand-drawn arrow */
.epc-callout {
  display: flex; align-items: flex-end; justify-content: flex-end; gap: 2px;
  margin: 16px 22px -4px 0; color: var(--gold); pointer-events: none; position: relative; z-index: 1;
}
.epc-callout span { font-family: var(--serif); font-style: italic; font-size: 21px; line-height: 1; margin-bottom: 40px; }
.epc-arrow { width: 76px; height: 54px; flex: none; overflow: visible; }
.epc-arrow path { fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; stroke-dashoffset: 1; }
.epc-callout.drawn .epc-arrow path:first-child { transition: stroke-dashoffset .7s ease-out .15s; stroke-dashoffset: 0; }
.epc-callout.drawn .epc-arrow path:last-child { transition: stroke-dashoffset .25s ease-out .8s; stroke-dashoffset: 0; }
.tier-epc.hot { background: var(--gold); border-color: var(--gold); color: #15130f; box-shadow: 0 6px 24px rgba(201,164,106,.25); }
.tier-epc.hot b, .tier-epc.hot .vat { color: #15130f; }
.tier-epc.hot .vat { opacity: .7; }
.epc-callout + .tier-epc { margin-top: 0; }

/* All services: a simple menu */
.price-groups { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); align-items: start; }
.price-group { padding: 22px 24px 8px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); }
.price-group h3 { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--gold); margin-bottom: 4px; }
.price-list { list-style: none; margin: 0; padding: 0; }
.price-list li { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 0; }
.price-list li + li { border-top: 1px solid var(--line); }
.price-list strong { display: block; font-size: 15px; font-weight: 600; }
.price-list span { display: block; font-size: 13px; color: var(--muted); margin-top: 2px; }
.price-list b { font-family: var(--serif); font-size: 1.6rem; font-weight: 400; white-space: nowrap; }

/* ---------- Book menu ---------- */
.scrim { position: fixed; inset: 0; z-index: 40; background: rgba(0,0,0,0); transition: background-color .25s; }
.scrim.open { background: rgba(0,0,0,.35); }
.book-menu {
  position: fixed; z-index: 45;
  top: calc(var(--top-h) + env(safe-area-inset-top) - 4px);
  right: max(var(--pad), calc((100vw - var(--max)) / 2 + var(--pad)));
  width: 340px; padding: 14px;
  background: var(--surface-2); border: 1px solid var(--line-2); border-radius: var(--r-lg);
  box-shadow: 0 24px 60px rgba(0,0,0,.55);
  opacity: 0; transform: translateY(-6px) scale(.98); transform-origin: top right;
  transition: opacity .2s var(--ease), transform .25s var(--ease);
}
.book-menu.open { opacity: 1; transform: none; }
.sheet-handle { display: none; }
.book-menu-title { font-weight: 600; font-size: 15px; padding: 4px 6px 0; }
.book-menu-sub { font-size: 12.5px; color: var(--muted); padding: 2px 6px 10px; }
.book-opt {
  display: flex; align-items: center; gap: 12px; width: 100%; text-align: left;
  padding: 10px; border-radius: 12px; transition: background-color .15s;
}
.book-opt:hover, .book-opt:focus-visible { background: rgba(255,255,255,.06); outline: none; }
.book-opt > span:nth-child(2) { flex: 1; display: flex; flex-direction: column; }
.book-opt strong { font-size: 14.5px; font-weight: 600; }
.book-opt small { font-size: 12.5px; color: var(--muted); }
.book-opt-icon { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-3); color: var(--gold); flex: none; }
.book-opt-icon.wa { color: var(--wa); }
.book-opt .chev { width: 16px; height: 16px; color: var(--faint); }
.book-opt.unset { opacity: .55; cursor: not-allowed; }

/* ---------- Form dialog ---------- */
dialog { color: var(--text); border: 0; padding: 0; background: transparent; max-width: none; max-height: none; }
dialog::backdrop { background: rgba(0,0,0,.6); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.form-dialog[open] {
  width: min(560px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); overflow: auto;
  background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--r-lg);
  padding: 28px; animation: pop .25s var(--ease);
}
@keyframes pop { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }
.dialog-close { position: absolute; top: 16px; right: 16px; width: 36px; height: 36px; }
.dialog-close svg { width: 18px; height: 18px; }
.form-dialog h2 { font-family: var(--serif); font-weight: 400; font-size: 2rem; line-height: 1.05; padding-right: 40px; }
.form-intro { color: var(--muted); font-size: 14px; margin: 6px 0 20px; }
#book-form { display: grid; gap: 14px; }
#book-form h2, #book-form .form-intro { margin-bottom: 0; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field { display: grid; gap: 6px; min-width: 0; }
.field > span { font-size: 12.5px; font-weight: 500; color: var(--muted); }
.field small { color: var(--faint); font-weight: 400; }
.field input, .field textarea {
  width: 100%; font: inherit; font-size: 16px; color: var(--text);
  background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r-sm);
  padding: 12px 14px; transition: border-color .2s, box-shadow .2s;
  -webkit-appearance: none; appearance: none; color-scheme: dark;
}
.field textarea { resize: vertical; min-height: 70px; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(201,164,106,.18); }
.field input.invalid { border-color: #d0694f; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { font-size: 13px; color: var(--muted); text-align: center; }
.form-status:empty { display: none; }
.form-status.error { color: #e08a72; }
.form-done { text-align: center; display: grid; justify-items: center; gap: 10px; padding: 20px 0 6px; }
.form-done p { color: var(--muted); max-width: 26em; }
.form-done .btn { margin-top: 10px; }
.done-mark { width: 60px; height: 60px; border-radius: 50%; background: var(--gold); color: #15130f; display: grid; place-items: center; }
.done-mark svg { width: 28px; height: 28px; }

/* ---------- Video viewer ---------- */
.video-viewer[open] {
  width: 100vw; height: 100vh; height: 100dvh;
  display: grid; grid-template-columns: auto 1fr auto; align-items: center;
  animation: fade .2s var(--ease); overflow: hidden;
}
.video-viewer::backdrop { background: rgba(5,5,5,.96); }
.video-viewer figure { margin: 0; min-width: 0; display: grid; justify-items: center; gap: 12px; padding: 48px 0; }
.vv-stage {
  position: relative; overflow: hidden; border-radius: 12px; background: #000;
  aspect-ratio: var(--ar, .5625);
  width: min(100%, calc((100dvh - 124px) * var(--ar, .5625)));
}
.vv-stage iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-viewer figcaption { font-size: 13px; color: var(--muted); }

/* ---------- Lightbox ---------- */
.lightbox[open] {
  width: 100vw; height: 100vh; height: 100dvh;
  display: grid; grid-template-columns: auto 1fr auto; align-items: center;
  animation: fade .2s var(--ease);
}
.lightbox::backdrop { background: rgba(5,5,5,.96); }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.lightbox figure { margin: 0; min-width: 0; display: grid; justify-items: center; gap: 12px; padding: 48px 0; }
/* One fixed 3:2 frame for every photo, so they all open at the same size */
.lb-frame {
  position: relative; overflow: hidden; border-radius: 6px;
  /* Capped at 1360px: big, while staying close enough to the photos' 2000px
     that they don't look stretched on a large retina screen */
  width: min(100%, 1360px, calc((100dvh - 124px) * 1.5)); aspect-ratio: 3 / 2;
  background: #141413 center / cover no-repeat;
}
.lb-frame img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .25s var(--ease); }
.lb-frame img.ready { opacity: 1; }
.lightbox.fit-contain .lb-frame { background-color: #f4f2ee; background-size: contain; }
.lightbox.fit-contain .lb-frame img { object-fit: contain; }
/* Floor plans: frame in the plan's own shape, white, click to zoom */
.lightbox.fit-plan .lb-frame {
  aspect-ratio: var(--ar, 1.5);
  width: min(100%, 1360px, calc((100dvh - 124px) * var(--ar, 1.5)));
  background-color: #fff; background-size: contain; cursor: zoom-in;
}
.lightbox.fit-plan .lb-frame img { object-fit: contain; transition: opacity .25s var(--ease), transform .35s var(--ease); }
.lightbox.zoomed .lb-frame { cursor: zoom-out; touch-action: none; }
.lightbox.zoomed .lb-frame img { transform: scale(2.6); transition: opacity .25s var(--ease), transform .35s var(--ease), transform-origin .12s linear; }
.lightbox figcaption { font-size: 13px; color: var(--muted); }
/* Swiping between photos: the next photo slides in beside the current one */
.lightbox[open] { overflow: hidden; }
.lightbox figure { position: relative; }
.lb-frame { will-change: transform; }
.lb-ghost { position: absolute; margin: 0; pointer-events: none; aspect-ratio: auto; background-size: cover; background-position: center; }
.lightbox.fit-contain .lb-ghost, .lightbox.fit-plan .lb-ghost { background-size: contain; }
.lb-close { z-index: 3; }
.lb-nav { position: relative; z-index: 3; }
.lb-close { position: absolute; top: calc(14px + env(safe-area-inset-top)); right: 16px; z-index: 2; }
.lb-nav { margin: 0 16px; width: 48px; height: 48px; }
.lightbox.single .lb-nav { visibility: hidden; }

/* ---------- "View all photos" tile & overlay ---------- */
button.tile-more { cursor: pointer; }
.more-veil {
  position: absolute; inset: 0; z-index: 2;
  display: grid; place-content: center; justify-items: center; gap: 6px;
  background: linear-gradient(180deg, rgba(12,12,11,.45), rgba(12,12,11,.7));
  backdrop-filter: blur(5px) saturate(.9); -webkit-backdrop-filter: blur(5px) saturate(.9);
  transition: background .35s var(--ease), backdrop-filter .35s var(--ease);
}
.more-count { font-family: var(--serif); font-size: clamp(38px, 4.4vw, 58px); line-height: .9; color: var(--text); transition: transform .45s var(--ease); }
.more-label {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 11.5px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--gold);
}
.more-label svg { width: 14px; height: 14px; transition: transform .35s var(--ease); }
button.tile-more:hover .more-veil { background: linear-gradient(180deg, rgba(12,12,11,.3), rgba(12,12,11,.55)); backdrop-filter: blur(2px); -webkit-backdrop-filter: blur(2px); }
button.tile-more:hover .more-count { transform: scale(1.06); }
button.tile-more:hover .more-label svg { transform: translateX(3px); }

.allphotos {
  position: fixed; inset: 0; margin: 0; padding: 0; border: 0;
  width: 100vw; max-width: none; height: 100vh; height: 100dvh; max-height: none;
  background: var(--bg); color: var(--text);
  overflow-y: auto; overscroll-behavior: contain;
}
.allphotos::backdrop { background: rgba(0,0,0,.55); animation: fade .3s var(--ease); }
.ap-head {
  position: sticky; top: 0; z-index: 3;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
  padding-top: env(safe-area-inset-top);
}
.ap-head-in { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 76px; }
.ap-eyebrow { margin: 0 0 2px; font-size: 11.5px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--gold); }
.ap-head h2 { margin: 0; font-family: var(--serif); font-weight: 400; font-size: clamp(26px, 3vw, 34px); line-height: 1.05; }
.ap-body { padding-top: 22px; padding-bottom: calc(40px + env(safe-area-inset-bottom)); }
.ap-grid { grid-template-columns: repeat(4, 1fr); }
.allphotos[open]:not(.closing) .ap-grid .tile { animation: ap-in .55s var(--ease) both; animation-delay: min(calc(160ms + var(--i, 0) * 35ms), 800ms); }
@keyframes ap-in { from { opacity: 0; transform: translateY(16px) scale(.98); } }

/* ---------- Mobile tab bar ---------- */
.bottombar { display: none; }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1080px) {
  .ap-grid { grid-template-columns: repeat(3, 1fr); }
  .incl-grid { grid-template-columns: repeat(3, 1fr); }
  .trial { grid-template-columns: 1fr; }
  .trial .btn { justify-self: start; }
  .site-link { display: none; }
  .tabs a { padding: 0 12px; }
  .topbar-inner { gap: 12px; }
  .pb-grid { grid-template-columns: 1fr; }
  .pb-summary { position: static; }
  .pb-mini {
    position: sticky; bottom: calc(var(--bottom-h) + 12px); z-index: 2;
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    margin: 0 -6px -6px; padding: 10px 10px 10px 16px; border-radius: 999px;
    background: rgba(29, 28, 25, .92); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(201,164,106,.5); box-shadow: 0 10px 30px rgba(0,0,0,.45);
  }
  .pb-mini b { font-family: var(--serif); font-weight: 400; font-size: 26px; line-height: 1; }
  .pb-mini small { font-size: 12px; color: var(--muted); }
  .pb-mini button { height: 36px; padding: 0 16px; border-radius: 999px; background: var(--gold); color: #15130f; font-size: 13px; font-weight: 600; white-space: nowrap; }
  .pb-main { padding: 18px; }
  .for-pill { max-width: 150px; }
  .for-logo { height: 30px; padding: 5px 10px; }
  .for-logo img { height: 20px; max-width: 96px; }
  .for-logo.square img { height: 24px; }
}

@media (max-width: 860px) {
  :root {
    --top-h: 58px; --bottom-h: calc(68px + env(safe-area-inset-bottom));
    --r-lg: 18px; --r: 12px; --r-sm: 8px; --gap: 8px; --section: 36px;
  }

  .tabs, .topbar-actions { display: none; }
  .for-pill { margin-left: auto; }
  .brand-word { font-size: 23px; }
  .brand-logo { height: 28px; }

  .screen { padding-top: 18px; }
  .subtabs-wrap { margin-top: -18px; margin-bottom: 20px; }

  /* app-style bottom tab bar */
  .bottombar {
    display: grid; grid-template-columns: repeat(5, 1fr);
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 35;
    height: var(--bottom-h); padding-bottom: env(safe-area-inset-bottom);
    background: rgba(18,18,16,.9);
    backdrop-filter: saturate(1.6) blur(20px); -webkit-backdrop-filter: saturate(1.6) blur(20px);
    border-top: 1px solid var(--line);
  }
  .bottombar > a, .bottombar > button {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
    font-size: 10.5px; font-weight: 500; color: var(--faint);
    transition: color .2s;
  }
  .bottombar svg { width: 23px; height: 23px; }
  .bottombar > a.active { color: var(--text); }
  .bottombar > a.active svg { color: var(--gold); }
  .bb-book { color: var(--gold) !important; }
  .bb-book-icon {
    width: 46px; height: 46px; border-radius: 50%; margin-top: -20px;
    display: grid; place-items: center;
    background: var(--gold); color: #15130f;
    box-shadow: 0 8px 22px rgba(201,164,106,.35), 0 0 0 5px var(--bg);
  }
  .bb-book-icon svg { width: 22px; height: 22px; }

  /* booking menu becomes a bottom sheet */
  .book-menu {
    top: auto; left: 0; right: 0; bottom: 0; width: auto;
    border-radius: 22px 22px 0 0; border-bottom: 0;
    padding: 10px 14px calc(18px + env(safe-area-inset-bottom));
    transform: translateY(100%); opacity: 1;
  }
  .book-menu.open { transform: none; }
  .scrim.open { background: rgba(0,0,0,.55); }
  .sheet-handle { display: block; width: 38px; height: 5px; border-radius: 3px; background: var(--line-2); margin: 0 auto 12px; }
  .book-menu-title { font-size: 17px; }
  .book-opt { padding: 12px 10px; }

  .form-dialog[open] {
    width: 100vw; max-height: 92dvh; margin: auto 0 0; border-radius: 22px 22px 0 0;
    padding: 12px 18px calc(22px + env(safe-area-inset-bottom));
    animation: sheetUp .3s var(--ease);
  }
  .form-dialog .sheet-handle { display: block; }
  .dialog-close { top: 14px; }
  @keyframes sheetUp { from { transform: translateY(100%); } to { transform: none; } }

  /* home */
  .stage { aspect-ratio: 16 / 10; --pos-x: var(--focus, 70%); }
  .stage-name { bottom: 50%; }
  .hero-body { grid-template-columns: 1fr; margin-top: -28px; padding: 0 20px 24px; gap: 14px; }
  .stage-pill { font-size: 12px; gap: 8px; padding: 4px 12px 4px 4px; }
  .stage-shade { height: 34%; }
  .pill-avatar { width: 24px; height: 24px; font-size: 12px; }
  .hero-text { font-size: 15px; }
  .hero-actions .btn { flex: 1; }

  .incl-grid { grid-template-columns: 1fr; }
  .extra-grid { grid-template-columns: 1fr; }
  .extra-card { display: grid; grid-template-columns: auto 1fr; gap: 4px 14px; padding: 16px; }
  .extra-icon { grid-row: span 2; width: 40px; height: 40px; }
  .extra-foot { grid-column: 2; padding-top: 10px; margin-top: 8px; }
  .video-viewer[open] { grid-template-columns: 1fr; }
  .video-viewer figure { padding: 64px 8px 100px; }
  .vv-stage { width: min(100%, calc((100dvh - 190px) * var(--ar, .5625))); }
  .incl-card { flex-direction: row; align-items: stretch; }
  .incl-card:hover { transform: none; }
  .incl-img { width: 104px; flex: none; aspect-ratio: 1; height: auto; }
  .incl-img .ph-label, .incl-img .ph-file { display: none; }
  .incl-body { padding: 12px 12px 12px 14px; align-items: center; }
  .incl-check { display: none; }
  .incl-body p { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .incl-chev { display: block; width: 18px; height: 18px; color: var(--faint); margin-left: auto; }
  .incl-body > div { flex: 1; min-width: 0; }

  .trial-steps { grid-template-columns: 1fr; }
  .trial .btn { width: 100%; }

  /* services / galleries */
  .panel-head { flex-direction: column; gap: 12px; margin-bottom: 18px; }
  .panel-head .badge { order: -1; }
  .gallery { grid-template-columns: repeat(2, 1fr); }
  .gallery-wide, .gallery-plans { grid-template-columns: 1fr; gap: 10px; }
  .plans-standard .gallery-plans,
  .plans-lux .gallery-plans { grid-template-columns: 1fr; gap: 10px; }
  .plan-tier { padding-top: 22px; }
  .plan-tier-head { flex-direction: column; gap: 12px; }
  .plan-tier-head .badge { order: -1; }
  .ap-grid { grid-template-columns: repeat(2, 1fr); }
  .ap-head-in { min-height: 64px; }
  .ap-body { padding-top: 14px; }
  .ph-file { display: none; }
  .compare-knob { width: 44px; height: 44px; }
  .compare-tag { top: 10px; font-size: 10px; padding: 5px 9px; }
  .tag-before { left: 10px; }
  .tag-after { right: 10px; }
  .hint { text-align: center; margin: 10px 0 14px; }
  /* Declutter: full width, rooms as a swipe strip */
  .declutter { width: 100%; }
  .declutter .hint { margin: 10px 0 12px; }
  .pair-thumbs { display: flex; overflow-x: auto; scrollbar-width: none; margin: 0 calc(-1 * var(--pad)); padding: 4px var(--pad); position: relative; }
  .pair-thumbs::-webkit-scrollbar { display: none; }
  .pair-thumb { flex: 0 0 128px; }
  .pair-thumb > span { font-size: 12.5px; margin-top: 6px; }

  .tiers { grid-template-columns: 1fr; gap: 18px; }
  .video-grid { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; margin: 0 calc(-1 * var(--pad)); padding: 0 var(--pad); scroll-padding: 0 var(--pad); }
  .video-grid::-webkit-scrollbar { display: none; }
  .tour-tips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin: -6px calc(-1 * var(--pad)) 4px; padding: 0 var(--pad); }
  .tour-tips::-webkit-scrollbar { display: none; }
  .tour-tips li { flex: none; }
  .tour-item { padding-top: 26px; }
  .tour-head { margin-bottom: 12px; }
  .tour-head h2 { flex-direction: column; gap: 2px; }
  .tour-fs { padding: 0 14px; }
  .tour-frame { height: min(72dvh, 620px); margin: 0 calc(-1 * var(--pad) + 6px); }
  .tv-stage { margin: 0; border-radius: 0; }
  .tour-start-ring { width: 74px; height: 74px; }
  .tour-start-ring svg { width: 34px; height: 34px; }
  .tour-start-text strong { font-size: 25px; }
  .tour-pano { animation-duration: 30s; }
  .video-grid .video-box { flex: 0 0 64%; scroll-snap-align: start; }
  .video-play { width: 62px; height: 62px; margin: -31px 0 0 -31px; }
  .video-play svg { width: 26px; height: 26px; }
  .tier { padding: 22px 20px 20px; }
  .tier h3 { min-height: 0; }
  .tier-price { font-size: 2.6rem; }
  .tier-body { margin-top: 16px; padding-top: 14px; }
  .size-panel { padding: 14px; gap: 10px; margin-bottom: 26px; }
  .size-q { width: 100%; font-size: 15px; }
  .size-q::after { content: " (sq ft)"; font-weight: 400; color: var(--muted); }
  .size-switch { display: flex; width: 100%; }
  .size-switch button { flex: 1 1 0; min-width: 0; padding: 0 4px; font-size: 13px; height: 38px; }
  .size-switch button .unit { display: none; }
  .size-over { width: 100%; margin-left: 0; text-align: center; }
  .price-groups { grid-template-columns: 1fr; }
  .price-group { padding: 18px 18px 4px; }
  .field-row { grid-template-columns: 1fr; }

  .lightbox[open] { grid-template-columns: 1fr; }
  .lightbox figure { padding: 70px 8px 100px; }
  .lb-frame { width: min(100%, calc((100dvh - 210px) * 1.5)); }
  .lightbox.fit-plan .lb-frame { width: min(100%, calc((100dvh - 210px) * var(--ar, 1.5))); }
  .lb-nav { position: absolute; bottom: calc(26px + env(safe-area-inset-bottom)); margin: 0; }
  .lb-prev { left: calc(50% - 60px); }
  .lb-next { right: calc(50% - 60px); }
}

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