/* ============================================
   SUNSET FARM — The Estate
   Shared stylesheet
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;1,300;1,400&family=Inter:wght@300;400;500&display=swap');

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

:root {
  --cream: #FBFAF7;
  --cream-warm: #F2EEE5;
  --ink: #1F1D1A;
  --ink-soft: #3A342C;
  --stone: #5C564D;
  --stone-light: #8A8378;
  --gold: #B8A582;
  --hairline: rgba(0, 0, 0, 0.12);
  --hairline-light: rgba(0, 0, 0, 0.08);
  --hairline-dark: rgba(251, 250, 247, 0.15);
}

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: 'Inter', -apple-system, system-ui, sans-serif;
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.7; font-size: 16px;
}

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

.serif {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 300;
  letter-spacing: -0.01em;
}

.eyebrow {
  font-size: 16px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--stone-light);
  font-weight: 500;
}

.divider {
  width: 40px;
  height: 1px;
  background: var(--gold);
  margin: 0 auto;
  border: 0;
}

/* ============ BUTTONS ============ */
.btn {
  display: inline-block;
  padding: 16px 32px;
  font-size: 16px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 500;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
}

.btn-dark {
  background: var(--ink);
  color: var(--cream);
}
.btn-dark:hover { background: var(--ink-soft); }

.btn-light {
  background: var(--cream);
  color: var(--ink);
}
.btn-light:hover { background: var(--cream-warm); }

.btn-ghost {
  background: transparent;
  color: var(--cream);
  border: 1px solid rgba(251, 250, 247, 0.6);
}
.btn-ghost:hover { background: rgba(251, 250, 247, 0.1); }

.btn-outline {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--ink);
}
.btn-outline:hover {
  background: var(--ink);
  color: var(--cream);
}

.btn-text {
  background: transparent;
  color: var(--ink);
  padding: 14px 0;
}

/* ============ NAVIGATION ============ */
.nav {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  padding: 28px 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav.nav-solid {
  position: relative;
  background: var(--ink);
}

.nav-logo {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 26px;
  color: var(--cream);
  font-style: italic;
  letter-spacing: 0.02em;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}
.nav-logo-img {
  height: 48px;
  width: auto;
  display: block;
  mix-blend-mode: screen;
}
.nav-solid .nav-logo-img {
  mix-blend-mode: normal;
}
@media (max-width: 768px) {
  .nav-logo-img { height: 36px; }
}

.nav-links {
  display: flex;
  gap: 36px;
  align-items: center;
}

.nav-link {
  font-size: 16px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--cream);
  text-decoration: none;
  font-weight: 400;
  opacity: 0.85;
  transition: opacity 0.2s;
}
.nav-link:hover { opacity: 1; }

.nav-link.active { opacity: 1; border-bottom: 1px solid var(--gold); padding-bottom: 4px; }

.nav-toggle {
  display: none;
  background: transparent;
  border: none;
  color: var(--cream);
  cursor: pointer;
  padding: 8px;
}

.nav-toggle svg { width: 24px; height: 24px; }

/* ============ HERO ============ */
.hero {
  position: relative;
  min-height: 680px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cream);
  text-align: center;
  padding: 120px 32px 80px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(20,18,15,0.4) 0%, rgba(20,18,15,0.6) 100%);
}

.hero-content {
  position: relative;
  max-width: 720px;
  z-index: 2;
}

.hero h1 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(48px, 8vw, 84px);
  line-height: 1.05;
  font-weight: 300;
  margin: 28px 0;
  letter-spacing: -0.015em;
}

.hero h1 em { font-weight: 300; font-style: italic; }

.hero p {
  font-size: clamp(14px, 1.2vw, 16px);
  line-height: 1.85;
  max-width: 480px;
  margin: 0 auto 40px;
  color: rgba(251, 250, 247, 0.9);
}

.hero-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Smaller hero for interior pages */
.hero-sm {
  min-height: 420px;
  padding: 140px 32px 80px;
}

.hero-sm h1 {
  font-size: clamp(44px, 6vw, 68px);
  margin: 20px 0 16px;
}

/* ============ SECTIONS ============ */
.section {
  padding: 120px 56px;
}

.section-sm {
  padding: 80px 56px;
}

.section-dark {
  background: var(--cream-warm);
}

.section-ink {
  background: var(--ink);
  color: var(--cream);
}

.container {
  max-width: 1100px;
  margin: 0 auto;
}

.container-narrow {
  max-width: 780px;
  margin: 0 auto;
}

.section h2 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(36px, 5vw, 56px);
  line-height: 1.2;
  font-weight: 300;
  margin: 0 0 24px;
  letter-spacing: -0.01em;
}

