(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[465],{2113:(e,t,i)=>{"use strict";i.d(t,{O:()=>o,u:()=>n});var l=i(45704),s=i(66724);let a=(0,s.createContext)(void 0),r="cookie_consent_status",o=e=>{let{children:t}=e,[i,o]=(0,s.useState)("pending");(0,s.useEffect)(()=>{let e=function(e){let t=e+"=",i=document.cookie.split(";");for(let e=0;e{!function(e,t,i){let l="";{let e=new Date;e.setTime(e.getTime()+31536e6),l="; expires="+e.toUTCString()}document.cookie=e+"="+(t||"")+l+"; path=/; SameSite=Lax; Secure"}(r,e,365),o(e)},[]),c=(0,s.useCallback)(()=>{n("1")},[n]),d=(0,s.useCallback)(()=>{n("0")},[n]);return(0,l.jsx)(a.Provider,{value:{consentStatus:i,acceptConsent:c,rejectConsent:d},children:t})},n=()=>{let e=(0,s.useContext)(a);if(void 0===e)throw Error("useCookieConsent must be used within a CookieConsentProvider");return e}},8426:(e,t,i)=>{"use strict";i.d(t,{A:()=>l});let l=(0,i(68148).A)("arrow-right",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]])},11481:(e,t,i)=>{"use strict";i.d(t,{default:()=>c});var l=i(45704),s=i(54173),a=i(11878),r=i(24293),o=i(64704),n=i(66724);function c(){let e=(0,s.c3)(),t=(0,o.n)(e=>e.openLogin),i=(0,o.n)(e=>e.isAuthenticated),[c,d]=(0,n.useState)(!1);(0,n.useEffect)(()=>{d(!0)},[]);let m=[{title:e("home.section_2.specialty"),image:"/images/home/overview-specialty.png",slug:"/patient/specialty"},{title:e("home.section_2.doctor"),image:"/images/home/overview-doctor.png",slug:"/patient/doctor"},{title:e("home.section_2.calendar"),image:"/images/home/overview-calendar.png",slug:"/patient/health-appointment"},{title:e("home.section_2.booking"),image:"/images/home/overview-booking.png",slug:"/patient/checkout"},{title:e("home.section_2.service"),image:"/images/home/overview-service.png",slug:"/patient/service"},{title:e("home.section_2.support"),image:"/images/home/overview-support.png",slug:"/patient/customer-knowledge"}];return(0,l.jsx)("section",{className:"bg-linear-overview xl:pt-16 md:pt-12 pt-8 xl:pb-[120px] md:pb-20 pb-[72px]",children:(0,l.jsxs)("div",{className:"container",children:[(0,l.jsx)("h2",{className:"display-4 text-primary-600 text-center mb-3",children:e("home.section_2.title")}),(0,l.jsx)("div",{className:"grid grid-cols-12 xl:gap-x-8 md:gap-x-[22px]",children:(0,l.jsx)("div",{className:"xl:col-span-full col-span-full xl:col-start-1 rounded-2xl bg-gray-50 p-4 overview-wrapper-shadow grid xl:grid-cols-6 md:grid-cols-3 grid-cols-2 xl:gap-8 md:gap-6 gap-4",children:m.map((e,s)=>{let o="/patient/checkout"===e.slug,n=(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)("div",{className:"size-[74px] mb-[18px] rounded-full overflow-hidden bg-primary-50 relative flex items-center justify-center",children:(0,l.jsx)(a.p,{src:e.image,alt:e.title,width:74,height:74,objectFit:"contain"})}),(0,l.jsx)("div",{className:"title-2 text-primary-900 lg:group-hover:text-white lg:duration-150 text-center",children:e.title}),s{e.stopPropagation(),t("/patient/checkout")},children:n},"overview-".concat(s)):(0,l.jsx)(r.N_,{href:{pathname:e.slug},className:"p-4 flex items-center flex-col rounded-lg relative max-lg:bg-white lg:hover:bg-primary-400 lg:duration-150 cursor-pointer group",children:n},"overview-".concat(s))})})})]})})}},14762:(e,t,i)=>{"use strict";i.d(t,{A:()=>l});let l=(0,i(68148).A)("chevron-down",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]])},18267:(e,t,i)=>{"use strict";i.d(t,{default:()=>a});var l=i(7283),s=i(45704);function a(e){let{locale:t,...i}=e;if(!t)throw Error(void 0);return(0,s.jsx)(l.Dk,{locale:t,...i})}},25020:(e,t,i)=>{"use strict";i.d(t,{HealthcareServices:()=>c});var l=i(45704),s=i(66724),a=i(11878),r=i(25308),o=i(54173),n=i(18250);function c(e){var t,i,c,d,m;let{items:h,cards:p,title:u,description:x}=e,g=(0,o.c3)(),[v,b]=(0,s.useState)(0),y=e=>{b(e)};return(0,l.jsxs)("section",{className:"relative text-white xl:pt-16 md:pt-12 pt-8 xl:pb-[64px] md:pb-20 pb-[48px] rounded-t-[32px] overflow-hidden translate-y-[-29px] bg-white",children:[(0,l.jsxs)("div",{className:"container relative z-20",children:[(0,l.jsx)(r.default,{once:!0,children:(0,l.jsx)("h2",{className:"display-4 text-white text-center mb-3",children:u})}),x&&(0,l.jsx)(r.default,{once:!0,children:(0,l.jsx)("p",{className:"body-2 text-white text-center xl:mb-[36px] md:mb-12 mb-8",children:x})}),p.length>0&&(0,l.jsx)(r.default,{once:!0,children:(0,l.jsx)("div",{className:"grid md:grid-cols-3 grid-cols-1 gap-x-6 max-md:gap-y-2 xl:mb-[36px] md:mb-12 mb-4",children:null==p?void 0:p.map((e,t)=>(0,l.jsxs)("div",{className:"rounded-t-lg xl:p-8 lg:p-6 p-4 bg-primary-75 space-y-1.5 border-b-[6px] border-primary-600",children:[(0,l.jsx)("div",{className:"display-2 max-md:!text-[36px] text-primary-600",children:null==e?void 0:e.title}),(null==e?void 0:e.content)&&(0,l.jsx)("div",{className:"label-1 max-md:!text-[14px] text-black",children:null==e?void 0:e.content})]},"value-".concat(t)))})}),h.length>0&&(0,l.jsx)(r.default,{once:!0,children:(0,l.jsxs)("div",{className:"flex max-lg:flex-col lg:space-x-16 py-[26px] lg:pl-[46px] pl-[25px] pr-[25px] bg-white rounded-lg xl:mb-12 md:mb-10 mb-8",children:[(0,l.jsx)("div",{className:"md:space-y-6 space-y-3.5 lg:pt-[23px] lg:w-[419px]",children:h.map((e,t)=>{var i,s;return(0,l.jsxs)("div",{className:"relative lg:pt-1.5 first:pt-0 transition-all space-y-3 ".concat("pb-3.5"),children:[(0,l.jsx)("div",{className:" text-primary-600 cursor-pointer ".concat(t===v?"heading-2":"body-1"),onClick:()=>y(t),children:e.title}),t===v&&(0,l.jsx)("div",{className:"text-black body-2",dangerouslySetInnerHTML:{__html:(0,n.p)(e.content||"")}}),t===v&&(0,l.jsx)("div",{className:"relative lg:hidden aspect-[646/481] rounded overflow-hidden",children:(0,l.jsx)(a.p,{src:(null===(i=e.image)||void 0===i?void 0:i.absolute_url)||"/cover.jpg",alt:(null===(s=e.image)||void 0===s?void 0:s.alt)||e.title,fill:!0,className:"transition-opacity duration-300",objectFit:"cover"})}),t===v&&(0,l.jsx)("a",{href:e.link,target:e.target,rel:"noopener noreferrer nofollow",className:"label-2 text-primary-600 hover:text-primary-400 underline underline-offset-2",children:g("button.know_more")}),(0,l.jsx)("div",{className:"absolute bottom-0 left-0 h-0.5 transition-all duration-300 z-[1] bg-linear-healthcare !mb-0 ".concat(t===v?"w-full":"w-0")}),(0,l.jsx)("div",{className:"absolute bottom-0 left-0 h-0.5 w-full transition-all duration-300 bg-gray-100"})]},"service-".concat(t))})}),(0,l.jsx)("div",{className:"relative h-[500px] rounded-lg overflow-hidden flex-1 max-lg:hidden",children:(0,l.jsx)(a.p,{src:(null===(i=h[v])||void 0===i?void 0:null===(t=i.image)||void 0===t?void 0:t.absolute_url)||"/cover.jpg",alt:(null===(d=h[v])||void 0===d?void 0:null===(c=d.image)||void 0===c?void 0:c.alt)||(null===(m=h[v])||void 0===m?void 0:m.title)||"",fill:!0,className:"object-cover transition-opacity duration-300"})})]})})]}),(0,l.jsx)("div",{className:"absolute inset-0 z-10 bg-primary-600 opacity-60"}),(0,l.jsx)("div",{className:"absolute inset-0 z-10 bg-linear-container-healthcare opacity-80"}),(0,l.jsx)("div",{className:"absolute inset-0",children:(0,l.jsx)(a.p,{src:"/images/home/health-care-bg.jpg",fill:!0,alt:"health care background"})})]})}},30487:(e,t,i)=>{"use strict";i.d(t,{s:()=>s});var l=i(72761);let s=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"vi";return(0,l.gf)("health-library-classifications",{fields:["id","name","slug"],filters:{status:{_eq:"published"}},sort:[{column:"position",order:"desc"},{column:"createdAt",order:"desc"}],pagination:!1,locale:e})}},32739:(e,t,i)=>{"use strict";i.d(t,{default:()=>d});var l=i(45704),s=i(73812),a=i(66724),r=i(30487),o=i(7283),n=i(24293),c=i(54173);function d(){let e=(0,o.Ym)(),t=(0,n.rd)(),i=(0,c.c3)(),[d,m]=(0,a.useState)(""),{data:h}=(0,r.s)(e),p=Array.isArray(null==h?void 0:h.data)?h.data:[],u=()=>{d.trim()&&t.push({pathname:"/patient/library",query:{keyword:d.trim()}})};return(0,l.jsx)("section",{className:"bg-white overflow-hidden max-lg:pt-8 lg:py-16",children:(0,l.jsx)("div",{className:"container",children:(0,l.jsxs)("div",{className:"grid grid-cols-12 lg:gap-12 md:gap-8 gap-6 items-center",children:[(0,l.jsx)("div",{className:"lg:col-span-6 col-span-full",children:(0,l.jsxs)("div",{className:"space-y-4",children:[(0,l.jsx)("div",{className:"display-7 text-primary-600 max-lg:text-center",children:i("home.section_1.title")}),(0,l.jsx)("div",{className:"flex flex-wrap gap-2 md:gap-3",children:p.map(e=>(0,l.jsx)(n.N_,{href:{pathname:"/patient/library",query:{category:e.slug}},className:"btn btn-outline-primary label-4 px-3 py-1",children:e.name},e.id))})]})}),(0,l.jsxs)("div",{className:"lg:col-span-6 col-span-full space-y-2",children:[(0,l.jsx)("div",{className:"label-2 text-primary-600",children:i("home.section_1.note")}),(0,l.jsxs)("div",{className:"relative group",children:[(0,l.jsx)("input",{type:"text",placeholder:i("home.section_1.placeholder"),value:d,onChange:e=>m(e.target.value),onKeyDown:e=>{"Enter"===e.key&&u()},className:"w-full pl-3 pr-16 py-3 bg-white border border-gray-200 rounded-lg focus:outline-none focus:ring-0 ring-0 focus:border-primary-500 transition-all duration-500 body-2 group-hover:border-primary-200 placeholder:text-gray-400 text-gray-800"}),(0,l.jsx)("button",{onClick:u,className:"absolute right-2.5 top-1/2 -translate-y-1/2 p-2.5 bg-primary-600 text-white rounded-lg hover:bg-primary-700 transition-all duration-300 cursor-pointer",children:(0,l.jsx)(s.A,{className:"size-4"})})]})]})]})})})}},49218:(e,t,i)=>{"use strict";i.d(t,{A:()=>s});var l=i(45704);let s=e=>{let{className:t="",...i}=e;return(0,l.jsx)("svg",{className:t,width:"23",height:"24",viewBox:"0 0 23 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...i,children:(0,l.jsx)("path",{d:"M7.43699 0.0764093C7.19789 0.175353 7.03162 0.337503 6.93819 0.562864C6.84475 0.788225 6.84751 1.02045 6.94645 1.25955L11.1515 11.4212C11.2505 11.6603 11.4152 11.823 11.6457 11.9093C11.8761 11.9958 12.1097 11.9873 12.3464 11.8836C12.5839 11.7884 12.7498 11.6272 12.844 11.3999C12.9382 11.1727 12.9358 10.9395 12.8369 10.7004L8.62013 0.56695C8.52119 0.327852 8.35904 0.161584 8.13368 0.0681483C7.90832 -0.0252882 7.67609 -0.022534 7.43699 0.0764093ZM3.75623 2.90271C3.51837 2.99866 3.35211 3.16082 3.25743 3.38916C3.16276 3.61751 3.16488 3.85126 3.26382 4.09036L7.00718 13.1362C7.10612 13.3753 7.27021 13.5369 7.49947 13.6209C7.72874 13.705 7.96139 13.7012 8.19745 13.6096C8.43958 13.5033 8.60737 13.3375 8.7008 13.1121C8.79424 12.8868 8.79149 12.6545 8.69254 12.4154L4.96568 3.40943C4.86544 3.1698 4.69827 3.00145 4.46429 2.90444C4.23008 2.80734 3.99409 2.80675 3.75623 2.90271ZM16.4237 22.7515C18.8412 21.7511 20.5491 20.0603 21.5474 17.6791C22.5456 15.298 22.5445 12.8986 21.5441 10.4811L19.8786 6.45625C19.7796 6.21715 19.6175 6.05088 19.3921 5.95745C19.1668 5.86401 18.9345 5.86676 18.6954 5.96571L17.8586 6.31201C17.5398 6.44393 17.2477 6.63096 16.9822 6.87302C16.7168 7.11508 16.5202 7.36368 16.3924 7.61885L13.7161 1.09519C13.6159 0.855555 13.4487 0.687209 13.2147 0.590199C12.9805 0.493095 12.7437 0.494494 12.5042 0.594378C12.2647 0.694448 12.0965 0.861294 11.9996 1.09492C11.9027 1.32873 11.9037 1.56519 12.0026 1.80428L15.3502 9.89375L16.4221 12.484L15.386 12.9127C14.2702 13.3745 13.4986 14.1605 13.0713 15.2708C12.644 16.3811 12.6617 17.4955 13.1245 18.6139L13.1394 18.6498C13.2383 18.8889 13.4024 19.0505 13.6317 19.1345C13.8609 19.2185 14.0936 19.2148 14.3297 19.1232C14.5718 19.0169 14.74 18.8501 14.8342 18.6229C14.9284 18.3957 14.9253 18.1644 14.8248 17.929L14.8083 17.8892C14.5334 17.225 14.5217 16.5765 14.7732 15.9434C15.0246 15.3104 15.4692 14.8619 16.1067 14.5981L17.9797 13.823C18.2193 13.7228 18.3877 13.5556 18.4847 13.3217C18.5818 13.0874 18.5808 12.8508 18.4819 12.6117L17.5467 10.4083C17.3598 9.95666 17.3657 9.49143 17.5642 9.01254C17.7628 8.53365 18.0879 8.20077 18.5395 8.01386L19.8588 11.2018C20.6613 13.1412 20.6608 15.0667 19.8572 16.9784C19.0536 18.89 17.6821 20.2472 15.7427 21.0497C13.7768 21.8632 11.8208 21.8831 9.87484 21.1092C7.92883 20.3354 6.55452 18.9788 5.75199 17.0395L1.77777 7.43573C1.67753 7.19609 1.51036 7.02775 1.27638 6.93074C1.04218 6.83363 0.806184 6.83304 0.568324 6.929C0.330465 7.02496 0.164198 7.18711 0.0695235 7.41546C-0.0251504 7.6438 -0.0230278 7.87755 0.0759155 8.11665L4.05014 17.7204C5.05056 20.1379 6.75852 21.831 9.17407 22.7994C11.5896 23.7679 14.0062 23.7519 16.4237 22.7515Z",fill:"#0D71BA"})})}},58192:(e,t,i)=>{"use strict";i.d(t,{A:()=>l});let l=(0,i(68148).A)("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]])},58453:(e,t,i)=>{Promise.resolve().then(i.bind(i,15097)),Promise.resolve().then(i.bind(i,18267)),Promise.resolve().then(i.t.bind(i,29126,23)),Promise.resolve().then(i.bind(i,77991)),Promise.resolve().then(i.bind(i,25308)),Promise.resolve().then(i.bind(i,32739)),Promise.resolve().then(i.bind(i,43538)),Promise.resolve().then(i.bind(i,25020)),Promise.resolve().then(i.bind(i,59032)),Promise.resolve().then(i.bind(i,18545)),Promise.resolve().then(i.bind(i,11481)),Promise.resolve().then(i.bind(i,96192))},59032:(e,t,i)=>{"use strict";i.d(t,{HealthLibrary:()=>h});var l=i(45704),s=i(66724),a=i(24293),r=i(11878),o=i(25308),n=i(85942),c=i(7283),d=i(54173);let m=[{id:"specialty",name:"Khoa l\xe2m s\xe0ng"},{id:"symptom",name:"Khoa cận l\xe2m s\xe0ng"},{id:"health-guide",name:"Khoa hỗ trợ l\xe2m s\xe0ng"}];function h(e){let{initialCategories:t=[],initialSpecialties:i=[]}=e,h=(0,d.c3)(),[p,u]=(0,s.useState)(m[0].id),x=(0,s.useRef)({}),g=(0,c.Ym)(),[v,b]=(0,s.useState)(t),[y,f]=(0,s.useState)(i),[w,j]=(0,s.useState)(!1);(0,s.useEffect)(()=>{let e=!0;return(async()=>{try{j(!0);let[t,i]=await Promise.all([n.Ay.fetchItems("specialty-categories",{fields:["id","name","slug"],filters:{status:{_eq:"published"}},sort:[{column:"position",order:"desc"},{column:"createdAt",order:"desc"}],pagination:!1,locale:g}),n.Ay.fetchItems("specialties",{fields:["id","name","slug","defaultImage","hoverImage","specialtyCategoryId"],filters:{status:{_eq:"published"}},sort:[{column:"name",order:"asc"},{column:"position",order:"desc"},{column:"createdAt",order:"desc"}],pagination:!1,locale:g})]);if(!e)return;b((null==t?void 0:t.data)||[]),f(i.data||[])}catch(e){}finally{e&&j(!1)}})(),()=>{e=!1}},[g]);let N=(0,s.useMemo)(()=>0===v.length?m.map(e=>({id:e.id,name:e.name,categoryId:void 0})):v.map((e,t)=>{var i,l,s,a;let r=m[t];return{id:null!==(l=null!==(i=e.slug)&&void 0!==i?i:null==r?void 0:r.id)&&void 0!==l?l:"category-".concat(e.id),name:null!==(a=null!==(s=e.name)&&void 0!==s?s:null==r?void 0:r.name)&&void 0!==a?a:"Danh mục ".concat(t+1),categoryId:e.id}}),[v]);(0,s.useEffect)(()=>{0!==N.length&&(N.some(e=>e.id===p)||u(N[0].id))},[N,p]);let k=(0,s.useMemo)(()=>{let e=N.find(e=>e.id===p);return null==e?void 0:e.categoryId},[N,p]),C=(0,s.useMemo)(()=>k?y.filter(e=>e.specialtyCategoryId===k):y,[y,k]),_=e=>{u(e)};return(0,l.jsx)("section",{className:"xl:pb-16 md:pb-12 pb-8 xl:pt-[35px] md:pt-6 bg-white",children:(0,l.jsxs)("div",{className:"container",children:[(0,l.jsx)(o.default,{once:!0,children:(0,l.jsx)("h2",{className:"display-4 text-center text-primary-600 xl:mb-[60px] md:mb-12 mb-8",children:h("home.section_4.title")})}),(0,l.jsxs)(o.default,{once:!0,children:[(0,l.jsx)("div",{className:"bg-primary-600 rounded-t-lg",children:(0,l.jsx)("div",{className:"flex overflow-x-auto scrollbar-hide justify-between flex-nowrap",children:N.map(e=>(0,l.jsx)("button",{ref:t=>{x.current[e.id]=t},className:"p-4 title-2 max-md:!text-[16px] text-white flex-shrink-0 md:flex-1 md:min-w-[300px] w-fit cursor-pointer ".concat(p===e.id?"opacity-100":"opacity-70 hover:opacity-100"),onClick:()=>_(e.id),children:e.name},e.id))})}),(0,l.jsx)("div",{className:"grid lg:grid-cols-6 md:grid-cols-4 grid-cols-2 gap-3.5 bg-[#EFEFEF] px-3.5 py-3.5 rounded-b-lg h-[548px] overflow-y-auto xl:mb-[60px] md:mb-12 mb-8 content-start items-start",children:w&&0===y.length?Array.from({length:12}).map((e,t)=>(0,l.jsxs)("div",{className:"p-3 bg-white rounded-lg animate-pulse",children:[(0,l.jsx)("div",{className:"size-[64px] mb-3 mx-auto rounded-full bg-neutral-200"}),(0,l.jsx)("div",{className:"h-[16px] mx-auto w-[80%] rounded bg-neutral-200"})]},"skeleton-".concat(t))):C.map(e=>{var t,i;let s=e.slug?{pathname:"/patient/specialty/[slug]",params:{slug:e.slug}}:{pathname:"/patient/specialty"};return(0,l.jsxs)(a.N_,{href:s,className:"p-3 bg-white rounded-lg lg:hover:bg-primary-300 lg:duration-150 group h-max",children:[(0,l.jsxs)("div",{className:"size-[64px] relative mb-3 mx-auto",children:[(0,l.jsx)(r.p,{src:(null===(t=e.defaultImage)||void 0===t?void 0:t.absolute_url)||"",alt:e.name,width:64,height:64,objectFit:"contain",className:"lg:group-hover:opacity-0 opacity-100 lg:duration-150 transition-opacity"}),e.hoverImage&&(0,l.jsx)(r.p,{src:null===(i=e.hoverImage)||void 0===i?void 0:i.absolute_url,alt:e.name,width:64,height:64,objectFit:"contain",className:"absolute top-0 lg:group-hover:opacity-100 opacity-0 lg:duration-150 transition-opacity"})]}),(0,l.jsx)("h3",{className:"title-3 line-clamp-2 text-black text-center lg:group-hover:text-white h-[40px]",children:e.name})]},"".concat(e.id,"-").concat(e.slug||"fallback"))})})]}),(0,l.jsx)(o.default,{once:!0,children:(0,l.jsx)("div",{className:"flex justify-center",children:(0,l.jsx)(a.N_,{href:"/patient/specialty",className:"btn btn-outline-primary label-2",children:h("button.view_all")})})})]})})}},73812:(e,t,i)=>{"use strict";i.d(t,{A:()=>l});let l=(0,i(68148).A)("search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]])},75330:(e,t,i)=>{"use strict";i.d(t,{H:()=>l});let l=(0,i(46101).v)(e=>({isOverlayVisible:!1,setOverlayVisible:t=>e({isOverlayVisible:t})}))},76767:(e,t,i)=>{"use strict";i.d(t,{A:()=>l});let l=(0,i(68148).A)("chevrons-down",[["path",{d:"m7 6 5 5 5-5",key:"1lc07p"}],["path",{d:"m7 13 5 5 5-5",key:"1d48rs"}]])},77991:(e,t,i)=>{"use strict";i.d(t,{default:()=>r});var l=i(66724),s=class extends l.Component{constructor(e){super(e),this.t=()=>this.i.current.offsetWidth,this.h=()=>this.i.current.offsetHeight,this.i=l.createRef(),this.state={path:""},this.l=0,this.o=0,this.p=0,this.u=this.u.bind(this)}m(){let e=[];for(let t=0;t<=Math.max(this.props.points,1);t++){let i=t/this.props.points*this.t(),l=(this.p+(t+t%this.props.points))*this.props.speed*100,s=Math.sin(l/100)*this.props.amplitude,a=Math.sin(l/100)*s+this.props.height;e.push({x:i,y:a})}return e}$(e){let t=`M ${e[0].x} ${e[0].y}`,i={x:(e[1].x-e[0].x)/2,y:e[1].y-e[0].y+e[0].y+(e[1].y-e[0].y)},l=(e,t)=>` C ${e.x} ${e.y} ${e.x} ${e.y} ${t.x} ${t.y}`;t+=l(i,e[1]);let s=i;for(let i=1;i{let{options:t,...i}=e;return l.createElement(s,Object.assign({},a,t,i))}},96192:(e,t,i)=>{"use strict";i.d(t,{default:()=>b});var l=i(45704),s=i(66724),a=i(24293),r=i(7283),o=i(11878),n=i(76767),c=i(58192),d=i(14762),m=i(8426),h=i(72572),p=i(54173),u=i(49218),x=i(64704),g=i(2113),v=i(75330);function b(){(0,a.rd)();let e=(0,r.Ym)(),t=(0,p.c3)(),i=(0,x.n)(e=>e.isAuthenticated),b=(0,x.n)(e=>e.openLogin),{consentStatus:y}=(0,g.u)(),f=(0,v.H)(e=>e.setOverlayVisible),[w,j]=(0,s.useState)(!1);(0,s.useEffect)(()=>(f(w),()=>f(!1)),[w,f]),(0,s.useEffect)(()=>{!/bot|crawler|spider|crawling|googlebot|bingbot|slurp|duckduckbot|baiduspider|yandexbot|sogou|exabot|facebot|ia_archiver|pagespeed|lighthouse|headlesschrome/i.test(navigator.userAgent)&&!0!==navigator.webdriver&&((0,h.Ri)("homeType")||sessionStorage.getItem("homeType")||(j(!0),document.body.style.overflow="hidden"))},[]);let N=[{key:"patient",title:t("welcome.patient.title"),desc:t("welcome.patient.desc"),img:"/images/welcome/welcome-patient.jpg",route:"/",children:[{title:t("welcome.patient.booking"),route:"https://play.google.com/store/apps/details?id=vn.com.umc.patient"},{title:t("welcome.patient.service"),route:"/patient/service"}]},{key:"medical",title:t("welcome.medical.title"),desc:t("welcome.medical.desc"),img:"/images/welcome/welcome-medical.jpg",route:"/medical",children:[{title:t("welcome.medical.training"),route:"/medical/training"},{title:t("welcome.medical.research"),route:"/medical/research"},{title:t("welcome.medical.career"),route:"/medical/career"}]},{key:"umcers",title:t("welcome.umcers.title"),desc:t("welcome.umcers.desc"),img:"/images/welcome/welcome-umcers-1.jpg",route:"/umcers",children:[{title:t("welcome.umcers.internal_corner"),route:"/umcers/internal-corner"},{title:t("welcome.umcers.contribution"),route:"/umcers",hash:"#contribution-section"}]}],[k,C]=(0,s.useState)(!0),[_,A]=(0,s.useState)(!1),[L,z]=(0,s.useState)(0),S=(0,s.useRef)(null),[E,I]=(0,s.useState)(null),P=(0,s.useRef)(null);(0,s.useEffect)(()=>{if(!w)return;let e=P.current;if(!e)return;let t=null,i=0,l=()=>{t&&cancelAnimationFrame(t),t=requestAnimationFrame(()=>{let t=e.scrollTop;t>100?C(!1):C(!0),Math.abs(t-i)>1&&(z(1),S.current&&clearTimeout(S.current),S.current=setTimeout(()=>{z(0)},400)),i=t})};return e.addEventListener("scroll",l,{passive:!0}),()=>{e.removeEventListener("scroll",l),t&&cancelAnimationFrame(t)}},[w]);let M=t=>{if("1"===y?(0,h.TV)("homeType",t.key,365):sessionStorage.setItem("homeType",t.key),"patient"===t.key){j(!1),document.body.style.overflow="auto";return}let i=a.DT.pathnames[t.route];if(!i)return;let l=i[e];l&&("/"===l&&"/"===t.route&&(l="/".concat(e)),window.location.href=l)},T=(t,l,s)=>{if("1"===y?(0,h.TV)("homeType",t.key,365):sessionStorage.setItem("homeType",t.key),"https://play.google.com/store/apps/details?id=vn.com.umc.patient"===l){let e="/patient/checkout";if(!i){b(e),j(!1),document.body.style.overflow="auto";return}window.location.href=e;return}if(l.startsWith("http")){window.open(l,"_blank","noopener,noreferrer");return}let r=a.DT.pathnames[l];if(!r)return;let o=r[e];if(!o)return;let n=s?"".concat(o).concat(s):o;window.location.href=n};return w?(0,l.jsx)("div",{ref:P,className:"fixed inset-0 z-[9997] bg-white overflow-y-auto no-scrollbar",style:{overscrollBehavior:"contain"},children:(0,l.jsxs)("div",{className:"relative flex flex-col min-h-screen",children:[(0,l.jsx)("div",{className:"absolute top-0 left-1/2 -translate-x-1/2 xl:py-4 md:py-3 py-2 xl:px-8 md:px-6 px-4 bg-white rounded-b-2xl z-20 logo-shadow max-md:hidden",children:(0,l.jsx)("div",{className:"lg:w-[244px] w-[200px] lg:h-12 h-10 relative",children:(0,l.jsx)(o.p,{src:"/logo-welcome.webp",fill:!0,alt:"logo welcome"})})}),(0,l.jsx)("div",{className:"h-20 md:hidden py-4 px-5 relative z-10 bg-white flex-shrink-0",children:(0,l.jsx)("div",{className:"w-[255px] h-12 relative",children:(0,l.jsx)(o.p,{src:"/logo-welcome.webp",fill:!0,alt:"logo welcome"})})}),(0,l.jsx)("div",{className:"md:flex md:flex-row flex-1 hidden",children:N.map(e=>{var i;return(0,l.jsxs)("div",{className:"relative welcome-banner group md:flex-1 h-full min-h-screen flex items-end transition-all ".concat("medical"===e.key?"md:order-1":"patient"===e.key?"md:order-2":"md:order-3"),style:{backgroundImage:"url(".concat(e.img,")"),backgroundSize:"cover",backgroundPosition:"center"},children:[(0,l.jsx)("div",{className:"absolute inset-x-0 bottom-0 h-[50%] bg-linear-white opacity-100 group-hover:opacity-0 transition-all duration-200"}),(0,l.jsx)("div",{className:"absolute inset-x-0 bottom-0 h-[50%] bg-linear-blue opacity-0 group-hover:opacity-100 transition-all duration-200"}),(0,l.jsxs)("div",{className:"relative z-10 xl:w-[80%] w-[90%] mx-auto xl:pb-16 lg:pb-12 pb-8 text-center flex flex-col items-center group-hover:translate-y-[-40px] duration-200",children:[(0,l.jsx)("h2",{className:"display-7 xl:mb-4 md:mb-3 mb-2 group-hover:text-white duration-200",children:e.title}),(0,l.jsx)("p",{className:"xl:mb-[18px] md:mb-3 mb-2 body-2 group-hover:text-white duration-200",children:e.desc}),(0,l.jsx)("div",{className:"flex items-center flex-wrap justify-center xl:gap-x-[55px] gap-x-6 md:gap-y-2 max-lg:gap-y-4 xl:mb-[30px] md:mb-6 mb-4",children:null===(i=e.children)||void 0===i?void 0:i.map((t,i)=>(0,l.jsx)("div",{className:"body-3 cursor-pointer text-primary-600 group-hover:text-white group-hover:border-white xl:pb-1.5 md:pb-1 pb-0.5 border-b-2 border-primary-600",onClick:()=>T(e,t.route,t.hash),children:t.title},i))}),(0,l.jsx)("button",{className:"cursor-pointer px-8 py-2.5 rounded-lg bg-white text-primary-600 group-hover:bg-white transition-all label-2 shadow-sm",onClick:()=>M(e),children:t("common.access")})]})]},e.key)})}),(0,l.jsx)("div",{className:"md:hidden relative",children:N.map((e,i)=>(0,l.jsxs)("div",{className:"sticky top-0 ".concat(0===i?"h-[calc(100svh-80px)]":"h-[100svh]"),style:{zIndex:10+i},children:[(0,l.jsx)("div",{className:"relative h-full w-full",children:(0,l.jsx)(o.p,{src:e.img,fill:!0,alt:e.title,className:"object-cover gray-scale-80"})}),(0,l.jsx)("div",{className:"absolute bg-welcome-gradient inset-x-0 bottom-0 h-[72%] z-[1]"}),(0,l.jsx)("div",{className:"absolute inset-x-0 bottom-0 h-[50%] z-[2]",children:(0,l.jsxs)("div",{className:"relative w-full px-8 pb-8",children:[(0,l.jsx)("h2",{className:"display-7 mb-4 text-white",children:e.title}),(0,l.jsx)("p",{className:"mb-3 body-2 text-white mb-8",children:e.desc}),(0,l.jsx)("div",{onClick:()=>M(e),className:"btn btn-secondary label-2",children:t("common.access")})]})})]},e.key))}),k&&(0,l.jsx)("div",{className:"md:hidden fixed bottom-0 inset-x-0 z-30",children:(0,l.jsxs)("div",{className:"relative",children:[(0,l.jsx)("div",{className:"absolute inset-x-0 top-0 h-full bg-gradient-to-b from-white/30 via-white/20 to-transparent backdrop-blur-lg -z-10 transition-opacity duration-500 ease-out",style:{opacity:L}}),(0,l.jsxs)("button",{onClick:()=>{let e=P.current;if(!e)return;let t=window.innerHeight-80;e.scrollTo({top:t,behavior:"smooth"})},className:"relative flex items-center justify-center w-full gap-1 px-6 py-6",children:[(0,l.jsx)("span",{className:"body-4 text-white whitespace-nowrap",children:t("welcome.scroll_down")}),(0,l.jsx)(n.A,{className:"w-5 h-5 text-white scroll-bounce-arrow"})]})]})}),(0,l.jsx)("div",{className:"md:hidden z-50 fixed right-6 bottom-24 size-12 bg-white rounded-[14px] flex justify-center items-center shadow-lg transition-all duration-200",onClick:()=>A(!0),children:(0,l.jsx)(u.A,{})}),_&&(0,l.jsxs)("div",{className:"md:hidden z-[10000] fixed inset-0 flex flex-col justify-end",children:[(0,l.jsx)("div",{className:"absolute inset-0 bg-black/50",onClick:()=>A(!1)}),(0,l.jsxs)("div",{className:"relative w-full bg-white py-8 px-4 rounded-t-2xl animate-in slide-in-from-bottom duration-300",children:[(0,l.jsx)("div",{className:"absolute right-2 top-2",children:(0,l.jsx)("button",{onClick:()=>A(!1),className:"p-1",children:(0,l.jsx)(c.A,{size:20})})}),(0,l.jsx)("div",{className:"display-6 text-primary-600 text-center mb-4",children:t("welcome.title")}),(0,l.jsx)("div",{className:"body-2 text-center text-black mb-8",children:t("welcome.desc")}),(0,l.jsx)("div",{className:"space-y-4 max-h-[50vh] overflow-y-auto",children:N.map(e=>{let t=E===e.key,i=e.children&&e.children.length>0;return(0,l.jsxs)("div",{className:"space-y-2",children:[(0,l.jsxs)("div",{className:"p-4 flex items-center justify-between bg-gray-100 rounded-lg",onClick:()=>M(e),children:[(0,l.jsx)("div",{className:"title-3 text-black",children:e.title}),i?(0,l.jsx)(d.A,{className:"w-4 h-4 transition-transform ".concat(t?"rotate-180":""),onClick:t=>{t.stopPropagation(),I(t=>t===e.key?null:e.key)}}):(0,l.jsx)(m.A,{size:16})]}),i&&t&&(0,l.jsx)("div",{className:"pl-4 space-y-2",children:e.children.map((t,i)=>(0,l.jsxs)("div",{className:"p-3 bg-gray-50 rounded-lg flex justify-between items-center",onClick:()=>T(e,t.route,t.hash),children:[(0,l.jsx)("div",{className:"body-2 text-primary-600",children:t.title}),(0,l.jsx)(m.A,{size:14,className:"text-primary-600"})]},i))})]},e.key)})})]})]})]})}):null}}},e=>{var t=t=>e(e.s=t);e.O(0,[2385,1383,6021,2263,6696,9126,6257,713,6750,919,9055,8003,7941,7953,4478,4293,3561,143,9575,1032,4619,7358],()=>t(58453)),_N_E=e.O()}]);