/* Cart container */
#upper-section {
  background-color: var(--accentYellow);
  height: 60px;
  border-radius: 0px 0px 20px 20px;
  display: flex;
  justify-content: center;
  align-items: center;
}

#upper-section p {
  font-size: 15px;
  color: var(--accentGreen);
  font-weight: bold;
}

.back-btn {
  position: absolute;
  top: 14px;
  right: 10px;
}

#cart {
  /* width: 98%; */
  /* background-color: var(--light2); */
  height: auto;
  margin: 0px auto;
  /* display: flex; */
  flex-direction: column;
  justify-content: space-between;
  align-items: center;

  display: none;
}

#empty-cart {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: calc(100% - 50px);
}

#empty-cart img {
  width: 150px;
  height: 150px;
}

#empty-cart #empty-text {
  font-size: 13px;
}

#cart-items {
  /* height: calc(100vh + 300px); */
  /* background-color: #cd8f8f; */
}

.item-cart {
  width: 90%;
  min-width: 320px;
  max-width: 400px;
  /* height: 120px; */
  background-color: var(--light2);
  margin-bottom: 7px;
  border-radius: 8px;
  overflow: hidden;
}

/* Upper section */
.item-cart .upper {
  /* styles for the top portion */
  background-color: var(--light1);
  /* height: 90px; */
  display: flex;
  justify-content: space-between;
}

.item-cart .upper .delete-btn {
  /* styles for the delete button */
  width: 30px;
  /* background-color: var(--light1); */
  display: flex;
  justify-content: center;
  align-items: center;
  border-right: 1px solid var(--light3);
}

.delete-btn .fa-trash-can {
  color: var(--primary);
  font-size: 19px;
}

.item-cart .upper .item-info {
  /* styles for the item info wrapper */
  padding: 3px;
  direction: rtl;
  display: flex;
}

.item-cart .upper .item-info .item-img {
  /* styles for the item image */
  width: 75px;
  height: 75px;
  border-radius: 3px;
  overflow: hidden;
}

.item-cart .upper .item-info .item-img img {
  /* styles for the item image */
  width: 100%;
  height: 100%;
}

.item-cart .upper .item-info .item-name-price {
  /* wrapper for name and price */
  /* height: 90px; */
  width: 150px;
  /* background-color: chocolate; */
  /* margin-right: 9px; */
  font-size: 12px;
  padding: 5px 10px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-right: 1px solid var(--light3);
}

/* Lower section */
.item-cart .lower {
  /* styles for the bottom portion */
  height: 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: var(--light3);
  border-top: 1px solid var(--light1);
}

.item-quantity {
  width: 85px;
  /* background-color: #958f8f; */
  display: flex;
  align-items: center;
  justify-content: center;
  /* gap: 8px; */
}

.item-quantity .qty-btn {
  width: 20px;
  height: 20px;
  border: none;
  border-radius: 50%;
  background-color: var(--primary);
  /* color: var(--light1); */
  /* font-size: 11px; */
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  /* padding: 6px; */
}

.item-quantity .qty-btn i {
  color: var(--light1);
  font-size: 10px;
  pointer-events: none; /* so click is handled by button */
  transition: color 0.2s ease;
}

.item-quantity .qty-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.item-quantity .qty-value {
  min-width: 24px;
  text-align: center;
  font-size: 15px;
  color: var(--dark1);
}

.item-subtotal {
  width: 100px;
  /* background-color: #958f8f; */
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding-right: 12px;
  font-size: 12px;
  direction: rtl;
}

.item-subtotal .currency {
  font-size: 11px;
  margin-right: 2px;
}

#checkout-btn {
  /* display: inline-block; */
  /* width: 100%; */ /* full width on small screens */
  /* max-width: 250px; */ /* optional, keep it balanced */
  padding: 10px 22px;
  /* background: linear-gradient(135deg, var(--primary), var(--primaryDark)); */
  color: var(--light1);
  font-size: 15px;
  /* font-weight: 600; */
  text-align: center;
  border: none;
  border-radius: 14px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.18);
  /* margin-bottom: 5px; */
}

#checkout-btn:hover {
  /* background: linear-gradient(135deg, var(--primaryDark), var(--primary)); */
  /* transform: translateY(-2px); */
  /* box-shadow: 0 8px 18px rgba(0, 0, 0, 0.22); */
}

#checkout-btn:active {
  transform: translateY(0);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

#checkout-btn:disabled {
  background: var(--light3);
  color: var(--dark3);
  cursor: not-allowed;
  box-shadow: none;
}

#cart-items {
  flex: 1;
  overflow-y: auto;
  padding-top: 10px;
  margin-bottom: 60px; /* space for footer */
}

#cart-footer {
  position: fixed;
  bottom: 50px; /* leave room if bottom-menu exists */
  left: 0;
  right: 0;
  background: #fff;
  border-top: 1px solid #ddd;
  /* padding: 0.75rem 1rem; */
  display: flex;
  height: 60px;
  justify-content: space-between;
  align-items: center;
  z-index: 10;
}

#total-text {
  display: flex;
  /* gap: 6px; */
  /* font-weight: bold; */
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 90px;
  height: 49px;
  /* background-color: burlywood; */
  direction: rtl;
}

#total-text .label {
  /* color: #555; */
  height: 20px;
  line-height: 20px;
  font-size: 12px;
}

#total-text .value {
  font-size: 15px;
  color: var(--primary);
  height: 20px;
  line-height: 20px;
}

#total-text .currency {
  font-size: 12px; /* smaller than the number */
  margin-right: 2px;
  color: #555; /* optional, softer look */
}

#checkout-btn {
  background-color: var(--accentGreen);
  color: #fff;
  padding: 7px 15px;
  border: none;
  border-radius: 8px;
  font-size: 13px;
  margin-right: 4px;
  flex: 1;
  cursor: pointer;
}
