/* Microgree – Microgreens Farm
   Modern green-themed design system */

:root {
  --bg-light: #F6FBF7;
  --bg-dark: #0B1F16;
  --primary: #22C55E;
  --deep-green: #166534;
  --mint: #A7F3D0;
  --text: #0F172A;
  --text-muted: #64748B;
  --border: rgba(15, 23, 42, 0.10);
  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 32px;
  --space-5: 48px;
  --space-6: 64px;
  --space-7: 96px;
  --max-width: 1200px;
  --header-height: 72px;
  --radius: 12px;
  --radius-lg: 16px;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
  --shadow-hover: 0 12px 40px rgba(0, 0, 0, 0.1);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg-light);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: 'Sora', 'Inter', sans-serif;
  font-weight: 600;
  line-height: 1.3;
  color: var(--text);
}

h1 { font-size: clamp(2rem, 5vw, 3rem); }
h2 { font-size: clamp(1.5rem, 4vw, 2rem); }
h3 { font-size: 1.25rem; }

a { color: var(--deep-green); text-decoration: none; }
a:hover { text-decoration: underline; }

img {
  max-width: 100%;
  height: auto;
  display: block;
}

img[loading="lazy"] { content-visibility: auto; }

/* Skip link */
.skip-link {
  position: absolute;
  top: -100%;
  left: var(--space-2);
  padding: var(--space-2);
  background: var(--primary);
  color: var(--text);
  font-weight: 600;
  border-radius: var(--radius);
  z-index: 1000;
  transition: top 0.2s;
}
.skip-link:focus { top: var(--space-2); outline: 2px solid var(--primary); outline-offset: 2px; }

/* Header */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-height);
  background: rgba(246, 251, 247, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-4);
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo {
  font-family: 'Sora', 'Inter', sans-serif;
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--text);
  text-decoration: none;
}
.logo:hover { text-decoration: none; }
.nav-desktop { display: none; }
@media (min-width: 768px) {
  .nav-desktop {
    display: flex;
    align-items: center;
    gap: var(--space-5);
  }
}
.nav-desktop a {
  color: var(--text);
  font-weight: 500;
  padding: var(--space-1) var(--space-2);
}
.nav-desktop a:hover { color: var(--deep-green); text-decoration: none; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  min-width: 44px;
  padding: var(--space-2) var(--space-4);
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius);
  cursor: pointer;
  border: 2px solid transparent;
  transition: transform 0.2s, box-shadow 0.2s;
}
.btn:hover { text-decoration: none; }
.btn:focus { outline: 2px solid var(--primary); outline-offset: 2px; }
.btn-primary {
  background: var(--primary);
  color: var(--text);
}
.btn-primary:hover { box-shadow: 0 0 24px rgba(34, 197, 94, 0.4); }
.btn-secondary {
  background: transparent;
  color: var(--deep-green);
  border-color: var(--deep-green);
}
.btn-secondary:hover { background: rgba(22, 101, 52, 0.08); }

/* Hamburger */
.hamburger {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: var(--space-2);
  background: none;
  border: none;
  cursor: pointer;
  min-height: 44px;
  min-width: 44px;
  justify-content: center;
  align-items: center;
}
@media (min-width: 768px) { .hamburger { display: none; } }
.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  border-radius: 1px;
}

/* Mobile drawer */
.drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(11, 31, 22, 0.4);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
  z-index: 150;
}
.drawer-overlay.open { opacity: 1; visibility: visible; }
.drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 300px;
  max-width: 85vw;
  height: 100vh;
  background: var(--bg-light);
  padding: var(--space-6) var(--space-4);
  transform: translateX(100%);
  transition: transform 0.3s;
  z-index: 151;
  box-shadow: -4px 0 24px rgba(0,0,0,0.1);
}
.drawer.open { transform: translateX(0); }
.drawer-nav { display: flex; flex-direction: column; gap: var(--space-2); }
.drawer-nav a { padding: var(--space-2); font-weight: 500; }
.drawer-nav .btn { margin-top: var(--space-2); }

