/* === QuikRecipes – Modern Design CSS === */
/* Font: Montserrat for modern, clean look */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700&display=swap');

:root {
  --brand: #FF6A2C;
  --brand-600: #E4571F;
  --brand-100: #FFE6D9;

  --ink: #111111;
  --muted-ink: #4A4A4A;

  --bg: #FBFBF9;
  --card: #FFFFFF;
  --line: #E0E0E0;

  --success: #20A464;
  --warning: #D9822B;
  --danger: #D94A4A;

  --radius: 16px;
  --radius-sm: 12px;
  --shadow: 0 8px 20px rgba(0, 0, 0, .06);
  --shadow-sm: 0 4px 10px rgba(0, 0, 0, .05);

  --gap-1: 8px;
  --gap-2: 12px;
  --gap-3: 16px;
  --gap-4: 24px;
  --gap-5: 32px;
}


/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  font-family: 'Montserrat', system-ui, -apple-system, 'Segoe UI', Roboto, Ubuntu, 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
}

/* Container */
.container {
  width: min(1200px, 92vw);
  margin-inline: auto;
}

/* Header Styles */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: saturate(1.2) blur(6px);
  background: linear-gradient(135deg, rgba(255, 106, 44, 0.35) 0%, rgba(228, 87, 31, 0.85) 100%),
    url('../images/site_images/banner_1.png') center/cover no-repeat;
  border-bottom: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}

/* Homepage Header - White Background */
.header-homepage {
  background: color-mix(in oklab, var(--bg) 88%, transparent);
}

.header-homepage .logo-text {
  color: var(--ink);
  text-shadow: none;
}

.header-homepage .nav-menu a {
  color: var(--ink);
  text-shadow: none;
}

.header-homepage .nav-menu a:hover,
.header-homepage .nav-menu a.active {
  background: var(--brand-100);
  color: var(--brand);
  backdrop-filter: none;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  padding-left: 20px;
  gap: var(--gap-4);
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.logo img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  box-shadow: var(--shadow-sm);
}

.logo-text {
  font-size: clamp(27px, 3.3vw, 33px);
  font-weight: 700;
  color: white;
  letter-spacing: 0.2px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: var(--gap-3);
}

.nav-menu a {
  color: white;
  text-decoration: none;
  padding: 8px 16px;
  border-radius: 999px;
  font-weight: 500;
  transition: all 0.2s ease;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.nav-menu a:hover,
.nav-menu a.active {
  background: rgba(255, 255, 255, 0.25);
  color: white;
  backdrop-filter: blur(4px);
}

/* Hero Section */
.hero {
  background: linear-gradient(135deg, rgba(255, 106, 44, 0.35) 0%, rgba(228, 87, 31, 0.85) 100%),
    url('../images/site_images/banner_1.png') center/cover no-repeat;
  color: white;
  padding: 5rem 0 4rem;
  text-align: center;
  position: relative;
  box-shadow: inset 0 -2px 10px rgba(0, 0, 0, 0.1);
}

.hero-content {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 1.5rem;
  width: 100%;
  box-sizing: border-box;
}

.hero-main-title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 700;
  margin-bottom: 1rem;
  line-height: 1.2;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.hero-subtitle {
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  margin-bottom: 2.5rem;
  opacity: 0.95;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
}

.hero-search-form {
  max-width: 700px;
  margin: 0 auto 1.5rem;
}

.hero-search-wrapper {
  display: flex;
  align-items: center;
  background: white;
  border-radius: 50px;
  padding: 8px 8px 8px 24px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
  gap: 12px;
}

.search-icon {
  color: var(--muted-ink);
  font-size: 1.1em;
}

.hero-search-input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-size: 1.05em;
  color: var(--ink);
  padding: 12px 8px;
  font-family: 'Montserrat', sans-serif;
}

.hero-search-input::placeholder {
  color: var(--muted-ink);
}

.hero-search-btn {
  background: var(--brand);
  color: white;
  border: none;
  padding: 14px 32px;
  border-radius: 50px;
  cursor: pointer;
  font-weight: 600;
  font-size: 1em;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'Montserrat', sans-serif;
}

