/* Raisedkit: garden shop. One stylesheet, no build step. */
:root {
  --paper: #f4efe6;
  --ink: #1a241c;
  --moss: #1f4d34;
  --cedar: #a85a32;
  --leaf: #3d7a52;
  --card: #fffdf8;
  --line: #e2d8c8;
  --muted: #5a645d;
  --measure: 44rem;
  --site: 72rem;
  --serif: "Fraunces", "Iowan Old Style", Palatino, "Palatino Linotype", serif;
  --sans: "Source Sans 3", "Source Sans Pro", "Segoe UI", sans-serif;
  --lift: 0 10px 24px rgba(26, 36, 28, 0.14);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--sans);
  font-size: 1.125rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; }
a { color: var(--moss); text-decoration-thickness: 1px; text-underline-offset: 0.16em; }
a:hover { color: var(--cedar); }
a:focus-visible { outline: 3px solid var(--cedar); outline-offset: 3px; }
p { margin: 0 0 1rem; }

.skip {
  position: absolute; left: 0.75rem; top: 0.75rem; z-index: 10;
  transform: translateY(-160%);
  background: var(--card); color: var(--ink);
  padding: 0.45rem 0.75rem; border: 1px solid var(--ink); text-decoration: none;
}
.skip:focus { transform: none; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

.wrap { max-width: var(--measure); margin: 0 auto; padding: 0 1.35rem; }
.wide,
.site-header .wrap,
.site-footer .wrap { max-width: var(--site); }

/* Header: moss shop bar */
.site-header { background: var(--moss); color: #fff; border-bottom: 4px solid var(--cedar); }
.header-row {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 0.5rem 1.5rem; padding-top: 0.8rem; padding-bottom: 0.8rem;
}
.logo {
  color: #fff; font-family: var(--serif); font-weight: 650; font-size: 1.9rem;
  letter-spacing: -0.03em; line-height: 1; text-decoration: none;
}
.logo:hover { color: #fff; }
.nav { display: flex; flex-wrap: wrap; gap: 0.25rem 0.35rem; align-items: center; }
.nav a {
  color: #fff; text-decoration: none; font-weight: 700; font-size: 1.02rem;
  padding: 0.4rem 0.7rem; border-radius: 4px;
}
.nav a:hover { background: rgba(255, 255, 255, 0.14); color: #fff; }
.nav a[aria-current="page"] { background: rgba(255, 255, 255, 0.18); }

/* Footer */
.site-footer { background: var(--moss); color: var(--paper); border-top: 4px solid var(--cedar); font-size: 0.98rem; }
.footer-row {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 0.75rem 1.5rem; padding-top: 1.2rem; padding-bottom: 1.2rem;
}
.footer-nav { display: flex; flex-wrap: wrap; gap: 0.35rem 1.1rem; }
.site-footer a { color: var(--paper); text-decoration: none; font-weight: 600; }
.site-footer a:hover { color: var(--paper); text-decoration: underline; text-decoration-color: #f0c7a4; }
.fine { margin: 0; color: var(--paper); }

/* Type */
h1, h2, h3 {
  font-family: var(--serif); font-weight: 560; letter-spacing: -0.02em;
  line-height: 1.15; color: var(--ink);
}
h1 { font-size: clamp(2.1rem, 4vw, 2.8rem); margin: 1.6rem 0 0.7rem; }
h2 { font-size: 1.55rem; margin: 2.4rem 0 0.7rem; padding-bottom: 0.35rem; border-bottom: 1px solid var(--line); }
h3 { font-size: 1.22rem; margin: 1.6rem 0 0.45rem; }
.lede { font-size: 1.22rem; line-height: 1.55; }

main { padding: 0 0 3rem; }

/* Guide, about, contact pages */
.affiliate-note {
  margin: 0; padding: 0.7rem 1.35rem; background: var(--card);
  border-bottom: 1px solid var(--line); font-size: 0.98rem; line-height: 1.45; text-align: center;
}
.article ul, .article ol { margin: 0.2rem 0 1.15rem; padding-left: 1.25rem; }
.article li { margin: 0.45rem 0; }
.article li::marker { color: var(--cedar); }
.article em { font-family: var(--serif); }
.article-figure { margin: 0.4rem 0 1.5rem; }
.article-figure img { display: block; width: 100%; height: auto; border: 1px solid var(--line); background: var(--card); }
.article-figure figcaption { margin-top: 0.45rem; font-size: 0.9rem; line-height: 1.4; color: var(--muted); }
main p a, main li a, figcaption a { overflow-wrap: anywhere; }

/* Buttons */
.btn,
.shop {
  display: inline-block; text-align: center; text-decoration: none;
  font-family: var(--sans); font-weight: 700; font-size: 1.05rem; line-height: 1.2;
  padding: 0.85rem 1.5rem; border-radius: 6px; border: 2px solid transparent;
  background: var(--cedar); color: #fff;
  transition: background-color 0.15s, transform 0.15s;
}
.btn:hover, .shop:hover { background: #8e4826; color: #fff; }
.btn-moss { background: var(--moss); }
.btn-moss:hover { background: var(--leaf); }
.btn-lg { font-size: 1.2rem; padding: 1rem 2rem; }
.price { font-family: var(--sans); font-weight: 700; font-size: 1.15rem; line-height: 1.2; margin: 0 0 0.75rem; }

/* Homepage hero: maker photo, hook line, one Shop button */
main.home { padding-top: 0; }
.hero {
  position: relative; overflow: hidden; isolation: isolate;
  height: clamp(14rem, 32vh, 16rem); display: flex; align-items: center;
  background: var(--moss); color: #fff;
}
.hero-img {
  position: absolute; inset: 0; z-index: -2;
  width: 100%; height: 100%; max-width: none;
  object-fit: cover; object-position: center 62%;
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(16, 28, 19, 0.86) 0%, rgba(16, 28, 19, 0.62) 38%, rgba(16, 28, 19, 0.12) 72%, rgba(16, 28, 19, 0) 100%),
    linear-gradient(0deg, rgba(16, 28, 19, 0.35) 0%, rgba(16, 28, 19, 0) 40%);
}
.hero-inner { width: 100%; padding-bottom: 1.6rem; }
.hero h1 {
  margin: 0 0 0.45rem; color: #fff; max-width: 13em;
  font-size: clamp(2.1rem, 4.4vw, 3.4rem); font-weight: 650; line-height: 1.02; letter-spacing: -0.025em;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.35);
}
.hero p { margin: 0 0 1.1rem; max-width: 30em; font-size: 1.2rem; line-height: 1.4; color: #f4efe6; }
.hero-btn { box-shadow: 0 6px 18px rgba(0, 0, 0, 0.28); }
.hero-btn:hover { color: #fff; }

/* Category doors: compact, pulled up over the hero edge */
.cat-grid {
  list-style: none; margin: -1.6rem 0 0; padding: 0; position: relative; z-index: 1;
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem;
}
.cat-tile > a {
  display: flex; align-items: stretch; height: 5rem;
  background: var(--card); border: 1px solid var(--line); border-radius: 8px; overflow: hidden;
  color: inherit; text-decoration: none; box-shadow: 0 6px 18px rgba(26, 36, 28, 0.12);
  transition: transform 0.18s, box-shadow 0.18s;
}
.cat-tile > a:hover, .cat-tile > a:focus-visible { transform: translateY(-3px); box-shadow: var(--lift); }
.cat-thumb { flex: 0 0 7.5rem; background: #fff; border-right: 1px solid var(--line); }
.cat-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.cat-thumb img.tower-photo { object-position: center 55%; }
/* Soil bag: the whole bag, small, on a soft paper ground. Never cropped. */
.cat-thumb.bag-thumb { background: #efe7d8; padding: 0.4rem 0; }
.cat-thumb.bag-thumb img { object-fit: contain; }
.cat-bar {
  flex: 1; display: flex; align-items: center; justify-content: space-between; gap: 0.5rem;
  padding: 0 1.1rem; min-width: 0;
}
.cat-bar h2 { margin: 0; padding: 0; border: 0; color: var(--ink); font-size: clamp(1.35rem, 2vw, 1.7rem); font-weight: 650; }
.cat-bar span { font-weight: 700; font-size: 1rem; white-space: nowrap; color: var(--moss); }
.cat-tile > a:hover .cat-bar h2, .cat-tile > a:hover .cat-bar span { color: var(--cedar); }

/* Soil bags: whole, at their own shape. */
.shop-card img.bag-photo,
.soil-band img.bag-photo { object-fit: contain; padding: 0.75rem; background: #fff; }

/* Popular picks: one tight row of six on desktop */
.home-section.picks { margin-top: 1.25rem; }
.picks .section-head { margin-bottom: 0.7rem; }
.picks .section-head h2 { font-size: clamp(1.4rem, 2.2vw, 1.7rem); }

.home-section { margin-top: 3rem; }
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0.5rem 1rem; margin-bottom: 1rem; }
.section-head h2 { margin: 0; padding: 0; border: 0; font-size: clamp(1.6rem, 2.6vw, 2.1rem); font-weight: 650; }
.section-head a { font-weight: 700; }

/* Size band */
.size-band { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.size-band a {
  display: block; height: 100%; padding: 1.2rem 1.3rem; border-radius: 8px;
  background: var(--moss); color: #fff; text-decoration: none;
  transition: transform 0.18s, box-shadow 0.18s, background-color 0.15s;
}
.size-band a:hover { background: var(--cedar); color: #fff; transform: translateY(-3px); box-shadow: var(--lift); }
.size-band strong { display: block; font-family: var(--serif); font-size: 2.6rem; font-weight: 650; line-height: 1; }
.size-band span { display: block; margin-top: 0.4rem; font-weight: 600; }

/* Soil band */
.soil-band {
  display: grid; grid-template-columns: 14rem 1fr; gap: 1.5rem; align-items: center;
  background: var(--card); border: 1px solid var(--line); border-radius: 8px; padding: 1.25rem 1.5rem;
}
.soil-band img { display: block; width: 100%; height: auto; border-radius: 6px; }
.soil-band h2 { margin: 0 0 0.4rem; padding: 0; border: 0; font-size: clamp(1.6rem, 2.6vw, 2.1rem); font-weight: 650; }
.soil-band p { margin: 0 0 1rem; color: var(--muted); }

/* Category page title band */
.page-band { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.25rem 1rem; padding: 1.4rem 0 1rem; border-bottom: 1px solid var(--line); margin-bottom: 1.4rem; }
.page-band h1 { margin: 0; font-weight: 650; }
.page-band p { margin: 0; font-weight: 700; color: var(--muted); }

/* Shop grid: equal-height cards, fixed photo frame, Shop on one baseline. */
.shop-grid {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(auto-fill, minmax(min(15rem, 100%), 1fr));
  gap: 1.25rem; align-items: stretch;
}
.shop-grid > li { margin: 0; padding: 0; }
.shop-card {
  display: flex; flex-direction: column; min-width: 0;
  background: #fff; border: 1px solid var(--line); border-radius: 8px; overflow: hidden;
  padding: 0 0 1rem;
  transition: transform 0.18s, box-shadow 0.18s;
}
.shop-card:hover { transform: translateY(-4px); box-shadow: var(--lift); }
.card-link { display: block; color: inherit; text-decoration: none; }
.card-link:hover h2, .card-link:hover h3 { color: var(--moss); text-decoration: underline; text-decoration-color: var(--cedar); }
.shop-card img {
  display: block; width: 100%; height: auto; aspect-ratio: 1 / 1;
  object-fit: cover; object-position: center; background: #fff; border-bottom: 1px solid var(--line);
}
.bag-grid .shop-card img { object-fit: contain; padding: 0.75rem; }
.shop-card h2,
.shop-card h3 {
  font-family: var(--sans); font-weight: 700; font-size: 1.05rem; line-height: 1.3; letter-spacing: 0;
  margin: 0.85rem 1rem 0.35rem; padding: 0; border: 0; color: var(--ink);
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2;
  overflow: hidden; min-height: 2.6em;
}
/* Small plain note under a price. */
.price-note { margin: 0 1rem; font-size: 0.88rem; line-height: 1.35; color: var(--muted); }
.shop-card .price { margin: 0 1rem 0.9rem; }
/* A lone card (Planters) has no row to line up with, so show its full name. */
.shop-grid > li:only-child h2 { display: block; -webkit-line-clamp: none; line-clamp: none; }
.shop-card .price:has(+ .price-note) { margin-bottom: 0.15rem; }
.shop-card .price-note { margin-bottom: 0.9rem; }
/* Shop pinned to the card bottom: equal-height grid rows put every button on one baseline. */
.shop-card .shop { display: block; margin: auto 1rem 0; }

/* Product page */
.crumbs { margin: 1.1rem 0 1rem; font-size: 0.98rem; color: var(--muted); }
.crumbs a { font-weight: 600; }
.product { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 2.5rem; align-items: start; }
.product-photo img { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); background: #fff; }
.product-info .maker { margin: 0 0 0.3rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; font-size: 0.85rem; color: var(--cedar); }
.product-info h1 { margin: 0 0 0.6rem; font-weight: 650; font-size: clamp(1.9rem, 3vw, 2.5rem); }
.product-info .price { font-size: 1.9rem; margin-bottom: 1.1rem; }
.product-info .btn { display: block; width: 100%; }
.specs { margin: 1.6rem 0 0; }
.specs h2 { font-size: 1.25rem; margin: 0 0 0.5rem; }
.specs dl { margin: 0; display: grid; grid-template-columns: max-content 1fr; gap: 0 1rem; }
.specs dt, .specs dd { margin: 0; padding: 0.5rem 0; border-bottom: 1px solid var(--line); }
.specs dt { font-weight: 700; }
.spec-source { margin-top: 0.75rem; font-size: 0.9rem; color: var(--muted); }

/* Responsive */
@media (min-width: 1100px) {
  .shop-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .shop-grid.row-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .shop-grid.picks-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 0.9rem; }
  .picks-grid .shop-card { padding-bottom: 0.8rem; }
  .picks-grid .shop-card img { aspect-ratio: 6 / 5; }
  .picks-grid .shop-card h3 { font-size: 0.98rem; margin: 0.65rem 0.8rem 0.3rem; }
  .picks-grid .shop-card .price { margin-left: 0.8rem; margin-right: 0.8rem; }
  .picks-grid .price-note { margin-left: 0.8rem; margin-right: 0.8rem; font-size: 0.82rem; }
  .picks-grid .shop-card .shop { margin: auto 0.8rem 0; padding: 0.65rem 0.75rem; }
}
@media (max-width: 860px) {
  .product { grid-template-columns: 1fr; gap: 1.5rem; }
  .shop-grid.picks-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  body { font-size: 1.05rem; }
  .header-row { padding-top: 0.65rem; padding-bottom: 0.55rem; }
  .logo { font-size: 1.6rem; }
  .nav { width: calc(100% + 0.5rem); margin: 0 0 0 -0.5rem; gap: 0.15rem 0.1rem; }
  .nav a { padding: 0.35rem 0.5rem; font-size: 0.98rem; }
  .size-band { grid-template-columns: 1fr; }
  .hero { height: auto; min-height: 0; padding: 2rem 0 2.6rem; }
  .hero::before { background: linear-gradient(180deg, rgba(16, 28, 19, 0.55) 0%, rgba(16, 28, 19, 0.78) 100%); }
  .hero-img { object-position: center 60%; }
  .hero h1 { font-size: 2.2rem; }
  .hero p { font-size: 1.05rem; margin-bottom: 1rem; }
  .hero .btn-lg { width: auto; padding: 0.85rem 1.6rem; font-size: 1.1rem; }
  .cat-grid { gap: 0.5rem; margin-top: -1.3rem; }
  .cat-tile > a { flex-direction: column; height: auto; }
  .cat-thumb { flex: none; height: 4.6rem; border-right: 0; border-bottom: 1px solid var(--line); }
  .cat-bar { flex-direction: column; align-items: flex-start; justify-content: center; gap: 0; padding: 0.45rem 0.6rem 0.55rem; }
  .cat-bar h2 { font-size: 1.15rem; }
  .cat-bar span { font-size: 0.85rem; }
  .shop-grid.picks-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.75rem; }
  .picks-grid .shop-card h3 { font-size: 0.95rem; margin: 0.6rem 0.7rem 0.3rem; }
  .picks-grid .shop-card .price, .picks-grid .price-note { margin-left: 0.7rem; margin-right: 0.7rem; }
  .picks-grid .shop-card .shop { margin: auto 0.7rem 0; padding: 0.6rem 0.5rem; }
  .soil-band { grid-template-columns: 7rem 1fr; gap: 1rem; padding: 1rem; }
  .btn-lg { width: 100%; }
  .footer-row { flex-direction: column; align-items: flex-start; }
}

/* Soil grid: when some cards carry an "Also on Amazon" row, reserve that row's
   height (0.5rem margin + 0.875rem x 1.6 line) under Shop on cards without it,
   so every Shop button in a row sits on one line. */
.bag-grid:has(.shop-alt) .shop-card > .shop:last-child { margin-bottom: 1.9rem; }

/* Guide links (home Guides section, category pages) */
.guide-row { margin: 2.4rem 0 2.5rem; }
.guide-row h2 { font-size: 1.3rem; margin: 0 0 0.7rem; }
.guide-links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.5rem 0.6rem; }
.guide-links a {
  display: inline-block; padding: 0.45rem 0.85rem; border: 1px solid var(--line); border-radius: 999px;
  background: var(--card); color: var(--ink); font-weight: 600; text-decoration: none;
}
.guide-links a:hover { background: var(--cedar); border-color: var(--cedar); color: #fff; }
.related { margin-top: 2rem; }
