/* style.css */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: Arial, sans-serif;
  background: #f7f7f7;
  padding: 20px;
}

.bundle-container {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 20px;
  flex: 2;
}

.product-card {
  background: #fff;
  padding: 15px;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  text-align: center;
  transition: transform 0.2s;
}

.product-card:hover {
  transform: translateY(-5px);
}

.product-card img {
  width: 100%;
  border-radius: 8px;
  margin-bottom: 10px;
}

.toggle-btn {
  background-color: #0070f3;
  color: white;
  padding: 8px 12px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  margin-top: 10px;
}

.toggle-btn.active {
  background-color: #28a745;
}

.sidebar {
  flex: 1;
  background: #fff;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  position: sticky;
  top: 20px;
  height: fit-content;
  min-width: 280px;
}

.progress-bar {
  margin-bottom: 10px;
  position: relative;
  background: #eee;
  height: 10px;
  border-radius: 5px;
  overflow: hidden;
}

.progress {
  background: #0070f3;
  height: 100%;
  width: 0%;
  transition: width 0.3s;
}

.progress-text {
  display: block;
  margin-top: 8px;
  font-size: 14px;
}

.selected-products {
  list-style: none;
  margin-top: 10px;
  margin-bottom: 10px;
}

.selected-products li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.selected-products img {
  width: 40px;
  height: 40px;
  border-radius: 5px;
  margin-right: 10px;
}

.cta-btn {
  width: 100%;
  padding: 10px;
  background: #0070f3;
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: 16px;
  cursor: pointer;
  margin-top: 10px;
}

.cta-btn:disabled {
  background: #ccc;
  cursor: not-allowed;
}

.discount {
  color: #28a745;
  font-weight: bold;
  margin-top: 10px;
}
.cta-btn.added {
  background-color: green;
  color: white;
  cursor: not-allowed;
}

@media (max-width: 768px) {
  .bundle-container {
    flex-direction: column;
  }

  .sidebar {
    position: relative;
    top: auto;
  }
}

.toggle-btn.animate {
  animation: bounce 0.3s ease;
}

@keyframes bounce {
  0% { transform: scale(1); }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); }
}

.quantity {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 5px;
}

.qty-btn {
  width: 24px;
  height: 24px;
  background: #eee;
  border: none;
  font-weight: bold;
  cursor: pointer;
}

.qty-value {
  min-width: 20px;
  text-align: center;
}

.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.cart-content {
  background: #fff;
  padding: 30px;
  border-radius: 8px;
  max-width: 400px;
  text-align: center;
  animation: fadeIn 0.4s ease;
}

.cart-content ul {
  list-style: none;
  padding: 0;
  margin: 15px 0;
  text-align: left;
}

.cart-content button {
  margin-top: 10px;
  padding: 10px 16px;
  background: black;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
