/* ==========================================================================
   BestWallClock — Product Cards
   Dark luxury product card styling with hover effects, badges, and overlays
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Product Grid Containers
   -------------------------------------------------------------------------- */
.bwc-product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
}

.bwc-product-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

/* --------------------------------------------------------------------------
   2. Product Card Base
   -------------------------------------------------------------------------- */
.bwc-dark-products .product-card,
.product-card {
  background-color: #0a1a12;
  border-radius: 6px;
  border: 1px solid #1a1a1a;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  transition:
    transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94),
    border-color 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94),
    box-shadow 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  position: relative;
}

.bwc-dark-products .product-card:hover,
.product-card:hover {
  transform: translateY(-5px);
  border-color: #c5a059;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6);
}

/* --------------------------------------------------------------------------
   3. Product Card Image
   -------------------------------------------------------------------------- */
.product-card-image {
  display: block;
  position: relative;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  background-color: #f5f5f5;
}

.product-card-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 8px;
  transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94), opacity 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.product-card-image-hover {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.product-card-image-hover img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 8px;
}

/* Hover swap: hide primary, show hover image */
.product-card:hover .product-card-image > img:first-child {
  opacity: 0;
  transform: scale(1.05);
}

.product-card:hover .product-card-image-hover {
  opacity: 1;
}

/* --------------------------------------------------------------------------
   4. Product Badge (Sale, New, etc.)
   -------------------------------------------------------------------------- */
