@font-face { font-family: "Source Serif 4"; font-weight: 600; font-display: swap; src: url(../fonts/source-serif-4-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: "Source Serif 4"; font-weight: 700; font-display: swap; src: url(../fonts/source-serif-4-latin-700-normal.woff2) format("woff2"); }
@font-face { font-family: "Nunito Sans"; font-weight: 400; font-display: swap; src: url(../fonts/nunito-sans-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: "Nunito Sans"; font-weight: 600; font-display: swap; src: url(../fonts/nunito-sans-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: "Nunito Sans"; font-weight: 700; font-display: swap; src: url(../fonts/nunito-sans-latin-700-normal.woff2) format("woff2"); }
@font-face { font-family: "Kaushan Script"; font-weight: 400; font-display: swap; src: url(../fonts/kaushan-script-latin-400-normal.woff2) format("woff2"); }

:root {
  --bg: #fbf7f1;
  --panel: #f3eee6;
  --ink: #1f1b18;
  --ink-soft: #4a433d;
  --muted: #6f665e;
  --red: #c8462b;
  --red-dark: #a8371f;
  --sage: #a9a68a;
  --sage-dark: #7f7c62;
  --line: #e6dfd4;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans: "Nunito Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --script: "Kaushan Script", "Brush Script MT", cursive;
  --radius: 14px;
  --wrap: 1200px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 1.0625rem/1.6 var(--sans); }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--serif); font-weight: 700; line-height: 1.1; margin: 0 0 .5em; letter-spacing: -.01em; }
p { margin: 0 0 1em; }
svg { width: 1.25em; height: 1.25em; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 10; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; border-radius: 4px; }

/* Header */
.site-header { background: var(--bg); position: relative; z-index: 3; }
.header-inner { display: flex; align-items: center; gap: 24px; min-height: 96px; padding-top: 10px; padding-bottom: 10px; }
.brand img { width: clamp(150px, 22vw, 230px); }
.main-nav { display: flex; gap: clamp(16px, 4vw, 56px); margin-left: auto; }
.main-nav a { text-decoration: none; font-size: 1.05rem; padding: 6px 0; border-bottom: 2px solid transparent; }
.main-nav a:hover { color: var(--red); }
.main-nav a[aria-current] { color: var(--red); font-weight: 700; border-bottom-color: var(--red); }
.header-tools { display: flex; align-items: center; gap: 14px; margin-left: clamp(8px, 3vw, 48px); }
.icon-btn { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; text-decoration: none; }
.icon-btn svg { width: 24px; height: 24px; stroke-width: 2; }
.icon-btn:hover { background: var(--panel); }
.lang-switch { display: inline-flex; border: 1.5px solid var(--line); border-radius: 999px; padding: 3px; text-decoration: none; font-size: .8rem; font-weight: 700; letter-spacing: .04em; }
.lang-switch span { padding: 3px 9px; border-radius: 999px; color: var(--muted); }
.lang-switch span.on { background: var(--red); color: #fff; }
.lang-switch:hover { border-color: var(--red); }

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: 10px; background: var(--red); color: #fff; border: 2px solid var(--red); border-radius: 999px; padding: .8em 1.6em; font: 600 1.05rem var(--sans); text-decoration: none; cursor: pointer; transition: background .15s, transform .15s; }
.btn:hover { background: var(--red-dark); border-color: var(--red-dark); }
.btn:active { transform: translateY(1px); }
.btn-outline { background: transparent; color: var(--red); }
.btn-outline:hover { background: #fff; color: var(--red-dark); }

/* Hero (home + recipe) */
.hero, .recipe-hero { position: relative; overflow: hidden; }
.hero-photo { position: absolute; inset: 0 0 0 auto; width: 56%; }
.hero-photo img { width: 100%; height: 100%; object-fit: cover; -webkit-mask-image: linear-gradient(to right, transparent 0, #000 22%); mask-image: linear-gradient(to right, transparent 0, #000 22%); }
.photo-note { position: absolute; right: 12px; bottom: 12px; background: rgba(31,27,24,.6); color: #fff; font-size: .75rem; padding: 3px 10px; border-radius: 999px; }
.hero-inner { position: relative; min-height: 560px; display: flex; align-items: center; }
.hero-text { max-width: 560px; padding: 56px 0; }
.hero-text > p, .recipe-hero .lead { max-width: 30em; }
.hero h1 { font-size: clamp(2.8rem, 6vw, 5rem); line-height: 1; }
.hero-text > p { font-size: clamp(1.15rem, 2vw, 1.5rem); color: var(--ink-soft); line-height: 1.4; margin-bottom: 1.4em; }
.recipe-hero .hero-inner { min-height: 470px; }
.recipe-hero h1 { font-size: clamp(2.2rem, 4.6vw, 3.6rem); }
.recipe-hero .lead { font-size: 1.15rem; color: var(--ink-soft); max-width: 27em; }
.doodle-heart { display: inline-block; width: .5em; height: .58em; margin-left: .15em; vertical-align: top; fill: none; stroke: var(--red); stroke-width: 2.6; transform: rotate(14deg); }
.crumbs { font-size: .9rem; color: var(--muted); margin-bottom: .8em; }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--red); text-decoration: underline; }

.facts { list-style: none; padding: 0; margin: 0 0 1.6em; display: flex; flex-wrap: wrap; gap: 0; }
.facts li { display: flex; align-items: center; gap: 8px; padding: 0 22px; border-left: 1.5px solid var(--line); }
.facts li:first-child { padding-left: 0; border-left: 0; }
.facts svg { width: 26px; height: 26px; }
.actions { display: flex; flex-wrap: wrap; gap: 14px; }
.share-menu { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.share-menu[hidden] { display: none; }
.share-menu a, .share-menu button { background: #fff; border: 1.5px solid var(--line); border-radius: 999px; padding: .45em 1.1em; font: 600 .95rem var(--sans); text-decoration: none; cursor: pointer; color: var(--ink); }
.share-menu a:hover, .share-menu button:hover { border-color: var(--red); color: var(--red); }

/* Badges */
.badge { display: grid; place-items: center; width: 84px; height: 84px; border-radius: 50%; background: var(--sage); color: #fff; flex: none; }
.badge svg { width: 40px; height: 40px; stroke-width: 1.4; }

/* Sections + cards */
.section { padding-top: 40px; padding-bottom: 40px; }
.section-title { font-size: 2rem; }
.page-head h1 { font-size: clamp(2.4rem, 5vw, 3.6rem); }
.page-head > p { color: var(--ink-soft); font-size: 1.15rem; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 28px; }
.card { background: #fff; border-radius: var(--radius); overflow: hidden; text-decoration: none; box-shadow: 0 1px 2px rgba(31,27,24,.06), 0 8px 24px rgba(31,27,24,.06); transition: transform .15s, box-shadow .15s; display: flex; flex-direction: column; }
.card:hover { transform: translateY(-3px); box-shadow: 0 2px 4px rgba(31,27,24,.08), 0 14px 32px rgba(31,27,24,.1); }
.card img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.card-body { padding: 18px 20px 20px; }
.card h3 { font-size: 1.35rem; margin: .35em 0 .5em; }
.card .meta { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: .92rem; margin: 0; }
.card .meta .sep { width: 4px; height: 4px; border-radius: 50%; background: var(--line); margin: 0 6px; }
.card .meta svg { width: 18px; height: 18px; }
.tag { display: inline-block; background: var(--panel); color: var(--sage-dark); font-weight: 700; font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; padding: 3px 10px; border-radius: 999px; }
.card[hidden] { display: none; }

.search-box { display: flex; align-items: center; gap: 10px; background: #fff; border: 1.5px solid var(--line); border-radius: 999px; padding: 0 20px; max-width: 560px; margin: 24px 0 18px; scroll-margin-top: 24px; }
.search-box:focus-within { border-color: var(--red); }
.search-box svg { color: var(--muted); }
.search-box input { border: 0; background: transparent; font: inherit; padding: 14px 0; width: 100%; outline: none; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip { background: transparent; border: 1.5px solid var(--line); border-radius: 999px; padding: .45em 1.2em; font: 600 .95rem var(--sans); cursor: pointer; color: var(--ink-soft); }
.chip:hover { border-color: var(--red); color: var(--red); }
.chip.on { background: var(--red); border-color: var(--red); color: #fff; }
.no-results { color: var(--muted); font-size: 1.1rem; }

/* Recipe body */
.recipe-body { display: grid; grid-template-columns: minmax(280px, 400px) 1fr; gap: 40px; padding-top: 28px; padding-bottom: 28px; align-items: start; }
.panel { background: var(--panel); border-radius: var(--radius); padding: 24px 24px 18px; }
.recipe-body > * { min-width: 0; }
.panel-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.panel-head h2, .method h2 { font-size: 1.85rem; margin: 0; }
.method h2 { margin-bottom: .6em; }
.servings-select { position: relative; display: inline-flex; align-items: center; }
.servings-select select { appearance: none; -webkit-appearance: none; background: #e7e1d6; border: 0; border-radius: 999px; padding: 7px 34px 7px 16px; font: 600 .9rem var(--sans); color: var(--ink); cursor: pointer; }
.servings-select svg { position: absolute; right: 11px; width: 16px; height: 16px; pointer-events: none; stroke-width: 2.2; }
.ing-list { list-style: none; margin: 0; padding: 0; }
.ing-list li { display: grid; grid-template-columns: 7.5em 1fr; gap: 12px; padding: 7px 0; border-bottom: 1px solid var(--line); }
.ing-list li:last-child { border-bottom: 0; }
.ing-list .amt { color: var(--ink-soft); }
.steps { list-style: none; margin: 0; padding: 0; }
.steps li { display: flex; gap: 20px; align-items: flex-start; padding: 8px 0 14px; scroll-margin-top: 20px; }
.steps li:target p { background: #fff3d6; border-radius: 6px; }
.steps .num { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--sage); color: #fff; font: 700 1.1rem var(--sans); flex: none; }
.steps p { margin: 0; padding-top: 6px; color: var(--ink-soft); }
.tips { display: grid; grid-template-columns: auto auto 1fr; gap: 20px; align-items: center; background: var(--panel); border-radius: var(--radius); padding: 18px 22px; margin-top: 18px; }
.tips .badge { width: 64px; height: 64px; }
.tips .badge svg { width: 32px; height: 32px; }
.tips h3 { font: 400 1.9rem/1 var(--script); color: var(--red); margin: 0; transform: rotate(-4deg); white-space: nowrap; }
.tips p { margin: 0; font-size: .95rem; color: var(--ink-soft); }

.more { display: flex; align-items: center; gap: 24px; background: linear-gradient(90deg, #fff 55%, var(--panel)); border-radius: var(--radius); padding: 22px 32px; margin-bottom: 48px; box-shadow: 0 1px 2px rgba(31,27,24,.05); }
.more > div { flex: 1; }
.more h2 { font-size: 1.75rem; margin-bottom: .15em; }
.more p { margin: 0; color: var(--ink-soft); }
.more-icon svg { width: 48px; height: 48px; color: var(--sage-dark); stroke-width: 1.3; }

/* About */
.about { display: grid; grid-template-columns: minmax(200px, 360px) 1fr; gap: 56px; align-items: center; }
.about h1 { font-size: clamp(2.4rem, 5vw, 3.6rem); }
.about p { font-size: 1.15rem; color: var(--ink-soft); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); margin-top: 24px; }
.footer-inner { display: flex; flex-direction: column; align-items: center; text-align: center; padding-top: 36px; padding-bottom: 36px; color: var(--muted); }
.footer-inner img { width: 140px; margin-bottom: 12px; }
.footer-inner p { margin: 0 0 .3em; }
.small { font-size: .85rem; }

/* Tablet / phone */
@media (max-width: 900px) {
  .recipe-body { grid-template-columns: 1fr; }
  .about { grid-template-columns: 1fr; gap: 24px; }
  .about img { max-width: 260px; }
}
@media (max-width: 760px) {
  .header-inner { flex-wrap: wrap; gap: 4px 12px; min-height: 0; }
  .brand img { width: 150px; }
  .header-tools { margin-left: auto; }
  .main-nav { order: 3; width: 100%; margin-left: 0; gap: 22px; overflow-x: auto; }
  .hero-photo { position: relative; width: 100%; height: 240px; }
  .hero-photo img { -webkit-mask-image: linear-gradient(to bottom, #000 70%, transparent); mask-image: linear-gradient(to bottom, #000 70%, transparent); }
  .hero-inner, .recipe-hero .hero-inner { min-height: 0; }
  .hero-text { padding: 8px 0 28px; }
  .facts li { padding: 0 14px; }
  .tips { grid-template-columns: auto 1fr; }
  .tips p { grid-column: 1 / -1; }
  .more { flex-direction: column; align-items: flex-start; padding: 22px; }
  .ing-list li { grid-template-columns: 6.5em 1fr; }
  .panel { padding: 20px 18px 14px; }
  .panel-head h2, .method h2 { font-size: 1.6rem; }
}

/* Print: just the recipe */
@media print {
  @page { margin: 16mm; }
  body { background: #fff; font-size: 11pt; color: #000; }
  .site-header .main-nav, .header-tools, .actions, .share-menu, .crumbs, .more, .site-footer, .servings-select svg, .photo-note, .doodle-heart, .skip { display: none !important; }
  .header-inner { min-height: 0; padding: 0; }
  .brand img { width: 120px; }
  .hero-photo { position: static; width: 45%; float: right; margin: 0 0 12px 20px; }
  .hero-photo img { -webkit-mask-image: none; mask-image: none; border-radius: 8px; }
  .hero-inner, .recipe-hero .hero-inner { min-height: 0; display: block; padding: 0; }
  .hero-text { padding: 8px 0; max-width: none; }
  .recipe-hero h1 { font-size: 24pt; }
  .recipe-body { display: block; padding: 0; clear: both; }
  .panel, .tips { background: none; border: 1px solid #ccc; break-inside: avoid; }
  .servings-select select { background: none; padding: 0; }
  .method { margin-top: 16px; }
  .steps li { break-inside: avoid; padding: 4px 0 8px; }
  .steps .num { width: 26px; height: 26px; font-size: 10pt; background: none; color: #000; border: 1.5px solid #000; }
  .tips .badge { display: none; }
  .tips { grid-template-columns: 1fr; }
  .tips h3 { transform: none; margin-bottom: 6px; }
  a { text-decoration: none; }
}
