/* Preserve the original header position and align page content to its logo edge. */
:root {
  --site-content-max: 1180px;
  --site-content-gutter: max(20px, calc((100vw - var(--site-content-max)) / 2));
}

html,
body {
  overflow-x: clip;
}

.site-header .container.nav,
.site-footer .container,
.content-page .site .wrap,
.content-page footer .wrap,
header.site .wrap,
body.food-page .wrap,
body.product-detail-page .wrap,
body[data-category] .wrap,
body[data-category] .container,
body.content-page main > section .wrap,
body.content-page .cta .wrap,
body.content-page footer .wrap,
body main > section > .container,
body main > section > .wrap,
body main > section > .foot,
body main > section > .block {
  width: min(var(--site-content-max), calc(100% - 40px)) !important;
  max-width: var(--site-content-max) !important;
  margin-inline: auto !important;
}

nav.crumbs {
  display: block;
  width: min(var(--site-content-max), calc(100% - 40px));
  max-width: var(--site-content-max);
  margin-inline: auto;
  padding-block: 16px;
  color: var(--muted, #5c6b61);
  font-size: .9rem;
  line-height: 1.5;
}

nav.crumbs ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

nav.crumbs li + li::before {
  margin-right: 8px;
  color: #9aa69d;
  content: "/";
}

nav.crumbs a {
  color: var(--green, #0c4723);
  text-decoration: none;
}

nav.crumbs a:hover,
nav.crumbs a:focus-visible {
  text-decoration: underline;
  text-underline-offset: 3px;
}

body table {
  display: table;
  width: 100%;
  max-width: 100%;
  overflow: visible;
}

body .tablewrap,
body .tbl {
  max-width: 100%;
  overflow-x: auto;
  overscroll-behavior-x: contain;
}

.contact-grid > *,
.contact-card > span {
  min-width: 0;
}

.contact-card > span > span {
  overflow-wrap: anywhere;
}

/* Align the products masthead copy with the header logo without a viewport overflow. */
.products .product-intro.hero {
  width: calc(100% + var(--site-content-gutter) + var(--site-content-gutter)) !important;
  margin-right: calc(0px - var(--site-content-gutter)) !important;
  margin-left: calc(0px - var(--site-content-gutter)) !important;
  padding-right: var(--site-content-gutter) !important;
  padding-left: var(--site-content-gutter) !important;
}

.products-page {
  overflow-x: clip;
}

.products-page .product-category-grid .hub-image-link {
  height: clamp(240px, 24vw, 340px);
}

.products-page .product-category-grid .hub-image-link img {
  object-position: center;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .mini-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
  gap: 22px;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .mini {
  display: flex;
  min-width: 0;
  flex-direction: column;
  overflow: hidden;
  padding: 24px;
  border: 1px solid #E4DCBE;
  border-radius: 24px;
  background: linear-gradient(180deg, #fff 0%, #FAF7EB 100%);
  box-shadow: 0 12px 30px rgba(7, 45, 23, .1);
  transition: transform .25s ease, box-shadow .25s ease;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .hub-image-link {
  height: clamp(230px, 22vw, 290px);
  flex: 0 0 auto;
  margin: -24px -24px 20px;
  border-radius: 23px 23px 0 0;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .hub-image-link img {
  object-position: center 52%;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .mini h3 {
  margin: 0;
  color: #0C4723;
  font-size: 1.3rem;
  line-height: 1.25;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .mini p {
  flex: 1 0 auto;
  margin: 10px 0 18px;
  color: #56635A;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .mini .btn {
  align-self: flex-start;
  margin-top: auto;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .product-category-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 24px;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .product-category-item {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 16px;
  padding: 14px;
  overflow: hidden;
  border: 1px solid #E4DCBE;
  border-top: 3px solid #0C4723;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(7, 45, 23, .08);
  transition: transform .2s ease, box-shadow .2s ease;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .product-category-thumb {
  display: block;
  width: 100px;
  height: 80px;
  flex: 0 0 100px;
  overflow: hidden;
  border-radius: 10px;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .product-category-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .product-category-copy {
  min-width: 0;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .product-category-label {
  margin: 0 0 3px;
  color: #0C8275;
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .06em;
  line-height: 1.35;
  text-transform: uppercase;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .product-category-copy h3 {
  margin: 0;
  color: #243245;
  font-size: 1.05rem;
  line-height: 1.25;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .product-category-copy h3 a {
  color: inherit;
  text-decoration: none;
}

.products-page main > section[aria-labelledby="specialty-products-title"] .product-category-copy h3 a:hover,
.products-page main > section[aria-labelledby="specialty-products-title"] .product-category-copy h3 a:focus-visible {
  color: var(--emerald-deep, #00703f);
}

.products-page main > section[aria-labelledby="specialty-products-title"] .product-category-copy > p:last-child {
  margin: 5px 0 0;
  color: #56635A;
  font-size: .87rem;
  line-height: 1.45;
}

.related-category-section {
  padding: 28px 0 64px;
  border-bottom: 3px solid var(--gold, #d4a13b);
  background: var(--ivory-soft, #fbf8eb);
}

.related-category-section h2 {
  margin: 0 0 16px;
  color: var(--green, #0c4723);
  font-family: Fraunces, Georgia, serif;
  font-size: clamp(1.65rem, 3vw, 2.35rem);
  line-height: 1.15;
}

.related-product-groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.related-product-group {
  min-width: 0;
  padding: 18px;
  border: 1px solid #E4DCBE;
  border-radius: 18px;
  background: #fff;
}

.related-product-group h3 {
  margin: 0 0 12px;
  color: var(--green, #0c4723);
  font-size: 1.12rem;
  line-height: 1.25;
}

.related-category-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.related-category-links a {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 9px 14px;
  border: 1px solid var(--line, #dce5dd);
  border-radius: 999px;
  background: #fff;
  color: var(--green, #0c4723);
  font-weight: 650;
  text-decoration: none;
}

.related-category-links a:hover,
.related-category-links a:focus-visible {
  border-color: var(--green, #0c4723);
}

@media (hover: hover) {
  .products-page main > section[aria-labelledby="specialty-products-title"] .mini:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 42px rgba(7, 45, 23, .16);
  }

  .products-page main > section[aria-labelledby="specialty-products-title"] .product-category-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 30px rgba(7, 45, 23, .13);
  }
}

@media (max-width: 640px) {
  .products-page main > section[aria-labelledby="specialty-products-title"] .mini-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
  }

  .related-product-groups {
    grid-template-columns: minmax(0, 1fr);
  }

  .products-page main > section[aria-labelledby="specialty-products-title"] .product-category-list {
    grid-template-columns: minmax(0, 1fr);
  }

  .products-page main > section[aria-labelledby="specialty-products-title"] .mini {
    padding: 20px;
  }

  .products-page main > section[aria-labelledby="specialty-products-title"] .hub-image-link {
    height: clamp(200px, 58vw, 270px);
    margin: -20px -20px 18px;
    border-radius: 23px 23px 0 0;
  }

  .products-page main > section[aria-labelledby="specialty-products-title"] .mini .btn {
    align-self: stretch;
  }
}

main > section.products:first-child {
  padding-top: 0 !important;
}

/* Full-width hero backgrounds keep their text and visuals on the same grid as the logo. */
.hub-motion main > .hero.wrap,
body[data-category]:not([data-category="hub"]) main > .hero.wrap {
  padding-inline: var(--site-content-gutter) !important;
}

/* Do not constrain the hero background itself to the text container width. */
.hub-motion main > .hero.wrap,
body[data-category]:not([data-category="hub"]) main > .hero.wrap {
  width: 100% !important;
  max-width: none !important;
  margin-inline: 0 !important;
}

.hub-motion main > .hero.wrap > .hero-curve {
  position: absolute !important;
  right: 0 !important;
  bottom: -1px !important;
  left: 0 !important;
  z-index: 2 !important;
  width: auto !important;
  height: 92px !important;
  pointer-events: none !important;
}

.content-page .hero {
  padding-inline: var(--site-content-gutter) !important;
}

.content-page .hero .wrap {
  width: auto !important;
  max-width: none !important;
  margin: 0 !important;
}

.ag-page .ag-shell > section > div,
.rare-page main > section > .wrap {
  width: 100% !important;
  max-width: var(--site-content-max) !important;
  padding-inline: 0 !important;
}

.ag-page .ag-shell > section,
.rare-page main > section:not(.hero) {
  padding-inline: var(--site-content-gutter) !important;
}

.ag-page .ag-shell > section:first-of-type {
  padding-inline: var(--site-content-gutter) !important;
}

/* Use the same single atmospheric overlay as the homepage on the agriculture hero. */
.ag-page .ag-shell > section:first-of-type::before {
  background: radial-gradient(circle at 10% 8%, rgba(0, 133, 74, .4), transparent 34%),
              radial-gradient(circle at 92% 88%, rgba(212, 161, 59, .16), transparent 36%) !important;
}

.ag-page .ag-shell > section:first-of-type.motion-ready > .shared-hero-fx {
  background: none !important;
}

.rare-page main > .hero {
  padding-inline: var(--site-content-gutter) !important;
}

.rare-page main > .hero > .wrap {
  width: 100% !important;
  max-width: var(--site-content-max) !important;
  margin-inline: auto !important;
}

.rare-page footer .wrap {
  width: min(var(--site-content-max), calc(100% - 40px)) !important;
  max-width: var(--site-content-max) !important;
}

/* Keep main headings proportional from wide desktop through mobile. */
body main > .hero h1,
body main > section.hero h1,
body.rare-page main > .hero h1,
body.content-page .hero h1,
.ag-page .ag-shell > section:first-of-type h1 {
  font-size: clamp(2.35rem, 4.2vw, 4.7rem) !important;
  line-height: 1.04 !important;
  letter-spacing: -.035em !important;
  text-wrap: balance;
}

@media (max-width: 760px) {
  .site-header .container.nav,
  .site-footer .container,
  .content-page .site .wrap,
  .content-page footer .wrap,
  header.site .wrap,
  body.food-page .wrap,
  body.product-detail-page .wrap,
  body[data-category] .wrap,
  body[data-category] .container,
  body.content-page main > section .wrap,
  body.content-page .cta .wrap,
  body.content-page footer .wrap,
  body main > section > .container,
  body main > section > .wrap,
  body main > section > .foot,
  body main > section > .block {
    width: min(var(--site-content-max), calc(100% - 32px)) !important;
  }

  nav.crumbs {
    width: min(var(--site-content-max), calc(100% - 32px));
  }

  .ag-page .ag-shell > section,
  .ag-page .ag-shell > section:first-of-type,
  .rare-page main > section:not(.hero),
  .rare-page main > .hero,
  .content-page .hero,
  .hub-motion main > .hero.wrap,
  body[data-category]:not([data-category="hub"]) main > .hero.wrap {
    padding-inline: 16px !important;
  }

  body main > .hero h1,
  body main > section.hero h1,
  body.rare-page main > .hero h1,
  body.content-page .hero h1,
  .ag-page .ag-shell > section:first-of-type h1 {
    font-size: clamp(2.2rem, 7.2vw, 3.35rem) !important;
  }
}

@media (max-width: 420px) {
  body main > .hero h1,
  body main > section.hero h1,
  body.rare-page main > .hero h1,
  body.content-page .hero h1,
  .ag-page .ag-shell > section:first-of-type h1 {
    font-size: clamp(2rem, 9vw, 2.45rem) !important;
  }
}

@media (max-width: 640px) {
  .rare-page .to-top,
  .rare-earth-detail-page .to-top {
    bottom: calc(100px + env(safe-area-inset-bottom, 0px));
  }
}
