:root {
  --primary-green: #2d5a27;
  --secondary-green: #4a7c59;
  --light-green: #8fbc8f;
  --accent-green: #90c695;
  --dark-green: #1e3f20;
  --cream: #f8f9fa;
}

* {
  font-family: "Prompt", sans-serif;
}

body {
  background-color: var(--cream);
}

/* Navigation */
.navbar {
  background: linear-gradient(
    135deg,
    var(--primary-green),
    var(--secondary-green)
  );
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.navbar-brand {
  font-weight: 700;
  font-size: 1.8rem;
  color: white !important;
  transition: transform 0.3s ease;
}

.navbar-brand:hover {
  transform: scale(1.05);
}

.nav-link {
  color: white !important;
  font-weight: 500;
  transition: all 0.3s ease;
  margin: 0 10px;
}

.nav-link:hover,
.nav-link.active {
  color: var(--accent-green) !important;
  transform: translateY(-2px);
}

/* Page Header */
.page-header {
  background: linear-gradient(135deg, var(--light-green), var(--accent-green));
  padding: 4rem 0 2rem 0;
  margin-top: 76px;
  color: white;
  position: relative;
  overflow: hidden;
}

.page-header::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 20"><defs><radialGradient id="a" cx="50%" cy="0%" r="50%"><stop offset="0%" stop-color="rgba(255,255,255,0.1)"/><stop offset="100%" stop-color="rgba(255,255,255,0)"/></radialGradient></defs><rect width="100" height="20" fill="url(%23a)"/></svg>')
    repeat-x;
  animation: shimmer 3s ease-in-out infinite;
}

@keyframes shimmer {
  0%,
  100% {
    opacity: 0.5;
  }

  50% {
    opacity: 1;
  }
}

.breadcrumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 25px;
  padding: 0.5rem 1rem;
}

.breadcrumb-item a {
  color: white;
  text-decoration: none;
}

.breadcrumb-item.active {
  color: var(--cream);
}

/* Search & Filter Section */
.search-filter-section {
  background: white;
  padding: 2rem 0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  margin-bottom: 2rem;
}

.search-box {
  border: 2px solid var(--light-green);
  border-radius: 25px;
  padding: 12px 20px;
  transition: all 0.3s ease;
}

.search-box:focus {
  border-color: var(--secondary-green);
  box-shadow: 0 0 0 3px rgba(74, 124, 89, 0.1);
  transform: scale(1.02);
}

.btn-search {
  background: var(--secondary-green);
  border: none;
  border-radius: 25px;
  padding: 12px 25px;
  color: white;
  font-weight: 600;
  transition: all 0.3s ease;
}

.btn-search:hover {
  background: var(--primary-green);
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(74, 124, 89, 0.3);
}

/* Category Filters */
.category-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 1rem;
}

.category-btn {
  background: var(--cream);
  border: 2px solid var(--light-green);
  border-radius: 25px;
  padding: 8px 20px;
  color: var(--primary-green);
  text-decoration: none;
  transition: all 0.3s ease;
  font-weight: 500;
  cursor: pointer;
}

.category-btn:hover,
.category-btn.active {
  background: var(--secondary-green);
  border-color: var(--secondary-green);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(74, 124, 89, 0.2);
}

/* Product Grid */
.products-grid {
  opacity: 1;
  transition: opacity 0.3s ease;
}

.products-grid.loading {
  opacity: 0.5;
}

.product-card {
  background: white;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  margin-bottom: 2rem;
  animation: fadeInUp 0.5s ease forwards;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.product-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 40px rgba(74, 124, 89, 0.2);
}

.product-card img {
  height: 250px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.product-card:hover img {
  transform: scale(1.05);
}

.product-card .card-body {
  padding: 1.5rem;
}

.product-price {
  color: var(--secondary-green);
  font-weight: 700;
  font-size: 1.2rem;
}

.product-old-price {
  color: #999;
  text-decoration: line-through;
  font-size: 0.9rem;
  margin-right: 10px;
}

.badge-sale {
  background: #e74c3c;
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 5px 10px;
  border-radius: 15px;
  font-size: 0.8rem;
  animation: pulse 2s infinite;
}

.badge-new {
  background: var(--accent-green);
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 5px 10px;
  border-radius: 15px;
  font-size: 0.8rem;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.05);
  }
}

.btn-action {
  transition: all 0.3s ease;
}

.btn-action:hover {
  transform: scale(1.1);
}

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

.page-link {
  color: var(--secondary-green);
  border: 2px solid var(--light-green);
  margin: 0 5px;
  border-radius: 50px;
  width: 45px;
  height: 45px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  transition: all 0.3s ease;
}

.page-link:hover,
.page-item.active .page-link {
  background: var(--secondary-green);
  border-color: var(--secondary-green);
  color: white;
  transform: scale(1.1);
}

/* Results Info */
.results-info {
  color: var(--primary-green);
  font-weight: 500;
  margin-bottom: 1rem;
}

/* Sort Options */
.sort-select {
  border: 2px solid var(--light-green);
  border-radius: 10px;
  padding: 8px 15px;
  background: white;
  transition: all 0.3s ease;
}

.sort-select:focus {
  border-color: var(--secondary-green);
  box-shadow: 0 0 0 3px rgba(74, 124, 89, 0.1);
}

/* Loading Animation */
.loading {
  display: none;
  text-align: center;
  padding: 2rem;
}

.loading.show {
  display: block;
}

.spinner {
  border: 3px solid var(--light-green);
  border-top: 3px solid var(--secondary-green);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
  margin: 0 auto 1rem;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

/* No Results */
.no-results {
  text-align: center;
  padding: 3rem;
  color: var(--primary-green);
  display: none;
}

.no-results.show {
  display: block;
}

.no-results i {
  font-size: 4rem;
  margin-bottom: 1rem;
  opacity: 0.5;
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%,
  20%,
  50%,
  80%,
  100% {
    transform: translateY(0);
  }

  40% {
    transform: translateY(-10px);
  }

  60% {
    transform: translateY(-5px);
  }
}

/* Responsive Design */
@media (max-width: 768px) {
  .page-header {
    padding: 2rem 0 1rem 0;
  }

  .category-filters {
    justify-content: center;
  }

  .search-filter-section {
    padding: 1rem 0;
  }

  .product-card {
    margin-bottom: 1rem;
  }
}

/* Smooth scroll */
html {
  scroll-behavior: smooth;
}

/* Product card entrance animation delay */
.product-card:nth-child(1) {
  animation-delay: 0.1s;
}

.product-card:nth-child(2) {
  animation-delay: 0.2s;
}

.product-card:nth-child(3) {
  animation-delay: 0.3s;
}

.product-card:nth-child(4) {
  animation-delay: 0.4s;
}

.product-card:nth-child(5) {
  animation-delay: 0.1s;
}

.product-card:nth-child(6) {
  animation-delay: 0.2s;
}

.product-card:nth-child(7) {
  animation-delay: 0.3s;
}

.product-card:nth-child(8) {
  animation-delay: 0.4s;
}

.product-card:nth-child(9) {
  animation-delay: 0.1s;
}

.product-card:nth-child(10) {
  animation-delay: 0.2s;
}

.product-card:nth-child(11) {
  animation-delay: 0.3s;
}

.product-card:nth-child(12) {
  animation-delay: 0.4s;
}
