/* ============================================================
   Kind Farm — styles.css

   EASY THEMING: change the colors and font below in one place
   and the whole site updates. You don't need to touch anything
   else in this file unless you want to.
   ============================================================ */
:root {
  /* --- Brand colors (fresh & bright: sky blue + green) --- */
  --color-primary:        #1a9ed9;   /* sky blue — buttons, links, accents */
  --color-primary-dark:   #147bab;   /* darker blue — hover states */
  --color-accent:         #4caf50;   /* leafy green — secondary accents */
  --color-accent-dark:    #3a8c3e;

  /* --- Neutrals (backgrounds & text) --- */
  --color-bg:        #ffffff;
  --color-bg-alt:    #f1f9fd;   /* very light blue, for alternating sections */
  --color-bg-dark:   #0e2a36;   /* deep teal, for the footer */
  --color-text:      #1f2d33;
  --color-text-soft: #5a6b72;
  --color-border:    #dce7ec;

  /* --- Type & layout --- */
  --font: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --maxw: 1080px;          /* max content width */
  --radius: 14px;          /* rounded corners */
  --shadow: 0 6px 24px rgba(14, 42, 54, 0.08);
}

/* ===================== BASE ===================== */
* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: var(--color-primary-dark); }

h1, h2, h3 { line-height: 1.2; color: var(--color-text); }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 20px;
}

/* Visually-hidden but available to screen readers */
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* Visible focus outline for keyboard users */
a:focus-visible, button:focus-visible, input:focus-visible {
  outline: 3px solid var(--color-primary);
  outline-offset: 2px;
}

/* ===================== BUTTONS ===================== */
.btn {
  display: inline-block;
  padding: 0.7em 1.4em;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color .15s ease, color .15s ease, transform .05s ease;
  font-size: 1rem;
}
.btn:active { transform: translateY(1px); }

.btn-primary { background: var(--color-primary); color: #fff; }
.btn-primary:hover { background: var(--color-primary-dark); }

.btn-outline {
  background: transparent;
  color: var(--color-primary-dark);
  border-color: var(--color-primary);
}
.btn-outline:hover { background: var(--color-primary); color: #fff; }

.btn-lg { font-size: 1.1rem; padding: 0.85em 1.8em; }

/* ===================== HEADER / NAV ===================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--color-border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 68px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.25rem;
  text-decoration: none;
  color: var(--color-text);
}
.brand-mark { font-size: 1.5rem; }
.brand-logo { height: 48px; width: auto; }

.site-nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}
.site-nav a {
  text-decoration: none;
  color: var(--color-text);
  font-weight: 600;
}
.site-nav a:not(.btn):hover { color: var(--color-primary-dark); }
.nav-donate { color: #fff; }

/* Hamburger (hidden on desktop) */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: 0;
  padding: 8px;
  cursor: pointer;
}
.nav-toggle span {
  width: 26px; height: 3px;
  background: var(--color-text);
  border-radius: 2px;
  transition: transform .2s ease, opacity .2s ease;
}

/* ===================== HERO ===================== */
.hero {
  background:
    linear-gradient(160deg, var(--color-bg-alt) 0%, #e3f3ea 100%);
  padding: clamp(3rem, 8vw, 6rem) 0;
}
.hero-inner { max-width: 720px; }
.eyebrow {
  text-transform: uppercase;
  letter-spacing: .08em;
  font-weight: 700;
  font-size: .85rem;
  color: var(--color-accent-dark);
  margin: 0 0 .5rem;
}
.hero h1 {
  font-size: clamp(2.2rem, 6vw, 3.6rem);
  margin: 0 0 1rem;
}
.lead {
  font-size: 1.2rem;
  color: var(--color-text-soft);
  margin: 0 0 1.8rem;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; }

/* ===================== STATS ===================== */
.stats {
  background: var(--color-primary);
  color: #fff;
  padding: 2.2rem 0;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  text-align: center;
}
.stat { display: flex; flex-direction: column; }
.stat-num { font-size: 2rem; font-weight: 800; }
.stat-label { font-size: .95rem; opacity: .9; }

/* ===================== SECTIONS ===================== */
.section { padding: clamp(3rem, 7vw, 5rem) 0; }
.section-alt { background: var(--color-bg-alt); }
.section-title {
  font-size: clamp(1.7rem, 4vw, 2.4rem);
  margin: 0 0 .5rem;
}
.section-sub {
  color: var(--color-text-soft);
  font-size: 1.1rem;
  margin: 0 0 2rem;
}

/* About */
.about-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 2.5rem;
  align-items: start;
}
.values {
  list-style: none;
  padding: 1.5rem;
  margin: 0;
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.values li { padding: .6rem 0; border-bottom: 1px solid var(--color-border); }
.values li:last-child { border-bottom: 0; }

/* Program cards */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}
.card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.6rem;
  box-shadow: var(--shadow);
  transition: transform .15s ease;
}
.card:hover { transform: translateY(-4px); }
.card-icon { font-size: 2.4rem; margin-bottom: .4rem; }
.card h3 { margin: 0 0 .4rem; }
.card p { margin: 0; color: var(--color-text-soft); }

