/* hob/css/cart.css */

/* --------------------------------
   Center wrapper & table
   -------------------------------- */
.cart-container {
  max-width: 800px;       /* constrain width */
  margin: 2rem auto;      /* auto‐center horizontally */
  background: #fff;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.cart-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 0.5rem;
  margin: 0 auto 1.5rem;  /* auto‐center and bottom space */
}

/* --------------------------------
   Success message
   -------------------------------- */
.cart-success {
  background: #e6f9e6;
  color: #2d662d;
  border: 1px solid #2d662d;
  padding: 0.75rem 1rem;
  border-radius: 4px;
  margin-bottom: 1rem;
  text-align: center;
}

/* --------------------------------
   Empty cart
   -------------------------------- */
.empty-cart {
  font-size: 1.125rem;
  text-align: center;
  margin: 2rem 0;
}
.empty-cart a {
  color: #b08b4f;
  text-decoration: none;
}
.empty-cart a:hover {
  text-decoration: underline;
}

/* --------------------------------
   Table cells & rows
   -------------------------------- */
.cart-table th,
.cart-table td {
  padding: 0.75rem;
  text-align: left;
}
.cart-table thead th {
  font-weight: 600;
  color: #333;
  border-bottom: 2px solid #eee;
}
.cart-table tbody tr {
  background: #fafafa;
  transition: background 0.2s;
}
.cart-table tbody tr:hover {
  background: #f0f0f0;
}
.cart-table tfoot td {
  padding-top: 1rem;
  border-top: 2px solid #ddd;
}

/* --------------------------------
   Item cell with image
   -------------------------------- */
.item-cell {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.item-cell img {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: 4px;
  flex-shrink: 0;
}

/* --------------------------------
   Remove button
   -------------------------------- */
.remove-btn {
  display: inline-block;
  font-size: 1.25rem;
  color: #900;
  text-decoration: none;
}
.remove-btn:hover {
  opacity: 0.7;
}

/* --------------------------------
   Cart action buttons
   -------------------------------- */
.cart-actions {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
}
.cart-actions .btn {
  padding: 0.75rem 1.5rem;
}
.cart-actions .btn-secondary {
  background-color: #666;
  color: #fff;
}
.cart-actions .btn-secondary:hover {
  opacity: 0.9;
}
