



/* =========================================================
SG FINAL CART BUTTON
DESKTOP = ICON ONLY
MOBILE + TABLET = ICON + TEXT
========================================================= */

/* =========================================================
DESKTOP
فقط آیکون
========================================================= */

.sg-cart-btn{
width:50px !important;
height:50px !important;

display:flex !important;

align-items:center !important;
justify-content:center !important;

flex-direction:row !important;

gap:0 !important;

padding:0 !important;
margin:0 !important;

font-size:0 !important;

line-height:1 !important;

overflow:hidden !important;

box-sizing:border-box !important;

}

/* متن در دسکتاپ کاملاً مخفی */

.sg-cart-btn .sg-cart-text{

```
display:none !important;
```

}

/* آیکون SVG در دسکتاپ */

.sg-cart-btn svg{

```
display:block !important;

width:20px !important;
height:20px !important;

min-width:20px !important;
max-width:20px !important;

margin:0 !important;
padding:0 !important;

flex:0 0 20px !important;

color:#fff !important;

fill:currentColor !important;
```

}

/* =========================================================
MOBILE + TABLET
آیکون + متن
========================================================= */

@media screen and (max-width:1100px){
.sg-product-card .sg-cart-btn{

    width:100% !important;

    height:44px !important;

    min-width:0 !important;

    display:flex !important;

    align-items:center !important;
    justify-content:center !important;

    flex-direction:row !important;

    gap:7px !important;

    padding:0 10px !important;

    margin:0 !important;

    font-size:12px !important;

    line-height:1 !important;

    white-space:nowrap !important;

    overflow:visible !important;

    box-sizing:border-box !important;

}


/* =========================
   متن افزودن به سبد خرید
========================= */

.sg-product-card .sg-cart-btn .sg-cart-text{

    display:inline-flex !important;

    align-items:center !important;
    justify-content:center !important;

    visibility:visible !important;

    opacity:1 !important;

    width:auto !important;
    height:auto !important;

    min-width:0 !important;
    max-width:none !important;

    overflow:visible !important;

    position:static !important;

    clip:auto !important;
    clip-path:none !important;

    text-indent:0 !important;

    font-size:12px !important;

    line-height:1 !important;

    font-weight:600 !important;

    color:#fff !important;

    white-space:nowrap !important;

    margin:0 !important;
    padding:0 !important;

    flex:0 0 auto !important;

}


/* =========================
   آیکون SVG
========================= */

.sg-product-card .sg-cart-btn svg{

    display:block !important;

    visibility:visible !important;

    opacity:1 !important;

    width:17px !important;
    height:17px !important;

    min-width:17px !important;
    max-width:17px !important;

    min-height:17px !important;
    max-height:17px !important;

    flex:0 0 17px !important;

    margin:0 !important;
    padding:0 !important;

    color:#fff !important;

    fill:currentColor !important;

}

}

/* =========================================================
MOBILE
========================================================= */

@media screen and (max-width:768px){
.sg-product-card .sg-cart-btn{

    height:40px !important;

    gap:6px !important;

    padding:0 8px !important;

}


.sg-product-card .sg-cart-btn .sg-cart-text{

    font-size:11px !important;

    line-height:1 !important;

    font-weight:600 !important;

}


.sg-product-card .sg-cart-btn svg{

    width:15px !important;
    height:15px !important;

    min-width:15px !important;
    max-width:15px !important;

    min-height:15px !important;
    max-height:15px !important;

    flex-basis:15px !important;

}
}









/*==================================================
        SG PRODUCT CARD RESPONSIVE
==================================================*/

/************** TABLET **************/
@media (min-width:769px) and (max-width:1100px){

    .woocommerce .products{
        grid-template-columns:repeat(3,1fr)!important;
        gap:18px!important;
    }

    .sg-product-card{
        min-height:420px;
    }

    .sg-product-image{
        margin:14px;
        padding:14px;
    }

    .sg-product-image img{
        height:130px;
    }

    .sg-product-content{
        padding:6px 14px 0;
    }

    .sg-product-title{

        font-size:18px!important;
        line-height:1.7!important;

        display:-webkit-box;
        -webkit-line-clamp:2;
        -webkit-box-orient:vertical;

        overflow:hidden;

        min-height:48px;
    }

    /* قیمت بالا */
    .sg-product-footer{

        margin-top:auto;

        display:flex;
        flex-direction:column;
        align-items:stretch;

        gap:10px;

        padding:14px;

    }

   .sg-product-price{

    width:100%;

    justify-content:center;

    text-align:center;

    padding:10px 12px;

    font-size:15px;

}

    .sg-product-price bdi{

        font-size:16px;

    }

    .sg-product-price .woocommerce-Price-currencySymbol{

        font-size:12px;

        position:relative;

        top:-4px;

    }

    /* دکمه پایین */
    .sg-cart-btn{

        width:100%;

        height:44px;

        border-radius:12px;

        font-size:0;

    }

    .sg-cart-btn i{

        font-size:19px;

    }

}



