/* =========================
   SPG INFO SECTION - Standard
   Mobile: horizontal scroll
   Desktop: 5 cards in one row
   ========================= */

.spg-info-section{
  padding: 70px 16px;
  background:
    radial-gradient(circle at 30% 40%, rgba(153, 64, 153, 0.15), transparent 40%),
    radial-gradient(circle at 70% 60%, rgba(170, 80, 170, 0.12), transparent 40%),
    linear-gradient(135deg, #f7f2fa, #ffffff);
}

/* دسکتاپ: 5 تا تو یک ردیف */
.spg-info-grid{
  max-width: 1300px;
  margin: auto;

  display: flex;
  flex-wrap: nowrap;              /* ✅ یک ردیف */
  justify-content: space-between; /* ✅ پخش یکنواخت */
  gap: 18px;                      /* ✅ ظریف‌تر از 60 */
}

/* کارت‌ها فقط داخل info-section */
.spg-info-section .spg-card{
  position: relative;
  flex: 0 0 calc((100% - 72px) / 5); /* ✅ 5 کارت + 4 گپ * 18px = 72px */
  aspect-ratio: 1 / 1;
  height: auto;

  border-radius: 34px;            /* کمی ظریف‌تر */
  overflow: hidden;

  background: rgba(255,255,255,0.28);
  backdrop-filter: blur(12px);

  box-shadow: 0 4px 18px rgba(0,0,0,.06);
  transition: transform .25s ease, box-shadow .25s ease;
  text-decoration: none;
  cursor: pointer;
}

.spg-info-section .spg-card:hover{
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(153,64,153,.18);
}

/* تصاویر */
.spg-info-section .spg-card img.main,
.spg-info-section .spg-card img.hover{
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity .25s ease;
  pointer-events: none;
}

.spg-info-section .spg-card img.hover{ opacity: 0; }

@media (hover: hover) and (pointer: fine){
  .spg-info-section .spg-card:hover img.main{ opacity: 0; }
  .spg-info-section .spg-card:hover img.hover{ opacity: 1; }
}

.spg-info-section .spg-card.is-pressed img.main{ opacity: 0 !important; }
.spg-info-section .spg-card.is-pressed img.hover{ opacity: 1 !important; }

/* عنوان */
.spg-info-section .spg-title{
  position: absolute;
  bottom: 0;
  width: 100%;
  padding: 12px 10px;

  background: rgba(255,255,255,.38);
  backdrop-filter: blur(8px);

  text-align: center;
  font-weight: 800;
  font-size: 15px;
  color: #2b2b2b;

  border-radius: 0 0 34px 34px;
  z-index: 3;

  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis; /* ✅ مثل دیجی‌کالا */
}

/* ====== Mobile: horizontal scroll ====== */
@media (max-width: 768px){
  .spg-info-section{
    padding: 40px 12px;
  }

  .spg-info-grid{
    max-width: 100%;
    flex-wrap: nowrap;        /* ✅ اسکرول افقی */
    justify-content: flex-start;
    gap: 12px;

    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;

    scroll-snap-type: x mandatory;
    scroll-padding-inline: 10px;

    padding-inline: 6px;
    scrollbar-width: none;
  }
  .spg-info-grid::-webkit-scrollbar{ display:none; }

  .spg-info-section .spg-card{
    flex: 0 0 78%;       /* ✅ اندازه کارت در موبایل */
    max-width: 78%;
    border-radius: 28px;
    scroll-snap-align: start;
  }

  .spg-info-section .spg-title{
    font-size: 14px;
    padding: 10px 10px;
    border-radius: 0 0 28px 28px;
  }
}

/* سایزهای میانی: اگر خیلی تنگ شد 4تایی بشه (اختیاری ولی کمک‌کننده) */
@media (min-width: 769px) and (max-width: 1100px){
  .spg-info-grid{
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
  }
  .spg-info-section .spg-card{
    flex: 0 0 calc((100% - 48px) / 3); /* 3 تا در ردیف */
  }
}


/* =========================================
   FIX: بازگشت استایل کارت‌های spg-info
   (مربع شدن + جلوگیری از کشیدگی موبایل)
   ========================================= */

/* خود کارت مربع باشد */
.spg-info-section .spg-card{
  position: relative;
  width: 460px;
  aspect-ratio: 1 / 1;   /* ✅ مربع */
  height: auto;          /* ✅ هر height قبلی را خنثی می‌کند */
  border-radius: 45px;
  overflow: hidden;
  background: rgba(255,255,255,0.28);
  backdrop-filter: blur(12px);
  box-shadow: 0 4px 20px rgba(0,0,0,.06);
  transition: transform .3s ease, box-shadow .3s ease;
  text-decoration: none;
  cursor: pointer;
}

/* هاور */
.spg-info-section .spg-card:hover{
  transform: scale(1.03);
  box-shadow: 0 10px 30px rgba(153,64,153,.25);
}

/* تصاویر دقیقاً کل کارت را پر کنند */
.spg-info-section .spg-card img.main,
.spg-info-section .spg-card img.hover{
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity .25s ease;
  pointer-events: none;
}

/* کنترل هاور تصویر */
.spg-info-section .spg-card img.hover{ opacity: 0; }

@media (hover: hover) and (pointer: fine){
  .spg-info-section .spg-card:hover img.main{ opacity: 0; }
  .spg-info-section .spg-card:hover img.hover{ opacity: 1; }
}

.spg-info-section .spg-card.is-pressed img.main{ opacity: 0 !important; }
.spg-info-section .spg-card.is-pressed img.hover{ opacity: 1 !important; }

/* عنوان پایین کارت */
.spg-info-section .spg-title{
  position: absolute;
  bottom: 0;
  width: 100%;
  padding: 14px 0;
  background: rgba(255,255,255,.35);
  backdrop-filter: blur(6px);
  text-align: center;
  font-weight: 700;
  font-size: 18px;
  color: #333;
  border-radius: 0 0 45px 45px;
  z-index: 3;
}

/* موبایل: کارت‌ها مربع و ریسپانسیو */
@media (max-width: 768px){
  .spg-info-section .spg-card{
    width: 90%;
    aspect-ratio: 1 / 1; /* ✅ مربع در موبایل */
    height: auto;        /* ✅ جلوگیری از کشیدگی */
  }
  .spg-info-section .spg-title{ font-size: 17px; }
}
/*  دکمه های  زیر بنر */
/* ─── Home Actions ─── */
/* ─── Home Actions ─── */
.home-actions {
  width: 92%;
  max-width: 1120px;
  margin: 22px auto 34px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.home-action-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 16px;
  border-radius: 16px;
  background: #fff;
  border: 0.5px solid rgba(0, 0, 0, .08);
  text-decoration: none;
  color: inherit;
  transition: border-color .18s ease, background .18s ease;
}

.home-action-card:hover {
  border-color: rgba(0, 0, 0, .16);
  background: #f9f9f9;
}

.home-action-card .action-icon {
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  border-radius: 12px;
  background: #fafafa;
  border: 0.5px solid rgba(0, 0, 0, .08);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: #7F2A7D;
}

.home-action-card .action-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  text-align: right;
  flex: 1;
}

.home-action-card .action-info strong {
  font-size: 13.5px;
  font-weight: 600;
  color: #1a1a1a;
  line-height: 1.3;
}

.home-action-card .action-info span {
  font-size: 11.5px;
  color: #888;
}

.home-action-card .action-arrow {
  font-size: 14px;
  color: #ccc;
  flex-shrink: 0;
  transition: color .18s ease;
}

.home-action-card:hover .action-arrow {
  color: #7F2A7D;
}

/* ─── موبایل ─── */
@media (max-width: 768px) {
  .home-actions {
    width: 92%;
    margin: 10px auto 22px;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }

  .home-action-card {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 14px 8px;
    border-radius: 14px;
    text-align: center;
  }

  .home-action-card .action-icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    font-size: 17px;
  }

  .home-action-card .action-info {
    text-align: center;
    gap: 0;
  }

  .home-action-card .action-info strong {
    font-size: 11px;
    font-weight: 600;
  }

  .home-action-card .action-info span,
  .home-action-card .action-arrow {
    display: none;
  }

  .home-action-card:hover {
    background: #fff;
    border-color: rgba(0, 0, 0, .12);
  }
}
