/* Recipes — added 2026-09-20 with mu-plugins/fatboys-recipes.php.

   Three surfaces, one file: the "Cook it" block on a product page, the meta list and the
   method on a recipe page, and the index on the parent page that lists the recipes.

   The "Cook it" block reuses the .fb-see-also__* class family on purpose, so it and
   "Same cut, other ways" read as one pair of boxes under the add-to-cart button rather
   than two that nearly match. fatboys-see-also.php prints those rules inline, but only on
   a product that has see-also entries; the copies here are scoped under .fb-recipes so a
   product with a recipe and no see-also entry still gets a styled box. The values are the
   same values, including the 44px link box from commit c91418a.

   Existing theme tokens only: --ink-soft, with the same plain fallbacks the see-also
   block uses. No new colour, no new font. */

/* ---------------------------------------------------- the block on the product page */

.fb-recipes {
  margin: 22px 0 4px;
  padding: 16px 18px;
  border: 1px solid rgba(0, 0, 0, .12);
  border-radius: 6px;
  background: #fdf7eb;
}
.fb-recipes + .fb-see-also { margin-top: 12px; }
.fb-recipes .fb-see-also__title {
  font-size: 1rem;
  margin: 0 0 10px;
  letter-spacing: .01em;
}
.fb-recipes .fb-see-also__list { list-style: none; margin: 0; padding: 0; }
.fb-recipes .fb-see-also__item { margin: 0 0 4px; line-height: 1.45; }
.fb-recipes .fb-see-also__item:last-child { margin-bottom: 0; }
.fb-recipes .fb-see-also__link {
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 2px;
  display: inline-block;
  padding: 10px 0;
  line-height: 24px;
  min-height: 44px;
  box-sizing: border-box;
}
.fb-recipes .fb-recipes__all { margin: 6px 0 0; }
.fb-recipes .fb-recipes__all a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: .95rem;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.fb-recipes .fb-see-also__why {
  display: block;
  color: var(--ink-soft, #55483f);
  font-size: .95rem;
  margin-top: -4px;
}

/* ------------------------------------------------------------- the recipe page itself */

/* Serves / Prep / Marinate / Cook. Two columns at every width, so nothing here can push
   the page sideways on a phone. */
.page-content .fb-recipe-meta {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 7px 20px;
  max-width: 380px;
  margin: 0 0 28px;
  padding: 14px 18px;
  border: 1px solid rgba(34, 29, 26, .14);
  border-radius: 6px;
  background: #fdf7eb;
}
.page-content .fb-recipe-meta dt {
  font-weight: 700;
  font-size: .82rem;
  letter-spacing: .06em;
  text-transform: uppercase;
  align-self: center;
}
.page-content .fb-recipe-meta dd { margin: 0; }

/* The method. The <ol> keeps the browser's own numbering: no counter, no drawn 01 02 03. */
.page-content ol.fb-recipe-steps { margin-left: 1.4em; }
.page-content ol.fb-recipe-steps li { margin-bottom: 12px; padding-left: 4px; }
.page-content ul.fb-recipe-ingredients { margin-bottom: 18px; }
.page-content ul.fb-recipe-ingredients li { margin-bottom: 4px; }
.page-content .fb-recipe-ingredients-sub {
  font-weight: 700;
  margin: 0 0 6px;
}

/* The dish photo at the top of a recipe page (owner 2026-10-19: every recipe has one).
   aspect-ratio holds the space before the image arrives, so the page does not jump. */
.page-content .fb-recipe-photo {
  margin: 0 0 24px;
  max-width: 860px;
  aspect-ratio: 3 / 2;
  border-radius: 8px;
  overflow: hidden;
  background: var(--paper-2, #e4dfd3);
}
.page-content .fb-recipe-photo__img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ------------------------------------------------------------ the index on /recipes/ */

/* A grid of cards, photo on top. These rules replace the 64px-thumbnail row layout that
   woo.css still carries (D12); this file loads after woo.css, so the same selectors win. */
.page-content .fb-recipe-index {
  list-style: none;
  margin: 18px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr));
  gap: 22px 18px;
}
.page-content .fb-recipe-index__item {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  border: 1px solid rgba(34, 29, 26, .14);
  border-radius: 8px;
  overflow: hidden;
  background: #fdf7eb;
  line-height: 1.45;
}
.page-content .fb-recipe-index__thumb {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  border-radius: 0;
  overflow: hidden;
  background: var(--paper-2, #e4dfd3);
}
.page-content .fb-recipe-index__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .35s ease;
}
.page-content .fb-recipe-index__item:hover .fb-recipe-index__thumb img { transform: scale(1.03); }
@media (prefers-reduced-motion: reduce) {
  .page-content .fb-recipe-index__thumb img { transition: none; }
  .page-content .fb-recipe-index__item:hover .fb-recipe-index__thumb img { transform: none; }
}
.page-content .fb-recipe-index__text {
  display: block;
  min-width: 0;
  padding: 2px 14px 14px;
}
.page-content .fb-recipe-index__link {
  font-weight: 700;
  font-size: 1.05rem;
  display: inline-block;
  padding: 10px 0;
  line-height: 24px;
  min-height: 44px;
  box-sizing: border-box;
}
.page-content .fb-recipe-index__why {
  display: block;
  color: var(--ink-soft, #55483f);
  font-size: .95rem;
  margin-top: -4px;
}

/* Phones: two cards a row, the title under each photo, the summary cut to three lines. */
@media (max-width: 559px) {
  .page-content .fb-recipe-index { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 12px; }
  .page-content .fb-recipe-index__text { padding: 0 10px 10px; }
  .page-content .fb-recipe-index__link { font-size: .95rem; line-height: 1.3; padding: 10px 0 6px; }
  .page-content .fb-recipe-index__why {
    font-size: .82rem;
    line-height: 1.35;
    margin-top: 0;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
  }
}
