@font-face {
  font-family: Montserrat;
  src: url("./fonts/montserrat.ttf") format("truetype");
  font-display: swap;
  font-weight: 100 900;
}

@font-face {
  font-family: Newsreader;
  src: url("./fonts/newsreader.woff2") format("woff2");
  font-display: swap;
  font-weight: 200 800;
}

@font-face {
  font-family: "DM Sans";
  src: url("./fonts/dm-sans.woff2") format("woff2");
  font-display: swap;
  font-weight: 100 1000;
}

:root {
  color-scheme: light;
  --paper: #f7f2e8;
  --ink: #233326;
  --muted: #4e5849;
  --accent: #884219;
  --clay: #ffc38a;
  --line: #d8cfc0;
  --gutter: clamp(1.25rem, 5.55vw, 5.5rem);
  --serif: Newsreader, Georgia, serif;
  --sans: Montserrat, system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 1rem/1.6 var(--sans); }
img { display: block; max-width: 100%; }
a { color: inherit; text-underline-offset: .25em; }
a:focus-visible { outline: 2px solid currentColor; outline-offset: 5px; }
h1, h2, p { margin: 0; }
.wrap { width: min(100% - 2 * var(--gutter), 82rem); margin-inline: auto; }
.skip { position: fixed; z-index: 3; top: .75rem; left: .75rem; padding: .6rem 1rem; background: var(--paper); transform: translateY(-200%); }
.skip:focus { transform: none; }

.masthead-inner {
  display: flex;
  min-height: 5.4rem;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 2rem;
}

