@import url('https://fonts.googleapis.com/css2?family=Unbounded:wght@400;500;600;700&display=swap');

.nh-actions,
.nh-actions * {
  box-sizing: border-box;
}

.nh-actions {
  width: 100%;
  padding: 0;
  margin: 0;
  font-family: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

.nh-actions__inner {
  max-width: 1480px;
  margin: 0 auto;
  padding: 0 20px;
}

.nh-actions__title {
  margin: 0 0 22px;
  font-size: clamp(24px, 3vw, 38px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: .01em;
  text-transform: uppercase;
  color: #1f2a1e;
}

.nh-actions__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

/* Page-обёртка — на десктопе невидима для сетки */
.nh-actions__page {
  display: contents;
}

/* Горизонтальная карточка: фото слева, подпись справа. Прямоугольное острое обрамление. */
.nh-action-card {
  position: relative;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0;
  padding: 0;
  background-color: transparent;
  border: 1px solid #d4d6d3;
  border-radius: 0;
  text-decoration: none;
  transition: border-color .2s ease;
  min-height: 112px;
  overflow: hidden;
}
.nh-action-card:hover,
.nh-action-card:focus-visible {
  border-color: #1f2a1e;
  outline: none;
}

.nh-action-card__img {
  display: block;
  flex: 0 0 92px;
  width: 92px;
  height: 92px;
  background-position: center;
  background-size: contain;
  background-repeat: no-repeat;
  overflow: hidden;
  transition: transform .35s ease;
  transform-origin: center center;
  will-change: transform;
}
.nh-action-card:hover .nh-action-card__img,
.nh-action-card:focus-visible .nh-action-card__img {
  transform: scale(1.08);
}

.nh-action-card__overlay { display: none; }

.nh-action-card__title {
  flex: 1;
  min-width: 0;
  font-family: "Unbounded", "Manrope", system-ui, sans-serif;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.28;
  letter-spacing: 0;
  color: #1f2a1e;
  text-transform: none;
  padding: 0 10px 0 14px;
}

@media (max-width: 1280px) {
  .nh-action-card__img { flex-basis: 82px; width: 82px; height: 82px; }
  .nh-action-card__title { font-size: 14px; }
}

@media (max-width: 1024px) {
  .nh-actions__grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
  }
  .nh-action-card { gap: 12px; padding: 9px; min-height: 102px; }
  .nh-action-card__img { flex-basis: 78px; width: 78px; height: 78px; }
  .nh-action-card__title { font-size: 13px; }
}

@media (max-width: 767px) {
  .nh-actions__inner { padding: 0 12px; }
  .nh-actions__title { margin-bottom: 16px; }
  /* 1 колонка — каждая карточка во всю ширину */
  .nh-actions__grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .nh-action-card { min-height: 100px; }
  .nh-action-card__img { flex-basis: 96px; width: 96px; height: 96px; }
  .nh-action-card__title {
    font-size: 14px;
    padding: 0 14px 0 16px;
  }

  /* На мобиле прячем карточки с 5-й и далее; раскрытие — через is-expanded */
  .nh-action-card.is-mobile-hidden { display: none; }
  .nh-actions.is-expanded .nh-action-card.is-mobile-hidden { display: flex; }
}

@media (max-width: 360px) {
  .nh-actions__grid { gap: 6px; }
  .nh-action-card { min-height: 84px; }
  .nh-action-card__img { flex-basis: 80px; width: 80px; height: 80px; }
  .nh-action-card__title { font-size: 13px; padding: 0 12px 0 14px; }
}

/* Кнопка «Показать ещё» — только на мобиле */
.nh-actions__actions { display: none; }
@media (max-width: 767px) {
  .nh-actions__actions {
    display: flex;
    justify-content: center;
    margin-top: 14px;
  }
  .nh-actions__toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 24px;
    border: 1px solid #d4d6d3;
    background: transparent;
    color: #1f2a1e;
    font-family: "Unbounded", "Manrope", system-ui, sans-serif;
    font-size: 13px;
    font-weight: 500;
    line-height: 1;
    letter-spacing: .02em;
    cursor: pointer;
    border-radius: 0;
    transition: background-color .2s ease, color .2s ease, border-color .2s ease;
  }
  .nh-actions__toggle:hover,
  .nh-actions__toggle:focus-visible {
    background-color: #1f2a1e;
    color: #ffffff;
    border-color: #1f2a1e;
    outline: none;
  }
  .nh-actions__toggle-icon {
    display: inline-block;
    font-size: 14px;
    line-height: 1;
    transition: transform .25s ease;
  }
  .nh-actions.is-expanded .nh-actions__toggle-icon {
    transform: rotate(180deg);
  }
}
