/* Base Styles */
:root {
  /* Color Variables */
  --primary-color: #e67e22;
  --primary-light: #f39c12;
  --primary-dark: #d35400;
  --secondary-color: #2c3e50;
  --secondary-light: #34495e;
  --accent-color: #27ae60;
  --success-color: #2ecc71;
  --warning-color: #f1c40f;
  --error-color: #e74c3c;
  --text-dark: #2c3e50;
  --text-medium: #34495e;
  --text-light: #7f8c8d;
  --background-light: #ffffff;
  --background-off-white: #f9f9f9;
  --background-gray: #ecf0f1;
  --border-color: #e0e0e0;
  
  /* Typography */
  --heading-font: 'Playfair Display', serif;
  --body-font: 'Source Sans Pro', sans-serif;
  
  /* Spacing (8px system) */
  --space-xs: 0.5rem;  /* 8px */
  --space-sm: 1rem;    /* 16px */
  --space-md: 1.5rem;  /* 24px */
  --space-lg: 2rem;    /* 32px */
  --space-xl: 3rem;    /* 48px */
  
  /* Other */
  --border-radius: 8px;
  --container-width: 1200px;
  --transition-speed: 0.3s;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--body-font);
  color: var(--text-dark);
  line-height: 1.5;
  background-color: var(--background-light);
}

a {
  text-decoration: none;
  color: var(--primary-color);
  transition: color var(--transition-speed) ease;
}

a:hover {
  color: var(--primary-dark);
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 var(--space-md);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--heading-font);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--space-sm);
  color: var(--secondary-color);
}

h1 {
  font-size: 3rem;
}

h2 {
  font-size: 2.25rem;
}

h3 {
  font-size: 1.75rem;
}

h4 {
  font-size: 1.5rem;
}

p {
  margin-bottom: var(--space-md);
}

/* Buttons */
.btn {
  display: inline-block;
  padding: var(--space-xs) var(--space-md);
  border-radius: var(--border-radius);
  font-weight: 600;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-speed) ease;
  border: none;
  font-family: var(--body-font);
}

.btn-primary {
  background-color: var(--primary-color);
  color: white;
}

.btn-primary:hover {
  background-color: var(--primary-dark);
  color: white;
}

.btn-secondary {
  background-color: var(--secondary-color);
  color: white;
}

.btn-secondary:hover {
  background-color: var(--secondary-light);
  color: white;
}

/* Header */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  background-color: rgba(255, 255, 255, 0.983);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: background-color var(--transition-speed) ease;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-sm) 0;
}

.logo img {
    width: 130px;
    height: auto;
}

.nav-links {
  display: flex;
  margin-left: auto;
}

.nav-links li {
  margin-right: var(--space-md);
}

.nav-links a {
  color: var(--text-dark);
  font-weight: 600;
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary-color);
  transition: width var(--transition-speed) ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.search-container {
  display: flex;
  align-items: center;
  margin-left: var(--space-md);
}

#search-input, #mobile-search-input {
  padding: 8px 12px;
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  font-family: var(--body-font);
  font-size: 0.9rem;
}

#search-btn, #mobile-search-btn {
  background-color: var(--primary-color);
  color: white;
  border: none;
  padding: 8px 12px;
  margin-left: 8px;
  border-radius: var(--border-radius);
  cursor: pointer;
  transition: background-color var(--transition-speed) ease;
}

#search-btn:hover, #mobile-search-btn:hover {
  background-color: var(--primary-dark);
}

.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  margin-left: var(--space-md);
}

.hamburger span {
  display: block;
  width: 25px;
  height: 3px;
  background-color: var(--text-dark);
  margin-bottom: 5px;
  border-radius: 2px;
  transition: transform var(--transition-speed) ease;
}

.mobile-nav {
  position: fixed;
  top: 80px;
  left: -100%;
  width: 80%;
  height: 100vh;
  background-color: rgba(255, 255, 255, 0.983);
  z-index: 101;
  padding: var(--space-lg);
  box-shadow: none;
  transition: left var(--transition-speed) ease;
  display: flex;
  flex-direction: column;
}

.mobile-nav.active {
  left: 0;
  top: 75px;
  box-shadow: none;
  background-color: rgba(255, 255, 255, 0.983);
}

.mobile-nav ul {
  margin-bottom: var(--space-lg);
}

.mobile-nav li {
  margin-bottom: var(--space-sm);
}

.mobile-nav a {
  color: var(--text-dark);
  font-size: 1.2rem;
  font-weight: 600;
  display: block;
}

.mobile-search {
  margin-top: 0;
  margin-bottom: 40px;
  display: flex;
  flex-direction: column;
}

.mobile-search input {
  margin-bottom: var(--space-xs);
  margin-bottom: 13px;
}

.hero {
  position: relative;
  height: 80vh;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  margin-top: 60px;
}

.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
  filter: brightness(50%); /* same as dark overlay */
}

.hero-content {
  width: 100%;
  max-width: 700px;
  margin: 0 auto;
  padding: var(--space-lg);
  color: white;
  position: relative;
  z-index: 1;
}

