/* ==========================================================================
   IsokoFresh Kigali — Craft-First Anti-AI Slop Design System
   Terroir: Rwandan Volcanic Earth, Deep Virunga Flora, Unbleached Linen
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Newsreader:ital,opsz,wght@0,6..72,400..600;1,6..72,400&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
  /* Color Palette */
  --bg-page: #FBFBFA;
  --bg-surface: #FFFFFF;
  --bg-subtle: #F3F5EE;
  --bg-card-highlight: #F7FAF4;

  --primary-deep: #133926;
  --primary-hover: #0C2619;
  --primary-light: #EBF3ED;

  --accent-clay: #C85A32;
  --accent-clay-light: #FBF0EB;

  --whatsapp-green: #25D366;
  --whatsapp-hover: #1EBE5D;
  --whatsapp-dark: #128C7E;

  --text-main: #141A16;
  --text-muted: #55635A;
  --text-light: #7E8D84;

  --border-subtle: #E2E6DC;
  --border-strong: #CAD1C0;

  /* Elevation Shadows (Layered subtle depth, zero cheesy fuzzy blur) */
  --shadow-sm: 0 1px 2px rgba(19, 57, 38, 0.04);
  --shadow-md: 0 4px 12px rgba(19, 57, 38, 0.06), 0 1px 3px rgba(19, 57, 38, 0.03);
  --shadow-lg: 0 12px 32px rgba(19, 57, 38, 0.08), 0 2px 6px rgba(19, 57, 38, 0.04);
  --shadow-float: 0 16px 40px -8px rgba(19, 57, 38, 0.16);

  /* Radii (Concentric system) */
  --radius-outer: 18px;
  --radius-inner: 10px;
  --radius-pill: 9999px;

  /* Typography */
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-serif: 'Newsreader', Georgia, serif;
}

/* Base Reset & Mobile Native Hardening */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-family: var(--font-sans);
  background-color: var(--bg-page);
  color: var(--text-main);
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  min-height: 100dvh;
  padding-bottom: 90px; /* Clearance for sticky mobile bar */
  overflow-x: hidden;
  font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
}

/* Typography Defaults */
h1, h2, h3 {
  color: var(--text-main);
  letter-spacing: -0.02em;
  font-weight: 700;
}

.serif-headline {
  font-family: var(--font-serif);
  font-weight: 500;
  letter-spacing: -0.015em;
  line-height: 1.15;
}

p {
  color: var(--text-muted);
}

.tabular {
  font-variant-numeric: tabular-nums;
}

/* Layout Utilities */
.container {
  max-width: 1080px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 20px;
  padding-right: 20px;
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background-color: rgba(251, 251, 250, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-subtle);
  padding: 14px 0;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--primary-deep);
}

.brand-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: block;
}

.brand-name {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--primary-deep);
}

.brand-name span {
  color: var(--accent-clay);
  font-weight: 700;
}

.header-meta {
  display: flex;
  align-items: center;
  gap: 16px;
}

.badge-terroir {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background-color: var(--primary-light);
  color: var(--primary-deep);
  font-size: 0.8125rem;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(19, 57, 38, 0.08);
}

.badge-terroir .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: var(--whatsapp-green);
}

.header-phone {
  display: none;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-main);
  text-decoration: none;
}

@media (min-width: 640px) {
  .header-phone {
    display: inline-flex;
    align-items: center;
    gap: 6px;
  }
}

/* ==========================================================================
   Hero Section (The Clear Promise - Slide 4)
   ========================================================================== */
.hero-section {
  padding: 48px 0 36px 0;
  text-align: center;
}

.cutoff-banner {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: var(--accent-clay-light);
  color: var(--accent-clay);
  border: 1px solid rgba(200, 90, 50, 0.2);
  padding: 7px 16px;
  border-radius: var(--radius-pill);
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 24px;
}

.cutoff-clock {
  font-family: var(--font-sans);
  font-weight: 800;
  letter-spacing: 0.02em;
  color: var(--accent-clay);
}

.hero-title {
  font-size: 2.25rem;
  max-width: 760px;
  margin: 0 auto 16px auto;
  color: var(--primary-deep);
}

@media (min-width: 768px) {
  .hero-title {
    font-size: 3.25rem;
  }
}

.hero-subtitle {
  font-size: 1.125rem;
  max-width: 620px;
  margin: 0 auto 28px auto;
  color: var(--text-muted);
  line-height: 1.6;
}

.hero-quick-stats {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-bottom: 36px;
}

.stat-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background-color: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-main);
  box-shadow: var(--shadow-sm);
}

/* ==========================================================================
   The Box Catalog (Boxes with Prices - Slide 4)
   ========================================================================== */
.catalog-section {
  padding: 12px 0 48px 0;
}

.section-label {
  text-align: center;
  font-size: 0.8125rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-light);
  margin-bottom: 8px;
}

