/* ============================================
   FARMSOURCE DESIGN SYSTEM — "The Homestead"
   Extracted from vision-final.html
   Warm editorial + craft signature elements
   ============================================ */

/* =========================================
   CUSTOM PROPERTIES
   ========================================= */
:root {
    /* Surfaces — Full Cream Mode */
    --surface-primary: #EDE8DE;
    --surface-linen: #E8E2D8;
    --surface-sage: #E4E8DF;
    --surface-card: #F5F0E8;
    --surface-dark: #2D2A26;

    /* Greens */
    --green-800: #2D4528;
    --green-700: #3B5534;
    --green-600: #4F7A45;
    --green-500: #5E8E53;
    --green-100: rgba(79, 122, 69, 0.08);

    /* Honey */
    --honey-500: #D4A843;
    --honey-400: #E0BC5E;
    --honey-100: rgba(212, 168, 67, 0.12);

    /* Blues — muted slate/lake */
    --blue-700: #3A5F7C;
    --blue-600: #4A7A9B;
    --blue-500: #5B8FAF;
    --blue-100: rgba(74, 122, 155, 0.08);

    /* Terra */
    --terra-500: #C4652A;
    --terra-100: rgba(196, 101, 42, 0.08);

    /* Brown */
    --brown-500: #8B5E3C;

    /* Text */
    --text-primary: #2D2A26;
    --text-secondary: #5C4A32;
    --text-muted: #9B9184;
    --text-inverse: #FDFBF7;

    /* Borders — Warm Brown Hierarchy */
    --border-warm: #8B7D6B;
    --border-faint: #B5AD9E;
    --border-defined: #6B5E50;

    /* Shadows */
    --shadow-xs: 0 1px 2px rgba(45, 42, 38, 0.04);
    --shadow-sm: 0 1px 4px rgba(45, 42, 38, 0.06), 0 1px 2px rgba(45, 42, 38, 0.04);
    --shadow-md: 0 4px 16px rgba(45, 42, 38, 0.07), 0 2px 4px rgba(45, 42, 38, 0.03);
    --shadow-lg: 0 12px 40px rgba(45, 42, 38, 0.1), 0 4px 8px rgba(45, 42, 38, 0.04);
    --shadow-glow-green: 0 0 0 3px rgba(74, 103, 65, 0.12);
    --shadow-glow-blue: 0 0 0 3px rgba(74, 122, 155, 0.12);

    /* Radii */
    --radius-sm: 4px;
    --radius-md: 7px;
    --radius-lg: 10px;
    --radius-xl: 14px;
    --radius-pill: 100px;

    /* Easings — snappy, not floaty */
    --ease-out: cubic-bezier(0.2, 0, 0, 1);
    --ease-spring: cubic-bezier(0.18, 0.89, 0.32, 1.15);

    /* Error / Success — additional tokens for app usage */
    --error-500: #C4652A;
    --error-100: rgba(196, 101, 42, 0.08);
    --success-500: #4A6741;
    --success-100: rgba(74, 103, 65, 0.08);
}

/* =========================================
   LINEN TEXTURE — subtle paper grain via CSS
   No image dependency
   ========================================= */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 10000;
    opacity: 0.025;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    background-size: 200px 200px;
}

/* =========================================
   TOPOGRAPHIC CONTOUR — the signature motif
   ========================================= */
.topo-bg {
    position: relative;
}
.topo-bg::before {
    content: '';
    position: fixed;
    inset: 0;
    opacity: 0.04;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 800 400'%3E%3Cg fill='none' stroke='%234A6741' stroke-width='1'%3E%3Cpath d='M-50 280c80-40 160 20 240-10s160-60 240-20 160 50 240 10 160-40 200-20'/%3E%3Cpath d='M-50 240c80-30 160 30 240 0s160-50 240-10 160 40 240 0 160-30 200-10'/%3E%3Cpath d='M-50 200c80-20 160 25 240 5s160-40 240-5 160 30 240-5 160-25 200-5'/%3E%3Cpath d='M-50 160c80-15 160 20 240 10s160-30 240 0 160 20 240-10 160-20 200 0'/%3E%3Cpath d='M-50 120c80-10 160 15 240 5s160-20 240 5 160 15 240-5 160-15 200 5'/%3E%3Cpath d='M-50 80c80-8 160 12 240 0s160-15 240 8 160 10 240 0 160-12 200 0'/%3E%3C/g%3E%3C/svg%3E");
    background-size: 800px 400px;
    background-repeat: repeat;
    pointer-events: none;
}

