/* ============================================================
   NORDHAUS - sharp light editorial design system
   No border-radius anywhere. Hard lines, generous whitespace.
   ============================================================ */

:root {
  --paper: #f6f4ef;
  --paper-2: #efece4;
  --card: #fffdf8;
  --ink: #161512;
  --ink-soft: #3f3c36;
  --muted: #8a857b;
  --line: #dcd7cc;
  --line-dark: #b9b3a6;
  --accent: #1e4636;
  --accent-deep: #0f2a1f;
  /* Type: sharp grotesque display + clean sans body. No serif. */
  --display: 'Archivo', 'Inter', -apple-system, sans-serif;
  --serif: var(--display); /* legacy alias - every old reference now renders the sans display face */
  --sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; border-radius: 0 !important; }

html { scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection { background: var(--accent); color: var(--paper); }

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

.container { max-width: 1280px; margin: 0 auto; padding: 0 32px; }

/* ---------- typography helpers ---------- */

.label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--muted);
}

.label--accent { color: var(--accent); }

.h-serif { font-family: var(--serif); font-weight: 400; line-height: 1.08; }

.section-head { margin-bottom: 64px; }
.section-head .label { display: block; margin-bottom: 20px; }
.section-head h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(34px, 4.6vw, 58px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  max-width: 16em;
}
.section-head h2 em { font-style: italic; color: var(--accent); }

.section { padding: 128px 0; }
.section--tight { padding: 96px 0; }

.rule { border: 0; border-top: 1px solid var(--line); }

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 16px 28px;
  border: 1px solid var(--ink);
  background: transparent;
  color: var(--ink);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  transition: background 0.3s var(--ease), color 0.3s var(--ease), border-color 0.3s var(--ease);
}
.btn:hover { background: var(--ink); color: var(--paper); }

.btn--solid { background: var(--ink); color: var(--paper); }
.btn--solid:hover { background: var(--accent); border-color: var(--accent); color: var(--paper); }

.btn--light { border-color: var(--paper); color: var(--paper); }
.btn--light:hover { background: var(--paper); color: var(--ink); }

.btn--solid-light { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.btn--solid-light:hover { background: transparent; color: var(--paper); }

.btn .arrow { transition: transform 0.3s var(--ease); }
.btn:hover .arrow { transform: translateX(6px); }

/* ---------- navigation ---------- */

.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  transition: background 0.35s var(--ease), border-color 0.35s var(--ease), transform 0.35s var(--ease), padding 0.5s var(--ease);
  border-bottom: 1px solid transparent;
}
.site-nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
  max-width: 1440px;
  transition: max-width 0.55s var(--ease), height 0.5s var(--ease), padding 0.5s var(--ease),
              background 0.4s var(--ease), border-color 0.4s var(--ease), box-shadow 0.5s var(--ease);
  border: 1px solid transparent;
}
.nav-brand { display: flex; align-items: center; gap: 14px; }
.nav-brand img { width: 30px; height: 30px; }
.nav-brand .wordmark {
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 600;
  letter-spacing: 0.34em;
  text-transform: uppercase;
}
.nav-links { display: flex; align-items: center; gap: 40px; list-style: none; }
.nav-links a {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  position: relative;
  padding: 6px 0;
}
.nav-links a::after {
  content: '';
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.35s var(--ease);
}
.nav-links a:hover::after, .nav-links a.active::after { transform: scaleX(1); transform-origin: left; }
.nav-cta { border: 1px solid currentColor; padding: 10px 20px !important; }
.nav-cta::after { display: none; }
.nav-cta:hover { background: var(--ink); color: var(--paper) !important; border-color: var(--ink); }

