:root {
  --cream: #fbf7ef;
  --cream-2: #f4ecdb;
  --cream-3: #ebe1c8;
  --paper: #ffffff;
  --ink: #2b231a;
  --ink-soft: #5a4d3b;
  --muted: #8a7c66;
  --line: #e3d9c2;
  --sage: #6b8c5a;
  --sage-deep: #3f5c33;
  --mulberry: #7a3d52;
  --terracotta: #c47648;
  --shadow-soft: 0 1px 2px rgba(34, 28, 18, 0.03), 0 6px 18px rgba(34, 28, 18, 0.06);

  --f-display: "DM Serif Display", Georgia, "Times New Roman", serif;
  --f-body: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --f-script: "Caveat", "DM Serif Display", cursive;

  --pad-x: clamp(1.25rem, 4vw, 4rem);
  --pad-y: clamp(3.5rem, 8vw, 7rem);
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 17px;
  line-height: 1.65;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a { color: var(--terracotta); text-decoration: none; transition: color .2s; }
a:hover { color: var(--sage-deep); }

h1, h2, h3 {
  font-family: var(--f-display);
  font-weight: 400;
  letter-spacing: -0.005em;
  color: var(--ink);
  margin: 0 0 1rem;
  line-height: 1.08;
}

h1 { font-size: clamp(2.75rem, 8vw, 5.75rem); }
h1 em { font-style: italic; color: var(--terracotta); }
h2 { font-size: clamp(1.85rem, 4vw, 3rem); max-width: 22ch; }
h3 { font-family: var(--f-body); font-size: 1.35rem; font-weight: 600; letter-spacing: -0.01em; }

p { margin: 0 0 1rem; }
p:last-child { margin-bottom: 0; }

.eyebrow {
  font-family: var(--f-script);
  font-size: 1.4rem;
  font-weight: 500;
  letter-spacing: 0.005em;
  text-transform: none;
  color: var(--terracotta);
  margin: 0 0 .5rem;
  line-height: 1;
}

/* ---------- nav ---------- */

.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem var(--pad-x);
  background: rgba(251, 247, 239, 0.85);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .25s, padding .25s;
}
.nav.is-scrolled { border-bottom-color: var(--line); padding-top: .65rem; padding-bottom: .65rem; }

.brand {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  font-family: var(--f-display);
  font-size: 1.25rem;
  font-weight: 400;
  color: var(--ink-soft);
  letter-spacing: 0;
}
.brand:hover { color: var(--ink); }
.brand-mark {
  display: block;
  width: 2.2rem;
  height: 2.2rem;
  margin-top: -0.15rem;
}

.nav-links {
  display: flex;
  gap: clamp(1rem, 2.4vw, 2rem);
  font-size: .92rem;
  font-weight: 500;
}
.nav-links a {
  color: var(--ink-soft);
  position: relative;
}
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: -4px;
  width: 0; height: 1px;
  background: var(--terracotta);
  transition: width .25s;
}
.nav-links a:hover { color: var(--terracotta); }
.nav-links a:hover::after { width: 100%; }

.lang-toggle {
  background: none;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: .4rem .85rem;
  font-family: var(--f-body);
  font-size: .78rem;
  font-weight: 500;
  letter-spacing: .12em;
  color: var(--ink-soft);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  transition: border-color .2s, background .2s;
}
.lang-toggle:hover { border-color: var(--terracotta); }
.lang-opt { opacity: .45; transition: opacity .2s, color .2s; }
.lang-opt.is-active { opacity: 1; color: var(--terracotta); }
.lang-sep { opacity: .35; }

@media (max-width: 760px) {
  .nav-links { display: none; }
}

/* ---------- hero ---------- */

