/* =====================================================================
   Blackwater Pastures — Demo Site
   Built to the Blackwater Brand Guide (camcgoy.com).
   ===================================================================== */

/* ---------- Tokens --------------------------------------------------- */
:root {
  /* Color */
  --forest:        #5D786C;
  --forest-dark:   #3F5549;
  --sage:          #8EAAA5;
  --bronze:        #B76B28;
  --bronze-dark:   #8F5118;
  --near-black:    #1A1A1A;
  --off-white:     #F5F7F8;
  --surface-2:     #F0F3F2;
  --white:         #FFFFFF;
  --alert-red:     #CD452E;
  --straw:         #FFD983;
  --success:       #3E8A6D;

  /* Spacing (base-4) */
  --space-1:  0.25rem;
  --space-2:  0.5rem;
  --space-3:  0.75rem;
  --space-4:  1rem;
  --space-5:  1.25rem;
  --space-6:  1.5rem;
  --space-8:  2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;

  /* Radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;

  /* Shadow */
  --shadow-sm: 0 1px 2px rgba(26, 26, 26, 0.06), 0 1px 3px rgba(26, 26, 26, 0.04);
  --shadow-md: 0 4px 12px rgba(26, 26, 26, 0.10), 0 2px 6px rgba(26, 26, 26, 0.05);

  /* Layout */
  --content-wide: 1200px;
  --container-pad-inline: clamp(var(--space-5), 5vw, var(--space-12));
  --section-pad-block: clamp(var(--space-12), 7vw, var(--space-24));

  /* Type */
  --font-display: "Montserrat", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body:    "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
}

/* ---------- Reset / base -------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.6;
  color: var(--near-black);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--forest); text-decoration: underline; text-underline-offset: 2px; }
a:hover { color: var(--forest-dark); }
p { margin: 0 0 var(--space-4); }
ul { margin: 0 0 var(--space-4); padding-left: var(--space-6); }
li { margin-bottom: var(--space-2); }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  margin: 0 0 var(--space-4);
  letter-spacing: 0;
  line-height: 1.2;
  color: var(--near-black);
}
h1 {
  font-weight: 300;
  font-size: clamp(34px, 4.5vw, 52px);
  line-height: 1.1;
  letter-spacing: 0.02em;
}
h2 { font-size: clamp(26px, 3vw, 32px); }
h3 { font-size: clamp(20px, 2vw, 24px); line-height: 1.25; }
h4 { font-size: 18px; line-height: 1.3; }

/* ---------- Focus ring (Straw) -------------------------------------- */
:focus-visible {
  outline: 3px solid var(--straw);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* ---------- Layout primitives --------------------------------------- */
.container {
  max-width: var(--content-wide);
  margin-inline: auto;
  padding-inline: var(--container-pad-inline);
}
.section { padding-block: var(--section-pad-block); }
.section--surface { background: var(--surface-2); }
.section--forest {
  background: var(--forest);
  color: var(--white);
}
.section--forest h1,
.section--forest h2,
.section--forest h3,
.section--forest h4 { color: var(--white); }
.section-eyebrow {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--forest);
  margin: 0 0 var(--space-3);
}
.section-eyebrow--on-dark { color: var(--straw); }

/* ---------- Promo / restock bar ------------------------------------- */
.promo-bar {
  background: var(--near-black);
  color: var(--white);
  font-size: 14px;
  text-align: center;
  padding: var(--space-3) var(--space-4);
}
.promo-bar a {
  color: var(--straw);
  text-decoration: underline;
  font-weight: 600;
}

/* ---------- Header / Nav -------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--white);
  border-bottom: 1px solid var(--surface-2);
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-6);
  min-height: 72px;
  padding-block: var(--space-3);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  text-decoration: none;
  color: inherit;
}
.brand__mark {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background: var(--forest);
  color: var(--white);
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 0.02em;
  font-size: 18px;
}
.brand__wordmark {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 18px;
  letter-spacing: 0.04em;
  color: var(--near-black);
}
.brand__sub {
  display: block;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--forest);
  margin-top: 2px;
}
.nav { display: none; }
.nav__list {
  list-style: none;
  display: flex;
  gap: var(--space-6);
  margin: 0; padding: 0;
}
.nav__link {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  color: var(--near-black);
  text-decoration: none;
  padding: var(--space-2) 0;
  border-bottom: 2px solid transparent;
}
.nav__link:hover { color: var(--forest); border-bottom-color: var(--forest); }
.header-cta { display: inline-flex; gap: var(--space-3); align-items: center; }

/* Hamburger (mobile) */
.menu-toggle {
  display: inline-grid;
  place-items: center;
  width: 44px; height: 44px;
  background: transparent;
  border: 1px solid var(--surface-2);
  border-radius: var(--radius-md);
  cursor: pointer;
  color: var(--near-black);
}
.menu-toggle svg { width: 22px; height: 22px; }

