1import{j as e}from"./index-Cmvmqj4M.js";import{a as j,h as z}from"./public-shared-DfSwM8xn.js";import{y as C,z as F}from"./LandingTrustStrip-DqVgJgex.js";import{b as f}from"./LandingLoading-ChieYznj.js";import{s as h}from"./stripHtml-D7hEuU4R.js";import{c as k,e as B}from"./addVenueToQuote-DKN8eLZ6.js";import{a as P}from"./VenueQuotePicker-gcQwrb60.js";import"./vendor-heavy-DLHqXWkC.js";import"./vendor-charts-CP8BGqTC.js";import"./BespokeVariationsPricing-D7cMOUF-.js";import"./label-BqU3nads.js";import"./index-BCzOIcF0.js";const T=n=>n==="cremation"?["Service at the crematorium","All funeral director services","Traditional coffin & hearse"]:["Grave purchase & preparation","All funeral director services","Traditional coffin & hearse"];function b({kind:n,data:s,page:d,showExampleQuote:v,quoteUrl:i}){const[a,u]=j.useState(!1),[t,o]=j.useState(null),g=async()=>{var l;if(i==="/QuoteYourQuote"){window.location.href=i;return}u(!0);try{let r=null;if(s!=null&&s.venue_service_id&&(r=await f.entities.FuneralService.get(s.venue_service_id).catch(()=>null)),!r&&(s!=null&&s.venue_slug)&&(r=(await f.entities.FuneralService.filter({slug:s.venue_slug}).catch(()=>[])||[])[0]||null),!r&&(s!=null&&s.venue_product_id)&&(r=(await f.entities.FuneralService.filter({product_id:s.venue_product_id}).catch(()=>[])||[])[0]||null),!r){window.location.href=i;return}let x=[],A="";if(r.category!=="cemetery"){const m=r.slug||r.sku;if(m){const p=await z.getVenueBySlug({slug:m});x=((l=p==null?void 0:p.data)==null?void 0:l.fees)||[]}const y=k(x);if(y){await B(r,y);return}window.location.href=i;return}o({venue:r,fees:[],phone:""})}catch{window.location.href=i}finally{u(!1)}};if(!s)return null;const w=s.venue_fee!=null?Number(s.venue_fee):null,N=n==="cremation"?`${s.venue_name||"Crematorium"} fee`:`${s.venue_name||"Cemetery"} fees`,c=n==="cremation"?C(d,N,w):F(d,s.grave_purchase,s.internment),_=c.total,S=T(n);return e.jsxs("div",{className:"lp-card overflow-hidden",children:[s.venue_image_url&&e.jsx("div",{style:{width:"100%",height:180,backgroundImage:`url("${s.venue_image_url}")`,backgroundSize:"cover",backgroundPosition:"center"}}),e.jsxs("div",{style:{padding:24},children:[e.jsx("div",{className:"lp-eyebrow",style:{marginBottom:8},children:n==="cremation"?"Cremation funeral":"Burial funeral"}),s.venue_name&&e.jsx("div",{className:"lp-serif",style:{fontSize:20,marginBottom:6},children:s.venue_name}),e.jsxs("div",{className:"lp-serif",style:{fontSize:30,marginBottom:14},children:[e.jsx("span",{style:{fontSize:20},children:"from"})," ",e.jsx("strong",{style:{fontWeight:600},children:_})]}),e.jsx("ul",{className:"space-y-2 mb-4",children:S.map((l,r)=>e.jsxs("li",{className:"flex items-start gap-2",style:{fontSize:14,color:"var(--lp-body)"},children:[e.jsx("span",{style:{color:"var(--lp-green)"},children:"â"})," ",l]},r))}),v&&e.jsxs("details",{className:"mb-4",children:[e.jsx("summary",{style:{cursor:"pointer",fontSize:13.5,fontWeight:600,color:"var(--lp-green)"},children:"View example quote breakdown"}),e.jsxs("div",{className:"mt-3 space-y-1.5",children:[c.line_items.map((l,r)=>e.jsxs("div",{className:"flex justify-between",style:{fontSize:13.5,color:"var(--lp-body)"},children:[e.jsx("span",{children:l.label}),e.jsx("span",{children:l.amount})]},r)),e.jsxs("div",{className:"flex justify-between pt-2 mt-2",style:{borderTop:"1px solid var(--lp-border)",fontWeight:600,color:"var(--lp-ink)"},children:[e.jsx("span",{children:"Funeral director fees"}),e.jsx("span",{children:c.fd_subtotal})]}),(c.venue_lines||[]).map((l,r)=>e.jsxs("div",{className:"flex justify-between",style:{fontSize:13.5,color:"var(--lp-body)"},children:[e.jsx("span",{children:l.label}),e.jsx("span",{children:l.amount})]},`v${r}`)),e.jsxs("div",{className:"flex justify-between pt-2 mt-2",style:{borderTop:"1px solid var(--lp-border)",fontWeight:700},children:[e.jsx("span",{children:"Total funeral cost"}),e.jsx("span",{children:c.total})]})]})]}),e.jsx("button",{type:"button",className:"lp-cta lp-cta-primary w-full",onClick:g,disabled:a,style:a?{opacity:.7}:void 0,children:a?"Building your quoteâ¦":e.jsxs(e.Fragment,{children:["Personalise ",e.jsx("span",{className:"hidden md:inline",children:"your "}),n," quote"]})}),e.jsx("div",{style:{fontSize:12.5,color:"var(--lp-muted)",marginTop:10,textAlign:"center"},children:"Adjust every detail to suit your family â no obligation"})]}),t&&e.jsx(P,{open:!0,onClose:()=>o(null),venue:t.venue,fees:t.fees,phone:t.phone,quoteBaseUrl:"/quotecemeteryoptions"})]})}function Y({pricing:n,page:s,savings:d,regionalAverage:v,showExampleQuote:i,showPromises:a,copy:u,quoteUrl:t="/Quote"}){if(!(n!=null&&n.cremation)&&!(n!=null&&n.burial))return null;const o=u||{};return e.jsx("section",{id:"pricing",className:"lp-sec",style:{background:"var(--lp-cream-alt)"},children:e.jsxs("div",{className:"lp-wrap",children:[e.jsxs("div",{className:"lp-mw-720 text-center",children:[e.jsx("div",{className:"lp-eyebrow",style:{marginBottom:11},children:h(o.eyebrow)||"Transparent pricing"}),e.jsx("h2",{className:"lp-h2",children:h(o.title)||"Simple, transparent funeral pricing"}),e.jsx("p",{className:"lp-lead",children:h(o.lead)||"Clear, fair prices with a price-match promise and never any deposit â and every quote is y
1ours to personalise, from coffin to flowers to the order of service."})]}),e.jsxs("div",{className:"grid md:grid-cols-2 gap-7 mt-8",children:[e.jsx(b,{kind:"cremation",data:n.cremation,page:s,showExampleQuote:i,quoteUrl:t}),e.jsx(b,{kind:"burial",data:n.burial,page:s,showExampleQuote:i,quoteUrl:t})]}),a&&e.jsx("div",{className:"lp-mw-720 text-center mt-8",children:e.jsxs("div",{className:"flex flex-wrap gap-4 justify-center",style:{fontSize:13,color:"var(--lp-body)"},children:[e.jsx("span",{children:"â No deposit"}),e.jsx("span",{children:"â Price-match promise"}),e.jsx("span",{children:"â 100% transparent"})]})})]})})}export{Y 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.