/* Astra's existing recommendations, scoped to the end of single posts. */
body.single-post .ast-single-related-posts-container .ast-related-posts-wrapper {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(5px, 1.15vw, 12px);
  align-items: stretch;
}
html.ulu-phone body.single-post .ast-single-related-posts-container .ast-related-posts-wrapper {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (max-width: 599px) {
  html:not(.ulu-tablet-home) body.single-post .ast-single-related-posts-container .ast-related-posts-wrapper {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
body.single-post .ast-related-posts-wrapper > .ast-related-post {
  box-sizing: border-box;
  min-width: 0;
  width: 100%;
  padding: 0;
  margin: 0;
  border: 1px solid #e4e4e4;
  border-radius: 7px;
  background: #f7f7f7;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .13);
}
body.single-post .ast-related-posts-wrapper .ast-related-posts-inner-section {
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
  height: 100%;
  padding: 0;
  margin: 0;
}
body.single-post .ast-related-posts-wrapper .ast-related-post-content {
  display: flex;
  flex-direction: column;
  flex: 1;
  height: auto;
  padding: 0;
  margin: 0;
  gap: 0;
}
body.single-post .ast-related-posts-wrapper .ast-related-post-featured-section {
  margin: 0;
}
body.single-post .ast-related-posts-wrapper .post-thumb-img-content > a {
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: #eee;
}
body.single-post .ast-related-posts-wrapper .post-thumb-img-content > a > img {
  display: block;
  width: 100%;
  height: 100%;
  aspect-ratio: auto;
  object-fit: cover;
  margin: 0;
}
body.single-post .ast-related-posts-wrapper .related-entry-header {
  box-sizing: border-box;
  flex: 1;
  display: grid;
  place-items: center;
  min-width: 0;
  min-height: 4em;
  width: 100%;
  padding: 6px 4px;
  margin: 0 !important;
  background: #f7f7f7;
  text-align: center;
}
body.single-post .ast-related-posts-wrapper .ast-related-post-title,
body.single-post .ast-related-posts-wrapper .ast-related-post-title a {
  margin: 0;
  color: #262626;
  font-size: clamp(12px, calc(9.5px + .55vw), 15px);
  line-height: 1.27;
  font-weight: 600;
  text-align: center;
  overflow-wrap: anywhere;
}
body.single-post .ast-related-posts-wrapper .ast-related-post-title a:hover {
  text-decoration: underline;
  text-underline-offset: 2px;
}
body.single-post .ast-related-posts-wrapper .ast-related-post a:focus-visible {
  outline: 2px solid #d96a6a;
  outline-offset: -2px;
}
body.single-post .ast-related-posts-wrapper .related-entry-header .entry-meta:empty,
body.single-post .ast-related-posts-wrapper .ast-related-post-content > .entry-content:not(:has(*)) {
  display: none;
}

/* Tablet: occupy the article column, including the theme's inner gutters. */
html.ulu-tablet-home body.single-post #primary #main {
  container-type: inline-size;
}
html.ulu-tablet-home body.single-post #primary #main .ast-article-single .ast-single-related-posts-container {
  box-sizing: border-box;
  width: 100cqw;
  max-width: none;
  margin-inline: calc((100% - 100cqw) / 2);
  padding-inline: 0;
}
