(()=>{var e={};e.id=409,e.ids=[409],e.modules={7849:e=>{"use strict";e.exports=require("next/dist/client/components/action-async-storage.external")},5403:e=>{"use strict";e.exports=require("next/dist/client/components/request-async-storage.external")},4749:e=>{"use strict";e.exports=require("next/dist/client/components/static-generation-async-storage.external")},399:e=>{"use strict";e.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},5528:e=>{"use strict";e.exports=require("next/dist\\client\\components\\action-async-storage.external.js")},1877:e=>{"use strict";e.exports=require("next/dist\\client\\components\\request-async-storage.external.js")},5319:e=>{"use strict";e.exports=require("next/dist\\client\\components\\static-generation-async-storage.external.js")},9411:e=>{"use strict";e.exports=require("node:path")},7742:e=>{"use strict";e.exports=require("node:process")},1041:e=>{"use strict";e.exports=require("node:url")},8371:(e,t,s)=>{"use strict";s.r(t),s.d(t,{GlobalError:()=>n.a,__next_app__:()=>m,originalPathname:()=>p,pages:()=>d,routeModule:()=>h,tree:()=>c});var r=s(482),a=s(9108),o=s(2563),n=s.n(o),i=s(8300),l={};for(let e in i)0>["default","tree","pages","GlobalError","originalPathname","__next_app__","routeModule"].indexOf(e)&&(l[e]=()=>i[e]);s.d(t,l);let c=["",{children:["book",{children:["[bookId]",{children:["__PAGE__",{},{page:[()=>Promise.resolve().then(s.bind(s,4013)),"C:\\Users\\DELL\\Muse Pro\\frontend\\app\\book\\[bookId]\\page.tsx"]}]},{}]},{}]},{layout:[()=>Promise.resolve().then(s.bind(s,2917)),"C:\\Users\\DELL\\Muse Pro\\frontend\\app\\layout.tsx"],"not-found":[()=>Promise.resolve().then(s.t.bind(s,9361,23)),"next/dist/client/components/not-found-error"]}],d=["C:\\Users\\DELL\\Muse Pro\\frontend\\app\\book\\[bookId]\\page.tsx"],p="/book/[bookId]/page",m={require:s,loadChunk:()=>Promise.resolve()},h=new r.AppPageRouteModule({definition:{kind:a.x.APP_PAGE,page:"/book/[bookId]/page",pathname:"/book/[bookId]",bundlePath:"",filename:"",appPaths:[]},userland:{loaderTree:c}})},1855:(e,t,s)=>{Promise.resolve().then(s.bind(s,2227))},9659:(e,t,s)=>{Promise.resolve().then(s.t.bind(s,2583,23)),Promise.resolve().then(s.t.bind(s,6840,23)),Promise.resolve().then(s.t.bind(s,8771,23)),Promise.resolve().then(s.t.bind(s,3225,23)),Promise.resolve().then(s.t.bind(s,9295,23)),Promise.resolve().then(s.t.bind(s,3982,23))},7378:(e,t,s)=>{Promise.resolve().then(s.bind(s,4669))},2227:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>O});var r=s(2295),a=s(3729),o=s(2254),n=s(3644),i=s(7916),l=s(3024),c=s(3211),d=s(7060),p=s(1222),m=s(3148),h=s(9224);/**
 * @license lucide-react v0.309.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */let x=(0,h.Z)("Share2",[["circle",{cx:"18",cy:"5",r:"3",key:"gq8acd"}],["circle",{cx:"6",cy:"12",r:"3",key:"w7nqdw"}],["circle",{cx:"18",cy:"19",r:"3",key:"1xt0gg"}],["line",{x1:"8.59",x2:"15.42",y1:"13.51",y2:"17.49",key:"47mynk"}],["line",{x1:"15.41",x2:"8.59",y1:"6.51",y2:"10.49",key:"1n3mei"}]]),u=(0,h.Z)("Download",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"7 10 12 15 17 10",key:"2ggqvy"}],["line",{x1:"12",x2:"12",y1:"15",y2:"3",key:"1vk2je"}]]);var f=s(5390),g=s(3733);/**
 * @license lucide-react v0.309.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */let y=(0,h.Z)("PenLine",[["path",{d:"M12 20h9",key:"t2du7b"}],["path",{d:"M16.5 3.5a2.12 2.12 0 0 1 3 3L7 19l-4 1 1-4Z",key:"ymcmye"}]]),b=(0,h.Z)("Save",[["path",{d:"M19 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h11l5 5v11a2 2 0 0 1-2 2z",key:"1owoqh"}],["polyline",{points:"17 21 17 13 7 13 7 21",key:"1md35c"}],["polyline",{points:"7 3 7 8 15 8",key:"8nz8an"}]]);var v=s(113),k=s(4669),j=s(4538);function w(e){return e.replace(/^#### (.+)$/gm,"<h4>$1</h4>").replace(/^### (.+)$/gm,"<h3>$1</h3>").replace(/^## (.+)$/gm,"<h2>$1</h2>").replace(/^# (.+)$/gm,"<h1>$1</h1>").replace(/\*\*(.+?)\*\*/g,"<strong>$1</strong>").replace(/\*(.+?)\*/g,"<em>$1</em>").replace(/^---$/gm,"<hr>").replace(/\n\n/g,"</p><p>").replace(/^(?!<[h|h])/gm,"").split("\n").map(e=>e.startsWith("<")?e:`<p>${e}</p>`).join("\n")}function N(e,t){let s=URL.createObjectURL(e),r=document.createElement("a");r.href=s,r.download=t,document.body.appendChild(r),r.click(),document.body.removeChild(r),URL.revokeObjectURL(s)}var C=s(3284),$=s(9157);let P=[{label:"PDF",value:"pdf",icon:"\uD83D\uDCC4"},{label:"Word Doc",value:"doc",icon:"\uD83D\uDCDD"},{label:"Markdown",value:"md",icon:"⬇️"},{label:"Plain Text",value:"txt",icon:"\uD83D\uDCC3"}],S={1:"#6366f1",2:"#a855f7",3:"#f59e0b",4:"#10b981"};function D({bookDraft:e,client:t,clientId:s,onBack:o}){let[h,D]=(0,a.useState)(e),[O,M]=(0,a.useState)(!1),[E,q]=(0,a.useState)(0),[z,Z]=(0,a.useState)(!1),[L,_]=(0,a.useState)(""),[F,I]=(0,a.useState)(!1),[R,U]=(0,a.useState)(!1),[B,A]=(0,a.useState)(!1),[J,G]=(0,a.useState)(!1),H=(0,a.useRef)(null),W=(0,a.useMemo)(()=>{let e=h.split("\n"),s=[],r=null,a=1;for(let t of e)if(/^## PART (\d)/.test(t)){let e=t.match(/^## PART (\d)/);e&&(a=parseInt(e[1]))}else if(/^### Chapter (\d+):/.test(t)){r&&s.push({title:r.title,content:r.lines.join("\n").trim(),num:r.num,part:r.part});let e=t.match(/^### Chapter (\d+): (.+)/);r={title:e?e[2]:t.replace(/^###\s*/,""),lines:[],num:e?parseInt(e[1]):s.length+1,part:a}}else/^### /.test(t)&&!r?r={title:t.replace(/^###\s*/,""),lines:[],num:s.length+1,part:a}:r&&r.lines.push(t);return r&&r.lines.length>0&&s.push({title:r.title,content:r.lines.join("\n").trim(),num:r.num,part:r.part}),s.length>0?s:[{title:t.bookTitle,content:h,num:1,part:1}]},[h,t.bookTitle]),Y=W[E],V=e=>{_(e),U(!1),H.current&&clearTimeout(H.current),H.current=setTimeout(()=>X(e),3e3)},X=(0,a.useCallback)(async e=>{if(!Y)return;let t=h.replace(Y.content,e);try{await $.s9.save(s,t),D(t),U(!0),setTimeout(()=>U(!1),3e3)}catch{}},[h,s,Y]),K=async()=>{if(!Y)return;I(!0);let e=h.replace(Y.content,L);try{await $.s9.save(s,e),D(e),Z(!1),k.default.success("Chapter saved!")}catch{k.default.error("Failed to save")}finally{I(!1)}},Q=async()=>{if(Y){A(!0);try{let e=await $.s9.regenerateChapter(s,Y.num),t=h.replace(Y.content,e.content);await $.s9.save(s,t),D(t),Z(!1),k.default.success("Chapter regenerated from your interview!")}catch(e){k.default.error(e.message||"Failed to regenerate")}finally{A(!1)}}},ee=e=>{M(!1);try{switch(e){case"pdf":!function(e,t,s){let r=window.open("","_blank");if(!r)return;let a=`<!DOCTYPE html>
<html>
<head>
  <meta charset="UTF-8">
  <title>${t}</title>
  <style>
    @import url('https://fonts.googleapis.com/css2?family=Georgia&family=Inter:wght@400;600;700&display=swap');
    * { margin: 0; padding: 0; box-sizing: border-box; }
    body { font-family: Georgia, serif; font-size: 12pt; line-height: 1.8; color: #1a1a1a; }
    .cover { display: flex; flex-direction: column; align-items: center; justify-content: center;
      height: 100vh; background: linear-gradient(135deg, #6366f1, #a855f7); color: white;
      text-align: center; page-break-after: always; }
    .cover h1 { font-size: 36pt; font-weight: 700; margin-bottom: 16px; }
    .cover h2 { font-size: 18pt; font-weight: 400; opacity: 0.9; }
    .content { max-width: 680px; margin: 0 auto; padding: 60px 40px; }
    h1 { font-size: 28pt; margin: 40px 0 16px; color: #4f46e5; page-break-before: always; }
    h2 { font-size: 20pt; margin: 32px 0 12px; color: #6366f1; }
    h3 { font-size: 14pt; margin: 24px 0 8px; color: #374151; }
    p { margin-bottom: 14px; text-align: justify; }
    hr { border: none; border-top: 1px solid #e5e7eb; margin: 32px 0; }
    @page { margin: 2.5cm; }
    @media print { .cover { -webkit-print-color-adjust: exact; print-color-adjust: exact; } }
  </style>
</head>
<body>
  <div class="cover">
    <h1>${t}</h1>
    <h2>By ${s}</h2>
  </div>
  <div class="content">
    ${w(e)}
  </div>
  <script>window.onload = () => { window.print(); }</script>
</body>
</html>`;r.document.write(a),r.document.close()}(h,t.bookTitle,t.name);break;case"doc":!function(e,t,s){let r=`<!DOCTYPE html>
<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word">
<head>
  <meta charset="UTF-8">
  <title>${t}</title>
  <style>
    body { font-family: 'Times New Roman', serif; font-size: 12pt; line-height: 1.8; }
    h1 { font-size: 24pt; color: #4f46e5; page-break-before: always; }
    h2 { font-size: 18pt; color: #6366f1; }
    h3 { font-size: 14pt; }
    p { margin-bottom: 12px; }
    .cover { text-align: center; margin-bottom: 60px; }
    .cover h1 { font-size: 32pt; color: #4f46e5; }
  </style>
</head>
<body>
  <div class="cover"><h1>${t}</h1><p>By ${s}</p></div>
  ${w(e)}
</body>
</html>`;N(new Blob([r],{type:"application/msword"}),`${t.replace(/\s+/g,"_")}.doc`)}(h,t.bookTitle,t.name);break;case"md":!function(e,t,s){let r=`# ${t}

**By ${s}**

---

${e}`;N(new Blob([r],{type:"text/markdown"}),`${t.replace(/\s+/g,"_")}.md`)}(h,t.bookTitle,t.name);break;case"txt":!function(e,t,s){let r=e.replace(/#{1,6}\s/g,"").replace(/\*\*(.+?)\*\*/g,"$1").replace(/\*(.+?)\*/g,"$1").replace(/---/g,"─".repeat(60)),a=`${"═".repeat(60)}
${t.toUpperCase()}
By ${s}
${"═".repeat(60)}

${((e,t=80)=>e.split("\n").map(e=>e.length<=t?e:e.match(RegExp(`.{1,${t}}(\\s|$)`,"g"))?.join("\n")??e).join("\n"))(r)}`;N(new Blob([a],{type:"text/plain"}),`${t.replace(/\s+/g,"_")}.txt`)}(h,t.bookTitle,t.name)}k.default.success(`Exporting as ${e.toUpperCase()}...`)}catch{k.default.error("Export failed")}},et=h.split(/\s+/).filter(Boolean).length,es=S[Y?.part||1];return(0,r.jsxs)("div",{className:"h-screen flex flex-col",style:{background:"var(--bg-secondary)"},children:[(0,r.jsxs)("header",{className:"flex-shrink-0 border-b px-4 py-3 flex items-center gap-3",style:{background:"var(--bg-card)",borderColor:"var(--border)"},children:[r.jsx("button",{onClick:o,className:"btn-ghost p-2 rounded-lg","aria-label":"Go back",children:r.jsx(l.Z,{className:"w-4 h-4"})}),(0,r.jsxs)("div",{className:"flex items-center gap-2 flex-1 min-w-0",children:[r.jsx(c.Z,{className:"w-4 h-4 flex-shrink-0",style:{color:"#6366f1"}}),(0,r.jsxs)("div",{className:"min-w-0",children:[r.jsx("span",{className:"font-bold text-sm truncate block",style:{color:"var(--text-primary)"},children:t.bookTitle}),(0,r.jsxs)("span",{className:"text-xs",style:{color:"var(--text-secondary)"},children:[W.length," chapters \xb7 ",et.toLocaleString()," words"]})]})]}),(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[r.jsx(n.M,{children:R&&(0,r.jsxs)(i.E.span,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},className:"text-xs text-green-500 flex items-center gap-1",children:[r.jsx(d.Z,{className:"w-3 h-3"})," Saved"]})}),(0,r.jsxs)("button",{onClick:()=>G(!J),className:"btn-ghost flex items-center gap-1.5 text-xs py-2",children:[J?r.jsx(p.Z,{className:"w-3.5 h-3.5"}):r.jsx(m.Z,{className:"w-3.5 h-3.5"}),r.jsx("span",{className:"hidden sm:inline",children:J?"Chapter view":"Full book"})]}),r.jsx("button",{onClick:()=>navigator.clipboard.writeText(window.location.href).then(()=>k.default.success("Link copied!")),className:"btn-secondary flex items-center gap-1.5 text-xs py-2",children:r.jsx(x,{className:"w-3.5 h-3.5"})}),(0,r.jsxs)("div",{className:"relative",children:[(0,r.jsxs)("button",{onClick:()=>M(!O),className:"btn-primary flex items-center gap-1.5 text-xs py-2",children:[r.jsx(u,{className:"w-3.5 h-3.5"})," Export",r.jsx(f.Z,{className:`w-3 h-3 transition-transform ${O?"rotate-180":""}`})]}),O&&r.jsx("div",{className:"absolute right-0 top-full mt-1 w-40 rounded-xl shadow-xl border overflow-hidden z-50",style:{background:"var(--bg-card)",borderColor:"var(--border)"},children:P.map(e=>(0,r.jsxs)("button",{onClick:()=>ee(e.value),className:"w-full px-4 py-2.5 text-left text-xs flex items-center gap-2 transition-colors hover:bg-indigo-50 dark:hover:bg-indigo-900/20",style:{color:"var(--text-primary)"},children:[r.jsx("span",{children:e.icon}),e.label]},e.value))})]})]})]}),(0,r.jsxs)("div",{className:"flex-1 flex overflow-hidden",children:[!J&&(0,r.jsxs)("aside",{className:"hidden lg:flex flex-col w-64 border-r flex-shrink-0 overflow-y-auto",style:{borderColor:"var(--border)",background:"var(--bg-card)"},children:[(0,r.jsxs)("div",{className:"m-3 rounded-xl p-4 text-white text-center",style:{background:"linear-gradient(135deg, #6366f1, #a855f7)"},children:[r.jsx("div",{className:"text-3xl mb-2",children:(0,C.w2)(t.sport)}),r.jsx("p",{className:"font-bold text-xs leading-tight",children:t.bookTitle}),(0,r.jsxs)("p",{className:"text-xs opacity-75 mt-1",children:["By ",t.name]}),(0,r.jsxs)("div",{className:"mt-2 text-xs opacity-60",children:[et.toLocaleString()," words"]})]}),(0,r.jsxs)("div",{className:"px-3 pb-3",children:[r.jsx("p",{className:"text-xs font-semibold uppercase tracking-wider mb-2",style:{color:"var(--text-secondary)"},children:"Contents"}),W.map((e,t)=>(0,r.jsxs)("button",{onClick:()=>{q(t),Z(!1)},className:"w-full text-left px-2.5 py-2 rounded-lg mb-0.5 flex items-center gap-2 transition-all text-xs",style:E===t?{background:`${S[e.part]}15`,color:S[e.part],fontWeight:600}:{color:"var(--text-secondary)"},children:[r.jsx("span",{className:"w-5 h-5 rounded-full flex items-center justify-center text-xs flex-shrink-0 font-bold",style:{background:E===t?`${S[e.part]}20`:"var(--bg-secondary)",color:S[e.part]},children:e.num}),r.jsx("span",{className:"truncate",children:e.title})]},t))]})]}),r.jsx("main",{className:"flex-1 overflow-y-auto",children:J?r.jsx("div",{className:"max-w-3xl mx-auto px-6 py-8",children:r.jsx("div",{className:"card p-8",children:r.jsx(v.UG,{components:T,children:h})})}):r.jsx("div",{className:"max-w-3xl mx-auto px-4 sm:px-6 py-6",children:Y&&(0,r.jsxs)(i.E.div,{initial:{opacity:0,y:8},animate:{opacity:1,y:0},children:[(0,r.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,r.jsxs)("div",{children:[(0,r.jsxs)("span",{className:"text-xs font-bold",style:{color:es},children:["Chapter ",Y.num," of ",W.length]}),r.jsx("h2",{className:"text-xl font-bold mt-0.5",style:{color:"var(--text-primary)"},children:Y.title})]}),(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[!z&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)("button",{onClick:Q,disabled:B,className:"btn-ghost flex items-center gap-1.5 text-xs py-2",title:"Regenerate from interview",children:[B?r.jsx(j.Z,{size:"sm"}):r.jsx(g.Z,{className:"w-3.5 h-3.5"}),r.jsx("span",{className:"hidden sm:inline",children:"Regenerate"})]}),(0,r.jsxs)("button",{onClick:()=>{_(Y?.content||""),Z(!0)},className:"btn-secondary flex items-center gap-1.5 text-xs py-2",children:[r.jsx(y,{className:"w-3.5 h-3.5"})," Edit"]})]}),z&&(0,r.jsxs)(r.Fragment,{children:[r.jsx("button",{onClick:()=>Z(!1),className:"btn-ghost text-xs py-2",children:"Cancel"}),(0,r.jsxs)("button",{onClick:K,disabled:F,className:"btn-primary flex items-center gap-1.5 text-xs py-2",children:[F?r.jsx(j.Z,{size:"sm"}):r.jsx(b,{className:"w-3.5 h-3.5"}),"Save"]})]})]})]}),r.jsx("div",{className:"card p-6 sm:p-8",children:z?r.jsx("textarea",{value:L,onChange:e=>V(e.target.value),className:"w-full text-sm leading-relaxed outline-none resize-none",style:{minHeight:"500px",background:"transparent",color:"var(--text-primary)",fontFamily:"Georgia, serif",lineHeight:"1.9"}}):r.jsx("div",{className:"prose prose-lg max-w-none",children:r.jsx(v.UG,{components:T,children:Y.content})})}),(0,r.jsxs)("div",{className:"flex justify-between mt-4",children:[r.jsx("button",{onClick:()=>{q(Math.max(0,E-1)),Z(!1)},disabled:0===E,className:"btn-secondary disabled:opacity-40 text-sm",children:"← Previous"}),(0,r.jsxs)("span",{className:"text-xs self-center",style:{color:"var(--text-secondary)"},children:[E+1," / ",W.length]}),r.jsx("button",{onClick:()=>{q(Math.min(W.length-1,E+1)),Z(!1)},disabled:E===W.length-1,className:"btn-secondary disabled:opacity-40 text-sm",children:"Next →"})]})]},E)})})]})]})}let T={h1:({children:e})=>r.jsx("h1",{className:"text-3xl font-bold mb-3 gradient-text",children:e}),h2:({children:e})=>r.jsx("h2",{className:"text-xl font-bold mt-10 mb-3 pt-6 border-t",style:{borderColor:"var(--border)",color:"#6366f1"},children:e}),h3:({children:e})=>r.jsx("h3",{className:"text-lg font-bold mt-8 mb-3",style:{color:"var(--text-primary)"},children:e}),p:({children:e})=>r.jsx("p",{className:"mb-5 leading-relaxed",style:{color:"var(--text-primary)",fontFamily:"Georgia, serif",fontSize:"1.05rem",lineHeight:"1.9"},children:e}),blockquote:({children:e})=>r.jsx("blockquote",{className:"border-l-4 pl-4 my-4 italic",style:{borderColor:"#6366f1",color:"var(--text-secondary)"},children:e}),hr:()=>r.jsx("hr",{className:"my-8",style:{borderColor:"var(--border)"}}),em:({children:e})=>r.jsx("em",{style:{color:"var(--text-primary)"},children:e}),strong:({children:e})=>r.jsx("strong",{style:{color:"var(--text-primary)"},children:e})};function O(){let{bookId:e}=(0,o.useParams)(),t=(0,o.useRouter)(),[s,n]=(0,a.useState)(null),[i,l]=(0,a.useState)(!0);return((0,a.useEffect)(()=>{(async()=>{try{if(!localStorage.getItem("muse_token")){t.push("/");return}await $.I8.verify();let s=await $.s9.get(e);n(s)}catch(e){k.default.error(e.message||"Failed to load book"),t.push("/")}finally{l(!1)}})()},[e,t]),i)?r.jsx("div",{className:"min-h-screen flex items-center justify-center",style:{background:"var(--bg-primary)"},children:(0,r.jsxs)("div",{className:"flex gap-1.5",children:[r.jsx("div",{className:"typing-dot"}),r.jsx("div",{className:"typing-dot",style:{animationDelay:"0.2s"}}),r.jsx("div",{className:"typing-dot",style:{animationDelay:"0.4s"}})]})}):s?r.jsx(D,{bookDraft:s.bookDraft,client:s.client,clientId:e,onBack:()=>window.location.href="/"}):null}},4538:(e,t,s)=>{"use strict";s.d(t,{Z:()=>a});var r=s(2295);function a({size:e="md"}){return r.jsx("div",{className:`${{sm:"w-4 h-4",md:"w-6 h-6",lg:"w-10 h-10"}[e]} border-2 rounded-full animate-spin`,style:{borderColor:"rgba(99,102,241,0.2)",borderTopColor:"#6366f1"}})}},5390:(e,t,s)=>{"use strict";s.d(t,{Z:()=>r});/**
 * @license lucide-react v0.309.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */let r=(0,s(9224).Z)("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]])},1222:(e,t,s)=>{"use strict";s.d(t,{Z:()=>r});/**
 * @license lucide-react v0.309.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */let r=(0,s(9224).Z)("EyeOff",[["path",{d:"M9.88 9.88a3 3 0 1 0 4.24 4.24",key:"1jxqfv"}],["path",{d:"M10.73 5.08A10.43 10.43 0 0 1 12 5c7 0 10 7 10 7a13.16 13.16 0 0 1-1.67 2.68",key:"9wicm4"}],["path",{d:"M6.61 6.61A13.526 13.526 0 0 0 2 12s3 7 10 7a9.74 9.74 0 0 0 5.39-1.61",key:"1jreej"}],["line",{x1:"2",x2:"22",y1:"2",y2:"22",key:"a6p6uj"}]])},3148:(e,t,s)=>{"use strict";s.d(t,{Z:()=>r});/**
 * @license lucide-react v0.309.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */let r=(0,s(9224).Z)("Eye",[["path",{d:"M2 12s3-7 10-7 10 7 10 7-3 7-10 7-10-7-10-7Z",key:"rwhkz3"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]])},3733:(e,t,s)=>{"use strict";s.d(t,{Z:()=>r});/**
 * @license lucide-react v0.309.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */let r=(0,s(9224).Z)("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]])},3284:(e,t,s)=>{"use strict";function r(e){return e>=1e3?`${(e/1e3).toFixed(1)}k`:e.toString()}function a(e){return({baseball:"⚾",football:"\uD83C\uDFC8",basketball:"\uD83C\uDFC0",cricket:"\uD83C\uDFCF",boxing:"\uD83E\uDD4A",athletics:"\uD83C\uDFC3",tennis:"\uD83C\uDFBE",soccer:"⚽"})[e]??"\uD83C\uDFC5"}function o(e){let t=Math.floor((Date.now()-new Date(e).getTime())/6e4);if(t<1)return"just now";if(t<60)return`${t}m ago`;let s=Math.floor(t/60);return s<24?`${s}h ago`:`${Math.floor(s/24)}d ago`}s.d(t,{CJ:()=>r,pi:()=>o,w2:()=>a})},9157:(e,t,s)=>{"use strict";s.d(t,{I8:()=>o,T6:()=>i,co:()=>c,s9:()=>l,yj:()=>n});let r=()=>null;async function a(e,t={}){let s=r(),a={"Content-Type":"application/json",...t.headers};s&&(a.Authorization=`Bearer ${s}`);let o=await fetch(`https://api.wailmehmood.com${e}`,{...t,headers:a}),n=await o.json();if(!o.ok)throw Error(n.error||`Request failed: ${o.status}`);return n}let o={register:e=>a("/api/auth/register",{method:"POST",body:JSON.stringify(e)}),login:e=>a("/api/auth/login",{method:"POST",body:JSON.stringify(e)}),verify:()=>a("/api/auth/verify"),logout:()=>a("/api/auth/logout",{method:"POST"})},n={create:e=>a("/api/clients",{method:"POST",body:JSON.stringify(e)}),list:e=>{let t=e?"?"+new URLSearchParams(e).toString():"";return a(`/api/clients${t}`)},get:e=>a(`/api/clients/${e}`),update:(e,t)=>a(`/api/clients/${e}`,{method:"PUT",body:JSON.stringify(t)}),delete:e=>a(`/api/clients/${e}`,{method:"DELETE"}),getByLink:e=>a(`/api/interview/link/${e}`),reset:e=>a(`/api/clients/${e}/reset`,{method:"POST"}),regenerateLink:e=>a(`/api/clients/${e}/regenerate-link`,{method:"POST"}),getStats:e=>a(`/api/clients/${e}/stats`)},i={getState:e=>a(`/api/interview/state/${e}`),startChapter:e=>a("/api/interview/chapter/start",{method:"POST",body:JSON.stringify(e)}),sendMessage:e=>a("/api/interview/message",{method:"POST",body:JSON.stringify(e)}),completeChapter:e=>a("/api/interview/chapter/complete",{method:"POST",body:JSON.stringify(e)}),getInsights:e=>fetch(`https://api.wailmehmood.com/api/interview/insights/${e}`,{headers:{Authorization:"Bearer null"}}).then(e=>e.json())},l={generate:e=>a("/api/book/generate",{method:"POST",body:JSON.stringify({clientId:e})}),get:e=>a(`/api/book/${e}`),save:(e,t)=>a(`/api/book/${e}`,{method:"PUT",body:JSON.stringify({bookDraft:t})}),export:(e,t)=>a("/api/book/export",{method:"POST",body:JSON.stringify({clientId:e,format:t})}),regenerateChapter:(e,t)=>a("/api/book/regenerate-chapter",{method:"POST",body:JSON.stringify({clientId:e,chapterNum:t})}),preview:(e,t)=>a("/api/interview/preview",{method:"POST",body:JSON.stringify({clientId:e,chapterNum:t})})},c={get:()=>a("/api/analytics")}},4013:(e,t,s)=>{"use strict";s.r(t),s.d(t,{$$typeof:()=>o,__esModule:()=>a,default:()=>n});let r=(0,s(6843).createProxy)(String.raw`C:\Users\DELL\Muse Pro\frontend\app\book\[bookId]\page.tsx`),{__esModule:a,$$typeof:o}=r,n=r.default},2917:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>n,metadata:()=>o});var r=s(5036),a=s(9636);s(7633),s(2244);let o={title:"Muse Pro — Athlete Biography Platform",description:"AI-powered biography publishing platform for professional athletes"};function n({children:e}){return(0,r.jsxs)("html",{lang:"en",suppressHydrationWarning:!0,children:[(0,r.jsxs)("head",{children:[r.jsx("link",{rel:"preconnect",href:"https://fonts.googleapis.com"}),r.jsx("link",{rel:"preconnect",href:"https://fonts.gstatic.com",crossOrigin:"anonymous"}),r.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap",rel:"stylesheet"})]}),(0,r.jsxs)("body",{children:[e,r.jsx(a.x7,{position:"top-right",toastOptions:{duration:3500,style:{borderRadius:"12px",fontFamily:"Inter, sans-serif",fontSize:"14px"},success:{style:{background:"#f0fdf4",color:"#166534",border:"1px solid #bbf7d0"}},error:{style:{background:"#fef2f2",color:"#991b1b",border:"1px solid #fecaca"}}}})]})]})}},2244:()=>{},7633:()=>{}};var t=require("../../../webpack-runtime.js");t.C(e);var s=e=>t(t.s=e),r=t.X(0,[257,741,887],()=>s(8371));module.exports=r})();