@charset "utf-8";

* {
  box-sizing: border-box;
}

.board_wrap {
  padding: 120px 20px;
}

.board_inner {
  max-width: 1280px;
  margin: 0 auto;
}

.board_inner_sm {
  max-width: 900px;
}

.board_head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 32px;
}

.board_title {
  margin: 0;
  font-size: 32px;
  font-weight: 700;
}

.board_list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.board_card {
  display: block;
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 20px;
  background: #fff;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.board_card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.08);
}

.board_card_thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 4 / 3;
  background: #eef1f5;
}

.board_card_body {
  padding: 20px;
}

.board_card_title {
  margin: 0 0 14px;
  font-size: 20px;
  line-height: 1.4;
}

.board_card_meta,
.board_view_meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  color: #666;
  font-size: 14px;
}

.board_view_meta .board_meta_item + .board_meta_item::before {
  content: '|';
  margin-right: 12px;
}

.board_view,
.board_form {
  padding: 32px;
  border: 1px solid #e5e7eb;
  border-radius: 24px;
  background: #fff;
}

.board_view_head {
  margin-bottom: 28px;
  padding-bottom: 20px;
  border-bottom: 1px solid #e5e7eb;
}

.board_view_title {
  margin: 0 0 14px;
  font-size: 32px;
  line-height: 1.35;
}

.board_view_content {
  font-size: 16px;
  line-height: 1.8;
}

.before_after_card_category {
  display: inline-block;
  margin-bottom: 8px;
  padding: 4px 10px;
  border-radius: 12px;
  background-color: #1f3d7a;
  color: #fff;
  font-size: 12px;
  font-weight: 600;
}

.before_after_details {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  margin-top: 28px;
  margin-bottom: 32px;
}

.before_info_box,
.after_info_box {
  border: 1px solid #e5e7eb;
  border-radius: 20px;
  background: #fcfdff;
  padding: 20px;
}

.before_info_box .before_after_label,
.after_info_box .before_after_label {
  display: block;
  margin-bottom: 12px;
  padding: 0; /* 기존 before_after_label의 패딩 제거 */
  border-bottom: none; /* 기존 before_after_label의 하단 테두리 제거 */
  font-size: 16px; /* 폰트 크기 조정 */
  color: #111827;
}

.before_after_info_content {
  font-size: 15px;
  line-height: 1.6;
  color: #4b5563;
  word-break: keep-all;
}

.before_after_details + .board_view_content {
  margin-top: 32px; /* 상세 정보와 본문 내용 사이 간격 */
}

.before_after_card_category.notice_badge {
  display: none;
}


.board_load_more_wrap {
  text-align: center;
  margin-top: 40px; /* 페이징 대신 더보기 버튼이므로 간격 조정 */
}



.board_form_item + .board_form_item {
  margin-top: 20px;
}

.board_label {
  display: block;
  margin-bottom: 10px;
  font-size: 15px;
  font-weight: 600;
}

.board_input,
.board_textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid #dcdfe5;
  border-radius: 14px;
  background: #fff;
  font-size: 15px;
  font-family: inherit;
}

.board_textarea {
  min-height: 280px;
  resize: vertical;
}

.board_bottom_btns {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.board_btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 120px;
  height: 48px;
  padding: 0 20px;
  border: 1px solid #d1d5db;
  border-radius: 14px;
  background: #fff;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

.board_btn_primary {
  border-color: #111;
  background: #111;
  color: #fff;
}

.board_write_title {
  font-size: 20px;
  font-weight: bold;
  padding: 20px 10px;
}

.before_after_view {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  margin-bottom: 32px;
}

.before_after_item {
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 20px;
  background: #fff;
}

.before_after_label {
  padding: 14px 18px;
  border-bottom: 1px solid #e5e7eb;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.before_after_thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 4 / 5;
  background: #f8fafc;
}

.before_after_thumb img,
.board_file_preview img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.before_after_empty {
  color: #777;
  font-size: 14px;
}

.board_file_preview {
  overflow: hidden;
  margin-top: 12px;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  aspect-ratio: 4 / 5;
  background: #f8fafc;
}

.board_view_move {
  margin-top: 32px;
  border-top: 1px solid #e5e7eb;
}

.board_move_item {
  display: flex;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid #e5e7eb;
}

.board_move_label {
  width: 70px;
  flex: 0 0 70px;
}

.board_move_link {
  flex: 1 1 auto;
}

.board_move_empty {
  color: #777;
}

/* 리스트 전후 비교 썸네일 */
.board_list_section {
  width: 100%;
}

.before_after_list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px 24px;
}

