/* Shared TreatShelf chrome */
@import url("nav.css");

:root {
  --ink: #14201c;
  --ink-soft: #3a4a44;
  --muted: #6a7872;
  --line: #d5ddd8;
  --paper: #f3f6f2;
  --brand: #0f3d32;
  --font-display: "Instrument Serif", Georgia, serif;
  --font-body: "Schibsted Grotesk", system-ui, sans-serif;
}
* { box-sizing: border-box; }
html {
  overflow-x: clip;
}
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background:
    radial-gradient(1200px 500px at 10% -10%, #dde8e1 0%, transparent 55%),
    radial-gradient(900px 420px at 100% 0%, #e8dfd4 0%, transparent 50%),
    var(--paper);
  line-height: 1.55;
  overflow-x: clip;
}

.page {
  /* Deprecated as a layout wrapper — use .site-shell + .site-content.
     Kept for in-content typography when nested. */
  max-width: none;
  margin: 0;
  padding: 0;
}
.page h1,
.site-content > h1 {
  margin: 0 0 0.75rem;
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 2.6rem);
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 1.15;
}
.page h2 {
  margin: 1.75rem 0 0.55rem;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
}
.page p, .page li { color: var(--ink-soft); }
.page a { color: var(--brand); }
.lede {
  margin: 0 0 1.5rem;
  color: var(--ink-soft);
  font-size: 1.05rem;
}
.links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.55rem;
  min-width: 0;
}
.links > li { min-width: 0; }
.links a {
  display: block;
  text-decoration: none;
  color: var(--ink);
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--line);
  font-weight: 650;
  font-size: 1rem;
  line-height: 1.3;
}
.links a:hover { color: var(--brand); }
.links a:has(img) {
  display: grid;
  grid-template-columns: 4.5rem minmax(0, 1fr);
  gap: 0.85rem;
  align-items: center;
  padding: 0.55rem 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
}
.links a img {
  width: 4.5rem;
  height: 4.5rem;
  object-fit: cover;
  border-radius: 10px;
  display: block;
}
.links a .link-copy {
  display: block;
  min-width: 0;
  margin: 0;
  font-weight: 650;
  font-size: 1rem;
  line-height: 1.3;
  color: var(--ink);
}
.links a:hover .link-copy { color: var(--brand); }
.links a > span:not(.link-copy),
.links a .link-copy > span {
  display: block;
  margin-top: 0.2rem;
  font-weight: 500;
  color: var(--muted);
  font-size: 0.9rem;
}
@media (min-width: 640px) {
  .links {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.35rem 1.5rem;
  }
  .links a:has(img) {
    grid-template-columns: 5rem minmax(0, 1fr);
  }
  .links a img {
    width: 5rem;
    height: 5rem;
  }
}

/* Site shell — left content + reserved right ad rail (aliases: guides-*) */
.site-shell,
.guides-shell {
  max-width: 1120px;
  width: 100%;
  margin: 0 auto;
  padding: 1.25rem 1.25rem 3rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 2rem;
  min-width: 0;
}
.site-content,
.guides-content {
  width: 100%;
  min-width: 0;
}
.site-content > h1,
.guides-content h1 {
  margin: 0 0 0.75rem;
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 2.6rem);
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 1.15;
}
.site-content > h2 {
  margin: 1.75rem 0 0.55rem;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
}
.site-content > p,
.site-content > ul {
  color: var(--ink-soft);
}
.site-content a {
  color: var(--brand);
}
.site-rail,
.guides-rail {
  display: none;
}
@media (min-width: 960px) {
  .site-shell,
  .guides-shell {
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 2.75rem;
    align-items: start;
  }
  .site-rail,
  .guides-rail {
    display: block;
    position: sticky;
    top: 5rem;
    min-height: 12rem;
  }
  .guide-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.guide-filters,
.hub-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1rem;
  margin: 0 0 1.35rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--line);
}
.guide-filters button,
.hub-filters button {
  appearance: none;
  border: 0;
  background: transparent;
  padding: 0.2rem 0;
  font: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
}
.guide-filters button:hover,
.hub-filters button:hover { color: var(--brand); }
.guide-filters button.is-active,
.hub-filters button.is-active {
  color: var(--brand);
  border-bottom-color: var(--brand);
}