.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: flex-end;
  padding: 0 var(--pad-x) clamp(2.5rem, 8vw, 6rem);
  overflow: hidden;
  color: var(--cream);
}
.hero-image, .hero-overlay {
  position: absolute; inset: 0;
}
.hero-image img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 35%;
}
.hero-overlay {
  background:
    linear-gradient(180deg, rgba(26, 47, 25, 0.15) 0%, rgba(26, 47, 25, 0) 35%, rgba(26, 47, 25, 0.85) 100%);
}
.hero-text {
  position: relative;
  max-width: 56rem;
  z-index: 2;
}
.hero-text .eyebrow {
  color: rgba(250, 246, 238, 0.85);
}
.hero-text h1 {
  color: var(--cream);
  text-shadow: 0 2px 24px rgba(0, 0, 0, .25);
}
.hero-text h1 em { color: #f0c4a0; }
.lede {
  font-family: var(--f-body);
  font-size: clamp(1.15rem, 1.7vw, 1.35rem);
  font-weight: 400;
  color: rgba(251, 247, 239, 0.92);
  margin-top: 1.5rem;
  max-width: 38ch;
  line-height: 1.4;
}
.scroll-cue {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  margin-top: 2.5rem;
  font-size: .82rem;
  font-weight: 500;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--cream);
  border-bottom: 1px solid rgba(250, 246, 238, 0.4);
  padding-bottom: .3rem;
}
.scroll-cue:hover { color: var(--cream); border-color: var(--cream); }

/* ---------- sections ---------- */

.section {
  padding: var(--pad-y) var(--pad-x);
}
.section--intro { background: var(--cream); }
.section--plantations { background: var(--cream-2); }
.section--history { background: var(--cream); }
.section--history .section-header { border-top: 1px dashed var(--line); padding-top: clamp(1.5rem, 3vw, 2.5rem); }
.section--team { background: var(--cream-2); }
.section--gallery { background: var(--cream); }
.section--contact { background: var(--cream-3); }

.section-header {
  max-width: 60rem;
  margin: 0 auto clamp(2.5rem, 5vw, 4rem);
  text-align: center;
}
.section-header h2 { margin-left: auto; margin-right: auto; }

.section-grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: clamp(2.5rem, 5vw, 5rem);
  align-items: center;
  max-width: 78rem;
  margin: 0 auto;
}
.section-text p {
  color: var(--ink-soft);
  font-size: 1.05rem;
  max-width: 38ch;
}
.section-figure {
  margin: 0;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}
.section-figure img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

@media (max-width: 820px) {
  .section-grid { grid-template-columns: 1fr; }
  .section-figure img { aspect-ratio: 5 / 4; }
}

/* ---------- cards (plantations) ---------- */

.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.5rem, 2.5vw, 2.25rem);
  max-width: 84rem;
  margin: 0 auto;
}
.card {
  background: var(--paper);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  display: flex; flex-direction: column;
  transition: transform .35s, box-shadow .35s;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 2px 4px rgba(34, 28, 18, .06), 0 16px 36px rgba(34, 28, 18, .12); }
.card-image { aspect-ratio: 4 / 3; overflow: hidden; }
.card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.card:hover .card-image img { transform: scale(1.04); }
.card-body { padding: 1.75rem 1.75rem 2rem; }
.card-number {
  font-family: var(--f-script);
  font-size: 1.3rem;
  color: var(--terracotta);
  margin: 0 0 .25rem;
  line-height: 1;
}
.card-stat {
  font-size: .92rem;
  color: var(--muted);
  margin: .25rem 0 1rem;
}
.card-stat strong { color: var(--ink); font-weight: 600; }
.card-body p:last-child { color: var(--ink-soft); }

@media (max-width: 920px) { .cards { grid-template-columns: 1fr; max-width: 32rem; } }

/* ---------- history ---------- */

.story {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 4vw, 4rem);
  align-items: center;
  max-width: 72rem;
  margin: 0 auto;
}
.story-image { margin: 0; }
.story-image img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 16px;
}
.story-image figcaption {
  font-family: var(--f-script);
  font-size: 1.15rem;
  color: var(--terracotta);
  margin-top: .5rem;
  text-align: center;
}
.story-text p {
  font-size: 1.05rem;
  color: var(--ink-soft);
  max-width: 42ch;
}

@media (max-width: 920px) {
  .story { grid-template-columns: 1fr; max-width: 36rem; }
  .story-text { order: 0; }
  .story-image { order: 1; }
}

/* ---------- team ---------- */

