/* 도움말(등급별 설명서) — help.html + frontend/help/<등급>.html 본문 스타일 */
.help-container { max-width: 1160px; }
.help-loading { color: #7b8a9d; padding: 40px 0; text-align: center; }

/* 등급 탭 */
.help-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 14px; }
.help-tab {
  padding: 9px 16px; border-radius: 999px; border: 1px solid #cfd8e5; background: #fff;
  color: #1e3d63; font-size: 14px; font-weight: 700; cursor: pointer;
}
.help-tab.active { background: #1e3d63; border-color: #1e3d63; color: #fff; }

.help-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 20px; align-items: start; }
.help-toc {
  position: sticky; top: 76px; max-height: calc(100vh - 96px); overflow: auto;
  background: #fff; border: 1px solid #dce3ec; border-radius: 12px; padding: 14px 12px;
  font-size: 13px;
}
.help-toc-title { font-weight: 800; color: #1e3d63; margin: 0 4px 10px; }

/* 찾기 */
.help-search { margin: 0 2px 10px; }
.help-search input {
  width: 100%; box-sizing: border-box; padding: 7px 10px; border: 1px solid #cfd8e5; border-radius: 8px;
  font-size: 13px; background: #f8fafc;
}
.help-search input:focus { outline: none; border-color: #1e3d63; background: #fff; }

/* 트리 내비게이션 */
.help-tree-item {
  display: block; width: 100%; text-align: left; padding: 6px 8px; margin: 1px 0; border: 0; background: none;
  border-radius: 6px; color: #33465c; line-height: 1.35; font-size: 13px; cursor: pointer; font-family: inherit;
}
.help-tree-item:hover { background: #f1f5fa; }
.help-tree-item.active { background: #e8eff8; color: #1e3d63; font-weight: 700; }
.help-tree-item.help-overview { font-weight: 800; color: #1e3d63; margin-bottom: 8px; padding-left: 8px; }
.help-tree-group { margin: 2px 0 10px; }
.help-tree-group.help-tree-flat { margin-top: -2px; }
.help-tree-group .help-tree-item { padding-left: 18px; }
.help-tree-flat .help-tree-item { padding-left: 8px; }
.help-tree-cat {
  font-weight: 800; color: #7b8a9d; font-size: 11.5px; letter-spacing: .02em; text-transform: uppercase;
  margin: 6px 2px 2px; padding: 2px 6px 2px 16px; cursor: pointer; position: relative;
}
.help-tree-cat::before {
  content: "▾"; position: absolute; left: 0; top: 1px; font-size: 10px; color: #a7b3c2;
}
.help-tree-group.collapsed .help-tree-cat::before { content: "▸"; }
.help-tree-group.collapsed .help-tree-item { display: none; }

/* 본문 영역 */
.help-main { min-width: 0; }
.help-crumb-row {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 0 2px 8px;
}
.help-crumb { margin: 0; font-size: 12.5px; color: #7b8a9d; }
.help-view-toggle {
  padding: 5px 12px; border-radius: 999px; border: 1px solid #cfd8e5; background: #fff; color: #1e3d63;
  font-size: 12.5px; font-weight: 700; cursor: pointer; white-space: nowrap;
}
.help-view-toggle.active { background: #1e3d63; border-color: #1e3d63; color: #fff; }

.help-body {
  background: #fff; border: 1px solid #dce3ec; border-radius: 12px; padding: 26px 28px 34px;
  box-shadow: 0 10px 28px rgba(7,21,38,.06); line-height: 1.75; font-size: 15px; color: #162333; min-width: 0;
}

/* 이전/다음 */
.help-pager {
  display: flex; align-items: stretch; justify-content: space-between; gap: 12px; margin-top: 14px;
}
.help-pager:empty { margin-top: 0; }
.help-pager-btn {
  flex: 1; max-width: 48%; padding: 12px 16px; border: 1px solid #dce3ec; border-radius: 10px; background: #fff;
  color: #1e3d63; font-size: 13.5px; font-weight: 700; cursor: pointer; text-align: left;
}
.help-pager-next { text-align: right; margin-left: auto; }
.help-pager-btn:hover { background: #f1f5fa; }

/* 설명서 본문 */
.mn-cover { padding-bottom: 18px; border-bottom: 2px solid #1e3d63; margin-bottom: 26px; }
.mn-cover h1 { font-size: 26px; color: #1e3d63; margin: 0 0 6px; }
.mn-cover p { color: #4a5b70; margin: 0; }
.mn-chapter { padding-top: 6px; margin-bottom: 44px; }
.mn-chapter > h2 {
  font-size: 21px; color: #1e3d63; margin: 0 0 12px; padding-bottom: 8px; border-bottom: 1px solid #dce3ec;
}
.mn-chapter h3 { font-size: 17px; color: #274a74; margin: 26px 0 8px; }
.mn-chapter p { margin: 8px 0; }
.mn-lead { color: #33465c; }

/* 메뉴·할 수 있는 일 표 */
.mn-table-wrap { overflow-x: auto; margin: 12px 0; }
.mn-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.mn-table th, .mn-table td { border: 1px solid #dce3ec; padding: 9px 12px; text-align: left; vertical-align: top; }
.mn-table th { background: #f1f5fa; color: #1e3d63; white-space: nowrap; }
.mn-table td ul { margin: 0; padding-left: 18px; list-style: disc; }
.mn-table td li { margin: 2px 0; }

/* 단계 */
.mn-steps { list-style: none; margin: 14px 0; padding: 0; counter-reset: step; }
.mn-steps > li {
  counter-increment: step; position: relative; padding: 0 0 20px 44px; margin: 0;
}
.mn-steps > li::before {
  content: counter(step); position: absolute; left: 0; top: 0; width: 30px; height: 30px; border-radius: 50%;
  background: #1e3d63; color: #fff; font-weight: 800; font-size: 14px; display: flex; align-items: center; justify-content: center;
}
.mn-steps > li::after {
  content: ""; position: absolute; left: 14px; top: 34px; bottom: 4px; width: 2px; background: #e3e9f1;
}
.mn-steps > li:last-child::after { display: none; }
.mn-steps p { margin: 0 0 6px; }

/* 화면 그림 */
.mn-fig { margin: 10px 0 4px; }
.mn-shot {
  width: 100%; max-width: 860px; border: 1px solid #cfd8e5; border-radius: 8px; cursor: zoom-in;
  box-shadow: 0 4px 14px rgba(7,21,38,.08); background: #fff;
}
.mn-fig figcaption { font-size: 12.5px; color: #7b8a9d; margin-top: 4px; }

/* 표시 요소 */
.mn-btn {
  display: inline-block; padding: 1px 9px; border-radius: 6px; background: #1e3d63; color: #fff;
  font-size: 13px; font-weight: 700; line-height: 1.6; white-space: nowrap;
}
.mn-btn.ghost { background: #fff; color: #1e3d63; border: 1px solid #1e3d63; }
.mn-field {
  display: inline-block; padding: 0 8px; border-radius: 6px; background: #eef3f9; color: #1e3d63;
  font-size: 13.5px; font-weight: 700; border: 1px solid #d4deeb;
}
.mn-menu { color: #98302b; font-weight: 700; }

/* 눌렀을 때 나오는 메시지 */
.mn-msg {
  margin: 8px 0; padding: 9px 12px; border-radius: 8px; background: #f3f8f1; border-left: 4px solid #4c9a3b;
  font-size: 14px; color: #21421a;
}
.mn-msg.error { background: #fdf2f1; border-left-color: #c0392b; color: #6d1f19; }
.mn-msg.confirm { background: #f4f6fb; border-left-color: #2e5a8e; color: #1c3556; }
.mn-msg b { display: inline-block; margin-right: 6px; font-size: 12.5px; }
.mn-msg q { quotes: "“" "”"; font-weight: 700; }

.mn-tip, .mn-note {
  margin: 10px 0; padding: 10px 14px; border-radius: 8px; font-size: 14px;
}
.mn-tip { background: #fffaf0; border: 1px solid #f1dfb3; }
.mn-note { background: #f6f8fb; border: 1px solid #dce3ec; }
.mn-tip::before { content: "TIP  "; font-weight: 800; color: #b07800; }
.mn-note::before { content: "참고  "; font-weight: 800; color: #1e3d63; }

/* 확대 보기 */
.help-lightbox {
  position: fixed; inset: 0; z-index: 10000; background: rgba(10,20,34,.82); display: flex;
  align-items: center; justify-content: center; padding: 20px; cursor: zoom-out;
}
.help-lightbox[hidden] { display: none; }
.help-lightbox img { max-width: 96vw; max-height: 94vh; border-radius: 8px; background: #fff; }

@media (max-width: 860px) {
  .help-layout { grid-template-columns: 1fr; }
  .help-toc { position: static; max-height: 320px; }
  .help-body { padding: 18px 16px 26px; font-size: 14.5px; }
  .mn-steps > li { padding-left: 38px; }
  .help-pager-btn { font-size: 12.5px; padding: 10px 12px; }
}
@media print {
  .topbar, .help-tabs, .help-toc, .help-crumb-row, .help-pager { display: none !important; }
  .help-layout { display: block; }
  .help-body { border: 0; box-shadow: none; padding: 0; }
  .mn-chapter { break-inside: avoid-page; }
}
