<!-- style.css -->
body {
  font-family: Arial, sans-serif;
  background: #f4f4f4;
  margin: 0;
  padding: 0;
}
.item-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 20px;
  padding: 20px;
}
.item-card {
  background: white;
  border-radius: 10px;
  padding: 15px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  text-align: center;
}
.item-card img {
  max-width: 100%;
  height: 180px;
  object-fit: contain;
}
.btn {
  padding: 10px 15px;
  background: #007bff;
  color: #fff;
  border: none;
  border-radius: 5px;
  cursor: pointer;
}
.btn:hover {
  background: #0056b3;
}

/* cart table */
table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
}
th, td {
  border: 1px solid #ccc;
  padding: 10px;
  text-align: center;
}
th {
  background: #eee;
}


/* script.js */
function confirmCheckout() {
  return confirm("Are you sure you want to complete this order?");
}

function updateCaseTotal(inputElem, percase, price, rowId) {
  let cases = parseInt(inputElem.value) || 1;
  let units = cases * percase;
  let subtotal = units * price;
  document.getElementById(`subtotal_${rowId}`).innerText = "$" + subtotal.toFixed(2);
}
