PageSourceSearch

https://caregene.ai/assets/NewUndiagnosedJourney-BVh5USEH.js

js caregene.ai collected 2026-10-05 15:20:56 UTC 28,374 bytes, 1 lines download raw bytes

1import{j as e}from"./vendor-markdown-kndB-TrI.js";import{a as c,aE as S,d as T,as as G,A,m as I,i as M,Q as O,l as z,q,G as P,a6 as H,f as U,ai as _,Y as J,_ as W,X as L,J as R,I as V,b3 as Y}from"./vendor-icons-CY2GDqE3.js";import{W as K,A as Q}from"./WhoIsThisFor-D6ZX-9Ur.js";import{m as k,A as X}from"./index-BlkXabAy.js";import"./vendor-charts-DZljEEfB.js";import"./vendor-motion-jquII4NE.js";function Z({onComplete:o,onBack:d,progress:i,initialData:a}){const[s,n]=c.useState(a?.mainConcern||""),[l,m]=c.useState(!1),u=p=>{p.preventDefault(),s.trim()&&o({mainConcern:s.trim()})},f=s.trim().split(/\s+/).filter(p=>p.length>0).length;return e.jsxs("div",{className:"min-h-screen flex flex-col font-sans selection:bg-[#0B3A66] selection:text-white",style:{backgroundColor:"#F9F8F6"},children:[e.jsxs("div",{className:"px-8 py-6",children:[e.jsxs("div",{className:"flex items-center justify-between mb-4",children:[e.jsx("div",{className:"flex items-center gap-2",children:e.jsx("span",{className:"text-[18px] font-bold text-[#051B30] tracking-tight",children:"CareGene"})}),e.jsxs("div",{className:"flex items-center gap-6",children:[d&&e.jsxs("button",{onClick:d,className:"flex items-center gap-2 text-[#64748B] hover:text-[#0B3A66] transition-colors font-bold text-[14px]",children:[e.jsx(S,{className:"w-4 h-4"}),"Back"]}),e.jsxs("span",{className:"text-[12px] font-black text-[#087179] tracking-widest uppercase",children:["STEP ",i.current," OF ",i.total]})]})]}),e.jsx("div",{className:"h-1 rounded-full bg-[#E2E8F0] overflow-hidden",children:e.jsx(k.div,{initial:{width:0},animate:{width:`${i.current/i.total*100}%`},className:"h-full bg-[#087179] transition-all duration-500"})})]}),e.jsx("div",{className:"flex-1 flex items-center justify-center px-6 py-12",children:e.jsxs("div",{className:"w-full max-w-2xl",children:[e.jsxs("div",{className:"text-center mb-12",children:[e.jsx("div",{className:"w-20 h-20 bg-white rounded-[32px] flex items-center justify-center mx-auto mb-8 shadow-xl shadow-black/5 border border-[#F1F5F9]",children:e.jsx(T,{className:"w-10 h-10 text-[#087179]",strokeWidth:2})}),e.jsx("h1",{className:"text-[44px] font-serif font-medium text-[#051B30] leading-tight tracking-tight mb-4",children:"Your Primary Concern"}),e.jsx("p",{className:"text-[18px] text-[#475569] font-medium leading-relaxed max-w-md mx-auto",children:"Help Genie understand what you're trying to figure out in your own words."})]}),e.jsxs("form",{onSubmit:u,className:"space-y-8",children:[e.jsxs("div",{className:"relative",children:[e.jsx("textarea",{value:s,onChange:p=>n(p.target.value),onFocus:()=>m(!0),onBlur:()=>m(!1),placeholder:"Example: My daughter has delays in speech and motor skills. She's 3 years old and still not talking in sentences...",rows:8,required:!0,className:`w-full p-8 rounded-[32px] border-2 transition-all outline-none text-[18px] font-medium leading-relaxed placeholder:text-[#94A3B8] shadow-sm ${l?"border-[#087179]/30 bg-white ring-4 ring-[#087179]/5":"border-[#F1F5F9] bg-[#F8FAFC]"}`}),e.jsxs("div",{className:"absolute bottom-6 left-8 right-8 flex items-center justify-between pointer-events-none",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(G,{className:"w-4 h-4",style:{color:s.length>20?"#087179":"#94A3B8"}}),e.jsx("span",{className:`text-[13px] font-bold uppercase tracking-wider ${s.length>20?"text-[#087179]":"text-[#94A3B8]"}`,children:s.length>20?"Great Detail":"Add more context"})]}),e.jsxs("div",{className:"text-[13px] font-black text-[#94A3B8] uppercase tracking-widest",children:[f," Words"]})]})]}),e.jsxs("div",{className:"p-8 rounded-[32px] bg-[#EBF2F8] border-2 border-blue-50",children:[e.jsx("h4",{className:"text-[15px] font-bold text-[#0B3A66] mb-3 uppercase tracking-widest",children:"What to include:"}),e.jsxs("ul",{className:"space-y-2 text-[15px] text-[#4A5F8B] font-medium",children:[e.jsxs("li",{className:"flex items-center gap-3",children:[e.jsx("div",{className:"w-1.5 h-1.5 rounded-full bg-[#0B3A66]/30"}),"Symptoms or behaviors you've noticed"]}),e.jsxs("li",{className:"flex items-center gap-3",children:[e.jsx("div",{className:"w-1.5 h-1.5 rounded-full bg-[#0B3A66]/30"}),"When the concerns first started"]}),e.jsxs("li",{className:"flex items-center gap-3",children:[e.jsx("div",{className:"w-1.5 h-1.5 rounded-full bg-[#0B3A66]/30"}),"Specialists or tests you've already tried"]})]})]}),e.jsxs("button",{type:"submit",disabled:!s.trim(),className:`w-full h-[72px] rounded-full transition-all duration-200 flex items-center justify-center gap-3 text-[20px] font-bold ${s.trim()?"bg-[#FF6B47] text-white shadow-xl shadow-[#FF6B47]/20 hover:bg-[#
1E55A38] active:scale-[0.98]":"bg-[#F1F5F9] text-[#CBD5E1] cursor-not-allowed"}`,children:[e.jsx("span",{children:"Continue"}),e.jsx(A,{className:"w-6 h-6",strokeWidth:2.5})]})]})]})})]})}const ee=["Developmental delays","Speech delays","Motor skill delays","Seizures","Sleep difficulties","Feeding challenges","Behavioral concerns","Sensory sensitivities","Muscle weakness","Vision problems","Hearing issues","Balance problems","Learning difficulties","Social interaction challenges","Repetitive behaviors","Anxiety"];function te({onComplete:o,onBack:d,progress:i,initialData:a}){const[s,n]=c.useState(a?.symptoms||[]),[l,m]=c.useState(a?.customSymptoms||[]),[u,f]=c.useState(""),[p,g]=c.useState(!1),N=t=>{s.includes(t)?n(s.filter(r=>r!==t)):n([...s,t])},j=()=>{const t=u.trim();t&&!l.includes(t)&&(m([...l,t]),f(""),g(!1))},w=t=>{m(l.filter(r=>r!==t))},x=t=>{t.preventDefault(),(s.length>0||l.length>0)&&o({symptoms:s,customSymptoms:l})},y=s.length+l.length;return e.jsxs("div",{className:"min-h-screen flex flex-col font-sans selection:bg-[#0B3A66] selection:text-white",style:{backgroundColor:"#F9F8F6"},children:[e.jsxs("div",{className:"px-8 py-6",children:[e.jsxs("div",{className:"flex items-center justify-between mb-4",children:[e.jsx("div",{className:"flex items-center gap-2",children:e.jsx("span",{className:"text-[18px] font-bold text-[#051B30] tracking-tight",children:"CareGene"})}),e.jsxs("div",{className:"flex items-center gap-6",children:[d&&e.jsxs("button",{onClick:d,className:"flex items-center gap-2 text-[#64748B] hover:text-[#0B3A66] transition-colors font-bold text-[14px]",children:[e.jsx(S,{className:"w-4 h-4"}),"Back"]}),e.jsxs("span",{className:"text-[12px] font-black text-[#087179] tracking-widest uppercase",children:["STEP ",i.current," OF ",i.total]})]})]}),e.jsx("div",{className:"h-1 rounded-full bg-[#E2E8F0] overflow-hidden",children:e.jsx(k.div,{initial:{width:0},animate:{width:`${i.current/i.total*100}%`},className:"h-full bg-[#087179] transition-all duration-500"})})]}),e.jsx("div",{className:"flex-1 flex items-start justify-center px-6 py-12 overflow-y-auto",children:e.jsxs("div",{className:"w-full max-w-3xl",children:[e.jsxs("div",{className:"text-center mb-12",children:[e.jsx("div",{className:"w-20 h-20 bg-white rounded-[32px] flex items-center justify-center mx-auto mb-8 shadow-xl shadow-black/5 border border-[#F1F5F9]",children:e.jsx(I,{className:"w-10 h-10 text-[#087179]",strokeWidth:2})}),e.jsx("h1",{className:"text-[44px] font-serif font-medium text-[#051B30] leading-tight tracking-tight mb-4",children:"Identify Symptoms"}),e.jsx("p",{className:"text-[18px] text-[#475569] font-medium leading-relaxed max-w-md mx-auto",children:"Select what you're noticing. Genie will use these to build your care timeline."})]}),e.jsxs("form",{onSubmit:x,className:"space-y-10",children:[e.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-4",children:ee.map(t=>{const r=s.includes(t);return e.jsxs("button",{type:"button",onClick:()=>N(t),className:`p-5 rounded-[24px] border-2 transition-all duration-200 text-left flex items-center gap-4 ${r?"border-[#087179] bg-white shadow-lg shadow-[#087179]/5":"border-[#F1F5F9] bg-[#F8FAFC] hover:border-[#E2E8F0]"}`,children:[e.jsx("div",{className:`w-6 h-6 rounded-lg border-2 flex items-center justify-center transition-all ${r?"bg-[#087179] border-[#087179]":"bg-white border-[#CBD5E1]"}`,children:r&&e.jsx(M,{className:"w-4 h-4 text-white",strokeWidth:3})}),e.jsx("span",{className:`text-[16px] font-bold ${r?"text-[#051B30]":"text-[#475569]"}`,children:t})]},t)})}),e.jsxs("div",{className:"p-8 rounded-[32px] bg-white border border-[#F1F5F9] shadow-sm",children:[e.jsx("h3",{className:"text-[14px] font-black text-[#94A3B8] uppercase tracking-widest mb-6",children:"Custom Symptoms"}),e.jsx("div",{className:"flex flex-wrap gap-3 mb-6",children:l.map(t=>e.jsxs(k.div,{initial:{scale:.9,opacity:0},animate:{scale:1,opacity:1},className:"px-4 py-2 rounded-full bg-[#F0FDFA] border border-[#087179]/20 flex items-center gap-2",children:[e.jsx("span",{className:"text-[14px] font-bold text-[#087179]",children:t}),e.jsx("button",{type:"button",onClick:()=>w(t),className:"w-5 h-5 rounded-full bg-[#087179] text-white flex items-center justify-center hover:bg-[#0B3A66] transition-colors",children:e.jsx("span",{className:"text-[14px] leading-none",children:"×"})})]},t))}),p?e.jsxs("div",{className:"flex gap-3",children:[e.jsx("input",{type:"text",value:u,onChange:t=>f(t.target.value),onKeyDown:t=>{t.key==="Enter"&&(t.preventDefault(),j())},placeholder:"Type a symptom...",autoFocus:!0,className:"flex-1 h-[58px] px-6 rounded-2xl border-2 border-[#087179]/30 bg-white outline-none text-[16px] font-medium"}),e.jsx("button",{type:"button",onClick:j,className:"h-[58px] px-8 rounded-2xl bg-[#087179] text-white font-bold",children:"Add"})]}):e.jsxs("button",{type:"button",onClick:()=>g(!0),className:"w-full h-[58px] rounded-2xl border-2 border-dashed border-[#CBD5E1] text-[#64748B] font-bold flex items-center justify-center gap-2 hover:bg-[#F8FAFC] transition-colors",children:[e.jsx(O,{className:"w-5 h-5"}),"Add another symptom"]})]}),e.jsxs("button",{type:"submit",disabled:y===0,className:`w-full h-[72px] rounded-full transition-all duration-200 flex items-center justify-center gap-3 text-[20px] font-bold ${y>0?"bg-[#FF6B47] text-white shadow-xl shadow-[#FF6B47]/20 hover:bg-[#
1E55A38] active:scale-[0.98]":"bg-[#F1F5F9] text-[#CBD5E1] cursor-not-allowed"}`,children:[e.jsx("span",{children:"Continue"}),e.jsx(A,{className:"w-6 h-6",strokeWidth:2.5})]})]})]})})]})}function se({onComplete:o,onBack:d,progress:i,initialData:a}){const[s,n]=c.useState(a?.childName||""),[l,m]=c.useState(a?.childAge||""),[u,f]=c.useState(a?.timeline||""),[p,g]=c.useState(!1),N=x=>{x.preventDefault(),s.trim()&&l.trim()&&u.trim()&&o({childName:s.trim(),childAge:l.trim(),timeline:u.trim()})},j=s.trim()&&l.trim()&&u.trim(),w=u.trim().split(/\s+/).filter(x=>x.length>0).length;return e.jsxs("div",{className:"min-h-screen flex flex-col font-sans selection:bg-[#0B3A66] selection:text-white",style:{backgroundColor:"#F9F8F6"},children:[e.jsxs("div",{className:"px-8 py-6",children:[e.jsxs("div",{className:"flex items-center justify-between mb-4",children:[e.jsx("div",{className:"flex items-center gap-2",children:e.jsx("span",{className:"text-[18px] font-bold text-[#051B30] tracking-tight",children:"CareGene"})}),e.jsxs("div",{className:"flex items-center gap-6",children:[d&&e.jsxs("button",{onClick:d,className:"flex items-center gap-2 text-[#64748B] hover:text-[#0B3A66] transition-colors font-bold text-[14px]",children:[e.jsx(S,{className:"w-4 h-4"}),"Back"]}),e.jsxs("span",{className:"text-[12px] font-black text-[#087179] tracking-widest uppercase",children:["STEP ",i.current," OF ",i.total]})]})]}),e.jsx("div",{className:"h-1 rounded-full bg-[#E2E8F0] overflow-hidden",children:e.jsx(k.div,{initial:{width:0},animate:{width:`${i.current/i.total*100}%`},className:"h-full bg-[#087179] transition-all duration-500"})})]}),e.jsx("div",{className:"flex-1 flex items-center justify-center px-6 py-12",children:e.jsxs("div",{className:"w-full max-w-2xl",children:[e.jsxs("div",{className:"text-center mb-12",children:[e.jsx("div",{className:"w-20 h-20 bg-white rounded-[32px] flex items-center justify-center mx-auto mb-8 shadow-xl shadow-black/5 border border-[#F1F5F9]",children:e.jsx(z,{className:"w-10 h-10 text-[#087179]",strokeWidth:2})}),e.jsx("h1",{className:"text-[44px] font-serif font-medium text-[#051B30] leading-tight tracking-tight mb-4",children:"Care Timeline"}),e.jsx("p",{className:"text-[18px] text-[#475569] font-medium leading-relaxed max-w-md mx-auto",children:"Organizing your observations into a clinical timeline helps specialists spot patterns."})]}),e.jsxs("form",{onSubmit:N,className:"space-y-8",children:[e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-6",children:[e.jsxs("div",{className:"space-y-3",children:[e.jsx("label",{className:"block text-[14px] font-bold text-[#475569] uppercase tracking-wider ml-1",children:"First Name"}),e.jsx("input",{type:"text",value:s,onChange:x=>n(x.target.value),placeholder:"e.g., Alex",required:!0,className:"w-full h-[64px] px-6 rounded-2xl border-2 border-[#F1F5F9] bg-[#F8FAFC] focus:border-[#087179]/30 focus:bg-white outline-none transition-all text-[18px] font-medium shadow-sm"})]}),e.jsxs("div",{className:"space-y-3",children:[e.jsx("label",{className:"block text-[14px] font-bold text-[#475569] uppercase tracking-wider ml-1",children:"Current Age"}),e.jsx("input",{type:"text",value:l,onChange:x=>m(x.target.value),placeholder:"e.g., 3 years",required:!0,className:"w-full h-[64px] px-6 rounded-2xl border-2 border-[#F1F5F9] bg-[#F8FAFC] focus:border-[#087179]/30 focus:bg-white outline-none transition-all text-[18px] font-medium shadow-sm"})]})]}),e.jsxs("div",{className:"relative",children:[e.jsx("label",{className:"block text-[14px] font-bold text-[#475569] uppercase tracking-wider mb-3 ml-1",children:"Clinical Narrative"}),e.jsx("textarea",{value:u,onChange:x=>f(x.target.value),onFocus:()=>g(!0),onBlur:()=>g(!1),placeholder:"Example: At 18 months, we noticed speech delays. By age 2, we started early intervention. Recently, seizures have emerged...",rows:7,required:!0,className:`w-full p-8 rounded-[32px] border-2 transition-all outline-none text-[18px] font-medium leading-relaxed placeholder:text-[#94A3B8] shadow-sm ${p?"border-[#087179]/30 bg-white ring-4 ring-[#087179]/5":"border-[#F1F5F9] bg-[#F8FAFC]"}`}),e.jsxs("div",{className:"flex items-center justify-between mt-3 px-2",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(q,{className:"w-4 h-4",style:{color:w>15?"#087179":"#94A3B8"}}),e.jsx("span",{className:`text-[13px] font-bold uppercase tracking-wider ${w>15?"text-[#087179]":"text-[#94A3B8]"}`,children:w>15?"Great Detail":"Include more context"})]}),e.jsxs("div",{className:"text-[13px] font-black text-[#94A3B8] uppercase tracking-widest",children:[w," Words"]})]})]}),e.jsxs("div",{className:"p-8 rounded-[32px] bg-[#EBF2F8] border-2 border-blue-50",children:[e.jsx("h4",{className:"text-[15px] font-bold text-[#0B3A66] mb-3 uppercase tracking-widest",children:"Timeline Tips:"}),e.jsxs("ul",{className:"space-y-2 text-[15px] text-[#4A5F8B] font-medium",children:[e.jsxs("li",{className:"flex items-center gap-3",children:[e.jsx("div",{className:"w-1.5 h-1.5 rounded-full bg-[#0B3A66]/30"}),"Include ages or dates if you remember them"]}),e.jsxs("li",{className:"flex items-center gap-3",children:[e.jsx("div",{className:"w-1.5 h-1.5 rounded-full bg-[#0B3A66]/30"}),"Note any milestones that were different"]}),e.jsxs("li",{className:"flex items-center gap-3",children:[e.jsx("div",{className:"w-1.5 h-1.5 rounded-full bg-[#0B3A66]/30"}),"Describe what has changed over time"]})]})]}),e.jsxs("button",{type:"submit",disabled:!j,className:`w-full h-[72px] rounded-full transition-all duration-200 flex items-center justify-center gap-3 text-[20px] font-bold ${j?"bg-[#FF6B47] text-white shadow-xl shadow-[#FF6B47]/20 hover:bg-[#
1E55A38] active:scale-[0.98]":"bg-[#F1F5F9] text-[#CBD5E1] cursor-not-allowed"}`,children:[e.jsx("span",{children:"Continue"}),e.jsx(A,{className:"w-6 h-6",strokeWidth:2.5})]})]})]})})]})}function ae({onComplete:o,onSkip:d,onBack:i,progress:a,initialData:s}){const[n,l]=c.useState(s?.hasPrimaryDoctor??null),[m,u]=c.useState(s?.doctorName||""),[f,p]=c.useState(s?.doctorSpecialty||""),[g,N]=c.useState(s?.doctorPractice||""),[j,w]=c.useState(s?.doctorEmail||""),[x,y]=c.useState(s?.doctorPhone||""),t=v=>{v.preventDefault(),n===!1?o({hasPrimaryDoctor:!1}):n===!0&&m.trim()&&o({hasPrimaryDoctor:!0,doctorName:m.trim(),doctorSpecialty:f.trim()||void 0,doctorPractice:g.trim()||void 0,doctorEmail:j.trim()||void 0,doctorPhone:x.trim()||void 0})},r=n===!1||n===!0&&m.trim();return e.jsxs("div",{className:"min-h-screen flex flex-col font-sans selection:bg-[#0B3A66] selection:text-white",style:{backgroundColor:"#F9F8F6"},children:[e.jsxs("div",{className:"px-8 py-6",children:[e.jsxs("div",{className:"flex items-center justify-between mb-4",children:[e.jsx("div",{className:"flex items-center gap-2",children:e.jsx("span",{className:"text-[18px] font-bold text-[#051B30] tracking-tight",children:"CareGene"})}),e.jsxs("div",{className:"flex items-center gap-6",children:[i&&e.jsxs("button",{onClick:i,className:"flex items-center gap-2 text-[#64748B] hover:text-[#0B3A66] transition-colors font-bold text-[14px]",children:[e.jsx(S,{className:"w-4 h-4"}),"Back"]}),e.jsxs("span",{className:"text-[12px] font-black text-[#087179] tracking-widest uppercase",children:["STEP ",a.current," OF ",a.total]})]})]}),e.jsx("div",{className:"h-1 rounded-full bg-[#E2E8F0] overflow-hidden",children:e.jsx(k.div,{initial:{width:0},animate:{width:`${a.current/a.total*100}%`},className:"h-full bg-[#087179] transition-all duration-500"})})]}),e.jsx("div",{className:"flex-1 flex items-center justify-center px-6 py-12 overflow-y-auto",children:e.jsxs("div",{className:"w-full max-w-2xl",children:[e.jsxs("div",{className:"text-center mb-12",children:[e.jsx("div",{className:"w-20 h-20 bg-white rounded-[32px] flex items-center justify-center mx-auto mb-8 shadow-xl shadow-black/5 border border-[#F1F5F9]",children:e.jsx(P,{className:"w-10 h-10 text-[#087179]",strokeWidth:2})}),e.jsx("h1",{className:"text-[44px] font-serif font-medium text-[#051B30] leading-tight tracking-tight mb-4",children:"Care Team"}),e.jsx("p",{className:"text-[18px] text-[#475569] font-medium leading-relaxed max-w-md mx-auto",children:"Tell us about your primary specialist so Genie can help coordinate communications."})]}),e.jsxs("form",{onSubmit:t,className:"space-y-8",children:[e.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[e.jsx($,{active:n===!0,onClick:()=>l(!0),label:"Working with a doctor"}),e.jsx($,{active:n===!1,onClick:()=>l(!1),label:"No doctor yet"})]}),e.jsx(X,{children:n===!0&&e.jsx(k.div,{initial:{height:0,opacity:0},animate:{height:"auto",opacity:1},exit:{height:0,opacity:0},className:"space-y-6 overflow-hidden",children:e.jsxs("div",{className:"p-8 rounded-[40px] bg-white shadow-[0_20px_50px_rgba(0,0,0,0.06)] border border-white/60 space-y-6",children:[e.jsx(B,{icon:P,label:"Doctor's Full Name",value:m,onChange:u,placeholder:"e.g., Dr. Sarah Johnson",required:!0}),e.jsx(B,{label:"Specialty",value:f,onChange:p,placeholder:"e.g., Pediatric Neurologist"}),e.jsx(B,{icon:H,label:"Hospital / Practice",value:g,onChange:N,placeholder:"e.g., Boston Children's"}),e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-4",children:[e.jsx(B,{icon:U,label:"Email",value:j,onChange:w,placeholder:"[email protected]"}),e.jsx(B,{icon:_,label:"Phone",value:x,onChange:y,placeholder:"(555) 000-0000"})]})]})})}),e.jsxs("div",{className:"flex flex-col gap-4",children:[e.jsxs("button",{type:"submit",disabled:!r,className:`w-full h-[72px] rounded-full transition-all duration-200 flex items-center justify-center gap-3 text-[20px] font-bold ${r?"bg-[#FF6B47] text-white shadow-xl shadow-[#FF6B47]/20 hover:bg-[#E55A38] active:scale-[0.98]":"bg-[#F1F5F9] text-[#CBD5E1] cursor-not-allowed"}`,children:[e.jsx("span",{children:"Continue"}),e.jsx(A,{className:"w-6 h-6",strokeWidth:2.5})]}),e.jsx("button",{type:"button",onClick:d,className:"w-full h-[64px] rounded-full border-2 border-[#F1F5F9] text-[16px] font-bold text-[#64748B] hover:bg-white transition-all",children:"Skip for now"})]})]})]})})]})}function $({active:o,onClick:d,label:i}){return e.jsxs("button",{type:"button",onClick:d,className:`h-[64px] rounded-2xl border-2 transition-all duration-200 font-bold text-[16px] flex items-center justify-center gap-2 ${o?"border-[#087179] bg-white text-[#051B30] shadow-lg shadow-[#087179]/5":"border-[#F1F5F9] bg-[#F8FAFC] text-[#64748B] hover:border-[#
1E2E8F0]"}`,children:[o&&e.jsx(J,{className:"w-5 h-5 text-[#087179]",strokeWidth:2.5}),i]})}function B({icon:o,label:d,value:i,onChange:a,placeholder:s,required:n=!1}){return e.jsxs("div",{className:"space-y-2",children:[e.jsxs("label",{className:"block text-[13px] font-black text-[#94A3B8] uppercase tracking-widest ml-1",children:[d," ",n&&e.jsx("span",{className:"text-[#EF4444]",children:"*"})]}),e.jsxs("div",{className:"relative group",children:[o&&e.jsx(o,{className:"absolute left-5 top-1/2 -translate-y-1/2 w-5 h-5 text-[#CBD5E1] group-focus-within:text-[#087179] transition-colors"}),e.jsx("input",{type:"text",value:i,onChange:l=>a(l.target.value),placeholder:s,className:`w-full h-[58px] rounded-2xl border-2 border-[#F1F5F9] bg-[#F8FAFC] focus:border-[#087179]/30 focus:bg-white outline-none transition-all text-[16px] font-medium placeholder:text-[#CBD5E1] ${o?"pl-14":"px-6"}`})]})]})}function le({onComplete:o,onSkip:d,onBack:i,progress:a}){const[s,n]=c.useState(!1),[l,m]=c.useState([]),u=t=>{t.preventDefault(),n(!0)},f=()=>{n(!1)},p=t=>{t.preventDefault(),n(!1);const r=Array.from(t.dataTransfer.files);N(r)},g=t=>{if(t.target.files){const r=Array.from(t.target.files);N(r)}},N=t=>{const v=t.filter(F=>{const D=F.type==="application/pdf"||F.type.startsWith("image/"),E=F.size<=10*1024*1024;return D&&E}).map(F=>({name:F.name,size:F.size,type:F.type}));m([...l,...v])},j=t=>{m(l.filter((r,v)=>v!==t))},w=t=>t<1024?t+" B":t<1024*1024?(t/1024).toFixed(1)+" KB":(t/(1024*1024)).toFixed(1)+" MB",x=t=>t==="application/pdf"?R:t.startsWith("image/")?V:Y,y=()=>{l.length>0?o({hasDocuments:!0,documentCount:l.length}):d()};return e.jsxs("div",{className:"min-h-screen flex flex-col font-sans selection:bg-[#0B3A66] selection:text-white",style:{backgroundColor:"#F9F8F6"},children:[e.jsxs("div",{className:"px-8 py-6",children:[e.jsxs("div",{className:"flex items-center justify-between mb-4",children:[e.jsx("div",{className:"flex items-center gap-2",children:e.jsx("span",{className:"text-[18px] font-bold text-[#051B30] tracking-tight",children:"CareGene"})}),e.jsxs("div",{className:"flex items-center gap-6",children:[i&&e.jsxs("button",{onClick:i,className:"flex items-center gap-2 text-[#64748B] hover:text-[#0B3A66] transition-colors font-bold text-[14px]",children:[e.jsx(S,{className:"w-4 h-4"}),"Back"]}),e.jsxs("span",{className:"text-[12px] font-black text-[#087179] tracking-widest uppercase",children:["STEP ",a.current," OF ",a.total]})]})]}),e.jsx("div",{className:"h-1 rounded-full bg-[#E2E8F0] overflow-hidden",children:e.jsx(k.div,{initial:{width:0},animate:{width:`${a.current/a.total*100}%`},className:"h-full bg-[#087179] transition-all duration-500"})})]}),e.jsx("div",{className:"flex-1 flex items-center justify-center px-6 py-12 overflow-y-auto",children:e.jsxs("div",{className:"w-full max-w-2xl",children:[e.jsxs("div",{className:"text-center mb-12",children:[e.jsx("div",{className:"w-20 h-20 bg-white rounded-[32px] flex items-center justify-center mx-auto mb-8 shadow-xl shadow-black/5 border border-[#F1F5F9]",children:e.jsx(W,{className:"w-10 h-10 text-[#087179]",strokeWidth:2})}),e.jsx("h1",{className:"text-[44px] font-serif font-medium text-[#051B30] leading-tight tracking-tight mb-4",children:"Clinical Context"}),e.jsx("p",{className:"text-[18px] text-[#475569] font-medium leading-relaxed max-w-md mx-auto",children:"Upload any existing medical documents to help Genie understand your child's journey so far."})]}),e.jsxs("div",{className:"space-y-8",children:[e.jsxs("div",{onDragOver:u,onDragLeave:f,onDrop:p,className:"relative",children:[e.jsx("input",{type:"file",multiple:!0,accept:".pdf,image/*",onChange:g,className:"absolute inset-0 w-full h-full opacity-0 cursor-pointer z-10"}),e.jsxs("div",{className:`border-3 border-dashed rounded-[40px] p-16 text-center transition-all duration-300 ${s?"border-[#087179] bg-[#F0FDFA] scale-[1.02]":"border-[#CBD5E1] bg-white"}`,children:[e.jsx("div",{className:`w-20 h-20 rounded-[24px] flex items-center justify-center mx-auto mb-6 transition-all duration-300 ${s?"bg-[#087179] text-white":"bg-[#F1F5F9] text-[#94A3B8]"}
1`,children:e.jsx(W,{className:"w-10 h-10",strokeWidth:2})}),e.jsx("h3",{className:"text-[20px] font-bold text-[#051B30] mb-2",children:s?"Drop files here":"Drop files or click to browse"}),e.jsx("p",{className:"text-[15px] text-[#64748B] font-medium",children:"PDF, JPG, PNG up to 10MB each"})]})]}),l.length>0&&e.jsxs(k.div,{initial:{opacity:0,y:10},animate:{opacity:1,y:0},className:"space-y-3",children:[e.jsxs("h3",{className:"text-[12px] font-black text-[#94A3B8] uppercase tracking-widest ml-1",children:["Uploaded files (",l.length,")"]}),l.map((t,r)=>{const v=x(t.type);return e.jsxs("div",{className:"flex items-center gap-4 p-5 rounded-[24px] bg-white border border-[#F1F5F9] shadow-sm",children:[e.jsx("div",{className:"w-12 h-12 rounded-xl bg-[#F0FDFA] border border-teal-50 flex items-center justify-center shrink-0",children:e.jsx(v,{className:"w-6 h-6 text-[#087179]",strokeWidth:2})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("p",{className:"text-[15px] font-bold text-[#051B30] truncate",children:t.name}),e.jsx("p",{className:"text-[13px] text-[#64748B] font-medium",children:w(t.size)})]}),e.jsx("button",{onClick:()=>j(r),className:"w-10 h-10 rounded-full flex items-center justify-center text-[#94A3B8] hover:bg-red-50 hover:text-red-500 transition-all",children:e.jsx(L,{className:"w-5 h-5",strokeWidth:2})})]},r)})]}),e.jsx("div",{className:"p-8 rounded-[32px] bg-[#EBF2F8] border-2 border-blue-50",children:e.jsxs("p",{className:"text-[15px] text-[#4A5F8B] font-medium leading-relaxed",children:[e.jsx("span",{className:"font-bold text-[#0B3A66] uppercase tracking-wider block mb-2 text-[12px]",children:"Helpful documents:"}),"Genetic test results, MRI reports, specialist summaries, or developmental assessments. You can always add more later."]})}),e.jsxs("div",{className:"flex flex-col gap-4",children:[e.jsxs("button",{onClick:y,className:"w-full h-[72px] bg-[#FF6B47] text-white rounded-full text-[20px] font-bold shadow-2xl shadow-[#FF6B47]/30 hover:bg-[#E55A38] hover:-translate-y-1 transition-all active:scale-[0.98] flex items-center justify-center gap-3",children:[e.jsx("span",{children:l.length>0?`Continue with ${l.length} ${l.length===1?"file":"files"}`:"Continue"}),e.jsx(A,{className:"w-6 h-6",strokeWidth:2.5})]}),e.jsx("button",{onClick:d,className:"w-full h-[64px] rounded-full border-2 border-[#F1F5F9] text-[16px] font-bold text-[#64748B] hover:bg-white transition-all",children:"Skip for now"})]})]})]})})]})}function xe({onComplete:o,onBack:d}){const[i,a]=c.useState("account"),[s,n]=c.useState({}),l=7,m={account:1,who:2,concern:3,symptoms:4,timeline:5,doctor:6,documents:7},u=h=>{n(b=>({...b,...h})),a("who")},f=h=>{n(b=>({...b,recipient:h})),a("concern")},p=()=>{a("account")},g=h=>{n(b=>({...b,...h})),a("symptoms")},N=()=>{a("who")},j=h=>{n(b=>({...b,...h})),a("timeline")},w=()=>{a("concern")},x=h=>{n(b=>({...b,...h})),a("doctor")},y=()=>{a("symptoms")},t=h=>{n(b=>({...b,...h})),a("documents")},r=()=>{n(h=>({...h,hasPrimaryDoctor:!1})),a("documents")},v=()=>{a("timeline")},F=h=>{const b={...s,...h};o(b)},D=()=>{const h={...s,hasDocuments:!1};o(h)},E=()=>{a("doctor")},C={current:m[i],total:l};switch(i){case"account":return e.jsx(Q,{onComplete:u,onBack:d});case"who":return e.jsx(K,{onSelect:f,onBack:p,progress:C});case"concern":return e.jsx(Z,{onComplete:g,onBack:N,progress:C,initialData:s});case"symptoms":return e.jsx(te,{onComplete:j,onBack:w,progress:C,initialData:s});case"timeline":return e.jsx(se,{onComplete:x,onBack:y,progress:C,initialData:s});case"doctor":return e.jsx(ae,{onComplete:t,onSkip:r,onBack:v,progress:C,initialData:s});case"documents":return e.jsx(le,{onComplete:F,onSkip:D,onBack:E,progress:C});default:return null}}export{xe as NewUndiagnosedJourney};

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.