/* ===========================================================
   board2.css (Scoped by .board-scope)
   -----------------------------------------------------------
   - 다크 테마(배경 #1c1c1c) 기반
   - 전역 충돌 방지 위해 .board-scope를 접두로 사용
   =========================================================== */

/* 
   .board-scope : 게시판 전체 래퍼
   - 배경 #1c1c1c (어두운 톤)
   - 기본 텍스트 색상은 흰색(#fff)
   - 전체 줄 간격 1.5
*/
.board-scope {
  background: #1c1c1c; /* 다크 배경 */
  color: #fff;         /* 기본 텍스트: 흰색 */
  line-height: 1.5;
}

/*
   .board-scope * : 
   - 마진/패딩 초기화, box-sizing, 폰트 지정
*/
.board-scope * {
  margin: 0; 
  padding: 0; 
  box-sizing: border-box;
  font-family: sans-serif;
}

/*
   .board-scope .container :
   - 가로 폭 제한(최대 1024px)
   - 내부 여백 1rem
*/
.board-scope .container {
  width: 100%;
  max-width: 1024px;
  margin: 0 auto;
  padding: 1rem;
}

/* 
   공통 버튼 / 링크 (btn-link)
   - 배경 투명
   - 테두리는 짙은 회색(#444)
   - 호버 시 조금 더 밝은 배경 + 포인트 색(#1a73e8)
*/
.board-scope .btn-link,
.board-scope a.btn-link {
  display: inline-block;
  padding: 0.45rem 0.8rem;
  margin-right: 0.25rem;
  text-decoration: none;
  border: 1px solid #444;    /* 테두리: 짙은 회색 */
  background: transparent;
  color: #ccc;               /* 기본 텍스트: 밝은 회색 */
  font-size: 0.9rem;
  border-radius: 4px;
  transition: all 0.25s ease;
}
.board-scope .btn-link:hover {
  background: #2a2a2a;       /* 호버 시 약간 밝은 톤 */
  border-color: #1a73e8;     /* 파랑 포인트 */
  color: #fff;               /* 흰색으로 반전 */
}

/*
   버튼 영역(주로 목록·쓰기·수정 등)
*/
.board-scope .btn-area {
  margin-bottom: 1rem;
}

/* ------------------------------------
   table (기본 text형 목록)
------------------------------------- */
/*
   기본 표(table):
   - 배경 투명
   - 테두리: #444
   - 헤더는 #2a2a2a 배경 + 흰색 텍스트
*/
.board-scope table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid #444;   /* 어두운 테두리 */
  margin-top: 0.8rem;
  background: transparent;
}
.board-scope table thead th {
  background: #2a2a2a;      /* 헤더 셀 배경 */
  color: #fff;              /* 헤더 텍스트 흰색 */
  padding: 0.75rem;
  border-bottom: 1px solid #555;
  text-align: center;
  font-weight: 600;
}
.board-scope table tbody td {
  padding: 0.75rem;
  border-bottom: 1px solid #333; /* 본문 셀 구분선 */
  vertical-align: middle;
  color: #ccc;
}
.board-scope table tbody tr:hover {
  background: #2a2a2a;      /* 마우스 오버 시 */
}
.board-scope table a {
  color: #1a73e8;           /* 링크: 파랑 포인트 */
}
.board-scope table a:hover {
  text-decoration: underline;
}

/* ------------------------------------
   그리드(grid) 목록
------------------------------------- */
.board-scope .grid-container {
  display: grid;
  gap: 1rem;
  margin-top: 1rem;
}

/* data-cols로 열 개수 설정 */
.board-scope .grid-container[data-cols="2"] {
  grid-template-columns: repeat(2, 1fr);
}
.board-scope .grid-container[data-cols="3"] {
  grid-template-columns: repeat(3, 1fr);
}
.board-scope .grid-container[data-cols="4"] {
  grid-template-columns: repeat(4, 1fr);
}
.board-scope .grid-container[data-cols="5"] {
  grid-template-columns: repeat(5, 1fr);
}

/*
   그리드 아이템
   - 배경 투명
   - 테두리 #444
*/
.board-scope .grid-item {
  background: transparent;
  border: 1px solid #444;
  border-radius: 4px;
  padding: 0.75rem;
  text-align: center;
  transition: box-shadow 0.2s;
}
.board-scope .grid-item:hover {
  box-shadow: 0 3px 8px rgba(255,255,255,0.08);
}
.board-scope .grid-item img {
  display: block;
  margin: 0 auto 0.5rem auto;
}
.board-scope .grid-item h3 {
  margin: 0.5rem 0;
  font-size: 1.1rem;
  color: #fff;
}
.board-scope .grid-item p {
  font-size: 0.85rem;
  color: #ccc;
}

