/* Nimble Creek Farm — shared styles for the static multi-page site */
:root {
  --paper: #f4f1e6;
  --cream: #e9e6d3;
  --green: #34521f;
  --green-dark: #26331a;
  --terra: #a8562b;
  --ink: #2e2a1c;
  --body: #3f3a2a;
  --muted: #6b6552;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: 'Karla', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.5;
}
img { max-width: 100%; }
a { color: var(--green); text-decoration: none; }
a:hover { color: var(--terra); }
h1, h2, h3 { font-family: 'Bitter', serif; font-weight: 600; margin: 0; }
strong { font-weight: 700; }

@keyframes ncfFade { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.fade { animation: ncfFade .5s ease both; }

.wrap { max-width: 1140px; margin: 0 auto; padding: 0 32px; }
.wrap.narrow { max-width: 900px; }
.wrap.mid { max-width: 1040px; }

.eyebrow {
  text-transform: uppercase; letter-spacing: 2.5px; font-size: 13px;
  font-weight: 700; margin: 0 0 12px;
}
.eyebrow.terra { color: var(--terra); }
.eyebrow.on-dark { color: #c7c99d; font-weight: 600; letter-spacing: 3px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-block; cursor: pointer; font-weight: 700; font-size: 15px;
  padding: 13px 22px; border-radius: 2px; border: 1.5px solid transparent;
  line-height: 1.2;
}
.btn-cream { color: var(--green); background: var(--paper); }
.btn-cream:hover { background: #fff; color: var(--green); }
.btn-green { color: #fff; background: var(--green); }
.btn-green:hover { background: var(--terra); color: #fff; }
.btn-outline { color: #fff; border-color: rgba(255,255,255,.7); }
.btn-outline:hover { background: rgba(255,255,255,.14); color: #fff; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(244,241,230,.94);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  border-bottom: 1px solid #dcd6c2;
}
.site-header .bar {
  position: relative; display: flex; align-items: center;
  justify-content: space-between; gap: 24px; flex-wrap: wrap;
  padding: 14px 32px; min-height: 56px; max-width: 1140px; margin: 0 auto;
}
.brand { display: flex; align-items: flex-start; cursor: pointer; }
.brand-logo {
  height: 104px; width: auto; display: block; margin: -6px 0 -46px;
  position: relative; z-index: 60;
  filter: drop-shadow(0 6px 16px rgba(30,40,18,.28));
}
.nav { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.nav a {
  font-size: 15px; font-weight: 600; padding: 6px 12px; border-radius: 2px;
  color: var(--body);
}
.nav a:hover { color: var(--terra); }
.nav a.active { color: var(--terra); background: var(--cream); }
.nav .phone {
  margin-left: 10px; font-weight: 700; font-size: 14px; letter-spacing: .3px;
  color: var(--paper); background: var(--green); padding: 9px 16px; border-radius: 2px;
}
.nav .phone:hover { background: var(--terra); color: #fff; }

/* ---------- hero ---------- */
.hero { position: relative; display: flex; align-items: flex-end; }
.hero--home {
  min-height: 560px;
  background-image: var(--hero-img);
  background-size: 130%; background-position: 16% 44%;
}
.hero--sub {
  min-height: 380px;
  background-image: linear-gradient(180deg, rgba(30,40,18,.2), rgba(30,40,18,.7)), var(--hero-img);
  background-size: cover; background-position: var(--hero-pos, center);
}
.hero-inner { max-width: 1140px; margin: 0 auto; padding: 0 32px 48px; width: 100%; }
.hero-inner .eyebrow { color: #d9dbb4; font-weight: 600; letter-spacing: 3px; }
.hero-inner h1 { font-size: 52px; color: #fff; }
.hero-panel {
  max-width: 480px;
  background: rgba(26,33,18,.5);
  -webkit-backdrop-filter: blur(7px); backdrop-filter: blur(7px);
  border: 1px solid rgba(255,255,255,.14); border-radius: 10px;
  padding: 24px 28px; box-shadow: 0 20px 55px rgba(18,24,10,.38);
}
.hero-panel .eyebrow { color: #e2e3c2; font-weight: 600; }
.hero-panel h1 { font-size: 46px; line-height: 1.05; color: #fff; margin: 0 0 14px; max-width: 13ch; text-wrap: balance; }
.hero-panel p { font-size: 18px; line-height: 1.55; color: #f4f2e2; margin: 0 0 24px; }
.hero-panel .actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- home: welcome + stats ---------- */
.welcome { padding: 90px 32px 40px; display: grid; grid-template-columns: 1.2fr 1fr; gap: 56px; align-items: center; }
.welcome h2 { font-size: 38px; line-height: 1.15; color: var(--green); margin: 0 0 20px; text-wrap: balance; }
.welcome p { font-size: 19px; line-height: 1.75; color: var(--body); margin: 0 0 16px; }
.welcome p:last-child { margin-bottom: 0; }
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.stat { padding: 24px 20px; border-radius: 3px; }
.stat .num { font-family: 'Bitter', serif; font-weight: 600; line-height: 1; }
.stat .lbl { font-size: 15px; margin-top: 6px; }
.stat.green { background: var(--green); color: var(--paper); }
.stat.green .num { font-size: 40px; } .stat.green .lbl { color: #c7c99d; margin-top: 4px; }
.stat.terra { background: var(--terra); color: #f9f1e9; }
.stat.terra .num { font-size: 40px; } .stat.terra .lbl { color: #f1d9c8; margin-top: 4px; }
.stat.cream { background: var(--cream); }
.stat.cream .num { font-size: 33px; color: var(--green); } .stat.cream .lbl { color: #5c563f; }

/* ---------- home: feature cards ---------- */
.features { padding: 50px 32px 90px; }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.card {
  display: block; background: #fff; border: 1px solid #e3ddca; border-radius: 4px;
  overflow: hidden; color: inherit;
}
.card:hover { border-color: var(--terra); }
.card .thumb { height: 210px; background-size: cover; background-position: center; }
.card .body { padding: 24px 24px 26px; }
.card h3 { font-size: 24px; color: var(--green); margin: 0 0 8px; }
.card p { font-size: 16px; line-height: 1.6; color: #544e3a; margin: 0 0 14px; }
.card .cta { font-weight: 700; font-size: 14px; color: var(--terra); text-transform: uppercase; letter-spacing: 1px; }

/* ---------- green cta band ---------- */
.band { background: var(--green); }
.band-inner { padding: 64px 32px; display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.band h2 { font-size: 34px; color: #fff; margin: 0 0 8px; }
.band p { font-size: 18px; color: #c7c99d; margin: 0; }
.band .actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- generic section intros / prose ---------- */
.prose { padding: 72px 32px 40px; }
.prose p { font-size: 21px; line-height: 1.75; color: var(--body); margin: 0 0 20px; }
.prose p:last-child { margin-bottom: 0; }
.section { padding: 20px 32px; }
.section h2.head { font-size: 30px; color: var(--green); margin: 0 0 24px; }

/* ---------- boarding: facility, checklist, chips, price ---------- */
.facility { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px 40px; }
.facility .item { display: flex; gap: 14px; align-items: flex-start; padding: 14px 0; border-bottom: 1px solid #e3ddca; }
.facility .dot { flex: none; width: 9px; height: 9px; margin-top: 8px; background: var(--terra); border-radius: 50%; }
.facility span.txt { font-size: 18px; line-height: 1.5; color: var(--body); }

.two-col { padding: 56px 32px; display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.rule { width: 52px; height: 3px; background: var(--terra); margin: 0 0 22px; }
.col-head { font-size: 28px; color: var(--green); margin: 0 0 6px; }
.check { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 13px; }
.check .mark { flex: none; color: var(--green); font-weight: 700; font-size: 18px; line-height: 1.5; }
.check span.txt { font-size: 17px; line-height: 1.5; color: var(--body); }
.note { font-size: 16px; line-height: 1.6; color: var(--muted); margin: 22px 0 0; font-style: italic; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip { font-size: 15px; color: #4a4531; background: var(--cream); padding: 9px 15px; border-radius: 2px; }
.price-card { margin-top: 32px; background: var(--green); color: #fff; border-radius: 4px; padding: 28px; }
.price-card .kicker { text-transform: uppercase; letter-spacing: 2px; font-size: 13px; font-weight: 700; color: #c7c99d; margin-bottom: 8px; }
.price-card .amount { font-family: 'Bitter', serif; font-size: 26px; font-weight: 600; margin-bottom: 14px; }
.price-card .amount .big { font-size: 46px; } .price-card .amount .per { font-size: 20px; color: #c7c99d; font-weight: 400; }
.price-card p { font-size: 16px; line-height: 1.6; color: #d5d7b0; margin: 14px 0 0; }

/* ---------- lessons: ready-to-ride card ---------- */
.ready { background: var(--cream); border-radius: 4px; padding: 28px; }
.ready h3 { font-size: 22px; color: var(--green); margin: 0 0 12px; }
.ready p { font-size: 16px; line-height: 1.65; color: #4a4531; margin: 0 0 12px; }
.ready p:last-child { margin-bottom: 0; }

/* ---------- horses ---------- */
.horses { padding: 72px 32px 90px; display: flex; flex-direction: column; gap: 48px; }
.horse { display: grid; gap: 36px; align-items: center; background: #fff; border: 1px solid #e3ddca; border-radius: 5px; overflow: hidden; }
.horse.left { grid-template-columns: 1fr 1.3fr; }
.horse.right { grid-template-columns: 1.3fr 1fr; }
.horse .photo { min-height: 340px; background-size: cover; background-position: center; }
.horse.right .photo { order: 2; }
.horse .info { padding: 36px 40px; }
.horse h2 { font-size: 36px; color: var(--green); margin: 0 0 14px; }
.horse .meta { display: flex; gap: 22px; flex-wrap: wrap; margin-bottom: 20px; }
.horse .meta .k { text-transform: uppercase; letter-spacing: 1px; font-size: 12px; font-weight: 700; color: var(--terra); }
.horse .meta .v { font-family: 'Bitter', serif; font-size: 19px; color: var(--green); }
.horse .desc { font-size: 17px; line-height: 1.7; color: var(--body); margin: 0 0 16px; }
.horse .avail { font-size: 16px; font-weight: 700; color: var(--terra); margin: 0 0 18px; }
.horse-foot { text-align: center; font-size: 17px; color: var(--muted); margin: 0; }

/* ---------- galleries (uniform grid, reliable lazy-loading) ---------- */
.gallery-section { padding: 20px 32px 90px; }
.gallery { display: grid; gap: 14px; }
.gallery.g3 { grid-template-columns: repeat(3, 1fr); }
.gallery.masonry { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.gallery .tile {
  display: block; padding: 0; border: 0; margin: 0; cursor: zoom-in;
  aspect-ratio: 3 / 2; overflow: hidden; border-radius: 3px; background: var(--cream);
}
.gallery .tile img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---------- directions ---------- */
.routes { padding: 72px 32px 96px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.route { background: #fff; border: 1px solid #e3ddca; border-radius: 5px; padding: 28px 26px; display: flex; flex-direction: column; }
.route h2 { font-size: 22px; color: var(--green); margin: 0 0 4px; }
.route .rule { width: 44px; margin: 0 0 18px; }
.route ol { margin: 0 0 20px; padding-left: 20px; flex: 1; }
.route li { font-size: 16px; line-height: 1.6; color: var(--body); margin-bottom: 10px; }
.route .maplink { font-weight: 700; font-size: 14px; color: var(--terra); text-transform: uppercase; letter-spacing: 1px; }

/* page header band (horses / directions) */
.pageband { background: var(--green); }
.pageband.dir h1 { color: #fff; font-size: 48px; margin: 0 0 10px; }
.pageband .inner { max-width: 1140px; margin: 0 auto; padding: 72px 32px; }
.pageband h1 { font-size: 52px; color: #fff; margin: 0; }
.pageband p { font-size: 19px; color: #d5d7b0; margin: 0; }
.gallery-intro { padding: 64px 32px 24px; }
.gallery-intro h1 { font-size: 48px; color: var(--green); margin: 0 0 10px; }
.gallery-intro p { font-size: 19px; color: #544e3a; margin: 0; max-width: 60ch; }

/* ---------- footer ---------- */
.site-footer { background: var(--green-dark); color: #c7c99d; }
.site-footer .cols { max-width: 1140px; margin: 0 auto; padding: 56px 32px 40px; display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; }
.site-footer .name { font-family: 'Bitter', serif; font-weight: 600; font-size: 22px; color: #fff; margin-bottom: 12px; }
.site-footer p { font-size: 16px; line-height: 1.7; margin: 0; }
.site-footer .h { text-transform: uppercase; letter-spacing: 2px; font-size: 12px; font-weight: 700; color: #8a9068; margin-bottom: 14px; }
.site-footer a { display: block; font-size: 16px; color: #c7c99d; margin-bottom: 9px; }
.site-footer a:hover { color: #fff; }
.site-footer .blurb { font-size: 15px; line-height: 1.6; margin-top: 7px; color: #9aa077; }
.site-footer .legal { border-top: 1px solid #3a4a29; }
.site-footer .legal .inner { max-width: 1140px; margin: 0 auto; padding: 20px 32px; font-size: 14px; color: #7c8560; }

/* ---------- lightbox ---------- */
.lb { position: fixed; inset: 0; z-index: 200; display: none; align-items: center; justify-content: center; background: rgba(12,14,8,.94); }
.lb.open { display: flex; }
.lb img { max-width: 92vw; max-height: 86vh; object-fit: contain; border-radius: 3px; box-shadow: 0 10px 60px rgba(0,0,0,.6); cursor: pointer; user-select: none; }
.lb button { position: absolute; background: rgba(255,255,255,.1); color: #fff; border: 0; cursor: pointer; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.lb button:hover { background: rgba(255,255,255,.22); }
.lb .lb-prev, .lb .lb-next { top: 50%; transform: translateY(-50%); width: 54px; height: 54px; font-size: 30px; line-height: 1; }
.lb .lb-prev { left: 20px; } .lb .lb-next { right: 20px; }
.lb .lb-close { top: 18px; right: 18px; width: 44px; height: 44px; font-size: 26px; }
.lb .lb-count { position: absolute; bottom: 20px; left: 0; right: 0; text-align: center; color: #e6e4d3; font-size: 14px; letter-spacing: .5px; }

/* ---------- responsive ---------- */
@media (max-width: 960px) {
  .brand-logo { height: 46px; margin: 0; filter: none; }
  .hero--home { background-size: cover; background-position: center 40%; }
}
@media (max-width: 820px) {
  .welcome, .two-col { grid-template-columns: 1fr; gap: 32px; }
  .feature-grid { grid-template-columns: 1fr; }
  .facility { grid-template-columns: 1fr; }
  .routes { grid-template-columns: 1fr; }
  .gallery.g3 { grid-template-columns: repeat(2, 1fr); }
  .horse, .horse.left, .horse.right { grid-template-columns: 1fr; }
  .horse.right .photo { order: 0; }
  .site-footer .cols { grid-template-columns: 1fr; gap: 28px; }
  .hero-inner h1 { font-size: 40px; }
  .welcome h2 { font-size: 32px; }
}
@media (max-width: 520px) {
  .wrap, .site-header .bar, .hero-inner { padding-left: 20px; padding-right: 20px; }
  .hero-panel h1 { font-size: 38px; }
  .gallery.g3 { grid-template-columns: 1fr 1fr; }
  .lb .lb-prev { left: 8px; } .lb .lb-next { right: 8px; }
}
