/* ===== متغیرهای رنگ (تم سایت) ===== */
:root {
    --wccc-green: #22c55e;
    --wccc-green-dark: #16a34a;
    --wccc-bg: #070a0e;
    --wccc-card-bg: rgba(13, 16, 19, 0.95);
    --wccc-border: rgba(34, 197, 94, 0.3);
    --wccc-text: #e5e5e5;
    --wccc-text-muted: #a1a1aa;
}

/* ===== شورتکد هدر ===== */
.wccc-header-cart {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none !important;
    color: #fff !important;
    padding: 6px 10px;
    border-radius: 8px;
    transition: color .2s, background .2s;
    font-size: 14px;
    line-height: 1;
    direction: rtl;
}
.wccc-header-cart:hover { color: var(--wccc-green) !important; }
.wccc-header-icon { display: inline-flex; align-items: center; justify-content: center; color: currentColor; }
.wccc-header-icon svg { display: block; }
.wccc-header-count {
    background: var(--wccc-green);
    color: var(--wccc-bg);
    border-radius: 50%;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 800;
    line-height: 1;
}
.wccc-header-total { font-size: 13px; font-weight: 600; color: var(--wccc-green); }
.wccc-header-total .amount, .wccc-header-total bdi { color: inherit !important; }

/* ===== پاپ آپ ===== */
.wccc-popup-overlay {
    position: fixed; inset: 0; background: rgba(0,0,0,.75); z-index: 99999;
    display: flex; align-items: center; justify-content: center; direction: rtl;
    backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.wccc-popup {
    background: var(--wccc-card-bg); border: 1px solid var(--wccc-border);
    border-radius: 20px; padding: 35px 24px 25px; max-width: 420px; width: 92%;
    text-align: center; position: relative; font-family: inherit;
    animation: wcccPop .3s cubic-bezier(0.22, 1, 0.36, 1);
    box-shadow: 0 20px 60px rgba(0,0,0,.6), 0 0 30px rgba(34,197,94,.1);
}
@keyframes wcccPop { from { opacity: 0; transform: translateY(20px) scale(.95); } to { opacity: 1; transform: translateY(0) scale(1); } }

.wccc-popup-icon {
    width: 60px; height: 60px; background: rgba(34, 197, 94, 0.15); border-radius: 50%;
    display: flex; align-items: center; justify-content: center; margin: 0 auto 15px;
    color: var(--wccc-green); border: 2px solid rgba(34, 197, 94, 0.4); box-shadow: 0 0 20px rgba(34, 197, 94, 0.2);
}
.wccc-popup-icon svg { width: 30px; height: 30px; }

.wccc-popup h3 { margin: 0 0 25px; font-size: 16px; font-weight: 700; color: #fff; line-height: 1.6; }
.wccc-popup-close {
    position: absolute; top: 12px; left: 15px; background: none; border: none;
    font-size: 24px; line-height: 1; color: var(--wccc-text-muted); cursor: pointer;
    padding: 4px 8px; border-radius: 6px; transition: color .2s;
}
.wccc-popup-close:hover { color: var(--wccc-green); }

.wccc-popup-buttons { display: flex; flex-direction: column; gap: 10px; }
.wccc-btn {
    display: block; width: 100%; padding: 12px 16px; border-radius: 100px;
    text-align: center; text-decoration: none; border: 1px solid transparent;
    cursor: pointer; font-family: inherit; font-size: 14px; font-weight: 700;
    transition: opacity .2s, transform .15s, background .2s, box-shadow .2s; box-sizing: border-box;
}
.wccc-btn:hover { transform: translateY(-2px); }

.wccc-btn-continue { background: transparent; color: var(--wccc-text); border-color: rgba(255,255,255,0.1); }
.wccc-btn-continue:hover { background: rgba(255,255,255,0.05); }
.wccc-btn-cart { background: rgba(255,255,255,0.05); color: #fff; border-color: rgba(34, 197, 94, 0.3); }
.wccc-btn-cart:hover { background: rgba(34, 197, 94, 0.1); border-color: var(--wccc-green); }
.wccc-btn-checkout { background: linear-gradient(135deg, var(--wccc-green-dark), var(--wccc-green)); color: #fff; border: none; box-shadow: 0 5px 15px rgba(34, 197, 94, 0.3); }
.wccc-btn-checkout:hover { box-shadow: 0 8px 25px rgba(34, 197, 94, 0.5); }

/* ===== آیکون شناور ===== */
.wccc-float { position: fixed; bottom: 22px; right: 22px; z-index: 9998; }
.wccc-float-btn {
    width: 54px; height: 54px; border-radius: 50%; background: var(--wccc-bg);
    border: 2px solid var(--wccc-green); cursor: pointer; display: flex;
    align-items: center; justify-content: center; color: var(--wccc-green);
    box-shadow: 0 6px 20px rgba(0,0,0,.5), 0 0 15px rgba(34, 197, 94, 0.2);
    position: relative; transition: transform .2s, box-shadow .2s; padding: 0;
}
.wccc-float-btn:hover { transform: scale(1.08); box-shadow: 0 8px 24px rgba(34,197,94,.4); }
.wccc-float-btn svg { width: 22px; height: 22px; display: block; }
.wccc-float-count {
    position: absolute; top: -4px; right: -4px; background: var(--wccc-green);
    color: var(--wccc-bg); border-radius: 50%; min-width: 20px; height: 20px;
    padding: 0 4px; font-size: 11px; font-weight: 800; display: flex;
    align-items: center; justify-content: center; border: 2px solid var(--wccc-bg); line-height: 1;
}

/* ===== مینی کارت ===== */
.wccc-mini-cart {
    position: fixed; bottom: 88px; right: 22px; width: 360px; max-width: calc(100vw - 32px);
    max-height: 470px; background: var(--wccc-card-bg); border: 1px solid var(--wccc-border);
    border-radius: 16px; box-shadow: 0 10px 40px rgba(0,0,0,.6), 0 0 20px rgba(34, 197, 94, 0.1);
    z-index: 9997; display: flex; flex-direction: column; overflow: hidden; direction: rtl;
    animation: wcccPop .25s ease; backdrop-filter: blur(15px); -webkit-backdrop-filter: blur(15px);
}
.wccc-mini-cart-header {
    display: flex; justify-content: space-between; align-items: center;
    padding: 14px 16px; border-bottom: 1px solid rgba(255,255,255,0.05);
    font-weight: 700; font-size: 14px; color: #fff; background: rgba(0,0,0,0.2);
}
.wccc-mini-close {
    background: none; border: none; font-size: 22px; line-height: 1; cursor: pointer;
    color: var(--wccc-text-muted); padding: 0 4px; transition: color .2s;
}
.wccc-mini-close:hover { color: var(--wccc-green); }
.wccc-mini-cart-body { padding: 10px 16px; overflow-y: auto; flex: 1; }
.wccc-empty { text-align: center; color: var(--wccc-text-muted); padding: 24px 0; font-size: 13px; }

/* آیتم‌های مینی‌کارت */
.wccc-items { list-style: none; margin: 0; padding: 0; }
.wccc-item {
    display: flex; gap: 12px; padding: 14px 0; border-bottom: 1px solid rgba(255,255,255,0.05);
    align-items: center; position: relative;
}
.wccc-item:last-child { border-bottom: none; }
.wccc-item-thumb img {
    width: 48px; height: 48px; border-radius: 8px; object-fit: cover;
    display: block; border: 1px solid rgba(255,255,255,0.1);
}
.wccc-item-info { flex: 1; min-width: 0; padding-left: 20px; }
.wccc-item-name {
    font-size: 13px; color: var(--wccc-text); text-decoration: none; display: block;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500;
}
.wccc-item-name:hover { color: var(--wccc-green); }
.wccc-item-meta { font-size: 12px; color: var(--wccc-green); margin-top: 4px; font-weight: 700; }

/* دکمه‌های تغییر تعداد */
.wccc-item-actions {
    display: flex; align-items: center; gap: 6px; background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08); border-radius: 20px; padding: 2px;
}
.wccc-qty-btn {
    width: 22px; height: 22px; border-radius: 50%; border: none; background: transparent;
    color: #fff; font-size: 16px; font-weight: 700; cursor: pointer; display: flex;
    align-items: center; justify-content: center; transition: background .2s, color .2s;
}
.wccc-qty-btn:hover { background: var(--wccc-green); color: var(--wccc-bg); }
.wccc-qty-num { font-size: 13px; font-weight: 700; color: #fff; min-width: 16px; text-align: center; }

/* دکمه حذف */
.wccc-item-remove {
    position: absolute; top: 10px; left: 0; background: transparent; border: none;
    color: #ef4444; cursor: pointer; padding: 4px; opacity: 0.6; transition: opacity .2s, transform .2s;
}
.wccc-item-remove:hover { opacity: 1; transform: scale(1.1); }

.wccc-total { padding: 12px 0 4px; font-size: 14px; font-weight: 700; color: #fff; display: flex; justify-content: space-between; }
.wccc-total .amount, .wccc-total bdi { color: var(--wccc-green) !important; }

/* فوتر مینی‌کارت (دو دکمه) */
.wccc-mini-cart-footer {
    display: flex; gap: 10px; padding: 14px 16px;
    border-top: 1px solid rgba(255,255,255,0.05); background: rgba(0,0,0,0.2);
}
.wccc-mini-cart-footer .wccc-btn {
    flex: 1; padding: 10px 8px; font-size: 13px; white-space: nowrap;
}
.wccc-btn-view-cart {
    background: rgba(255,255,255,0.05); color: #fff;
    border-color: rgba(255,255,255,0.1); box-shadow: none;
}
.wccc-btn-view-cart:hover { background: rgba(255,255,255,0.1); }