/* =======================
   Front Page Styles
   ======================= */

/* 전체 레이아웃 */
.main-container {
  display: flex;
  justify-content: center;
  gap: 40px;
  margin-top: 40px;
  font-family: 'Pretendard', 'Noto Sans KR', sans-serif;
  line-height: 1.7;
  color: #2E2E2E;

  /* 좌측 사이드바와 콘텐츠를 같은 행에 고정 */
  flex-wrap: nowrap;
  align-items: flex-start; /* sticky 기준 */
}

/* 링크 스타일 (카테고리, 카드, 공지 등만 적용) */
.sidebar-left a,
.card-content a,
.notice-content a {
  color: #2E2E2E;
  text-decoration: none;
  transition: 0.2s ease;
}

.sidebar-left a:hover,
.card-content a:hover,
.notice-content a:hover {
  color: #6BBF8E;
}

/* 좌측 사이드바 */
.sidebar-left {
  width: 220px;
  flex-shrink: 0;
  position: sticky;
  top: 20px; /* 스크롤 시 여백 */
  align-self: flex-start;
}
.sidebar-box {
  background: #f8faf9;
  border-radius: 10px;
  padding: 15px;
  margin-bottom: 20px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}
.sidebar-category h3 {
  font-size: 1.1rem;
  color: #3d5c48;
  margin-bottom: 10px;
}
.sidebar-category ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.sidebar-category li {
  margin-bottom: 8px;
}

/* 인트로 영역 */
.intro-block {
  background: #f5f9f7;
  border-left: 4px solid #6BBF8E;
  border-radius: 12px;
  padding: 30px;
  text-align: center;
  margin-bottom: 40px;
}
.intro-block h1 {
  font-size: 1.7rem;
  color: #3d5c48;
  margin-bottom: 12px;
}
.intro-block p {
  color: #555;
  font-size: 1rem;
  margin-bottom: 24px;
}
.cta-button {
  display: inline-block;
  background: #6BBF8E;
  color: #fff;
  padding: 12px 28px;
  border-radius: 30px;
  font-weight: 600;
  text-decoration: none;
  transition: 0.3s;
}
.cta-button:hover {
  background: #57a76d;
  transform: translateY(-2px);
}

/* 중앙 콘텐츠 */
.content {
  max-width: 820px;
  flex-grow: 1;
}
.content h2 {
  font-size: 1.3rem;
  color: #3d5c48;
  margin-bottom: 15px;
}

/* 공지 */
.notice-block {
  background: #E9F7EF;
  border-left: 4px solid #6BBF8E;
  border-radius: 10px;
  padding: 25px;
  margin-bottom: 40px;
  position: relative;
}
.notice-block h3 {
  font-size: 1rem;
  position: absolute;
  top: 12px;
  left: 20px;
  color: #3d5c48;
}
.notice-content {
  margin-top: 30px;
}

/* 카드형 글 */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 24px;
}
.post-card {
  background: #fff;
  border: 1px solid #eee;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0,0,0,0.05);
  transition: all 0.25s ease;
}
.post-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 14px rgba(0,0,0,0.1);
}
.card-thumb img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}
.card-content {
  padding: 16px;
}
.card-content h3 {
  font-size: clamp(1.05rem, 1.2vw, 1.3rem);
  color: #2E2E2E;
  margin-bottom: 8px;
}
.card-content p {
  color: #555;
  font-size: 0.9rem;
}

/* 반응형 */
@media (max-width: 768px) {
  .main-container {
    flex-wrap: wrap;
    justify-content: center;
  }

  .sidebar-left {
    position: relative;
    top: auto;
    width: 100%;
    margin-bottom: 20px;
  }

  .footer-inner {
    flex-direction: row !important;
    justify-content: space-between !important;
    padding-top: 8px !important;
    padding-bottom: 8px !important;
  }

  .footer-bottom-bar .footer-text {
    font-size: 0.75rem !important;
    line-height: 1.2 !important;
    margin: 0 !important;
  }

  .footer-widgets .widget {
    margin-bottom: 6px !important;
  }
}