/* =========================================
   SALE PILL — frosted glass + moving shimmer
   One reusable treatment for every sale badge/button (dashboard, storefront,
   marketplace), mirroring the marketplace glass but kept in the existing warm
   rose→terra sale palette. Efficiency: the shimmer sweeps via `transform`
   (compositor-only, no repaint) and pauses each cycle; honors reduced-motion.
   ========================================= */
.fs-sale-pill {
    position: relative;
    overflow: hidden;
    isolation: isolate;
    color: #fff;
    background: linear-gradient(135deg, rgba(212, 168, 67, 0.92), rgba(196, 101, 42, 0.92));
    border: 1px solid rgba(255, 255, 255, 0.45);
    box-shadow: 0 2px 8px rgba(168, 85, 31, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.35);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
}
.fs-sale-pill::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 45%;
    background: linear-gradient(100deg, transparent 0%, rgba(255, 255, 255, 0.55) 50%, transparent 100%);
    transform: translateX(-160%) skewX(-18deg);
    animation: fsSalePillShimmer 3.4s ease-in-out infinite;
    pointer-events: none;
    will-change: transform;
}
@keyframes fsSalePillShimmer {
    0% { transform: translateX(-160%) skewX(-18deg); }
    55%, 100% { transform: translateX(420%) skewX(-18deg); }
}
@media (prefers-reduced-motion: reduce) {
    .fs-sale-pill::after { animation: none; display: none; }
}

/* =========================================
   HEADER — warm, distinctive, compact
   ========================================= */
.header {
    height: 60px;
    background: var(--surface-card);
    border-bottom: 1px solid var(--border-warm);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    position: sticky;
    top: 0;
    z-index: 100;
}
.header-left {
    display: flex;
    align-items: center;
    gap: 28px;
}
.header-logo {
    display: flex;
    align-items: center;
    gap: 9px;
    text-decoration: none;
}
.header-logo-icon {
    width: 30px;
    height: 30px;
    background: var(--green-600);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.1s var(--ease-spring);
}
.header-logo:hover .header-logo-icon { transform: rotate(-4deg) scale(1.04); }
.header-logo-text {
    font-weight: 700;
    font-size: 17px;
    color: var(--text-primary);
    letter-spacing: -0.02em;
}
.header-nav {
    display: flex;
    gap: 4px;
}
.header-nav a {
    text-decoration: none;
    color: var(--text-muted);
    font-size: 13px;
    font-weight: 500;
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    transition: all 0.15s;
}
.header-nav a:hover { color: var(--text-primary); background: var(--surface-linen); }
.header-nav a.active {
    color: var(--green-600);
    background: var(--green-100);
}
.header-right {
    display: flex;
    align-items: center;
    gap: 8px;
}
.header-search {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--surface-linen);
    border: 1px solid transparent;
    border-radius: var(--radius-pill);
    padding: 7px 14px 7px 12px;
    width: 220px;
    color: var(--text-muted);
    font-size: 13px;
    cursor: text;
    transition: all 0.2s;
}
.header-search:hover { border-color: var(--border-warm); }
.header-search svg { width: 14px; height: 14px; flex-shrink: 0; opacity: 0.5; }
.header-search kbd {
    margin-left: auto;
    font-family: inherit;
    font-size: 10px;
    font-weight: 500;
    color: var(--text-muted);
    background: var(--surface-card);
    border: 1px solid var(--border-warm);
    border-radius: 4px;
    padding: 1px 5px;
    line-height: 1.4;
}
.icon-btn {
    position: relative;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
    border: none;
    transition: all 0.15s;
}
.icon-btn:hover { background: var(--surface-linen); color: var(--text-primary); }
.icon-btn svg { width: 18px; height: 18px; }
.cart-badge {
    position: absolute;
    top: 2px;
    right: 1px;
    min-width: 16px;
    height: 16px;
    border-radius: 8px;
    background: var(--green-600);
    color: white;
    font-size: 10px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    border: 2px solid var(--surface-card);
}
.avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(160deg, var(--green-600), var(--green-500));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 12px;
    cursor: pointer;
    transition: transform 0.08s var(--ease-spring);
}
.avatar:hover { transform: scale(1.06); }

/* =========================================
   LAYOUT
   ========================================= */
