/* =====================================================
   CART LAYOUT
===================================================== */

/* =====================================================
   CART MODAL
===================================================== */
#cartModal{
    position:fixed;
    top:0;
    right:0;
    width:360px;
    height:100%;
    background:#fff;
    transform:translateX(100%);
    transition:0.3s ease;
    z-index:999;
    overflow-y:auto;
}

#cartModal.active{
    transform:translateX(0);
}
/* =========================
   CART HEADER
========================= */

.cart-header{
    display:flex;
    align-items:center;
    justify-content:space-between;
    padding:14px;
    border-bottom:1px solid #eee;
}

.cart-header h2{
    flex:1;
    text-align:center;
    margin:0;
    font-size:24px;
    font-weight:700;
}

.cart-header button{
    width:32px;
    height:32px;
    border:none;
    border-radius:50%;
    background:#f3f3f3;
    cursor:pointer;
}
/* =====================================================
   CART ROW
===================================================== */
.cart-row{
    display:grid;
    grid-template-columns:30px 90px 1fr 110px;
    align-items:center;
    gap:10px;
    padding:12px 10px;
    border-bottom:1px solid #eee;
}
/* =====================================================
   BUY ROW
===================================================== */
.buy-row{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:10px;
    padding:12px 10px;
    border-bottom:1px solid #eee;
}
/* =====================================================
   CHECKBOX
===================================================== */
.cart-left,
.buy-left{
    width:40px;
    display:flex;
    justify-content:center;
    flex-shrink:0;
}

.cart-left input,
.buy-left input{
    width:18px;
    height:18px;
    cursor:pointer;
}
/* =====================================================
   MIDDLE
===================================================== */
.cart-middle{
    display:flex;
    flex-direction:column;
    align-items:flex-start;
    justify-content:center;
    text-align:left;
    font-size:14px;
}

.buy-middle{
    flex:1;
    text-align:center;
}
/* =====================================================
   PRODUCT INFO
===================================================== */
.cart-info{
    display:flex;
    flex-direction:column;
}

.cart-name{
    font-weight:700;
}

.cart-capacity{
    font-size:13px;
    color:#666;
}
/* =====================================================
   CART IMAGE
===================================================== */
.cart-row img{
    width:90px;
    height:90px;
    object-fit:contain;
}
/* =====================================================
   QUANTITY
===================================================== */
.cart-right,
.buy-qty{
    display:flex;
    align-items:center;
    justify-content:flex-end;
    gap:6px;
    flex-shrink:0;
    white-space:nowrap;
}

.cart-right button,
.buy-qty button{
    width:30px;
    height:30px;
    border:none;
    border-radius:6px;
    background:#1565c0;
    color:#fff;
    cursor:pointer;
}

.cart-right input,
.buy-qty input{
    width:42px;
    height:30px;
    text-align:center;
    border:1px solid #ddd;
    border-radius:6px;
}
/* =========================
   BUY BUTTON
========================= */

.cart-bottom{
    padding:14px;
}

.buy-now-btn{
    width:180px;
    height:46px;

    margin:0 auto;
    display:block;

    border:none;
    border-radius:8px;

    background:#e53935;
    color:#fff;

    font-size:15px;
    font-weight:700;

    cursor:pointer;
}
/* =========================
   CART TITLE
========================= */

.cart-name{
    font-size:16px;
    font-weight:700;
    line-height:1.4;
}

.cart-capacity{
    margin-top:4px;
    color:#666;
    font-size:13px;
}
/* =========================
   CART BUY NOW FIX
========================= */

.buy-now-btn{
    width:180px !important;
    height:46px !important;

    display:block !important;

    margin:15px auto !important;

    background:#e53935 !important;
    color:#fff !important;

    border:none !important;
    border-radius:8px !important;

    font-size:15px !important;
    font-weight:700 !important;

    cursor:pointer;
}

.buy-now-btn:hover{
    background:#c62828 !important;
}
/* =========================
   POPUP 
========================= */

.popup-overlay{
    position:fixed;
    inset:0;
    background:rgba(0,0,0,0.45);
    display:flex;
    align-items:center;
    justify-content:center;
    z-index:9999;
}
.popup-overlay{

    position:fixed !important;

    top:0;
    left:0;

    width:100vw;
    height:100vh;

    background:rgba(0,0,0,.45);

    display:flex;
    align-items:center;
    justify-content:center;

    z-index:99999;
}
/* =====================================================
   POPUP BOX
===================================================== */
.popup-box{

    width:90%;
    max-width:700px;

    max-height:85vh;

    overflow-y:auto;

    background:#fff;

    border-radius:16px;

    padding:20px;

    position:relative;

    box-shadow:
    0 10px 30px rgba(0,0,0,.2);
}

.popup-box > span{

    position:absolute;

    top:10px;
    right:15px;

    font-size:24px;

    cursor:pointer;
}

/* =====================================================
   POPUP IMAGE
===================================================== */
#buyProductImg,
#popupCartImg{
    width:60px;
    height:60px;
    object-fit:contain;
    display:block;
    margin:10px auto;
}
/* =====================================================
   POPUP CONTENT
===================================================== */
#popupCartImg,
#buyProductImg{

    width:80px;
    height:80px;

    object-fit:contain;

    display:block;

    margin:10px auto;
}

#popupCartName,
#buyProductName{

    text-align:center;

    margin-bottom:15px;
}


/* =====================================================
   CART ITEM
===================================================== */

.cart-footer{
    padding:15px;
    display:flex;
    justify-content:center;
    border-top:1px solid #eee;
}

.cart-footer button{
    width:180px;
    height:46px;

    border:none;
    border-radius:8px;

    background:#e53935;
    color:#fff;

    font-size:15px;
    font-weight:700;

    cursor:pointer;
}

.cart-footer button:hover{
    background:#c62828;
}



/* =====================================================
   CUSTOMER FORM
===================================================== */
.customer-grid{
    display:grid;
    grid-template-columns:1fr 1fr 1fr;
    gap:10px;
    margin-bottom:20px;
}

.customer-grid input,
.customer-grid textarea{
    width:100%;
    box-sizing:border-box;
    padding:10px;
    border:1px solid #ddd;
    border-radius:8px;
}

#customerInvoice,
#customerAddress{
    height:70px;
    resize:none;
}


/* =====================================================
   FORM VALIDATION
===================================================== */
.input-error{

    border:2px solid #e53935 !important;

    background:#fff5f5 !important;
}

/* =====================================================
   REQUEST TYPE
===================================================== */
.request-type{
    display:flex;
    justify-content:center;
    gap:25px;
    margin:15px 0 20px;
    flex-wrap:wrap;
}

.request-type label{
    display:flex;
    align-items:center;
    gap:8px;
    cursor:pointer;
    font-weight:600;
    color:#0b3f91;
    white-space:nowrap;
}

.request-type span{
    white-space:nowrap;
}

.request-type input[type="radio"]{
    transform:scale(1.15);
}