.section p {
  font-size: 17px;
  line-height: 1.9;
  color: var(--stone);
}

.text-center { text-align: center; }

/* ============ STATS ============ */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 48px;
  text-align: center;
  border-top: 0.5px solid var(--hairline);
  border-bottom: 0.5px solid var(--hairline);
  padding: 56px 0;
}

.stat-num {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 72px;
  font-weight: 300;
  line-height: 1;
  color: var(--ink-soft);
}

.stat-label {
  font-size: 16px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--stone-light);
  margin-top: 10px;
}

/* ============ CARDS / GALLERY ============ */
.cards-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.cards-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.card-img {
  aspect-ratio: 3/4;
  background-size: cover;
  background-position: center;
  margin-bottom: 20px;
}

.card-tag {
  font-size: 16px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 500;
  margin-bottom: 10px;
}

.card h3 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 26px;
  font-weight: 400;
  margin: 0 0 8px;
}

.card-body {
  font-size: 16px;
  color: var(--stone-light);
  line-height: 1.7;
  margin: 0;
}

.image-full {
  aspect-ratio: 4/5;
  background-size: cover;
  background-position: center;
}

/* ============ TESTIMONIAL ============ */
.testimonial {
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
}

.testimonial-mark {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 72px;
  line-height: 1;
  color: var(--gold);
  margin-bottom: 20px;
}

.testimonial-body {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.45;
  font-style: italic;
  font-weight: 300;
  margin: 0 0 32px;
}

/* ============ PRICING ============ */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border-top: 0.5px solid var(--hairline);
  border-bottom: 0.5px solid var(--hairline);
}

.price-card {
  padding: 56px 40px;
  border-right: 0.5px solid var(--hairline);
  text-align: center;
}
.price-card:last-child { border-right: none; }

.price-card.featured { background: var(--cream-warm); }

.price-season {
  font-size: 16px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--stone-light);
  margin-bottom: 24px;
}

.price-value {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 68px;
  font-weight: 300;
  line-height: 1;
  color: var(--ink);
  margin-bottom: 8px;
}

.price-from {
  font-size: 16px;
  color: var(--stone-light);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 32px;
}

.price-months {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 17px;
  font-style: italic;
  color: var(--stone);
  margin-bottom: 32px;
}

.price-list {
  list-style: none;
  padding: 0;
  margin: 0 0 32px;
  text-align: left;
}
.price-list li {
  font-size: 16px;
  color: var(--stone);
  padding: 10px 0;
  border-bottom: 0.5px solid var(--hairline-light);
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.price-list li::before {
  content: '';
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--gold);
  margin-top: 8px;
  flex-shrink: 0;
}

/* ============ INCLUDES LIST ============ */
.includes-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px 40px;
  margin-top: 56px;
}

.include-item h4 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 24px;
  font-weight: 400;
  margin: 0 0 8px;
}

.include-item p {
  font-size: 16px;
  color: var(--stone-light);
  line-height: 1.7;
  margin: 0;
}

.include-num {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 16px;
  font-style: italic;
  color: var(--gold);
  margin-bottom: 8px;
  display: block;
}

/* ============ ABOUT - TIMELINE ============ */
.timeline {
  position: relative;
  max-width: 720px;
  margin: 0 auto;
}

.timeline-item {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 40px;
  padding: 40px 0;
  border-top: 0.5px solid var(--hairline);
  align-items: start;
}

.timeline-item:last-child { border-bottom: 0.5px solid var(--hairline); }

.timeline-year {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 40px;
  font-weight: 300;
  color: var(--gold);
  line-height: 1;
}

.timeline-content h4 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 26px;
  font-weight: 400;
  margin: 0 0 8px;
}

.timeline-content p {
  font-size: 16px;
  color: var(--stone);
  line-height: 1.8;
  margin: 0;
}

/* ============ CONTACT FORM ============ */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.form-field {
  display: flex;
  flex-direction: column;
}

.form-field.full { grid-column: 1 / -1; }

.form-field label {
  font-size: 16px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--stone-light);
  margin-bottom: 10px;
  font-weight: 500;
}

.form-field input,
.form-field select,
.form-field textarea {
  background: transparent;
  border: none;
  border-bottom: 0.5px solid var(--hairline);
  padding: 16px 0;
  font-family: inherit;
  font-size: 17px;
  color: var(--ink);
  font-weight: 300;
  outline: none;
  transition: border-color 0.2s;
  border-radius: 0;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-bottom-color: var(--ink);
}

.form-field textarea {
  min-height: 120px;
  resize: vertical;
  font-family: inherit;
}

