/* ============================================================
   community 공통 CSS — admin-service /page/community/* 페이지 단일 룩
   ------------------------------------------------------------
   대상 페이지:
     - /page/community/inquiry         (1:1문의 — dual-grid + 답변 폼)
     - /page/community/advertisement   (제휴광고문의 — dual-grid + 답변 폼)
     - /page/community/service-center  (고객센터 — 사용자매뉴얼/공지사항 2탭)
     - manage/communityView            (커뮤니티 — 운영 메뉴)

   사상:
     - 외곽(.conts-area / .dual-grid-container / .search-filter-bar / .detail-panel)
       은 grid-common.css 단일 정본 그대로 사용.
     - manage 페이지 공용 컴포넌트(.admin-tab / 모달 등)는 manage-common.css 가 담당.
     - 이 파일은 community 페이지에서 반복되는 컴포넌트만 단일 정의:
       * 첨부 영역 (.attach-area / .answer-file-wrap)
       * 디테일 푸터 안의 체크그룹/버튼그룹 (.checkbox-group / .button-group)
       * 본문 HTML 뷰어 (.ql-editor-readonly)
       * 코멘트/답변 페이저 (.pagination-container-right .page-btn-small)
       * 답변 에디터 (#answerContentEditor)
       * 페이지 한정 hint (.cb-gap 체크박스 좌우 간격)
   ============================================================ */

/* ── 첨부 영역 — 1:1문의/광고 답변 폼 안 ───────────── */
.attach-area,
.notice-attach-area {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: 4px;
    font-size: 12px;
}

.attach-area > p,
.notice-attach-area > p {
    display: inline-block;
    margin: 0;
    color: var(--color-text-muted);
    font-size: 11px;
    white-space: nowrap;
}

.attach-area input[type="file"],
.notice-attach-area input[type="file"] {
    flex: 1;
    min-width: 0;
    font-size: 12px;
}

/* 첨부 파일 목록 */
.answer-file-wrap {
    margin-top: 6px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 12px;
}

.answer-file-wrap .file-item,
.answer-file-wrap a {
    color: var(--color-blue-600);
    text-decoration: none;
}

.answer-file-wrap .file-item:hover,
.answer-file-wrap a:hover {
    text-decoration: underline;
}

/* ── detail-panel-footer 안의 체크/버튼 묶음 ─────────
   inquiry/advertisement 의 답변 폼 푸터 표준. */
.detail-panel-footer .checkbox-group {
    display: inline-flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 14px;
    font-size: 12px;
    color: var(--color-text);
}

.detail-panel-footer .checkbox-group label {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    user-select: none;
}

.detail-panel-footer .button-group {
    margin-left: auto;
    display: inline-flex;
    gap: 6px;
}

/* community 페이지의 체크박스 좌우 간격 — 공용 토큰 */
.cb-gap {
    margin-right: 4px;
    accent-color: var(--color-blue-500);
    cursor: pointer;
}

/* ── Quill 본문 뷰어 (읽기전용) ──────────────────────── */
.ql-editor-readonly {
    font-size: 12px;
    line-height: 1.6;
    padding: 8px;
    border: 1px solid var(--color-border);
    border-radius: 4px;
    background: var(--color-bg-alt);
    color: var(--color-text);
    min-height: 80px;
    max-height: 200px;
    overflow-y: auto;
}

.ql-editor-readonly img {
    max-width: 100%;
    height: auto;
}

/* 답변 에디터 — Quill */
#answerContentEditor {
    font-size: 12px;
}

#answerContentEditor .ql-editor {
    min-height: 120px;
    font-size: 12px;
}

/* ── 코멘트/답변 페이저 (.pagination-container-right) ──
   메인 페이저(.pagination-bar-container) 와 분리된 inline 페이저. */
.pagination-container-right {
    display: flex;
    justify-content: end;
    align-items: center;
    gap: 4px;
    margin-top: 8px;
}

.pagination-container-right .page-btn-small {
    min-width: 24px;
    height: 24px;
    padding: 2px 8px;
    font-size: 12px;
    color: var(--color-text);
    background: #ffffff;
    border: 1px solid var(--color-border-strong);
    border-radius: 3px;
    cursor: pointer;
    transition: background-color 0.15s, border-color 0.15s;
}

.pagination-container-right .page-btn-small:hover {
    background-color: var(--color-bg-strong);
    border-color: var(--color-text-disabled);
    color: var(--color-text-strong);
}

.pagination-container-right .page-btn-small.active {
    background-color: var(--color-blue-500);
    border-color: var(--color-blue-500);
    color: #ffffff;
    font-weight: 600;
}

#commentPageSize {
    height: 26px;
    padding: 2px 8px;
    font-size: 12px;
    border: 1px solid var(--color-border-strong);
    border-radius: 3px;
    background: #ffffff;
    margin-left: 8px;
    cursor: pointer;
}

/* ── 고객센터 2탭 (.page-tabs / .page-tab) ──────────────
   manage-common.css 의 .admin-tab 과 동일 룩으로 정렬. */
.page-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 12px;
    border-bottom: 2px solid var(--color-border);
}

.page-tab {
    padding: 8px 20px;
    font-size: 12px;
    font-weight: 500;
    color: var(--color-text-muted);
    background-color: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-bottom: none;
    border-radius: 4px 4px 0 0;
    cursor: pointer;
    transition: background-color 0.15s, color 0.15s, border-color 0.15s;
    margin-right: -1px;
    user-select: none;
}

.page-tab:hover {
    background-color: var(--color-bg-strong);
    color: var(--color-text);
}

.page-tab.active {
    background-color: #ffffff;
    color: var(--color-text-strong);
    font-weight: 600;
    border-color: var(--color-border);
    border-bottom: 2px solid #ffffff;
    margin-bottom: -2px;
    position: relative;
    z-index: 1;
}

/* ── pagination-controls2 (고객센터 매뉴얼/공지 페이저) ─ */
.pagination-bar-container .pagination-controls2,
.pagination-controls2 {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
}

/* ── inquiry/advertisement 답변 폼의 detail-panel-section
   안 sub-제목 (.title) 표준 룩 (h4) ───────────────────── */
.detail-panel-section h4.title {
    margin: 6px 0;
    font-size: 12px;
    font-weight: 700;
    color: var(--color-text-strong);
}