.page-section {
    max-width: 1100px;
    margin: 0 auto;
    padding: 56px 24px;
}
.section-label {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 20px;
}
/* Hand-drawn wavy divider */
.wavy-divider {
    width: 100%;
    height: 12px;
    opacity: 0.12;
    background-repeat: repeat-x;
    background-size: 120px 12px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 12'%3E%3Cpath d='M0 6c10-4 20 4 30 0s20-4 30 0 20 4 30 0 20-4 30 0' fill='none' stroke='%234A6741' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
}
.alt-bg {
    background: var(--surface-sage);
}
.linen-bg {
    background: var(--surface-linen);
}

/* =========================================
   HERO — asymmetric, confident, signature
   ========================================= */
.hero {
    padding: 80px 24px 72px;
    position: relative;
    overflow: hidden;
}
.hero-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
}
.hero-text h1 {
    font-size: 44px;
    font-weight: 800;
    line-height: 1.08;
    letter-spacing: -0.03em;
    color: var(--text-primary);
    margin-bottom: 16px;
}
.hero-text h1 .green { color: var(--green-600); }
.hero-text p {
    font-size: 17px;
    line-height: 1.65;
    color: var(--text-secondary);
    max-width: 420px;
    margin-bottom: 28px;
}
.hero-text .hero-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}
.hero-visual {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 12px;
    height: 340px;
}
.hero-card {
    background: var(--surface-card);
    border: 2px solid var(--border-warm);
    border-radius: var(--radius-lg);
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.12s var(--ease-out), border-color 0.12s;
    position: relative;
    overflow: hidden;
}
.hero-card:hover {
    box-shadow: var(--shadow-md);
}
.hero-card:nth-child(1) {
    grid-row: 1 / 3;
    background: var(--surface-linen);
}
.hero-card:nth-child(2) { transform-origin: bottom left; }
.hero-card:nth-child(3) { transform-origin: top left; }
.hero-card-label {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 4px;
}
.hero-card-value {
    font-size: 20px;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text-primary);
}
.hero-card-sub {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 2px;
}
.hero-card .craft-icon-sm {
    position: absolute;
    top: 14px;
    right: 14px;
    opacity: 0.15;
}
.hero-stamp {
    position: absolute;
    bottom: 16px;
    right: 16px;
}

/* =========================================
   STAMP BADGES — organic, not pill-shaped
   Wax-seal / rubber-stamp aesthetic
   ========================================= */
.stamp {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: 2px solid var(--green-600);
    color: var(--green-600);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-align: center;
    line-height: 1.1;
    transform: rotate(-12deg);
    opacity: 0.7;
    position: relative;
}
.stamp::before {
    content: '';
    position: absolute;
    inset: 3px;
    border: 1px dashed var(--green-600);
    border-radius: 50%;
    opacity: 0.4;
}
.stamp-honey {
    border-color: var(--honey-500);
    color: var(--honey-500);
}
.stamp-honey::before { border-color: var(--honey-500); }
.stamp-terra {
    border-color: var(--terra-500);
    color: var(--terra-500);
}
.stamp-terra::before { border-color: var(--terra-500); }

/* =========================================
   BUTTONS
   ========================================= */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    font-family: inherit;
    font-weight: 600;
    font-size: 14px;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    border: none;
    cursor: pointer;
    transition: background 0.08s var(--ease-out), box-shadow 0.08s var(--ease-out), transform 0.06s var(--ease-out);
    text-decoration: none;
    position: relative;
}
.btn-primary {
    background: var(--green-600);
    color: var(--text-inverse);
    box-shadow: 0 1px 2px rgba(74, 103, 65, 0.2), inset 0 1px 0 rgba(255,255,255,0.1);
}
.btn-primary:hover {
    background: var(--green-700);
    box-shadow: 0 2px 8px rgba(74, 103, 65, 0.25), inset 0 1px 0 rgba(255,255,255,0.1);
}
.btn-primary:active { transform: scale(0.97); }
.btn-secondary {
    background: var(--surface-card);
    color: var(--green-600);
    border: 2px solid var(--border-warm);
    box-shadow: var(--shadow-xs);
}
.btn-secondary:hover {
    border-color: var(--green-600);
    background: var(--green-100);
}
.btn-secondary:active { transform: scale(0.97); }
.btn-warm {
    background: var(--honey-500);
    color: var(--text-primary);
    box-shadow: 0 1px 2px rgba(212, 168, 67, 0.25), inset 0 1px 0 rgba(255,255,255,0.2);
}
.btn-warm:hover {
    background: var(--honey-400);
    box-shadow: 0 2px 8px rgba(212, 168, 67, 0.25), inset 0 1px 0 rgba(255,255,255,0.2);
}
.btn-warm:active { transform: scale(0.97); }
.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    padding: 10px 14px;
}
.btn-ghost:hover { color: var(--green-600); }
.btn-ghost .arrow { transition: transform 0.08s; }
.btn-ghost:hover .arrow { transform: translateX(3px); }
.btn-sm { font-size: 13px; padding: 7px 14px; }
.btn-lg { font-size: 15px; padding: 13px 26px; }
.btn-icon {
    width: 36px;
    height: 36px;
    padding: 0;
    border-radius: 50%;
    background: var(--surface-linen);
    color: var(--text-secondary);
    border: 1px solid var(--border-warm);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}
