/* ==========================================================================
   Divided Sky Estates - dividedskyestates.com
   Palette drawn from the sale sign:
     cream   #F4EFE2   deep forest #17300C   olive   #8A8F6A
     gold    #B8973F   pale sage   #DBDACC
   Type: Cormorant Garamond (display serif) / Alegreya Sans (body)
         Ephesis (script accent, sparing)
   ========================================================================== */

:root {
  --cream: #F4EFE2;
  --cream-deep: #ECE5D2;
  --paper: #F9F4E8;
  --forest: #17300C;
  --forest-soft: #2C4A1D;
  --olive: #7C8259;
  --sage: #C9CBB4;
  --gold: #B8973F;
  --gold-deep: #96782C;
  --ink: #22301A;
  --ink-soft: #3F4A35;
  --stone: #6E6C5B;

  --serif: "Cormorant Garamond", "Iowan Old Style", Georgia, serif;
  --sans: "Alegreya Sans", "Gill Sans", "Segoe UI", sans-serif;
  --script: "Ephesis", cursive;

  --measure: 62ch;
  --pad-x: clamp(1.25rem, 5vw, 4rem);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--forest); }
a:hover { color: var(--gold-deep); }

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 600;
  color: var(--forest);
  line-height: 1.08;
  margin: 0 0 0.5em;
  text-wrap: balance;
}

h1 { font-size: clamp(2.3rem, 5.5vw, 3.6rem); letter-spacing: 0.01em; }
h2 { font-size: clamp(1.9rem, 4.5vw, 3rem); }
h3 {
  font-size: 1rem;
  font-family: var(--sans);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--forest);
}

p { margin: 0 0 1em; }

/* ---- Script accent ---- */
.script-eyebrow {
  font-family: var(--script);
  font-size: clamp(1.9rem, 4vw, 2.6rem);
  line-height: 1;
  color: var(--gold-deep);
  margin: 0 0 0.35rem;
}
.script-light { color: var(--gold); }
.script-gold { color: var(--gold); }

/* ==========================================================================
   Masthead
   ========================================================================== */
.masthead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.9rem clamp(1rem, 4vw, 4rem);
  border-bottom: 1px solid rgba(23, 48, 12, 0.14);
  background: var(--cream);
  position: sticky;
  top: 0;
  z-index: 10;
}

.masthead-brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
}

.brand-mark, .footer-mark {
  width: 44px;
  flex: none;
}
@media (max-width: 420px) {
  .brand-mark { width: 36px; }
}
.mark-sun { stroke: var(--gold); }
.mark-peaks { stroke: var(--forest); }
.mark-trees { fill: var(--forest); }

.brand-word {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(0.92rem, 3.4vw, 1.15rem);
  letter-spacing: clamp(0.08em, 1.2vw, 0.16em);
  text-transform: uppercase;
  color: var(--forest);
  white-space: nowrap;
}
.brand-word em {
  font-style: normal;
  color: var(--gold-deep);
}

.masthead-nav {
  display: flex;
  gap: 2.1rem;
  align-items: center;
}
.masthead-nav a:not(.nav-cta) { display: none; }
@media (min-width: 760px) {
  .masthead-nav a:not(.nav-cta) { display: inline-block; }
}
.masthead-nav a {
  font-size: 0.86rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ink-soft);
  padding: 0.3rem 0;
  border-bottom: 1.5px solid transparent;
  transition: color 0.25s var(--ease-out), border-color 0.25s var(--ease-out);
}
.masthead-nav a:hover { color: var(--forest); border-bottom-color: var(--gold); }
.masthead-nav .nav-cta {
  border: 1.5px solid var(--forest);
  padding: 0.45rem clamp(0.7rem, 2.5vw, 1.1rem);
  color: var(--forest);
  white-space: nowrap;
}
.masthead-nav .nav-cta:hover {
  background: var(--forest);
  color: var(--cream);
  border-bottom-color: var(--forest);
}

/* ==========================================================================
   Hero
   ========================================================================== */
