/* Recipe directory v2: editorial pass.
 * Eyebrow + bigger hero, refined cards, kills hover-lift in favor of
 * image-scale-in-frame, optional featured card on page 1.
 * Layered AFTER recipe-directory.css. */

/* ---------- Hero rework ---------- */
.page-header {
  max-width: 1100px;
  padding: 3.5rem 2rem 2rem;
  text-align: left;
}
.page-header .header-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--coral, #FF8A73);
  margin-bottom: 1rem;
}
.page-header .header-eyebrow::before {
  content: '';
  width: 28px;
  height: 1px;
  background: currentColor;
  display: inline-block;
}
.page-header h1 {
  font-family: 'Fraunces', serif;
  font-size: clamp(2.5rem, 5.5vw, 4.5rem);
  line-height: 1.02;
  font-weight: 500;
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
  font-variation-settings: "opsz" 96;
  max-width: 14ch;
}
.page-header p {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 400;
  font-size: 1.2rem;
  line-height: 1.5;
  color: #5a5a5a;
  max-width: 52ch;
  margin: 0;
}
.page-header .header-count {
  display: inline-flex;
  align-items: baseline;
  gap: 0.5rem;
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(43, 43, 43, 0.1);
  width: 100%;
  max-width: 420px;
  font-family: 'Inter', sans-serif;
}
.page-header .header-count-value {
  font-family: 'Fraunces', serif;
  font-weight: 500;
  font-size: 1.65rem;
  color: var(--charcoal, #2B2B2B);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.01em;
}
.page-header .header-count-label {
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #888;
  font-weight: 500;
}

@media (max-width: 768px) {
  .page-header { padding: 2.5rem 1.25rem 1.5rem; }
  .page-header p { font-size: 1.05rem; }
}

/* ---------- Filter sections ---------- */
.content-section {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 2rem 4rem;
}
.categories-section {
  margin-bottom: 2rem;
}
.section-label {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #888;
  margin-bottom: 0.9rem;
}
.section-label::before {
  content: '';
  width: 24px;
  height: 1px;
  background: currentColor;
  display: inline-block;
}

/* Kill hover-lift on filter chips, replace with cleaner ink-fill */
.category-tag {
  display: inline-flex;
  align-items: center;
  padding: 0.55rem 1.15rem;
  background: #fff;
  border: 1px solid rgba(43, 43, 43, 0.12);
  border-radius: 999px;
  text-decoration: none;
  color: var(--charcoal, #2B2B2B);
  font-weight: 500;
  font-size: 0.9rem;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
  transform: none !important;
}
.category-tag:hover {
  background: var(--charcoal, #2B2B2B);
  color: #fff;
  border-color: var(--charcoal, #2B2B2B);
  transform: none !important;
}
.category-tag.active {
  background: var(--coral, #FF8A73);
  color: #fff;
  border-color: var(--coral, #FF8A73);
}
.category-tag.active:hover {
  background: var(--coral, #FF8A73);
  border-color: var(--coral, #FF8A73);
}

/* ---------- Featured recipe (page 1 only) ---------- */
.featured-recipe {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 3rem;
  align-items: center;
  padding: 2rem 0 3rem;
  margin-bottom: 2.5rem;
  border-bottom: 1px solid rgba(43, 43, 43, 0.1);
}
.featured-recipe-figure {
  position: relative;
  margin: 0;
  aspect-ratio: 4 / 5;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 30px 80px -30px rgba(43, 43, 43, 0.25);
  background: var(--soft-gray, #F5F2EE);
}
.featured-recipe-figure img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.7s cubic-bezier(0.2, 0.6, 0.2, 1);
  transform: scale(1.02);
}
.featured-recipe:hover .featured-recipe-figure img {
  transform: scale(1.06);
}
.featured-recipe-body {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}
.featured-recipe-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--coral, #FF8A73);
}
.featured-recipe-eyebrow::before {
  content: '';
  width: 22px;
  height: 1px;
  background: currentColor;
}
.featured-recipe-title {
  font-family: 'Fraunces', serif;
  font-weight: 500;
  font-size: clamp(1.85rem, 3.5vw, 2.75rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--charcoal, #2B2B2B);
  text-decoration: none;
  display: block;
  transition: color 0.2s;
  margin: 0;
}
.featured-recipe-title:hover { color: var(--coral, #FF8A73); }
.featured-recipe-meta {
  display: flex;
  gap: 1.75rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(43, 43, 43, 0.1);
  margin-top: 0.5rem;
}
.featured-recipe-meta .meta-stat-value {
  font-family: 'Fraunces', serif;
  font-weight: 500;
  font-size: 1.65rem;
  line-height: 1;
  color: var(--charcoal, #2B2B2B);
  font-variant-numeric: tabular-nums;
  display: block;
}
.featured-recipe-meta .meta-stat-label {
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #888;
  font-weight: 500;
  margin-top: 0.2rem;
  display: block;
}
@media (max-width: 820px) {
  .featured-recipe {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    padding: 1rem 0 2rem;
  }
  .featured-recipe-figure { aspect-ratio: 4 / 3; border-radius: 18px; }
}

/* ---------- Recipes section heading ---------- */
.recipes-section > h2 {
  font-family: 'Fraunces', serif;
  font-weight: 500;
  font-size: 1.4rem;
  letter-spacing: -0.01em;
  color: var(--charcoal, #2B2B2B);
  margin-bottom: 1.5rem;
}

/* ---------- Refined card grid ---------- */
.recipes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 2.5rem 1.75rem;
}

.recipe-card {
  background: transparent;
  border: 0;
  border-radius: 0;
  overflow: visible;
  transition: none;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}
.recipe-card:hover {
  transform: none !important;
  box-shadow: none !important;
  border-color: transparent;
}

.recipe-card > a:first-child {
  position: relative;
  display: block;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: 14px;
  background: var(--soft-gray, #F5F2EE);
  box-shadow: 0 8px 28px -16px rgba(43, 43, 43, 0.18);
}
.recipe-card .recipe-image {
  width: 100%;
  height: 100%;
  aspect-ratio: auto;
  object-fit: cover;
  display: block;
  transition: transform 0.65s cubic-bezier(0.2, 0.6, 0.2, 1);
  transform: scale(1.01);
}
.recipe-card:hover .recipe-image {
  transform: scale(1.06);
}

.recipe-card .recipe-content {
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.recipe-card .recipe-content > a {
  font-family: 'Fraunces', serif;
  font-size: 1.1rem;
  line-height: 1.25;
  font-weight: 500;
  letter-spacing: -0.005em;
  color: var(--charcoal, #2B2B2B);
  text-decoration: none;
  margin-bottom: 0;
  transition: color 0.2s;
}
.recipe-card .recipe-content > a:hover { color: var(--coral, #FF8A73); }

.recipe-card-meta {
  display: flex;
  gap: 0.6rem;
  align-items: center;
  font-size: 0.8rem;
  color: #888;
  font-family: 'Inter', sans-serif;
  letter-spacing: 0.01em;
  font-variant-numeric: tabular-nums;
}
.recipe-card-meta .dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.55;
}
.recipe-card-meta .type-tag {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.7rem;
  color: var(--coral, #FF8A73);
  font-weight: 600;
}

/* Hide the bare ".recipe-calories" if it exists alongside the new meta row */
.recipe-card-meta + .recipe-calories,
.recipe-card-meta ~ .recipe-calories {
  display: none;
}

/* ---------- Pagination polish ---------- */
.pagination-container {
  margin: 3rem 0 1rem;
  display: flex;
  justify-content: center;
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .featured-recipe-figure img,
  .recipe-card .recipe-image {
    transition: none !important;
    transform: none !important;
  }
}