.hero-search-btn:hover {
  background: var(--brand-600);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(255, 106, 44, 0.3);
}

.advanced-search-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: white;
  text-decoration: none;
  font-size: 0.95em;
  opacity: 0.9;
  transition: opacity 0.2s ease;
  font-weight: 500;
}

.advanced-search-link:hover {
  opacity: 1;
  text-decoration: underline;
}

/* Quick Filters Section */
.quick-filters {
  background: white;
  padding: 2rem 0;
  border-bottom: 1px solid var(--line);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.quick-filters-wrapper {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  align-items: center;
}

.filter-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: white;
  color: var(--ink);
  padding: 10px 20px;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95em;
  border: 2px solid var(--line);
  transition: all 0.2s ease;
  box-shadow: var(--shadow-sm);
}

.filter-pill:hover {
  background: var(--brand);
  color: white;
  border-color: var(--brand);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(255, 106, 44, 0.2);
}

.filter-pill i {
  font-size: 1.1em;
}

/* Modern Grid Layout for Recipe Cards */
.recipes-grid-modern {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

/* Vertical Recipe Cards */
.recipe-card-vertical {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  height: 100%;
}

.recipe-card-vertical:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.15);
  text-decoration: none;
  color: inherit;
}

.recipe-image-vertical {
  width: 100%;
  height: 220px;
  background: var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted-ink);
  font-size: 3em;
  overflow: hidden;
  position: relative;
}

.recipe-image-vertical img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.recipe-card-vertical:hover .recipe-image-vertical img {
  transform: scale(1.05);
}

.recipe-content-vertical {
  padding: 1.25rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.recipe-title-vertical {
  font-size: 1.15em;
  font-weight: 600;
  margin: 0;
  color: var(--ink);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.recipe-meta-vertical {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: auto;
}

.recipe-stats-vertical {
  display: flex;
  gap: 1rem;
  font-size: 0.9em;
  color: var(--muted-ink);
}

.recipe-stats-vertical span {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.recipe-tags-vertical {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.favorite-badge {
  position: absolute;
  bottom: 12px;
  right: 12px;
  background: rgba(255, 106, 44, 0.95);
  color: white;
  padding: 6px 10px;
  border-radius: 20px;
  font-size: 0.85em;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(4px);
}

/* Responsive Design */
@media (max-width: 768px) {
  .hero {
    padding: 3rem 0 2.5rem;
  }

  .hero-main-title {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .hero-search-wrapper {
    padding: 6px 6px 6px 16px;
  }

  .hero-search-btn {
    padding: 12px 24px;
    font-size: 0.95em;
  }

  .quick-filters {
    padding: 1.5rem 0;
  }

  .quick-filters-wrapper {
    gap: 0.75rem;
  }

  .filter-pill {
    padding: 8px 16px;
    font-size: 0.9em;
  }

  .recipes-grid-modern {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.5rem;
  }

  .recipe-image-vertical {
    height: 180px;
  }
}

/* Old Hero Search Styles - Keep for search.php page */

/* Search Box */
.search-box {
  max-width: 700px;
  margin: 0 auto;
  position: relative;
}

.search {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 12px 16px;
  width: 100%;
  box-shadow: var(--shadow);
}

.search input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-size: 18px;
  color: var(--ink);
  padding: 16px 20px;
}

.search input::placeholder {
  color: var(--muted-ink);
}

.search button {
  background: var(--brand);
  color: white;
  border: none;
  padding: 16px 24px;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 600;
  font-size: 16px;
  transition: all 0.2s ease;
}

.search button:hover {
  background: var(--brand-600);
}

.search button:focus-visible {
  outline: 3px solid rgba(255, 106, 44, .4);
  outline-offset: 2px;
}

/* Stats Section */
.stats {
  background: linear-gradient(180deg, var(--bg) 0%, rgba(255, 255, 255, 0.5) 100%);
  padding: 4rem 0;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
  text-align: center;
}

.stat-item {
  background: var(--card);
  padding: 2.5rem 2rem;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.stat-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--brand), var(--brand-600));
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.stat-item:hover::before {
  transform: scaleX(1);
}

.stat-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
}

.stat-number {
  font-size: 3.2em;
  font-weight: 700;
  color: var(--brand);
  margin-bottom: 0.5rem;
  background: linear-gradient(135deg, var(--brand), var(--brand-600));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stat-label {
  color: var(--muted-ink);
  font-size: 1.05em;
  font-weight: 600;
}

/* Section */
.section {
  padding: 4rem 0;
}

.section-title {
  text-align: center;
  font-size: 2.5em;
  font-weight: 700;
  margin-bottom: 3rem;
  color: var(--ink);
  position: relative;
  padding-bottom: 1rem;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: linear-gradient(90deg, var(--brand), var(--brand-600));
  border-radius: 2px;
}

/* Page Header */
.page-header {
  text-align: center;
  margin-bottom: 3rem;
}

.page-title {
  font-size: 2.5em;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--ink);
}

.results-info {
  color: var(--muted-ink);
  font-size: 1.1em;
}

/* Grid System */
.grid {
  display: grid;
  gap: var(--gap-4);
  grid-template-columns: repeat(12, 1fr);
}

.recipes-grid,
.results-grid {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 3rem;
}

.cuisines-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}

/* Recipe Cards */
.recipe-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: all 0.25s ease;
  display: flex;
  align-items: stretch;
  height: 180px;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  position: relative;
}

