/* ==============================================
   CART PAGE - OPTIMIZED CSS
   Professional, fast, clean design
   ============================================== */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

/* Hide Astra header */
header.entry-header.ast-no-thumbnail{display:none}

/* Reset entry content width */
.entry-content[data-ast-blocks-layout]>*{max-width:100%;margin-left:auto;margin-right:auto}

/* Cart totals width */
.woocommerce .cart-collaterals .cart_totals,
.woocommerce-page .cart-collaterals .cart_totals{width:100%!important}

/* Hide variation swatches */
.woo-variation-swatches .wvs-archive-variations-wrapper{display:none}

/* Base resets */
.custom-cart-page *{margin:0;padding:0;box-sizing:border-box}

/* Main container */
.custom-cart-page{
    font-family:'Poppins',sans-serif;
    color:#1a1a1a;
    padding:40px 20px 80px;
    background:#f0f2f1;
    min-height:100vh
}

.ast-on-card-button.ast-onsale-card {
    opacity: 1;
    visibility: hidden;
}

.custom-cart-page .review-rating {
    
    display: none;
}

.custom-cart-page .cart-subtotal {
    display: contents !important;
}

/* Page header */
.custom-cart-page .page-header{
    max-width:1400px;
    margin:0 auto 40px
}

.custom-cart-page .page-header h1{
    font-size:2.5rem;
    font-weight:700;
    color:#3a4d42;
    margin-bottom:8px;
    letter-spacing:-0.5px
}

.custom-cart-page .page-header p{
    color:#5a6c62;
    font-size:1rem;
    font-weight:400
}

/* Progress container */
.custom-cart-page .progress-container{
    max-width:1400px;
    margin:0 auto 40px;
    background:white;
    padding:24px 32px;
    border-radius:12px;
    box-shadow:0 2px 8px rgba(0,0,0,0.04)
}

.custom-cart-page .progress-steps{
    display:flex;
    justify-content:space-between;
    align-items:center;
    position:relative;
    max-width:600px;
    margin:0 auto
}

.custom-cart-page .progress-steps::before{
    content:'';
    position:absolute;
    top:20px;
    left:60px;
    right:60px;
    height:3px;
    background:#e5ebe8;
    z-index:0
}

.custom-cart-page .progress-step{
    display:flex;
    flex-direction:column;
    align-items:center;
    gap:12px;
    position:relative;
    z-index:1
}

.custom-cart-page .progress-step .step-icon{
    width:44px;
    height:44px;
    border-radius:50%;
    background:white;
    border:3px solid #e5ebe8;
    display:flex;
    align-items:center;
    justify-content:center;
    font-size:1.2rem;
    color:#9ba8a0;
    transition:all 0.3s ease
}

.custom-cart-page .progress-step.active .step-icon{
    background:#3a4d42;
    border-color:#3a4d42;
    color:white
}

.custom-cart-page .progress-step span{
    font-size:0.85rem;
    font-weight:600;
    color:#7a8a80
}

.custom-cart-page .progress-step.active span{
    color:#3a4d42
}

/* Cart wrapper */
.custom-cart-page .cart-wrapper{
    max-width:1400px;
    margin:0 auto;
    display:grid;
    grid-template-columns:1fr 400px;
    gap:30px;
    align-items:start
}

.custom-cart-page .cart-main{
    background:white;
    border-radius:16px;
    box-shadow:0 2px 12px rgba(0,0,0,0.06);
    overflow:hidden
}

/* Shop table */
.custom-cart-page .woocommerce-cart-form{width:100%}

.custom-cart-page .shop_table{
    width:100%;
    border-collapse:collapse;
    background:white;
    border-radius:16px;
    overflow:hidden
}

