/* =====================================================================
   Terra Vita Agri — site styles (earthy subset of SpendSense tokens)
   ===================================================================== */
:root {
  /* dark theme — green-grey canvas, light text, lime accent */
  --ink:        #e9efe9;   /* primary text (light) */
  --ink-2:      #a9b6ac;   /* secondary */
  --ink-3:      #76837a;   /* tertiary / meta */
  --canvas:     #181e1b;   /* dark green-grey page */
  --canvas-2:   #222a26;   /* raised surface */
  --line:       rgba(255,255,255,0.10);
  --line-2:     rgba(255,255,255,0.18);

  --field:      #1f6748;   /* primary action green (lifted for dark) */
  --field-mid:  #2a875e;   /* hover / links / active */
  --field-deep: #18503C;   /* deep brand green */
  --field-soft: rgba(168,207,69,0.12); /* lime-tint surface */
  --lime:       #A8CF45;   /* bright lime accent */
  --grain:      var(--lime);
  --grain-2:    var(--lime);
  --sun:        var(--lime);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }
body {
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--font-sans);
  overflow-x: hidden;
}

/* faint grain over the whole page */
body::after {
  content: "";
  position: fixed; inset: 0; z-index: 5; pointer-events: none;
  background-image: radial-gradient(rgba(255, 255, 255, 0.022) 1px, transparent 1px);
  background-size: 4px 4px;
  opacity: 0.7;
}

/* ---- the fixed 3D canvas behind everything ---- */
#crop-canvas {
  position: fixed; inset: 0;
  width: 100vw; height: 100vh;
  z-index: 1;
  display: block;
}
/* readability scrim — keeps content legible over the fruit */
#scrim {
  position: fixed; inset: 0; z-index: 2; pointer-events: none;
  background:
    linear-gradient(105deg,
      var(--canvas) 0%,
      rgba(24, 30, 27, 0.92) 30%,
      rgba(24, 30, 27, 0.45) 52%,
      rgba(24, 30, 27, 0.0) 70%);
}
@media (max-width: 820px) {
  #scrim {
    background:
      linear-gradient(190deg,
        rgba(24, 30, 27, 0.0) 0%,
        rgba(24, 30, 27, 0.55) 34%,
        var(--canvas) 56%);
  }
}

/* ---- top nav ---- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 30;
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px clamp(20px, 5vw, 64px);
  transition: background var(--dur-base), border-color var(--dur-base);
  border-bottom: 1px solid transparent;
}
.nav.solid {
  background: rgba(24, 30, 27, 0.82);
  border-bottom: 1px solid var(--line);
  backdrop-filter: saturate(1.2) blur(8px);
}
.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; color: var(--ink); }
.brand .mark {
  width: 40px; height: 40px; border-radius: 11px;
  background: #fbf8f2;
  display: grid; place-items: center;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.brand .mark img { width: 30px; height: 30px; object-fit: contain; display: block; }
.brand .wm { display: flex; flex-direction: column; line-height: 1; }
.brand .wm b {
  font-family: var(--font-display); font-weight: 800;
  font-size: 19px; letter-spacing: -0.02em; color: var(--ink);
  white-space: nowrap;
}
.brand .wm small {
  font-size: 10px; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--lime); font-weight: 600; margin-top: 3px;
}

/* ---- loading screen ---- */
#loader {
  position: fixed; inset: 0; z-index: 9999;
  display: flex; align-items: center; justify-content: center;
  background: var(--canvas);
  transition: transform 0.65s cubic-bezier(0.65,0,0.35,1), opacity 0.65s ease;
}
#loader img {
  width: 96px; height: 96px; object-fit: contain;
  animation: loaderPulse 1s ease-in-out infinite;
}
#loader.hide {
  transform: translateY(-100%);
  opacity: 0;
}
@keyframes loaderPulse {
  0%, 100% { transform: scale(1); opacity: 0.92; }
  50%      { transform: scale(1.06); opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  #loader img { animation: none; }
}
.nav-links { display: flex; align-items: center; gap: 30px; }
.nav-links a {
  font-size: 14px; font-weight: 500; color: var(--ink-2);
  text-decoration: none; transition: color var(--dur-fast);
}
.nav-links a:hover { color: var(--lime); }
.btn {
  font-family: var(--font-sans); font-size: 14px; font-weight: 600;
  border: none; cursor: pointer; border-radius: var(--radius-pill);
  padding: 11px 20px; transition: transform var(--dur-fast), background var(--dur-fast);
  text-decoration: none; display: inline-flex; align-items: center; gap: 8px;
}
.btn:active { transform: scale(0.97); }
.btn-primary, .nav-links a.btn-primary { background: var(--field); color: #eef5ee; }
.btn-primary:hover, .nav-links a.btn-primary:hover { background: var(--field-mid); color: #eef5ee; }
.btn-ghost, .nav-links a.btn-ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--line-2); }
.btn-ghost:hover, .nav-links a.btn-ghost:hover { border-color: var(--lime); color: var(--lime); }
@media (max-width: 980px) { .nav-links a:not(.btn) { display: none; } }

/* ---- section layout ---- */
main { position: relative; z-index: 10; }
.section {
  min-height: 100vh;
  display: flex; align-items: center;
  padding: 120px clamp(20px, 5vw, 64px) 96px;
}
.panel { max-width: 560px; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  font-size: 12px; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--lime);
  padding: 7px 14px; border-radius: var(--radius-pill);
  background: var(--field-soft);
  border: 1px solid rgba(168, 207, 69, 0.32);
}
.eyebrow .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--grain-2); }