.form-field select { cursor: pointer; }

.contact-info {
  padding: 0 0 0 40px;
  border-left: 0.5px solid var(--hairline);
}

.contact-info h4 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 26px;
  font-weight: 400;
  margin: 0 0 16px;
}

.contact-info p {
  font-size: 16px;
  line-height: 1.8;
  color: var(--stone);
  margin: 0 0 24px;
}

.contact-info .eyebrow { display: block; margin-bottom: 8px; }

/* ============ FAQ ============ */
.faq-item {
  border-bottom: 0.5px solid var(--hairline);
  padding: 28px 0;
}

.faq-q {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 26px;
  font-weight: 400;
  margin: 0 0 12px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.faq-q::after {
  content: '+';
  font-size: 24px;
  color: var(--gold);
  font-weight: 300;
  transition: transform 0.2s;
}

.faq-item.open .faq-q::after { transform: rotate(45deg); }

.faq-a {
  font-size: 16px;
  color: var(--stone);
  line-height: 1.85;
  margin: 12px 0 0;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.faq-item.open .faq-a { max-height: 400px; }

/* ============ FOOTER ============ */
.footer {
  background: var(--ink);
  color: var(--cream);
  padding: 80px 56px 40px;
}

.footer-inner { max-width: 1100px; margin: 0 auto; }

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 0.5px solid var(--hairline-dark);
}

.footer-brand {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 40px;
  font-style: italic;
  margin-bottom: 16px;
}

.footer p {
  font-size: 16px;
  line-height: 1.8;
  color: rgba(251, 250, 247, 0.65);
  margin: 0;
  max-width: 280px;
}

.footer-col-title {
  font-size: 16px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(251, 250, 247, 0.5);
  font-weight: 500;
  margin-bottom: 16px;
  display: block;
}

.footer-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-list a {
  font-size: 16px;
  color: rgba(251, 250, 247, 0.85);
  text-decoration: none;
  letter-spacing: 0.02em;
}

.footer-list a:hover { color: var(--cream); }

.footer-bottom {
  padding-top: 32px;
  display: flex;
  justify-content: space-between;
  font-size: 16px;
  color: rgba(251, 250, 247, 0.4);
  letter-spacing: 0.1em;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-bottom .legal { display: flex; gap: 24px; }

/* ============ MOBILE RESPONSIVE ============ */
@media (max-width: 900px) {
  .nav { padding: 20px 24px; }
  .nav-links { display: none; }
  .nav-toggle { display: block; }

  .nav-links.open {
    display: flex;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--ink);
    padding: 24px;
    gap: 20px;
    align-items: flex-start;
  }

  .section { padding: 72px 24px; }
  .section-sm { padding: 56px 24px; }

  .hero { padding: 100px 24px 64px; min-height: 580px; }
  .hero-sm { min-height: 360px; padding: 120px 24px 64px; }

  .stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 40px 24px;
    padding: 40px 0;
  }

  .stat-num { font-size: 42px; }

  .cards-3 { grid-template-columns: 1fr; gap: 40px; }
  .cards-2 { grid-template-columns: 1fr; gap: 40px; }

  .pricing-grid { grid-template-columns: 1fr; }
  .price-card {
    border-right: none;
    border-bottom: 0.5px solid var(--hairline);
    padding: 48px 32px;
  }
  .price-card:last-child { border-bottom: none; }

  .includes-grid { grid-template-columns: 1fr; gap: 32px; }

  .timeline-item {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .form-grid { grid-template-columns: 1fr; }

  .contact-info {
    padding: 40px 0 0;
    border-left: none;
    border-top: 0.5px solid var(--hairline);
    margin-top: 40px;
  }

  .footer { padding: 56px 24px 32px; }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px 24px;
  }
  .footer-grid > div:first-child { grid-column: 1 / -1; }

  .card-img { aspect-ratio: 4/3; }
  .image-full { aspect-ratio: 3/2; }

  /* Contact page form + sidebar stack */
  .section > .container > div[style*="grid-template-columns: 1.4fr 1fr"] {
    display: block !important;
  }
  .section > .container > div[style*="grid-template-columns: 1.4fr 1fr"] > aside {
    margin-top: 48px;
  }
}

@media (max-width: 520px) {
  .hero-actions { flex-direction: column; width: 100%; }
  .hero-actions .btn { width: 100%; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; }
}

/* ============ MOTION FOUNDATION ============ */

/* Disable the existing CSS smooth-scroll — Lenis takes over. */
html { scroll-behavior: auto; }

/* Lenis sets a class on <html> while active; keep native scroll snapping off. */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: hidden; }

