/* =========================================================
   BLOG LISTING
========================================================= */

.blogs-listing {
  width: 100%;
  padding: 40px 0;
  background-color: var(--color-17);
}

.blogs-listing-container {
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 15px;
}

/* =========================================================
   MAIN BLOG LAYOUT
========================================================= */

.blogs-layout {
  display: grid;
  grid-template-columns: 25% 75%;
  align-items: start;
  width: 100%;
}

/* =========================================================
   SIDEBAR
========================================================= */

.blog-sidebar {
  width: 100%;
  padding-right: 40px;
  position: sticky;
  top: 110px;
  align-self: flex-start;
}

/* =========================================================
   SEARCH
========================================================= */

.blog-search {
  position: relative;
  width: 100%;
  margin-bottom: 35px;
  border-bottom: 1px solid var(--color-20);
}

.blog-search svg {
  position: absolute;
  left: 3%;
  top: 30%;
}

.blog-search-input {
  width: 100%;
  height: 50px;

  padding: 10px 50px 10px 15px;

  border: none !important;
  border-radius: 0;

  background: transparent;

  color: var(--color-18);

  outline: none;

  font-size: 16px;

  transition:
    border-color 0.3s ease,
    background-color 0.3s ease;
}
.blog-search-input {
  padding-left: 48px !important;
}
/* .blog-search-input::placeholder {
  padding-left: 10px !important;
  position: relative;
  left: 14%;
} */

.blog-search-input:focus {
  border-color: var(--color-18);
}

.blog-search-input::placeholder {
  color: var(--color-22);
}

.blog-search-button {
  position: absolute;

  top: 0;
  right: 0;

  width: 50px;
  height: 50px;

  padding: 0;

  border: 0;

  background: transparent;

  color: var(--color-18);

  display: flex;
  align-items: center;
  justify-content: center;

  cursor: pointer;
}

/* =========================================================
   CATEGORIES
========================================================= */

.blog-categories {
  position: sticky;
  top: 100px;

  width: 100%;
}

.blog-categories-inner {
  display: flex;
  flex-direction: column;

  gap: 10px;

  width: 100%;
}

.blog-category-btn {
  width: 100%;

  margin: 0;
  padding: 12px 14px;

  border: 0;
  outline: none;

  background: transparent;

  color: var(--color-22);

  text-align: left;

  cursor: pointer;

  transition:
    color 0.3s ease,
    background-color 0.3s ease;
}

.blog-category-btn:hover {
  color: var(--color-18);
}

.blog-category-btn.active {
  color: var(--color-18);
}

/* =========================================================
   POSTS AREA
========================================================= */

.blog-posts-area {
  width: 100%;
  min-width: 0;
}

/* =========================================================
   POSTS GRID
========================================================= */

.blog-posts-grid {
  display: grid;

  grid-template-columns: repeat(2, minmax(0, 1fr));

  column-gap: 30px;
  row-gap: 40px;

  width: 100%;
}

/* =========================================================
   SINGLE POST
========================================================= */

.blog-post-item {
  width: 100%;
  min-width: 0;

  display: flex;
  flex-direction: column;
  gap: 24px;

  opacity: 1;
  visibility: visible;

  transform: translateY(0);

  transition:
    opacity 0.25s ease,
    transform 0.25s ease;
}

/*
 * IMPORTANT
 *
 * We are NOT using:
 *
 * .hidden {
 *     display: none;
 * }
 *
 * Instead JS uses the native [hidden] attribute.
 */

.blog-post-item[hidden] {
  display: none !important;
}

/* =========================================================
   BLOG CARD
========================================================= */

.blog-card {
  width: 100%;

  display: flex;
  flex-direction: column;

  gap: 24px;
}

/* =========================================================
   BLOG IMAGE
========================================================= */

.blog-card-image {
  width: 100%;

  overflow: hidden;
}

.blog-card-image a {
  display: block;

  width: 100%;
  height: 100%;
}

.blog-card-image img {
  display: block;
border-radius: 20px;
  width: 100%;
  height: 350px;

  object-fit: cover;
  object-position: center;

  transition: transform 0.5s ease;
}

/* =========================================================
   BLOG CONTENT
========================================================= */