/************** MOBILE **************/
@media (max-width:768px){

    .woocommerce .products{

        grid-template-columns:repeat(2,1fr)!important;

        gap:10px!important;

    }

    .sg-product-card{

        min-height:330px;

        border-radius:16px;

    }

    .sg-product-image{

        margin:10px;

        padding:10px;

    }

    .sg-product-image img{

        height:120px;

    }

    .sg-product-content{

        padding:5px 10px 0;

    }

    .sg-product-title{

        font-size:14px!important;

        line-height:1.6!important;

        display:-webkit-box;

        -webkit-line-clamp:2;

        -webkit-box-orient:vertical;

        overflow:hidden;

        min-height:38px;

    }

    /* قیمت بالا */

    .sg-product-footer{

        margin-top:auto;

        display:flex;

        flex-direction:column;

        align-items:stretch;

        gap:8px;

        padding:10px;

    }

    .sg-product-price{

        width:100%;

        text-align:center;

        justify-content:flex-end;

        padding:8px 10px;

        font-size:13px;

    }

    .sg-product-price bdi{

        font-size:14px;

    }

    .sg-product-price .woocommerce-Price-currencySymbol{

        font-size:10px;

        position:relative;

        top:-3px;

    }

    /* دکمه پایین */

    .sg-cart-btn{

        width:100%;

        height:40px;

        border-radius:10px;

        font-size:0;

    }

    .sg-cart-btn i{

        font-size:16px;

    }

}



























/* ======================================================
   SG PRODUCT CARD
   Part 1 : Grid + Card Structure
====================================================== */

/* ---------- Product Grid ---------- */

.woocommerce .products{
    display:grid !important;
    grid-template-columns:repeat(4,minmax(0,1fr));
    gap:22px;
    margin:0;
    padding:0;
}

.woocommerce .products .product{

    width:100% !important;
    max-width:100% !important;

    margin:0 !important;
    padding:0 !important;

    float:none !important;
}

/* ---------- Card ---------- */

.sg-product-card{

    position:relative;

    display:flex;
    flex-direction:column;

    width:100%;
    height:100%;

    overflow:hidden;

    border-radius:24px;

    background:
    linear-gradient(
        145deg,
        rgba(30,30,30,.95),
        rgba(10,10,10,.98)
    );

    border:1px solid rgba(255,255,255,.08);

    backdrop-filter:blur(18px);
    -webkit-backdrop-filter:blur(18px);

    box-shadow:

        0 20px 45px rgba(0,0,0,.28),

        inset 0 1px 0 rgba(255,255,255,.05);

    transition:

        transform .35s ease,
        box-shadow .35s ease,
        border-color .35s ease;

}

/* ---------- Hover ---------- */

.sg-product-card:hover{

    transform:translateY(-8px);

    border-color:rgba(223,29,38,.45);

    box-shadow:

        0 30px 60px rgba(0,0,0,.42),

        0 0 0 1px rgba(223,29,38,.18);

}

/* ---------- Link ---------- */

.sg-product-link{

    display:flex;
    flex-direction:column;

    color:inherit;

    text-decoration:none;

    height:100%;
}

/* ======================================================
   PART 2
   Image + Wishlist + Badge + Title
======================================================*/


/*============================
        IMAGE
============================*/

.sg-product-image{

    padding:18px;

    display:flex;
    justify-content:center;
    align-items:center;

    background:#ffffff;

    border-radius:22px;

    margin:18px 18px 10px;

}


.sg-product-image img{

    width:100%;
    height:220px;

    object-fit:contain;

    background:transparent;

    border-radius:0;

    padding:0;

    border:none;

    box-shadow:none;

    transition:.35s;

}


.sg-product-card:hover .sg-product-image img{

    transform:scale(1.05);

}



/*============================
      CONTENT
============================*/

.sg-product-content{

    padding:8px 18px 0;

}



/*============================
      TITLE
============================*/

.sg-product-title{

    margin:0;

    color:#fff;

    font-size:18px;

    font-weight:600;

    line-height:1.9;

    text-align:right;

    min-height:58px;

    display:-webkit-box;

    -webkit-box-orient:vertical;

    -webkit-line-clamp:2;

    overflow:hidden;

    text-overflow:ellipsis;

}





/*============================
      BADGE
============================*/

.sg-badges{

    position:absolute;

    top:16px;

    right:16px;

    z-index:5;

}


.sg-badge{

    display:inline-flex;

    align-items:center;

    justify-content:center;

    height:30px;

    padding:0 12px;

    border-radius:999px;

    background:linear-gradient(
        135deg,
        #df1d26,
        #ff4b55
    );

    color:#fff;

    font-size:14px;

    font-weight:700;

    box-shadow:

        0 8px 20px rgba(223,29,38,.30);

}

/* ======================================================
   PART 3
   Footer + Price + Cart Button
======================================================*/


/*============================
        FOOTER
============================*/

.sg-product-footer{

    margin-top:auto;

    display:flex;
    
    flex-direction:row-reverse;

    align-items:center;

    justify-content:space-between;

    gap:12px;

    padding:18px;

}



/*============================
        PRICE
============================*/

