/* ============================================================
   Farm Stands of America — Rustic Farmhouse Design System
   Single source of truth for the whole site. Link this file
   in <head> and use the component classes below.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,500;9..144,600;9..144,700&family=Nunito+Sans:wght@400;600;700;800&display=swap');

:root {
  /* paper / surfaces */
  --paper:      #f5ecdb;   /* page background */
  --paper-2:    #fbf5e9;   /* raised surfaces */
  --cream:      #fffdf8;   /* cards */
  /* primary (green) */
  --barn:       #4eb03c;
  --barn-dark:  #3a9230;
  /* greens (secondary) */
  --green:      #3f6a2a;
  --green-2:    #5c913b;
  --green-dark: #2b4a1c;
  /* wheat / gold */
  --gold:       #c89b3c;
  --gold-dark:  #a37c25;
  /* ink / text */
  --ink:        #2d2117;
  --ink-soft:   #5f5142;
  --ink-faint:  #8a7c6a;
  /* lines */
  --line:       #e3d5bd;
  --line-soft:  #efe5d2;

  --radius:     14px;
  --radius-sm:  9px;
  --radius-lg:  22px;
  --shadow:     0 10px 28px rgba(67,46,20,.12);
  --shadow-sm:  0 3px 10px rgba(67,46,20,.10);
  --shadow-lg:  0 22px 50px rgba(45,33,23,.22);

  --font-head:  'Fraunces', Georgia, 'Times New Roman', serif;
  --font-body:  'Nunito Sans', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;

  --maxw: 1140px;
}

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