.display {
  font-family: var(--font-display); font-weight: 800;
  letter-spacing: -0.025em; line-height: 1.04;
  font-size: clamp(40px, 5.8vw, 74px);
  color: var(--ink); margin: 22px 0 0;
  text-wrap: balance;
}
.display .leaf, .h2 .leaf,
.display .gold, .h2 .gold { color: var(--lime); }

.h2 {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(32px, 4.4vw, 52px); line-height: 1.06;
  letter-spacing: -0.02em; margin: 18px 0 0; text-wrap: balance;
}
.lead {
  font-size: clamp(17px, 1.5vw, 20px); line-height: 1.55;
  color: var(--ink-2); margin-top: 22px; max-width: 46ch;
}
.voice {
  font-family: var(--font-voice); font-style: italic; font-weight: 500;
  font-size: clamp(20px, 2.1vw, 26px); line-height: 1.4;
  color: #c6da9a; margin-top: 26px; max-width: 30ch;
  padding-left: 18px; border-left: 2px solid var(--lime);
}
.cta-row { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }
.cta-row .btn { padding: 14px 26px; font-size: 15px; }

/* stat strip */
.stats { display: flex; flex-wrap: wrap; gap: 36px; margin-top: 44px; }
.stat .num {
  font-family: var(--font-display); font-weight: 800;
  font-size: clamp(34px, 4vw, 46px); letter-spacing: -0.02em;
  color: var(--lime); line-height: 1;
}
.stat .num .u { color: var(--ink-2); }
.stat .lbl { font-size: 13px; color: var(--ink-3); margin-top: 8px; max-width: 16ch; }

/* focus list (division capabilities) */
.focus {
  list-style: none; margin-top: 30px;
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px 28px;
  max-width: 540px;
}
.focus li {
  display: flex; align-items: center; gap: 11px;
  font-size: 15px; font-weight: 500; color: var(--ink);
  padding: 13px 2px; border-top: 1px solid var(--line);
}
.focus li::before {
  content: "✓"; flex: none;
  width: 22px; height: 22px; border-radius: 50%;
  background: rgba(168, 207, 69, 0.16); color: var(--lime);
  display: grid; place-items: center;
  font-size: 12px; font-weight: 700;
  box-shadow: inset 0 0 0 1px rgba(168, 207, 69, 0.4);
}
@media (max-width: 600px) { .focus { grid-template-columns: 1fr; gap: 0; } }

/* feature list */
.flist { margin-top: 30px; display: flex; flex-direction: column; gap: 4px; }.frow {
  display: grid; grid-template-columns: auto 1fr; gap: 16px; align-items: start;
  padding: 18px 0; border-top: 1px solid var(--line);
}
.frow:last-child { border-bottom: 1px solid var(--line); }
.frow .ic {
  width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center;
  background: var(--canvas-2); border: 1px solid var(--line); color: var(--lime);
}
.frow .ic svg { width: 21px; height: 21px; }
.frow h4 { font-size: 16px; font-weight: 600; color: var(--ink); }
.frow p { font-size: 14px; color: var(--ink-2); margin-top: 4px; line-height: 1.5; }

/* contact card */
.contact-card {
  margin-top: 30px; background: var(--canvas-2);
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  box-shadow: 0 16px 40px -16px rgba(0,0,0,0.5); padding: 28px;
}
.contact-card .row { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.contact-card .row + .row { border-top: 1px solid var(--line); }
.contact-card .row svg { width: 18px; height: 18px; color: var(--lime); flex: none; }
.contact-card .row span { font-size: 15px; color: var(--ink); }
.contact-card .row b { font-weight: 600; }

/* ---- scroll reveal ---- */
.reveal { opacity: 0; transform: translateY(72px); transition:
  opacity 0.9s var(--ease-standard), transform 0.9s var(--ease-standard); }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: 0.08s; }
.reveal.d2 { transition-delay: 0.16s; }
.reveal.d3 { transition-delay: 0.24s; }
.reveal.d4 { transition-delay: 0.32s; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ---- right-side section dots ---- */
.dots {
  position: fixed; right: clamp(14px, 2.4vw, 30px); top: 50%;
  transform: translateY(-50%); z-index: 25;
  display: flex; flex-direction: column; gap: 14px;
}
.dots button {
  width: 11px; height: 11px; border-radius: 50%; border: 1.5px solid var(--line-2);
  background: transparent; cursor: pointer; padding: 0; position: relative;
  transition: all var(--dur-base);
}
.dots button::after {
  content: attr(data-label); position: absolute; right: 22px; top: 50%;
  transform: translateY(-50%); white-space: nowrap;
  font-size: 11px; font-weight: 600; letter-spacing: 0.04em; color: var(--ink-2);
  opacity: 0; transition: opacity var(--dur-fast); pointer-events: none;
}
.dots button:hover::after { opacity: 1; }
.dots button.on { background: var(--lime); border-color: var(--lime); transform: scale(1.25); }
@media (max-width: 820px) { .dots { display: none; } }

/* progress bar */
.progress {
  position: fixed; top: 0; left: 0; height: 3px; z-index: 40;
  background: linear-gradient(90deg, var(--field-mid), var(--lime));
  width: 0%;
}

/* footer mini */
.foot {
  position: relative; z-index: 10;
  padding: 26px clamp(20px, 5vw, 64px);
  display: flex; justify-content: space-between; align-items: center;
  border-top: 1px solid var(--line); background: var(--canvas);
  font-size: 13px; color: var(--ink-3);
}
.foot a { color: var(--ink-2); text-decoration: none; }
.foot a:hover { color: var(--lime); }
@media (max-width: 560px) { .foot { flex-direction: column; gap: 10px; } }
