/*-------------------------------------------------------*/
/* Blog
/*-------------------------------------------------------*/
.entry {
  overflow: hidden;
  position: relative;
  margin-bottom: 60px;
  word-wrap: break-word;

  &--no-content {
    padding-bottom: 0;
    margin-bottom: 0;
    border-bottom: 0;
  }

  &__img-holder {
    overflow: hidden;
    position: relative;

    & + .entry__body {
      padding-top: 24px;
    }

    &:hover {
      img {
        @include transform(scale(1.1));
      }
    }
  }

  &__img {
    width: 100%;
    @include transition(transform 0.4s cubic-bezier(0.05, 0.2, 0.1, 1) !important);
  }

  &__title {
    font-size: 1.625rem;
    margin-bottom: 20px;
    position: relative;

    &--small {
      font-size: 1.375rem;
    }
  }

  &__excerpt {
    p {
      margin-bottom: 0;
    }
  }
}

/*-------------------------------------------------------*/
/* Post List
/*-------------------------------------------------------*/
.post-list {
  .entry {
    display: flex;
  }

  &.masonry-item .entry .entry__img-holder {
    margin-right: 40px;
  }

  .entry__img-holder {
    flex: 0 0 120px;

    @include bp-xl-up {
      flex: 0 0 180px;
    }
  }

  @include bp-sm-down {
    &.masonry-item .entry .entry__img-holder {
      flex: 0 0 60px;
      margin-right: 20px;
    }
  }

  .entry__body {
    flex: 1 0 0;
    padding-top: 0;
  }
}

/*-------------------------------------------------------*/
/* Post Cards
/*-------------------------------------------------------*/
.post-cards {
  .entry__title {
    font-size: 1.3125rem;
  }
}

/*-------------------------------------------------------*/
/* Isotope Filter
/*-------------------------------------------------------*/
.isotope-filter {
  margin-bottom: 48px;

  a {
    display: inline-block;
    position: relative;
    padding: 4px 12px;
    border-radius: 3px;
    margin-right: 2px;
    margin-bottom: 8px;
    font-size: 1rem;
    font-weight: 500;
    color: $meta-color;

    &.active,
    &:hover,
    &:focus {
      background-color: var(--dinery-main-color);
      color: #fff;
    }

    &:last-child {
      margin-right: 0;
    }
  }
}

/*-------------------------------------------------------*/
/* Meta
/*-------------------------------------------------------*/
.entry__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 20px;

  &--top {
    margin-bottom: 8px;
  }

  &-item {
    font-family: $heading-font;
    display: inline-flex;
    flex-wrap: wrap;
    font-size: 1rem;
    color: $meta-color;

    &::after {
      content: "·";
      display: block;
      margin: 0 8px;
    }

    &:last-child::after {
      display: none;
    }

    a {
      color: $text-color;
    }
  }

  a {
    &:hover,
    &:focus {
      color: var(--dinery-main-color);
    }
  }

  &-date,
  &-comments {
    font-size: 0.875rem;
  }

  .entry__excerpt + & {
    padding-top: 12px;
    margin-top: 20px;
    margin-bottom: 0;
    border-top: 1px solid $border-color;
  }
}

// Categories
.entry__category {
  &-item {
    margin-left: 4px;
  }
}

// Author
.entry__meta-author {
  &-img {
    border-radius: 50% !important;
    margin-right: 8px;
  }

  &-url {
    display: flex;
    align-items: center;
  }
}

/*-------------------------------------------------------*/
/* Pagination
/*-------------------------------------------------------*/
.pagination {
  text-align: center;
  margin-top: 30px;
  margin-bottom: 24px;
}

.post-pagination {
  margin-top: 24px;
}

.page-numbers,
.post-page-numbers {
  font-size: 1.125rem;
  display: inline-block;
  padding: 0 6px;
  height: 24px;
  min-width: 24px;
  line-height: 24px;
  margin: 0 0 6px;
  text-align: center;
  color: $meta-color;
  vertical-align: middle;
  white-space: nowrap;
  list-style: none;

  &:not(span):hover {
    color: var(--dinery-main-color);
  }

  &.current {
    color: $heading-color;
  }

  i {
    font-size: 1rem;
    display: inline-block;

    .rtl & {
      transform: rotate(180deg);
    }
  }
}

/* Post Pagination
-------------------------------------------------------*/
.post-pagination {
  & > span:first-child {
    margin-right: 10px;
  }
}

/*-------------------------------------------------------*/
/* Single Post
/*-------------------------------------------------------*/
.fullwidth.single-post .blog__content {
  max-width: 820px;
}

