

/* Mise en page responsive */
.news-section {
  font-size: 0.94em;           /* 15px de base */
  line-height: 1.6;
  font-family: 'Noto Sans Display', sans-serif;
  color: #00507D;
  max-width: 1200px;
  margin: 0 auto 20px auto;
  padding: 1rem;
}
.news-section h2 {
	
  text-align: center;
  margin-bottom: 1.5rem;
  font-size: 1.25rem;
}
.cards-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1rem;
}

/* Style de base de la carte */
.card {
	font-size: 62.5%; /* 1rem = 10px */
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  text-decoration: none;
  font-family: inherit;
  color: inherit;
  /* Ombre très subtile par défaut */
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  opacity: 0;                  /* pour l'animation fadeInUp */
  transform: translateY(20px);
}

/* Conteneur image */
.card-image {
  overflow: hidden;
  height: 0;
  padding-top: 56.25%; /* ratio 16:9 */
  position: relative;
}
.card-image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

/* Contenu texte */
.card-content {
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  font-family: inherit;
}
.card-content time {
  font-size: 0.9rem;
  color: #666;
}
.card-title {
  margin: 0.5rem 0;
  font-size: 1rem;
  line-height: 1.5;
  color: #00507D;
  font-family: inherit;
}

/* Nom de la source (badge) */
.card-source {
  display: inline-block;
  font-size: 0.87rem;
  padding: 0.2rem 0.6rem;
  background-color: rgba(255, 106, 0, 0.4); /* orange adouci */
  color: #ffffff;                          /* texte toujours opaque */
  opacity: 2;                              /* forcer pleine opacité du texte */
  border-radius: 9999px;
  margin-top: auto;
  font-family: inherit;
  text-decoration: none;
}
.card-source:hover {
  display: inline-block;
  font-size: 0.87rem;
  padding: 0.2rem 0.6rem;
  background-color: rgba(255, 106, 0, 0.8); /* orange plus foncé */
  color: #ffffff;                          /* texte toujours opaque */
  opacity: 2;                              /* forcer pleine opacité du texte */
  border-radius: 9999px;
  margin-top: auto;
  font-family: inherit;
  text-decoration: none;
}
/* Animation d'apparition */
@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.fade-in-up {
  animation: fadeInUp 0.6s ease forwards;
}

/* Hover sur desktop */
@media (hover: hover) {
  .card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 24px rgba(0, 80, 125, 0.2);
  }
  .card:hover .card-image img {
    transform: scale(1.1);
  }
}

/* Touch sur mobile/tablette */
@media (hover: none) {
  .card:active,
  .card.is-hovered {
    transform: translateY(-8px);
    box-shadow: 0 8px 24px rgba(0, 80, 125, 0.2);
  }
  .card:active .card-image img,
  .card.is-hovered .card-image img {
    transform: scale(1.2);
  }
}