.btn-icon:hover {
    background: var(--green-100);
    border-color: var(--green-600);
    color: var(--green-600);
}
.btn-icon-filled {
    width: 32px;
    height: 32px;
    padding: 0;
    border-radius: 50%;
    background: var(--green-600);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.08s var(--ease-out), transform 0.06s var(--ease-out), box-shadow 0.08s;
    box-shadow: 0 2px 6px rgba(74, 103, 65, 0.25);
}
.btn-icon-filled:hover {
    background: var(--green-700);
    box-shadow: 0 3px 10px rgba(74, 103, 65, 0.3);
}
.btn-icon-filled:active {
    transform: scale(0.92);
}
.button-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }

/* Danger button — terra themed */
.btn-danger {
    background: var(--terra-500);
    color: var(--text-inverse);
    box-shadow: 0 1px 2px rgba(196, 101, 42, 0.2), inset 0 1px 0 rgba(255,255,255,0.1);
}
.btn-danger:hover {
    background: #A8551F;
    box-shadow: 0 2px 8px rgba(196, 101, 42, 0.25), inset 0 1px 0 rgba(255,255,255,0.1);
}
.btn-danger:active { transform: scale(0.97); }

/* Disabled state for all buttons */
.btn:disabled,
.btn-primary:disabled,
.btn-secondary:disabled,
.btn-warm:disabled,
.btn-danger:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* =========================================
   CARDS
   ========================================= */
.card {
    background: var(--surface-card);
    border: 2px solid var(--border-defined);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.12s var(--ease-out), border-color 0.12s;
    overflow: hidden;
}
.card:hover {
    box-shadow: var(--shadow-md);
    border-color: var(--border-warm);
}

/* =========================================
   FARM CARDS — with craft icon overlay
   ========================================= */
.farm-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}
.farm-card-img {
    height: 160px;
    background: linear-gradient(170deg, var(--surface-linen), var(--surface-sage));
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 12px;
    position: relative;
}
.farm-card-img .craft-badge {
    position: absolute;
    bottom: -16px;
    left: 16px;
    width: 32px;
    height: 32px;
    background: var(--surface-card);
    border: 1px solid var(--border-warm);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-sm);
    z-index: 2;
}
.farm-card-body { padding: 22px 16px 16px; }
.farm-name {
    font-weight: 700;
    font-size: 15px;
    letter-spacing: -0.01em;
}
.farm-location {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 1px;
}
.farm-tags { display: flex; gap: 6px; margin-top: 10px; flex-wrap: wrap; }
.tag {
    font-size: 11px;
    font-weight: 500;
    padding: 3px 9px;
    border-radius: var(--radius-pill);
    background: var(--green-100);
    color: var(--green-600);
}
.tag-honey { background: var(--honey-100); color: #8B6F1A; }
.tag-brown { background: rgba(139, 94, 60, 0.08); color: var(--brown-500); }
.tag-new {
    background: var(--honey-500);
    color: var(--text-primary);
    font-weight: 700;
    font-size: 9px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 2px 7px;
}
.farm-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--border-faint);
}
.farm-meta {
    font-size: 12px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 4px;
}
.farm-meta svg { width: 12px; height: 12px; }
.open-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--green-500);
    display: inline-block;
    margin-right: 2px;
}

/* =========================================
   PRODUCT RESULTS — category icon headers
   ========================================= */
.results-section { max-width: 540px; }
.cat-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    margin-top: 24px;
}
.cat-header:first-child { margin-top: 0; }
.cat-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}
.cat-label {
    font-size: 14px;
    font-weight: 700;
    letter-spacing: -0.01em;
}
.cat-count {
    font-size: 12px;
    color: var(--text-muted);
    margin-left: auto;
}
.product-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    background: var(--surface-card);
    border: 1px solid var(--border-warm);
    border-radius: var(--radius-md);
    margin-bottom: 6px;
    transition: border-color 0.1s, box-shadow 0.1s;
    cursor: pointer;
}
.product-row:hover {
    border-color: var(--green-600);
    box-shadow: var(--shadow-glow-green);
}
.product-thumb {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-sm);
    background: var(--surface-linen);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.product-info { flex: 1; min-width: 0; }
