.home-category-navigation {
  display: grid;
  gap: 9px;
  margin: 10px 12px 2px;
}

.home-category-row {
  gap: 8px;
}

.home-category-row--primary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.home-category-row--secondary {
  display: flex;
  overflow-x: auto;
  padding: 1px 0 4px;
  scroll-snap-type: x proximity;
  scrollbar-width: none;
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
}

.home-category-row--secondary::-webkit-scrollbar {
  display: none;
}

.home-category-row--secondary .home-category-card {
  flex: 0 0 calc((100% - 24px) / 4);
  scroll-snap-align: start;
}

.home-category-card {
  position: relative;
  min-width: 0;
  padding: 0;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 10px;
  color: #fff;
  background: #dfe9e4;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
  cursor: pointer;
}

.home-category-card::after {
  content: "";
  position: absolute;
  inset: 38% 0 0;
  background: linear-gradient(transparent, rgba(4, 15, 11, 0.76));
  pointer-events: none;
}

.home-category-card img,
.home-category-card__placeholder {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.home-category-card__placeholder {
  background: linear-gradient(135deg, #b8d6c7, #57856f);
}

.home-category-card strong {
  position: absolute;
  z-index: 1;
  right: 4px;
  bottom: 5px;
  left: 4px;
  overflow: hidden;
  font-size: 11px;
  line-height: 1.2;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.45);
}

.home-category-card.is-active {
  border-color: #087a55;
  box-shadow: 0 0 0 2px rgba(8, 122, 85, 0.2);
}

.home-category-card:focus-visible {
  outline: 2px solid rgba(8, 122, 85, 0.55);
  outline-offset: 2px;
}
