/* ============================================================
   استایل‌های مشترک - فقط برای المنت‌های داخلی ویجت‌ها
   بدون افکت روی کل صفحه
   ============================================================ */

/* ============================================================
   ========== ریست و تنظیمات پایه ==========
   ============================================================ */

/* حذف فاصله‌های اضافی برای همه ویجت‌ها */
[class*="wcc-"],
[class*="wph-"] {
    box-sizing: border-box;
}

/* ============================================================
   ========== محصولات ==========
   ============================================================ */

.wcc-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #e74c3c;
    color: #fff;
    padding: 5px 12px;
    border-radius: 18px;
    font-size: 12px;
    font-weight: 700;
    z-index: 2;
    box-shadow: 0 3px 10px rgba(231, 76, 60, 0.25);
}

.wcc-product-card {
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid #eee;
    transition: all 0.3s;
}

.wcc-product-card:hover {
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.08);
    transform: translateY(-4px);
}

.wcc-product-img-wrap {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    aspect-ratio: 1;
    background: #f8f9fb;
    padding: 20px;
    overflow: hidden;
}

.wcc-product-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: transform 0.4s;
}

.wcc-product-card:hover .wcc-product-img {
    transform: scale(1.05);
}

.wcc-product-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.3s;
}

.wcc-product-card:hover .wcc-product-overlay {
    opacity: 1;
}

.wcc-product-overlay span {
    background: #fff;
    color: #1e272e;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
}

.wcc-product-content {
    padding: 16px;
}

.wcc-product-cat {
    font-size: 11px;
    color: #636e72;
    margin-bottom: 6px;
}

.wcc-product-cat a {
    color: #636e72;
    text-decoration: none;
}

.wcc-product-title {
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 8px 0;
    line-height: 1.5;
}

.wcc-product-title a {
    color: #1e272e;
    text-decoration: none;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.wcc-product-price {
    font-weight: 700;
    font-size: 17px;
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.wcc-price-current {
    font-size: 18px;
    font-weight: 700;
    color: #2d3436;
}

.wcc-price-old {
    font-size: 14px;
    color: #b2bec3;
    text-decoration: line-through;
    font-weight: 400;
}

.wcc-price-sale {
    font-size: 18px;
    font-weight: 700;
    color: #e74c3c;
    text-decoration: none;
}

/* ============================================================
   ========== صفحه‌بندی ==========
   ============================================================ */

.wcc-pagination {
    margin-top: 32px;
    text-align: center;
}

.wcc-pagination-inner {
    display: inline-flex;
    gap: 6px;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
}

.wcc-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    background: #f1f2f6;
    color: #2d3436;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.2s;
    border: 2px solid transparent;
}

.wcc-pagination .page-numbers:hover {
    background: #dfe6e9;
    border-color: #b2bec3;
}

.wcc-pagination .page-numbers.current {
    background: #0a66c2;
    color: #ffffff;
    border-color: #0a66c2;
    box-shadow: 0 4px 12px rgba(10, 102, 194, 0.25);
}

/* ============================================================
   ========== استایل‌های عمومی ویجت‌ها ==========
   ============================================================ */

/* ===== کانتینرهای اصلی ویجت‌ها - بدون فاصله اضافی ===== */
.wcc-about-wrap,
.wcc-search-wrap,
.wcc-tracking-wrap,
.wcc-contact-wrap,
.wcc-footer,
.wcc-home-wrap,
.wcc-product-wrap,
.wcc-post-wrap,
.wcc-gallery-wrap,
.wcc-cart-wrap,
.wcc-checkout-wrap,
.wcc-order-tracking-wrap,
.wph-container,
.wph-header,
.wcc-sp-wrap,
.wsp-wrap,
.wig-wrap,
.whs-wrap,
.wba-wrap,
.wco-wrap,
.wcc-footer {
    width: 100%;
    max-width: 100% !important;
    margin: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* ===== کانتینرهای داخلی با محدودیت عرض ===== */
.wcc-inner-container,
.wcc-container,
.wcc-content-wrap,
.wph-inner,
.whs-inner,
.wco-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== ریسپانسیو برای موبایل ===== */
@media (max-width: 1024px) {
    .wcc-inner-container,
    .wcc-container,
    .wcc-content-wrap,
    .wph-inner,
    .whs-inner,
    .wco-inner {
        padding: 0 16px;
    }
}

@media (max-width: 768px) {
    .wcc-inner-container,
    .wcc-container,
    .wcc-content-wrap,
    .wph-inner,
    .whs-inner,
    .wco-inner {
        padding: 0 12px;
    }
}

@media (max-width: 480px) {
    .wcc-inner-container,
    .wcc-container,
    .wcc-content-wrap,
    .wph-inner,
    .whs-inner,
    .wco-inner {
        padding: 0 8px;
    }
}

/* ============================================================
   ========== استایل‌های فرم ==========
   ============================================================ */

.wcc-form-group {
    margin-bottom: 16px;
}

.wcc-form-label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    font-size: 13px;
    color: #1e272e;
}

.wcc-form-input {
    width: 100%;
    padding: 12px 14px;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    font-size: 14px;
    color: #1e272e;
    background: #ffffff;
    outline: none;
    font-family: inherit;
    box-sizing: border-box;
    transition: all 0.2s;
}

.wcc-form-input:focus {
    border-color: #0a66c2;
    box-shadow: 0 0 0 3px rgba(10, 102, 194, 0.1);
}

.wcc-form-input.error {
    border-color: #dc2626;
}

.wcc-form-textarea {
    resize: vertical;
    min-height: 80px;
}

/* ============================================================
   ========== دکمه‌ها ==========
   ============================================================ */

.wcc-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    font-family: inherit;
}