.blog-card-content {
  width: 100%;

  display: flex;
  flex-direction: column;

  gap: 24px;
}

/* =========================================================
   BLOG TITLE
========================================================= */

.blog-card-title {
  margin: 0;
}

.blog-card-title a {
  display: inline-block;
}

/* =========================================================
   BLOG EXCERPT
========================================================= */

.blog-card-excerpt {
  margin: 0;

  display: -webkit-box;

  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;

  overflow: hidden;
}

/* =========================================================
   NO RESULTS
========================================================= */

.blog-no-results,
.blog-filter-no-results {
  width: 100%;

  padding: 40px 0;
}

.blog-no-results p,
.blog-filter-no-results p {
  margin: 0;
}

/* =========================================================
   PAGINATION
========================================================= */

.blog-pagination {
  width: 100%;

  margin-top: 50px;
}

.blog-pagination ul {
  display: flex;

  align-items: center;
  justify-content: center;

  flex-wrap: wrap;

  gap: 14px;

  margin: 0;
  padding: 0;

  list-style: none;
}

.blog-pagination li {
  margin: 0;
  padding: 0;
}

.blog-pagination a,
.blog-pagination span {
  display: flex;
  border: 1px solid #dbdbdb;
  color: var(--color-18);
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 45px;
  border-radius: 5px;
  padding: 14px 20px;
  text-decoration: none;
  transition:
    color 0.3s ease,
    border-color 0.3s ease,
    background-color 0.3s ease;
}

.blog-pagination a:hover {
  color: var(--color-18);
}

.blog-pagination .current {
  background-color: var(--color-18);
  color: var(--color-17);
}

.blog-categories-inner {
  padding-top: 24px;
}

.blog-category-btn.active {
  color: var(--color-18);
  position: relative;
}

.blog-category-btn.active::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 3px;
  height: 100%;
  background-color: var(--color-1);
}

.pagination-mobile {
  display: none !important;
}
.pagination-desktop {
  display: flex !important;
}

.blog-category-dropdown {
  display: none;
}

/* RWD  */

@media (max-width: 991px) {
  /* .blog-sidebar {
    display: none;
  } */

  .blog-sidebar {
    padding: 0;
    position: static;
  }

  .blog-card-image img {
    height: 250px;
    border-radius: 10px;
  }

  .blogs-layout,
  .blog-posts-grid {
    display: flex;
    flex-direction: column;
  }

  .blog-card-content,
  .blog-post-item {
    gap: 14px;
  }
  .pagination-desktop {
    display: none !important;
  }

  .pagination-mobile {
    display: flex !important;
  }

  .blog-categories-inner {
    display: none;
  }

  .blog-category-dropdown {
    display: block;
    position: relative;
    width: 100%;
  }

  /* TOGGLE */

  .blog-category-dropdown-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    background: transparent;
    border: 1px solid #707070;
    cursor: pointer;
    text-align: left;
    margin-bottom: 24px;
    border-radius: 10px;
  }

  /* ARROW */

  .blog-category-dropdown-arrow {
    display: flex;
    align-items: center;
    justify-content: center;

    transition: transform 0.3s ease;
  }

  .blog-category-dropdown-toggle[aria-expanded="true"]
    .blog-category-dropdown-arrow {
    transform: rotate(180deg);
  }

  /* DROPDOWN MENU */

  .blog-category-dropdown-menu {
    position: absolute;

    top: calc(100% + 5px);
    left: 0;

    width: 100%;

    background: #fff;
    border: 1px solid #707070;

    z-index: 100;

    display: none;
  }

  .blog-category-dropdown-menu.is-open {
    display: block;
    position: relative;
    z-index: 2;
    margin-bottom: 10px;
  }

  /* DROPDOWN ITEM */

  .blog-category-dropdown-item {
    width: 100%;

    display: block;

    padding: 12px 16px;

    background: transparent;
    border: 0;

    text-align: left;

    cursor: pointer;
  }

  .blog-category-dropdown-item:hover {
    background: #f5f5f5;
  }

  .blog-category-dropdown-item.active {
    font-weight: 600;
  }
  .blog-search {
    margin-bottom: 24px;
  }
}
