/* ==============================
   CART VIEW PROFESSIONAL
============================== */
#cartView {
  padding: 0px;
  box-sizing: border-box;
}

.cartItem {
  display: flex;
  flex-direction: column; /* 🔥 main change */
  position: relative;
  gap: 8px;
  padding: 12px;
  border-bottom: 1px solid #eee;
  background: #fff;
  border-radius: 12px;
  margin-bottom: 10px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}
.cartTop {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.cartImg {
  width: 70px;       /* consistent size */
  height: 70px;      /* professional card height */
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid #eee;
  flex-shrink: 0;    /* prevent image shrink */
  cursor: default;   /* disable zoom */
  transition: none;  /* disable hover zoom */
}

.cartInfo {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.cartName {
  font-size: 15px;
  font-weight: 600;
  color: #333;
  line-height: 1.4;
  flex: 1; 
  display: -webkit-box;
  -webkit-line-clamp: 2;  
  -webkit-box-orient: vertical;

  overflow: hidden;     
  word-break: break-word; 
}

.cartQty {
  display: flex;
  align-items: center;
  gap: 8px;
}

.cartQty button {
  width: 25px;
  height: 25px;
  border: none;
  border-radius: 2px;
  background: #EC3C28;
  font-size: 18px;
  cursor: pointer;
}

.cartQty span {
  font-weight: 600;
  min-width: 20px;
  text-align: center;
}

.cartDelete {
  position: absolute;
  top: 0px;
  right: 12px;
  z-index: 10;
  cursor: pointer;

  display: inline-flex; /* inline-block سے بہتر */
  justify-content: center;
  align-items: center;

  width: 22px;   /* fix hitbox */
  height: 22px;  /* fix hitbox */
  pointer-events: auto; /* ensure only this triggers */
  background: none;
  border: none;
}



/* Cart total styling */
.cartTotal, #cartTotalBox {
  font-size: 20px;
  font-weight: 800;
  text-align: center;
  margin-top: 15px;
  color: #333;
}

/* Cart scrollable items with side gap on mobile */
#cartItems {
  overflow-y: auto;
  padding: 10px 12px 140px 12px;
  height: 100%;
  max-width: 480px;       /* limit width on mobile */
  margin: auto;           /* center cart */
}

/* Fixed cart footer */
#cartFooter {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 55px; 
  background: #fff;
  padding: 15px;
  box-shadow: 0 -3px 12px rgba(0,0,0,0.08);
  z-index: 9998;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.cartBottom {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 8px;

  width: 100%;        /* 🔥 IMPORTANT */
  padding-right: 40px; /* delete ke liye space */
}

/* Cart scrollable items */
#cartItems {
  overflow-y: auto;
  padding: 10px 12px 140px 12px;
  height: 100%;
}



.btnOrder {
  width: 100%;
  padding: 12px 0;
  font-size: 17px;
  font-weight: 700;
  border-radius: 12px;
  border: none;
  font-weight: 600;
  cursor: pointer;
  background: #25D366;
  color: white;
}

.btnOrder:hover {
  background: #1da851;
}
#cartFooter .btnOrder {
    width: 90%;          /* تھوڑی کم چوڑائی */
    padding: 12px 0;     /* تھوڑی کم height */
    font-size: 16px;
    margin: auto;
    display: block;
}

/* =======================================================
   PRODUCT CARD
======================================================= */
.cartIconWrap {
  position: relative; /* badge relative to icon */
  display: inline-block;
}

#cartBadge {
  position: absolute;
  top: -8px;       /* 🔹 تھوڑا اوپر icon */
  right: -10px;    /* 🔹 تھوڑا right side پر */
  background-color: #ff0000; /* 🔹 red background */
  color: #fff;               /* 🔹 white text */
  font-size: 12px;           /* 🔹 adjust if needed */
  font-weight: 700;
  width: 18px;               /* 🔹 square badge */
  height: 18px;              /* 🔹 square badge */
  border-radius: 50%;        /* 🔹 circle */
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2); /* optional shadow for visibility */
}
.productCard:hover {
  transform: translateY(-4px);

  box-shadow:
  0 10px 22px rgba(0,0,0,0.12),
  0 4px 10px rgba(0,0,0,0.08);
}

/* Product Image */
.productCard img.mainImg{
  width:100%;
  height:190px;
  object-fit:cover;
  border-radius:10px;
}

/* PRODUCT CARD */
.productCard {

  border-radius: 6px;

  margin-left: 2px;
  margin-right: 2px;

  display: flex;
  flex-direction: column;

  background: #ffffff;

  

  overflow: hidden;

  padding: 14px;

  border-bottom: 1px solid #e6e6e6;

  box-shadow: none;

  transition: all 0.25s ease;
}

#cartRewardBox{

    background:
    linear-gradient(
        135deg,
        #fff3cd,
        #ffe8a3
    );

    border-radius:14px;

    padding:12px;

    display:flex;
    align-items:center;
    justify-content:space-between;

    margin-bottom:10px;
}

.rewardVoucherLeft{

    font-weight:700;
    color:#8a6500;
}

.rewardVoucherRight{

    font-size:14px;
    font-weight:800;

    color:#ff5722;

    cursor:pointer;
}
