/* Shared product card. Source: the approved homepage recommended-product card.
   Page layouts own columns/gaps; card typography and appearance live here. */
:is(.xinocler-home,.shopwise-main) .x-product-card {
  --product-divider-color:#d5dbe3;
  box-sizing:border-box;display:flex;flex-direction:column;min-width:0;height:100%;
  border:1px solid var(--product-divider-color);border-radius:12px;overflow:hidden;
  background:#f1f5fb;color:#192a47;box-shadow:none;text-decoration:none;
  font-family:var(--cn-font,"XINOCLER Source Han Sans SC",sans-serif);
  font-style:normal;text-align:left;cursor:pointer;transition:box-shadow .3s;
}
.x-product-card .x-product-card__media {
  position:relative;flex:none;width:100%;aspect-ratio:16/9;max-height:192px;
  overflow:hidden;background:#eef2f6;
}
.x-product-card .x-product-card__media>img {
  display:block;width:100%;height:100%;max-width:100%;object-fit:cover;
  object-position:center;transform-origin:center;transition:transform .5s;
}
.x-product-card .x-product-card__category {
  position:absolute;top:8px;left:8px;max-width:calc(100% - 16px);padding:2px 8px;
  margin:0;border-radius:4px;background:rgb(30 136 229 / 90%);color:#fff;
  font-size:10px;line-height:15px;font-weight:400;letter-spacing:var(--tracking-control,.05em);
  white-space:nowrap;overflow:hidden;text-overflow:ellipsis;
}
.x-product-card .x-product-card__body {
  display:flex;flex-direction:column;flex:1;min-width:0;padding:16px 16px 12px;
}
.x-product-card .x-product-card__summary {display:block;flex:1;min-width:0;margin:0;padding:0;}
.x-product-card .x-product-card__title {
  margin:0 0 8px;padding:0;color:#192a47;font-family:inherit;font-size:12px;
  line-height:17px;font-weight:400;letter-spacing:var(--tracking-heading,.055em);
  white-space:nowrap;overflow:hidden;text-overflow:ellipsis;transition:color .3s;
}
.x-product-card .x-product-card__description {
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;
  height:34px;margin:0 0 12px;padding:0;color:#546479;font-size:10px;line-height:17px;
  font-weight:300;letter-spacing:var(--tracking-body,.045em);
}
.x-product-card .x-product-card__bottom {
  display:flex;justify-content:space-between;align-items:center;gap:12px;
  padding:8px 0 0;margin:0;border-top:1px solid var(--product-divider-color);
}
.x-product-card .x-product-card__sku {font-size:10px;line-height:15px;font-weight:400;color:#4b6078;}
.x-product-card .x-product-card__action {
  display:inline-flex;align-items:center;flex:none;gap:4px;color:#21588d;
  font-size:10px;line-height:16px;font-weight:400;transition:transform .3s;
}
.x-product-card .x-product-card__action svg {width:12px;height:12px;flex:none;}
/* The imported homepage applies an important Light reset to all text elements. */
.x-product-card :is(.x-product-card__title,.x-product-card__category,.x-product-card__sku,.x-product-card__action) {font-weight:400!important;}
:is(.xinocler-home,.shopwise-main) .x-product-card:is(:hover,:focus-visible) {
  border-color:var(--product-divider-color);box-shadow:0 10px 15px rgb(30 136 229 / 5%);
}
.x-product-card:is(:hover,:focus-visible) .x-product-card__media>img {transform:scale(1.05);}
.x-product-card:is(:hover,:focus-visible) .x-product-card__title {color:#21588d;}
.x-product-card:is(:hover,:focus-visible) .x-product-card__action {transform:translateX(4px);}
:is(.xinocler-home,.shopwise-main) .x-product-card:focus-visible {outline:2px solid #1e88e5;outline-offset:3px;}
/* Homepage five-screen composition keeps its existing short-window density. */
@media(min-width:992px) {
  .x-product-card[data-card-density="compact"] .x-product-card__media {height:clamp(72px,calc(22svh - 105px),192px);aspect-ratio:auto;}
}
@media(min-width:992px) and (max-height:1199px) {
  .x-product-card[data-card-density="compact"] .x-product-card__body {padding:8px 12px;}
  .x-product-card[data-card-density="compact"] .x-product-card__title {margin-bottom:4px;}
  .x-product-card[data-card-density="compact"] .x-product-card__description {height:30px;line-height:15px;margin-bottom:6px;}
  .x-product-card[data-card-density="compact"] .x-product-card__bottom {padding-top:5px;}
}
@media(prefers-reduced-motion:reduce) {
  :is(.xinocler-home,.shopwise-main) .x-product-card,
  .x-product-card .x-product-card__media>img,
  .x-product-card .x-product-card__title,
  .x-product-card .x-product-card__action {transition:none;}
  .x-product-card:is(:hover,:focus-visible) .x-product-card__media>img,
  .x-product-card:is(:hover,:focus-visible) .x-product-card__action {transform:none;}
}

/* The catalog's compact list reuses the card fields and quick-view interaction. */
.shopwise-main [data-view="simple"] .x-product-card {
  display:grid;
  grid-template-columns:clamp(70px,12%,108px) minmax(0,1fr);
  min-height:78px;
  border-radius:8px;
}
.shopwise-main [data-view="simple"] .x-product-card__media {
  height:100%;
  max-height:none;
  aspect-ratio:auto;
}
.shopwise-main [data-view="simple"] .x-product-card__media > img {position:absolute;inset:0;}
.shopwise-main [data-view="simple"] .x-product-card__category {display:none;}
.shopwise-main [data-view="simple"] .x-product-card__body {
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  align-items:center;
  gap:12px;
  padding:8px 13px;
}
.shopwise-main [data-view="simple"] .x-product-card__title {margin:0 0 3px;}
.shopwise-main [data-view="simple"] .x-product-card__description {
  display:block;
  height:auto;
  margin:0;
  white-space:nowrap;
  text-overflow:ellipsis;
}
.shopwise-main [data-view="simple"] .x-product-card__bottom {padding:0;border:0;}
@media(max-width:575px) {
  .shopwise-main [data-view="simple"] .x-product-card__body {grid-template-columns:minmax(0,1fr);gap:4px;padding:6px 9px;}
}

/* Translucent product cards for the dark consultation section. */
.shopwise-main [data-card-surface="dark"] .x-product-card {
  --product-divider-color:rgb(217 234 252 / 16%);
  background:rgb(225 238 255 / 5%);
}
.shopwise-main [data-card-surface="dark"] .x-product-card__title {
  color:#fff;
}
.shopwise-main [data-card-surface="dark"] .x-product-card__description {
  color:#b8c8da;
}
.shopwise-main [data-card-surface="dark"] :is(.x-product-card__sku,.x-product-card__action) {
  color:#8ccaff;
}
