");
+ sb.AppendLine($"
{Escape(title)}
");
+ sb.AppendLine($"
문서 유형: {Escape(GetDocTypeLabel(docType))} | 작성일: {DateTime.Now:yyyy-MM-dd} | 섹션: {sections.Count}개
");
+
+ // 목차
+ if (sections.Count > 1)
+ {
+ sb.AppendLine("
");
+ sb.AppendLine("
📋 목차
");
+ sb.AppendLine("
");
+ sb.AppendLine("
");
+ }
+
+ // 섹션 본문
+ for (int i = 0; i < sections.Count; i++)
+ {
+ var sec = sections[i];
+ sb.AppendLine($"
{Escape(sec.Heading)}
");
+ sb.AppendLine("
");
+ foreach (var kp in sec.KeyPoints)
+ {
+ sb.AppendLine($"
");
+ sb.AppendLine($"
▸ {Escape(kp)}");
+ sb.AppendLine($"
{Escape(kp)}에 대한 상세 내용을 여기에 작성합니다. (목표: 약 {sec.TargetWords / Math.Max(1, sec.KeyPoints.Count)}단어)
");
+ sb.AppendLine("
");
+ }
+ sb.AppendLine("
");
+ }
+
+ sb.AppendLine("
");
+ sb.AppendLine("");
+ sb.AppendLine("");
+
+ File.WriteAllText(path, sb.ToString(), Encoding.UTF8);
+ }
+
+ // ─── DOCX 생성 ──────────────────────────────────────────────────────────
+
+ private static void GenerateDocx(string path, string title, List