.recipe-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: var(--radius);
  border: 2px solid var(--brand);
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}

.recipe-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 32px rgba(0, 0, 0, .12);
  text-decoration: none;
  color: inherit;
}

.recipe-card:hover::after {
  opacity: 0.6;
}

.recipe-image {
  width: 180px;
  height: 180px;
  min-width: 180px;
  background: var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted-ink);
  font-size: 2em;
  overflow: hidden;
  flex-shrink: 0;
}

.recipe-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.recipe-content {
  padding: var(--gap-3);
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.recipe-title {
  font-size: 1.2em;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--ink);
  line-height: 1.3;
}

.recipe-meta {
  margin-bottom: 0.75rem;
}

.recipe-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  font-size: 0.85em;
  color: var(--muted-ink);
  margin-bottom: 0.5rem;
}

.recipe-stats span {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.recipe-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
}

.cuisine-tag {
  background: var(--brand-100);
  color: var(--brand);
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75em;
  font-weight: 500;
}

.category-tag {
  background: var(--line);
  color: var(--muted-ink);
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75em;
  font-weight: 500;
}

.dietary-tags {
  display: flex;
  gap: 0.3rem;
  flex-wrap: wrap;
}

.dietary-tag {
  background: #e8f5e8;
  color: #2d5016;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-size: 0.7em;
  font-weight: 500;
  text-transform: uppercase;
}

.recipe-description {
  color: var(--muted-ink);
  margin-bottom: 1rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Cuisine Cards */
.cuisine-card {
  background: var(--card);
  padding: 2rem;
  border-radius: var(--radius);
  text-align: center;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  transition: all 0.25s ease;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.cuisine-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(255, 106, 44, 0.05), rgba(228, 87, 31, 0.08));
  opacity: 0;
  transition: opacity 0.25s ease;
}

.cuisine-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.1);
  border-color: var(--brand-100);
}

.cuisine-card:hover::before {
  opacity: 1;
}

.cuisine-icon {
  font-size: 2.8em;
  margin-bottom: 1rem;
  color: var(--brand);
  transition: transform 0.25s ease;
  position: relative;
  z-index: 1;
}

.cuisine-card:hover .cuisine-icon {
  transform: scale(1.1);
}

.cuisine-name {
  font-size: 1.2em;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--ink);
  position: relative;
  z-index: 1;
}

.cuisine-count {
  color: var(--muted-ink);
  font-size: 0.9em;
  position: relative;
  z-index: 1;
}

/* Filters */
.filters-section {
  background: var(--card);
  padding: 2rem;
  border-radius: var(--radius);
  margin-bottom: 2rem;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}

.filters-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  align-items: end;
}

.filter-group {
  display: flex;
  flex-direction: column;
}

.filter-group label {
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: var(--ink);
}

