/* Rudra's Recipes - home "Cook with Rudra's" section + recipes page */
/* Loaded after style.css, uses the site's theme variables */

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* The menu has 5 items; scale it a little so it stays on one line */
.header-nav .nav-links { gap: clamp(18px, 2.6vw, 48px); }
.header-nav .nav-links a { font-size: clamp(1.02rem, 1.3vw, 1.34rem); }

/* ============================================
   COOK WITH RUDRA'S (home page section + list)
   ============================================ */
.recipes-home { background-color: var(--white); padding: 64px 0 80px; }

.recipes-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 32px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border-color);
}
.recipes-head h2 { font-size: 2rem; line-height: 1.2; letter-spacing: -0.3px; color: var(--primary-maroon); }

.recipes-viewall {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--primary-maroon);
  padding-bottom: 2px;
  border-bottom: 2px solid var(--primary-orange);
  transition: color 0.3s ease;
  white-space: nowrap;
}
.recipes-viewall:hover { color: var(--primary-orange); }

.recipe-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }

/* the whole card is clickable (the title link stretches over it) */
.recipe-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background-color: var(--light-bg);
  border: 1px solid #f7e7d7;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: var(--soft-shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.recipe-card[hidden] { display: none; }
.recipe-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }

.recipe-card-image { aspect-ratio: 3 / 2; overflow: hidden; background-color: var(--border-color); }
.recipe-card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.recipe-card:hover .recipe-card-image img { transform: scale(1.05); }

.recipe-card-body { flex: 1; display: flex; flex-direction: column; padding: 22px 24px 26px; }
.recipe-card-body h3 { font-size: 1.2rem; line-height: 1.35; margin-bottom: 10px; }

.recipe-card-link { color: var(--dark-text); transition: color 0.3s ease; }
.recipe-card-link::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.recipe-card-link:focus-visible { outline: none; }
.recipe-card-link:focus-visible::after { outline: 3px solid var(--primary-orange); outline-offset: -3px; border-radius: 18px; }
.recipe-card:hover .recipe-card-link { color: var(--primary-maroon); }

.recipe-card-body p { flex: 1; margin-bottom: 18px; font-size: 0.95rem; line-height: 1.7; color: var(--muted-text); }

.recipe-card-btn {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background-color: var(--primary-maroon);
  color: var(--white);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  border-radius: 6px;
  transition: background-color 0.3s ease;
}
.recipe-card:hover .recipe-card-btn { background-color: #6f0a0a; }

/* ============================================
   RECIPES PAGE
   ============================================ */
.recipes-hero {
  text-align: center;
  padding: 34px 4vw 30px;
  background: linear-gradient(180deg, #fbf0de 0%, #fffaf2 100%);
  border-bottom: 1px solid var(--border-color);
}
.recipes-eyebrow { display: inline-block; margin-bottom: 6px; font-size: 0.8rem; font-weight: 700; letter-spacing: 2px; text-transform: uppercase; color: var(--primary-orange); }
.recipes-hero h1 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); line-height: 1.15; color: var(--primary-maroon); }
.recipes-hero p { max-width: 920px; margin: 10px auto 0; font-size: 1rem; line-height: 1.6; color: var(--muted-text); }

/* .recipes-home.recipes-index is more specific than .recipes-home, so this padding wins */
.recipes-home.recipes-index { padding: 36px 0 56px; }

/* ---- list view / recipe view switching (only when JavaScript is on) ---- */
.recipe-back { display: none; }
.recipes-more { display: none; }
.js .recipe-detail { display: none; }
.js .recipe-detail.is-open { display: block; }
.js .view-recipe .recipes-hero,
.js .view-recipe .recipes-index { display: none; }
.js .view-recipe .recipe-back { display: block; }
.js .view-recipe .recipes-more { display: block; }

.recipe-back { padding: 16px 0; background: var(--light-bg); border-bottom: 1px solid var(--border-color); }
.recipe-back .container { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 24px; }
.recipe-back a { font-weight: 700; color: var(--primary-maroon); }
.recipe-back a:hover { color: var(--primary-orange); }
.recipe-crumb { font-size: 0.9rem; color: var(--muted-text); }
.recipe-crumb a { font-weight: 400; }
.recipe-crumb span { color: var(--dark-text); font-weight: 700; }

