1import{K as ke,B as Ce,r as c,y as e,L as X}from"./vendor-CAn19U_C.js";import{d as u,n as o,a as Z}from"./index-CJ3hxe8K.js";import{o as Se,q as ee,h as B,f as se,k as Ae,u as v,d as b,e as P,B as ze}from"./vendor-firebase-CMgAD1F0.js";import{u as Ve}from"./videoSecurity-C6H9gFJI.js";import{f as Ue,g as Ee}from"./emailService-Dq7LSEVV.js";import{c as Pe,a as De}from"./courseVersioning--wRpcjCw.js";import{e as $e}from"./exclusiveCourseEnrollment-BPtETjfD.js";import{aB as te,x as Re,S as Q,O as Fe,p as ae,aa as Ie,aA as Le,az as M,a as Te,a4 as re,aM as le,F as ie,ac as Be,an as ne,J as D,e as Qe,j as _,b1 as J,z as Me,r as _e}from"./vendor-lucide-B99EgzbQ.js";function Xe(){var O,K;const{id:d}=ke(),N=Ce(),[t,W]=c.useState(null),[ce,de]=c.useState(!0),[C,$]=c.useState(""),[S,q]=c.useState(""),[R,oe]=c.useState([0]),[xe,ue]=c.useState(!0),[g,V]=c.useState(null),[m,F]=c.useState(null),[f,I]=c.useState(null),[h,me]=c.useState([]),[U,pe]=c.useState([]),[he,be]=c.useState(new Set),[A,E]=c.useState(!1),[j,ge]=c.useState(null),[z,L]=c.useState(!1),[y,T]=c.useState(!1);c.useEffect(()=>{t&&(L(t.hideStatsFromPublic||!1),T(t.showTrainerName||!1),t.price&&$(t.price))},[t]);const H=s=>{if(s!=null&&s.quizQuestions&&Array.isArray(s.quizQuestions))return s.quizQuestions;if(s!=null&&s.quizJson)try{const r=JSON.parse(s.quizJson);return Array.isArray(r)?r:[]}catch{return[]}return[]};c.useEffect(()=>{const s=Se(Z,async r=>{var a;if(r)try{const i=b(u,"users",r.uid),l=await P(i);l.exists()&&((a=l.data().role)==null?void 0:a.trim())==="admin"?fe():(o.error("Unauthorized","Admin access required"),N("/dashboard"))}catch{N("/dashboard")}finally{ue(!1)}else N("/admin/login")});return()=>s()},[d]);const fe=async()=>{if(d)try{const s=b(u,"courses",d),r=await P(s);if(r.exists()){const a=r.id?{id:r.id,...r.data()}:r.data();if(W(a),$(a.price||a.suggestedPrice||""),q(a.adminComment||""),a.demoVideoUrl&&V({url:a.demoVideoUrl,title:"Promotional Preview"}),a.instructorId){const i=await P(b(u,"users",a.instructorId));i.exists()&&ge(i.data())}}}catch{o.error("Error","Failed to load course details")}finally{de(!1)}};c.useEffect(()=>{if(!d)return;const s=ee(B(u,"courses",d,"reviews")),r=se(s,a=>{const i=a.docs.map(l=>({id:l.id,...l.data()}));i.sort((l,n)=>{var x,p;return(((x=n.createdAt)==null?void 0:x.seconds)||0)-(((p=l.createdAt)==null?void 0:p.seconds)||0)}),me(i)},()=>{});return()=>r()},[d]),c.useEffect(()=>{if(!d)return;const s=ee(B(u,"courses",d,"questions")),r=se(s,a=>{const i=a.docs.map(l=>({id:l.id,...l.data()}));i.sort((l,n)=>{var x,p;return(((x=n.createdAt)==null?void 0:x.seconds)||0)-(((p=l.createdAt)==null?void 0:p.seconds)||0)}),pe(i)},()=>{});return()=>r()},[d]);const je=s=>{oe(r=>r.includes(s)?r.filter(a=>a!==s):[...r,s])},G=()=>{if(t!=null&&t.duration)return t.duration;let s=0;if(((t==null?void 0:t.curriculum)||[]).forEach(i=>{(i.lessons||[]).forEach(l=>{if(l.type==="video"&&l.duration){const n=l.duration.split(":");if(n.length===2){const x=parseInt(n[0])||0,p=parseInt(n[1])||0;s+=x+p/60}}})}),s===0)return"TBA";const r=Math.floor(s/60),a=Math.round(s%60);return r>0?`${r}h ${a}m`:`${a}m`},Y=async(s=!1)=>{var r,a;if(!C){o.error("Required","Please set a final price for the course");return}try{const i=Pe({...t,price:C,showTrainerName:y});await v(b(u,"courses",d),{status:"published",price:C,adminComment:S,isEliteCourse:s,hideStatsFromPublic:z,showTrainerName:y,approvedAt:new Date,lastUpdated:new Date().toLocaleDateString("en-US",{month:"long",year:"numeric"}),publishedVersion:i,hasPendingChanges:!1});try{const{newQuizzes:l,newAssignments:n}=De(((r=t==null?void 0:t.publishedVersion)==null?void 0:r.curriculum)||[],i.curriculum||[]);(l.length>0||n.length>0)&&await Ue({courseId:t.id||d||"",courseName:t.title,newQuizzes:l,newAssignments:n})}catch(l){console.error("Failed to trigger syllabus update emails during admin approval:",l)}if(s&&(t!=null&&t.instructorId)){const l=t.instructorId;await v(b(u,"users",l),{isVerifiedPro:!0,elitePartnerAt:new Date}),await v(b(u,"trainers",l),{isVerifiedPro:!0,status:"active"})}try{const l={...t,isExclusive:t.isExclusive,assignedStudentEmails:t.assignedStudentEmails||[],assignedStudentPhones:t.assignedStudentPhones||[]},n=await $e(d,l);n>0&&console.log(`[AdminApproval] Auto-enrolled ${n} existing students into exclusive course ${d}`)}catch(l){console.error("Failed to auto-enroll existing students on approval:",l)}try{let l="";if(t!=null&&t.instructorId){const n=await P(b(u,"users",t.instructorId));n.exists()&&(l=n.data().email)}l?await Ee({adminName:((a=Z.currentUser)==null?void 0:a.displayName)||"Admin",courseName:t.title,instructorName:t.instructor||t.instructorName||"Unknown",instructorEmail:l,price:C,category:t.category||"General"}):console.warn("Instructor email not found, skipping email notification.")}catch(l){console.error("Failed to send course approval email:",l)}o.success(s?"Elite Partner Verified":"Standard Approval",s?"Course live & Instructor granted Pro status":"Course is now live on the platform"),N("/admin/courses")}catch(i){console.error("Approval error:",i),o.error("Failed","Could not process approval")}},Ne=async()=>
1{if(!S){o.error("Required","Please provide feedback for the instructor");return}try{const s={adminComment:S,updatedAt:new Date};t.publishedVersion?(s.title=t.publishedVersion.title,s.subtitle=t.publishedVersion.subtitle,s.description=t.publishedVersion.description,s.category=t.publishedVersion.category,s.level=t.publishedVersion.level,s.price=t.publishedVersion.price,s.thumbnailUrl=t.publishedVersion.thumbnailUrl,s.thumbnailFit=t.publishedVersion.thumbnailFit,s.whatYouWillLearn=t.publishedVersion.whatYouWillLearn,s.demoVideoUrl=t.publishedVersion.demoVideoUrl,s.demoVideoId=t.publishedVersion.demoVideoId,s.curriculum=t.publishedVersion.curriculum,s.liveClasses=t.publishedVersion.liveClasses,s.duration=t.publishedVersion.duration,s.isLiveClass=t.publishedVersion.isLiveClass,s.status="published",s.hasPendingChanges=!1,o.success("Changes Rejected","Course reverted to published version")):(s.status="draft",o.success("Feedback Sent","Course sent back for revisions")),await v(b(u,"courses",d),s),N("/admin/courses")}catch(s){console.error("Rejection error:",s),o.error("Failed","Could not process request")}},ve=async()=>{const s=!z;if(L(s),(t==null?void 0:t.status)==="published"){E(!0);try{await v(b(u,"courses",d),{hideStatsFromPublic:s}),o.success("Updated",`Stealth Mode ${s?"Enabled":"Disabled"}`)}catch{o.error("Update Failed","Could not sync visibility status"),L(!s)}finally{E(!1)}}},ye=async()=>{const s=!y;if(T(s),(t==null?void 0:t.status)==="published"){E(!0);try{const r={showTrainerName:s};t.publishedVersion&&(r.publishedVersion={...t.publishedVersion,showTrainerName:s}),await v(b(u,"courses",d),r),o.success("Updated",`Trainer Visibility ${s?"Enabled":"Disabled"}`)}catch{o.error("Update Failed","Could not sync visibility status"),T(!s)}finally{E(!1)}}},we=async()=>{if(window.confirm("Are you sure you want to permanently delete this course? This action cannot be undone."))try{await ze(b(u,"courses",d)),o.success("Deleted","Course has been removed from the platform"),N("/admin/courses")}catch{o.error("Failed","Could not delete course")}};return xe||ce?e.jsx("div",{className:"min-h-screen bg-gray-50 flex items-center justify-center",children:e.jsx("div",{className:"w-12 h-12 border-4 border-blue-600/20 border-t-blue-600 rounded-full animate-spin"})}):t?e.jsxs("div",{className:"min-h-screen bg-[#f8fafc] text-gray-900 font-sans pb-20",children:[e.jsx("div",{className:"bg-white border-b border-gray-200 sticky top-0 z-[100] shadow-sm",children:e.jsxs("div",{className:"max-w-7xl mx-auto px-6 h-20 flex items-center justify-between",children:[e.jsxs("div",{className:"flex items-center gap-8",children:[e.jsx(X,{to:"/",className:"flex items-center",children:e.jsxs("span",{className:"text-2xl font-black tracking-tighter leading-none",children:[e.jsx("span",{className:"text-blue-600",children:"ai"}),e.jsx("span",{className:"text-orange-600",children:"Cure"}),e.jsx("span",{className:"text-blue-600",children:"Academy"})]})}),e.jsx("div",{className:"h-6 w-px bg-gray-200"}),e.jsxs("button",{onClick:()=>N("/admin/courses"),className:"flex items-center gap-2 text-gray-500 hover:text-blue-600 transition-colors font-bold text-sm",children:[e.jsx(Re,{size:18}),"Exit Review Mode"]})]}),e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsxs("div",{className:"flex items-center gap-2 bg-blue-50 text-blue-600 px-4 py-2 rounded-xl border border-blue-100 text-[10px] font-black uppercase tracking-widest",children:[e.jsx(Q,{size:14}),"Governance Audit"]}),e.jsx("span",{className:`px-4 py-2 rounded-xl text-[10px] font-black uppercase tracking-widest ${t.status==="pending"?"bg-amber-50 text-amber-600 border border-amber-100":t.status==="published"?"bg-emerald-50 text-emerald-600 border border-emerald-100":"bg-gray-100 text-gray-500"}`,children:t.status})]})]})}),e.jsxs("main",{className:"max-w-7xl mx-auto px-6 py-10 lg:flex lg:gap-10",children:[e.jsxs("div",{className:"lg:w-2/3 space-y-8",children:[e.jsxs("div",{className:"bg-white rounded-[40px] p-10 border border-gray-200 shadow-sm border-b-4 border-b-blue-600 overflow-hidden",children:[e.jsxs("div",{className:"flex flex-col md:flex-row gap-10 items-start",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex flex-wrap items-center gap-2 text-blue-600 text-[10px] font-black uppercase tracking-[0.2em] mb-4",children:[e.jsx("span",{className:"bg-blue-50 px-2 py-0.5 rounded-md",children:t.category}),e.jsx("span",{className:"text-gray-300",children:"â¢"}),e.jsx("span",{className:"bg-slate-50 px-2 py-0.5 rounded-md text-slate-500",children:t.language||"English"}),t.isExclusive&&e.jsxs(e.Fragment,{children:[e.jsx("span",{className:"text-gray-300",children:"â¢"}),e.jsxs("span",{className:"inline-flex items-center gap-1.5 bg-purple-100 text-purple-700 px-3 py-0.5 rounded-full border border-purple-200",children:[e.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"10",height:"10",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"3",strokeLinecap:"round",strokeLinejoin:"round",children:[e.jsx("rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2"}),e.jsx("path",{d:"M7 11V7a5 5 0 0 1 10 0v4"})]}),"Campus Exclusive"]})]})]}),e.jsx("h1",{className:"text-3xl md:text-5xl font-black text-gray-900 mb-6 leading-[1.1] tracking-tight break-words",children:t.title}),e.jsx("p",{className:"text-gray-600 text-lg leading-relaxed font-medium mb-4 break-words",children:t.description}),e.jsx("p",{className:"text-gray-400 text-sm italic mb-8 break-words leading-relaxed",children:t.subtitle})]}),t.thumbnailUrl&&e.jsxs("div",{className:"w-full md:w-80 aspect-video shrink-0 rounded-3xl overflow-hidden border border-gray-100 shadow-xl relative group bg-gray-50 self-start",children:[e.jsx("img",{src:t.thumbnailUrl,alt:"Course Thumbn
1ail",className:"w-full h-full object-cover transition-transform group-hover:scale-110 duration-700"}),e.jsx("div",{className:"absolute inset-0 bg-black/5 group-hover:bg-transparent transition-colors"})]})]}),e.jsxs("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-8 pt-10 border-t border-gray-100",children:[e.jsxs("div",{className:"flex flex-col gap-1.5",children:[e.jsx("span",{className:"text-[10px] font-black text-gray-400 uppercase tracking-widest",children:"Instructor"}),e.jsxs("div",{className:"flex items-center gap-2 text-gray-900 font-black text-sm",children:[e.jsx("div",{className:"w-6 h-6 bg-blue-50 rounded-full flex items-center justify-center text-blue-600 text-[10px]",children:(t.instructor||"U").charAt(0)}),t.instructor||t.instructorName||"Unknown",(j==null?void 0:j.isVerifiedPro)&&e.jsx("span",{className:"ml-2 px-1.5 py-0.5 bg-blue-100 text-blue-600 rounded-md text-[8px] uppercase tracking-tighter",children:"Elite"})]})]}),e.jsxs("div",{className:"flex flex-col gap-1.5",children:[e.jsx("span",{className:"text-[10px] font-black text-gray-400 uppercase tracking-widest",children:"Duration"}),e.jsxs("div",{className:"flex items-center gap-2 text-gray-900 font-black text-sm",children:[e.jsx(Fe,{size:14,className:"text-emerald-500"}),G()]})]}),e.jsxs("div",{className:"flex flex-col gap-1.5",children:[e.jsx("span",{className:"text-[10px] font-black text-gray-400 uppercase tracking-widest",children:"Suggested Price"}),e.jsxs("div",{className:"flex items-center gap-2 text-amber-600 font-black text-sm tracking-tight text-lg",children:[e.jsx(ae,{size:14}),"â¹",t.suggestedPrice||"0"]})]}),e.jsxs("div",{className:"flex flex-col gap-1.5",children:[e.jsx("span",{className:"text-[10px] font-black text-gray-400 uppercase tracking-widest",children:"Analytics"}),e.jsxs("div",{className:"flex items-center gap-2 text-gray-900 font-black text-sm",children:[e.jsx(Ie,{size:14,className:"text-purple-500"}),h.length," Review",h.length!==1?"s":""," ",h.length>0&&`(${(h.reduce((s,r)=>s+r.rating,0)/h.length).toFixed(1)} â
)`]})]}),t.isLiveClass&&e.jsxs("div",{className:"flex flex-col gap-1.5",children:[e.jsx("span",{className:"text-[10px] font-black text-gray-400 uppercase tracking-widest",children:"Live Schedule"}),e.jsxs("div",{className:"flex items-center gap-2 text-red-600 font-black text-sm",children:[e.jsx(Le,{size:14,className:"animate-pulse"}),((O=t.liveClasses)==null?void 0:O.length)||0," Live Sessions"]})]})]})]}),e.jsxs("div",{className:"bg-white rounded-[32px] overflow-hidden border border-gray-200 shadow-sm relative",children:[e.jsxs("div",{className:"px-8 h-16 border-b border-gray-100 flex items-center justify-between bg-white sticky top-0 z-[10]",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx("div",{className:"w-8 h-8 bg-blue-50 rounded-lg flex items-center justify-center",children:e.jsx(M,{size:18,className:"text-blue-600"})}),e.jsx("h2",{className:"text-sm font-black text-gray-900 uppercase tracking-widest",children:"Audit Terminal"})]}),(g||m||f)&&e.jsxs("div",{className:"flex items-center gap-4",children:[e.jsxs("span",{className:"text-[10px] font-black text-blue-600 bg-blue-50 px-3 py-1 rounded-full uppercase tracking-wider",children:["Now Auditing: ",(g==null?void 0:g.title)||(m==null?void 0:m.title)||(f==null?void 0:f.title)]}),e.jsx("button",{onClick:()=>{V(null),F(null),I(null)},className:"p-1 hover:bg-gray-100 rounded text-gray-400 hover:text-gray-600 transition-colors",title:"Close Audit View",children:e.jsx(Te,{size:14})})]})]}),e.jsx("div",{className:"min-aspect-video bg-gray-50 relative group",children:g!=null&&g.url?e.jsx("iframe",{src:Ve(g.url)||"",className:"w-full aspect-video border-0",allowFullScreen:!0}):m?e.jsxs("div",{className:"p-8 max-h-[500px] overflow-y-auto bg-white",children:[e.jsx("div",{className:"flex items-center justify-between mb-8 border-b border-gray-100 pb-6",children:e.jsxs("div",{className:"flex items-center gap-4",children:[e.jsx("div",{className:"w-12 h-12 bg-amber-50 text-amber-600 rounded-2xl flex items-center justify-center shadow-sm border border-amber-100",children:e.jsx(re,{size:24})}),e.jsxs("div",{children:[e.jsx("h3",{className:"font-black text-gray-900 text-lg uppercase tracking-tight",children:m.title}),e.jsx("p",{className:"text-[10px] font-black text-gray-400 uppercase tracking-widest mt-0.5",children:"Qu
1iz Content Validation"})]})]})}),e.jsx("div",{className:"space-y-6",children:H(m).length>0?H(m).map((s,r)=>e.jsxs("div",{className:"bg-gray-50 p-8 rounded-3xl border border-gray-100 shadow-sm transition-all hover:border-amber-200 group/q",children:[e.jsxs("div",{className:"flex items-start gap-4 mb-6",children:[e.jsx("span",{className:"w-8 h-8 rounded-xl bg-white border border-gray-200 flex items-center justify-center font-black text-amber-500 text-sm shrink-0 shadow-sm group-hover/q:border-amber-200 group-hover/q:bg-amber-50 group-hover/q:text-amber-600 transition-all",children:r+1}),e.jsx("p",{className:"font-black text-gray-900 text-lg leading-snug flex-1 pt-1",children:s.question})]}),e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4 ml-12",children:s.options.map((a,i)=>e.jsxs("div",{className:`p-5 rounded-2xl border-2 font-bold text-sm flex items-center justify-between transition-all ${s.correctAnswer===i?"bg-emerald-50 border-emerald-500/50 text-emerald-800 shadow-sm shadow-emerald-100":"bg-white border-gray-100 text-gray-500 group-hover/q:border-gray-200"}`,children:[e.jsx("span",{className:"flex-1 pr-4",children:a}),s.correctAnswer===i&&e.jsx("div",{className:"w-6 h-6 rounded-lg bg-emerald-500 flex items-center justify-center text-white shrink-0",children:e.jsx(le,{size:14,strokeWidth:4})})]},i))})]},r)):m.quizJson?e.jsxs("div",{className:"bg-gray-900 p-8 rounded-[32px] overflow-hidden relative group/json",children:[e.jsx("div",{className:"absolute top-4 right-6 text-[8px] font-black text-emerald-500/50 uppercase tracking-[0.2em]",children:"Source Content"}),e.jsx("pre",{className:"text-emerald-400 text-xs font-mono whitespace-pre-wrap leading-relaxed max-h-[400px] overflow-y-auto custom-scrollbar",children:m.quizJson})]}):e.jsxs("div",{className:"py-20 text-center",children:[e.jsx(te,{size:40,className:"text-gray-200 mx-auto mb-4"}),e.jsx("p",{className:"text-gray-400 font-bold",children:"No questions found for this quiz"})]})})]}):f?e.jsxs("div",{className:"p-10 flex flex-col items-center justify-center text-center",children:[e.jsx("div",{className:"w-20 h-20 bg-emerald-50 text-emerald-600 rounded-[32px] flex items-center justify-center mb-6 shadow-xl shadow-emerald-500/10",children:e.jsx(ie,{size:40})}),e.jsx("h3",{className:"text-xl font-black text-gray-900 mb-2",children:f.fileName||"Linked Resource"}),e.jsx("p",{className:"text-gray-500 font-bold mb-8 max-w-sm",children:"Supplemental materials are hosted externally or in our secure clinical storage."}),e.jsxs("a",{href:f.fileUrl||f.content,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 bg-gray-900 text-white px-8 py-4 rounded-2xl font-black uppercase text-xs tracking-widest hover:scale-105 transition-all shadow-xl",children:["Inspect Source ",e.jsx(Be,{size:16})]})]}):e.jsxs("div",{className:"w-full aspect-video flex flex-col items-center justify-center text-gray-400 italic",children:[e.jsx(M,{size:48,className:"mb-4 opacity-20"}),"Select a curriculum unit to audit"]})})]}),e.jsxs("div",{className:"bg-white rounded-[32px] overflow-hidden border border-gray-200 shadow-sm",children:[e.jsx("div",{className:"px-10 h-20 border-b border-gray-100 flex items-center bg-white",children:e.jsx("h2",{className:"text-lg font-black text-gray-900 uppercase tracking-tight",children:"Full Curriculum Deep-Dive"})}),e.jsx("div",{className:"divide-y divide-gray-100",children:(t.curriculum||[]).map((s,r)=>e.jsxs("div",{className:"group",children:[e.jsxs("button",{onClick:()=>je(r),className:"w-full flex items-center justify-between p-8 hover:bg-gray-50 transition-colors text-left",children:[e.jsxs("div",{className:"flex items-center gap-6",children:[e.jsx("div",{className:`w-8 h-8 rounded-full border-2 flex items-center justify-center transition-all ${R.includes(r)?"bg-blue-600 border-blue-600 rotate-180":"bg-white border-gray-200"}`,children:e.jsx(ne,{size:14,className:R.includes(r)?"text-white":"text-gray-400"})}),e.jsxs("div",{children:[e.jsxs("span",{className:"text-[10px] font-black text-blue-600 uppercase tracking-widest block mb-1",children:["Module ",r+1]}),e.jsx("h3",{className:"font-black text-gray-900 text-lg leading-tight tracking-tight",children:s.title})]})]}),e.jsxs("div",{className:"flex flex-col items-end",children:[e.jsx("span",{className:"text-xs font-black text-gray-400 uppercase tracking-widest",children:s.duration}),e.jsxs("span",{className:"text-[10px] font-bold text-gray-300",children:[(s.lessons||[]).length," Lectures"]})]})]}),R.includes(r)&&e.jsx("div",{className:"bg-gray-50/50 px-8 pb-8 pt-2",children:e.jsx("div",{className:"space-y-2",children:(s.lessons||[]).map((a,i)=>{var x;const l=a.type==="video"&&(g==null?void 0:g.url)===a.videoUrl||a.type==="quiz"&&(m==null?void 0:m.id)===a.id||a.type==="document"&&(f==null?void 0:f.id)===a.id,n=()=>{V(null),F(null),I(null),a.type==="video"&&a.videoUrl?V({url:a.videoUrl,title:a.title}):a.type==="quiz"?F({...a,title:a.title}):a.type==="document"&&I({...a,title:a.title})};return e.jsxs("div",{onClick:n,className:`flex items-center justify-between p-5 rounded-2xl border transition-all cursor-pointer ${l?"bg-blue-600 border-blue-600 text-white shadow-lg shadow-blue-100":"bg-white border-gray-100 hover:border-blue-200 hover:shadow-md text-gray-900"}`,children:[e.jsxs("div",{className:"flex items-center gap-5",children:[e.jsx("div",{className:`w-10 h-10 rounded-xl flex items-center justify-center transition-colors ${l?"bg-white/20":"bg-gray-50 text-gray-400"}`,children:a.type==="quiz"?e.jsx(re,{size:16,className:l?"text-white":"text-amber-500"}):a.type==="document"?e.jsx(ie,{size:16,className:l?"text-white":"text-emerald-500"}):e.jsx(M,{size:16,className:l?"text-white":"text-blue-500"})}),e.jsxs("div",{children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:`text-[8px] font-black uppercase tracking-widest px-1.5 py-0.5 rounded border ${l?"bg-white/10 border-white/20 text-white":"bg-gray-100 border-gray-100 text-gray-500"}`,children:a.type||"video"}),e.jsx("p",{className:"text-sm font-black tracking-tight",children:a.title})]}),e.jsxs("div",{className:"flex items-center gap-3 mt-1",children:[a.isPreview&&e.jsx("span",{className:`text-[9px] font-black uppercase tracking-widest px-2 py-0.5 rounded-full ${l?"bg-white/20 text-white":"bg-emerald-50 text-emerald-600"}`,children:"Preview"}),a.type==="video"&&!a.videoUrl&&e.jsx("span",{className:"text-[9px] font-bold text-red-500 uppercase tracking-widest",children:"Video Missing"}),a.type==="document"&&!a.fileUrl&&e.jsx("span",{className:"text-[9px] font-bold text-red-500 uppercase tracking-widest",children:"Asset Missing"})]})]})]}),e.jsx("div",{className:"flex items-center gap-5 font-black text-xs opacity-60",children:a.type==="quiz"?`${((x=a.quizQuestions)==null?void 0:x.length)||0} Ques`:a.duration||""})]},i)})})})]},r))})]}),e.jsxs("div",{className:"bg-white rounded-[32px] p-10 border border-gray-200 shadow-sm border-t-4 border-t-emerald-500",children:[e.jsx("h2",{className:"text-lg font-black text-gray-900 mb-8 uppercase tracking-widest",children:"Expected Competencies"}),e.jsx("div",{className:"grid md:grid-cols-2 gap-6",children:(t.whatYouWillLearn||[]).map((s,r)=>e.jsxs("div",{className:"flex gap-5 p-6 bg-gray-50 rounded-2xl border border-gray-100 hover:border-blue-100 transition-colors",children:[e.jsx("div",{className:"w-6 h-6 bg-emerald-100 rounded-full flex items-center justify-center shrink-0",children:e.jsx(le,{className:"text-emerald-600",size:14})}),e.jsx("span",{className:"text-sm text-gray-700 font-bold leading-relaxed",children:s})]},r))})]}),e.jsxs("div",{className:"bg-white rounded-[32px] overflow-hidden border border-gray-200 shadow-sm border-t-4 border-t-amber-500",children:[e.jsxs("div",{className:"px-10 h-20 border-b border-gray-100 flex items-center justify-between bg-white",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx("div",{className:"w-8 h-8 bg-amber-50 rounded-lg flex items-center justify-center",children:e.jsx(D,{size:18,className:"text-amber-600"})}),e.jsx("h2",{className:"text-lg font-black text-gray-900 uppercase tracking-tight",children:"Student Reviews"})]}),e.jsxs("span",{className:"text-xs font-black text-gray-400 uppercase tracking-widest",children:[h.length," Review",h.length!==1?"s":""]})]}),e.jsx("div",{className:"p-8",children:h.length>0?e.jsx("div",{className:"space-y-4 max-h-[400px] overflow-y-auto",children:h.map(s=>{var r,a,i;return e.jsxs("div",{className:"bg-gray-50 rounded-2xl p-6 border border-gray-100",children:[e.jsxs("div",{className:"flex items-start justify-between mb-3",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx("div",{className:"w-10 h-10 bg-blue-100 rounded-full flex items-center justify-center text-blue-600 font-black text-sm",children:(s.userName||"U").charAt(0).toUpperCase()}),e.jsxs("div",{children:[e.jsx("p",{className:"font-black text-gray-900 text-sm",children:s.userName||"Anonymous"}),e.jsx("div",{className:"flex items-center gap-1",children:[...Array(5)].map((l,n)=>e.jsx(D,{size:12,className:n<s.rating?"text-amber-500 fill-amber-500":"text-gray-300"},n))})]})]}),e.jsx("span",{className:"text-[10px] font-bold text-gray-400 uppercase tracking-widest",children:((i=(a=(r=s.createdAt)==null?void 0:r.toDate)==null?void 0:a.call(r))==null?void 0:i.toLocaleDateString())||"Recent"})]}),e.jsx("p",{className:"text-sm text-gray-700 font-medium leading-relaxed",children:s.comment})]},s.id)})}):e.jsxs("div",{className:"text-center py-12",children:[e.jsx(D,{size:48,className:"text-gray-300 mx-auto mb-4"}),e.jsx("p",{className:"text-gray-400 font-bold text-sm",children:"No reviews yet"})]})})]}),e.jsxs("div",{className:"bg-white rounded-[32px] overflow-hidden border border-gray-200 shadow-sm border-t-4 border-t-blue-500",children:[e.jsxs("div",{className:"px-10 h-20 border-b border-gray-100 flex items-center justify-between bg-white",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx("div",{className:"w-8 h-8 bg-blue-50 rounded-lg flex items-center justify-center",children:e.jsx(Qe,{size:18,className:"text-blue-600"})}),e.jsx("h2",{className:"text-lg font-black text-gray-900 uppercase tracking-tight",children:"Student Q&A"})]}),e.jsxs("span",{className:"text-xs font-black text-gray-400 uppercase tracking-widest",children:[U.length," Question",U.length!==1?"s":""]})]}),e.jsx("div",{className:"p-8",children:U.length>0?e.jsx("div",{className:"space-y-4 max-h-[400px] overflow-y-auto",children:U.map(s=>{var i,l,n,x,p;const r=he.has(s.id),a=s.replies&&s.replies.length>0;return e.jsxs("div",{className:"bg-gray-50 rounded-2xl border border-gray-100 overflow-hidden",children:[e.jsxs("div",{className:`p-6 ${a?"cursor-pointer hover:bg-gray-100 transition-colors":""}`,onClick:()=>{a&&be(w=>{const k=new Set(w);return k.has(s.id)?k.delete(s.id):k.add(s.id),k})},children:[e.jsxs("div",{className:"flex items-start justify-between mb-3",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx("div",{className:"w-10 h-10 bg-blue-100 rounded-full flex items-center justify-center text-blue-600 font-black text-sm",children:(s.userName||"U").charAt(0).toUpperCase()}),e.jsxs("div",{children:[e.jsx("p",{className:"font-black text-gray-900 text-sm",children:s.userName||"Anonymous"}),e.jsx("p",{className:"text-[10px] font-bold text-gray-400 uppercase tracking-widest",children:((n=(l=(i=s.createdAt)==null?void 0:i.toDate)==null?void 0:l.call(i))==null?void 0:n.toLocaleDateString())||"Recent"})]})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxs("span",{className:"text-[10px] font-black text-blue-600 bg-blue-50 px-2 py-1 rounded uppercase tracking-widest",children:[((x=s.replies)==null?void 0:x.length)||0," ",((p=s.replies)==null?void 0:p.length)===1?"Reply":"Replies"]}),a&&e.jsx(ne,{size:16,className:`text-gray-400 transition-transform ${r?"rotate-180":""}`})]})]}),e.jsx("h4",{className:"font-black text-gray-900 mb-2",children:s.title}),e.jsx("p",{className:"text-sm text-gray-700 font-medium leading-relaxed",children:s.content})]}),a&&r&&e.jsxs("div",{className:"border-t border-gray-200 bg-white p-6",children:[e.jsxs("div",{className:"flex items-center gap-2 mb-4",children:[e.jsx(_,{size:14,className:"text-blue-600"}),e.jsxs("h5",{className:"text-[10px] font-black text-gray-400 uppercase tracking-widest",children:[s.replies.length," Answer",s.replies.length!==1?"s":""]})]}),e.jsx("div",{className:"space-y-3",children:s.replies.map((w,k)=>e.jsxs("div",{className:"bg-blue-50/50 rounded-xl p-4 border border-blue-100",children:[e.jsxs("div",{className:"flex items-center gap-2 mb-2",children:[e.jsx("div",{className:"w-8 h-8 bg-blue-100 rounded-full flex items-center justify-center text-blue-600 font-black text-xs",children:(w.userName||"U").charAt(0).toUpperCase()}),e.jsxs("div",{children:[e.jsx("p",{className:"font-black text-gray-900 text-xs",children:w.userName||"Anonymous"}),e.jsx("p",{className:"text-[9px] font-bold text-gray-400 uppercase tracking-widest",children:new Date(w.createdAt).toLocaleDateString()||"Recent"})]})]}),e.jsx("p",{className:"text-sm text-gray-700 font-medium leading-relaxed pl-10",children:w.
1content})]},k))})]})]},s.id)})}):e.jsxs("div",{className:"text-center py-12",children:[e.jsx(_,{size:48,className:"text-gray-300 mx-auto mb-4"}),e.jsx("p",{className:"text-gray-400 font-bold text-sm",children:"No questions yet"})]})})]})]}),e.jsx("div",{className:"lg:w-1/3",children:e.jsxs("div",{className:"sticky top-[120px] space-y-8",children:[e.jsxs("div",{className:"bg-white rounded-[40px] p-10 border border-gray-100 shadow-[0_32px_64px_-16px_rgba(0,0,0,0.1)] relative overflow-hidden",children:[e.jsx("div",{className:"absolute top-0 right-0 w-64 h-64 bg-blue-500/10 rounded-full blur-[100px] -mr-32 -mt-32 opacity-60"}),e.jsxs("div",{className:"relative z-10",children:[e.jsxs("div",{className:"flex items-center justify-between mb-10",children:[e.jsxs("div",{className:"flex items-center gap-4",children:[e.jsx("div",{className:"w-12 h-12 bg-blue-600 rounded-2xl flex items-center justify-center shadow-lg shadow-blue-500/30",children:e.jsx(Q,{size:24,className:"text-white"})}),e.jsxs("div",{children:[e.jsx("h2",{className:"text-xl font-black text-gray-900 tracking-tight leading-none",children:"Decision Core"}),e.jsx("p",{className:"text-[10px] font-black text-blue-600 uppercase tracking-widest mt-1.5 opacity-60",children:"Governance Protocol"})]})]}),A&&e.jsxs("div",{className:"flex items-center gap-2 text-blue-600 px-3 py-1 bg-blue-50 rounded-full",children:[e.jsx(J,{size:10,className:"animate-spin"}),e.jsx("span",{className:"text-[9px] font-black uppercase tracking-widest",children:"Syncing"})]})]}),e.jsxs("div",{className:"space-y-8",children:[e.jsxs("div",{className:"space-y-4",children:[e.jsx("label",{className:"text-[10px] font-black text-gray-400 uppercase tracking-[0.2em] ml-1",children:"Market Valuation (INR)"}),e.jsxs("div",{className:"relative group/input",children:[e.jsxs("div",{className:"absolute left-6 top-1/2 -translate-y-1/2 flex items-center gap-3",children:[e.jsx("span",{className:"text-gray-400 font-black text-2xl group-focus-within/input:text-blue-600 transition-colors",children:"â¹"}),e.jsx("div",{className:"w-px h-6 bg-gray-200 group-focus-within/input:bg-blue-200"})]}),e.jsx("input",{type:"number",value:C,onChange:s=>$(s.target.value),placeholder:"Set price...",className:"w-full bg-gray-50 border-2 border-transparent hover:border-gray-200 focus:bg-white focus:border-blue-600 rounded-[30px] pl-20 pr-8 py-6 text-gray-900 font-black placeholder:text-gray-300 outline-none transition-all text-3xl tracking-tighter shadow-inner"})]}),e.jsxs("div",{className:"bg-amber-50/50 p-4 rounded-2xl border border-amber-100/50 flex items-center justify-between",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(ae,{size:12,className:"text-amber-500"}),e.jsx("span",{className:"text-[10px] font-black text-amber-700 uppercase tracking-widest",children:"Proposed"})]}),e.jsxs("span",{className:"text-sm font-black text-amber-600 underline decoration-amber-200",children:["â¹",t.suggestedPrice||"0"]})]})]}),e.jsx("div",{className:"bg-slate-50 rounded-[32px] p-8 border border-gray-100",children:e.jsxs("div",{className:"flex items-center justify-between gap-6",children:[e.jsxs("div",{className:"flex-1",children:[e.jsxs("div",{className:"flex items-center gap-2 mb-2",children:[e.jsx("div",{className:`w-2 h-2 rounded-full ${z?"bg-amber-500":"bg-emerald-500"} animate-pulse`}),e.jsx("h4",{className:"text-[11px] font-black text-slate-900 uppercase tracking-widest",children:"Stealth Configuration"})]}),e.jsx("p",{className:"text-[10px] font-bold text-slate-400 leading-relaxed",children:"Hide market metrics and active enrollment data from the public directory."})]}),e.jsx("button",{onClick:ve,disabled:A,className:`w-14 h-8 rounded-full transition-all relative flex items-center px-1 shrink-0 ${z?"bg-amber-500":"bg-emerald-500"} ${A?"opacity-50":""}`,children:e.jsx("div",{className:`w-6 h-6 bg-white rounded-full shadow-lg transition-all transform ${z?"translate-x-6":"translate-x-0"}`})})]})}),e.jsx("div",{className:"bg-slate-50 rounded-[32px] p-8 border border-gray-100 mt-4",children:e.jsxs("div",{className:"flex items-center justify-between gap-6",children:[e.jsxs("div",{className:"flex-1",children:[e.jsxs("div",{className:"flex items-center gap-2 mb-2",children:[e.jsx("div",{className:`w-2 h-2 rounded-full ${y?"bg-emerald-500":"bg-amber-500"} animate-pulse`}),e.jsx("h4",{className:"text-[11px] font-black text-slate-900 uppercase tracking-widest",children:"Trainer Visibility"})]}),e.jsx("p",{className:"text-[10px] font-bold text-slate-400 leading-relaxed",children:"Show trainer/instructor name and bio to the public in frontend directory."})]}),e.jsx("button",{onClick:ye,disabled:A,className:`w-14 h-8 rounded-full transition-all relative flex items-center px-1 shrink-0 ${y?"bg-emerald-500":"bg-amber-500"} ${A?"opacity-50":""}`,children:e.jsx("div",{className:`w-6 h-6 bg-white rounded-full shadow-lg transition-all transform ${y?"translate-x-6":"translate-x-0"}`})})]})}),(t==null?void 0:t.isExclusive)&&e.jsxs("div",{className:"mt-4 bg-purple-50 rounded-[32px] p-6 border border-purple-100",children:[e.jsxs("div",{className:"flex items-center gap-3 mb-4",children:[e.jsx("div",{className:"w-8 h-8 bg-purple-600 rounded-xl flex items-center justify-center shrink-0",children:e.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"white",strokeWidth:"2.5",strokeLinecap:"round",strokeLinejoin:"round",children:[e.jsx("rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2"}),e.jsx("path",{d:"M7 11V7a5 5 0 0 1 10 0v4"})]})}),e.jsxs("div",{children:[e.jsx("h4",{className:"text-[11px] font-black text-purple-900 uppercase tracking-widest",children:"Campus Exclusive Course"}),e.jsx("p",{className:"text-[10px] font-bold text-purple-500 mt-0.5",children:"Hidden from public catalog · Auto-enrolled for matched students"})]})]}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{className:"flex items-center justify-between bg-white rounded-xl px-4 py-2.5 border border-purple-100",children:[e.jsx("span",{className:"text-[10px] font-black text-purple-700 uppercase tracking-widest",children:"Assigned Students"}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:"text-sm font-black text-purple-900",children:t.assignedStudentCount??(((K=t.assignedStudentEmails)==null?void 0:K.length)||0)}),e.jsx("button",{type:"button",onClick:async()=>{try{if(t.assignedBatchIds&&t.assignedBatchIds.length>0){const s=B(u,"partner_student_batches"),l=(await Ae(s)).docs.map(n=>({id:n.id,...n.data()})).filter(n=>
1t.assignedBatchIds.includes(n.id)).reduce((n,x)=>{var p;return n+(((p=x.students)==null?void 0:p.length)||0)},0);l!==t.assignedStudentCount?(await v(b(u,"courses",d),{assignedStudentCount:l}),W(n=>({...n,assignedStudentCount:l})),o.success("Updated",`Student count refreshed: ${l} students`)):o.success("Up to date","Count is already accurate")}}catch(s){console.error("Failed to refresh count:",s),o.error("Error","Failed to refresh student count")}},className:"p-1 text-purple-600 hover:bg-purple-50 rounded-lg transition-all",title:"Refresh student count from batches",children:e.jsx(J,{size:14})})]})]}),t.assignedBatchNames&&t.assignedBatchNames.length>0&&e.jsxs("div",{className:"bg-white rounded-xl px-4 py-3 border border-purple-100",children:[e.jsxs("p",{className:"text-[10px] font-black text-purple-600 uppercase tracking-widest mb-2",children:["Assigned Batches (",t.assignedBatchNames.length,")"]}),e.jsx("div",{className:"flex flex-wrap gap-1.5",children:t.assignedBatchNames.map((s,r)=>e.jsx("span",{className:"px-2.5 py-1 bg-purple-50 border border-purple-200 text-purple-800 rounded-full text-[10px] font-bold",children:s},r))})]}),t.assignedColleges&&t.assignedColleges.length>0&&e.jsxs("div",{className:"bg-white rounded-xl px-4 py-3 border border-purple-100",children:[e.jsxs("p",{className:"text-[10px] font-black text-purple-600 uppercase tracking-widest mb-2",children:["Institutions (",t.assignedColleges.length,")"]}),e.jsx("div",{className:"flex flex-wrap gap-1.5",children:t.assignedColleges.map((s,r)=>e.jsxs("span",{className:"px-2.5 py-1 bg-indigo-50 border border-indigo-200 text-indigo-800 rounded-full text-[10px] font-bold",children:["ðï¸ ",s]},r))})]})]})]}),e.jsxs("div",{className:"space-y-4",children:[e.jsxs("div",{className:"flex items-center justify-between px-1",children:[e.jsx("label",{className:"text-[10px] font-black text-gray-400 uppercase tracking-[0.2em]",children:"Audit Feedback"}),S&&e.jsx("span",{className:"text-[9px] font-black text-blue-600 uppercase tracking-widest bg-blue-50 px-2 py-0.5 rounded italic",children:"Draft Active"})]}),e.jsxs("div",{className:"relative group/text",children:[e.jsx(_,{size:18,className:"absolute left-6 top-6 text-gray-300 group-focus-within/text:text-blue-500 transition-colors"}),e.jsx("textarea",{value:S,onChange:s=>q(s.target.value),placeholder:"Provide detailed revision requests or approval notes...",rows:5,className:"w-full bg-gray-50 border-2 border-transparent hover:border-gray-100 focus:bg-white focus:border-blue-600 rounded-[30px] pl-16 pr-8 py-6 text-gray-900 font-bold placeholder:text-gray-300 outline-none transition-all resize-none text-sm leading-relaxed shadow-inner"})]})]}),e.jsxs("div",{className:"pt-6 space-y-4",children:[e.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[e.jsxs("button",{onClick:()=>Y(!0),className:`flex flex-col items-center justify-center gap-2 h-28 ${j!=null&&j.isVerifiedPro?"bg-amber-600 hover:bg-amber-700":"bg-emerald-600 hover:bg-emerald-700"} text-white rounded-[24px] transition-all active:scale-[0.98] shadow-xl shadow-emerald-500/20 group`,children:[e.jsx(Me,{size:24,className:"group-hover:scale-110 transition-transform"}),e.jsx("span",{className:"text-[10px] font-black uppercase tracking-widest text-center px-2",children:j!=null&&j.isVerifiedPro?"Approve (Elite Partner)":"Verify as Elite Partner"})]}),e.jsxs("button",{onClick:()=>Y(!1),className:"flex flex-col items-center justify-center gap-2 h-28 bg-blue-600 hover:bg-blue-700 text-white rounded-[24px] transition-all active:scale-[0.98] shadow-xl shadow-blue-500/20 group",children:[e.jsx(Q,{size:24,className:"group-hover:scale-110 transition-transform"}),e.jsx("span",{className:"text-[10px] font-black uppercase tracking-widest text-center px-2",children:"Standard Live"})]})]}),e.jsxs("button",{onClick:Ne,className:"w-full h-16 bg-white border-2 border-slate-900 text-slate-900 font-black uppercase text-xs tracking-[0.15em] rounded-[20px] transition-all hover:bg-slate-900 hover:text-white active:scale-[0.98] flex items-center justify-center gap-3",children:[e.jsx(J,{size:18}),"Request Revisions"]}),e.jsx("button",{onClick:we,className:"w-full h-16 bg-red-50 text-red-600 font-black uppercase text-xs tracking-[0.15em] rounded-[20px] transition-all hover:bg-red-600 hover:text-white active:scale-[0.98] flex items-center justify-center group",children:"Reject & Destroy"})]})]})]})]}),e.jsxs("div",{className:"bg-slate-900 rounded-[40px] p-10 border border-white/10 shadow-2xl relative overflow-hidden",children:[e.jsx("div",{className:"absolute top-0 right-0 w-32 h-32 bg-blue-500/20 rounded-full blur-[60px] -mr-16 -mt-16"}),e.jsxs("div",{className:"flex items-center gap-3 mb-8",children:[e.jsx("div",{className:"p-2 bg-white/10 rounded-xl",children:e.jsx(_e,{size:16,className:"text-blue-400"})}),e.jsx("h3",{className:"text-[10px] font-black text-white uppercase tracking-[0.2em]",children:"Technical Audit Registry"})]}),e.jsxs("div",{className:"space-y-6",children:[[{label:"Category",value:t.category||"Uncategorized",color:"text-blue-400"},{label:"Curriculum",value:`${(t.curriculum||[]).reduce((s,r)=>{var a;return s+(((a=r.lessons)==null?void 0:a.filter(i=>i.type==="video").length)||0)},0)} Units`,color:"text-white"},{label:"Runtime",value:G(),color:"text-white"},{label:"Assessment",value:`${(t.curriculum||[]).reduce((s,r)=>{var a;return s+(((a=r.lessons)==null?void 0:a.filter(i=>i.type==="quiz").length)||0)},0)} Interactive`,color:"text-white"}].map((s,r)=>e.jsxs("div",{className:"flex justify-between items-center group/stat border-b border-white/5 pb-4 last:border-0 last:pb-0",children:[e.jsx("span",{className:"text-white/40 text-[9px] font-black uppercase tracking-widest transition-all group-hover/stat:text-white/60",children:s.label}),e.jsx("span",{className:`font-black tracking-tight text-sm ${s.color}`,children:s.value})]},r)),e.jsx("div",{className:"mt-8 pt-8 border-t border-white/10",children:e.jsxs("div",{className:"flex items-center justify-between px-1",children:[e.jsxs("div",{className:"flex flex-col",children:[e.jsx("span",{className:"text-[9px] font-black text-white/30 uppercase tracking-widest mb-1",children:"QA Threshold"}),e.jsx("span",{className:`text-[10px] font-black uppercase tracking-widest px-3 py-1.5 rounded-xl text-center ${(t.curriculum||[]).reduce((s,r)=>{var a;return s+(((a=r.lessons)==null?void 0:a.length)||0)},0)>=20?"bg-emerald-500/10 text-emerald-400 border border-emerald-500/20":"bg-blue-500/10 text-blue-400 border border-blue-500/20"}`,children:(t.curriculum||[]).reduce((s,r)=>{var a;return s+(((a=r.lessons)==null?void 0:a.length)||0)},0)>=20?"Professional":"Intermediate"})]}),e.jsxs("div",{className:"flex flex-col items-end",children:[e.jsx("span",{className:"text-[9px] font-black text-white/30 uppercase tracking-widest mb-1",children:"Expert Score"}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:"text-xl font-black text-white",children:h.length>0?(h.reduce((s,r)=>s+r.rating,0)/h.length).toFixed(1):"0.0"}),e.jsx(D,{size:16,className:"fill-amber-500 text-amber-500"})]})]})]})})]})]})]})})]})]}):e.jsxs("div",{className:"min-h-screen bg-gray-50 flex flex-col items-center justify-center text-gray-900 p-6",children:[e.jsx(te,{size:64,className:"text-red-500 mb-6"}),e.jsx("h1",{className:"text-3xl font-black mb-2",children:"Course Not Found"}),e.jsx("p",{className:"text-gray-500 mb-8",children:"The course may have been deleted or moved."}),e.jsx(X,{to:"/admin/courses",className:"bg-blue-600 text-white px-8 py-3 rounded-xl font-black uppercase text-xs tracking-widest hover:bg-blue-700 transition-all",children:"Back to Terminal"})]})}
1export{Xe as default};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.