/* Fieldnote Builders · shared styles */
/* (scene rail dims over the blueprint sheet: see .scene-rail.is-dim below) */
:root {
  --paper: #F4F0E8;
  --paper-2: #ECE6DA;
  --paper-3: #E3DBCC;
  --ink: #1C1B19;
  --stone: #6F685E;
  --line: #D6CEC0;
  --blueprint: #2B4C7E;
  --blueprint-soft: #DCE4EF;
  --dusk: #E9A55B;

  --serif: "Instrument Serif", "Times New Roman", serif;
  --sans: "Albert Sans", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;

  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --gutter: clamp(24px, 6vw, 96px);
  --head-h: 76px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 clamp(16px, 0.3vw + 15px, 18px)/1.65 var(--sans);
  -webkit-font-smoothing: antialiased; overflow-x: clip;
}
h1, h2, h3, p, ol, ul, dl, dd, figure, blockquote { margin: 0; }
ol, ul { padding: 0; list-style: none; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--blueprint); outline-offset: 4px; }
::selection { background: var(--blueprint); color: var(--paper); }
@view-transition { navigation: auto; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: 450ms; }

.skip { position: absolute; left: 12px; top: -60px; z-index: 200; padding: 10px 16px; background: var(--ink); color: var(--paper); text-decoration: none; }
.skip:focus { top: 12px; }
.sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* ---------- type ---------- */
.serif { font-family: var(--serif); font-weight: 400; letter-spacing: -0.01em; line-height: 0.98; }
.serif em, .serif i { font-style: italic; }
.mono { font-family: var(--mono); font-size: 11.5px; letter-spacing: 0.14em; text-transform: uppercase; }
.label { color: var(--blueprint); display: block; margin-bottom: 22px; }
.h-xl { font-size: clamp(56px, 10.5vw, 184px); }
.h-lg { font-size: clamp(44px, 7vw, 120px); }
.h-md { font-size: clamp(34px, 4.6vw, 76px); }
.h-sm { font-size: clamp(28px, 2.8vw, 44px); line-height: 1.05; }
.lede { font-size: clamp(18px, 0.6vw + 15px, 22px); line-height: 1.55; color: var(--stone); max-width: 36rem; }
.fine { font-size: 13px; color: var(--stone); }

/* line-mask reveals (JS splits [data-lines] into .ln > span) */
.ln { display: block; overflow: hidden; padding: 0.1em 0 0.12em; margin: -0.1em 0 -0.12em; }
.ln > span { display: inline-block; will-change: transform; }

