1import{u as ae,y as ce,z as oe,r as o,j as e,C as h,B as i,E as K,L as v,p as y,b as le,c as ne,M as Y,R as _,e as re,U as ie}from"./index-U8D282DB.js";import{B as de}from"./badge-BmpMbrZ9.js";import{L as pe}from"./LineItemsBreakdown-BTPMYgXp.js";import{f as A}from"./dateUtils-xDUjtiFQ.js";import{a as xe,s as G,g as ue,b as me}from"./vehicle-meta-CSB9CKbt.js";import{C as W}from"./circle-check-BhfzMN_T.js";import{C as H}from"./circle-x-DRl5_Mg7.js";import{C as ge}from"./calendar-Ctb75UO1.js";import{L as he}from"./luggage-CAvD0ihS.js";import"./undo-2-DuItk8Ae.js";const fe={airport_transfer:"Airport Transfer",corporate:"Corporate / Business",event_transport:"Event Transport",wedding:"Wedding / Special Occasion",group_transport:"Group Transport",everyday:"Everyday / Personal",long_distance:"Long Distance",other:"Other"};function Be(){ae("Quote Response");const J=ce(),z=oe(),f=new URLSearchParams(z),d=J.id;f.get("action");const p=f.get("token"),[s,w]=o.useState(null),[X,k]=o.useState(!0),[B,C]=o.useState(null),[m,P]=o.useState(!1),[n,S]=o.useState(null),[x,T]=o.useState(null),[l,R]=o.useState(null),[Q,u]=o.useState(null),[O,$]=o.useState(null),[D,q]=o.useState(null),[I,Z]=o.useState([]);o.useEffect(()=>{const t=f.get("vehicle"),a=f.get("action");if(s?.vehicleOptions&&s.vehicleOptions.length>1){const c=!!(t&&s.vehicleOptions.some(N=>N.vehicleName===t));R(c?t:null)}else t&&a==="accepted"&&s&&s.status==="sent"&&!m&&!n&&!x&&R(t)},[s]),o.useEffect(()=>{if(!d||!p){C("Invalid link. Please use the link from your email."),k(!1);return}fetch(`/api/quotes/${d}/details?token=${p}`).then(async t=>{if(!t.ok){const a=await t.json().catch(()=>({}));throw new Error(a.error||"Failed to load quote")}return t.json()}).then(t=>{w(t),Z(t.linkedBookingIds||[]),(t.status==="accepted"||t.status==="declined"||t.status==="converted")&&T(t.status)}).catch(t=>C(t.message)).finally(()=>k(!1))},[d,p]);const F=async()=>{if(!d||!p)return!1;try{const t=await fetch(`/api/quotes/${d}/details?token=${encodeURIComponent(p)}`);if(!t.ok)return!1;const a=await t.json();return a.status!=="converted"||!a.linkedBookingIds?.length?!1:(w(a),$(a.linkedBookingIds[0]),q(a.linkedBookingIds[1]||null),S("accepted"),!0)}catch{return!1}},V=async t=>{if(!(!p||!d)){if(t==="accepted"&&s?.confirmationReady===!1){const a=s.missingRequiredFields?.join(", ")||"required trip details";u(`This quote cannot be confirmed yet because it is missing: ${a}. Please contact Drive4u so we can complete it.`);return}if(t==="accepted"&&s?.vehicleOptions&&s.vehicleOptions.length>1&&!!!(l&&s.vehicleOptions.some(c=>c.vehicleName===l))){u("Please select one of the vehicle options before confirming your quote.");return}u(null),P(!0);try{const a=await fetch(`/api/quotes/${d}/respond`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({action:t,token:p,selectedVehicle:t==="accepted"?l:void 0})}),c=await a.json();a.ok?(t==="accepted"&&($(c.bookingId||null),q(c.returnBookingId||null),c.selectedVehicle&&R(c.selectedVehicle)),S(t)):c.error==="already_responded"?t==="accepted"&&c.currentStatus==="converted"&&await F()||T(c.currentStatus):u(c.message||"We could not confirm this quote. Please contact Drive4u so we can help.")}catch{t==="accepted"&&await F()||u("We could not confirm this quote just now. Your selected vehicle has been kept; please try again or contact Drive4u.")}finally{P(!1)}}};if(n)return e.jsx(h,{"data-loc":"client/src/pages/QuoteResponse.tsx:197",children:e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:198",className:"min-h-[60vh] flex items-center justify-center px-4",children:e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:199",className:"max-w-md w-full text-center space-y-6",children:[e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:200",className:`mx-auto h-20 w-20 rounded-full flex items-center justify-center ${n==="accepted"?"bg-emerald-100 dark:bg-emerald-900/30":"bg-red-100 dark:bg-red-900/30"}`,children:n==="accepted"?e.jsx(W,{"data-loc":"client/src/pages/QuoteResponse.tsx:204",className:"h-10 w-10 text-emerald-600"}):e.jsx(H,{"data-loc":"client/src/pages/QuoteResponse.tsx:206",className:"h-10 w-10 text-red-600"})}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:209",children:[e.jsx("h1",{"data-loc":"client/src/pages/QuoteResponse.tsx:210",className:"text-2xl font-bold",style:{color:"#1B2A4A"},children:n==="accepted"?"Quote Accepted!":"Quote Declined"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:213",className:"text-muted-foreground mt-2",children:n==="accepted"?`Thank y
1ou! Your ${l?`${l} `:""}booking has been created${O?` as Booking #${O}`:""}.`:"No worries â feel free to request a new quote anytime."})]}),n==="accepted"&&e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:220",className:"rounded-xl p-4 border",style:{backgroundColor:"rgba(27,42,74,0.04)",borderColor:"rgba(27,42,74,0.1)"},children:e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:221",className:"text-sm",style:{color:"#1B2A4A"},children:[e.jsx("strong",{"data-loc":"client/src/pages/QuoteResponse.tsx:222",children:"What happens next?"}),e.jsx("br",{"data-loc":"client/src/pages/QuoteResponse.tsx:222"}),"A confirmation email has been sent with your trip details and selected vehicle. Our team will assign your chauffeur and provide the remaining booking information.",D?e.jsxs(e.Fragment,{children:[e.jsx("br",{"data-loc":"client/src/pages/QuoteResponse.tsx:224"}),e.jsx("br",{"data-loc":"client/src/pages/QuoteResponse.tsx:224"}),e.jsx("strong",{"data-loc":"client/src/pages/QuoteResponse.tsx:224",children:"Return booking:"})," #",D]}):null]})}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:228",className:"flex flex-col sm:flex-row gap-3 justify-center pt-2",children:[e.jsx(i,{"data-loc":"client/src/pages/QuoteResponse.tsx:229",variant:"outline",onClick:()=>window.location.href="/",className:"gap-2",children:"Back to Home"}),n==="declined"&&e.jsx(i,{"data-loc":"client/src/pages/QuoteResponse.tsx:237",onClick:()=>window.location.href="/get-quote",className:"gap-2 font-semibold",style:{backgroundColor:"#C8A951",color:"#1B2A4A"},children:"Get a New Quote"})]})]})})});if(x)return e.jsx(h,{"data-loc":"client/src/pages/QuoteResponse.tsx:255",children:e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:256",className:"min-h-[60vh] flex items-center justify-center px-4",children:e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:257",className:"max-w-md w-full text-center space-y-6",children:[e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:258",className:"mx-auto h-20 w-20 rounded-full flex items-center justify-center bg-blue-100 dark:bg-blue-900/30",children:e.jsx(K,{"data-loc":"client/src/pages/QuoteResponse.tsx:259",className:"h-10 w-10 text-blue-600"})}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:261",children:[e.jsx("h1",{"data-loc":"client/src/pages/QuoteResponse.tsx:262",className:"text-2xl font-bold",style:{color:"#1B2A4A"},children:"Already Responded"}),e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:265",className:"text-muted-foreground mt-2",children:[x==="accepted"&&"You've already accepted this quote. We're preparing your booking.",x==="declined"&&"You've already declined this quote.",x==="converted"&&"Great news! This quote has been converted into a confirmed booking."]}),x==="converted"&&I.length>0&&e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:271",className:"mt-3 text-sm font-semibold",style:{color:"#1B2A4A"},children:["Booking ",I.map(t=>`#${t}`).join(" and ")," has already been created. No further action is needed."]})]}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:276",className:"flex flex-col sm:flex-row gap-3 justify-center pt-2",children:[e.jsx(i,{"data-loc":"client/src/pages/QuoteResponse.tsx:277",variant:"outline",onClick:()=>window.location.href="/",className:"gap-2",children:"Back to Home"}),e.jsx(i,{"data-loc":"client/src/pages/QuoteResponse.tsx:280",onClick:()=>window.location.href="/my-account",className:"gap-2 font-semibold",style:{backgroundColor:"#C8A951",color:"#1B2A4A"},children:"View My Account"}),e.jsx("a",{"data-loc":"client/src/pages/QuoteResponse.tsx:287",href:"tel:+61408886230",className:"text-sm underline self-center",style:{color:"#1B2A4A"},children:"Need help? Call Drive4u"})]})]})})});if(X)return e.jsx(h,{"data-loc":"client/src/pages/QuoteResponse.tsx:298",children:e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:299",className:"min-h-[60vh] flex items-center justify-center",children:e.jsx(v,{"data-loc":"client/src/pages/QuoteResponse.tsx:300",className:"h-8 w-8 animate-spin",style:{color:"#C8A951"}})})});if(B||!s)return e.jsx(h,{"data-loc":"client/src/pages/QuoteResponse.tsx:309",children:e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:310",className:"min-h-[60vh] flex items-center justify-center px-4",children:e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:311",className:"max-w-md w-full text-center space-y-6",children:[e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:312",className:"mx-auto h-20 w-20 rounded-full flex items-center justify-center bg-red-100 dark:bg-red-900/30",children:e.jsx(K,{"data-loc":"client/src/pages/QuoteResponse.tsx:313",className:"h-10 w-10 text-red-600"})}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:315",children:[e.jsx("h1",{"data-loc":"client/src/pages/QuoteResponse.tsx:316",className:"text-2xl font-bold",style:{color:"#1B2A4A"},children:"Unable to Load Quote"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:317",className:"text-muted-foreground mt-2",children:B||"Something went wrong. Please try the link from your email again."}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:318",className:"text-sm text-muted-foreground mt-2",children:"If this keeps happening, call Drive4u with your quote number and we will help you confirm your booking."})]}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:320",className:"flex flex-wrap gap-3 justify-center",children:[e.jsx(i,{"data-loc":"client/src/pages/QuoteResponse.tsx:321",asChild:!0,children:e.jsx("a",{"data-loc":"client/src/pages/QuoteResponse.tsx:321",href:"tel:+61408886230",children:"Call Drive4u"})}),e.jsx(i,{"data-loc":"client/src/pages/QuoteResponse.tsx:322",variant:"outline",onClick:()=>window.location.href="/",children:"Back to Home"})]})]})})});const E=s.estimatedPrice&&parseFloat(s.estimatedPrice)>0?`$${parseFloat(s.estimatedPrice).toFixed(2)}`:null,b=s.scheduledAt?A(Number(s.scheduledAt)):null,ee=s.returnScheduledAt?A(Number(s.returnScheduledAt)):"To be confirmed",L=s.serviceType?fe[s.serviceType]||s.serviceType:null,se=s.customerName?.split(" ")[0]||"there",M=s.vehicleOptions&&s.vehicleOptions.length>1?xe(s.vehicleOptions):[],r=M.find(t=>t.vehicleName===l)||null,g=r?G(r.price,!!s.isReturnTrip,r):null;return e.jsx(h,{"data-loc":"client/src/pages/QuoteResponse.tsx:352",children:e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:353",className:"container py-6 sm:py-10 max-w-2xl mx-auto px-4",children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:355",className:"text-center mb-6 sm:mb-8",children:[e.jsxs(de,{"data-loc":"client/src/pages/QuoteResponse.tsx:356",className:"mb-3 bg-blue-100 text-blue-800 dark:bg-blue-900/30 dark:text-blue-400",children:["Quote #",s.id]}),e.jsxs("h1",{"data-loc":"client/src/pages/QuoteResponse.tsx:359",className:"text-2xl sm:text-3xl font-bold",style:{color:"#1B2A4A"},children:["Hi ",se,", your quote is ready"]}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:362",className:"text-muted-foreground mt-2 text-sm sm:text-base",children:"Review the details below and let us know if you'd like to proceed."})]}),s.vehicleOptions&&s.vehicleOptions.length>1?e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:370",className:"mb-6",children:[e.jsx("h2",{"data-loc":"client/src/pages/QuoteResponse.tsx:371",className:"text-center text-lg font-bold mb-4",style:{color:"#1B2A4A"},children:"Choose Your Experience"}),e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:374",className:"space-y-3",children:M.map(t=>{const a=l===t.vehicleName,c=t.badge,N=me(c),U=ue(t.vehicleName),j=G(t.price,!!s.isReturnTrip,t);return e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:382",onClick:()=>{R(t.vehicleName),u(null)},className:`rounded-xl border-2 overflow-hidden cursor-pointer transition-all ${a?"border-[#C8A951] shadow-lg ring-2 ring-[#C8A951]/30":"border-gray-200 hover:border-[#C8A951]/50"}`,children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:389",className:"flex items-center",children:[e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:390",className:"w-24 sm:w-28 shrink-0 p-3 flex items-center justify-center",style:{background:"#1B2A4A"},children:t.imageUrl?e.jsx("img",{"data-loc":"client/src/pages/QuoteResponse.tsx:392",src:t.imageUrl,alt:t.vehicleName,className:"max-w-full max-h-16 object-contain"}):e.jsx(y,{"data-loc":"client/src/pages/QuoteResponse.tsx:394",className:"h-10 w-10 text-white/50"})}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:397",className:"flex-1 p-3 sm:p-4",children:[e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:398",className:"flex items-center gap-2 mb-1",children:e.jsx("span",{"data-loc":"client/src/pages/QuoteResponse.tsx:399",className:"text-[10px] font-bold uppercase tracking-wide px-2 py-0.5 rounded text-white",style:{background:N},children:c})}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:403",className:"font-bold text-sm",style:{color:"#1B2A4A"},children:t.vehicleName}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:404",className:"text-xs italic",style:{color:"#C8A951"},children:t.tagline}),e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:405",className:"text-xs text-muted-foreground mt-0.5",children:["Seating: ",t.capacity," passengers"]}
1),U&&e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:407",className:"text-[11px] font-semibold mt-1 leading-tight",style:{color:"#9A7B1F"},children:["Airport & cruise: ",U]})]}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:412",className:"pr-4 text-right shrink-0",children:[s.isReturnTrip?e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:414",className:"mb-1",children:[e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:415",className:"text-[11px] text-muted-foreground",children:["Outbound ",e.jsxs("strong",{"data-loc":"client/src/pages/QuoteResponse.tsx:415",style:{color:"#1B2A4A"},children:["$",j.outboundPrice]})]}),e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:416",className:"text-[11px] text-muted-foreground",children:["Return ",e.jsxs("strong",{"data-loc":"client/src/pages/QuoteResponse.tsx:416",style:{color:"#1B2A4A"},children:["$",j.returnPrice]})]}),e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:417",className:"text-lg sm:text-xl font-bold",style:{color:"#1B2A4A"},children:["Total $",j.totalPrice]})]}):e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:420",className:"text-xl sm:text-2xl font-bold",style:{color:"#1B2A4A"},children:["$",j.totalPrice]}),e.jsx("a",{"data-loc":"client/src/pages/QuoteResponse.tsx:422",href:`/fleet#${t.slug}`,target:"_blank",rel:"noopener noreferrer",className:"text-[11px] underline",style:{color:"#C8A951"},onClick:te=>te.stopPropagation(),children:"View details"})]})]}),a&&e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:435",className:"px-4 py-2 text-center text-xs font-semibold",style:{background:"rgba(200,169,81,0.1)",color:"#C8A951"},children:"â Selected"})]},t.vehicleId)})}),e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:443",className:"text-center text-xs text-muted-foreground mt-3",children:["All prices include private vehicle, professional chauffeur, tolls, parking & government levy.",s.isReturnTrip?" Each option shows its separate outbound and return prices plus the total.":""]}),Q&&e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:448",className:"text-center text-sm font-semibold text-red-600 mt-3",role:"alert",children:Q}),s.confirmationReady===!1&&!Q&&e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:451",className:"mt-3 rounded-lg border border-amber-300 bg-amber-50 px-3 py-2 text-center",role:"status",children:[e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:452",className:"text-sm font-semibold text-amber-900",children:["This quote is awaiting ",s.missingRequiredFields?.join(" and ")||"required trip details","."]}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:453",className:"text-xs text-amber-800 mt-1",children:"You can review and select a vehicle, but confirmation will remain unavailable until Drive4u completes those details."})]})]}):E?e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:458",className:"rounded-2xl overflow-hidden shadow-lg mb-6",style:{background:"linear-gradient(135deg, #1B2A4A, #243556)"},children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:459",className:"p-6 sm:p-8 text-center",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:460",className:"text-xs uppercase tracking-[0.2em] font-semibold mb-2",style:{color:"#C8A951"},children:"Quoted Price"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:463",className:"text-4xl sm:text-5xl font-bold text-white mb-1",children:E}),e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:464",className:"text-sm text-white/60",children:["AUD (incl. GST)",s.isReturnTrip?" â includes return trip":""]}),s.isReturnTrip&&s.outboundPrice&&s.returnPrice&&e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:468",className:"mt-4 grid grid-cols-2 gap-3 text-left",children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:469",className:"rounded-lg bg-white/10 p-3",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:469",className:"text-[11px] uppercase text-white/60",children:"Outbound"}),e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:469",className:"text-lg font-bold text-white",children:["$",s.outboundPrice]})]}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:470",className:"rounded-lg bg-white/10 p-3",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:470",className:"text-[11px] uppercase text-white/60",children:"Return"}),e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:470",className:"text-lg font-bold text-white",children:["$",s.returnPrice]})]})]})]}),s.lineItems&&s.lineItems.length>0&&e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:476",className:"px-6 pb-6",children:e.jsx(pe,{"data-loc":"client/src/pages/QuoteResponse.tsx:477",items:s.lineItems,total:s.estimatedPrice?parseFloat(s.estimatedPrice):0,subtotal:s.estimatedPrice?parseFloat(s.estimatedPrice):0,discountTotal:0,editable:!1,
1compact:!0})})]}):null,e.jsx(le,{"data-loc":"client/src/pages/QuoteResponse.tsx:491",className:"shadow-md mb-6 overflow-hidden",children:e.jsxs(ne,{"data-loc":"client/src/pages/QuoteResponse.tsx:492",className:"p-0",children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:494",className:"p-5 sm:p-6 space-y-4",children:[e.jsx("h3",{"data-loc":"client/src/pages/QuoteResponse.tsx:495",className:"text-sm font-semibold uppercase tracking-wider text-muted-foreground",children:"Trip Details"}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:496",className:"space-y-3",children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:497",className:"flex items-start gap-3",children:[e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:498",className:"mt-0.5 h-8 w-8 rounded-full bg-emerald-100 dark:bg-emerald-900/30 flex items-center justify-center shrink-0",children:e.jsx(Y,{"data-loc":"client/src/pages/QuoteResponse.tsx:499",className:"h-4 w-4 text-emerald-600"})}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:501",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:502",className:"text-xs text-muted-foreground font-medium",children:"Pickup"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:503",className:"text-sm font-medium",style:{color:"#1B2A4A"},children:s.pickupAddress})]})]}),e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:506",className:"ml-4 border-l-2 border-dashed h-4",style:{borderColor:"rgba(27,42,74,0.15)"}}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:507",className:"flex items-start gap-3",children:[e.jsx("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:508",className:"mt-0.5 h-8 w-8 rounded-full bg-red-100 dark:bg-red-900/30 flex items-center justify-center shrink-0",children:e.jsx(Y,{"data-loc":"client/src/pages/QuoteResponse.tsx:509",className:"h-4 w-4 text-red-600"})}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:511",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:512",className:"text-xs text-muted-foreground font-medium",children:"Dropoff"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:513",className:"text-sm font-medium",style:{color:"#1B2A4A"},children:s.dropoffAddress})]})]}),s.isReturnTrip&&e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:517",className:"mt-5 rounded-xl border border-indigo-200 bg-indigo-50/60 p-4 space-y-3",children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:518",className:"flex items-center gap-2",children:[e.jsx(_,{"data-loc":"client/src/pages/QuoteResponse.tsx:518",className:"h-4 w-4 text-indigo-600"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:518",className:"text-sm font-semibold text-indigo-900",children:"Return Journey"})]}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:519",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:519",className:"text-xs text-muted-foreground",children:"Return pickup"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:519",className:"text-sm font-medium",style:{color:"#1B2A4A"},children:s.returnPickupAddress||s.dropoffAddress})]}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:520",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:520",className:"text-xs text-muted-foreground",children:"Return destination"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:520",className:"text-sm font-medium",style:{color:"#1B2A4A"},children:s.returnDropoffAddress||s.pickupAddress})]}),s.returnScheduledAt&&e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:521",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:521",className:"text-xs text-muted-foreground",children:"Return date & time"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:521",className:"text-sm font-medium",style:{color:"#1B2A4A"},children:A(s.returnScheduledAt)})]}),(s.returnDistanceKm||s.distanceKm)&&e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:522",className:"text-xs text-indigo-800",children:[parseFloat(s.returnDistanceKm||s.distanceKm||"0").toFixed(1)," km · approximately ",Math.round(parseFloat(s.returnDurationMin||s.durationMin||"0"))," minutes"]})]})]})]}),s.isReturnTrip&&e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:529",className:"border-t px-5 sm:px-6 py-4 grid gap-3 sm:grid-cols-2 bg-slate-50/70",children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:530",className:"rounded-lg border bg-white p-3",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:531",className:"text-[11px] font-bold uppercase tracking-wide mb-1",style:{color:"#1B2A4A"},children:"Outbound"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:532",className:"text-xs text-muted-foreground mb-2",children:b||"To be confirmed"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:533",className:"text-xs font-medium",style:{color:"#1B2A4A"},children:s.pickupAddress}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:534",className:"text-[11px] text-muted-foreground my-1",children:"to"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:535",className:"text-xs font-medium",style:{color:"#1B2A4A"},children:s.dropoffAddress})]}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:537",className:"rounded-lg border bg-white p-3",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:538",className:"text-[11px] font-bold uppercase tracking-wide mb-1",style:{color:"#9A7B1F"},children:"Return"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:539",className:"text-xs text-muted-foreground mb-2",children:ee}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:540",className:"text-xs font-medium",style:{color:"#1B2A4A"},children:s.dropoffAddress}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:541",className:"text-[11px] text-muted-foreground my-1",children:"to"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:542",className:"text-xs font-medium",style:{color:"#1B2A4A"},children:s.pickupAddress})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:548",className:"border-t px-5 sm:px-6 py-4 grid grid-cols-2 gap-y-4 gap-x-6",children:[b&&e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:550",className:"col-span-2",children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:551",className:"flex items-center gap-2 text-xs text-muted-foreground font-medium mb-1",children:[e.jsx(ge,{"data-loc":"client/src/pages/QuoteResponse.tsx:552",className:"h-3.5 w-3.5"})," Date & Time"]}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:554",className:"text-sm font-medium",style:{color:"#1B2A4A"},children:b})]}),L&&e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:558",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:559",className:"text-xs text-muted-foreground font-medium mb-1",children:"Service"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:560",className:"text-sm font-medium",style:{color:"#1B2A4A"},children:L})]}),s.vehicleOptions&&s.vehicleOptions.length>1?e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:564",children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:565",className:"flex items-center gap-2 text-xs text-muted-foreground font-medium mb-1",children:[e.jsx(y,{"data-loc":"client/src/pages/QuoteResponse.tsx:566",className:"h-3.5 w-3.5"})," Vehicle"]}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:568",className:`text-sm font-medium ${r?"":"text-amber-700"}`,style:r?{color:"#1B2A4A"}:void 0,children:r?.vehicleName||"Select a vehicle above"})]}):s.vehicleName?e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:573",children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:574",className:"flex items-center gap-2 text-xs text-muted-foreground font-medium mb-1",children:[e.jsx(y,{"data-loc":"client/src/pages/QuoteResponse.tsx:575",className:"h-3.5 w-3.5"})," Vehicle"]}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:577",className:"text-sm font-medium",style:{color:"#1B2A4A"},children:s.vehicleName})]}
1):null,s.distanceKm&&e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:581",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:582",className:"text-xs text-muted-foreground font-medium mb-1",children:"Distance"}),e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:583",className:"text-sm font-medium",style:{color:"#1B2A4A"},children:[parseFloat(s.distanceKm).toFixed(1)," km"]})]}),s.durationMin&&e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:587",children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:588",className:"flex items-center gap-2 text-xs text-muted-foreground font-medium mb-1",children:[e.jsx(re,{"data-loc":"client/src/pages/QuoteResponse.tsx:589",className:"h-3.5 w-3.5"})," Est. Duration"]}),e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:591",className:"text-sm font-medium",style:{color:"#1B2A4A"},children:[Math.round(parseFloat(s.durationMin))," mins"]})]}),s.passengerCount&&e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:595",children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:596",className:"flex items-center gap-2 text-xs text-muted-foreground font-medium mb-1",children:[e.jsx(ie,{"data-loc":"client/src/pages/QuoteResponse.tsx:597",className:"h-3.5 w-3.5"})," Passengers"]}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:599",className:"text-sm font-medium",style:{color:"#1B2A4A"},children:s.passengerCount})]}),s.luggageCount&&s.luggageCount!=="none"&&e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:603",children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:604",className:"flex items-center gap-2 text-xs text-muted-foreground font-medium mb-1",children:[e.jsx(he,{"data-loc":"client/src/pages/QuoteResponse.tsx:605",className:"h-3.5 w-3.5"})," Luggage"]}),e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:607",className:"text-sm font-medium",style:{color:"#1B2A4A"},children:[s.luggageCount," bags"]})]}),s.isReturnTrip&&!(s.vehicleOptions&&s.vehicleOptions.length>1)&&e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:611",children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:612",className:"flex items-center gap-2 text-xs text-muted-foreground font-medium mb-1",children:[e.jsx(_,{"data-loc":"client/src/pages/QuoteResponse.tsx:613",className:"h-3.5 w-3.5"})," Return Trip"]}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:615",className:"text-sm font-medium text-emerald-600",children:"Included"})]})]}),r&&g&&e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:621",className:"border-t px-5 sm:px-6 py-5",style:{background:"rgba(200,169,81,0.07)"},children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:622",className:"flex items-center justify-between gap-3 mb-3",children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:623",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:624",className:"text-xs font-bold uppercase tracking-wide",style:{color:"#9A7B1F"},children:"Selected Vehicle Pricing"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:625",className:"text-sm font-semibold",style:{color:"#1B2A4A"},children:r.vehicleName})]}),e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:627",className:"text-xl font-bold",style:{color:"#1B2A4A"},children:["Total $",g.totalPrice]})]}),s.isReturnTrip?e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:630",className:"grid grid-cols-2 gap-3",children:[e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:631",className:"rounded-lg bg-white border p-3",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:632",className:"text-[11px] text-muted-foreground uppercase font-semibold",children:"Outbound"}),e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:633",className:"text-lg font-bold",style:{color:"#1B2A4A"},children:["$",g.outboundPrice]})]}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:635",className:"rounded-lg bg-white border p-3",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:636",className:"text-[11px] text-muted-foreground uppercase font-semibold",children:"Return"}),e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:637",className:"text-lg font-bold",style:{color:"#1B2A4A"},children:["$",g.returnPrice]})]})]}):e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:641",className:"rounded-lg bg-white border p-3",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:642",className:"text-[11px] text-muted-foreground uppercase font-semibold",children:"Selected Fare"}),e.jsxs("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:643",className:"text-lg font-bold",style:{color:"#1B2A4A"},children:["$",g.totalPrice]})]})]}),s.notes&&e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:651",className:"border-t px-5 sm:px-6 py-4",children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:652",className:"text-xs text-muted-foreground font-medium mb-1",children:"Notes"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:653",className:"text-sm",style:{color:"#1B2A4A"},children:s.notes})]})]})}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:660",className:"rounded-xl border p-4 mb-6",style:{backgroundColor:"rgba(22,163,74,0.04)",borderColor:"rgba(22,163,74,0.2)"},children:[e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:661",className:"text-sm font-semibold text-emerald-700 mb-1",children:"Vehicle Guarantee"}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:662",className:"text-xs text-emerald-600 leading-relaxed",children:"If your selected vehicle is not available, you will automatically be assigned a similar or higher-grade vehicle at no extra charge."})]}),e.jsxs("div",{"data-loc":"client/src/pages/QuoteResponse.tsx:668",className:"space-y-3",children:[e.jsxs(i,{"data-loc":"client/src/pages/QuoteResponse.tsx:669",className:"w-full h-14 text-lg font-bold gap-2 rounded-xl shadow-lg",style:{backgroundColor:"#16a34a",color:"white"},disabled:m||s.confirmationReady===!1||!!(s.vehicleOptions&&s.vehicleOptions.length>1&&!l),onClick:()=>
1V("accepted"),children:[m?e.jsx(v,{"data-loc":"client/src/pages/QuoteResponse.tsx:676",className:"h-5 w-5 animate-spin"}):e.jsx(W,{"data-loc":"client/src/pages/QuoteResponse.tsx:678",className:"h-5 w-5"}),s.confirmationReady===!1?"Awaiting trip details":l&&s.vehicleOptions&&s.vehicleOptions.length>1?`Confirm ${l}`:s.vehicleOptions&&s.vehicleOptions.length>1?"Select a vehicle above":"Accept Quote"]}),e.jsxs(i,{"data-loc":"client/src/pages/QuoteResponse.tsx:688",variant:"outline",className:"w-full h-12 text-base font-semibold gap-2 rounded-xl border-red-200 text-red-600 hover:bg-red-50 hover:border-red-300",disabled:m,onClick:()=>V("declined"),children:[m?e.jsx(v,{"data-loc":"client/src/pages/QuoteResponse.tsx:695",className:"h-5 w-5 animate-spin"}):e.jsx(H,{"data-loc":"client/src/pages/QuoteResponse.tsx:697",className:"h-5 w-5"}),"Decline Quote"]})]}),e.jsx("p",{"data-loc":"client/src/pages/QuoteResponse.tsx:704",className:"text-center text-xs text-muted-foreground mt-6",children:"This quote is valid for 7 days. Questions? Reply to the email or call us â we're here to help!"})]})})}export{Be 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.