.filter-group select,
.filter-group input {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 1em;
  background: var(--card);
  color: var(--ink);
}

.filter-group select:focus,
.filter-group input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(255, 106, 44, .1);
}

.filter-actions {
  display: flex;
  gap: 1rem;
}

/* Search Form */
.search-header {
  background: var(--card);
  padding: 2rem;
  border-radius: var(--radius);
  margin-bottom: 2rem;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.search-title {
  font-size: 2.5em;
  font-weight: 700;
  margin-bottom: 2rem;
  color: var(--ink);
  text-align: center;
}

.search-form {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1rem;
  align-items: end;
  margin-bottom: 2rem;
}

.search-form .search-group:first-child {
  grid-column: 1 / 3;
}

@media (max-width: 1200px) {
  .search-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
  }

  .search-group:first-child {
    grid-column: 1 / -1;
  }

  .search-btn {
    grid-column: 1 / -1;
    margin-top: 0.5rem;
  }
}

@media (max-width: 768px) {
  .hero .search-form {
    padding: 1.5rem;
    margin: 0 0 2rem;
  }

  .search-form {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .search-group:first-child,
  .search-btn {
    grid-column: auto;
  }
}

.search-group {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.search-group label {
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: var(--ink);
  font-size: 0.9em;
  white-space: nowrap;
}

.search-group input,
.search-group select {
  padding: 11px 12px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 0.95em;
  background: var(--card);
  color: var(--ink);
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  transition: all 0.2s ease;
}

.search-group input:focus,
.search-group select:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(255, 106, 44, .15);
}

.search-group select {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M10.293 3.293L6 7.586 1.707 3.293A1 1 0 00.293 4.707l5 5a1 1 0 001.414 0l5-5a1 1 0 10-1.414-1.414z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

.search-btn {
  padding: 12px 28px;
  background: var(--brand);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-weight: 600;
  font-size: 1em;
  transition: all 0.2s ease;
  box-shadow: 0 4px 12px rgba(255, 106, 44, 0.3);
  white-space: nowrap;
}

.search-btn:hover {
  background: var(--brand-600);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(255, 106, 44, 0.4);
}

.search-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(255, 106, 44, 0.3);
}

.search-btn:focus-visible {
  outline: 3px solid rgba(255, 106, 44, .4);
  outline-offset: 2px;
}

.popular-searches {
  margin-top: 1rem;
  text-align: center;
}

.popular-searches span {
  color: var(--muted-ink);
  margin-right: 1rem;
}

.popular-tag {
  display: inline-block;
  background: var(--brand-100);
  color: var(--brand);
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
  font-size: 0.9em;
  text-decoration: none;
  margin: 0.2rem;
  transition: all 0.2s ease;
  border: 1px solid color-mix(in oklab, var(--brand) 15%, var(--brand-100));
}

.popular-tag:hover {
  background: var(--brand);
  color: white;
}

/* Recipe Detail Page */
.recipe-header {
  background: var(--card);
  border-radius: var(--radius);
  padding: 2rem;
  margin-bottom: 2rem;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.recipe-title {
  font-size: clamp(28px, 3.2vw, 40px);
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--ink);
}

.recipe-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  margin-bottom: 2rem;
  color: var(--muted-ink);
}

.meta-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.1em;
}

.meta-item i {
  color: var(--brand);
  font-size: 1.2em;
}

.recipe-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--brand-100);
  color: var(--brand);
  border: 1px solid color-mix(in oklab, var(--brand) 15%, var(--brand-100));
}

.dietary-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.dietary-badge {
  padding: 0.4rem 0.8rem;
  border-radius: 999px;
  font-size: 0.85em;
  font-weight: 500;
}

.badge-vegan {
  background: #c8e6c9;
  color: #2e7d32;
}

.badge-vegetarian {
  background: #fff3e0;
  color: #ef6c00;
}

.badge-halal {
  background: #e1f5fe;
  color: #0277bd;
}

.badge-kosher {
  background: #f3e5f5;
  color: #7b1fa2;
}

.badge-vegan-alt {
  background: #e8f5e8;
  color: #2e7d32;
  border: 1px dashed #2e7d32;
}

