/* 헤더 스타일 */
.site-header {
    background-color: #ffffff; /* 밝고 깔끔한 흰색 */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); /* 가벼운 그림자 */
    padding: 20px 40px;
}

/* 메뉴 스타일 */
.main-navigation a {
    color: #333; /* 차분한 진회색 */
    font-weight: 500;
    font-size: 16px;
    margin: 0 15px;
    text-decoration: none;
    transition: color 0.3s ease-in-out;
}

.main-navigation a:hover {
    color: #0078d4; /* 포인트 컬러 */
}

/* 로고 텍스트 스타일 */
.site-branding a {
    font-size: 24px;
    font-weight: bold;
    color: #0078d4; /* 로고와 일관된 포인트 색상 */
    text-transform: uppercase;
}

/* 블로그 그리드 컨테이너 */
.blog .site-main {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    padding: 20px;
}

/* 블로그 카드 스타일 */
.blog .inside-article {
    border: 1px solid #e0e0e0;
    border-radius: 8px; /* 부드러운 모서리 */
    overflow: hidden;
    background-color: #ffffff;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    display: flex;
    flex-direction: column;
}

.blog .inside-article:hover {
    transform: translateY(-5px); /* 가벼운 부각 효과 */
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

/* 카드 이미지 스타일 */
.blog .inside-article img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

/* 카드 텍스트 스타일 */
.blog .inside-article .entry-header {
    padding: 15px;
    font-size: 18px;
    font-weight: bold;
    color: #333;
}

.blog .inside-article .entry-summary {
    padding: 15px;
    font-size: 14px;
    color: #666;
    flex-grow: 1;
}

/* 공통 버튼 스타일 */
button, .button {
    background-color: #0078d4; /* 블루 계열 포인트 색상 */
    color: #ffffff;
    border: none;
    padding: 10px 20px;
    font-size: 16px;
    font-weight: bold;
    border-radius: 5px; /* 부드러운 모서리 */
    cursor: pointer;
    transition: background-color 0.3s ease;
}

button:hover, .button:hover {
    background-color: #005bb5; /* 더 어두운 파란색 */
}

/* 공지 배너 스타일 */
.announcement-bar {
    background-color: #f4f8fb; /* 밝은 블루 계열 배경 */
    color: #0078d4; /* 포인트 색상 */
    text-align: center;
    padding: 15px;
    font-size: 16px;
    border-bottom: 2px solid #e0e0e0;
}

.announcement-bar a {
    color: #005bb5; /* 강조된 링크 */
    font-weight: bold;
    text-decoration: none;
    margin-left: 10px;
}

.announcement-bar a:hover {
    text-decoration: underline;
}

/* 글로벌 폰트 스타일 */
body {
    font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
}

/* 제목과 강조 텍스트 */
h1, h2, h3, h4, h5, h6 {
    font-weight: bold;
    font-family: 'Pretendard', sans-serif;
    color: #333; /* 기본 텍스트 색상 */
}

/* 페이지네이션 컨테이너 강제 설정 */
#nav-below {
  display: flex !important; /* 강제 적용 */
  flex-direction: row; /* 수평 정렬 */
  justify-content: center; /* 중앙 정렬 */
  align-items: center; /* 수직 정렬 */
  flex-wrap: nowrap; /* 줄 바꿈 방지 */
  gap: 10px; /* 버튼 간격 */
  margin: 20px 0;
  padding: 0;
  box-sizing: border-box;
}

/* 페이지 버튼 공통 스타일 */
#nav-below .nav-links a,
#nav-below .nav-links span,
#nav-below .nav-previous a,
#nav-below .nav-next a {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: 40px; /* 모든 버튼 동일한 너비 */
  height: 40px; /* 모든 버튼 동일한 높이 */
  font-size: 14px;
  font-weight: 600;
  color: #0078d4; /* 기본 색상 */
  border: 2px solid #ddd;
  border-radius: 5px; /* 둥근 모서리 */
  background-color: white;
  text-decoration: none;
  transition: all 0.3s ease;
  box-sizing: border-box;
}

/* 현재 페이지 버튼 */
#nav-below .nav-links .current {
  background-color: #005bb5; /* 강조된 배경 */
  color: white; /* 강조된 텍스트 */
  border-color: #005bb5;
  pointer-events: none; /* 클릭 불가 */
}

/* 마우스오버 효과 */
#nav-below .nav-links a:hover,
#nav-below .nav-previous a:hover,
#nav-below .nav-next a:hover {
  background-color: #0078d4; /* 호버 시 배경 */
  color: white;
  border-color: #0078d4;
}

