/**
 * 본문 HTML(정화 결과) 공통 꾸밈 (P9-1 설계 4-4, 규칙 8-7)
 * 사용 화면 : 사용자 게시물 상세(user/post/postDetail.jsp). 이후 콘텐츠·미리보기가 읽는다.
 * 작성      : njjang83 2026.10.31
 * 수정      : njjang83 2026.11.04 편집기 본문 CSS(weditor-content.min.css)가 읽는 변수를 사이트 값으로 잇는다 (P14-1B Task 6, 설계 6-2-5)
 * 수정      : njjang83 2026.11.05 본문 줄바꿈 normal, 꼬리 문구만 pre-wrap (P14-8 Task 4)
 * .editor-content 아래에만 둔다. 정화가 남기는 클래스 13개(align 4, valign 3, width 4, float 2)만 꾸민다.
 */

/* ===== 본문 바깥 요소 ===== */
.editor-content {
    /* 본문은 wEditor가 문단(p)·줄바꿈(br)으로 저장하고 글자 모드 글도 저장 때 br로 바뀐다(toHtmlFromText). HTML 소스의 줄바꿈·들여쓰기는 공백이다(P14-8 D5) */
    white-space: normal;
    overflow-wrap: anywhere;
    /* 편집기 본문 CSS(weditor-content.min.css, 이 파일 다음에 읽는다)의 글꼴은 사이트 글꼴 변수를 따른다(원칙 14-8: 제품 CSS가 글꼴을 직접 정하지 않는다).
       글자색·바탕은 테마의 본문 색을 그대로 물려받는다. 글자색은 inherit가 아니라 currentColor다: 사용자 속성의 inherit는 부모의 같은 변수(없음)를 물려받아
       편집기 CSS의 기본 글자색(#1f2328)으로 떨어지지만, currentColor는 color 자리에서 물려받은 글자색이 된다 */
    --weditor-font: var(--site-font-family);
    --weditor-color: currentColor;
    --weditor-bg: transparent;
}

/* 꼬리 문구는 편집기 없는 글 상자라 관리자가 친 줄바꿈이 뜻을 가진다 */
.editor-content.site-copyright {
    white-space: pre-wrap;
}

.editor-content p,
.editor-content ul,
.editor-content ol,
.editor-content blockquote,
.editor-content table,
.editor-content figure {
    margin: 0 0 1em;
}

.editor-content img {
    max-width: 100%;
    height: auto;
}

/* ===== 표 ===== */
.editor-content table {
    border-collapse: collapse;
    max-width: 100%;
}

.editor-content th,
.editor-content td {
    border: 1px solid #c8ced6;
    padding: 0.4em 0.6em;
}

/* ===== 정렬 ===== */
.editor-content .editor-align-left { text-align: left; }
.editor-content .editor-align-center { text-align: center; }
.editor-content .editor-align-right { text-align: right; }
.editor-content .editor-align-justify { text-align: justify; }

/* ===== 표 칸 세로 정렬 ===== */
.editor-content .editor-valign-top { vertical-align: top; }
.editor-content .editor-valign-middle { vertical-align: middle; }
.editor-content .editor-valign-bottom { vertical-align: bottom; }

/* ===== 폭(25% 단위) ===== */
.editor-content .editor-width-25 { width: 25%; }
.editor-content .editor-width-50 { width: 50%; }
.editor-content .editor-width-75 { width: 75%; }
.editor-content .editor-width-100 { width: 100%; }

/* ===== 그림 띄우기 ===== */
.editor-content .editor-float-left { float: left; margin: 0 1em 0.5em 0; }
.editor-content .editor-float-right { float: right; margin: 0 0 0.5em 1em; }
