/* =============================================================================
   پارسی شو — قالب نمایش جایگاه‌های تبلیغات (عمودی ۲۰۵×۳۰۰ / افقی ۵۷۰×۲۰۰)
   سبک، بدون تصویر سنگین: در حالت خالی فقط یک SVG ~۲KB نمایش داده می‌شود.
   ============================================================================= */

.phad-band {
  margin: 16px 0 8px;
  padding: 0;
  font-family: inherit;
  font-feature-settings: "ss01";
}

.phad-band-in {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 12px;
}

@media (min-width: 640px) {
  .phad-band-in { padding: 0 24px; }
}
@media (min-width: 1024px) {
  .phad-band-in { padding: 0 32px; }
}

.phad-band-h {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 10px;
  font-size: 11.5px;
  font-weight: 800;
  color: #6b7a8d;
  letter-spacing: .2px;
}

.phad-band-h::before {
  content: "";
  width: 24px;
  height: 3px;
  border-radius: 3px;
  background: linear-gradient(90deg, #25b6cc, #4e7dff);
  flex: 0 0 auto;
}

.phad-band-h em {
  font-style: normal;
  font-size: 9.5px;
  font-weight: 800;
  color: #8ea0b5;
  border: 1px solid #e4ecf6;
  border-radius: 999px;
  padding: 1px 7px;
}

.phad-band-grid {
  display: flex;
  gap: 14px;
  justify-content: center;
  align-items: flex-start;
  flex-wrap: wrap;
}

/* پوشش هر جایگاه: چیدمان را از والدش می‌گیرد تا اندازهٔ دقیق حفظ شود */
.phad-card-slot { display: contents; }

/* --- کارت جایگاه --- */
.phad-card {
  display: block;
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid #e4ecf6;
  background: #fff;
  box-shadow: 0 6px 18px rgba(20, 40, 70, .06);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}

.phad-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 26px rgba(20, 40, 70, .11);
  border-color: #cfe0f2;
}

.phad-card img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 0;
}