/* 이전/다음 버튼 스타일 */
#nav-below .nav-previous a,
#nav-below .nav-next a {
  width: 80px; /* 넓은 너비 */
  font-size: 10px;
  font-weight: bold;
}
#nav-below .nav-links .prev {
	font-size: 5px;
}

/* 이전/다음 버튼 스타일 */
#nav-below .nav-previous .prev a,
#nav-below .nav-links .next {
  width: 80px; /* 넓은 너비 */
  font-weight: bold;
}

/* 사이드바 기본 스타일링 */
.widget-area .widget {
    padding: 20px;
    background-color: #ffffff;
    border-radius: 8px;
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* 사이드바 위젯 제목 */
.widget-area .widget-title {
    font-size: 18px;
    color: #333;
    padding-bottom: 10px;
    border-bottom: 2px solid #007bff;
    margin-bottom: 15px;
}

/* 사이드바 링크 스타일 */
.widget-area .widget a {
    color: #495057;
    text-decoration: none;
    transition: color 0.3s ease;
	/* 폴백 색상 */
    color: #333; 
    
    /* 그라데이션 지원하는 브라우저용 */
    background: linear-gradient(45deg, #0014ff, #000000);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    
    /* 텍스트를 더 선명하게 */
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.widget-area .widget a:hover {
    color: #007bff;
}

/* 사이드바 리스트 스타일 */
.widget-area .widget ul {
    margin: 0;
}

.widget-area .widget ul li {
    padding: 8px 0;
    border-bottom: 1px solid #eee;
}

.widget-area .widget ul li:last-child {
    border-bottom: none;
}

/* 검색 위젯 스타일 */
.widget-area .search-form {
    display: flex;
}

.widget-area .search-form .search-field {
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 8px;
    flex-grow: 1;
}

.widget-area .search-form .search-submit {
    padding: 8px 15px;
    margin-left: 5px;
}

/* 모바일 반응형 */
@media (max-width: 768px) {
    .widget-area {
        margin-top: 30px;
    }
}

/* 메인 컨텐츠 컨테이너 스타일 */
.site-content {
    position: relative;
}

/* 사이드바 컨테이너 스타일 */
#right-sidebar {
    position: relative; /* 부모 요소 기준 */
}

/* 사이드바 스티키 스타일 */
.widget-area {
    position: sticky;
    top: 32px; /* 워드프레스 관리자 바가 있는 경우 */
    margin-bottom: 30px;
}

/* 관리자 로그아웃 상태일 때 */
body:not(.admin-bar) .widget-area {
    top: 0;
}

/* 모바일에서는 스티키 효과 제거 */
@media (max-width: 768px) {
    .widget-area {
        position: static;
    }
}

/* 모바일 버전 사이드바 스타일 */
@media (max-width: 768px) {
    .widget-area {
        position: static !important; /* sticky 해제 */
        top: auto !important;
        max-height: none !important;
        overflow-y: visible !important;
        margin-top: 30px; /* 본문과의 간격 */
        width: 100% !important;
    }
    
    /* 사이드바를 본문 아래로 이동 */
    #primary {
        order: 1;
    }
    
    #right-sidebar {
        order: 2;
    }
    
    /* 컨테이너에 flex 속성 추가 */
    .site-content {
        display: flex;
        flex-direction: column;
    }
}

.blog .site-main {
	display:flex;
	flex-direction: column;
}

footer.entry-meta{
	visibility: hidden;
}

/* 서브메뉴 전용 CSS - 워드프레스 추가 CSS (호버 효과 강제 적용 수정) */

.menu.sf-menu .sub-menu {
    background-color: var(--base-3, #ffffff);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
    border-radius: 6px;
    overflow: hidden;
    padding: 8px 0;
    box-sizing: border-box;
    opacity: 0;
    visibility: hidden;
    position: absolute;
    top: 100%;
    left: 0;
    width: 220px;
    transition: opacity 0.2s ease, visibility 0.2s ease;

}

.menu.sf-menu li:hover > .sub-menu {
    opacity: 1;
    visibility: visible;
}

.menu.sf-menu .sub-menu li {
    padding: 8px 16px;
    font-size: 16px;
    font-family: 'Pretendard', sans-serif;
    color: var(--contrast, #222222);
    cursor: pointer;
    transition: background-color 0.3s ease, color 0.3s ease, transform 0.3s ease;
}

.menu.sf-menu .sub-menu li:hover {

    color: #ffffff !important;
    transform: translateX(8px);
}

.menu.sf-menu .sub-menu li:not(:last-child) {
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.menu.sf-menu .sub-menu::before {
    content: "";
    position: absolute;
    top: -8px;
    left: 20px;
    border-width: 0 8px 8px 8px;
    border-style: solid;
    border-color: transparent transparent var(--base-3, #ffffff) transparent;
}