/* ===================== EVENTS ===================== */
.events-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}
.event {
  background: #fff;
  border: 1px solid var(--color-border);
  border-left: 5px solid var(--color-accent);
  border-radius: var(--radius);
  padding: 1.4rem;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
}
.event-date {
  font-weight: 700;
  color: var(--color-accent-dark);
  font-size: .9rem;
  text-transform: uppercase;
  letter-spacing: .03em;
}
.event h3 { margin: .3rem 0; }
.event-loc { color: var(--color-text-soft); font-size: .95rem; margin: 0 0 .8rem; }
.event p { margin: 0 0 1.2rem; color: var(--color-text-soft); }
.event .btn { margin-top: auto; align-self: flex-start; }
.events-empty { color: var(--color-text-soft); font-style: italic; }

/* ===================== DONATE ===================== */
.section-donate {
  background: linear-gradient(160deg, #e3f3ea 0%, var(--color-bg-alt) 100%);
  text-align: center;
}
.donate-inner { max-width: 760px; margin: 0 auto; }
.donate-tiers {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin: 2rem 0;
}
.tier {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.3rem 1rem;
  display: flex;
  flex-direction: column;
  gap: .4rem;
  box-shadow: var(--shadow);
}
.tier-amt { font-size: 1.6rem; font-weight: 800; color: var(--color-primary-dark); }
.donate-note { font-size: .9rem; color: var(--color-text-soft); margin-top: 1.2rem; }

/* ===================== CONTACT ===================== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
}
.socials { display: flex; gap: 1.2rem; margin-top: 1rem; }
.socials a { font-weight: 600; text-decoration: none; }
.socials a:hover { text-decoration: underline; }
.newsletter { display: flex; gap: .6rem; flex-wrap: wrap; margin-top: .5rem; }
.newsletter input {
  flex: 1 1 200px;
  padding: .7em 1em;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  font-size: 1rem;
}
.newsletter-msg { color: var(--color-accent-dark); font-weight: 600; min-height: 1.4em; }

/* ===================== FOOTER ===================== */
.site-footer {
  background: var(--color-bg-dark);
  color: #cfe3ec;
  padding: 2.2rem 0;
}
.footer-inner { text-align: center; }
.footer-inner p { margin: .2rem 0; }
.footer-note { font-size: .9rem; opacity: .8; }

/* ===================== RESPONSIVE ===================== */
@media (max-width: 860px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .about-grid,
  .contact-grid { grid-template-columns: 1fr; }
  .donate-tiers { grid-template-columns: 1fr; }

  /* Collapse nav into a toggle menu */
  .nav-toggle { display: flex; }
  .site-nav {
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: #fff;
    border-bottom: 1px solid var(--color-border);
    padding: .5rem 20px 1rem;
    box-shadow: var(--shadow);
    display: none;
  }
  .site-nav.open { display: flex; }
  .site-nav a { padding: .9rem 0; border-bottom: 1px solid var(--color-border); }
  .site-nav a:last-child { border-bottom: 0; }
  .nav-donate { text-align: center; margin-top: .6rem; }

  /* Animate hamburger into an X when open */
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
