:root {
  --ink: #16140f;
  --cream: #faf6ef;
  --cream-alt: #f1ead9;
  --sand: #c9a876;
  --sand-deep: #a8895c;
  --grey: #6f6b62;
  --line: #e6ddc9;
  --max: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: 'Poppins', -apple-system, sans-serif;
  margin: 0;
}

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 32px; }
.wrap-narrow { max-width: 760px; margin: 0 auto; padding: 0 32px; }
.center { text-align: center; }

.concept-tag {
  position: fixed;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 60;
  background: var(--ink);
  color: var(--cream);
  font-size: 11.5px;
  letter-spacing: 0.06em;
  padding: 6px 16px;
  border-radius: 30px;
  opacity: 0.88;
  pointer-events: none;
}

/* Header */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 40;
  padding: 22px 0;
  transition: background .3s ease, padding .3s ease, box-shadow .3s ease;
}
.site-header.scrolled {
  background: rgba(250, 246, 239, 0.92);
  backdrop-filter: blur(10px);
  padding: 14px 0;
  box-shadow: 0 8px 24px -18px rgba(22,20,15,0.3);
}
.header-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.logo {
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 22px;
  letter-spacing: 0.01em;
  color: #fff;
  text-decoration: none;
  transition: color .3s ease;
}
.site-header.scrolled .logo { color: var(--ink); }

.nav { display: flex; gap: 30px; margin-right: auto; margin-left: 56px; }
.nav a {
  color: rgba(255,255,255,0.88);
  text-decoration: none;
  font-size: 14.5px;
  font-weight: 500;
  transition: color .3s ease, opacity .2s ease;
}
.nav a:hover { opacity: 0.7; }
.site-header.scrolled .nav a { color: var(--ink); }

.btn {
  display: inline-block;
  padding: 13px 26px;
  border-radius: 30px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease, color .2s ease;
}
.btn-pill { background: #fff; color: var(--ink); }
.btn-pill:hover { transform: translateY(-2px); box-shadow: 0 10px 22px -10px rgba(0,0,0,0.35); }
.btn-dark { background: var(--ink); color: var(--cream); }
.btn-dark:hover { background: #000; transform: translateY(-2px); }
.btn-outline-light { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,0.6); }
.btn-outline-light:hover { background: rgba(255,255,255,0.12); }
.btn-block { width: 100%; text-align: center; }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 34px; height: 34px;
  background: transparent;
  border: none;
  cursor: pointer;
}
.nav-toggle span { display: block; width: 100%; height: 1.5px; background: #fff; transition: transform .25s ease, opacity .2s ease, background .3s ease; }
.site-header.scrolled .nav-toggle span { background: var(--ink); }

/* Hero */
.hero { position: relative; background: var(--ink); overflow: visible; }
.hero-pin {
  position: relative;
  height: 100vh;
  min-height: 560px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.hero-video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
.hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(10,10,8,0.55) 0%, rgba(10,10,8,0.15) 32%, rgba(10,10,8,0.1) 55%, rgba(10,10,8,0.75) 100%);
}
.hero-content {
  position: relative;
  z-index: 2;
  padding: 0 32px 64px;
  max-width: 720px;
}
.hero-badge {
  display: inline-block;
  font-size: 12.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fff;
  background: rgba(255,255,255,0.14);
  border: 1px solid rgba(255,255,255,0.3);
  padding: 7px 16px;
  border-radius: 30px;
  margin-bottom: 22px;
  backdrop-filter: blur(6px);
}
.hero-content h1 {
  color: #fff;
  font-weight: 300;
  font-size: clamp(42px, 7vw, 78px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  margin-bottom: 22px;
}
.hero-sub {
  color: rgba(255,255,255,0.82);
  font-size: 16.5px;
  max-width: 460px;
  margin: 0 0 30px;
}
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-caption {
  position: absolute;
  right: 32px;
  bottom: 28px;
  z-index: 2;
  color: rgba(255,255,255,0.75);
  font-size: 12.5px;
  letter-spacing: 0.04em;
  text-align: right;
  line-height: 1.5;
  margin: 0;
}
.scroll-hint {
  position: absolute;
  left: 32px;
  bottom: 28px;
  z-index: 2;
  color: rgba(255,255,255,0.7);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0;
}
.scroll-hint span { display: inline-block; animation: bob 1.8s ease-in-out infinite; }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(5px); } }

/* Scroll-scrubbed hero video: only enabled once JS confirms the video can be driven by scroll */
html.has-scrub-hero .hero { height: 230vh; overflow: visible; }
html.has-scrub-hero .hero-pin { position: sticky; top: 0; }
@media (max-width: 760px) {
  html.has-scrub-hero .hero { height: 100vh; min-height: 560px; }
  html.has-scrub-hero .hero-pin { position: relative; }
}
@media (prefers-reduced-motion: reduce) {
  html.has-scrub-hero .hero { height: auto; }
  html.has-scrub-hero .hero-pin { position: relative; }
}