/* Hub search — filters the list in place (no dropdown; avoids overflow clipping) */
.hub-search {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 32rem;
  min-width: 0;
  margin: 0 0 1.1rem;
  overflow: visible;
}
.hub-search input[type="search"] {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  min-height: 2.85rem;
  padding: 0.65rem 0.95rem;
  border: 1px solid #b7c9bf;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
  appearance: none;
  -webkit-appearance: none;
}
.hub-search input[type="search"]::-webkit-search-decoration,
.hub-search input[type="search"]::-webkit-search-cancel-button {
  -webkit-appearance: none;
}
.hub-search input[type="search"]::placeholder {
  color: var(--muted);
}
.hub-search input[type="search"]:focus {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
  border-color: var(--brand);
}
.guide-grid {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.85rem;
}
.guide-grid a {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
  color: var(--ink);
  padding: 1.05rem 1.1rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255,255,255,0.75);
  font-weight: 650;
  line-height: 1.3;
}
.guide-grid a:hover { border-color: #7fb89a; }
.guide-grid span {
  display: block;
  margin-top: 0.4rem;
  font-weight: 500;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.4;
}
.guide-empty {
  margin: 0.5rem 0 0;
  color: var(--muted);
}
@media (min-width: 720px) {
  .guide-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
  }
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 1.25rem;
  color: var(--muted);
  font-size: 0.86rem;
}
.site-footer-inner {
  max-width: 1120px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  justify-content: space-between;
  align-items: center;
}
.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
}
.site-footer a {
  color: var(--muted);
  text-decoration: none;
}
.site-footer a:hover { color: var(--brand); }

.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;
}