.wcc-btn-primary {
    background: #0a66c2;
    color: #fff;
}

.wcc-btn-primary:hover {
    background: #084a8a;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(10, 102, 194, 0.3);
    color: #fff;
}

.wcc-btn-secondary {
    background: #f1f5f9;
    color: #1e272e;
}

.wcc-btn-secondary:hover {
    background: #e2e8f0;
    transform: translateY(-2px);
}

.wcc-btn-success {
    background: #22c55e;
    color: #fff;
}

.wcc-btn-success:hover {
    background: #16a34a;
    transform: translateY(-2px);
    color: #fff;
}

.wcc-btn-danger {
    background: #ef4444;
    color: #fff;
}

.wcc-btn-danger:hover {
    background: #dc2626;
    transform: translateY(-2px);
    color: #fff;
}

.wcc-btn:disabled,
.wcc-btn.disabled {
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
}

/* ============================================================
   ========== استایل‌های محصولات مرتبط ==========
   ============================================================ */

.wcc-related-products {
    margin-top: 40px;
}

.wcc-related-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 2px solid #f1f5f9;
}

.wcc-related-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

@media (max-width: 1024px) {
    .wcc-related-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .wcc-related-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
}

@media (max-width: 480px) {
    .wcc-related-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
}

/* ============================================================
   ========== استایل‌های اعلان ==========
   ============================================================ */

.wcc-notification {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    padding: 16px 28px;
    border-radius: 12px;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    z-index: 99999;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    max-width: 90%;
    text-align: center;
}

.wcc-notification.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.wcc-notification.success {
    background: #22c55e;
}

.wcc-notification.error {
    background: #ef4444;
}

.wcc-notification.info {
    background: #0a66c2;
}

/* ============================================================
   ========== استایل‌های بارگذاری ==========
   ============================================================ */

.wcc-loading {
    opacity: 0.5;
    pointer-events: none;
    transition: opacity 0.3s;
}

.wcc-loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: wccSpin 0.7s linear infinite;
}

@keyframes wccSpin {
    to {
        transform: rotate(360deg);
    }
}