.hero {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(2rem, 5vw, 3.5rem);
  padding: clamp(2.5rem, 7vw, 5.5rem) var(--pad-x) clamp(2rem, 5vw, 4rem);
  max-width: 1280px;
  margin-inline: auto;
  align-items: center;
}

/* Faint topographic contours behind the hero, like a survey field sheet */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='560' height='420' viewBox='0 0 560 420'%3E%3Cg fill='none' stroke='%2317300C' stroke-opacity='0.055' stroke-width='1.2'%3E%3Cpath d='M-20 340 C 90 300 150 320 250 270 S 430 230 580 250'/%3E%3Cpath d='M-20 300 C 100 260 170 285 265 235 S 440 195 580 215'/%3E%3Cpath d='M-20 260 C 110 222 190 250 280 200 S 450 160 580 180'/%3E%3Cpath d='M-20 220 C 120 185 205 215 295 168 S 460 128 580 148'/%3E%3Cpath d='M-20 180 C 130 148 220 180 310 136 S 470 96 580 116'/%3E%3C/g%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: left bottom;
  background-size: min(120%, 760px) auto;
}
.hero > * { position: relative; }

.hero-text { max-width: 34rem; }

.hero-sub {
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  color: var(--ink-soft);
  max-width: 30rem;
  margin-bottom: 1.75rem;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 0.85rem; }

.btn {
  display: inline-block;
  font-family: var(--sans);
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.9rem 1.7rem;
  border: 1.5px solid var(--forest);
  transition: transform 0.15s var(--ease-out), background 0.25s var(--ease-out), color 0.25s var(--ease-out);
}
.btn:active { transform: translateY(1px) scale(0.99); }
.btn-solid { background: var(--forest); color: var(--cream); }
.btn-solid:hover { background: var(--forest-soft); color: var(--cream); }
.btn-ghost { background: transparent; color: var(--forest); border-width: 2px; }
.btn-ghost:hover { background: rgba(23, 48, 12, 0.07); color: var(--forest); }

.hero-map { margin: 0; }

.map-frame {
  overflow: hidden;
  border: 1px solid rgba(23, 48, 12, 0.35);
  border-radius: 6px;
  box-shadow: 0 18px 45px -18px rgba(23, 48, 12, 0.35);
  background: var(--sage);
}

.map-img { width: 100%; }

/* Ken Burns: gentle drift + zoom, classy not gimmicky */
@keyframes kenburns {
  0%   { transform: scale(1) translate(0, 0); }
  100% { transform: scale(1.07) translate(-1.4%, -1%); }
}
.kenburns {
  animation: kenburns 32s var(--ease-out) both alternate infinite;
  will-change: transform;
  transform-origin: 60% 45%;
}

.hero-map figcaption {
  color: var(--ink-soft);
  font-style: italic;
  font-family: var(--serif);
  font-size: 1.05rem;
  margin-top: 0.7rem;
  text-align: right;
}

@media (min-width: 900px) {
  .hero {
    grid-template-columns: 5fr 7fr;
  }
}

/* ==========================================================================
   Section rule (mountain divider)
   ========================================================================== */
.section-rule {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  max-width: 1280px;
  margin-inline: auto;
  padding: clamp(1rem, 3vw, 2rem) var(--pad-x);
  color: rgba(23, 48, 12, 0.45);
}
.section-rule::before,
.section-rule::after {
  content: "";
  flex: 1;
  height: 1px;
  background: currentColor;
  opacity: 0.5;
}
.rule-mark { width: 84px; flex: none; }

/* ==========================================================================
   Section scaffolding
   ========================================================================== */
section { scroll-margin-top: 5rem; }

.section-head { margin-bottom: clamp(1.75rem, 4vw, 3rem); }
.section-lede {
  max-width: var(--measure);
  color: var(--ink-soft);
  font-size: clamp(1rem, 1.8vw, 1.125rem);
}

/* ==========================================================================
   The Lots
   ========================================================================== */
.lots {
  padding: clamp(3rem, 8vw, 6rem) var(--pad-x);
  max-width: 1280px;
  margin-inline: auto;
}

.lots-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(2rem, 4vw, 3.5rem);
  align-items: start;
}