/* ---------- buttons & links ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 14px; min-height: 54px; padding: 0 28px;
  border-radius: 999px; border: 1px solid var(--ink); background: var(--ink); color: var(--paper);
  font: 500 15px/1 var(--sans); letter-spacing: 0.01em; text-decoration: none; cursor: pointer;
  transition: background-color 300ms var(--ease-out), color 300ms var(--ease-out), transform 200ms var(--ease-out);
}
.btn:active { transform: scale(0.97); }
.btn .arr { display: inline-block; transition: transform 400ms var(--ease-out); }
.btn-line { background: transparent; color: var(--ink); }
@media (hover: hover) {
  .btn:hover { background: var(--blueprint); border-color: var(--blueprint); color: var(--paper); }
  .btn:hover .arr { transform: translateX(6px); }
}
.link {
  text-decoration: none; background: linear-gradient(currentColor, currentColor) 0 100% / 100% 1px no-repeat;
  transition: background-size 500ms var(--ease-out);
}
@media (hover: hover) { .link:hover { background-size: 0 1px; background-position: 100% 100%; } }

/* ---------- header ---------- */
.head {
  position: fixed; inset: 0 0 auto; z-index: 60; height: var(--head-h);
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 0 var(--gutter); color: var(--ink);
  transition: background-color 400ms var(--ease-out), color 400ms var(--ease-out), transform 500ms var(--ease-out), border-color 400ms;
  border-bottom: 1px solid transparent;
}
.head.is-solid { background: rgb(244 240 232 / 0.82); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); border-bottom-color: var(--line); }
.head.is-hidden { transform: translateY(-100%); }
.head.on-dark:not(.is-solid) { color: var(--paper); }
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: inherit; }
.brand svg { width: 30px; height: 30px; }
.brand-word { font: 400 26px/1 var(--serif); letter-spacing: -0.01em; }
.brand-word i { font-style: italic; }
.nav { display: none; gap: 34px; }
.nav a { font: 500 14px/1 var(--sans); text-decoration: none; padding: 8px 0; position: relative; }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 2px; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform 500ms var(--ease-out); }
.nav a[aria-current="page"]::after { transform: scaleX(1); }
@media (hover: hover) { .nav a:hover::after { transform: scaleX(1); transform-origin: left; } }
.head .btn { display: none; min-height: 44px; padding: 0 20px; }
.head.on-dark:not(.is-solid) .btn { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.menu-btn { display: inline-flex; align-items: center; gap: 10px; height: 44px; background: none; border: 0; color: inherit; cursor: pointer; font: 500 14px/1 var(--sans); padding: 0; }
.menu-btn i { position: relative; width: 22px; height: 8px; }
.menu-btn i::before, .menu-btn i::after { content: ""; position: absolute; left: 0; right: 0; height: 1.5px; background: currentColor; transition: transform 400ms var(--ease-out), top 400ms var(--ease-out); }
.menu-btn i::before { top: 0; } .menu-btn i::after { top: 7px; }
.menu-btn[aria-expanded="true"] i::before { top: 3.5px; transform: rotate(45deg); }
.menu-btn[aria-expanded="true"] i::after { top: 3.5px; transform: rotate(-45deg); }
@media (min-width: 1040px) { .nav, .head .btn { display: inline-flex; } .menu-btn { display: none; } }

.menu {
  position: fixed; inset: 0; z-index: 55; background: var(--paper);
  padding: calc(var(--head-h) + 32px) var(--gutter) 32px;
  display: flex; flex-direction: column; justify-content: space-between;
  clip-path: inset(0 0 100% 0); transition: clip-path 700ms var(--ease-in-out);
}
.menu[hidden] { display: none; }
.menu.is-open { clip-path: inset(0 0 0 0); }
.menu-list a {
  display: flex; align-items: baseline; gap: 16px; text-decoration: none;
  font: 400 clamp(44px, 12vw, 76px)/1.05 var(--serif);
  opacity: 0; transform: translateY(30px); transition: opacity 500ms var(--ease-out), transform 700ms var(--ease-out);
}
.menu-list .mono { color: var(--blueprint); }
.menu.is-open .menu-list a { opacity: 1; transform: none; }
.menu.is-open li:nth-child(2) a { transition-delay: 60ms; } .menu.is-open li:nth-child(3) a { transition-delay: 120ms; }
.menu.is-open li:nth-child(4) a { transition-delay: 180ms; } .menu.is-open li:nth-child(5) a { transition-delay: 240ms; }
.menu-foot { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; color: var(--stone); }
body.menu-open { overflow: hidden; }

/* ---------- generic sections ---------- */
.sec { padding: clamp(120px, 16vw, 240px) var(--gutter) 0; }
.sec-head { display: grid; gap: 28px; margin-bottom: clamp(48px, 7vw, 96px); }
@media (min-width: 960px) { .sec-head.split { grid-template-columns: 7fr 5fr; align-items: end; } }

/* photo with placeholder when the image file isn't there yet */
.ph { position: relative; overflow: hidden; background: var(--paper-3); }
.ph img { width: 100%; height: 100%; object-fit: cover; }
.ph.is-missing img { display: none; }
.ph.is-missing::after {
  content: attr(data-label); position: absolute; inset: 0; display: grid; place-items: center; padding: 16px; text-align: center;
  font: 400 11.5px/1.4 var(--mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--stone);
  background: repeating-linear-gradient(135deg, transparent 0 14px, rgb(28 27 25 / 0.04) 14px 15px), var(--paper-3);
}

/* ---------- footer ---------- */
.foot { margin-top: clamp(120px, 16vw, 240px); padding: clamp(64px, 8vw, 112px) var(--gutter) 40px; background: var(--ink); color: var(--paper); }
.foot-cta { display: grid; gap: 32px; padding-bottom: clamp(64px, 8vw, 112px); border-bottom: 1px solid rgb(244 240 232 / 0.16); }
.foot-cta .serif { font-size: clamp(48px, 9vw, 160px); }
.foot-cta .btn { background: var(--paper); color: var(--ink); border-color: var(--paper); justify-self: start; }
@media (hover: hover) { .foot-cta .btn:hover { background: var(--dusk); border-color: var(--dusk); } }
.foot-grid { display: grid; gap: 32px; padding-top: 40px; color: rgb(244 240 232 / 0.72); font-size: 15px; }
@media (min-width: 900px) { .foot-grid { grid-template-columns: 2fr 1fr 1fr 1fr; } }
.foot-grid .mono { color: rgb(244 240 232 / 0.5); display: block; margin-bottom: 12px; }
.foot-grid a { text-decoration: none; display: block; padding: 2px 0; }
@media (hover: hover) { .foot-grid a:hover { color: var(--paper); } }
.foot-note { margin-top: 48px; font-size: 13px; color: rgb(244 240 232 / 0.5); }

/* ---------- reveal states set by JS (GSAP takes over when present) ---------- */
.js [data-fade] { opacity: 0; }
@media (prefers-reduced-motion: reduce) { .js [data-fade] { opacity: 1; } .menu, .menu-list a { transition: none; } }

/* =========================================================
   Scene: the house builds itself on scroll
   ========================================================= */
.scene { position: relative; height: 100vh; height: 100svh; }
.scene-pin { position: relative; height: 100vh; height: 100svh; overflow: hidden; background: var(--paper-3); }
.scene-cam { position: absolute; inset: 0; transform-origin: 50% 62%; will-change: transform; }
.frame { position: absolute; inset: 0; margin: 0; }
.frame img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; }
.frame.is-missing::after { font-size: 13px; }
.frame[data-stage="0"].is-missing::after { background: linear-gradient(#DCE6EC 0 52%, #CFC3A6 52%), var(--paper-3); }
.frame[data-stage="2"].is-missing::after { background: linear-gradient(#DCE6EC 0 52%, #BDB8AE 52%); }
.frame[data-stage="3"].is-missing::after { background: linear-gradient(#DCE6EC 0 52%, #C9A57C 52%); }
.frame[data-stage="4"].is-missing::after { background: linear-gradient(#CFE0EA 0 52%, #E8E1D2 52%); }
.frame[data-stage="5"].is-missing::after { background: linear-gradient(#1F2C47 0 52%, #3A3328 52%); color: var(--dusk); }
.js .frame:not([data-stage="0"]) { clip-path: inset(100% 0 0 0); }
.js .frame[data-stage="5"] { clip-path: none; opacity: 0; }
.scene-shade { position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to top, rgb(28 27 25 / 0.42), rgb(28 27 25 / 0) 45%), linear-gradient(to bottom, rgb(244 240 232 / 0.55), rgb(244 240 232 / 0) 22%); }

.bp-wash { position: absolute; inset: 0; background: #1B3A6B; mix-blend-mode: multiply; opacity: 0; pointer-events: none; }
.blueprint { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.bp-line { fill: none; stroke: #F4F0E8; stroke-width: 1.6; vector-effect: non-scaling-stroke; stroke-linecap: round; stroke-linejoin: round; }
.bp-line.thin { stroke-width: 1; stroke-opacity: 0.85; }
.bp-text { fill: #F4F0E8; font: 500 10.5px var(--mono); letter-spacing: 0.12em; }
.bp-c { text-anchor: middle; }
.bp-big { font-size: 20px; letter-spacing: 0.06em; }
.js .bp-line { stroke-dasharray: 1; stroke-dashoffset: 1; }
.js .bp-fade { opacity: 0; }

.scene-titles { position: absolute; left: var(--gutter); right: var(--gutter); bottom: clamp(32px, 7vh, 80px); pointer-events: none; color: var(--paper); }
.st { position: absolute; left: 0; bottom: 0; max-width: 980px; }
.st .mono { color: rgb(244 240 232 / 0.8); margin-bottom: 18px; display: block; }
.st .serif { font-size: clamp(44px, 7.4vw, 128px); text-shadow: 0 2px 40px rgb(28 27 25 / 0.25); }
.st p:last-child { margin-top: 16px; max-width: 30rem; color: rgb(244 240 232 / 0.88); }
.js .st:not(:first-child) { visibility: hidden; }
.st:first-child .serif { font-size: clamp(56px, 10vw, 176px); }

.scene-rail { position: absolute; right: var(--gutter); top: 50%; transform: translateY(-50%); display: none; gap: 2px; color: var(--paper); }
@media (min-width: 900px) { .scene-rail { display: grid; } }
.scene-rail button {
  display: flex; align-items: center; justify-content: flex-end; gap: 12px; padding: 7px 0; background: none; border: 0; cursor: pointer;
  color: rgb(244 240 232 / 0.55); font: 400 11px/1 var(--mono); letter-spacing: 0.14em; text-transform: uppercase; transition: color 300ms;
}
.scene-rail button::after { content: ""; width: 18px; height: 1px; background: currentColor; transition: width 500ms var(--ease-out); }
.scene-rail button.on { color: var(--paper); }
.scene-rail button.on::after { width: 44px; }
@media (hover: hover) { .scene-rail button:hover { color: var(--paper); } }
.scene-hint { position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%); color: rgb(244 240 232 / 0.85); display: flex; flex-direction: column; align-items: center; gap: 10px; }
.scene-hint::after { content: ""; width: 1px; height: 36px; background: linear-gradient(currentColor, transparent); animation: hint 2.2s var(--ease-in-out) infinite; transform-origin: top; }
@keyframes hint { 0% { transform: scaleY(0); } 50% { transform: scaleY(1); } 100% { transform: scaleY(1); opacity: 0; } }

@media (prefers-reduced-motion: reduce) {
  .scene, .scene-pin { height: auto; }
  .scene-pin { display: grid; gap: 0; background: none; }
  .scene-cam { position: relative; display: grid; gap: 8px; }
  .frame { position: relative; aspect-ratio: 16 / 9; clip-path: none !important; opacity: 1 !important; }
  .blueprint, .bp-wash, .scene-rail, .scene-hint, .scene-shade { display: none; }
  .scene-titles { position: static; color: var(--ink); padding: 48px 0; display: grid; gap: 40px; }
  .st { position: static; visibility: visible !important; }
  .st .mono, .st p:last-child { color: var(--stone); }
  .st .serif { text-shadow: none; }
}

/* ---------- home sections ---------- */
.pr-list { border-top: 1px solid var(--line); }
.pr { display: grid; gap: 16px 40px; padding: clamp(36px, 5vw, 64px) 0; border-bottom: 1px solid var(--line); }
.pr .mono { color: var(--blueprint); padding-top: 14px; }
.pr p { color: var(--stone); max-width: 30rem; }
@media (min-width: 960px) { .pr { grid-template-columns: 1fr 6fr 4fr; align-items: baseline; } }

.ht-grid { display: grid; gap: 28px; }
@media (min-width: 960px) { .ht-grid { grid-template-columns: 7fr 5fr; grid-template-rows: auto auto; gap: 28px 40px; } .ht.big { grid-row: 1 / 3; } }
.ht { display: grid; gap: 16px; text-decoration: none; }
.ht-img { aspect-ratio: 4 / 3; }
.ht.big .ht-img { aspect-ratio: 4 / 5; }
@media (max-width: 959.98px) { .ht.big .ht-img { aspect-ratio: 4 / 3; } }
.ht-meta { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px 20px; }
.ht-meta .mono { color: var(--stone); }
a.ht .ht-img img { transition: transform 1.2s var(--ease-out); }
@media (hover: hover) { a.ht:hover .ht-img img { transform: scale(1.04); } }

.pt { display: grid; gap: 28px; justify-items: start; max-width: 1100px; }

/* ---------- inner page tops ---------- */
.page-top { padding-top: calc(var(--head-h) + clamp(80px, 12vw, 180px)); }

/* ---------- homes list ---------- */
.hm-list { display: grid; gap: clamp(96px, 12vw, 180px); }
.hm { display: grid; gap: 32px; text-decoration: none; align-items: center; }
@media (min-width: 960px) {
  .hm { grid-template-columns: 7fr 5fr; gap: clamp(40px, 6vw, 96px); }
  .hm:nth-child(even) { grid-template-columns: 5fr 7fr; }
  .hm:nth-child(even) .hm-img { order: 2; }
}
.hm-img { aspect-ratio: 4 / 3; }
.hm-text { display: grid; gap: 20px; justify-items: start; }
.hm-text .mono:first-child { color: var(--blueprint); }
.hm-facts { color: var(--stone); }
.hm-soon { color: var(--stone); }
a.hm .hm-img img { transition: transform 1.4s var(--ease-out); }
@media (hover: hover) { a.hm:hover .hm-img img { transform: scale(1.04); } }

/* ---------- house case ---------- */
.case-hero { position: relative; height: 100vh; height: 100svh; min-height: 600px; }
.case-hero-img { position: absolute; inset: 0; }
.case-hero-img.is-missing::after { background: linear-gradient(#CFE0EA 0 52%, #E8E1D2 52%); }
.case-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgb(28 27 25 / 0.5), transparent 50%); pointer-events: none; }
.case-hero-text { position: absolute; left: var(--gutter); right: var(--gutter); bottom: clamp(40px, 8vh, 96px); z-index: 1; color: var(--paper); }
.case-hero-text .label { color: rgb(244 240 232 / 0.85); }
.facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 24px; border-top: 1px solid var(--line); padding-top: 32px; }
@media (min-width: 900px) { .facts { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.facts dt { color: var(--blueprint); margin-bottom: 8px; }
.facts dd { font: 400 clamp(20px, 1.6vw, 26px)/1.25 var(--serif); }
.story { display: grid; gap: 18px; color: var(--stone); max-width: 36rem; }

/* floor plan */
.plan { display: grid; gap: 32px; align-items: start; }
@media (min-width: 1000px) { .plan { grid-template-columns: 6fr 5fr; gap: clamp(40px, 5vw, 80px); } .plan-view { position: sticky; top: calc(var(--head-h) + 24px); } }
.plan-draw { background: var(--blueprint-soft); padding: clamp(16px, 2.4vw, 32px); }
.plan-svg { display: block; width: 100%; height: auto; overflow: visible; }
.plan-wall { fill: none; stroke: var(--blueprint); stroke-width: 6; }
.room-static, .room rect { fill: transparent; stroke: var(--blueprint); stroke-width: 1.5; }
.room-static { fill: url(#hatch); }
.room { cursor: pointer; outline: none; }
.room rect { transition: fill 350ms var(--ease-out); }
.room.on rect, .room:focus-visible rect { fill: rgb(43 76 126 / 0.9); }
.room.on .plan-label, .room.on .plan-dim, .room:focus-visible .plan-label, .room:focus-visible .plan-dim { fill: var(--paper); }
.room:focus-visible rect { stroke: var(--ink); stroke-width: 3; }
@media (hover: hover) { .room:hover:not(.on) rect { fill: rgb(43 76 126 / 0.14); } }
.plan-label { fill: var(--blueprint); font: 500 13px var(--mono); letter-spacing: 0.14em; text-anchor: middle; transition: fill 300ms; pointer-events: none; }
.plan-dim { fill: var(--blueprint); font: 400 12px var(--mono); text-anchor: middle; opacity: 0.8; pointer-events: none; }
.plan-door, .plan-dimline { fill: none; stroke: var(--blueprint); stroke-width: 1.2; }
.plan-north circle, .plan-north path { fill: none; stroke: var(--blueprint); stroke-width: 1.2; }
.plan-photos { position: relative; aspect-ratio: 4 / 3; }
.plan-photo { position: absolute; inset: 0; opacity: 0; clip-path: inset(0 0 0 100%); transition: opacity 600ms var(--ease-out), clip-path 900ms var(--ease-in-out); }
.plan-photo.on { opacity: 1; clip-path: inset(0 0 0 0); }
.plan-cap { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px 16px; margin-top: 16px; }
.plan-cap .mono { color: var(--stone); }

.mats { display: grid; gap: 0; border-top: 1px solid var(--line); }
@media (min-width: 900px) { .mats { grid-template-columns: repeat(4, 1fr); border-top: 0; } .mats li { border-left: 1px solid var(--line); padding: 8px 28px 0; } .mats li:first-child { border-left: 0; padding-left: 0; } }
.mats li { display: grid; gap: 12px; align-content: start; padding: 28px 0; border-bottom: 1px solid var(--line); }
@media (min-width: 900px) { .mats li { border-bottom: 0; } }
.mats .mono { color: var(--blueprint); }
.mats p { color: var(--stone); }
.next { display: grid; gap: 8px; text-decoration: none; padding-top: 48px; border-top: 1px solid var(--line); }
.next .arr { display: inline-block; transition: transform 600ms var(--ease-out); }
@media (hover: hover) { .next:hover .arr { transform: translateX(24px); } .next:hover .serif { color: var(--blueprint); } }

/* ---------- process: horizontal track ---------- */
.hscroll { margin-top: clamp(80px, 10vw, 140px); }
.hs-pin { position: relative; overflow: hidden; padding: 0 var(--gutter); }
.hs-track { display: flex; gap: clamp(24px, 4vw, 64px); width: max-content; padding-bottom: 8px; }
.pp { width: clamp(300px, 34vw, 520px); display: grid; gap: 16px; align-content: start; }
.pp-img { aspect-ratio: 4 / 5; }
.pp-when { color: var(--blueprint); margin-top: 8px; }
.pp-n { font-family: var(--mono); font-size: 14px; color: var(--blueprint); vertical-align: super; margin-right: 6px; }
.pp p { color: var(--stone); max-width: 28rem; }
.hs-bar { height: 1px; background: var(--line); margin-bottom: 32px; position: relative; }
.hs-fill { position: absolute; inset: 0; background: var(--blueprint); transform-origin: left; transform: scaleX(0); }
.no-hs .hs-pin { overflow-x: auto; scroll-snap-type: x mandatory; }
.no-hs .pp { scroll-snap-align: start; }
@media (max-width: 899.98px) {
  .hs-pin { overflow: visible; }
  .hs-track { flex-direction: column; width: auto; gap: 64px; }
  .pp { width: 100%; }
  .hs-bar { display: none; }
}

/* ---------- studio ---------- */
.towns { border-top: 1px solid var(--line); }
.towns li { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px 24px; padding: 22px 0; border-bottom: 1px solid var(--line); }
.towns .mono { color: var(--stone); }
.contact-grid { display: grid; gap: 56px; }
@media (min-width: 1000px) { .contact-grid { grid-template-columns: 5fr 6fr; gap: clamp(48px, 6vw, 112px); align-items: start; } }
.form { display: grid; gap: 24px; }
.field { display: grid; gap: 8px; border: 0; padding: 0; margin: 0; min-width: 0; }
.field label, .field legend { font-weight: 500; padding: 0; }
.field label span { color: var(--stone); font-weight: 400; }
.field input:not([type=radio]), .field select, .field textarea {
  width: 100%; min-height: 54px; padding: 14px 0; border: 0; border-bottom: 1px solid var(--ink); border-radius: 0;
  background: transparent; color: var(--ink); font: 400 18px/1.4 var(--sans);
  transition: border-color 300ms;
}
.field textarea { resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-bottom: 2px solid var(--blueprint); }
.field input::placeholder, .field textarea::placeholder { color: #9A9184; }
.field [aria-invalid="true"] { border-bottom-color: #A23B2A; }
.err { color: #A23B2A; font-size: 14px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.chips label { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 18px; border: 1px solid var(--ink); border-radius: 999px; cursor: pointer; font-weight: 400; transition: background-color 250ms, color 250ms; }
.chips input { position: absolute; opacity: 0; pointer-events: none; }
.chips label:has(input:checked) { background: var(--ink); color: var(--paper); }
.chips label:has(input:focus-visible) { outline: 2px solid var(--blueprint); outline-offset: 3px; }
.form .btn { justify-self: start; margin-top: 8px; }
.form-status { min-height: 1.6em; font-size: 17px; }
.form-status.ok { color: var(--blueprint); }
@media (max-width: 699.98px) { .scene-hint { display: none; } }

.scene-rail { transition: opacity 400ms var(--ease-out); }
.scene-rail.is-dim { opacity: 0.18; }

/* word between the dusk sky and the house (front layer = same photo with the sky cut out) */
.sky-word { position: absolute; inset: 0; display: grid; justify-items: center; align-content: start; padding-top: 11vh; pointer-events: none; }
.sky-word span {
  font: italic 400 clamp(84px, 16.5vw, 330px)/0.85 var(--serif); letter-spacing: -0.02em;
  color: #F6E7D0; white-space: nowrap; will-change: transform;
}
.frame-front {
  position: absolute; inset: 0; opacity: 0; pointer-events: none;
  background: image-set(url("../assets/img/scene-05-dusk-1376.jpg") 1x, url("../assets/img/scene-05-dusk.jpg") 2x) 50% 50% / cover no-repeat;
  -webkit-mask: url("../assets/img/house-mask.png") 50% 50% / cover no-repeat;
          mask: url("../assets/img/house-mask.png") 50% 50% / cover no-repeat;
}
.js .sky-word span { transform: translateY(100vh); }
@media (prefers-reduced-motion: reduce) { .sky-word, .frame-front { display: none; } }
@media (max-width: 699.98px) { .sky-word { padding-top: 12vh; } .sky-word span { white-space: normal; text-align: center; font-size: 23vw; line-height: 0.9; } }
@media (max-width: 699.98px) { .sky-word span { max-width: 5.2ch; display: block; } }
@media (min-width: 900px) { .pp { width: max(280px, min(30vw, 56vh, 480px)); } .pp-img { aspect-ratio: 1 / 1; } }
.js .sky-word span { visibility: hidden; }

/* process cards size to the window height, so title and text always fit under the photo */
@media (min-width: 900px) {
  .hs-track { padding-right: var(--gutter); }
  .pp { width: max(240px, min(32vw, calc((100vh - 360px) * 1.3333), 520px)); gap: 12px; }
  .pp-img { aspect-ratio: 4 / 3; }
  .pp .h-md { font-size: clamp(30px, min(3.2vw, 6vh), 56px); }
  .pp p { font-size: 16px; line-height: 1.5; }
  .hs-bar { margin-bottom: 24px; }
}
