/* LisaFarm – Dolly Parton Light, Hybrid Palette
   Friendly, warm, welcoming, soft shadows & rounded corners.
   Keeps existing class names: .nav, .card, .grid, .hero-*, .chat-*, .prose, etc.
*/

/* ------------------ Tokens ------------------ */
:root{
  --ink:#141414;                /* soft black for text */
  --bg:#ffffff;                 /* page background */
  --line:#e8ecf0;               /* light stroke */
  --muted:#6b7280;              /* secondary text */

  /* LisaFarm core palette (soft sage, not hunter) */
  --brand:#8FBF9C;              /* lighter sage primary */
  --brand-ink:#63856C;          /* calm sage for hovers/text */

  --rose:#E3CDFA;               /* lavender for Lisa + accents */
  --butter:#FAE8CD;             /* peach-cream, very subtle */
  --mint:#F3FBF7;               /* ultra-soft mint for panels */
  --sky:#eef6ff;                /* light sky for hover accents */

  /* Deep accents */
  --earth:#7A613B;              /* warm brown for headings */
  --plum:#5A3B7A;               /* plum for highlights / hearts */

  --card:#ffffff;               /* card surface */

  /* Soft neutral shadow */
  --shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
  --radius: 18px;
}

/* ------------------ Base ------------------ */
*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  color:var(--ink);
  background:var(--bg);
  font-family: system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,sans-serif;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
}
a{
  color:var(--brand-ink);
  text-decoration:none;
}
a:hover{text-decoration:underline}

main{
  max-width:1200px;
  margin:0 auto;
  padding:20px 18px;
}
.section-title{
  margin:8px 0 14px;
  font-weight:800;
  font-size:21px;
}

/* ------------------ Header / Nav ------------------ */
header{
  position:sticky;
  top:0;
  z-index:70;
  background:#fff;
  border-bottom:1px solid var(--line);
  backdrop-filter:saturate(180%) blur(3px);
}
.nav{
  max-width:1200px;
  margin:0 auto;
  display:flex;
  align-items:center;
  gap:16px;
  padding:12px 18px;
}
.nav img{height:60px}
.nav .spacer{flex:1}
.nav a.link{
  color:#374151;
  font-weight:600;
  padding:7px 10px;
  border-radius:10px;
  transition:background .15s,color .15s, box-shadow .15s;
}
.nav a.link:hover{
  background:#f3f4f6;
  color:var(--brand-ink);
  box-shadow: 0 2px 10px rgba(15, 23, 42, .08);
}

/* ------------------ Hero (Farmer Lisa on pure white) ------------------ */
.hero,
.hero-wrap,
.hero-banner,
.hero-container{
  background:#fff !important;
  background-image:none !important;
}
.hero-wrap{
  display:grid;
  gap:18px;
  align-items:center;
}
@media(min-width:840px){
  .hero-wrap{grid-template-columns:280px 1fr;}
}