@media (min-width: 1025px) {
  .nav { display: block; }
  .menu-toggle { display: none; }
}

/* ---------- Buttons ------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  line-height: 1.2;
  padding: 12px 20px;
  min-height: 44px;
  border-radius: var(--radius-md);
  border: 2px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
  white-space: nowrap;
}
.btn--primary {
  background: var(--bronze);
  color: var(--white);
}
.btn--primary:hover { background: var(--bronze-dark); color: var(--white); }
.btn--secondary {
  background: transparent;
  color: var(--forest);
  border-color: var(--forest);
}
.btn--secondary:hover {
  background: var(--forest);
  color: var(--white);
}
.btn--secondary-on-dark {
  background: transparent;
  color: var(--white);
  border-color: var(--white);
}
.btn--secondary-on-dark:hover {
  background: var(--white);
  color: var(--forest-dark);
}
.btn--block { width: 100%; }

/* ---------- Hero ---------------------------------------------------- */
.hero {
  position: relative;
  min-height: clamp(520px, 75vh, 760px);
  display: grid;
  align-items: end;
  color: var(--white);
  isolation: isolate;
  overflow: hidden;
}
.hero__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}
/* Photo-type scrim (Brand Guide § Type on photography).
   Two layers: a directional left scrim that protects the text column,
   plus a soft bottom wash that grounds the page transition. */
.hero::after {
  content: "";
  position: absolute; inset: 0;
  background:
    linear-gradient(90deg,
      rgba(26,26,26,0.72) 0%,
      rgba(26,26,26,0.55) 40%,
      rgba(26,26,26,0.10) 75%,
      transparent 100%),
    linear-gradient(180deg,
      transparent 0%,
      rgba(26,26,26,0.10) 60%,
      rgba(26,26,26,0.55) 100%);
  z-index: -1;
}
.hero__inner {
  padding-block: var(--space-16) var(--space-12);
  display: grid;
  gap: var(--space-6);
  max-width: 760px;
}
.hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--straw);
}
/* On photography: weight 400 minimum + defensive text-shadow.
   Never weight 300 over photo (Brand Guide). */
.hero h1 {
  color: var(--white);
  margin: 0;
  font-weight: 400;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}
.hero__lede {
  font-size: clamp(16px, 1.6vw, 18px);
  max-width: 56ch;
  color: rgba(255, 255, 255, 0.95);
  margin: 0;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}
.hero__eyebrow { text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35); }
.hero__ctas {
  display: flex;
  gap: var(--space-3);
  flex-wrap: wrap;
  margin-top: var(--space-2);
}
.hero__pillars {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-top: var(--space-2);
}
.pill {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.25);
  color: var(--white);
  font-size: 13px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 999px;
  backdrop-filter: blur(6px);
}

/* ---------- Section header pattern ---------------------------------- */
.section__head {
  display: grid;
  gap: var(--space-3);
  margin-bottom: var(--space-10);
  max-width: 720px;
}
.section__head--center {
  margin-inline: auto;
  text-align: center;
}
.section__lede {
  color: #3a3a3a;
  font-size: 17px;
  margin: 0;
}

/* ---------- Pillars (Holistic Approach) ----------------------------- */
.pillars-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--space-6);
}
.pillar {
  background: var(--white);
  border: 1px solid var(--surface-2);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  display: grid;
  gap: var(--space-3);
  box-shadow: var(--shadow-sm);
}
.pillar__icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  background: var(--surface-2);
  display: grid;
  place-items: center;
  color: var(--forest);
}
.pillar__icon svg { width: 26px; height: 26px; stroke-width: 2; }
.pillar h3 { margin: 0; }
.pillar p { margin: 0; color: #3a3a3a; }
.pillars-cta {
  margin-top: var(--space-10);
  text-align: center;
}

/* ---------- Product grid -------------------------------------------- */
.products-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: var(--space-6);
  margin-bottom: var(--space-10);
  flex-wrap: wrap;
}
.products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-5);
}
@media (max-width: 900px) { .products-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .products-grid { grid-template-columns: 1fr; } }

.product-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--surface-2);
  border-radius: var(--radius-md);
  padding: var(--space-5);
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.15s ease, transform 0.15s ease;
}
.product-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.product-card__media {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--surface-2);
  aspect-ratio: 4 / 3;
  margin-bottom: var(--space-4);
}
.product-card__media img {
  width: 100%; height: 100%; object-fit: cover;
}
.badge {
  position: absolute;
  top: var(--space-3);
  left: var(--space-3);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--white);
  background: var(--forest);
  padding: 4px 8px;
  border-radius: var(--radius-sm);
}
.badge--bestseller { background: var(--bronze); }
.badge--share { background: var(--forest-dark); }