/* Container */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-4);
}
.section { padding: var(--space-6) 0; }
.section-heading { text-align: center; margin-bottom: var(--space-5); }
.section-heading h2 { margin: 0 0 var(--space-2); }
.section-heading p { margin: 0; color: var(--text-muted); max-width: 560px; margin-left: auto; margin-right: auto; }

/* Hero */
.hero {
  padding: var(--space-6) 0 calc(var(--space-6) * 1.5);
  background: linear-gradient(180deg, var(--bg-light) 0%, rgba(167, 243, 208, 0.15) 100%);
}
.hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-4);
  display: grid;
  gap: var(--space-6);
  align-items: center;
}
@media (min-width: 992px) {
  .hero-inner { grid-template-columns: 1fr 1fr; gap: var(--space-6); }
}
.hero h1 { margin: 0 0 var(--space-3); }
.hero .subhead {
  font-size: 1.25rem;
  color: var(--text-muted);
  margin: 0 0 var(--space-5);
  max-width: 480px;
}
.hero-ctas { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-bottom: var(--space-5); }
.hero-visual {
  position: relative;
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.1) 0%, rgba(167, 243, 208, 0.2) 100%);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  aspect-ratio: 4/3;
  overflow: hidden;
}
.hero-visual img { width: 100%; height: 100%; object-fit: cover; }

/* Trust strip */
.trust-strip {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-4);
  background: white;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.trust-item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: 0.9375rem;
  color: var(--text-muted);
}
.trust-item::before {
  content: '';
  width: 24px;
  height: 24px;
  background: var(--mint);
  border-radius: 50%;
}

/* Product grid */
.product-grid {
  display: grid;
  gap: var(--space-4);
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}
.product-card {
  background: white;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform 0.2s, box-shadow 0.2s;
}
.product-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.product-card-image {
  aspect-ratio: 4/3;
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.1), rgba(167, 243, 208, 0.2));
  object-fit: cover;
}
.product-card-body { padding: var(--space-4); }
.product-card h3 { margin: 0 0 var(--space-1); font-size: 1.125rem; }
.product-card .meta { font-size: 0.875rem; color: var(--text-muted); margin-bottom: var(--space-2); }
.product-card .price { font-weight: 700; font-size: 1.125rem; margin-bottom: var(--space-2); }

/* Steps */
.steps {
  display: grid;
  gap: var(--space-4);
  grid-template-columns: 1fr;
}
@media (min-width: 768px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step-card {
  padding: var(--space-4);
  background: white;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}
.step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--primary);
  color: var(--text);
  font-weight: 700;
  font-size: 1.125rem;
  border-radius: 50%;
  margin-bottom: var(--space-2);
}
.step-card h3 { margin: 0 0 var(--space-1); font-size: 1.125rem; }
.step-card p { margin: 0; font-size: 0.9375rem; color: var(--text-muted); }

/* Testimonials */
.testimonial-grid {
  display: grid;
  gap: var(--space-4);
  grid-template-columns: 1fr;
}
@media (min-width: 640px) { .testimonial-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 992px) { .testimonial-grid { grid-template-columns: repeat(3, 1fr); } }
.testimonial-card {
  padding: var(--space-4);
  background: white;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
}
.testimonial-card blockquote { margin: 0 0 var(--space-2); font-style: italic; }
.testimonial-card cite { font-style: normal; font-size: 0.875rem; color: var(--text-muted); }

/* FAQ accordion */
.faq-list { max-width: 720px; margin: 0 auto; }
.faq-item { border-bottom: 1px solid var(--border); }
.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-4);
  min-height: 44px;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  text-align: left;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text);
}
.faq-question:hover, .faq-question:focus { color: var(--deep-green); outline: none; }
.faq-question::after { content: '+'; font-size: 1.5rem; }
.faq-item.open .faq-question::after { content: '−'; }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height 0.3s; }
.faq-answer-inner { padding: 0 var(--space-4) var(--space-4); color: var(--text-muted); }