.section-title {
  text-align: center;
  font-size: 1.75rem;
  margin-bottom: 32px;
  color: var(--primary-deep);
}

.boxes-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-bottom: 24px;
}

@media (min-width: 768px) {
  .boxes-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
  }
}

.box-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-outer);
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: var(--shadow-md);
  position: relative;
  transition: transform 200ms cubic-bezier(0.2, 0, 0, 1), box-shadow 200ms ease;
}

@media (hover: hover) and (pointer: fine) {
  .box-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
    border-color: var(--border-strong);
  }
}

.box-card.featured {
  border-color: rgba(19, 57, 38, 0.4);
  background-color: var(--bg-card-highlight);
  padding-top: 32px;
}

.featured-tag {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background-color: var(--primary-deep);
  color: #FFFFFF;
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(19, 57, 38, 0.22);
  z-index: 2;
}

.box-header {
  margin-bottom: 16px;
}

.sku-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-light);
  background: var(--bg-subtle);
  padding: 3px 8px;
  border-radius: 6px;
  margin-bottom: 8px;
}

.box-name {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary-deep);
  margin-bottom: 4px;
}

.box-target {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.box-price-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 16px 0 20px 0;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-subtle);
}

.box-price {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.02em;
}

.box-savings {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--accent-clay);
}

.box-contents-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-light);
  margin-bottom: 10px;
}

.box-items-list {
  list-style: none;
  margin-bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.box-items-list li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.875rem;
  color: var(--text-main);
}

.box-items-list li svg {
  flex-shrink: 0;
  color: var(--whatsapp-dark);
}

/* Add-on Egg Card */
.addon-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-outer);
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  box-shadow: var(--shadow-sm);
  margin-top: 12px;
}

@media (min-width: 640px) {
  .addon-card {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.addon-info {
  display: flex;
  align-items: center;
  gap: 16px;
}

.addon-badge-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background-color: var(--bg-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-clay);
  flex-shrink: 0;
}

.addon-title {
  font-size: 1.0625rem;
  font-weight: 700;
  color: var(--primary-deep);
}

.addon-desc {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.addon-action-group {
  display: flex;
  align-items: center;
  gap: 16px;
}

.addon-price {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-main);
}

/* ==========================================================================
   Buttons & Interactive States (Emil Kowalski Tactile Principles)
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  font-weight: 700;
  padding: 12px 20px;
  border-radius: var(--radius-inner);
  border: none;
  cursor: pointer;
  text-decoration: none;
  touch-action: manipulation;
  user-select: none;
  white-space: nowrap;
  transition: transform 160ms cubic-bezier(0.2, 0, 0, 1), background-color 140ms ease-out, box-shadow 140ms ease-out;
}

.btn:active {
  transform: scale(0.96);
}

.btn-whatsapp {
  background-color: var(--whatsapp-green);
  color: #FFFFFF;
  box-shadow: 0 2px 8px rgba(37, 211, 102, 0.28);
}

@media (hover: hover) and (pointer: fine) {
  .btn-whatsapp:hover {
    background-color: var(--whatsapp-hover);
    box-shadow: 0 4px 14px rgba(37, 211, 102, 0.4);
  }
}

.btn-primary {
  background-color: var(--primary-deep);
  color: #FFFFFF;
}

@media (hover: hover) and (pointer: fine) {
  .btn-primary:hover {
    background-color: var(--primary-hover);
  }
}

.btn-secondary {
  background-color: var(--bg-subtle);
  color: var(--primary-deep);
  border: 1px solid var(--border-subtle);
}

@media (hover: hover) and (pointer: fine) {
  .btn-secondary:hover {
    background-color: #E6EADE;
  }
}

.btn-sm {
  font-size: 0.8125rem;
  padding: 8px 14px;
}

/* ==========================================================================
   Interactive Order Builder & Zone Selector (Slide 4 & 5)
   ========================================================================== */
.builder-section {
  padding: 36px 0;
}

.builder-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-outer);
  padding: 28px;
  box-shadow: var(--shadow-md);
}

.builder-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
}

@media (min-width: 840px) {
  .builder-grid {
    grid-template-columns: 1.4fr 1fr;
    gap: 36px;
  }
}

.builder-step-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--primary-deep);
  margin-bottom: 12px;
}

.step-num {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background-color: var(--primary-deep);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
}

.box-selector-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 20px;
}

.radio-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 12px;
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-inner);
  background-color: var(--bg-surface);
  cursor: pointer;
  transition: border-color 150ms ease, background-color 150ms ease;
  user-select: none;
}

.radio-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.radio-card.selected {
  border-color: var(--primary-deep);
  background-color: var(--primary-light);
}

.radio-card-name {
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--text-main);
}

.radio-card-price {
  font-size: 0.9375rem;
  font-weight: 800;
  color: var(--primary-deep);
  margin-top: 4px;
}