/* nav over hero video = light text; scrolled = paper bg, ink text */
.site-nav.on-hero { color: #fdfcf9; }
.site-nav.on-hero .nav-brand img { filter: invert(1) brightness(2); }
/* scrolled = a floating "island" pill that detaches from the top edge */
.site-nav.scrolled {
  background: transparent;
  border-bottom-color: transparent;
  color: var(--ink);
  padding-top: 16px;
}
.site-nav.scrolled .container {
  height: 60px;
  max-width: 1120px;
  padding-left: 26px;
  padding-right: 14px;
  background: rgba(246, 244, 239, 0.82);
  backdrop-filter: blur(16px) saturate(1.4);
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  border-color: var(--line);
  box-shadow: 0 20px 50px -22px rgba(20, 18, 15, 0.4), 0 2px 8px rgba(20, 18, 15, 0.05);
}
.site-nav.scrolled .nav-brand img { filter: none; }
.site-nav.scrolled .nav-cta:hover { background: var(--ink); color: var(--paper) !important; }

.nav-burger {
  display: none;
  background: none;
  border: 1px solid currentColor;
  color: inherit;
  width: 44px; height: 44px;
  position: relative;
}
.nav-burger span, .nav-burger span::before, .nav-burger span::after {
  content: '';
  position: absolute;
  left: 11px; right: 11px;
  height: 1.5px;
  background: currentColor;
  transition: transform 0.3s var(--ease), opacity 0.3s;
}
.nav-burger span { top: 50%; }
.nav-burger span::before { left: 0; right: 0; top: -7px; }
.nav-burger span::after { left: 0; right: 0; top: 7px; }
body.nav-open .nav-burger span { background: transparent; }
body.nav-open .nav-burger span::before { transform: translateY(7px) rotate(45deg); }
body.nav-open .nav-burger span::after { transform: translateY(-7px) rotate(-45deg); }

.mobile-menu {
  display: none;
  position: fixed;
  top: 76px; left: 0; right: 0;
  z-index: 99;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  padding: 24px 32px 40px;
}
body.nav-open .mobile-menu { display: block; }
.mobile-menu a {
  display: block;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  font-family: var(--serif);
  font-size: 24px;
}

/* ---------- hero scroll animation ---------- */

.hero-scroll { position: relative; height: 460vh; background: var(--ink); }
.hero-sticky { position: sticky; top: 0; height: 100vh; overflow: hidden; }
.hero-canvas { position: absolute; inset: 0; width: 100%; height: 100%; }

.hero-grad-top {
  position: absolute; top: 0; left: 0; right: 0; height: 22vh;
  background: linear-gradient(to bottom, rgba(10, 10, 9, 0.42), transparent);
  pointer-events: none;
}
.hero-grad-bottom {
  position: absolute; bottom: 0; left: 0; right: 0; height: 34vh;
  background: linear-gradient(to top, rgba(10, 10, 9, 0.5), transparent);
  pointer-events: none;
}

.beat {
  position: absolute;
  z-index: 10;
  color: #fdfcf9;
  opacity: 0;
  filter: blur(8px);
  transform: translateY(24px);
  transition: opacity 0.7s var(--ease), filter 0.7s var(--ease), transform 0.7s var(--ease);
  pointer-events: none;
}
.beat.visible { opacity: 1; filter: blur(0); transform: translateY(0); pointer-events: auto; }

.beat--hero { left: 0; right: 0; bottom: 10vh; }
.beat--hero .label { color: rgba(253, 252, 249, 0.75); margin-bottom: 22px; display: block; }
.beat--hero h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(54px, 9vw, 128px);
  line-height: 0.98;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.beat--hero .tagline {
  margin-top: 24px;
  font-size: clamp(15px, 1.4vw, 19px);
  font-weight: 300;
  letter-spacing: 0.04em;
  color: rgba(253, 252, 249, 0.85);
  max-width: 34em;
}

.beat--mid { left: 0; right: 0; top: 50%; transform: translateY(calc(-50% + 24px)); text-align: center; }
.beat--mid.visible { transform: translateY(-50%); }
.beat--mid blockquote {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 300;
  font-size: clamp(26px, 3.6vw, 48px);
  line-height: 1.25;
  max-width: 22em;
  margin: 0 auto;
}
.beat--mid .label { display: block; margin-top: 28px; color: rgba(253, 252, 249, 0.7); }

.beat--end { left: 0; right: 0; bottom: 12vh; text-align: center; }
.beat--end p {
  font-family: var(--serif);
  font-size: clamp(20px, 2.4vw, 32px);
  font-style: italic;
}

.scroll-cue {
  position: absolute;
  right: 48px; bottom: 4vh;
  z-index: 11;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  color: rgba(253, 252, 249, 0.8);
  transition: opacity 0.5s;
}
.scroll-cue .label { color: inherit; writing-mode: vertical-rl; }
.scroll-cue .line { width: 1px; height: 64px; background: rgba(253, 252, 249, 0.4); position: relative; overflow: hidden; }
.scroll-cue .line::after {
  content: '';
  position: absolute;
  left: 0; top: -40%;
  width: 100%; height: 40%;
  background: #fdfcf9;
  animation: cue-drop 1.8s var(--ease) infinite;
}
@keyframes cue-drop { 0% { top: -40%; } 100% { top: 110%; } }
.hero-scroll.done .scroll-cue { opacity: 0; }

.hero-progress {
  position: absolute;
  left: 48px; bottom: 4vh;
  z-index: 11;
  display: flex;
  align-items: center;
  gap: 16px;
  color: rgba(253, 252, 249, 0.8);
}
.hero-progress .track { width: 120px; height: 1px; background: rgba(253, 252, 249, 0.3); }
.hero-progress .fill { height: 100%; width: 0%; background: #fdfcf9; }
.hero-progress .pct { font-size: 11px; letter-spacing: 0.2em; min-width: 4ch; }

/* ---------- about ---------- */

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 96px;
  align-items: start;
}
.about-copy .lede {
  font-family: var(--serif);
  font-size: clamp(22px, 2.2vw, 30px);
  line-height: 1.4;
  margin-bottom: 32px;
}
.about-copy p + p { margin-top: 20px; color: var(--ink-soft); }
.about-media { position: relative; }
.about-media img { width: 100%; aspect-ratio: 16 / 11; object-fit: cover; border: 1px solid var(--line); }
.about-media .caption {
  margin-top: 14px;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.stat-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
  margin-top: 96px;
}
.stat { border-top: 1px solid var(--ink); padding-top: 20px; }
.stat .num {
  font-family: var(--serif);
  font-size: clamp(34px, 3.4vw, 52px);
  font-weight: 400;
  line-height: 1;
}
.stat .num sup { font-size: 0.5em; color: var(--accent); }
.stat .desc { margin-top: 10px; font-size: 13px; color: var(--muted); letter-spacing: 0.06em; }

/* ---------- listing cards ---------- */

.cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.card {
  background: var(--card);
  border: 1px solid var(--line);
  transition: border-color 0.35s var(--ease), transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
  cursor: pointer;
  display: flex;
  flex-direction: column;
}
.card:hover { border-color: var(--ink); transform: translateY(-4px); box-shadow: 0 18px 40px -24px rgba(22, 21, 18, 0.35); }
.card-media { overflow: hidden; position: relative; }
.card-media img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  transition: transform 0.7s var(--ease);
}
.card:hover .card-media img { transform: scale(1.045); }
.card-media .status {
  position: absolute;
  top: 0; left: 0;
  background: var(--paper);
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 8px 14px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}
.card-media .status--sold { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.card-body { padding: 26px 26px 30px; flex: 1; display: flex; flex-direction: column; }
.card-body .loc { font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.card-body h3 { font-family: var(--serif); font-weight: 500; font-size: 24px; line-height: 1.15; }
.card-body .price { margin-top: 8px; font-size: 17px; font-weight: 600; color: var(--accent); letter-spacing: 0.02em; }
.card-specs {
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  display: flex;
  gap: 0;
  font-size: 12.5px;
  color: var(--ink-soft);
}
.card-specs span { flex: 1; }
.card-specs span + span { border-left: 1px solid var(--line); padding-left: 14px; margin-left: 14px; }
.card-cta {
  margin-top: 22px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
}
.card-cta .arrow { transition: transform 0.3s var(--ease); }
.card:hover .card-cta .arrow { transform: translateX(6px); }

.listings-head-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 40px;
  margin-bottom: 64px;
}
.listings-head-row .section-head { margin-bottom: 0; }

/* ---------- process (scroll-animated) ---------- */

.process { background: var(--paper-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.process-grid {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: 96px;
  align-items: start;
}
.process-sticky { position: sticky; top: 140px; }
.process-sticky p.intro { margin-top: 28px; color: var(--ink-soft); max-width: 26em; }

.steps { position: relative; padding-left: 48px; }
.steps .steps-line {
  position: absolute;
  left: 0; top: 8px; bottom: 8px;
  width: 1px;
  background: var(--line-dark);
}
.steps .steps-line .steps-fill {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  background: var(--accent);
  transform: scaleY(0);
  transform-origin: top;
}
.step { padding: 36px 0; border-bottom: 1px solid var(--line); position: relative; }
.step:last-child { border-bottom: 0; }
.step::before {
  content: '';
  position: absolute;
  left: -48px; top: 52px;
  width: 9px; height: 9px;
  margin-left: -4px;
  background: var(--paper-2);
  border: 1px solid var(--line-dark);
  transition: background 0.4s var(--ease), border-color 0.4s var(--ease), transform 0.4s var(--ease);
}
.step.reached::before { background: var(--accent); border-color: var(--accent); transform: scale(1.25); }
.step .num {
  font-family: var(--serif);
  font-style: italic;
  font-size: 15px;
  color: var(--accent);
  letter-spacing: 0.1em;
}
.step h3 { font-family: var(--serif); font-weight: 500; font-size: 26px; margin: 10px 0 12px; }
.step p { color: var(--ink-soft); max-width: 34em; }

/* ---------- FAQ ---------- */

.faq-list { border-top: 1px solid var(--ink); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-q {
  width: 100%;
  background: none;
  border: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  text-align: left;
  padding: 28px 0;
  color: var(--ink);
}
.faq-q h3 { font-family: var(--serif); font-weight: 500; font-size: clamp(18px, 2vw, 24px); }
.faq-icon { position: relative; width: 16px; height: 16px; flex: none; }
.faq-icon::before, .faq-icon::after {
  content: '';
  position: absolute;
  background: var(--ink);
  transition: transform 0.35s var(--ease);
}
.faq-icon::before { left: 0; right: 0; top: 7px; height: 2px; }
.faq-icon::after { top: 0; bottom: 0; left: 7px; width: 2px; }
.faq-item.open .faq-icon::after { transform: scaleY(0); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height 0.5s var(--ease); }
.faq-a p { padding: 0 0 28px; color: var(--ink-soft); max-width: 52em; }

/* ---------- contact ---------- */

.contact { background: var(--ink); color: var(--paper); }
.contact .section-head h2 { color: var(--paper); }
.contact .label { color: rgba(246, 244, 239, 0.6); }
.contact-grid { display: grid; grid-template-columns: 7fr 5fr; gap: 96px; }

.field { margin-bottom: 28px; }
.field label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(246, 244, 239, 0.65);
  margin-bottom: 10px;
}
.field input, .field textarea, .field select {
  width: 100%;
  background: transparent;
  border: 1px solid rgba(246, 244, 239, 0.28);
  color: var(--paper);
  padding: 16px;
  font-family: var(--sans);
  font-size: 15px;
  transition: border-color 0.3s;
}
.field input:focus, .field textarea:focus, .field select:focus { outline: none; border-color: var(--paper); }
.field textarea { min-height: 140px; resize: vertical; }

.contact-info .info-block { border-top: 1px solid rgba(246, 244, 239, 0.25); padding: 24px 0; }
.contact-info .info-block .label { margin-bottom: 8px; display: block; }
.contact-info .info-block p { font-size: 17px; line-height: 1.5; }
.contact-info .info-block a:hover { text-decoration: underline; text-underline-offset: 4px; }

.form-success {
  display: none;
  border: 1px solid rgba(246, 244, 239, 0.35);
  padding: 32px;
}
.form-success h3 { font-family: var(--serif); font-size: 24px; margin-bottom: 8px; }
form.sent .form-fields { display: none; }
form.sent .form-success { display: block; }

/* ---------- footer ---------- */

.site-footer { background: var(--paper-2); border-top: 1px solid var(--line); padding: 56px 0; }
.footer-row { display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.footer-brand { display: flex; align-items: center; gap: 12px; }
.footer-brand img { width: 24px; height: 24px; }
.footer-brand span { font-family: var(--serif); letter-spacing: 0.3em; font-weight: 600; font-size: 14px; }
.site-footer .legal { font-size: 12.5px; color: var(--muted); }
.footer-links { display: flex; gap: 28px; font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; }
.footer-links a:hover { color: var(--accent); }

/* ---------- listing modal ---------- */

.modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 4vh 4vw;
}
.modal.open { display: flex; }
.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(18, 17, 15, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.modal-panel {
  position: relative;
  background: var(--paper);
  border: 1px solid var(--ink);
  width: min(1080px, 100%);
  max-height: 92vh;
  overflow-y: auto;
  animation: modal-in 0.45s var(--ease);
}
@keyframes modal-in {
  from { opacity: 0; transform: translateY(28px); }
  to { opacity: 1; transform: translateY(0); }
}
.modal-close {
  position: sticky;
  top: 0;
  margin-left: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 52px; height: 52px;
  background: var(--ink);
  color: var(--paper);
  border: 0;
  font-size: 20px;
  z-index: 5;
  float: right;
}
.modal-close:hover { background: var(--accent); }
.modal-hero { position: relative; }
.modal-hero img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.modal-content { padding: 48px; }
.modal-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 40px; flex-wrap: wrap; border-bottom: 1px solid var(--line); padding-bottom: 28px; }
.modal-head .loc { font-size: 11px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.modal-head h2 { font-family: var(--serif); font-weight: 500; font-size: clamp(28px, 3.4vw, 44px); line-height: 1.05; }
.modal-head .price { font-family: var(--serif); font-size: clamp(24px, 2.6vw, 34px); color: var(--accent); white-space: nowrap; }
.modal-specs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-bottom: 1px solid var(--line);
}
.modal-specs .spec { padding: 22px 8px 22px 0; }
.modal-specs .spec + .spec { border-left: 1px solid var(--line); padding-left: 22px; }
.modal-specs .spec .label { display: block; margin-bottom: 6px; font-size: 10px; }
.modal-specs .spec .val { font-family: var(--serif); font-size: 22px; }
.modal-desc { padding: 32px 0; color: var(--ink-soft); max-width: 62em; border-bottom: 1px solid var(--line); }
.modal-desc p + p { margin-top: 16px; }

.inquiry { padding-top: 36px; }
.inquiry h3 { font-family: var(--serif); font-weight: 500; font-size: 26px; margin-bottom: 6px; }
.inquiry .sub { color: var(--muted); font-size: 14px; margin-bottom: 28px; }
.inquiry .field label { color: var(--muted); }
.inquiry .field input, .inquiry .field textarea {
  border-color: var(--line-dark);
  color: var(--ink);
}
.inquiry .field input:focus, .inquiry .field textarea:focus { border-color: var(--ink); }
.inquiry .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.inquiry .form-success { border-color: var(--accent); color: var(--ink); }
.inquiry .form-success h3 { color: var(--accent); }

body.modal-open { overflow: hidden; }

/* ---------- page hero (listings page) ---------- */

.page-hero { padding: 200px 0 96px; border-bottom: 1px solid var(--line); }
.page-hero h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(44px, 6.5vw, 88px);
  line-height: 1;
  letter-spacing: -0.01em;
}
.page-hero h1 em { font-style: italic; color: var(--accent); }
.page-hero .sub { margin-top: 24px; color: var(--ink-soft); max-width: 40em; font-size: 17px; }
.page-hero .label { display: block; margin-bottom: 24px; }

/* ---------- reveal animations ---------- */

.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
}
.reveal.in { opacity: 1; transform: translateY(0); }
.reveal-d1 { transition-delay: 0.1s; }
.reveal-d2 { transition-delay: 0.2s; }
.reveal-d3 { transition-delay: 0.3s; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .beat { transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- responsive ---------- */

@media (max-width: 1080px) {
  .cards-grid { grid-template-columns: repeat(2, 1fr); }
  .process-grid { grid-template-columns: 1fr; gap: 56px; }
  .process-sticky { position: static; }
  .contact-grid { grid-template-columns: 1fr; gap: 64px; }
  .about-grid { grid-template-columns: 1fr; gap: 56px; }
  .stat-row { grid-template-columns: repeat(2, 1fr); gap: 32px; }
}

/* ---------- mobile hardening (phones only; desktop is untouched) ---------- */
@media (max-width: 820px) {
  /* Pin the scroll-video to the SMALL viewport height. On iOS/Android the
     address bar hides & shows while you scroll, resizing 100vh continuously —
     that resized the canvas mid-scroll and made the whole journey judder.
     svh never changes, so the pinned frame stays rock-steady. Falls back to
     the base 100vh on browsers without svh support. */
  .hero-sticky { height: 100svh; }
  /* Shorter journeys on phones: a small screen turned 720vh / 1000vh into an
     endless swipe. These cover the same frame range and story beats over far
     less finger-scrolling (overrides the inline desktop heights, phones only). */
  #heroScroll { height: 440vh !important; }
  #riseScroll { height: 560vh !important; }
  /* Animating filter: blur is one of the most expensive things a mobile GPU can
     do per frame. Drop it from the beat reveal on phones — fade + slide only. */
  .beat { filter: none; transition: opacity 0.6s var(--ease), transform 0.6s var(--ease); }
  .beat.visible { filter: none; }
  /* the island glides during scroll; a lighter blur keeps mobile GPUs smooth */
  .site-nav.scrolled .container {
    background: rgba(246, 244, 239, 0.92);
    backdrop-filter: blur(9px) saturate(1.2);
    -webkit-backdrop-filter: blur(9px) saturate(1.2);
  }
}

@media (max-width: 760px) {
  .container { padding: 0 20px; }
  .section { padding: 88px 0; }
  .nav-links { display: none; }
  .nav-burger { display: block; }
  .cards-grid { grid-template-columns: 1fr; }
  .listings-head-row { flex-direction: column; align-items: flex-start; }
  .hero-progress { display: none; }
  .scroll-cue { right: 24px; }
  .modal { padding: 0; }
  .modal-panel { max-height: 100vh; height: 100%; }
  .modal-content { padding: 28px 20px; }
  .modal-specs { grid-template-columns: repeat(2, 1fr); }
  .modal-specs .spec:nth-child(3) { border-left: 0; padding-left: 0; }
  .inquiry .form-row { grid-template-columns: 1fr; }
  .beat--hero h1 { font-size: clamp(44px, 13vw, 72px); }
}

/* ============================================================
   ADDITIONS - continuous journey beats, dedicated property page
   with tabs, and the parametric floor-plan.
   ============================================================ */

/* ---------- journey: service-story beats over the video ---------- */
.beat--service { left: 0; right: 0; top: 50%; transform: translateY(calc(-50% + 24px)); }
.beat--service.visible { transform: translateY(-50%); }
.beat--service .inner { max-width: 30em; }
.beat--service .idx {
  font-family: var(--display);
  font-size: 13px; font-weight: 600; letter-spacing: 0.3em;
  color: rgba(253, 252, 249, 0.7);
  display: block; margin-bottom: 18px;
}
.beat--service h2 {
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(30px, 4.4vw, 60px);
  line-height: 1.02;
  letter-spacing: -0.01em;
}
.beat--service h2 em { font-style: normal; color: #9ecdb8; }
.beat--service p {
  margin-top: 20px;
  font-size: clamp(15px, 1.35vw, 18px);
  font-weight: 300;
  line-height: 1.6;
  color: rgba(253, 252, 249, 0.86);
}
.beat--service.right { text-align: right; }
.beat--service.right .inner { margin-left: auto; }

/* handoff: last frame of the journey dissolves into the light page */
.journey-out {
  height: 60vh;
  margin-top: -60vh;
  position: relative;
  z-index: 6;
  pointer-events: none;
  background: linear-gradient(to bottom, rgba(246,244,239,0) 0%, rgba(246,244,239,0.6) 55%, var(--paper) 100%);
}

/* ---------- dedicated property page ---------- */
.property { padding-top: 76px; }

.property-hero { position: relative; height: 66vh; min-height: 440px; overflow: hidden; }
.property-hero > img { width: 100%; height: 100%; object-fit: cover; }
.property-hero .ph-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(14,13,12,0.78), rgba(14,13,12,0.04) 58%);
  display: flex; align-items: flex-end;
}
.property-hero .ph-inner { width: 100%; max-width: 1280px; margin: 0 auto; padding: 48px 32px; color: var(--paper); }
.property-hero .loc { font-size: 12px; letter-spacing: 0.24em; text-transform: uppercase; color: rgba(246,244,239,0.8); margin-bottom: 14px; }
.property-hero h1 { font-family: var(--display); font-weight: 500; font-size: clamp(34px, 5.4vw, 68px); line-height: 1; letter-spacing: -0.01em; }
.property-hero .ph-price { margin-top: 16px; font-family: var(--display); font-size: clamp(20px, 2.4vw, 30px); color: #9ecdb8; }
.property-back {
  position: absolute; top: 96px; left: 32px; z-index: 3;
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--paper); font-size: 11px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase;
  background: rgba(14,13,12,0.4); padding: 10px 16px; border: 1px solid rgba(246,244,239,0.3);
  backdrop-filter: blur(6px);
}
.property-back:hover { background: var(--ink); }

/* sticky tab bar */
.tabbar { position: sticky; top: 76px; z-index: 50; background: rgba(246,244,239,0.95); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.tabbar .tabs { display: flex; max-width: 1280px; margin: 0 auto; padding: 0 32px; overflow-x: auto; }
.tab-btn {
  padding: 22px 0; margin-right: 40px; background: none; border: 0;
  border-bottom: 2px solid transparent; color: var(--muted);
  font-size: 12px; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; white-space: nowrap;
  transition: color 0.25s var(--ease), border-color 0.25s var(--ease);
}
.tab-btn:hover { color: var(--ink); }
.tab-btn.active { color: var(--ink); border-bottom-color: var(--accent); }

.property-body { max-width: 1280px; margin: 0 auto; padding: 72px 32px 128px; }
.tab-panel { display: none; }
.tab-panel.active { display: block; animation: fadeUp 0.5s var(--ease); }
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* overview tab */
.overview-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 80px; align-items: start; }
.overview-copy h2 { font-family: var(--display); font-weight: 500; font-size: clamp(24px, 2.6vw, 34px); margin-bottom: 24px; letter-spacing: -0.01em; }
.overview-copy p { color: var(--ink-soft); margin-bottom: 18px; max-width: 40em; }
.overview-side .spec-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  border-left: 1px solid var(--line); border-top: 1px solid var(--line);
}
.spec-cell { padding: 20px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.spec-cell .k { font-size: 10px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); }
.spec-cell .v { margin-top: 8px; font-family: var(--display); font-size: 22px; }
.feature-block { margin-top: 40px; }
.feature-block .label { display: block; margin-bottom: 18px; }
.feature-list { list-style: none; }
.feature-list li { padding: 15px 0; border-top: 1px solid var(--line); display: flex; gap: 14px; align-items: flex-start; font-size: 14.5px; color: var(--ink-soft); }
.feature-list li::before { content: ''; width: 7px; height: 7px; background: var(--accent); margin-top: 6px; flex: none; }

/* floor-plan tab */
.plan-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 32px; margin-bottom: 32px; flex-wrap: wrap; }
.plan-head h2 { font-family: var(--display); font-weight: 500; font-size: clamp(24px, 2.6vw, 34px); letter-spacing: -0.01em; }
.plan-legend { display: flex; gap: 26px; flex-wrap: wrap; }
.plan-legend .lg { display: flex; align-items: center; gap: 9px; font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.plan-legend .sw { width: 18px; height: 3px; }
.plan-legend .sw.wall { background: var(--ink); height: 5px; }
.plan-legend .sw.win { background: var(--accent); }
.plan-legend .sw.part { background: var(--line-dark); }
.plan-wrap { border: 1px solid var(--line); background: var(--paper-2); padding: 32px; }
.plan-note { margin-top: 20px; font-size: 13px; color: var(--muted); }

/* gallery tab */
.property-gallery { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.property-gallery figure { overflow: hidden; border: 1px solid var(--line); position: relative; }
.property-gallery .g-main { grid-column: 1 / -1; }
.property-gallery .g-main img { aspect-ratio: 16 / 8; }
.property-gallery img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4 / 3; transition: transform 0.8s var(--ease); }
.property-gallery figure:hover img { transform: scale(1.04); }
.property-gallery figcaption { position: absolute; left: 0; bottom: 0; background: var(--paper); border-top: 1px solid var(--line); border-right: 1px solid var(--line); padding: 7px 13px; font-size: 10px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); }