/* عنوان تبلیغ روی پایین تصویر (بدون تغییر ابعاد ۲۰۵×۳۰۰) */
.phad-cap {
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  display: block;
  padding: 14px 8px 7px;
  font-size: 10.5px;
  font-weight: 800;
  text-align: center;
  color: #fff;
  line-height: 1.7;
  text-shadow: 0 1px 2px rgba(0, 0, 0, .55);
  background: linear-gradient(180deg, rgba(8, 20, 34, 0), rgba(8, 20, 34, .72));
  pointer-events: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* عمودی ۲۰۵×۳۰۰ — دقیق */
.phad-card.is-v {
  width: 205px;
  height: 300px;
  flex: 0 0 205px;
}

/* افقی ۵۷۰×۲۰۰ — دقیق */
.phad-card.is-h {
  width: 570px;
  min-height: 200px;
  aspect-ratio: 570 / 200;
  flex: 0 1 570px;
  max-width: calc(50% - 7px);
}

/* جایگاه خالی = تصویر جایگزین */
.phad-card.is-ph {
  box-shadow: none;
  background: #fdfbf6;
  border-style: dashed;
  border-color: #e3d2ab;
}
.phad-card.is-ph:hover { transform: none; box-shadow: none; }

/* ستون کنار کیف پول: بدون تغییر چیدمان */
.phad-aside {
  display: flex;
  flex-direction: column;
  gap: 14px;
  align-items: center;
}
.phad-aside .phad-card.is-v { width: 100%; max-width: 205px; height: auto; aspect-ratio: 205 / 300; flex: none; }

/* ستون تبلیغات سمت چپ صفحه اصلی — دو بنر عمودی ۲۰۵×۳۰۰ زیر هم */
.phad-rail-left {
  position: absolute;
  top: 34px;
  left: clamp(8px, 1vw, 24px);
  width: 205px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  z-index: 4;
}

.phad-rail-left .phad-card {
  width: 205px;
  height: 300px;
  flex: 0 0 300px;
}

/* فاصلهٔ کمی بیشتر زیر تبلیغات کسب‌وکار */
#phad-biz { margin: 18px 0 32px; }

/* افقی: دو بنر قرینه — چسبیده به لبهٔ چپ و راست محتوا */
.phad-band[data-phad-band="h"] .phad-band-grid {
  justify-content: center;
  gap: 14px;
}

/* افقی: هم‌عرض کادر سکشن (بدون پدینگ اضافه) تا بنرها مماس لبه‌ها باشند */
.phad-band[data-phad-band="h"] .phad-band-in {
  max-width: 1280px;
  padding: 0;
}

@media (min-width: 1240px) {
  .phad-band[data-phad-band="h"] .phad-band-in {
    width: 1218px;
    max-width: none;
    margin-inline: calc(50% - 609px);
  }
}

/* --- حالت شب --- */
html.ph-night .phad-band-h { color: #9fb2cb; }
html.ph-night .phad-band-h em { color: #7f93ad; border-color: #22384f; }
html.ph-night .phad-card {
  background: #12233a;
  border-color: #22384f;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .3);
}
html.ph-night .phad-card.is-ph {
  background: #101f33;
  border-color: #2a3f57;
}

/* ===== کسب‌وکارهای ویژه: چهار ستون کامل + شیشه‌ای/نئون کوانتومی ===== */
.phad-vip-row {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 14px !important;
  overflow: visible !important;
  padding: 0 !important;
  margin: 0 !important;
}
.phad-vip-row > a {
  width: auto !important;
  flex: none !important;
  position: relative;
  border-radius: 22px;
  isolation: isolate;
}
.phad-vip-row > a::after {
  content: "";
  position: absolute;
  inset: -1.5px;
  border-radius: 23px;
  pointer-events: none;
  background: conic-gradient(from 140deg, #25b6cc, #4e7dff, #a855f7, #22d3ee, #25b6cc);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  padding: 1.5px;
  opacity: .5;
  z-index: 0;
  animation: phad-neon-spin 10s linear infinite;
}
@keyframes phad-neon-spin { to { filter: hue-rotate(360deg); } }

.phad-vip-row > a > div {
  position: relative;
  z-index: 1;
  background: rgba(255, 255, 255, .66) !important;
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  backdrop-filter: blur(16px) saturate(150%);
  border: 1px solid rgba(255, 255, 255, .8) !important;
  border-radius: 20px !important;
  box-shadow:
    0 10px 30px -14px rgba(14, 116, 144, .45),
    inset 0 0 18px rgba(37, 182, 204, .16);
  transition: transform .25s ease, box-shadow .25s ease;
}
.phad-vip-row > a:hover > div {
  transform: translateY(-3px);
  box-shadow:
    0 18px 42px -16px rgba(14, 116, 144, .55),
    0 0 26px rgba(78, 125, 255, .28);
}
html.ph-night .phad-vip-row > a > div {
  background: rgba(16, 31, 47, .72) !important;
  border-color: rgba(88, 160, 220, .35) !important;
  box-shadow:
    0 12px 32px -14px rgba(0, 0, 0, .7),
    inset 0 0 22px rgba(37, 182, 204, .22);
}
@media (max-width: 1023px) {
  .phad-vip-row { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
}
@media (max-width: 560px) {
  .phad-vip-row { grid-template-columns: 1fr !important; }
}
@media (prefers-reduced-motion: reduce) {
  .phad-vip-row > a::after { animation: none; }
}

/* --- موبایل --- */
@media (max-width: 640px) {
  .phad-band { margin: 12px 0 6px; }
  .phad-band-in { padding: 0 10px; }
  .phad-band-grid { gap: 10px; }
  .phad-card.is-v {
    width: calc(50% - 5px);
    max-width: 205px;
    height: auto;
    aspect-ratio: 205 / 300;
    flex: 0 1 calc(50% - 5px);
  }
  .phad-card.is-h {
    width: 100%;
    flex: 1 1 100%;
    aspect-ratio: 570 / 200;
    min-height: 0;
  }
}
