/* کارت‌های تخفیف روی قاب‌های اسپرت بنر لوکسی — لایهٔ جدا، هم‌سطح .luxy-groups.
   فونت ارث‌بری می‌شود (بدون font-family)؛ letter-spacing فقط روی برند لاتین پایه. اندازه‌ها نسبت به عرض قاب (cqw). */
.luxy-banner-wrap { position: relative; }

.luxy-sale-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 2;
}

.luxy-sale-slot {
  position: absolute;
  container-type: inline-size;
  pointer-events: none;
}

.luxy-sale-card {
  --lsc-gold: #d9b25f;
  --lsc-gold2: #f0d78a;
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: clamp(4px, 3cqw, 10px);
  padding: clamp(7px, 5.5cqw, 16px) clamp(7px, 6cqw, 18px) clamp(7px, 5cqw, 15px);
  color: #fff;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  opacity: 0;
  pointer-events: none;
}

.luxy-sale-card.is-in {
  animation: lsc-in 0.3s ease-out both;
}

/* فقط عکس و کادر قیمت کلیک‌پذیرند؛ بقیهٔ قاب همان لینک فروش ویژه می‌ماند */
.luxy-sale-card.is-in .lsc-media,
.luxy-sale-card.is-in .lsc-info { pointer-events: auto; }

.luxy-sale-card.is-out {
  pointer-events: none;
  animation: lsc-out 0.3s ease-in both;
}

@keyframes lsc-in {
  from { opacity: 0; transform: scale(0.94); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes lsc-out {
  from { opacity: 1; }
  to { opacity: 0; }
}

/* ===== ظاهر ویترینی (۲۰۲۶-۱۰-۱۹): شیشهٔ روشن با لبهٔ طلایی، محصول معلق، برچسب قرمز،
   پایهٔ سرمه‌ای با برند (حروف کشیده)، قیمت قبلی خط‌خورده و قیمت جدید طلایی.
   فقط ظاهر؛ زمان‌بندی و رفتار در luxy-sale-cards.js دست نخورده. ===== */
.lsc-box {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  border-radius: clamp(10px, 6cqw, 16px);
  overflow: hidden;
  isolation: isolate;
  background: radial-gradient(120% 90% at 50% 18%, #ffffff 0%, #f3f6fa 55%, #dfe6ef 100%);
  border: 1px solid var(--lsc-gold);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 0 0 1px rgba(240, 215, 138, 0.25),
    0 10px 22px -10px rgba(0, 0, 0, 0.6);
}
/* هایلایت شیشه */
.lsc-box::before {
  content: '';
  position: absolute;
  inset: 0 0 auto;
  height: 42%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0));
  pointer-events: none;
  z-index: 2;
}

/* محصول معلق */
.lsc-stage {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: clamp(6px, 5cqw, 14px) clamp(6px, 5cqw, 14px) clamp(8px, 6cqw, 16px);
}

.lsc-media {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  overflow: hidden;
  animation: lsc-float 3.2s ease-in-out infinite;
}

.lsc-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  mix-blend-mode: multiply; /* زمینهٔ سفید عکس روی شیشه محو می‌شود */
}

@keyframes lsc-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}

/* یک‌بار نور طلایی از روی شیشه، ۰٫۱۵ث بعد از ورود، ۰٫۶ث */
.lsc-box::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 35%, rgba(240, 215, 138, 0.5) 50%, transparent 65%);
  transform: translateX(-130%);
  pointer-events: none;
  z-index: 3;
}

.luxy-sale-card.is-in .lsc-box::after {
  animation: lsc-sheen 0.6s ease-in-out 0.15s both;
}

@keyframes lsc-sheen {
  from { transform: translateX(-130%); }
  to { transform: translateX(130%); }
}

/* سایهٔ بیضی محو زیر محصول */
.lsc-floor {
  position: absolute;
  left: 50%;
  bottom: clamp(3px, 2.5cqw, 8px);
  width: 56%;
  height: clamp(5px, 3.5cqw, 10px);
  transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(13, 40, 61, 0.35), transparent);
  pointer-events: none;
}

/* برچسب درصد — «X٪» (بدون منفی) */
.lsc-pct {
  position: absolute;
  z-index: 4;
  top: clamp(5px, 3.5cqw, 10px);
  right: clamp(5px, 3.5cqw, 10px);
  padding: clamp(2px, 1.2cqw, 4px) clamp(6px, 3.2cqw, 10px);
  border-radius: 999px;
  background: var(--nx-sale-red, #e23a3a);
  color: #fff;
  font-size: clamp(10px, 5.2cqw, 15px);
  font-weight: 800;
  line-height: 1.3;
  white-space: nowrap;
  box-shadow: 0 2px 6px rgba(140, 20, 20, 0.35);
}

.luxy-sale-card.is-in .lsc-pct {
  animation: lsc-pop 0.25s ease-out 0.15s both;
}

@keyframes lsc-pop {
  0% { transform: scale(0.6); }
  70% { transform: scale(1.12); }
  100% { transform: scale(1); }
}

/* پایهٔ سرمه‌ای */
.lsc-info {
  position: relative;
  z-index: 4;
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(1px, 0.8cqw, 3px);
  padding: clamp(4px, 2.8cqw, 9px) clamp(5px, 3cqw, 10px);
  background: linear-gradient(180deg, #1b3a52 0%, #0d283d 70%, #081b2a 100%);
  border-top: 1px solid rgba(217, 178, 95, 0.55);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
  line-height: 1.35;
  text-align: center;
}

.lsc-brand {
  display: block;
  max-width: 100%;
  overflow: hidden;
  white-space: nowrap;
  color: var(--lsc-gold2);
  font-size: clamp(9px, 4.2cqw, 13px);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.22em; /* فقط برند لاتین؛ فارسی پایین normal می‌شود */
  padding-left: 0.22em;
}
.lsc-brand.is-fa { letter-spacing: normal; padding-left: 0; }

.lsc-prices {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: clamp(4px, 2.5cqw, 8px);
  max-width: 100%;
  overflow: hidden;
  white-space: nowrap;
}

.lsc-old {
  color: rgba(255, 255, 255, 0.62);
  font-size: clamp(9px, 4.2cqw, 12px);
  text-decoration-color: rgba(226, 58, 58, 0.95);
}

.lsc-new {
  color: #e6c77a;
  font-size: clamp(10px, 5.6cqw, 16px);
  font-weight: 800;
}

.luxy-sale-card.no-brand .lsc-brand,
.luxy-sale-card.no-old .lsc-old { display: none; }

/* قاب‌های کوچک: بدون برند؛ کوچک‌تر: بدون قیمت قبلی */
@container (max-width: 175px) {
  .lsc-brand { display: none; }
}

@container (max-width: 140px) {
  .lsc-old { display: none; }
}

/* حرکت کمتر: فقط محو شدن ساده */
.luxy-sale-card.is-reduced.is-in { animation-name: lsc-fade-in; }
.luxy-sale-card.is-reduced.is-in .lsc-box::after,
.luxy-sale-card.is-reduced.is-in .lsc-pct,
.luxy-sale-card.is-reduced .lsc-media { animation: none; }

@keyframes lsc-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .luxy-sale-card.is-in { animation-name: lsc-fade-in; }
  .luxy-sale-card.is-in .lsc-box::after,
  .luxy-sale-card.is-in .lsc-pct,
  .lsc-media { animation: none; }
}
