@font-face {
  font-family: 'Inter Tight Local';
  src: url('./assets/fonts/inter-tight.woff2') format('woff2');
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --purple: #9333D2;
  --purple-deep: #4A2574;
  --paper: #F5F2ED;
  --white: #FFFFFF;
  --ink: #211C25;
  --muted: #665E69;
  --line: #DCD5DF;
  --purple-pale: #F1E7F8;
  --purple-text: #E5D6F0;
  --quiz-image-stage: #F5F2F7;
  --error: #9A2237;
  --error-paper: #FFF0F2;
  --gutter: clamp(24px, 4vw, 80px);
  --measure: 70ch;
  --radius: 12px;
  --ease-out: cubic-bezier(.16, 1, .3, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--paper); }
body { margin: 0; color: var(--ink); background: var(--white); font: 400 18px/1.5 'Inter Tight Local', Arial, sans-serif; -webkit-text-size-adjust: 100%; }
img { display: block; max-width: 100%; height: auto; }
button, input { font: inherit; }
button, input, a { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
button { color: inherit; cursor: pointer; }
a { color: inherit; text-underline-offset: .22em; text-decoration-thickness: 1px; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { font-weight: 700; text-wrap: balance; overflow-wrap: anywhere; }
p { max-width: var(--measure); text-wrap: pretty; }
button, input, summary { min-height: 44px; }
button, input { border-radius: var(--radius); }
button:disabled { cursor: not-allowed; }
:focus-visible { outline: 3px solid var(--purple); outline-offset: 4px; }
::selection { background: var(--purple-deep); color: var(--white); }
input { caret-color: var(--purple); }
* { scrollbar-width: thin; scrollbar-color: var(--purple) var(--paper); }
*::-webkit-scrollbar { width: 10px; height: 10px; }
*::-webkit-scrollbar-track { background: var(--paper); }
*::-webkit-scrollbar-thumb { background: var(--purple); border: 2px solid var(--paper); border-radius: 8px; }
section[id], article[id] { scroll-margin-top: 24px; }
[hidden] { display: none !important; }
.nowrap { white-space: nowrap; }
.mobile-quiz-return { display: none; }
.visually-hidden, .hero-eyebrow { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }

/* A quiet masthead lets the building and offer carry the first screen. */
.site-header { position: relative; z-index: 2; background: var(--white); border-bottom: 1px solid var(--line); }
.site-nav { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 80px; padding: 12px var(--gutter); }
.brand { display: inline-flex; align-items: center; flex: 0 0 auto; min-height: 44px; }
.brand img { width: 124px; height: auto; }
.nav-links { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 32px; }
.nav-links a { display: inline-flex; align-items: center; min-height: 44px; font-size: 15px; font-weight: 600; text-decoration: none; }
.nav-links a:hover { text-decoration: underline; }
.nav-links a:last-child { padding: 10px 20px; color: var(--purple-deep); border: 1px solid var(--purple-deep); border-radius: var(--radius); }

/* The full-bleed photo stays exposed beside an opaque reading surface. */
.hero { position: relative; isolation: isolate; background: var(--paper); }
.hero-media { position: absolute; inset: 0; z-index: -1; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: 68% center; }
.hero-poster, .hero-video { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-poster img, .hero-video { width: 100%; height: 100%; object-fit: cover; object-position: center; }
.hero-video { opacity: 1; transition: opacity .28s var(--ease-out); }
.hero-media.is-video-fallback .hero-video { opacity: 0; pointer-events: none; }
.hero-surface { display: grid; grid-template-columns: 53% minmax(0, 1fr); }
.hero-copy { grid-column: 1; min-width: 0; padding: clamp(28px, 3vw, 54px) 40px 24px var(--gutter); background: var(--white); }
.hero h1 { max-width: 18ch; font-size: clamp(2.75rem, 3.75vw, 4.5rem); line-height: 1.04; letter-spacing: -.035em; }
.hero-subtitle { max-width: 38ch; margin-top: 22px; color: var(--muted); font-size: clamp(17px, 1.4vw, 22px); line-height: 1.35; }
.hero-proof { grid-column: 1; display: grid; grid-template-columns: 1fr 1.6fr 1.2fr; gap: 18px; padding: 0 40px 28px var(--gutter); background: var(--white); }
.hero-proof p { padding-top: 14px; border-top: 1px solid var(--line); font-size: 13px; line-height: 1.4; color: var(--muted); font-variant-numeric: tabular-nums; }
.hero-proof p:first-child, .hero-proof p:last-child { color: var(--purple-deep); font-weight: 650; }
.hero-proof-highlight { font: inherit; }

/* One continuous tray: a visible question, compact progress and real answers. */
.quiz-section { grid-column: 1 / -1; min-width: 0; background: var(--purple-deep); color: var(--white); border-top: 5px solid var(--purple); }
.quiz { display: grid; padding: 20px var(--gutter) 22px; min-width: 0; }
.quiz.is-transitioning { overflow: clip; }
.quiz[aria-busy='true'] { cursor: progress; }
.quiz-topline { display: flex; align-items: center; gap: 20px; min-height: 8px; }
.quiz-step-count { flex: 0 0 auto; font-size: 12px; line-height: 1.4; color: var(--purple-text); font-variant-numeric: tabular-nums; }
.quiz-progress { flex: 1; height: 3px; overflow: hidden; background: #795C98; }
.quiz-progress span { display: block; height: 100%; width: var(--progress, 16.67%); background: var(--white); transition: width .24s var(--ease-out); }
.quiz-back { flex: 0 0 44px; width: 44px; height: 44px; border: 1px solid #B29BC5; background: transparent; color: var(--white); font-size: 24px; line-height: 1; }
.quiz-back:hover { background: #633D88; }
.quiz-panel { grid-row: 2; display: grid; grid-template-columns: minmax(210px, .8fr) minmax(0, 2.2fr); align-items: start; column-gap: 32px; row-gap: 18px; min-width: 0; padding-top: 18px; }
.quiz-panel h2 { margin: 0; max-width: 22ch; font-size: clamp(1.5rem, 2.25vw, 2rem); line-height: 1.1; letter-spacing: -.025em; }
.quiz-options { min-width: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.quiz-option { display: flex; align-items: center; gap: 10px; min-width: 0; min-height: 76px; padding: 14px; border: 1px solid #A88BBF; background: transparent; color: var(--white); text-align: left; line-height: 1.25; transition: background-color .18s ease, border-color .18s ease, transform .18s var(--ease-out), box-shadow .18s ease; }
.quiz-option:hover { background: #633D88; border-color: var(--white); }
.quiz-option.is-selected { background: var(--white); color: var(--purple-deep); border-color: var(--white); }
.quiz-option-copy { display: grid; gap: 5px; min-width: 0; overflow-wrap: anywhere; }
.quiz-option-copy strong { font-weight: 600; font-size: 16px; }
.quiz-option-copy small { font-size: 13px; line-height: 1.35; }
.quiz-option-icon { display: none; }
.quiz-check { display: grid; place-items: center; flex: 0 0 20px; width: 20px; height: 20px; margin-left: auto; border: 1px solid #B29BC5; border-radius: 50%; font-size: 13px; color: transparent; transition: color .18s ease, background-color .18s ease, border-color .18s ease, transform .18s var(--ease-out); }
.quiz-option.is-selected .quiz-check { border-color: var(--purple-deep); background: var(--purple-deep); color: var(--white); }
.quiz-options--step-2 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.quiz-option--image { display: grid; position: relative; align-content: start; padding: 0; gap: 0; background: var(--white); color: var(--ink); overflow: hidden; }
.quiz-option-media { display: block; width: 100%; height: 156px; overflow: hidden; background: var(--quiz-image-stage); }
.quiz-option--image img { width: 100%; height: 100%; padding: 0; object-fit: cover; object-position: center; background: var(--quiz-image-stage); transition: transform .4s var(--ease-out); }
.quiz-option--image[data-option-id='one'] img { object-position: 50% 46%; }
.quiz-option--image[data-option-id='two'] img { object-position: 50% 48%; }
.quiz-option--image[data-option-id='three'] img { object-position: 50% 48%; }
.quiz-option--image[data-option-id='sale'] img { transform: scale(1.55); }
.quiz-option--image[data-option-id='ready'] img { object-position: 50% 48%; }
.quiz-option--image[data-option-id='different'] img { object-position: 50% 58%; }
.quiz-option--image .quiz-option-copy { padding: 14px 38px 14px 14px; }
.quiz-option--image .quiz-check { position: absolute; right: 10px; top: 10px; background: var(--white); border-color: var(--purple-deep); }
.quiz-option--image:hover { background: var(--purple-pale); color: var(--purple-deep); }
.quiz-option--image.is-selected { border: 2px solid var(--white); background: var(--purple-pale); }
.quiz-options--step-4 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.quiz-options--step-4 .quiz-option:last-child { grid-column: span 2; }
.advisor { grid-row: 3; display: flex; align-items: center; gap: 10px; margin-top: 16px; min-width: 0; }
.advisor img { flex: 0 0 36px; width: 36px; height: 36px; object-fit: cover; border-radius: 50%; }
.advisor p { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; line-height: 1.3; }
.advisor strong { font-size: 13px; font-weight: 650; }
.advisor span { color: var(--purple-text); font-size: 12px; }
.quiz :focus-visible { outline-color: var(--white); }
.quiz ::selection { color: var(--purple-deep); background: var(--white); }

.button { display: inline-flex; align-items: center; justify-content: center; gap: 20px; max-width: 100%; min-height: 50px; padding: 14px 22px; border: 0; border-radius: var(--radius); background: var(--purple); color: var(--white); font-size: 14px; font-weight: 700; line-height: 1.25; text-align: center; text-decoration: none; overflow-wrap: anywhere; transition: background-color .18s ease, transform .18s var(--ease-out), box-shadow .18s ease; }
.button > span:first-child { min-width: 0; }
.button > span:last-child { flex: 0 0 auto; font-size: 22px; line-height: 1; }
.button:hover { background: var(--purple-deep); }
.quiz-next, .quiz-submit { grid-column: 2; justify-self: start; min-width: 160px; background: var(--white); color: var(--purple-deep); }
.quiz-next:hover, .quiz-submit:hover { background: var(--purple-pale); }
.button:disabled { opacity: 1; color: #766B7F; background: #DBD2E3; cursor: not-allowed; }
.button[aria-busy='true'] { cursor: progress; }

/* Input boundaries remain explicit, including touched-invalid fields. */
.quiz-panel[data-quiz-step='5'] { width: 100%; max-width: 1180px; margin-inline: auto; grid-template-columns: minmax(260px, .85fr) minmax(420px, 1.15fr); gap: clamp(28px, 4vw, 64px); align-items: center; }
.quiz-panel[data-quiz-step='5'] h2 { max-width: 20ch; font-size: clamp(1.75rem, 2.25vw, 2.55rem); line-height: 1.06; }
.quiz-contact-card { grid-column: 2; display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; min-width: 0; padding: clamp(22px, 2.2vw, 30px); border: 1px solid rgba(74, 37, 116, .12); border-radius: 20px; background: var(--white); color: var(--ink); box-shadow: 0 28px 70px -38px rgba(24, 10, 38, .72); }
.contact-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.contact-grid label { display: block; min-width: 0; }
.contact-grid > div { min-width: 0; }
.field-error { min-height: 0; margin: 0; font-size: 13px; line-height: 1.35; color: var(--error); }
.field-error:empty { display: none; }
.field-error:not(:empty) { margin-top: 6px; }
.contact-grid input { width: 100%; min-width: 0; min-height: 54px; padding: 12px 16px; color: var(--ink); background: var(--paper); border: 1px solid var(--line); }
.contact-grid input::placeholder { color: var(--muted); opacity: 1; }
.contact-grid input[aria-invalid='true'] { border-color: var(--error); background: var(--error-paper); }
.contact-grid .phone-field { display: flex; align-items: center; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); color: var(--ink); }
.phone-field > span[aria-hidden] { flex: 0 0 auto; padding-left: 14px; font-variant-numeric: tabular-nums; }
.phone-field input { min-height: 50px; padding-left: 10px; border: 0; font-variant-numeric: tabular-nums; }
.phone-field.is-invalid { border-color: var(--error); background: var(--error-paper); }
.phone-field:has(input:focus-visible) { outline: 3px solid var(--purple); outline-offset: 2px; }
.phone-field input:focus-visible { outline: none; }
.messenger-label { font-size: 15px; font-weight: 650; color: var(--purple-deep); }
.messengers { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.messenger { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-width: 0; min-height: 44px; padding: 10px 12px; border: 1px solid #B89CCB; background: var(--white); color: var(--purple-deep); font-size: 14px; transition: color .18s ease, background-color .18s ease, border-color .18s ease, transform .18s var(--ease-out); }
.messenger:hover { border-color: var(--purple-deep); background: var(--purple-pale); }
.messenger.is-selected { background: var(--purple-deep); color: var(--white); border-color: var(--purple-deep); font-weight: 700; }
.messenger.is-selected::after { content: '✓'; font-size: 12px; line-height: 1; }
.quiz-contact-card .quiz-submit { grid-column: 1; width: 100%; min-width: 0; margin-top: 2px; background: var(--purple); color: var(--white); }
.quiz-contact-card .quiz-submit:hover { background: var(--purple-deep); }
.quiz-contact-card .button:disabled { color: #766B7F; background: #DBD2E3; }
.quiz:has(.quiz-panel[data-quiz-step='5']) .advisor { width: min(100%, 1180px); margin-inline: auto; }
.quiz-result { display: grid; justify-items: start; gap: 20px; min-width: 0; }
.quiz-result .button { background: var(--white); color: var(--purple-deep); }
.quiz-result .button:hover { background: var(--purple-pale); }

/* Editorial spans establish a gallery rhythm instead of repeated equal tiles. */
.project-gallery { padding: 100px var(--gutter) 112px; }
.section-heading { margin-bottom: 40px; }
.section-heading h2 { max-width: 20ch; font-size: clamp(2.25rem, 4.5vw, 4.5rem); line-height: 1.06; letter-spacing: -.035em; }
.project-gallery-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 76px 40px; align-items: start; }
.project-card { grid-column: span 7; min-width: 0; }
.project-card:nth-child(2), .project-card:nth-child(3), .project-card:nth-child(6) { grid-column: span 5; }
.project-card:nth-child(2), .project-card:nth-child(6) { margin-top: 90px; }
.project-card:nth-child(3) { margin-top: 50px; }
.project-media { position: relative; overflow: hidden; aspect-ratio: 1.6; touch-action: pan-y; background: var(--paper); border-radius: var(--radius); }
.project-card:nth-child(2) .project-media, .project-card:nth-child(3) .project-media, .project-card:nth-child(6) .project-media { aspect-ratio: 1.25; }
.project-gallery-track { position: absolute; inset: 0; }
.project-slide { position: absolute; inset: 0; margin: 0; opacity: 0; transform: translateX(calc(var(--gallery-direction, 1) * 7%)); transition: opacity .3s ease, transform .36s var(--ease-out); pointer-events: none; }
.project-slide.is-active { z-index: 1; opacity: 1; transform: translateX(0); }
.project-slide img { width: 100%; height: 100%; object-fit: cover; transition: transform .7s var(--ease-out); }
.project-gallery-controls { position: absolute; z-index: 2; right: 14px; bottom: 14px; display: grid; grid-template-columns: 44px auto 44px; align-items: center; gap: 6px; }
.project-gallery-arrow { display: grid; place-items: center; min-width: 44px; min-height: 44px; padding: 0; border: 1px solid rgba(255, 255, 255, .7); border-radius: 50%; background: rgba(74, 37, 116, .9); color: var(--white); transition: background-color .18s ease, transform .18s var(--ease-out); }
.project-gallery-arrow:hover { background: var(--purple); transform: translateY(-1px); }
.project-gallery-arrow svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.project-gallery-count { min-width: 52px; padding: 8px 10px; border-radius: 999px; background: rgba(33, 28, 37, .82); color: var(--white); font-size: 12px; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1; text-align: center; }
.project-copy { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 20px; padding-top: 20px; }
.project-copy h3 { grid-column: 1 / -1; max-width: 24ch; font-size: clamp(1.8rem, 2.7vw, 3rem); line-height: 1.1; letter-spacing: -.025em; }
.project-location { grid-column: 1 / -1; margin-top: 8px; color: var(--muted); font-size: 15px; }
.project-status { grid-column: 1; align-self: end; margin-top: 14px; font-size: 14px; line-height: 1.35; color: var(--purple-deep); }
.project-price { grid-column: 2; align-self: end; margin-top: 14px; color: var(--ink); font-size: 18px; font-weight: 650; font-variant-numeric: tabular-nums; line-height: 1.3; }
.project-copy details { grid-column: 1 / -1; margin-top: 18px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); font-size: 16px; }
.project-copy summary { padding: 12px 0; cursor: pointer; font-weight: 550; color: var(--muted); }
.project-copy summary:hover { color: var(--purple-deep); }
.project-copy summary::marker { color: var(--purple); }
.project-copy details[open] summary { color: var(--purple-deep); }
.project-copy details p { padding: 4px 0 12px; }
.project-copy details ul { padding: 0 0 0 1em; margin: 0 0 18px; list-style: none; max-width: var(--measure); }
.project-copy details li { margin: 7px 0; }
.project-copy .button { grid-column: 1 / -1; justify-self: start; margin-top: 18px; }
.project-card:hover .project-copy h3, .project-card:focus-within .project-copy h3 { color: var(--purple-deep); }

/* A proof ledger replaces the old icon-card scaffold. */
.benefits { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: 72px; padding: 88px var(--gutter) 100px; background: var(--paper); }
.benefits .section-heading { margin: 0; }
.benefit-grid { min-width: 0; }
.benefit-card { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 24px; padding: 24px 0; border-top: 1px solid var(--line); }
.benefit-card:last-child { border-bottom: 1px solid var(--line); }
.benefit-card > span { display: none; }
.benefit-card h3 { font-size: 24px; font-weight: 600; line-height: 1.14; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.benefit-card p { color: var(--muted); font-size: 16px; }

/* The final screen is a decision tool: compare districts, then enter the quiz with context. */
.location-map { padding: 104px var(--gutter) 112px; background: var(--white); }
.location-map-heading { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(260px, .65fr); gap: 48px; align-items: end; }
.location-map-heading h2 { max-width: 16ch; font-size: clamp(2.5rem, 4.5vw, 4.75rem); line-height: 1.02; letter-spacing: -.035em; }
.location-map-heading p { justify-self: end; max-width: 34ch; padding-bottom: 8px; color: var(--muted); font-size: clamp(17px, 1.4vw, 20px); line-height: 1.4; }
.location-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 36px; }
.location-chip { min-height: 44px; padding: 9px 16px; border: 1px solid var(--line); border-radius: 999px; background: var(--white); color: var(--muted); font-size: 14px; font-weight: 650; transition: color .18s ease, border-color .18s ease, background-color .18s ease; }
.location-chip:hover { color: var(--purple-deep); border-color: var(--purple-deep); }
.location-chip[aria-pressed='true'] { color: var(--white); border-color: var(--purple-deep); background: var(--purple-deep); }
.location-layout { display: grid; grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr); gap: 20px; align-items: stretch; margin-top: 20px; }
.location-plot { position: relative; min-width: 0; min-height: 490px; overflow: hidden; border: 1px solid var(--line); border-radius: 16px; background: #EDE9E3; box-shadow: 0 24px 60px -36px rgba(74, 37, 116, .48); }
.location-live-map { position: absolute; inset: 0; z-index: 0; background: #EDE9E3; }
.location-live-map .leaflet-control-attribution { padding: 3px 7px; background: rgba(255, 255, 255, .9); color: var(--muted); font-size: 10px; }
.location-live-map .leaflet-control-zoom a { color: var(--purple-deep); }
.location-live-map .leaflet-marker-icon { transition: filter .18s ease, transform .18s var(--ease-out); }
.location-live-map .leaflet-marker-icon.is-active {
  filter:
    drop-shadow(0 0 2px #9333D2)
    drop-shadow(0 0 8px rgba(147, 51, 210, .9))
    drop-shadow(0 10px 12px rgba(74, 37, 116, .42));
}
.location-live-map .leaflet-tooltip { border: 0; border-radius: 8px; box-shadow: 0 10px 28px -18px rgba(33, 28, 37, .75); color: var(--purple-deep); font: 700 12px/1.2 'Inter Tight Local', Arial, sans-serif; }
.location-map-error { position: absolute; z-index: 500; inset: auto 16px 16px; max-width: calc(100% - 32px); padding: 10px 14px; border-radius: 10px; background: rgba(74, 37, 116, .94); color: var(--white); font-size: 14px; line-height: 1.35; box-shadow: 0 12px 30px -18px rgba(33, 28, 37, .9); }
.location-detail { display: flex; flex-direction: column; min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 16px; background: var(--white); }
.location-detail > img { width: 100%; aspect-ratio: 1.35; object-fit: cover; }
.location-detail-copy { display: flex; flex: 1; flex-direction: column; align-items: flex-start; padding: 24px; }
.location-detail-status { color: var(--purple-deep); font-size: 13px; font-weight: 700; line-height: 1.35; }
.location-detail h3 { margin-top: 9px; font-size: clamp(1.85rem, 2.8vw, 2.8rem); line-height: 1.02; letter-spacing: -.03em; }
.location-detail-address { margin-top: 10px; color: var(--muted); font-size: 15px; line-height: 1.4; }
.location-detail-price { margin-top: 18px; font-size: 21px; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.25; }
.location-detail .button { width: 100%; margin-top: auto; transform: translateY(16px); }
.location-unknown { align-self: center; min-height: 44px; margin-top: 22px; padding: 7px 4px; border: 0; border-radius: 0; background: transparent; color: var(--muted); font-size: 14px; text-decoration: underline; text-underline-offset: 4px; }
.location-unknown:hover { color: var(--purple-deep); }
.location-conversion { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 28px; align-items: center; margin-top: 20px; padding: 24px 28px; border-radius: 16px; background: var(--purple-deep); color: var(--white); }
.location-conversion p { max-width: 46ch; color: var(--purple-text); font-size: clamp(18px, 1.6vw, 22px); line-height: 1.3; }
.location-conversion .button { min-width: 230px; background: var(--white); color: var(--purple-deep); }
.location-conversion .button:hover { background: var(--purple-pale); }
.location-conversion :focus-visible { outline-color: var(--white); }

body.is-dialog-open { overflow: hidden; }
.consultation-dialog { width: min(560px, calc(100% - 32px)); max-width: none; max-height: min(720px, calc(100dvh - 32px)); padding: 0; overflow: auto; border: 1px solid rgba(74, 37, 116, .12); border-radius: 22px; background: var(--white); color: var(--ink); box-shadow: 0 34px 100px -28px rgba(33, 28, 37, .68); }
.consultation-dialog::backdrop { background: rgba(33, 28, 37, .64); backdrop-filter: blur(5px); }
.consultation-form, .consultation-success { position: relative; display: grid; padding: clamp(30px, 4vw, 44px); }
.consultation-form h2, .consultation-success h2 { max-width: none; padding-right: 52px; font-size: clamp(2rem, 3.6vw, 2.8rem); line-height: 1.02; letter-spacing: -.035em; }
.consultation-location { max-width: 42ch; margin-top: 12px; color: var(--muted); font-size: 15px; line-height: 1.4; }
.dialog-close { position: absolute; top: 16px; right: 16px; z-index: 1; width: 44px; min-height: 44px; padding: 0; border: 1px solid var(--line); border-radius: 50%; background: var(--white); transition: border-color .18s ease, background-color .18s ease, transform .18s var(--ease-out); }
.dialog-close::before, .dialog-close::after { content: ''; position: absolute; top: 50%; left: 50%; width: 17px; height: 2px; border-radius: 1px; background: var(--purple-deep); transform: translate(-50%, -50%) rotate(45deg); }
.dialog-close::after { transform: translate(-50%, -50%) rotate(-45deg); }
.dialog-close:hover { border-color: var(--purple-deep); background: var(--purple-pale); }
.consultation-fields { display: grid; grid-template-columns: minmax(0, 1fr); gap: 6px; margin-top: 28px; }
.consultation-field { display: grid; gap: 8px; }
.consultation-field > label { color: var(--purple-deep); font-size: 14px; font-weight: 700; }
.consultation-field > input, .consultation-phone { width: 100%; min-width: 0; min-height: 56px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); }
.consultation-field > input { padding: 13px 15px; color: var(--ink); }
.consultation-phone { display: flex; align-items: center; overflow: hidden; }
.consultation-phone > span { flex: 0 0 auto; padding-left: 15px; color: var(--ink); font-variant-numeric: tabular-nums; }
.consultation-phone input { width: 100%; min-width: 0; min-height: 54px; padding: 13px 15px 13px 8px; border: 0; border-radius: 0; background: transparent; color: var(--ink); font-variant-numeric: tabular-nums; }
.consultation-field input::placeholder { color: var(--muted); opacity: 1; }
.consultation-field input:focus-visible { outline: 3px solid var(--purple); outline-offset: 2px; }
.consultation-phone:has(input:focus-visible) { outline: 3px solid var(--purple); outline-offset: 2px; }
.consultation-phone input:focus-visible { outline: 0; }
.consultation-field.is-invalid > input, .consultation-field.is-invalid .consultation-phone { border-color: var(--error); background: var(--error-paper); }
.consultation-error { min-height: 18px; margin-top: 5px; color: var(--error); font-size: 13px; line-height: 1.35; }
.consultation-form > .button { width: 100%; min-width: 0; margin-top: 12px; }
.consultation-note { margin-top: 12px; color: var(--muted); font-size: 12px; line-height: 1.4; text-align: center; }
.consultation-success { min-height: 360px; align-content: center; justify-items: start; }
.consultation-success h2 { padding-right: 0; }
.consultation-success > p { margin-top: 14px; color: var(--muted); font-size: 18px; }
.consultation-success .button { margin-top: 28px; }

@keyframes consultation-enter {
  from { opacity: 0; transform: translateY(16px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes consultation-backdrop-enter {
  from { background: rgba(33, 28, 37, 0); backdrop-filter: blur(0); }
  to { background: rgba(33, 28, 37, .64); backdrop-filter: blur(5px); }
}
@media (prefers-reduced-motion: no-preference) {
  .consultation-dialog[open] { animation: consultation-enter .32s var(--ease-out) both; }
  .consultation-dialog[open]::backdrop { animation: consultation-backdrop-enter .24s ease both; }
}

/* One restrained entrance; all content is visible before JavaScript runs. */
@keyframes gallery-arrive {
  from { transform: translateY(6px); }
  to { transform: translateY(0); }
}
@media (prefers-reduced-motion: no-preference) {
  .hero-surface { animation: gallery-arrive .4s var(--ease-out) both; }
  .motion-ready [data-reveal] { opacity: 0; transform: translateY(20px); transition: opacity .58s var(--ease-out), transform .58s var(--ease-out); transition-delay: calc(var(--reveal-index, 0) * 70ms); }
  .motion-ready [data-reveal].is-visible { opacity: 1; transform: translateY(0); }
}

@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .project-card:hover .project-slide.is-active img, .project-card:focus-within .project-slide.is-active img { transform: scale(1.025); }
  .button:hover { transform: translateY(-2px); box-shadow: 0 12px 28px -18px rgba(33, 28, 37, .75); }
  .quiz-option:hover { transform: translateY(-2px); box-shadow: 0 14px 28px -22px rgba(0, 0, 0, .8); }
  .quiz-option.is-selected .quiz-check { transform: scale(1.08); }
  .messenger:hover, .dialog-close:hover { transform: translateY(-1px); }
}

@media (max-width: 1099px) {
  :root { --gutter: 28px; }
  .site-nav { min-height: 72px; }
  .nav-links { gap: 16px; }
  .hero-surface { grid-template-columns: 62% minmax(0, 1fr); }
  .hero-copy { padding: 32px 28px 22px var(--gutter); }
  .hero h1 { font-size: clamp(2.5rem, 4.6vw, 3.25rem); }
  .hero-proof { grid-template-columns: 1fr 1.4fr; padding-right: 28px; gap: 12px; }
  .hero-proof p:last-child { grid-column: 1 / -1; padding-top: 0; border: 0; }
  .quiz-panel { grid-template-columns: minmax(180px, .75fr) minmax(0, 1.5fr); gap: 18px; }
  .quiz-options { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .quiz-option { min-height: 64px; }
  .quiz-options--step-4 .quiz-option:last-child { grid-column: 1 / -1; }
  .quiz-panel[data-quiz-step='5'] { grid-template-columns: minmax(220px, .8fr) minmax(360px, 1.2fr); gap: 28px; }
  .contact-grid { grid-template-columns: 1fr; }
  .messengers { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .project-gallery { padding-top: 72px; padding-bottom: 80px; }
  .project-gallery-grid { gap: 54px 28px; }
  .project-copy { grid-template-columns: minmax(0, 1fr); }
  .project-status, .project-price { grid-column: 1; }
  .project-price { margin-top: 8px; }
  .project-copy h3 { font-size: clamp(1.75rem, 3vw, 2.5rem); }
  .benefits { gap: 36px; grid-template-columns: minmax(0, .7fr) minmax(0, 1fr); padding-top: 64px; padding-bottom: 72px; }
  .benefit-card { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .location-map { padding-top: 76px; padding-bottom: 84px; }
  .location-map-heading { grid-template-columns: minmax(0, 1.2fr) minmax(240px, .8fr); gap: 28px; }
  .location-layout { grid-template-columns: minmax(0, 1.45fr) minmax(260px, 1fr); }
  .location-plot { min-height: 430px; }
  .location-detail-copy { padding: 20px; }
  .location-detail .button { transform: none; margin-top: 22px; }
}

@media (max-width: 719px) {
  :root { --gutter: 20px; }
  body { font-size: 16px; }
  body:has(.mobile-quiz-return:not([hidden])) { padding-bottom: calc(84px + env(safe-area-inset-bottom, 0px)); }
  .mobile-quiz-return { display: block; position: fixed; inset: auto 0 0; z-index: 5; padding: 12px var(--gutter) calc(12px + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--line); background: var(--white); }
  .mobile-quiz-return .button { width: 100%; }
  .site-nav { min-height: 64px; gap: 12px; padding-top: 8px; padding-bottom: 8px; }
  .brand img { width: 100px; }
  .nav-links { gap: 0; }
  .nav-links a { display: none; }
  .nav-links a:last-child { display: inline-flex; min-height: 44px; padding: 8px 12px; font-size: 13px; }
  .hero { background: var(--purple-deep); }
  .hero-media { inset: 0 0 auto; height: 510px; }
  .hero-media::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(20, 10, 29, .35) 0%, rgba(26, 10, 39, .72) 58%, rgba(33, 14, 50, .92) 100%); }
  .hero-media img { object-position: 62% center; }
  .hero-poster img, .hero-video { object-position: 50% 42%; }
  .hero-surface { display: flex; flex-direction: column; }
  .hero-copy { display: flex; width: 100%; min-height: 420px; flex-direction: column; justify-content: flex-end; padding: 48px 20px 28px; background: transparent; color: var(--white); }
  .hero h1 { max-width: 18ch; font-size: clamp(1.875rem, 8.4vw, 2.75rem); line-height: 1.04; letter-spacing: -.03em; }
  .hero h1, .hero-subtitle { text-shadow: 0 2px 18px rgba(16, 7, 23, .32); }
  .hero-subtitle { margin-top: 16px; color: rgba(255, 255, 255, .84); font-size: 16px; line-height: 1.35; }
  .hero-proof { display: contents; }
  .hero-proof p { max-width: none; border: 0; font-size: 14px; }
  .hero-proof p:first-child { order: 1; width: auto; margin: 0 var(--gutter) 20px; padding: 12px 16px; border: 1px solid rgba(255, 255, 255, .32); border-radius: 12px; background: rgba(255, 255, 255, .12); color: var(--white); font-size: 14px; backdrop-filter: blur(8px); }
  .hero-proof p:nth-child(2), .hero-proof p:last-child { width: auto; margin-inline: var(--gutter); padding-inline: 20px; border-left: 1px solid var(--purple); background: var(--white); color: var(--muted); font-size: 14px; font-weight: 400; line-height: 1.42; }
  .hero-proof p:nth-child(2) { order: 3; margin-top: 16px; padding-top: 20px; padding-bottom: 8px; border-radius: 14px 14px 0 0; }
  .hero-proof p:last-child { order: 4; margin-bottom: 20px; padding-top: 8px; padding-bottom: 20px; border-radius: 0 0 14px 14px; }
  .hero-proof-highlight { display: block; margin-bottom: 5px; color: var(--purple-deep); font-size: 22px; font-weight: 760; line-height: 1; letter-spacing: -.02em; }
  .quiz-section { order: 2; border-top-width: 4px; }
  .quiz { padding: 16px var(--gutter) 18px; }
  .quiz-topline { gap: 14px; }
  .quiz-panel, .quiz-panel[data-quiz-step='5'] { display: flex; flex-direction: column; gap: 16px; padding-top: 16px; }
  .quiz-panel h2 { max-width: 25ch; font-size: 24px; line-height: 1.1; }
  .quiz-panel[data-quiz-step='5'] h2 { font-size: 24px; max-width: 27ch; }
  .quiz-options { width: 100%; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .quiz-option { gap: 7px; min-height: 66px; padding: 12px 10px; }
  .quiz-option-copy strong { font-size: 14px; }
  .quiz-option-copy small { font-size: 12px; }
  .quiz-check { flex-basis: 18px; width: 18px; height: 18px; font-size: 12px; }
  .quiz-option--image { padding: 0; }
  .quiz-option-media { height: 108px; }
  .quiz-option--image img { padding: 0; }
  .quiz-option--image .quiz-option-copy { padding: 12px; }
  .quiz-options--step-4 .quiz-option:last-child { grid-column: 1 / -1; }
  .advisor { margin-top: 16px; align-items: center; }
  .advisor p { display: grid; gap: 2px; }
  .advisor img { width: 32px; height: 32px; flex-basis: 32px; }
  .advisor span { max-width: 34ch; font-size: 11px; }
  .quiz-next, .quiz-submit { width: 100%; min-width: 0; }
  .contact-grid { width: 100%; gap: 10px; }
  .quiz-contact-card { width: 100%; gap: 14px; padding: 18px; border-radius: 16px; }
  .messenger-label { margin-bottom: 0; }
  .messengers { display: grid; width: 100%; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .messenger { min-width: 0; }
  .quiz-result { gap: 18px; }
  .project-gallery { padding: 54px var(--gutter) 64px; }
  .section-heading { margin-bottom: 28px; }
  .section-heading h2 { font-size: 36px; }
  .project-gallery-grid { display: flex; flex-direction: column; gap: 44px; }
  .project-card { width: 100%; }
  .project-card:nth-child(2), .project-card:nth-child(3), .project-card:nth-child(6) { margin-top: 0; }
  .project-media, .project-card:nth-child(2) .project-media, .project-card:nth-child(3) .project-media, .project-card:nth-child(6) .project-media { aspect-ratio: 1.35; }
  .project-gallery-controls { right: 10px; bottom: 10px; }
  .project-copy { padding-top: 16px; }
  .project-copy h3 { font-size: clamp(1.8rem, 7.5vw, 2.5rem); max-width: 22ch; }
  .project-location { font-size: 14px; }
  .project-status { margin-top: 12px; }
  .project-price { font-size: 20px; }
  .project-copy details { margin-top: 16px; }
  .project-copy .button { width: 100%; }
  .benefits { display: block; padding: 52px var(--gutter) 60px; }
  .benefits .section-heading { margin-bottom: 28px; }
  .benefit-card { padding: 22px 0; gap: 10px; }
  .benefit-card h3 { max-width: 22ch; font-size: 26px; }
  .location-map { padding: 56px var(--gutter) 64px; }
  .location-map-heading { display: block; }
  .location-map-heading h2 { max-width: 12ch; font-size: clamp(2.3rem, 10vw, 3.3rem); }
  .location-map-heading p { margin-top: 16px; padding: 0; font-size: 16px; }
  .location-chips { flex-wrap: nowrap; gap: 7px; margin: 26px calc(var(--gutter) * -1) 0; padding: 0 var(--gutter) 8px; overflow-x: auto; scroll-snap-type: x proximity; }
  .location-chip { flex: 0 0 auto; scroll-snap-align: start; }
  .location-layout { grid-template-columns: minmax(0, 1fr); gap: 12px; margin-top: 12px; }
  .location-plot { min-height: 0; aspect-ratio: 1 / 1.02; border-radius: 14px; }
  .location-live-map .leaflet-control-attribution { max-width: 180px; white-space: normal; line-height: 1.2; }
  .location-detail { display: grid; grid-template-columns: minmax(112px, .72fr) minmax(0, 1.28fr); border-radius: 14px; }
  .location-detail > img { height: 100%; min-height: 280px; aspect-ratio: auto; }
  .location-detail-copy { padding: 18px; }
  .location-detail h3 { font-size: clamp(1.7rem, 8vw, 2.25rem); }
  .location-detail-price { margin-top: 14px; font-size: 18px; }
  .location-detail .button { margin-top: 20px; padding-inline: 14px; font-size: 12px; }
  .location-unknown { align-self: flex-start; margin-top: 12px; text-align: left; }
  .location-conversion { grid-template-columns: minmax(0, 1fr); gap: 18px; margin-top: 12px; padding: 22px 20px; border-radius: 14px; }
  .location-conversion p { font-size: 18px; }
  .location-conversion .button { width: 100%; min-width: 0; }
  .consultation-dialog { width: calc(100% - 20px); max-height: calc(100dvh - 20px); border-radius: 18px; }
  .consultation-form, .consultation-success { padding: 28px 18px calc(22px + env(safe-area-inset-bottom, 0px)); }
  .consultation-form h2, .consultation-success h2 { max-width: none; padding-right: 48px; font-size: clamp(1.75rem, 8vw, 2.25rem); }
  .dialog-close { top: 14px; right: 14px; }
  .consultation-fields { grid-template-columns: minmax(0, 1fr); gap: 6px; margin-top: 24px; }
  .consultation-form > .button { width: 100%; min-width: 0; margin-top: 14px; }
  .consultation-success { min-height: 320px; }
}

@media (max-width: 399px) {
  .location-detail { display: flex; }
  .location-detail > img { min-height: 0; aspect-ratio: 1.45; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; transform: none !important; }
  .project-slide { transition: none !important; }
  .quiz-option--image[data-option-id='sale'] img { transform: scale(1.55) !important; }
}
