/* 핵심 가치 섹션 공통 스타일 */
.core-values {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin-top: 20px;
}

.core-values .value-item {
    background-color: #ffffff; /* 기본 배경색 (흰색) */
    color: #333; /* 기본 글자색 (검은색) */
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    text-align: center;
    flex: 1 1 calc(50% - 20px);
    min-width: 250px;
    transition: transform 0.3s ease;
}

.core-values .value-item:hover {
    transform: translateY(-5px);
}

.core-values .value-item h4 {
    margin-top: 0;
    font-size: 1.2em;
    color: #007bff;
    border-bottom: 2px solid #007bff;
    padding-bottom: 5px;
    display: inline-block;
    margin-bottom: 10px;
}

.core-values .value-item p {
    margin: 10px 0 0;
    line-height: 1.5;
    color: #555;
    font-size: 16px; /* 설명 글자 16px로 설정 */
}

/* 첫 번째 핵심 가치 항목에만 특별 스타일 적용 */
.core-values .value-item:first-child {
    background-color: #555; /* 회색 배경 */
    color: #ffffff; /* 흰색 글자 */
}

.core-values .value-item:first-child h4 {
    color: #ffffff; /* h4도 흰색 글자로 */
    border-bottom: 2px solid rgba(255, 255, 255, 0.7); /* 흰색 투명 밑줄 */
}

.core-values .value-item:first-child p {
    color: #333; /* 설명 글자는 검은색으로 */
    background-color: #ffffff; /* 설명 글자 배경색 흰색으로 */
    padding: 10px; /* 패딩 추가 */
    border-radius: 8px;
    font-size: 16px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) inset; /* 안쪽 그림자 효과 */
}

/* 로고 헤더 스타일 */
.logo-header {
    background-color: #ffffff;
    padding: 20px;
    text-align: center;
    border-bottom: 1px solid #ddd;
}

.logo-header .logo-container img {
    max-width: 200px;
    height: auto;
    display: block;
    margin: 0 auto 10px; /* 로고 아래 여백 */
}

.logo-header h1 {
    font-size: 1.8em;
    color: #333;
    margin: 0;
}


/* 기본 스타일 */
html {
  scroll-behavior: smooth;
}

body {
    font-family: 'Noto Sans KR', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
}

/* 모든 링크의 색상을 항상 파란색으로 고정 */
a {
    color: #333; /* 링크 기본 색상 (파란색) */
    text-decoration: none; /* 밑줄 제거 */
}

/* 방문한 링크, 마우스를 올렸을 때, 클릭 중일 때 모두 같은 색상 유지 */
a:visited,
a:hover,
a:active {
    color: #333; /* 기본 색상과 동일하게 설정 */
    text-decoration: none; /* 밑줄이 생기지 않도록 제거 */
}

.icon-section {
    display: flex;
    flex-wrap: wrap; /* 화면이 작아지면 아이콘이 다음 줄로 내려가게 함 */
    justify-content: center;
    padding: 20px;
    background-color: #fff;
    border-bottom: 1px solid #ddd;
}

.icon-item {
    text-align: center;
    margin: 15px;
    flex-basis: 120px; /* 각 아이콘의 기본 너비 */
}

.icon-item img {
    width: 60px;
    height: 60px;
}