.hero-face{
  background:#fff;
  border:1px solid var(--line);
  border-radius:20px;
  overflow:hidden;
  box-shadow: var(--shadow);
}
.hero-face img{
  display:block;
  width:100%;
  height:260px;
  object-fit:cover;
  background:#fff;
}
.greeting{
  font-family: "Caveat", cursive;
  color:var(--brand);
  font-size:30px;
}
.hero-note{
  background:linear-gradient(180deg, var(--mint), #fff);
  border:1px solid var(--line);
  border-radius:16px;
  padding:12px 14px;
  color:#374151;
}

/* ------------------ Grids ------------------ */
.grid{ display:grid; gap:16px }
@media(min-width:640px){
    .grid.cols-3{
    grid-template-columns:repeat(2, minmax(0, 1fr));
  }
@media(min-width:840px){
  .grid.cols-3{grid-template-columns:repeat(3,1fr);}
  .grid.cols-4{grid-template-columns:repeat(4,1fr);}
}

/* ------------------ Cards ------------------ */
.card{
  background:var(--card);
  border:1px solid var(--line);
  border-radius:var(--radius);
  overflow:hidden;
  display:flex;
  flex-direction:column;
  box-shadow: var(--shadow);
}
.card img{
  width:100%;
  height:auto;
  display:block;
  background:#ddd;
}

/* Listing images: consistent, people-first crop */
.card img.listing-img{
  width:100%;
  aspect-ratio:4/3;
  height:auto;
  object-fit:cover;
  object-position:50% 20%;  /* top-center bias avoids chest-centric crop */
  background:#f1f5f9;
  transition: transform .25s ease;
}
.card:hover img.listing-img{ transform:scale(1.02) }

.card .body{ padding:12px }
.meta{
  color:var(--muted);
  font-size:13px;
  margin-top:4px;
}

/* Optional escape hatch if a particular image looks cramped */
.card img.listing-img.softcontain{
  object-fit:contain;
  background:#f5f7f8;
  border:1px solid var(--line);
}

/* ------------------ Chips / Filters ------------------ */
.chips{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
}
.chip{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:8px 12px;
  border-radius:999px;
  font-weight:600;
  border:1px solid var(--line);
  background:#fff;
  color:#374151;
  transition: transform .15s ease, background .15s ease;
}
.chip:hover{
  transform: translateY(-1px);
  background:var(--sky);
}
.chip.brand{
  background:#ffffff;
  border-color:#d9efe3;
  color:var(--brand-ink);
}
.chip.rose{
  background:#ffffff;
  border-color:#dbc2f0;
  color:var(--plum);
}

/* ------------------ Buttons ------------------ */
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border:1px solid var(--line);
  background:#fff;
  padding:8px 12px;
  border-radius:10px;
  font-weight:600;
  font-size:0.9rem;
  transition: filter .15s ease, transform .05s ease-in-out, box-shadow .15s ease;
}
.btn:hover{ filter:brightness(.98) }
.btn:active{ transform: translateY(1px) }

.btn.primary{
  background:var(--brand);
  border-color:var(--brand);
  color:#fff;
  box-shadow:0 2px 14px rgba(15, 23, 42, .12);
}
.btn.primary:hover{ filter:brightness(.96) }

/* ------------------ Forms ------------------ */
.row{
  display:flex;
  gap:12px;
  flex-wrap:wrap;
}
input[type="text"],
input:not([type]),
select,
textarea{
  border:1px solid var(--line);
  border-radius:12px;
  padding:10px 14px;
  font: inherit;
}
input[type="text"]::placeholder{
  color:#9aa3af;
}

/* ------------------ Chat ------------------ */
.chat-wrap{
  border:1px solid var(--line);
  border-radius:16px;
  overflow:hidden;
  background:#fff;
  box-shadow: var(--shadow);
}
.chat-head{
  display:flex;
  align-items:center;
  gap:10px;
  padding:12px 14px;
  background:#f9fafb;              /* neutral, not big mint block */
  border-bottom:1px solid var(--line);
}
.chat-avatar{
  width:36px;
  height:36px;
  border-radius:50%;
  overflow:hidden;
  background:#e2e8f0;
}
.chat-body{
  max-height:420px;
  overflow:auto;
  padding:14px;
}
.chat-msg{
  margin:0 0 12px;
  line-height:1.6;
}

/* Visitor messages */
.chat-me{
  background:#ffffff;
  border:1px solid rgba(0,0,0,0.04);
  color:var(--ink);
  padding:8px 10px;
  border-radius:14px;
  display:inline-block;
}
/* Farmer Lisa messages – lavender, cozy */
.chat-lisa{
  background: var(--rose);
  border: 1px solid rgba(0,0,0,0.03);
  color: var(--earth);
  padding:8px 10px;
  border-radius:14px;
  display:inline-block;
  box-shadow: var(--shadow);
}

.chat-input{
  display:flex;
  gap:10px;
  padding:12px;
  border-top:1px solid var(--line);
}
.chat-input input,
.chat-input textarea{
  flex:1;
  border:1px solid var(--line);
  border-radius:12px;
  padding:10px 14px;
  resize:vertical;
}

/* ------------------ Prose / Blog ------------------ */
.prose{
  font-family: ui-serif, Georgia, Cambria, "Times New Roman", serif;
  line-height:1.65;
}
.prose p{
  margin:0 0 12px;
  font-size:17px;
}
.prose h2,
.prose h3{
  margin:18px 0 8px;
  font-weight:700;
}

.handwritten{
  font-family:"Caveat", cursive;
  letter-spacing:.2px;
}
.blog-h1{
  font-size:28px;
  font-weight:700;
}
.blog-title{
  font-size:20px;
  font-weight:700;
}

/* Blog visuals */
.blog-heading{
  font-family:"Caveat", cursive;
  color:var(--brand);
  font-size:46px;
  text-align:center;
  margin:8px 0 16px;
}
.blog-title{
  font-family:"Caveat", cursive;
  font-size:22px;
  font-weight:700;
  color:var(--brand-ink);
}

/* ------------------ Blog top nav (for posts) ------------------ */
.blog-top-nav{
  padding:10px 16px;
  font-size:13px;
  background:#fffdf6;
  border-bottom:1px solid rgba(0,0,0,0.05);
  display:flex;
  gap:12px;
}
.blog-top-nav .back-link{
  color:var(--brand-ink);
  text-decoration:none;
}
.blog-top-nav .back-link:hover{
  text-decoration:underline;
}

/* ------------------ Footer ------------------ */
footer{
  border-top:1px solid var(--line);
  padding:20px 16px;
  color:var(--muted);
}

/* ------------------ Subtle page accents ------------------ */
.banner{
  background:#ffffff;
  border-radius:12px;
  padding:10px 14px;
  border:1px solid #e5e7eb;
  border-left:4px solid var(--rose);  /* gentle Lisa note */
  color:var(--earth);
}

/* ------------------ Responsive Tweaks ------------------ */
@media (max-width: 1024px){
  .card img.listing-img{ aspect-ratio:3/2; }
}

@media (max-width: 640px){
  main{ padding:16px 14px; }

  /* Header/nav: slimmer and less busy on phones */
  header{
    position:static;   /* let it scroll with content on phones */
    padding:4px 0;
  }

  .nav{
    padding:6px 10px;
    gap:8px;
    flex-wrap:wrap;
    align-items:flex-start;
  }

  .nav img{
    height:36px;
  }

  .nav-title strong{
    font-size:16px;
  }

  .nav-subtitle{
    font-size:11px;
  }

  /* Hide the big CTA row on small screens to keep header short */
  .nav-ctas{
    display:none;
  }

  .nav a.link{
    font-size:0.9rem;
    padding:4px 6px;
  }

  /* Stack hero: image on top, text below */
  .hero-wrap{
    grid-template-columns:1fr;
    gap:12px;
  }
  .hero-face{
    max-width:260px;
    margin:0 auto 8px;
  }
  .hero-face img{
    height:200px;
  }

  .chips{
    gap:6px;
  }
  .chip{
    padding:6px 10px;
    font-size:0.85rem;
  }

  /* Three cards per row for cols-3 grids on mobile */
  .grid.cols-3{
    grid-template-columns:repeat(3, minmax(0, 1fr));
  }

  .card img.listing-img{ aspect-ratio: 1 / 1.2; }

  /* Mobile polish: tighter cards, bottom breathing room */
  .card{
    margin:8px;
    padding:8px 10px 12px;
    border-radius:18px;
    box-shadow: var(--shadow);
  }

  .card .body{
    padding:8px 8px 10px;
  }

  .card-title,
  .blog-title{
    font-size:18px;
    line-height:1.3;
  }

  .meta{
    font-size:13px;
  }

  body{
    padding-bottom:72px;
  }
}

/* ===== Chat overlay (LisaFarm) ===== */
.chat-overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
}
.chat-overlay[hidden] {
  display: none;
}
.chat-overlay-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45); /* darker but see-through */
}
.chat-overlay-panel {
  position: relative;
  max-width: 480px;
  width: 100%;
  margin: 16px;
  background: #ffffff;
  border-radius: 16px;
  padding: 16px 16px 12px;
  box-shadow: 0 18px 40px rgba(0,0,0,0.30);
  z-index: 1;
}
.chat-overlay-close {
  position: absolute;
  top: 8px;
  right: 10px;
  border: none;
  background: transparent;
  font-size: 1.1rem;
  cursor: pointer;
}
.chat-overlay-title {
  margin: 0 0 4px;
}
.chat-overlay-lead {
  margin: 0 0 10px;
  font-size: 0.9rem;
  opacity: 0.8;
}

/* Prevent background scroll while overlay is open */
body.chat-overlay-open {
  overflow: hidden;
}

/* Keep this marker so we know the right CSS is live */
 /* =====================  STEP 1: Responsive polish  ===================== */