/* Homepage */
.home {
  min-height: 60vh;
  max-width: 100%;
}
.home-hero {
  position: relative;
  z-index: 4;
  display: flex;
  align-items: center;
  padding: 1.35rem 1.25rem 1.25rem;
  overflow: visible;
  background:
    linear-gradient(180deg, rgba(15, 61, 50, 0.08) 0%, transparent 42%),
    radial-gradient(900px 480px at 18% 20%, #c9ddd2 0%, transparent 58%),
    radial-gradient(700px 420px at 92% 8%, #e6d7c4 0%, transparent 52%),
    linear-gradient(160deg, #e8efe9 0%, #f3f6f2 55%, #ebe4d8 100%);
}
.home-hero::after {
  content: "";
  position: absolute;
  inset: auto 0 -40% 35%;
  height: 70%;
  background:
    radial-gradient(ellipse at center, rgba(15, 61, 50, 0.12) 0%, transparent 68%);
  pointer-events: none;
  z-index: 0;
}
.home-hero-inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1120px;
  min-width: 0;
  margin: 0 auto;
  text-align: left;
}
.home-hero h1 {
  margin: 0 0 0.4rem;
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 8vw, 3.25rem);
  font-weight: 400;
  letter-spacing: -0.035em;
  line-height: 0.95;
  color: var(--brand);
}
.home-hero-lede {
  margin: 0 0 1rem;
  max-width: 28rem;
  color: var(--ink-soft);
  font-size: clamp(0.98rem, 2.8vw, 1.1rem);
  line-height: 1.45;
}
.home-search {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.55rem;
  width: 100%;
  max-width: 32rem;
  min-width: 0;
  margin: 0;
}
.home-search input[type="search"] {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  min-height: 3rem;
  padding: 0.7rem 0.95rem;
  border: 1px solid #b7c9bf;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
  appearance: none;
  -webkit-appearance: none;
}
.home-search input[type="search"]::-webkit-search-decoration,
.home-search input[type="search"]::-webkit-search-cancel-button {
  -webkit-appearance: none;
}
.home-search input[type="search"]::placeholder {
  color: var(--muted);
}
.home-search input[type="search"]:focus {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
  border-color: var(--brand);
}
.home-search button {
  min-height: 3rem;
  width: 100%;
  padding: 0 1.15rem;
  border: 0;
  border-radius: 12px;
  background: var(--brand);
  color: #f5faf7;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}
.home-search button:hover {
  background: #0a2e26;
}
.home-search-results {
  position: absolute;
  top: calc(100% + 0.4rem);
  left: 0;
  right: 0;
  z-index: 20;
  margin: 0;
  padding: 0.35rem;
  list-style: none;
  text-align: left;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(20, 32, 28, 0.12);
  max-height: min(20rem, 50vh);
  overflow: auto;
}
@media (min-width: 640px) {
  .home-hero {
    min-height: min(32vh, 16rem);
    padding: 1.75rem 1.25rem 1.5rem;
  }
  .home-search {
    grid-template-columns: minmax(0, 1fr) auto;
  }
  .home-search button {
    width: auto;
  }
}
.home-search-results a {
  display: block;
  padding: 0.7rem 0.8rem;
  text-decoration: none;
  color: var(--ink);
  border-radius: 8px;
}
.home-search-results a:hover {
  background: #eef4f0;
}
.home-search-results strong {
  display: block;
  font-weight: 650;
  font-size: 0.95rem;
  line-height: 1.3;
}
.home-search-results span {
  display: block;
  margin-top: 0.15rem;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 500;
}
.home-search-empty {
  padding: 0.85rem 0.9rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.home-body {
  position: relative;
  z-index: 1;
}
.home-body.site-shell {
  /* shell owns width/padding; drop duplicate home-body box */
  max-width: 1120px;
}
.home-block {
  margin: 0 0 2.25rem;
  min-width: 0;
}
.home-block:last-child {
  margin-bottom: 0;
}
.home-block > h2 {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 7vw, 2.45rem);
  font-weight: 400;
  letter-spacing: -0.03em;
  color: var(--ink);
  border-bottom: 1px solid var(--line);
  padding-bottom: 0.5rem;
}
.home-subblock {
  margin: 0 0 1.75rem;
  min-width: 0;
}
.home-subblock:last-child {
  margin-bottom: 0;
}
.home-subhead {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.35rem 0.85rem;
  margin: 0 0 0.7rem;
}
.home-subhead h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 5vw, 1.45rem);
  font-weight: 400;
  letter-spacing: -0.02em;
}
.home-more {
  color: var(--brand);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
}
.home-more:hover {
  text-decoration: underline;
}
.home-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.55rem;
  min-width: 0;
}
.home-links > li {
  min-width: 0;
}
.home-links a {
  display: block;
  text-decoration: none;
  color: var(--ink);
  padding: 0.8rem 0;
  border-bottom: 1px solid var(--line);
  font-weight: 650;
  font-size: 1rem;
  line-height: 1.3;
  overflow-wrap: anywhere;
  word-break: break-word;
  min-width: 0;
}
.home-links a:hover {
  color: var(--brand);
}
.home-links a > span:not(.link-copy) {
  display: block;
  margin-top: 0.2rem;
  font-weight: 500;
  color: var(--muted);
  font-size: 0.9rem;
  overflow-wrap: anywhere;
}
.home-links--media {
  gap: 0.65rem;
}
.home-links--media a {
  display: grid;
  grid-template-columns: 4.25rem minmax(0, 1fr);
  gap: 0.75rem;
  align-items: center;
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--line);
  font-weight: 650;
  font-size: 1rem;
}
.home-links--media img {
  width: 4.25rem;
  height: 4.25rem;
  object-fit: cover;
  border-radius: 10px;
  display: block;
}
.home-links--media .link-copy {
  display: block;
  min-width: 0;
  margin: 0;
  font-weight: 650;
  font-size: 1rem;
  line-height: 1.3;
  color: var(--ink);
}
.home-links--media a:hover .link-copy {
  color: var(--brand);
}
.home-links--media .link-copy > span {
  display: block;
  margin-top: 0.2rem;
  font-weight: 500;
  color: var(--muted);
  font-size: 0.9rem;
}
.home-coming-soon {
  margin: 0;
  color: var(--ink-soft);
  font-size: 1.05rem;
  max-width: 28rem;
}
.home-block--cats {
  padding-top: 0.25rem;
}
@media (min-width: 640px) {
  .home-links {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 1.5rem;
  }
  .home-links a {
    padding: 0.9rem 0;
  }
  .home-links--media {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.35rem 1.5rem;
  }
  .home-links--media a {
    grid-template-columns: 5rem 1fr;
  }
  .home-links--media img {
    width: 5rem;
    height: 5rem;
  }
}