/* inquiry tab */
.property-inquiry { max-width: 780px; }
.property-inquiry h2 { font-family: var(--display); font-weight: 500; font-size: clamp(24px, 2.6vw, 34px); margin-bottom: 10px; }
.property-inquiry .sub { color: var(--muted); margin-bottom: 36px; max-width: 44em; }
.property-inquiry .field label { color: var(--muted); }
.property-inquiry .field input, .property-inquiry .field textarea { border-color: var(--line-dark); color: var(--ink); }
.property-inquiry .field input:focus, .property-inquiry .field textarea:focus { border-color: var(--ink); }
.property-inquiry .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.property-inquiry .form-success { border-color: var(--accent); color: var(--ink); }
.property-inquiry .form-success h3 { color: var(--accent); font-family: var(--display); }

@media (max-width: 900px) {
  .overview-grid { grid-template-columns: 1fr; gap: 48px; }
  .property-hero { height: 52vh; }
  .property-back { top: 90px; left: 20px; }
}
@media (max-width: 640px) {
  .property-body { padding: 48px 20px 96px; }
  .property-hero .ph-inner { padding: 28px 20px; }
  .property-gallery { grid-template-columns: 1fr; }
  .property-inquiry .form-row { grid-template-columns: 1fr; }
  .tabbar .tabs { padding: 0 20px; }
  .tab-btn { margin-right: 26px; }
}

