/**
 * Posts Grid Styles
 * Responsive grid for displaying posts
 */

/* Grid Container */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin: 0;
  padding: 0;
}

/* Post Card */
.post-card {
  background: #ffffff;
  border-radius: 8px;
  padding: 20px;
  transition: transform 0.2s, box-shadow 0.2s;
}

.post-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.post-card-link {
  text-decoration: none;
  display: block;
}

/* Post Thumbnail */
.post-thumbnail {
  width: 100%;
  height: 150px;
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 16px;
  background-color: #f3f4f6;
}

.post-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.post-thumbnail-placeholder {
  width: 100%;
  height: 100%;
  background-color: #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Post Content */
.post-content {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.post-title {
  font-size: 14px;
  font-weight: 600;
  color: #000000;
  margin: 0;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.post-excerpt {
  font-size: 14px;
  font-weight: 400;
  color: #000000;
  line-height: 1.5;
  margin: 0;
}

/* No Posts Message */
.no-posts-message {
  text-align: center;
  font-size: 16px;
  color: #6b7280;
  padding: 40px 20px;
}

/* Tablet - 3 columns */
@media (max-width: 1024px) {
  .posts-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Mobile - 1 column */
@media (max-width: 768px) {
  .posts-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .post-card {
    padding: 16px;
  }

  .post-thumbnail {
    height: 180px;
    margin-bottom: 12px;
  }
}