.product-name {
    font-weight: 600;
    font-size: 14px;
    letter-spacing: -0.01em;
}
.product-farm-name {
    font-size: 12px;
    color: var(--text-muted);
}
.product-right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}
.product-price {
    font-weight: 700;
    font-size: 14px;
    color: var(--green-600);
    text-align: right;
}
.product-unit {
    font-weight: 400;
    font-size: 11px;
    color: var(--text-muted);
    display: block;
}

/* =========================================
   CHECKOUT
   ========================================= */
.checkout { max-width: 400px; }
.checkout-card {
    background: var(--surface-card);
    border: 2px solid var(--border-defined);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}
.checkout-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-faint);
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.checkout-header h3 {
    font-size: 15px;
    font-weight: 700;
    letter-spacing: -0.01em;
}
.checkout-items { padding: 12px 20px; }
.checkout-line {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    font-size: 14px;
}
.checkout-line-label { color: var(--text-secondary); }
.checkout-line-value { font-weight: 600; }
.checkout-footer {
    padding: 14px 20px;
    background: var(--surface-linen);
    border-top: 1px solid var(--border-faint);
}
.checkout-total {
    display: flex;
    justify-content: space-between;
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 14px;
}

/* =========================================
   FORMS
   ========================================= */
.form-card {
    background: var(--surface-card);
    border: 2px solid var(--border-defined);
    border-radius: var(--radius-lg);
    padding: 28px;
    box-shadow: var(--shadow-sm);
    max-width: 380px;
}
.form-card-title {
    font-size: 20px;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 20px;
}
.form-group { margin-bottom: 14px; }
.form-label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 5px;
}
.form-input {
    width: 100%;
    padding: 10px 12px;
    border: 2px solid var(--border-warm);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 14px;
    color: var(--text-primary);
    background: var(--surface-primary);
    transition: border-color 0.1s, box-shadow 0.1s;
}
.form-input:focus {
    outline: none;
    border-color: var(--green-600);
    box-shadow: var(--shadow-glow-green);
}
.form-input::placeholder { color: var(--text-muted); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.form-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 16px 0;
    color: var(--text-muted);
    font-size: 12px;
}
.form-divider::before,
.form-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border-warm);
}

/* Error state for form inputs */
.form-input-error {
    border-color: var(--error-500);
    box-shadow: 0 0 0 3px var(--error-100);
}
.form-input-error:focus {
    border-color: var(--error-500);
    box-shadow: 0 0 0 3px var(--error-100);
}

/* Toggle */
.toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
}
.toggle-label { font-size: 14px; font-weight: 500; }
.toggle {
    width: 42px;
    height: 24px;
    background: var(--border-warm);
    border-radius: 12px;
    position: relative;
    cursor: pointer;
    transition: background 0.1s;
}
.toggle.active { background: var(--green-600); }
.toggle-knob {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background: var(--surface-card);
    border-radius: 50%;
    box-shadow: 0 1px 4px rgba(0,0,0,0.15);
    transition: transform 0.1s var(--ease-spring);
}
.toggle.active .toggle-knob { transform: translateX(18px); }

