/* Padid Sale Slider — Glass Theme */
:root {
    --pss-accent: #e30613;
    --pss-accent-dark: #c0000f;
    --pss-glass: rgba(255,255,255,0.09);
    --pss-border: rgba(255,255,255,0.16);
    --pss-text: #FFF;
    --pss-muted: rgba(241,232,255,0.6);
    --pss-card-bg: rgba(255,255,255,0.07);
    --pss-radius: 14px;
    --pss-card-w: 220px;
}

.pss-wrapper {
    direction: rtl;
    font-family: 'Peyda', Tahoma, sans-serif;
    padding: 20px 0 24px;
    position: relative;
    overflow: hidden;
}

/* ── هدر ── */
.pss-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 0 4px 18px;
    flex-wrap: wrap;
    border-bottom: 1px solid rgba(255,255,255,.08);
    margin-bottom: 20px;
}
.pss-header-right { display: flex; align-items: center; gap: 14px; }
.pss-header-left  { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }

.pss-fire-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, var(--pss-accent), #ff4444);
    color: #fff;
    font-size: .78rem;
    font-weight: 800;
    padding: 6px 14px;
    border-radius: 20px;
    letter-spacing: .3px;
    box-shadow: 0 4px 14px rgba(227,6,19,.4);
    white-space: nowrap;
    animation: pssFirePulse 2s ease-in-out infinite;
}
@keyframes pssFirePulse {
    0%,100% { box-shadow: 0 4px 14px rgba(227,6,19,.4); }
    50%      { box-shadow: 0 4px 22px rgba(227,6,19,.7); }
}

.pss-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: #fff;
    margin: 0 0 2px;
    line-height: 1.3;
}
.pss-subtitle {
    font-size: .78rem;
    color: var(--pss-muted);
    margin: 0;
}

/* تایمر */
.pss-global-timer {
    display: flex;
    align-items: center;
    gap: 5px;
    background: rgba(227,6,19,.12);
    border: 1px solid rgba(227,6,19,.3);
    border-radius: 10px;
    padding: 8px 14px;
    direction: ltr;   /* ← چپ به راست: روز ساعت دقیقه ثانیه */
}
.pss-timer-unit { display: flex; flex-direction: column; align-items: center; gap: 1px; }
.pss-timer-num {
    font-size: 1.15rem;
    font-weight: 900;
    color: #fff;
    line-height: 1;
    font-variant-numeric: tabular-nums;
    min-width: 28px;
    text-align: center;
}
.pss-timer-label { font-size: .56rem; color: #fff; font-weight: 700; direction: rtl; }
.pss-timer-sep { font-size: 1.1rem; font-weight: 900; color: #fff; line-height: 1.4; align-self: flex-start; padding-top: 2px; }

.pss-view-all {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: var(--pss-muted);
    text-decoration: none;
    font-size: .82rem;
    font-weight: 700;
    padding: 7px 14px;
    border: 1px solid var(--pss-border);
    border-radius: 8px;
    background: var(--pss-glass);
    transition: all .25s;
    white-space: nowrap;
}
.pss-view-all:hover {
    color: #fff;
    border-color: rgba(196,181,253,.5);
    background: rgba(255,255,255,.14);
}

/* ── Track ── */
.pss-track-outer {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0;
}
.pss-track {
    display: flex;
    gap: 14px;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none;
    padding: 8px 4px 12px;
    flex: 1;
    -webkit-overflow-scrolling: touch;
}
.pss-track::-webkit-scrollbar { display: none; }

/* ── کارت محصول ── */
.pss-card {
    flex: 0 0 var(--pss-card-w);
    width: var(--pss-card-w);
    background: var(--pss-card-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--pss-border);
    border-radius: var(--pss-radius);
    position: relative;
    transition: transform .3s ease, box-shadow .3s ease, border-color .25s;
    overflow: hidden;
    cursor: pointer;
}
.pss-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 40px rgba(0,0,0,.3);
    border-color: rgba(196,181,253,.4);
}
.pss-card:focus { outline: 2px solid var(--pss-accent); outline-offset: 2px; }

/* ── ربان مورب گوشه — corner ribbon ── */
.pss-discount-badge {
    position: absolute;
    top: 0;
    right: 0;
    z-index: 4;
    width: 80px;
    height: 80px;
    overflow: hidden;
    pointer-events: none;
}
.pss-discount-badge span {
    position: absolute;
    top: 5px;
    right: -30px;
    width: 100px;
    background: linear-gradient(135deg, var(--pss-accent), var(--pss-accent-dark));
    color: #fff;
    font-size: 1rem;
    direction: ltr;
    font-weight: 900;
    text-align: center;
    padding: 4px 0;
    letter-spacing: .5px;
    transform: rotate(45deg);
    box-shadow: 0 2px 6px rgba(0, 0, 0, .3);
    line-height: 1.4;
    border: 1px;
    border-style: dashed;
}



/* تصویر */
.pss-img-wrap {
    display: block;
    width: 100%;
    aspect-ratio: 1;
    padding: 36px 14px 10px;
    position: relative;
    overflow: hidden;
    background: rgba(0,0,0,.12);
    text-decoration: none;
}
.pss-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform .4s ease;
}
.pss-card:hover .pss-img { transform: scale(1.07); }
.pss-out-of-stock {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.6);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: .8rem;
    font-weight: 700;
    border-radius: 0;
}