.notice-section, .gallery-section {
    padding: 20px;
    margin: 20px auto;
    max-width: 960px;
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

h2 {
    text-align: center;
    margin-top: 0;
    color: #333;
}

h3 {
    text-align: center;
    margin-top: 0;
    color: #333;
}

.notice-section ul {
    list-style: none;
    padding: 0;
}

.notice-section li {
    padding: 10px 0;
    border-bottom: 1px dashed #eee;
}

/* 공지사항 내 소제목 스타일 */
.notice-section h3 {
    text-align: left;
    font-size: 1.3em;
    color: #555;
    margin: 30px 0 0 0px;
	padding-bottom:10px;
	border-bottom: 2px solid #c9c9c9;
}

/* 교회 소개 내용 스타일 추가 */
.church-intro-content {
    text-align: center;
    line-height: 1.6;
}

.gallery-section {
    background-color: #333;
    color: #fff;
}

.gallery-container {
    text-align: center;
}

.gallery-container img {
    max-width: 100%; /* 이미지가 부모 요소 너비에 맞춰 크기가 조절됨 */
    height: auto;
}

.content-section {
    padding: 20px;
    margin: 20px auto;
    max-width: 960px;
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.church-intro-content {
    text-align: center;
    line-height: 1.6;
}

.church-intro-content p {
    margin: 10px 0;
}

/* 유튜브 영상 컨테이너 (기존 스타일 재활용) */
.youtube-video-container {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 비율 */
    height: 0;
    overflow: hidden;
    max-width: 100%;
    background: #000;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    flex: 1 1 calc(50% - 20px); /* 2개씩 배치 (작은 화면에서 1개) */
    min-width: 280px; /* 최소 너비 */
}

.youtube-video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* YouTube Shorts 영상 컨테이너 (세로 비율 9:16) */
.youtube-shorts-container {
    position: relative;
    padding-bottom: 177.77%; /* 9:16 비율 */
    height: 0;
    overflow: hidden;
    max-width: 100%;    
    background: #000;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    /* flex 항목으로 사용될 때의 기본값 */
    flex: 1 1 calc(50% - 20px); /* 2개씩 배치 (작은 화면에서 1개) */
    min-width: 280px; /* 최소 너비 */
}

.youtube-shorts-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}


/* 공지사항 리스트 스타일 */
.notice-list {
    list-style: none;
    padding: 0;
    line-height: 1.6;
	margin: 0 0 30px 0;
}

.notice-list li {
    padding: 15px 0;
    border-bottom: 1px dashed #eee;
}

.notice-list li h3 {
    margin: 0 0 5px;
    font-size: 1.1em;
    color: #007bff; /* 제목 색상 강조 */
}

.notice-list li .date {
    display: block;
    font-size: 0.9em;
    color: #888;
    margin-bottom: 8px;
}

.notice-list li p {
    margin: 0;
}

.ntable {border-collapse: collapse;table-layout: fixed;width:100%;}
.ntable th {background:#ddd;border:1px solid #888;text-align:center;padding:.3rem;box-sizing:border-box;}
.ntable td {border:1px solid #888;text-align:center;padding:.3rem;box-sizing:border-box;}

/* 섹션 구분선 스타일 */
.section-divider {
    border: 0;
    border-top: 1px solid #eee;
    margin: 20px 0;
}

/* 갤러리 섹션 내부 스타일 */
.gallery-section {
    background-color: #f8f8f8; /* 갤러리 배경색을 약간 다르게 */
    color: #333;
    padding-bottom: 40px; /* 하단 여백 추가 */
}

.gallery-topic {
    margin-bottom: 30px;
}

.gallery-topic h3 {
    color: #007bff; /* 주제 제목 색상 강조 */
    border-bottom: 2px solid #007bff;
    padding-bottom: 5px;
    margin-bottom: 20px;
    display: inline-block; /* h3 밑줄을 텍스트 길이만큼만 */
    text-align: center;
    width: auto;
}

.gallery-content {
    display: flex;
    flex-wrap: wrap; /* 내용이 많으면 다음 줄로 넘어감 */
    justify-content: center; /* 가운데 정렬 */
    gap: 20px; /* 항목 간 간격 */
}

.gallery-content img {
    max-width: 100%; /* 반응형 이미지 */
    height: auto;
    object-fit: cover; /* 비율 유지하며 채우기 */
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    flex: 1 1 calc(50% - 20px); /* 2개씩 배치 (작은 화면에서 1개) */
    min-width: 280px; /* 최소 너비 */
}

/* 오시는 길 섹션 스타일 */
.map-container {
    height: 400px; /* 지도의 세로 크기 */
    width: 100%;
    margin-bottom: 20px;
    background-color: #eee;
    border: 1px solid #ddd;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.address-info {
    text-align: center;
    line-height: 1.6;
}

/* HTML <img> 태그에 대한 CSS */
.twinkling-star {
    position: absolute; /* 부모 요소(autumn-night-gradient) 기준으로 위치 지정 */
    width: 80px; /* 별 이미지 크기 */
    height: 80px;
    opacity: 0.8; /* 투명도 조절 */
    animation: twinkle 2s infinite alternate; /* 반짝이는 애니메이션 (아래 참고) */
}

.star-1 {
    top: 10%;
    left: 5%;
    width: 3rem;
    height: 3rem;
}

.star-2 {
    top: 10%;
    right: 5%;
    width: 3rem; /* 다른 별은 크기를 다르게 */
    height: 3rem;
    animation-delay: 1s; /* 애니메이션 시작 시간 지연 */
}

/* 별이 반짝이는 애니메이션 (선택 사항) */
@keyframes twinkle {
    from { opacity: 0.5; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1.1); }
}

/* 반응형 디자인을 위한 미디어 쿼리 */
@media (max-width: 768px) {
    .icon-section {
        justify-content: space-around;
    }

    .icon-item {
        flex-basis: 30%; /* 모바일 화면에서 아이콘 크기 조정 */
        margin: 10px 5px;
    }
	
	.gallery-content img,
    .youtube-video-container {
        flex: 1 1 100%; /* 모바일에서는 1개씩 배치 */
    }
	.youtube-shorts-container { /* Shorts 컨테이너 추가 */
        flex: 1 1 100%; /* 모바일에서는 1개씩 배치 */
        max-width: 100%;
    }
    
}
