/* ========== Blog Page Layout ========== */

#blog {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

#blog-container {
  width: 100%;
}

/* ========== Collapsible Monthly Section ========== */

.blog-month-wrapper {
  margin-bottom: 10px;
}

.blog-month-header {
  position: relative;
  width: 100%;
  text-align: left;
  padding: 15px 20px;
  font-size: 1.5rem;
  background-color: #252424;
  color: #ffcc00;
}

.blog-month-header::after {
  content: "▼";
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%) rotate(0deg);
  font-size: 1rem;
  transition: transform 0.2s ease;
  color: #ffcc00;
}

.blog-month-header.active {
  margin-bottom: 1%;
}

.blog-month-header.active::after {
  transform: translateY(-50%) rotate(-90deg); /* Points right when expanded */
}

.blog-month-header:hover,
.blog-month-header.active:hover {
  background-color: #2a2a2a;
}

/* ========== Blog Group Grid ========== */

.blog-group {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 40px 20px;
}


/* Highlight expanded blog group */
.blog-month-wrapper.active {
  background-color: #2c2c2c;
  border-radius: 10px;
  padding: 20px;
  box-shadow: inset 0 0 10px rgba(255, 255, 255, 0.1);
  transition: background-color 0.3s ease;
}

/* ========== Blog Post Wrapper ========== */

.blog-post-wrapper {
  display: flex;
  justify-content: flex-start;
  text-decoration: none;
  cursor: pointer;
  max-width: 100%;
  box-sizing: border-box;

}

.blog-post-wrapper.right {
  justify-content: flex-end;
}

/* ========== Blog Card ========== */

.blog-post-card {
  display: flex;
  flex-direction: row;
  align-items: center;
  background: #1e1e1e;
  padding: 20px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  gap: 20px;
  width: 100%;
  max-width: 550px;
}

.blog-post-card:hover {
  transform: scale(1.05);
}

/* ========== Blog Card Content ========== */

.blog-post-img {
  width: 200px;
  height: 120px;
  object-fit: cover;
  border-radius: 8px;
}

.blog-post-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.blog-post-content h3 {
  color: #ffffff;
  margin: 0 0 8px;
  font-size: 1.4rem;
  text-decoration: underline;
  text-underline-offset: 4px;
  transition: color 0.2s ease;
}

.blog-post-wrapper:hover .blog-post-content h3 {
  color: #ffffff;
}

.blog-post-desc {
  color: #ffffff;
  margin: 0 0 8px;
  font-size: 1rem;
}

.blog-post-date {
  font-size: 0.9rem;
  color: #ffffff;
}

/* ========== Responsive Adjustments ========== */

@media (max-width: 1000px) {
  .blog-group {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .blog-post-card {
    max-width: 100%;
  }
}




@media (max-width: 900px) {
  
  /* .blog-post-card {
    flex-direction: column;
    align-items: flex-start;
  } */

  .blog-post-img{
    width: 200px;
    height: 120px;
  }

  .blog-post-content h3 {
    font-size: 1rem;
  }

  .blog-post-desc {
    font-size: 0.95rem;
  }
}

@media (max-width: 600px) {
  .blog-month-header {
    font-size: 1.2rem;
    padding: 12px 16px;
  }

  .blog-post-content h3 {
    font-size: 0.8rem;
  }

  .blog-post-img {
    width: 170px;
    height: 90px;
    align-self: center;
  }

  .blog-post-desc,
  .blog-post-date {
    font-size: 0.7rem;
  }

  .blog-post-card {
    padding: 15px;
    gap: 15px;
  }
}