/* =========================================
   BADGES & STATUS
   ========================================= */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    border-radius: var(--radius-pill);
    font-size: 12px;
    font-weight: 600;
}
.badge-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
}
.badge-success { background: var(--green-100); color: var(--green-600); }
.badge-success .badge-dot { background: var(--green-500); }
.badge-pending { background: var(--honey-100); color: #8B6F1A; }
.badge-pending .badge-dot { background: var(--honey-500); }
.badge-info { background: var(--blue-100); color: var(--blue-600); }
.badge-info .badge-dot { background: var(--blue-500); }
.badge-warning { background: var(--terra-100); color: var(--terra-500); }
.badge-warning .badge-dot { background: var(--terra-500); }

/* =========================================
   COMMUNITY EVENTS — date-strip variant
   Scoped via .ds-event-card to avoid conflict
   with community-hub.css .event-card (cork-board)
   ========================================= */
.ds-event-card {
    display: flex;
    gap: 0;
    background: var(--surface-card);
    border: 2px solid var(--border-defined);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    transition: box-shadow 0.12s var(--ease-out), border-color 0.12s;
}
.ds-event-card:hover {
    box-shadow: var(--shadow-md);
}
.event-date-strip {
    width: 64px;
    background: var(--green-600);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    padding: 12px 8px;
}
.event-date-day {
    font-size: 26px;
    font-weight: 800;
    color: white;
    line-height: 1;
    letter-spacing: -0.03em;
}
.event-date-month {
    font-size: 11px;
    font-weight: 600;
    color: rgba(255,255,255,0.7);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.ds-event-card .event-body { padding: 14px 18px; flex: 1; }
.ds-event-card .event-body h4 {
    font-size: 15px;
    font-weight: 600;
    letter-spacing: -0.01em;
}
.ds-event-card .event-body p {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 2px;
}
.ds-event-card .event-body .caveat-note {
    font-family: 'Caveat', cursive;
    font-size: 17px;
    color: var(--green-600);
    margin-top: 4px;
}

/* =========================================
   FARMER QUOTE — pull-quote callout
   ========================================= */
.farmer-quote {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    padding: 24px;
    background: var(--surface-linen);
    border-radius: var(--radius-lg);
    border-left: 3px solid var(--green-600);
    max-width: 520px;
}
.farmer-quote-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--surface-sage);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 11px;
}
.farmer-quote-text {
    font-family: 'Caveat', cursive;
    font-size: 20px;
    line-height: 1.4;
    color: var(--text-primary);
}
.farmer-quote-attr {
    font-family: 'Inter', sans-serif;
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 4px;
}

/* =========================================
   TYPOGRAPHY
   ========================================= */
.type-scale h1 {
    font-size: 44px; font-weight: 800; letter-spacing: -0.03em; line-height: 1.08; margin-bottom: 6px;
}
.type-scale h2 {
    font-size: 28px; font-weight: 700; letter-spacing: -0.02em; line-height: 1.15; margin-bottom: 6px;
}
.type-scale h3 {
    font-size: 20px; font-weight: 600; letter-spacing: -0.01em; line-height: 1.3; margin-bottom: 6px;
}
.type-scale p {
    font-size: 15px; line-height: 1.65; color: var(--text-secondary); max-width: 480px; margin-bottom: 8px;
}
.type-scale .caveat-demo {
    font-family: 'Caveat', cursive;
    font-size: 24px;
    color: var(--green-600);
}
.type-scale .micro {
    font-size: 10px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted);
}

/* Craft underline */
.craft-underline {
    position: relative;
    display: inline;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 8'%3E%3Cpath d='M1 5.5C30 2 50 7 80 3.5S130 1 160 4.5S190 7 199 4' fill='none' stroke='%234A6741' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
    background-position: bottom left;
    background-repeat: repeat-x;
    background-size: 100px 6px;
    padding-bottom: 4px;
}

/* =========================================
   UTILITY
   ========================================= */
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: start; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.gap-10 { display: flex; flex-direction: column; gap: 10px; }
.badge-row { display: flex; gap: 8px; flex-wrap: wrap; }

/* =========================================
   RESPONSIVE
   ========================================= */
@media (max-width: 900px) {
    .hero-inner { grid-template-columns: 1fr; }
    .hero-visual { display: none; }
    .farm-grid { grid-template-columns: 1fr; }
    .two-col { grid-template-columns: 1fr; }
}

/* =========================================
   MOBILE — design rules (consumer app)
   Single source of mobile conventions. Tokens only — no new
   colors, fonts, or arbitrary values. Component rules that
   implement these live in mobile-responsive.css.

   Rules (≤768px):
   - Breakpoint boundary: 768px. Mobile = ≤768px, desktop = ≥769px
     (desktop is frozen — never restyle ≥1024px unless fixing a bug).
   - Minimum touch target: 44px. Minimum input font-size: 16px
     (smaller fonts trigger iOS zoom-on-focus). Both enforced in
     mobile-responsive.css base.
   - Single-column layout below 768px.
   - Primary destinations live in a fixed bottom tab bar in the
     thumb zone (.fs-bottom-nav) — see mobile-responsive.css.
   - Modals become full-screen / bottom sheets below 768px.
   - Respect safe-area insets on notched devices.
   ========================================= */
:root {
    /* Height of the fixed mobile bottom nav (excludes the safe-area pad). */
    --bottom-nav-height: 60px;
    /* Notch-safe bottom inset; 0 on devices without one. */
    --safe-bottom: env(safe-area-inset-bottom, 0px);
}
