/* The Family Recipe Book (Designer's homey spec, design/specs/recipe-book-homey.md, 11/27): a warm, plain food blog.
   Light only at launch. Colors are the `recipes` brand: red leads (links, buttons, step numbers), evergreen only for the
   recipe card's top line and small labels, oak only for the tip rule. 12px radius, 1px lines, no shadows, no gradients
   (the plaid line is the one pattern). Headings Young Serif, body Source Serif 4 at 18px/1.65, UI Inter. 48px targets. */
:root {
  --rb-paper: #fbf5ea; --rb-card: #fffdf8; --rb-ink: #2a211c; --rb-soft: #6b5b4f; --rb-line: #e6dccb;
  --rb-red: #a8322d; --rb-red-d: #8a2622; --rb-green: #2f5d47; --rb-oak: #8a5a2b; --rb-note: #f6ecd9; --rb-r: 12px;
  --rb-serif: "Source Serif 4", Georgia, serif; --rb-head: "Young Serif", Georgia, serif; --rb-ui: "Inter Variable", Inter, system-ui, sans-serif;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body.rb { margin: 0; background: var(--rb-paper); color: var(--rb-ink); font: 400 18px/1.65 var(--rb-serif); }
.rb a { color: var(--rb-red); text-underline-offset: 0.15em; }
.rb a:hover { color: var(--rb-red-d); }
.rb :focus-visible { outline: 3px solid var(--rb-red); outline-offset: 2px; border-radius: 4px; }
.rb h1, .rb h2, .rb h3 { font-family: var(--rb-head); font-weight: 400; color: var(--rb-ink); }
.rb-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.rb-skip { position: absolute; left: 12px; top: -60px; z-index: 10; background: var(--rb-red); color: #fff !important; font: 600 15px var(--rb-ui); padding: 12px 18px; border-radius: 999px; }
.rb-skip:focus { top: 12px; }
.rb-wrap { max-width: 1040px; margin: 0 auto; padding: 0 20px; }
.rb-plaid { height: 8px; background: repeating-linear-gradient(90deg, var(--rb-red) 0 12px, var(--rb-paper) 12px 14px, var(--rb-red) 14px 26px, var(--rb-paper) 26px 40px); }

/* Header */
.rb-bar { background: var(--rb-card); border-bottom: 1px solid var(--rb-line); }
.rb-bar-row { display: flex; align-items: center; gap: 12px; min-height: 72px; }
.rb-bar .rb-wrap { max-width: 1180px; }
.rb .rb-logo { display: flex; align-items: center; gap: 10px; min-height: 48px; font: 400 24px/1 var(--rb-head); color: var(--rb-red); text-decoration: none; white-space: nowrap; }
.rb-logo img { border-radius: 9px; flex: none; }
.rb-nav { display: flex; margin-left: 4px; }
.rb .rb-nav a { display: flex; align-items: center; min-height: 48px; padding: 0 9px; color: var(--rb-ink); text-decoration: none; font: 500 15px var(--rb-ui); white-space: nowrap; }
.rb .rb-nav a:hover, .rb .rb-nav a[aria-current] { color: var(--rb-red); }
.rb .rb-nav a[aria-current] { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 8px; }
.rb-search { margin-left: auto; display: flex; min-width: 0; flex: 0 1 280px; }
.rb-search input { min-height: 48px; flex: 1 1 140px; width: 0; min-width: 0; border: 1px solid var(--rb-line); border-right: 0; border-radius: 999px 0 0 999px; padding: 0 16px; background: #fff; color: var(--rb-ink); font: 15px var(--rb-ui); }
.rb-search button { min-height: 48px; border: 0; border-radius: 0 999px 999px 0; padding: 0 18px; background: var(--rb-red); color: #fff; font: 600 15px var(--rb-ui); cursor: pointer; }
.rb-search button:hover { background: var(--rb-red-d); }
.rb-lang select { min-height: 48px; border: 1px solid var(--rb-line); border-radius: 999px; padding: 0 12px; background: transparent; color: var(--rb-ink); font: 14px var(--rb-ui); cursor: pointer; }
.rb-menu { display: none; align-items: center; gap: 6px; min-height: 48px; padding: 0 12px; border: 1px solid var(--rb-line); border-radius: 999px; background: transparent; color: var(--rb-ink); font: 500 15px var(--rb-ui); cursor: pointer; }
.rb-sheet { margin: 0 0 0 auto; height: 100%; max-height: none; width: min(360px, 90vw); border: 0; padding: 20px; background: var(--rb-card); color: var(--rb-ink); }
.rb-sheet::backdrop { background: rgb(42 33 28 / 0.4); }
.rb-sheet-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.rb-sheet-title { font: 400 22px var(--rb-head); color: var(--rb-red); }
.rb-close { width: 48px; height: 48px; border: 0; background: transparent; color: var(--rb-ink); border-radius: 999px; cursor: pointer; }
.rb-sheet-links { display: flex; flex-direction: column; margin-bottom: 16px; }
.rb .rb-sheet-links a { display: flex; align-items: center; min-height: 48px; color: var(--rb-ink); text-decoration: none; font: 500 17px var(--rb-ui); border-bottom: 1px solid var(--rb-line); }
.rb .rb-sheet-links a[aria-current] { color: var(--rb-red); }

/* Shared pieces */
.rb-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 48px; padding: 0 22px; border-radius: 999px; border: 2px solid var(--rb-red);
  background: var(--rb-red); color: #fff; font: 600 15px var(--rb-ui); text-decoration: none; cursor: pointer; }
.rb a.rb-btn { color: #fff; }
.rb .rb-btn:hover { background: var(--rb-red-d); border-color: var(--rb-red-d); color: #fff; }
.rb .rb-btn.o, .rb a.rb-btn.o { background: transparent; color: var(--rb-red); }
.rb .rb-btn.o:hover { background: var(--rb-red); color: #fff; }
.rb-save[aria-pressed="true"] { background: var(--rb-note); }
.rb-acts { display: flex; flex-wrap: wrap; gap: 12px; margin: 18px 0 28px; }
.rb-crumbs { padding: 18px 0 4px; font: 14px var(--rb-ui); color: var(--rb-soft); }
.rb-crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; align-items: center; }
.rb-crumbs li { display: inline-flex; align-items: center; min-height: 32px; }
.rb-crumbs li:not(:last-child)::after { content: "›"; margin: 0 8px; }
.rb .rb-crumbs a { color: var(--rb-soft); display: inline-flex; min-height: 32px; align-items: center; }
.rb-sec { font-size: 30px; line-height: 1.2; margin: 44px 0 6px; padding-bottom: 8px; border-bottom: 2px solid var(--rb-line); }
.rb-lede { color: var(--rb-soft); margin: 0 0 8px; }
.rb-soft { color: var(--rb-soft); }
.rb-center { text-align: center; margin-top: 30px; }
.rb-chip { display: inline-flex; align-items: center; min-height: 40px; padding: 0 14px; border: 1px solid var(--rb-line); border-radius: 999px; background: var(--rb-card);
  color: var(--rb-ink); font: 14px var(--rb-ui); text-decoration: none; cursor: pointer; }
.rb a.rb-chip { color: var(--rb-ink); }
.rb .rb-chip:hover { border-color: var(--rb-red); color: var(--rb-red); }
.rb .rb-chip[aria-current], .rb .rb-chip[aria-pressed="true"] { background: var(--rb-red); border-color: var(--rb-red); color: #fff; }
.rb-chip[aria-disabled="true"] { opacity: 0.5; cursor: default; }
/* 48px hit areas on the 40px chips and the 32px breadcrumb links (Designer 11/27): the look stays, the tap target grows. */
.rb-chip, .rb .rb-crumbs a { position: relative; }
.rb-chip::before { content: ""; position: absolute; inset: -5px -1px; } /* from inside the 1px border: 38 + 10 = 48px */
.rb .rb-crumbs a::before { content: ""; position: absolute; inset: -8px -4px; }
.rb-courses, .rb-chips, .rb-selected-list { list-style: none; margin: 16px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }

/* Cards */
.rb-grid { list-style: none; margin: 18px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.rb-card { position: relative; height: 100%; background: var(--rb-card); border: 1px solid var(--rb-line); border-radius: var(--rb-r); overflow: hidden; }
.rb-card picture, .rb-card img { display: block; width: 100%; aspect-ratio: 3 / 2; object-fit: cover; height: auto; }
.rb-card-flat { display: flex; align-items: center; justify-content: center; aspect-ratio: 3 / 2; padding: 16px; background: var(--rb-note); font: 400 22px var(--rb-head); color: var(--rb-red); text-align: center; }
.rb-card-body { padding: 14px 16px 18px; }
.rb .rb-card-title { font-size: 21px; line-height: 1.25; margin: 0 0 6px; }
.rb .rb-card-title a { color: var(--rb-ink); text-decoration: none; }
.rb-card-title a::after { content: ""; position: absolute; inset: 0; }
.rb .rb-card:hover .rb-card-title a { color: var(--rb-red); }
.rb-card:focus-within { outline: 3px solid var(--rb-red); outline-offset: 2px; }
.rb-card-title a:focus-visible { outline: none; }
.rb-card-meta { font: 14px var(--rb-ui); color: var(--rb-soft); }

/* Home */
.rb-welcome { display: grid; grid-template-columns: 1.15fr 1fr; gap: 32px; align-items: center; padding: 36px 0 8px; }
.rb-welcome-photo img { display: block; width: 100%; aspect-ratio: 3 / 2; height: auto; object-fit: cover; border-radius: var(--rb-r); }
.rb-kicker { margin: 0 0 6px; font: 600 14px var(--rb-ui); letter-spacing: 0.06em; text-transform: uppercase; color: var(--rb-green); }
.rb .rb-welcome h1 { font-size: clamp(34px, 5vw, 50px); line-height: 1.08; margin: 0 0 14px; }
.rb-welcome-body { margin: 0 0 8px; color: var(--rb-soft); }
.rb-cats { list-style: none; margin: 18px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.rb .rb-cat { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 76px; padding: 12px 8px; background: var(--rb-card);
  border: 1px solid var(--rb-line); border-radius: var(--rb-r); text-align: center; text-decoration: none; color: var(--rb-ink); }
.rb .rb-cat:hover { border-color: var(--rb-red); }
.rb-cat b { font: 400 19px/1.2 var(--rb-head); }
.rb-cat span { font: 14px var(--rb-ui); color: var(--rb-soft); }

/* Lists */
.rb-list h1, .rb-about h1 { font-size: clamp(34px, 5vw, 44px); line-height: 1.1; margin: 8px 0 6px; }
.rb-more { margin: 18px 0 0; border: 1px solid var(--rb-line); border-radius: var(--rb-r); background: var(--rb-card); }
.rb-more summary { display: flex; align-items: center; min-height: 48px; padding: 0 16px; font: 600 15px var(--rb-ui); cursor: pointer; color: var(--rb-ink); }
.rb-groups { padding: 0 16px 16px; display: grid; gap: 12px; }
.rb .rb-facet h3 { font: 600 13px var(--rb-ui); text-transform: uppercase; letter-spacing: 0.06em; color: var(--rb-green); margin: 8px 0 0; }
.rb-facet .rb-chips { margin-top: 8px; }
html[data-js] .rb-nojs, html:not([data-js]) .rb-js { display: none; }
.rb-summary { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; min-height: 48px; margin-top: 16px; }
.rb-count { margin: 0; font: 600 15px var(--rb-ui); color: var(--rb-soft); }
.rb-summary .rb-selected-list { margin: 0; }
.rb-textbtn { min-height: 48px; border: 0; background: transparent; color: var(--rb-red); font: 600 15px var(--rb-ui); cursor: pointer; text-decoration: underline; padding: 0 4px; }
.rb-empty { margin: 18px 0; padding: 28px; background: var(--rb-card); border: 1px solid var(--rb-line); border-radius: var(--rb-r); text-align: center; }
.rb-pager { display: flex; align-items: center; justify-content: center; gap: 16px; margin: 30px 0 0; font: 15px var(--rb-ui); color: var(--rb-soft); }

/* About */
.rb-about { max-width: 720px; }

/* Recipe page */
.rb-post article { max-width: 1000px; }
.rb .rb-post h1 { font-size: clamp(34px, 5vw, 52px); line-height: 1.08; margin: 10px 0 8px; }
.rb-by { font: 15px var(--rb-ui); color: var(--rb-soft); margin: 0 0 20px; }
.rb-hero { margin: 0; }
.rb-hero img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; border-radius: var(--rb-r); }
.rb-hero figcaption { margin-top: 6px; font: 13px var(--rb-ui); color: var(--rb-soft); }
.rb-intro { font-size: 20px; margin: 22px 0; }
.rb-bar-meta { display: flex; flex-wrap: wrap; margin: 18px 0; border: 1px solid var(--rb-line); border-radius: var(--rb-r); background: var(--rb-card); }
.rb-bar-meta div { flex: 1; min-width: 130px; padding: 12px 16px; border-right: 1px solid var(--rb-line); }
.rb-bar-meta div:last-child { border-right: 0; }
.rb-bar-meta dt { font: 13px var(--rb-ui); text-transform: uppercase; letter-spacing: 0.06em; color: var(--rb-soft); }
.rb-bar-meta dd { margin: 2px 0 0; font: 600 18px/1.3 var(--rb-ui); color: var(--rb-ink); }
.rb-recipe { background: var(--rb-card); border: 1px solid var(--rb-line); border-top: 6px solid var(--rb-green); border-radius: var(--rb-r); padding: 28px; margin: 12px 0 30px; scroll-margin-top: 16px; }
.rb .rb-recipe-title { font-size: 30px; margin: 0 0 18px; }
.rb-cols { display: grid; grid-template-columns: 1fr 1.5fr; gap: 36px; }
.rb .rb-col-h { font-size: 24px; margin: 0 0 12px; }
.rb-ing { list-style: none; margin: 0; padding: 0; }
.rb-ing li { display: flex; gap: 12px; align-items: flex-start; padding: 8px 0; border-bottom: 1px dotted var(--rb-line); }
.rb-ing input { flex: none; width: 22px; height: 22px; margin: 4px 0 0; accent-color: var(--rb-red); cursor: pointer; }
.rb-ing label { cursor: pointer; }
.rb-ing input:checked + label { text-decoration: line-through; color: var(--rb-soft); }
.rb .rb-ing-h { margin: 16px 0 2px; padding-top: 12px; border-top: 1px solid var(--rb-line); font: 600 15px var(--rb-ui); text-transform: uppercase; letter-spacing: 0.05em; color: var(--rb-ink); }
.rb-ing-block:first-child .rb-ing-h { margin-top: 0; border-top: 0; padding-top: 0; }
.rb-steps { list-style: none; counter-reset: s; margin: 0; padding: 0; }
.rb-steps li { counter-increment: s; position: relative; padding: 4px 0 18px 52px; }
.rb-steps li::before { content: counter(s); position: absolute; left: 0; top: 0; width: 36px; height: 36px; border-radius: 50%; background: var(--rb-red); color: #fff;
  font: 600 16px/36px var(--rb-ui); text-align: center; }
.rb-tip { background: var(--rb-note); border-left: 4px solid var(--rb-oak); padding: 14px 18px; border-radius: 0 var(--rb-r) var(--rb-r) 0; margin: 8px 0 0; }
.rb-serve { margin: 18px 0 0; }
.rb-serve dt { font: 600 13px var(--rb-ui); text-transform: uppercase; letter-spacing: 0.06em; color: var(--rb-green); }
.rb-serve dd { margin: 2px 0 10px; }
.rb-tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 10px; }

/* Footer */
.rb-foot { margin-top: 60px; background: var(--rb-card); border-top: 1px solid var(--rb-line); padding: 18px 0 32px; font: 14px var(--rb-ui); color: var(--rb-soft); }
.rb-foot .rb-wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 20px; }
.rb .rb-foot a { display: inline-flex; align-items: center; min-height: 48px; color: var(--rb-soft); }

/* Tablet and phone */
@media (max-width: 1139px) { .rb-nav { display: none; } .rb-menu { display: inline-flex; } }
.rb-sheet .rb-lang select { width: 100%; }
@media (max-width: 860px) {
  .rb-bar-row { flex-wrap: wrap; padding-top: 8px; padding-bottom: 10px; gap: 8px; }
  .rb-search { order: 5; flex: 1 0 100%; margin-left: 0; }
  .rb-lang-bar { margin-left: auto; }
  .rb-welcome { grid-template-columns: 1fr; gap: 20px; }
  .rb-cats { grid-template-columns: repeat(2, 1fr); }
  .rb-grid { grid-template-columns: repeat(2, 1fr); gap: 18px; }
  .rb-cols { grid-template-columns: 1fr; gap: 24px; }
}
@media (max-width: 560px) {
  body.rb { font-size: 17px; }
  .rb-lang-bar { display: none; }
  .rb-menu { margin-left: auto; }
  .rb .rb-logo { font-size: 20px; }
  .rb-logo img { width: 30px; height: 30px; }
  .rb-grid { grid-template-columns: 1fr; }
  .rb-recipe { padding: 20px; }
  .rb-intro { font-size: 19px; line-height: 1.55; margin: 18px 0; } /* not a wall of text above the recipe card on phones */
  .rb-bar-meta div { min-width: 50%; border-right: 0; border-bottom: 1px solid var(--rb-line); }
  .rb-bar-meta div:nth-child(odd) { border-right: 1px solid var(--rb-line); }
  .rb-bar-meta div:nth-last-child(-n + 2) { border-bottom: 0; }
}
@media (max-width: 380px) { .rb-lang select { padding: 0 6px; } .rb-menu { padding: 0 10px; } }

/* Print: the recipe only, black on white, photo at most 180px tall, ingredients and steps in two columns. */
@media print {
  .rb-plaid, .rb-bar, .rb-foot, .rb-noprint, .rb-crumbs, .rb-skip, .rb-related, .rb-tags, .rb-hero figcaption { display: none !important; }
  body.rb { background: #fff; color: #000; font-size: 11pt; line-height: 1.45; }
  .rb-wrap { max-width: none; padding: 0; }
  .rb .rb-post h1 { font-size: 22pt; margin: 0 0 4pt; }
  .rb-hero img { max-height: 180px; width: auto; aspect-ratio: auto; border-radius: 0; }
  .rb-intro { font-size: 11pt; margin: 8pt 0; }
  .rb-bar-meta { border: 0; background: none; margin: 6pt 0; }
  .rb-bar-meta div { border: 0; padding: 0 12pt 0 0; min-width: 0; }
  .rb-recipe { border: 0; padding: 0; margin: 0; background: none; }
  .rb .rb-recipe-title { display: none; }
  .rb-cols { grid-template-columns: 1fr 1.6fr; gap: 18pt; }
  .rb-steps li::before { background: none; color: #000; border: 1px solid #000; }
  .rb-ing input { display: none; }
  .rb-tip { background: none; border-left: 2px solid #000; }
  .rb a { color: #000; text-decoration: none; }
}