.hero h1 {
  color: white;
  font-size: 3.5rem;
  margin-bottom: var(--space-md);
  font-weight: 700;
}

.hero p {
  font-size: 1.5rem;
  margin-bottom: var(--space-lg);
}

/* Section Styles */
section {
  padding: var(--space-xl) 0;
}

.section-title {
  text-align: center;
  margin-bottom: var(--space-lg);
  position: relative;
}

.section-title::after {
  content: '';
  display: block;
  width: 50px;
  height: 3px;
  background-color: var(--primary-color);
  margin: var(--space-xs) auto 0;
}


/* Featured Category */
.featured-category {
  background-color: var(--background-gray);
}

.featured-content {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: var(--space-lg) 0;
}

.featured-text {
  max-width: 600px;
}

.featured-text h2 {
  margin-bottom: var(--space-sm);
}

.featured-text p {
  margin-bottom: var(--space-md);
}

/* Newsletter */
.newsletter {
  background-color: var(--secondary-color);
  color: white;
}

.newsletter-content {
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
}

.newsletter h2 {
  color: white;
}

.form-group {
  display: flex;
  margin-top: var(--space-md);
}

#email {
  flex: 1;
  padding: 12px;
  border: none;
  border-radius: var(--border-radius) 0 0 var(--border-radius);
  font-family: var(--body-font);
  font-size: 1rem;
}

#newsletter-form button {
  border-radius: 0 var(--border-radius) var(--border-radius) 0;
  padding: 0 var(--space-md);
}

#subscription-message {
  margin-top: var(--space-md);
  font-weight: 600;
}

/* Footer */
footer {
  background-color: var(--secondary-light);
  color: white;
  padding: var(--space-xl) 0 var(--space-md);
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-lg);
  margin-bottom: var(--space-lg);
}

.footer-logo img {
  max-width: 80%;
}

.footer-logo p {
  color: var(--primary-light);
  font-size: 0.9rem;
  padding-left: 30px;
}

.footer-links h4, .footer-social h4 {
  color: white;
  margin-bottom: var(--space-sm);
  font-size: 1.1rem;
}

.footer-links ul li {
  margin-bottom: 8px;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.7);
  transition: color var(--transition-speed) ease;
}

.footer-links a:hover {
  color: white;
}

.social-icons {
  display: flex;
  gap: var(--space-sm);
}

.social-icons a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  color: white;
  transition: background-color var(--transition-speed) ease;
}

.social-icons a:hover {
  background-color: var(--primary-color);
}

.footer-bottom {
  text-align: center;
  padding-top: var(--space-md);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.5);
}

/* Utility Classes */
.text-center {
  text-align: center;
}

.mb-1 {
  margin-bottom: var(--space-xs);
}

.mb-2 {
  margin-bottom: var(--space-sm);
}

.mb-3 {
  margin-bottom: var(--space-md);
}

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

.mb-5 {
  margin-bottom: var(--space-xl);
}



/* ===================================
        RECIPES PAGE STYLE 
  ===================================== */
  .page-banner {
    margin-top: 14px;
  }

  .hero-search-container {
    display: flex;
    align-items: center;
    justify-content: center;
  }

  #hero-search-input {
    padding: 8px 37px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-family: var(--body-font);
    font-size: 0.9rem;
  }
  
  #hero-search-btn {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 8px 12px;
    margin-left: 8px;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: background-color var(--transition-speed) ease;
  }
  
  #hero-search-btn:hover {
    background-color: var(--primary-dark);
  }
  
  .recipes-section {
    padding-top: 0;
    margin: 0 2rem 0 2rem;
  }

  /* Menu Tabs Section */
  .category-tabs {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
  }
  
  .category-tabs .tab {
    background: none;
    border: none;
    font-weight: bold;
    padding: 10px 0;
    cursor: pointer;
    color: #004d40;
    font-size: 1rem;
  }
  
  .category-tabs .tab.active {
    border-bottom: 2px solid var(--primary-light);
    color: var(--primary-color);
  }

  /* Recipe Cards ================================================ */

  .recipe-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: var(--space-md);
    margin-bottom: var(--space-xl);
  }

  .recipe-card {
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: transform var(--transition-speed) ease;
    text-align: center;
    background-color: white;
  }

  .recipe-card:hover {
    transform: translateY(-5px);
    cursor: pointer;
  }
    
  .recipe-img {
    height: 150px;
    overflow: hidden;
  }
  
  .recipe-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-speed) ease;
  }
  
  .recipe-card:hover .recipe-img img {
  transform: scale(1.05);
  }
  
  .recipe-card .recipe-content h3 {
  padding: var(--space-xs) var(--space-sm) var(--space-xs);
  font-size: 1.2rem;
  }
  
  .recipe-content {
  padding: var(--space-xs) var(--space-sm) var(--space-xs);
  }

  .recipe-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: var(--text-light);
    padding: 0 var(--space-sm) var(--space-sm);
  }
  .recipe-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
  }

  .recipe-meta .stars {
    color: var(--warning-color);
  }

  .recipe-meta2 {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-xs);
    font-size: 0.85rem;
    color: var(--text-light);
    font-size: 0.9rem;
  }

  .recipe-category {
    color: var(--primary-color);
    font-weight: 600;
    margin-right: var(--space-xs);
  }

  .recipe-excerpt {
    color: var(--text-medium);
    margin-bottom: var(--space-sm);
    font-size: 0.95rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  .read-more {
    position: sticky;
    bottom: 9px;
    font-weight: 600;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
  }

  .read-more i {
    margin-left: 5px;
    font-size: 0.8rem;
    transition: transform var(--transition-speed) ease;
  }

  .read-more:hover i {
    transform: translateX(3px);
  }


/* New Recipes Section*/
.new-recipes-section {
  margin-top: calc(var(--spacing-unit) * 3);
}

.new-recipes-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
  gap: 30px;
}

