:root {
  --storefront-font: Arial, Helvetica, sans-serif;
  --storefront-muted: #515d67;
  --storefront-border: #dce1e5;
}

body { font-family: var(--storefront-font); }
button, input, select, textarea { font-family: inherit; font-size: 1rem; }
#results .invoice-add { font-family: inherit; }
#retail > label { font-size: .95rem; font-weight: 700; }
#retail > label :is(input, select) {
  min-height: 44px;
  border: 1px solid #aeb8bf;
  border-radius: .5rem;
  background: #fff;
  color: var(--ink);
}
#brands { grid-template-columns: repeat(auto-fit, minmax(min(100%, 130px), 1fr)); }

#cases, #lots {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr));
  gap: 1rem;
}
.bundle-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: clamp(1rem, 3vw, 1.5rem);
  border: 1px solid var(--storefront-border);
  border-radius: .75rem;
  background: #fff;
}
.bundle-card h3, .bundle-card h4 { margin: 0; line-height: 1.25; }
.bundle-card h3 { font-size: 1.25rem; }
.bundle-card h4 { font-size: .95rem; margin-top: 1.15rem; }
.bundle-card .bundle-specs { margin: .4rem 0 .75rem; font-size: .9rem; color: var(--storefront-muted); }
.bundle-manifest { padding: 0; margin: .45rem 0 1rem; list-style: none; }
.bundle-manifest li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: .65rem;
  align-items: start;
  padding: .65rem 0;
  border-bottom: 1px solid var(--storefront-border);
  font-size: .9rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.bundle-manifest .bundle-manifest-row { grid-template-columns: 56px minmax(0, 1fr) auto; }
.bundle-manifest li > span { white-space: nowrap; font-weight: 700; }
.bundle-preview img { display: block; width: 56px; height: 56px !important; object-fit: contain; }
.bundle-manifest small, .cart-preview small { display: block; margin-top: .2rem; color: var(--storefront-muted); }
.bundle-add {
  align-self: flex-start;
  margin-top: auto;
  min-height: 44px;
  padding: .55rem .9rem;
  border: 0;
  border-radius: .5rem;
  background: var(--orange);
  color: var(--ink);
  font-size: .9rem;
  font-weight: 700;
  cursor: pointer;
}
.bundle-add:disabled { opacity: .55; cursor: default; }

#quote { max-width: 920px; }
.invoice-cart-heading {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .5rem;
}
.invoice-cart-heading h3 { margin: 0; }
#quote :is(#cart-remove-all, .cart-remove) {
  background: transparent;
  color: var(--ink);
  border: 0;
  min-height: 44px;
  padding: .3rem;
  font-size: .9rem;
  text-decoration: underline;
}
#requested .invoice-cart-line {
  grid-template-columns: 96px minmax(0, 1fr) auto;
  gap: .75rem 1rem;
  align-items: start;
  padding: 1rem;
  background: #fff;
  border: 1px solid var(--storefront-border);
  border-radius: .65rem;
}
#requested .invoice-cart-line + .invoice-cart-line { margin-top: .65rem; }
#requested .invoice-cart-line > :not(img) { grid-column: auto; min-width: 0; }
.cart-preview { text-align: center; }
.cart-preview img { display: block; width: 100%; height: 96px !important; object-fit: contain; }
.cart-preview small { font-size: .68rem; line-height: 1.2; overflow-wrap: anywhere; }
#requested .cart-product-name { margin: 0; overflow-wrap: anywhere; }
#requested .cart-product-meta { margin: .25rem 0 0; color: var(--storefront-muted); font-size: .9rem; }
.cart-product-info details { margin-top: .5rem; font-size: .88rem; }
.cart-product-info summary { cursor: pointer; text-decoration: underline; }
.cart-product-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .35rem .8rem; margin-top: .5rem; }
.cart-quantity-controls { gap: 0; margin: 0; }
#quote .cart-quantity-button {
  background: #f4f6f7;
  color: var(--ink);
  border-color: #aeb8bf;
}
#quote .cart-quantity-button:first-child { border-radius: .45rem 0 0 .45rem; }
#quote .cart-quantity-button:last-child { border-radius: 0 .45rem .45rem 0; }
#quote .cart-quantity-controls input {
  width: 54px !important;
  padding: .25rem;
  border-radius: 0;
  border-inline: 0;
  appearance: textfield;
  -moz-appearance: textfield;
}
.cart-quantity-controls input::-webkit-inner-spin-button,
.cart-quantity-controls input::-webkit-outer-spin-button { appearance: none; }
.cart-amount { text-align: right; }
.cart-amount small { color: var(--storefront-muted); }
#requested .cart-line-total { margin: .2rem 0 0; font-size: 1.05rem; }
#cart-summary { border-radius: .55rem; padding: .85rem 1rem; font-weight: normal; }
.cart-summary-heading { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .4rem 1rem; font-weight: 700; }
#cart-summary p { margin: .3rem 0 0; font-size: .88rem; line-height: 1.35; }
@media (max-width: 560px) {
  #requested .invoice-cart-line { grid-template-columns: 56px minmax(0, 1fr); padding: .75rem; gap: .6rem; }
  #requested .invoice-cart-line > .cart-amount { grid-column: 2; text-align: left; }
  .cart-preview img { height: 65px !important; }
  .bundle-manifest .bundle-manifest-row { grid-template-columns: 48px minmax(0, 1fr) auto; gap: .45rem; }
  .bundle-preview img { width: 48px; height: 48px !important; }
}