/* floor-plan renderer variables + svg text */
.floorplan { width: 100%; height: auto; display: block; }
.fp-label { font-family: var(--display); font-size: 11px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; fill: var(--ink-soft); }
.fp-sub { font-family: var(--sans); font-size: 9px; letter-spacing: 0.03em; fill: var(--muted); text-transform: uppercase; }

:root {
  --fp-grid: #e8e3d9;
  --fp-fill: #fffdf8;
  --fp-wall: #161512;
  --fp-part: #b3ac9e;
  --fp-win: #1e4636;
  --fp-accent: #1e4636;
  --fp-water: #dfe8e3;
}

/* ---------- page transition + loading curtain ---------- */
.page-curtain {
  position: fixed; inset: 0; z-index: 9999;
  background: var(--paper);
  display: flex; align-items: center; justify-content: center;
  transform: translateY(0);
  transition: transform 0.6s cubic-bezier(0.76, 0, 0.24, 1);
  will-change: transform;
}
.page-curtain.is-hidden { transform: translateY(-100%); }
.page-curtain.done { pointer-events: none; }
.curtain-inner { display: flex; flex-direction: column; align-items: center; gap: 26px; }
.curtain-mark { display: flex; align-items: center; gap: 15px; opacity: 0; transform: translateY(10px); }
.curtain-mark img { width: 34px; height: 34px; }
.curtain-mark span {
  font-family: var(--display); font-weight: 600; letter-spacing: 0.42em;
  text-transform: uppercase; font-size: 24px; padding-left: 0.42em; color: var(--ink);
}
.curtain-bar { width: 190px; height: 1px; background: var(--line-dark); position: relative; overflow: hidden; opacity: 0; }
.curtain-bar i { position: absolute; inset: 0; background: var(--accent); transform: scaleX(0); transform-origin: left; }
/* first-load loader animation */
.page-curtain.load .curtain-mark { animation: curtain-mark 0.5s var(--ease) 0.05s forwards; }
.page-curtain.load .curtain-bar { opacity: 1; }
.page-curtain.load .curtain-bar i { animation: curtain-fill 0.6s cubic-bezier(0.76, 0, 0.24, 1) 0.05s forwards; }
@keyframes curtain-mark { to { opacity: 1; transform: none; } }
@keyframes curtain-fill { to { transform: scaleX(1); } }
@media (prefers-reduced-motion: reduce) {
  .page-curtain { transition: none; }
  .page-curtain .curtain-mark { opacity: 1; transform: none; }
}

