PageSourceSearch

https://www.airporttransfers.ai/_next/static/chunks/pages/order-7bb087f47c21b8fc.js

js airporttransfers.ai collected 2026-10-05 13:28:33 UTC 62,931 bytes, 1 lines download raw bytes

1try{!function(){var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},s=(new e.Error).stack;s&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[s]="2c9d9b78-a1c8-4731-a54e-4de680d482f8",e._sentryDebugIdIdentifier="sentry-dbid-2c9d9b78-a1c8-4731-a54e-4de680d482f8")}()}catch(e){}(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9864],{18266:(e,s,a)=>{"use strict";a.d(s,{A:()=>r});let r=function(e){let s=Number(e);return Number.isNaN(s)?"0":Math.round(s).toLocaleString("en-US")}},43619:(e,s,a)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/order",function(){return a(62072)}])},44405:(e,s,a)=>{"use strict";a.d(s,{A:()=>f});var r=a(37876),l=a(14232),i=a(54587),n=a.n(i),d=a(44937),c=a(3738),o=a(64004),x=a(59232),m=a(70925),h=a(92396),u=a(51122),g=a(56041),p=a(18266);function f(e){let{customColor:s}=e,{t:a}=(0,x.Bd)(["order","common"]),i=(0,l.useRef)(null),[f,b]=(0,l.useState)([]),[v,j]=(0,l.useState)(!0),[y,N]=(0,l.useState)(null),[w,_]=(0,l.useState)(!1),[k,C]=(0,l.useState)(!1),[A,S]=(0,l.useState)(null),{localizedReplace:E}=(0,m.g)();(0,l.useEffect)(()=>{(async()=>{try{var e;let{languageId:s}=h.A.getState(),a=await fetch("".concat("https://app.airporttransfers.ai/api","/recommendedProducts/").concat(s||1)),r=await a.json();b((null==r||null==(e=r.data)?void 0:e.products)||[])}catch(e){console.error("Error fetching recommended products:",e)}finally{j(!1)}})()},[]),(0,l.useEffect)(()=>{(async()=>{try{let e=await (0,g.Ec)();e&&1!==e.exchange_rate&&S(e)}catch(e){console.error("Error fetching currency rate:",e)}})()},[]);let I=()=>{if(!i.current)return;let{scrollLeft:e,scrollWidth:s,clientWidth:a}=i.current;_(e>0),C(e+a<s-1)};(0,l.useEffect)(()=>{I();let e=i.current;if(e)return e.addEventListener("scroll",I),window.addEventListener("resize",I),()=>{e.removeEventListener("scroll",I),window.removeEventListener("resize",I)}},[f]);let L=e=>{if(!i.current)return;let s=i.current.querySelector("[data-card]");if(!s)return;let a=parseInt(window.getComputedStyle(s).marginRight)||16,r=s.offsetWidth+a;i.current.scrollBy({left:"left"===e?-r:r,behavior:"smooth"})};return(0,r.jsxs)("section",{style:{backgroundColor:s},className:"relative w-full py-4 md:py-8 bg-black",children:[v&&(0,r.jsx)("div",{className:"absolute inset-0 z-50 flex justify-center items-center bg-black/60 pointer-events-none",children:(0,r.jsx)(u.A,{})}),(0,r.jsxs)("div",{className:"container mx-auto px-4 sm:px-6 relative z-10",children:[(0,r.jsxs)("div",{className:"flex items-center justify-between mb-6 md:mb-10",children:[(0,r.jsx)("h2",{className:"text-lg sm:text-xl md:text-2xl font-semibold text-white",children:a("recommended_products")}),(0,r.jsxs)("div",{className:"flex space-x-2",children:[(0,r.jsx)("button",{onClick:()=>L("left"),disabled:!w,className:"p-2 rounded-full border border-gray-600 transition ".concat(w?"hover:bg-gray-800 text-white":"opacity-40 cursor-not-allowed text-gray-500"),children:(0,r.jsx)(d.A,{size:20})}),(0,r.jsx)("button",{onClick:()=>L("right"),disabled:!k,className:"p-2 rounded-full border border-gray-600 transition ".concat(k?"hover:bg-gray-800 text-white":"opacity-40 cursor-not-allowed text-gray-500"),children:(0,r.jsx)(c.A,{size:20})})]})]}),!v&&f.length>0?(0,r.jsx)("div",{ref:i,className:"flex gap-4 overflow-x-auto scroll-smooth scrollbar-hide pb-2",children:f.map(e=>{var s;let l="number"==typeof(s=null==e?void 0:e.starting_price)?s:s&&parseFloat(s.toString().replace(/[^0-9.]/g,""))||0;return(0,r.jsxs)("div",{"data-card":!0,className:"flex flex-col flex-shrink-0 w-[180px] sm:w-[200px] md:w-[220px] lg:w-[240px] xl:w-[260px] bg-white rounded-xl shadow-sm hover:shadow-md transition-all border border-gray-100 overflow-hidden relative",children:[y===e.id&&(0,r.jsx)("div",{className:"absolute inset-0 z-20 flex justify-center items-center bg-white/80 rounded-xl",children:(0,r.jsx)(u.A,{})}),(0,r.jsx)("div",{className:"relative w-full h-36 sm:h-40 md:h-44 rounded-t-xl overflow-hidden",children:(0,r.jsx)(n(),{src:(0,o.m)(e.image)||e.image||"/placeholder.svg",alt:e.title,fill:!0,className:"object-cover"})}),(0,r.jsxs)("div",{className:"p-3 flex flex-col flex-grow",children:[(0,r.jsx)("h3",{className:"text-black font-medium text-xs sm:text-sm line-clamp-2 mb-1.5 h-9 sm:h-10",children:e.title}),(0,r.jsx)("p",{className:"text-[11px] sm:text-xs text-gray-500 line-clamp-2 mb-2",children:e.short_desc}),(0,r.jsxs)("div",{className:"flex items-center justify-between mt-auto",children:[(0,r.jsxs)("div",{className:"flex flex-col text-left",children:[(0,r.jsxs)("span",{className:"font-semibold text-[#CC9A55] text-xs sm:text-sm",children:[null==e?void 0:e.starting_price," ",null==e?void 0:e.currency]}),A&&1!==A.exchange_rate&&(0,r.jsxs)("span",{className:"text-[10px] text-gray-500 font-medium",children:["Est. ",(0,p.A)(l*(null==A?void 0:A.exchange_rate))," ",null==A?void 0:A.currency]})]}),(0,r.jsx)("button",{onClick:()=>{var s;N(e.id),sessionStorage.removeItem("fromOrder"),E("/day-tours/".concat(!(s=e.title)?"":encodeURIComponent(s.toString().toLowerCase().replace(/\s+/g,"-").replace(RegExp("[^\\p{L}\\p{N}-]+","gu"),"").replace(/--+/g,"-").replace(/^-+/,"").replace(/-+$/,"")),"/").concat(e.id))},disabled:null!==y,className:"bg-[#CC9A55] hover:bg-[#b88a45] text-white px-2.5 md:py-2 py-1 rounded-md text-[11px] sm:text-xs font-medium transition disabled:opacity-70 disabled:cursor-not-allowed",children:y===e.id?a("loading","Loading..."):a("view_details")})]})]})]},e.id)})}):!v&&(0,r.jsx)("div",{className:"py-12 text-center text-gray-500",children:a("no_products","No Recommended Products Found")})]})]})}},47126:(e,s,a)=>{"use strict";a.d(s,{Z:()=>d});var r=a(8106),l=a(4319),i=a(34923),n=a(92396);let d=(0,r.v)()((0,l.Zr)((e,s)=>({vouchers:[],selectedVoucher:null,loading:!1,error:null,fetchVouchers:async s=>{let{languageId:a}=n.A.getState();e({loading:!0,error:null});try{let r=await (0,i.Y3)(s,{language_id:a||1});r.success?e({vouchers:r.data||[],loading:!1}):e({error:r.message||"Failed to fetch vouchers",loading:!1,vouchers:[]})}catch(s){e({error:s.message||"Failed to load vouchers",loading:!1,vouchers:[]})}}
1,fetchVoucherDetail:async(s,a)=>{let{languageId:r}=n.A.getState();e({loading:!0,error:null});try{let l=await (0,i.Y3)(s,{voucher_id:a,language_id:r||1});if(l.success&&l.data){let s=Array.isArray(l.data)?l.data.find(e=>String(e.voucher_id)===String(a)):l.data;e({selectedVoucher:s||null,loading:!1})}else throw Error(l.message||"Voucher not found")}catch(s){e({error:s.message||"Failed to load voucher details",loading:!1,selectedVoucher:null})}},clearError:()=>e({error:null}),reset:()=>e({vouchers:[],selectedVoucher:null,loading:!1,error:null})}),{name:"voucher-storage",partialize:e=>({vouchers:e.vouchers,selectedVoucher:e.selectedVoucher})}))},56041:(e,s,a)=>{"use strict";a.d(s,{Ec:()=>l,Ot:()=>r});let r=async function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];try{if(!e){let e=localStorage.getItem("cachedIPInfo");if(e)return JSON.parse(e)}let s=await fetch("https://api64.ipify.org?format=json"),a=await s.json();if(a&&a.ip)return localStorage.setItem("cachedIPInfo",JSON.stringify(a)),a;return{}}catch(e){return console.warn("⚠️ Failed to fetch IP:",e),{}}},l=async()=>{try{let e=await r(!0),s=null==e?void 0:e.ip;if(!s)throw Error("Could not retrieve current IP");let a=localStorage.getItem("user_currency_ip"),l=localStorage.getItem("user_currency_info");if(a===s&&l){let e=JSON.parse(l);if(e&&e.currency)return e}let i="".concat("https://app.airporttransfers.ai/api","/user-currency?ip=").concat(s),n=await fetch(i),d=await n.json();if(d&&d.success&&d.data)return localStorage.setItem("user_currency_ip",s),localStorage.setItem("user_currency_info",JSON.stringify(d.data)),d.data;throw Error((null==d?void 0:d.message)||"Failed to fetch currency from API")}catch(e){return console.warn("⚠️ Failed to get user currency rate:",e),{success:!1,currency:"SGD",base_currency:"SGD",exchange_rate:1,is_fallback:!0}}}},62072:(e,s,a)=>{"use strict";a.r(s),a.d(s,{__N_SSG:()=>ev,default:()=>ej});var r=a(37876),l=a(14232),i=a(14e3),n=a(82366),d=a(54075),c=a(59488),o=a(71661),x=a(14280),m=a(26678),h=a(50416),u=a(97842),g=a(79890),p=a(15495),f=a(8584),b=a(18024),v=a(50843),j=a(76849),y=a(18500),N=a(35162),w=a(72183),_=a(87082),k=a(28043),C=a(59878),A=a(26805),S=a(5712),E=a(45944),I=a(19009),L=a(51122),B=a(59232),z=a(47126),M=a(54587),O=a.n(M),D=a(59452),P=a(44937),R=a(3738),F=a(64004),T=a(92396),U=a(89099);function q(e){let{itineraryId:s,customColor:a}=e,{t:i}=(0,B.Bd)(["common","order"]),n=(0,l.useRef)(null),d=(0,U.useRouter)(),[c,o]=(0,l.useState)([]),[x,m]=(0,l.useState)(null),[h,u]=(0,l.useState)([]),[g,p]=(0,l.useState)(!0),[f,b]=(0,l.useState)(!1),[v,j]=(0,l.useState)(!1),[y,N]=(0,l.useState)(-1),[w,_]=(0,l.useState)(null);(0,l.useEffect)(()=>{(async()=>{try{let{languageId:e}=T.A.getState(),s=await fetch("".concat("https://app.airporttransfers.ai/api","/landmark-types/").concat(e||1)),a=await s.json();o((null==a?void 0:a.data)||[])}catch(e){console.error("Error fetching types:",e)}finally{}})()},[]),(0,l.useEffect)(()=>{s&&(async()=>{try{var e,a;let{languageId:r}=T.A.getState(),l=await fetch("".concat("https://app.airporttransfers.ai/api","/customer/itinerary/nearby-landmarks"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({itinerary_id:s,landmark_type:x?[x]:[],language_id:r||1})}),i=await l.json(),n=(null==i||null==(a=i.data)||null==(e=a.landmarks)?void 0:e.data)||[],d=n;try{let e=JSON.parse(localStorage.getItem("viewedLandmarks")||"[]"),s=n.filter(s=>!e.includes(s.id)),a=n.filter(s=>e.includes(s.id));a.sort((s,a)=>e.indexOf(s.id)-e.indexOf(a.id)),d=[...s,...a]}catch(e){}u(d),N(e=>-1===e?n.length:e)}catch(e){console.error("Error fetching landmarks:",e)}finally{}})()},[x,s]);let k=()=>{if(!n.current)return;let{scrollLeft:e,scrollWidth:s,clientWidth:a}=n.current;b(e>0),j(e+a<s-1)};(0,l.useEffect)(()=>{k();let e=n.current;if(e)return e.addEventListener("scroll",k),window.addEventListener("resize",k),()=>{e.removeEventListener("scroll",k),window.removeEventListener("resize",k)}},[h]);let C=e=>{if(!n.current)return;let s=n.current.querySelector("[data-card]");if(!s)return;let a=parseInt(window.getComputedStyle(s).marginRight)||16,r=s.offsetWidth+a;n.current.scrollBy({left:"left"===e?-r:r,behavior:"smooth"})};return 0!==y||g?(0,r.jsx)("section",{style:{backgroundColor:a},className:"relative w-full py-2 md:py-3 bg-black",children:(0,r.jsxs)("div",{className:"container mx-auto px-4 sm:px-6 relative z-10",children:[(0,r.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,r.jsxs)("h2",{className:"text-lg sm:text-xl md:text-2xl font-semibold text-white flex items-center gap-2",children:[(0,r.jsx)(D.A,{size:20})," ",i("nearby_landmarks")]}),(0,r.jsxs)("div",{className:"flex space-x-2",children:[(0,r.jsx)("button",{onClick:()=>C("left"),disabled:!f,className:"p-2 rounded-full border border-gray-600 transition ".concat(f?"hover:bg-gray-800 text-white":"opacity-40 cursor-not-allowed text-gray-500"),children:(0,r.jsx)(P.A,{size:20})}),(0,r.jsx)("button",{onClick:()=>C("right"),disabled:!v,className:"p-2 rounded-full border border-gray-600 transition ".concat(v?"hover:bg-gray-800 text-white":"opacity-40 cursor-not-allowed text-gray-500"),children:(0,r.jsx)(R.A,{size:20})})]})]}),(0,r.jsx)("div",{className:"mb-4 pb-2 overflow-x-auto",children:(0,r.jsxs)("div",{className:"flex gap-2 whitespace-nowrap",children:[(0,r.jsx)("button",{onClick:()=>m(null),className:"inline-block rounded-full text-sm px-3 py-1 ".concat(null===x?"bg-[#C6A15B] text-black":"text-[#C6A15B] border border-[#C6A15B] hover:bg-[#C6A15B] hover:text-black"),children:i("all")}),c.map(e=>(0,r.jsx)("button",{onClick:()=>m(e.id),className:"inline-block rounded-full text-sm px-3 py-1 ".concat(x===e.id?"bg-[#C6A15B] text-black":"text-[#C6A15B] border border-[#C6A15B] hover:bg-[#C6A15B] hover:text-black"),children:e.name},e.id))]})}),!g&&0===h.length&&(0,r.jsx)("div",{className:"text-center text-white py-4 lg:py-8",children:(0,r.jsx)("p",{children:i("no_landmarks_found")})}),(0,r.jsx)("div",{ref:n,className:"flex gap-4 overflow-x-auto scroll-smooth scrollbar-hide pb-2",children:h.map(e=>(0,r.jsxs)("div",{"data-card":!0,onClick:()=>(e=>{_(e.id);try{let s=JSON.parse(localStorage.getItem("viewedLandmarks")||"[]");
1if(!s.includes(e.id)){let a=[...s,e.id];localStorage.setItem("viewedLandmarks",JSON.stringify(a))}}catch(e){}let s=(e.title||"detail").toLowerCase().trim().replace(/\s+/g,"-").replace(/[^\w-]+/g,"").replace(/--+/g,"-")||"detail";d.push("/landmark/".concat(s,"/").concat(e.id))})(e),className:"cursor-pointer group flex flex-col flex-shrink-0 w-[180px] sm:w-[200px] md:w-[220px] lg:w-[240px] xl:w-[260px] bg-white rounded-xl shadow-sm hover:shadow-md transition-all border border-gray-700 overflow-hidden relative",children:[w===e.id&&(0,r.jsx)("div",{className:"absolute inset-0 bg-white/70 flex justify-center items-center z-20 rounded-xl",children:(0,r.jsx)(L.A,{})}),(0,r.jsx)("div",{className:"relative w-full h-36 sm:h-40 md:h-44 rounded-t-xl overflow-hidden",children:(0,r.jsx)(O(),{src:(0,F.m)(e.image)||"/placeholder.svg",alt:e.title,fill:!0,className:"object-cover transition-transform duration-300 group-hover:scale-105"})}),(0,r.jsxs)("div",{className:"p-3 flex flex-col flex-grow",children:[(0,r.jsx)("h3",{className:"text-black font-medium text-xs sm:text-sm line-clamp-2 mb-1.5 h-9 sm:h-10",children:e.title}),(0,r.jsx)("p",{className:"text-[11px] sm:text-xs text-gray-800 line-clamp-4 mb-2 flex-grow",children:e.description}),(0,r.jsx)("div",{className:"flex justify-between items-end mt-2",children:(0,r.jsx)("span",{className:"font-semibold text-black text-xs sm:text-sm mt-auto",children:e.type})})]})]},e.id))})]})}):null}var V=a(44405),J=a(21744),G=a(9674),H=a(49240),W=a(3739),X=a(41001),Z=a(28364),K=a(73449),Q=a(46618),Y=a(38129),$=a(95316);let ee=e=>{var s,a;let{voucher:i,onClose:n}=e,{t:d}=(0,B.Bd)(["order","common"]),[c,o]=(0,l.useState)(!1),[x,m]=(0,l.useState)(!1);(0,l.useEffect)(()=>{let e=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=e}},[]);let h=e=>new Date(e).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"}),g=e=>{if(!e)return"";let[s,a]=e.split(":"),r=parseInt(s);return"".concat(r%12||12,":").concat(a," ").concat(r>=12?"PM":"AM")},p=async()=>{if(!i.file_path)return;o(!0);let e=(()=>{let e=navigator.userAgent,s=navigator.platform;return{isIOS:/iPad|iPhone|iPod/.test(e)||"MacIntel"===s&&navigator.maxTouchPoints>1,isAndroid:/Android/.test(e),isMobile:/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(e)}})(),s=i.file_path,a="".concat(i.title.replace(/[^a-z0-9]/gi,"_"),".pdf");try{if(e.isIOS){let e=document.createElement("a");e.href=s,e.target="_blank",e.rel="noopener noreferrer",document.body.appendChild(e),e.click(),document.body.removeChild(e)}else if(e.isMobile){let e=document.createElement("a");e.href=s,e.download=a,e.target="_blank",document.body.appendChild(e),e.click(),document.body.removeChild(e),setTimeout(()=>{document.hidden||window.open(s,"_blank")},500)}else try{let e=await fetch(s,{method:"GET",headers:{"Content-Type":"application/pdf"}});if(!e.ok)throw Error("Network response was not ok");let r=await e.blob(),l=window.URL.createObjectURL(r),i=document.createElement("a");i.href=l,i.download=a,i.style.display="none",document.body.appendChild(i),i.click(),setTimeout(()=>{document.body.removeChild(i),window.URL.revokeObjectURL(l)},100)}catch(r){let e=document.createElement("a");e.href=s,e.download=a,e.target="_blank",document.body.appendChild(e),e.click(),document.body.removeChild(e)}}catch(e){console.error("Download failed:",e),window.open(s,"_blank","noopener,noreferrer")}finally{o(!1)}};return(0,r.jsx)("div",{className:"fixed top-0 left-0 right-0 bottom-0 bg-black/60 backdrop-blur-sm flex items-center justify-center z-[9999] p-4 sm:p-4",onClick:n,style:{position:"fixed",inset:0,margin:0},children:(0,r.jsxs)("div",{className:"bg-white dark:bg-slate-800 rounded-xl sm:rounded-2xl max-w-sm w-full my-4 sm:my-auto max-h-[calc(100vh-2rem)] sm:max-h-[90vh] flex flex-col relative shadow-2xl overflow-hidden",onClick:e=>e.stopPropagation(),children:[(0,r.jsxs)("div",{className:"bg-gradient-to-br from-[#CC9A55] to-[#B88A45] text-white p-3 rounded-t-xl sm:rounded-t-2xl flex-shrink-0",children:[(0,r.jsx)("button",{onClick:n,className:"absolute top-2 right-2 z-10 p-1.5 rounded-full bg-white/20 hover:bg-white/30 transition-colors",children:(0,r.jsx)(u.A,{className:"w-4 h-4 text-white"})}),(0,r.jsxs)("div",{className:"flex items-start gap-2.5 pr-8",children:["voucher"===i.type?(0,r.jsx)("div",{className:"w-9 h-9 sm:w-10 sm:h-10 rounded-lg bg-white/20 backdrop-blur-sm flex items-center justify-center flex-shrink-0",children:(0,r.jsx)(Z.A,{className:"w-4 h-4 sm:w-5 sm:h-5 text-white"})}):(0,r.jsx)("div",{className:"w-9 h-9 sm:w-10 sm:h-10 rounded-lg bg-white/20 backdrop-blur-sm flex items-center justify-center flex-shrink-0 overflow-hidden",children:(null==(a=i.redemption)||null==(s=a.sku)?void 0:s.image)?(0,r.jsx)("img",{src:i.redemption.sku.image,alt:i.redemption.sku.description,className:"w-full h-full object-cover"}):(0,r.jsx)(K.A,{className:"w-4 h-4 sm:w-5 sm:h-5 text-white"})}),(0,r.jsxs)("div",{className:"flex-1",children:[(0,r.jsx)("p",{className:"text-xs text-white/80 mb-0.5",children:d("voucher"===i.type?"pdf_voucher":"qr_code_voucher")}),(0,r.jsx)("h2",{className:"text-base sm:text-lg font-bold leading-tight",children:i.title})]})]})]}),(0,r.jsxs)("div",{className:"overflow-y-auto overflow-x-hidden flex-1 p-3 space-y-2.5 text-sm",style:{WebkitOverflowScrolling:"touch"},children:[(0,r.jsxs)("div",{className:"bg-gray-50 dark:bg-slate-700 rounded-lg p-2.5",children:[(0,r.jsx)("h3",{className:"text-sm font-semibold text-gray-900 dark:text-white mb-1.5",children:d("booking_details")}),(0,r.jsxs)("div",{className:"grid grid-cols-2 gap-2",children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-xs text-gray-500 dark:text-gray-400 mb-0.5",children:d("service_date")}),(0,r.jsxs)("div",{className:"flex items-center gap-1",children:[(0,r.jsx)(J.A,{className:"w-3 h-3 text-[#CC9A55]"}),(0,r.jsx)("p",{className:"text-xs font-medium text-gray-900 dark:text-white",children:h(i.itinerary.date)})]})]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-xs text-gray-500 dark:text-gray-400 mb-0.5",children:d("passengers")}),(0,r.jsxs)("div",{className:"flex items-center gap-1",children:[(0,r.jsx)(G.A,{className:"w-3 h-3 text-[#CC9A55]"}),(0,r.jsxs)("p",{className:"text-xs font-medium text-gray-900 dark:text-white",children:[i.itinerary.adults,d("adult_short"),i.itinerary.children>0&&", ".concat(i.itinerary.children).concat(d("child_short"))]})]})]})]})]}),"qr"===i.type&&i.qr_link?(0,r.jsxs)("div",{className:"bg-gray-50 dark:bg-slate-700 rounded-lg p-2.5",children:[(0,r.jsx)("h3",{className:"text-sm font-semibold text-gray-900 dark:text-white mb-2",children:d("qr_code")}),(0,r.jsx)("div",{className:"bg-white dark:bg-slate-600 p-3 rounded-lg border-2 border-[#CC9A55]",children:(0,r.jsx)("div",{className:"w-full aspect-square flex items-center justify-center",children:(0,r.jsx)("img",{src:"https://api.qrserver.com/v1/create-qr-code/?size=400x400&data=".concat(encodeURIComponent(i.qr_link)),alt:"QR Code",className:"w-full h-auto rounded-lg"})})}),i.redemption&&(0,r.jsx)("p",{className:"text-lg text-center text-[#CC9A55] font-mono font-bold mt-2",children:i.redemption.code})]}):"voucher"===i.type&&i.file_path&&(0,r.jsxs)("div",{className:"bg-gray-50 dark:bg-slate-700 rounded-lg p-2.5",children:[(0,r.jsxs)("h3",{className:"text-sm font-semibold text-gray-900 dark:text-white mb-2",children:[" ",d("download_voucher")]}
1),(0,r.jsx)("button",{onClick:p,disabled:c,className:"w-full px-3 py-2 bg-[#CC9A55] text-white rounded-lg hover:bg-[#B88A45] transition-colors flex items-center justify-center gap-2 text-xs font-medium disabled:opacity-50",children:c?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(y.A,{className:"w-3 h-3 animate-spin"}),d("downloading")]}):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(Q.A,{className:"w-3 h-3"}),d("download_pdf")]})})]}),i.redemption&&(0,r.jsxs)("div",{className:"bg-gray-50 dark:bg-slate-700 rounded-lg p-2.5 space-y-2",children:[(0,r.jsx)("h3",{className:"text-sm font-semibold text-gray-900 dark:text-white",children:d("redemption_details")}),(0,r.jsxs)("div",{className:"flex items-center justify-between",children:[(0,r.jsxs)("div",{className:"flex items-center gap-1.5",children:[(e=>{switch(e){case"assigned":case"redeemed":return(0,r.jsx)(H.A,{className:"w-4 h-4 text-[#CC9A55]"});case"expired":return(0,r.jsx)(W.A,{className:"w-4 h-4 text-[#CC9A55]"});default:return(0,r.jsx)(X.A,{className:"w-4 h-4 text-[#CC9A55]"})}})(i.redemption.status)," ",(0,r.jsx)("span",{className:"text-xs text-gray-600 dark:text-gray-300",children:d("status")})]})," ",(0,r.jsx)("span",{className:"px-2 py-0.5 rounded-full text-xs font-medium ".concat((i.redemption.status,"text-[#CC9A55] bg-[#CC9A55]/10 dark:bg-[#CC9A55]/20 border border-[#CC9A55]/30")),children:d(i.redemption.status.toLowerCase())})]}),i.redemption.sku.valid_days&&i.redemption.sku.valid_days.length>0&&(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-xs text-gray-500 dark:text-gray-400 mb-1",children:d("valid_days")}),(0,r.jsx)("div",{className:"flex flex-wrap gap-1",children:i.redemption.sku.valid_days.map(e=>(0,r.jsx)("span",{className:"px-2 py-0.5 bg-[#CC9A55]/10 text-[#CC9A55] rounded-full text-xs font-medium",children:e.substring(0,3)},e))})]}),i.redemption.sku.is_time_specific&&(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[(0,r.jsx)(b.A,{className:"w-3 h-3 text-[#CC9A55]"}),(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-xs text-gray-500 dark:text-gray-400",children:d("valid_time")}),(0,r.jsxs)("p",{className:"text-xs font-medium text-gray-900 dark:text-white",children:[g(i.redemption.sku.valid_time_from)," -"," ",g(i.redemption.sku.valid_time_to)]})]})]}),i.redemption.sku.description&&(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-xs text-gray-500 dark:text-gray-400 mb-0.5",children:d("description")}),(0,r.jsx)("p",{className:"text-xs text-gray-900 dark:text-white leading-relaxed",children:i.redemption.sku.description})]}),i.redemption.sku.terms_conditions&&(0,r.jsxs)("div",{className:"border-t border-gray-300 dark:border-slate-600 pt-2",children:[(0,r.jsxs)("button",{onClick:()=>m(!x),className:"w-full flex items-center justify-between text-left",children:[(0,r.jsx)("p",{className:"text-xs font-semibold text-gray-900 dark:text-white",children:d("terms_conditions")}),x?(0,r.jsx)(Y.A,{className:"w-4 h-4 text-[#CC9A55]"}):(0,r.jsx)($.A,{className:"w-4 h-4 text-[#CC9A55]"})]}),x&&(0,r.jsx)("p",{className:"text-xs text-gray-700 dark:text-gray-300 leading-relaxed mt-1.5",children:i.redemption.sku.terms_conditions})]}),i.redemption.redeemed_at&&(0,r.jsx)("div",{className:"pt-1.5 border-t border-gray-300 dark:border-slate-600",children:(0,r.jsxs)("p",{className:"text-xs text-gray-500 dark:text-gray-400",children:[d("redeemed")," ",h(i.redemption.redeemed_at)]})})]})]})]})})},et=e=>{let{vouchers:s,loading:a}=e,{t:i}=(0,B.Bd)("order"),[d,c]=(0,l.useState)(null);if(a)return(0,r.jsx)("div",{className:"bg-white dark:bg-slate-800 rounded-2xl shadow-sm p-8",children:(0,r.jsxs)("div",{className:"flex flex-col items-center justify-center gap-3",children:[(0,r.jsx)(y.A,{className:"w-10 h-10 text-[#CC9A55] animate-spin"})," ",(0,r.jsx)("p",{className:"text-gray-600 dark:text-gray-300 text-sm",children:i("loading_vouchers")})]})});if(!s||0===s.length)return null;let o=e=>e?e.toLowerCase().startsWith("qr")?"QR"+e.slice(2):e.charAt(0).toUpperCase()+e.slice(1):e;return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)("div",{className:"space-y-4",children:[(0,r.jsxs)("div",{className:"flex items-center gap-3",children:[(0,r.jsx)(n.A,{className:"w-6 h-6 text-[#CC9A55]"}),(0,r.jsx)("h2",{className:"text-xl sm:text-2xl font-bold text-white",children:i("my_vouchers")})]}),(0,r.jsx)("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-6",children:s.map(e=>{var s,a;return(0,r.jsx)("div",{onClick:()=>c(e),className:"group relative cursor-pointer transition-all duration-300 hover:scale-[1.02]",children:(0,r.jsxs)("div",{className:"relative flex bg-white shadow-lg hover:shadow-2xl transition-shadow",style:{borderRadius:"0 12px 12px 0",overflow:"visible"},children:[(0,r.jsx)("div",{className:"absolute w-4 h-4 bg-black rounded-full",style:{left:"64px",top:"-8px",transform:"translateX(-50%)",zIndex:20}}),(0,r.jsx)("div",{className:"absolute w-4 h-4 bg-black rounded-full",style:{left:"64px",bottom:"-8px",transform:"translateX(-50%)",zIndex:20}}),(0,r.jsx)("div",{className:"relative flex-shrink-0 w-16 bg-gradient-to-br from-[#CC9A55] to-[#B88A45] flex flex-col items-center justify-center py-5 px-2",children:(0,r.jsx)("div",{className:"text-center flex-1 flex items-center justify-center",children:(0,r.jsx)("p",{className:"text-base font-extrabold text-white uppercase tracking-widest",style:{writingMode:"vertical-rl",textOrientation:"mixed"},children:"voucher"===e.type?i("voucher"):i("qr_code")})})}),(0,r.jsxs)("div",{className:"flex-1 p-5",children:[(0,r.jsxs)("div",{className:"flex items-start justify-between mb-3",children:[(0,r.jsxs)("div",{className:"flex-1 pr-3",children:[(0,r.jsx)("h3",{className:"text-lg font-bold text-gray-900 mb-1.5 line-clamp-2 group-hover:text-[#CC9A55] transition-colors leading-tight",children:o(e.title)}),(0,r.jsx)("p",{className:"text-sm text-gray-600 line-clamp-1",children:o((null==(a=e.redemption)||null==(s=a.sku)?void 0:s.description)||e.itinerary.product_title)})]}),"qr"===e.type&&e.redemption&&(0,r.jsx)("div",{className:"flex-shrink-0",children:(0,r.jsx)("span",{className:"inline-block px-3 py-1.5 bg-[#CC9A55]/15 text-[#CC9A55] border border-[#CC9A55]/40 rounded-md text-xs font-bold uppercase tracking-wide",children:"Paid"===e.redemption.status?i("confirmed"):o(e.redemption.status)})})]}),(0,r.jsxs)("div",{className:"flex flex-wrap gap-4",children:[(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[(0,r.jsx)(J.A,{className:"w-4 h-4 text-[#CC9A55] flex-shrink-0"}),(0,r.jsx)("span",{className:"text-sm text-gray-700 font-medium",children:new Date(e.itinerary.date).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})})]}),(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[(0,r.jsx)(G.A,{className:"w-4 h-4 text-[#CC9A55] flex-shrink-0"}),(0,r.jsxs)("span",{className:"text-sm text-gray-700 font-medium",children:[e.itinerary.adults," ",i("adult"),(e.itinerary.adults,""),e.itinerary.children>0&&", ".concat(e.itinerary.children," ").concat(e.itinerary.children>1?i("children"):i("child"))]})]})]})]}),(0,r.jsx)("div",{className:"absolute inset-0 border-2 border-[#CC9A55] rounded-lg opacity-0 group-hover:opacity-100 transition-opacity pointer-events-none"})]})}
1,e.voucher_id)})})]}),d&&(0,r.jsx)(ee,{voucher:d,onClose:()=>c(null)})]})};var es=a(53911);let ea=e=>e?e.charAt(0).toUpperCase()+e.slice(1):e,er=e=>{var s,a,l,i,n;let{item:d,onClick:c}=e,{t:o}=(0,B.Bd)("order"),x=(0,F.m)((null==(s=d.addon_info)?void 0:s.image)||d.image||(null==(l=d.product_images)||null==(a=l[0])?void 0:a.image)),m=ea((null==(i=d.addon_info)?void 0:i.title)||d.title);ea((null==(n=d.addon_info)?void 0:n.short_desc)||d.subtitle||o("guest_travel_support_item"));let h=d.status||d.booking_status||"",u=["confirmed","paid"].includes((h||"").toString().trim().toLowerCase()),g=h||o("confirmation_pending");return(0,r.jsx)("div",{onClick:()=>u?c(d):null,className:"group relative transition-all duration-300 ".concat(u?"cursor-pointer":"cursor-default"," md:h-[170px] h-[170px] w-full"),children:(0,r.jsxs)("div",{className:"relative flex flex-row bg-white shadow-sm ring-1 ring-black/5 rounded-2xl overflow-hidden group-hover:shadow-md transition-all h-full group-hover:scale-[1.01]",children:[(0,r.jsxs)("div",{className:"relative h-full w-[35%] sm:w-[40%] shrink-0 bg-gray-50 border-r border-gray-100 overflow-hidden",children:[x?(0,r.jsx)("img",{src:x,alt:m,className:"absolute inset-0 w-full h-full object-cover transition-all duration-500 ".concat(u?"group-hover:scale-110":"grayscale opacity-50")}):(0,r.jsx)("div",{className:"absolute inset-0 flex items-center justify-center bg-[#CC9A55]/10",children:(0,r.jsx)(es.A,{className:"w-8 h-8 text-[#CC9A55]"})}),!u&&(0,r.jsx)("div",{className:"absolute inset-0 flex items-center justify-center bg-black/20 backdrop-blur-[1px]",children:(0,r.jsx)("p",{className:"text-[10px] text-white font-black uppercase tracking-tight text-center px-1",children:g})}),(0,r.jsx)("div",{className:"absolute top-0 left-0 w-1 h-full bg-[#CC9A55]"})]}),(0,r.jsxs)("div",{className:"flex-1 p-3 sm:p-5 flex flex-col justify-between overflow-hidden",children:[(0,r.jsxs)("div",{children:[(0,r.jsxs)("div",{className:"flex items-start justify-between gap-2 mb-2",children:[(0,r.jsx)("div",{className:"flex-1 pr-3",children:(0,r.jsx)("h3",{className:"md:text-sm text-lg font-bold text-gray-900 mb-1 line-clamp-1 group-hover:text-[#CC9A55] transition-colors leading-tight",children:m})}),(0,r.jsx)("div",{className:"hidden xs:block flex-shrink-0",children:(0,r.jsx)("span",{className:"inline-block px-2 py-1 sm:px-3 sm:py-1.5 border rounded-md text-[10px] sm:text-xs font-bold uppercase tracking-wide ".concat(u?"bg-emerald-50 text-emerald-700 border-emerald-200":"bg-gray-50 text-gray-500 border-gray-200"),children:g})})]}),(0,r.jsx)("div",{children:(0,r.jsx)("span",{className:"rounded-full bg-[#f7efe3] px-2 py-0.5 text-[10px] font-bold text-[#9b6b2d] uppercase tracking-wider",children:o("service_add_on")})})]}),(0,r.jsx)("div",{className:"flex items-center justify-end mt-4",children:u?(0,r.jsxs)("button",{onClick:e=>{e.stopPropagation(),c(d)},className:"inline-flex items-center gap-1.5 text-sm font-medium text-[#CC9A55] hover:text-[#B88A45] transition-colors",children:[" ",o("view_details")," ",(0,r.jsx)(f.A,{className:"w-3.5 h-3.5"})]}):(0,r.jsx)("span",{className:"text-[10px] font-bold text-gray-400 uppercase tracking-widest italic",children:g})})]}),(0,r.jsx)("div",{className:"absolute inset-0 border-2 border-[#CC9A55] rounded-lg opacity-0 group-hover:opacity-100 transition-opacity pointer-events-none"})]})},"addon-".concat(d.id))};var el=a(27550),ei=a(88964);function en(e){var s,a;let{cityName:l,weatherInfo:i,displayDayItemsCount:d,essentialItemsCount:c,paidCount:o,unpaidCount:x}=e,{t:m}=(0,B.Bd)("order");return(0,r.jsx)("div",{className:"space-y-6",children:(0,r.jsxs)("div",{className:"rounded-[20px] bg-white p-5 md:p-7",children:[(0,r.jsxs)("div",{className:"grid gap-4 lg:grid-cols-[1fr_300px] lg:items-start",children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-sm font-bold uppercase tracking-[0.22em] text-[#CC9A55]",children:m("digital_itinerary")}),(0,r.jsx)("h1",{className:"mt-2 text-3xl font-black tracking-tight text-gray-950 md:text-4xl",children:l})," ",(0,r.jsx)("p",{className:"mt-3 max-w-2xl text-base leading-7 text-gray-600",children:m("digital_itinerary_description")})]}
1),(0,r.jsxs)("div",{className:"flex items-center gap-4 rounded-2xl border border-gray-200 bg-gray-50 p-4",children:[(0,r.jsx)("div",{className:"flex h-14 w-14 shrink-0 items-center justify-center rounded-2xl bg-[#f7efe3]",children:(0,r.jsx)(p.A,{className:"h-8 w-8 text-[#9b6b2d]"})}),(0,r.jsxs)("div",{children:[(0,r.jsxs)("p",{className:"text-3xl font-black text-gray-950",children:[(null==i||null==(s=i.weather)?void 0:s.temp_c)||30,"\xb0C"]})," ",(0,r.jsx)("p",{className:"text-xs text-gray-600",children:(null==i||null==(a=i.weather)?void 0:a.summary)||m("humid_showers_possible")})]})]})]}),(0,r.jsxs)("div",{className:"mt-5 grid grid-cols-2 gap-3 lg:grid-cols-4",children:[(0,r.jsxs)("div",{className:"flex items-center gap-2 rounded-xl border border-gray-200 bg-gray-50 p-3",children:[(0,r.jsx)(el.A,{className:"h-6 w-6 shrink-0 text-[#9b6b2d]"}),(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-2xl font-bold",children:d}),(0,r.jsx)("p",{className:"text-[10px] text-gray-600",children:m("planned_services")})]})]}),(0,r.jsxs)("div",{className:"flex items-center gap-2 rounded-xl border border-gray-200 bg-gray-50 p-3",children:[(0,r.jsx)(n.A,{className:"h-6 w-6 shrink-0 text-[#9b6b2d]"}),(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-2xl font-bold",children:c}),(0,r.jsx)("p",{className:"text-[10px] text-gray-600",children:m("essentials_ready")})]})]}),(0,r.jsxs)("div",{className:"flex items-center gap-2 rounded-xl border border-gray-200 bg-gray-50 p-3",children:[(0,r.jsx)(es.A,{className:"h-6 w-6 shrink-0 text-emerald-600"}),(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-2xl font-bold",children:o}),(0,r.jsx)("p",{className:"text-[10px] text-gray-600",children:m("confirmed_orders")})]})]}),(0,r.jsxs)("div",{className:"flex items-center gap-2 rounded-xl border border-gray-200 bg-gray-50 p-3",children:[(0,r.jsx)(ei.A,{className:"h-6 w-6 shrink-0 text-yellow-500"}),(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-2xl font-bold",children:x}),(0,r.jsx)("p",{className:"text-[10px] text-gray-600",children:m("pending_orders")})]})]})]})]})})}function ed(e){let{modalTiles:s=[],onOpen:a}=e,{t:l}=(0,B.Bd)("order");return(0,r.jsxs)("div",{className:"rounded-[20px] bg-white p-4 md:p-6 shadow-sm border border-gray-100",children:[(0,r.jsx)("div",{className:"mb-3 flex items-end justify-between",children:(0,r.jsx)("div",{children:(0,r.jsx)("p",{className:"text-[10px] font-bold uppercase tracking-[0.2em] text-[#CC9A55]",children:l("destination_guide")})})}),(0,r.jsx)("div",{className:"grid grid-cols-2 gap-2.5 lg:grid-cols-3",children:s.map(e=>{let s=e.icon;return(0,r.jsxs)("button",{onClick:()=>a(e),className:"group flex min-h-[56px] items-center justify-between rounded-2xl border border-gray-100 bg-gray-50/30 p-3 text-left transition-all hover:border-[#CC9A55]/40 hover:bg-white hover:shadow-sm active:scale-[0.98]",children:[(0,r.jsxs)("div",{className:"flex flex-col w-full",children:[(0,r.jsxs)("div",{className:"flex items-center gap-2 mb-0.5",children:[(0,r.jsx)(s,{className:"h-3.5 w-3.5 text-[#CC9A55]"}),(0,r.jsx)("h3",{className:"font-bold text-[12px] md:text-[13px] text-gray-900 truncate",children:e.title})]})," ",(0,r.jsx)("p",{className:"text-[9px] font-medium text-gray-400 uppercase tracking-tight",children:l("tap_to_explore")})]}),(0,r.jsx)(f.A,{className:"h-3.5 w-3.5 text-gray-300 transition-colors group-hover:text-[#CC9A55]"})]},e.title)})})]})}var ec=a(95112),eo=a(40049),ex=a(5723);let em=e=>{if(!e)return t("time_tba");try{let[s,a]=e.split(":"),r=parseInt(s),l=parseInt(a);return"".concat(r%12||12,":").concat(l.toString().padStart(2,"0")," ").concat(r>=12?"PM":"AM")}catch(s){return e}};function eh(e){var s;let a,{accommodation:l,availableHotelsLength:i,currentHotelIndex:n,setCurrentHotelIndex:d,hotelImages:x=[],hotelImageIndex:m,setHotelImageIndex:h,nights:u,cityName:p,onViewDetails:v}=e,{t:j}=(0,B.Bd)("order"),y=e=>e?new Date(e).toLocaleDateString("en-US",{weekday:"short",month:"short",day:"numeric"}):j("date_pending");return l?(0,r.jsxs)("section",{className:"mt-3 rounded-[24px] bg-white p-4 shadow-sm ring-1 ring-black/5 md:p-6",children:[(0,r.jsxs)("div",{className:"mb-5 flex items-center justify-between",children:[(0,r.jsx)("div",{className:"mb-5 flex items-center ",children:(0,r.jsxs)("div",{className:"flex items-center gap-3",children:[(0,r.jsx)(o.A,{className:"h-6 w-6 text-[#CC9A55]"}),(0,r.jsx)("div",{children:(0,r.jsx)("h2",{className:"text-lg md:text-2xl font-bold",children:(a=(null==l?void 0:l.hotel_name)||(null==l?void 0:l.title)||j("hotel_accommodation"))?a.charAt(0).toUpperCase()+a.slice(1):a})})]})}),i>1&&(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[(0,r.jsxs)("button",{className:"rounded-full border border-gray-200 bg-white p-2 text-gray-700 shadow-sm transition hover:bg-gray-50 disabled:opacity-30",disabled:0===n,onClick:()=>d(e=>Math.max(0,e-1)),children:[(0,r.jsx)(P.A,{className:"h-5 w-5"})," "]}),(0,r.jsxs)("span",{className:"text-xs font-bold text-gray-500",children:[n+1," / ",i]}),(0,r.jsxs)("button",{className:"rounded-full border border-gray-200 bg-white p-2 text-gray-700 shadow-sm transition hover:bg-gray-50 disabled:opacity-30",disabled:n===i-1,onClick:()=>d(e=>Math.min(i-1,e+1)),children:[(0,r.jsx)(R.A,{className:"h-5 w-5"})," "]})]})]}),(0,r.jsxs)("div",{className:"grid gap-6 lg:grid-cols-[0.95fr_1.05fr]",children:[(0,r.jsxs)("div",{className:"relative h-[250px] overflow-hidden rounded-2xl bg-gray-100",children:[(0,r.jsx)("img",{src:(0,F.m)(null==x||null==(s=x[m])?void 0:s.image),alt:(null==l?void 0:l.hotel_name)||(null==l?void 0:l.title)||"Hotel",className:"h-full w-full object-cover"}),x.length>1&&(0,r.jsx)("div",{className:"absolute bottom-4 left-1/2 flex -translate-x-1/2 gap-1.5",children:x.map((e,s)=>(0,r.jsx)("button",{onClick:()=>h(s),className:"h-1.5 rounded-full transition-all ".concat(s===m?"w-6 bg-[#CC9A55]":"w-1.5 bg-white/60")},s))})]}),(0,r.jsx)("div",{className:"flex flex-col justify-between bg-gray-50/50 p-3 md:p-4 roun
1ded-2xl border border-gray-100",children:(0,r.jsxs)("div",{className:"space-y-2",children:[(0,r.jsxs)("div",{className:"grid grid-cols-2 sm:grid-cols-3 gap-3",children:[(0,r.jsxs)("div",{className:"rounded-xl bg-white p-3 shadow-sm border border-gray-100",children:[(0,r.jsxs)("div",{className:"flex items-center gap-2 mb-1",children:[(0,r.jsx)(ec.A,{className:"h-3.5 w-3.5 text-[#CC9A55]"}),(0,r.jsx)("p",{className:"text-[10px] font-bold uppercase tracking-[0.1em] text-gray-500",children:j("check_in")})]}),(0,r.jsx)("p",{className:"mt-1 text-sm sm:text-base font-bold text-gray-900",children:y((null==l?void 0:l.checkin_date)||(null==l?void 0:l.check_in_date))}),(0,r.jsxs)("div",{className:"mt-2 flex items-center gap-1 text-xs text-gray-600",children:[(0,r.jsx)(b.A,{className:"h-3 w-3"}),em((null==l?void 0:l.checkin_time)||(null==l?void 0:l.check_in_time))]})]}),(0,r.jsxs)("div",{className:"rounded-xl bg-white p-3 shadow-sm border border-gray-100",children:[(0,r.jsxs)("div",{className:"flex items-center gap-2 mb-1",children:[(0,r.jsx)(eo.A,{className:"h-3.5 w-3.5 text-[#CC9A55]"}),(0,r.jsx)("p",{className:"text-[10px] font-bold uppercase tracking-[0.1em] text-gray-500",children:j("check_out")})]}),(0,r.jsx)("p",{className:"mt-1 text-sm sm:text-base font-bold text-gray-900",children:y((null==l?void 0:l.checkout_date)||(null==l?void 0:l.check_out_date))}),(0,r.jsxs)("div",{className:"mt-2 flex items-center gap-1 text-xs text-gray-600",children:[(0,r.jsx)(b.A,{className:"h-3 w-3"}),em((null==l?void 0:l.checkout_time)||(null==l?void 0:l.check_out_time))]})]}),(0,r.jsxs)("div",{className:"rounded-xl bg-white p-3 shadow-sm border border-gray-100",children:[(0,r.jsxs)("div",{className:"flex items-center gap-2 mb-1",children:[(0,r.jsx)(ex.A,{className:"h-3.5 w-3.5 text-[#CC9A55]"}),(0,r.jsx)("p",{className:"text-[10px] font-bold uppercase tracking-[0.1em] text-gray-500",children:j("duration")})]}),(0,r.jsxs)("p",{className:"mt-1 text-sm sm:text-base font-bold text-gray-900",children:[u," ",u>1?j("nights"):j("night")]})]}),(0,r.jsxs)("a",{href:"https://www.google.com/maps/search/?api=1&query=".concat(encodeURIComponent((null==l?void 0:l.hotel_address)||(null==l?void 0:l.hotel_name)||p)),target:"_blank",rel:"noreferrer",className:"rounded-xl bg-white p-3 shadow-sm border border-gray-100 flex flex-col justify-center transition hover:bg-gray-50 group",children:[(0,r.jsxs)("div",{className:"flex items-center justify-between mb-1.5",children:[(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[(0,r.jsx)(c.A,{className:"h-4 w-4 text-[#CC9A55]"}),(0,r.jsx)("p",{className:"text-[10px] font-bold text-gray-500 uppercase tracking-tight",children:j("location")})]}),(0,r.jsx)(f.A,{className:"h-3 w-3 text-gray-400 group-hover:text-[#CC9A55] transition"})]}),(0,r.jsx)("p",{className:"mt-1 text-sm text-gray-900 font-bold",children:j("open_in_google_maps")})]}),(0,r.jsxs)("div",{className:"col-span-2 sm:col-span-2 rounded-xl bg-white p-3 shadow-sm border border-gray-100 min-h-[80px] flex flex-col justify-center",children:[(0,r.jsxs)("div",{className:"flex items-center gap-2 mb-2",children:[(0,r.jsx)(g.A,{className:"h-4 w-4 text-[#CC9A55]"}),(0,r.jsx)("p",{className:"text-[10px] font-bold text-gray-500 uppercase tracking-tight",children:j("address")})]}),(0,r.jsx)("p",{className:"mt-1 text-sm text-gray-900 line-clamp-2 leading-relaxed",children:(null==l?void 0:l.hotel_address)||(null==l?void 0:l.address)})]})]}),!(null==l?void 0:l.is_package_tour)&&(0,r.jsxs)("button",{onClick:()=>v&&v(l),className:"ml-auto w-fit bg-[#CC9A55] text-white font-bold py-2 px-5 rounded-lg hover:bg-[#b88a45] transition-all flex items-center justify-center gap-2 shadow-sm text-sm",children:[(0,r.jsx)("span",{children:j("view_details")}),(0,r.jsx)(f.A,{className:"h-3.5 w-3.5"})]})]})})]})]}):null}var eu=a(79434);let eg=e=>{var s,a;return(0,F.m)((null==e||null==(a=e.product_images)||null==(s=a[0])?void 0:s.image)||(null==e?void 0:e.pickup_point_image)||(null==e?void 0:e.dropoff_point_image)||(null==e?void 0:e.image)||(null==e?void 0:e.cover))},ep=e=>2===e?1:3===e||1===e||8===e?2:4===e?3:11===e?4:5,ef=e=>{let{items:s=[]}=e;return(0,r.jsx)("div",{className:"grid gap-3 md:grid-cols-2",children:s.map((e,s)=>(0,r.jsxs)("figure",{className:"overflow-hidden rounded-xl border border-gray-200 bg-white",children:["video"===e.type?(0,r.jsx)("video",{className:"h-44 w-full bg-gray-100 object-cover",controls:!0,poster:e.poster,preload:"metadata",children:(0,r.jsx)("source",{src:e.src,type:"video/mp4"})}):(0,r.jsx)("img",{src:e.src,alt:e.caption,className:"h-44 w-full object-cover"}),(0,r.jsx)("figcaption",{className:"px-3 py-2 text-sm font-medium text-gray-700",children:e.caption})]},"".concat(e.src,"-").concat(s)))})},eb=e=>{let{active:s,onClose:a}=e;return s?(0,r.jsx)("div",{className:"fixed inset-0 z-[70] flex items-end justify-center bg-black/40 backdrop-blur-sm px-4 py-2 sm:items-center animate-in fade-in duration-300",children:(0,r.jsxs)("div",{className:"w-full max-w-lg rounded-[28px] bg-white shadow-2xl animate-in zoom-in-95 slide-in-from-bottom-8 duration-500",children:[(0,r.jsxs)("div",{className:"flex items-center justify-between border-b border-gray-50 p-3 md:p-4",children:[(0,r.jsxs)("div",{className:"flex items-center gap-3",children:[(0,r.jsx)("div",{className:"flex h-10 w-10 items-center justify-center rounded-xl bg-[#fcf8f1]",children:(0,r.jsx)(s.icon,{className:"h-5 w-5 text-[#CC9A55]"})}),(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-[10px] font-bold uppercase tracking-[0.15em] text-[#CC9A55]",children:s.guideL
1abel}),(0,r.jsx)("h3",{className:"text-lg font-bold text-gray-950 leading-none",children:s.title})]})]}),(0,r.jsx)("button",{onClick:a,className:"group rounded-full p-2 transition-all hover:bg-gray-100 active:scale-90",children:(0,r.jsx)(u.A,{className:"h-5 w-5 text-gray-400 transition-colors group-hover:text-gray-900"})})]}),(0,r.jsx)("div",{className:"max-h-[60vh] overflow-y-auto p-5 md:p-6 text-gray-700 scrollbar-hide",children:s.content})]})}):null};var ev=!0;let ej=()=>{var e,s,a,u,M;let{t:O}=(0,B.Bd)("order","common"),D=e=>e?new Date(e).toLocaleDateString("en-US",{weekday:"short",month:"short",day:"numeric"}):O("date_pending"),P=e=>1===e?O("category_attraction"):2===e?O("category_transfer"):3===e?O("category_day_tour"):4===e?O("category_hotel"):11===e?O("category_add_on"):8===e?O("category_package_tour"):O("category_service"),R=e=>e?e.charAt(0).toUpperCase()+e.slice(1):e,F=(0,i.useRouter)(),{upcomingBookings:T,pastBookings:U,loading:J,error:G,fetchUpcomingBookings:H,fetchPastBookings:W,clearError:X,weatherInfo:Z,fetchWeatherInfo:K,accommodations:Q}=(0,S.x)(),{vouchers:Y,loading:$,fetchVouchers:ee}=(0,z.Z)(),{token:es,user:ea,qrCode:el}=(0,E.A)(),[ei,ec]=(0,l.useState)(0),[eo,ex]=(0,l.useState)(6),[em,ev]=(0,l.useState)(0),[ej,ey]=(0,l.useState)(null),[eN,ew]=(0,l.useState)(null),[e_,ek]=(0,l.useState)(null);(0,l.useEffect)(()=>{es&&(H(es),W(es),K(null==ea?void 0:ea.id),(null==ea?void 0:ea.access_token)&&ee(ea.access_token))},[H,W,K,ee,es,el,null==ea?void 0:ea.access_token]);let eC=(0,l.useMemo)(()=>(T||[]).flatMap(e=>(e.itineraries||[]).map(s=>({...s,order_id:e.order_id,booking_status:s.booking_status||e.booking_status}))),[T]),eA=(0,l.useMemo)(()=>(U||[]).flatMap(e=>(e.itineraries||[]).map(s=>({...s,order_id:e.order_id,tour_date:s.date||s.tour_date||e.tour_date,booking_status:e.booking_status}))),[U]),eS=(0,l.useMemo)(()=>{let e=eC.find(e=>11!==e.category_id&&4!==e.category_id);return(null==e?void 0:e.itinerary_id)||(null==e?void 0:e.id)},[eC]),eE=eC.filter(e=>11===e.category_id),eI=eC.filter(e=>11!==e.category_id&&4!==e.category_id),eL=(0,l.useMemo)(()=>(null==Q?void 0:Q.length)>0?Q:eC.filter(e=>4===e.category_id),[Q,eC]),eB=eL[ei]||null,ez=(0,l.useMemo)(()=>{var e;return eB?((null==eB||null==(e=eB.pictures)?void 0:e.length)>0?eB.pictures:(null==eB?void 0:eB.product_images)||[]).map(e=>({...e,image:e.image||e.name})):[]},[eB]);(0,l.useEffect)(()=>{ei>=eL.length&&ec(0)},[eL.length,ei]),(0,l.useEffect)(()=>{ev(0)},[ei]),(0,l.useEffect)(()=>{if(ez.length<=1)return;let e=setInterval(()=>{ev(e=>(e+1)%ez.length)},5e3);return()=>clearInterval(e)},[ez.length]);let eM=(0,l.useMemo)(()=>T.filter(e=>"Confirmed"===e.booking_status).length,[T]),eO=(0,l.useMemo)(()=>T.filter(e=>"Confirmed"!==e.booking_status).length,[T]),eD=function(e,s){if(!e||!s)return null;let a=new Date(s)-new Date(e);return Number.isNaN(a)?null:Math.max(1,Math.ceil(a/864e5))}((null==eB?void 0:eB.checkin_date)||(null==eB?void 0:eB.check_in_date),(null==eB?void 0:eB.checkout_date)||(null==eB?void 0:eB.check_out_date)),eP=(null==Z?void 0:Z.city)||(null==(e=eL[0])?void 0:e.city_name)||O("your_destination"),eR=Y||[],eF=[...eE.map(e=>({kind:"addon",item:e})),...eR.map(e=>({kind:"voucher",item:e}))],eT=[...eI,...eE].sort((e,s)=>{let a=new Date(e.date||e.tour_date||e.checkin_date||"2999-12-31").getTime(),r=new Date(s.date||s.tour_date||s.checkin_date||"2999-12-31").getTime();return a!==r?a-r:ep(e.category_id)-ep(s.category_id)}).slice(0,5),eU=(0,l.useMemo)(()=>[{name:"Accommodation",value:eL.length,color:"#111827"},{name:"Transfers",value:eI.filter(e=>2===e.category_id).length,color:"#CC9A55"},{name:"Add-ons",value:eE.length,color:"#d8d1c7"},{name:"Vouchers",value:eR.length,color:"#6b7280"},{name:"Day tours",value:eI.filter(e=>3===e.category_id||8===e.category_id).length,color:"#8b6f47"},{name:"Attractions",value:eI.filter(e=>1===e.category_id).length,color:"#b7a58b"}].filter(e=>e.value>0),[eL.length,eI,eE.length,eR.length]),eq=eU.reduce((e,s)=>e+s.value,0),eV=e=>{let s=e.itinerary_id||e.id;if(!s)return;ek(s);let a=(0,eu.b)(s);a.success&&F.push("/order/detail/".concat(a.data))},eJ=[{src:"".concat("https://smartdestinations-media.s3.ap-southeast-1.amazonaws.com/","External+Links/NS19_Toa_Payoh_MRT_Exit_D_20220712_192031.jpg"),caption:O("mrt_station_entrance")},{src:"".concat("https://smartdestinations-media.s3.ap-southeast-1.amazonaws.com/","External+Links/Bombardier-9thO
1ct.avif"),caption:O("mrt_train")}],eG=[{title:O("about_singapore"),guideLabel:O("destination_guide"),icon:g.A,content:(0,r.jsxs)("div",{className:"space-y-6",children:[(0,r.jsx)("div",{className:"overflow-hidden rounded-3xl border border-gray-200 bg-black",children:(0,r.jsx)("iframe",{className:"w-full aspect-[16/9]",src:"https://www.youtube.com/embed/2sA4dLPvKFs?rel=0&autoplay=1&mute=1",title:"Singapore Travel Guide",allow:"autoplay; fullscreen; encrypted-media; picture-in-picture; web-share",allowFullScreen:!0})}),(0,r.jsx)("div",{className:"space-y-4",children:(0,r.jsx)("p",{className:"leading-7 text-gray-700",children:O("about_singapore_description")})}),(0,r.jsxs)("div",{className:"grid gap-4 md:grid-cols-2",children:[(0,r.jsxs)("div",{className:"rounded-3xl border border-gray-200 bg-gray-50 p-4",children:[" ",(0,r.jsx)("h4",{className:"font-semibold text-gray-950",children:O("marina_bay_sands")}),(0,r.jsx)("p",{className:"text-sm text-gray-600 mt-2",children:O("marina_bay_sands_description")})]}),(0,r.jsxs)("div",{className:"rounded-3xl border border-gray-200 bg-gray-50 p-4",children:[" ",(0,r.jsx)("h4",{className:"font-semibold text-gray-950",children:O("gardens_by_the_bay")}),(0,r.jsx)("p",{className:"text-sm text-gray-600 mt-2",children:O("gardens_by_the_bay_description")})]}),(0,r.jsxs)("div",{className:"rounded-3xl border border-gray-200 bg-gray-50 p-4",children:[" ",(0,r.jsx)("h4",{className:"font-semibold text-gray-950",children:O("orchard_road")}),(0,r.jsx)("p",{className:"text-sm text-gray-600 mt-2",children:O("orchard_road_description")})]}),(0,r.jsxs)("div",{className:"rounded-3xl border border-gray-200 bg-gray-50 p-4",children:[" ",(0,r.jsx)("h4",{className:"font-semibold text-gray-950",children:O("sentosa_island")}),(0,r.jsx)("p",{className:"text-sm text-gray-600 mt-2",children:O("sentosa_island_description")})]})]})]})},{title:O("weather"),guideLabel:O("destination_guide"),icon:p.A,content:(0,r.jsxs)("div",{className:"space-y-3",children:[(0,r.jsxs)("div",{className:"flex items-center gap-4",children:[(null==Z||null==(s=Z.weather)?void 0:s.icon)&&(0,r.jsx)("img",{src:Z.weather.icon,alt:(null==Z||null==(a=Z.weather)?void 0:a.summary)||O("weather"),className:"h-14 w-14"}),(0,r.jsxs)("p",{className:"text-4xl font-bold text-gray-950",children:[(null==Z||null==(u=Z.weather)?void 0:u.temp_c)||30," \xb0C"]})]}),(0,r.jsx)("p",{children:(null==Z||null==(M=Z.weather)?void 0:M.summary)||O("weather_summary_default")})]})},{title:O("public_transport"),guideLabel:O("destination_guide"),icon:d.A,content:(0,r.jsxs)("div",{className:"space-y-6",children:[(0,r.jsxs)("div",{className:"space-y-4",children:[(0,r.jsx)("p",{className:"leading-7 text-gray-700",children:O("public_transport_description")}),(0,r.jsxs)("a",{href:"https://mrtmapsingapore.com/",target:"_blank",rel:"noreferrer noopener",className:"inline-flex items-center gap-2 rounded-full border border-[#CC9A55] bg-[#FFF7E5] px-4 py-2 text-sm font-semibold text-[#7A4A14] transition hover:bg-[#F7E3C0]",children:[(0,r.jsx)(f.A,{className:"h-4 w-4"}),O("view_mrt_map_routes")]})]}),(0,r.jsx)(ef,{items:eJ}),(0,r.jsxs)("div",{className:"grid gap-4",children:[(0,r.jsxs)("div",{className:"rounded-3xl border border-gray-200 bg-gray-50 p-4",children:[(0,r.jsx)("h4",{className:"font-semibold text-gray-950",children:O("mrt_basics")}),(0,r.jsx)("p",{className:"text-sm text-gray-600 mt-2",children:O("mrt_basics_description")})]}),(0,r.jsxs)("div",{className:"rounded-3xl border border-gray-200 bg-gray-50 p-4",children:[(0,r.jsx)("h4",{className:"font-semibold text-gray-950",children:O("how_to_pay")}),(0,r.jsx)("p",{className:"text-sm text-gray-600 mt-2",children:O("how_to_pay_description")})]}),(0,r.jsxs)("div",{className:"rounded-3xl border border-gray-200 bg-gray-50 p-4",children:[(0,r.jsx)("h4",{className:"font-semibold text-gray-950",children:O("esim_for_visitors")}),(0,r.jsx)("p",{className:"text-sm text-gray-600 mt-2",children:O("esim_for_visitors_description")}),(0,r.jsxs)("div",{className:"flex jusitfy-between",children:[(0,r.jsx)("p",{className:"text-sm text-[#7A4A14] mt-2",children:O("recommended_provider")}),(0,r.jsx)("a",{href:"https://www.airalo.com/",target:"_blank",rel:"noreferrer noopener",className:"text-sm font-semibold text-[#CC9A55] underline",children:"airalo.com"})]})]})]})]})}
1,{title:O("tour_overview"),guideLabel:O("destination_guide"),icon:h.A,content:(0,r.jsx)("div",{className:"relative space-y-2 before:absolute before:left-[19px] before:top-2 before:h-[calc(100%-20px)] before:w-[1px] before:bg-gray-100",children:eT.map((e,s)=>{var a;let l=(e=>1===e?n.A:2===e?d.A:3===e?c.A:4===e?o.A:11===e?x.A:8===e?m.A:h.A)(e.category_id);return(0,r.jsxs)("div",{className:"relative flex gap-4 pl-0",children:[(0,r.jsx)("div",{className:"relative z-10 flex h-10 w-10 shrink-0 items-center justify-center rounded-full border-[3px] border-white bg-gray-950 shadow-sm",children:(0,r.jsx)(l,{className:"h-3.5 w-3.5 text-white"})}),(0,r.jsxs)("div",{className:"flex-1 rounded-2xl border border-gray-50 bg-gray-50/40 p-3.5 transition-all hover:bg-white hover:shadow-sm",children:[(0,r.jsxs)("div",{className:"flex items-center justify-between mb-0.5",children:[(0,r.jsx)("p",{className:"text-[9px] font-black uppercase tracking-widest text-[#CC9A55]",children:P(e.category_id)}),(e.date||e.tour_date)&&(0,r.jsx)("p",{className:"text-[10px] font-bold text-gray-400",children:D(e.date||e.tour_date)})]})," ",(0,r.jsx)("h4",{className:"text-[13px] font-bold text-gray-900 leading-snug",children:e.title||(null==(a=e.addon_info)?void 0:a.title)||e.hotel_name||O("booked_service")}),e.pickup_time&&(0,r.jsxs)("div",{className:"mt-1.5 flex items-center gap-1 text-[11px] font-medium text-gray-500",children:[(0,r.jsx)(b.A,{className:"h-3 w-3"}),(0,r.jsx)("span",{children:e.pickup_time})]})]})]},"".concat(e.id,"-").concat(s))})})},{title:O("tour_statistics"),guideLabel:O("destination_guide"),icon:v.A,content:(0,r.jsxs)("div",{className:"grid gap-6 md:grid-cols-[200px_1fr] items-start",children:[(0,r.jsxs)("div",{className:"relative h-44 w-44 mx-auto md:mx-0",children:[(0,r.jsx)(_.u,{width:"100%",height:"100%",children:(0,r.jsx)(k.r,{children:(0,r.jsx)(C.F,{data:eU,dataKey:"value",innerRadius:38,outerRadius:68,paddingAngle:4,stroke:"none",children:eU.map(e=>(0,r.jsx)(A.f,{fill:e.color},e.name))})})}),(0,r.jsxs)("div",{className:"absolute inset-0 flex flex-col items-center justify-center",children:[(0,r.jsx)("p",{className:"text-2xl font-extrabold text-gray-950",children:eq})," ",(0,r.jsx)("p",{className:"text-[11px] font-semibold uppercase tracking-[0.12em] text-gray-500",children:O("items")})]})]}),(0,r.jsx)("div",{className:"space-y-3",children:eU.map(e=>{let s=eq?Math.round(e.value/eq*100):0;return(0,r.jsxs)("div",{className:"rounded-xl border border-gray-100 bg-gray-50 p-3",children:[(0,r.jsxs)("div",{className:"flex items-center justify-between mb-2",children:[(0,r.jsxs)("div",{className:"flex items-center gap-3",children:[(0,r.jsx)("span",{className:"h-3 w-3 rounded-full",style:{backgroundColor:e.color}}),(0,r.jsx)("p",{className:"text-sm font-semibold text-gray-700",children:e.name})]})," ",(0,r.jsxs)("p",{className:"text-sm font-bold text-gray-900",children:[e.value," ",(0,r.jsxs)("span",{className:"text-xs text-gray-500",children:["(",s,"%)"]})]})]}),(0,r.jsx)("div",{className:"h-2 w-full rounded-full bg-gray-200",children:(0,r.jsx)("div",{className:"h-2 rounded-full",style:{width:"".concat(s,"%"),backgroundColor:e.color}})})]},e.name)})})]})},{title:O("customer_reviews"),guideLabel:O("destination_guide"),icon:j.A,content:(0,r.jsx)("div",{className:"w-full",children:eA.length>0?(0,r.jsx)("div",{className:"grid grid-cols-1 gap-3",children:eA.map((e,s)=>{var a;let l=eN==="".concat(e.id,"-").concat(s);return(0,r.jsxs)("div",{className:"flex items-center gap-3 rounded-2xl border border-gray-100 bg-gray-50/50 p-3 transition-all hover:bg-white hover:shadow-md",children:[(0,r.jsx)("div",{className:"h-14 w-14 shrink-0 overflow-hidden rounded-xl bg-gray-200",children:(0,r.jsx)("img",{src:eg(e)||"/placeholder.svg",alt:e.title||e.hotel_name,className:"h-full w-full object-cover"})}),(0,r.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,r.jsx)("h4",{className:"text-[13px] font-bold text-gray-900 truncate",children:R(e.title||(null==(a=e.addon_info)?void 0:a.title)||e.hotel_name||O("booked_service"))}),(0,r.jsxs)("div",{className:"mt-1 flex items-center gap-1.5 text-[11px] font-medium text-gray-500",children:[(0,r.jsx)(h.A,{className:"h-3 w-3 text-gray-400"}),(0,r.jsx)("span",{children:D(e.tour_date)})]})]}),(0,r.jsx)("button",{onClick:()=>{ew("".concat(e.id,"-").concat(s)),F.push("/review/".concat(el,"/").concat(e.id||e.itinerary_id))},disabled:l,className:"shrink-0 rounded-lg bg-[#CC9A55] px-3.5 py-1.5 text-[11px] font-bold text-white transition-all hover:bg-[#B88A45] active:scale-95 shadow-sm min-w-[65px] flex items-center justify-center disabled:opacity-70",children:l?(0,r.jsx)(y.A,{className:"h-3 w-3 animate-spin"}):O("review")})]},"".concat(e.id,"-").concat(s))})}):(0,r.jsxs)("div",{className:"text-center py-12",children:[(0,r.jsx)("div",{className:"mx-auto flex h-16 w-16 items-center justify-center rounded-2xl bg-gray-50",children:(0,r.jsx)(N.A,{className:"h-8 w-8 text-gray-200"})}),(0,r.jsx)("p",{className:"mt-4 text-sm font-medium text-gray-400 italic",children:O("no_past_trips_for_review")})]})})}];return J||$?(0,r.jsx)("div",{className:"min-h-screen bg-black flex items-center justify-center",children:(0,r.jsx)(L.A,{})}):(0,r.jsx)(I.A,{children:(0,r.jsxs)("div",{className:"min-h-screen pt-6 md:pt-12 bg-black",children:[(0,r.jsx)("button",{onClick:()=>F.push("/chat"),className:"fixed bottom-6 right-6 z-50 rounded-full bg-[#CC9A55] p-4 text-white shadow-xl transition-transform duration-300 hover:scale-105","aria-label":O("chat_with_ai"),children:(0,r.jsx)(w.A,{})}),(0,r.jsxs)("div",{className:"mx-auto max-w-7xl px-4 py-8 pt-12 sm:px-6 lg:px-8",children:[G&&(0,r.jsxs)("div",{className:"mb-4 flex items-center justify-between rounded-xl border border-red-200 bg-red-50 px-4 py-3 text-red-700",children:[(0,r.jsx)("span",{children:G}),(0,r.jsx)("button",{onClick:X,className:"font-semibold underline",children:O("dismiss")})]}),(0,r.jsx)("section",{className:"overflow-hidden rounded-[28px] shadow-2xl ",children:(0,r.jsxs)("div",{className:"space-y-6",children:[(0,r.jsx)(en,{cityName:eP,weatherInfo:Z,displayDayItemsCount:eI.length,essentialItemsCount:eF.length,paidCount:eM,unpaidCount:eO}),(0,r.jsx)(ed,{modalTiles:eG,onOpen:e=>ey(e.title)})]})}),eB&&(0,r.jsx)(eh,{accommodation:eB,availableHotelsLength:eL.length,currentHotelIndex:ei,setCurrentHotelIndex:ec,hotelImages:ez,hotelImageIndex:em,setHotelImageIndex:ev,nights:eD,cityName:eP,onViewDetails:eV}),(Y.length>0||eE.length>0)&&(0,r.jsx)("section",{className:"mt-8",children:(0,r.jsx)("div",{className:"rounded-[24px] bg-black text-white ",children:(0,r.jsxs)("div",{className:"space-y-3",children:[Y.length>0&&(0,r.jsx)(et,{vouchers:Y,loading:$}),eE.length>0&&(0,r.jsxs)("div",{className:"mt-8 space-y-4",children:[(0,r.jsxs)("div",{className:"flex items-center gap-3",children:[(0,r.jsx)(x.A,{className:"w-6 h-6 text-[#CC9A55]"}),(0,r.jsxs)("h2",{className:"text-xl sm:text-2xl font-bold ",children:[" ",O("extra_services")]})]}),(0,r.jsx)("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-6",children:eE.map(e=>(0,r.jsx)(er,{item:e,onClick:eV},e.id))})]})]})})}),eI.length>0&&(0,r.jsxs)("section",{className:"mt-8 pb-10",children:[(0,r.jsxs)("div",{className:"mb-4 flex items-center gap-3",children:[(0,r.jsx)(h.A,{className:"h-6 w-6 text-[#CC9A55]"}),(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-sm font-bold uppercase tracking-[0.18em] text-[#CC9A55]",children:O("day_by_day_itinerary")}),(0,r.jsx)("h2",{className:"text-xl md:text-3xl text-white font-bold",children:O("upcoming_trip_flow")})]})]}),(0,r.jsx)("div",{className:"grid grid-cols-1 gap-6 lg:grid-cols-2",children:eI.map((e,s)=>(0,r.jsx)("article",{className:"group flex flex-row overflow-hidden rounded-2xl bg-white shadow-sm ring-1 ring-black/5 transition-all duration-300 hover:scale-[1.01] hover:shadow-xl md:h-[170px] h-[170px]",children:(()=>{let s=String(e.status||e.booking_status||"").trim(),a=["confirmed","paid"].includes(s.toLowerCase()),l=s||O("confirmation_pending");return eg(e),(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)("div",{onClick:()=>a?eV(e):null,className:"relative h-full w-[35%] sm:w-[40%] shrink-0 bg-gray-100 overflow-hidden ".concat(a?"cursor-pointer":"cursor-default"),children:[(0,r.jsx)("img",{src:eg(e),alt:e.title||e.hotel_name||"Booked service",className:"h-full w-full object-cover transition-transform duration-500 ".concat(a?"group-hover:scale-110":"grayscale-[0.5] opacity-80")}),!a&&(0,r.jsx)("div",{className:"absolute inset-0 bg-black/40 flex items-center justify-center backdrop-blur-[1px]",children:(0,r.jsx)("p",{className:"text-white text-[10px] font-black uppercase tracking-[0.2em] border border-white/30 px-2 py-1 rounded bg-black/20",children:l})}),(0,r.jsx)("div",{className:"absolute inset-0 bg-gradient-to-t from-black/30 to-transparent sm:hidden"})]}),(0,r.jsxs)("div",{className:"flex flex-1 flex-col",children:[(0,r.jsx)("div",{className:"flex items-center text-gray-950 p-2 bg-[#fdf8f0] border-b border-[#f7efe3]",children:(0,r.jsxs)("div",{className:"flex flex-wrap items-center gap-3",children:[(0,r.jsxs)("div",{className:"flex items-center gap-1.5",children:[(0,r.jsx)(h.A,{className:"h-4 w-4 text-[#CC9A55]"}),(0,r.jsx)("span",{className:"text-xs font-bold md:text-sm text-gray-800",children:D(e.date||e.tour_date)})]}),e.pickup_time&&(0,r.jsxs)("div",{className:"flex items-center gap-1.5 border-l border-gray-300 pl-3",children:[(0,r.jsx)(b.A,{className:"h-4 w-4 text-[#CC9A55]"}),(0,r.jsx)("span",{className:"text-xs font-bold md:text-sm text-gray-800",children:e.pickup_time})]})]})}),(0,r.jsxs)("div",{className:"flex flex-1 flex-col justify-between p-3 overflow-hidden",children:[(0,r.jsxs)("div",{className:"min-w-0",children:[(0,r.jsx)("h3",{className:"line-clamp-1 md:text-sm text-lg font-semibold text-gray-900 group-hover:text-[#CC9A55] transition-colors",children:R(e.title||e.hotel_name||"Booked service")}),(0,r.jsxs)("div",{className:"mt-2 flex flex-wrap items-center gap-2",children:[(0,r.jsx)("span",{className:"rounded-full bg-[#f7efe3] px-2 py-0.5 text-[10px] font-bold text-[#9b6b2d]",children:P(e.category_id)}),(0,r.jsx)("span",{className:"rounded-full bg-emerald-50 px-2 py-0.5 text-[10px] font-bold text-emerald-700 border border-emerald-100",children:l})]})]}),(0,r.jsxs)("div",{className:"mt-auto pt-4 flex items-center justify-between",children:[(0,r.jsx)("div",{})," ",a?(0,r.jsxs)("button",{onClick:()=>eV(e),disabled:e_===(e.itinerary_id||e.id),className:"flex items-center justify-center rounded-lg bg-gray-950 px-4 py-2 text-xs font-bold text-white transition hover:bg-[#CC9A55] disabled:opacity-70",children:[e_===(e.itinerary_id||e.id)?(0,r.jsx)(y.A,{className:"h-3.5 w-3.5 animate-spin mr-2"}):null,(0,r.jsx)("span",{children:O("view_detail")}),e_!==(e.itinerary_id||e.id)&&(0,r.jsx)(f.A,{className:"h-3.5 w-3.5 ml-2"})]}):(0,r.jsx)("p",{className:"text-[10px] font-bold text-red-500/80 uppercase ",children:O("order_unconfirmed")})]})]})]})]})})()},e.id))})]}),eS&&(0,r.jsx)("div",{className:"mb-8",children:(0,r.jsx)(q,{itineraryId:eS})}),(0,r.jsx)("div",{className:"mb-8",children:(0,r.jsx)(V.A,{})})]}),(0,r.jsx)(eb,{active:eG.find(e=>e.title===ej),onClose:()=>{ey(null),ex(6)}})]})})}}},e=>{e.O(0,[6989,9221,5919,9877,636,6593,8792],()=>e(e.s=43619)),_N_E=e.O()}]);

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.