
:root {
  --tzedek-green: rgb(34, 197, 94);
  --tzedek-green-dark: rgb(22, 163, 74);
  --tzedek-green-light: rgb(187, 247, 208);
  --tzedek-gold: rgb(234, 179, 8);
  --tzedek-gold-dark: rgb(202, 138, 4);
  --tzedek-gold-light: rgb(254, 240, 138);
  --white: #ffffff;
  --black: #000000;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;
  
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.1);
  --shadow-md: 0 4px 6px rgba(0,0,0,0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
  background-color: var(--gray-50);
  color: var(--gray-700);
  line-height: 1.6;
}

.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
}

@media (min-width: 1024px) {
  .container {
      padding: 0 2rem;
  }
}

/* Navbar Styles */
.navbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background-color: var(--white);
  box-shadow: var(--shadow-sm);
  padding: 10px 0;
}

.navbar-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.navbar-logo .logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--tzedek-green);
  text-decoration: none;
}

.navbar-links {
  display: flex;
  gap: 2rem;
}

.nav-link {
  color: var(--gray-700);
  text-decoration: none;
  font-weight: 500;
  position: relative;
  padding: 8px 0;
  transition: color 0.3s ease;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--tzedek-green);
  transition: width 0.3s ease;
}

.nav-link:hover {
  color: var(--tzedek-green);
}

.nav-link:hover::after {
  width: 100%;
}

.nav-link.active {
  color: var(--tzedek-green);
}

.nav-link.active::after {
  width: 100%;
}

.navbar-auth {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.cart-icon {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: var(--gray-100);
  color: var(--gray-700);
  text-decoration: none;
  transition: all 0.3s;
}

.cart-icon:hover {
  background-color: var(--tzedek-green-light);
  color: var(--tzedek-green);
}

.cart-count {
  position: absolute;
  top: -5px;
  right: -5px;
  background-color: #ef4444;
  color: var(--white);
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 600;
}

.mobile-menu-button {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.5rem;
  color: var(--gray-700);
}

.mobile-menu-button i {
  font-size: 1.5rem;
}

.navbar {
  position: relative;
}

.mobile-nav {
  display: none;
  background-color: var(--white);
  position: fixed;
  top: 60px;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
  overflow-y: auto;
}

.mobile-nav.show {
  display: block;
}

.mobile-nav .container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1rem;
}

.mobile-nav .nav-link {
  display: block;
  padding: 1rem;
  border-bottom: 1px solid var(--gray-200);
  color: var(--gray-700);
  font-weight: 500;
  transition: all 0.3s ease;
}

.mobile-nav .nav-link:hover {
  background-color: var(--gray-100);
  color: var(--tzedek-green);
}

.mobile-nav .nav-link:last-child {
  border-bottom: none;
}

.mobile-nav .btn-primary {
  margin: 1rem 0;
  justify-content: center;
  width: 100%;
}

.hidden {
  display: none !important;
}

@media (max-width: 768px) {
  .navbar-content {
    padding: 0.5rem 1rem;
    height: 60px; /* Fixed height for navbar */
  }

  .desktop-nav {
    display: none !important;
  }
  
  .mobile-menu-button {
    display: flex;
    align-items: center;
    gap: 1rem;
  }

  .mobile-menu-button button {
    background: none;
    border: none;
    padding: 0.5rem;
    cursor: pointer;
    color: var(--gray-700);
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .mobile-menu-button button i {
    font-size: 1.5rem;
  }
  
  /* Show cart icon in mobile view */
  .cart-icon {
    display: flex !important;
    margin-right: 0.5rem;
  }

  .mobile-nav .nav-link.active {
    color: var(--tzedek-green);
    background-color: var(--tzedek-green-light);
  }
  
  .navbar-logo .logo {
    font-size: 1.25rem;
  }
}



/* Buttons */
.btn-primary {
  background-color: var(--tzedek-green);
  color: var(--white);
  padding: 12px 18px;
  border-radius: var(--radius-md);
  text-decoration: none;
  font-weight: 600;
  transition: background-color 0.3s;
  font-size: 14px;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

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

.btn-outline {
  background-color: transparent;
  color: var(--tzedek-green);
  padding: 8px 16px;
  border-radius: var(--radius-md);
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s;
  font-size: 14px;
  border: 1px solid var(--tzedek-green);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-outline:hover {
  background-color: var(--tzedek-green-light);
}

/* Products Page */
.products-page {
  padding: 2rem 0;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.section-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--gray-900);
}

.search-container {
  position: relative;
  display: flex;
  align-items: center;
  max-width: 400px;
  width: 100%;
}

.search-container i {
  position: absolute;
  left: 12px;
  color: var(--gray-500);
}

.search-container input {
  width: 100%;
  padding: 10px 10px 10px 40px;
  border: 1px solid var(--gray-300);
  border-radius: var(--radius-md);
  font-size: 16px;
  transition: all 0.3s;
}

.search-container input:focus {
  outline: none;
  border-color: var(--tzedek-green);
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.1);
}

.products-container {
  display: grid;
  grid-template-columns: 250px 1fr;
  gap: 2rem;
}

.filters {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  height: fit-content;
  position: sticky;
  top: 100px;
}

.filter-section {
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--gray-200);
}

.filter-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.filter-section h3 {
  margin-bottom: 1rem;
  font-size: 1rem;
  font-weight: 600;
  color: var(--gray-900);
}

.filter-options {
  list-style: none;
}

.filter-options li {
  margin-bottom: 0.5rem;
}

.filter-options label {
  display: flex;
  align-items: center;
  cursor: pointer;
  font-size: 14px;
}

