/* =========================================================
   Articles Page
========================================================= */

.articles-page {
  width: 100%;
  background: #f7f7f2;
  padding: 14px 12px 42px;
  color: #333333;
}

.articles-featured {
  display: flex;
  flex-direction: row;
  gap: 10px;
  margin-bottom: 14px;
}

.articles-main-featured {
  width: 54%;
  height: 210px;
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  display: block;
}

.articles-main-featured img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.articles-main-featured::after,
.articles-small-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.52), rgba(0, 0, 0, 0.05));
  z-index: 1;
}

.articles-main-featured h1 {
  position: absolute;
  right: 22px;
  bottom: 22px;
  z-index: 2;
  color: #ffffff;
  font-size: 28px;
  font-weight: 800;
  line-height: 1.6;
}

.articles-small-grid {
  width: 46%;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.articles-small-card {
  width: calc(50% - 4px);
  height: 101px;
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  display: block;
}

.articles-small-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.articles-small-card h3 {
  position: absolute;
  right: 8px;
  left: 8px;
  bottom: 7px;
  z-index: 2;
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.5;
  text-align: right;
}

/* ================= Articles List ================= */

.articles-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.article-row-card {
  display: flex;
  flex-direction: row;
  gap: 20px;
  background: #d8d8d8;
  border-radius: 8px;
  padding: 8px;
  min-height: 135px;
}

.article-row-image {
  width: 195px;
  height: 120px;
  flex: 0 0 195px;
  border-radius: 7px;
  overflow: hidden;
  order: 1;
}

.article-row-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.article-row-content {
  flex: 1;
  text-align: right;
  padding: 8px 8px 4px 0;
  order: 2;
}

.article-row-content h2 {
  font-size: 17px;
  font-weight: 800;
  line-height: 1.8;
  color: #333333;
  margin-bottom: 5px;
}

.article-row-content p {
  font-size: 13px;
  line-height: 2;
  color: #333333;
}

/* ================= Pagination ================= */

.articles-pagination {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  direction: rtl;
  margin: 42px 0 100px;
}

.articles-pagination a {
  min-width: 40px;
  height: 30px;
  border: 1px solid #9bb8a9;
  border-left: 0;
  color: #005331;
  background: #f7f7f2;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.articles-pagination a:first-child {
  border-left: 1px solid #9bb8a9;
}

.articles-pagination a.active {
  background: #005331;
  color: #ffffff;
}

/* ================= Follow Section ================= */

.articles-follow-section {
  padding: 0 18px 18px;
  text-align: center;
}

.articles-follow-section h2 {
  color: #333333;
  font-size: 28px;
  font-weight: 800;
  margin-bottom: 24px;
}

.articles-social-list {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 32px;
  flex-wrap: wrap;
}

.articles-social-list a {
  color: #555555;
  font-size: 34px;
  transition: 0.2s ease;
}

.articles-social-list a:hover {
  color: #005331;
}

/* ================= Responsive Articles Page ================= */

@media (max-width: 1024px) {
  .articles-page {
    padding: 12px 10px 38px;
  }

  .articles-main-featured {
    height: 190px;
  }

  .articles-main-featured h1 {
    font-size: 24px;
  }

  .articles-small-card {
    height: 91px;
  }

  .article-row-image {
    width: 175px;
    flex-basis: 175px;
  }

  .article-row-content h2 {
    font-size: 16px;
  }

  .article-row-content p {
    font-size: 12px;
  }
}

@media (max-width: 768px) {
  .articles-featured {
    flex-direction: column;
  }

  .articles-main-featured,
  .articles-small-grid {
    width: 100%;
  }

  .articles-main-featured {
    height: 230px;
  }

  .articles-small-card {
    height: 115px;
  }

  .article-row-card {
    gap: 12px;
  }

  .article-row-image {
    width: 145px;
    height: 105px;
    flex-basis: 145px;
  }

  .article-row-content {
    padding-top: 2px;
  }

  .article-row-content h2 {
    font-size: 14px;
    margin-bottom: 3px;
  }

  .article-row-content p {
    font-size: 11px;
    line-height: 1.9;
  }

  .articles-pagination {
    justify-content: center;
    flex-wrap: wrap;
    margin: 34px 0 70px;
  }

  .articles-follow-section h2 {
    font-size: 22px;
  }

  .articles-social-list {
    gap: 22px;
  }

  .articles-social-list a {
    font-size: 28px;
  }
}

@media (max-width: 520px) {
  .articles-page {
    padding: 10px 8px 34px;
  }

  .articles-main-featured {
    height: 210px;
  }

  .articles-main-featured h1 {
    font-size: 21px;
    right: 16px;
    bottom: 16px;
  }

  .articles-small-grid {
    gap: 6px;
  }

  .articles-small-card {
    width: calc(50% - 3px);
    height: 95px;
  }

  .articles-small-card h3 {
    font-size: 11px;
  }

  .article-row-card {
    flex-direction: column;
    padding: 8px;
  }

  .article-row-image {
    width: 100%;
    height: 185px;
    flex-basis: auto;
  }

  .article-row-content {
    width: 100%;
    padding: 4px 2px;
  }

  .article-row-content h2 {
    font-size: 15px;
  }

  .article-row-content p {
    font-size: 12px;
  }

  .articles-pagination a {
    min-width: 34px;
    height: 30px;
    font-size: 11px;
  }
}
