/* Row of cards */
.raven-sale-images {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 20px;
  margin: 20px auto;
  max-width: 1200px;
}

/* Each card: 3 per row */
.sale-item {
  flex: 0 0 calc(33.333% - 20px); /* 3 per row */
  box-sizing: border-box;
  display: flex;                  /* make image + info side by side */
  align-items: flex-start;
  gap: 12px;
  background: #fff;
  padding: 12px;
  border-radius: 6px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

/* Image box */
.img-wrapper {
  position: relative;
  width: 150px;   /* fixed image width */
  flex-shrink: 0; /* prevent shrinking */
}

/* Image */
.img-wrapper img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

/* Discount badge: cover ~15% of image width */
.discount-badge {
  position: absolute;
  top: 0;
  right: 0;
  width: 0;
  height: 0;
  border-top: 25% solid red;          /* 25% of wrapper height */
  border-left: 25% solid transparent; /* 25% of wrapper width */
}

.discount-badge::after {
  content: attr(data-discount);
  position: absolute;
  top: -28px;       /* adjust to sit inside triangle */
  right: -6px;
  transform: rotate(45deg);
  color: #fff;
  font-size: 14px;
  font-weight: bold;
  line-height: 1;
}



/* Price line: keep old and new price side by side */
.info p {
  margin: 4px 0;
  white-space: nowrap; /* keep all in one line */
}

.info p strong,
.old-price,
.new-price {
  display: inline-block;
  vertical-align: middle;
}
.old-price {
  text-decoration: line-through;
  color: #888;
  margin: 0 8px;
}
.new-price {
  font-weight: bold;
  color: #e60000;
}

/* Responsive */
@media (max-width: 900px) {
  .sale-item { flex: 0 0 calc(50% - 20px); }
}
@media (max-width: 600px) {
  .sale-item { flex: 0 0 100%; flex-direction: column; text-align: center; }
  .img-wrapper { margin: 0 auto 10px; }
}
