/* 🌈 Algemene instellingen */
:root {
  --primary-color: #7464f3;
  --secondary-color: #6C63AC;
  --light-bg: #fff7fb;
  --card-bg: #ffffff;
  --text-dark: #333;
  --shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Segoe UI', sans-serif;
  background-color: #fafafa;
  color: var(--text-dark);
  margin: 0;
  padding: 0;
}

/* 🛍️ Sectie titel */
.all-products-section {
  padding: 60px 20px;
  background-color: var(--light-bg);
  text-align: center;
}

.all-products-section h2 {
  font-size: 32px;
  color: var(--secondary-color);
  margin-bottom: 20px;
}

/* 🔍 Zoekveld */
.search-wrapper {
  margin: 0 auto 40px;
  max-width: 500px;
}

#searchInput {
  width: 100%;
  padding: 12px 16px;
  font-size: 16px;
  border: 2px solid var(--secondary-color);
  border-radius: 10px;
  outline: none;
  box-shadow: var(--shadow);
  transition: border 0.3s ease;
}

#searchInput:focus {
  border-color: var(--primary-color);
}

/* 📦 Productweergave */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 10px;
  align-items: stretch; /* Zorgt dat alle kaarten gelijke hoogte hebben */
}


.product-card {
  background-color: var(--card-bg);
  border-radius: 15px;
  padding: 20px;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease-in-out;
  text-align: left;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  height: 100%;
}

.product-card:hover {
  transform: translateY(-5px);
}

.product-card img {
  width: 100%;
  height: auto;
  border-radius: 10px;
  margin-bottom: 15px;
  max-height: 230px;
  object-fit: contain;
}

.product-card h3 {
  font-size: 20px;
  color: var(--secondary-color);
  margin-bottom: 10px;
  min-height: 48px; /* 2 regels */
}

.product-card p {
  font-size: 15px;
  color: var(--text-dark);
  margin-bottom: 20px;
  min-height: 42px;
  flex-grow: 1; /* Zorgt dat deze ruimte opvult */
}



/* 👉 CTA knop */
.fun-button {
  margin-top: auto; /* Altijd onderaan */
  align-self: center; /* Voor perfecte uitlijning */
  text-align: center;
  display: inline-block;
  background-color: var(--primary-color);
  color: #fff;
  padding: 12px 20px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s ease;
}

.fun-button:hover {
  background-color: var(--primary-color);
  transform: scale(1.05);
}

.fun-button:focus-visible {
  outline: 3px solid var(--primary-color);
  outline-offset: 2px;
}

/* 🔝 Scroll-knop */
.scroll-to-top-btn {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: var(--primary-color);
  color: white;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  font-size: 20px;
  cursor: pointer;
  box-shadow: var(--shadow);
  display: none;
  z-index: 999;
}

.scroll-to-top-btn.show {
  display: block;
}

/* 📱 Mobiel */
@media (max-width: 768px) {
  .product-card {
    text-align: center;
  }

  .fun-button {
    width: 100%;
  }
}

@media (max-width: 500px) {
  .product-card {
    padding: 15px 12px;
  }
}

/* 🧠 FILTERS */
.filter-bar {
  margin: 0 auto 40px;
  max-width: 1000px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

.filter-btn {
  padding: 10px 18px;
  background-color: var(--card-bg);
  border: 2px solid var(--secondary-color);
  color: var(--secondary-color);
  border-radius: 8px;
  cursor: pointer;
  font-size: 15px;
  font-weight: 500;
  transition: all 0.3s ease, transform 0.2s ease;
}

.filter-btn:hover {
  background-color: var(--secondary-color);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.filter-btn.active {
  background-color: var(--secondary-color);
  color: white;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.filter-btn:focus-visible {
  outline: 3px solid var(--primary-color);
  outline-offset: 2px;
}


@media (max-width: 768px) {
  .product-grid {
    gap: 20px;
    padding: 0 5px;
  }

  .product-card {
    padding: 15px;
    box-shadow: none;
    border: 1px solid #eee;
  }

  .product-card img {
    max-height: 180px;
  }

  .product-card h3 {
    font-size: 18px;
  }

  .product-card p {
    font-size: 14px;
    margin-bottom: 15px;
  }

  .fun-button {
    font-size: 15px;
    padding: 10px;
  }
}
