:root {
  color-scheme: light;
  --paper: #fbf6eb;
  --ink: #28291b;
  --green: #425626;
  --red: #a9321d;
  --line: #dcd0bc;
  font: 100%/1.6 system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
}
* { box-sizing: border-box; }
body { margin: 0; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 4px; }
.wrap { width: min(1180px, calc(100% - 48px)); margin-inline: auto; }
.top { border-bottom: 1px solid var(--line); }
.nav, .footer { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-block: 17px; }
nav { display: flex; gap: 24px; }
nav a:hover, .back:hover { text-decoration: underline; }
.brand, h1, h2, h3, .collection-grid strong { font-family: Georgia, serif; line-height: 1.08; }
.brand { font-size: clamp(1.2rem, 3vw, 1.75rem); font-weight: bold; }
.brand span, .back, .meta { color: var(--green); }
h1 { font-size: clamp(2.5rem, 7vw, 5.25rem); margin: 0 0 15px; letter-spacing: -.035em; overflow-wrap: anywhere; }
h2 { font-size: clamp(1.75rem, 4vw, 2.75rem); margin: 0 0 23px; letter-spacing: -.025em; }
h3 { font-size: 1.45rem; margin: 9px 0; }
p { margin: 0 0 1em; }
.hero { position: relative; display: grid; grid-template-columns: 1fr 1.08fr; overflow: hidden; min-height: 410px; margin-top: 24px; border: 1px solid var(--line); border-radius: 22px; background: #f4ead8; }
.hero-copy { z-index: 1; padding: clamp(25px, 5vw, 65px); align-self: center; }
.hero-copy p { font-size: clamp(1.05rem, 2.25vw, 1.35rem); }
.hero img { position: absolute; inset: 0 0 0 auto; width: 52%; height: 100%; object-fit: cover; object-position: center; }
form { display: flex; padding: 5px; border: 1px solid var(--line); border-radius: 14px; background: #fffaf2; }
input { min-width: 0; width: 100%; border: 0; border-radius: 8px; padding: 8px; background: transparent; }
form button { border: 0; border-radius: 10px; background: var(--red); color: white; padding: 8px 16px; }
.listing { margin-block: 32px 52px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 30px; }
.chips button, .portions button { border: 1px solid var(--green); border-radius: 999px; background: transparent; padding: 7px 13px; color: var(--green); }
.chips button[aria-pressed="true"], .chips button:hover { background: var(--green); color: white; }
.grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.card, .panel, .collection-grid a { min-width: 0; background: #fffaf2; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.card a { display: block; height: 100%; }
.card a:hover h3, .collection-grid a:hover strong { text-decoration: underline; }
.card a:focus-visible { outline-offset: -4px; }
.card img, .photo-placeholder { display: block; width: 100%; height: auto; aspect-ratio: 1.6; object-fit: cover; }
.photo-placeholder { display: grid; place-items: center; color: var(--green); background: #e9eddb; font-size: 4rem; }
.card-body { padding: 15px 18px; }
.card-body p { margin: 0; color: #514d41; }
.meta { display: flex; justify-content: space-between; gap: 8px; font-size: .875rem; font-weight: 650; }
.collection-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.collection-grid a { padding: 20px; }
.collection-grid span { display: block; margin-top: 7px; }
.collection-grid strong { font-size: 1.55rem; }
.recipe { padding-top: 24px; }
.back { display: inline-block; margin-bottom: 18px; }
.recipe-intro { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 28px; margin-bottom: 24px; }
.recipe-intro h1 { font-size: clamp(2.4rem, 6vw, 4.5rem); }
.recipe-photo { width: 100%; max-height: 360px; object-fit: cover; border-radius: 16px; }
.recipe-grid { display: grid; grid-template-columns: 1fr 1.4fr; gap: 20px; }
.panel { padding: 22px; }
.portions { display: flex; align-items: center; gap: 10px; }
.portions button { min-width: 44px; min-height: 44px; }
.portions button:disabled { opacity: .45; cursor: default; }
.ingredients { list-style: none; padding: 0; }
.ingredients li { display: flex; justify-content: space-between; gap: 8px; border-bottom: 1px solid var(--line); padding: 8px 0; }
.ingredients strong { white-space: nowrap; }
.steps { padding-left: 24px; }
.steps li { padding-left: 5px; margin-bottom: 12px; }
.steps li::marker { color: var(--green); font-weight: 700; }
.footer { margin-top: 48px; border-top: 1px solid var(--line); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
@media (max-width: 820px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .recipe-grid { grid-template-columns: 1fr; }
}
@media (max-width: 610px) {
  .wrap { width: calc(100% - 28px); }
  .nav, .footer { flex-wrap: wrap; gap: 8px 18px; }
  nav { gap: 14px; }
  .hero { display: flex; flex-direction: column; min-height: 0; }
  .hero-copy { width: 100%; padding: 24px 16px; }
  .hero-copy br { display: none; }
  .hero img { position: static; width: 100%; height: 208px; }
  .grid, .recipe-intro, .collection-grid { grid-template-columns: 1fr; }
  .recipe-photo { max-height: 275px; }
  .panel { padding: 17px; }
}