/* body کارت */
.pss-card-body {
    padding: 10px 12px 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.pss-card-title {
    display: block;
    font-size: .78rem;
    font-weight: 600;
    color: var(--pss-text);
    text-decoration: none;
    line-height: 1.5;
    min-height: 2.25em;
    transition: color .2s;
    text-align: center;
}
.pss-card-title:hover { color: #c4b5fd; }

/* قیمت */
.pss-price-row {
    display: flex;
    flex-direction: column;
    gap: 5px;
    align-items: center;
    text-align: center;
}
.pss-price-old-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}
.pss-price-old {
    font-size: .82rem;
    color: #fff;
    position: relative;
    display: inline-block;
    font-weight: 600;
}
/* خط کج قرمز — مثل تصویر نمونه */
.pss-price-old::after {
    content: '';
    position: absolute;
    right: -3px; left: -3px;
    top: 45%;
    height: 2px;
    background: var(--pss-accent);
    border-radius: 1px;
    transform: rotate(-12deg);
    box-shadow: 0 1px 3px rgba(227,6,19,.4);
}
.pss-price-old-unit {
    font-size: .85rem;
    color: #fff;
}
.pss-prices { display: flex; align-items: baseline; gap: 4px; justify-content: center; }
.pss-price-sale {
    font-size: 1.05rem;
    font-weight: 900;
    color: #4ade80;
    line-height: 1;
}
.pss-price-unit {
    font-size: .85rem;
    color: #fff;
    font-weight: 600;
}

/* دکمه */
.pss-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    width: 100%;
    padding: 8px;
    border-radius: 8px;
    font-family: 'Peyda', Tahoma, sans-serif;
    font-size: .73rem;
    font-weight: 700;
    cursor: pointer;
    border: none;
    text-decoration: none;
    transition: all .25s;
    background: linear-gradient(135deg, var(--pss-accent), var(--pss-accent-dark));
    color: #fff;
    box-shadow: 0 3px 10px rgba(227,6,19,.3);
}
.pss-btn:hover { transform: translateY(-1px); box-shadow: 0 5px 16px rgba(227,6,19,.5); color: #fff; }
.pss-btn.pss-btn-var {
    background: linear-gradient(135deg, var(--pss-accent), var(--pss-accent-dark));
    box-shadow: 0 3px 10px rgba(227,6,19,.3);
}
.pss-btn.pss-btn-var:hover { box-shadow: 0 5px 16px rgba(227,6,19,.55); }
.pss-btn[disabled], .pss-btn.disabled {
    background: rgba(255,255,255,.1);
    color: rgba(241,232,255,.4);
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

/* ── ناوبری ── */
.pss-nav {
    flex-shrink: 0;
    width: 36px; height: 36px;
    border-radius: 50%;
    background: var(--pss-glass);
    border: 1.5px solid var(--pss-border);
    color: var(--pss-muted);
    display: flex; align-items: center; justify-content: center;
    cursor: pointer;
    transition: all .25s;
    z-index: 2;
}
.pss-nav:hover { background: rgba(255,255,255,.16); border-color: rgba(196,181,253,.5); color: #fff; }
.pss-nav:disabled { opacity: .3; cursor: not-allowed; }
.pss-nav-next { transform: scaleX(-1); }

/* dots */
.pss-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 12px;
}
.pss-dot {
    width: 6px; height: 6px;
    border-radius: 50%;
    background: rgba(255,255,255,.2);
    cursor: pointer;
    transition: all .3s;
}
.pss-dot.active {
    background: var(--pss-accent);
    width: 20px;
    border-radius: 3px;
    box-shadow: 0 0 8px var(--pss-accent);
}

/* responsive */
@media (max-width: 768px) {
    :root { --pss-card-w: 185px; }
    .pss-title { font-size: 1rem; }
    .pss-nav { display: none; }
    .pss-global-timer { padding: 6px 10px; }
    .pss-timer-num { font-size: 1rem; }
}
@media (max-width: 480px) {
    :root { --pss-card-w: 160px; }
    .pss-header { padding-bottom: 12px; margin-bottom: 14px; }
    .pss-fire-badge { font-size: .72rem; padding: 5px 10px; }
}

/* ── صفحه کامل محصولات تخفیف‌خورده ── */
.pss-page-wrap {
    direction: rtl;
    font-family: 'Peyda', Tahoma, sans-serif;
    padding: 24px 0;
}
.pss-page-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 28px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255,255,255,.1);
    flex-wrap: wrap;
    justify-content: space-between;
}
.pss-page-title-group { display: flex; align-items: center; gap: 12px; }
.pss-page-count {
    font-size: .78rem;
    color: rgba(241,232,255,.5);
    background: rgba(255,255,255,.07);
    border: 1px solid rgba(255,255,255,.12);
    padding: 3px 12px;
    border-radius: 20px;
}
.pss-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
}
.pss-grid .pss-card { flex: none; width: auto; }
@media (max-width: 1200px) { .pss-grid { grid-template-columns: repeat(4,1fr); } }
@media (max-width: 900px)  { .pss-grid { grid-template-columns: repeat(3,1fr); } }
@media (max-width: 600px)  { .pss-grid { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 400px)  { .pss-grid { grid-template-columns: 1fr; } }
