.cart-container {
  max-width: 1000px;
  margin: 40px auto;
  padding: 20px;
}

.cart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  border-bottom: 2px solid #2c7a3f;
  padding-bottom: 20px;
}

.cart-header h1 {
  margin: 0;
  color: #333;
}

.item-count {
  font-size: 16px;
  color: #666;
}

.cart-items {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 30px;
}

.cart-items thead {
  background-color: #f5f5f5;
}

.cart-items th {
  padding: 15px;
  text-align: left;
  font-weight: 600;
  color: #333;
  border-bottom: 2px solid #ddd;
}

.cart-items td {
  padding: 15px;
  border-bottom: 1px solid #eee;
  vertical-align: middle;
}

.cart-items tbody tr:hover {
  background-color: #f9f9f9;
}

.item-details {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.item-details span {
  font-size: 13px;
  color: #666;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.item-details strong {
  color: #333;
}

.price {
  font-weight: 600;
  color: #2c7a3f;
  font-size: 16px;
}

.quantity-input {
  width: 60px;
  padding: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
}

.remove-btn {
  background-color: #ff6b6b;
  color: white;
  border: none;
  padding: 8px 12px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 13px;
  transition: background-color 0.3s ease;
}

.remove-btn:hover {
  background-color: #ff5252;
}

.cart-empty {
  text-align: center;
  padding: 60px 20px;
  color: #666;
}

.cart-empty p {
  font-size: 18px;
  margin-bottom: 20px;
}

.cart-summary {
  background-color: #f5f5f5;
  padding: 25px;
  border-radius: 8px;
  max-width: 400px;
  margin-left: auto;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 15px;
}

.summary-row span {
  min-width: 0;
}

.summary-row span:last-child {
  margin-left: auto;
  white-space: nowrap;
}

.summary-row.total {
  border-top: 2px solid #ddd;
  padding-top: 12px;
  font-weight: 600;
  font-size: 18px;
  color: #2c7a3f;
}

.cart-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  margin-top: 30px;
}

.btn {
  padding: 12px 28px;
  border: none;
  border-radius: 6px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-continue {
  background-color: #e8e8e8;
  color: #333;
}

.btn-continue:hover {
  background-color: #d4d4d4;
}

.btn-checkout {
  background-color: #2c7a3f;
  color: white;
  box-shadow: 0 2px 8px rgba(44, 122, 63, 0.2);
}

.btn-checkout:hover {
  background-color: #1f5a2b;
  box-shadow: 0 4px 12px rgba(44, 122, 63, 0.3);
  transform: translateY(-2px);
}

.btn-checkout:active {
  transform: translateY(0);
}

.buyer-policies {
  margin-top: 26px;
  padding: 18px;
  background-color: #f6f8f6;
  border: 1px solid #dfe6df;
  border-radius: 8px;
}

.buyer-policies h2 {
  margin: 0 0 10px;
  font-size: 20px;
  color: #222;
}

.buyer-policies p {
  margin: 0 0 12px;
  color: #444;
}

.buyer-policies ul {
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 7px;
}

.buyer-policies a {
  color: #1f5a2b;
  font-weight: 600;
}

@media (max-width: 768px) {
  .cart-container {
    padding: 12px;
  }

  .cart-items {
    font-size: 13px;
    border-collapse: separate;
    width: 100%;
  }

  .cart-items thead {
    display: none;
  }

  .cart-items tbody,
  .cart-items tr,
  .cart-items td {
    display: block;
    width: 100%;
  }

  .cart-items tr {
    border: 1px solid #e3e3e3;
    border-radius: 10px;
    background-color: #fff;
    margin-bottom: 12px;
    padding: 10px;
  }

  .cart-items td {
    border-bottom: 1px solid #efefef;
    padding: 8px 0;
  }

  .cart-items td:last-child {
    border-bottom: none;
    padding-bottom: 0;
  }

  .cart-items td::before {
    content: '';
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #444;
    margin-bottom: 4px;
  }

  .cart-items td:nth-child(1)::before {
    content: 'Product';
  }

  .cart-items td:nth-child(2)::before {
    content: 'Details';
  }

  .cart-items td:nth-child(3)::before {
    content: 'Price';
  }

  .cart-items td:nth-child(4)::before {
    content: 'Quantity';
  }

  .cart-items td:nth-child(5)::before {
    content: 'Total';
  }

  .cart-items td:nth-child(6)::before {
    content: 'Action';
  }

  .quantity-input {
    width: 100%;
    max-width: 110px;
  }

  .remove-btn {
    width: 100%;
  }

  .cart-summary {
    max-width: 100%;
    margin-left: 0;
    margin-top: 20px;
    padding: 18px;
  }

  .summary-row {
    flex-wrap: wrap;
  }

  .cart-actions {
    flex-direction: column;
  }

  .btn {
    width: 100%;
    justify-content: center;
  }
}
