/* === Tend Landing Page Styles === */

:root {
  --soil-brown: #3D2E1E;
  --terracotta: #B86F50;
  --sand: #E8DCC4;
  --cream: #F5F0E6;
  --oak: #8B7355;
  --birch: #C4B49A;
  --walnut: #5C4A3A;
  --copper: #7D6B5D;
  --patina: #6B7B6E;
  --iron: #6E6A65;
  --rust-error: #9E5A4A;
  --slate-info: #5D6B7D;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'DM Sans', sans-serif;
  color: var(--soil-brown);
  background: var(--cream);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* === Typography === */

h1, h2, h3 {
  font-family: 'Lora', serif;
  font-weight: 600;
  line-height: 1.2;
}

/* === Layout === */

.section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 24px;
  position: relative;
}

.section-inner {
  max-width: 960px;
  width: 100%;
  margin: 0 auto;
}

/* === Section 1: Hero === */

.hero {
  background: var(--cream);
  overflow: hidden;
  flex-direction: column;
}

.hero-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  z-index: 0;
}

.hero-bg svg {
  position: absolute;
  width: 100%;
  height: 100%;
}

.hero-blob {
  fill: var(--sand);
  opacity: 0.5;
}

.hero-blob:nth-child(2) {
  fill: var(--birch);
  opacity: 0.3;
}

@keyframes drift1 {
  0%, 100% { transform: translate(0, 0) scale(1) rotate(0deg); }
  33% { transform: translate(30px, -20px) scale(1.05) rotate(3deg); }
  66% { transform: translate(-20px, 15px) scale(0.97) rotate(-2deg); }
}

@keyframes drift2 {
  0%, 100% { transform: translate(0, 0) scale(1) rotate(0deg); }
  33% { transform: translate(-25px, 25px) scale(0.95) rotate(-4deg); }
  66% { transform: translate(35px, -10px) scale(1.03) rotate(2deg); }
}

@keyframes drift3 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(15px, -30px) scale(1.08); }
}

.hero-blob-1 { animation: drift1 25s ease-in-out infinite; }
.hero-blob-2 { animation: drift2 30s ease-in-out infinite; }
.hero-blob-3 { animation: drift3 35s ease-in-out infinite; }

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}

.hero h1 {
  font-size: 3.5rem;
  color: var(--soil-brown);
  font-weight: 500;
}

.hero-sub {
  font-size: 1.25rem;
  color: var(--copper);
  max-width: 480px;
  font-weight: 400;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--terracotta);
  color: var(--cream);
  border: none;
  border-radius: 24px;
  padding: 16px 32px;
  font-size: 1.1rem;
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.15s ease;
  min-height: 44px;
}

.btn-primary:hover {
  background: var(--walnut);
  transform: translateY(-1px);
}

.btn-primary:active {
  transform: translateY(0);
}

.hero-hint {
  font-size: 0.85rem;
  color: var(--iron);
  max-width: 300px;
}

.hero-loading {
  font-size: 1rem;
  color: var(--copper);
  font-style: italic;
}

/* === Section 2: Map === */

.map-section {
  background: var(--cream);
  padding: 0;
  flex-direction: column;
}

.map-container {
  width: 100%;
  height: 70vh;
  position: relative;
}

#map {
  width: 100%;
  height: 100%;
  background: #EDE7D9;
}

.map-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 48px 24px;
  background: linear-gradient(to top, rgba(245, 240, 230, 0.95) 0%, rgba(245, 240, 230, 0.7) 70%, transparent 100%);
  text-align: center;
  z-index: 10;
}

.map-overlay--centered {
  top: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: transparent;
}

.map-overlay h2 {
  font-size: 1.75rem;
  margin-bottom: 8px;
  color: var(--soil-brown);
}

.map-overlay p {
  font-size: 1rem;
  color: var(--copper);
  max-width: 520px;
  margin: 0 auto;
  font-style: italic;
}

.map-below {
  padding: 48px 24px 80px;
  text-align: center;
}

/* Sprouting markers */

.sprout-marker {
  width: 28px;
  height: 28px;
  cursor: default;
  animation: sprout 0.7s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

@keyframes sprout {
  0% {
    transform: scale(0);
    opacity: 0;
  }
  60% {
    opacity: 1;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

/* === Section 3: Value Props === */

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

.value-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
  margin-bottom: 64px;
}

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

.value-card.animate-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.value-card.animate-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.value-card .icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 20px;
}

.value-card h3 {
  font-size: 1.35rem;
  margin-bottom: 12px;
  color: var(--soil-brown);
  font-weight: 500;
}

.value-card p {
  font-size: 0.95rem;
  color: var(--copper);
  line-height: 1.7;
}

.value-tagline {
  text-align: center;
  font-family: 'Lora', serif;
  font-style: italic;
  font-size: 1.5rem;
  color: var(--walnut);
}

.value-tagline.animate-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease 0.3s, transform 0.6s ease 0.3s;
}

