/* 커뮤니티 페이지 전용 스타일 */

/* 카테고리 탭 */
.community-category-tab {
  padding: 12px 24px;
  border-radius: 12px;
  border: none;
  background: var(--white);
  color: var(--gray-600);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.community-category-tab:hover {
  background: var(--gray-50);
  color: var(--gray-900);
}

.community-category-tab.active {
  background: linear-gradient(135deg, var(--blue), var(--purple));
  color: var(--white);
  box-shadow: 0 4px 16px rgba(59, 130, 246, 0.3);
}

/* 게시글 카드 */
.community-post-card {
  background: var(--white);
  border-radius: 20px;
  padding: 24px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
  cursor: pointer;
  transition: all 0.3s;
  margin-bottom: 16px;
}

.community-post-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.post-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.post-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--purple));
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 16px;
}

.post-author {
  font-weight: 600;
  color: var(--gray-900);
}

.post-time {
  font-size: 13px;
  color: var(--gray-500);
}

.post-category {
  display: inline-block;
  padding: 4px 12px;
  background: var(--gray-100);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--gray-700);
  margin-bottom: 12px;
}

.post-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--gray-900);
  margin-bottom: 8px;
}

.post-content {
  font-size: 14px;
  color: var(--gray-600);
  line-height: 1.6;
  margin-bottom: 16px;
}

.post-stats {
  display: flex;
  gap: 16px;
  font-size: 13px;
  color: var(--gray-500);
}

.post-stat {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* 새 게시글 버튼 */
.btn-new-post {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  border: none;
  background: linear-gradient(135deg, var(--blue), var(--purple));
  color: var(--white);
  font-size: 32px;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(59, 130, 246, 0.4);
  transition: all 0.3s;
  z-index: 50;
}

.btn-new-post:hover {
  transform: scale(1.1) rotate(90deg);
  box-shadow: 0 12px 32px rgba(59, 130, 246, 0.5);
}

/* 반응형 */
@media (max-width: 768px) {
  .community-post-card {
    padding: 20px;
  }

  .post-title {
    font-size: 16px;
  }

  .btn-new-post {
    width: 56px;
    height: 56px;
    bottom: 24px;
    right: 24px;
  }
}

/* ✅ 커뮤니티 카드 컨테이너 */
.community-post-card {
  background: #ffffff;
  border-radius: 16px;
  padding: 24px;
  margin: 16px 0;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
  transition: all 0.2s ease;
}

.community-post-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
}

/* ✅ 카테고리 라벨 */
.community-post-category {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  color: #fff;
  border-radius: 8px;
  padding: 4px 10px;
  margin-bottom: 10px;
}

/* 카테고리별 색상 */
.community-post-category.safety {
  background: #5b8def;
}
.community-post-category.tip {
  background: #67c587;
}
.community-post-category.story {
  background: #f7a54b;
}
.community-post-category.qna {
  background: #e45858;
}

/* ✅ 게시글 제목 */
.community-post-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
  color: #222;
}

/* ✅ 게시글 내용 */
.community-post-content {
  font-size: 14px;
  color: #555;
  margin-bottom: 18px;
  line-height: 1.5;
}

/* ✅ 작성자 + 좋아요/조회수 영역 */
.community-post-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid #f0f0f0;
  padding-top: 12px;
}

.community-post-author {
  display: flex;
  align-items: center;
  gap: 10px;
}

.community-author-avatar {
  background: linear-gradient(135deg, #74b9ff, #a29bfe);
  color: white;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-weight: 600;
  font-size: 14px;
}

.community-author-name {
  font-size: 13px;
  color: #333;
}

/* ✅ 좋아요/조회수 아이콘 */
.community-post-stats {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #777;
  font-size: 13px;
}

.community-post-stats .community-stat-item {
  display: flex;
  align-items: center;
  gap: 4px;
}

.community-post-stats .community-stat-item svg {
  width: 16px;
  height: 16px;
}