.checkbox-addon-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-inner);
  margin-bottom: 20px;
  cursor: pointer;
}

.checkbox-addon-row:hover {
  background-color: var(--bg-subtle);
}

.checkbox-addon-row label {
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-main);
}

.zone-selector-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 20px;
}

.zone-radio-card {
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-inner);
  padding: 12px;
  cursor: pointer;
  background-color: var(--bg-surface);
  transition: border-color 150ms ease, background-color 150ms ease;
}

.zone-radio-card.selected {
  border-color: var(--primary-deep);
  background-color: var(--primary-light);
}

.zone-name {
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--text-main);
}

.zone-places {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin: 2px 0 6px 0;
}

.zone-fee {
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--accent-clay);
}

.address-input-group {
  margin-bottom: 16px;
}

.address-input-group label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.text-input {
  width: 100%;
  padding: 10px 14px;
  font-family: var(--font-sans);
  font-size: 1rem; /* >=16px prevents iOS auto-zoom */
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-inner);
  background-color: var(--bg-surface);
  color: var(--text-main);
  outline: none;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.text-input:focus {
  border-color: var(--primary-deep);
  box-shadow: 0 0 0 3px rgba(19, 57, 38, 0.1);
}

/* Summary Panel */
.builder-summary-panel {
  background-color: var(--bg-subtle);
  border-radius: var(--radius-inner);
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.summary-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--primary-deep);
  margin-bottom: 16px;
}

.summary-lines {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}

.summary-line {
  display: flex;
  justify-content: space-between;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.summary-line span:last-child {
  font-weight: 600;
  color: var(--text-main);
}

.summary-divider {
  height: 1px;
  background-color: var(--border-strong);
  margin: 8px 0;
}

.summary-line.total {
  font-size: 1.125rem;
  color: var(--primary-deep);
  font-weight: 800;
}

.summary-line.total span:last-child {
  font-size: 1.375rem;
  color: var(--primary-deep);
}

.momo-note {
  font-size: 0.75rem;
  color: var(--text-light);
  line-height: 1.4;
  margin-top: 12px;
  text-align: center;
}

/* ==========================================================================
   Trust & Operating Rules (Slide 4)
   ========================================================================== */
.trust-section {
  padding: 36px 0;
}

.trust-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

@media (min-width: 640px) {
  .trust-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 960px) {
  .trust-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.trust-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-inner);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}

.trust-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background-color: var(--primary-light);
  color: var(--primary-deep);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
}

.trust-card-title {
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--primary-deep);
  margin-bottom: 4px;
}

.trust-card-desc {
  font-size: 0.8125rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ==========================================================================
   Farmer Cooperative Story (Slide 4)
   ========================================================================== */
.story-section {
  padding: 40px 0;
}

.story-card {
  background-color: var(--primary-deep);
  color: #FFFFFF;
  border-radius: var(--radius-outer);
  padding: 36px 28px;
  box-shadow: var(--shadow-lg);
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 768px) {
  .story-card {
    grid-template-columns: 1.4fr 1fr;
    padding: 48px;
    align-items: center;
  }
}

.story-badge {
  display: inline-block;
  background-color: rgba(255, 255, 255, 0.12);
  color: var(--whatsapp-green);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  margin-bottom: 14px;
}

.story-title {
  font-size: 1.75rem;
  color: #FFFFFF;
  margin-bottom: 14px;
  line-height: 1.25;
}

.story-desc {
  font-size: 0.9375rem;
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.6;
  margin-bottom: 20px;
}

.story-stat-box {
  background-color: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-inner);
  padding: 20px;
  text-align: center;
}

.story-stat-number {
  font-size: 2.25rem;
  font-weight: 800;
  color: var(--whatsapp-green);
  margin-bottom: 4px;
}

.story-stat-label {
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.75);
}

/* ==========================================================================
   Sticky Bottom Mobile Bar (Slide 5)
   ========================================================================== */
.sticky-mobile-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background-color: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--border-subtle);
  padding: 10px 16px;
  padding-bottom: calc(10px + env(safe-area-inset-bottom, 0px));
  box-shadow: 0 -4px 16px rgba(19, 57, 38, 0.08);
}

.sticky-bar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  max-width: 600px;
  margin: 0 auto;
}

.sticky-price-info {
  display: flex;
  flex-direction: column;
}

.sticky-label {
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-light);
}

.sticky-val {
  font-size: 1.0625rem;
  font-weight: 800;
  color: var(--primary-deep);
}

.sticky-btn {
  flex-grow: 1;
  max-width: 260px;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  margin-top: 48px;
  padding: 32px 0;
  border-top: 1px solid var(--border-subtle);
  text-align: center;
  font-size: 0.8125rem;
  color: var(--text-light);
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-bottom: 12px;
}

.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-weight: 600;
}

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