import{j as e}from"./ui-vendor-BxIDIFnU.js";import{r as s,L as a}from"./react-vendor-0XwOhuTY.js";import{t,H as i,a as r,h as l,i as n,j as d,k as c,l as o,m,b as x,c as h,d as u,e as j,f as v,L as f,I as g,B as p,D as N,M as b,n as y,A as C,o as M,p as k,q as w,F as S,r as A}from"./index-CK9GMtDj.js";import{S as I}from"./slider-AQe2EKXK.js";import"./chart-vendor-H_zCtd_i.js";const $=()=>{const[$,F]=s.useState(1e3),[L,E]=s.useState(15),[B,O]=s.useState(50),[R,Y]=s.useState(5e3),[_,D]=s.useState(70),[H,P]=s.useState(2e3),[T,z]=s.useState(5e4),[V,q]=s.useState("expected"),G=s.useMemo(()=>{const e=$*L/60*B*12,s=R*(_/100)*12,a=(e+s)*("conservative"===V?.7:"expected"===V?1:1.3),t=T+12*H,i=(a-t)/t*100,r=a-t,l=T/Math.max((a-12*H)/12,1);return{paybackMonths:Math.max(l,0),netBenefit:r,roi:i,benefits:a,costs:t,laborSavings:e,errorSavings:s}},[$,L,B,R,_,H,T,V]);s.useEffect(()=>{$>0&&L>0&&t({scenario:"agentic",roi_pct:Math.round(100*G.roi)/100,payback_months:Math.round(10*G.paybackMonths)/10,npv_3yr:Math.round(G.netBenefit)})},[G.roi,G.paybackMonths,G.netBenefit,$,L]);return e.jsxs("div",{className:"min-h-screen bg-background",children:[e.jsxs(i,{children:[e.jsx("title",{children:"Agentic AI Automation ROI Calculator | Allerin"}),e.jsx("meta",{name:"description",content:"Calculate Year-1 ROI and payback for agentic AI automation projects. Estimate labor savings and error reduction."})]}),e.jsx(r,{}),e.jsx("main",{className:"py-8 md:py-12",children:e.jsxs("div",{className:"container max-w-6xl",children:[e.jsx(l,{className:"mb-6",children:e.jsxs(n,{children:[e.jsx(d,{children:e.jsx(c,{asChild:!0,children:e.jsx(a,{to:"/",children:"Home"})})}),e.jsx(o,{}),e.jsx(d,{children:e.jsx(c,{asChild:!0,children:e.jsx(a,{to:"/roi-calculator",children:"ROI Calculator"})})}),e.jsx(o,{}),e.jsx(m,{children:"Agentic AI"})]})}),e.jsxs("div",{className:"mb-8",children:[e.jsx("h1",{className:"text-3xl md:text-4xl font-bold mb-2",children:"Agentic AI Automation ROI Estimate"}),e.jsx("p",{className:"text-muted-foreground",children:"Calculate labor savings and error reduction from automated workflows."})]}),e.jsxs("div",{className:"grid lg:grid-cols-2 gap-8",children:[e.jsxs(x,{children:[e.jsxs(h,{children:[e.jsx(u,{children:"Your Inputs"}),e.jsx(j,{children:"Adjust values to match your environment"})]}),e.jsxs(v,{className:"space-y-6",children:[e.jsxs("div",{className:"space-y-2",children:[e.jsx(f,{htmlFor:"tasks",children:"Tasks per month"}),e.jsx(g,{id:"tasks",type:"number",value:$,onChange:e=>F(Number(e.target.value))})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx(f,{htmlFor:"minutes",children:"Minutes saved per task"}),e.jsx(g,{id:"minutes",type:"number",value:L,onChange:e=>E(Number(e.target.value))})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx(f,{htmlFor:"hourly",children:"Hourly rate ($)"}),e.jsx(g,{id:"hourly",type:"number",value:B,onChange:e=>O(Number(e.target.value))})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx(f,{htmlFor:"error",children:"Baseline error cost per month ($)"}),e.jsx(g,{id:"error",type:"number",value:R,onChange:e=>Y(Number(e.target.value))})]}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs(f,{htmlFor:"reduction",children:["Error reduction (%): ",_]}),e.jsx(I,{id:"reduction",min:0,max:100,step:5,value:[_],onValueChange:e=>D(e[0])})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx(f,{htmlFor:"monthly",children:"Monthly platform cost ($)"}),e.jsx(g,{id:"monthly",type:"number",value:H,onChange:e=>P(Number(e.target.value))})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx(f,{htmlFor:"build",children:"One-time build cost ($)"}),e.jsx(g,{id:"build",type:"number",value:T,onChange:e=>z(Number(e.target.value))})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx(f,{children:"Confidence level"}),e.jsx("div",{className:"flex gap-2",children:[{value:"conservative",label:"Conservative (0.7×)"},{value:"expected",label:"Expected (1.0×)"},{value:"aggressive",label:"Aggressive (1.3×)"}].map(s=>e.jsx(p,{variant:V===s.value?"default":"outline",size:"sm",onClick:()=>q(s.value),className:"flex-1",children:s.label.split(" ")[0]},s.value))}),e.jsx("p",{className:"text-xs text-muted-foreground",children:"Conservative = 0.7×, Expected = 1.0×, Aggressive = 1.3× applied to benefits only."})]})]})]}),e.jsxs("div",{className:"space-y-6",children:[e.jsxs(x,{children:[e.jsx(h,{children:e.jsx(u,{children:"Year-1 Results"})}),e.jsxs(v,{className:"space-y-6",role:"region","aria-live":"polite",children:[e.jsxs("div",{className:"grid grid-cols-3 gap-4",children:[e.jsxs("div",{children:[e.jsx("div",{className:"text-sm text-muted-foreground mb-1",children:"Payback"}),e.jsxs("div",{className:"text-2xl font-bold",children:[G.paybackMonths.toFixed(1)," mo"]})]}),e.jsxs("div",{children:[e.jsx("div",{className:"text-sm text-muted-foreground mb-1",children:"Net Benefit"}),e.jsxs("div",{className:"text-2xl font-bold",children:["$",Math.round(G.netBenefit).toLocaleString()]})]}),e.jsxs("div",{children:[e.jsx("div",{className:"text-sm text-muted-foreground mb-1",children:"ROI"}),e.jsxs("div",{className:"text-2xl font-bold",children:[G.roi.toFixed(0),"%"]})]})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx("div",{className:"text-sm font-medium",children:"Costs vs Benefits (Year-1)"}),e.jsxs("div",{className:"space-y-1",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("div",{className:"w-20 text-xs text-muted-foreground",children:"Costs"}),e.jsxs("div",{className:"flex-1 h-8 bg-destructive/20 rounded relative overflow-hidden",children:[e.jsx("div",{className:"h-full bg-destructive transition-all",style:{width:G.costs/Math.max(G.benefits,G.costs)*100+"%"}}),e.jsxs("span",{className:"absolute inset-0 flex items-center px-2 text-xs font-medium",children:["$",Math.round(G.costs).toLocaleString()]})]})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("div",{className:"w-20 text-xs text-muted-foreground",children:"Benefits"}),e.jsxs("div",{className:"flex-1 h-8 bg-primary/20 rounded relative overflow-hidden",children:[e.jsx("div",{className:"h-full bg-primary transition-all",style:{width:G.benefits/Math.max(G.benefits,G.costs)*100+"%"}}),e.jsxs("span",{className:"absolute inset-0 flex items-center px-2 text-xs font-medium",children:["$",Math.round(G.benefits).toLocaleString()]})]})]})]})]})]})]}),e.jsxs(x,{children:[e.jsx(h,{children:e.jsx(u,{children:"Actions"})}),e.jsxs(v,{className:"flex flex-col gap-3",children:[e.jsxs(p,{onClick:()=>{alert("PDF download would trigger here with assumptions + results")},className:"w-full justify-start",children:[e.jsx(N,{className:"mr-2 h-4 w-4"}),"Download PDF"]}),e.jsxs(p,{onClick:()=>{alert("Email form would open here")},variant:"outline",className:"w-full justify-start",children:[e.jsx(b,{className:"mr-2 h-4 w-4"}),"Email me this"]}),e.jsxs(p,{onClick:()=>{A({scenario:"agentic",roi_pct:Math.round(100*G.roi)/100,payback_months:Math.round(10*G.paybackMonths)/10}),window.location.href="mailto:[email protected]?subject=ROI Consult: Agentic AI Automation"},variant:"outline",className:"w-full justify-start",children:[e.jsx(y,{className:"mr-2 h-4 w-4"}),"Book 30-min consult"]})]})]}),e.jsx(C,{type:"single",collapsible:!0,children:e.jsxs(M,{value:"assumptions",children:[e.jsx(k,{children:"View all assumptions"}),e.jsx(w,{className:"space-y-2 text-sm",children:e.jsxs("div",{className:"grid grid-cols-2 gap-2",children:[e.jsx("div",{className:"text-muted-foreground",children:"Tasks/month:"}),e.jsx("div",{className:"font-medium",children:$.toLocaleString()}),e.jsx("div",{className:"text-muted-foreground",children:"Min saved/task:"}),e.jsx("div",{className:"font-medium",children:L}),e.jsx("div",{className:"text-muted-foreground",children:"Hourly rate:"}),e.jsxs("div",{className:"font-medium",children:["$",B]}),e.jsx("div",{className:"text-muted-foreground",children:"Labor savings (Y1):"}),e.jsxs("div",{className:"font-medium",children:["$",Math.round(G.laborSavings).toLocaleString()]}),e.jsx("div",{className:"text-muted-foreground",children:"Error cost/mo:"}),e.jsxs("div",{className:"font-medium",children:["$",R.toLocaleString()]}),e.jsx("div",{className:"text-muted-foreground",children:"Error reduction:"}),e.jsxs("div",{className:"font-medium",children:[_,"%"]}),e.jsx("div",{className:"text-muted-foreground",children:"Error savings (Y1):"}),e.jsxs("div",{className:"font-medium",children:["$",Math.round(G.errorSavings).toLocaleString()]}),e.jsx("div",{className:"text-muted-foreground",children:"Platform/mo:"}),e.jsxs("div",{className:"font-medium",children:["$",H.toLocaleString()]}),e.jsx("div",{className:"text-muted-foreground",children:"One-time build:"}),e.jsxs("div",{className:"font-medium",children:["$",T.toLocaleString()]}),e.jsx("div",{className:"text-muted-foreground",children:"Confidence:"}),e.jsx("div",{className:"font-medium capitalize",children:V})]})})]})}),e.jsx("p",{className:"text-xs text-muted-foreground text-center",children:"This is an estimate based on provided inputs and industry heuristics. It is not financial advice."})]})]})]})}),e.jsx(S,{})]})};export{$ as default};