/* ═══════════════════════════════════════════════════════════════
   Category card — a picture with a title and an optional line underneath:
   the product tile's look (see sub-components/ProductTile) without a price
   and a "+". No box, no shadow; every color and font is a global token.
   From the carousel: --cc-ratio-d (from 1024px up), --cc-ratio-m, --cc-text.
   ═══════════════════════════════════════════════════════════════ */

.cc_JsHSjQyQmG_HHDiM2iSdZ .category-card {
  display: flex;
  flex-direction: column;
  width: 100%;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}

/* The ratio is fixed before the picture arrives: nothing moves when it loads.
   Without a picture this plain surface is the card. */
.cc_JsHSjQyQmG_HHDiM2iSdZ .category-card__media {
  position: relative;
  display: block;
  aspect-ratio: var(--cc-ratio-d, 3 / 4);
  overflow: hidden;
  background: var(--color-surface-alt);
}

.cc_JsHSjQyQmG_HHDiM2iSdZ .category-card__picture {
  position: absolute;
  inset: 0;
  display: block;
}

/* Cropped to the card's shape, never stretched or zoomed */
.cc_JsHSjQyQmG_HHDiM2iSdZ .category-card__image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity var(--duration) var(--ease);
}

.cc_JsHSjQyQmG_HHDiM2iSdZ .category-card__info {
  display: flex;
  flex-direction: column;
  gap: var(--space-2xs);
  min-width: 0;
  padding: var(--space-xs) var(--space-xs) 0;
}

/* One line; a long title ends in "…" */
.cc_JsHSjQyQmG_HHDiM2iSdZ .category-card__title {
  display: block;
  overflow: hidden;
  font-size: var(--cc-text, var(--text-label));
  letter-spacing: var(--tracking-wide);
  line-height: 1.4;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.cc_JsHSjQyQmG_HHDiM2iSdZ .category-card__text {
  display: block;
  overflow: hidden;
  font-size: var(--cc-text, var(--text-label));
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--color-text-secondary);
}

/* The only hover effect: the picture lightens a little */
@media (hover: hover) {
  .cc_JsHSjQyQmG_HHDiM2iSdZ .category-card--link:hover .category-card__image { opacity: 0.92; }
}

.cc_JsHSjQyQmG_HHDiM2iSdZ .category-card--link:focus-visible { outline: none; }

.cc_JsHSjQyQmG_HHDiM2iSdZ .category-card--link:focus-visible .category-card__media {
  outline: 1px solid var(--color-text-primary);
  outline-offset: -4px;
}

@media not all and (min-width: 1024px) {
  .cc_JsHSjQyQmG_HHDiM2iSdZ .category-card__media { aspect-ratio: var(--cc-ratio-m, 3 / 4); }
}

@media (prefers-reduced-motion: reduce) {
  .cc_JsHSjQyQmG_HHDiM2iSdZ .category-card__image { transition: none; }
}