.custom-cart-page .shop_table thead{
    background:linear-gradient(135deg,#3a4d42 0%,#4a5f52 100%)
}

.custom-cart-page .shop_table thead th{
    padding:20px 16px;
    font-size:0.8rem;
    font-weight:600;
    text-transform:uppercase;
    letter-spacing:0.5px;
    color:white;
    text-align:left;
    border:none
}

.custom-cart-page .shop_table tbody tr{
    border-bottom:1px solid #f0f4f2;
    transition:background 0.2s ease
}

.custom-cart-page .shop_table tbody tr:hover{
    background:#f9fbfa
}

.custom-cart-page .shop_table tbody tr:last-child{
    border-bottom:none
}

.custom-cart-page .shop_table tbody td{
    padding:28px 16px;
    vertical-align:middle;
    border:none;
    max-width:60px
}

/* Product remove */
.custom-cart-page .shop_table .product-remove{
    text-align:center
}

.custom-cart-page .shop_table .product-remove a{
    width:36px;
    height:36px;
    border-radius:8px;
    background:#f8f9f8;
    color:#9ba8a0;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    text-decoration:none;
    font-size:1.3rem;
    transition:all 0.2s ease;
    border:1px solid #e8ede9
}

.custom-cart-page .shop_table .product-remove a:hover{
    background:#fee;
    color:#dc3545;
    border-color:#fcc
}

/* Product thumbnail */
.custom-cart-page .shop_table .product-thumbnail img{
    width:100px;
    height:100px;
    object-fit:cover;
    border-radius:12px;
    border:1px solid #e8ede9
}

/* Product name */
.custom-cart-page .shop_table .product-name{
    font-size:1.05rem;
    font-weight:600
}

.custom-cart-page .shop_table .product-name a{
    color:#3a4d42;
    text-decoration:none;
    transition:color 0.2s ease
}

.custom-cart-page .shop_table .product-name a:hover{
    color:#5a7565
}

.custom-cart-page .shop_table .product-name dl.variation{
    margin-top:8px;
    font-size:0.85rem;
    color:#6a7a70;
    display:grid;
    grid-template-columns:repeat(2,1fr)
}

.custom-cart-page .shop_table .product-name dl.variation dt,
.custom-cart-page .shop_table .product-name dl.variation dd{
    margin:4px 0
}

/* Product price */
.custom-cart-page .shop_table .product-price{
    font-size:1.1rem;
    font-weight:600
}

/* Product quantity */
.custom-cart-page .shop_table .product-quantity .quantity input{
    width:70px;
    height:42px;
    border:2px solid #e8ede9;
    border-radius:8px;
    text-align:center;
    font-size:1rem;
    font-weight:600;
    color:#1a1a1a;
    background:white;
    transition:border-color 0.2s ease
}

.custom-cart-page .shop_table .product-quantity .quantity input:focus{
    outline:none;
    border-color:#3a4d42
}

/* Product subtotal */
.custom-cart-page .shop_table .product-subtotal{
    font-size:1.2rem;
    font-weight:700;
    text-align:right
}

/* Actions */
.custom-cart-page .actions{
    padding:24px 32px;
    background:#f9fbfa;
    border-top:1px solid #e8ede9;
    display:flex;
    justify-content:space-between;
    align-items:center;
    flex-wrap:wrap;
    gap:16px
}

.custom-cart-page .coupon{
    display:flex;
    gap:12px;
    flex:1;
    max-width:500px
}

.custom-cart-page .coupon input[type="text"]{
    flex:1;
    padding:14px 18px;
    border:2px solid #e8ede9;
    border-radius:10px;
    font-size:0.95rem;
    font-weight:500;
    color:#1a1a1a;
    background:white;
    transition:all 0.2s ease
}

.custom-cart-page .coupon input[type="text"]:focus{
    outline:none;
    border-color:#3a4d42
}

.custom-cart-page .coupon button{
    padding:14px 28px;
    background:#3a4d42;
    color:white;
    border:none;
    border-radius:10px;
    font-size:0.9rem;
    font-weight:600;
    cursor:pointer;
    transition:all 0.2s ease;
    white-space:nowrap
}

.custom-cart-page .coupon button:hover{
    background:#2d3d35;
    transform:translateY(-1px)
}

.custom-cart-page button[name="update_cart"]{
    padding:14px 28px;
    background:#5a6c62;
    color:white;
    border:none;
    border-radius:10px;
    font-size:0.9rem;
    font-weight:600;
    cursor:pointer;
    transition:all 0.2s ease
}

.custom-cart-page button[name="update_cart"]:hover{
    background:#4a5c52
}

.custom-cart-page button[name="update_cart"]:disabled{
    opacity:0.5;
    cursor:not-allowed
}

/* Cart sidebar */
.custom-cart-page .cart-sidebar{
    position:sticky;
    top:20px
}

.custom-cart-page .cart-collaterals{
    width:100%
}

.custom-cart-page .cart_totals{
    background:white;
    border-radius:16px;
    box-shadow:0 2px 12px rgba(0,0,0,0.06);
    overflow:hidden
}

.custom-cart-page .cart_totals>h2{
    background:linear-gradient(135deg,#3a4d42 0%,#4a5f52 100%);
    padding:24px 28px;
    font-size:1.4rem;
    font-weight:700;
    color:white;
    margin:0
}

.custom-cart-page .cart_totals table{
    width:100%;
    border-collapse:collapse
}

.custom-cart-page .cart_totals .shop_table{
    background:transparent;
    box-shadow:none
}

.custom-cart-page .cart_totals .shop_table tr{
    border-bottom:1px solid #f0f4f2
}

.custom-cart-page .cart_totals .shop_table tr:last-child{
    border-bottom:none
}

.custom-cart-page .cart_totals .shop_table th,
.custom-cart-page .cart_totals .shop_table td{
    padding:16px 28px;
    background:transparent;
    border:none
}

.custom-cart-page .cart_totals .shop_table th{
    font-size:0.95rem;
    font-weight:500;
    color:#5a6c62;
    text-align:left;
    text-transform:none
}

.custom-cart-page .cart_totals .shop_table td{
    font-size:1rem;
    font-weight:600;
    color:#1a1a1a;
    text-align:right
}

.custom-cart-page .cart_totals .order-total th{
    font-size:1.1rem;
    font-weight:700;
    color:#1a1a1a;
    padding-top:20px;
    border-top:2px solid #e8ede9
}

.custom-cart-page .cart_totals .order-total td{
    font-size:1.3rem!important;
    font-weight:800;
    color:#3a4d42;
    padding-top:20px;
    border-top:2px solid #e8ede9
}

/* Checkout button */
.custom-cart-page .wc-proceed-to-checkout{
    padding:0 28px 28px
}

.custom-cart-page .wc-proceed-to-checkout a.checkout-button{
    width:100%;
    padding:18px;
    background:#3a4d42;
    color:white;
    border:none;
    border-radius:12px;
    font-size:1rem;
    font-weight:700;
    text-transform:uppercase;
    letter-spacing:0.5px;
    cursor:pointer;
    text-decoration:none;
    display:block;
    text-align:center;
    transition:all 0.3s ease
}

.custom-cart-page .wc-proceed-to-checkout a.checkout-button:hover{
    background:#2d3d35;
    transform:translateY(-2px);
    box-shadow:0 8px 20px rgba(58,77,66,0.4)
}

.custom-cart-page .secure-checkout{
    display:flex;
    align-items:center;
    justify-content:center;
    gap:8px;
    margin-top:16px;
    padding:0 28px 28px;
    color:#6a7a70;
    font-size:0.85rem
}

.custom-cart-page .secure-checkout i{
    color:#3a4d42
}

/* Empty cart */
.custom-cart-page .cart-empty{
    max-width:600px;
    margin:60px auto;
    background:white;
    border-radius:16px;
    padding:80px 40px;
    text-align:center;
    box-shadow:0 2px 12px rgba(0,0,0,0.06)
}

.custom-cart-page .cart-empty::before{
    content:'\f07a';
    font-family:'Font Awesome 5 Free';
    font-weight:900;
    font-size:5rem;
    color:#3a4d42;
    opacity:0.3;
    display:block;
    margin-bottom:24px
}

.custom-cart-page .cart-empty .return-to-shop{
    margin-top:32px
}

.custom-cart-page .cart-empty .return-to-shop a{
    padding:16px 40px;
    background:#3a4d42;
    color:white;
    border:none;
    border-radius:12px;
    font-size:1rem;
    font-weight:600;
    text-decoration:none;
    display:inline-block;
    transition:all 0.2s ease
}

.custom-cart-page .cart-empty .return-to-shop a:hover{
    background:#2d3d35;
    transform:translateY(-2px)
}

/* Misc */
.ast-onsale-card{
    color:#fff;
    background-color:#4caf50;
    padding:0.4em 0.8em!important
}

article#post-20 p{
    margin:0!important
}

article#post-20 dl.variation{
    display:grid;
    grid-template-columns:repeat(2,1fr)
}

