@charset "utf-8";
/**
 * Eoingti Board FAQ - FAQ 아코디언 게시판
 * @author 어잉티연구소 https://eoingti.com
 */

/* =============================================
   1. 공통 버튼
============================================= */
a.kboard-eoingti-board-faq-button-small,
input.kboard-eoingti-board-faq-button-small,
button.kboard-eoingti-board-faq-button-small {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 6px; margin: 0; padding: 10px 20px; min-height: 38px;
  font-size: 14px; font-weight: 500; color: #333 !important;
  background: #fff !important; border: 1px solid #e0e0e0; border-radius: 6px;
  text-decoration: none !important; cursor: pointer;
  transition: all 0.25s ease; box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
a.kboard-eoingti-board-faq-button-small:hover,
input.kboard-eoingti-board-faq-button-small:hover,
button.kboard-eoingti-board-faq-button-small:hover {
  background: #f8f9fa !important; border-color: #d0d0d0;
  transform: translateY(-1px); box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}
.kboard-eoingti-board-faq-button-save { color: #667eea !important; border-color: #667eea !important; }
.kboard-eoingti-board-faq-button-save:hover { background: rgba(102,126,234,0.08) !important; }

/* =============================================
   2. 목록 래퍼
============================================= */
#kboard-eoingti-board-faq-list {
  width: 100%; max-width: 900px; margin: 0 auto; padding: 30px 20px;
}
#kboard-eoingti-board-faq-list ul,
.ebf-pages { margin: 0 !important; padding: 0 !important; list-style: none !important; }
#kboard-eoingti-board-faq-list form { margin: 0; padding: 0; }

/* =============================================
   3. 카테고리
============================================= */
.kboard-category { padding: 0 !important; margin-bottom: 24px; }
.kboard-category-list {
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: 8px; padding: 14px 16px; list-style: none;
  background: #fff; border-radius: 8px; box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.kboard-category-list li { margin: 0; list-style: none; }
.kboard-category-list li a {
  display: inline-flex; align-items: center; padding: 7px 16px;
  font-size: 14px; font-weight: 500; color: #666;
  background: #f8f9fa; border: 1px solid transparent; border-radius: 20px;
  text-decoration: none !important; transition: all 0.2s;
}
.kboard-category-list li a:hover { color: #667eea; background: rgba(102,126,234,0.1); border-color: #667eea; }
.kboard-category-list li.kboard-category-selected a { background: #eef1ff; color: #4a55a2; border-color: #dce1f7; font-weight: 600; }

/* =============================================
   4. 검색
============================================= */
.ebf-search { margin-bottom: 28px; }
.ebf-search-inner {
  display: flex; align-items: center; gap: 0;
  background: #fff; border: 1.5px solid #e0e0e0; border-radius: 10px;
  padding: 0 16px; transition: border-color 0.2s;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.ebf-search-inner:focus-within { border-color: #667eea; box-shadow: 0 0 0 3px rgba(102,126,234,0.1); }
.ebf-search-icon { color: #aaa; font-size: 18px; flex-shrink: 0; }
.ebf-search-inner input[type="text"] {
  flex: 1; height: 48px; padding: 0 12px; font-size: 15px;
  border: none; background: transparent; color: #333; outline: none;
}
.ebf-search-inner input[type="text"]::placeholder { color: #bbb; }
.ebf-search-inner button {
  flex-shrink: 0; padding: 8px 20px; height: 34px;
  font-size: 14px; font-weight: 500; color: #fff !important;
  background: #667eea !important; border: none; border-radius: 6px;
  cursor: pointer; transition: background 0.2s;
}
.ebf-search-inner button:hover { background: #4a55a2 !important; }

/* 검색 영역 다크모드 유지 */
.ebf-search { color-scheme: light; }
.ebf-search-inner, .ebf-search-inner input { color-scheme: light; background: #fff !important; color: #333 !important; }

/* =============================================
   5. 아코디언
============================================= */
.ebf-accordion-wrap { margin-bottom: 24px; }

.ebf-item {
  background: #fff; border-radius: 10px; margin-bottom: 10px;
  border: 1.5px solid #f0f0f0; overflow: hidden;
  transition: border-color 0.2s, box-shadow 0.2s;
  animation: ebfFadeIn 0.4s ease-out;
}
.ebf-item:hover { border-color: #dce1f7; box-shadow: 0 2px 10px rgba(102,126,234,0.08); }
.ebf-item.ebf-open { border-color: #667eea; box-shadow: 0 4px 16px rgba(102,126,234,0.12); }
.ebf-item.ebf-notice { border-color: #ffd700; background: #fffef5; }
.ebf-item.ebf-notice.ebf-open { border-color: #f5a623; }

@keyframes ebfFadeIn { from { opacity:0; transform:translateY(6px); } to { opacity:1; transform:translateY(0); } }

/* 질문 버튼 */
.ebf-question {
  width: 100%; display: flex; align-items: center; gap: 14px;
  padding: 18px 20px; background: none; border: none; cursor: pointer;
  text-align: left; transition: background 0.2s;
}
.ebf-question:hover { background: rgba(102,126,234,0.03); }
.ebf-item.ebf-open .ebf-question { background: rgba(102,126,234,0.05); }

.ebf-q-icon {
  flex-shrink: 0; width: 32px; height: 32px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 700; color: #667eea;
  background: rgba(102,126,234,0.1); transition: all 0.2s;
}
.ebf-item.ebf-open .ebf-q-icon { background: #667eea; color: #fff; }
.ebf-item.ebf-notice .ebf-q-icon { color: #f5a623; background: rgba(245,166,35,0.1); }
.ebf-item.ebf-notice.ebf-open .ebf-q-icon { background: #f5a623; color: #fff; }

.ebf-q-text {
  flex: 1; font-size: 15px; font-weight: 500; color: #222; line-height: 1.5;
}
.ebf-item.ebf-open .ebf-q-text { color: #667eea; font-weight: 600; }

.ebf-new {
  display: inline-flex; align-items: center; justify-content: center;
  width: 16px; height: 16px; background: #FFB4B4; color: #7B2D2D;
  font-size: 10px; font-weight: 700; border-radius: 3px; margin-right: 6px; vertical-align: middle;
}
.ebf-notice-badge {
  display: inline-flex; align-items: center; padding: 2px 8px;
  font-size: 11px; font-weight: 700; color: #f5a623;
  background: rgba(245,166,35,0.12); border-radius: 4px; margin-right: 8px; vertical-align: middle;
}

.ebf-category {
  flex-shrink: 0; font-size: 12px; color: #999;
  background: #f5f5f5; padding: 4px 10px; border-radius: 12px;
}
.ebf-date { flex-shrink: 0; font-size: 12px; color: #bbb; }
.ebf-arrow {
  flex-shrink: 0; font-size: 20px; color: #bbb;
  transition: transform 0.3s ease;
}
.ebf-item.ebf-open .ebf-arrow { transform: rotate(180deg); color: #667eea; }

/* 답변 패널 */
.ebf-answer { border-top: 1px solid #f0f0f0; }
.ebf-item.ebf-open .ebf-answer { border-top-color: rgba(102,126,234,0.15); }
.ebf-answer-inner {
  display: flex; gap: 14px; padding: 20px;
  background: rgba(102,126,234,0.02);
}
.ebf-item.ebf-notice .ebf-answer-inner { background: rgba(245,166,35,0.03); }

.ebf-a-icon {
  flex-shrink: 0; width: 32px; height: 32px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 700; color: #fff;
  background: #667eea; margin-top: 2px;
}
.ebf-item.ebf-notice .ebf-a-icon { background: #f5a623; }

.ebf-a-content {
  flex: 1; font-size: 15px; line-height: 1.8; color: #444; word-break: break-word;
}
.ebf-a-content p { margin: 0 0 0.8em; }
.ebf-a-content p:last-child { margin: 0; }
.ebf-a-content img { max-width: 100%; border-radius: 6px; margin: 8px 0; }

/* 첨부파일 */
.ebf-attach { margin-top: 14px; padding-top: 12px; border-top: 1px dashed #e0e0e0; }
.ebf-attach-item {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px; margin-right: 8px; margin-bottom: 6px;
  background: #fff; border: 1px solid #e0e0e0; border-radius: 6px;
  text-decoration: none !important; color: #555; font-size: 13px; transition: border-color 0.2s;
}
.ebf-attach-item:hover { border-color: #aaa !important; }

/* 수정/삭제 버튼 */
.ebf-item-control { margin-top: 14px; padding-top: 12px; border-top: 1px dashed #e0e0e0; display: flex; gap: 8px; }
.ebf-btn-sm {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 6px 12px; font-size: 12px; border-radius: 6px;
  text-decoration: none !important; border: 1px solid; transition: all 0.2s;
}
.ebf-btn-edit { color: #28a745 !important; border-color: #28a745; }
.ebf-btn-edit:hover { background: rgba(40,167,69,0.08) !important; }
.ebf-btn-delete { color: #dc3545 !important; border-color: #dc3545; }
.ebf-btn-delete:hover { background: rgba(220,53,69,0.08) !important; }

/* =============================================
   6. 빈 목록
============================================= */
.ebf-empty {
  text-align: center; padding: 60px 20px; color: #bbb;
}
.ebf-empty i { font-size: 48px; display: block; margin-bottom: 12px; opacity: 0.3; }
.ebf-empty p { font-size: 15px; }

/* =============================================
   7. 페이지네이션 + 컨트롤
============================================= */
.ebf-pagination { display: flex; justify-content: center; margin: 24px 0 16px; }
.ebf-pages { display: flex; gap: 4px; }
.ebf-pages li a, .ebf-pages li span {
  display: flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 6px; font-size: 13px; color: #555;
  background: #fff; border: 1px solid #e0e0e0; text-decoration: none; transition: all 0.2s;
}
.ebf-pages li a:hover { border-color: #aaa; }
.ebf-pages li.active a { background: #667eea; color: #fff; border-color: #667eea; }
.ebf-control { display: flex; justify-content: flex-end; margin: 8px 0; }

/* =============================================
   8. 에디터
============================================= */
#kboard-eoingti-board-faq-editor { max-width: 900px; margin: 0 auto; padding: 30px 20px; }
#kboard-eoingti-board-faq-editor .kboard-form {
  background: #fff; border-radius: 12px; padding: 40px 32px;
  border: 1px solid #e0e0e0; box-shadow: 0 4px 16px rgba(0,0,0,0.05);
}
#kboard-eoingti-board-faq-editor .kboard-attr-row { align-items: center; margin-bottom: 14px; }
#kboard-eoingti-board-faq-editor .attr-name {
  display: inline-block; vertical-align: middle;
  width: 150px !important; min-width: 150px !important;
  font-weight: 400 !important; color: #333 !important; font-size: 14px;
}
#kboard-eoingti-board-faq-editor .attr-value {
  display: inline-block; vertical-align: middle;
  width: calc(100% - 160px); min-width: 0;
}
#kboard-eoingti-board-faq-editor input[type="text"],
#kboard-eoingti-board-faq-editor select,
#kboard-eoingti-board-faq-editor textarea {
  width: 100%; min-width: 0; padding: 10px 14px; font-size: 14px;
  border: 1px solid #dcdcdc; border-radius: 8px;
  background: #f8f9fa; transition: all 0.2s; box-sizing: border-box;
}
#kboard-eoingti-board-faq-editor input:focus,
#kboard-eoingti-board-faq-editor select:focus,
#kboard-eoingti-board-faq-editor textarea:focus {
  outline: none; background: #fff; border-color: #667eea;
  box-shadow: 0 0 0 3px rgba(102,126,234,0.1);
}
#kboard-eoingti-board-faq-editor .kboard-control {
  display: flex; justify-content: space-between; align-items: center;
  gap: 15px; padding: 25px 0 0; flex-wrap: wrap; clear: both;
  border-top: 1px solid #e0e0e0; margin-top: 20px;
}
#kboard-eoingti-board-faq-editor .kboard-control .left,
#kboard-eoingti-board-faq-editor .kboard-control .right { display: flex; gap: 10px; flex-wrap: wrap; }
#kboard-eoingti-board-faq-editor .kboard-control a.kboard-eoingti-board-faq-button-small,
#kboard-eoingti-board-faq-editor .kboard-control button.kboard-eoingti-board-faq-button-small {
  padding: 10px 20px !important; min-height: 38px !important;
  display: inline-flex !important; align-items: center !important; gap: 6px !important;
}

/* =============================================
   9. 반응형
============================================= */
@media screen and (max-width: 768px) {
  #kboard-eoingti-board-faq-list { padding: 20px 15px; }
  .ebf-category, .ebf-date { display: none; }
  .ebf-question { padding: 14px 16px; gap: 10px; }
  .ebf-answer-inner { padding: 14px 16px; gap: 10px; }
  .ebf-q-text { font-size: 14px; }
  #kboard-eoingti-board-faq-editor .kboard-form { padding: 24px 16px; }
  #kboard-eoingti-board-faq-editor .attr-name { display: block; width: 100% !important; margin-bottom: 6px; }
  #kboard-eoingti-board-faq-editor .attr-value { width: 100%; }
}

/* FAQ KBoard 6.7 Final Standard */
#kboard-eoingti-board-faq-editor .secret-password-row[style*="display:none"],
#kboard-eoingti-board-faq-editor .secret-password-row[style*="display: none"],
#kboard-eoingti-board-faq-editor .notice-expired-date-row[style*="display:none"],
#kboard-eoingti-board-faq-editor .notice-expired-date-row[style*="display: none"] {
  display:none !important;
}
#kboard-eoingti-board-faq-editor .secret-password-row:not([style*="display:none"]):not([style*="display: none"]),
#kboard-eoingti-board-faq-editor .notice-expired-date-row:not([style*="display:none"]):not([style*="display: none"]) {
  display:flex !important;
}
#kboard-eoingti-board-faq-editor .wp-editor-wrap.tmce-active .quicktags-toolbar {
  display:none !important;
}
#kboard-eoingti-board-faq-editor .wp-editor-wrap.html-active .quicktags-toolbar {
  display:block !important;
}