/* Under reduced-motion, force everything to its final state and kill smooth scroll. */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* ============ REVEAL PRIMITIVES ============ */

/* Hidden pre-reveal states only apply when JS is active. */
html.js [data-reveal] {
  opacity: 0;
  will-change: opacity, transform;
  transition: none;
}
html.js [data-reveal="fade"]      { transform: none; }
html.js [data-reveal="fade-up"]   { transform: translate3d(0, 24px, 0); }
html.js [data-reveal="fade-left"] { transform: translate3d(-24px, 0, 0); }
html.js [data-reveal="fade-right"]{ transform: translate3d(24px, 0, 0); }
html.js [data-reveal="scale-in"]  { transform: scale(0.94); }

/* After reveal, GSAP will clear the inline transform/opacity. */

@media (prefers-reduced-motion: reduce) {
  html.js [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
  }
}

/* ============ HERO PARALLAX LAYER ============ */
.hero { position: relative; overflow: hidden; }
.hero-bg {
  position: absolute;
  inset: -10% 0;
  background-size: cover;
  background-position: center;
  z-index: 0;
  will-change: transform;
}
.hero-content { position: relative; z-index: 1; }

/* ============ GOLD UNDERLINE ============ */
.gold-underline {
  display: block;
  margin: 16px auto 0;
  width: 220px;
  height: 8px;
  overflow: visible;
}
.gold-underline line {
  stroke: var(--gold);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-dasharray: 220;
  stroke-dashoffset: 220;
}
@media (prefers-reduced-motion: reduce) {
  .gold-underline line { stroke-dashoffset: 0; }
}

/* ============ FRAME LINES ============ */
.frame-wrap { position: relative; }
.frame-svg {
  position: absolute;
  inset: 12px;
  width: calc(100% - 24px);
  height: calc(100% - 24px);
  pointer-events: none;
  overflow: visible;
  z-index: 2;
}
.frame-svg rect {
  fill: none;
  stroke: var(--gold);
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
}
@media (prefers-reduced-motion: reduce) {
  .frame-svg rect { stroke-dasharray: none !important; stroke-dashoffset: 0 !important; }
}

/* ============ CUSTOM CURSOR ============ */
.cursor-dot, .cursor-halo {
  position: fixed;
  top: 0; left: 0;
  pointer-events: none;
  z-index: 9999;
  border-radius: 50%;
  transform: translate3d(-50%, -50%, 0);
  mix-blend-mode: difference;
}
.cursor-dot {
  width: 6px; height: 6px;
  background: #FBFAF7;
}
.cursor-halo {
  width: 36px; height: 36px;
  border: 1px solid rgba(251, 250, 247, 0.6);
  transition: width 0.25s ease, height 0.25s ease, background 0.25s ease, border-color 0.25s ease;
}
.cursor-halo.is-hover {
  width: 60px; height: 60px;
  background: rgba(184, 165, 130, 0.14);
  border-color: rgba(184, 165, 130, 0.6);
}
@media (hover: none), (pointer: coarse), (max-width: 1023px), (prefers-reduced-motion: reduce) {
  .cursor-dot, .cursor-halo { display: none !important; }
}
@media (hover: hover) and (pointer: fine) and (min-width: 1024px) {
  html.has-custom-cursor, html.has-custom-cursor * { cursor: none !important; }
}

/* ============ GRAIN OVERLAY ============ */
/* Hero uses ::after so the existing ::before scrim (line 183) is preserved. */
.section-dark, .hero { position: relative; }
.section-dark::before, .hero::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 3;
  opacity: 0.04;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='300' height='300'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix type='matrix' values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.55 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  background-size: 300px 300px;
}
.section-dark > * { position: relative; z-index: 2; }

/* ============ EYEBROW DASHES ============ */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 14px;
}
.eyebrow::before, .eyebrow::after {
  content: '';
  width: 16px;
  height: 1px;
  background: var(--gold);
  display: inline-block;
  flex-shrink: 0;
}

/* ============ SPLIT UNIT DEFAULTS ============ */
html.js [data-split] .split-unit {
  display: inline-block;
  will-change: transform, opacity;
}

/* ============ HOME HERO READABILITY ============ */
body[data-page="home"] .hero::before {
  background: linear-gradient(180deg, rgba(15,13,10,0.55) 0%, rgba(15,13,10,0.78) 100%);
}
body[data-page="home"] .hero-content h1,
body[data-page="home"] .hero-content p,
body[data-page="home"] .hero-content .eyebrow {
  text-shadow: 0 2px 20px rgba(0,0,0,0.45);
}