.before_after_card {
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.before_after_card:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
}

.before_after_link {
  display: block;
  color: inherit;
  text-decoration: none;
}

.before_after_compare {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 5;
  background: #f8fafc;
  user-select: none;
}

.before_after_base,
.before_after_overlay {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
}

.before_after_base {
  z-index: 1;
  width: 100%;
}

.before_after_overlay {
  z-index: 2;
  width: 50%;
  overflow: hidden;
}

.before_after_base .before_after_img,
.before_after_overlay .before_after_img {
  position: absolute;
  top: 0;
  left: 0;
  display: block;
  width: 409px;
  height: 100%;
  object-fit: cover;
}

.before_after_noimg {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  color: #64748b;
  font-size: 14px;
  background: #f1f5f9;
}

.before_after_overlay .before_after_noimg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
}

.before_after_badge {
  position: absolute;
  top: 16px;
  z-index: 4;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 78px;
  height: 34px;
  padding: 0 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #fff;
  backdrop-filter: blur(8px);
}

.before_badge {
  left: 16px;
  background: rgba(15, 23, 42, 0.72);
}

.after_badge {
  right: 16px;
  background: rgba(17, 24, 39, 0.72);
}

.before_after_divider {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  z-index: 5;
  width: 0;
  cursor: ew-resize;
}

.before_after_divider::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: -1px;
  width: 2px;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.08);
}

.before_after_handle {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 42px;
  height: 42px;
  border: 2px solid #fff;
  border-radius: 50%;
  background: rgba(17, 24, 39, 0.72);
  transform: translate(-50%, -50%);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.18);
}

.before_after_handle::before,
.before_after_handle::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 8px;
  height: 8px;
  border-top: 2px solid #fff;
  border-right: 2px solid #fff;
}

.before_after_handle::before {
  left: 10px;
  transform: translateY(-50%) rotate(225deg);
}

.before_after_handle::after {
  right: 10px;
  transform: translateY(-50%) rotate(45deg);
}

.before_after_card_body {
  padding: 20px 20px 22px;
}

.before_after_card_title {
  margin: 0 0 12px;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.45;
  color: #111827;
}

.before_after_card_meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  font-size: 14px;
  color: #6b7280;
}

.board_empty {
  padding: 60px 20px;
  border: 1px solid #e5e7eb;
  border-radius: 24px;
  background: #fff;
  text-align: center;
  color: #6b7280;
  font-size: 16px;
}

.board_paging {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 40px;
}

.board_page_btn,
.board_page_num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  height: 44px;
  padding: 0 14px;
  border: 1px solid #d1d5db;
  border-radius: 12px;
  background: #fff;
  color: #111827;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.2s ease;
}

.board_page_btn:hover,
.board_page_num:hover,
.board_page_num.is_active {
  border-color: #111827;
  background: #111827;
  color: #fff;
}

/* 분류 필터 */
.board_category {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 28px;
}

.board_category_btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid #e5e7eb;
  background: #fff;
  font-size: 13px;
  color: #374151;
  transition: all 0.2s ease;
}

.board_category_btn:hover {
  border-color: #111;
  color: #111;
}

.board_category_btn.is_active {
  background: #111;
  color: #fff;
  border-color: #111;
}

@media (max-width: 1200px) {
  .before_after_list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  
  .before_after_base .before_after_img, .before_after_overlay .before_after_img {
    left: 50%;
    position: unset;
  }
}

@media (max-width: 768px) {
  .board_wrap {
    padding: 120px 16px 40px;
  }

  .board_head {
    flex-direction: column;
    align-items: flex-start;
  }

  .board_title,
  .board_view_title {
    font-size: 26px;
  }

  .board_list {
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 16px;
  }

  .board_view,
  .board_form {
    padding: 24px 18px;
    border-radius: 18px;
  }

  .board_btn {
    width: 100%;
  }

  .before_after_view {
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 16px;
  }

  .before_after_details {
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 16px;
  }

  .board_move_item {
    flex-direction: column;
    gap: 8px;
  }

  .board_move_label {
    width: auto;
    flex: none;
  }

  .before_after_list {
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 18px;
  }

  .before_after_card {
    border-radius: 20px;
  }

  .before_after_card_body {
    padding: 18px 16px 20px;
  }

  .before_after_card_title {
    font-size: 18px;
  }

  .before_after_badge {
    top: 12px;
    min-width: 70px;
    height: 30px;
    padding: 0 12px;
    font-size: 11px;
  }

  .before_badge {
    left: 12px;
  }

  .after_badge {
    right: 12px;
  }

  .before_after_handle {
    width: 38px;
    height: 38px;
  }
}