.lot-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid rgba(23, 48, 12, 0.22);
}

.lot-row {
  display: grid;
  grid-template-columns: 4.5rem 1fr auto;
  align-items: baseline;
  gap: 0.5rem 0.75rem;
  padding: 0.85rem 0.4rem;
  border-bottom: 1px solid rgba(23, 48, 12, 0.16);
  transition: background 0.2s var(--ease-out);
}
.lot-row-noted .lot-note { grid-column: 1 / -1; margin-top: -0.4rem; }
.lot-row:hover { background: rgba(23, 48, 12, 0.045); }

.lot-name {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.2rem;
  color: var(--forest);
  letter-spacing: 0.02em;
}

.lot-acres {
  font-size: 1rem;
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.lot-status {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  justify-self: end;
  text-align: right;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.dot {
  width: 0.62rem;
  height: 0.62rem;
  border-radius: 50%;
  flex: none;
}

.lot-row[data-status="available"] .lot-status { color: var(--forest-soft); }
.lot-row[data-status="available"] .dot { background: #4B7231; }
.lot-row[data-status="pending"] .lot-status { color: var(--gold-deep); }
.lot-row[data-status="pending"] .dot { background: var(--gold); }
.lot-row[data-status="unavailable"] { opacity: 0.62; }
.lot-row[data-status="unavailable"] .lot-status { color: var(--stone); }
.lot-row[data-status="unavailable"] .dot { background: var(--stone); }

.lot-note {
  display: block;
  font-weight: 400;
  letter-spacing: 0.02em;
  text-transform: none;
  font-size: 0.82rem;
  font-style: italic;
  color: var(--stone);
}

/* Legend card, echoing the legend box on the sign */
.lots-aside { max-width: 22rem; }

.legend {
  position: relative;
  border: 1.5px solid var(--forest);
  border-radius: 8px;
  background: var(--paper);
  padding: 1.4rem 1.5rem 1.2rem;
  box-shadow: 4px 4px 0 rgba(23, 48, 12, 0.14);
}
.legend-title {
  margin-bottom: 0.9rem;
  letter-spacing: 0.2em;
}
.legend-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0 0 0.5rem;
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.dot-available { background: #4B7231; }
.dot-pending { background: var(--gold); }
.dot-unavailable { background: var(--stone); }

.legend-hr {
  border: 0;
  border-top: 1px solid rgba(23, 48, 12, 0.2);
  margin: 1rem 0 0.9rem;
}
.legend-note {
  font-size: 0.95rem;
  color: var(--ink);
  margin: 0;
  padding-right: 2rem;
}
.legend-tree {
  position: absolute;
  right: 1.1rem;
  bottom: 1rem;
  width: 20px;
  fill: var(--forest-soft);
  opacity: 0.75;
}

.lots-cta {
  margin-top: 1.4rem;
  font-family: var(--serif);
  font-size: 1.2rem;
  font-style: italic;
  color: var(--ink);
}

@media (min-width: 880px) {
  .lots-layout { grid-template-columns: 7fr 4fr; }
  .lots-aside { position: sticky; top: 6rem; }
}

/* ==========================================================================
   Our Story (deep green band)
   ========================================================================== */
.story {
  background: var(--forest);
  color: var(--cream);
  padding: clamp(3.5rem, 9vw, 6.5rem) var(--pad-x);
}

.story-inner {
  max-width: 1280px;
  margin-inline: auto;
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(1rem, 3vw, 3rem);
}

.story h2 { color: var(--paper); }

.story-body {
  max-width: 56ch;
  font-size: clamp(1.1rem, 2vw, 1.25rem);
  line-height: 1.85;
}
.story-body p { color: #E3E6D3; margin-bottom: 1.25em; }
.story-body p:first-child::first-letter {
  font-family: var(--serif);
  font-size: 2.9em;
  line-height: 0.85;
  float: left;
  padding-right: 0.12em;
  color: #CFAE58;
}

.story-sun {
  width: clamp(80px, 12vw, 130px);
  stroke: var(--gold);
  justify-self: center;
  margin-top: 1.5rem;
  opacity: 0.85;
  overflow: visible;
}

@media (min-width: 880px) {
  .story-inner {
    grid-template-columns: minmax(16rem, 22rem) 1fr;
    align-items: start;
  }
  .story-sun {
    grid-column: 1;
    grid-row: 2;
    justify-self: start;
    margin-top: 0.5rem;
  }
}

/* ==========================================================================
   Final Plat
   ========================================================================== */
.plat {
  padding: clamp(3rem, 8vw, 6rem) var(--pad-x);
  max-width: 1280px;
  margin-inline: auto;
}

.plat-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: center;
}

.plat-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-bottom: 1rem;
}

.plat-aside {
  font-size: 0.95rem;
  color: var(--ink-soft);
  max-width: 30rem;
  margin: 0;
}

/* The plat rendered as a survey sheet pinned at a slight tilt */
.plat-sheet {
  position: relative;
  display: block;
  background: #FDFBF4;
  border: 1px solid rgba(23, 48, 12, 0.3);
  padding: 0.6rem;
  box-shadow: 0 14px 34px -14px rgba(23, 48, 12, 0.45);
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
  max-width: 34rem;
  justify-self: center;
  margin-top: 1.5rem;
}
@media (min-width: 880px) {
  .plat-sheet { transform: rotate(-1.1deg); margin-top: 0; }
  .plat-sheet:hover {
    transform: rotate(0deg) scale(1.015);
    box-shadow: 0 20px 44px -16px rgba(23, 48, 12, 0.5);
  }
}
.plat-sheet img { border: 1px solid rgba(23, 48, 12, 0.14); }
.plat-sheet-tag {
  position: absolute;
  bottom: -0.85rem;
  right: 1.2rem;
  background: var(--forest);
  color: var(--cream);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 0.4rem 0.85rem;
}

@media (min-width: 880px) {
  .plat-grid { grid-template-columns: 6fr 6fr; }
  .plat .section-head { margin-bottom: 1.5rem; }
}

/* ==========================================================================
   About Salida
   ========================================================================== */
.salida {
  padding: clamp(3rem, 8vw, 6rem) var(--pad-x) clamp(3.5rem, 9vw, 6.5rem);
  max-width: 1280px;
  margin-inline: auto;
}

.salida-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border-top: 1px solid rgba(23, 48, 12, 0.22);
}

.salida-item {
  padding: 1.6rem 0.25rem 1.1rem;
  border-bottom: 1px solid rgba(23, 48, 12, 0.14);
}
.salida-item h3 { margin-bottom: 0.4em; display: flex; align-items: center; gap: 0.55rem; }
.salida-item h3::before {
  content: "";
  flex: none;
  width: 11px;
  height: 9px;
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
  background: var(--gold);
}
.salida-item p { color: var(--ink-soft); margin-bottom: 0; max-width: 38rem; }

@media (min-width: 760px) {
  .salida-grid {
    grid-template-columns: 1fr 1fr;
    column-gap: clamp(2rem, 5vw, 4.5rem);
  }
}

/* ==========================================================================
   Contact (green band, mirrors the sign footer)
   ========================================================================== */
.contact {
  background: var(--forest);
  color: var(--cream);
  padding: clamp(3.5rem, 9vw, 6.5rem) var(--pad-x);
}

.contact-inner {
  max-width: 1280px;
  margin-inline: auto;
}

.contact h2 { color: var(--paper); }
.contact-lede { color: #C8CDB4; max-width: 34rem; margin-bottom: 2rem; }

.contact-people {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  max-width: 44rem;
}

.contact-card {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  border: 1.5px solid rgba(244, 239, 226, 0.55);
  border-radius: 8px;
  padding: 1.4rem 1.6rem;
  text-decoration: none;
  color: var(--cream);
  background: rgba(244, 239, 226, 0.04);
  transition: border-color 0.25s var(--ease-out), background 0.25s var(--ease-out), transform 0.15s var(--ease-out);
}
.contact-card:hover {
  border-color: var(--gold);
  background: rgba(184, 151, 63, 0.1);
  color: var(--cream);
}
.contact-card:active { transform: scale(0.99); }

.contact-name {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--paper);
}
.contact-phone {
  font-family: var(--serif);
  font-size: clamp(1.8rem, 5vw, 2.3rem);
  font-weight: 500;
  color: #D3B45E;
  letter-spacing: 0.04em;
  line-height: 1.2;
}
.contact-hint {
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(244, 239, 226, 0.72);
  margin-top: 0.3rem;
}

@media (min-width: 640px) {
  .contact-people { grid-template-columns: 1fr 1fr; }
}

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
  background: var(--forest);
  border-top: 1px solid rgba(244, 239, 226, 0.18);
  color: var(--cream);
  text-align: center;
  padding: 2.5rem var(--pad-x) 2.75rem;
}
.footer-mark {
  width: 52px;
  margin-inline: auto;
}
.footer .mark-peaks { stroke: var(--cream); }
.footer .mark-trees { fill: var(--cream); }
.footer-word {
  font-family: var(--serif);
  font-size: 1.15rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--paper);
  margin: 0.9rem 0 0.15rem;
}
.footer-sub {
  font-family: var(--script);
  font-size: 1.7rem;
  color: #CFAE58;
  margin: 0;
}

