/* Bunak Purchase Rules – front */

/* ---------- باکس زیر دکمه ---------- */
.bpr-box { display:block; width:100%; box-sizing:border-box; margin:8px 0 0; padding:8px 10px; border-radius:12px; direction:rtl; text-align:right;
    font-size:11.5px; line-height:1.7; font-weight:600; color:#7c2d12;
    background:linear-gradient(120deg,#fff7ed 0%,#ffedd5 55%,#fde68a 100%); border:1px solid #fdba74;
    box-shadow:0 3px 10px rgba(249,115,22,.14); position:relative; overflow:hidden; }
.bpr-box::before { content:""; position:absolute; inset:0 auto 0 0; width:4px; background:linear-gradient(180deg,#f97316,#ef4444); }
.bpr-box.only-max { color:#7f1d1d; background:linear-gradient(120deg,#fef2f2,#fee2e2); border-color:#fca5a5; box-shadow:0 3px 10px rgba(239,68,68,.12); }
.bpr-box.only-max::before { background:linear-gradient(180deg,#ef4444,#be123c); }
.bpr-box-row { display:flex; gap:6px; align-items:flex-start; }
.bpr-box-row + .bpr-box-row { margin-top:3px; padding-top:3px; border-top:1px dashed rgba(124,45,18,.25); }
.bpr-box-row.is-max { color:#991b1b; }
.bpr-box-ico { flex:0 0 auto; }
.bpr-box b { font-weight:900; }
.wcam-master-container .bpr-box { margin-top:12px; font-size:13px; padding:10px 14px; }

/* ---------- توست ---------- */
.bpr-toast { position:fixed; z-index:100002; bottom:24px; left:50%; transform:translate(-50%,30px); opacity:0; max-width:92vw; width:max-content;
    padding:11px 18px; border-radius:14px; font-size:13px; font-weight:700; line-height:1.8; direction:rtl; color:#fff; background:#1e293b;
    box-shadow:0 14px 34px rgba(15,23,42,.35); transition:all .3s ease; }
.bpr-toast.show { opacity:1; transform:translate(-50%,0); }
.bpr-toast.ok { background:linear-gradient(120deg,#059669,#10b981); }
.bpr-toast.warn { background:linear-gradient(120deg,#d97706,#f59e0b); color:#1f1300; }
.bpr-toast.err { background:linear-gradient(120deg,#dc2626,#ef4444); }

/* ---------- مودال ---------- */
body.bpr-lock { overflow:hidden; }
.bpr-modal { position:fixed; inset:0; z-index:100001; display:flex; align-items:center; justify-content:center; padding:16px; opacity:0; visibility:hidden; transition:opacity .25s, visibility .25s; font-family:inherit; }
.bpr-modal.open { opacity:1; visibility:visible; }
.bpr-overlay { position:absolute; inset:0; background:rgba(15,23,42,.62); backdrop-filter:blur(7px); }
.bpr-dialog { position:relative; width:100%; max-width:760px; max-height:92vh; display:flex; flex-direction:column; background:#fff; border-radius:26px; overflow:hidden;
    box-shadow:0 30px 70px -12px rgba(15,23,42,.5); transform:translateY(18px) scale(.97); transition:transform .3s cubic-bezier(.2,.8,.2,1); }
.bpr-modal.open .bpr-dialog { transform:none; }
.bpr-x { position:absolute; top:12px; left:12px; z-index:3; width:36px; height:36px; border:0; border-radius:50%; background:rgba(255,255,255,.22); color:#fff; font-size:24px; line-height:1; cursor:pointer; backdrop-filter:blur(4px); }
.bpr-x:hover { background:rgba(255,255,255,.4); }
.bpr-body { overflow-y:auto; overscroll-behavior:contain; }

.bpr-head { display:flex; gap:14px; align-items:center; padding:22px 22px 20px 56px; color:#fff; background:linear-gradient(125deg,#4f46e5 0%,#7c3aed 55%,#db2777 100%); }
.bpr-head.is-ok { background:linear-gradient(125deg,#059669 0%,#10b981 60%,#22c55e 100%); }
.bpr-head-img { flex:0 0 66px; height:66px; border-radius:18px; background:#fff; padding:5px; box-shadow:0 8px 20px rgba(0,0,0,.25); }
.bpr-head-img img { width:100%; height:100%; object-fit:contain; border-radius:12px; }
.bpr-title { font-size:19px; font-weight:900; margin-bottom:4px; }
.bpr-sub { font-size:13px; opacity:.95; line-height:1.8; }

.bpr-info { padding:16px 22px 4px; }
.bpr-rule { font-size:13.5px; line-height:2; color:#334155; background:#f8fafc; border:1px solid #e2e8f0; border-radius:14px; padding:10px 14px; }
.bpr-rule.is-ok { background:#ecfdf5; border-color:#a7f3d0; color:#065f46; }
.bpr-progress { display:flex; align-items:center; gap:12px; margin:12px 0 4px; font-size:12px; font-weight:800; color:#475569; }
.bpr-bar { flex:1; height:10px; border-radius:99px; background:#e2e8f0; overflow:hidden; }
.bpr-bar i { display:block; height:100%; border-radius:99px; background:linear-gradient(90deg,#f59e0b,#22c55e); transition:width .4s ease; }
.bpr-chips { display:flex; flex-wrap:wrap; gap:6px; margin:8px 0 2px; }
.bpr-chip { font-size:11.5px; font-weight:700; padding:5px 11px; border-radius:99px; background:#eef2ff; color:#3730a3; border:1px solid #c7d2fe; }
.bpr-chip.is-soft { background:#fff7ed; color:#9a3412; border-color:#fed7aa; }
.bpr-chip.is-max { background:#fef2f2; color:#991b1b; border-color:#fecaca; }

.bpr-list-title { padding:14px 22px 6px; font-size:14px; font-weight:900; color:#0f172a; }
.bpr-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(150px,1fr)); gap:12px; padding:6px 22px 18px; }
.bpr-empty { grid-column:1/-1; text-align:center; padding:30px 10px; color:#94a3b8; font-weight:700; }

.bpr-card { position:relative; display:flex; flex-direction:column; align-items:stretch; gap:6px; padding:12px 10px 10px; border-radius:18px; background:#fff; border:1.5px solid #e2e8f0; text-align:center; transition:transform .2s, box-shadow .2s, border-color .2s; }
.bpr-card:hover { transform:translateY(-2px); box-shadow:0 10px 24px rgba(15,23,42,.1); }
.bpr-card.is-busy { opacity:.6; pointer-events:none; }
.bpr-card.is-picked { border-color:#22c55e; background:linear-gradient(180deg,#f0fdf4,#fff); }
.bpr-card.is-featured { border-color:#f59e0b; background:linear-gradient(180deg,#fffbeb,#fff 60%); box-shadow:0 6px 18px rgba(245,158,11,.22); }
.bpr-card.is-featured.is-picked { border-color:#22c55e; }
.bpr-ribbon { position:absolute; top:-1px; right:12px; padding:3px 10px 4px; font-size:10.5px; font-weight:900; color:#fff; background:linear-gradient(120deg,#f59e0b,#ef4444); border-radius:0 0 10px 10px; box-shadow:0 4px 10px rgba(239,68,68,.35); z-index:1; }
.bpr-card-img { aspect-ratio:1/1; display:flex; align-items:center; justify-content:center; margin-top:8px; }
.bpr-card-img img { max-width:100%; max-height:100%; object-fit:contain; }
.bpr-card-name { font-size:12.5px; font-weight:800; line-height:1.7; color:#1e293b; min-height:42px; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.bpr-card-price { font-size:12px; font-weight:900; color:#0f766e; display:flex; flex-direction:column; align-items:center; min-height:34px; justify-content:center; }
.bpr-card-price del { color:#94a3b8; font-weight:600; font-size:10.5px; }
.bpr-add { border:0; border-radius:12px; padding:9px 6px; font-size:12.5px; font-weight:900; color:#fff; cursor:pointer; font-family:inherit; background:linear-gradient(120deg,#4f46e5,#7c3aed); box-shadow:0 6px 14px rgba(79,70,229,.35); }
.bpr-add:hover { filter:brightness(1.08); }
.bpr-step { display:flex; align-items:center; justify-content:space-between; border-radius:12px; background:#dcfce7; padding:3px; }
.bpr-step button { width:32px; height:32px; border:0; border-radius:9px; background:#16a34a; color:#fff; font-size:18px; font-weight:900; cursor:pointer; line-height:1; }
.bpr-step span { font-weight:900; color:#166534; font-size:14px; }

.bpr-foot { position:sticky; bottom:0; display:flex; flex-wrap:wrap; gap:10px; align-items:center; justify-content:space-between; padding:14px 22px; background:#fff; border-top:1px solid #e2e8f0; box-shadow:0 -10px 24px rgba(15,23,42,.06); }
.bpr-warn { flex:1 1 100%; font-size:12.5px; font-weight:700; color:#92400e; background:#fffbeb; border:1px solid #fde68a; padding:8px 12px; border-radius:12px; line-height:1.8; }
.bpr-btn { flex:1 1 180px; border:1.5px solid #cbd5e1; background:#fff; color:#334155; border-radius:14px; padding:12px 16px; font-size:13.5px; font-weight:900; cursor:pointer; font-family:inherit; }
.bpr-btn:hover { background:#f1f5f9; }
.bpr-btn.is-primary { border:0; color:#fff; background:linear-gradient(120deg,#059669,#10b981); box-shadow:0 8px 18px rgba(16,185,129,.35); }
.bpr-btn.is-primary:hover { filter:brightness(1.07); }

@media (max-width:560px) {
    .bpr-modal { padding:0; align-items:flex-end; }
    .bpr-dialog { max-height:94vh; border-radius:24px 24px 0 0; }
    .bpr-grid { grid-template-columns:repeat(2,1fr); padding:6px 14px 16px; gap:10px; }
    .bpr-info, .bpr-list-title, .bpr-foot { padding-right:14px; padding-left:14px; }
    .bpr-head { padding:18px 14px 16px 52px; }
    .bpr-title { font-size:16.5px; }
}

/* ---------- افزوده‌ها: پنل قوانین در مودال ---------- */
.bpr-box.is-blocked { background:linear-gradient(120deg,#f1f5f9,#e2e8f0); border-color:#94a3b8; color:#334155; box-shadow:none; }
.bpr-box.is-blocked::before { background:#64748b; }
.bpr-box-more { margin-top:3px; font-size:10.5px; opacity:.75; text-align:left; }
.bpr-head.is-amount { background:linear-gradient(125deg,#b45309 0%,#f59e0b 55%,#f97316 100%); }
.bpr-need { margin-top:8px; font-size:13px; font-weight:800; color:#92400e; background:#fffbeb; border:1px dashed #f59e0b; border-radius:12px; padding:8px 12px; text-align:center; }
.bpr-need b { font-size:15px; color:#b45309; }

.bpr-conds { padding:6px 22px 4px; }
.bpr-conds-title { font-size:14px; font-weight:900; color:#0f172a; margin:12px 0 8px; }
.bpr-conds-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(230px,1fr)); gap:10px; }
.bpr-cond { position:relative; display:flex; gap:10px; align-items:flex-start; padding:11px 12px; border-radius:16px; border:1.5px solid #e2e8f0; background:linear-gradient(135deg,#f8fafc,#fff); overflow:hidden; }
.bpr-cond::before { content:""; position:absolute; inset:0 0 0 auto; width:4px; background:#94a3b8; }
.bpr-cond-ico { flex:0 0 38px; height:38px; border-radius:12px; display:flex; align-items:center; justify-content:center; font-size:20px; background:#fff; box-shadow:0 3px 10px rgba(15,23,42,.1); }
.bpr-cond-txt { flex:1; min-width:0; }
.bpr-cond-txt b { display:block; font-size:12.5px; font-weight:900; color:#0f172a; }
.bpr-cond-txt p { margin:2px 0 0; font-size:12px; line-height:1.9; color:#475569; }
.bpr-cond-txt p b { display:inline; color:#4f46e5; font-size:12.5px; }
.bpr-cond-st { flex:0 0 22px; height:22px; border-radius:50%; display:flex; align-items:center; justify-content:center; font-size:12px; font-weight:900; color:#fff; background:#94a3b8; }
.bpr-cond.is-ok { border-color:#86efac; background:linear-gradient(135deg,#f0fdf4,#fff); }
.bpr-cond.is-ok::before, .bpr-cond.is-ok .bpr-cond-st { background:#22c55e; }
.bpr-cond.is-bad { border-color:#fca5a5; background:linear-gradient(135deg,#fef2f2,#fff); animation:bprPulse 1.8s ease-in-out infinite; }
.bpr-cond.is-bad::before, .bpr-cond.is-bad .bpr-cond-st { background:#ef4444; }
.bpr-cond.is-info::before, .bpr-cond.is-info .bpr-cond-st { background:#6366f1; }
.bpr-cond.k-global { border-color:#fdba74; background:linear-gradient(135deg,#fff7ed,#fff); }
.bpr-cond.k-ratio .bpr-cond-ico, .bpr-cond.k-with .bpr-cond-ico { background:#fff7ed; }
@keyframes bprPulse { 0%,100% { box-shadow:0 0 0 0 rgba(239,68,68,.25); } 50% { box-shadow:0 0 0 6px rgba(239,68,68,0); } }
@media (max-width:560px) { .bpr-conds { padding:6px 14px 4px; } .bpr-conds-grid { grid-template-columns:1fr; } }

/* ---------- v2: دکمه‌ها (رنگ متن سفید، مقاوم در برابر استایل قالب) ---------- */
.bpr-modal button { font-family:inherit; text-transform:none; letter-spacing:0; }
.bpr-modal .bpr-add {
    display:flex !important; align-items:center; justify-content:center; gap:4px; width:100%;
    border:0 !important; border-radius:14px !important; padding:11px 6px !important; min-height:42px;
    font-size:13px !important; font-weight:900 !important; line-height:1.2 !important;
    color:#fff !important; -webkit-text-fill-color:#fff !important; text-shadow:0 1px 2px rgba(0,0,0,.25);
    background:linear-gradient(135deg,#f97316 0%,#ec4899 55%,#8b5cf6 100%) !important;
    box-shadow:0 8px 18px rgba(236,72,153,.38), inset 0 1px 0 rgba(255,255,255,.35) !important;
    transition:transform .12s ease, box-shadow .12s ease, filter .12s ease; cursor:pointer;
}
.bpr-modal .bpr-add:hover { filter:brightness(1.08); transform:translateY(-1px); box-shadow:0 12px 24px rgba(236,72,153,.45) !important; }
.bpr-modal .bpr-add:active { transform:scale(.96); }
.bpr-modal .bpr-card.is-featured .bpr-add { background:linear-gradient(135deg,#f59e0b 0%,#ef4444 60%,#db2777 100%) !important; box-shadow:0 8px 18px rgba(239,68,68,.4), inset 0 1px 0 rgba(255,255,255,.35) !important; }
.bpr-modal .bpr-step { background:linear-gradient(135deg,#dcfce7,#bbf7d0) !important; border:1px solid #86efac; border-radius:14px; padding:4px !important; }
.bpr-modal .bpr-step button { width:36px !important; height:36px !important; border:0 !important; border-radius:11px !important; padding:0 !important; font-size:20px !important; font-weight:900 !important; line-height:1 !important; color:#fff !important; -webkit-text-fill-color:#fff !important; background:linear-gradient(135deg,#22c55e,#059669) !important; box-shadow:0 4px 10px rgba(5,150,105,.35); cursor:pointer; }
.bpr-modal .bpr-step button.bpr-minus { background:linear-gradient(135deg,#fb7185,#e11d48) !important; box-shadow:0 4px 10px rgba(225,29,72,.3); }
.bpr-modal .bpr-step span { font-size:15px !important; color:#14532d !important; }
.bpr-modal .bpr-btn { color:#334155 !important; -webkit-text-fill-color:#334155 !important; border:1.5px solid #cbd5e1 !important; background:#fff !important; border-radius:14px !important; }
.bpr-modal .bpr-btn.is-primary { color:#fff !important; -webkit-text-fill-color:#fff !important; border:0 !important; background:linear-gradient(135deg,#10b981,#059669 60%,#047857) !important; box-shadow:0 8px 18px rgba(5,150,105,.38) !important; }
.bpr-modal .bpr-x { color:#fff !important; -webkit-text-fill-color:#fff !important; padding:0 !important; }

/* ---------- تعداد خودِ محصول در هدر ---------- */
.bpr-head-txt { flex:1; min-width:0; }
.bpr-mq { display:flex; align-items:center; gap:10px; margin-top:8px; }
.bpr-mq > span { font-size:12px; font-weight:800; opacity:.95; }
.bpr-mqc { display:inline-flex; align-items:center; gap:2px; background:rgba(255,255,255,.2); border:1px solid rgba(255,255,255,.35); border-radius:14px; padding:3px; backdrop-filter:blur(4px); }
.bpr-mqc b { min-width:38px; text-align:center; font-size:16px; font-weight:900; color:#fff; }
.bpr-modal .bpr-mqc button { width:34px !important; height:34px !important; border:0 !important; border-radius:11px !important; padding:0 !important; font-size:20px !important; font-weight:900 !important; line-height:1 !important; cursor:pointer; color:#4f46e5 !important; -webkit-text-fill-color:#4f46e5 !important; background:#fff !important; box-shadow:0 3px 8px rgba(0,0,0,.18); transition:transform .1s; }
.bpr-modal .bpr-mqc button:active { transform:scale(.9); }
.bpr-modal .bpr-mqc button:disabled { opacity:.5; cursor:default; }
.bpr-head.is-ok .bpr-mqc button { color:#047857 !important; -webkit-text-fill-color:#047857 !important; }
.bpr-head.is-amount .bpr-mqc button { color:#b45309 !important; -webkit-text-fill-color:#b45309 !important; }
.bpr-sub { overflow:hidden; text-overflow:ellipsis; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; }

/* ---------- اسکلت بارگذاری ---------- */
.bpr-skel { padding:18px 22px 24px; }
.bpr-skel i, .bpr-skel b { display:block; border-radius:14px; background:linear-gradient(90deg,#eef2f7 25%,#f8fafc 50%,#eef2f7 75%); background-size:200% 100%; animation:bprShimmer 1.1s linear infinite; }
.bpr-skel i { height:46px; margin-bottom:10px; }
.bpr-skel-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(150px,1fr)); gap:12px; margin-top:16px; }
.bpr-skel-grid b { height:190px; }
@keyframes bprShimmer { to { background-position:-200% 0; } }

/* انیمیشن سریع‌تر مودال */
.bpr-modal { transition:opacity .15s, visibility .15s; }
.bpr-dialog { transition:transform .18s cubic-bezier(.2,.8,.2,1); }
.bpr-card, .bpr-bar i { transition-duration:.12s; }
@media (max-width:560px) { .bpr-mq { flex-wrap:wrap; gap:6px; } .bpr-skel { padding:14px; } }

/* ---------- حالت هدیه ---------- */
.bpr-chip.is-gift { background:linear-gradient(120deg,#fff7ed,#fce7f3); color:#9d174d; border-color:#fbcfe8; }
.bpr-giftbadge { position:absolute; top:8px; left:8px; z-index:1; padding:3px 9px; border-radius:99px; font-size:10.5px; font-weight:900; color:#fff; background:linear-gradient(120deg,#ec4899,#8b5cf6); box-shadow:0 4px 10px rgba(139,92,246,.4); }
.bpr-card-price.is-gift span { color:#be185d; font-size:14px; }
.bpr-card-price.is-gift del { color:#94a3b8; }

/* ======== v3 ======== */
/* باکس کوتاه روی کارت */
.bpr-box { display:flex; align-items:center; gap:7px; padding:6px 8px 6px 6px; font-size:11.5px; line-height:1.6; }
.bpr-box-txt { flex:1; min-width:0; }
.bpr-box-img { flex:0 0 24px; width:24px; height:24px; object-fit:contain; border-radius:7px; background:#fff; padding:2px; box-shadow:0 2px 6px rgba(0,0,0,.12); }
.bpr-box.has-ratio { color:#312e81; background:linear-gradient(120deg,#eef2ff,#e0e7ff); border-color:#a5b4fc; box-shadow:0 3px 10px rgba(79,70,229,.14); }
.bpr-box.has-ratio::before { background:linear-gradient(180deg,#6366f1,#8b5cf6); }
.bpr-box.is-gift { color:#831843; background:linear-gradient(120deg,#fff1f2,#fce7f3); border-color:#f9a8d4; box-shadow:0 3px 10px rgba(236,72,153,.16); }
.bpr-box.is-gift::before { background:linear-gradient(180deg,#f472b6,#a855f7); }
.bpr-info-btn { flex:0 0 22px; width:22px; height:22px; padding:0 !important; border:0 !important; border-radius:50% !important; cursor:pointer; font:italic 900 13px/22px Georgia,serif !important; text-align:center;
    color:#fff !important; -webkit-text-fill-color:#fff !important; background:linear-gradient(135deg,#6366f1,#8b5cf6) !important; box-shadow:0 3px 8px rgba(99,102,241,.4); transition:transform .12s; }
.bpr-info-btn:hover { transform:scale(1.15); }
.bpr-box.is-gift .bpr-info-btn { background:linear-gradient(135deg,#ec4899,#a855f7) !important; }
.bpr-box.only-max .bpr-info-btn { background:linear-gradient(135deg,#ef4444,#be123c) !important; }
.wcam-master-container .bpr-box { font-size:13px; }

/* پاپ‌اور شناور */
.bpr-pop { position:fixed; z-index:100003; opacity:0; visibility:hidden; transform:translateY(6px) scale(.97); transition:opacity .15s, transform .15s, visibility .15s;
    background:#fff; border-radius:18px; overflow:hidden; box-shadow:0 22px 50px -10px rgba(15,23,42,.45), 0 0 0 1px rgba(15,23,42,.06); direction:rtl; text-align:right; max-height:70vh; overflow-y:auto; }
.bpr-pop.show { opacity:1; visibility:visible; transform:none; }
.bpr-pop-head { display:flex; align-items:center; gap:10px; padding:12px 14px; color:#fff; font-size:14px; }
.bpr-pop-head.is-set { background:linear-gradient(125deg,#4f46e5,#7c3aed); }
.bpr-pop-head.is-gift { background:linear-gradient(125deg,#ec4899,#8b5cf6); }
.bpr-pop-head.is-rule { background:linear-gradient(125deg,#475569,#1e293b); }
.bpr-pop-head img { width:34px; height:34px; object-fit:contain; background:#fff; border-radius:10px; padding:3px; }
.bpr-pop-list { padding:10px 12px 12px; display:grid; gap:8px; }
.bpr-pop-row { display:flex; gap:10px; align-items:flex-start; padding:9px 10px; border-radius:13px; background:#f8fafc; border:1px solid #e2e8f0; }
.bpr-pop-ic { flex:0 0 32px; height:32px; display:flex; align-items:center; justify-content:center; font-size:17px; border-radius:10px; background:#fff; box-shadow:0 2px 8px rgba(15,23,42,.1); }
.bpr-pop-row b { font-size:12.5px; color:#0f172a; display:block; }
.bpr-pop-row p { margin:2px 0 0; font-size:12.5px; line-height:1.95; color:#475569; }
.bpr-pop-row p b { display:inline; color:#4f46e5; }
.bpr-pop-row.k-ratio, .bpr-pop-row.k-with { background:linear-gradient(135deg,#faf5ff,#fff); border-color:#ddd6fe; }

/* مودال: تصویر کنار متن، دکمه بستن قرمز، ترتیب z-index */
.bpr-rule.has-img { display:flex; gap:12px; align-items:center; }
.bpr-rule-img { flex:0 0 52px; width:52px; height:52px; object-fit:contain; background:#fff; border-radius:14px; padding:4px; border:1px solid #e2e8f0; box-shadow:0 4px 12px rgba(15,23,42,.08); }
.bpr-modal .bpr-x { top:12px !important; left:12px !important; width:40px !important; height:40px !important; display:flex !important; align-items:center; justify-content:center; padding:0 !important; border:2px solid rgba(255,255,255,.9) !important; border-radius:50% !important; cursor:pointer; backdrop-filter:none !important;
    background:linear-gradient(135deg,#f43f5e,#dc2626) !important; box-shadow:0 8px 18px rgba(220,38,38,.5); transition:transform .15s, box-shadow .15s; z-index:20; }
.bpr-modal .bpr-x:hover { transform:rotate(90deg) scale(1.08); box-shadow:0 10px 22px rgba(220,38,38,.65); }
.bpr-modal .bpr-x svg { display:block; }
.bpr-grid { position:relative; z-index:0; }
.bpr-card { isolation:isolate; }
.bpr-foot { z-index:30 !important; }
.bpr-modal .bpr-btn.is-continue { color:#fff !important; -webkit-text-fill-color:#fff !important; border:0 !important; background:linear-gradient(135deg,#22c55e,#16a34a 60%,#15803d) !important; box-shadow:0 8px 18px rgba(22,163,74,.4) !important; }
.bpr-modal .bpr-btn.is-checkout { color:#fff !important; -webkit-text-fill-color:#fff !important; border:0 !important; background:linear-gradient(135deg,#4f46e5,#3730a3) !important; box-shadow:0 8px 18px rgba(55,48,163,.35) !important; }
.bpr-modal .bpr-btn.is-continue:hover, .bpr-modal .bpr-btn.is-checkout:hover { filter:brightness(1.08); }

/* ======== v4 ======== */
/* قفل اسکرول صفحه و جلوگیری از Pull-to-Refresh */
html.bpr-open, html.bpr-open body { overscroll-behavior:none !important; overflow:hidden !important; }
html.bpr-open { scrollbar-gutter:stable; }
body.bpr-open { min-height:calc(100vh + 4px) !important; min-height:calc(100dvh + 4px) !important; }
.bpr-modal { overscroll-behavior:contain !important; overflow:hidden !important; }
.bpr-overlay { overscroll-behavior:none; touch-action:none; }
.bpr-body { overflow-y:auto; overscroll-behavior:contain !important; -webkit-overflow-scrolling:touch; touch-action:pan-y; overflow-anchor:none; }

/* نوار وضعیت چسبان بالای مودال */
.bpr-strip { position:sticky; top:0; z-index:40; display:flex; flex-direction:row-reverse; align-items:center; gap:10px; padding:9px 14px; background:linear-gradient(120deg,#fffbeb,#fff7ed); border-bottom:1px solid #fde68a; box-shadow:0 6px 16px -8px rgba(15,23,42,.25); }
.bpr-strip.is-ok { background:linear-gradient(120deg,#ecfdf5,#f0fdf4); border-bottom-color:#a7f3d0; }
.bpr-strip.is-amount { background:linear-gradient(120deg,#fff7ed,#ffedd5); border-bottom-color:#fdba74; }
.bpr-strip-main { flex:1; min-width:0; }
.bpr-strip-txt { font-size:12.5px; font-weight:800; color:#92400e; line-height:1.6; margin-bottom:5px; }
.bpr-strip.is-ok .bpr-strip-txt { color:#047857; }
.bpr-strip-txt b { font-weight:900; font-size:14px; }
.bpr-strip-txt em { font-style:normal; font-weight:600; opacity:.75; font-size:11.5px; }
.bpr-strip .bpr-bar { height:9px; margin:0; background:rgba(15,23,42,.1); box-shadow:inset 0 1px 2px rgba(0,0,0,.12); }
.bpr-strip .bpr-bar i { background:linear-gradient(90deg,#f59e0b,#f97316 40%,#22c55e); box-shadow:0 0 8px rgba(34,197,94,.5); }
.bpr-strip.is-ok .bpr-bar i { background:linear-gradient(90deg,#10b981,#22c55e); }
/* دکمه بستن: داخل باکس، سمت چپ نوار */
.bpr-modal .bpr-strip .bpr-x { position:static !important; flex:0 0 28px; width:28px !important; min-width:28px !important; height:28px !important; min-height:28px !important; margin:0 !important; padding:0 !important;
    display:inline-flex !important; align-items:center; justify-content:center; border:2px solid #fff !important; border-radius:50% !important; background:linear-gradient(135deg,#f43f5e,#dc2626) !important; box-shadow:0 4px 10px rgba(220,38,38,.45); }
.bpr-modal .bpr-strip .bpr-x:hover { transform:rotate(90deg) scale(1.1); }
.bpr-head, .bpr-head { padding-left:22px !important; }
@media (max-width:560px) { .bpr-head { padding-left:14px !important; } }

/* دکمه‌های + و − کوچک‌تر */
.bpr-modal .bpr-mqc button { width:26px !important; height:26px !important; border-radius:9px !important; font-size:16px !important; }
.bpr-mqc { padding:2px; border-radius:12px; }
.bpr-mqc b { min-width:30px; font-size:14px; }
.bpr-mq { margin-top:6px; }
.bpr-modal .bpr-step button { width:28px !important; height:28px !important; border-radius:9px !important; font-size:16px !important; }
.bpr-modal .bpr-step { padding:3px !important; border-radius:12px !important; }
.bpr-modal .bpr-step span { font-size:14px !important; }

/* دکمه i: دایره‌ی کامل */
.bpr-info-btn { box-sizing:border-box !important; display:inline-flex !important; align-items:center; justify-content:center; flex:0 0 20px !important; width:20px !important; min-width:20px !important; max-width:20px !important;
    height:20px !important; min-height:20px !important; max-height:20px !important; aspect-ratio:1/1; margin:0 !important; padding:0 !important; line-height:1 !important; font-size:12px !important; border-radius:50% !important; overflow:hidden; }

/* لوگو: گوشه‌ی منحنی + نوار رنگی نازک دورش */
.bpr-box-img, .bpr-rule-img, .bpr-pop-head img, .bpr-head-img {
    border:2px solid transparent !important; box-sizing:border-box;
    background:linear-gradient(#fff,#fff) padding-box, linear-gradient(135deg,#6366f1,#ec4899,#f59e0b) border-box !important; }
.bpr-box-img { border-width:1.5px !important; border-radius:9px !important; }
.bpr-rule-img { border-radius:18px !important; padding:5px !important; }
.bpr-pop-head img { border-radius:12px !important; }
.bpr-head-img { border-radius:20px !important; }
.bpr-head-img img { border-radius:15px; }

/* نوار اطلاعیه روی کارت: کم‌ارتفاع‌تر */
.bpr-box { padding:3px 7px 3px 4px !important; gap:6px; font-size:11px; line-height:1.45; margin-top:6px; border-radius:10px; }
.bpr-box-img { flex:0 0 20px; width:20px; height:20px; padding:1px; }
.wcam-master-container .bpr-box { padding:5px 10px 5px 6px !important; font-size:12.5px; }
.bpr-info { padding-top:12px; }

/* هایلایت پس از افزودن */
@keyframes bprFlash { 0% { box-shadow:0 0 0 0 rgba(250,204,21,.9), 0 0 0 3px #facc15; background:#fef9c3; }
    45% { box-shadow:0 0 0 6px rgba(250,204,21,.35), 0 0 0 3px #eab308; background:#fef08a; }
    100% { box-shadow:0 0 0 10px rgba(34,197,94,0), 0 0 0 3px #22c55e; background:#dcfce7; } }
.bpr-modal .bpr-step.bpr-flash { animation:bprFlash 1.4s ease-out; }


/* ==========================================================
   مودال اطلاع‌رسانی تغییر تعداد در سبد (بدون انیمیشن/ترنزیشن برای حفظ سرعت)
   ========================================================== */
.bpr-info-modal { display: none; position: fixed; inset: 0; z-index: 2147483200; direction: rtl; }
.bpr-info-modal.open { display: flex; align-items: center; justify-content: center; padding: 16px; }
.bpr-info-overlay { position: absolute; inset: 0; background: rgba(15, 23, 42, .55); }
.bpr-info-dialog {
    position: relative; width: 100%; max-width: 420px; max-height: 86vh; overflow: auto;
    background: #fff; border-radius: 20px; box-shadow: 0 20px 50px rgba(15, 23, 42, .35);
    font-family: inherit; color: #1f2937; box-sizing: border-box;
}
.bpr-info-dialog * { box-sizing: border-box; font-family: inherit; }
.bpr-info-head { display: flex; align-items: center; gap: 10px; padding: 16px 16px 12px; background: linear-gradient(120deg, #eef2ff, #fdf2f8); border-radius: 20px 20px 0 0; }
.bpr-info-ico { flex: 0 0 38px; width: 38px; height: 38px; border-radius: 50%; background: #6366f1; color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 18px; }
.bpr-info-head > div { flex: 1; min-width: 0; }
.bpr-info-head b { display: block; font-size: 15px; font-weight: 900; color: #111827; }
.bpr-info-head p { margin: 2px 0 0; font-size: 12px; color: #6b7280; }
.bpr-info-x { flex: 0 0 auto; border: 0; background: transparent; font-size: 26px; line-height: 1; color: #9ca3af; cursor: pointer; padding: 0 4px; }
.bpr-info-list { padding: 12px 14px 4px; display: flex; flex-direction: column; gap: 10px; }
.bpr-info-item { border: 1px solid #e5e7eb; border-radius: 14px; padding: 10px 12px; background: #f9fafb; }
.bpr-info-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.bpr-info-name { font-size: 13px; font-weight: 800; color: #111827; line-height: 1.6; }
.bpr-info-nums { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; font-size: 13px; }
.bpr-info-nums s { color: #9ca3af; }
.bpr-info-nums i { font-style: normal; color: #6b7280; }
.bpr-info-nums b { color: #b91c1c; font-weight: 900; }
.bpr-info-nums b.is-gone { background: #fee2e2; color: #991b1b; padding: 1px 8px; border-radius: 999px; font-size: 12px; }
.bpr-info-msg { margin: 6px 0 0; font-size: 12px; line-height: 1.9; color: #4b5563; }
.bpr-info-foot { padding: 10px 14px 16px; }
.bpr-info-ok { width: 100%; border: 0; border-radius: 14px; padding: 12px; font-size: 14px; font-weight: 900; color: #fff; background: linear-gradient(135deg, #6366f1, #8b5cf6); cursor: pointer; }
html.bpr-info-open, body.bpr-info-open { overflow: hidden; }