/* ============================================================
   ========== استایل‌های ریسپانسیو کلی ==========
   ============================================================ */

/* تبلت */
@media (max-width: 1024px) {
    .wcc-product-content {
        padding: 12px;
    }

    .wcc-product-title {
        font-size: 13px;
    }

    .wcc-product-price {
        font-size: 15px;
    }
}

/* موبایل */
@media (max-width: 768px) {
    .wcc-product-content {
        padding: 10px;
    }

    .wcc-product-title {
        font-size: 12px;
    }

    .wcc-product-price {
        font-size: 14px;
    }

    .wcc-price-current,
    .wcc-price-sale {
        font-size: 15px;
    }

    .wcc-price-old {
        font-size: 12px;
    }

    .wcc-badge {
        font-size: 10px;
        padding: 3px 10px;
    }

    .wcc-pagination .page-numbers {
        min-width: 34px;
        height: 34px;
        font-size: 12px;
    }
}

/* موبایل کوچک */
@media (max-width: 480px) {
    .wcc-product-content {
        padding: 8px;
    }

    .wcc-product-title {
        font-size: 11px;
    }

    .wcc-product-price {
        font-size: 12px;
    }

    .wcc-price-current,
    .wcc-price-sale {
        font-size: 13px;
    }

    .wcc-price-old {
        font-size: 11px;
    }

    .wcc-product-cat {
        font-size: 10px;
    }

    .wcc-badge {
        font-size: 9px;
        padding: 2px 8px;
        top: 6px;
        right: 6px;
    }

    .wcc-pagination .page-numbers {
        min-width: 30px;
        height: 30px;
        font-size: 11px;
        padding: 0 8px;
    }
}

/* ============================================================
   ========== افکت‌های عمومی ==========
   ============================================================ */

.wcc-fade-in {
    animation: wccFadeIn 0.45s ease backwards;
}

@keyframes wccFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.wcc-scale-in {
    animation: wccScaleIn 0.4s ease backwards;
}

@keyframes wccScaleIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ============================================================
   ========== اسکرول‌بار سفارشی ==========
   ============================================================ */

.wcc-scrollbar::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

.wcc-scrollbar::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 3px;
}

.wcc-scrollbar::-webkit-scrollbar-thumb {
    background: #0a66c2;
    border-radius: 3px;
}

.wcc-scrollbar::-webkit-scrollbar-thumb:hover {
    background: #084a8a;
}

/* ============================================================
   ========== تایپوگرافی ==========
   ============================================================ */

.wcc-text-center {
    text-align: center;
}

.wcc-text-right {
    text-align: right;
}

.wcc-text-left {
    text-align: left;
}

.wcc-text-muted {
    color: #94a3b8;
}

.wcc-text-primary {
    color: #0a66c2;
}

.wcc-text-success {
    color: #22c55e;
}

.wcc-text-danger {
    color: #ef4444;
}

.wcc-text-warning {
    color: #f59e0b;
}

/* ============================================================
   ========== فاصله‌ها ==========
   ============================================================ */

.wcc-mt-1 {
    margin-top: 8px;
}

.wcc-mt-2 {
    margin-top: 16px;
}

.wcc-mt-3 {
    margin-top: 24px;
}

.wcc-mt-4 {
    margin-top: 32px;
}

.wcc-mt-5 {
    margin-top: 48px;
}

.wcc-mb-1 {
    margin-bottom: 8px;
}

.wcc-mb-2 {
    margin-bottom: 16px;
}

.wcc-mb-3 {
    margin-bottom: 24px;
}

.wcc-mb-4 {
    margin-bottom: 32px;
}

.wcc-mb-5 {
    margin-bottom: 48px;
}

.wcc-p-1 {
    padding: 8px;
}

.wcc-p-2 {
    padding: 16px;
}

.wcc-p-3 {
    padding: 24px;
}

.wcc-p-4 {
    padding: 32px;
}

.wcc-p-5 {
    padding: 48px;
}