/* articles.css */

body {
  margin: 0;
  padding-top: 100px;
  padding-bottom: 120px;
  font-family: 'Arial', sans-serif;
  background: #0d0d0d;
  color: #f2f2f2;
  line-height: 1.6;
  box-sizing: border-box;
  position: relative;
}

.articles-page {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 20px;
}

.articles-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  padding: 20px 0;
}

.article-card {
  background: #111;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 0 12px #4A90E2aa;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
  display: flex;
  flex-direction: column;
}

.article-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 0 18px #4A90E2;
}

.article-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

.article-content {
  padding: 16px;
}

.article-content h2 {
  margin-top: 0;
  color: #4A90E2;
  font-size: 1.3rem;
}

.article-content .date {
  font-size: 0.8rem;
  color: #888;
}

.article-content p {
  font-size: 0.9rem;
}

.article-link {
  display: inline-block;
  margin-top: 10px;
  color: #4A90E2;
  font-weight: bold;
  text-decoration: underline;
}

/* Article individuel */
.single-article {
  padding: 20px;
  background: #111;
  border-radius: 10px;
  box-shadow: 0 0 15px #4A90E2aa;
}

.single-article h1 {
  font-size: 2rem;
  margin-bottom: 10px;
  color: #4A90E2;
}

.single-article .date {
  font-size: 0.9rem;
  color: #888;
  margin-bottom: 20px;
}

.article-image img {
  width: 100%;
  max-height: 400px;
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 20px;
}

.article-contenu {
  font-size: 1rem;
  white-space: pre-wrap;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  body {
    padding-top: 90px;
    padding-bottom: 110px;
  }

  .article-content h2 {
    font-size: 1.1rem;
  }

  .article-contenu {
    font-size: 0.95rem;
  }

  .single-article h1 {
    font-size: 1.6rem;
  }
}

@media (max-width: 480px) {
  .article-card img {
    height: 150px;
  }
  .article-content p,
  .article-contenu {
    font-size: 0.85rem;
  }
  .article-content h2 {
    font-size: 1rem;
  }
  .single-article h1 {
    font-size: 1.3rem;
  }
}

/* SEO optimisations (visibles pour screen readers & robots) */
article, section {
  display: block;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}
