/* 게시판 스타일.
   사이트 CSS(layout/responsive) 위에 얹히므로 게시판 범위만 좁게 잡는다.
   프로젝트 규칙: 12px 미만 글자 금지, 터치 타깃 40x40 이상, 360px 에서 가로 스크롤 금지.
   표는 .table-scroll 래퍼 안에서만 가로로 스크롤한다. */

.bd { --bd-ink:#242424; --bd-muted:#6b7280; --bd-line:#e3e6ea; --bd-accent:#55a13f;
      color:var(--bd-ink); font-size:15px; line-height:1.7; }
.bd * { box-sizing:border-box; }

/* 검색 */
.bd-search { display:flex; flex-wrap:wrap; gap:8px; justify-content:flex-end;
             align-items:center; margin:0 0 16px; }
.bd-search input[type=text] { flex:1 1 180px; min-width:0; height:42px; padding:0 12px;
             border:1px solid var(--bd-line); border-radius:4px; font-size:15px; }
.bd-search button { height:42px; min-width:64px; padding:0 18px; border:0; cursor:pointer;
             background:var(--bd-ink); color:#fff; border-radius:4px; font-size:15px; }
.bd-count { margin-right:auto; color:var(--bd-muted); font-size:14px; }

/* 표 */
.table-scroll { width:100%; overflow-x:auto; -webkit-overflow-scrolling:touch; }
table.bd-table { width:100%; min-width:560px; border-collapse:collapse; }
table.bd-table th, table.bd-table td { padding:13px 10px; border-bottom:1px solid var(--bd-line);
             font-size:15px; text-align:center; }
table.bd-table thead th { background:#f7f8f9; border-top:2px solid var(--bd-ink);
             font-weight:700; white-space:nowrap; }
table.bd-table td.subject { text-align:left; }
table.bd-table td.subject a { color:var(--bd-ink); text-decoration:none;
             display:inline-block; min-height:24px; }
table.bd-table td.subject a:hover { text-decoration:underline; }
table.bd-table .num, table.bd-table .date, table.bd-table .hit { color:var(--bd-muted);
             white-space:nowrap; font-size:14px; }
.bd-fixed { display:inline-block; margin-right:6px; padding:2px 8px; border-radius:3px;
             background:var(--bd-accent); color:#fff; font-size:12px; vertical-align:middle; }
.bd-clip { margin-left:6px; color:var(--bd-muted); font-size:13px; }
.bd-empty { padding:60px 20px; text-align:center; color:var(--bd-muted); }

/* 읽기 */
.bd-head { border-top:2px solid var(--bd-ink); border-bottom:1px solid var(--bd-line);
             padding:18px 4px; }
.bd-head h3 { margin:0 0 8px; font-size:19px; line-height:1.45; word-break:keep-all; }
.bd-meta { color:var(--bd-muted); font-size:14px; }
.bd-meta span + span::before { content:"·"; margin:0 7px; }
.bd-body { padding:26px 4px; min-height:160px; word-break:break-word; }
.bd-body img { max-width:100%; height:auto; }
.bd-files { border-top:1px solid var(--bd-line); padding:14px 4px; }
.bd-files a { display:inline-flex; align-items:center; min-height:40px; padding:0 4px;
             color:var(--bd-ink); font-size:15px; }
.bd-files .size { color:var(--bd-muted); font-size:13px; margin-left:8px; }

/* 갤러리 */
.bd-grid { display:grid; grid-template-columns:repeat(auto-fill, minmax(210px, 1fr));
             gap:20px; }
.bd-card { border:1px solid var(--bd-line); border-radius:6px; overflow:hidden;
             background:#fff; }
.bd-card a { display:block; text-decoration:none; color:var(--bd-ink); }
.bd-thumb { aspect-ratio:4/3; background:#f2f4f6; display:flex; align-items:center;
             justify-content:center; overflow:hidden; }
.bd-thumb img { width:100%; height:100%; object-fit:cover; }
.bd-thumb .noimg { color:#9aa3ae; font-size:14px; }
.bd-card .cap { padding:12px 13px; }
.bd-card .cap strong { display:block; font-size:15px; font-weight:600; line-height:1.5;
             word-break:keep-all; }
.bd-card .cap em { display:block; margin-top:5px; color:var(--bd-muted);
             font-size:13px; font-style:normal; }

/* 버튼 · 페이지 */
.bd-actions { display:flex; flex-wrap:wrap; gap:8px; justify-content:space-between;
             margin:22px 0 0; }
.bd-btn { display:inline-flex; align-items:center; justify-content:center; min-height:44px;
             padding:0 20px; border:1px solid var(--bd-line); border-radius:4px;
             background:#fff; color:var(--bd-ink); font-size:15px; text-decoration:none;
             cursor:pointer; }
.bd-btn.primary { background:var(--bd-ink); border-color:var(--bd-ink); color:#fff; }
.bd-nav { display:flex; flex-wrap:wrap; gap:8px; }
.bd-pager { display:flex; flex-wrap:wrap; gap:6px; justify-content:center; margin:26px 0 0; }
.bd-pager a, .bd-pager strong { display:inline-flex; align-items:center; justify-content:center;
             min-width:40px; min-height:40px; padding:0 6px; border:1px solid var(--bd-line);
             border-radius:4px; color:var(--bd-ink); text-decoration:none; font-size:15px; }
.bd-pager strong { background:var(--bd-ink); border-color:var(--bd-ink); color:#fff; }

/* 폼 (문의) */
.bd-form { max-width:720px; margin:0 auto; }
.bd-form .row2 { display:flex; flex-wrap:wrap; gap:14px; }
.bd-form .row2 > .field { flex:1 1 220px; min-width:0; }
.bd-form .field { margin:0 0 15px; }
.bd-form label { display:block; margin:0 0 6px; font-size:14px; font-weight:600; }
.bd-form label .req { color:#c0392b; margin-left:3px; }
.bd-form input[type=text], .bd-form input[type=email], .bd-form input[type=tel],
.bd-form textarea { width:100%; padding:11px 12px; border:1px solid var(--bd-line);
             border-radius:4px; font-size:15px; font-family:inherit; background:#fff; }
.bd-form textarea { min-height:190px; resize:vertical; line-height:1.7; }
.bd-form .hint { margin:6px 0 0; color:var(--bd-muted); font-size:13px; }
.bd-privacy { border:1px solid var(--bd-line); border-radius:6px; padding:14px 16px;
             margin:6px 0 18px; background:#fafbfc; }
.bd-privacy .box { max-height:120px; overflow-y:auto; color:var(--bd-muted);
             font-size:13px; line-height:1.75; margin:0 0 10px; }
.bd-privacy label { display:flex; align-items:center; gap:8px; min-height:40px;
             margin:0; font-size:15px; font-weight:600; cursor:pointer; }
.bd-privacy input[type=checkbox] { width:18px; height:18px; }
.bd-alert { border-radius:5px; padding:13px 16px; margin:0 0 18px; font-size:14px;
             line-height:1.7; }
.bd-alert.error { background:#fdecea; color:#8e2b21; }
.bd-alert.ok { background:#eaf6e8; color:#2f6d24; }
.bd-alert ul { margin:0; padding-left:19px; }
.bd-done { text-align:center; padding:56px 16px; }
.bd-done h3 { margin:0 0 12px; font-size:21px; }
.bd-done p { margin:0 0 26px; color:var(--bd-muted); }

@media (max-width:768px) {
  .bd { font-size:14px; }
  .bd-search { justify-content:stretch; }
  .bd-count { width:100%; margin:0 0 4px; }
  .bd-head h3 { font-size:17px; }
  .bd-grid { grid-template-columns:repeat(auto-fill, minmax(150px, 1fr)); gap:14px; }
  .bd-actions { flex-direction:column-reverse; }
  .bd-actions .bd-nav { width:100%; }
  .bd-actions .bd-btn { width:100%; }
  .bd-form .row2 { gap:0; }
}
