.cards-grid-3 {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.5rem;
  padding: 1rem;
}

.cards-row-3 {
  flex: 1 1 calc(33.333% - 1.5rem);
  max-width: calc(33.333% - 1.5rem);
  box-sizing: border-box;
  background-color: #f7f7f7;
  border-radius: 30px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.cards-row-3__body {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-align: justify;
}

.cards-row-3__image img {
  border-radius: 20px;
  width: 100%;
  height: auto;
}

.cards-row-3__title {
  font-size: 1.2rem;
  font-weight: bold;
  margin: 0;
}

.cards-row-3__description {
  font-size: 0.95rem;
  line-height: 1.4;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 6;
  -webkit-box-orient: vertical;
}

.cards-row-3__link {
  margin-top: 20px;
}

.cards-row-3__link a {
  display: inline-block;
  background: linear-gradient(90deg, #ffce00, #ffb000);
  color: #ffffff;
  font-weight: bold;
  text-align: center;
  padding: 9px 20px;
  border-radius: 45px;
  text-decoration: none;
}
@media (max-width: 768px) {
  .cards-row-3 {
    flex: 1 1 100%;
    max-width: 100%;
  }
}

@media (min-width: 1024px) {
  .cards-grid-3:has(> .cards-row-3:nth-child(4):last-child):not(:has(> .cards-row-3:nth-child(5))) .cards-row-3 {
    flex: 1 1 calc(25% - 1.5rem);
    max-width: calc(25% - 1.5rem);
  }
}