/* Featured Image / Entry Header
-------------------------------------------------------*/
.single-post {
  &__entry-header {
    margin-bottom: 58px;

    .entry__meta-item::after {
      display: none;
    }

    .entry__category {
      margin-bottom: 20px;
      margin-right: 0;

      span {
        display: none;
      }
    }

    .entry__category-item {
      text-transform: uppercase;
      color: var(--dinery-main-color);
      position: relative;
      font-size: 0.875rem;
      margin-right: 14px;
      margin-left: 0;

      &::after {
        content: "";
        width: 0;
        height: 1px;
        display: block;
        background-color: var(--dinery-main-color);
        @include transition($all);
      }

      &:hover::after,
      &:focus::after {
        width: 100%;
      }
    }

    .entry__category-item:last-child {
      margin-right: 0;
    }

    .entry__meta-author,
    .entry__meta-date {
      display: block;
    }

    .entry__meta-author {
      text-transform: none;
      font-size: 1.125rem;
      color: $heading-color;
      line-height: 1.1;
      margin-right: 0;

      a {
        color: inherit;

        &:hover,
        &:focus {
          color: var(--dinery-main-color);
        }
      }
    }
  }

  &__featured-img {
    margin-bottom: 68px;
  }

  &__entry {
    overflow: visible;
    margin-bottom: 40px;
  }

  &__entry-title {
    word-wrap: break-word;
    line-height: 1.2;
    margin-bottom: 28px;

    @include bp-lg-up {
      font-size: 2.5rem;
    }

    @include bp-xl-up {
      font-size: 3rem;
    }
  }
}

.fullwidth {
  .single-post__entry-header {
    text-align: center;
  }

  .single-post__entry-meta {
    justify-content: center;
  }
}

@include bp-xl-up {
  .fullwidth {
    .single-post__entry-header,
    .single-post__featured-img {
      margin-left: -220px;
      margin-right: -220px;
    }
  }
}

/* Entry header author
-------------------------------------------------------*/
.single-post__entry-author {
  display: flex;
  flex-wrap: wrap;
  align-items: center;

  .fullwidth & {
    justify-content: center;
  }

  &-url {
    margin-right: 16px;
  }

  &-img {
    border-radius: 50%;
  }

  &-content {
    text-align: left;
  }
}

/* Single post article
-------------------------------------------------------*/
.entry__article {
  font-size: 1.375rem;
  line-height: 1.8;

  @include bp-lg-down {
    margin-top: 16px;
  }

  & > h1,
  & > h2,
  & > h3,
  & > h4,
  & > h5,
  & > h6 {
    margin-top: 36px;
    margin-bottom: 20px;
  }

  & > p,
  & > ul,
  & > ol {
    margin-bottom: 34px;
  }

  p a,
  li:not(.wp-social-link) a {
    color: $post-link-color;
    text-decoration: underline;

    &:hover {
      color: $heading-color;
    }
  }

  ol {
    padding-left: 26px;
  }

  ul {
    padding-left: 20px;
  }
}

/* Sidebar
/*-------------------------------------------------------*/
@include bp-lg-up {
  .sidebar:not(.elementor-column) {
    max-width: 25%;
    flex: 0 0 25%;
  }

  .left-sidebar {
    .content {
      order: 2;
      padding-left: 40px;
    }
  }

  .right-sidebar {
    .content {
      padding-right: 40px;
    }
  }
}

.elementor-widget-sidebar .widget-title,
.sidebar .widget-title {
  font-size: 1.3125rem;
}

/* Entry Share
-------------------------------------------------------*/
.entry__share {
  &-label {
    text-transform: uppercase;
    font-size: 0.8125rem;
    font-family: $heading-font;
    margin-right: 8px;
  }

  &-socials {
    display: inline-block;
  }

  @include bp-md-up {
    &--right {
      text-align: right;
    }
  }
}

/* Entry Tags
/*-------------------------------------------------------*/
.entry__tags {
  overflow: hidden;

  @include bp-md-down {
    margin-bottom: 18px;
  }
}

/* Author
/*-------------------------------------------------------*/
.entry-author {
  background-color: $bg-light;
  margin-top: 24px;
  margin-bottom: 48px;
  padding: 32px;

  &__url {
    display: inline-flex;
    float: left;
    align-items: center;
  }

  &__img {
    height: 64px;
    width: 64px;
    display: block;
    margin-right: 24px;
    border-radius: 50%;

    @include bp-sm-down {
      width: 50px;
      height: 50px;
    }
  }

  &__img-holder {
    display: block;
    float: left;

    @include bp-sm-down {
      float: none;
      margin-bottom: 24px;
    }
  }

  &__info {
    overflow: hidden;
  }

  &__name {
    display: inline-block;
    margin-bottom: 0;
    margin-right: 8px;
    font-size: 1.25rem;
  }

  &__description {
    margin-top: 10px;
    margin-bottom: 20px;
  }

  &__socials {
    display: flex;
  }
}

