/* =========================================
   CONTAINER DO CARROSSEL
   ========================================= */
.carousel-container {
  display: flex;
  flex-wrap: wrap;
  gap: 25px;
  padding: 10px;
  margin-bottom: 20px;
  height: auto;

  scroll-snap-type: x mandatory;
  overflow-x: auto;
}

/* =========================================
   CARD (DESIGN SÓBRIO)
   ========================================= */
div.gallery-item {
  flex: 0 0 auto;
  width: 260px; /* Largura fixa */
  display: flex;
  flex-direction: column;

  background-color: var(--bg-card);
  border: 1px solid var(--card-border);
  border-radius: 12px;

  overflow: hidden;
  scroll-snap-align: start;
  position: relative;

  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

div.gallery-item:hover {
  border-color: var(--secondary);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  cursor: pointer;
}

/* Link cobre tudo e organiza as caixas internas */
div.gallery-item a.card-link-wrapper {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  height: 100%;
}

/* =========================================
   A CAIXA DA IMAGEM (Corrige o esticamento)
   ========================================= */
.card-image-box {
  width: 100%;
  height: 180px; /* Altura travada */
  border-bottom: 1px solid var(--card-border);
  background-color: #000;
  flex-shrink: 0; /* Impede que a imagem encolha ou estique */
}

.card-image-box img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Corta o excesso sem distorcer */
  display: block;
}

/* =========================================
   A CAIXA DO CONTEÚDO (Texto embaixo)
   ========================================= */
.card-content {
  padding: 15px 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background-color: var(--bg-card);
}

.card-content h3.desc {
  font-family: "Oswald", sans-serif;
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--text-color);
  margin-bottom: 10px;
  line-height: 1.3;

  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.read-more {
  font-family: "Poppins", sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--primary);
  margin-top: auto;
  display: block;
}

/* =========================================
   GRID DE NOTÍCIAS/MISSIONÁRIOS (Página Específica)
   ========================================= */
.news-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  justify-content: start;
  padding: 40px 20px;
}

.news-grid .gallery-item {
  width: 280px;
}

/* Ajuste Mobile */
@media (max-width: 768px) {
  .carousel-container {
    flex-wrap: nowrap;
    justify-content: flex-start;
  }

  div.gallery-item {
    width: 240px;
  }

  .news-grid {
    justify-content: center;
  }
}

.short-desc {
  font-family: "Poppins", sans-serif;
  font-size: 0.85rem;
  color: var(--text-color);
  opacity: 0.8;
  margin-bottom: 15px;
  line-height: 1.5;

  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
