/* =========================================================
   LATEST BLOG POSTS
   ========================================================= */

.latest-blog-section {
  width: 100%;
  padding: 60px 6%;
  box-sizing: border-box;
}

.latest-blog-section .section-header {
  text-align: center;
  margin-bottom: 55px;
}

.latest-blog-section .section-header h2 {
  margin: 0;
  /* font-size: 2.2rem; */
  font-weight: 700;
  letter-spacing: 1px;
}

.latest-blog-section .section-header h2 span {
  font-weight: 400;
}

.latest-blog-section .section-header p {
  margin-top: 12px;
  /* font-size: 1rem; */
  opacity: 0.75;
}

/* =========================================================
   CATEGORY NAVIGATION
   Desktop Hidden
   ========================================================= */

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

/* =========================================================
   CATEGORY CONTAINER
   ========================================================= */

.blog-categories {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 25px;
  width: 100%;
}

/* =========================================================
   CATEGORY CARD
   ========================================================= */

.blog-category {
  min-width: 0;
  padding: 28px;
  border: 1px solid rgba(128, 128, 128, 0.25);
  border-radius: 14px;
  background: rgba(172, 3, 3, 0.04);
  box-sizing: border-box;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

/* =========================================================
   DESKTOP HOVER EFFECT
   ========================================================= */

@media (min-width: 1025px) and (hover: hover) and (pointer: fine) {
  .blog-category:hover {
    transform: translateY(-5px);
    border-color: rgba(128, 128, 128, 0.45);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
  }
}

/* =========================================================
   CATEGORY HEADER
   ========================================================= */

.blog-category-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 15px;
  padding-bottom: 20px;
  margin-bottom: 10px;
  border-bottom: 1px solid rgba(128, 128, 128, 0.2);
}

.blog-category-label {
  display: block;
  margin-bottom: 7px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 1.4px;
  opacity: 0.6;
}

.blog-category h3 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 700;
}

/* =========================================================
   VIEW ALL
   ========================================================= */

.blog-view-all {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: opacity 0.2s ease;
}

.blog-view-all:hover {
  opacity: 0.65;
}

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

.blog-posts {
  display: flex;
  flex-direction: column;
}

/* =========================================================
   INDIVIDUAL POST
   ========================================================= */

.blog-post {
  padding: 17px 0;
  border-bottom: 1px solid rgba(128, 128, 128, 0.16);
}

.blog-post:last-child {
  border-bottom: none;
}

.blog-post a {
  display: block;
  color: inherit;
  text-decoration: none;
}

.blog-post-title {
  margin: 0 0 7px;
  font-size: 0.98rem;
  line-height: 1.45;
  font-weight: 600;
  transition: opacity 0.2s ease;
}

.blog-post a:hover .blog-post-title {
  opacity: 0.65;
}

.blog-post-date {
  font-size: 0.75rem;
  opacity: 0.55;
}

/* =========================================================
   LOADING / ERROR
   ========================================================= */

.blog-loading,
.blog-error {
  padding: 25px 0;
  font-size: 0.85rem;
  opacity: 0.6;
}

/* =========================================================
   TABLET
   769px - 1024px
   ========================================================= */

@media (min-width: 769px) and (max-width: 1024px) {
  .latest-blog-section {
    padding: 75px 5%;
  }

  .latest-blog-section .section-header {
    margin-bottom: 35px;
  }

  /* -------------------------------------------------------
     CATEGORY NAVIGATION
     ------------------------------------------------------- */

  .blog-category-navigation {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 35px;
    margin-bottom: 28px;
    padding-bottom: 2px;
    border-bottom: 1px solid rgba(128, 128, 128, 0.18);
  }

  .blog-category-button {
    position: relative;
    padding: 10px 0;
    border: none;
    background: transparent;
    color: inherit;
    font: inherit;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    opacity: 0.5;
    white-space: nowrap;
    cursor: pointer;
    transition: opacity 0.25s ease, color 0.25s ease;
  }

  .blog-category-button::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -3px;
    height: 2px;
    transform: scaleX(0);
    transform-origin: center;
    background: currentColor;
    transition: transform 0.25s ease;
  }

  .blog-category-button:hover,
  .blog-category-button.active {
    opacity: 1;
  }

  .blog-category-button.active::after {
    transform: scaleX(1);
  }

  /* -------------------------------------------------------
     HORIZONTAL SLIDER
     ------------------------------------------------------- */

  .blog-categories {
    display: flex;
    width: 100%;
    gap: 0;
    padding: 12px 0 18px;
    overflow-x: auto;
    overflow-y: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
  }

  .blog-categories::-webkit-scrollbar {
    display: none;
  }

  .blog-category {
    flex: 0 0 100%;
    width: 100%;
    scroll-snap-align: start;
    scroll-snap-stop: always;
    padding: 28px;
  }
}

/* =========================================================
   MOBILE
   768px and Below
   ========================================================= */

@media (max-width: 768px) {
  .latest-blog-section {
    padding: 65px 5%;
  }

  .latest-blog-section .section-header {
    margin-bottom: 30px;
  }

  .latest-blog-section .section-header h2 {
    font-size: 1.7rem;
  }

  .latest-blog-section .section-header p {
    font-size: 0.9rem;
    line-height: 1.6;
  }

  /* -------------------------------------------------------
     CATEGORY NAVIGATION
     ------------------------------------------------------- */

  .blog-category-navigation {
    display: flex;
    width: 100%;
    gap: 24px;
    margin-bottom: 22px;
    padding-bottom: 2px;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    border-bottom: 1px solid rgba(128, 128, 128, 0.18);
    scrollbar-width: none;
    -ms-overflow-style: none;
  }

  .blog-category-navigation::-webkit-scrollbar {
    display: none;
  }

  .blog-category-button {
    position: relative;
    flex-shrink: 0;
    padding: 9px 0;
    border: none;
    background: transparent;
    color: inherit;
    font: inherit;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.4px;
    opacity: 0.5;
    white-space: nowrap;
    cursor: pointer;
    transition: opacity 0.25s ease, color 0.25s ease;
  }

  .blog-category-button::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -3px;
    height: 2px;
    transform: scaleX(0);
    transform-origin: center;
    background: currentColor;
    transition: transform 0.25s ease;
  }

  .blog-category-button.active {
    opacity: 1;
  }

  .blog-category-button.active::after {
    transform: scaleX(1);
  }

  /* -------------------------------------------------------
     HORIZONTAL SLIDER
     ------------------------------------------------------- */

  .blog-categories {
    display: flex;
    width: 100%;
    gap: 0;
    padding: 12px 0 18px;
    overflow-x: auto;
    overflow-y: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
  }

  .blog-categories::-webkit-scrollbar {
    display: none;
  }

  .blog-category {
    flex: 0 0 100%;
    width: 100%;
    scroll-snap-align: start;
    scroll-snap-stop: always;
    padding: 22px;
    border-radius: 12px;
  }

  .blog-category-header {
    align-items: center;
  }

  .blog-category h3 {
    font-size: 1.1rem;
  }

  .blog-view-all {
    font-size: 0.72rem;
  }

  .blog-post-title {
    font-size: 0.9rem;
  }
}

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

.blog-category:active {
  transform: translateY(-3px);
  border-color: rgba(128, 128, 128, 0.45);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.10);
}