body.fs {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background-color: var(--paper);
  /* subtle paper / linen texture */
  background-image:
    radial-gradient(circle at 20% -10%, rgba(92,145,59,.10), transparent 45%),
    radial-gradient(circle at 100% 0%, rgba(200,155,60,.10), transparent 40%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='80'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.035'/%3E%3C/svg%3E");
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.fs h1, .fs h2, .fs h3, .fs h4 {
  font-family: var(--font-head);
  font-weight: 600;
  line-height: 1.1;
  color: var(--ink);
  margin: 0 0 .5em;
  letter-spacing: -.01em;
}
.fs a { color: var(--green); text-decoration: none; }
.fs a:hover { color: var(--green-dark); }
.fs img { max-width: 100%; display: block; }
.fs p { margin: 0 0 1em; }

.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 22px; }
.container-narrow { max-width: 760px; }

.eyebrow {
  font-family: var(--font-body);
  text-transform: uppercase;
  letter-spacing: .18em;
  font-weight: 800;
  font-size: 13px;
  color: var(--barn);
}
.muted { color: var(--ink-soft); }
.text-center { text-align: center; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55em;
  padding: .85rem 1.6rem;
  font-family: var(--font-body);
  font-weight: 800; font-size: 1.02rem; line-height: 1;
  border: 2px solid transparent; border-radius: var(--radius-sm);
  cursor: pointer; text-decoration: none;
  transition: transform .15s ease, background .2s ease, box-shadow .2s ease, color .2s ease;
  box-shadow: var(--shadow-sm);
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.btn:active { transform: translateY(0); }
.btn-primary { background: var(--barn); color: #fff; }
.btn-primary:hover { background: var(--barn-dark); color: #fff; }
.btn-secondary { background: var(--green); color: #fff; }
.btn-secondary:hover { background: var(--green-dark); color: #fff; }
.btn-gold { background: var(--gold); color: #3a2c10; }
.btn-gold:hover { background: var(--gold-dark); color: #fff; }
.btn-outline { background: transparent; color: var(--ink); border-color: var(--ink); box-shadow: none; }
.btn-outline:hover { background: var(--ink); color: var(--cream); }
.btn-ghost { background: rgba(255,255,255,.85); color: var(--green-dark); border-color: var(--line); }
.btn-ghost:hover { background: #fff; color: var(--green-dark); }
.btn-lg { padding: 1.05rem 2.1rem; font-size: 1.12rem; }
.btn-block { display: flex; width: 100%; }

/* ---------- Site header / nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(251,245,233,.92);
  backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-header .container { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding-block: 12px; }
.brand { display: flex; align-items: center; gap: 11px; font-family: var(--font-head); font-weight: 700; font-size: 1.18rem; color: var(--ink); }
.brand img { width: 40px; height: 40px; object-fit: contain; }
.brand span { line-height: 1.05; }
.main-nav { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.main-nav a { padding: 8px 13px; border-radius: 999px; font-weight: 700; color: var(--ink-soft); }
.main-nav a:hover { background: rgba(63,106,42,.10); color: var(--green-dark); }
.main-nav a.active { color: var(--green-dark); background: rgba(63,106,42,.12); }
.nav-toggle { display: none; background: none; border: 0; font-size: 1.6rem; cursor: pointer; color: var(--ink); }
@media (max-width: 760px) {
  .nav-toggle { display: block; }
  .main-nav { display: none; width: 100%; flex-direction: column; align-items: stretch; gap: 2px; padding-top: 8px; }
  .main-nav.open { display: flex; }
  .site-header .container { flex-wrap: wrap; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  color: #fff; text-align: center;
  padding: clamp(60px, 12vw, 130px) 20px clamp(70px, 13vw, 140px);
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -2;
  background: linear-gradient(150deg, #4a7a2f 0%, #335421 55%, #2b4a1c 100%);
}
.hero .hero-media { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; }
.hero .hero-overlay { position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(43,74,28,.55), rgba(40,30,18,.66)); }
.hero h1 { color: #fff; font-size: clamp(34px, 6.4vw, 64px); font-weight: 700; text-shadow: 0 3px 18px rgba(0,0,0,.35); margin-bottom: .2em; }
.hero .lead { max-width: 640px; margin: 0 auto 1.6em; font-size: clamp(17px, 2.2vw, 22px); color: #fbf3e4; }
.hero .hero-logo { width: clamp(120px, 22vw, 190px); margin: 0 auto 18px; filter: drop-shadow(0 6px 14px rgba(0,0,0,.35)); }
.hero .btns { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; }
/* torn-paper bottom edge */
.hero .edge { position: absolute; left: 0; right: 0; bottom: -1px; z-index: 0; width: 100%; display: block; color: var(--paper); }

/* ---------- Sections ---------- */
.section { padding: clamp(46px, 8vw, 90px) 0; }
.section-head { text-align: center; max-width: 720px; margin: 0 auto clamp(28px, 5vw, 48px); }
.section-head h2 { font-size: clamp(28px, 4.4vw, 44px); }
.section-head p { font-size: 1.12rem; color: var(--ink-soft); }
.section--cream { background: var(--paper-2); border-block: 1px solid var(--line); }

/* ---------- Stand cards grid ---------- */
.stand-grid { display: grid; gap: 22px; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.stand-card {
  background: var(--cream); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow-sm);
  transition: transform .18s ease, box-shadow .18s ease; display: flex; flex-direction: column;
}
.stand-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.stand-card .thumb { aspect-ratio: 4/3; background: #e9dcc4 center/cover no-repeat; position: relative; }
.stand-card .thumb.placeholder { display: grid; place-items: center; font-size: 2.6rem; background: linear-gradient(150deg,#dfe6d0,#e3d8c2); }
.stand-card .thumb .new-flag {
  position: absolute; top: 10px; left: 10px;
  background: var(--barn); color: #fff; font-weight: 800; font-size: 11px;
  letter-spacing: .08em; text-transform: uppercase; padding: 5px 10px; border-radius: 999px;
}
.stand-card .body { padding: 15px 16px 17px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.stand-card .body h3 { font-size: 1.22rem; margin: 0; }
.stand-card .loc { color: var(--ink-soft); font-weight: 700; font-size: .92rem; }
.stand-card .cat { color: var(--green); font-weight: 700; font-size: .82rem; text-transform: uppercase; letter-spacing: .06em; }
.stand-card .go { margin-top: auto; padding-top: 10px; color: var(--barn); font-weight: 800; font-size: .92rem; }

/* ---------- Generic card / panel ---------- */
.card { background: var(--cream); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: clamp(20px, 4vw, 34px); }

/* feature list */
.feature-grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); list-style: none; padding: 0; margin: 0; }
.feature-grid li { background: var(--cream); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow-sm); }
.feature-grid li strong { display: block; font-family: var(--font-head); color: var(--green-dark); font-size: 1.22rem; margin-bottom: 6px; }
.feature-grid li .ico { font-size: 1.7rem; display: block; margin-bottom: 8px; }

/* ---------- Forms ---------- */
.field { display: block; margin-top: 16px; }
.field > label { display: block; font-weight: 800; margin-bottom: 6px; color: var(--ink); }
.fs input[type=text], .fs input[type=email], .fs input[type=password],
.fs input[type=tel], .fs input[type=url], .fs input[type=number],
.fs select, .fs textarea {
  width: 100%; padding: 12px 14px; font-family: var(--font-body); font-size: 1rem;
  color: var(--ink); background: #fff; border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.fs input:focus, .fs select:focus, .fs textarea:focus {
  outline: none; border-color: var(--green-2); box-shadow: 0 0 0 3px rgba(92,145,59,.18);
}

/* ---------- Footer ---------- */
.site-footer { background: var(--green-dark); color: #e9e2d2; text-align: center; padding: 40px 20px; margin-top: 60px; }
.site-footer a { color: #f3e7c7; text-decoration: underline; }
.site-footer .foot-brand { font-family: var(--font-head); font-size: 1.3rem; color: #fff; margin-bottom: 8px; }
.site-footer small { color: #c7bfac; }

/* ---------- Badges / pills ---------- */
.badge { display: inline-block; padding: 5px 11px; border-radius: 999px; font-weight: 800; font-size: 12px; letter-spacing: .03em; }
.badge-free { background: rgba(92,145,59,.16); color: var(--green-dark); border: 1px solid rgba(92,145,59,.4); }
.badge-new { background: var(--barn); color: #fff; }

/* ---------- Utility ---------- */
.stack > * + * { margin-top: 1rem; }
.hidden { display: none !important; }

/* ============================================================
   Mobile-first hardening — base targets phones; min-width
   queries above progressively enhance for larger screens.
   ============================================================ */
html { -webkit-text-size-adjust: 100%; }
body.fs { overflow-x: hidden; }
.fs img, .fs video { max-width: 100%; height: auto; }
/* never let long words / URLs blow out the layout on small screens */
.fs h1, .fs h2, .fs h3, .fs h4, .fs p, .fs li, .fs a,
.stand-card .body, .card { overflow-wrap: anywhere; word-break: break-word; }
/* comfortable tap targets */
.btn, .main-nav a { min-height: 44px; }
/* wrap any wide table so it scrolls instead of overflowing */
.table-wrap { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* Phones (default-up tuning) */
@media (max-width: 540px) {
  .container { padding-inline: 16px; }
  .section { padding: 40px 0; }
  /* stack hero CTAs full-width so they're easy to tap */
  .hero .btns { flex-direction: column; align-items: stretch; }
  .hero .btns .btn { width: 100%; }
  /* single-column card grids on small screens */
  .stand-grid { grid-template-columns: 1fr; }
  .feature-grid { grid-template-columns: 1fr; }
}
