.add-to-cart-button {
  margin-top: 2rem
}

.books-grid {
    display: grid;
    gap: 20px;
}

/* Desktop: 4 columns */
@media (min-width: 1024px) {
    .books-grid { grid-template-columns: repeat(4, 1fr); }
}

/* Tablet: 2 columns */
@media (min-width: 600px) and (max-width: 1023px) {
    .books-grid { grid-template-columns: repeat(2, 1fr); }
}

/* Mobile: 1 column */
@media (max-width: 599px) {
    .books-grid { grid-template-columns: repeat(1, 1fr); }
}

.book-card {
    border: 1px solid #ddd;
    padding: 10px;
    text-align: center;
    background: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.book-card img {
    max-width: 100%;
    height: 200px;
}

.book-card h2 {font-size:1em; margin-top:10px;}

.book-card h3 { margin: 10px 0; }
.book-card p { margin: 5px 0; }
.checkout-button, .add-to-cart-button {
    background-color: rgb(56, 87, 35);
    border: none;
    color: white;
    padding: 10px 15px;
    text-align: center;
    text-decoration: none;
    display: block;
    width: 120px;
    font-size: 14px;
    border-radius: 20px;
    border: 2px solid rgb(56, 87, 35);
    margin: auto

}

.checkout-button:hover {
      color: rgb(56, 87, 35);
      background-color: white;
      text-decoration: none;
}

button:disabled{
    opacity:0.5;
}


.image-container{width:50%; float:left;
img {
    width:-webkit-fill-available;
}
}


table.cart-table {
  border: 1px solid;
  width: 100%;
  tr, td, th {
    border-bottom: 1px solid;
    padding: 8px;
  }
  td:last-of-type, th:last-of-type{
    text-align: right;
  }
}

.form-row{
  margin-bottom: 0;
}

/* .checkout-button{margin-top:15px} */
.book-details{padding-left:20px;width:50%; float:right}

.checkout-page {
   font-family: sans-serif;
  .order-summary {
    border: 1px solid #ccc;
    padding: 1rem;
  }
  table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1rem;
  }
  .heading{
    border-bottom: 1px solid #ddd;}
  th, td {
    padding: 0.5rem;
    border-bottom: 1px solid #ddd;
    text-align: left;
  }


  .required-star::after {
    content: " *";
    color: red;
  }

}


.checkout-button.disabled {
    pointer-events: none;
    opacity: 0.5;
}
.input-error {
    border: 2px solid red !important;
    background-color: #fff0f0;
}
.error-message {
    color: red;
    font-size: 0.9em;
    margin-top: 2px;
    margin-bottom: 8px;
    display: block;
}
input.input-error, select.input-error, textarea.input-error {
    border: 1px solid red !important;
    background-color: #fff0f0 !important;
}

.user-message {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  min-width: 250px;
  max-width: 90vw;
  z-index: 9999;
  padding: 16px 24px;
  border-radius: 6px;
  font-size: 1.1em;
  color: #fff;
  background:rgb(43, 182, 75);
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  text-align: center;
  transition: opacity 0.3s;
}

.user-message.error {
  background:rgb(220, 53, 69);
}

.table-borderless td, .table-borderless th {
  border: none !important;
  padding: 0.25rem 0.5rem !important;
}
.badge-secondary { background: #6c757d; }
.badge-success { background: #28a745; }

.chip {
  display: inline-block;
  background: #f1f1f1;
  border-radius: 16px;
  padding: 0.25em 0.75em;
  margin: 0 0.25em 0.25em 0;
  font-size: 0.95em;
}
.badge-secondary { background: #6c757d; color: #fff; border-radius: 8px; padding: 0.1em 0.5em; }
.badge-success { background: #28a745; color: #fff; border-radius: 8px; padding: 0.1em 0.5em; }