/* Story / text-fill section */
.story { padding: 120px 0 70px; background: var(--cream); }
.eyebrow {
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--sand-deep);
  font-weight: 600;
  margin: 0 0 18px;
}
.fill-heading {
  font-weight: 400;
  font-size: clamp(30px, 4.6vw, 52px);
  line-height: 1.25;
  margin: 0 0 60px;
  background-image: linear-gradient(90deg, var(--ink) 0%, var(--ink) var(--fill, 0%), #d8d0bd var(--fill, 0%), #d8d0bd 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.story-photo-wrap { display: flex; justify-content: center; }
.story-photo {
  width: 100%;
  max-width: 980px;
  aspect-ratio: 16/9;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 40px 80px -40px rgba(22,20,15,0.35);
}
.story-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Residences */
.residences { padding: 110px 0; background: var(--cream-alt); }
.section-heading {
  font-weight: 400;
  font-size: clamp(30px, 4vw, 44px);
  color: var(--ink);
  margin: 0 0 16px;
}
.section-sub { color: var(--grey); font-size: 16px; max-width: 480px; margin: 0 auto 56px; }
.residence-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 44px 32px;
}
.residence-card { text-align: left; }
.residence-photo {
  aspect-ratio: 4/3;
  border-radius: 18px;
  overflow: hidden;
  margin-bottom: 18px;
  box-shadow: 0 26px 50px -30px rgba(22,20,15,0.35);
}
.residence-photo img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s ease; }
.residence-card:hover .residence-photo img { transform: scale(1.05); }
.residence-card h3 { font-size: 21px; font-weight: 500; color: var(--ink); margin: 0 0 8px; }
.residence-card p { font-size: 14.5px; color: var(--grey); margin: 0; max-width: 420px; }

/* Parallax contact */
.contact-parallax {
  position: relative;
  overflow: hidden;
  min-height: 640px;
  display: flex;
  align-items: center;
  padding: 120px 0;
}
.parallax-bg {
  position: absolute;
  top: -10%; left: 0;
  width: 100%; height: 120%;
  background-size: cover;
  background-position: center;
  will-change: transform;
}
.parallax-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(120deg, rgba(10,9,7,0.88) 0%, rgba(10,9,7,0.65) 45%, rgba(10,9,7,0.35) 100%);
}
.contact-wordmark {
  position: absolute;
  right: -2%;
  bottom: -4%;
  font-family: 'Poppins', sans-serif;
  font-weight: 700;
  font-size: clamp(90px, 16vw, 260px);
  color: transparent;
  -webkit-text-stroke: 1.5px rgba(255,255,255,0.16);
  line-height: 1;
  z-index: 1;
  pointer-events: none;
  user-select: none;
}
.contact-wrap { position: relative; z-index: 2; }
.contact-card {
  max-width: 440px;
  background: rgba(22,20,15,0.55);
  border: 1px solid rgba(255,255,255,0.16);
  backdrop-filter: blur(14px);
  border-radius: 20px;
  padding: 40px;
}
.contact-card .eyebrow { color: var(--sand); }
.contact-card h2 { color: #fff; font-weight: 400; font-size: 32px; margin-bottom: 26px; }
.contact-form { display: flex; flex-direction: column; gap: 14px; }
.row2 { display: flex; gap: 12px; }
.contact-form input, .contact-form textarea {
  font-family: inherit;
  font-size: 14.5px;
  padding: 13px 15px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.22);
  background: rgba(255,255,255,0.08);
  color: #fff;
  width: 100%;
}
.contact-form input::placeholder, .contact-form textarea::placeholder { color: rgba(255,255,255,0.55); }
.contact-form input:focus, .contact-form textarea:focus {
  outline: none; border-color: var(--sand); background: rgba(255,255,255,0.12);
}
.contact-form textarea { resize: vertical; }
.form-note { color: rgba(255,255,255,0.8); font-size: 13px; margin: 4px 0 0; }

/* Footer */
.site-footer { background: var(--ink); color: rgba(255,255,255,0.7); padding: 26px 0; }
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 13px;
}
.footer-links { display: flex; gap: 20px; }
.footer-links a { color: rgba(255,255,255,0.7); text-decoration: none; }
.footer-links a:hover { color: #fff; }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s ease; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

/* Responsive */
@media (max-width: 900px) {
  .residence-grid { grid-template-columns: 1fr; }
  .nav { margin-left: 24px; gap: 20px; }
}
@media (max-width: 760px) {
  .header-inner { padding: 0 20px; }
  .nav {
    display: none;
    position: absolute;
    top: 100%; left: 0; right: 0;
    flex-direction: column;
    gap: 0;
    background: var(--cream);
    box-shadow: 0 20px 30px -20px rgba(22,20,15,0.3);
    margin: 0;
  }
  .nav.is-open { display: flex; }
  .nav a { color: var(--ink); padding: 16px 24px; border-bottom: 1px solid var(--line); }
  .nav-toggle { display: flex; }
  .btn-pill { display: none; }
  .row2 { flex-direction: column; }
  .hero-content { padding: 0 20px 54px; }
  .hero-caption, .scroll-hint { display: none; }
  .contact-card { padding: 28px; }
  .contact-wordmark { display: none; }
  .story { padding: 100px 0 50px; }
  .residences { padding: 80px 0; }
}
