@import "../../../../assets/scss/variables";
@import "../../../../assets/scss/mixins";

.ftm-latest-posts {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-content: flex-start;
  justify-content: center;
  align-items: flex-start;
  column-gap: 13px;

  &.narrow {
    &.vertical {
      > article {
        max-width: 100%;
      }
    }
    &.horizontal {
      > article {
        max-width: 32%;
        padding-left: 20px;
        padding-right: 20px;
      }
    }
  }

  > div.ftm--list-posts-title {
    width: 100%;
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    background: unset;
    font-weight: bold;
    font-size: var(--ftm_h2_font_size_setting);
  }

  > h2 {
    width: 100%;
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    background: unset;
  }

  > article {
    width: 100%;
    max-width: 366px;
    margin-bottom: 20px;

    > .post-thumbnail {
      display: block;
      width: 100%;

      > a {
        > img {
          width: 100%;
          height: 100%;
          object-fit: cover;
          max-height: 234px;
        }
      }
    }

    > h4,
    div.ftm--list-post-title {
      font-size: 1.25rem;
      color: #27292e;
      margin: unset;

      > a {
        color: inherit;
        text-decoration: none;
        font-size: 1.25rem;
        transition: color 0.3s ease-in-out, opacity 0.3s ease-in-out,
          background-color 0.3s ease-in-out;

        &:hover {
          color: #ff7917;
        }
      }
    }

    .post_excerpt {
      color: #27292e;
    }

    .post_meta {
      letter-spacing: 0.2px;
      margin-top: auto;
      font-size: 0.875rem;
      color: #ff7917;

      > span {
        color: #27292e;
      }
    }
  }
}
