.tst-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
@media (min-width: 576px) {
  .tst-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 992px) {
  .tst-grid { grid-template-columns: repeat(3, 1fr); }
}

.tst-card {
  border-radius: 18px;
  border: 1px solid #D7DDE2;
  overflow: hidden;
  background: #fff;
  display: flex;
  flex-direction: column;
  min-width: 0;
  transition: box-shadow .2s;
}
.tst-card:hover {
  box-shadow: 0 8px 24px rgba(0,0,0,.09);
}

.tst-card-img-link {
  display: block;
  flex-shrink: 0;
  overflow: hidden;
  aspect-ratio: 5 / 3;
}
.tst-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .3s ease;
}
.tst-card-img-link:hover .tst-card-img {
  transform: scale(1.04);
}

.tst-card-body {
  padding: 16px 20px 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.tst-author {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}
.tst-avatars {
  display: flex;
  align-items: center;
}
.tst-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1.5px solid #fff;
  object-fit: cover;
  flex-shrink: 0;
}
.tst-avatars .tst-avatar + .tst-avatar {
  margin-left: -8px;
}
.tst-author-name {
  font-size: 12px;
  font-weight: 600;
  color: #434A57;
  line-height: 1;
  font-family: Inter, sans-serif;
}

.tst-card-title {
  font-size: 20px;
  font-weight: 600;
  line-height: 1.4;
  margin: 0 0 4px;
  font-family: Inter, sans-serif;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.tst-card-title a {
  color: #1F2937;
  text-decoration: none;
}
.tst-card-title a:hover {
  color: #45bc60;
}
@media (min-width: 992px) {
  .tst-card-title { font-size: 22px; }
}

.tst-card-desc {
  font-size: 15px;
  color: #697488;
  line-height: 1.5;
  margin: 0;
  font-family: Inter, sans-serif;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Теги — одна строка, скрываем лишнее */
.tst-tags {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  margin-top: auto;
  padding-top: 20px;
  overflow: hidden;
  align-items: center;
}

a.tst-tag,
button.tst-tag {
  display: inline-flex;
  align-items: center;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1.5px solid #D7DDE2;
  font-size: 13px;
  font-weight: 600;
  color: #1F2937;
  line-height: 1;
  white-space: nowrap;
  font-family: Inter, sans-serif;
  text-decoration: none;
  background: #fff;
  cursor: pointer;
  flex-shrink: 0;
  transition: background .15s, border-color .15s, color .15s;
}
a.tst-tag:hover,
button.tst-tag:hover {
  background: #f0f5f2;
  border-color: #45bc60;
  color: #2e8a47;
}

/* Кнопка "···" */
.tst-more-wrap {
  flex-shrink: 0;
}
button.tst-tag-more {
  letter-spacing: 2px;
  padding: 7px 10px;
}

/* Дропдаун вынесен в body через JS — position: fixed */
.tst-tag-dropdown {
  display: none;
  position: fixed;
  background: #fff;
  border: 1px solid #D7DDE2;
  border-radius: 12px;
  padding: 8px;
  box-shadow: 0 6px 20px rgba(0,0,0,.12);
  z-index: 9999;
  flex-direction: column;
  gap: 6px;
  max-width: calc(100vw - 16px);
}
.tst-tag-dropdown.tst-open {
  display: flex;
}
.tst-tag-dropdown a.tst-tag {
  justify-content: flex-start;
}

.tst-pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2px;
  margin-top: 32px;
  justify-content: center;
}
.tst-page-item {
  min-width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  color: #858C97;
  font-family: Inter, sans-serif;
  text-decoration: none;
  padding: 0 4px;
  transition: background .15s, color .15s;
}
.tst-page-item:hover {
  background: #f0f2f5;
  color: #1F2937;
}
.tst-page-item.active {
  color: #1F2937;
  font-weight: 700;
}
.tst-page-item.dots {
  color: #B4BBC3;
  cursor: default;
  pointer-events: none;
}