.team {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.5rem, 3vw, 3rem);
  max-width: 78rem;
  margin: 0 auto;
}
.member {
  padding: 2rem 1.75rem;
  border-top: 1px solid var(--line);
  text-align: center;
}
.member-portrait {
  width: 9rem;
  height: 9rem;
  margin: 0 auto 1.5rem;
  border-radius: 50%;
  overflow: hidden;
  background: var(--cream-2);
  box-shadow: var(--shadow-soft);
}
.member-portrait img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center top;
}
.member:nth-of-type(2) .member-portrait img {
  object-position: 70% top;
}
.member:nth-of-type(3) .member-portrait img {
  object-position: 100% 30%;
}
.member h3 { margin-bottom: .15rem; }
.member .role {
  font-family: var(--f-script);
  color: var(--terracotta);
  font-size: 1.2rem;
  margin: 0 0 1rem;
  line-height: 1;
}
.member p:last-child { color: var(--ink-soft); text-align: left; }

@media (max-width: 880px) { .team { grid-template-columns: 1fr; max-width: 32rem; } }

/* ---------- gallery ---------- */

.gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 10rem;
  gap: .75rem;
  max-width: 90rem;
  margin: 0 auto;
}
.g-item {
  display: block;
  overflow: hidden;
  border-radius: 8px;
  cursor: zoom-in;
  background: var(--cream-3);
}
.g-item img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .5s ease, opacity .25s;
  opacity: .92;
}
.g-item:hover img { transform: scale(1.05); opacity: 1; }
.g-tall { grid-row: span 2; }
.g-wide { grid-column: span 2; }

@media (max-width: 880px) {
  .gallery { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 8rem; }
  .g-wide { grid-column: span 2; }
  .g-tall { grid-row: span 2; }
}

/* lightbox */
.lightbox {
  position: fixed; inset: 0;
  background: rgba(15, 12, 8, 0.94);
  z-index: 100;
  display: grid; place-items: center;
  padding: 2rem;
  animation: fadeIn .2s ease;
}
.lightbox[hidden] { display: none; }
.lightbox-img {
  max-width: 100%; max-height: 100%;
  object-fit: contain;
  box-shadow: 0 20px 60px rgba(0,0,0,.4);
}
.lightbox-close {
  position: absolute;
  top: 1rem; right: 1.25rem;
  background: none;
  border: none;
  color: var(--cream);
  font-size: 2.5rem;
  line-height: 1;
  cursor: pointer;
  opacity: .75;
}
.lightbox-close:hover { opacity: 1; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

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

.contact-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: clamp(2.5rem, 5vw, 5rem);
  align-items: center;
  max-width: 70rem;
  margin: 0 auto;
}
.contact-grid h2 { max-width: 18ch; }
.contact-lede {
  color: var(--ink-soft);
  font-size: 1.05rem;
  max-width: 42ch;
  margin-top: 1rem;
}
.contact-list {
  list-style: none;
  padding: 0; margin: 0;
  display: grid;
  gap: 1.25rem;
}
.contact-list li {
  display: grid;
  gap: .15rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px dashed var(--line);
}
.contact-list li:last-child { border-bottom: 0; padding-bottom: 0; }
.contact-label {
  font-family: var(--f-script);
  font-size: 1.1rem;
  letter-spacing: 0;
  text-transform: none;
  color: var(--terracotta);
}
.contact-list a {
  color: var(--ink);
  font-size: 1.1rem;
  font-family: var(--f-body);
  font-weight: 500;
  border-bottom: 1px solid var(--terracotta);
  padding-bottom: 2px;
  display: inline-block;
}
.contact-list a:hover { color: var(--terracotta); }
.contact-list li span:not(.contact-label) {
  color: var(--ink);
  font-size: 1.1rem;
  font-weight: 500;
  border-bottom: 1px solid var(--terracotta);
  padding-bottom: 2px;
  display: inline-block;
}

@media (max-width: 820px) { .contact-grid { grid-template-columns: 1fr; } }

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

.footer {
  padding: 2rem var(--pad-x);
  text-align: center;
  background: var(--cream-3);
  color: var(--muted);
  font-size: .85rem;
  border-top: 1px dashed var(--line);
}

/* ---------- reveal on scroll ---------- */

.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .8s ease, transform .8s ease;
}
.reveal.is-in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
  .card, .card-image img, .g-item img { transition: none; }
}