.recipe-detail { padding: 56px 0 64px; border-top: 1px solid var(--border-color); background-color: var(--white); }

.recipe-detail-grid { display: grid; grid-template-columns: 5fr 6fr; gap: 48px; align-items: start; }

.recipe-detail-photo { position: sticky; top: 24px; }
.recipe-detail-photo img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 18px; box-shadow: var(--shadow); }

.recipe-detail-text h2 { font-size: 2rem; line-height: 1.2; color: var(--primary-maroon); margin-bottom: 12px; }
.recipe-intro { margin-bottom: 18px; line-height: 1.8; color: var(--muted-text); }

.recipe-meta { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 8px; }
.recipe-meta li { padding: 10px 16px; line-height: 1.3; background: var(--light-bg); border: 1px solid var(--border-color); border-radius: 12px; }
.recipe-meta strong { display: block; font-size: 0.72rem; letter-spacing: 1px; text-transform: uppercase; color: var(--primary-orange); }
.recipe-meta span { font-weight: 700; color: var(--dark-text); }

.recipe-detail-text h3 { margin: 26px 0 12px; font-size: 1.25rem; color: var(--primary-maroon); }

.recipe-ingredients li { position: relative; padding: 5px 0 5px 22px; line-height: 1.6; color: var(--dark-text); }
.recipe-ingredients li::before { content: ""; position: absolute; left: 2px; top: 0.9em; width: 8px; height: 8px; border-radius: 50%; background: var(--primary-orange); }

.recipe-method { list-style: none; counter-reset: step; }
.recipe-method li { position: relative; counter-increment: step; padding: 8px 0 8px 46px; line-height: 1.7; color: var(--dark-text); }
.recipe-method li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 8px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--primary-maroon);
  color: var(--white);
  font-size: 0.9rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.recipe-method strong { color: var(--primary-maroon); }

.recipe-madewith { margin-top: 26px; padding: 14px 18px; background: var(--light-bg); border: 1px dashed #d9ad57; border-radius: 12px; color: var(--muted-text); line-height: 1.7; }

/* "Explore Our Products" button under each recipe */
.recipe-products-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  padding: 13px 26px;
  background-color: var(--primary-maroon);
  color: var(--white);
  font-size: 0.98rem;
  font-weight: 700;
  border-radius: 10px;
  box-shadow: 0 6px 16px rgba(139, 13, 13, 0.25);
  transition: background-color 0.3s ease, transform 0.3s ease;
}
.recipe-products-btn:hover { background-color: #6f0a0a; transform: translateY(-2px); }

/* WhatsApp / Instagram / Facebook quick icons under each recipe */
.recipe-social {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
  padding-top: 20px;
  border-top: 1px solid var(--border-color);
}
.recipe-social-label {
  margin-right: 4px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--muted-text);
}
.social-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  box-shadow: var(--soft-shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.social-btn svg { width: 24px; height: 24px; display: block; }
.social-btn:hover { transform: translateY(-3px) scale(1.06); box-shadow: var(--shadow); }
.social-wa { background: #25d366; }
.social-ig { background: linear-gradient(45deg, #f9a03c 0%, #e1306c 55%, #833ab4 100%); }
.social-fb { background: #1877f2; }

.recipes-more { background: var(--light-bg); border-top: 1px solid var(--border-color); padding: 56px 0 64px; }
.recipes-more .recipe-card { background: var(--white); }

/* ---------- Responsive ---------- */
@media (max-width: 992px) {
  .recipe-grid { grid-template-columns: repeat(2, 1fr); }
  .recipe-detail-grid { grid-template-columns: 1fr; gap: 28px; }
  .recipe-detail-photo { position: static; }
}
@media (max-width: 640px) {
  .recipes-home { padding: 44px 0 56px; }
  .recipes-hero { padding: 26px 4vw 24px; }
  .recipes-home.recipes-index { padding: 28px 0 44px; }
  .recipes-head h2 { font-size: 1.6rem; }
  .recipe-grid { grid-template-columns: 1fr; }
  .recipe-detail { padding: 40px 0 48px; }
  .recipe-detail-text h2 { font-size: 1.6rem; }
}
