:root {
  --ink: #2d211c;
  --muted: #6f625b;
  --cream: #fbf7ef;
  --paper: #fffdf8;
  --rust: #9b3f22;
  --rust-dark: #73301c;
  --gold: #d8943b;
  --sage: #5d6e54;
  --line: #e6d9ca;
  --shadow: 0 18px 60px rgba(69, 40, 24, .12);
  --serif: Georgia, 'Times New Roman', serif;
  --sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 100px; }
body { margin: 0; color: var(--ink); background: var(--cream); font-family: var(--sans); font-size: 1rem; line-height: 1.7; }
body::before { content: ''; position: fixed; inset: 0; pointer-events: none; opacity: .22; background-image: url('../img/bg-section.jpg'); z-index: -1; }
img { display: block; max-width: 100%; height: auto; }
a { color: var(--rust); text-underline-offset: .2em; }
a:hover { color: var(--rust-dark); }
button, input, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.shell { width: min(1180px, calc(100% - 40px)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; left: 1rem; top: -5rem; z-index: 100; padding: .7rem 1rem; color: white; background: var(--ink); border-radius: .4rem; }
.skip-link:focus { top: 1rem; }
.anchor { position: absolute; top: 0; }

.site-header { position: sticky; top: 0; z-index: 50; height: 88px; background: rgba(251,247,239,.94); border-bottom: 1px solid rgba(155,63,34,.12); backdrop-filter: blur(14px); }
.nav-shell { width: min(1240px, calc(100% - 40px)); height: 100%; margin: auto; display: flex; align-items: center; }
.site-brand { position: absolute; left: 50%; top: -6px; transform: translateX(-50%); width: 180px; height: 140px; display: block; overflow: hidden; border-radius: 0 0 50% 50%; background: #ba5a31; box-shadow: 0 4px 0 rgba(103,102,102,.12), 0 12px 30px rgba(91,48,25,.16); }
.site-brand img { width: 180px; height: 140px; object-fit: fill; }
.site-menu { width: 100%; display: grid; grid-template-columns: repeat(2, auto) 1fr auto; gap: clamp(1.4rem, 4vw, 4rem); align-items: center; }
.site-menu a { color: var(--ink); font-size: .84rem; font-weight: 750; letter-spacing: .08em; text-decoration: none; text-transform: uppercase; }
.site-menu a:nth-child(3) { grid-column: 4; }
.site-menu a:hover { color: var(--rust); }
.shop-link { display: inline-flex; align-items: center; gap: .4rem; }
.shop-icon { font-size: 1.05em; line-height: 1; }
.menu-toggle { display: none; width: 46px; height: 46px; margin-left: auto; padding: 11px; border: 0; border-radius: 50%; color: var(--ink); background: transparent; cursor: pointer; }
.menu-toggle > span:not(.sr-only) { display: block; height: 2px; margin: 5px 0; background: currentColor; transition: transform .2s, opacity .2s; }

.recipe-section { position: relative; overflow: hidden; padding: clamp(4.5rem, 9vw, 8rem) 0; }
.recipe-section::before { content: ''; position: absolute; top: 120px; right: -190px; width: 480px; aspect-ratio: 1; border: 1px solid rgba(155,63,34,.16); border-radius: 50%; box-shadow: inset 0 0 0 45px var(--cream), inset 0 0 0 46px rgba(155,63,34,.1); z-index: -1; }
.section-title { margin-bottom: clamp(2.5rem, 5vw, 4.5rem); text-align: center; }
.section-title span, .preparation-aside > span { display: block; margin-bottom: .3rem; color: var(--rust); font-size: .75rem; font-weight: 800; letter-spacing: .2em; text-transform: uppercase; }
.section-title h1, .preparation h2 { margin: 0; font-family: var(--serif); font-size: clamp(2.8rem, 7vw, 5.6rem); font-weight: 500; line-height: .95; }
.section-title h1::after { content: ''; display: block; width: 56px; height: 3px; margin: 1.4rem auto 0; background: var(--gold); }
.recipe-intro { display: grid; grid-template-columns: minmax(0, 1.03fr) minmax(360px, .97fr); gap: clamp(2rem, 6vw, 6rem); align-items: start; }
.intro-copy { padding-top: 1rem; }
.intro-copy h2 { margin: 0 0 1.7rem; font-family: var(--serif); font-size: clamp(1.8rem, 3vw, 2.65rem); font-weight: 500; line-height: 1.22; }
.intro-copy p { color: var(--muted); }
.intro-copy p b { color: var(--ink); }
.media-stack { display: grid; gap: 1rem; }
.video-wrap { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: var(--ink); box-shadow: var(--shadow); }
.video-wrap iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.gallery { position: relative; aspect-ratio: 500 / 332; overflow: hidden; background: #d9c7b2; box-shadow: var(--shadow); }
.gallery-item { position: absolute; inset: 0; width: 100%; height: 100%; padding: 0; border: 0; opacity: 0; background: none; cursor: zoom-in; transition: opacity .35s ease; }
.gallery-item.is-active { opacity: 1; z-index: 1; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; }
.gallery-control { position: absolute; z-index: 3; top: 50%; width: 42px; height: 42px; border: 1px solid rgba(255,255,255,.6); border-radius: 50%; color: white; background: rgba(45,33,28,.55); transform: translateY(-50%); cursor: pointer; }
.gallery-prev { left: 14px; } .gallery-next { right: 14px; }
.gallery-dots { position: absolute; z-index: 3; left: 50%; bottom: 14px; display: flex; gap: 7px; transform: translateX(-50%); }
.gallery-dots span { width: 7px; height: 7px; border-radius: 50%; background: rgba(255,255,255,.55); }
.gallery-dots .is-active { width: 22px; border-radius: 20px; background: white; }

.lightbox { width: 100%; max-width: none; height: 100%; max-height: none; margin: 0; padding: 0; border: 0; color: white; background: transparent; overflow: hidden; }
.lightbox[open] { display: grid; place-items: center; }
.lightbox::backdrop { background: rgba(20,14,11,.94); backdrop-filter: blur(5px); }
.lightbox-frame { position: relative; display: grid; place-items: center; width: min(92vw, 1200px); height: 92vh; }
.lightbox figure { margin: 0; display: grid; place-items: center; width: 100%; height: 100%; }
.lightbox figure img { display: block; width: auto; max-width: 100%; height: auto; max-height: 88vh; object-fit: contain; box-shadow: 0 24px 80px rgba(0,0,0,.45); }
.lightbox button { position: absolute; z-index: 2; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.55); border-radius: 50%; color: white; background: rgba(20,14,11,.68); cursor: pointer; transition: background .2s, transform .2s; }
.lightbox button:hover { background: var(--rust); transform: scale(1.06); }
.lightbox-close { top: 0; right: 0; width: 50px; height: 50px; font-size: 2rem; line-height: 1; }
.lightbox-nav { top: 50%; width: 52px; height: 52px; font-size: 2.2rem; transform: translateY(-50%); }
.lightbox-nav:hover { transform: translateY(-50%) scale(1.06) !important; }
.lightbox-previous { left: 0; }
.lightbox-next { right: 0; }

.ingredients-grid { margin: clamp(5rem, 10vw, 9rem) 0; display: grid; grid-template-columns: 1.1fr repeat(3, 1fr); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.ingredients-grid > div { min-height: 280px; padding: clamp(1.4rem, 3vw, 2.5rem); border-left: 1px solid var(--line); }
.ingredients-grid > div:first-child { display: flex; align-items: center; padding-left: 0; border-left: 0; }
.ingredients-grid h2 { margin: 0; font-family: var(--serif); font-size: clamp(2rem, 3vw, 3.2rem); font-weight: 500; line-height: 1.1; }
.ingredient-card { position: relative; }
.ingredient-card:nth-child(3) { background: rgba(216,148,59,.1); }
.card-number { color: var(--rust); font-family: var(--serif); font-size: .9rem; }
.ingredient-card ul { margin: 3rem 0 0; padding: 0; list-style: none; }
.ingredient-card li { padding: .48rem 0; border-bottom: 1px solid rgba(155,63,34,.1); }

.preparation { display: grid; grid-template-columns: minmax(280px, .7fr) minmax(0, 1.3fr); gap: clamp(2rem, 7vw, 7rem); align-items: start; }
.preparation-aside { position: sticky; top: 130px; }
.preparation-aside h2 { margin-bottom: 2.5rem; font-size: clamp(2.5rem, 5vw, 4.5rem); }
.preparation-aside ul { padding: 1.5rem 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); list-style: none; }
.preparation-aside li + li { margin-top: .75rem; }
.preparation-copy { counter-reset: paragraphs; }
.preparation-copy > p { position: relative; min-height: 64px; margin: 0; padding: 1.4rem 0 1.4rem 4.6rem; border-top: 1px solid var(--line); color: var(--muted); counter-increment: paragraphs; }
.preparation-copy > p::before { content: counter(paragraphs, decimal-leading-zero); position: absolute; left: 0; top: 1.15rem; color: var(--rust); font-family: var(--serif); font-size: 1.5rem; }
.preparation-copy blockquote { margin: 1.7rem 0 0; padding: 2rem 2.2rem; color: white; background: var(--rust); font-family: var(--serif); font-size: 1.35rem; }
.more-recipes { margin-top: 5rem; padding: 2.4rem; border: 1px solid var(--line); background: rgba(255,253,248,.7); text-align: center; }
.more-recipes h2 { margin: 0; font-family: var(--serif); font-weight: 500; }

.button { display: inline-flex; gap: 2rem; justify-content: space-between; min-width: 180px; padding: .85rem 1.2rem; border: 0; color: var(--ink); background: white; text-decoration: none; cursor: pointer; transition: transform .2s, box-shadow .2s; }
.button:hover { color: var(--ink); transform: translateY(-2px); box-shadow: 0 12px 30px rgba(0,0,0,.15); }

.site-footer { color: rgba(255,255,255,.82); background: var(--ink); }
.footer-main { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 4rem; padding-top: 3.5rem; padding-bottom: 3.5rem; }
.footer-logo img { width: 180px; }
.footer-main h2 { margin: 0 0 1rem; color: white; font-family: var(--serif); font-size: 1.35rem; font-weight: 500; }
.footer-main div { display: flex; flex-direction: column; align-items: flex-start; }
.footer-main a { padding: .2rem 0; color: inherit; text-decoration: none; }
.footer-main a:hover { color: white; }
.footer-bottom { padding: 1rem 20px; color: var(--muted); background: var(--paper); font-size: .78rem; text-align: center; }
.footer-bottom a { color: inherit; }
.back-to-top { position: fixed; right: 20px; bottom: 20px; z-index: 30; width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; color: white; background: var(--rust); box-shadow: 0 8px 25px rgba(0,0,0,.15); text-decoration: none; opacity: 0; pointer-events: none; transform: translateY(12px); transition: .2s; }
.back-to-top.is-visible { opacity: 1; pointer-events: auto; transform: none; }

.legal-page { padding: clamp(4rem, 8vw, 7rem) 0; }
.legal-content { max-width: 900px; margin: auto; padding: clamp(1.4rem, 5vw, 4.5rem); background: var(--paper); box-shadow: var(--shadow); }
.legal-content > .section-heading h2, .legal-content > h1 { margin-top: 0; font-family: var(--serif); font-size: clamp(2.5rem, 6vw, 4.5rem); font-weight: 500; line-height: 1; }
.legal-content h2 { margin: 2.4rem 0 .6rem; font-family: var(--serif); font-size: 1.7rem; font-weight: 500; }
.legal-content p { color: var(--muted); overflow-wrap: anywhere; }
.error-page { min-height: 70vh; display: grid; place-items: center; padding: 3rem 20px; text-align: center; }
.error-page h1 { margin: 0; color: var(--rust); font-family: var(--serif); font-size: clamp(4rem, 12vw, 8rem); font-weight: 500; }

@media (max-width: 900px) {
  .site-header { height: 76px; }
  .site-brand { left: 14px; top: 0; width: 108px; height: 84px; transform: none; }
  .site-brand img { width: 108px; height: 84px; }
  .menu-toggle { display: block; }
  .site-menu { position: absolute; top: 76px; left: 0; width: 100%; display: none; grid-template-columns: 1fr; gap: 0; padding: 1rem 20px 1.3rem; background: var(--paper); border-bottom: 1px solid var(--line); box-shadow: 0 20px 30px rgba(45,33,28,.08); }
  .site-menu.is-open { display: grid; }
  .site-menu a, .site-menu a:nth-child(3) { grid-column: auto; padding: .72rem 0; }
  .recipe-intro { grid-template-columns: 1fr; }
  .media-stack { grid-template-columns: 1fr 1fr; }
  .ingredients-grid { grid-template-columns: 1fr 1fr; }
  .ingredients-grid > div:nth-child(3) { border-left: 0; }
  .ingredients-grid > div { min-height: auto; }
}

@media (max-width: 680px) {
  .shell { width: min(100% - 28px, 1180px); }
  .recipe-section { padding-top: 4rem; }
  .recipe-section::before { display: none; }
  .media-stack { grid-template-columns: 1fr; }
  .ingredients-grid { grid-template-columns: 1fr; }
  .ingredients-grid > div { padding: 1.5rem 0; border-left: 0; border-top: 1px solid var(--line); }
  .ingredients-grid > div:first-child { border-top: 0; }
  .ingredient-card:nth-child(3) { margin-inline: -14px; padding-inline: 14px; }
  .ingredient-card ul { margin-top: 1.2rem; }
  .lightbox-frame { width: 100vw; height: 100dvh; padding: 62px 10px 72px; }
  .lightbox figure img { max-height: calc(100dvh - 150px); }
  .lightbox-close { top: 10px; right: 12px; }
  .lightbox-nav { top: auto; bottom: 12px; transform: none; }
  .lightbox-nav:hover { transform: scale(1.06) !important; }
  .lightbox-previous { left: calc(50% - 64px); }
  .lightbox-next { right: calc(50% - 64px); }
  .preparation { grid-template-columns: 1fr; }
  .preparation-aside { position: static; }
  .footer-main { grid-template-columns: 1fr 1fr; gap: 2.5rem 1.5rem; }
  .footer-logo { grid-column: 1 / -1; }
  .footer-logo img { width: 150px; }
  .g-recaptcha { max-width: 100%; transform-origin: left top; transform: scale(.88); margin-bottom: -.8rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
