/* ==========================
   Подключаем шрифт Poppins
========================== */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600&display=swap');

/* ==========================
   Общие стили страницы
========================== */
body {
  font-family: 'Poppins', sans-serif;
  color: #222;
  margin: 0;
  padding: 0;
  background-color: #fff;
}

/* ==========================
   Секция со статьями
========================== */
.articles-page {
  padding: 80px 0;
  background-color: #fff;
}

/* Заголовок раздела */
.articles-page .section-title {
  text-align: center;
  font-size: 32px;
  font-weight: 600;
  margin-bottom: 50px;
  color: #0b0b0b;
}

/* ==========================
   Сетка карточек
========================== */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 40px; /* ↑ расстояние между карточками */
  padding: 0 40px;
}

/* Добавляем вертикальный зазор между карточками */
.article-card {
  margin-bottom: 40px; /* расстояние между прямоугольниками */
}

/* ==========================
   Карточка статьи
========================== */
.article-card {
  display: flex;
  flex-direction: row;
  border: 1px solid rgba(102, 209, 233, 0.75); /* корпоративный голубой бордер */
  border-radius: 6px;
  background: #ffffff;
  overflow: hidden;
  transition: box-shadow 0.2s ease;
}

.article-card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* ==========================
   Изображение слева
========================== */
.article-card img {
  width: 350px !important;
  height: 197px !important;
  object-fit: cover;
  flex-shrink: 0;
}

/* ==========================
   Контент карточки
========================== */
.article-content {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Заголовок статьи */
.article-content h3 {
  margin: 0 0 10px;
  font-size: 20px;
  font-weight: 600;
  color: #005385;
}

/* ==========================
   Дата публикации
========================== */
.article-date {
  font-size: 14px !important; /* ↓ принудительно меньше */
  color: #666;
  font-style: normal;
  margin-bottom: 10px;
  line-height: 1.2;
}

/* ==========================
   Текст статьи (тизер)
========================== */
.article-content p {
  font-size: 17px;
  color: #333;
  margin: 0 0 15px;
  line-height: 1.5;
}

/* ==========================
   Ключевые слова
========================== */
.article-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.article-tags span,
.article-tags a,
.article-tags a:visited {
  font-size: 13px;
  font-weight: 500;
  color: #005385;
  font-style: normal;
  text-decoration: none;
}

.article-tags a:hover {
  text-decoration: underline;
}

/* ==========================
   Ссылки в карточках
========================== */
.article-content a,
.article-content a:visited {
  color: #005385;
  text-decoration: none;
}

.article-content a:hover {
  color: #005385;
  text-decoration: underline;
}

/* ==========================
   Адаптив для мобильных
========================== */
@media (max-width: 900px) {
  .articles-page {
    padding: 50px 0;
  }

  .articles-list {
    padding: 0 16px;
  }

  .article-card {
    flex-direction: column;      /* картинка сверху, контент снизу */
    height: auto;
    border-radius: 6px;
    overflow: hidden;
  }

  .article-card img {
    width: 100% !important;
    height: auto !important;
    object-fit: cover;
    border-bottom: 1px solid rgba(102, 209, 233, 0.3);
  }

  .article-content {
    padding: 18px 16px 20px;
    text-align: left;
  }

  .article-content h3 {
    font-size: 18px;
    margin-bottom: 8px;
  }

  .article-date {
    font-size: 13px;
    margin-bottom: 8px;
  }

  .article-content p {
    font-size: 15px;
    line-height: 1.5;
    margin-bottom: 10px;
  }

  .article-tags {
    margin-top: 6px;
    gap: 6px;
  }

  .article-tags span {
    font-size: 12px;
  }
}