/* HAVEN MALL - Catalog & Item Cards */

.catalog-section {
  padding: 2.5rem 0 5rem;
  flex: 1;
}

.catalog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.8rem;
}

.items-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
}

/* Item Card Component */
.item-card {
  background-color: var(--bg-card);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  overflow: hidden;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  position: relative;
  box-shadow: var(--shadow-sm);
}

.item-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
  border-color: rgba(31, 40, 42, 0.3);
}

.item-card-image {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background-color: var(--bg-subtle);
}

.item-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.item-card-image::after {
  content: "HAVEN MALL";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(-15deg);
  font-family: 'Kalam', 'Comic Sans MS', cursive;
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: 2px;
  white-space: nowrap;
  color: rgba(255, 255, 255, 0.55);
  -webkit-text-stroke: 1px rgba(31, 40, 42, 0.35);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
  z-index: 2;
  pointer-events: none;
  user-select: none;
}

.item-card:hover .item-card-image img {
  transform: scale(1.06);
}

.item-badge-top {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 5;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* Wishlist Heart Button */
.wishlist-heart-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 5;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
  opacity: 1;
  transform: scale(1);
}

.item-card:hover .wishlist-heart-btn {
  opacity: 1;
  transform: scale(1);
}

/* Always show if active (wishlisted) */
.wishlist-heart-btn.active {
  opacity: 1;
  transform: scale(1);
}

.wishlist-heart-btn i {
  font-size: 1.05rem;
  color: var(--text-muted);
  transition: color 0.2s ease, transform 0.2s ease;
}

.wishlist-heart-btn:hover {
  background: #ffffff;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
  transform: scale(1.08);
}

.wishlist-heart-btn:hover i {
  color: var(--sale-red);
}

.wishlist-heart-btn.active i {
  color: var(--sale-red);
}

/* Pop animation on toggle */
@keyframes heartPop {
  0% { transform: scale(1); }
  30% { transform: scale(1.3); }
  60% { transform: scale(0.9); }
  100% { transform: scale(1); }
}

.wishlist-heart-btn.pop {
  animation: heartPop 0.4s ease;
}

.item-card-body {
  padding: 1.3rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.item-category-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--primary-accent);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.4rem;
}

.item-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.6rem;
  color: var(--text-main);
  line-height: 1.3;

  /* Clamp lines */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.item-description-short {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 1.2rem;
  line-height: 1.4;

  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.item-footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 1rem;
  border-top: 1px dashed var(--border-color);
}

.item-price {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 800;
  color: #166534;
}

.item-card .btn-primary {
  padding: 0.6rem 1.2rem;
  font-size: 0.9rem;
}

.item-card .btn-whatsapp {
  background-color: #00A859;
  color: #ffffff;
  font-weight: 800;
  padding: 0.6rem 1.2rem;
  font-size: 0.85rem;
  letter-spacing: 0.5px;
  transition: all 0.25s ease;
}

.item-card .btn-whatsapp:hover {
  background-color: #00875A;
  transform: translateY(-2px);
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 4rem 1rem;
  grid-column: 1 / -1;
}

.empty-state i {
  font-size: 3.5rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
}
