1import{a as m,x as p,y,z as w,w as C}from"./chunk-EF7DTUVF-BYAtb9KD.js";import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{P as k}from"./PageLayout-ltf-EhZD.js";import{P as S}from"./PageHeader-BSl7YiED.js";import{C as A}from"./circle-check-big-CCeYvgdL.js";import{a as _,C as z}from"./chevron-right-BGUhdJ7u.js";import{T}from"./TechnologyInCaregiving-D0HyJ346.js";function F(){const[n,t]=m.useState(1),[r,u]=m.useState({whoNeedsCare:"",primaryConcerns:[],careTiming:"",zipCode:"",fullName:"",phoneNumber:"",emailAddress:"",additionalNotes:""}),s=p(),h=y().state==="submitting",x=(s==null?void 0:s.success)===!0,l=(a,o)=>{u(d=>({...d,[a]:o}))},v=(a,o,d)=>{u(c=>({...c,[a]:d?[...c[a],o]:c[a].filter(j=>j!==o)}))},i=a=>{switch(a){case 1:return r.whoNeedsCare!==""&&r.primaryConcerns.length>0&&r.careTiming!=="";case 2:return r.zipCode!==""&&r.fullName!==""&&r.phoneNumber!==""&&r.emailAddress!=="";default:return!1}},g=()=>{i(n)&&t(a=>a+1)},f=()=>{t(a=>a-1)},b=a=>{if(!i(2)){a.preventDefault();return}},N=()=>r.fullName.split(" ")[0]||"there";if(x){if(typeof window<"u"&&window.Intercom)try{window.Intercom("update",{email:r.emailAddress,name:r.fullName,phone:r.phoneNumber,custom_attributes:{who_needs_care:r.whoNeedsCare,primary_concerns:r.primaryConcerns.join(", "),care_timing:r.careTiming,zip_code:r.zipCode,form_type:"care_request"}})}catch(a){console.error("Failed to update Intercom:",a)}return e.jsxs("div",{className:"bg-white rounded-2xl p-8 shadow-lg max-w-2xl mx-auto text-center border border-haven-lavender/20",children:[e.jsx("div",{className:"w-16 h-16 bg-haven-lavender/20 rounded-full flex items-center justify-center mx-auto mb-6",children:e.jsx(A,{className:"w-8 h-8 text-haven-plum"})}),e.jsxs("h2",{className:"font-serif text-3xl font-bold text-haven-plum mb-4",children:["Thanks, ",N(),"!"]}),e.jsx("div",{className:"space-y-4 text-lg font-alexandria font-light",children:e.jsxs("p",{children:["Our Care Team is reviewing your needs now. You'll get a call from us within",e.jsx("strong",{className:"text-haven-plum",children:" 3 business hours"}),"."]})})]})}return e.jsxs(w,{method:"post",onSubmit:b,className:"bg-white rounded-2xl p-8 shadow-lg max-w-2xl mx-auto border border-haven-lavender/20",children:[e.jsxs("div",{className:"mb-8",children:[e.jsxs("div",{className:"flex items-center justify-between mb-4",children:[e.jsxs("span",{className:"text-sm font-medium text-haven-plum/70 font-alexandria font-light",children:["Step ",n," of 2"]}),e.jsxs("span",{className:"text-sm font-medium text-haven-plum font-alexandria font-light bg-haven-lavender/20 px-3 py-1 rounded-full",children:[n===1&&"Care Needs",n===2&&"Contact Info"]})]}),e.jsx("div",{className:"w-full bg-haven-lavender/30 rounded-full h-3",children:e.jsx("div",{className:"bg-gradient-to-r from-haven-plum to-haven-lavender h-3 rounded-full transition-all duration-500 ease-in-out shadow-sm",style:{width:`${n/2*100}%`}})})]}),n===1&&e.jsxs("div",{className:"space-y-6 transition-all duration-300 ease-in-out",children:[e.jsx("div",{children:e.jsx("h2",{className:"font-serif text-2xl font-bold text-haven-plum mb-6",children:"Tell us about your care needs"})}),e.jsxs("div",{children:[e.jsx("label",{className:"text-lg font-medium mb-3 block text-haven-plum",children:"Who needs care? *"}),e.jsxs("select",{value:r.whoNeedsCare,onChange:a=>l("whoNeedsCare",a.target.value),className:"w-full text-lg py-3 px-4 border border-haven-lavender/40 rounded-md focus:border-haven-plum focus:ring-1 focus:ring-haven-plum/20",children:[e.jsx("option",{value:"",children:"Select who needs care"}),e.jsx("option",{value:"myself",children:"Myself"}),e.jsx("option",{value:"parent",children:"Parent"}),e.jsx("option",{value:"spouse",children:"Spouse"}),e.jsx("option",{value:"other",children:"Other"})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"text-lg font-medium mb-3 block text-haven-plum",children:"Primary concern? * (Select all that apply)"}),e.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3",children:["Memory Care","Mobility Help","Companionship","Respite Care","Other"].map(a=>e.jsxs("label",{className:"flex items-center space-x-3 p-3 border border-haven-lavender/40 rounded-lg hover:bg-haven-lavender/10 hover:border-haven-plum/
150 transition-colors cursor-pointer",children:[e.jsx("input",{type:"checkbox",checked:r.primaryConcerns.includes(a),onChange:o=>v("primaryConcerns",a,o.target.checked),className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 rounded focus:ring-blue-500 focus:ring-2"}),e.jsx("span",{className:"text-base font-alexandria font-light cursor-pointer",children:a})]},a))})]}),e.jsxs("div",{children:[e.jsx("label",{className:"text-lg font-medium mb-3 block text-haven-plum",children:"How soon do you need care? *"}),e.jsxs("select",{value:r.careTiming,onChange:a=>l("careTiming",a.target.value),className:"w-full text-lg py-3 px-4 border border-haven-lavender/40 rounded-md focus:border-haven-plum focus:ring-1 focus:ring-haven-plum/20",children:[e.jsx("option",{value:"",children:"Select timing"}),e.jsx("option",{value:"asap",children:"ASAP"}),e.jsx("option",{value:"1-2-weeks",children:"Within 1â2 Weeks"}),e.jsx("option",{value:"exploring",children:"Just Exploring"})]})]})]}),n===2&&e.jsxs("div",{className:"space-y-6 transition-all duration-300 ease-in-out",children:[e.jsx("div",{children:e.jsx("h2",{className:"font-serif text-2xl font-bold text-haven-plum mb-6",children:"Contact information"})}),e.jsxs("div",{children:[e.jsx("label",{htmlFor:"zipCode",className:"text-lg font-medium mb-3 block text-haven-plum",children:"Zip Code *"}),e.jsx("input",{id:"zipCode",type:"text",placeholder:"Enter your zip code",value:r.zipCode,onChange:a=>l("zipCode",a.target.value),className:"w-full text-lg py-3 px-4 border border-haven-lavender/40 rounded-md focus:border-haven-plum focus:ring-1 focus:ring-haven-plum/20",maxLength:5})]}),e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-6",children:[e.jsxs("div",{className:"sm:col-span-2",children:[e.jsx("label",{htmlFor:"fullName",className:"text-lg font-medium mb-3 block text-haven-plum",children:"Full Name *"}),e.jsx("input",{id:"fullName",type:"text",placeholder:"Enter your full name",value:r.fullName,onChange:a=>l("fullName",a.target.value),className:"w-full text-lg py-3 px-4 border border-haven-lavender/40 rounded-md focus:border-haven-plum focus:ring-1 focus:ring-haven-plum/20"})]}),e.jsxs("div",{children:[e.jsx("label",{htmlFor:"phoneNumber",className:"text-lg font-medium mb-3 block text-haven-plum",children:"Phone Number *"}),e.jsx("input",{id:"phoneNumber",type:"tel",placeholder:"(555) 123-4567",value:r.phoneNumber,onChange:a=>l("phoneNumber",a.target.value),className:"w-full text-lg py-3 px-4 border border-haven-lavender/40 rounded-md focus:border-haven-plum focus:ring-1 focus:ring-haven-plum/20"})]}),e.jsxs("div",{children:[e.jsx("label",{htmlFor:"emailAddress",className:"text-lg font-medium mb-3 block text-haven-plum",children:"Email Address *"}),e.jsx("input",{id:"emailAddress",type:"email",placeholder:"[email protected]",value:r.emailAddress,onChange:a=>l("emailAddress",a.target.value),className:"w-full text-lg py-3 px-4 border border-haven-lavender/40 rounded-md focus:border-haven-plum focus:ring-1 focus:ring-haven-plum/20"})]})]}),e.jsxs("div",{children:[e.jsx("label",{htmlFor:"additionalNotes",className:"text-lg font-medium mb-3 block text-haven-plum",children:"Anything else we should know? (Optional)"}),e.jsx("textarea",{id:"additionalNotes",placeholder:"Tell us about specific needs, preferences, or concerns...",value:r.additionalNotes,onChange:a=>l("additionalNotes",a.target.value),className:"w-full text-base min-h-[100px] p-3 border border-haven-lavender/40 rounded-md focus:border-haven-plum focus:ring-1 focus:ring-haven-plum/20 resize-none",rows:4})]})]}),e.jsx("input",{type:"hidden",name:"whoNeedsCare",value:r.whoNeedsCare}),e.jsx("input",{type:"hidden",name:"primaryConcerns",value:JSON.stringify(r.primaryConcerns)}),e.jsx("input",{type:"hidden",name:"careTiming",value:r.careTiming}),e.jsx("input",{type:"hidden",name:"zipCode",value:r.zipCode}),e.jsx("input",{type:"hidden",name:"fullName",value:r.fullName}),e.jsx("input",{type:"hidden",name:"phoneNumber",value:r.phoneNumber}),e.jsx("input",{type:"hidden",name:"emailAddress",value:r.emailAddress}),e.jsx("input",{type:"hidden",name:"additionalNotes",value:r.additionalNotes}),(s==null?void 0:s.error)&&e.jsx("div",{className:"mt-6 p-4 bg-red-50 border border-red-200 rounded-lg",children:e.jsx("p",{className:"text-red-700 text-sm font-medium",children:s.error})}),e.jsxs("div",{className:"flex justify-between items-center mt-8 pt-6 border-t border-haven-lavender/30",children:[n>
11?e.jsxs("button",{type:"button",onClick:f,className:"border border-haven-lavender/40 text-haven-plum hover:bg-haven-lavender/10 flex items-center gap-2 px-6 py-3 text-lg rounded-md cursor-pointer",children:[e.jsx(_,{className:"w-5 h-5"}),"Previous"]}):e.jsx("div",{}),n<2?e.jsxs("button",{type:"button",onClick:g,disabled:!i(n),className:"bg-haven-plum hover:bg-haven-lavender text-white flex items-center gap-2 px-6 py-3 text-lg disabled:opacity-50 rounded-md cursor-pointer",children:["Next",e.jsx(z,{className:"w-5 h-5"})]}):e.jsx("button",{type:"submit",disabled:!i(2)||h,className:"bg-haven-plum hover:bg-haven-lavender text-white flex items-center gap-2 px-8 py-3 text-lg disabled:opacity-50 shadow-lg rounded-md cursor-pointer",children:h?"Submitting...":"Submit Request"})]})]})}function D({}){return[{title:"Get Care - Request In-Home Care Services"},{name:"description",content:"Start your care request with Havencare. Reliable, high-quality in-home care for your loved ones in the Bay Area. Simple intake process, trusted caregivers."}]}const L=C(function(){const t=p();return m.useEffect(()=>{if(t!=null&&t.success&&t.userData&&typeof window<"u"&&window.Intercom)try{const r=t.userData;window.Intercom("update",{email:r.email,name:r.name,phone:r.phone,custom_attributes:{who_needs_care:r.whoNeedsCare,primary_concerns:Array.isArray(r.primaryConcerns)?r.primaryConcerns.join(", "):r.primaryConcerns,care_timing:r.careTiming,zip_code:r.zipCode,form_type:"care_request"}})}catch(r){console.error("Failed to update Intercom:",r)}},[t]),e.jsxs(k,{children:[e.jsxs(S,{title:"Need quality",highlight:"care?",children:[e.jsx("span",{className:"inline-block bg-haven-lavender/20 text-haven-plum text-sm font-medium py-1 px-3 rounded-full mt-4 mb-3",children:"Private Beta"}),e.jsx("p",{className:"text-xl mt-4 align-left font-alexandria font-light",children:"Reliable and high-quality in-home care for your loved ones is just a click away. Our tech-driven concierge service connects you with experienced case managers, while our caregiver-first approach ensures compassionate and consistent care. Sign up for our private beta to experience the future of in-home care."})]}),e.jsx("section",{className:"pb-16",id:"intake-form",children:e.jsx("div",{className:"container-custom",children:e.jsx(F,{})})}),e.jsx(T,{})]})});export{L as default,D as meta};
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.