.badge-vegetarian-alt {
  background: #fef7e6;
  color: #ef6c00;
  border: 1px dashed #ef6c00;
}

.badge-halal-alt {
  background: #e6f7ff;
  color: #0277bd;
  border: 1px dashed #0277bd;
}

.badge-kosher-alt {
  background: #f9f0fa;
  color: #7b1fa2;
  border: 1px dashed #7b1fa2;
}

.recipe-content {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 2rem;
}

.main-content {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 2rem;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}

.card-title {
  font-size: 1.5em;
  font-weight: 600;
  margin-bottom: 1.5rem;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.card-title i {
  color: var(--brand);
}

/* Ingredients */
.ingredients-group {
  margin-bottom: 2rem;
}

.ingredients-group:last-child {
  margin-bottom: 0;
}

.group-title {
  font-size: 1.2em;
  font-weight: 600;
  color: var(--brand);
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--line);
}

.ingredients-list {
  list-style: none;
}

.ingredient-item {
  padding: 0.15rem 0;
  border-bottom: 1px solid var(--line);
  line-height: 1.3;
}

.ingredient-item:last-child {
  border-bottom: none;
}

.ingredient-full {
  display: block;
  color: var(--ink);
  font-weight: 500;
  font-size: 1.125em;
}

.ingredient-amount-inline {
  color: var(--ink);
  font-weight: 600;
  margin-right: 0.5rem;
}

.ingredient-name {
  color: var(--ink);
  font-weight: 500;
}

.ingredient-note {
  font-size: 0.9em;
  color: var(--muted-ink);
  font-style: italic;
  margin-left: 0.25rem;
}

.ingredient-alternative {
  font-size: 0.85em;
  color: var(--muted-ink);
  margin-top: 0.1rem;
  padding-left: 1rem;
}

.ingredient-alternative i {
  color: var(--brand);
  margin-right: 0.25rem;
}

/* Recipe Steps */
.steps-list {
  list-style: none;
  counter-reset: step-counter;
}

.step-item {
  counter-increment: step-counter;
  margin-bottom: 1.5rem;
  display: flex;
  gap: 1rem;
}

.step-number {
  background: var(--brand);
  color: white;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  flex-shrink: 0;
}

.step-number::before {
  content: counter(step-counter);
}

.step-content {
  flex: 1;
  padding-top: 0.5rem;
}

.step-instruction {
  font-size: 1.1em;
  line-height: 1.7;
}

/* Sidebar */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.nutrition-info {
  background: var(--brand-100);
  padding: 1.5rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1rem;
}

.nutrition-title {
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--ink);
}

/* Related Recipes */
.related-recipes {
  margin-top: 3rem;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.related-card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 1rem;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  transition: translate 0.12s ease;
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.related-card:hover {
  translate: 0 -3px;
}

.related-image {
  width: 80px;
  height: 80px;
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
}

.no-image-placeholder {
  color: var(--muted-ink);
  font-size: 1.5rem;
}

.related-content {
  flex: 1;
}

.related-title {
  font-size: 1.1em;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--ink);
}

.related-meta {
  color: var(--muted-ink);
  font-size: 0.9em;
  margin-bottom: 1rem;
}

/* Buttons */
.btn {
  display: inline-block;
  appearance: none;
  border: none;
  cursor: pointer;
  font-weight: 600;
  border-radius: 999px;
  padding: 14px 32px;
  text-decoration: none;
  transition: all 0.25s ease;
  font-family: inherit;
  font-size: 1em;
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn:hover::before {
  width: 300px;
  height: 300px;
}

.btn:focus-visible {
  outline: 3px solid rgba(255, 106, 44, .35);
  outline-offset: 2px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--brand), var(--brand-600));
  color: white;
  box-shadow: 0 4px 15px rgba(255, 106, 44, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 106, 44, 0.4);
}

.btn-secondary {
  background: var(--line);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
  background: var(--muted-ink);
  color: white;
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border: 2px solid var(--line);
}

.btn-ghost:hover {
  background: var(--brand);
  color: white;
  border-color: var(--brand);
  transform: translateY(-1px);
}

