/* ═══════════════════════════════════════════════════════
   REXFORD HOMES Shared Stylesheet
   Sibling site to rexfordco.ca. Same brand tokens,
   light + serif-led where the studio site is dark + geometric.
═══════════════════════════════════════════════════════ */

:root {
  --ink:       #1B1F23;
  --slate:     #45556A;
  --stone:     #8A7E70;
  --sand:      #B8AFA4;
  --mist:      #D7D3CC;
  --bone:      #F4F1EC;
  --paper:     #FBF9F5;
  --bronze:    #8A6F4E;
  --bronze-lt: #B89673;

  --serif:   'Cormorant Garamond', serif;
  --display: 'Jost', sans-serif;
  --body:    'Inter', sans-serif;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  --pad-x: clamp(24px, 6vw, 80px);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }

/* ── Utilities ── */
.label {
  font-family: var(--display);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--bronze);
}
.label--light { color: var(--bronze-lt); }

.serif-h {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(32px, 4vw, 52px);
  line-height: 1.12;
  letter-spacing: 0.005em;
  color: var(--ink);
  margin-top: 16px;
}
.serif-h em { font-style: italic; font-weight: 500; }
.section-intro {
  font-weight: 300;
  font-size: 17px;
  color: var(--slate);
  line-height: 1.75;
  max-width: 620px;
}

.btn {
  display: inline-block;
  font-family: var(--display);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  padding: 17px 38px;
  border: 1px solid var(--ink);
  color: var(--ink);
  background: transparent;
  transition: background 0.35s var(--ease-out), color 0.35s var(--ease-out), border-color 0.35s var(--ease-out);
}
.btn:hover { background: var(--ink); color: var(--paper); }
.btn--solid { background: var(--ink); color: var(--paper); }
.btn--solid:hover { background: var(--bronze); border-color: var(--bronze); color: var(--paper); }
.btn--light { border-color: var(--paper); color: var(--paper); }
.btn--light:hover { background: var(--paper); color: var(--ink); }

.text-link {
  font-family: var(--display);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--bronze);
  border-bottom: 1px solid var(--sand);
  padding-bottom: 5px;
  transition: color 0.3s, border-color 0.3s;
}
.text-link:hover { color: var(--ink); border-color: var(--bronze); }

/* ── Scroll reveal ── */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ── Navigation ── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--pad-x);
  height: 76px;
  background: rgba(251, 249, 245, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(215, 211, 204, 0.6);
}
.wordmark {
  display: flex;
  align-items: baseline;
  gap: 11px;
}
.wordmark-main {
  font-family: var(--display);
  font-weight: 400;
  font-size: 21px;
  letter-spacing: 0.22em;
  color: var(--ink);
}
.wordmark-div {
  font-family: var(--display);
  font-weight: 400;
  font-size: 21px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--bronze);
}
.nav-links {
  display: flex;
  gap: 40px;
  list-style: none;
}
.nav-links a {
  font-family: var(--display);
  font-weight: 400;
  font-size: 12.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--slate);
  padding-bottom: 4px;
  border-bottom: 1px solid transparent;
  transition: color 0.3s, border-color 0.3s;
}
.nav-links a:hover { color: var(--ink); }
.nav-links a.active { color: var(--ink); border-color: var(--bronze); }
.nav-cta {
  font-family: var(--display);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  padding: 12px 24px;
  background: var(--ink);
  color: var(--paper);
  border: 1px solid var(--ink);
  transition: background 0.35s var(--ease-out), border-color 0.35s var(--ease-out);
  white-space: nowrap;
}
.nav-cta:hover { background: var(--bronze); border-color: var(--bronze); }
.nav-right { display: flex; align-items: center; gap: 40px; }
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  width: 30px; height: 22px;
  position: relative;
}
.nav-toggle span {
  position: absolute;
  left: 0; right: 0;
  height: 1.5px;
  background: var(--ink);
  transition: transform 0.3s, opacity 0.3s;
}
.nav-toggle span:nth-child(1) { top: 2px; }
.nav-toggle span:nth-child(2) { top: 10px; }
.nav-toggle span:nth-child(3) { top: 18px; }

/* ── Page hero (interior pages) ── */
.page-hero {
  padding: 190px var(--pad-x) 80px;
  text-align: center;
}
.page-hero .section-intro { margin: 26px auto 0; }

/* ── Sketch → built crossfade card ── */
.work-card { display: block; }
.work-media {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: var(--bone);
}
.work-media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.work-media .photo {
  opacity: 0;
  transition: opacity 1.1s var(--ease-out);
}
.work-card.built .work-media .photo { opacity: 1; }
.work-card.built:hover .work-media .photo { opacity: 0; }
@media (prefers-reduced-motion: reduce) {
  .work-media .photo { transition: none; }
}
.work-meta { padding: 20px 2px 0; }
.work-name {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 23px;
  color: var(--ink);
  line-height: 1.25;
}
.work-loc {
  font-family: var(--display);
  font-weight: 400;
  font-size: 11px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--stone);
  margin-top: 5px;
}

/* ── Dark CTA band ── */
.cta-band {
  background: var(--ink);
  padding: 110px var(--pad-x);
  text-align: center;
}
.cta-band .serif-h { color: var(--paper); }
.cta-band .section-intro { color: var(--sand); margin: 22px auto 40px; }

/* ── Footer ── */
footer {
  background: var(--ink);
  border-top: 1px solid rgba(138, 111, 78, 0.35);
  padding: 70px var(--pad-x) 46px;
  color: var(--sand);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 48px;
  max-width: 1180px;
  margin: 0 auto;
}
.footer-word { display: flex; align-items: baseline; gap: 10px; margin-bottom: 18px; }
.footer-word .wordmark-main { color: var(--paper); font-size: 19px; }
.footer-word .wordmark-div { font-size: 19px; }
.footer-tag {
  font-weight: 300;
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--sand);
  max-width: 320px;
}
.footer-tag a { color: var(--bronze-lt); border-bottom: 1px solid rgba(184, 150, 115, 0.4); }
.footer-tag a:hover { color: var(--paper); }
.footer-h {
  font-family: var(--display);
  font-weight: 500;
  font-size: 10.5px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--stone);
  margin-bottom: 16px;
}
.footer-list { list-style: none; }
.footer-list li { margin-bottom: 9px; }
.footer-list a, .footer-list span {
  font-weight: 300;
  font-size: 13.5px;
  color: var(--sand);
}
.footer-list a:hover { color: var(--paper); }
.footer-base {
  max-width: 1180px;
  margin: 54px auto 0;
  padding-top: 24px;
  border-top: 1px solid rgba(215, 211, 204, 0.12);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 11.5px;
  font-weight: 300;
  color: var(--stone);
}

/* ── Focus visibility ── */
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--bronze);
  outline-offset: 3px;
}

/* ── Mobile ── */
@media (max-width: 820px) {
  .nav { height: 64px; }
  .nav-right { gap: 18px; }
  .nav-cta { padding: 9px 16px; font-size: 10px; }
  .nav-toggle { display: block; }
  .nav-links {
    position: fixed;
    top: 64px; left: 0; right: 0;
    background: var(--paper);
    flex-direction: column;
    gap: 0;
    padding: 12px 0 20px;
    border-bottom: 1px solid var(--mist);
    display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links li { padding: 13px var(--pad-x); }
  .nav-open .nav-toggle span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
  .nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
  .nav-open .nav-toggle span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
  .page-hero { padding: 140px var(--pad-x) 60px; }
  .footer-grid { grid-template-columns: 1fr; gap: 36px; }
}