/* Cross-sells */
.custom-cart-page .cross-sells{
    max-width:1400px;
    margin:50px auto 0;
    background:white;
    border-radius:16px;
    padding:50px 40px;
    box-shadow:0 2px 12px rgba(0,0,0,0.06)
}

.custom-cart-page .cross-sells h2{
    font-size:2rem;
    font-weight:700;
    color:#3a4d42;
    margin-bottom:12px;
    text-align:center
}

.custom-cart-page .cross-sells>p{
    text-align:center;
    color:#5a6c62;
    font-size:1rem;
    margin-bottom:40px
}

.custom-cart-page .cross-sells ul.products{
    display:grid;
    grid-template-columns:repeat(auto-fill,minmax(280px,1fr));
    gap:28px;
    list-style:none;
    padding:0;
    margin:0
}

.custom-cart-page .cross-sells ul.products li.product{
    background:#f8f9f8;
    border-radius:14px;
    padding:20px;
    transition:all 0.3s ease;
    border:2px solid transparent;
    text-align:center
}

.custom-cart-page .cross-sells ul.products li.product:hover{
    border-color:#3a4d42;
    transform:translateY(-6px);
    box-shadow:0 8px 24px rgba(58,77,66,0.15)
}

.custom-cart-page .cross-sells ul.products li.product img{
    width:100%;
    height:220px;
    object-fit:cover;
    border-radius:10px;
    margin-bottom:18px;
    border:1px solid #e8ede9
}

