import{e as F,f as E,h as N,c as a,i as t,a as e,t as o,k as n,F as y,E as _,b as c,w as j,v as b,l as C,r as L,g as P,o as s}from"./-dIGDsTg.js";import{q as B}from"./eG5ISeQw.js";const D={key:0,class:"grid min-h-[calc(100vh_-_119px)] place-items-center bg-black px-6 py-16 text-center text-white"},T={class:"grid justify-items-center gap-[22px]"},V={class:"m-0 max-w-[900px] text-[clamp(2.25rem,5.4vw,4.75rem)] font-black leading-none tracking-normal"},A={class:"m-0 max-w-[680px] text-[clamp(1.05rem,2vw,1.35rem)] font-semibold leading-normal tracking-normal text-gray-300"},K=["href"],M={key:1,class:"bg-gray-50 px-10 py-[72px] text-gray-900 max-[700px]:px-6 max-[700px]:py-14","aria-labelledby":"services-preview-title"},O={class:"mx-auto grid w-full max-w-[1120px] auto-cols-[minmax(280px,520px)] grid-flow-col gap-5 overflow-x-auto overscroll-x-contain scroll-px-1 snap-x snap-mandatory pb-4 max-[700px]:auto-cols-[minmax(260px,86vw)]","aria-label":"Service cards"},$=["src","alt"],z={class:"grid gap-3 p-6"},H={class:"m-0 text-[1.35rem] font-black leading-[1.15] tracking-normal"},I={class:"m-0 text-base leading-relaxed text-gray-600"},J={key:2,class:"bg-white px-10 py-[72px] text-gray-900 max-[700px]:px-6 max-[700px]:py-14"},R={class:"mx-auto grid w-full max-w-[920px] gap-12"},Y={class:"m-0 text-[clamp(1.75rem,3vw,2.75rem)] font-black leading-[1.05] tracking-normal"},G={class:"m-0 text-[1.05rem] leading-[1.8] text-gray-700"},Q={key:0,class:"m-0 grid gap-2 pl-5 text-[1.05rem] leading-[1.7] text-gray-700"},U={key:3,class:"bg-black px-10 py-[72px] text-white max-[700px]:px-6 max-[700px]:py-14","aria-labelledby":"lead-form-title"},W={class:"mx-auto grid w-full max-w-[920px] gap-8"},X={class:"grid gap-4"},Z={id:"lead-form-title",class:"m-0 text-[clamp(1.85rem,3vw,3rem)] font-black leading-[1.05] tracking-normal"},ee={class:"m-0 max-w-[680px] text-[1.05rem] leading-[1.8] text-gray-300"},te={class:"grid gap-5 md:grid-cols-2"},ae={key:0,class:"m-0 text-sm font-semibold text-gray-300"},se={key:1,class:"m-0 text-sm font-semibold text-red-300"},ne=F({__name:"index",async setup(re){let x,w;const g=(l,p)=>{if(!l)return p;if(typeof l!="string")return l;try{return JSON.parse(l)}catch{return p}},{data:d}=([x,w]=E(()=>P("home-page",()=>B("content").path("/").first())),x=await x,w(),x);if(!d.value)throw N({statusCode:404,statusMessage:"Page not found",fatal:!0});const m=b(()=>g(d.value?.hero,null)),v=b(()=>g(d.value?.cards,[])),k=b(()=>g(d.value?.sections,[])),h=b(()=>g(d.value?.leadForm,null)),f=C(!1),u=C(""),S=async l=>{f.value=!1,u.value="";try{await $fetch("https://api.hoosierconcreteleveling.com/contact",{method:"POST",body:{...l}}),f.value=!0}catch{u.value="Sorry, your quote request could not be sent. Please call (463) 444-7933."}};return(l,p)=>{const i=L("FormKit");return s(),a("div",null,[t(m)?(s(),a("section",D,[e("div",T,[e("h1",V,o(t(m).title),1),e("p",A,o(t(m).subtitle),1),e("a",{class:"inline-flex min-h-[52px] items-center justify-center border border-white bg-white px-7 text-base font-black leading-none text-black no-underline hover:border-gray-200 hover:bg-gray-200",href:t(m).cta.href},o(t(m).cta.label),9,K)])])):n("",!0),t(v).length?(s(),a("section",M,[p[0]||(p[0]=e("div",{class:"mx-auto mb-7 w-full max-w-[1120px]"},[e("h2",{id:"services-preview-title",class:"m-0 text-[clamp(1.75rem,3vw,2.75rem)] font-black leading-[1.05] tracking-normal"}," Concrete Leveling Services ")],-1)),e("div",O,[(s(!0),a(y,null,_(t(v),r=>(s(),a("article",{key:r.title,class:"snap-start overflow-hidden rounded-lg border border-gray-200 bg-white"},[e("img",{class:"block aspect-[3/2] w-full bg-gray-300 object-cover",src:r.image,alt:`${r.title} placeholder photo`,loading:"lazy"},null,8,$),e("div",z,[e("h3",H,o(r.title),1),e("p",I,o(r.text),1)])]))),128))])])):n("",!0),t(k).length?(s(),a("section",J,[e("div",R,[(s(!0),a(y,null,_(t(k),r=>(s(),a("article",{key:r.title,class:"grid gap-4 border-t border-gray-200 pt-10 first:border-t-0 first:pt-0"},[e("h2",Y,o(r.title),1),e("p",G,o(r.text),1),r.items?.length?(s(),a("ul",Q,[(s(!0),a(y,null,_(r.items,q=>(s(),a("li",{key:q,class:"list-disc"},o(q),1))),128))])):n("",!0)]))),128))])])):n("",!0),t(h)?(s(),a("section",U,[e("div",W,[e("div",X,[e("h2",Z,o(t(h).title),1),e("p",ee,o(t(h).text),1)]),c(i,{type:"form",actions:!1,"form-class":"grid gap-5",onSubmit:S},{default:j(()=>[c(i,{type:"textarea",name:"issue",label:"Describe your issue",validation:"required",rows:"6","outer-class":"grid gap-2","label-class":"text-sm font-bold uppercase tracking-normal text-gray-200","input-class":"min-h-[160px] w-full rounded-lg border border-gray-700 !bg-white px-4 py-3 text-base leading-relaxed !text-gray-950 outline-none focus:border-white focus:ring-2 focus:ring-white/30","message-class":"text-sm font-semibold text-red-300"}),e("div",te,[c(i,{type:"text",name:"name",label:"Name",validation:"required","outer-class":"grid gap-2","label-class":"text-sm font-bold uppercase tracking-normal text-gray-200","input-class":"min-h-[52px] w-full rounded-lg border border-gray-700 !bg-white px-4 text-base !text-gray-950 outline-none focus:border-white focus:ring-2 focus:ring-white/30","message-class":"text-sm font-semibold text-red-300"}),c(i,{type:"text",name:"contactInfo",label:"Phone number or email",validation:"required","outer-class":"grid gap-2","label-class":"text-sm font-bold uppercase tracking-normal text-gray-200","input-class":"min-h-[52px] w-full rounded-lg border border-gray-700 !bg-white px-4 text-base !text-gray-950 outline-none focus:border-white focus:ring-2 focus:ring-white/30","message-class":"text-sm font-semibold text-red-300"})]),c(i,{type:"radio",name:"contactMethod",label:"How would you like to be contacted?",validation:"required",options:[{label:"Call",value:"call"},{label:"Text",value:"text"},{label:"Email",value:"email"}],"outer-class":"grid gap-3","fieldset-class":"m-0 border-0 p-0","legend-class":"mb-3 text-sm font-bold uppercase tracking-normal text-gray-200","options-class":"grid gap-3 sm:grid-cols-3","option-class":"m-0","wrapper-class":"flex min-h-[52px] cursor-pointer items-center gap-3 rounded-lg border border-gray-700 !bg-white px-4 !text-gray-950","label-class":"text-base font-bold","message-class":"text-sm font-semibold text-red-300"}),c(i,{type:"submit",label:"Request quote","outer-class":"mt-1","input-class":"inline-flex min-h-[54px] cursor-pointer items-center justify-center rounded-lg border border-white bg-white px-7 text-base font-black leading-none text-black hover:border-gray-200 hover:bg-gray-200"})]),_:1}),t(f)?(s(),a("p",ae," Thanks. Your quote request has been sent. ")):n("",!0),t(u)?(s(),a("p",se,o(t(u)),1)):n("",!0)])])):n("",!0)])}}});export{ne as default};