/*
 * 전역 설정
 */
body, html {
    margin: 0;
    padding: 0;
    font-family: 'AppleSDGothicNeo-Regular', 'Malgun Gothic', '맑은 고딕', dotum, '돋움', sans-serif;
    background-color: #f0f2f5;
}

.wrapper h2 span {
    color: #d9534f;
}
/*
 * 라이트박스 오버레이 (주석 처리된 position: fixed는 복원하지 않았습니다.)
 */
.lightbox-overlay {
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px;
    box-sizing: border-box;
    overflow-y: auto;
}

.lightbox-content {
    background: #fff;
    padding: 20px 15px;
    border-radius: 10px;
    max-width: 800px;
    width: 100%;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
    position: relative;
}

.close-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 30px;
    font-weight: bold;
    color: #888;
    cursor: pointer;
    text-decoration: none;
}

/*
 * 게시글 컨테이너
 */
.post-container {
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
    margin-bottom: 10px;
}

.post-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    color: #666;
    font-size: 0.9em;
}

.post-author {
    font-weight: bold;
}

.post-author strong {
    color: #0056b3;
    font-size: 16px;
}

.post-body p {
    /*white-space: pre-wrap;*/
    line-height: 1.4;
    color: #333;
}

.post-body img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin-top: 15px;
    max-height: 500px;
    object-fit: cover;  /* 필요시 이미지를 잘라서 맞출 때 */
}

.youtube-embed {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    margin-top: 15px;
    border-radius: 8px;
}

.youtube-embed iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/*
 * 댓글 섹션
 */
.comments-section h3 {
    margin-top: 0;
}

.comments-list {
    padding-right: 10px;
}

.comment {
    border-bottom: 1px solid #f0f0f0;
    padding: 12px 0;
}

.comment:last-child {
    border-bottom: none;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    font-size: 0.95em;
    color: #777;
    margin-bottom: 5px;
}

.comment-author {
    font-weight: bold;
    color: #444;
}

.comment-body {
    word-wrap: break-word;
    line-height: 1.4;
}

.comment-form-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.comment-form input, .comment-form textarea,
.reply-form-container input, .reply-form-container textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box;
}
.comment-form input[type="text"] {
    height: 25px;
}

.comment-form button,
.reply-form-container form button {
    padding: 10px;
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-top: 0;
    font-size: 0.9em;
}
/*
 * 캡차
 */
.captcha-container {
    display: flex;
    align-items: center;
    gap: 10px;
}

.captcha-label {
    height: 20px;
    line-height: 20px;
    font-size: 14px !important;
    font-weight: normal !important;
    color: blue !important;
}

.captcha-input {
    height: 22px;
    width: 70px !important;
    padding: 0px !important;
}

/*
 * 광고 컨테이너
 */
.flex-ad-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 30px;
    flex-wrap: wrap;
}

.ad-container-mobl {
    display: none;
}

/*
 * 반응형 디자인 - 모바일
 */
@media (max-width: 768px) {
    .flex-ad-wrapper {
        gap: 0;
    }

    .post-body p {
        font-size: 0.95em;
    }

    .comment-body {
        font-size: 0.95em;
    }
}

@media (max-width: 740px) {
    .flex-ad-wrapper {
        gap: 0;
    }

    .ad-container {
        margin: 15px 0;
    }

    .ad-container-desktop {
        display: none;
    }

    .ad-container-mobl {
        display: block !important;
    }
}

@media (max-width: 610px) {
	.post-body img {
		max-height: 320px;
	}
}