/* Related Posts
/*-------------------------------------------------------*/
.related-posts {
  margin-top: 60px;
  margin-bottom: 20px;

  &__entry {
    margin-bottom: 30px;
    padding-bottom: 0;
    border-bottom: 0;
  }

  &__title {
    padding-right: 80px;
  }

  &__entry-img-holder {
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 20px;
  }

  &__entry-title {
    font-size: 1.1875rem;
  }
}

/* Comments
/*-------------------------------------------------------*/
.entry__comments {
  margin-top: 30px;
}

.related-posts__title,
.entry-comments__title,
.comment-respond__title {
  font-size: 1.75rem;
  margin-bottom: 32px;
}

.comment-respond__title small {
  margin-left: 12px;
}

.comment-content {
  a {
    text-decoration: underline;
  }

  & > h1,
  & > h2,
  & > h3,
  & > h4,
  & > h5,
  & > h6 {
    margin-top: 36px;
    margin-bottom: 20px;
  }

  ol {
    padding-left: 26px;
  }

  ul {
    padding-left: 20px;
  }
}

.comment {
  &-list {
    padding-left: 0;
    margin-bottom: 48px;
  }

  &-list,
  &-list .children {
    list-style: none;
  }

  .children {
    padding-left: 30px;

    @include bp-md-down {
      padding-left: 20px;

      .children {
        padding-left: 0;
      }
    }
  }

  &-list > li:first-child > .comment-body {
    border-top: 0;
    padding-top: 0;
  }

  &-body {
    margin-bottom: 32px;
    padding-top: 32px;
    border-top: 1px solid $border-color;
  }

  &-text {
    overflow: hidden;

    p {
      margin-bottom: 10px;
    }
  }

  &-avatar {
    float: left;
    margin-right: 20px;
    display: block;
    border-radius: 50%;
    overflow: hidden;
  }

  &-author {
    font-size: 1rem;

    &__name {
      color: $heading-color;
      text-transform: uppercase;
      display: inline-block;
      font-size: 1rem;
    }

    &__post-author-label {
      display: inline-block;
      vertical-align: middle;
      margin-left: 10px;
      margin-bottom: 3px;
      background-color: var(--dinery-main-color);
      color: #fff;
      padding: 3px 8px;
      border-radius: 3px;
      font-weight: 700;
      font-size: 0.6875rem;
    }

    a {
      color: inherit;
    }
  }

  &-metadata {
    display: inline-block;
  }

  &-date,
  &-edit-link {
    display: inline-block;
    margin-bottom: 10px;
    font-size: 0.875rem;
    color: $meta-color;
  }

  &-edit-link {
    margin-left: 5px;
    margin-bottom: 0;
    color: var(--dinery-main-color);
  }
}

/* Comment Form
/*-------------------------------------------------------*/
.comment-respond {
  margin-top: 40px;
  margin-bottom: 40px;
}

.comment-form .logged-in-as {
  margin-bottom: 26px;
  margin-top: -20px;
}

/* Previous / Next Post Navigation
/*-------------------------------------------------------*/
.entry-navigation {
  padding-top: 36px;
  margin-top: 36px;
  border-top: 1px solid $border-color;
  margin-bottom: 36px;

  &__row {
    margin: 0 -20px;
    @include display-flex;
  }

  &__col {
    padding: 0 20px;
  }

  &__item {
    @include display-flex;
    overflow: hidden;
    height: 100%;
  }

  &--left {
    float: left;
    width: 50%;
    margin-bottom: 12px;

    i {
      margin-right: 7px;
    }
  }

  &--right {
    margin-bottom: 12px;
    text-align: right;
    float: right;
    margin-left: auto;
    width: 50%;

    i {
      margin-left: 7px;
    }
  }

  &__body {
    width: 100%;
  }

  i {
    font-size: 12px;
    display: inline-block;
    color: $text-color;

    .rtl & {
      transform: rotate(180deg);
    }
  }

  &__label {
    display: inline-block;
    margin-bottom: 5px;
    color: $meta-color;
    font-size: 0.875rem;
  }

  &__title {
    font-size: 1.125rem;
    margin-bottom: 0;
  }

  @include bp-sm-down {
    &__row {
      display: block;
    }

    &__col {
      width: 100%;
      float: none;
    }

    &--right {
      text-align: left;
    }
  }
}