/* CTA block */
.cta-block {
  padding: var(--space-6) var(--space-4);
  background: var(--bg-dark);
  color: white;
  text-align: center;
}
.cta-block h2 { color: white; margin: 0 0 var(--space-3); }
.cta-block p { color: var(--mint); opacity: 0.9; margin: 0 0 var(--space-5); max-width: 480px; margin-left: auto; margin-right: auto; }
.cta-block .btn-primary { background: var(--primary); color: var(--text); }
.cta-block .btn-primary:hover { background: var(--mint); }

/* Footer */
.footer {
  background: var(--bg-dark);
  color: var(--mint);
  padding: var(--space-6) var(--space-4);
}
.footer-inner { max-width: var(--max-width); margin: 0 auto; text-align: center; }
.footer-mission { font-size: 0.9375rem; margin-bottom: var(--space-5); opacity: 0.9; }
.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-4);
  margin-bottom: var(--space-4);
}
.footer-links a { color: var(--mint); }
.footer-links a:hover { text-decoration: underline; }

/* Forms */
.form-group { margin-bottom: var(--space-4); }
.form-group label { display: block; font-weight: 500; margin-bottom: var(--space-1); }
.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: var(--space-2);
  font-family: inherit;
  font-size: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: 2px solid var(--primary);
  outline-offset: 0;
}
.form-row { display: grid; gap: var(--space-4); }
@media (min-width: 640px) { .form-row { grid-template-columns: 1fr 1fr; } }

/* Category filters */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-bottom: var(--space-5);
}
.filter-btn {
  padding: var(--space-2) var(--space-3);
  font-family: inherit;
  font-size: 0.9375rem;
  font-weight: 500;
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  min-height: 44px;
}
.filter-btn:hover, .filter-btn.active {
  border-color: var(--primary);
  background: rgba(34, 197, 94, 0.1);
  color: var(--deep-green);
}

/* Cart drawer (basic) */
.cart-toggle {
  position: relative;
  padding: var(--space-2);
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.25rem;
  min-height: 44px;
  min-width: 44px;
}
.cart-count {
  position: absolute;
  top: 4px;
  right: 4px;
  background: var(--primary);
  color: var(--text);
  font-size: 0.75rem;
  font-weight: 700;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.cart-count:empty { display: none; }

/* Breadcrumb */
.breadcrumb {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: var(--space-4);
}
.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--deep-green); }

/* Blog */
.blog-grid {
  display: grid;
  gap: var(--space-4);
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}
.blog-card {
  background: white;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: transform 0.2s, box-shadow 0.2s;
}
.blog-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.blog-card-image { aspect-ratio: 16/10; object-fit: cover; background: var(--mint); }
.blog-card-body { padding: var(--space-4); }
.blog-card .category { font-size: 0.75rem; font-weight: 600; color: var(--primary); text-transform: uppercase; margin-bottom: var(--space-1); }
.blog-card h3 { margin: 0 0 var(--space-1); font-size: 1.125rem; }
.blog-card .excerpt { font-size: 0.9375rem; color: var(--text-muted); }

/* Article */
.article-body { max-width: 720px; margin: 0 auto; }
.article-body h2 { margin-top: var(--space-5); }
.article-body h3 { margin-top: var(--space-4); }
.article-body ul, .article-body ol { padding-left: var(--space-4); }
.article-body li { margin-bottom: var(--space-1); }

/* Service area */
.service-area {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  justify-content: center;
  margin-top: var(--space-4);
}
.service-area span {
  padding: var(--space-1) var(--space-2);
  background: rgba(34, 197, 94, 0.15);
  border-radius: 6px;
  font-size: 0.875rem;
}

/* Tables */
table { width: 100%; border-collapse: collapse; }
th, td { padding: var(--space-2); text-align: left; border-bottom: 1px solid var(--border); }
th { font-weight: 600; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  border: 0;
}