/* ============ Desktop-only gate ============
   NORDHAUS ist eine scroll-getriebene Video-Erfahrung, die für große
   Bildschirme gebaut ist. Auf Handys/kleinen Tablets (<=900px) wird die
   Seite komplett durch diesen Vollbild-Hinweis ersetzt. */
.desktop-only-gate { display: none; }
@media (max-width: 900px) {
  .desktop-only-gate {
    display: flex;
    position: fixed;
    inset: 0;
    z-index: 100000;
    background: var(--paper);
    color: var(--ink);
    align-items: center;
    justify-content: center;
    padding: 2.5rem 1.75rem;
    text-align: center;
  }
  .desktop-only-gate .dog-inner {
    max-width: 30rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
  }
  .desktop-only-gate .dog-logo {
    width: 48px;
    height: 48px;
    display: block;
  }
  .desktop-only-gate .dog-kicker {
    font-family: var(--display);
    font-weight: 600;
    letter-spacing: 0.42em;
    font-size: 0.72rem;
    text-transform: uppercase;
    color: var(--accent);
    margin: 0;
    padding-left: 0.42em;
  }
  .desktop-only-gate .dog-title {
    font-family: var(--display);
    font-weight: 700;
    font-size: clamp(1.9rem, 9vw, 2.6rem);
    line-height: 1.04;
    margin: 0;
    color: var(--ink);
  }
  .desktop-only-gate .dog-text {
    font-family: var(--sans);
    font-weight: 400;
    font-size: 0.98rem;
    line-height: 1.6;
    color: var(--ink-soft);
    margin: 0;
  }
  .desktop-only-gate .dog-rule {
    width: 56px;
    height: 2px;
    background: var(--ink);
    margin: 0.25rem 0;
  }
  /* alles andere hinter dem Gate wegsperren + Scroll verhindern */
  html, body { overflow: hidden; height: 100%; }
}
