/* ==========================================================
   بازطراحی کامل ظاهر ایندکس (نسخه ۲) — فقط ظاهر، بدون تغییر منطق
   رنگ‌ها از متغیرهای تم سایت می‌آیند و با هر ۶ تم کار می‌کنند.
   برگشت به طرح قبلی: خط <link> این فایل را از index.php حذف کنید.
   ========================================================== */
:root {
  --ink: color-mix(in srgb, var(--primary) 12%, #080b16);
  --ink-text: rgba(255,255,255,.72);
  --ink-line: rgba(255,255,255,.14);
  --surface: color-mix(in srgb, var(--card) 75%, var(--bg));
  --tint: color-mix(in srgb, var(--primary) 10%, transparent);
  --light-primary: color-mix(in srgb, var(--primary) 55%, #fff);
  --wrap: 1336px;
}

/* ---------- نوار بالا ---------- */
.ed-topbar { background: var(--ink); border: 0; color: var(--ink-text); font-size: .78rem; }
.ed-topbar a { color: var(--ink-text); }
.ed-topbar a:hover { color: #fff; }

/* ---------- هدر ---------- */
.ed-header { background: var(--bg); backdrop-filter: none; border-bottom: 1px solid var(--line); }
.ed-logo-mark { border-radius: 10px; box-shadow: none; }
.ed-nav a { border-radius: 8px; padding: 8px 14px; font-weight: 600; }
.ed-nav a:hover { background: var(--tint); }
.ed-nav a.active { background: transparent; color: var(--primary); }
.ed-icon-btn, .ed-user-btn, .ed-mobile-btn {
  border-radius: 10px; border: 1px solid var(--line); background: transparent;
}
.ed-icon-btn:hover, .ed-user-btn:hover { border-color: var(--primary); background: var(--tint); }
.ed-user-menu { border-radius: 14px; border: 1px solid var(--line); overflow: hidden; }

/* ---------- هیرو: باند تیره، دو ستونه ---------- */
.ed-hero {
  position: relative; overflow: hidden;
  width: 100%; max-width: none; margin: 0;
  padding: 56px max(24px, calc((100vw - var(--wrap)) / 2)) 60px;
  display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr);
  column-gap: 64px; row-gap: 0; align-items: center;
  background:
    linear-gradient(var(--ink-line) 1px, transparent 1px) 0 0 / 48px 48px,
    linear-gradient(90deg, var(--ink-line) 1px, transparent 1px) 0 0 / 48px 48px,
    var(--ink);
  background-blend-mode: soft-light, soft-light, normal;
  color: #fff; border: 0; border-radius: 0; box-shadow: none;
}
.ed-hero > * { position: relative; z-index: 1; }
.ed-hero .ed-glow {
  position: absolute; z-index: 0; inset: auto auto -40% -10%;
  width: 640px; height: 640px; border-radius: 50%; opacity: .5; pointer-events: none;
  background: radial-gradient(circle, var(--primary), transparent 68%);
}
.ed-hero-title {
  grid-column: 1; grid-row: 1; align-self: end; display: block;
  margin: 0 0 18px; color: #fff;
  font-size: clamp(2.1rem, 4.3vw, 3.6rem); font-weight: 900; line-height: 1.3; letter-spacing: 0;
}
.ed-hero-title .ed-line { display: block; }
.ed-line-accent em { font-style: normal; color: var(--light-primary); }
.ed-line-accent::after, .ed-underline { display: none; }
.ed-hero-bottom {
  grid-column: 1; grid-row: 2; align-self: start;
  display: flex; flex-direction: column; gap: 26px;
  border: 0; padding: 0;
}
.ed-hero-desc { max-width: 52ch; margin: 0; font-size: 1rem; line-height: 2; color: var(--ink-text); }
.ed-hero-cta { display: flex; flex-wrap: wrap; gap: 12px; }
.ed-hero-cta .ed-btn { flex: 0 0 auto; padding: 14px 24px; font-size: .92rem; border-radius: 12px; text-decoration: none; }
.ed-hero-cta .ed-btn-primary { background: var(--primary); box-shadow: 0 14px 28px -12px var(--primary); color: #fff; }
.ed-hero-cta .ed-btn-primary:hover { filter: brightness(1.1); transform: translateY(-2px); }
.ed-btn-ghost { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,.3); }
.ed-btn-ghost:hover { background: rgba(255,255,255,.09); border-color: #fff; color: #fff; }
.ed-hero-stats { display: flex; gap: 0; padding-top: 22px; border-top: 1px solid var(--ink-line); }
.ed-hero-stats > div { padding-inline-end: 28px; margin-inline-end: 28px; border-inline-end: 1px solid var(--ink-line); }
.ed-hero-stats > div:last-child { border: 0; margin: 0; padding: 0; }
.ed-stat-num { font-size: 1.8rem; font-weight: 900; color: #fff; line-height: 1.3; }
.ed-stat-label { font-size: .78rem; color: rgba(255,255,255,.55); }

/* کارت تحویل لایسنس */
.ed-hero-visual { grid-column: 2; grid-row: 1 / span 2; align-self: center; position: relative; max-width: 430px; width: 100%; margin-inline: auto; }
.ed-hero-visual::before {
  content: ""; position: absolute; inset: 0; border-radius: 22px; transform: rotate(5deg);
  border: 1px solid var(--ink-line); background: rgba(255,255,255,.03);
}
.ed-key-card {
  position: relative; padding: 22px; border-radius: 22px; transform: rotate(-1.5deg);
  background: linear-gradient(160deg, rgba(255,255,255,.12), rgba(255,255,255,.04));
  border: 1px solid rgba(255,255,255,.2); backdrop-filter: blur(10px);
  box-shadow: 0 40px 70px -30px rgba(0,0,0,.7);
}
.ed-key-head { display: flex; align-items: center; gap: 10px; font-size: .84rem; color: var(--ink-text); }
.ed-key-head b { margin-inline-start: auto; font-size: .72rem; padding: 4px 10px; border-radius: 6px; background: rgba(52,211,153,.16); color: #6ee7b7; }
.ed-key-dot { width: 9px; height: 9px; border-radius: 50%; background: #34d399; box-shadow: 0 0 0 0 rgba(52,211,153,.6); animation: edPing 2s infinite; }
@keyframes edPing { 70% { box-shadow: 0 0 0 9px rgba(52,211,153,0); } 100% { box-shadow: 0 0 0 0 rgba(52,211,153,0); } }
.ed-key-product { display: flex; align-items: center; gap: 14px; margin: 20px 0 16px; }
.ed-key-icon { width: 48px; height: 48px; flex: none; display: grid; place-items: center; border-radius: 12px; background: var(--primary); color: #fff; font-size: 1.1rem; }
.ed-key-product strong { display: block; font-size: 1rem; color: #fff; }
.ed-key-product small { font-size: .76rem; color: rgba(255,255,255,.55); }
.ed-key-code {
  direction: ltr; text-align: center; padding: 15px 10px; border-radius: 12px;
  font: 600 .98rem/1 ui-monospace, Menlo, Consolas, monospace; letter-spacing: .1em;
  color: var(--light-primary); background: rgba(0,0,0,.35); border: 1px dashed rgba(255,255,255,.25);
}
.ed-key-foot { display: flex; justify-content: space-between; gap: 10px; margin-top: 16px; font-size: .76rem; color: var(--ink-text); }
.ed-key-foot i { color: #6ee7b7; margin-inline-end: 4px; }
.ed-key-chip {
  position: absolute; z-index: 2; display: flex; align-items: center; gap: 8px;
  padding: 10px 14px; border-radius: 12px; background: #fff; color: #10131f;
  font-size: .78rem; font-weight: 700; box-shadow: 0 18px 30px -14px rgba(0,0,0,.6);
}
.ed-key-chip i { color: var(--primary); }
.ed-key-chip-1 { top: -18px; inset-inline-start: -22px; }
.ed-key-chip-2 { bottom: -16px; inset-inline-end: -18px; }

/* ---------- نوار مزایا ---------- */
.ed-marquee {
  margin: 0; padding: 14px 0; border: 0; box-shadow: none; border-radius: 0;
  background: color-mix(in srgb, var(--primary) 82%, #000);
}
.ed-marquee::before, .ed-marquee::after { display: none; }
.ed-marquee-item { color: #fff; font-size: .86rem; font-weight: 700; padding: 0 22px; background: none; border: 0; }
.ed-marquee-item i { color: rgba(255,255,255,.75); }

/* ---------- عنوان بخش ---------- */
.ed-section { padding-top: 56px; scroll-margin-top: 80px; }
.ed-section-head { display: flex; align-items: center; gap: 18px; margin-bottom: 28px; }
.ed-section-head::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.ed-section-title { display: flex; align-items: center; gap: 14px; margin: 0; font-size: clamp(1.4rem, 3vw, 2rem); line-height: 1.3; letter-spacing: 0; }
.ed-section-title small { padding: 4px 12px; border-radius: 6px; background: var(--text); color: var(--bg); font-size: .72rem; font-weight: 700; letter-spacing: 0; }

/* ---------- کارت محصول: تخت، با نوار خرید چسبیده ---------- */
.ed-grid { grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 22px; }
.ed-card {
  padding: 0; min-height: 0; overflow: hidden; border-radius: 16px;
  background: var(--surface); border: 1px solid var(--line); box-shadow: none;
  transition: transform .25s, border-color .25s, box-shadow .25s;
}
.ed-card::before { display: none; }
.ed-card:hover { transform: translateY(-4px); border-color: var(--primary); box-shadow: 0 22px 40px -22px color-mix(in srgb, var(--primary) 60%, transparent); }
.ed-card-top { position: absolute; z-index: 2; top: 12px; inset-inline: 12px; margin: 0; padding: 0; }
.ed-card-badges { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px; width: 100%; }
.ed-badge { padding: 4px 10px; border-radius: 6px; font-size: .72rem; font-weight: 700; }
.ed-badge-validity { background: var(--bg); color: var(--text); border: 1px solid var(--line); }
.ed-badge-discount { background: var(--accent); color: #fff; border: 0; box-shadow: none; }
.ed-img-box {
  aspect-ratio: 16 / 11; margin: 0; border: 0; border-bottom: 1px solid var(--line); border-radius: 0;
  background: radial-gradient(color-mix(in srgb, var(--text) 16%, transparent) 1px, transparent 1.4px) 0 0 / 14px 14px, var(--soft);
}
.ed-img-box img { max-width: 56%; max-height: 70%; filter: drop-shadow(0 14px 14px color-mix(in srgb, var(--text) 25%, transparent)); }
.ed-card:hover .ed-img-box img { transform: scale(1.06); }
.ed-card-title { margin: 18px 20px 6px; font-size: 1.05rem; line-height: 1.5; }
.ed-card-desc { margin: 0 20px 16px; }
.ed-card-price { display: flex; align-items: baseline; flex-wrap: wrap; gap: 2px 6px; margin: 0 20px 18px; padding: 0; background: none; }
.ed-price-current { font-size: 1.5rem; font-weight: 900; color: var(--text); }
.ed-price-unit { font-size: .78rem; color: var(--muted); }
.ed-price-old { margin-inline-start: auto; font-size: .82rem; color: var(--muted); text-decoration: line-through; }
.ed-card-actions { display: flex; gap: 0; border-top: 1px solid var(--line); }
.ed-card .ed-btn { border-radius: 0; padding: 16px 18px; }
.ed-card .ed-btn-primary { background: var(--primary); box-shadow: none; }
.ed-card .ed-btn-primary:hover { filter: brightness(1.12); transform: none; }
.ed-card-actions .ed-btn-outline {
  flex: 0 0 62px; width: 62px; padding-inline: 0; background: transparent;
  border: 0; border-inline-start: 1px solid var(--line); color: var(--text);
}
.ed-card-actions .ed-btn-outline:hover { background: var(--tint); color: var(--primary); }

/* ---------- نمایش لیستی ---------- */
.ed-list { display: flex; flex-direction: column; gap: 12px; }
.ed-list-item, .ed-list-item:hover {
  padding: 14px 18px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface);
}
.ed-list-item:hover { border-color: var(--primary); }
.ed-list-img { border-radius: 10px; background: var(--soft); padding: 6px; }

/* ---------- ویژگی‌ها: یک نوار تک‌تکه ---------- */
.ed-features {
  width: calc(100% - 48px); max-width: calc(var(--wrap) - 64px); margin: 8px auto 72px; padding: 0; gap: 0;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--line); border-radius: 18px; overflow: hidden; background: var(--surface);
}
.ed-feature-item, .ed-feature-item:hover {
  display: grid; grid-template-columns: 46px 1fr; column-gap: 14px; align-content: center;
  padding: 24px 22px; border: 0; border-radius: 0; background: none; box-shadow: none; transform: none;
  border-inline-start: 1px solid var(--line);
}
.ed-feature-item:first-child { border-inline-start: 0; }
.ed-feature-item::before { display: none; }
.ed-feature-item i {
  grid-row: 1 / span 2; width: 46px; height: 46px; display: grid; place-items: center; margin: 0;
  border-radius: 12px; font-size: 1.05rem; color: var(--primary); background: var(--tint);
}
.ed-feature-title { font-size: .98rem; font-weight: 800; margin: 0; }
.ed-feature-text { font-size: .8rem; line-height: 1.8; margin: 2px 0 0; }

/* ---------- تم، مودال ---------- */
.ed-theme-btn { border-radius: 14px; }
.ed-theme-panel { border-radius: 14px; border: 1px solid var(--line); }
.ed-view-btn { border-radius: 8px; }
.ed-modal .modal-content { border-radius: 18px; border: 1px solid var(--line); overflow: hidden; }
.ed-modal .modal-header { border-bottom: 1px solid var(--line); }
.modal-backdrop.show { backdrop-filter: blur(4px); }
.ed-input { border-radius: 10px; }

/* ---------- فوتر تیره ---------- */
.ed-footer { margin: 0; border: 0; border-radius: 0; background: var(--ink); color: var(--ink-text); }
.ed-footer h5 { color: #fff; font-weight: 800; }
.ed-footer p, .ed-footer a { color: rgba(255,255,255,.62); }
.ed-footer a:hover { color: #fff; }
.ed-social a { border-radius: 10px; border: 1px solid var(--ink-line); background: rgba(255,255,255,.05); color: #fff; }
.ed-social a:hover { background: var(--primary); border-color: var(--primary); }
.ed-trust-item { border-radius: 10px; border: 1px solid var(--ink-line); background: rgba(255,255,255,.05); }
.ed-trust-item img { background: #fff; border-radius: 8px; padding: 3px; }
.ed-trust-item span { color: var(--ink-text); }
.ed-copyright { border-top: 1px solid var(--ink-line); color: rgba(255,255,255,.55); }

/* ---------- ریسپانسیو ---------- */
@media (max-width: 1000px) {
  .ed-hero { grid-template-columns: 1fr; padding-top: 40px; padding-bottom: 52px; }
  .ed-hero-title, .ed-hero-bottom, .ed-hero-visual { grid-column: 1; }
  .ed-hero-title { grid-row: 1; }
  .ed-hero-bottom { grid-row: 2; }
  .ed-hero-visual { grid-row: 3; margin-top: 44px; max-width: 400px; }
  .ed-features { grid-template-columns: repeat(2, 1fr); }
  .ed-feature-item:nth-child(3) { border-inline-start: 0; }
  .ed-feature-item:nth-child(n+3) { border-top: 1px solid var(--line); }
}
@media (max-width: 768px) {
  .ed-hero { padding: 32px 20px 44px; }
  .ed-hero-cta .ed-btn { flex: 1 1 100%; }
  .ed-hero-stats > div { padding-inline-end: 16px; margin-inline-end: 16px; }
  .ed-stat-num { font-size: 1.4rem; }
  .ed-key-chip-1 { inset-inline-start: -6px; }
  .ed-key-chip-2 { inset-inline-end: -6px; }
  .ed-grid { grid-template-columns: 1fr; gap: 16px; }
  .ed-section { padding-top: 40px; }
  .ed-features { grid-template-columns: 1fr; width: calc(100% - 32px); }
  .ed-feature-item { border-inline-start: 0; border-top: 1px solid var(--line); }
  .ed-feature-item:first-child { border-top: 0; }
  .ed-list-item, .ed-list-item:hover { padding: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .ed-key-dot { animation: none; }
  .ed-card, .ed-card:hover, .ed-card:hover .ed-img-box img, .ed-hero-cta .ed-btn-primary:hover { transform: none; transition: none; }
}

/* ==========================================================
   نسخه ۳: مارکی بی‌انتها + زمینه و کارت‌های شیشه‌ای
   ========================================================== */

/* مارکی: ۶ گروه پشت‌سرهم؛ جابه‌جایی نصف عرض = ۳ گروه، پس تکرار بدون هیچ فاصله‌ی خالی */
.ed-marquee { overflow: hidden; }
.ed-marquee-inner { animation: edScroll 70s linear infinite; will-change: transform; }
.ed-marquee-group { gap: 0; padding-inline-end: 0; }
.ed-marquee-item { padding: 0 20px; }

/* زمینه‌ی شیشه‌ای محصولات: لکه‌های رنگی نرم که پشت کارت‌ها محو می‌شوند */
.ed-section#products { position: relative; isolation: isolate; }
.ed-section#products::before {
  content: ""; position: absolute; z-index: -1; pointer-events: none;
  top: 0; bottom: 0; left: calc(50% - 50vw); right: calc(50% - 50vw);
  background:
    radial-gradient(38% 42% at 12% 18%, color-mix(in srgb, var(--primary) 30%, transparent), transparent 70%),
    radial-gradient(34% 40% at 88% 28%, color-mix(in srgb, var(--accent) 26%, transparent), transparent 70%),
    radial-gradient(40% 38% at 50% 95%, color-mix(in srgb, var(--primary) 20%, transparent), transparent 70%);
}

/* کارت شیشه‌ای */
.ed-card {
  background: linear-gradient(160deg,
    color-mix(in srgb, var(--card) 62%, transparent),
    color-mix(in srgb, var(--card) 28%, transparent));
  backdrop-filter: blur(18px) saturate(170%);
  -webkit-backdrop-filter: blur(18px) saturate(170%);
  border: 1px solid color-mix(in srgb, #fff 38%, var(--line));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.4), 0 18px 40px -26px color-mix(in srgb, var(--text) 45%, transparent);
}
.ed-card:hover {
  border-color: color-mix(in srgb, var(--primary) 70%, #fff);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.5), 0 28px 50px -24px color-mix(in srgb, var(--primary) 70%, transparent);
}
.ed-img-box {
  background:
    radial-gradient(60% 60% at 50% 45%, color-mix(in srgb, #fff 40%, transparent), transparent 72%),
    color-mix(in srgb, var(--card) 22%, transparent);
  border-bottom: 1px solid color-mix(in srgb, #fff 30%, var(--line));
}
.ed-badge-validity {
  background: color-mix(in srgb, var(--card) 55%, transparent);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  border: 1px solid color-mix(in srgb, #fff 35%, var(--line));
}
.ed-card-actions { border-top: 1px solid color-mix(in srgb, #fff 30%, var(--line)); }
.ed-card-actions .ed-btn-outline {
  background: color-mix(in srgb, var(--card) 35%, transparent);
  border-inline-start: 1px solid color-mix(in srgb, #fff 30%, var(--line));
}

/* لیست و ویژگی‌ها هم هم‌سبک شیشه */
.ed-list-item, .ed-list-item:hover {
  background: color-mix(in srgb, var(--card) 45%, transparent);
  backdrop-filter: blur(16px) saturate(160%); -webkit-backdrop-filter: blur(16px) saturate(160%);
  border: 1px solid color-mix(in srgb, #fff 35%, var(--line));
}
.ed-list-item:hover { border-color: var(--primary); }
.ed-features {
  background: color-mix(in srgb, var(--card) 45%, transparent);
  backdrop-filter: blur(16px) saturate(160%); -webkit-backdrop-filter: blur(16px) saturate(160%);
  border-color: color-mix(in srgb, #fff 35%, var(--line));
}

@media (prefers-reduced-motion: reduce) { .ed-marquee-inner { animation-duration: 140s; } }

/* ==========================================================
   نسخه ۴: سبک Windows 11 — شیشه‌ی اکریلیک + نئون
   ========================================================== */
:root {
  --neon: color-mix(in srgb, var(--primary) 70%, #fff);
  --neon-glow: 0 0 14px color-mix(in srgb, var(--primary) 70%, transparent),
               0 0 38px color-mix(in srgb, var(--primary) 42%, transparent);
}

/* ---------- دکمه‌ی نئونی شیشه‌ای (خرید، هیرو، مودال) ---------- */
.ed-btn-primary {
  position: relative; overflow: hidden; isolation: isolate;
  color: #fff; font-weight: 800; letter-spacing: 0;
  text-shadow: 0 0 10px rgba(255,255,255,.55), 0 1px 2px rgba(0,0,0,.35);
  background:
    linear-gradient(180deg, rgba(255,255,255,.34), rgba(255,255,255,0) 55%),
    linear-gradient(135deg, color-mix(in srgb, var(--primary) 88%, transparent), color-mix(in srgb, var(--accent) 72%, transparent));
  border: 1px solid var(--neon);
  backdrop-filter: blur(10px) saturate(180%); -webkit-backdrop-filter: blur(10px) saturate(180%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.55), inset 0 -8px 16px -8px rgba(0,0,0,.25), var(--neon-glow);
  transition: box-shadow .3s, transform .25s, filter .3s;
}
.ed-btn-primary::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(110deg, transparent 32%, rgba(255,255,255,.5) 50%, transparent 68%);
  transform: translateX(130%); transition: transform .8s cubic-bezier(.2,.7,.2,1);
}
.ed-btn-primary:hover {
  filter: brightness(1.08); transform: translateY(-2px);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.65), inset 0 -8px 16px -8px rgba(0,0,0,.25),
              0 0 20px var(--primary), 0 0 56px color-mix(in srgb, var(--primary) 60%, transparent);
}
.ed-btn-primary:hover::after { transform: translateX(-130%); }
.ed-btn-primary:active { transform: translateY(0) scale(.98); }
.ed-hero-cta .ed-btn-primary { background-color: transparent; }

/* ---------- کارت: اکریلیک ویندوز ۱۱ + نوار دکمه‌ها ---------- */
.ed-card:hover {
  border-color: var(--neon);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.55), 0 0 0 1px color-mix(in srgb, var(--primary) 35%, transparent),
              0 26px 54px -24px color-mix(in srgb, var(--primary) 75%, transparent);
}
.ed-card-actions { gap: 10px; padding: 4px 16px 16px; border-top: 0; }
.ed-card .ed-btn { border-radius: 12px; padding: 0 18px; height: 48px; }
.ed-card .ed-btn-primary {
  box-shadow: inset 0 1px 0 rgba(255,255,255,.55), inset 0 -8px 16px -8px rgba(0,0,0,.25), var(--neon-glow);
}
.ed-card .ed-btn-primary:hover { filter: brightness(1.08); transform: translateY(-2px); }
.ed-card-actions .ed-btn-outline {
  flex: 0 0 48px; width: 48px; padding: 0; color: var(--text);
  background: linear-gradient(180deg, rgba(255,255,255,.28), rgba(255,255,255,.06));
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border: 1px solid color-mix(in srgb, #fff 45%, var(--line));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.5);
}
.ed-card-actions .ed-btn-outline:hover {
  color: #fff; border-color: var(--neon); background: color-mix(in srgb, var(--primary) 55%, transparent);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.5), var(--neon-glow);
}

/* ---------- تصویر محصول: کاشی شیشه‌ای + درخشش نئونی (بدون بیضی) ---------- */
.ed-img-box {
  position: relative; overflow: hidden; aspect-ratio: 16 / 11;
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--primary) 18%, transparent), transparent 58%),
    linear-gradient(315deg, color-mix(in srgb, var(--accent) 16%, transparent), transparent 58%),
    color-mix(in srgb, var(--card) 18%, transparent);
  border-bottom: 1px solid color-mix(in srgb, #fff 30%, var(--line));
}
.ed-img-box::before {
  content: ""; position: absolute; z-index: 0; pointer-events: none;
  top: 50%; left: 50%; width: 112px; height: 112px; border-radius: 34px;
  transform: translate(-50%, -42%) rotate(-8deg);
  background: linear-gradient(135deg, var(--primary), var(--accent));
  filter: blur(30px); opacity: .6; transition: opacity .35s, transform .35s;
}
.ed-card:hover .ed-img-box::before { opacity: .95; transform: translate(-50%, -46%) rotate(4deg) scale(1.15); }
.ed-img-box img {
  position: relative; z-index: 1;
  width: 128px; height: 128px; max-width: none; max-height: none;
  padding: 22px; object-fit: contain; border-radius: 30px;
  background: linear-gradient(145deg, rgba(255,255,255,.5), rgba(255,255,255,.1));
  border: 1px solid rgba(255,255,255,.6);
  backdrop-filter: blur(14px) saturate(170%); -webkit-backdrop-filter: blur(14px) saturate(170%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.8), 0 0 0 1px color-mix(in srgb, var(--primary) 22%, transparent),
              0 20px 32px -14px rgba(0,0,0,.4), 0 0 28px -6px color-mix(in srgb, var(--primary) 55%, transparent);
  filter: none; transition: transform .4s cubic-bezier(.2,.8,.2,1), box-shadow .4s;
}
.ed-card:hover .ed-img-box img {
  transform: translateY(-4px) scale(1.06);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.9), 0 0 0 1px var(--neon),
              0 26px 38px -14px rgba(0,0,0,.45), 0 0 40px -4px var(--primary);
}
.ed-list-img {
  border-radius: 16px; padding: 8px; background: linear-gradient(145deg, rgba(255,255,255,.45), rgba(255,255,255,.08));
  border: 1px solid rgba(255,255,255,.55); box-shadow: 0 0 18px -6px color-mix(in srgb, var(--primary) 55%, transparent);
}

@media (max-width: 768px) {
  .ed-img-box img { width: 112px; height: 112px; padding: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  .ed-btn-primary::after { display: none; }
  .ed-card:hover .ed-img-box img, .ed-card:hover .ed-img-box::before { transform: none; }
}

/* ==========================================================
   نسخه ۵: Liquid Glass — شیشه‌ی کاملاً شفاف، لبه‌ی نورانی، دکمه‌ی قرص‌شکل
   ========================================================== */
:root {
  --g-fill: linear-gradient(145deg, rgba(255,255,255,.2), rgba(255,255,255,.03));
  --g-edge: inset 1px 1px 0 rgba(255,255,255,.75), inset -1px -1px 0 rgba(255,255,255,.22), inset 0 0 26px rgba(255,255,255,.1);
}

/* ---------- زمینه‌ی رنگی متحرک پشت شیشه ---------- */
.ed-section#products::before {
  background:
    radial-gradient(34% 36% at 10% 15%, color-mix(in srgb, var(--primary) 55%, transparent), transparent 70%),
    radial-gradient(30% 34% at 90% 25%, color-mix(in srgb, var(--accent) 50%, transparent), transparent 70%),
    radial-gradient(32% 34% at 55% 70%, color-mix(in srgb, var(--primary) 38%, transparent), transparent 70%),
    radial-gradient(28% 30% at 15% 95%, color-mix(in srgb, var(--accent) 38%, transparent), transparent 70%);
  background-size: 150% 150%;
  animation: edAurora 28s ease-in-out infinite alternate;
}
@keyframes edAurora { from { background-position: 0% 0%; } to { background-position: 100% 100%; } }

/* ---------- هدر شیشه‌ای ---------- */
.ed-header {
  background: color-mix(in srgb, var(--bg) 55%, transparent);
  backdrop-filter: blur(22px) saturate(180%); -webkit-backdrop-filter: blur(22px) saturate(180%);
}
.ed-nav a.active {
  background: color-mix(in srgb, var(--primary) 14%, transparent);
  border-radius: 999px; box-shadow: inset 0 1px 0 rgba(255,255,255,.6);
}
.ed-nav a.active::after { display: none; }

/* ---------- کارت: شیشه‌ی شفاف با لبه‌ی نورانی ---------- */
.ed-card {
  background: var(--g-fill);
  backdrop-filter: blur(22px) saturate(190%) brightness(1.03);
  -webkit-backdrop-filter: blur(22px) saturate(190%) brightness(1.03);
  border: 1px solid color-mix(in srgb, var(--text) 9%, transparent);
  border-radius: 30px;
  box-shadow: var(--g-edge), 0 34px 60px -34px color-mix(in srgb, var(--text) 55%, transparent);
}
.ed-card::before {
  display: block; content: ""; position: absolute; inset: 0; z-index: 3; pointer-events: none;
  border-radius: inherit; opacity: 1;
  background: linear-gradient(125deg, rgba(255,255,255,.34) 0%, rgba(255,255,255,0) 32%, rgba(255,255,255,0) 70%, rgba(255,255,255,.12) 100%);
}
.ed-card:hover {
  transform: translateY(-6px);
  border-color: color-mix(in srgb, var(--primary) 40%, transparent);
  box-shadow: var(--g-edge), 0 40px 70px -30px color-mix(in srgb, var(--primary) 70%, transparent);
}
.ed-card-top { z-index: 4; }
.ed-badge { border-radius: 999px; padding: 5px 12px; }
.ed-badge-validity {
  background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.5);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.6);
}
.ed-badge-discount { background: linear-gradient(135deg, var(--accent), color-mix(in srgb, var(--accent) 60%, #000)); box-shadow: 0 6px 16px -6px var(--accent); }

/* ---------- تصویر: شناور روی شیشه‌ی شفاف ---------- */
.ed-img-box { background: none; border: 0; overflow: visible; aspect-ratio: 4 / 3; margin-top: 8px; }
.ed-img-box::before { width: 130px; height: 130px; opacity: .7; filter: blur(36px); }
.ed-img-box::after {
  content: ""; position: absolute; z-index: 0; pointer-events: none; width: 90px; height: 90px; border-radius: 50%;
  top: 50%; left: 50%; transform: translate(-5%, -85%); background: var(--accent); filter: blur(38px); opacity: .45;
}
.ed-img-box img {
  width: 136px; height: 136px; padding: 24px; border-radius: 38px;
  background: var(--g-fill); border: 1px solid rgba(255,255,255,.5);
  backdrop-filter: blur(6px) saturate(190%); -webkit-backdrop-filter: blur(6px) saturate(190%);
  box-shadow: var(--g-edge), 0 26px 36px -18px rgba(0,0,0,.45);
}
.ed-card:hover .ed-img-box img {
  transform: translateY(-6px) scale(1.06);
  box-shadow: var(--g-edge), 0 0 0 1px color-mix(in srgb, var(--primary) 45%, transparent), 0 34px 44px -16px color-mix(in srgb, var(--primary) 70%, transparent);
}

/* ---------- دکمه‌های نسل جدید: قرص شیشه‌ای + چیپ آیکن ---------- */
.ed-btn { border-radius: 999px; }
.ed-btn-primary {
  height: 52px; gap: 12px; padding: 0 22px 0 8px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.4) 0%, rgba(255,255,255,.04) 48%, rgba(255,255,255,.14) 100%),
    color-mix(in srgb, var(--primary) 74%, transparent);
  border: 1px solid rgba(255,255,255,.6);
  backdrop-filter: blur(16px) saturate(210%); -webkit-backdrop-filter: blur(16px) saturate(210%);
  box-shadow: inset 0 1.5px 0 rgba(255,255,255,.85), inset 0 -3px 8px rgba(255,255,255,.22), inset 0 0 18px rgba(255,255,255,.12),
              0 14px 30px -10px color-mix(in srgb, var(--primary) 85%, transparent);
}
.ed-btn-primary > i {
  flex: none; width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%; font-size: .82rem;
  background: rgba(255,255,255,.3); box-shadow: inset 0 1px 0 rgba(255,255,255,.8), 0 4px 10px -4px rgba(0,0,0,.35);
  text-shadow: none; transition: transform .35s cubic-bezier(.2,.8,.2,1), background .3s;
}
.ed-btn-primary:hover {
  filter: brightness(1.07); transform: translateY(-2px);
  box-shadow: inset 0 1.5px 0 rgba(255,255,255,.9), inset 0 -3px 8px rgba(255,255,255,.28), inset 0 0 18px rgba(255,255,255,.16),
              0 18px 38px -8px var(--primary), 0 0 0 4px color-mix(in srgb, var(--primary) 22%, transparent);
}
.ed-btn-primary:hover > i { transform: translateX(-4px); background: rgba(255,255,255,.42); }
.ed-card .ed-btn-primary { height: 52px; border-radius: 999px; }
.ed-card-actions { gap: 10px; padding: 6px 16px 18px; }
.ed-card-actions .ed-btn-outline {
  flex: 0 0 52px; width: 52px; height: 52px; border-radius: 50%; color: var(--text);
  background: var(--g-fill); border: 1px solid rgba(255,255,255,.55);
  backdrop-filter: blur(14px) saturate(190%); -webkit-backdrop-filter: blur(14px) saturate(190%);
  box-shadow: var(--g-edge);
}
.ed-card-actions .ed-btn-outline:hover {
  color: #fff; background: color-mix(in srgb, var(--primary) 70%, transparent); border-color: rgba(255,255,255,.7);
  box-shadow: var(--g-edge), 0 12px 24px -8px var(--primary);
}
.ed-hero-cta .ed-btn-primary { padding-inline-end: 26px; }
.ed-btn-outline { border-radius: 999px; }

/* ---------- لیست و ویژگی‌ها هم‌سبک ---------- */
.ed-list-item, .ed-list-item:hover { border-radius: 24px; background: var(--g-fill); box-shadow: var(--g-edge); }
.ed-list-img { border-radius: 20px; background: var(--g-fill); box-shadow: var(--g-edge); }
.ed-features { border-radius: 30px; background: var(--g-fill); box-shadow: var(--g-edge), 0 30px 60px -36px color-mix(in srgb, var(--text) 45%, transparent); }

@media (max-width: 768px) {
  .ed-img-box img { width: 118px; height: 118px; padding: 20px; }
  .ed-card { border-radius: 26px; }
}
@media (prefers-reduced-motion: reduce) {
  .ed-section#products::before { animation: none; }
  .ed-btn-primary:hover > i { transform: none; }
}

/* ==========================================================
   نسخه ۶: هماهنگی با رنگ زمینه‌ی تم — شیشه از رنگ کارت تم ساخته می‌شود،
   نه از سفید؛ در تم تیره کم‌نور و در تم روشن ملایم.
   ========================================================== */
body[data-tone="dark"] {
  --g-fill: linear-gradient(145deg, color-mix(in srgb, var(--card) 66%, transparent), color-mix(in srgb, var(--card) 24%, transparent));
  --g-edge: inset 1px 1px 0 rgba(255,255,255,.16), inset -1px -1px 0 rgba(255,255,255,.05), inset 0 0 24px rgba(255,255,255,.025);
  --g-border: rgba(255,255,255,.13);
  --g-sheen: rgba(255,255,255,.07);
  --hl: rgba(255,255,255,.38); --hl-s: rgba(255,255,255,.18); --hl-xs: rgba(255,255,255,.07);
  --g-drop: rgba(0,0,0,.65);
  --blob-a: 30%; --blob-b: 24%; --blob-c: 18%;
}
body[data-tone="light"] {
  --g-fill: linear-gradient(145deg, color-mix(in srgb, var(--card) 58%, transparent), color-mix(in srgb, var(--card) 16%, transparent));
  --g-edge: inset 1px 1px 0 rgba(255,255,255,.85), inset -1px -1px 0 rgba(255,255,255,.3), inset 0 0 22px rgba(255,255,255,.12);
  --g-border: rgba(255,255,255,.6);
  --g-sheen: rgba(255,255,255,.3);
  --hl: rgba(255,255,255,.85); --hl-s: rgba(255,255,255,.45); --hl-xs: rgba(255,255,255,.16);
  --g-drop: color-mix(in srgb, var(--text) 40%, transparent);
  --blob-a: 42%; --blob-b: 36%; --blob-c: 26%;
}

/* زمینه‌ی رنگی: ملایم‌تر و هم‌رنگ تم */
.ed-section#products::before {
  background:
    radial-gradient(34% 36% at 10% 15%, color-mix(in srgb, var(--primary) var(--blob-a, 35%), transparent), transparent 70%),
    radial-gradient(30% 34% at 90% 25%, color-mix(in srgb, var(--accent) var(--blob-b, 30%), transparent), transparent 70%),
    radial-gradient(32% 34% at 55% 70%, color-mix(in srgb, var(--primary) var(--blob-c, 22%), transparent), transparent 70%),
    radial-gradient(28% 30% at 15% 95%, color-mix(in srgb, var(--accent) var(--blob-c, 22%), transparent), transparent 70%);
  background-size: 150% 150%;
}

/* کارت */
.ed-card {
  backdrop-filter: blur(22px) saturate(160%); -webkit-backdrop-filter: blur(22px) saturate(160%);
  border-color: color-mix(in srgb, var(--text) 10%, transparent);
  box-shadow: var(--g-edge), 0 30px 56px -34px var(--g-drop);
}
.ed-card::before { background: linear-gradient(125deg, var(--g-sheen) 0%, transparent 30%, transparent 72%, var(--hl-xs) 100%); }
.ed-card:hover { border-color: color-mix(in srgb, var(--primary) 55%, transparent); }
.ed-badge-validity { background: var(--hl-xs); border-color: var(--g-border); box-shadow: inset 0 1px 0 var(--hl-s); }

/* تصویر */
.ed-img-box::before { opacity: .5; }
.ed-img-box::after { opacity: .32; }
.ed-card:hover .ed-img-box::before { opacity: .8; }
.ed-img-box img {
  border-color: var(--g-border);
  backdrop-filter: blur(6px) saturate(160%); -webkit-backdrop-filter: blur(6px) saturate(160%);
  box-shadow: var(--g-edge), 0 24px 34px -18px var(--g-drop);
}
.ed-list-img { border-color: var(--g-border); }

/* دکمه‌ها: همان فرم، نور داخلی ملایم‌تر و هم‌رنگ تم */
.ed-btn-primary {
  background:
    linear-gradient(180deg, var(--hl-s) 0%, transparent 50%, var(--hl-xs) 100%),
    color-mix(in srgb, var(--primary) 78%, transparent);
  border-color: color-mix(in srgb, var(--primary) 45%, var(--hl-s));
  box-shadow: inset 0 1.5px 0 var(--hl), inset 0 -3px 8px var(--hl-xs), inset 0 0 18px var(--hl-xs),
              0 14px 28px -12px color-mix(in srgb, var(--primary) 80%, transparent);
}
.ed-btn-primary > i { background: var(--hl-s); box-shadow: inset 0 1px 0 var(--hl), 0 4px 10px -4px rgba(0,0,0,.4); }
.ed-btn-primary:hover > i { background: var(--hl-s); }
.ed-btn-primary:hover {
  box-shadow: inset 0 1.5px 0 var(--hl), inset 0 -3px 8px var(--hl-xs), inset 0 0 18px var(--hl-xs),
              0 16px 34px -10px var(--primary), 0 0 0 4px color-mix(in srgb, var(--primary) 20%, transparent);
}
.ed-card-actions .ed-btn-outline {
  background: var(--g-fill); border-color: var(--g-border); box-shadow: var(--g-edge);
  backdrop-filter: blur(14px) saturate(160%); -webkit-backdrop-filter: blur(14px) saturate(160%);
}
.ed-card-actions .ed-btn-outline:hover { background: color-mix(in srgb, var(--primary) 72%, transparent); border-color: color-mix(in srgb, var(--primary) 50%, var(--hl-s)); }

/* هدر و ویژگی‌ها */
.ed-header { background: color-mix(in srgb, var(--bg) 62%, transparent); }
.ed-nav a.active { box-shadow: inset 0 1px 0 var(--hl-s); }
.ed-features { box-shadow: var(--g-edge), 0 28px 56px -36px var(--g-drop); border-color: color-mix(in srgb, var(--text) 10%, transparent); }
.ed-list-item, .ed-list-item:hover { border-color: color-mix(in srgb, var(--text) 10%, transparent); }

/* ==========================================================
   نسخه ۷: رفع دو مشکل تم
   ۱) آیکن/متن دکمه‌ی حساب کاربری در تم‌های روشن سفید و نامرئی بود
      (متن سفید روی پس‌زمینه‌ی شفاف) — حالا با رنگ تم هماهنگ است.
   ۲) نمادهای اعتماد (اینماد و ...) در بعضی تم‌ها سفید/محو دیده می‌شد.
   ========================================================== */

/* ---- دکمه‌ی حساب کاربری (ایندکس و سبد خرید) ---- */
.ed-user-btn {
  color: var(--text);
  background: var(--g-fill, linear-gradient(145deg, rgba(255,255,255,.2), rgba(255,255,255,.03)));
  border: 1px solid var(--g-border, var(--line));
  box-shadow: var(--g-edge, none);
  backdrop-filter: blur(14px) saturate(170%); -webkit-backdrop-filter: blur(14px) saturate(170%);
}
.ed-user-btn i, .ed-user-btn span, .ed-user-btn .ed-chev { color: inherit; }
.ed-user-btn i { color: var(--primary); font-size: .95rem; transition: color .2s; }
.ed-user-btn:hover, .ed-user-wrap:hover .ed-user-btn {
  color: #fff; border-color: color-mix(in srgb, var(--primary) 55%, var(--g-border, var(--line)));
  background: linear-gradient(180deg, var(--hl-s, rgba(255,255,255,.25)), transparent 55%), color-mix(in srgb, var(--primary) 80%, transparent);
  box-shadow: inset 0 1px 0 var(--hl, rgba(255,255,255,.6)), 0 10px 22px -8px var(--primary);
}
.ed-user-btn:hover i, .ed-user-wrap:hover .ed-user-btn i { color: #fff; }
.ed-icon-btn { color: var(--text); }
.ed-icon-btn i { color: inherit; }

/* ---- نمادهای اعتماد: صفحه‌ی روشن ثابت پشت هر نماد، مستقل از تم ---- */
.ed-trust-item a { display: flex; padding: 0; line-height: 0; }
.ed-trust-item img {
  width: 56px; height: 56px; flex: none; object-fit: contain; padding: 5px;
  border-radius: 14px; border: 1px solid rgba(15, 23, 42, .12);
  background: linear-gradient(145deg, #ffffff, #e9edf5);
  box-shadow: inset 0 1px 0 #fff, 0 6px 14px -6px rgba(0, 0, 0, .45);
  filter: drop-shadow(0 0 1px rgba(15, 23, 42, .45));
  opacity: 1;
}
.ed-trust-item span { color: inherit; opacity: .85; }

/* ==========================================================
   نسخه ۸: بهینه‌سازی سرعت (بدون تغییر ظاهر در دسکتاپ)
   - حذف انیمیشن پس‌زمینه‌ی بزرگ (باعث بازرسم مداوم صفحه می‌شد)
   - رندر تنبلی بخش‌های پایین صفحه
   - موبایل: حذف backdrop-filter از اجزای تکراری و سبک‌کردن درخشش‌ها
   ========================================================== */
.ed-section#products::before, .ed-container::before { animation: none; background-size: 100% 100%; }
.ed-footer, .ed-features { content-visibility: auto; contain-intrinsic-size: auto 420px; }
.ed-card, .ed-cart-item { contain: layout paint; }

@media (max-width: 768px) {
  .ed-card, .ed-list-item, .ed-features, .ed-img-box img, .ed-badge-validity, .ed-cart-list, .ed-summary,
  .ed-qty, .ed-card-actions .ed-btn-outline, .ed-btn-primary, .ed-header, .ed-steps, .ed-user-btn, .ed-empty,
  .ed-item-img, .ed-key-card {
    backdrop-filter: none; -webkit-backdrop-filter: none;
  }
  .ed-card, .ed-list-item, .ed-cart-list, .ed-summary, .ed-features {
    background: color-mix(in srgb, var(--card) 86%, transparent);
  }
  .ed-header { background: color-mix(in srgb, var(--bg) 94%, transparent); }
  .ed-img-box::after { display: none; }
  .ed-img-box::before { filter: blur(22px); }
  .ed-summary::before { display: none; }
}
@media (prefers-reduced-motion: reduce) { .ed-marquee-inner { animation: none; } }
