.store-page {
  max-width: 60rem;
  margin: auto;
  padding: 2rem 1rem;
}

.page-title {
  text-align: center;
}

.product-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 1.5rem;
}

.product-card {
  display: flex;
  flex-direction: column;
  text-align: center;
}

.product-card-link {
  flex-grow: 1;
  /* Lines up the Quick add buttons, even when one product name is longer than the others */
  color: var(--colour-text);
  text-decoration: none;
}

.product-card img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  /* Makes every image a square, cropping instead of stretching */
  background-color: #eee;
  border-radius: 4px;
}

.product-card h2 {
  font-size: 1.1rem;
  margin: 0.75rem 0 0.25rem;
}

.price {
  font-weight: bold;
  margin: 0;
}

.out-of-stock {
  color: var(--colour-text-soft);
  margin: 0.25rem 0 0;
}

/* Its outline and shape come from ROUNDED BUTTONS in index.css */
.quick-add-button {
  display: block;
  margin-top: 0.75rem;
  padding: 0.6rem;
  background-color: var(--colour-surface);
  color: var(--colour-text);
  font-size: 0.95rem;
  font-weight: bold;
  text-decoration: none;
  cursor: pointer;
}

.quick-add-button:hover {
  background-color: var(--colour-button);
  color: var(--colour-text-on-dark);
}

.quick-add-button:disabled {
  border-color: var(--colour-border);
  color: var(--colour-text-soft);
  background-color: var(--colour-surface);
  cursor: not-allowed;
}

@media(max-width: 768px) {
  .product-grid {
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
  }
}