.brand { display: inline-flex; align-items: center; gap: .75rem; text-decoration: none; }
.brand img { border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.brand-text { display: grid; gap: .12rem; }
.brand strong { font: 550 1.85rem/.95 var(--serif); letter-spacing: -.045em; }
.brand small { color: var(--muted); font-size: .735rem; line-height: 1.15; }
nav { display: flex; align-items: center; gap: clamp(1.1rem, 3.1vw, 3rem); }
nav a { white-space: nowrap; text-decoration: none; font-size: .92rem; font-weight: 650; }
nav a:hover { text-decoration: underline; }

.hero { position: relative; isolation: isolate; display: grid; align-items: center; min-height: clamp(32rem, 46vw, 44rem); color: var(--paper); background: #293123; }
.hero::after {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  background: linear-gradient(90deg, rgba(19, 23, 13, .86), rgba(19, 23, 13, .66) 43%, rgba(19, 23, 13, .05) 85%);
}
.hero-image { position: absolute; z-index: -2; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 51%; }
.hero-inner { padding-block: clamp(4rem, 7vw, 6.5rem); }
.eyebrow { font-size: .875rem; font-weight: 750; line-height: 1.3; letter-spacing: .135em; text-transform: uppercase; }
.hero-place { display: flex; align-items: center; gap: .75rem; margin-bottom: 1.8rem; color: #ffdaa9; }
.hero-place::before { content: ""; width: 1.8rem; height: 1px; background: currentColor; }

h1, h2 { font-family: var(--serif); font-weight: 420; letter-spacing: -.045em; text-wrap: balance; }
h1 { max-width: 9em; white-space: pre-line; font-size: clamp(3.6rem, 8.05vw, 7.65rem); line-height: .92; }
h2 { font-size: clamp(2.7rem, 5vw, 4.6rem); line-height: 1; }

.hero-intro { max-width: 29rem; margin-top: 1.3rem; font-size: clamp(1.05rem, 1.4vw, 1.2rem); color: #f2eadb; }
.button { display: inline-flex; min-height: 3rem; align-items: center; justify-content: center; padding: .7rem 1.25rem; font-size: .95rem; font-weight: 750; text-decoration: none; }
.button-hero { margin-top: 1.7rem; background: var(--clay); color: #342418; }
.button-hero:hover { background: #ffdaa9; }

.farm {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, .85fr);
  gap: clamp(1rem, 6vw, 6.5rem);
  align-items: end;
  padding-block: clamp(3.5rem, 7.25vw, 7rem);
}

.section-label { color: var(--accent); margin-bottom: 1rem; }
.farm h2 { max-width: 13ch; text-wrap: pretty; }
.farm-story { max-width: 34rem; padding-bottom: .18rem; color: var(--muted); font-size: clamp(1.08rem, 1.53vw, 1.28rem); }

.products { display: grid; grid-template-columns: 1.14fr 1fr; background: #253b2c; color: var(--paper); }
.product-photo { position: relative; min-height: 20rem; }
.product-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.product-copy { padding: clamp(2.25rem, 5.25vw, 5.25rem); }
.product-copy h2 { font-size: clamp(2.9rem, 4.5vw, 4.25rem); text-wrap: pretty; }
.product-label { color: var(--clay); margin-bottom: 1.15rem; }
.product-copy h2 + p { margin-top: .85rem; color: #ede3d5; font-size: 1.075rem; }
.store-link { margin-top: 1.7rem; }
.store-link { color: #352619; background: var(--clay); }
.store-link:hover { background: #ffdaa9; }

.footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  margin-top: clamp(3rem, 6.1vw, 5.75rem);
  border-top: 1px solid var(--line);
  padding-block: 1.65rem 2rem;
}
.footer-links { display: flex; flex-wrap: wrap; gap: .75rem 1.4rem; font-size: .94rem; }
.footer-links a:hover { color: var(--accent); }
.map-label { color: var(--muted); }

@media (max-width: 48rem) {
  .farm { grid-template-columns: 1fr; gap: .9rem; }
  .products { grid-template-columns: 1fr; }
  .product-photo { min-height: 0; aspect-ratio: 16/10; }
}

@media (max-width: 38rem) {
  .masthead-inner { display: grid; gap: .85rem; padding-block: .85rem .75rem; }
  nav { gap: 1.6rem; }
  .hero { min-height: 35rem; align-items: end; }
  .hero-image { object-position: 64% 50%; }
  .hero::after { background: linear-gradient(0deg, rgba(17, 22, 14, .92), rgba(17, 22, 14, .56) 62%, rgba(17, 22, 14, .04) 100%); }
  .hero-inner { padding-block: 9rem 2.75rem; }
  .hero-place { margin-bottom: 1.25rem; }
  h1 { font-size: clamp(3rem, 11.35vw, 4.5rem); }
  .footer { align-items: flex-start; flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

/* Interior pages and homepage links */
nav { gap: clamp(.8rem, 2.15vw, 2.35rem); }
nav a[aria-current="page"] { color: var(--accent); text-decoration: underline; }
.text-link { display: inline-block; color: var(--accent); font-size: .96rem; font-weight: 750; }
.text-link:hover { color: var(--ink); }
.farm-story .text-link { margin-top: .85rem; }

.home-features { padding-top: clamp(3.5rem, 7vw, 6rem); }
.home-features h2 { margin-bottom: 1.5rem; }
.feature-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(1rem, 3vw, 2.5rem); }
.feature { border: 1px solid var(--line); }
.feature a { display: block; height: 100%; text-decoration: none; }
.feature a:hover h3 { text-decoration: underline; }
.feature-photo { width: 100%; height: auto; aspect-ratio: 16/8; object-fit: cover; background: #253b2c; }
.feature-copy { padding: clamp(1.1rem, 3.2vw, 2.35rem); }
.feature h3, .detail-grid h3 { margin: 0 0 .4rem; font: 520 clamp(1.6rem, 2.55vw, 2.25rem)/1.05 var(--serif); letter-spacing: -.035em; }
.feature p, .detail-grid p { color: var(--muted); }

.page-hero {
  display: grid;
  grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr);
  gap: clamp(2rem, 6.2vw, 6.5rem);
  align-items: center;
  padding-block: clamp(2.75rem, 6vw, 6rem);
}
.page-intro h1 { max-width: 11.5ch; font-size: clamp(3.55rem, 6.55vw, 6.5rem); line-height: .95; text-wrap: pretty; }
.page-lead { max-width: 31rem; margin-top: 1.2rem; color: var(--muted); font-size: clamp(1.1rem, 1.55vw, 1.27rem); }
.page-figure { margin: 0; }
.page-photo { width: 100%; height: auto; aspect-ratio: 3/2; object-fit: cover; background: #253b2c; }
.page-figure figcaption { margin-top: .45rem; color: var(--muted); font-size: .79rem; }

.detail-section { border-top: 1px solid var(--line); padding-top: clamp(2rem, 5vw, 4rem); }
.detail-section h2, .contact-location h2 { font-size: clamp(2.35rem, 4vw, 3.65rem); }
.detail-section h2 { margin-bottom: 1.5rem; }
.detail-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  list-style: none;
  gap: clamp(1.1rem, 3vw, 2.5rem);
  margin: 0;
  padding: 0;
}
.detail-grid li { border-top: 1px solid var(--line); padding-top: 1rem; }
.detail-steps { grid-template-columns: repeat(4, minmax(0, 1fr)); counter-reset: step; }
.detail-steps li { counter-increment: step; }
.detail-steps li::before {
  content: counter(step) ".";
  display: block;
  margin-bottom: .5rem;
  color: var(--accent);
  font-size: .95rem;
  font-weight: 750;
}
.farm-motto {
  background: #253b2c;
  color: var(--paper);
  margin-top: clamp(2.5rem, 5vw, 4.5rem);
  padding: clamp(1.5rem, 4vw, 3.75rem);
  font: 420 clamp(2.3rem, 4vw, 3.85rem)/1 var(--serif);
}
.page-next { margin-top: 2rem; }
.callout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.3rem 2rem;
  margin-top: clamp(2.5rem, 5vw, 4.5rem);
  padding: clamp(1.5rem, 4vw, 3.75rem);
  background: #eee5d6;
}
.callout h2 { margin-bottom: .4rem; font-size: clamp(2rem, 3.6vw, 3.3rem); }
.callout p { color: var(--muted); }
.button-dark { align-self: flex-start; background: #253b2c; color: var(--paper); white-space: normal; }
.button-dark:hover { background: #3b5441; }
.button-dark:focus-visible { outline-color: var(--ink); }
.contact-actions { display: flex; align-items: center; flex-wrap: wrap; gap: .75rem 1.25rem; }

.contact {
  display: grid;
  grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr);
  gap: clamp(2.5rem, 7vw, 7rem);
  align-items: start;
  padding-top: clamp(2.75rem, 6vw, 6rem);
}
.contact-intro .button { margin-top: 1.4rem; }
.phone { margin-top: .65rem; color: var(--muted); }
.contact-location address { margin-top: .8rem; font-style: normal; }
.contact-location .text-link { margin-top: .8rem; }
.map { display: block; width: 100%; height: clamp(18rem, 36vw, 25rem); margin-top: 1rem; border: 1px solid var(--line); background: #eee5d6; }

@media (max-width: 54rem) {
  .masthead-inner { flex-wrap: wrap; gap: .65rem 1.25rem; padding-block: .7rem; }
  nav { flex-wrap: wrap; gap: .25rem 1.15rem; }
  nav a { display: inline-flex; min-height: 2.4rem; align-items: center; }
  .page-hero, .contact { grid-template-columns: 1fr; }
  .page-intro h1 { max-width: 16ch; }
  .detail-grid, .detail-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 33rem) {
  .masthead-inner { gap: .5rem; }
  nav { column-gap: .5rem; justify-content: space-between; }
  nav a { font-size: .875rem; }
  .feature-grid, .detail-grid { grid-template-columns: 1fr; }
  .callout { flex-direction: column; align-items: flex-start; }
}

.header-actions { display: flex; align-items: center; gap: .65rem; }
.cart-link, .language-picker summary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .45rem;
  min-height: 2.6rem;
  padding: .35rem .65rem;
  border: 1px solid var(--line);
  font-size: .875rem;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}
.cart-link:hover, .cart-link[aria-current], .language-picker summary:hover { border-color: var(--muted); }
.cart-link span {
  min-width: 1.25rem;
  border-radius: 1rem;
  padding-inline: .2rem;
  color: var(--paper);
  background: #253b2c;
  font-size: .73rem;
  text-align: center;
}
.language-picker { position: relative; }
.language-picker summary { cursor: pointer; list-style: none; }
.language-picker summary::-webkit-details-marker { display: none; }
.language-picker summary::after {
  content: "";
  width: .38rem;
  height: .38rem;
  border: solid currentColor;
  border-width: 0 1px 1px 0;
  transform: translateY(-.12rem) rotate(45deg);
}
.language-picker summary:focus-visible { outline: 2px solid currentColor; outline-offset: 4px; }
.language-picker ul {
  position: absolute;
  z-index: 3;
  top: calc(100% + .35rem);
  right: 0;
  min-width: 11rem;
  margin: 0;
  padding: .35rem;
  border: 1px solid var(--line);
  background: var(--paper);
  box-shadow: 0 .5rem 1rem #2333261a;
  list-style: none;
}
.language-picker a { display: block; padding: .5rem .6rem; font-size: .9rem; text-decoration: none; }
.language-picker a:hover, .language-picker a[aria-current] { background: #eee5d6; }
.masthead-inner nav { gap: clamp(.65rem, 1.65vw, 1.6rem); }

.shop-hero { padding-bottom: clamp(2.25rem, 4vw, 3.75rem); }
.shop-hero .page-photo { aspect-ratio: 16 / 8; }
.shop-section { border-top: 1px solid var(--line); padding-top: 2rem; }
.shop-heading { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 1rem; margin-bottom: 1.5rem; }
.shop-heading h2 { font-size: clamp(2.5rem, 4.5vw, 3.75rem); }
.shop-heading p { margin-top: .35rem; color: var(--muted); }
.shop-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(1rem, 2.8vw, 2.25rem); }
.shop-item { display: flex; flex-direction: column; border: 1px solid var(--line); min-width: 0; }
.shop-photo { width: 100%; height: auto; aspect-ratio: 3/2; object-fit: cover; background: #eee5d6; }
.shop-copy { display: flex; flex-direction: column; flex: 1; padding: clamp(.9rem, 2vw, 1.6rem); }
.shop-copy h3, .cart-row h2 { margin: .25rem 0 .5rem; font: 520 clamp(1.65rem, 2.55vw, 2.15rem)/1.05 var(--serif); letter-spacing: -.035em; text-wrap: pretty; }
.shop-weight { font-size: .85rem; font-weight: 750; color: var(--accent); }
.shop-description { flex: 1; margin-bottom: 1rem; color: var(--muted); }
.shop-price { font-size: 1.13rem; font-weight: 750; }
.add-form { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: .25rem .55rem; margin-top: .85rem; }
.add-form label { grid-column: 1 / -1; font-size: .88rem; color: var(--muted); }
.add-form input, .cart-controls input { width: 4.25rem; min-height: 3rem; padding: .3rem .4rem; border: 1px solid var(--line); background: var(--paper); color: var(--ink); font: inherit; }
.add-form .button { border: 0; padding-inline: .55rem; min-width: 0; cursor: pointer; }
.add-form .button:disabled { opacity: .55; cursor: default; }
.shop-feedback { min-height: 1.25em; margin-top: .35rem; color: var(--accent); font-size: .85rem; }
.cart-page { padding-top: clamp(3rem, 7vw, 5rem); max-width: 60rem; }
.cart-page > h1 { margin-bottom: 1.25rem; font-size: clamp(3.35rem, 6vw, 5.65rem); }
.cart-row { display: grid; grid-template-columns: 6rem 1fr auto; align-items: center; gap: 1rem; padding-block: 1.1rem; border-top: 1px solid var(--line); }
.cart-photo { width: 6rem; height: 4.5rem; object-fit: cover; }
.cart-description p { color: var(--muted); }
.cart-controls { display: flex; align-items: center; gap: .85rem; flex-wrap: wrap; }
.cart-controls label { display: flex; align-items: center; gap: .4rem; font-size: .85rem; }
.line-price { min-width: 4.6em; text-align: right; }
.remove-item { border: 0; padding: .35rem; background: transparent; color: var(--accent); font: inherit; text-decoration: underline; cursor: pointer; }
.cart-total { padding: 1.1rem 1.3rem; background: #eee5d6; }
.cart-total p:first-child { display: flex; justify-content: space-between; gap: .75rem; font-size: 1.15rem; }
.cart-total p + p { color: var(--muted); margin-top: .35rem; }
.cart-feedback { margin-block: .5rem; color: var(--accent); }

@media (max-width: 66rem) {
  .masthead-inner { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .5rem 1rem; padding-block: .75rem .55rem; }
  .masthead-inner nav { grid-row: 2; grid-column: 1 / -1; }
  .header-actions { grid-row: 1; grid-column: 2; }
}
@media (max-width: 53rem) {
  .shop-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cart-row { grid-template-columns: 5rem 1fr; }
  .cart-controls { grid-column: 2; }
}
@media (max-width: 35rem) {
  .masthead-inner nav { justify-content: flex-start; column-gap: .42rem; }
  .masthead-inner nav a { font-size: .84rem; min-height: 2.15rem; }
  .masthead .brand { gap: .5rem; }
  .masthead .brand img { width: 2.3rem; height: 2.3rem; }
  .masthead .brand strong { font-size: 1.55rem; }
  .masthead .brand small { font-size: .67rem; }
  .header-actions { gap: .35rem; }
  .cart-link, .language-picker summary { padding-inline: .4rem; }
  .shop-grid { grid-template-columns: 1fr; }
  .cart-controls { grid-column: 1 / -1; justify-content: space-between; }
}
.language-flag { display: inline-block; flex: 0 0 auto; width: 1.3rem; height: .87rem; border-radius: 2px; outline: 1px solid #2333262b; }
.language-picker li a { display: flex; align-items: center; gap: .65rem; }
.shop-copy h3 a { text-decoration: none; }
.shop-copy h3 a:hover { text-decoration: underline; }
.product-detail h1 { margin-top: .8rem; }
.product-detail-weight { margin-top: 1rem; font-size: 1.12rem; }
.product-detail .add-form { max-width: 24rem; }
.product-detail-demo { color: var(--muted); margin-block: .7rem; }
.shop-categories, .detail-sizes ul { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; margin: 0; padding: 0; }
.shop-categories a, .detail-sizes a { display: block; padding: .45rem .8rem; border: 1px solid var(--line); text-decoration: none; }
.shop-categories a:hover, .detail-sizes a:hover, .detail-sizes a[aria-current] { background: #253b2c; color: var(--paper); }
.shop-category { padding-top: clamp(2rem, 4vw, 4rem); }
.shop-category > h3 { margin: 0 0 1rem; font: 500 clamp(2rem, 4vw, 3rem)/1 var(--serif); letter-spacing: -.035em; }
.catalog-size { margin-top: 1rem; }
.detail-sizes { margin-top: 1rem; }
.detail-sizes p { font-weight: 650; margin-bottom: .35rem; }
.catalog-placeholder { display: grid; place-items: center; background: #eee5d6; }
.catalog-placeholder img { border-radius: 50%; opacity: .78; }
.product-figure img.page-photo { object-fit: contain; max-height: 34rem; background: #eee5d6; }
.cart-row-no-photo .cart-description { grid-column: 1 / 3; }
.shop-item img.shop-photo { object-fit: contain; background: #eee5d6; }

.cart-checkout { margin-top: .9rem; }
.merchant-page h1 { max-width: none; }
.merchant-form { display: grid; gap: 1rem; margin-top: 1rem; max-width: 40rem; }
.merchant-form[hidden], .merchant-form [hidden] { display: none; }
.merchant-form label { display: grid; gap: .35rem; font-weight: 650; }
.merchant-form input, .merchant-form select, .merchant-form textarea { font: inherit; padding: .6rem .75rem; width: 100%; border: 1px solid var(--line); background: var(--paper); color: var(--ink); }
.merchant-form fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 1rem; }
.merchant-form ul { margin: 0; padding: 0 0 0 1.25rem; }
.merchant-total, .merchant-test { background: #eee5d6; padding: .85rem 1rem; }
.merchant-total { display: flex; justify-content: space-between; gap: .5rem; }
.merchant-back { margin-top: 1.15rem; margin-right: .6rem; }
.merchant-page button { border: 0; cursor: pointer; }
.merchant-page button:disabled { opacity: .65; cursor: wait; }
[data-order-reference] { margin-top: .6rem; overflow-wrap: anywhere; }
.shipping-summary { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .35rem .75rem; }

.site-motto { font-size: .88rem; font-weight: 600; margin-top: .35rem; }
.slow-food { padding-block: 2.5rem; border-top: 1px solid var(--line); }
.slow-food h2 { font-size: 1.75rem; margin-bottom: .5rem; }
.slow-food p { max-width: 42rem; }

.shop-assurances { display: flex; flex-wrap: wrap; gap: .4rem 1.5rem; margin: 0 0 1.5rem; color: var(--muted); font-size: .9rem; }
