/* =============================================================================
   Artisan Tempeh — recipe page styles (public/css/recipe.css)
   Individual recipe pages. Loaded after site.css and pages.css.
   Only tokens from site.css (:root custom properties, palette, type scale).
   ============================================================================= */

/* --- Recipe meta bar (prep / cook / serves) --- */
.recipe-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s2) var(--s5);
  margin-top: var(--s4);
}
.recipe-meta-item {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: var(--fs-small);
  color: var(--choc-deep);
  padding: var(--s1) var(--s3);
  background: var(--bone);
  border-radius: var(--pill);
}

/* --- Two-column layout: ingredients (sticky) + steps --- */
.recipe-columns {
  display: grid;
  gap: var(--s6);
  max-width: 72rem;
  margin: 0 auto;
}
@media (min-width: 48em) {
  .recipe-columns {
    grid-template-columns: 1fr 1.6fr;
    align-items: start;
    gap: var(--s7);
  }
  .recipe-col-ingredients {
    position: sticky;
    top: calc(var(--chrome-h) + var(--s4));
  }
}

/* --- Ingredients card --- */
.recipe-col-ingredients {
  padding: clamp(1.25rem, 3vw, 2rem);
  border-radius: var(--cut);
  box-shadow: var(--shadow-lg);
}
.recipe-col-ingredients h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--choc-deep);
  margin: 0 0 var(--s4);
}
.recipe-ingredients {
  list-style: none;
  margin: 0;
  padding: 0;
}
.recipe-ingredients li {
  padding: var(--s2) 0;
  border-bottom: 1px dashed var(--sand);
  font-size: 1rem;
  line-height: 1.5;
}
.recipe-ingredients li:last-child { border-bottom: none; }
.recipe-ingredients li:empty {
  padding: var(--s3) 0 0;
  border-bottom: none;
}

/* --- Steps --- */
.recipe-col-steps h2 {
  font-family: var(--font-display);
  font-size: 1.75rem;
  color: var(--cream);
  margin: 0 0 var(--s5);
}
.recipe-steps {
  list-style: none;
  counter-reset: step;
  margin: 0;
  padding: 0;
}
.recipe-steps li {
  counter-increment: step;
  position: relative;
  padding: 0 0 var(--s5) 3.5rem;
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--cream);
}
.recipe-steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background: var(--sand);
  color: var(--choc-deep);
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  display: grid;
  place-items: center;
  line-height: 1;
}
.recipe-steps li:last-child { padding-bottom: 0; }

/* --- Tips --- */
.recipe-tips {
  margin-top: var(--s7);
  padding: var(--s5);
  background: rgb(74 91 60 / 0.35);
  border-radius: var(--cut);
  border-left: 4px solid var(--sand);
}
.recipe-tips h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--cream);
  margin: 0 0 var(--s3);
}
.recipe-tips ul {
  margin: 0;
  padding: 0 0 0 1.25rem;
}
.recipe-tips li {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--sand);
  margin-bottom: var(--s2);
}
.recipe-tips li:last-child { margin-bottom: 0; }

/* --- CTA band --- */
.recipe-cta-box {
  text-align: center;
  max-width: 36rem;
  margin: 0 auto;
}
.recipe-cta-box h2 {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2rem);
  color: var(--choc-deep);
  margin-bottom: var(--s5);
}

/* --- Recipe card grid (listing page) --- */
.recipe-grid {
  display: grid;
  gap: var(--s5);
  max-width: 72rem;
  margin: 0 auto;
}
@media (min-width: 36em) { .recipe-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 64em) { .recipe-grid { grid-template-columns: repeat(3, 1fr); } }

.recipe-card {
  display: flex;
  flex-direction: column;
  border-radius: var(--cut);
  overflow: hidden;
  background: var(--cream);
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  text-decoration: none;
  color: inherit;
}
@media (prefers-reduced-motion: no-preference) {
  .recipe-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
}
.recipe-card-img {
  aspect-ratio: 16 / 10;
  background: var(--bone);
  display: grid;
  place-items: center;
  font-size: var(--fs-small);
  color: var(--choc);
  font-weight: 600;
}
.recipe-card-body {
  padding: var(--s4);
  flex: 1;
  display: flex;
  flex-direction: column;
}
.recipe-card-body h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--choc-deep);
  margin: 0 0 var(--s2);
}
.recipe-card-body p {
  font-size: 1rem;
  line-height: 1.5;
  color: var(--choc);
  margin: 0;
  flex: 1;
}
.recipe-card-meta {
  display: flex;
  gap: var(--s3);
  margin-top: var(--s3);
  font-size: var(--fs-small);
  font-weight: 700;
  color: var(--olive);
}

/* "Coming soon" cards */
.recipe-card.is-coming {
  opacity: 0.6;
  pointer-events: none;
}
.recipe-card.is-coming .recipe-card-img {
  background: var(--sand);
}

/* Real recipe photos (2026-11-19): the card crops the portrait shot to 16:10 around the food; the recipe page
   shows it whole in a photo frame in place of the tray. */
.recipe-card-img.has-photo { position: relative; overflow: hidden; }
.recipe-card-img.has-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 58%; display: block; }
.mast-art.has-photo { padding: 0; }
.mast-art.has-photo .photo-frame { rotate: 1.5deg; }
/* A landscape photo gets the full width on phones and a wider column beside the title on desktop */
.mast-art.has-photo.is-landscape { width: 100%; }
@media (min-width: 52.5em) {
  .mast-grid:has(.mast-art.is-landscape) { grid-template-columns: minmax(0, 1fr) clamp(18rem, 34vw, 30rem); }
}