.value-tagline.animate-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* === Section 4: CTA === */

.cta-section {
  background: var(--sand);
}

.cta-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.cta-content h2 {
  font-size: 2.5rem;
  color: var(--soil-brown);
  font-weight: 500;
}

.cta-sub {
  font-size: 1.1rem;
  color: var(--copper);
  max-width: 420px;
  margin-bottom: 16px;
}

.waitlist-form {
  display: flex;
  gap: 12px;
  max-width: 440px;
  width: 100%;
}

.waitlist-form input[type="email"] {
  flex: 1;
  padding: 14px 20px;
  border: 2px solid var(--oak);
  border-radius: 24px;
  background: var(--cream);
  font-family: 'DM Sans', sans-serif;
  font-size: 1rem;
  color: var(--soil-brown);
  outline: none;
  transition: border-color 0.2s ease;
  min-height: 44px;
}

.waitlist-form input[type="email"]:focus {
  border-color: var(--terracotta);
}

.waitlist-form input[type="email"]::placeholder {
  color: var(--birch);
}

.waitlist-form button {
  white-space: nowrap;
}

.waitlist-form button .spinner {
  display: none;
  width: 18px;
  height: 18px;
  border: 2px solid var(--cream);
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

.waitlist-form button.loading .spinner {
  display: inline-block;
}

.waitlist-form button.loading .btn-text {
  display: none;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.waitlist-privacy {
  font-size: 0.8rem;
  color: var(--iron);
  max-width: 380px;
}

/* Waitlist success */
.waitlist-success {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.waitlist-success.show {
  display: flex;
}

.waitlist-success p {
  font-size: 1.15rem;
  color: var(--patina);
  font-weight: 500;
}

.seed-sprout-anim {
  width: 48px;
  height: 48px;
}

.seed-sprout-anim .seed {
  animation: seedDrop 0.6s ease-in both;
}

.seed-sprout-anim .sprout-stem {
  animation: growUp 0.8s ease-out 0.8s both;
  transform-origin: bottom center;
}

.seed-sprout-anim .sprout-leaf-l,
.seed-sprout-anim .sprout-leaf-r {
  animation: leafUnfurl 0.5s ease-out 1.4s both;
  transform-origin: bottom center;
}

@keyframes seedDrop {
  0% { transform: translateY(-20px); opacity: 0; }
  100% { transform: translateY(0); opacity: 1; }
}

@keyframes growUp {
  0% { transform: scaleY(0); }
  100% { transform: scaleY(1); }
}

@keyframes leafUnfurl {
  0% { transform: scale(0); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

.cta-form-container.hidden {
  display: none;
}

/* Download buttons (post-launch) */
.download-badges {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: center;
}

.download-badges a {
  display: block;
  height: 48px;
}

.download-badges img {
  height: 100%;
}

.cta-echo {
  margin-top: 48px;
  font-size: 0.95rem;
  color: var(--iron);
  font-style: italic;
}

/* === Footer === */

footer {
  background: var(--sand);
  padding: 32px 24px;
  text-align: center;
  border-top: 1px solid var(--birch);
}

.footer-inner {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.footer-brand {
  font-family: 'Lora', serif;
  font-size: 1.25rem;
  color: var(--soil-brown);
  font-weight: 600;
}

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

.footer-links a {
  color: var(--copper);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--terracotta);
}

.footer-copy {
  font-size: 0.8rem;
  color: var(--iron);
}

/* === Responsive === */

@media (max-width: 768px) {
  .section {
    padding: 48px 20px;
  }

  .hero h1 {
    font-size: 2.5rem;
  }

  .hero-sub {
    font-size: 1.05rem;
  }

  .value-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .value-tagline {
    font-size: 1.25rem;
  }

  .cta-content h2 {
    font-size: 2rem;
  }

  .waitlist-form {
    flex-direction: column;
  }

  .waitlist-form button {
    width: 100%;
  }

  .map-overlay h2 {
    font-size: 1.35rem;
  }

  .map-container {
    height: 60vh;
  }
}

/* === Visibility helper for scroll reveals === */
.reveal.animate-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.animate-in.visible {
  opacity: 1;
  transform: translateY(0);
}