.new-recipe-card {
  display: flex;
  align-items: stretch; /* Make both columns the same height */
  height: 200px; /* Set a fixed card height */
  gap: 0;
  cursor: pointer;
  background-color: #fffcfc;
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: 4px 3px 5px rgba(0, 0, 0, 0.05);
  transition: background 0.2s;
}

.new-recipe-card:hover {
  background-color: #fdfdfd;
}

.new-recipe-card-img {
  width: 40%;
  height: 100%; /* Ensure it matches the card height */
  overflow: hidden;
}

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

.new-recipe-card-content {
  padding: 0 1rem 1rem 1rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 60%;
}

.new-recipe-card-content h4 {
  font-size: 1rem;
  margin-bottom: 0.5rem;
  color: var(--text-color);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.new-recipe-date {
  font-size: 0.75rem;
  color: #888;
  margin-bottom: 0.5rem;
}

.new-recipe-excerpt {
  color: var(--text-medium);
  font-size: 0.9rem;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.read-more2 {
  font-weight: 600;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
}

.read-more2 i {
  margin-left: 5px;
  font-size: 0.8rem;
  transition: transform var(--transition-speed) ease;
}

.read-more2:hover i {
  transform: translateX(3px);
}

/* ===================================
          Responsive Design 
  ===================================== */

@media (max-width: 992px) {
  h1 {
    font-size: 2.5rem;
  }
  
  h2 {
    font-size: 2rem;
  }
  
  .hero h1 {
    font-size: 3rem;
  }
  
  .footer-content {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .nav-links, .search-container {
    display: none;
  }
  
  .hamburger {
    display: flex;
  }
  
  .header-content {
    padding: var(--space-xs) 0;
  }
  
  .hero {
    height: 70vh;
  }
  .hero h1 {
    font-size: 2.5rem;
  }
  .hero p {
    font-size: 1.2rem;
  }
  
  .form-group {
    flex-direction: column;
    align-items: center;
    gap: 10px;
  }
  
  #email {
    width: 90%;
    border-radius: var(--border-radius);
    margin-bottom: var(--space-xs);
  }
  
  #newsletter-form button {
    border-radius: var(--border-radius);
    width: 30%;
    padding: 6px;
  }
  
  .footer-content {
    grid-template-columns: 1fr;
    gap: var(--space-md);
  }
    .logo img {
      max-width: 110px;
      height: auto;
    }

  .new-recipes-container {
    grid-template-columns: 1fr;
  }

  .new-recipe-card {
    flex-direction: column;
    height: auto;
  }

  .new-recipe-card-img,
  .new-recipe-card-content {
    width: 100%;
  }

  .new-recipe-card-img {
    height: 200px;
  }

  .new-recipe-card-content {
    padding: 1rem;
  }

  .new-recipe-card-content h4 {
    font-size: 1rem;
    white-space: normal;
  }

  .new-recipe-excerpt {
    -webkit-line-clamp: 4;
  }
}
  
@media (max-width: 600px) {

  .hero-search-container {
    flex-direction: row;
    gap: var(--space-xs);
  }

  #hero-search-input {
    width: 70%;
  }

  .category-tabs {
    flex-wrap: wrap;
    gap: 10px;
  }

  .category-tabs .tab {
    font-size: 0.9rem;
    padding: 8px 0;
  }

  .tab-dropdown .dropdown-menu {
    right: 0;
    left: auto;
  }
}

@media (max-width: 576px) {
  section {
    padding: var(--space-lg) 0;
  }
  
  .article-grid {
    grid-template-columns: 1fr;
  }
  
  h1 {
    font-size: 2rem;
  }
  
  h2 {
    font-size: 1.75rem;
  }
  
  .hero h1 {
    font-size: 2rem;
  }
}

@media (max-width: 480px) {
  .new-recipe-card-content h4 {
    font-size: 0.95rem;
  }

  .new-recipe-excerpt {
    font-size: 0.85rem;
  }

  .read-more2 {
    font-size: 0.85rem;
  }
}

@media (max-width: 320px) {
  .footer-logo img {
    width: fit-content;
    height: auto;
  }
}