.custom-cart-page .cross-sells ul.products li.product h3,
.custom-cart-page .cross-sells ul.products li.product h2{
    font-size:1.05rem;
    font-weight:600;
    color:#1a1a1a;
    margin-bottom:10px;
    min-height:48px;
    display:flex;
    align-items:center;
    justify-content:center
}

.custom-cart-page .cross-sells ul.products li.product .price{
    font-size:1.3rem;
    font-weight:700;
    color:#3a4d42;
    margin-bottom:16px
}

.custom-cart-page .cross-sells ul.products li.product .button{
    width:100%;
    padding:12px 24px;
    background:#3a4d42;
    color:white;
    border:none;
    border-radius:10px;
    font-size:0.9rem;
    font-weight:600;
    cursor:pointer;
    transition:all 0.2s ease;
    text-decoration:none;
    display:inline-block
}

.custom-cart-page .cross-sells ul.products li.product .button:hover{
    background:#2d3d35;
    transform:translateY(-2px)
}

.woocommerce-js ul.products li.product .price,
.woocommerce-page ul.products li.product .price{
    font-size:12px
}

/* Responsive */
@media (max-width:1200px){
    .custom-cart-page .cart-wrapper{
        grid-template-columns:1fr
    }
    .custom-cart-page .cart-sidebar{
        position:static;
        max-width:500px;
        margin:0 auto
    }
}

@media (max-width:968px){
    .custom-cart-page .shop_table thead{
        display:none
    }
    .custom-cart-page .shop_table tbody tr{
        display:block;
        padding:24px 20px;
        position:relative
    }
    .custom-cart-page .shop_table tbody td{
        display:block;
        padding:8px 0;
        text-align:left!important
    }
    .custom-cart-page .shop_table .product-remove{
        position:absolute;
        top:24px;
        right:20px
    }
    .custom-cart-page .shop_table .product-thumbnail{
        display:inline-block;
        margin-right:16px;
        vertical-align:top
    }
    .custom-cart-page .shop_table .product-name{
        display:inline-block;
        vertical-align:top;
        width:calc(100% - 120px)
    }
    .custom-cart-page .shop_table .product-price::before{
        content:'Price: ';
        color:#8a9790;
        font-weight:500
    }
    .custom-cart-page .shop_table .product-quantity::before{
        content:'Quantity: ';
        color:#8a9790;
        font-weight:500;
        margin-right:12px
    }
    .custom-cart-page .shop_table .product-subtotal{
        padding-top:12px;
        border-top:1px solid #f0f4f2;
        font-size:1.3rem
    }
    .custom-cart-page .shop_table .product-subtotal::before{
        content:'Subtotal: ';
        color:#8a9790;
        font-weight:500;
        margin-right:8px
    }
    .custom-cart-page .actions{
        flex-direction:column;
        align-items:stretch
    }
    .custom-cart-page .coupon{
        max-width:100%
    }
}

@media (max-width:640px){
    .woocommerce-cart table.cart td.actions .coupon{
        display:flex;
        flex-direction:row
    }
    .custom-cart-page .shop_table .product-name{
        width:100%;
        text-align:left!important
    }
    .custom-cart-page{
        padding:20px 12px 60px
    }
    .custom-cart-page .shop_table tbody td{
        max-width:100%!important
    }
    .custom-cart-page .page-header h1{
        font-size:1.8rem
    }
    .custom-cart-page .progress-container{
        padding:20px 16px
    }
    .custom-cart-page .progress-step span{
        font-size:0.75rem
    }
    .custom-cart-page .progress-step .step-icon{
        width:38px;
        height:38px;
        font-size:1rem
    }
    .custom-cart-page .progress-steps::before{
        top:18px;
        left:50px;
        right:50px
    }
    .custom-cart-page .shop_table tbody tr{
        padding:20px 16px
    }
    .custom-cart-page .shop_table .product-thumbnail img{
        width:80px;
        height:80px
    }
    .custom-cart-page .actions{
        padding:20px 16px
    }
    .custom-cart-page .coupon{
        flex-direction:column
    }
    .custom-cart-page .cart_totals>h2,
    .custom-cart-page .cart_totals .shop_table th,
    .custom-cart-page .cart_totals .shop_table td{
        padding-left:20px;
        padding-right:20px
    }
    .custom-cart-page .wc-proceed-to-checkout{
        padding:0 20px 20px
    }
    .custom-cart-page .secure-checkout{
        padding:0 20px 20px
    }
    .custom-cart-page .cart-empty{
        padding:60px 24px
    }
    .custom-cart-page .cross-sells{
        padding:35px 10px
    }
    .custom-cart-page .cart-sidebar{
        position:static;
        max-width:100%;
        margin:0 auto;
        width:100%
    }
}

@media (max-width:400px){
    a.button.view_product_button{
        font-size:9px!important;
        padding:6px 8px!important
    }
}