/**
 * Product card: React app src/components/ProductWidgets/ProductCard.js,
 * ApparelOptionIcons.js, components/Image (MUI Card, CardContent, CardActions).
 */
.card {
  overflow: hidden;
  border-radius: 8px;
  box-shadow: var(--shadow-1);
  background-color: inherit;
  color: #262626;
  font-family: var(--mui-font);
}
.card__media { position: relative; height: 150px; line-height: 0; }
@media (min-width: 489px) { .card__media { height: 184px; } }
@media (min-width: 1024px) { .card__media { height: 159px; } }
@media (min-width: 1536px) { .card__media { height: 200px; } }
.card__image-link { display: block; height: 100%; }
/* Image box: black, with the placeholder until the photo paints over it. */
.card__image {
  display: flex;
  height: 100%;
  background: #000 url('../images/kure_lm_default_product_image_card.jpg') center / contain no-repeat;
}
.card__image img { width: 100%; height: 100%; display: block; object-fit: cover; }
.card__image--empty { background-image: none; }
.card__image--empty img { object-fit: contain; }

.card__content {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 190px;
  padding: 10px;
  background-color: #333;
}
@media (min-width: 768px) { .card__content { height: 180px; } }
.wrapper .card__title-wrap { margin: 0; color: #8c8c8c; }
.card__title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: normal;
  height: 37px;
  font-size: 1rem;
  line-height: 1.1;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
  cursor: pointer;
}
.card__title:hover { color: #32beb9; text-decoration: underline; }
@media (min-width: 768px) { .card__title { height: 52px; line-height: 1.5; } }

.card__options { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; padding-top: 6px; }
.swatch { width: 16px; height: 16px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, 0.55); }
.swatch.is-out { opacity: 0.4; }
.size-tile {
  min-width: 22px;
  height: 20px;
  padding: 0 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 4px;
  color: #fff;
  font-size: 0.6875rem;
  font-weight: 700;
  line-height: 1;
}
.size-tile.is-out { opacity: 0.6; text-decoration: line-through; }

/* Brand / strain in letter-spaced capitals under the title, then THC/CBD in a
   dashed label-style box (design 18, tmp/product-card-designs-2.html). The
   title keeps two lines of height, so these start at the same place on every card. */
.wrapper .card__brand {
  margin: 0;
  padding-top: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #bdbdbd;
  font-size: 0.6875rem;
  line-height: 1.5;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.wrapper .card__potency {
  margin: 8px 0 0;
  padding: 4px 6px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  border: 1px dashed #777;
  border-radius: 4px;
  color: #e8e8e8;
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 0.6875rem;
  line-height: 1.5;
  letter-spacing: 0.03em;
  text-align: center;
}

.card__price { margin-top: auto; color: #000; font-size: 0.875rem; }
.price { display: flex; color: #fff; }
.price span { font-size: 15px; line-height: 30px; font-weight: bold; }
.price span.price__original { text-decoration: line-through; margin-right: 10px; font-weight: 400; }

.card__actions { display: flex; align-items: center; padding: 0 10px 10px; background-color: #333; }
.card__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-width: 64px;
  height: 38px;
  margin: 0;
  padding: 6px 8px;
  border: 1px solid #32beb9;
  border-radius: 4px;
  background-color: #32beb9;
  color: #fff;
  font-family: var(--mui-font);
  font-size: 0.875rem;
  font-weight: 400;
  line-height: 1.75;
  text-align: center;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms, box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms, border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms, color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;
}
.card__button:disabled { cursor: default; }
/* CircularProgress shown while adding (15px, white). */
.spinner {
  display: inline-block;
  width: 15px;
  height: 15px;
  margin-right: 10px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spin 1.4s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Staff "Adjust product" menu (js/shell.js): a ⋮ button over the image, styled
   like the card badges, opening a dark menu with the teal accent, matching the
   customer popup panels (css/cart-customer.css). */
.adjust-trigger {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 11;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background-color: rgba(0, 0, 0, 0.7);
  color: #fff;
  cursor: pointer;
  transition: background-color 150ms cubic-bezier(0.4, 0, 0.2, 1);
}
.adjust-trigger .icon { font-size: 20px; }
.adjust-trigger:hover, .adjust-trigger.is-open { background-color: rgba(0, 0, 0, 0.9); }
.adjust-trigger:focus-visible { outline: 2px solid #32beb9; outline-offset: 2px; }
.product__image-box .adjust-trigger { top: 16px; right: 16px; width: 40px; height: 40px; }
.product__image-box .adjust-trigger .icon { font-size: 24px; }

.adjust-menu { position: fixed; inset: 0; z-index: 1400; }
.adjust-menu__paper {
  position: absolute;
  min-width: 180px;
  border: 1px solid #2e3333;
  border-radius: 8px;
  background-color: #1c1c1c;
  color: var(--text-color);
  box-shadow: var(--shadow-24);
}
.adjust-menu__list { margin: 0; padding: 6px 0; list-style: none; }
.adjust-menu__item {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 48px;
  padding: 6px 16px;
  box-sizing: border-box;
  color: var(--text-color);
  font-family: var(--mui-font);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.57;
  white-space: nowrap;
  text-decoration: none;
  outline: 0;
  transition: background-color 150ms, color 150ms;
}
@media (min-width: 489px) { .adjust-menu__item { min-height: 40px; } }
.adjust-menu__item .icon { font-size: 20px; color: var(--primary); }
.adjust-menu__item:hover { background-color: #262a2a; color: var(--primary-hover); }
.adjust-menu__item:hover .icon { color: var(--primary-hover); }
.adjust-menu__item:focus-visible { background-color: rgba(50, 190, 185, 0.16); box-shadow: inset 3px 0 0 var(--primary); }
