/* ===================================
   BLOG - INDEX ET ARTICLES
   (styles partages avec l'index des categories /categorie)
   ================================== */

.blog-page {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* Intro editoriale de l'index (page CMS /blog) */
.blog-intro {
  max-width: none;
}

/* Liste des articles : un article par ligne, image a gauche */
.blog-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.blog-card {
  display: flex;
  background: var(--card);
  border-radius: 16px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.blog-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* L'image remplit sa colonne en absolu : c'est le texte qui dicte
   la hauteur de la ligne, pas les proportions de la photo */
.blog-card-image {
  display: block;
  position: relative;
  flex: 0 0 280px;
  min-height: 190px;
}

.blog-card-image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.blog-card-content {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 10px;
  padding: 20px 24px;
  min-width: 0;
}

.blog-card-title {
  font-size: 20px;
  margin: 0;
}

.blog-card-title a {
  color: var(--text-dark);
  text-decoration: none;
}

.blog-card-title a:hover {
  text-decoration: underline;
}

.blog-card-excerpt {
  flex: 1;
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.blog-card-link {
  font-weight: 600;
  color: var(--text-dark);
  text-decoration: none;
}

.blog-card-link:hover {
  text-decoration: underline;
}

.blog-empty {
  text-align: center;
}

/* Article */
.blog-article-date {
  font-size: 14px;
  margin-bottom: 24px;
}

.blog-article-image img {
  display: block;
  width: 100%;
  max-height: 380px;
  object-fit: cover;
  border-radius: 12px;
  margin-bottom: 24px;
}

.blog-back {
  margin-top: 32px;
}

/* Bloc « A lire aussi » */
.blog-read-also {
  background: var(--card);
  border-radius: 16px;
  padding: 24px 32px;
  box-shadow: var(--shadow-sm);
  max-width: 900px;
  margin: 0 auto;
  width: 100%;
}

.blog-read-also h2 {
  font-size: 20px;
  margin-bottom: 12px;
  color: var(--text-dark);
}

.blog-read-also ul {
  padding-left: 20px;
}

.blog-read-also li {
  line-height: 1.8;
}

/* Responsive */
@media (max-width: 680px) {
  /* Mobile : l'image repasse au-dessus du texte */
  .blog-card {
    flex-direction: column;
  }

  .blog-card-image {
    flex: none;
    min-height: 0;
    height: 180px;
  }

  .blog-read-also {
    padding: 20px;
  }
}