/* ------------------------------------
   썸네일(thumbnail) 목록
------------------------------------- */
.board-scope .thumb-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid #444;
}
.board-scope .thumb-item img {
  border: 1px solid #666;
  background: #2a2a2a;
  border-radius: 4px;
  display: block;
}
.board-scope .thumb-item h3 {
  margin-bottom: 0.3rem;
  font-size: 1.1rem;
  color: #fff;
}
.board-scope .thumb-item p {
  font-size: 0.85rem;
  color: #ccc;
  line-height: 1.4;
}
.board-scope .thumb-item a {
  text-decoration: none;
  color: #1a73e8; /* 링크 파랑 */
}
.board-scope .thumb-item a:hover {
  text-decoration: underline;
}

/* ------------------------------------
   블로그(blog) 목록
------------------------------------- */
.board-scope .blog-item {
  background: transparent;
  border: 1px solid #444;
  border-radius: 4px;
  padding: 1rem;
  margin: 0.8rem 0;
  transition: box-shadow 0.2s;
}
.board-scope .blog-item:hover {
  box-shadow: 0 3px 8px rgba(255,255,255,0.08);
}
.board-scope .blog-item h2 {
  margin-bottom: 0.6rem;
  font-size: 1.3rem;
  color: #fff;
}
.board-scope .blog-item img {
  display: block;
  margin: 0.5rem 0;
  border-radius: 4px;
  border: 1px solid #666;
  background: #2a2a2a;
}
.board-scope .blog-item p {
  font-size: 0.9rem;
  color: #ccc;
  margin-bottom: 0.5rem;
}

/* ------------------------------------
   글 보기(게시글 읽기)
------------------------------------- */
.board-scope .post-view {
  background: transparent;
  border: 1px solid #444;
  border-radius: 4px;
  padding: 1.5rem;
  margin-top: 1rem;
  box-shadow: 0 2px 5px rgba(255,255,255,0.05);
}

/* 게시글 제목 */
.board-scope .post-title {
  font-size: 1.6rem;
  font-weight: bold;
  margin-bottom: 0.75rem;
  color: #fff;
  line-height: 1.3;
}

/* 게시글 메타정보 (작성일·작성자 등) */
.board-scope .post-meta {
  margin-bottom: 1rem;
  font-size: 0.85rem;
  color: #999;
  border-bottom: 1px solid #444;
  padding-bottom: 0.5rem;
}

/* 게시글 실제 내용 */
.board-scope .post-content {
  font-size: 0.95rem;
  line-height: 1.6;
  color: #ccc;
}

/* 게시글 내 이미지 */
.board-scope .post-image {
  margin: 1rem 0;
  border: 1px solid #666;
  display: block;
  width: 100%;
  max-width: 100%;
  border-radius: 4px;
  box-shadow: 0 1px 3px rgba(255,255,255,0.08);
  transition: box-shadow 0.2s;
}
.board-scope .post-image:hover {
  box-shadow: 0 3px 6px rgba(255,255,255,0.12);
}

/* ------------------------------------
   글쓰기/수정 폼
------------------------------------- */
.board-scope form p {
  margin-bottom: 1rem;
}
.board-scope form label {
  display: inline-block;
  margin-bottom: 0.3rem;
  font-weight: 600;
  color: #ccc;
}
.board-scope form input[type="text"],
.board-scope form input[type="file"],
.board-scope form textarea {
  width: 100%;
  padding: 0.6rem;
  border: 1px solid #666;
  border-radius: 4px;
  font-size: 0.9rem;
  background: #2a2a2a;
  color: #fff;
}
.board-scope form textarea {
  resize: vertical; /* 세로 크기 조절 */
}
.board-scope form button {
  padding: 0.6rem 1.2rem;
  border: none;
  border-radius: 4px;
  background: #1a73e8; /* 파랑 */
  color: #fff;
  cursor: pointer;
  font-size: 0.9rem;
  transition: background 0.2s;
}
.board-scope form button:hover {
  background: #1358ac; /* 더 진한 파랑 */
}

/* ------------------------------------
   반응형 (<= 768px)
------------------------------------- */
@media (max-width: 768px) {
  /* 그리드 항목은 2열 강제 */
  .board-scope .grid-container {
    grid-template-columns: repeat(2, 1fr) !important;
  }
  /* 썸네일 레이아웃은 세로 배치 */
  .board-scope .thumb-item {
    flex-direction: column;
  }
}