/* ==========================================================================
   Reveal on scroll
   ========================================================================== */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}
.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* Hero entrance (staggered; .js-anim is added by main.js so content is
   never hidden when scripts or animations are unavailable) */
@keyframes fade-up {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: none; }
}
.js-anim .hero-text > * { animation: fade-up 0.8s var(--ease-out) backwards; }
.js-anim .hero-text > *:nth-child(1) { animation-delay: 0.05s; }
.js-anim .hero-text > *:nth-child(2) { animation-delay: 0.15s; }
.js-anim .hero-text > *:nth-child(3) { animation-delay: 0.28s; }
.js-anim .hero-text > *:nth-child(4) { animation-delay: 0.4s; }
.js-anim .hero-map { animation: fade-up 1s var(--ease-out) 0.25s backwards; }

/* ==========================================================================
   Reduced motion
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .kenburns { animation: none; }
  .js-anim .hero-text > *, .js-anim .hero-map { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ==========================================================================
   Photos (Our Story + Salida) — framed like paper prints
   ========================================================================== */
.story-photo {
  margin: 0;
  justify-self: center;
  max-width: 24rem;
  background: var(--paper);
  padding: 0.6rem 0.6rem 0.9rem;
  border: 1px solid rgba(23, 48, 12, 0.25);
  box-shadow: 0 18px 40px -18px rgba(0, 0, 0, 0.55);
}
.story-photo img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid rgba(23, 48, 12, 0.12);
}
.story-photo figcaption {
  font-family: var(--sans);
  font-size: 0.82rem;
  line-height: 1.5;
  color: var(--ink-soft);
  padding-top: 0.65rem;
}
@media (min-width: 880px) {
  .story-inner { grid-template-columns: minmax(16rem, 22rem) 1fr minmax(18rem, 24rem); }
  .story-photo {
    grid-column: 3;
    grid-row: 1 / span 2;
    align-self: start;
    transform: rotate(1.2deg);
    transition: transform 0.35s var(--ease-out);
  }
  .story-photo:hover { transform: rotate(0deg) scale(1.01); }
}

.salida-photo {
  margin: 0 auto clamp(2rem, 5vw, 3.5rem);
  max-width: 56rem;
  background: #FDFBF4;
  padding: 0.6rem 0.6rem 0.9rem;
  border: 1px solid rgba(23, 48, 12, 0.3);
  box-shadow: 0 14px 34px -14px rgba(23, 48, 12, 0.45);
}
.salida-photo img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid rgba(23, 48, 12, 0.14);
}
.salida-photo figcaption {
  font-family: var(--sans);
  font-size: 0.85rem;
  line-height: 1.55;
  color: var(--ink-soft);
  padding-top: 0.65rem;
}

.footer-legal {
  max-width: 46rem;
  margin: 1.1rem auto 0;
  font-size: 0.74rem;
  line-height: 1.6;
  color: rgba(244, 239, 226, 0.55);
}