.filter-options input {
  margin-right: 0.75rem;
  accent-color: var(--tzedek-green);
}

.price-range-container {
  margin-top: 1rem;
}

.price-range {
  width: 100%;
  margin-bottom: 0.5rem;
}

.price-display {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  color: var(--gray-600);
}

.filter-actions {
  margin-top: 1.5rem;
}

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

.product-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
  position: relative;
  display: flex;
  flex-direction: column;
}

.product-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.product-image {
  height: 180px;
  width: 100%;
  position: relative;
  overflow: hidden;
}

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

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

.product-info {
  padding: 1.25rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.product-category {
  color: var(--tzedek-green);
  font-size: 0.875rem;
  margin-bottom: 0.5rem;
  text-transform: capitalize;
}

.product-title {
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--gray-900);
  line-height: 1.3;
}

.product-description {
  color: var(--gray-600);
  font-size: 0.875rem;
  margin-bottom: 0.75rem;
  line-height: 1.4;
  flex: 1;
}

.product-price {
  font-weight: 700;
  color: var(--tzedek-green);
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

.product-actions {
  display: flex;
  gap: 0.5rem;
}

.product-actions .btn-primary,
.product-actions .btn-outline {
  flex: 1;
  justify-content: center;
  font-size: 13px;
  padding: 8px 12px;
}

.no-products {
  grid-column: 1 / -1;
  text-align: center;
  padding: 3rem;
  color: var(--gray-500);
}

/* Toast Notification */
.toast {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background-color: var(--tzedek-green);
  color: var(--white);
  padding: 15px 20px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 10px;
  z-index: 1000;
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.3s ease;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

.toast i {
  font-size: 20px;
}

/* Footer */
.footer {
  background-color: var(--gray-900);
  color: var(--white);
  padding: 3rem 0 1.5rem;
  margin-top: 3rem;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-column h3 {
  font-size: 18px;
  margin-bottom: 1rem;
  color: var(--white);
}

.footer-column p {
  margin-bottom: 1rem;
  opacity: 0.8;
  font-size: 14px;
}

.footer-social {
  display: flex;
  gap: 10px;
}

.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  color: var(--white);
  text-decoration: none;
  transition: background-color 0.3s;
}

.social-icon:hover {
  background-color: var(--tzedek-green);
}

.footer-links {
  list-style: none;
}

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

.footer-links a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  transition: color 0.3s;
  font-size: 14px;
}

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

.footer-contact li {
  margin-bottom: 0.5rem;
  opacity: 0.8;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer-bottom {
  text-align: center;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  opacity: 0.7;
  font-size: 14px;
}

.footer-bottom a {
  color: var(--tzedek-green);
  text-decoration: none;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .products-container {
      grid-template-columns: 220px 1fr;
  }
}

@media (max-width: 768px) {
  .products-container {
      grid-template-columns: 1fr;
  }
  
  .filters {
      position: static;
      margin-bottom: 1.5rem;
  }
  
  .section-header {
      flex-direction: column;
      align-items: flex-start;
  }
  
  .search-container {
      max-width: 100%;
  }
  
  .products-listing {
      grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  }
}

@media (max-width: 640px) {
  .products-listing {
      grid-template-columns: 1fr 1fr;
  }
  
  .product-actions {
      flex-direction: column;
  }
}

@media (max-width: 480px) {
  .products-listing {
      grid-template-columns: 1fr;
  gap: 1rem;
  padding: 0;
  margin: 0;
  width: 100%;
  overflow-x: hidden;
  box-sizing: border-box;
  display: grid;
  grid-template-columns: 1fr;
}
  
  .product-card {
      width: 100%;
      margin: 0;
      box-sizing: border-box;
  }
  
  .section-title {
      font-size: 20px;
  }
  
  .search-container {
      width: 100%;
  }
}

/* Mobile Filter Toggle */
.mobile-filter-toggle {
  display: none;
  background-color: var(--tzedek-green);
  color: var(--white);
  border: none;
  border-radius: var(--radius-md);
  padding: 10px 15px;
  font-weight: 600;
  cursor: pointer;
  margin-bottom: 1rem;
  width: 100%;
  justify-content: center;
  align-items: center;
  gap: 8px;
}

@media (max-width: 768px) {
  .mobile-filter-toggle {
      display: flex;
  }
  
  .filters {
      display: none;
  }
  
  .filters.show {
      display: block;
  }
}
/* Product Card Cart Icon */
.product-card {
  position: relative;
}

.product-image {
  position: relative;
  overflow: hidden;
}

.add-to-cart-icon {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 45px;
  height: 45px;
  background-color: #fff;
  border: none;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
  transition: all 0.3s ease;
  z-index: 10;
  opacity: 0;
  transform: scale(0.8);
}

.product-card:hover .add-to-cart-icon {
  opacity: 1;
  transform: scale(1);
}

.add-to-cart-icon:hover {
  background-color: rgb(34, 197, 94);
  color: #fff;
  transform: scale(1.1);
  box-shadow: 0 4px 12px rgba(34, 197, 94, 0.3);
}

.add-to-cart-icon:disabled {
  cursor: not-allowed;
  opacity: 0.7;
}

.add-to-cart-icon.added {
  background-color: rgb(34, 197, 94);
  color: #fff;
}

.add-to-cart-icon i {
  font-size: 18px;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
  .add-to-cart-icon {
    opacity: 1;
    transform: scale(1);
    width: 40px;
    height: 40px;
  }

  .add-to-cart-icon i {
    font-size: 16px;
  }
}