.sg-product-price{

    flex:1;

    background:rgba(255,255,255,.06);

    border:1px solid rgba(255,255,255,.08);

    border-radius:14px;

    padding:10px 14px;

    color:#fff;

        font-size:16px;

    line-height:1.6;

    font-weight:700;

    text-align:left;

    backdrop-filter:blur(12px);

}


.sg-product-price del{

    color:#8f8f8f;

    font-size:15px;

}


.sg-product-price ins{

    color:#ffffff;

    text-decoration:none;

}



/*============================
      CART WRAP
============================*/

.sg-cart-wrap{

    flex-shrink:0;

}



/*============================
      CART BUTTON
============================*/

.sg-cart-btn{

    width:50px;

    height:50px;

    display:flex;

    justify-content:center;

    align-items:center;

    border-radius:14px;

    background:linear-gradient(
        135deg,
        #df1d26,
        #ff4954
    );

    color:#fff !important;

    text-decoration:none;

    box-shadow:
        0 10px 25px rgba(223,29,38,.35);

    transition:.3s;

}


/* حذف متن دکمه */

.sg-cart-btn{

    font-size:0;

}


.sg-cart-btn i{

    font-size:22px;

}



/* Hover */

.sg-cart-btn:hover{

    transform:translateY(-3px);

    box-shadow:
        0 16px 30px rgba(223,29,38,.45);

}



/* حذف استایل ووکامرس */

.sg-cart-btn::after{

    display:none;

}
/* ======================================================
   PART 4
   Final Polish + Responsive
======================================================*/

/* ---------- ارتفاع ثابت کارت ---------- */

.sg-product-card{

    min-height:460px;

}

/* ---------- تصویر ---------- */

.sg-product-image{

    flex-shrink:0;

}

/* ---------- عنوان ---------- */

.sg-product-title{

    height:58px;

}

/* ---------- فوتر ---------- */

.sg-product-footer{

    display:flex;

    flex-direction:row-reverse;

    align-items:center;

    justify-content:space-between;

    gap:14px;

    margin-top:auto;

    flex-wrap:nowrap;

}

/* قیمت همیشه فضای باقیمانده را بگیرد */

.sg-product-price{

    flex:1;

    display:flex;

    align-items:center;

    justify-content:flex-start;

    min-width:0;

    white-space:normal;

    overflow:visible;

    text-overflow:unset;

    word-break:keep-all;

}

/* دکمه همیشه مربع بماند */

.sg-cart-btn{

    width:50px;

    height:50px;

    flex-shrink:0;

}

/* ---------- Hover تصویر ---------- */

.sg-product-card:hover .sg-product-image img{

    transform:scale(1.05);

}

/* ---------- موبایل ---------- */

@media(max-width:768px){

    .woocommerce .products{

        grid-template-columns:repeat(2,1fr);

        gap:12px;

    }

    .sg-product-card{

        min-height:360px;

        border-radius:18px;

    }

    .sg-product-image{

        margin:12px;

        padding:10px;

    }

    .sg-product-image img{

        height:105px;

    }

    .sg-product-content{

        padding:8px 14px 0;

    }

    .sg-product-title{

        font-size:18px;

        line-height:1.8;

        height:46px;

    }

    .sg-product-footer{

        padding:14px;

    }

    .sg-product-price{

        font-size:15px;

        padding:8px 10px;

    }

    .sg-cart-btn{

        width:42px;

        height:42px;

    }

    .sg-cart-btn i{

        font-size:17px;

    }

}

/* ---------- تبلت ---------- */

@media(min-width:769px) and (max-width:1100px){

    .woocommerce .products{

        grid-template-columns:repeat(3,1fr);

    }

}

/* واحد پول */

.sg-product-price .woocommerce-Price-currencySymbol{

    font-size:12px;

    position:relative;

    top:-5px;

    margin-right:4px;

    color:#cfcfcf;

    font-weight:500;

}

/* ===================================
   CART ICON FIX
=================================== */

.sg-cart-btn{

    display:flex !important;

    align-items:center !important;

    justify-content:center !important;

    padding:0 !important;

    margin:0 !important;

    line-height:1 !important;

    text-align:center !important;

}

.sg-cart-btn i{

    display:flex !important;

    align-items:center !important;

    justify-content:center !important;

    width:100%;

    height:100%;

    font-size:20px;

    line-height:1;

    margin:0;

    padding:0;

}



/* =====================================
   YITH Wishlist
===================================== */

.sg-wishlist{

    position:absolute;

    top:14px;

    left:14px;

    z-index:20;

}

.sg-wishlist .yith-wcwl-add-to-wishlist{

    margin:0 !important;

}

.sg-wishlist a{

    width:42px;
    height:42px;

    display:flex;
    align-items:center;
    justify-content:center;

    border-radius:50%;

    background:rgba(255,255,255,.92);

    border:1px solid rgba(0,0,0,.08);

    color:#df1d26 !important;

    box-shadow:
        0 8px 18px rgba(0,0,0,.15);

    transition:.3s;

}

.sg-wishlist a:hover{

    background:#df1d26;

    color:#fff !important;

    transform:scale(1.08);

}

.sg-wishlist i,
.sg-wishlist svg{

    font-size:18px;

    color:inherit !important;

}



