/* --- Base Styles and Global Keyframes --- */
body {
  font-family: "Roboto", sans-serif;
  margin: 0;
  padding: 0;
  background-color: white;
}

/* --- Keyframe Animation for Fade-in/Slide-up --- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-fadein-up {
  opacity: 0; /* Start hidden */
  animation: fadeInUp 0.8s ease-out forwards;
}

/* --- Hero Section Styling --- */
/* Consolidated Hero Styles for all products */
.chicken-hero-section,
.crab-hero-section,
.shrimp-hero-section,
.products-hero-section,
.product-hero-section {
  text-align: center;
  padding: 120px 20px;
  position: relative;
  z-index: 1;
  margin-bottom: 40px;
  color: white;
}

/* Common ::before styles for Hero background */
.chicken-hero-section::before,
.crab-hero-section::before,
.shrimp-hero-section::before,
.products-hero-section::before,
.product-hero-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center center;
  filter: brightness(0.4);
}

/* Specific background images (Ensure these paths are correct for your file structure) */
.chicken-hero-section::before {
  background-image: url("../img/products/Hand feeding chickens.jpg.webp");
}
.crab-hero-section::before {
  background-image: url("../img/products/crab.jpg");
}
.shrimp-hero-section::before {
  background-image: url("../img/products/PXL_20221021_204624660.MP_-e1667814197604-1536x833.jpg");
}
.products-hero-section::before {
  background-image: url("../img/products/header-feeding-fish-2048x984.jpg");
}
/* ADD Feather Meal Background (Assuming you want a background image here, otherwise this can be omitted) */
.product-hero-section::before {
  background-image: url("../img/products/feather-meal.jpg");
}

.hero-title {
  font-size: 44px;
  font-weight: 900;
  margin-bottom: 15px;
}

.hero-subtitle {
  font-size: 20px;
  font-weight: 500;
  max-width: 900px;
  margin: 0 auto;
  margin-top: 20px;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

/* --- Product Hero Content Grid (for image/summary layout) --- */
.product-grid {
  display: flex;
  flex-direction: column; /* Stacks image on top of text by default (mobile first) */
  gap: 30px;
  align-items: flex-start;
  margin-top: 20px;
  padding: 0 10px;
}

.image-card {
  width: 100%; /* Full width on mobile */
  text-align: center;
}
.image-card img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.summary-content {
  width: 100%;
  line-height: 1.6;
  text-align: justify;
}
.summary-content p {
  margin-bottom: 15px;
}

/* --- Categories Section (Grid) --- */
.categories-section {
  padding: 40px 0;
  text-align: center;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  margin-top: 40px;
}

.category-card {
  display: block;
  text-decoration: none;
  background-color: #fff;
  padding: 30px 20px;
  border-radius: 8px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  border-bottom: 5px solid transparent;
  transition: all 0.3s ease;
}

.category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
  border-bottom-color: #0746d8;
}

.category-card i {
  font-size: 40px;
  color: #0746d8;
  margin-bottom: 15px;
}

.category-card h3 {
  font-family: "Montserrat", sans-serif;
  color: #3c0c70;
  font-size: 20px;
  margin: 5px 0;
}

.category-card p {
  color: #666;
  font-size: 14px;
}

/* --- Product Characteristics/Features Grid (NEW STYLES) --- */
.characteristics-section {
  padding: 40px 0;
}
.characteristics-section h2 {
  font-size: 28px;
  color: #3c0c70;
  margin-bottom: 30px;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
}
.characteristics-section h2 i {
  font-size: 32px;
  color: #0746d8;
  margin-right: 10px;
}

.features-grid {
  display: grid;
  /* Flexible default: up to 6 columns, min 180px */
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 20px;
  text-align: center;
  padding: 0 10px;
}
.feature-item {
  padding: 15px 10px;
  border: 1px solid #eee;
  border-radius: 6px;
  background-color: #f9f9f9;
  transition: all 0.3s;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}
.feature-item:hover {
  background-color: #eaf7f7;
  border-color: #0746d8;
  transform: translateY(-2px);
}
.feature-item i {
  font-size: 28px;
  color: #0746d8;
  margin-bottom: 5px;
}
.feature-item p {
  font-size: 14px;
  margin: 0;
  font-weight: 500;
  color: #333;
}

/* --- Product Detail Sections (Lists) --- */
.product-detail-section {
  padding: 60px 0 20px;
}

.product-list-header {
  display: flex;
  align-items: center;
  margin-bottom: 30px;
}

.product-list-header h2 {
  margin: 0;
  border-bottom: none;
  font-size: 28px;
}

.product-list-header i {
  font-size: 32px;
  color: #0746d8;
  margin-right: 15px;
}

.list-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  padding-bottom: 40px;
  border-bottom: 1px dashed #ddd;
}

.list-item {
  background-color: #fff;
  padding: 15px 20px;
  border-left: 5px solid #0746d8;
  border-radius: 4px;
  font-weight: 500;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  transition: background-color 0.2s;
}

.list-item:hover {
  background-color: #eaf7f7;
}

/* ----------------------------------------------- */
/* --- Media Queries for Improved Responsiveness --- */
/* ----------------------------------------------- */

/* Tablets and Medium Screens (max 992px) */
@media (max-width: 992px) {
  /* Hero/Titles Adjustments */
  .hero-title {
    font-size: 38px;
  }

  /* Product Hero Grid: Switches image and text to be side-by-side */
  .product-grid {
    flex-direction: row;
    align-items: flex-start;
  }
  .image-card {
    flex: 1;
    min-width: 250px;
    text-align: left;
  }
  .summary-content {
    flex: 2;
  }

  /* Category Grid: Flexible 2-3 columns */
  .category-grid {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
  }

  /* Product List: Flexible 2 columns */
  .list-container {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
  }

  /* Features Grid: Flexible columns, minimum width 150px */
  .features-grid {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }
}

/* Mobile Phones (max 600px) */
@media (max-width: 600px) {
  /* Hero/Titles Adjustments */
  .hero-title {
    font-size: 30px;
  }
  .hero-subtitle {
    font-size: 16px;
  }
  .product-list-header h2,
  .characteristics-section h2 {
    font-size: 22px;
  }
  .characteristics-section h2 i {
    font-size: 26px;
  }

  /* Product Hero Grid: Stacks vertically (inherited from base style) */
  .product-grid {
    flex-direction: column;
    gap: 20px;
  }

  /* Category Grid: Single column for mobile */
  .category-grid {
    grid-template-columns: 1fr;
    gap: 15px;
  }

  /* Product List: Single column for mobile */
  .list-container {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  /* Features Grid: Tighter two columns or single column if space is very limited */
  .features-grid {
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
  }
  .feature-item p {
    font-size: 13px;
  }
}
