.wp-encoded-category-cards {
  --encoded-category-columns: var(--encoded-category-columns-desktop, 4);
  --encoded-category-gap: var(--encoded-category-gap-desktop, 16px);
  display: grid;
  grid-template-columns: repeat(var(--encoded-category-columns), minmax(0, 1fr));
  gap: var(--encoded-category-gap);
  width: 100%;
  margin: 0;
  padding: 0;
  list-style: none;
}

.wp-encoded-category-cards__item {
  min-width: 0;
  margin: 0;
}

.wp-encoded-category-cards__item > .btn-href {
  box-sizing: border-box;
  display: flex;
  width: 100%;
  min-height: 132px;
  padding: 20px 16px;
  border: 1px solid #c9a85e;
  border-radius: 16px;
  background: #d2d4d6;
  color: #20272d;
  cursor: pointer;
  transition: border-color 180ms cubic-bezier(0.23, 1, 0.32, 1),
    box-shadow 180ms cubic-bezier(0.23, 1, 0.32, 1),
    transform 180ms cubic-bezier(0.23, 1, 0.32, 1);
}

.wp-encoded-category-cards.is-vertical .wp-encoded-category-cards__item > .btn-href {
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  text-align: center;
}

.wp-encoded-category-cards.is-horizontal .wp-encoded-category-cards__item > .btn-href {
  flex-direction: row;
  align-items: center;
  gap: 14px;
  text-align: left;
}

.wp-encoded-category-cards__item > .btn-href:hover {
  border-color: #e76720;
  box-shadow: 0 10px 28px rgba(20, 31, 38, 0.14);
  transform: translateY(-2px);
}

.wp-encoded-category-cards__item > .btn-href:focus-visible {
  outline: 3px solid #f28c45;
  outline-offset: 3px;
}

.wp-encoded-category-cards__media {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 61px;
  height: 61px;
}

.wp-encoded-category-cards__media img,
.wp-encoded-category-cards__icon,
.wp-encoded-category-cards__icon svg,
.wp-encoded-category-cards__icon i {
  display: block;
  width: 61px;
  height: 61px;
}

.wp-encoded-category-cards__media img {
  object-fit: contain;
}

.wp-encoded-category-cards__icon {
  color: currentColor;
  font-size: 52px;
  line-height: 61px;
}

.wp-encoded-category-cards__content {
  min-width: 0;
}

.wp-encoded-category-cards .name {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.35;
}

.wp-encoded-category-cards .text {
  margin-top: 5px;
  color: #697078;
  font-size: 0.9rem;
  line-height: 1.45;
}

@media (max-width: 1024px) {
  .wp-encoded-category-cards {
    --encoded-category-columns: var(--encoded-category-columns-tablet, 2);
    --encoded-category-gap: var(--encoded-category-gap-tablet, 12px);
  }
}

@media (max-width: 767px) {
  .wp-encoded-category-cards {
    --encoded-category-columns: var(--encoded-category-columns-mobile, 2);
    --encoded-category-gap: var(--encoded-category-gap-mobile, 10px);
  }

  .wp-encoded-category-cards__item > .btn-href {
    min-height: 118px;
    padding: 16px 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .wp-encoded-category-cards__item > .btn-href {
    transition: none;
  }
}