.product-card-badge {
  position: absolute;
  top: 15px;
  left: 15px;
  z-index: 10;
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.product-card-badge span {
  /* background-color set via inline style per badge */
  color: #ffffff;
  border-radius: 3px;
  padding: 6px 12px;
  text-transform: uppercase;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-weight: 700;
  font-size: 0.65rem;
  letter-spacing: 0.5px;
  line-height: 1;
  white-space: nowrap;
}

/* --------------------------------------------------------------------------
   5. Wishlist Button
   -------------------------------------------------------------------------- */
.product-card-wishlist {
  position: absolute;
  top: 15px;
  right: 15px;
  z-index: 10;
  width: 36px;
  height: 36px;
  background-color: rgba(3, 28, 18, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--bwc-text);
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.3s var(--bwc-ease);
}

.product-card-wishlist:hover {
  background-color: rgba(197, 160, 89, 0.2);
  border-color: var(--bwc-gold);
  color: var(--bwc-gold);
}

.product-card-wishlist.active {
  color: #e74c3c;
  border-color: #e74c3c;
}

/* --------------------------------------------------------------------------
   6. Product Card Body
   -------------------------------------------------------------------------- */
.product-card-body {
  padding: 20px 18px;
  text-align: left;
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  color: #ffffff !important;
  background-color: #0a1a12;
  min-height: 100px;
}

/* Category */
.product-card-category {
  color: #888888 !important;
  font-size: 0.7rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 8px;
  display: block !important;
}

/* Title */
.product-card-title {
  color: #ffffff !important;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.4;
  margin-bottom: 10px;
}

.product-card-title a {
  color: #ffffff !important;
  text-decoration: none;
  transition: color 0.3s ease;
}

.product-card-title a:hover {
  color: #c5a059;
}

/* --------------------------------------------------------------------------
   7. Star Rating
   -------------------------------------------------------------------------- */
.product-card-rating {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-bottom: 8px;
}

.product-card-rating .stars {
  color: #c5a059;
  font-size: 0.85rem;
}

.product-card-rating .rating-count {
  color: #888888 !important;
  font-size: 0.75rem;
}

/* --------------------------------------------------------------------------
   8. Price
   -------------------------------------------------------------------------- */
.product-card-price {
  font-family: var(--bwc-font-body);
  font-weight: 700;
  font-size: 1.15rem;
  color: #c5a059 !important;
}

.product-card-price .price-original {
  color: #777;
  font-weight: 400;
  font-size: 0.9rem;
  text-decoration: line-through;
  margin-right: 8px;
}

/* --------------------------------------------------------------------------
   9. Delivery Info
   -------------------------------------------------------------------------- */
.product-card-delivery {
  color: #aaaaaa !important;
  font-size: 0.8rem;
  font-weight: 300;
  margin-top: 10px;
  display: flex !important;
  align-items: center;
  gap: 5px;
}

.product-card-delivery svg {
  width: 16px;
  height: 16px;
  fill: #c5a059;
  flex-shrink: 0;
}

.product-card-delivery strong {
  color: #ffffff;
  font-weight: 500;
}

/* Price amount spans (WooCommerce injects .woocommerce-Price-amount) */
.product-card-price .woocommerce-Price-amount,
.product-card-price .price-sale .woocommerce-Price-amount,
.product-card-price .price-current .woocommerce-Price-amount {
  color: #c5a059 !important;
}

.product-card-price .price-original .woocommerce-Price-amount {
  color: #777 !important;
}

/* --------------------------------------------------------------------------
   10. USA Express Badge
   -------------------------------------------------------------------------- */
.bwc-express-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: linear-gradient(135deg, var(--bwc-gold), #e0c283);
  color: #000;
  font-size: 0.75rem;
  font-weight: 900;
  padding: 4px 10px;
  border-radius: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  line-height: 1;
}

.bwc-express-badge svg {
  width: 14px;
  height: 14px;
  fill: #000;
}

/* --------------------------------------------------------------------------
   11. Quick View Overlay
   -------------------------------------------------------------------------- */
.product-card-quick {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background-color: rgba(3, 28, 18, 0.85);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  padding: 15px;
  text-align: center;
  transform: translateY(100%);
  opacity: 0;
  transition:
    transform 0.4s var(--bwc-ease),
    opacity 0.4s var(--bwc-ease);
  z-index: 5;
}

.product-card:hover .product-card-quick {
  transform: translateY(0);
  opacity: 1;
}

.product-card-quick button,
.product-card-quick a {
  display: block;
  width: 100%;
  padding: 12px;
  background-color: transparent;
  border: 1px solid var(--bwc-gold);
  color: var(--bwc-gold);
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 1.5px;
  font-weight: 600;
  font-family: var(--bwc-font-body);
  cursor: pointer;
  text-decoration: none;
  text-align: center;
  transition: all 0.3s var(--bwc-ease);
}

.product-card-quick button:hover,
.product-card-quick a:hover {
  background-color: var(--bwc-gold);
  color: var(--bwc-text);
}

/* --------------------------------------------------------------------------
   12. Loading Skeleton
   -------------------------------------------------------------------------- */
.product-card-skeleton {
  background-color: var(--bwc-card-dark);
  border-radius: 6px;
  border: 1px solid var(--bwc-border);
  overflow: hidden;
}

.product-card-skeleton .skeleton-img {
  aspect-ratio: 1 / 1;
  background: linear-gradient(
    90deg,
    #1a1a1a 25%,
    #252525 50%,
    #1a1a1a 75%
  );
  background-size: 200% 100%;
  animation: bwc-shimmer 1.5s infinite;
}

.product-card-skeleton .skeleton-line {
  height: 14px;
  margin: 10px 20px;
  border-radius: 3px;
  background: linear-gradient(
    90deg,
    #1a1a1a 25%,
    #252525 50%,
    #1a1a1a 75%
  );
  background-size: 200% 100%;
  animation: bwc-shimmer 1.5s infinite;
}

.product-card-skeleton .skeleton-line:nth-child(2) { width: 60%; }
.product-card-skeleton .skeleton-line:nth-child(3) { width: 40%; height: 18px; }

@keyframes bwc-shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* --------------------------------------------------------------------------
   13. Product Card Variants
   -------------------------------------------------------------------------- */

/* Featured / Large Card */
.product-card--featured {
  grid-column: span 2;
  grid-row: span 2;
}

.product-card--featured .product-card-image {
  aspect-ratio: auto;
  height: 100%;
}

/* Compact Card */
.product-card--compact .product-card-body {
  padding: 15px;
}

.product-card--compact .product-card-title {
  font-size: 0.85rem;
}

/* --------------------------------------------------------------------------
   14. Compare Checkbox (optional feature)
   -------------------------------------------------------------------------- */
.product-card-compare {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
  font-size: 0.75rem;
  color: var(--bwc-text-muted);
}

.product-card-compare input[type="checkbox"] {
  accent-color: var(--bwc-gold);
  width: 14px;
  height: 14px;
}