.product-card__title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 18px;
  line-height: 1.3;
  margin: 0 0 var(--space-2);
  color: var(--near-black);
}
.product-card__desc {
  font-size: 14px;
  line-height: 1.55;
  color: #3a3a3a;
  margin: 0 0 var(--space-4);
  flex: 1;
}
.product-card__meta {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: 13px;
  color: #555;
  margin-bottom: var(--space-4);
}
.stars { color: var(--bronze); letter-spacing: 1px; font-size: 13px; }
.product-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
}
.price {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 18px;
  color: var(--near-black);
}
.price small {
  font-family: var(--font-body);
  font-size: 12px;
  color: #555;
  font-weight: 400;
}

/* ---------- Compare (Grass vs Grain) -------------------------------- */
.compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-6);
}
@media (max-width: 800px) { .compare { grid-template-columns: 1fr; } }

.compare__panel {
  background: var(--white);
  border: 1px solid var(--surface-2);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  box-shadow: var(--shadow-sm);
}
.compare__panel--grass { border-top: 6px solid var(--forest); }
.compare__panel--grain { border-top: 6px solid var(--bronze); }
.compare__tag {
  align-self: flex-start;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--white);
  background: var(--forest);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
}
.compare__panel--grain .compare__tag { background: var(--bronze); }
.compare__list { padding-left: var(--space-5); }
.compare__list li {
  font-size: 15px;
  line-height: 1.55;
}
.compare__list li strong { color: var(--near-black); }

/* ---------- Story / How are we different ---------------------------- */
.story {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: var(--space-12);
  align-items: center;
}
@media (max-width: 900px) { .story { grid-template-columns: 1fr; } }
.story__media {
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  aspect-ratio: 4 / 5;
}
.story__media img { width: 100%; height: 100%; object-fit: cover; }
.story__quote {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(20px, 2vw, 24px);
  line-height: 1.4;
  color: var(--forest-dark);
  border-left: 4px solid var(--bronze);
  padding-left: var(--space-5);
  margin: var(--space-6) 0;
}

/* ---------- Trust badges ------------------------------------------- */
.trust {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--space-12);
  padding-block: var(--space-12);
}
.trust__label {
  flex-basis: 100%;
  text-align: center;
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--forest);
  font-weight: 600;
  margin-bottom: var(--space-4);
}
.trust img {
  height: 80px;
  width: auto;
  opacity: 0.85;
  filter: saturate(0.9);
}

/* ---------- Newsletter --------------------------------------------- */
.newsletter {
  background: var(--forest);
  color: var(--white);
  border-radius: var(--radius-xl);
  padding: clamp(var(--space-8), 5vw, var(--space-16));
  display: grid;
  gap: var(--space-6);
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
}
@media (max-width: 800px) { .newsletter { grid-template-columns: 1fr; } }
.newsletter h2 { color: var(--white); margin: 0; }
.newsletter p { color: rgba(255,255,255,0.88); margin: 0; }
.newsletter__form {
  display: grid;
  gap: var(--space-3);
}
.field {
  display: flex;
  gap: var(--space-2);
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 6px;
}
.field input {
  flex: 1;
  border: 0;
  outline: 0;
  padding: 10px 12px;
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--near-black);
  background: transparent;
  border-radius: var(--radius-sm);
}
.field input:focus-visible { outline: 3px solid var(--straw); outline-offset: 1px; }
.helper {
  font-size: 13px;
  color: rgba(255,255,255,0.78);
  margin: 0;
}

/* ---------- Footer ------------------------------------------------- */
.site-footer {
  background: var(--near-black);
  color: rgba(255,255,255,0.85);
  padding-block: var(--space-12);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: var(--space-8);
}
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }

.footer-grid h4 {
  color: var(--white);
  font-size: 14px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0 0 var(--space-4);
}
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: var(--space-2); }
.footer-grid a {
  color: rgba(255,255,255,0.78);
  text-decoration: none;
  font-size: 14px;
}
.footer-grid a:hover { color: var(--white); text-decoration: underline; }

.footer-brand p { font-size: 14px; color: rgba(255,255,255,0.7); max-width: 36ch; }
.footer-brand .brand__wordmark { color: var(--white); }
.footer-brand .brand__sub { color: var(--straw); }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.10);
  margin-top: var(--space-12);
  padding-top: var(--space-6);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-3);
  font-size: 13px;
  color: rgba(255,255,255,0.55);
}

/* ---------- Utility ------------------------------------------------- */
.center { text-align: center; }
.muted { color: #555; }
.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;
}

/* ---------- Reduced motion ----------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}
