/* News cards: home page section and the /news listing. */
.pa-news {
  max-width: 1180px;
  margin: 3rem auto;
  padding: 0 1rem;
  color: #16181d;
}
.pa-news__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid #d9dbe0;
  margin-bottom: 1.75rem;
}
.pa-news__heading,
.pa-news__title {
  margin: 0;
  font-size: clamp(1.5rem, 3vw, 2rem);
  line-height: 1.15;
  color: #112244;
}
.pa-news .pa-news__all,
#main .pa-news .pa-news__all {
  font-weight: 700;
  color: #0d4f8b;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.pa-news .pa-news__all:hover,
.pa-news .pa-news__all:focus {
  color: #990000;
}
.pa-news .pa-news__all:focus-visible,
.pa-news .pa-news-card__link:focus-visible {
  outline: 3px solid #f0c040;
  outline-offset: 2px;
}
.pa-news__count {
  margin: 0 0 1.5rem;
  color: #4a515c;
}

.pa-news__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.75rem;
}
@media (max-width: 900px) {
  .pa-news__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  .pa-news__grid { grid-template-columns: 1fr; }
}

.pa-news-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid #e2e4e8;
  border-radius: 4px;
  overflow: hidden;
  transition: box-shadow 0.15s ease, transform 0.15s ease;
}
.pa-news-card:hover,
.pa-news-card:focus-within {
  box-shadow: 0 10px 24px rgba(16, 24, 40, 0.12);
  transform: translateY(-2px);
}
.pa-news-card__media {
  aspect-ratio: 16 / 9;
  background: #d9dbe0;
  /* Belt and braces: a tall picture must crop, not stretch the box. */
  overflow: hidden;
}
/* The image field renders its own wrappers inside the card's media box; they
   have to fill it or the pictures keep their natural height and the cards in a
   row stop lining up. */
.pa-news-card__media > div,
.pa-news-card__media .field,
.pa-news-card__media .field__item,
.pa-news-card__media picture {
  display: block;
  width: 100%;
  height: 100%;
}
.pa-news-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.pa-news-card__media--placeholder {
  background: linear-gradient(135deg, #112244, #24507a);
}
.pa-news-card__body {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  align-items: flex-start;
  padding: 1.15rem 1.25rem 1.35rem;
}
.pa-news-card__date {
  margin: 0 0 0.5rem;
  color: #4a515c;
  font-size: 0.9rem;
}
.pa-news-card__title {
  margin: 0 0 0.6rem;
  font-size: 1.15rem;
  line-height: 1.3;
  color: #112244;
}
.pa-news-card__summary {
  margin: 0 0 1rem;
  color: #3f4652;
  font-size: 0.95rem;
  line-height: 1.5;
}
.pa-news .pa-news-card__link,
#main .pa-news .pa-news-card__link {
  /* Pinned to the bottom so the links line up across a row of cards. */
  margin-top: auto;
  font-weight: 700;
  color: #0d4f8b;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.pa-news .pa-news-card__link:hover,
.pa-news .pa-news-card__link:focus {
  color: #990000;
}

/* Pager on /news. */
.pa-news .pager__items {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  list-style: none;
  margin: 2rem 0 0;
  padding: 0;
}
.pa-news .pager__item a,
#main .pa-news .pager__item a {
  display: inline-block;
  padding: 0.5rem 0.85rem;
  border: 1px solid #d9dbe0;
  border-radius: 4px;
  background: #fff;
  color: #16181d !important;
  text-decoration: none;
  font-weight: 600;
}
.pa-news .pager__item a:hover,
#main .pa-news .pager__item a:hover {
  background: #112244;
  color: #fff !important;
  border-color: #112244;
}
.pa-news .pager__item.is-active a,
#main .pa-news .pager__item.is-active a {
  background: #112244;
  color: #fff !important;
  border-color: #112244;
}
