/* Articles archive and single article layouts. */
.articles-archive__hero {
  padding-bottom: 28px;
}

.articles-archive__intro {
  padding: 0 0 36px;
  background: #fff;
}

.articles-archive__intro p {
  max-width: 900px;
  margin: 0;
  color: #333;
  font-size: 17px;
  line-height: 1.65;
}

.articles-archive__content {
  padding: 48px 0 90px;
  background: #f5f6fa;
}

/* Keep article pagination independent of the parent theme's .articles-pagination rule. */
.ehs-articles-pagination {
  position: static !important;
  left: auto !important;
  bottom: auto !important;
  transform: none !important;
  display: flex;
  justify-content: center;
  clear: both;
  width: 100%;
}

.ehs-articles-pagination .pagination-list {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.articles-grid,
.articles-related-grid {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  row-gap: 48px;
}

.articles-grid .news-card,
.articles-grid .news-card:nth-child(-n + 2),
.articles-related-grid .news-card,
.articles-related-grid .news-card:nth-child(-n + 2) {
  grid-column: span 2;
}

.articles-grid .news-card__link,
.articles-related-grid .news-card__link {
  display: flex;
  flex-direction: column;
}

.articles-grid .news-card__media,
.articles-related-grid .news-card__media {
  aspect-ratio: 540 / 290;
}

.articles-grid .news-card__body,
.articles-related-grid .news-card__body {
  flex: 1 1 auto;
}

.articles-grid .news-card__title,
.articles-grid .news-card:nth-child(-n + 2) .news-card__title {
  font-size: 21px;
}

.article-single__top {
  padding: 26px 0 90px;
}

.article-single__top > .container > .ehs-breadcrumbs {
  margin-bottom: 28px;
}

.article-single__grid {
  align-items: start;
}

.article-single__body h1 {
  margin-bottom: 16px;
}

.article-single__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin-bottom: 28px;
  color: #59636f;
  font-size: 14px;
  line-height: 1.5;
}

.article-single__topic {
  color: #1f355f;
  font-weight: 700;
}

.article-single__cover {
  margin: 0 0 28px;
}

.article-single__cover img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.article-single__content {
  margin-bottom: 38px;
}

.article-single__sidebar .project-cost {
  width: 100%;
}

.ehs-article-services {
  padding: 30px 0 0;
  background: transparent;
}

.ehs-article-services .ehs-related__head {
  margin-bottom: 18px;
}

.ehs-article-services .ehs-related__title,
.articles-author h2,
.articles-related h2 {
  font-size: 25px;
}

.ehs-article-services .ehs-related__grid--services {
  grid-template-columns: 1fr;
  gap: 14px;
}

.ehs-article-services .ehs-related-service {
  min-height: 110px;
}

.articles-author {
  margin-top: 36px;
  padding: 24px;
  border: 1px solid #e3e7ed;
  border-radius: 8px;
  background: #f8f9fb;
}

.articles-author h2,
.articles-related h2 {
  margin: 0 0 18px;
  color: #151d25;
  font-weight: 700;
  line-height: 1.25;
}

.articles-author__content {
  display: flex;
  align-items: center;
  gap: 18px;
}

.articles-author__photo {
  width: 76px;
  height: 76px;
  flex: 0 0 76px;
  border-radius: 50%;
  object-fit: cover;
}

.articles-author__name,
.articles-author__role {
  margin: 0;
}

.articles-author__name {
  color: #151d25;
  font-size: 18px;
  font-weight: 700;
}

.articles-author__name a {
  color: inherit;
  text-decoration: none;
}

.articles-author__role {
  margin-top: 5px;
  color: #63727c;
  font-size: 14px;
}

.articles-related {
  margin-top: 70px;
}

.articles-related-grid .news-card__title {
  font-size: 18px;
}

.articles-related-grid .news-card:nth-child(-n + 2) .news-card__title {
  font-size: 18px;
}

@media (max-width: 767px) {
  .articles-archive__hero {
    padding: 28px 0 28px;
  }

  .articles-archive__intro {
    padding-bottom: 26px;
  }

  .articles-archive__intro p {
    font-size: 15px;
  }

  .articles-archive__content {
    padding: 35px 0 65px;
  }

  .articles-grid,
  .articles-related-grid {
    row-gap: 34px;
  }

  .articles-grid .news-card,
  .articles-grid .news-card:nth-child(-n + 2),
  .articles-related-grid .news-card,
  .articles-related-grid .news-card:nth-child(-n + 2) {
    grid-column: 1 / -1;
  }

  .article-single__top {
    padding: 22px 0 60px;
  }

  .article-single__top > .container > .ehs-breadcrumbs {
    margin-bottom: 20px;
  }

  .article-single__grid {
    display: block;
  }

  .article-single__sidebar {
    margin-top: 35px;
  }

  .article-single__meta {
    gap: 6px 12px;
    margin-bottom: 20px;
    font-size: 13px;
  }

  .article-single__cover img {
    aspect-ratio: 4 / 3;
  }

  .articles-author {
    padding: 18px;
  }

  .articles-related {
    margin-top: 48px;
  }
}

/* Keep the related service tiles compact inside the article's left column. */
.article-single .ehs-article-services {
  padding: 30px 0 0;
  background: transparent;
}

.article-single .ehs-article-services .ehs-related__head {
  margin-bottom: 18px;
}

.article-single .ehs-article-services .ehs-related__grid--services {
  grid-template-columns: 1fr;
  gap: 14px;
}