/* Active Filters */
.active-filters {
  margin-bottom: 2rem;
  text-align: center;
}

.active-filter {
  display: inline-block;
  background: var(--brand);
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  margin: 0.2rem;
  font-size: 0.9em;
}

.active-filter a {
  color: white;
  text-decoration: none;
  margin-left: 0.5rem;
}

/* Pagination */
.pagination {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 3rem;
}

.pagination a {
  padding: 10px 15px;
  background: var(--card);
  color: var(--brand);
  text-decoration: none;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  transition: all 0.2s ease;
}

.pagination a:hover,
.pagination a.active {
  background: var(--brand);
  color: white;
  border-color: var(--brand);
}

/* No Results */
.no-results {
  text-align: center;
  padding: 4rem 2rem;
  color: var(--muted-ink);
}

.no-results i {
  font-size: 4em;
  margin-bottom: 1rem;
  opacity: 0.5;
}

/* Back Link */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--brand);
  text-decoration: none;
  margin-bottom: 2rem;
  font-weight: 500;
}

.back-link:hover {
  color: var(--brand-600);
}

/* CTA Section */
.cta-section {
  background: linear-gradient(135deg, var(--brand), var(--brand-600));
  color: white;
  text-align: center;
  padding: 5rem 0;
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 1px, transparent 1px);
  background-size: 30px 30px;
  animation: ctaBackground 20s linear infinite;
}

@keyframes ctaBackground {
  0% {
    transform: translate(0, 0);
  }

  100% {
    transform: translate(30px, 30px);
  }
}

.cta-section h2 {
  font-size: 2.8em;
  font-weight: 700;
  margin-bottom: 1rem;
  position: relative;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.cta-section p {
  font-size: 1.3em;
  margin-bottom: 2.5rem;
  opacity: 0.95;
  position: relative;
}

.cta-section .btn {
  background: white;
  color: var(--brand);
  padding: 16px 40px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 1.1em;
  position: relative;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.cta-section .btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
}

/* Footer */
.footer {
  background: var(--card);
  color: var(--muted-ink);
  padding: 3rem 0 2rem 0;
  border-top: 1px solid var(--line);
  margin-top: 4rem;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.footer-sections {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 2rem;
}

.footer-brand {
  display: flex;
  flex-direction: column;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 1rem;
  text-decoration: none;
  color: var(--ink);
}

.footer-logo img {
  width: 32px;
  height: 32px;
  border-radius: 50%;
}

.footer-logo-text {
  font-size: 1.5rem;
  font-weight: 700;
}

.footer-description {
  color: var(--muted-ink);
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.footer-section-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 1rem;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 0.5rem;
}

.footer-links a {
  color: var(--muted-ink);
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: var(--brand);
}

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid var(--line);
  text-align: center;
  color: var(--muted-ink);
  font-size: 0.9rem;
}

@media (max-width: 768px) {
  .footer-sections {
    grid-template-columns: 1fr;
    gap: 2rem;
    text-align: center;
  }
}

/* Utility Classes */
.center {
  display: grid;
  place-items: center;
}

.mt-4 {
  margin-top: var(--gap-4);
}

.mb-4 {
  margin-bottom: var(--gap-4);
}

.hidden {
  display: none !important;
}

/* Responsive Design */
@media (max-width: 980px) {
  .recipe-content {
    grid-template-columns: 1fr;
  }


  .filters-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.5em;
  }

  .nav-menu {
    display: none;
  }

  .logo img {
    height: 30px;
    width: 30px;
  }

  .logo-text {
    font-size: 1.5em;
  }


  .section {
    padding: 2rem 0;
  }

  .recipe-title {
    font-size: 2em;
  }

  .recipe-meta {
    flex-direction: column;
    gap: 1rem;
  }

  .container {
    padding: 1rem;
  }

  .recipe-stats {
    flex-direction: column;
    gap: 0.5rem;
  }

  .recipe-meta {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
}

@media (max-width: 640px) {
  .nav-container {
    gap: 12px;
  }

  .search {
    display: none;
    /* Hide search in mobile nav, show in hero */
  }

  .cuisines-grid {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }
}