1 line
182 KiB
JavaScript
1 line
182 KiB
JavaScript
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8450],{881:(e,t,i)=>{"use strict";i.d(t,{XN:()=>a.X});var a=i(40444);a.X},8177:(e,t,i)=>{"use strict";i.d(t,{BackendStatusIndicator:()=>o});var a=i(95155);i(12115);var r=i(28035),n=i(64078),s=i(97124);let o=()=>{let{isConnected:e}=(0,n.F)();return(0,a.jsx)(r.a,{isOpen:!e,onClose:()=>{},title:(0,a.jsxs)("div",{className:"flex items-center space-x-2 text-orange-400",children:[(0,a.jsx)(s.X,{className:"h-5 w-5 animate-spin"}),(0,a.jsx)("span",{children:"Connection Issue"})]}),size:"small",closeOnBackdropClick:!1,closeOnEsc:!1,showCloseButton:!1,className:"border-orange-500/30",contentClassName:"bg-gradient-to-br from-orange-950/50 via-black/30 to-black/50",children:(0,a.jsxs)("div",{className:"text-center text-orange-200/90",children:[(0,a.jsx)("p",{className:"mb-2",children:"We're having trouble connecting to the server right now."}),(0,a.jsx)("p",{className:"text-sm text-orange-300/70",children:"Attempting to reconnect automatically. Some features may be temporarily unavailable."})]})})}},15590:(e,t,i)=>{"use strict";i.d(t,{GradientLine:()=>n});var a=i(95155);i(12115);var r=i(37281);function n(e){let{color:t="blue",opacity:i=.2,position:n="top",distance:s=4,animate:o=!1,className:l=""}=e;return(0,a.jsx)(r.P.div,{className:"absolute ".concat({top:"-top-".concat(s," left-0 right-0 h-px"),bottom:"-bottom-".concat(s," left-0 right-0 h-px"),left:"-left-".concat(s," top-0 bottom-0 w-px"),right:"-right-".concat(s," top-0 bottom-0 w-px")}[n]," ").concat("left"===n||"right"===n?"bg-gradient-to-b":"bg-gradient-to-r"," ").concat({blue:"from-transparent via-electric-blue to-transparent",pink:"from-transparent via-electric-pink to-transparent",purple:"from-transparent via-electric-purple to-transparent",vibrant:"from-electric-blue via-electric-purple to-electric-pink"}[t]," ").concat(l),initial:"initial",animate:o?"animate":"initial",variants:{initial:{opacity:i},animate:{opacity:[i,1.5*i,i],transition:{duration:2,repeat:1/0,repeatType:"reverse"}}}})}},16506:(e,t,i)=>{"use strict";i.r(t),i.d(t,{CookieBanner:()=>c});var a=i(95155);i(12115);var r=i(33535),n=i(91202),s=i(44912),o=i(37281),l=i(76703);function c(e){let{className:t=""}=e,{hasInteracted:i,acceptAll:c,rejectNonEssential:d,showPreferencesModal:u}=(0,r.u)(),h=(0,l.useClientTranslations)("Cookies");return i?null:(0,a.jsx)(o.P.div,{initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.5,ease:"easeOut"},className:"fixed left-1/2 -translate-x-1/2 bottom-20 md:translate-x-0 md:left-auto md:right-4 md:bottom-4 z-50 max-w-sm w-[calc(100%-2rem)] md:w-auto ".concat(t),"data-testid":"cookie-banner",children:(0,a.jsx)(n.Card,{variant:"glass",className:"overflow-hidden",children:(0,a.jsxs)(n.CardContent,{className:"p-4",children:[(0,a.jsx)("h2",{className:"text-base font-medium mb-2 text-white",children:h("banner.title")}),(0,a.jsx)("p",{className:"text-xs text-white/80 mb-4",children:h("banner.description")}),(0,a.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,a.jsxs)("div",{className:"flex gap-2 w-full",children:[(0,a.jsx)(s.Button,{variant:"outline",size:"small",className:"flex-1",onClick:()=>u(),"data-testid":"cookie-preferences-button",children:h("banner.customize")}),(0,a.jsx)(s.Button,{variant:"outline",size:"small",className:"flex-1",onClick:()=>d(),"data-testid":"cookie-reject-button",children:h("banner.essentialOnly")})]}),(0,a.jsx)(s.Button,{variant:"primary",size:"small",fullWidth:!0,onClick:()=>c(),"data-testid":"cookie-accept-button",children:h("banner.acceptAll")})]})]})})})}},18809:(e,t,i)=>{"use strict";i.d(t,{K:()=>n});var a=i(85909),r=i(22295);class n{async getConsent(){return await this.repository.getConsent()||new a.Z}async saveConsent(e){await this.repository.saveConsent(e)}async hasUserInteracted(){return null!==await this.repository.getConsent()}async acceptAll(){let e=(await this.getConsent()).acceptAll();return await this.saveConsent(e),e}async rejectNonEssential(){let e=(await this.getConsent()).rejectNonEssential();return await this.saveConsent(e),e}async updateConsent(e,t){let i=await this.getConsent(),a=r.J[e].toLowerCase(),n=i.update(a,t);return await this.saveConsent(n),n}constructor(e){this.repository=e}}},22295:(e,t,i)=>{"use strict";i.d(t,{J:()=>a});var a=function(e){return e.ESSENTIAL="essential",e.ANALYTICS="analytics",e.MARKETING="marketing",e}({})},23854:(e,t,i)=>{"use strict";i.d(t,{b:()=>n});var a=i(95155);i(12115);var r=i(37281);function n(e){let{href:t,label:i,icon:n,className:s=""}=e;return(0,a.jsxs)(r.P.a,{href:t,target:"_blank",rel:"noopener noreferrer",className:"w-10 h-10 rounded-full bg-glass-bg-light flex items-center justify-center text-white hover:text-white border border-white/5 hover:border-electric-blue/30 hover:shadow-glow relative overflow-hidden group cursor-pointer ".concat(s),"aria-label":i,initial:"initial",animate:"animate",whileHover:"hover",whileTap:"tap",variants:{initial:{opacity:0,scale:.8},animate:{opacity:1,scale:1,transition:{type:"spring",stiffness:200,damping:25}},hover:{y:-5,scale:1.1,transition:{type:"spring",stiffness:200,damping:25,duration:.2}},tap:{scale:.95,transition:{type:"spring",stiffness:200,damping:25,duration:.1}}},children:[(0,a.jsx)("span",{className:"relative z-10",children:(e=>{switch(e){case"twitter":case"x":return(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,a.jsx)("path",{d:"M23 3a10.9 10.9 0 0 1-3.14 1.53 4.48 4.48 0 0 0-7.86 3v1A10.66 10.66 0 0 1 3 4s-4 9 5 13a11.64 11.64 0 0 1-7 2c9 5 20 0 20-11.5a4.5 4.5 0 0 0-.08-.83A7.72 7.72 0 0 0 23 3z"})});case"instagram":return(0,a.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("rect",{x:"2",y:"2",width:"20",height:"20",rx:"5",ry:"5"}),(0,a.jsx)("path",{d:"M16 11.37A4 4 0 1 1 12.63 8 4 4 0 0 1 16 11.37z"}),(0,a.jsx)("line",{x1:"17.5",y1:"6.5",x2:"17.51",y2:"6.5"})]});case"linkedin":return(0,a.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("path",{d:"M16 8a6 6 0 0 1 6 6v7h-4v-7a2 2 0 0 0-2-2 2 2 0 0 0-2 2v7h-4v-7a6 6 0 0 1 6-6z"}),(0,a.jsx)("rect",{x:"2",y:"9",width:"4",height:"12"}),(0,a.jsx)("circle",{cx:"4",cy:"4",r:"2"})]});case"facebook":return(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,a.jsx)("path",{d:"M18 2h-3a5 5 0 0 0-5 5v3H7v4h3v8h4v-8h3l1-4h-4V7a1 1 0 0 1 1-1h3z"})});case"github":return(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,a.jsx)("path",{d:"M9 19c-5 1.5-5-2.5-7-3m14 6v-3.87a3.37 3.37 0 0 0-.94-2.61c3.14-.35 6.44-1.54 6.44-7A5.44 5.44 0 0 0 20 4.77 5.07 5.07 0 0 0 19.91 1S18.73.65 16 2.48a13.38 13.38 0 0 0-7 0C6.27.65 5.09 1 5.09 1A5.07 5.07 0 0 0 5 4.77a5.44 5.44 0 0 0-1.5 3.78c0 5.42 3.3 6.61 6.44 7A3.37 3.37 0 0 0 9 18.13V22"})});case"youtube":return(0,a.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("path",{d:"M22.54 6.42a2.78 2.78 0 0 0-1.94-2C18.88 4 12 4 12 4s-6.88 0-8.6.46a2.78 2.78 0 0 0-1.94 2A29 29 0 0 0 1 11.75a29 29 0 0 0 .46 5.33A2.78 2.78 0 0 0 3.4 19c1.72.46 8.6.46 8.6.46s6.88 0 8.6-.46a2.78 2.78 0 0 0 1.94-2 29 29 0 0 0 .46-5.25 29 29 0 0 0-.46-5.33z"}),(0,a.jsx)("polygon",{points:"9.75 15.02 15.5 11.75 9.75 8.48 9.75 15.02"})]});default:return null}})(n)}),(0,a.jsx)(r.P.span,{className:"absolute inset-0 bg-gradient-vibrant opacity-0 group-hover:opacity-30 transition-opacity duration-300",initial:{opacity:0},whileHover:{opacity:.3}}),(0,a.jsx)(r.P.span,{className:"absolute inset-0 rounded-full opacity-0 group-hover:opacity-100",animate:{boxShadow:["0 0 0px rgba(0,127,255,0)","0 0 10px rgba(0,127,255,0.5)","0 0 0px rgba(0,127,255,0)"]},transition:{duration:2,repeat:1/0,repeatType:"loop"}})]})}},28035:(e,t,i)=>{"use strict";i.d(t,{a:()=>l});var a=i(95155),r=i(12115),n=i(47650),s=i(60760),o=i(37281);function l(e){let{isOpen:t,onClose:i,children:l,title:c,size:d="medium",closeOnBackdropClick:u=!0,closeOnEsc:h=!0,showCloseButton:m=!0,className:p="",contentClassName:x="",preventScroll:g=!0}=e,{lockScroll:v,unlockScroll:f}=function(){let e=(0,r.useRef)(0),t=(0,r.useRef)(""),i=(0,r.useRef)(!1),a=(0,r.useCallback)(()=>{"undefined"==typeof document||i.current||(e.current=window.scrollY,t.current=document.body.style.overflow,i.current=!0,document.body.style.overflow="hidden",document.body.style.position="fixed",document.body.style.top="-".concat(e.current,"px"),document.body.style.width="100%")},[]),n=(0,r.useCallback)(()=>{"undefined"!=typeof document&&i.current&&(document.body.style.overflow=t.current,document.body.style.position="",document.body.style.top="",document.body.style.width="",window.scrollTo(0,e.current),i.current=!1)},[]);return(0,r.useEffect)(()=>()=>{i.current&&n()},[n]),{lockScroll:a,unlockScroll:n}}(),b=function(){let e=!(arguments.length>0)||void 0===arguments[0]||arguments[0],t=(0,r.useRef)(null);return(0,r.useEffect)(()=>{if(!e||!t.current)return;let i=document.activeElement,a=()=>{var e;return Array.from((null===(e=t.current)||void 0===e?void 0:e.querySelectorAll('a[href], button:not([disabled]), textarea:not([disabled]), input:not([disabled]), select:not([disabled]), [tabindex]:not([tabindex="-1"])'))||[])},r=e=>{if("Tab"!==e.key)return;let t=a();if(0===t.length)return;let i=t[0],r=t[t.length-1];e.shiftKey&&document.activeElement===i?(e.preventDefault(),r.focus()):e.shiftKey||document.activeElement!==r||(e.preventDefault(),i.focus())};return t.current.setAttribute("tabindex","-1"),t.current.addEventListener("keydown",r),setTimeout(()=>{let e=a();if(e.length>0)e[0].focus();else{var i;null===(i=t.current)||void 0===i||i.focus()}},50),()=>{var e;null===(e=t.current)||void 0===e||e.removeEventListener("keydown",r),i&&"focus"in i&&i.focus()}},[e]),t}(t),[y,w]=(0,r.useState)(!1);(0,r.useEffect)(()=>{if(!t||!h)return;let e=e=>{"Escape"===e.key&&j()};return document.addEventListener("keydown",e),()=>{document.removeEventListener("keydown",e)}},[t,h,i]),(0,r.useEffect)(()=>(t&&g?v():f(),()=>{g&&f()}),[t,g]);let j=()=>{w(!0),setTimeout(()=>{i(),w(!1)},300)},N={hidden:{opacity:0,y:10},visible:{opacity:1,y:0,transition:{type:"spring",stiffness:300,damping:30}},exit:{opacity:0,y:5}};return(0,n.createPortal)((0,a.jsx)(s.N,{mode:"wait",children:t&&(0,a.jsxs)("div",{className:"fixed inset-0 z-50 overflow-y-auto",children:[(0,a.jsx)(o.P.div,{className:"fixed inset-0 bg-black/70 backdrop-blur-lg",initial:"hidden",animate:"visible",exit:"hidden",variants:{hidden:{opacity:0},visible:{opacity:1,transition:{duration:.3,ease:[.16,1,.3,1]}}},onClick:u?j:void 0,"aria-hidden":"true"}),(0,a.jsx)("div",{className:"flex min-h-full items-center justify-center p-4 text-center",children:(0,a.jsx)(o.P.div,{ref:b,className:"".concat({small:"max-w-md",medium:"max-w-2xl",large:"max-w-4xl",full:"max-w-full mx-4"}[d]," w-full ").concat(p," relative z-10"),role:"dialog","aria-modal":"true","aria-labelledby":c?"modal-title":void 0,initial:"hidden",animate:"visible",exit:"exit",variants:{hidden:{opacity:0,y:15,scale:.98,rotateX:"2deg"},visible:{opacity:1,y:0,scale:1,rotateX:"0deg",transition:{type:"spring",stiffness:400,damping:35,mass:.8,delayChildren:.1,staggerChildren:.05}},exit:{opacity:0,y:8,scale:.99,rotateX:"1deg",transition:{duration:.2,ease:[.32,0,.67,0]}}},onClick:e=>e.stopPropagation(),children:(0,a.jsxs)(o.P.div,{className:"\n relative overflow-hidden\n bg-black/15 backdrop-blur-md \n border border-white/10\n rounded-xl\n shadow-[0_25px_80px_-15px_rgba(0,0,0,0.8)]\n ".concat(x,"\n "),variants:N,children:[(0,a.jsx)("div",{className:"absolute inset-0 bg-gradient-to-b from-white/5 via-transparent to-black/10 pointer-events-none"}),(0,a.jsx)("div",{className:"absolute inset-0 border-t border-l border-white/5 rounded-xl pointer-events-none"}),(c||m)&&(0,a.jsxs)(o.P.div,{className:"flex justify-between items-center px-6 pt-6 pb-4",variants:N,children:[c&&(0,a.jsx)(o.P.h3,{id:"modal-title",className:"text-lg font-normal text-white/90 tracking-wide",variants:N,children:c}),m&&(0,a.jsx)(o.P.button,{type:"button",onClick:j,className:"group relative flex items-center justify-center w-7 h-7 -mr-1 text-white/50 hover:text-white/90 transition-all focus:outline-none cursor-pointer","aria-label":"Close",whileHover:{scale:1.1},whileTap:{scale:.95},children:(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-4 w-4 transition-transform duration-200 group-hover:rotate-90",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:1.25,strokeLinecap:"round",strokeLinejoin:"round",children:(0,a.jsx)("path",{d:"M18 6L6 18M6 6l12 12"})})})]}),(0,a.jsx)(o.P.div,{className:"max-h-[75vh] overflow-auto px-6 pb-6 pt-0 relative scrollbar-thin scrollbar-thumb-white/10 scrollbar-track-transparent",variants:N,children:(0,a.jsx)(o.P.div,{className:"relative",variants:N,children:l})})]})})})]})}),document.body)}},29146:(e,t,i)=>{"use strict";i.r(t),i.d(t,{CookieConsentProviderWrapper:()=>l});var a=i(95155);i(12115);var r=i(56609),n=i(93376),s=i(18809),o=i(70581);function l(e){let{children:t}=e,i=new o.B,l=new s.K(i),c=new n.e(l),d=new n.V(l);return(0,a.jsx)(r.CookieConsentProvider,{getConsentUseCase:c,updateConsentUseCase:d,children:t})}},33535:(e,t,i)=>{"use strict";i.d(t,{u:()=>a.useCookieConsent});var a=i(56609)},35624:(e,t,i)=>{"use strict";i.d(t,{uC:()=>a.u}),i(85909),i(18809),i(93376),i(56609),i(16506),i(41459),i(29146);var a=i(33535);i(70581)},41459:(e,t,i)=>{"use strict";i.r(t),i.d(t,{CookiePreferencesModal:()=>d});var a=i(95155);i(12115);var r=i(33535),n=i(28035),s=i(44912),o=i(37281);function l(e){let{checked:t,onChange:i,disabled:r=!1,className:n="",size:s="medium","data-testid":l,"aria-label":c}=e,d={small:{container:"h-4 w-8",thumb:"w-3 h-3",translateX:{checked:16,unchecked:2}},medium:{container:"h-6 w-12",thumb:"w-5 h-5",translateX:{checked:24,unchecked:3}},large:{container:"h-8 w-16",thumb:"w-7 h-7",translateX:{checked:32,unchecked:4}}}[s],u={checked:{x:d.translateX.checked},unchecked:{x:d.translateX.unchecked}},h=()=>{r||i(!t)};return(0,a.jsx)("div",{className:"relative ".concat(d.container," rounded-full flex items-center cursor-pointer transition-all duration-300 ").concat(r?"opacity-50 cursor-not-allowed":""," ").concat(n),onClick:h,onKeyDown:e=>{(" "===e.key||"Enter"===e.key)&&(e.preventDefault(),h())},role:"switch","aria-checked":t,"aria-label":c,tabIndex:r?-1:0,"data-testid":l,style:{backgroundColor:t?"rgb(34, 197, 94)":"rgb(107, 114, 128)"},children:(0,a.jsx)(o.P.div,{className:"".concat(d.thumb," bg-white rounded-full shadow-md absolute"),animate:t?"checked":"unchecked",variants:u,transition:{type:"spring",stiffness:500,damping:30}})})}var c=i(76703);function d(e){let{className:t=""}=e,{consent:i,showPreferences:o,setConsent:d,savePreferences:u,hidePreferencesModal:h}=(0,r.u)(),m=(0,c.useClientTranslations)("Cookies");return o?(0,a.jsx)(n.a,{isOpen:!0,onClose:h,title:m("preferences.title"),size:"small",className:t,contentClassName:"text-white",children:(0,a.jsxs)("div",{className:"space-y-6",children:[(0,a.jsx)("p",{className:"text-sm text-white/80 text-left",children:m("preferences.description")}),(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsx)("div",{className:"p-3 border border-white/10 rounded-lg bg-black/20 backdrop-blur-sm",children:(0,a.jsxs)("div",{className:"flex items-start justify-between gap-4",children:[(0,a.jsxs)("div",{className:"flex-1 text-left",children:[(0,a.jsx)("h3",{className:"font-medium text-white",children:m("preferences.essential.title")}),(0,a.jsx)("p",{className:"text-xs text-white/70 mt-1",children:m("preferences.essential.description")})]}),(0,a.jsx)(l,{checked:!0,onChange:()=>{},disabled:!0,"aria-label":"Essential cookies (always enabled)"})]})}),(0,a.jsx)("div",{className:"p-3 border border-white/10 rounded-lg bg-black/20 backdrop-blur-sm",children:(0,a.jsxs)("div",{className:"flex items-start justify-between gap-4",children:[(0,a.jsxs)("div",{className:"flex-1 text-left",children:[(0,a.jsx)("h3",{className:"font-medium text-white",children:m("preferences.analytics.title")}),(0,a.jsx)("p",{className:"text-xs text-white/70 mt-1",children:m("preferences.analytics.description")})]}),(0,a.jsx)(l,{checked:i.analytics,onChange:e=>d("ANALYTICS",e),"data-testid":"analytics-checkbox","aria-label":"Analytics cookies"})]})}),(0,a.jsx)("div",{className:"p-3 border border-white/10 rounded-lg bg-black/20 backdrop-blur-sm",children:(0,a.jsxs)("div",{className:"flex items-start justify-between gap-4",children:[(0,a.jsxs)("div",{className:"flex-1 text-left",children:[(0,a.jsx)("h3",{className:"font-medium text-white",children:m("preferences.marketing.title")}),(0,a.jsx)("p",{className:"text-xs text-white/70 mt-1",children:m("preferences.marketing.description")})]}),(0,a.jsx)(l,{checked:i.marketing,onChange:e=>d("MARKETING",e),"data-testid":"marketing-checkbox","aria-label":"Marketing cookies"})]})})]}),(0,a.jsx)("div",{className:"flex justify-end pt-2",children:(0,a.jsx)(s.Button,{variant:"primary",size:"small",onClick:u,"data-testid":"save-preferences-button",children:m("preferences.save")})})]})}):null}},44475:(e,t,i)=>{"use strict";i.d(t,{M:()=>r});var a=i(95155);i(12115);let r=e=>{let{className:t,...i}=e;return(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",className:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",...i,children:(0,a.jsx)("path",{d:"M18 6L6 18M6 6l12 12"})})}},44912:(e,t,i)=>{"use strict";i.d(t,{Button:()=>s});var a=i(95155);i(12115);var r=i(37281),n=i(86442);function s(e){let{variant:t="primary",size:i="medium",fullWidth:s=!1,className:o="",children:l,icon:c,...d}=e,u=d.disabled?"opacity-60 cursor-not-allowed filter grayscale":"",h="".concat("inline-flex items-center justify-center font-medium rounded-full focus:outline-hidden relative overflow-hidden group cursor-pointer"," ").concat({primary:"bg-gradient-to-r from-electric-blue to-electric-purple text-white focus:ring-2 focus:ring-electric-blue/50",secondary:"bg-glass-bg-light backdrop-blur-glass border border-glass-border text-white focus:ring-2 focus:ring-electric-blue/30",outline:"bg-transparent border border-glass-border text-white hover:bg-glass-bg-light focus:ring-2 focus:ring-electric-blue/30",text:"bg-transparent text-white hover:text-electric-blue hover:bg-glass-bg-light focus:ring-2 focus:ring-electric-blue/20",glass:"bg-glass-bg backdrop-blur-glass border border-glass-border text-white focus:ring-2 focus:ring-electric-blue/30"}[t]," ").concat({small:"text-sm px-4 py-2",medium:"text-base px-5 py-2.5",large:"text-lg px-8 py-3.5"}[i]," ").concat(s?"w-full":""," ").concat(u," ").concat(o),m=()=>d.disabled?"disabled":"initial";return(0,a.jsxs)(r.P.button,{className:h,initial:m(),animate:d.disabled||"enabled"!==d.animate?m():"enabled",whileHover:d.disabled?"disabled":"hover",whileTap:d.disabled?"disabled":"tap",variants:{initial:{y:0,boxShadow:"0 0 0 rgba(0, 127, 255, 0)"},hover:{y:-5,boxShadow:"0 0 15px rgba(0, 127, 255, 0.5)",transition:{type:"spring",stiffness:400,damping:10}},tap:{y:-2,scale:.98,transition:{type:"spring",stiffness:400,damping:10}},disabled:{y:0,scale:1,boxShadow:"0 0 0 rgba(0, 0, 0, 0)"},enabled:{boxShadow:["0 0 0 0 rgba(0, 127, 255, 0.2)","0 0 0 8px rgba(0, 127, 255, 0)"],scale:[1,1.02,1],transition:{boxShadow:{repeat:1/0,repeatType:"loop",duration:1.5,ease:"easeInOut",times:[0,1]},scale:{repeat:1/0,repeatType:"loop",duration:1.5,ease:"easeInOut",times:[0,.5,1]}}}},onClick:e=>{(0,n.sx)("button_click",{variant:t,size:i,content:"string"==typeof l?l:"non-text-content",disabled:d.disabled||!1,...Object.fromEntries(Object.entries(d).filter(e=>{let[t]=e;return t.startsWith("data-")}))}),d.onClick&&d.onClick(e)},...d,children:[(0,a.jsxs)("span",{className:"relative z-10 flex items-center gap-2",children:[d.disabled&&(0,a.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-4 w-4 mr-1 opacity-70",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("rect",{x:"3",y:"11",width:"18",height:"11",rx:"2",ry:"2"}),(0,a.jsx)("path",{d:"M7 11V7a5 5 0 0 1 10 0v4"})]}),l,c&&!d.disabled&&(0,a.jsx)(r.P.span,{className:"button-icon",variants:{initial:{x:0},hover:{x:3,transition:{type:"spring",stiffness:400,damping:10}}},children:c})]}),(0,a.jsx)("span",{className:"absolute inset-0 bg-gradient-to-r from-electric-blue via-electric-purple to-electric-pink opacity-0 group-hover:opacity-20 transition-opacity"}),(0,a.jsx)(r.P.span,{className:"absolute inset-0 bg-gradient-to-r from-transparent via-white to-transparent opacity-0",variants:{initial:{x:"-100%",opacity:0},hover:{x:"100%",opacity:.5,transition:{duration:.5,ease:"easeInOut"}}}}),("secondary"===t||"outline"===t||"glass"===t)&&(0,a.jsx)(r.P.span,{className:"absolute inset-0 rounded-full opacity-0 border border-electric-blue/30",initial:{opacity:0},whileHover:{opacity:1},transition:{duration:.2}})]})}},48061:(e,t,i)=>{Promise.resolve().then(i.bind(i,86836)),Promise.resolve().then(i.bind(i,51457)),Promise.resolve().then(i.bind(i,60043)),Promise.resolve().then(i.bind(i,49218)),Promise.resolve().then(i.bind(i,8177)),Promise.resolve().then(i.bind(i,50530)),Promise.resolve().then(i.bind(i,72275)),Promise.resolve().then(i.bind(i,11757)),Promise.resolve().then(i.bind(i,80191)),Promise.resolve().then(i.bind(i,99652)),Promise.resolve().then(i.bind(i,66759)),Promise.resolve().then(i.bind(i,99459)),Promise.resolve().then(i.bind(i,36515)),Promise.resolve().then(i.bind(i,64078)),Promise.resolve().then(i.bind(i,44570)),Promise.resolve().then(i.bind(i,77030)),Promise.resolve().then(i.bind(i,96110)),Promise.resolve().then(i.bind(i,53419)),Promise.resolve().then(i.bind(i,16506)),Promise.resolve().then(i.bind(i,56609)),Promise.resolve().then(i.bind(i,29146)),Promise.resolve().then(i.bind(i,41459)),Promise.resolve().then(i.bind(i,15484)),Promise.resolve().then(i.bind(i,76703)),Promise.resolve().then(i.bind(i,5138)),Promise.resolve().then(i.bind(i,52014)),Promise.resolve().then(i.t.bind(i,53773,23)),Promise.resolve().then(i.t.bind(i,52787,23))},49218:(e,t,i)=>{"use strict";i.d(t,{PageTransitionProvider:()=>l,t:()=>o});var a=i(95155),r=i(12115),n=i(35695);let s=(0,r.createContext)({isTransitioning:!1,previousPath:"",currentPath:""}),o=()=>(0,r.useContext)(s);function l(e){let{children:t}=e,i=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{duration:t=300,onStart:i,onComplete:a}=e,s=(0,n.usePathname)(),[o,l]=(0,r.useState)(!1),[c,d]=(0,r.useState)(""),[u,h]=(0,r.useState)(""),m=(0,r.useRef)(null),p=s+window.location.search,x=(0,r.useCallback)(()=>{c!==p&&(m.current&&(clearTimeout(m.current),m.current=null),""!==c?(l(!0),i&&i(),h(p),m.current=setTimeout(()=>{l(!1),d(p),a&&a(),m.current=null},Math.min(t,500))):(d(p),h(p)))},[p,c,t,i,a]);return(0,r.useEffect)(()=>()=>{m.current&&clearTimeout(m.current)},[]),(0,r.useEffect)(()=>{x()},[x]),{isTransitioning:o,previousPath:c,currentPath:u}}({duration:300,onStart:()=>{},onComplete:()=>{}});return(0,a.jsx)(s.Provider,{value:i,children:t})}},50530:(e,t,i)=>{"use strict";i.d(t,{Layout:()=>ek});var a=i(95155),r=i(12115),n=i(76703),s=i(35695),o=i(6874),l=i.n(o),c=i(66766),d=i(37281),u=i(60760),h=i(38997);function m(e){let{href:t,label:i,isActive:r,onClick:n}=e,s={type:"spring",stiffness:400,damping:10},o={initial:{y:0},hover:{y:0,transition:s},tap:{scale:.98,transition:s},active:{}},c={initial:{width:0,opacity:0,x:"-50%"},hover:{width:"60%",opacity:.5,x:"-50%",transition:{type:"spring",stiffness:300,damping:30}},active:{width:"60%",opacity:.8,x:"-50%",transition:{type:"spring",stiffness:300,damping:30}}},u="".concat("px-5 h-full font-medium text-sm flex items-center justify-center relative z-10 transition-all tracking-wide nav-touch-target nav-item"," ").concat(r?"cursor-default":"cursor-pointer");return r?(0,a.jsx)(d.P.div,{className:"relative overflow-hidden h-full",initial:"initial",animate:"active",variants:o,children:(0,a.jsxs)("div",{className:u,"aria-current":"page",children:[(0,a.jsxs)("span",{className:"relative transition-colors duration-300",style:{letterSpacing:"0.2px",textRendering:"optimizeLegibility",WebkitFontSmoothing:"subpixel-antialiased"},children:[(0,a.jsx)(h.y,{as:"span",gradient:"cool",className:"font-medium",children:i}),(0,a.jsx)("span",{className:"sr-only",children:"(current page)"})]}),(0,a.jsxs)(d.P.span,{className:"absolute inset-0 bg-white/5",initial:{opacity:0},animate:{opacity:.15},transition:{duration:.3},children:[(0,a.jsx)("span",{className:"absolute inset-x-0 top-0 h-[1px] bg-white/10"}),(0,a.jsx)("span",{className:"absolute inset-x-0 bottom-0 h-[1px] bg-white/10"})]}),(0,a.jsx)(d.P.span,{className:"absolute bottom-0 left-1/2 h-[2px] bg-white/60 rounded-full will-change-transform",initial:"initial",animate:"active",variants:c}),(0,a.jsx)(d.P.span,{className:"absolute inset-0 bg-gradient-to-r from-transparent via-white to-transparent opacity-0",animate:{x:["-100%","100%"],opacity:[0,.2,0]},transition:{duration:2,ease:"easeInOut",repeat:1/0,repeatDelay:5}})]})}):(0,a.jsx)(d.P.div,{className:"relative overflow-hidden h-full",initial:"initial",whileHover:"hover",whileTap:"tap",variants:o,children:(0,a.jsxs)(l(),{href:t,className:u,onClick:n,style:{WebkitTapHighlightColor:"transparent"},children:[(0,a.jsx)("span",{className:"relative text-white/80 hover:text-electric-blue/90 transition-colors duration-300",style:{letterSpacing:"0.2px",textRendering:"optimizeLegibility",WebkitFontSmoothing:"subpixel-antialiased"},children:i}),(0,a.jsxs)(d.P.span,{className:"absolute inset-0 bg-white/5 opacity-0",initial:{opacity:0},whileHover:{opacity:.1},transition:{duration:.2},children:[(0,a.jsx)("span",{className:"absolute inset-x-0 top-0 h-[1px] bg-white/10 opacity-0 group-hover:opacity-100 transition-opacity"}),(0,a.jsx)("span",{className:"absolute inset-x-0 bottom-0 h-[1px] bg-white/10 opacity-0 group-hover:opacity-100 transition-opacity"})]}),(0,a.jsx)(d.P.span,{className:"absolute bottom-0 left-1/2 h-[2px] bg-white/40 rounded-full will-change-transform",initial:"initial",animate:"initial",whileHover:"hover",variants:c}),(0,a.jsx)(d.P.span,{className:"absolute inset-0 bg-gradient-to-r from-transparent via-white to-transparent opacity-0",variants:{initial:{x:"-100%",opacity:0},hover:{x:"100%",opacity:.3,transition:{duration:.5,ease:"easeInOut"}}}})]})})}var p=i(51626),x=i(76468),g=i(51457),v=i(36515),f=i(34955),b=i(44912),y=i(80991);function w(e){var t,i;let{item:s}=e,{updateItem:o,removeItem:d}=(0,v._)(),u=(0,n.useClientLocale)(),[h,m]=(0,r.useState)(s.product||null),[p,x]=(0,r.useState)(s.price||null),[g,f]=(0,r.useState)(!s.product);(0,r.useEffect)(()=>{if(s.product){m(s.product),x(s.price||null),f(!1);return}(async()=>{try{let t=await fetch("/api/products?id=".concat(s.product_id));if(t.ok){var e;let i=await t.json();m(i);let a=null===(e=i.prices)||void 0===e?void 0:e.find(e=>e.id===s.price_id);x(a||null)}}catch(e){console.error("Error fetching product details:",e)}finally{f(!1)}})()},[s]);let b=(null==h?void 0:null===(t=h.name)||void 0===t?void 0:t[u])||"Product",w=p?{amount:p.amount,currency:p.currency}:null,j=p?{amount:p.amount*s.quantity,currency:p.currency}:null,N=(null==h?void 0:null===(i=h.images)||void 0===i?void 0:i[0])||"/img/placeholder.jpg";if(g)return(0,a.jsxs)("div",{className:"flex items-start gap-3 p-2 rounded-lg animate-pulse",children:[(0,a.jsx)("div",{className:"shrink-0 w-16 h-16 rounded-md bg-glass-bg-light/30"}),(0,a.jsxs)("div",{className:"flex-grow",children:[(0,a.jsx)("div",{className:"h-4 w-3/4 bg-glass-bg-light/30 rounded mb-2"}),(0,a.jsx)("div",{className:"h-3 w-1/4 bg-glass-bg-light/30 rounded"})]})]});let k=!(null==h?void 0:h.type)||"physical"!==h.type,C=e=>{!k&&e>=1&&o(s.product_id,e)};return(0,a.jsxs)("div",{className:"flex items-start gap-3 p-2 rounded-lg hover:bg-glass-bg-light/30 transition-colors",children:[(0,a.jsx)(l(),{href:"/".concat(u,"/products/").concat(s.product_id),className:"shrink-0 w-16 h-16 rounded-md overflow-hidden border border-glass-border",children:(0,a.jsx)("div",{className:"relative w-full h-full",children:(0,a.jsx)(c.default,{src:N,alt:b,fill:!0,sizes:"64px",className:"object-cover"})})}),(0,a.jsxs)("div",{className:"flex-grow min-w-0",children:[(0,a.jsx)(l(),{href:"/".concat(u,"/products/").concat(s.product_id),className:"text-white hover:text-electric-blue transition-colors line-clamp-1 font-medium",children:b}),(0,a.jsx)("div",{className:"text-white/70 text-sm mt-1",children:(0,a.jsx)(y.g,{money:w,locale:u})}),(0,a.jsx)("div",{className:"flex items-center mt-2",children:k?(0,a.jsx)("div",{className:"text-sm text-white/70",children:"Qty: 1"}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("button",{onClick:()=>C(s.quantity-1),className:"w-6 h-6 flex items-center justify-center rounded-full bg-glass-bg-light/50 text-white/70 hover:text-white hover:bg-glass-bg-light transition-colors","aria-label":"Decrease quantity",children:(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-3 w-3",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,a.jsx)("line",{x1:"5",y1:"12",x2:"19",y2:"12"})})}),(0,a.jsx)("span",{className:"mx-2 text-sm text-white min-w-[20px] text-center",children:s.quantity}),(0,a.jsx)("button",{onClick:()=>C(s.quantity+1),className:"w-6 h-6 flex items-center justify-center rounded-full bg-glass-bg-light/50 text-white/70 hover:text-white hover:bg-glass-bg-light transition-colors","aria-label":"Increase quantity",children:(0,a.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-3 w-3",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("line",{x1:"12",y1:"5",x2:"12",y2:"19"}),(0,a.jsx)("line",{x1:"5",y1:"12",x2:"19",y2:"12"})]})})]})})]}),(0,a.jsxs)("div",{className:"flex flex-col items-end",children:[(0,a.jsx)("div",{className:"text-white font-medium",children:(0,a.jsx)(y.g,{money:j,locale:u})}),(0,a.jsx)("button",{onClick:()=>{d(s.product_id)},className:"mt-2 text-white/50 hover:text-white/80 transition-colors","aria-label":"Remove item",children:(0,a.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-4 w-4",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("path",{d:"M3 6h18"}),(0,a.jsx)("path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6m3 0V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2"})]})})]})]})}function j(e){let{onClose:t}=e,i=(0,n.useClientTranslations)("Navigation");(0,n.useClientTranslations)("Products");let s=(0,n.useClientTranslations)("Checkout"),o=(0,n.useClientTranslations)("Common"),c=(0,n.useClientLocale)(),{items:u,itemCount:h,subtotal:m,tax:p,total:x,isLoading:g,isTaxLoading:j}=(0,v._)(),[N,k]=(0,r.useState)(!1),[C,E]=(0,r.useState)(null),S=async()=>{if(0!==u.length)try{k(!0),E(null);let e=u.map(e=>({product_id:e.product_id,price_id:e.price_id,quantity:e.quantity,reference:"".concat(e.product_id,"-").concat(e.price_id)})),t=await (0,f.fw)({items:e,locale:c});if(t.url)window.location.href=t.url;else throw Error("No checkout URL returned")}catch(t){console.error("Error initiating checkout:",t);let e=t instanceof Error?t.message:String(t);E("".concat(s("orderFailed")," (").concat(e,")")),k(!1)}},P={hidden:{opacity:0,y:-10},visible:{opacity:1,y:0,transition:{type:"spring",stiffness:300,damping:24}}};return(0,a.jsxs)(d.P.div,{className:"absolute right-0 mt-2 w-80 max-h-[80vh] overflow-auto rounded-xl bg-glass-bg backdrop-blur-xl border border-glass-border shadow-glow z-50",initial:"hidden",animate:"visible",exit:"hidden",variants:{hidden:{opacity:0,y:-20,scale:.95,transition:{type:"spring",stiffness:500,damping:30}},visible:{opacity:1,y:0,scale:1,transition:{type:"spring",stiffness:500,damping:30,staggerChildren:.07,delayChildren:.1}}},children:[(0,a.jsx)("div",{className:"absolute inset-0 z-0 opacity-30 pointer-events-none rounded-xl",style:{background:"linear-gradient(to bottom, rgba(255,255,255,0.05) 0%, transparent 100%)"}}),(0,a.jsx)("div",{className:"absolute inset-0 z-0 pointer-events-none rounded-xl overflow-hidden",children:[void 0,void 0,void 0,void 0,void 0].map((e,t)=>(0,a.jsx)("div",{className:"absolute rounded-full bg-electric-blue/20 animate-float-subtle",style:{width:"".concat(2+3*Math.random(),"px"),height:"".concat(2+3*Math.random(),"px"),left:"".concat(100*Math.random(),"%"),top:"".concat(100*Math.random(),"%"),animationDelay:"".concat(2*Math.random(),"s"),opacity:.5+.5*Math.random()}},t))}),(0,a.jsxs)("div",{className:"p-4 relative z-10",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between mb-4 pb-2 border-b border-white/10",children:[(0,a.jsxs)("h3",{className:"text-lg font-medium text-white",children:[i("cart")," (",h,")"]}),(0,a.jsx)("button",{onClick:t,className:"text-white/70 hover:text-white transition-colors","aria-label":"Close cart",children:(0,a.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-5 w-5",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),(0,a.jsx)("line",{x1:"6",y1:"6",x2:"18",y2:"18"})]})})]}),(0,a.jsx)("div",{className:"space-y-3 max-h-[40vh] overflow-y-auto pr-1 mb-4",children:g?(0,a.jsx)("div",{className:"flex justify-center py-8",children:(0,a.jsx)("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-electric-blue"})}):0===u.length?(0,a.jsxs)(d.P.div,{variants:P,className:"text-center py-8 text-white/70",children:[(0,a.jsx)("div",{className:"flex justify-center mb-4",children:(0,a.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-12 w-12 text-white/30",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("circle",{cx:"9",cy:"21",r:"1"}),(0,a.jsx)("circle",{cx:"20",cy:"21",r:"1"}),(0,a.jsx)("path",{d:"M1 1h4l2.68 13.39a2 2 0 0 0 2 1.61h9.72a2 2 0 0 0 2-1.61L23 6H6"})]})}),(0,a.jsx)("p",{children:"Your cart is empty"}),(0,a.jsx)(l(),{href:"/".concat(c,"/products"),className:"text-electric-blue hover:text-electric-blue/80 text-sm mt-2 inline-block",onClick:t,children:"Browse products"})]}):u.map(e=>(0,a.jsx)(d.P.div,{variants:P,children:(0,a.jsx)(w,{item:e})},e.product_id))}),u.length>0&&(0,a.jsxs)(d.P.div,{variants:P,children:[(0,a.jsxs)("div",{className:"space-y-2 mb-4 pt-2 border-t border-white/10",children:[(0,a.jsxs)("div",{className:"flex justify-between items-center",children:[(0,a.jsx)("span",{className:"text-white/70 text-sm",children:s("subtotal")}),(0,a.jsx)(y.g,{money:m,className:"text-white",locale:c})]}),(0,a.jsxs)("div",{className:"flex justify-between items-center",children:[(0,a.jsx)("span",{className:"text-white/70 text-sm",children:s("tax")}),j?(0,a.jsxs)("span",{className:"text-white/70 flex items-center",children:[(0,a.jsx)("span",{className:"inline-block h-2 w-2 animate-spin rounded-full border-2 border-solid border-current border-r-transparent mr-1"}),(0,a.jsx)("span",{className:"text-xs",children:o("loading")})]}):(0,a.jsx)(y.g,{money:p,className:"text-white",locale:c})]}),(0,a.jsxs)("div",{className:"flex justify-between items-center pt-1",children:[(0,a.jsx)("span",{className:"text-white font-medium",children:s("total")}),(0,a.jsx)(y.g,{money:x,className:"text-white font-bold",locale:c})]})]}),C&&(0,a.jsx)("div",{className:"bg-red-500/20 border border-red-500/30 rounded-md p-2 mb-3",children:(0,a.jsx)("p",{className:"text-white text-xs",children:C})}),(0,a.jsxs)("div",{className:"grid grid-cols-2 gap-2",children:[(0,a.jsx)(l(),{href:"/".concat(c,"/cart"),onClick:t,className:"block",children:(0,a.jsx)(b.Button,{variant:"outline",fullWidth:!0,children:i("cart")})}),(0,a.jsx)(b.Button,{fullWidth:!0,onClick:()=>{S()},disabled:N,children:N?(0,a.jsxs)("span",{className:"flex items-center justify-center",children:[(0,a.jsx)("span",{className:"inline-block h-3 w-3 animate-spin rounded-full border-2 border-solid border-current border-r-transparent mr-1"}),(0,a.jsx)("span",{className:"text-xs",children:o("loading")})]}):s("title")})]})]})]})]})}function N(e){let{className:t=""}=e,{itemCount:i}=(0,v._)(),[n,s]=(0,r.useState)(!1),o=(0,r.useRef)(null);return(0,r.useEffect)(()=>{function e(e){o.current&&!o.current.contains(e.target)&&s(!1)}return document.addEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[]),(0,a.jsxs)("div",{className:"relative",ref:o,children:[(0,a.jsxs)(d.P.button,{onClick:()=>s(!n),variants:{initial:{scale:1},hover:{scale:1.05,transition:{type:"spring",stiffness:400,damping:10}},tap:{scale:.95,transition:{type:"spring",stiffness:500,damping:10}}},initial:"initial",whileHover:"hover",whileTap:"tap",className:"relative flex items-center justify-center p-2 rounded-full transition-all duration-300 \n text-white/70 hover:text-electric-blue bg-glass-bg-light/50 hover:bg-glass-bg-light/80 backdrop-blur-sm\n border border-white/10 hover:border-electric-blue/30\n focus:outline-none focus:ring-2 focus:ring-electric-blue/30\n ".concat(t),"aria-label":"Shopping Cart",children:[(0,a.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:"w-6 h-6",children:[(0,a.jsx)("circle",{cx:"9",cy:"21",r:"1"}),(0,a.jsx)("circle",{cx:"20",cy:"21",r:"1"}),(0,a.jsx)("path",{d:"M1 1h4l2.68 13.39a2 2 0 0 0 2 1.61h9.72a2 2 0 0 0 2-1.61L23 6H6"})]}),(0,a.jsx)(u.N,{children:i>0&&(0,a.jsx)(d.P.div,{variants:{initial:{scale:0,opacity:0},animate:{scale:1,opacity:1,transition:{type:"spring",stiffness:500,damping:15}},exit:{scale:0,opacity:0,transition:{duration:.2}}},initial:"initial",animate:"animate",exit:"exit",className:"absolute -top-1 -right-1 flex items-center justify-center w-5 h-5 rounded-full bg-electric-blue text-white text-xs font-bold",children:i>99?"99+":i},"badge")})]}),(0,a.jsx)(u.N,{children:n&&(0,a.jsx)(j,{onClose:()=>s(!1)})})]})}var k=i(44570);function C(e){var t,i,s,o,u;let{item:h,onClick:m}=e,p=(0,n.useClientTranslations)("Products"),{removeItem:x}=(0,k.n)(),{addItem:g}=(0,v._)(),f=(0,n.useClientLocale)(),[b,y]=(0,r.useState)(!1),[w,j]=(0,r.useState)(null),[N,C]=(0,r.useState)(!0);(0,r.useEffect)(()=>{(async()=>{if(h.product){j(h.product),C(!1);return}try{let e=await fetch("/api/products?id=".concat(h.product_id));if(e.ok){let t=await e.json();j(t)}}catch(e){console.error("Error fetching product details:",e)}finally{C(!1)}})()},[h]);let E=(null==w?void 0:w.name)&&"object"==typeof w.name&&(w.name[f]||w.name.en)||"Product",S=(null==w?void 0:null===(i=w.prices)||void 0===i?void 0:null===(t=i[0])||void 0===t?void 0:t.amount)||0,P=S?new Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}).format(S):"",L=(null==w?void 0:null===(s=w.images)||void 0===s?void 0:s[0])||"/img/placeholder.jpg",_=async e=>{var t,i;if(e.preventDefault(),e.stopPropagation(),null==w?void 0:null===(i=w.prices)||void 0===i?void 0:null===(t=i[0])||void 0===t?void 0:t.id){y(!0);try{await g({product_id:h.product_id,price_id:w.prices[0].id,quantity:1}),await x(h.product_id)}catch(e){console.error("Error moving item to cart:",e)}finally{y(!1)}}};return(0,a.jsx)(d.P.div,{variants:{initial:{opacity:0,y:10},animate:{opacity:1,y:0,transition:{type:"spring",stiffness:500,damping:30}},exit:{opacity:0,y:-10,transition:{duration:.2}},hover:{backgroundColor:"rgba(255, 255, 255, 0.05)",transition:{duration:.2}}},initial:"initial",animate:"animate",exit:"exit",whileHover:"hover",className:"group rounded-lg overflow-hidden",children:(0,a.jsxs)("div",{className:"flex items-start gap-3 p-2",children:[(0,a.jsx)(l(),{href:"/".concat(f,"/products/").concat(h.product_id),onClick:m,className:"shrink-0 w-16 h-16 rounded-md overflow-hidden border border-glass-border",children:(0,a.jsx)("div",{className:"relative w-full h-full",children:(0,a.jsx)(c.default,{src:L,alt:E,fill:!0,sizes:"64px",className:"object-cover"})})}),(0,a.jsxs)("div",{className:"flex-grow min-w-0",children:[(0,a.jsx)(l(),{href:"/".concat(f,"/products/").concat(h.product_id),onClick:m,className:"text-white hover:text-red-400 transition-colors line-clamp-1 font-medium",children:E}),(0,a.jsx)("div",{className:"text-white/70 text-sm mt-1",children:P}),(0,a.jsx)("div",{className:"flex items-center mt-2 space-x-2",children:(0,a.jsxs)("button",{onClick:_,disabled:b||!(null==w?void 0:null===(u=w.prices)||void 0===u?void 0:null===(o=u[0])||void 0===o?void 0:o.id),className:"text-xs text-electric-blue hover:text-electric-blue/80 transition-colors flex items-center",children:[b?(0,a.jsx)(d.P.span,{animate:{rotate:360},transition:{repeat:1/0,duration:1,ease:"linear"},className:"mr-1",children:(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-3 w-3",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,a.jsx)("path",{d:"M16.023 9.348h4.992v-.001M2.985 19.644v-4.992m0 0h4.992m-4.993 0l3.181 3.183a8.25 8.25 0 0013.803-3.7M4.031 9.865a8.25 8.25 0 0113.803-3.7l3.181 3.182m0-4.991v4.99"})})}):(0,a.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-3 w-3 mr-1",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("circle",{cx:"9",cy:"21",r:"1"}),(0,a.jsx)("circle",{cx:"20",cy:"21",r:"1"}),(0,a.jsx)("path",{d:"M1 1h4l2.68 13.39a2 2 0 0 0 2 1.61h9.72a2 2 0 0 0 2-1.61L23 6H6"})]}),p("addToCart")]})})]}),(0,a.jsx)("button",{onClick:e=>{e.preventDefault(),e.stopPropagation(),x(h.product_id)},className:"p-1.5 rounded-full text-white/40 hover:text-white/80 hover:bg-glass-bg-light/50 transition-colors opacity-0 group-hover:opacity-100","aria-label":"Remove from wishlist",children:(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-4 w-4",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,a.jsx)("path",{d:"M18 6L6 18M6 6l12 12"})})})]})})}function E(e){let{onClose:t}=e,i=(0,n.useClientTranslations)("Navigation");(0,n.useClientTranslations)("Products");let r=(0,n.useClientLocale)(),{items:s,itemCount:o,isLoading:c,clearWishlist:u}=(0,k.n)(),h={hidden:{opacity:0,y:-10},visible:{opacity:1,y:0,transition:{type:"spring",stiffness:300,damping:24}}};return(0,a.jsxs)(d.P.div,{className:"absolute right-0 mt-2 w-80 max-h-[80vh] overflow-auto rounded-xl bg-glass-bg backdrop-blur-xl border border-glass-border shadow-glow z-50",initial:"hidden",animate:"visible",exit:"hidden",variants:{hidden:{opacity:0,y:-20,scale:.95,transition:{type:"spring",stiffness:500,damping:30}},visible:{opacity:1,y:0,scale:1,transition:{type:"spring",stiffness:500,damping:30,staggerChildren:.07,delayChildren:.1}}},children:[(0,a.jsx)("div",{className:"absolute inset-0 z-0 opacity-30 pointer-events-none rounded-xl",style:{background:"linear-gradient(to bottom, rgba(255,255,255,0.05) 0%, transparent 100%)"}}),(0,a.jsx)("div",{className:"absolute inset-0 z-0 pointer-events-none rounded-xl overflow-hidden",children:[void 0,void 0,void 0,void 0,void 0].map((e,t)=>(0,a.jsx)("div",{className:"absolute rounded-full bg-red-400/20 animate-float-subtle",style:{width:"".concat(2+3*Math.random(),"px"),height:"".concat(2+3*Math.random(),"px"),left:"".concat(100*Math.random(),"%"),top:"".concat(100*Math.random(),"%"),animationDelay:"".concat(2*Math.random(),"s"),opacity:.5+.5*Math.random()}},t))}),(0,a.jsxs)("div",{className:"p-4 relative z-10",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between mb-4 pb-2 border-b border-white/10",children:[(0,a.jsxs)("h3",{className:"text-lg font-medium text-white",children:[i("wishlist")," (",o,")"]}),(0,a.jsxs)("div",{className:"flex items-center space-x-3",children:[o>0&&(0,a.jsx)("button",{onClick:()=>u(),className:"text-sm text-white/60 hover:text-white transition-colors",children:i("clear")}),(0,a.jsx)("button",{onClick:t,className:"text-white/70 hover:text-white transition-colors","aria-label":"Close wishlist",children:(0,a.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-5 w-5",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),(0,a.jsx)("line",{x1:"6",y1:"6",x2:"18",y2:"18"})]})})]})]}),(0,a.jsx)("div",{className:"space-y-3 max-h-[40vh] overflow-y-auto pr-1 mb-4",children:c?(0,a.jsx)("div",{className:"flex justify-center py-8",children:(0,a.jsx)("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-red-400"})}):0===s.length?(0,a.jsxs)(d.P.div,{variants:h,className:"text-center py-8 text-white/70",children:[(0,a.jsx)("div",{className:"flex justify-center mb-4",children:(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-12 w-12 text-white/30",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1",strokeLinecap:"round",strokeLinejoin:"round",children:(0,a.jsx)("path",{d:"M20.84 4.61a5.5 5.5 0 0 0-7.78 0L12 5.67l-1.06-1.06a5.5 5.5 0 0 0-7.78 7.78l1.06 1.06L12 21.23l7.78-7.78 1.06-1.06a5.5 5.5 0 0 0 0-7.78z"})})}),(0,a.jsx)("p",{children:i("emptyWishlist")}),(0,a.jsx)(l(),{href:"/".concat(r,"/products"),className:"text-red-400 hover:text-red-300 text-sm mt-2 inline-block",onClick:t,children:i("browseProducts")})]}):s.map(e=>(0,a.jsx)(d.P.div,{variants:h,children:(0,a.jsx)(C,{item:e,onClick:t})},e.product_id))}),s.length>0&&(0,a.jsx)(d.P.div,{variants:h,children:(0,a.jsx)("div",{className:"pt-2 border-t border-white/10",children:(0,a.jsx)(l(),{href:"/".concat(r,"/account/wishlist"),onClick:t,className:"block mt-3",children:(0,a.jsx)(b.Button,{variant:"primary",fullWidth:!0,children:i("viewWishlist")})})})})]})]})}function S(e){let{className:t=""}=e,i=(0,n.useClientTranslations)("Navigation"),{itemCount:s,isLoading:o}=(0,k.n)(),[l,c]=(0,r.useState)(!1),[h,m]=(0,r.useState)(!1),p=(0,r.useRef)(null);return(0,r.useEffect)(()=>{function e(e){p.current&&!p.current.contains(e.target)&&c(!1)}return document.addEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[]),(0,a.jsxs)("div",{className:"relative",ref:p,children:[(0,a.jsxs)(d.P.button,{onClick:()=>c(!l),onMouseEnter:()=>m(!0),onMouseLeave:()=>m(!1),variants:{initial:{scale:1},hover:{scale:1.05,transition:{type:"spring",stiffness:400,damping:10}},tap:{scale:.95,transition:{type:"spring",stiffness:500,damping:10}}},initial:"initial",whileHover:"hover",whileTap:"tap",className:"relative flex items-center justify-center p-2 rounded-full transition-all duration-300 \n text-white/70 hover:text-red-400 bg-glass-bg-light/50 hover:bg-glass-bg-light/80 backdrop-blur-sm\n border border-white/10 hover:border-red-400/30\n focus:outline-none focus:ring-2 focus:ring-red-400/30\n ".concat(t),"aria-label":i("wishlist"),children:[(0,a.jsx)(d.P.div,{variants:{initial:{scale:1},hover:{scale:1.1,transition:{type:"spring",stiffness:300,damping:10,repeat:1,repeatType:"reverse"}}},animate:h?"hover":"initial",children:(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:s>0?"currentColor":"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:"w-6 h-6",children:(0,a.jsx)("path",{d:"M20.84 4.61a5.5 5.5 0 0 0-7.78 0L12 5.67l-1.06-1.06a5.5 5.5 0 0 0-7.78 7.78l1.06 1.06L12 21.23l7.78-7.78 1.06-1.06a5.5 5.5 0 0 0 0-7.78z"})})}),(0,a.jsx)(u.N,{children:!o&&s>0&&(0,a.jsx)(d.P.div,{variants:{initial:{scale:0,opacity:0},animate:{scale:1,opacity:1,transition:{type:"spring",stiffness:500,damping:15}},exit:{scale:0,opacity:0,transition:{duration:.2}}},initial:"initial",animate:"animate",exit:"exit",className:"absolute -top-1 -right-1 flex items-center justify-center w-5 h-5 rounded-full bg-red-500 text-white text-xs font-bold",children:s>99?"99+":s},"badge")}),o&&(0,a.jsx)(d.P.div,{className:"absolute -top-1 -right-1 flex items-center justify-center w-5 h-5 rounded-full bg-red-400/20 backdrop-blur-sm",animate:{rotate:360},transition:{repeat:1/0,duration:1,ease:"linear"},children:(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",className:"w-3 h-3 text-red-400",children:(0,a.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M16.023 9.348h4.992v-.001M2.985 19.644v-4.992m0 0h4.992m-4.993 0l3.181 3.183a8.25 8.25 0 0013.803-3.7M4.031 9.865a8.25 8.25 0 0113.803-3.7l3.181 3.182m0-4.991v4.99"})})})]}),(0,a.jsx)(u.N,{children:l&&(0,a.jsx)(E,{onClose:()=>c(!1)})})]})}let P=()=>(0,a.jsxs)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("path",{d:"M3 10.25l9-7.25 9 7.25V20a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-9.75z"}),(0,a.jsx)("path",{d:"M9 22v-7a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v7"}),(0,a.jsx)("rect",{x:"10",y:"9",width:"4",height:"3",rx:"0.5"})]}),L=()=>(0,a.jsxs)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("path",{d:"M21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16z"}),(0,a.jsx)("path",{d:"M12 22.5v-10.5"}),(0,a.jsx)("path",{d:"M3.3 7L12 12l8.7-5"})]}),_=()=>(0,a.jsxs)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("rect",{x:"2",y:"7",width:"20",height:"14",rx:"2",ry:"2"}),(0,a.jsx)("path",{d:"M16 21V5a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16"}),(0,a.jsx)("path",{d:"M2 12h20"})]}),T=()=>(0,a.jsxs)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("circle",{cx:"12",cy:"12",r:"10"}),(0,a.jsx)("path",{d:"M9.5 9a2.5 2.5 0 0 1 5 0c0 2.5-3.5 2.5-3.5 5"}),(0,a.jsx)("circle",{cx:"12",cy:"17",r:"0.5",fill:"currentColor"})]}),I=()=>(0,a.jsxs)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("path",{d:"M4 4h16c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2z"}),(0,a.jsx)("polyline",{points:"22,6 12,13 2,6"})]}),B=()=>(0,a.jsxs)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("path",{d:"M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2"}),(0,a.jsx)("circle",{cx:"12",cy:"7",r:"4"})]}),M=()=>(0,a.jsxs)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("line",{x1:"4",y1:"12",x2:"20",y2:"12"}),(0,a.jsx)("line",{x1:"4",y1:"6",x2:"20",y2:"6"}),(0,a.jsx)("line",{x1:"4",y1:"18",x2:"20",y2:"18"})]}),R=()=>(0,a.jsxs)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),(0,a.jsx)("line",{x1:"6",y1:"6",x2:"18",y2:"18"})]});var O=i(53363);function A(){let e=(0,O.fM)("Navigation"),t=(0,O.py)(),i=(0,s.usePathname)(),a=(0,r.useCallback)(e=>!!i&&i.includes(e),[i]),n=(0,r.useCallback)(e=>!!i&&("en"!==t?i===e:"/"===e?"/"===i||i==="/".concat(t):i===e||i==="/".concat(t).concat(e)),[i,t]),o=e=>{switch(e){case"home":default:return r.createElement(P);case"products":return r.createElement(L);case"services":return r.createElement(_);case"about":return r.createElement(T);case"contact":return r.createElement(I);case"account":return r.createElement(B)}},l=(0,r.useMemo)(()=>[{key:"home",href:"en"===t?"/":"/".concat(t),label:e("home"),icon:o("home")},{key:"products",href:"en"===t?"/products":"/".concat(t,"/products"),label:e("products"),icon:o("products"),requiredFeatureFlag:"NEXT_PUBLIC_ENABLE_PRODUCTS_LISTING"},{key:"services",href:"en"===t?"/services":"/".concat(t,"/services"),label:e("services"),icon:o("services"),requiredFeatureFlag:"NEXT_PUBLIC_ENABLE_SERVICES"},{key:"about",href:"en"===t?"/about":"/".concat(t,"/about"),label:e("about"),icon:o("about")},{key:"contact",href:"en"===t?"/contact":"/".concat(t,"/contact"),label:e("contact"),icon:o("contact")},{key:"account",href:"en"===t?"/account":"/".concat(t,"/account"),label:e("account"),icon:o("account"),requiredFeatureFlag:"NEXT_PUBLIC_ENABLE_USER_MENU"}],[e,t]);return{navItems:(0,r.useMemo)(()=>l.map(e=>"products"===e.key||"services"===e.key||"account"===e.key?{...e,disabled:!0,href:"#"}:e).filter(e=>!e.disabled),[l]),isActive:n,pathnameIncludes:a}}var U=i(49509);function z(){return function(){let e={NEXT_PUBLIC_FOOTER_SHOW_PRODUCTS:!1,NEXT_PUBLIC_ENABLE_PRODUCTS_LISTING:!0,NEXT_PUBLIC_ENABLE_SERVICES:!0,NEXT_PUBLIC_ENABLE_CART:!0,NEXT_PUBLIC_ENABLE_WISHLIST:!0,NEXT_PUBLIC_ENABLE_USER_MENU:!0,NEXT_PUBLIC_FOOTER_PRODUCTS_LINKS:[],VERCEL_URL:"http://localhost:3000",NEXT_PUBLIC_SITE_URL:"http://localhost:3000"},t=e=>!!e&&"true"===e.toLowerCase(),i=(e,t)=>{if(!e)return t;try{return JSON.parse(e)}catch(e){return console.error("Error parsing JSON from environment variable:",e),t}};try{var a,r;let n=window.__NEXT_DATA__;if(null==n?void 0:null===(r=n.props)||void 0===r?void 0:null===(a=r.pageProps)||void 0===a?void 0:a.env){let a=n.props.pageProps.env;return{...e,NEXT_PUBLIC_FOOTER_SHOW_PRODUCTS:t(a.NEXT_PUBLIC_FOOTER_SHOW_PRODUCTS),NEXT_PUBLIC_ENABLE_PRODUCTS_LISTING:t(a.NEXT_PUBLIC_ENABLE_PRODUCTS_LISTING),NEXT_PUBLIC_ENABLE_SERVICES:t(a.NEXT_PUBLIC_ENABLE_SERVICES),NEXT_PUBLIC_ENABLE_CART:t(a.NEXT_PUBLIC_ENABLE_CART),NEXT_PUBLIC_ENABLE_WISHLIST:t(a.NEXT_PUBLIC_ENABLE_WISHLIST),NEXT_PUBLIC_ENABLE_USER_MENU:t(a.NEXT_PUBLIC_ENABLE_USER_MENU),NEXT_PUBLIC_FOOTER_PRODUCTS_LINKS:i(a.NEXT_PUBLIC_FOOTER_PRODUCTS_LINKS,[]),VERCEL_URL:a.VERCEL_URL||e.VERCEL_URL,NEXT_PUBLIC_SITE_URL:a.NEXT_PUBLIC_SITE_URL||e.NEXT_PUBLIC_SITE_URL}}}catch(e){console.error("Error accessing environment variables from window.__NEXT_DATA__:",e)}return{...e,NEXT_PUBLIC_FOOTER_SHOW_PRODUCTS:t("false"),NEXT_PUBLIC_ENABLE_PRODUCTS_LISTING:t("false"),NEXT_PUBLIC_ENABLE_SERVICES:t("false"),NEXT_PUBLIC_ENABLE_CART:t("false"),NEXT_PUBLIC_ENABLE_WISHLIST:t("false"),NEXT_PUBLIC_ENABLE_USER_MENU:t("false"),NEXT_PUBLIC_FOOTER_PRODUCTS_LINKS:i("",[]),VERCEL_URL:U.env.VERCEL_URL||e.VERCEL_URL,NEXT_PUBLIC_SITE_URL:U.env.NEXT_PUBLIC_SITE_URL||e.NEXT_PUBLIC_SITE_URL}}()}function W(){let e=(0,n.useClientTranslations)("Navigation"),t=(0,n.useClientLocale)(),i=(0,s.usePathname)(),[o,h]=(0,r.useState)(!1),[v,f]=(0,r.useState)(!1),[b,y]=(0,r.useState)(!1),w=r.useRef(0),{mousePosition:j,elementRef:k,isHovering:C}=(0,p.c)(),{user:E}=(0,g.A)(),{navItems:P,isActive:L,pathnameIncludes:_}=A(),T=z();(0,r.useEffect)(()=>{let e;let t=()=>{clearTimeout(e),e=setTimeout(()=>{if(window.scrollY>50?f(!0):f(!1),window.innerWidth<768){let e=window.scrollY;e>w.current+10?y(!0):(e<w.current-10||e<=0)&&y(!1),w.current=e}else y(!1)},10)};return window.addEventListener("scroll",t,{passive:!0}),()=>{clearTimeout(e),window.removeEventListener("scroll",t)}},[]);let I={type:"spring",stiffness:300,damping:30},B={type:"spring",stiffness:200,damping:25},O={initial:{y:-100,opacity:0,x:"-50%",left:"50%"},animate:{y:0,opacity:1,x:"-50%",left:"50%",transition:{...I,delay:.2}},hidden:{y:-100,opacity:0,transition:{...I,duration:.3}},visible:{y:0,opacity:1,transition:{...I,duration:.3}}},U={normal:{scale:1,y:0,width:"90%",backdropFilter:"blur(12px)",boxShadow:"0 10px 30px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(255, 255, 255, 0.05), 0 0 15px rgba(0, 127, 255, 0.1)",borderColor:"rgba(255, 255, 255, 0.1)",transition:{...I,duration:.4}},scrolled:{scale:.97,y:-5,width:"85%",backdropFilter:"blur(18px)",boxShadow:"0 15px 40px rgba(0, 0, 0, 0.2), 0 1px 3px rgba(255, 255, 255, 0.1), 0 0 20px rgba(0, 127, 255, 0.15)",borderColor:"rgba(255, 255, 255, 0.15)",transition:{...I,duration:.4}}},W={closed:{opacity:0,y:-20,transition:{...I,staggerChildren:.05,staggerDirection:-1}},open:{opacity:1,y:0,transition:{...I,staggerChildren:.07,delayChildren:.1}}},F={closed:{opacity:0,y:-10,transition:B},open:{opacity:1,y:0,transition:B}};return(0,a.jsxs)(d.P.header,{ref:k,className:"fixed top-0 md:top-6 hidden md:block w-full md:w-[90%] max-w-7xl z-[var(--z-index-header)] backdrop-blur-xl bg-glass-bg border-b md:border border-glass-border md:rounded-full will-change-transform overflow-visible",initial:"initial",animate:["animate",v?"scrolled":"normal",b?"hidden":"visible"],variants:{...O,...U},style:{boxShadow:"0 10px 30px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(255, 255, 255, 0.05)",left:"50%",transform:"translateX(-50%)",margin:"0 auto"},children:[(0,a.jsx)(d.P.div,{className:"absolute -inset-[1px] rounded-full z-0 opacity-0 hover:opacity-100",initial:"initial",whileHover:"hover",variants:{initial:{opacity:.5,filter:"blur(1px)"},hover:{opacity:.8,filter:"blur(1.5px)",transition:B}},style:{background:"linear-gradient(90deg, rgba(0, 127, 255, 0) 0%, rgba(0, 127, 255, 0.3) 50%, rgba(0, 127, 255, 0) 100%)"}}),(0,a.jsx)("div",{className:"absolute inset-0 rounded-full z-0",style:{background:"radial-gradient(circle at ".concat((null==j?void 0:j.relativeX)||50,"% ").concat((null==j?void 0:j.relativeY)||50,"%, rgba(255, 255, 255, 0.08) 0%, transparent 70%)"),opacity:+!!j,transition:"opacity 0.3s ease"}}),(0,a.jsx)("div",{className:"absolute inset-0 rounded-full z-0 opacity-30",style:{background:"linear-gradient(to bottom, rgba(255,255,255,0.1) 0%, transparent 100%)",pointerEvents:"none"}}),(0,a.jsxs)("div",{className:"grid grid-cols-[auto_1fr_auto] w-full h-full",children:[(0,a.jsx)("div",{className:"px-4 md:px-8 flex items-center h-full py-2 md:py-3",children:(0,a.jsx)("div",{className:"logo relative flex items-center z-10 w-[100px] md:w-[120px]",children:(0,a.jsx)(l(),{href:"en"===t?"/":"/".concat(t),children:(0,a.jsx)("div",{className:"flex items-center",children:(0,a.jsxs)("div",{className:"relative group",children:[(0,a.jsx)(c.default,{src:"/img/logo-white.svg",alt:"Logo",width:32,height:32,className:"h-6 md:h-8 w-auto filter drop-shadow-[0_0_5px_rgba(0,127,255,0.3)] transition-all group-hover:scale-110 group-hover:filter-drop-shadow-[0_0_8px_rgba(0,127,255,0.5)]"}),(0,a.jsx)("div",{className:"absolute -inset-3 bg-gradient-vibrant opacity-0 group-hover:opacity-30 rounded-full blur-md transition-all duration-500"}),(0,a.jsx)("div",{className:"absolute -inset-6 bg-electric-blue/10 opacity-0 group-hover:opacity-100 rounded-full blur-xl transition-all duration-500 animate-pulse"}),(0,a.jsx)("span",{className:"ml-2 text-white font-bold text-xl sr-only",children:"Cable Creations"})]})})})})}),(0,a.jsx)("nav",{className:"hidden md:flex z-10 h-full items-stretch justify-center nav-container",children:(0,a.jsx)("ul",{className:"flex items-stretch h-full",children:P.map((e,t)=>(0,a.jsx)("li",{className:"h-full flex items-stretch ".concat(0===t?"border-l border-white/10":""),children:(0,a.jsx)("div",{className:"border-r border-white/10 h-full nav-item-container",children:(0,a.jsx)(m,{href:e.href,label:e.label,isActive:L(e.href),onClick:()=>{console.log("Navigating to ".concat(e.href))}})})},e.key))})}),(0,a.jsx)("div",{className:"px-4 md:px-8 flex items-center justify-end h-full py-2 md:py-3",children:(0,a.jsxs)("div",{className:"flex items-center z-10 gap-2 md:gap-4 md:w-auto w-[120px] md:w-[240px] justify-end overflow-visible",children:[T.NEXT_PUBLIC_ENABLE_CART&&(0,a.jsx)(N,{}),T.NEXT_PUBLIC_ENABLE_WISHLIST&&(0,a.jsx)(S,{className:"hidden md:block"}),T.NEXT_PUBLIC_ENABLE_USER_MENU&&(0,a.jsx)(x.B,{translations:{account:e("account"),login:e("login"),signup:e("signup"),logout:e("logout"),wishlist:e("wishlist"),orders:e("orders")},locale:t}),(0,a.jsx)(d.P.div,{className:"flex md:hidden",whileHover:{scale:1.1},whileTap:{scale:.95},children:(0,a.jsxs)("button",{type:"button",className:"inline-flex items-center justify-center p-2 rounded-full text-white hover:bg-glass-bg-light focus:outline-hidden border border-transparent hover:border-electric-blue/20 transition-all duration-300 hover:shadow-glow","aria-controls":"mobile-menu","aria-expanded":o,onClick:()=>{h(!o)},children:[(0,a.jsx)("span",{className:"sr-only",children:"Open main menu"}),(0,a.jsx)("div",{className:"h-6 w-6 text-electric-blue/90",children:o?(0,a.jsx)(R,{}):(0,a.jsx)(M,{})})]})})]})})]}),(0,a.jsx)(u.N,{children:o&&(0,a.jsxs)(d.P.div,{className:"md:hidden absolute top-full left-0 w-full mt-3 rounded-xl bg-glass-bg border border-glass-border shadow-glow overflow-hidden z-50",style:{background:"rgba(10, 10, 15, 0.95)",WebkitBackdropFilter:"blur(0px)"},id:"mobile-menu",initial:"closed",animate:"open",exit:"closed",variants:W,children:[(0,a.jsx)("div",{className:"absolute inset-0 z-0 opacity-30 pointer-events-none",style:{background:"linear-gradient(to bottom, rgba(255,255,255,0.05) 0%, transparent 100%)"}}),(0,a.jsx)("div",{className:"absolute inset-0 z-0 pointer-events-none",children:[void 0,void 0,void 0,void 0,void 0].map((e,t)=>(0,a.jsx)("div",{className:"absolute rounded-full bg-electric-blue/20 animate-float-subtle",style:{width:"".concat(2+3*Math.random(),"px"),height:"".concat(2+3*Math.random(),"px"),left:"".concat(100*Math.random(),"%"),top:"".concat(100*Math.random(),"%"),animationDelay:"".concat(2*Math.random(),"s"),opacity:.5+.5*Math.random()}},t))}),(0,a.jsxs)("div",{className:"px-3 pt-3 pb-4 space-y-2 relative z-10",children:[E&&T.NEXT_PUBLIC_ENABLE_USER_MENU&&(0,a.jsxs)("div",{className:"mb-3 border-b border-white/10 pb-3",children:[(0,a.jsx)("h3",{className:"px-4 py-2 text-xs uppercase text-white/50 font-medium tracking-wider",children:e("account")}),(0,a.jsx)(d.P.div,{variants:F,children:(0,a.jsx)(l(),{href:"/".concat(t,"/account"),className:"block px-4 py-3 rounded-lg text-base font-medium group transition-all duration-300 ".concat(i&&i==="/".concat(t,"/account")?"bg-glass-bg-light border border-electric-blue/30 shadow-glow":"text-gray-300 hover:text-white hover:bg-glass-bg-light hover:border hover:border-electric-blue/10"),onClick:()=>h(!1),children:(0,a.jsxs)("div",{className:"flex items-center",children:[(0,a.jsx)("div",{className:"mr-3 ".concat(i&&i==="/".concat(t,"/account")?"text-electric-blue":"text-gray-400 group-hover:text-electric-blue/70"),children:(0,a.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,a.jsx)("path",{d:"M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2"}),(0,a.jsx)("circle",{cx:"12",cy:"7",r:"4"})]})}),(0,a.jsx)("span",{className:i&&i==="/".concat(t,"/account")?"text-electric-blue font-medium":"group-hover:text-electric-blue/90 transition-colors duration-300",children:e("account")})]})})}),(0,a.jsx)(d.P.div,{variants:F,children:(0,a.jsx)(l(),{href:"/".concat(t,"/account/orders"),className:"block px-4 py-3 rounded-lg text-base font-medium group transition-all duration-300 ".concat(_("/account/orders")?"bg-glass-bg-light border border-electric-blue/30 shadow-glow":"text-gray-300 hover:text-white hover:bg-glass-bg-light hover:border hover:border-electric-blue/10"),onClick:()=>h(!1),children:(0,a.jsxs)("div",{className:"flex items-center",children:[(0,a.jsx)("div",{className:"mr-3 ".concat(_("/account/orders")?"text-electric-blue":"text-gray-400 group-hover:text-electric-blue/70"),children:(0,a.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,a.jsx)("path",{d:"M16 11V7a4 4 0 00-8 0v4M5 9h14l1 12H4L5 9z"})})}),(0,a.jsx)("span",{className:_("/account/orders")?"text-electric-blue font-medium":"group-hover:text-electric-blue/90 transition-colors duration-300",children:e("orders")})]})})}),T.NEXT_PUBLIC_ENABLE_WISHLIST&&(0,a.jsx)(d.P.div,{variants:F,children:(0,a.jsx)(l(),{href:"/".concat(t,"/account/wishlist"),className:"block px-4 py-3 rounded-lg text-base font-medium group transition-all duration-300 ".concat(_("/account/wishlist")?"bg-glass-bg-light border border-electric-blue/30 shadow-glow":"text-gray-300 hover:text-white hover:bg-glass-bg-light hover:border hover:border-electric-blue/10"),onClick:()=>h(!1),children:(0,a.jsxs)("div",{className:"flex items-center",children:[(0,a.jsx)("div",{className:"mr-3 ".concat(_("/account/wishlist")?"text-electric-blue":"text-gray-400 group-hover:text-electric-blue/70"),children:(0,a.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:(0,a.jsx)("path",{d:"M20.84 4.61a5.5 5.5 0 0 0-7.78 0L12 5.67l-1.06-1.06a5.5 5.5 0 0 0-7.78 7.78l1.06 1.06L12 21.23l7.78-7.78 1.06-1.06a5.5 5.5 0 0 0 0-7.78z"})})}),(0,a.jsx)("span",{className:_("/account/wishlist")?"text-electric-blue font-medium":"group-hover:text-electric-blue/90 transition-colors duration-300",children:e("wishlist")})]})})})]}),(0,a.jsx)("h3",{className:"px-4 py-2 text-xs uppercase text-white/50 font-medium tracking-wider",children:e("navigation")}),P.map(e=>(0,a.jsx)(d.P.div,{variants:F,children:L(e.href)?(0,a.jsx)("div",{className:"block px-4 py-3 rounded-lg text-base font-medium group transition-all duration-300 bg-glass-bg-light border border-electric-blue/30 shadow-glow cursor-default","aria-current":"page",children:(0,a.jsxs)("div",{className:"flex items-center",children:[(0,a.jsx)("div",{className:"mr-3 text-electric-blue",children:(0,a.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:e.href.includes("products")?(0,a.jsx)("path",{d:"M21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16z"}):e.href.includes("services")?(0,a.jsxs)(a.Fragment,{children:[" ",(0,a.jsx)("rect",{x:"2",y:"7",width:"20",height:"14",rx:"2",ry:"2"}),(0,a.jsx)("path",{d:"M16 21V5a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16"})]}):e.href.includes("contact")?(0,a.jsxs)(a.Fragment,{children:[" ",(0,a.jsx)("path",{d:"M4 4h16c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2z"}),(0,a.jsx)("polyline",{points:"22,6 12,13 2,6"})]}):e.href.includes("about")?(0,a.jsxs)(a.Fragment,{children:[" ",(0,a.jsx)("circle",{cx:"12",cy:"12",r:"10"}),(0,a.jsx)("line",{x1:"12",y1:"16",x2:"12",y2:"12"}),(0,a.jsx)("line",{x1:"12",y1:"8",x2:"12.01",y2:"8"})]}):(0,a.jsx)("path",{d:"M3 9l9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z"})})}),(0,a.jsxs)("span",{className:"text-electric-blue font-medium",children:[e.label,(0,a.jsx)("span",{className:"sr-only",children:"(current page)"})]})]})}):(0,a.jsx)(l(),{href:e.href,className:"block px-4 py-3 rounded-lg text-base font-medium group transition-all duration-300 text-gray-300 hover:text-white hover:bg-glass-bg-light hover:border hover:border-electric-blue/10",onClick:()=>h(!1),children:(0,a.jsxs)("div",{className:"flex items-center",children:[(0,a.jsx)("div",{className:"mr-3 text-gray-400 group-hover:text-electric-blue/70",children:(0,a.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:e.href.includes("products")?(0,a.jsx)("path",{d:"M21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16z"}):e.href.includes("services")?(0,a.jsxs)(a.Fragment,{children:[" ",(0,a.jsx)("rect",{x:"2",y:"7",width:"20",height:"14",rx:"2",ry:"2"}),(0,a.jsx)("path",{d:"M16 21V5a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16"})]}):e.href.includes("contact")?(0,a.jsxs)(a.Fragment,{children:[" ",(0,a.jsx)("path",{d:"M4 4h16c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2z"}),(0,a.jsx)("polyline",{points:"22,6 12,13 2,6"})]}):e.href.includes("about")?(0,a.jsxs)(a.Fragment,{children:[" ",(0,a.jsx)("circle",{cx:"12",cy:"12",r:"10"}),(0,a.jsx)("line",{x1:"12",y1:"16",x2:"12",y2:"12"}),(0,a.jsx)("line",{x1:"12",y1:"8",x2:"12.01",y2:"8"})]}):(0,a.jsx)("path",{d:"M3 9l9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z"})})}),(0,a.jsx)("span",{className:"group-hover:text-electric-blue/90 transition-colors duration-300",children:e.label})]})})},e.href))]})]})})]})}var F=i(35624),D=i(96110),X=i(41589),H=i(23854);function V(e){let{href:t,children:i,className:r="",showArrow:n=!0,underlineOnHover:s=!0,external:o=!1}=e,c="".concat("text-gray-400 hover:text-electric-blue transition-all duration-300 flex items-center group cursor-pointer"," ").concat(r),u=(0,a.jsxs)(a.Fragment,{children:[n&&(0,a.jsx)("span",{className:"mr-2 opacity-0 group-hover:opacity-100 transition-all duration-300 transform translate-x-0 group-hover:translate-x-1 text-electric-blue",children:"›"}),(0,a.jsx)("span",{className:"group-hover:translate-x-1 transition-transform duration-300",children:i}),s&&(0,a.jsx)(d.P.span,{className:"absolute bottom-0 left-0 h-[1px] bg-electric-blue/30",initial:{width:0},whileHover:{width:"100%"},transition:{duration:.3}})]});return o?(0,a.jsx)("a",{href:t,className:c,target:"_blank",rel:"noopener noreferrer",children:u}):(0,a.jsx)(l(),{href:t,className:c,children:u})}var q=i(43486),G=i(15590);function Y(e){let{className:t="",color:i="text-electric-pink",size:r="mx-1",animationDuration:n=2}=e;return(0,a.jsx)(d.P.span,{className:"".concat(i," ").concat(r," inline-block ").concat(t),animate:{scale:[1,1.2,1],opacity:[.7,1,.7]},transition:{duration:n,repeat:1/0,repeatType:"loop"},children:"♥"})}var K=i(34477);let J=(0,K.createServerReference)("60c939a19cbea59286e6fa31306c181e32b62cbac9",K.callServer,void 0,K.findSourceMapURL,"subscribeToNewsletter");var Z=i(86442);let $={success:!1,message:"",errors:{}};function Q(e){var t,i,s,o,l,c;let{className:h="",onSubscribe:m,buttonText:p,placeholderText:x,successMessage:g="Thanks for subscribing!",buttonVariant:v="primary",buttonSize:f="small"}=e,y=(0,n.useClientTranslations)("Footer"),[w,j]=(0,r.useTransition)(),N=p||y("newsletter.subscribeButton"),[k,C]=(0,r.useState)(""),[E,S]=(0,r.useState)(!1),[P,L]=(0,r.useState)(!1),[_,T]=(0,r.useState)(""),[I,B]=(0,r.useState)(!1),[M,R]=(0,r.useState)(!1),[O,A]=(0,r.useState)(!1),U=(0,r.useRef)(null),z=(0,r.useRef)(null),W=(0,r.useRef)(null),[F,D]=(0,r.useActionState)(J,$);(0,r.useEffect)(()=>{T(Date.now().toString())},[]),(0,r.useEffect)(()=>{if(I){if((F.success||F.message&&!F.success)&&(W.current&&(clearTimeout(W.current),W.current=null),W.current=setTimeout(()=>{S(!1)},500)),F.success){(0,Z.sx)("newsletter_subscription_success",{email:k}),C(""),L(!0),A(!1),m&&m(k);let e=setTimeout(()=>{L(!1),B(!1)},5e3);return()=>clearTimeout(e)}F.message&&!F.success&&(0,Z.sx)("newsletter_subscription_failure",{email:k,error:F.message})}},[F,m,k,I]),(0,r.useEffect)(()=>()=>{W.current&&clearTimeout(W.current)},[]);let X={type:"spring",stiffness:200,damping:25};return(0,a.jsx)("div",{className:h,children:(0,a.jsx)(u.N,{mode:"wait",children:P?(0,a.jsxs)(d.P.div,{className:"relative",variants:{hidden:{opacity:0,scale:.8,y:20},visible:{opacity:1,scale:1,y:0,transition:{type:"spring",stiffness:300,damping:20}},exit:{opacity:0,scale:.9,y:-10,transition:{duration:.2}}},initial:"hidden",animate:"visible",exit:"exit",children:[(0,a.jsx)(d.P.div,{className:"absolute inset-0 bg-gradient-to-r from-electric-blue/20 to-teal-400/20 rounded-full blur-xl",initial:{scale:0,opacity:0},animate:{scale:1.2,opacity:1},transition:{delay:.1,duration:.6}}),(0,a.jsxs)("div",{className:"relative bg-glass-bg-light backdrop-blur-md border border-electric-blue/30 rounded-full px-6 py-4 text-sm text-white flex items-center justify-center shadow-glow",children:[(0,a.jsx)(d.P.div,{className:"mr-3",initial:{scale:0,rotate:-180},animate:{scale:1,rotate:0},transition:{type:"spring",stiffness:300,damping:20,delay:.2},children:(0,a.jsxs)("div",{className:"relative",children:[(0,a.jsx)(d.P.div,{className:"absolute inset-0 bg-electric-blue/30 rounded-full",initial:{scale:0},animate:{scale:[0,1.2,1]},transition:{duration:.6,delay:.3}}),(0,a.jsx)("svg",{className:"w-6 h-6 text-electric-blue relative z-10",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,a.jsx)(d.P.path,{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.5,d:"M5 13l4 4L19 7",initial:{pathLength:0},animate:{pathLength:1},transition:{duration:.5,delay:.4}})})]})}),(0,a.jsxs)(d.P.div,{className:"flex flex-col",initial:{opacity:0,x:20},animate:{opacity:1,x:0},transition:{delay:.5,duration:.3},children:[(0,a.jsx)("span",{className:"font-medium text-white",children:F.message||g}),(0,a.jsx)(d.P.span,{className:"text-xs text-white/70 mt-1",initial:{opacity:0},animate:{opacity:1},transition:{delay:.7,duration:.3},children:"Check your inbox for confirmation"})]}),[...Array(6)].map((e,t)=>(0,a.jsx)(d.P.div,{className:"absolute w-1 h-1 bg-electric-blue rounded-full",initial:{scale:0,x:0,y:0},animate:{scale:[0,1,0],x:40*Math.cos(60*t*Math.PI/180),y:40*Math.sin(60*t*Math.PI/180)},transition:{duration:1,delay:.6+.1*t,ease:"easeOut"}},t))]})]}):(0,a.jsxs)(d.P.form,{ref:U,action:D,onSubmit:e=>{U.current&&(S(!0),B(!0))},className:"flex flex-col sm:flex-row gap-2",initial:{opacity:0,y:10},animate:{opacity:1,y:0},exit:{opacity:0,y:-10},transition:X,children:[(0,a.jsx)("input",{type:"text",name:"honeypot",className:"hidden",tabIndex:-1,autoComplete:"off"}),(0,a.jsx)("input",{type:"hidden",name:"submitTimestamp",value:_}),(0,a.jsx)("input",{type:"hidden",name:"source",value:"website"}),(0,a.jsxs)("div",{className:"relative flex-1",children:[(0,a.jsx)(d.P.input,{ref:z,type:"email",name:"email",value:k,onChange:e=>{let t=e.target.value;C(t),R(/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(t)),A(t.length>0),I&&(B(!1),L(!1)),1===t.length&&0===k.length&&T(Date.now().toString())},placeholder:x||y("newsletter.emailPlaceholder"),className:"bg-glass-bg-light backdrop-blur-md border rounded-full px-4 py-2 pr-10 text-sm text-white focus:outline-hidden focus:ring-2 focus:ring-electric-blue/30 w-full transition-all duration-200 ".concat(E||w?"opacity-75 cursor-not-allowed":""),required:!0,disabled:E||w,"aria-invalid":(null===(t=F.errors)||void 0===t?void 0:t.email)?"true":"false","aria-describedby":(null===(i=F.errors)||void 0===i?void 0:i.email)?"email-error":void 0,variants:{idle:{scale:1,borderColor:"rgba(255, 255, 255, 0.1)"},focused:{scale:1.02,borderColor:"rgba(0, 113, 227, 0.5)",transition:X},valid:{borderColor:"rgba(79, 209, 181, 0.5)",transition:X},invalid:{borderColor:"rgba(239, 68, 68, 0.5)",transition:X},loading:{scale:.98,borderColor:"rgba(0, 113, 227, 0.3)",transition:X}},initial:"idle",animate:E||w?"loading":O?M?"valid":"invalid":"idle",whileFocus:"focused"}),(0,a.jsxs)(u.N,{children:[O&&!(E||w)&&(0,a.jsx)(d.P.div,{className:"absolute right-3 top-1/2 transform -translate-y-1/2",initial:{opacity:0,scale:.5},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.5},transition:{duration:.2},children:M?(0,a.jsx)("svg",{className:"w-4 h-4 text-teal-400",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24","aria-label":"Valid email",children:(0,a.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M5 13l4 4L19 7"})}):(0,a.jsx)("svg",{className:"w-4 h-4 text-red-400",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24","aria-label":"Invalid email",children:(0,a.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})}),(E||w)&&(0,a.jsx)(d.P.div,{className:"absolute right-3 top-1/2 transform -translate-y-1/2",initial:{opacity:0,scale:.5},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.5},transition:{duration:.2},children:(0,a.jsxs)(d.P.svg,{className:"w-4 h-4 text-electric-blue",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",animate:{rotate:360},transition:{duration:1,repeat:1/0,ease:"linear"},children:[(0,a.jsx)("circle",{className:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),(0,a.jsx)("path",{className:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})]})})]})]}),(0,a.jsx)(d.P.div,{variants:{idle:{scale:1},hover:{scale:1.05},tap:{scale:.95},loading:{scale:1,transition:{duration:.2}}},initial:"idle",whileHover:E||w?"loading":"hover",whileTap:E||w?"loading":"tap",animate:E||w?"loading":"idle",children:(0,a.jsx)(b.Button,{type:"submit",variant:v,size:f,className:"whitespace-nowrap relative overflow-hidden",disabled:E||w||O&&!M,children:(0,a.jsx)(u.N,{mode:"wait",children:E||w?(0,a.jsxs)(d.P.span,{className:"flex items-center",initial:{opacity:0,y:20},animate:{opacity:1,y:0},exit:{opacity:0,y:-20},transition:{duration:.2},children:[(0,a.jsxs)(d.P.svg,{className:"w-4 h-4 text-white mr-2",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",animate:{rotate:360},transition:{duration:1,repeat:1/0,ease:"linear"},children:[(0,a.jsx)("circle",{className:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),(0,a.jsx)("path",{className:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})]}),y("newsletter.subscribing")]},"loading"):(0,a.jsx)(d.P.span,{initial:{opacity:0,y:20},animate:{opacity:1,y:0},exit:{opacity:0,y:-20},transition:{duration:.2},children:N},"idle")})})}),(null===(s=F.errors)||void 0===s?void 0:s.email)&&(0,a.jsx)(d.P.p,{className:"text-red-400 text-xs mt-1",initial:{opacity:0,y:-5},animate:{opacity:1,y:0},transition:X,children:F.errors.email[0]}),(null===(o=F.errors)||void 0===o?void 0:o.submitTimestamp)&&(0,a.jsx)(d.P.p,{className:"text-red-400 text-xs mt-1",initial:{opacity:0,y:-5},animate:{opacity:1,y:0},transition:X,children:"Please wait a moment before submitting the form."}),I&&F.message&&!F.success&&!(null===(l=F.errors)||void 0===l?void 0:l.email)&&!(null===(c=F.errors)||void 0===c?void 0:c.submitTimestamp)&&(0,a.jsx)(d.P.p,{className:"text-red-400 text-xs mt-1",initial:{opacity:0,y:-5},animate:{opacity:1,y:0},transition:X,children:F.message})]})})})}function ee(e){let{socialMediaLinks:t}=e,i=(0,n.useClientTranslations)("Footer"),s=(0,n.useClientLocale)(),{showPreferencesModal:o}=(0,F.uC)(),{openModal:u}=(0,D.p)(),[m,p]=(0,r.useState)([]);(0,r.useEffect)(()=>{let e=z(),t={title:i("sections.legal"),links:[{href:"/".concat(s,"/terms"),label:i("terms")},{href:"/".concat(s,"/privacy"),label:i("privacy")},{href:"#",label:i("cookies"),action:()=>o()}]};if(!(e.NEXT_PUBLIC_FOOTER_SHOW_PRODUCTS&&e.NEXT_PUBLIC_ENABLE_PRODUCTS_LISTING&&e.NEXT_PUBLIC_ENABLE_SERVICES)){p([t]);return}try{let a=e.NEXT_PUBLIC_FOOTER_PRODUCTS_LINKS||[];p([{title:i("sections.products"),links:a.map(e=>({href:"/".concat(s).concat(e.href),label:e.label}))},t])}catch(e){console.error("Error updating footer sections:",e),p([t])}},[s]);let x={type:"spring",stiffness:200,damping:25},g={hidden:{opacity:0},visible:{opacity:1,transition:{staggerChildren:.1,delayChildren:.1}}},v={hidden:{opacity:0,y:20},visible:{opacity:1,y:0,transition:x}};return(0,a.jsx)(X.A,{children:(0,a.jsxs)(d.P.footer,{className:"bg-dark-black border-t border-white/5 relative overflow-hidden hidden md:block z-[var(--z-index-footer)]",initial:"hidden",whileInView:"visible",viewport:{once:!0,amount:.1},variants:g,children:[(0,a.jsx)(G.GradientLine,{color:"blue",position:"top",distance:0,animate:!0}),(0,a.jsx)("div",{className:"absolute inset-0 bg-radial-gradient-blue opacity-10"}),(0,a.jsxs)("div",{className:"container mx-auto px-4 sm:px-6 lg:px-8 py-16 relative z-10",children:[(0,a.jsxs)(d.P.div,{className:"grid grid-cols-1 sm:grid-cols-2 md:grid-cols-6 gap-8 mb-12",variants:g,children:[(0,a.jsxs)(d.P.div,{className:"col-span-1 sm:col-span-2",variants:v,children:[(0,a.jsx)(l(),{href:"/".concat(s),className:"inline-block mb-4",children:(0,a.jsx)(d.P.div,{className:"relative group",whileHover:{scale:1.05},whileTap:{scale:.98},transition:x,children:(0,a.jsxs)("div",{className:"relative flex items-center",children:[(0,a.jsx)(c.default,{src:"/img/logo-white.svg",alt:"Logo",width:32,height:32,className:"h-8 w-auto filter drop-shadow-[0_0_5px_rgba(0,127,255,0.3)] transition-all group-hover:scale-110 group-hover:filter-drop-shadow-[0_0_8px_rgba(0,127,255,0.5)]"}),(0,a.jsx)("span",{className:"ml-3 text-white font-bold text-xl sr-only",children:"Cable Creations"}),(0,a.jsx)("div",{className:"absolute -inset-3 bg-gradient-vibrant opacity-0 group-hover:opacity-30 rounded-full blur-md transition-all duration-500"}),(0,a.jsx)("div",{className:"absolute -inset-6 bg-electric-blue/10 opacity-0 group-hover:opacity-100 rounded-full blur-xl transition-all duration-500 animate-pulse"})]})})}),(0,a.jsx)(d.P.p,{className:"text-gray-400 text-sm mb-6 max-w-xs",variants:v,children:i("description")}),(0,a.jsx)(d.P.div,{className:"flex space-x-4",variants:g,children:t.map(e=>(0,a.jsx)(H.b,{href:"LinkedIn"===e.name?"https://www.linkedin.com/company/101094754":"Instagram"===e.name?"https://instagram.com/cablecreations.de":e.url,label:e.name,icon:e.icon||e.name.toLowerCase()},e.url))})]}),m.map((e,t)=>(0,a.jsxs)(d.P.div,{className:"col-span-1",variants:v,custom:t,children:[(0,a.jsx)(h.y,{as:"h3",gradient:"cool",className:"font-semibold text-lg mb-4",children:e.title}),(0,a.jsx)(d.P.ul,{className:"space-y-2",variants:g,children:e.links.map((e,t)=>(0,a.jsx)(d.P.li,{variants:v,children:e.action?(0,a.jsxs)("button",{onClick:e.action,className:"text-gray-400 hover:text-electric-blue transition-all duration-300 flex items-center group cursor-pointer relative",children:[(0,a.jsx)("span",{className:"mr-2 opacity-0 group-hover:opacity-100 transition-all duration-300 transform translate-x-0 group-hover:translate-x-1 text-electric-blue",children:"›"}),(0,a.jsx)("span",{className:"group-hover:translate-x-1 transition-transform duration-300",children:e.label}),(0,a.jsx)(d.P.span,{className:"absolute bottom-0 left-0 h-[1px] bg-electric-blue/30",initial:{width:0},whileHover:{width:"100%"},transition:{duration:.3}})]}):e.href?(0,a.jsx)(V,{href:e.href,children:e.label}):null},e.label||"link-".concat(t)))})]},e.title)),(0,a.jsxs)(d.P.div,{className:"col-span-1 sm:col-span-2 md:col-span-2",variants:v,children:[(0,a.jsx)(h.y,{as:"h3",gradient:"vibrant",className:"font-semibold text-lg mb-4",children:i("newsletter.title")}),(0,a.jsx)(d.P.p,{className:"text-gray-400 text-sm mb-4",variants:v,children:i("newsletter.description")}),(0,a.jsx)(Q,{})]})]}),(0,a.jsx)(q.J,{color:"blue",animate:!0,sides:["top"],position:"outside",distance:0,children:(0,a.jsxs)(d.P.div,{className:"border-t border-white/5 pt-8 flex flex-col md:flex-row justify-between items-center",variants:g,children:[(0,a.jsxs)(d.P.div,{className:"flex flex-col md:flex-row items-center gap-4 md:gap-8",variants:v,children:[(0,a.jsxs)("div",{className:"relative",children:[(0,a.jsx)(G.GradientLine,{color:"blue"}),(0,a.jsx)("p",{className:"text-gray-400 text-sm hover:text-gray-300 transition-colors duration-300",children:i("copyright")})]}),(0,a.jsx)("div",{className:"relative",children:(0,a.jsx)("button",{onClick:()=>o(),className:"text-sm text-white/60 hover:text-white/80 transition-colors cursor-pointer",children:i("footer.managePreferences")})})]}),(0,a.jsxs)(d.P.div,{className:"mt-4 md:mt-0 relative",variants:v,children:[(0,a.jsx)(G.GradientLine,{color:"pink"}),(0,a.jsxs)("p",{className:"text-gray-400 text-sm hover:text-gray-300 transition-colors duration-300 flex items-center",children:[i("designedWith")," ",(0,a.jsx)(Y,{})," ",i("forCreatives")]})]})]})})]})]})})}function et(e){let{socialMediaLinks:t}=e,i=(0,n.useClientTranslations)("Footer"),s=(0,n.useClientLocale)(),{openModal:o}=(0,D.p)(),{showPreferencesModal:u}=(0,F.uC)(),[h,m]=(0,r.useState)([]);(0,r.useEffect)(()=>{let e=z(),t=[{href:"/".concat(s,"/contact"),label:"Contact"},{href:"/".concat(s,"/terms"),label:"Terms"},{href:"/".concat(s,"/privacy"),label:"Privacy"},{href:"#",label:"Cookies",action:()=>u()},{href:"#",label:i("brochure")||"Brochure",action:()=>o()}];if(e.NEXT_PUBLIC_FOOTER_SHOW_PRODUCTS&&e.NEXT_PUBLIC_ENABLE_PRODUCTS_LISTING&&e.NEXT_PUBLIC_ENABLE_SERVICES)try{let i=(e.NEXT_PUBLIC_FOOTER_PRODUCTS_LINKS||[]).map(e=>({href:"/".concat(s).concat(e.href),label:e.label}));m([...i,...t])}catch(e){console.error("Error processing product links:",e),m(t)}else m(t)},[s]);let p={hidden:{opacity:0},visible:{opacity:1,transition:{staggerChildren:.1,delayChildren:.1}}},x={hidden:{opacity:0,y:20},visible:{opacity:1,y:0,transition:{type:"spring",stiffness:200,damping:25}}};return(0,a.jsxs)(d.P.footer,{className:"bg-dark-black border-t border-white/5 relative overflow-hidden block md:hidden pb-[var(--mobile-nav-height)]",initial:"hidden",whileInView:"visible",viewport:{once:!0,amount:.1},variants:p,children:[(0,a.jsx)(G.GradientLine,{color:"blue",position:"top",distance:0,animate:!0}),(0,a.jsx)("div",{className:"absolute inset-0 bg-radial-gradient-blue opacity-10"}),(0,a.jsxs)("div",{className:"container mx-auto px-4 py-4 relative z-10",children:[(0,a.jsxs)(d.P.div,{className:"flex flex-col items-start mb-4",variants:x,children:[(0,a.jsx)(l(),{href:"/".concat(s),className:"inline-block mb-4",children:(0,a.jsx)("div",{className:"relative flex items-center",children:(0,a.jsx)(c.default,{src:"/img/logo-white.svg",alt:"Logo",width:28,height:28,className:"h-7 w-auto filter drop-shadow-[0_0_5px_rgba(0,127,255,0.3)]"})})}),(0,a.jsx)(d.P.p,{className:"text-gray-400 text-xs text-left mb-3 max-w-xs",variants:x,children:"Premium digital assets for creative professionals. High-quality visualizations for your projects."}),(0,a.jsx)(d.P.div,{className:"flex space-x-3 mb-6",variants:p,children:t.map(e=>(0,a.jsx)(H.b,{href:"LinkedIn"===e.name?"https://www.linkedin.com/company/101094754":"Instagram"===e.name?"https://instagram.com/cablecreations.de":e.url,label:e.name,icon:e.icon||e.name.toLowerCase(),className:"w-8 h-8"},e.url))})]}),(0,a.jsx)(d.P.div,{className:"flex flex-wrap justify-center gap-4 mb-6",variants:p,children:h.map((e,t)=>(0,a.jsx)(d.P.div,{variants:x,children:e.action?(0,a.jsx)("button",{onClick:()=>e.action&&e.action(),className:"text-xs text-gray-300 hover:text-white transition-colors cursor-pointer",children:e.label}):(0,a.jsx)(V,{href:e.href||"#",className:"text-xs text-gray-300",children:e.label})},e.label||"link-".concat(t)))}),(0,a.jsx)(d.P.div,{className:"border-t border-white/5 pt-4 flex flex-col items-center",variants:p,children:(0,a.jsxs)(d.P.div,{variants:x,children:[(0,a.jsx)("div",{className:"relative",children:(0,a.jsx)("p",{className:"text-gray-400 text-xs text-center mb-2",children:i("copyright")})}),(0,a.jsx)("div",{className:"relative text-center",children:(0,a.jsx)("button",{onClick:()=>u(),className:"text-xs text-white/60 hover:text-white/80 transition-colors cursor-pointer",children:i("footer.managePreferences")})})]})})]})]})}var ei=i(881),ea=i(95627);function er(){let{navItems:e,isActive:t}=A(),i=(0,n.useClientLocale)(),o=(0,s.usePathname)(),[h,m]=(0,r.useState)(null),[p,x]=(0,r.useState)(!0),[g,v]=(0,r.useState)(!0),[f,b]=(0,r.useState)(!1),y=r.useRef(0),[w,j]=(0,r.useState)([]),[N,k]=(0,r.useState)([]),[C,E]=(0,r.useState)([]);(0,n.useClientTranslations)("Common");let S=(0,ea.s)(),P=e.slice(0,3),L=e.slice(3);(0,r.useEffect)(()=>{j([,,,,].fill(0).map((e,t)=>({id:t,width:1+2*Math.random(),height:1+2*Math.random(),left:"".concat(100*Math.random(),"%"),top:"".concat(100*Math.random(),"%"),duration:2+3*Math.random(),delay:2*Math.random()}))),k(Array(8).fill(0).map((e,t)=>({id:t,width:1+2*Math.random(),height:1+2*Math.random(),left:"".concat(100*Math.random(),"%"),top:"".concat(100*Math.random(),"%"),duration:2+3*Math.random(),delay:2*Math.random()}))),E(Array(12).fill(0).map((e,t)=>({id:t,width:1+3*Math.random(),height:1+3*Math.random(),left:"".concat(100*Math.random(),"%"),top:"".concat(100*Math.random(),"%"),duration:2+3*Math.random(),delay:2*Math.random()})))},[]),(0,r.useEffect)(()=>{let e=()=>{let e=window.scrollY;e>y.current+10?(v(!1),x(!1)):(e<y.current-10||e<=0)&&(v(!0),x(!0)),y.current=e};return window.addEventListener("scroll",e,{passive:!0}),()=>window.removeEventListener("scroll",e)},[]);let _=()=>{"undefined"!=typeof navigator&&navigator.vibrate&&navigator.vibrate(5),b(!f)},T=()=>{b(!1)};return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(d.P.div,{className:"fixed top-0 left-0 right-0 z-[100] md:hidden h-14 w-full px-0",initial:{y:-50},animate:{y:0,opacity:g?1:.8},transition:{type:"spring",stiffness:300,damping:30},children:(0,a.jsxs)("div",{className:"relative h-full flex items-center justify-center",children:[(0,a.jsx)("div",{className:"absolute inset-0 backdrop-blur-2xl",style:{background:"rgba(10, 10, 15, 0.65)",borderBottom:"1px solid rgba(255, 255, 255, 0.08)"}}),(0,a.jsx)("div",{className:"absolute inset-0 opacity-30 pointer-events-none",style:{background:"linear-gradient(to bottom, rgba(0,127,255,0.05) 0%, transparent 100%)"}}),(0,a.jsx)("div",{className:"absolute inset-0 overflow-hidden pointer-events-none",children:w.map(e=>(0,a.jsx)(d.P.div,{className:"absolute rounded-full bg-electric-blue/20",style:{width:"".concat(e.width,"px"),height:"".concat(e.height,"px"),left:e.left,top:e.top},animate:{y:[0,-5,0],opacity:[.2,.5,.2]},transition:{duration:e.duration,repeat:1/0,delay:e.delay}},e.id))}),(0,a.jsx)(l(),{href:"en"===i?"/":"/".concat(i),className:"relative z-10",children:(0,a.jsx)("div",{className:"flex items-center",children:(0,a.jsxs)("div",{className:"relative group",children:[(0,a.jsx)(c.default,{src:"/img/logo-white.svg",alt:"Logo",width:28,height:28,className:"h-7 w-auto filter drop-shadow-[0_0_5px_rgba(0,127,255,0.3)] transition-all"}),(0,a.jsx)(d.P.div,{className:"absolute -inset-3 bg-gradient-vibrant opacity-0 group-hover:opacity-30 rounded-full blur-md transition-all duration-500",animate:{opacity:[.05,.15,.05],scale:[1,1.1,1]},transition:{duration:3,repeat:1/0,ease:"easeInOut"}})]})})})]})}),(0,a.jsx)(d.P.nav,{className:"fixed bottom-0 left-0 right-0 z-[100] md:hidden w-full",initial:{y:100},animate:{y:0,height:p?"var(--mobile-nav-height)":"calc(var(--mobile-nav-height) - 12px)"},transition:{type:"spring",stiffness:400,damping:30,mass:.8},children:(0,a.jsxs)("div",{className:"relative bg-glass-bg backdrop-blur-2xl border-t border-glass-border px-2 py-1 h-full",style:{background:"rgba(10, 10, 15, 0.75)",boxShadow:"0 -8px 32px rgba(0, 10, 30, 0.2)"},children:[(0,a.jsx)("div",{className:"absolute inset-0 opacity-30 pointer-events-none",style:{background:"linear-gradient(to top, rgba(0,127,255,0.05) 0%, transparent 100%)",borderTop:"1px solid rgba(255, 255, 255, 0.08)"}}),(0,a.jsx)("div",{className:"absolute inset-0 overflow-hidden pointer-events-none",children:N.map(e=>(0,a.jsx)(d.P.div,{className:"absolute rounded-full bg-electric-blue/20",style:{width:"".concat(e.width,"px"),height:"".concat(e.height,"px"),left:e.left,top:e.top},animate:{y:[0,-10,0],opacity:[.2,.5,.2]},transition:{duration:e.duration,repeat:1/0,delay:e.delay}},e.id))}),(0,a.jsxs)("div",{className:"flex justify-around items-center h-full relative z-10",children:[P.map(e=>(0,a.jsx)(en,{href:e.href,label:e.label,icon:e.icon,isActive:t(e.href),showLabel:p,onTap:()=>m(e.key),isRecentlyTapped:h===e.key,onClick:T},e.key)),(0,a.jsx)(en,{href:"https://wa.me/4915678584306",label:"WhatsApp",icon:(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",className:"w-6 h-6",children:(0,a.jsx)("path",{fillRule:"evenodd",d:"M1.5 4.5a3 3 0 013-3h1.372c.86 0 1.61.586 1.819 1.42l1.105 4.423a1.875 1.875 0 01-.694 1.955l-1.293.97c-.135.101-.164.249-.126.352a11.285 11.285 0 006.697 6.697c.103.038.25.009.352-.126l.97-1.293a1.875 1.875 0 011.955-.694l4.423 1.105c.834.209 1.42.959 1.42 1.82V19.5a3 3 0 01-3 3h-2.25C8.552 22.5 1.5 15.448 1.5 6.75V4.5z",clipRule:"evenodd"})}),isActive:!1,showLabel:p,onTap:()=>{let e=new ei.XN({name:"whatsapp_button_click",timestamp:new Date,properties:{location:"mobile_nav"}});S.trackEvent(e)},isRecentlyTapped:"whatsapp"===h,onClick:()=>{window.open("https://wa.me/4915678584306","_blank")}},"whatsapp"),(0,a.jsxs)("div",{className:"relative flex flex-col items-center justify-center py-1 px-1 transition-all",style:{width:"25%",maxWidth:"76px"},children:[(0,a.jsxs)("button",{onClick:_,className:"w-full h-full flex flex-col items-center justify-center focus:outline-none touch-manipulation","aria-label":"Toggle menu","aria-expanded":f,style:{WebkitTapHighlightColor:"transparent"},children:[(0,a.jsx)(d.P.div,{className:"relative flex items-center justify-center ".concat(f?"text-electric-blue":"text-gray-400"),animate:{rotate:90*!!f,scale:f?1.1:1},transition:{type:"spring",stiffness:400,damping:15},children:(0,a.jsx)(d.P.div,{className:"w-6 h-6",whileHover:{scale:1.1},whileTap:{scale:.95},children:f?(0,a.jsx)(R,{}):(0,a.jsx)(M,{})})}),p&&(0,a.jsx)(d.P.span,{className:"text-xs font-medium mt-1 ".concat(f?"text-electric-blue":"text-gray-400"),initial:{opacity:0,height:0},animate:{opacity:1,height:"auto"},exit:{opacity:0,height:0},children:"Menu"})]}),(0,a.jsx)(u.N,{children:f&&(0,a.jsxs)(d.P.div,{className:"absolute bottom-0 w-10 h-1 rounded-t-full overflow-hidden",initial:{opacity:0,width:"30%",y:4},animate:{opacity:1,width:"50%",y:0},exit:{opacity:0,width:"30%",y:4},transition:{type:"spring",stiffness:500,damping:15},children:[(0,a.jsx)("div",{className:"absolute inset-0 bg-gradient-cool"}),(0,a.jsx)(d.P.div,{className:"absolute inset-0 bg-white/30",animate:{x:["0%","100%"],opacity:[0,.5,0]},transition:{duration:1.5,repeat:1/0,repeatDelay:1},style:{width:"50%",filter:"blur(4px)"}})]})})]})]})]})}),(0,a.jsx)(u.N,{children:f&&(0,a.jsxs)(d.P.div,{className:"fixed inset-0 z-[90] md:hidden",initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.2},children:[(0,a.jsx)(d.P.div,{className:"absolute inset-0 bg-black/70 backdrop-blur-lg",initial:{opacity:0,scale:1.05},animate:{opacity:1,scale:1},exit:{opacity:0,scale:1.05},transition:{duration:.3},onClick:_,children:(0,a.jsx)(d.P.div,{className:"absolute inset-0 opacity-20",style:{backgroundImage:"radial-gradient(circle at 30% 20%, rgba(0,127,255,0.2) 0%, transparent 50%)"},animate:{scale:[1,1.05,1],opacity:[.1,.2,.1]},transition:{duration:8,repeat:1/0,ease:"easeInOut"}})}),(0,a.jsxs)(d.P.div,{className:"absolute bottom-[var(--mobile-nav-height)] left-0 right-0 w-full bg-glass-bg border-t border-glass-border overflow-hidden z-[95]",initial:{height:0,opacity:0},animate:{height:"auto",opacity:1,transition:{height:{type:"spring",stiffness:300,damping:30},opacity:{duration:.3}}},exit:{height:0,opacity:0,transition:{height:{type:"spring",stiffness:400,damping:40},opacity:{duration:.2}}},style:{background:"rgba(10, 10, 15, 0.85)",boxShadow:"0 -8px 32px rgba(0, 10, 30, 0.4)"},children:[(0,a.jsx)(d.P.div,{className:"absolute inset-0 pointer-events-none",style:{background:"linear-gradient(to bottom, rgba(0,127,255,0.08) 0%, transparent 100%)"},animate:{opacity:[.3,.5,.3]},transition:{duration:4,repeat:1/0,ease:"easeInOut"}}),(0,a.jsx)("div",{className:"absolute inset-0 overflow-hidden pointer-events-none",children:C.map(e=>(0,a.jsx)(d.P.div,{className:"absolute rounded-full bg-electric-blue/30",style:{width:"".concat(e.width,"px"),height:"".concat(e.height,"px"),left:e.left,top:e.top},animate:{y:[0,-20],x:[0,(e.id%2==0?1:-1)*10],opacity:[0,.7,0]},transition:{duration:e.duration,repeat:1/0,delay:e.delay}},e.id))}),(0,a.jsxs)("div",{className:"p-5 max-h-[70vh] overflow-y-auto",children:[L.map((e,i)=>(0,a.jsx)(d.P.div,{initial:{opacity:0,y:20,scale:.95},animate:{opacity:1,y:0,scale:1,transition:{delay:.05*i+.2,type:"spring",stiffness:400,damping:30}},exit:{opacity:0,y:10,scale:.95,transition:{duration:.2}},className:"hidden",children:(0,a.jsxs)(l(),{href:e.href,className:"flex items-center p-3 rounded-xl transition-all ".concat(t(e.href)?"bg-glass-bg-light border border-electric-blue/30 text-electric-blue":"text-gray-300 hover:text-white hover:bg-glass-bg-light hover:border hover:border-electric-blue/10"),onClick:T,children:[(0,a.jsx)("div",{className:"mr-3 text-current",children:(0,a.jsx)("div",{className:"w-5 h-5",children:e.icon})}),(0,a.jsx)("span",{className:"font-medium text-sm",children:e.label}),t(e.href)&&(0,a.jsx)(d.P.div,{className:"absolute inset-0 rounded-xl bg-electric-blue/5",animate:{opacity:[.1,.2,.1]},transition:{duration:2,repeat:1/0,ease:"easeInOut"}})]})},e.key)),(0,a.jsx)(d.P.div,{className:"mt-4 pt-4",initial:{opacity:0},animate:{opacity:1},transition:{delay:.4},children:(0,a.jsx)("div",{className:"flex justify-center",children:(0,a.jsx)("div",{className:"relative flex p-1 bg-glass-bg-light rounded-full border border-white/10",children:O.IB.map(e=>{let t=e===i,r="en"===e?"\uD83C\uDDEC\uD83C\uDDE7":"de"===e?"\uD83C\uDDE9\uD83C\uDDEA":"\uD83C\uDF10",n=o||"/",s="en"===e?n.replace(/^\/[^\/]+/,"")||"/":n.replace(/^\/[^\/]+/,"/".concat(e))||"/".concat(e);return(0,a.jsx)(l(),{href:s,className:"relative z-10",onClick:T,children:(0,a.jsxs)("div",{className:"relative px-5 py-2 flex items-center justify-center",children:[t&&(0,a.jsx)(d.P.div,{className:"absolute inset-0 bg-electric-blue/10 rounded-full",layoutId:"languageHighlight",initial:!1,transition:{type:"spring",stiffness:300,damping:30},children:(0,a.jsx)(d.P.div,{className:"absolute inset-0 bg-gradient-cool opacity-30 rounded-full",animate:{opacity:[.2,.4,.2]},transition:{duration:2,repeat:1/0,ease:"easeInOut"}})}),(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{className:"text-lg",children:r}),(0,a.jsx)("span",{className:"font-medium text-sm ".concat(t?"text-electric-blue":"text-gray-300"),children:e.toUpperCase()})]})]})},e)})})})})]})]})]})})]})}function en(e){let{href:t,label:i,icon:r,isActive:n,showLabel:s,onTap:o,isRecentlyTapped:c,onClick:h}=e,m=()=>{"undefined"!=typeof navigator&&navigator.vibrate&&navigator.vibrate(n?[5,10,5]:10),o()};return(0,a.jsxs)(l(),{href:t,className:"relative flex flex-col items-center justify-center py-1 px-1 transition-all nav-touch-target nav-item nav-item-container",onClick:()=>{m(),h&&h()},style:{width:"25%",maxWidth:"76px",WebkitTapHighlightColor:"transparent",touchAction:"manipulation"},children:[n&&(0,a.jsx)(d.P.div,{className:"absolute inset-0 rounded-xl opacity-10 bg-electric-blue",initial:{opacity:0,scale:.8},animate:{opacity:.1,scale:1},exit:{opacity:0,scale:.8},transition:{duration:.3},style:{filter:"blur(8px)"}}),(0,a.jsxs)(d.P.div,{className:"relative flex items-center justify-center ".concat(n?"text-electric-blue":"text-gray-400"),animate:{y:c&&!n?-4:0,scale:n?1.1:1},whileTap:{y:-8},transition:{y:{type:"spring",stiffness:300,damping:10},scale:{type:"spring",stiffness:400,damping:15}},children:[(0,a.jsx)(d.P.div,{className:"w-6 h-6",whileHover:{scale:1.1},whileTap:{scale:.95},children:r}),(0,a.jsx)(u.N,{children:n&&(0,a.jsx)(d.P.div,{className:"absolute -top-0.5 -right-0.5 w-2 h-2 bg-electric-blue rounded-full",initial:{scale:0,opacity:0},animate:{scale:1,opacity:1},exit:{scale:0,opacity:0},transition:{type:"spring",stiffness:500,damping:15},children:(0,a.jsx)(d.P.div,{className:"absolute inset-0 bg-electric-blue rounded-full",animate:{scale:[1,1.8,1],opacity:[.7,.2,.7]},transition:{duration:2,repeat:1/0,ease:"easeInOut"}})})})]}),(0,a.jsx)(u.N,{children:s&&(0,a.jsx)(d.P.span,{className:"text-xs font-medium mt-1 ".concat(n?"text-electric-blue":"text-gray-400"),initial:{opacity:0,height:0,y:-5},animate:{opacity:1,height:"auto",y:0},exit:{opacity:0,height:0,y:-5},transition:{duration:.2},children:i})})]})}var es=i(8619),eo=i(70881);function el(e){let{isOpen:t,onClose:i,children:n,align:s="right",width:o="auto",className:l="",id:c}=e,h=(0,r.useRef)(null);(0,r.useEffect)(()=>{if(!t)return;let e=e=>{h.current&&!h.current.contains(e.target)&&i()},a=setTimeout(()=>{document.addEventListener("mousedown",e)},10);return()=>{clearTimeout(a),document.removeEventListener("mousedown",e)}},[t,i]);let[m,p]=(0,r.useState)({x:0,y:0}),x=(0,es.d)(0),g=(0,es.d)(0),v=(0,eo.G)(g,[-150,150],[1,-1]),f=(0,eo.G)(x,[-150,150],[-1,1]);(0,r.useEffect)(()=>{if(!t)return;let e=e=>{if(h.current){let t=h.current.getBoundingClientRect(),i=t.left+t.width/2,a=t.top+t.height/2,r=e.clientX-i,n=e.clientY-a;p({x:r,y:n}),x.set(r),g.set(n)}};return document.addEventListener("mousemove",e),()=>document.removeEventListener("mousemove",e)},[t,x,g]);let b=(0,r.useMemo)(()=>({default:{type:"spring",stiffness:380,damping:28,mass:.65},subtle:{type:"spring",stiffness:280,damping:24,mass:.55},quick:{type:"spring",stiffness:480,damping:32,mass:.45},elastic:{type:"spring",stiffness:420,damping:18,mass:.6}}),[]),y=(0,r.useMemo)(()=>({dropdown:{hidden:{opacity:0,y:-5,scale:.98,rotateX:5,transformOrigin:"left"===s?"top left":"right"===s?"top right":"top center",transition:{type:"tween",ease:"easeOut",duration:.15}},visible:{opacity:1,y:0,scale:1,rotateX:0,transformOrigin:"left"===s?"top left":"right"===s?"top right":"top center",transition:{type:"tween",ease:"easeOut",duration:.2}}},glass:{initial:{opacity:.7,scale:.98,filter:"blur(10px)"},animate:{opacity:1,scale:1,filter:"blur(0px)",transition:{opacity:{duration:.3},scale:b.subtle,filter:{duration:.25}}}},glow:{initial:{opacity:0},animate:{opacity:1,transition:{duration:.4}},exit:{opacity:0,transition:{duration:.2}}},content:{hidden:{opacity:0,y:-5},visible:{opacity:1,y:0,transition:{...b.default,staggerChildren:.04,delayChildren:.05}},exit:{opacity:0,y:-5,transition:{duration:.15,staggerChildren:.02,staggerDirection:-1}}}}),[b,s]);return(0,a.jsx)(u.N,{presenceAffectsLayout:!1,children:t&&(0,a.jsxs)(d.P.div,{id:c,ref:h,className:"absolute mt-2 rounded-lg overflow-hidden z-50 ".concat({left:"left-0",right:"right-0",center:"left-1/2 -translate-x-1/2"}[s]," ").concat(l),initial:"hidden",animate:"visible",exit:"hidden",variants:y.dropdown,style:{width:o,willChange:"transform, opacity, scale",contain:"layout",perspective:"1000px",transform:"perspective(1000px) rotateX(".concat(.3*v.get(),"deg) rotateY(").concat(.3*f.get(),"deg)")},layoutId:"dropdown-container",children:[(0,a.jsxs)(d.P.div,{className:"absolute inset-0 rounded-lg z-0 overflow-hidden",initial:"initial",animate:"animate",variants:y.glass,style:{background:"rgba(10, 10, 15, 0.5)",backdropFilter:"blur(15px)",WebkitBackdropFilter:"blur(15px)",border:"1px solid rgba(255, 255, 255, 0.1)",boxShadow:"0 10px 30px -5px rgba(0, 0, 0, 0.3), 0 0 15px rgba(0, 127, 255, 0.2)"},children:[(0,a.jsx)(d.P.div,{className:"absolute inset-x-0 top-0 h-[1px] bg-white/15 rounded-t-lg",initial:{scaleX:.7,opacity:0},animate:{scaleX:1,opacity:1},transition:{delay:.1,duration:.3}}),(0,a.jsx)(d.P.div,{className:"absolute inset-x-0 bottom-0 h-[1px] bg-black/20 rounded-b-lg",initial:{scaleX:.7,opacity:0},animate:{scaleX:1,opacity:1},transition:{delay:.1,duration:.3}}),(0,a.jsx)(d.P.div,{className:"absolute inset-0 z-0 pointer-events-none rounded-lg",initial:{opacity:0},animate:{opacity:.3},transition:{duration:.4},style:{background:"linear-gradient(to bottom, rgba(255,255,255,0.08) 0%, transparent 100%)"}}),(0,a.jsx)(d.P.div,{className:"absolute inset-0 rounded-lg",variants:y.glow,style:{boxShadow:"inset 0 0 15px rgba(0, 127, 255, 0.1)",pointerEvents:"none"}})]}),(0,a.jsx)(d.P.div,{className:"relative z-10",variants:y.content,children:n}),(0,a.jsx)(d.P.div,{className:"absolute inset-0 bg-electric-blue/5 rounded-lg pointer-events-none z-0",initial:{opacity:0},animate:{opacity:.03},transition:{duration:.3},style:{background:"radial-gradient(circle at ".concat(m.x+150,"px ").concat(m.y+150,"px, rgba(0, 127, 255, 0.1) 0%, transparent 70%)")}})]})})}let ec={hidden:{opacity:0,x:-3,y:-2,transition:{type:"tween",ease:"easeOut",duration:.15}},visible:{opacity:1,x:0,y:0,transition:{type:"tween",ease:"easeOut",duration:.2}},hover:{scale:1.01,x:1,backgroundColor:"rgba(0, 127, 255, 0.05)",transition:{type:"tween",ease:"easeOut",duration:.15}},tap:{scale:.99,transition:{type:"tween",ease:"easeOut",duration:.1}}};var ed=i(5138),eu=i(52014);let eh=(0,eu.withClientTranslations)(function(e){let{loc:t,currentLocale:i,getFlag:n,onClick:s,onHover:o,onLeave:l,isHovered:c,variant:m}=e,p=(0,ed.f)("Common.languageSelector"),[x,g]=(0,r.useState)(!1),v=(0,r.useRef)(null),f=(0,es.d)(0),b=(0,eo.G)(f,[-100,100],[-2,5]),y=t===i,w="en"===t?p("english",{defaultValue:"English"}):"de"===t?p("german",{defaultValue:"German"}):t.toUpperCase(),j="en"===t?"/":"/".concat(t);return(0,a.jsxs)(d.P.button,{ref:v,className:"w-full text-left px-4 py-2 text-xs font-medium transition-colors relative block cursor-pointer ".concat(y?"text-electric-blue bg-glass-bg-light":"text-white"),onClick:e=>{if(console.log("=== LANGUAGE SELECTOR CLICK ==="),console.log("Current locale: ".concat(i)),console.log("Selected locale: ".concat(t)),console.log("Is active: ".concat(y)),console.log("Generated href: ".concat(j)),console.log("Current URL: ".concat(window.location.href)),console.log("Current pathname: ".concat(window.location.pathname)),console.log("Current search: ".concat(window.location.search)),console.log("Current hash: ".concat(window.location.hash)),console.log("Current origin: ".concat(window.location.origin)),console.log("User agent: ".concat(navigator.userAgent)),console.log("==============================="),window.navigator&&"vibrate"in window.navigator)try{window.navigator.vibrate(5)}catch(e){}if(y){console.log("Same locale selected, preventing navigation"),e.preventDefault();return}e.preventDefault(),console.log("Calling onClick handler to close dropdown"),s(),console.log("Clearing NEXT_LOCALE cookie"),document.cookie="NEXT_LOCALE=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;",console.log("Setting window.location.href to: ".concat(j)),window.location.href=j,console.log("Navigation command executed")},onMouseEnter:()=>{g(!0),o()},onMouseLeave:()=>{g(!1),l()},onMouseMove:e=>{if(v.current){let t=v.current.getBoundingClientRect(),i=e.clientX-t.left;f.set(i-t.width/2)}},variants:ec,whileHover:"hover",whileTap:"tap",role:"option","aria-selected":y,style:{letterSpacing:"0.2px",textRendering:"optimizeLegibility"},children:[(0,a.jsxs)(d.P.span,{className:"relative flex items-center ".concat("flag"===m?"gap-2":""),variants:{initial:{x:0,opacity:.9},hover:{x:3,opacity:1,transition:{type:"spring",stiffness:300,damping:20}},active:{x:0,opacity:1,transition:{type:"spring",stiffness:400,damping:25}},tap:{scale:.98,x:1,transition:{type:"spring",stiffness:500,damping:30}}},animate:y?"active":x?"hover":"initial",style:{x:x&&!y?b:0},children:["flag"===m&&(0,a.jsx)(d.P.span,{className:"text-base",animate:{scale:x?1.05:1,rotate:3*!!x},transition:{scale:{duration:.2,ease:"easeOut"},rotate:{duration:.2,ease:"easeOut"}},children:n(t)}),y?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(h.y,{as:"span",gradient:"cool",className:"font-medium",children:w}),(0,a.jsx)(d.P.span,{className:"absolute -left-2 top-1/2 w-1 h-1 bg-electric-blue rounded-full",initial:{scale:0,y:"-50%"},animate:{scale:1,y:"-50%"},transition:{scale:{duration:.2},y:{duration:.2}}}),(0,a.jsx)(d.P.span,{className:"absolute inset-0 bg-electric-blue/5 rounded-sm",initial:{opacity:0},animate:{opacity:.5},transition:{duration:.3}})]}):(0,a.jsx)(d.P.span,{animate:{opacity:x?1:.9},transition:{duration:.2},children:w})]}),(0,a.jsx)(u.N,{children:(x||c)&&!y&&(0,a.jsx)(d.P.span,{className:"absolute inset-0 bg-electric-blue/5 rounded-sm",initial:{opacity:0},animate:{opacity:.5},exit:{opacity:0},transition:{duration:.2}})}),(0,a.jsx)(u.N,{children:x&&!y&&(0,a.jsx)(d.P.span,{className:"absolute inset-0 overflow-hidden rounded-sm pointer-events-none",initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.2},children:(0,a.jsx)(d.P.span,{className:"absolute inset-0 bg-gradient-to-r from-transparent via-white/10 to-transparent",initial:{x:"-100%"},animate:{x:"100%"},transition:{duration:.6,ease:"easeOut"}})})})]},t)},["Common"]),em={initial:{scale:1,boxShadow:"0 2px 10px rgba(0, 0, 0, 0.1), 0 0 1px rgba(255, 255, 255, 0.1)"},hover:{scale:1.05,boxShadow:"0 4px 15px rgba(0, 0, 0, 0.15), 0 0 2px rgba(255, 255, 255, 0.2), 0 0 5px rgba(0, 127, 255, 0.2)",transition:{type:"tween",ease:"easeOut",duration:.2}},tap:{scale:.96,boxShadow:"0 1px 5px rgba(0, 0, 0, 0.1), 0 0 1px rgba(255, 255, 255, 0.1)",transition:{type:"tween",ease:"easeOut",duration:.1}}},ep={initial:{x:"-100%",opacity:0},animate:{x:"100%",opacity:.7,transition:{duration:.6,ease:"easeOut"}}},ex=(0,r.forwardRef)((e,t)=>{let{onClick:i,isOpen:n,dropdownId:s,children:o,className:l="",style:c={},variants:h,...m}=e,[p,x]=(0,r.useState)(!1),g=(0,es.d)(0),v=(0,es.d)(0),f=(0,eo.G)(v,[-100,100],[1,-1]),b=(0,eo.G)(g,[-100,100],[-1,1]);return(0,a.jsxs)(d.P.button,{ref:t,className:"py-1.5 px-4 text-xs font-medium bg-glass-bg-light backdrop-blur-xl border border-glass-border rounded-full text-white focus:outline-hidden focus:ring-2 focus:ring-electric-blue/30 transition-colors will-change-transform cursor-pointer ".concat(l),onClick:e=>{if(e.preventDefault(),window.navigator&&"vibrate"in window.navigator)try{window.navigator.vibrate(10)}catch(e){}i()},onMouseEnter:()=>x(!0),onMouseLeave:()=>x(!1),onMouseMove:e=>{let t=e.currentTarget.getBoundingClientRect(),i=t.left+t.width/2,a=t.top+t.height/2;g.set(e.clientX-i),v.set(e.clientY-a)},"aria-expanded":n,"aria-haspopup":"listbox","aria-controls":s,"aria-label":"Toggle dropdown",initial:"initial",whileHover:"hover",whileTap:"tap",variants:h||em,style:{boxShadow:n?"0 4px 20px rgba(0, 0, 0, 0.15), 0 0 3px rgba(255, 255, 255, 0.2), 0 0 7px rgba(0, 127, 255, 0.25)":"0 2px 10px rgba(0, 0, 0, 0.1), 0 0 1px rgba(255, 255, 255, 0.1)",letterSpacing:"0.2px",textRendering:"optimizeLegibility",transform:p?"perspective(1000px) rotateX(".concat(.3*f.get(),"deg) rotateY(").concat(.3*b.get(),"deg)"):"none",...c},...m,children:[(0,a.jsx)(d.P.span,{className:"relative z-10 flex items-center justify-center",animate:{y:.5*!!n,scale:n?1.01:1},transition:{type:"tween",duration:.2,ease:"easeOut"},children:o}),(0,a.jsx)(d.P.span,{className:"absolute inset-0 rounded-full overflow-hidden pointer-events-none",initial:{opacity:.6},animate:{opacity:n?.9:.6},transition:{duration:.2},children:(0,a.jsx)(d.P.span,{className:"absolute inset-0 bg-gradient-to-r from-transparent via-white/15 to-transparent",variants:ep,initial:"initial",animate:p?"animate":"initial"})}),(0,a.jsx)(u.N,{children:n&&(0,a.jsx)(d.P.span,{className:"absolute inset-0 rounded-full pointer-events-none",initial:{opacity:0,scale:.95},animate:{opacity:1,scale:1},exit:{opacity:0,scale:1.05},transition:{type:"tween",ease:"easeOut",duration:.2},style:{boxShadow:"0 0 0 1px rgba(0, 127, 255, 0.3), 0 0 15px 2px rgba(0, 127, 255, 0.15)"}})}),(0,a.jsx)(u.N,{children:n&&(0,a.jsx)(d.P.span,{className:"absolute -bottom-0.5 left-1/2 w-1 h-1 bg-electric-blue rounded-full",initial:{scale:0,opacity:0,x:"-50%"},animate:{scale:1,opacity:1,x:"-50%"},exit:{scale:0,opacity:0,x:"-50%"},transition:{type:"tween",ease:"easeOut",duration:.2}})})]})});ex.displayName="DropdownButton";let eg=(0,r.forwardRef)((e,t)=>{let{onClick:i,isOpen:r,dropdownId:n,children:s,className:o="",style:l={},variants:c,...d}=e;return(0,a.jsx)(ex,{ref:t,onClick:i,isOpen:r,dropdownId:n,className:o,style:l,variants:c,"aria-label":"Select language",...d,children:s})});eg.displayName="LanguageSelectorButton";let ev=(0,eu.withClientTranslations)(function(e){let{locale:t,locales:i,className:o="",variant:l="full",translations:c={}}=e,m=(0,n.useClientTranslations)("Common.languageSelector"),p=(0,r.useCallback)(e=>{switch(e){case"en":return"\uD83C\uDDEC\uD83C\uDDE7";case"de":return"\uD83C\uDDE9\uD83C\uDDEA";default:return"\uD83C\uDF10"}},[]),[x,g]=(0,r.useState)(!1),v=(0,s.usePathname)()||"/";(0,s.useRouter)();let f=(0,r.useRef)(null),b=v.split("/").filter(Boolean),y=(0,r.useMemo)(()=>b.length>0&&("en"===b[0]||"de"===b[0])?b[0]:t,[v,t]),w=(0,r.useCallback)(()=>{g(e=>!e)},[]),j=(0,r.useMemo)(()=>({default:{type:"spring",stiffness:380,damping:28,mass:.65},subtle:{type:"spring",stiffness:280,damping:24,mass:.55},quick:{type:"spring",stiffness:480,damping:32,mass:.45},elastic:{type:"spring",stiffness:420,damping:18,mass:.6},precise:{type:"spring",stiffness:500,damping:40,mass:.4}}),[]),N=(0,es.d)(0),k=(0,es.d)(0);(0,r.useEffect)(()=>{let e=e=>{N.set(e.clientX),k.set(e.clientY)};return window.addEventListener("mousemove",e),()=>window.removeEventListener("mousemove",e)},[N,k]);let C=(0,r.useMemo)(()=>({button:{initial:{scale:1,boxShadow:"0 2px 10px rgba(0, 0, 0, 0.1), 0 0 1px rgba(255, 255, 255, 0.1)"},hover:{scale:1.05,boxShadow:"0 4px 15px rgba(0, 0, 0, 0.15), 0 0 2px rgba(255, 255, 255, 0.2), 0 0 5px rgba(0, 127, 255, 0.2)",transition:j.subtle},tap:{scale:.96,boxShadow:"0 1px 5px rgba(0, 0, 0, 0.1), 0 0 1px rgba(255, 255, 255, 0.1)",transition:j.quick}},arrow:{initial:{rotate:0,y:0,opacity:.9},open:{rotate:180,y:1,opacity:1,transition:{rotate:{...j.elastic,duration:.3},y:{...j.subtle,duration:.2},opacity:{duration:.2}}}},label:{initial:{opacity:.9,scale:1},hover:{opacity:1,scale:1.02,transition:{duration:.2}}},glow:{initial:{opacity:0,scale:.8},animate:{opacity:.5,scale:1.2,transition:{duration:2,repeat:1/0,repeatType:"loop",ease:"easeInOut",times:[0,.5,1],repeatDelay:.5}},exit:{opacity:0,scale:.8}},shine:{initial:{opacity:0,x:"-100%"},animate:{opacity:[0,.5,0],x:["100%","100%","100%"],transition:{duration:0,repeat:1,repeatDelay:3,ease:"easeOut"}},hover:{opacity:.7,x:"100%",transition:{duration:.6,ease:"easeOut"}}},pulse:{initial:{scale:1,opacity:.7},animate:{scale:1.05,opacity:1,transition:{duration:2,repeat:1/0,repeatType:"loop",ease:"easeInOut",yoyo:1/0}}}}),[j]),E=(0,r.useCallback)(e=>{if(console.log("=== LANGUAGE SELECTOR HANDLER ==="),console.log("Language change handler called for: ".concat(e)),console.log("Current detected locale: ".concat(y)),console.log("Current pathname: ".concat(v)),console.log("Path parts: ".concat(JSON.stringify(b))),console.log("Dropdown open state: ".concat(x)),console.log("================================="),g(!1),console.log("Dropdown closed"),e===y){console.log("Same locale selected, not navigating");return}console.log("Navigation will be handled by LanguageSelectorItem component")},[y,v,b,x]),S=(0,r.useMemo)(()=>"language-dropdown-".concat(y),[y]),P=function(e){let r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(eg,{ref:f,onClick:w,isOpen:x,dropdownId:S,variants:C.button,...r,children:e}),(0,a.jsx)(el,{isOpen:x,onClose:()=>g(!1),id:S,align:"right",width:n,children:(0,a.jsx)("div",{className:"py-1.5",children:i.map(e=>(0,a.jsx)(eh,{loc:e,currentLocale:y,getFlag:p,onClick:()=>{console.log("Item click handler for ".concat(e)),E(e)},onHover:()=>{},onLeave:()=>{},isHovered:!1,variant:l,locale:t,translations:c||{}},e))})})]})};if("flag"===l)return(0,a.jsx)("div",{className:"relative ".concat(o),children:P((0,a.jsxs)(d.P.span,{className:"flex items-center justify-center text-lg relative",animate:{rotateY:x?[0,10,0,-10,0]:0},transition:{duration:.5,ease:"easeInOut",times:[0,.25,.5,.75,1]},children:[p(y),(0,a.jsx)(d.P.div,{className:"absolute inset-0 rounded-full bg-electric-blue/20 blur-md z-[-1]",initial:{opacity:0,scale:.8},animate:{opacity:.3,scale:1.1},transition:{duration:1.5,ease:"easeInOut",repeatType:"reverse",repeat:1/0}})]}),{className:"p-2 w-10 h-10 flex items-center justify-center overflow-hidden",style:{aspectRatio:"1 / 1"}},"8rem")});if("minimal"===l){let e=(0,a.jsxs)("span",{className:"flex items-center gap-1.5 relative",children:[(0,a.jsxs)(d.P.svg,{className:"h-3 w-3 text-electric-blue/90",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",animate:{rotate:15*!!x},transition:{duration:.3,ease:"easeOut"},children:[(0,a.jsx)(d.P.circle,{cx:"12",cy:"12",r:"10",animate:{scale:x?1.05:1},transition:{duration:.3,ease:"easeOut"}}),(0,a.jsx)(d.P.line,{x1:"2",y1:"12",x2:"22",y2:"12",animate:{opacity:x?.7:1},transition:{duration:.3,ease:"easeOut"}}),(0,a.jsx)(d.P.path,{d:"M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10 15.3 15.3 0 0 1 4-10z",animate:{rotateZ:10*!!x},transition:{duration:.3,ease:"easeOut"}})]}),(0,a.jsxs)(d.P.span,{className:"relative",whileHover:{y:-1},transition:j.subtle,children:[(0,a.jsx)(h.y,{as:"span",gradient:"cool",className:"font-medium text-xs",children:"en"===y?m("english",{defaultValue:"English"}):"de"===y?m("german",{defaultValue:"German"}):y.toUpperCase()}),(0,a.jsx)(d.P.span,{className:"absolute -bottom-0.5 left-0 h-[1px] bg-electric-blue/30",initial:{width:"0%"},animate:{width:x?"100%":"70%"},transition:{duration:.3,ease:"easeInOut"}})]}),(0,a.jsx)(d.P.svg,{className:"h-3 w-3 text-electric-blue/90",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",animate:x?"open":"initial",variants:C.arrow,children:(0,a.jsx)(d.P.path,{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M19 9l-7 7-7-7",animate:{pathLength:x?[1,.8,1]:1,opacity:x?[1,.8,1]:1},transition:{duration:.3,ease:"easeInOut",times:[0,.5,1]}})}),(0,a.jsx)(d.P.span,{className:"absolute inset-0 bg-gradient-to-r from-transparent via-white/20 to-transparent",variants:C.shine,initial:"initial",animate:"animate",whileHover:"hover"})]});return(0,a.jsx)("div",{className:"relative ".concat(o),children:P(e,{},"8rem")})}let L=(0,a.jsxs)("span",{className:"flex items-center gap-1.5 relative",children:[(0,a.jsx)(d.P.div,{whileHover:{y:-1},transition:j.subtle,children:(0,a.jsx)(h.y,{as:"span",gradient:"cool",className:"font-medium text-xs",children:"en"===y?m("english",{defaultValue:"English"}):"de"===y?m("german",{defaultValue:"German"}):y.toUpperCase()})}),(0,a.jsx)(d.P.svg,{className:"h-3 w-3 text-electric-blue/90",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",animate:x?"open":"initial",variants:C.arrow,children:(0,a.jsx)(d.P.path,{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M19 9l-7 7-7-7",animate:{pathLength:x?.9:1,opacity:x?.9:1},transition:{duration:.3,ease:"easeOut"}})}),(0,a.jsx)(d.P.span,{className:"absolute inset-0 bg-gradient-to-r from-transparent via-white/20 to-transparent",variants:C.shine,initial:"initial",animate:"animate",whileHover:"hover"})]});return(0,a.jsx)("div",{className:"relative ".concat(o),children:(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsxs)(d.P.span,{style:{letterSpacing:"0.2px",textRendering:"optimizeLegibility"},variants:C.label,initial:"initial",whileHover:"hover",children:[(0,a.jsx)(h.y,{as:"span",gradient:"cool",className:"text-sm font-medium tracking-wide",children:m("label",{defaultValue:"Language:"})}),(0,a.jsx)(d.P.span,{className:"block h-[1px] bg-gradient-to-r from-electric-blue/0 via-electric-blue/30 to-electric-blue/0",initial:{width:"0%",opacity:0},whileHover:{width:"100%",opacity:1},transition:{duration:.3}})]}),(0,a.jsxs)("div",{className:"relative",children:[P(L,{},"8rem"),(0,a.jsx)(u.N,{children:x&&(0,a.jsx)(d.P.div,{className:"absolute -bottom-1 left-1/2 w-1 h-1 bg-electric-blue rounded-full",initial:{scale:0,opacity:0},animate:{scale:1,opacity:1},exit:{scale:0,opacity:0},transition:j.precise})})]})]})})},["Common"]);var ef=i(49218);let eb={initial:{opacity:0,y:20,scale:.98},animate:{opacity:1,y:0,scale:1,transition:{duration:.3,ease:[.22,1,.36,1],staggerChildren:.03,delayChildren:.1}},exit:{opacity:0,y:-20,scale:.98,transition:{duration:.25,ease:[.22,1,.36,1]}}};function ey(e){let{children:t}=e,{currentPath:i,isTransitioning:r}=(0,ef.t)();return(0,a.jsx)(u.N,{mode:"wait",initial:!1,children:(0,a.jsx)(d.P.div,{initial:"initial",animate:"animate",exit:"exit",variants:eb,className:"w-full perspective-1000 z-[var(--z-index-page-content)]",children:t},i)})}let ew=()=>(0,a.jsxs)("svg",{className:"absolute inset-0 w-full h-full",xmlns:"http://www.w3.org/2000/svg",style:{color:"var(--transition-color-primary)"},children:[(0,a.jsxs)("defs",{children:[(0,a.jsxs)("filter",{id:"glow",x:"-20%",y:"-20%",width:"140%",height:"140%",children:[(0,a.jsx)("feGaussianBlur",{stdDeviation:"3",result:"blur"}),(0,a.jsx)("feComposite",{in:"SourceGraphic",in2:"blur",operator:"over"})]}),(0,a.jsxs)("linearGradient",{id:"lineGradient",x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[(0,a.jsx)("stop",{offset:"0%",stopColor:"var(--transition-color-primary)",stopOpacity:"0.1"}),(0,a.jsx)("stop",{offset:"50%",stopColor:"var(--transition-color-primary)",stopOpacity:"1"}),(0,a.jsx)("stop",{offset:"100%",stopColor:"var(--transition-color-primary)",stopOpacity:"0.1"})]}),(0,a.jsxs)("linearGradient",{id:"accentGradient",x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[(0,a.jsx)("stop",{offset:"0%",stopColor:"var(--transition-accent-color)",stopOpacity:"0.1"}),(0,a.jsx)("stop",{offset:"50%",stopColor:"var(--transition-accent-color)",stopOpacity:"1"}),(0,a.jsx)("stop",{offset:"100%",stopColor:"var(--transition-accent-color)",stopOpacity:"0.1"})]})]}),(0,a.jsxs)("g",{opacity:"0.4",children:[Array.from({length:20}).map((e,t)=>(0,a.jsx)("line",{x1:"0",y1:"".concat(5*t,"%"),x2:"100%",y2:"".concat(5*t,"%"),stroke:"currentColor",strokeWidth:t%4==0?"1":"0.5",strokeOpacity:t%4==0?"0.6":"0.3"},"h-line-".concat(t))),Array.from({length:20}).map((e,t)=>(0,a.jsx)("line",{x1:"".concat(5*t,"%"),y1:"0",x2:"".concat(5*t,"%"),y2:"100%",stroke:"currentColor",strokeWidth:t%4==0?"1":"0.5",strokeOpacity:t%4==0?"0.6":"0.3"},"v-line-".concat(t)))]}),(0,a.jsx)("g",{style:{color:"var(--transition-color-secondary)"},children:Array.from({length:6}).map((e,t)=>Array.from({length:6}).map((e,i)=>(0,a.jsx)("circle",{cx:"".concat(20*t,"%"),cy:"".concat(20*i,"%"),r:"2",fill:"currentColor",opacity:"0.7"},"marker-".concat(t,"-").concat(i))))}),(0,a.jsxs)("g",{filter:"url(#glow)",children:[(0,a.jsx)(d.P.path,{d:"M 0,30 L 30,30 C 40,30 40,70 50,70 L 100,70",fill:"none",stroke:"url(#lineGradient)",strokeWidth:"1.5",strokeDasharray:"5,5",initial:{pathLength:0,opacity:0},animate:{pathLength:1,opacity:1},transition:{duration:1.5,ease:"easeInOut"}}),(0,a.jsx)(d.P.path,{d:"M 100,30 L 70,30 C 60,30 60,50 50,50 L 0,50",fill:"none",stroke:"url(#accentGradient)",strokeWidth:"1.5",strokeDasharray:"5,5",initial:{pathLength:0,opacity:0},animate:{pathLength:1,opacity:1},transition:{duration:1.5,ease:"easeInOut",delay:.2}})]}),(0,a.jsx)("circle",{cx:"25%",cy:"25%",r:"50",fill:"none",stroke:"var(--transition-color-secondary)",strokeWidth:"0.5",strokeOpacity:"0.2"}),(0,a.jsx)("circle",{cx:"25%",cy:"25%",r:"30",fill:"none",stroke:"var(--transition-color-secondary)",strokeWidth:"0.5",strokeOpacity:"0.3"}),(0,a.jsx)("circle",{cx:"75%",cy:"75%",r:"70",fill:"none",stroke:"var(--transition-color-secondary)",strokeWidth:"0.5",strokeOpacity:"0.2"}),(0,a.jsx)("circle",{cx:"75%",cy:"75%",r:"40",fill:"none",stroke:"var(--transition-color-secondary)",strokeWidth:"0.5",strokeOpacity:"0.3"})]});function ej(){let{isTransitioning:e,currentPath:t,previousPath:i}=(0,ef.t)();return(0,a.jsx)(u.N,{mode:"wait",children:e&&(0,a.jsxs)(d.P.div,{className:"fixed inset-0 z-[50] pointer-events-none page-transition-overlay",initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.4},children:[(0,a.jsx)(d.P.div,{className:"absolute inset-0 z-0",style:{backgroundColor:"var(--blueprint-background)"},initial:{opacity:0},animate:{opacity:1},exit:{opacity:0}}),(0,a.jsxs)("div",{className:"absolute inset-0 z-10 overflow-hidden flex items-center justify-center",children:[(0,a.jsx)("div",{className:"absolute inset-0",children:(0,a.jsx)(ew,{})}),(0,a.jsx)(d.P.div,{className:"absolute inset-0",style:{backgroundColor:"var(--blueprint-background)"},initial:{clipPath:"circle(0% at 50% 50%)"},animate:{clipPath:["circle(150% at 50% 50%)","circle(0% at 50% 50%)","circle(150% at 50% 50%)"]},transition:{times:[0,.5,1],duration:1.2,ease:"easeInOut"}})]}),(0,a.jsx)(d.P.div,{className:"absolute inset-0 bg-gradient-dark z-20",initial:{opacity:0},animate:{opacity:[0,.2,0]},transition:{times:[0,.5,1],duration:.9,ease:"easeInOut"}})]},"overlay-".concat(t))})}function eN(e){let{phoneNumber:t,className:i=""}=e,r=(0,n.useClientTranslations)("Common"),s=(0,ea.s)(),o=t.startsWith("0")?"49".concat(t.substring(1)):t,c=r("whatsapp",{defaultValue:"Hello! I'm interested in your services."}),d="https://wa.me/".concat(o,"?text=").concat(encodeURIComponent(c)),u=r("whatsappAriaLabel",{defaultValue:"Chat on WhatsApp"}),h=r("whatsappSrText",{defaultValue:"Chat on WhatsApp"});return(0,a.jsxs)(l(),{href:d,target:"_blank",rel:"noopener noreferrer",onClick:()=>{let e=new ei.XN({name:"whatsapp_button_click",timestamp:new Date,properties:{phoneNumber:o,hasMessage:!!c}});s.trackEvent(e)},className:"fixed md:bottom-6 md:right-6 bottom-[calc(var(--mobile-nav-height)+1.5rem)] right-4 z-[4] hidden md:flex items-center justify-center w-12 h-12 md:w-14 md:h-14 rounded-full bg-[#25D366] text-white shadow-lg hover:bg-[#20ba5a] transition-all duration-300 hover:scale-110 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-[#25D366] ".concat(i),"aria-label":u,children:[(0,a.jsx)("span",{className:"sr-only",children:h}),(0,a.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",className:"w-6 h-6 md:w-7 md:h-7",children:(0,a.jsx)("path",{fillRule:"evenodd",d:"M1.5 4.5a3 3 0 013-3h1.372c.86 0 1.61.586 1.819 1.42l1.105 4.423a1.875 1.875 0 01-.694 1.955l-1.293.97c-.135.101-.164.249-.126.352a11.285 11.285 0 006.697 6.697c.103.038.25.009.352-.126l.97-1.293a1.875 1.875 0 011.955-.694l4.423 1.105c.834.209 1.42.959 1.42 1.82V19.5a3 3 0 01-3 3h-2.25C8.552 22.5 1.5 15.448 1.5 6.75V4.5z",clipRule:"evenodd"})})]})}function ek(e){let{children:t,socialMediaLinks:i}=e,o=(0,n.useClientLocale)(),l=(0,s.usePathname)(),[c,d]=(0,r.useState)(!1),[u,h]=(0,r.useState)(!1);return((0,r.useEffect)(()=>{let e=setTimeout(()=>{h(!0)},2e3);return()=>clearTimeout(e)},[]),(0,r.useEffect)(()=>{l&&d(l.includes("/".concat(o,"/admin")))},[l,o]),c)?(0,a.jsx)("div",{className:"admin-content",children:t}):(0,a.jsxs)("div",{className:"flex flex-col min-h-screen",children:[(0,a.jsx)(ej,{}),(0,a.jsx)(W,{}),(0,a.jsx)("main",{className:"flex-grow pb-0 relative",children:(0,a.jsx)("div",{className:"min-h-screen",children:(0,a.jsx)(ey,{children:t})})}),(0,a.jsx)(ee,{socialMediaLinks:i}),(0,a.jsx)(et,{socialMediaLinks:i}),(0,a.jsx)(er,{}),(0,a.jsx)("div",{className:"fixed top-4 right-4 z-[var(--z-index-language-switcher)] hidden md:block",children:(0,a.jsx)(ev,{locale:o,locales:O.IB,variant:"flag",translations:{}})}),(0,a.jsx)(eN,{phoneNumber:"015678584306",message:"Hello! I'm interested in your cable visualization services. Could you provide more information?"})]})}},52787:()=>{},53419:(e,t,i)=>{"use strict";i.r(t),i.d(t,{BrowserCookieRepository:()=>r});var a=i(85909);class r{async getConsent(){try{if("undefined"==typeof localStorage)return null;let e=localStorage.getItem(this.STORAGE_KEY);if(!e)return null;try{let t=JSON.parse(e);return a.Z.fromJSON(t)}catch(e){return console.error("Error parsing cookie preferences:",e),null}}catch(e){return console.error("Error accessing cookie preferences:",e),null}}async saveConsent(e){try{if("undefined"==typeof localStorage)return;localStorage.setItem(this.STORAGE_KEY,JSON.stringify(e.toJSON()))}catch(e){console.error("Error saving cookie preferences:",e)}}constructor(){this.STORAGE_KEY="cookie-consent-preferences"}}},53773:()=>{},56609:(e,t,i)=>{"use strict";i.r(t),i.d(t,{CookieConsentProvider:()=>o,useCookieConsent:()=>l});var a=i(95155),r=i(12115),n=i(85909);let s=(0,r.createContext)({consent:new n.Z,hasInteracted:!1,showPreferences:!1,acceptAll:async()=>{},rejectNonEssential:async()=>{},setConsent:async()=>{},savePreferences:async()=>{},showPreferencesModal:()=>{},hidePreferencesModal:()=>{}});function o(e){let{children:t,getConsentUseCase:i,updateConsentUseCase:o}=e,[l,c]=(0,r.useState)(new n.Z),[d,u]=(0,r.useState)(!1),[h,m]=(0,r.useState)(!1);(0,r.useEffect)(()=>{(async()=>{try{let e=await i.execute();c(e.consent),u(e.hasInteracted)}catch(e){console.error("Error loading cookie consent:",e)}})()},[i]);let p=async()=>{try{let e=await o.acceptAll();e&&(c(e),u(!0))}catch(e){console.error("Error accepting all cookies:",e)}},x=async()=>{try{let e=await o.rejectNonEssential();e&&(c(e),u(!0))}catch(e){console.error("Error rejecting non-essential cookies:",e)}},g=async(e,t)=>{try{let i=await o.updateCategory({category:e,value:t});i&&c(i)}catch(e){console.error("Error updating cookie consent:",e)}},v=async()=>{u(!0),m(!1)};return(0,a.jsx)(s.Provider,{value:{consent:l,hasInteracted:d,showPreferences:h,acceptAll:p,rejectNonEssential:x,setConsent:g,savePreferences:v,showPreferencesModal:()=>{m(!0)},hidePreferencesModal:()=>{m(!1)}},children:t})}function l(){let e=(0,r.useContext)(s);if(!e)throw Error("useCookieConsent must be used within a CookieConsentProvider");return e}},60043:(e,t,i)=>{"use strict";i.d(t,{ClientEffects:()=>o});var a=i(95155),r=i(12115),n=i(86442);function s(){let[e,t]=(0,r.useState)(!1);return(0,r.useEffect)(()=>{let e=document.documentElement;e.classList.remove("no-js"),e.classList.add("js-enabled");let i=document.body,a=setTimeout(()=>{i.classList.remove("loading"),i.classList.add("loaded"),t(!0)},100);return()=>{clearTimeout(a)}},[]),(0,r.useEffect)(()=>{if(e){let e=new CustomEvent("app:loadingComplete",{detail:{timestamp:Date.now()}});window.dispatchEvent(e)}},[e]),null}function o(){let e=(0,n.st)();return(0,n.Lq)(e),(0,r.useEffect)(()=>{let e=()=>{(function(){let e=document.createElement("style");e.textContent="\n .cursor-effect {\n position: absolute;\n width: 30px;\n height: 30px;\n border-radius: 50%;\n background: radial-gradient(circle, rgba(0, 127, 255, 0.2) 0%, transparent 70%);\n pointer-events: none;\n z-index: 9999;\n transform: translate(-50%, -50%);\n animation: cursor-fade 1s forwards;\n will-change: transform, opacity;\n }\n \n @keyframes cursor-fade {\n 0% {\n opacity: 1;\n transform: translate(-50%, -50%) scale(0.3);\n }\n 100% {\n opacity: 0;\n transform: translate(-50%, -50%) scale(1.5);\n }\n }\n ",document.head.appendChild(e),document.addEventListener("mousemove",e=>{if(document.body.classList.contains("modal-open"))return;let t=document.createElement("div");t.className="cursor-effect",t.style.left="".concat(e.pageX,"px"),t.style.top="".concat(e.pageY,"px"),document.body.appendChild(t),setTimeout(()=>{t.parentNode&&t.parentNode.removeChild(t)},1e3)}),function(){let e=document.createElement("div");e.className="scroll-progress",e.style.cssText="\n position: fixed;\n top: 0;\n left: 0;\n width: 0%;\n height: 3px;\n background: linear-gradient(to right, #007aff, #5e5ce6, #ff375f);\n background-size: 200% auto;\n z-index: 2000;\n transition: width 0.1s;\n box-shadow: 0 0 15px rgba(0, 127, 255, 0.7);\n animation: gradient-shift 4s ease infinite alternate;\n ",document.body.appendChild(e),window.addEventListener("scroll",()=>{let t=document.documentElement.scrollTop||document.body.scrollTop,i=document.documentElement.scrollHeight-document.documentElement.clientHeight;e.style.width="".concat(t/i*100,"%")})}()})(),function(){let e=new IntersectionObserver(e=>{e.forEach(e=>{if(e.isIntersecting){e.target.classList.add("visible");let t=e.target,i=t.getAttribute("data-scroll-animation");"fade-up"===i?(t.style.opacity="1",t.style.transform="translateY(0)"):"fade-in"===i?t.style.opacity="1":"scale-up"===i&&(t.style.transform="scale(1)")}})},{threshold:.1,rootMargin:"0px 0px -10% 0px"});document.querySelectorAll("[data-scroll-animation]").forEach(t=>{let i=t.getAttribute("data-scroll-animation");"fade-up"===i?(t.style.opacity="0",t.style.transform="translateY(30px)",t.style.transition="opacity 0.8s ease, transform 0.8s ease"):"fade-in"===i?(t.style.opacity="0",t.style.transition="opacity 0.8s ease"):"scale-up"===i&&(t.style.transform="scale(0.9)",t.style.transition="transform 0.8s ease"),e.observe(t)})}(),function(){let e=document.createElement("style");e.textContent="\n @keyframes gradient-shift {\n 0% {\n background-position: 0% 50%;\n }\n 50% {\n background-position: 100% 50%;\n }\n 100% {\n background-position: 0% 50%;\n }\n }\n\n @keyframes pulse {\n 0% {\n opacity: 0.3;\n }\n 50% {\n opacity: 0.5;\n }\n 100% {\n opacity: 0.3;\n }\n }\n\n @keyframes float {\n 0% {\n transform: translateY(0px) rotate(0deg);\n }\n 25% {\n transform: translateY(-5px) rotate(-0.5deg);\n }\n 50% {\n transform: translateY(-10px) rotate(0deg);\n }\n 75% {\n transform: translateY(-5px) rotate(0.5deg);\n }\n 100% {\n transform: translateY(0px) rotate(0deg);\n }\n }\n \n @keyframes glow {\n 0% {\n box-shadow: 0 0 5px rgba(0, 127, 255, 0.5);\n }\n 50% {\n box-shadow: 0 0 25px rgba(0, 127, 255, 0.8);\n }\n 100% {\n box-shadow: 0 0 5px rgba(0, 127, 255, 0.5);\n }\n }\n ",document.head.appendChild(e)}(),function(){let e=document.documentElement;e.style.setProperty("--gradient-vibrant","linear-gradient(to right, #007aff, #5e5ce6, #ff375f)"),e.style.setProperty("--gradient-cool","linear-gradient(to right, #64d2ff, #007aff, #5e5ce6)"),e.style.setProperty("--glow-effect","0 0 15px rgba(0, 127, 255, 0.5)"),e.style.setProperty("--glow-strong","0 0 25px rgba(0, 127, 255, 0.7)"),e.style.setProperty("--glass-bg","rgba(10, 10, 15, 0.65)"),e.style.setProperty("--glass-bg-light","rgba(255, 255, 255, 0.08)"),e.style.setProperty("--glass-border","rgba(255, 255, 255, 0.08)"),e.style.setProperty("--transition-spring","all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1)"),e.style.setProperty("--transition-bounce","all 0.7s cubic-bezier(0.68, -0.6, 0.32, 1.6)")}()};window.addEventListener("app:loadingComplete",e);let t=setTimeout(e,200);return()=>{window.removeEventListener("app:loadingComplete",e),clearTimeout(t)}},[]),(0,a.jsx)(a.Fragment,{children:(0,a.jsx)(s,{})})}},64078:(e,t,i)=>{"use strict";i.d(t,{ConnectivityProvider:()=>o,F:()=>s});var a=i(95155),r=i(12115);let n=(0,r.createContext)(void 0),s=()=>{let e=(0,r.useContext)(n);if(void 0===e)throw Error("useConnectivity must be used within a ConnectivityProvider");return e},o=e=>{let{children:t,checkInterval:i=3e4}=e,[s,o]=(0,r.useState)(!0),l=(0,r.useRef)(null);(0,r.useRef)(!1);let c=(0,r.useCallback)(async()=>{},[s]);return(0,r.useEffect)(()=>{c()},[c]),(0,r.useEffect)(()=>(l.current&&clearInterval(l.current),l.current=setInterval(c,i),()=>{l.current&&clearInterval(l.current)}),[c,i]),(0,r.useEffect)(()=>{let e=()=>{console.log("Browser reported online, re-checking connection..."),c()},t=()=>{console.warn("Browser reported offline. Setting connection status to false."),o(!1)};return window.addEventListener("online",e),window.addEventListener("offline",t),()=>{window.removeEventListener("online",e),window.removeEventListener("offline",t)}},[c]),(0,a.jsx)(n.Provider,{value:{isConnected:s,checkConnection:c},children:t})}},70581:(e,t,i)=>{"use strict";i.d(t,{B:()=>a.BrowserCookieRepository});var a=i(53419)},77030:(e,t,i)=>{"use strict";i.d(t,{BrochureModalProvider:()=>ep});var a=i(95155),r=i(12115),n=i(28035),s=i(44912),o=i(34477);let l=(0,o.createServerReference)("60abcd8a42d1f5b0c8b86ce3195c14f8c38afe408f",o.callServer,void 0,o.findSourceMapURL,"subscribeToBrochure");var c=i(47650),d=i(76703),u=i(37281);function h(e){let{className:t="",size:i=24,color:r="currentColor",animated:n=!0}=e,s={hidden:{pathLength:0,opacity:0},visible:e=>({pathLength:1,opacity:1,transition:{pathLength:{type:"spring",duration:1.5,bounce:0,delay:.05*e},opacity:{duration:.2,delay:.05*e}}})},o=n?u.P.svg:"svg",l=n?u.P.path:"path",c=n?u.P.rect:"rect",d=n?u.P.line:"line",h=n?u.P.circle:"circle";return(0,a.jsxs)(o,{xmlns:"http://www.w3.org/2000/svg",width:i,height:i,viewBox:"0 0 100 100",fill:"none",stroke:r,strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",className:t,variants:n?s:void 0,children:[(0,a.jsx)(c,{x:"15",y:"10",width:"70",height:"80",rx:"2",fill:"none",stroke:r,strokeWidth:"1.5",custom:1,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"50",y1:"10",x2:"50",y2:"90",strokeDasharray:"3,2",custom:2,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(l,{d:"M15 10 L50 10 L50 90 L15 90 Z",fill:"none",stroke:r,strokeWidth:"0.2",strokeOpacity:"0.5",custom:3,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsxs)("g",{strokeWidth:"0.2",strokeOpacity:"0.3",children:[Array.from({length:8}).map((e,t)=>(0,a.jsx)("line",{x1:15+4.5*t,y1:"10",x2:15+4.5*t,y2:"90"},"vgrid-".concat(t))),Array.from({length:16}).map((e,t)=>(0,a.jsx)("line",{x1:"15",y1:10+5*t,x2:"50",y2:10+5*t},"hgrid-".concat(t)))]}),(0,a.jsx)(h,{cx:"32.5",cy:"35",r:"12",strokeWidth:"0.8",custom:4,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(h,{cx:"32.5",cy:"35",r:"8",strokeWidth:"0.8",strokeDasharray:"2,1",custom:5,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(h,{cx:"32.5",cy:"35",r:"4",strokeWidth:"0.8",custom:6,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"20.5",y1:"35",x2:"26.5",y2:"35",strokeWidth:"0.5",custom:7,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"38.5",y1:"35",x2:"44.5",y2:"35",strokeWidth:"0.5",custom:8,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"32.5",y1:"23",x2:"32.5",y2:"29",strokeWidth:"0.5",custom:9,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"32.5",y1:"41",x2:"32.5",y2:"47",strokeWidth:"0.5",custom:10,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"20",y1:"60",x2:"45",y2:"60",strokeWidth:"0.8",custom:11,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"20",y1:"65",x2:"45",y2:"65",strokeWidth:"0.8",custom:12,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"20",y1:"70",x2:"45",y2:"70",strokeWidth:"0.8",custom:13,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"20",y1:"75",x2:"40",y2:"75",strokeWidth:"0.8",custom:14,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(c,{x:"55",y:"20",width:"25",height:"20",rx:"1",strokeWidth:"1",custom:15,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"55",y1:"45",x2:"80",y2:"45",custom:16,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"55",y1:"50",x2:"80",y2:"50",custom:17,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"55",y1:"55",x2:"80",y2:"55",custom:18,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"55",y1:"60",x2:"80",y2:"60",custom:19,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"55",y1:"65",x2:"75",y2:"65",custom:20,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"55",y1:"70",x2:"70",y2:"70",custom:21,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(d,{x1:"25",y1:"15",x2:"75",y2:"15",strokeWidth:"1",custom:22,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(h,{cx:"15",cy:"10",r:"0.5",fill:r,custom:23,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(h,{cx:"50",cy:"10",r:"0.5",fill:r,custom:24,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(h,{cx:"85",cy:"10",r:"0.5",fill:r,custom:25,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(h,{cx:"15",cy:"90",r:"0.5",fill:r,custom:26,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(h,{cx:"50",cy:"90",r:"0.5",fill:r,custom:27,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0}),(0,a.jsx)(h,{cx:"85",cy:"90",r:"0.5",fill:r,custom:28,variants:n?s:void 0,initial:n?"hidden":void 0,animate:n?"visible":void 0})]})}var m=i(18063);function p(){let{pending:e}=(0,c.useFormStatus)(),t=(0,d.useClientTranslations)("Brochure");return(0,a.jsx)(s.Button,{type:"submit",variant:"primary",className:"w-full mt-4",disabled:e,animate:e?"enabled":"initial",children:t(e?"sending":"getTheBrochure")})}function x(e){let t,{isOpen:i,onClose:s}=e,[o,c]=(0,r.useActionState)(l,{success:!1,message:"",errors:{}}),[x,g]=(0,r.useState)(""),[v,f]=(0,r.useState)(!1),[b,y]=(0,m.l)();try{t=(0,d.useClientTranslations)("Brochure")}catch(e){t=e=>({title:"Get Our PDF Brochure",description:"Enter your email to receive our PDF brochure containing additional insights, images and information on our services.",emailPlaceholder:"Your email address",getTheBrochure:"Get the Brochure",sending:"Sending...",successMessage:"Thank you! We've sent the brochure to your email.",newsletterInfo:"By requesting the brochure, you'll also be subscribed to our newsletter. You can unsubscribe at any time."})[e]||e}return(0,r.useEffect)(()=>{g(Date.now().toString())},[]),(0,r.useEffect)(()=>{i&&g(Date.now().toString())},[i]),(0,r.useEffect)(()=>{if(o.success){let e=setTimeout(()=>{s()},3e3);return()=>clearTimeout(e)}},[o.success,s]),(0,a.jsx)(n.a,{isOpen:i,onClose:s,title:t("title"),size:"small",children:(0,a.jsx)("div",{className:"space-y-6 py-2",ref:b,children:o.success?(0,a.jsxs)(u.P.div,{className:"text-center py-8",initial:{opacity:0},animate:{opacity:1},transition:{duration:.6},children:[(0,a.jsxs)(u.P.div,{className:"inline-flex items-center justify-center w-20 h-20 rounded-full bg-gradient-to-r from-electric-blue to-purple mb-6 relative overflow-hidden",initial:{scale:0,rotate:-10},animate:{scale:1,rotate:0},transition:{type:"spring",stiffness:260,damping:20,delay:.2},children:[(0,a.jsx)(u.P.div,{className:"absolute inset-0 bg-gradient-to-r from-electric-blue/30 to-purple/30",animate:{rotate:360},transition:{duration:8,repeat:1/0,ease:"linear"}}),(0,a.jsx)(u.P.svg,{xmlns:"http://www.w3.org/2000/svg",className:"h-10 w-10 text-white relative z-10",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2.5",strokeLinecap:"round",strokeLinejoin:"round",children:(0,a.jsx)(u.P.polyline,{points:"20 6 9 17 4 12",initial:{pathLength:0,opacity:0},animate:{pathLength:1,opacity:1},transition:{pathLength:{duration:.8,delay:.5,ease:"easeOut"},opacity:{duration:.3,delay:.5}}})}),(0,a.jsx)(u.P.div,{className:"absolute inset-0 rounded-full",initial:{boxShadow:"0 0 0 0 rgba(0, 122, 255, 0)"},animate:{boxShadow:["0 0 0 0 rgba(0, 122, 255, 0.7)","0 0 0 10px rgba(0, 122, 255, 0)"]},transition:{duration:1.5,repeat:2,repeatDelay:.5,ease:"easeOut",delay:.8}})]}),(0,a.jsx)(u.P.h3,{className:"text-2xl font-medium text-white mb-3 tracking-wide",initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{type:"spring",stiffness:100,damping:15,delay:.7},children:t("successMessage")}),(0,a.jsx)(u.P.p,{className:"text-white/70 text-lg font-light leading-relaxed max-w-md mx-auto",initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{type:"spring",stiffness:100,damping:15,delay:.9},children:t("checkYourInbox")})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(u.P.div,{className:"flex justify-center mb-8",initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.5},children:(0,a.jsxs)(u.P.div,{className:"p-6 rounded-xl bg-glass-bg backdrop-blur-md border border-glass-border icon-container relative overflow-hidden",transition:{type:"spring",stiffness:400,damping:10},children:[(0,a.jsx)(u.P.div,{className:"absolute inset-0 bg-gradient-to-r from-electric-blue/5 to-transparent opacity-0",animate:{opacity:[0,.3,0]},transition:{duration:3,repeat:1/0,repeatType:"mirror",ease:"easeInOut"}}),(0,a.jsx)(h,{size:100,className:"text-electric-blue animate-float relative z-10"})]})}),(0,a.jsx)(u.P.p,{className:"text-white/90 text-lg leading-relaxed tracking-wide font-light mb-6",initial:{opacity:0},animate:{opacity:1},transition:{duration:.5,delay:.2},children:t("description")}),(0,a.jsx)(u.P.h3,{className:"text-sm uppercase tracking-widest text-electric-blue font-medium mb-4",initial:{opacity:0,x:-20},animate:{opacity:1,x:0},transition:{duration:.5,delay:.3},children:t("emailPrompt")||"Enter your email below"}),(0,a.jsxs)("form",{action:c,className:"space-y-4",children:[(0,a.jsxs)(u.P.div,{className:"relative",initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.5,delay:.4},children:[(0,a.jsx)("input",{type:"email",name:"email",placeholder:t("emailPlaceholder"),required:!0,className:"w-full px-5 py-3 bg-glass-bg-dark backdrop-blur-md rounded-lg border text-white focus:outline-none focus:ring-2 transition-all duration-300 ".concat(v?"border-electric-blue ring-electric-blue/50 shadow-[0_0_15px_rgba(0,122,255,0.15)]":"border-glass-border"),onFocus:()=>{f(!0),y("input[type='email']",{scale:[1,1.02,1]},{duration:.3,ease:"easeOut"})},onBlur:()=>f(!1)}),(0,a.jsx)(u.P.div,{className:"absolute inset-0 pointer-events-none rounded-lg bg-gradient-to-r from-electric-blue/5 to-transparent",initial:{opacity:.3},animate:{opacity:v?.7:.3,background:v?"linear-gradient(to right, rgba(0, 122, 255, 0.1), transparent)":"linear-gradient(to right, rgba(0, 122, 255, 0.05), transparent)"},transition:{duration:.3}}),(0,a.jsx)("input",{type:"text",name:"honeypot",style:{display:"none"},tabIndex:-1,autoComplete:"off"}),(0,a.jsx)("input",{type:"hidden",name:"submitTimestamp",value:x})]}),o.message&&!o.success&&(0,a.jsx)("div",{className:"text-red-500 text-sm",children:o.message}),(0,a.jsx)(u.P.p,{className:"text-white/60 text-xs leading-relaxed tracking-wide italic",initial:{opacity:0},animate:{opacity:1},transition:{duration:.5,delay:.5},children:t("newsletterInfo")}),(0,a.jsx)(u.P.div,{className:"mt-6",initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.5,delay:.6},children:(0,a.jsx)(p,{})})]})]})})})}class g{async requestBrochure(e){return this.requestBrochureUseCase.execute(e)}async markBrochureSeen(e){return this.markBrochureSeenUseCase.execute(e)}async hasUserSeenBrochure(e){if(!this.repository)throw Error("Repository is required for this operation");return this.repository.hasUserSeenBrochure(e)}constructor(e,t,i){this.requestBrochureUseCase=e,this.markBrochureSeenUseCase=t,this.repository=i}}class v{isValidEmail(e){return/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(e)}markAsFulfilled(){this._fulfilled=!0}get fulfilled(){return this._fulfilled}constructor(e){if(!this.isValidEmail(e.email))throw Error("Invalid email format");this.email=e.email,this.timestamp=e.timestamp,this.locale=e.locale||"en",this._fulfilled=e.fulfilled||!1}}class f{async execute(e){try{let t=new v({email:e.email,timestamp:new Date,locale:e.locale});try{await this.newsletterService.subscribeToNewsletter(t.email,e.source)}catch(e){console.warn("Newsletter subscription failed for ".concat(t.email,": ").concat(e,". Continuing with brochure request."))}await this.repository.saveRequest(t),await this.emailService.sendBrochureEmail(t),t.markAsFulfilled();let i={email:t.email,timestamp:t.timestamp.toISOString(),locale:t.locale,fulfilled:t.fulfilled};return{success:!0,message:"Brochure request processed successfully",request:i}}catch(e){return console.error("Error in RequestBrochure use case:",e),{success:!1,message:e instanceof Error?e.message:"An unknown error occurred"}}}constructor(e,t,i){this.repository=e,this.emailService=t,this.newsletterService=i}}class b{async execute(e){try{if(!this.isValidEmail(e))return{success:!1,message:"Invalid email format"};return await this.repository.markBrochureAsSeen(e),{success:!0,message:"Brochure marked as seen"}}catch(e){return{success:!1,message:e instanceof Error?e.message:"An unknown error occurred"}}}isValidEmail(e){return/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(e)}constructor(e){this.repository=e}}class y{async saveRequest(e){let t=this.getStoredRequests();t.push({email:e.email,timestamp:e.timestamp.toISOString(),locale:e.locale,fulfilled:e.fulfilled}),localStorage.setItem(this.REQUESTS_KEY,JSON.stringify(t))}async hasUserSeenBrochure(e){return"true"===localStorage.getItem(this.SEEN_KEY)}async markBrochureAsSeen(e){localStorage.setItem(this.SEEN_KEY,"true")}getStoredRequests(){let e=localStorage.getItem(this.REQUESTS_KEY);return e?JSON.parse(e):[]}constructor(){this.REQUESTS_KEY="brochureRequests",this.SEEN_KEY="hasSeenBrochureModal"}}var w=i(54538);class j{async saveRequest(e){if(!this.cookiesFn){console.warn("SupabaseBrochureRepository: No cookies function provided, this operation requires server-side execution");return}let t=(0,w.d)(this.cookiesFn);try{let{error:i}=await t.from("brochure_requests").insert({email:e.email,timestamp:e.timestamp.toISOString(),locale:e.locale,fulfilled:e.fulfilled});if(i)throw console.error("Supabase error details:",i),Error("Failed to save brochure request: ".concat(i.message||JSON.stringify(i)))}catch(e){throw console.error("Error saving brochure request:",e),Error("Failed to save brochure request: ".concat(e instanceof Error?e.message:String(e)))}}async hasUserSeenBrochure(e){if(!this.cookiesFn)return console.warn("SupabaseBrochureRepository: No cookies function provided, this operation requires server-side execution"),!1;let t=(0,w.d)(this.cookiesFn),{data:i,error:a}=await t.from("brochure_seen").select().eq("email",e).single();if(a&&"PGRST116"!==a.code)throw Error("Failed to check if brochure was seen: ".concat(a.message));return!!i&&!0===i.seen}async markBrochureAsSeen(e){if(!this.cookiesFn){console.warn("SupabaseBrochureRepository: No cookies function provided, this operation requires server-side execution");return}let t=(0,w.d)(this.cookiesFn),{error:i}=await t.from("brochure_seen").upsert({email:e,seen:!0,updated_at:new Date().toISOString()});if(i)throw Error("Failed to mark brochure as seen: ".concat(i.message))}constructor(e=null){this.cookiesFn=e}}var N=i(50173),k=i(65016),C=i(25268),E=i(38759),S=i(31959),P=i(15306),L=i(17725),_=i(73875),T=i(14391),I=i(39627),B=i(34592),M=i(37720),R=i(49509);let O=()=>{var e,t,i,a,r,n;let s=null!==(n=null!==(r=null!==(a=null==R?void 0:null===(e=R.env)||void 0===e?void 0:"https://cablecreations.de")&&void 0!==a?a:null==R?void 0:null===(t=R.env)||void 0===t?void 0:t.VERCEL_URL)&&void 0!==r?r:null==R?void 0:null===(i=R.env)||void 0===i?void 0:"cablecreations-44b9t3csl-marc-mintels-projects.vercel.app")&&void 0!==n?n:"http://localhost:3000/";return"/"===(s=s.includes("http")?s:"https://".concat(s)).charAt(s.length-1)?s:"".concat(s,"/")},A=O(),U="".concat(A,"img/logo-white.svg"),z=()=>(0,a.jsxs)(C.w,{style:{background:"transparent",padding:"0",margin:"0"},children:[(0,a.jsx)("div",{style:{padding:"32px 24px 24px 24px",textAlign:"center",background:"transparent"},children:(0,a.jsxs)(S.N,{href:A,style:{textDecoration:"none",display:"inline-block"},children:[(0,a.jsx)(M.E,{src:U,alt:"Cable Creations Logo",width:"120",height:"auto",style:{display:"block",margin:"0 auto",maxWidth:"120px",height:"auto",filter:"drop-shadow(0 0 5px rgba(0, 122, 255, 0.3))"}}),(0,a.jsx)("div",{style:{display:"none",fontSize:"24px",fontWeight:"bold",color:"#ffffff",textAlign:"center",fontFamily:"Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif"},children:"Cable Creations"})]})}),(0,a.jsxs)("div",{style:{padding:"0 24px",background:"transparent"},children:[(0,a.jsx)("div",{style:{height:"1px",backgroundColor:"rgba(255, 255, 255, 0.08)",margin:"0 0 8px 0",position:"relative"}}),(0,a.jsxs)("div",{style:{display:"flex",alignItems:"center",justifyContent:"center",marginBottom:"16px"},children:[(0,a.jsx)("div",{style:{flex:"1",height:"1px",backgroundColor:"rgba(255, 255, 255, 0.08)"}}),(0,a.jsx)("div",{style:{width:"8px",height:"8px",background:"linear-gradient(135deg, #0066cc, #007aff)",borderRadius:"50%",margin:"0 12px",boxShadow:"0 0 8px rgba(0, 122, 255, 0.5)"}}),(0,a.jsx)("div",{style:{flex:"1",height:"1px",backgroundColor:"rgba(255, 255, 255, 0.08)"}})]})]})]}),W=O(),F=new Date().getFullYear(),D=e=>{let{email:t,unsubscribeToken:i}=e;return(0,a.jsxs)(C.w,{style:{background:"transparent",padding:"0",margin:"0"},children:[(0,a.jsx)("div",{style:{padding:"24px 24px 0 24px",background:"transparent"},children:(0,a.jsxs)("div",{style:{display:"flex",alignItems:"center",justifyContent:"center",marginBottom:"24px"},children:[(0,a.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:"4px"},children:[(0,a.jsx)("div",{style:{width:"4px",height:"4px",background:"linear-gradient(135deg, #0066cc, #007aff)",borderRadius:"50%",boxShadow:"0 0 4px rgba(0, 122, 255, 0.5)"}}),(0,a.jsx)("div",{style:{width:"20px",height:"1px",backgroundColor:"rgba(255, 255, 255, 0.08)"}}),(0,a.jsx)("div",{style:{width:"2px",height:"2px",backgroundColor:"#64d2ff",borderRadius:"50%"}})]}),(0,a.jsx)("div",{style:{flex:"1",height:"1px",backgroundColor:"rgba(255, 255, 255, 0.08)",margin:"0 16px"}}),(0,a.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:"4px"},children:[(0,a.jsx)("div",{style:{width:"2px",height:"2px",backgroundColor:"#64d2ff",borderRadius:"50%"}}),(0,a.jsx)("div",{style:{width:"20px",height:"1px",backgroundColor:"rgba(255, 255, 255, 0.08)"}}),(0,a.jsx)("div",{style:{width:"4px",height:"4px",background:"linear-gradient(135deg, #0066cc, #007aff)",borderRadius:"50%",boxShadow:"0 0 4px rgba(0, 122, 255, 0.5)"}})]})]})}),(0,a.jsxs)("div",{style:{padding:"0 24px 32px 24px",textAlign:"center",background:"transparent"},children:[(0,a.jsxs)(k.E,{style:{margin:"0 0 8px 0",fontSize:"14px",lineHeight:"20px",color:"#ffffff",fontWeight:"600",fontFamily:"-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif"},children:["\xa9 ",F," Cable Creations. All rights reserved."]}),(0,a.jsx)(k.E,{style:{margin:"0 0 16px 0",fontSize:"12px",lineHeight:"16px",color:"#808080",fontFamily:"Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif"},children:"Cable Creations, Georg-Meistermann-Stra\xdfe 7, 54586 Sch\xfcller, Germany"}),(0,a.jsxs)(k.E,{style:{margin:"0",fontSize:"12px",lineHeight:"16px",color:"#808080",fontFamily:"Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif"},children:[(0,a.jsx)(S.N,{href:"".concat(W,"/privacy"),style:{color:"#007aff",textDecoration:"none",fontWeight:"500"},children:"Privacy Policy"}),(0,a.jsx)("span",{style:{margin:"0 8px",color:"rgba(255, 255, 255, 0.08)"},children:"|"}),(0,a.jsx)(S.N,{href:"".concat(W,"/terms"),style:{color:"#007aff",textDecoration:"none",fontWeight:"500"},children:"Terms of Service"}),t&&i&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("span",{style:{margin:"0 8px",color:"rgba(255, 255, 255, 0.08)"},children:"|"}),(0,a.jsx)(S.N,{href:"".concat(W,"/unsubscribe?token=").concat(i,"&email=").concat(encodeURIComponent(t)),style:{color:"#007aff",textDecoration:"none",fontWeight:"500"},children:"Unsubscribe"})]})]})]})]})},X=e=>{let{previewText:t,children:i}=e;return(0,a.jsxs)(P.E,{children:[(0,a.jsx)(L.p,{children:(0,a.jsx)("link",{rel:"preload",as:"image",href:"".concat(O(),"img/logo-white.svg")})}),(0,a.jsx)(_.l,{children:t}),(0,a.jsx)(T.n,{config:{theme:{extend:{colors:{"electric-blue":"#007aff","medium-blue":"#0066cc","light-blue":"#4da6ff",purple:"#5e5ce6",pink:"#ff375f",teal:"#64d2ff",black:"#000000","deep-black":"#0a0a0a","dark-blue":"#000a1f","glass-bg":"rgba(10, 10, 15, 0.65)","glass-bg-light":"rgba(255, 255, 255, 0.08)","glass-border":"rgba(255, 255, 255, 0.08)",white:"#ffffff",grey:"#808080","light-grey":"#e6e6e6"},fontFamily:{sans:["-apple-system","BlinkMacSystemFont","Segoe UI","Roboto","Helvetica Neue","Arial","sans-serif"]}}}},children:(0,a.jsxs)(I.n,{className:"bg-dark-bg text-text-primary-dark font-sans",style:{margin:0,padding:0,backgroundColor:"#000000",color:"#ffffff",fontFamily:"-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif"},children:[(0,a.jsx)("style",{children:"\n /* Global email styles aligned with web UI */\n * {\n color: #ffffff !important;\n }\n h1, h2, h3, h4, h5, h6 {\n color: #ffffff !important;\n font-family: \"Inter\", -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif !important;\n }\n p, div, span, td {\n color: #ffffff !important;\n font-family: \"Inter\", -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif !important;\n }\n .text-secondary {\n color: #808080 !important;\n }\n .text-muted {\n color: #808080 !important;\n }\n hr {\n border-color: rgba(255, 255, 255, 0.08) !important;\n }\n a {\n color: #007aff !important;\n text-decoration: none !important;\n }\n a:hover {\n color: #4da6ff !important;\n }\n /* Glass effect styling for email compatibility */\n .glass-effect {\n background: rgba(10, 10, 15, 0.65) !important;\n border: 1px solid rgba(255, 255, 255, 0.08) !important;\n }\n "}),(0,a.jsx)("div",{style:{background:"linear-gradient(135deg, #0066cc, #007aff)",height:"4px",width:"100%"}}),(0,a.jsx)("div",{style:{height:"40px"}}),(0,a.jsxs)(B.m,{className:"max-w-2xl mx-auto glass-effect",style:{maxWidth:"600px",margin:"0 auto",background:"rgba(10, 10, 15, 0.65)",border:"1px solid rgba(255, 255, 255, 0.08)",borderRadius:"12px"},children:[(0,a.jsx)(z,{}),(0,a.jsx)("main",{style:{padding:"32px 24px",background:"transparent",color:"#ffffff"},children:i}),(0,a.jsx)(D,{})]}),(0,a.jsx)("div",{style:{height:"40px"}})]})})]})},H=e=>{let{email:t,locale:i="en"}=e,r=O(),n="de"===i,s="".concat(r,"/s/en/brochure"),o="".concat(r,"/s/de/brochure");return(0,a.jsxs)(X,{previewText:"Cable Creations: Your PDF Brochure is Ready!",children:[(0,a.jsx)(N.D,{className:"text-2xl font-bold text-foreground mb-4",children:"Your Cable Creations Brochure is Ready!"}),(0,a.jsx)(k.E,{className:"text-base text-foreground mb-4",children:"Thank you for your interest in Cable Creations! As requested, here is your PDF brochure containing additional insights, images, and information on our services."}),(0,a.jsx)(C.w,{className:"text-center mb-6",children:(0,a.jsx)(E.$,{href:n?o:s,className:"bg-brand text-white font-semibold py-3 px-6 rounded-lg",children:n?"Download German Brochure":"Download English Brochure"})}),(0,a.jsxs)(k.E,{className:"text-sm text-foreground mb-6 text-center",children:["Also available in ",n?"English":"German",":"," ",(0,a.jsx)(S.N,{href:n?s:o,className:"text-brand",children:n?"Download English Version":"Download German Version"})]}),(0,a.jsx)(k.E,{className:"text-base text-foreground mb-4",children:"We've also added you to our newsletter to keep you updated on our latest services, innovations, and special offers. You can unsubscribe at any time using the link in our newsletter emails."}),(0,a.jsx)(k.E,{className:"text-base text-foreground mb-6",children:"If you have any questions or would like to discuss your specific needs, please don't hesitate to contact us."}),(0,a.jsxs)(k.E,{className:"text-base text-foreground mt-6",children:["Best regards,",(0,a.jsx)("br",{}),"The Cable Creations Team"]})]})};class V{async sendBrochureEmail(e){await this.emailService.sendEmail({to:e.email,from:"brochure@cablecreations.de",subject:"Your Cable Creations Brochure",text:"Thank you for requesting our brochure. You can download it using the link in this email.",html:r.createElement(H,{email:e.email,locale:e.locale})})}constructor(e){this.emailService=e}}let q=(0,o.createServerReference)("60d80fd1be4d0684e7bbae9fc28d6679c6bd7a9cae",o.callServer,void 0,o.findSourceMapURL,"subscribeToNewsletter");class G{async subscribeToNewsletter(e,t){try{let i=new FormData;return i.append("email",e),i.append("source",t),i.append("honeypot",""),i.append("submitTimestamp",Date.now().toString()),(await q(null,i)).success}catch(t){console.error("Error in NewsletterServiceAdapter:",t);let e=t.message||"";if(e.includes("duplicate key")&&e.includes("newsletter_subscribers_email_key"))return!0;return!1}}}class Y{isValid(){return!!this.to&&!!this.from&&!!this.subject&&!!this.text&&this.isValidEmail(this.to)&&this.isValidEmail(this.from)}isValidEmail(e){return/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(e)}constructor(e){this.to=e.to,this.from=e.from,this.subject=e.subject,this.text=e.text,this.html=e.html,this.metadata=e.metadata}}class K{static create(e,t){return{namespace:e,key:t,fullKey:"".concat(e,".").concat(t)}}static fromFullKey(e){let t=e.split(".");if(t.length<2)throw Error("Invalid full key format: ".concat(e));return{namespace:t[0],key:t.slice(1).join("."),fullKey:e}}}class J{static create(e,t,i){return{code:e,region:t,fallback:i}}static fromString(e,t){let i=e.split("-");return{code:i[0],region:i[1],fallback:t}}}class Z{static create(e,t,i,a){return{templateName:e,locale:t,data:i,metadata:a}}}var $=i(53363);let Q=e=>{let{name:t,subject:i,message:r,t:n}=e,s=O(),o="Cable Creations: ".concat(n("contact.userConfirmation.subject"));return(0,a.jsxs)(X,{previewText:o,children:[(0,a.jsx)(N.D,{className:"text-2xl font-bold mb-4",children:n("contact.userConfirmation.subject")}),(0,a.jsx)(k.E,{className:"text-base mb-4",children:n("contact.userConfirmation.greeting",{name:t})}),(0,a.jsx)(k.E,{className:"text-base mb-4",children:n("contact.userConfirmation.thankYou",{subject:i})}),(0,a.jsxs)(C.w,{className:"bg-gray-50 p-4 rounded-lg mb-4",children:[(0,a.jsx)(k.E,{className:"text-black text-sm font-semibold mb-2",children:n("contact.userConfirmation.yourMessage")}),(0,a.jsx)(k.E,{className:"text-base mb-2",style:{whiteSpace:"pre-wrap"},children:r})]}),(0,a.jsx)(k.E,{className:"text-base text-secondary mb-6",children:n("contact.userConfirmation.responseTime")}),(0,a.jsx)(C.w,{className:"text-center",children:(0,a.jsx)(E.$,{href:"".concat(s,"/services"),className:"bg-electric-blue text-white font-semibold py-3 px-6 rounded-lg",style:{background:"linear-gradient(135deg, #0066cc, #007aff)",color:"#ffffff",fontWeight:"600",padding:"12px 24px",borderRadius:"12px",textDecoration:"none",display:"inline-block",border:"1px solid rgba(255, 255, 255, 0.08)",boxShadow:"0 0 15px rgba(0, 122, 255, 0.3)",fontFamily:"Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif"},children:n("contact.userConfirmation.exploreServices")})}),(0,a.jsx)(k.E,{className:"text-base mt-6",style:{whiteSpace:"pre-line"},children:n("contact.userConfirmation.signature")})]})};var ee=i(49861);let et=e=>{let{submission:t,t:i}=e,r="Cable Creations: ".concat(i("contact.adminNotification.subject",{subject:t.subject}));return(0,a.jsxs)(X,{previewText:r,children:[(0,a.jsx)(N.D,{className:"text-2xl font-bold mb-4",children:i("contact.adminNotification.title")}),(0,a.jsx)(k.E,{className:"text-base mb-4",children:i("contact.adminNotification.description")}),(0,a.jsxs)(C.w,{className:"bg-gray-50 p-4 rounded-lg mb-4",children:[(0,a.jsxs)(k.E,{className:"text-sm font-semibold mb-2",children:[i("contact.adminNotification.name")," ",t.name]}),(0,a.jsxs)(k.E,{className:"text-sm mb-2",children:[i("contact.adminNotification.email")," ",t.email]}),t.phone&&(0,a.jsxs)(k.E,{className:"text-sm mb-2",children:[i("contact.adminNotification.phone")," ",t.phone]}),!t.phone&&(0,a.jsxs)(k.E,{className:"text-sm mb-2",children:[i("contact.adminNotification.phone")," ",i("contact.adminNotification.phoneNotProvided")]}),(0,a.jsxs)(k.E,{className:"text-sm mb-2",children:[i("contact.adminNotification.subjectLabel")," ",t.subject]}),(0,a.jsxs)(k.E,{className:"text-sm mb-2",children:[i("contact.adminNotification.source")," ",t.source]}),(0,a.jsxs)(k.E,{className:"text-sm mb-2",children:[i("contact.adminNotification.submitted")," ",t.createdAt]}),(0,a.jsxs)(k.E,{className:"text-sm mb-2",children:[i("contact.adminNotification.submissionId")," ",t.id]})]}),(0,a.jsx)(ee.Hr,{className:"my-4"}),(0,a.jsx)(k.E,{className:"text-sm font-semibold mb-2",children:i("contact.adminNotification.message")}),(0,a.jsx)(k.E,{className:"text-base mb-4",style:{whiteSpace:"pre-wrap"},children:t.message})]})},ei=e=>{let{email:t,unsubscribeToken:i,t:r}=e,n=O(),s="Cable Creations: ".concat(r("newsletter.subscriptionConfirmation.subject")),o="".concat(n,"/unsubscribe?token=").concat(i,"&email=").concat(encodeURIComponent(t));return(0,a.jsxs)(X,{previewText:s,children:[(0,a.jsx)(N.D,{className:"text-2xl font-bold mb-4",children:r("newsletter.subscriptionConfirmation.greeting")}),(0,a.jsx)(k.E,{className:"text-base mb-4",children:r("newsletter.subscriptionConfirmation.thankYou")}),(0,a.jsx)(k.E,{className:"text-base mb-4",children:r("newsletter.subscriptionConfirmation.description")}),(0,a.jsx)(k.E,{className:"text-base mt-6",children:r("newsletter.subscriptionConfirmation.signature")}),(0,a.jsxs)(k.E,{className:"text-xs text-muted mt-8",children:[r("newsletter.subscriptionConfirmation.unsubscribeText")," ",(0,a.jsx)(S.N,{href:o,children:r("newsletter.subscriptionConfirmation.unsubscribeLink")}),"."]})]})},ea=e=>{let{email:t,t:i}=e,r=O(),n="Cable Creations: ".concat(i("newsletter.unsubscriptionConfirmation.subject")),s="".concat(r,"/?resubscribe=").concat(encodeURIComponent(t));return(0,a.jsxs)(X,{previewText:n,children:[(0,a.jsx)(N.D,{className:"text-2xl font-bold mb-4",children:i("newsletter.unsubscriptionConfirmation.greeting")}),(0,a.jsx)(k.E,{className:"text-base mb-4",children:i("newsletter.unsubscriptionConfirmation.message",{email:t})}),(0,a.jsx)(k.E,{className:"text-base mb-4",children:i("newsletter.unsubscriptionConfirmation.feedback")}),(0,a.jsx)(k.E,{className:"text-base mb-6",children:i("newsletter.unsubscriptionConfirmation.resubscribeText")}),(0,a.jsx)(C.w,{className:"text-center",children:(0,a.jsx)(E.$,{href:s,className:"bg-electric-blue text-white font-semibold py-3 px-6 rounded-lg",style:{background:"linear-gradient(135deg, #0066cc, #007aff)",color:"#ffffff",fontWeight:"600",padding:"12px 24px",borderRadius:"12px",textDecoration:"none",display:"inline-block",border:"1px solid rgba(255, 255, 255, 0.08)",boxShadow:"0 0 15px rgba(0, 122, 255, 0.3)",fontFamily:"Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif"},children:i("newsletter.unsubscriptionConfirmation.resubscribeButton")})}),(0,a.jsx)(k.E,{className:"text-base mt-6",children:i("newsletter.unsubscriptionConfirmation.signature")})]})};class er{async sendEmail(e){try{let t=new Y(e);if(!t.isValid())return console.error("Invalid email message:",e),!1;let i=await this.emailRepository.logEmail(t,"pending");if(await this.emailProvider.send(t))return await this.emailRepository.updateEmailStatus(i,"sent"),!0;{let e="Failed to send email using ".concat(this.emailProvider.getProviderName());return await this.emailRepository.updateEmailStatus(i,"failed",e),!1}}catch(e){return console.error("Error sending email:",e),!1}}async sendInternationalizedEmail(e,t,i,a,r){try{if(!this.renderingService)throw Error("Rendering service is required for internationalized emails");let n=this.templateMap[e];if(!n)throw Error("Template '".concat(e,"' not found"));let s=await (0,$.ei)("Email",i),o=Z.create(e,i,a,null==r?void 0:r.metadata),l=null==r?void 0:r.subject;if(!l)try{let t=e.replace("/",".").replace(/-([a-z])/g,(e,t)=>t.toUpperCase());l=s("".concat(t,".subject"))}catch(e){l=(null==r?void 0:r.subject)||"Email from Cable Creations"}let c={...a,t:s},d=await this.renderingService.renderComponent(n,c,o,null==r?void 0:r.renderingOptions),u={to:t,from:(null==r?void 0:r.from)||"info@cablecreations.de",subject:l,html:d.html,text:d.plainText||d.html.replace(/<[^>]*>/g,""),metadata:{template:e,locale:i,originalData:a,renderingMetadata:d.metadata,...null==r?void 0:r.metadata}};return await this.sendEmail(u)}catch(t){return console.error("Error sending internationalized email with template ".concat(e,":"),t),!1}}async sendSimpleInternationalizedEmail(e,t,i,a){let r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},n=arguments.length>5?arguments[5]:void 0;try{if(!this.translationService)throw Error("Translation service is required for internationalized emails");let s={locale:J.fromString(a,"en"),templateName:"simple",data:r},o=K.create("Email",t),l=K.create("Email",i),[c,d]=await Promise.all([this.translationService.resolveTranslation(o,s,r),this.translationService.resolveTranslation(l,s,r)]),u='\n <!DOCTYPE html>\n <html>\n <head>\n <meta charset="utf-8">\n <title>'.concat(c.value,'</title>\n </head>\n <body>\n <div style="font-family: Arial, sans-serif; max-width: 600px; margin: 0 auto; padding: 20px;">\n ').concat(d.value.replace(/\n/g,"<br>"),"\n </div>\n </body>\n </html>\n "),h={to:e,from:(null==n?void 0:n.from)||"info@cablecreations.de",subject:c.value,html:u,text:d.value,metadata:{type:"simple_internationalized",locale:a,subjectKey:t,contentKey:i,originalData:r,...null==n?void 0:n.metadata}};return await this.sendEmail(h)}catch(e){return console.error("Error sending simple internationalized email:",e),!1}}async resendEmail(e){try{let t=await this.emailRepository.getEmailById(e);if(!t)return console.error("Email not found:",e),!1;await this.emailRepository.incrementRetryCount(e);let i=new Y(t.message);if(await this.emailProvider.send(i))return await this.emailRepository.updateEmailStatus(e,"sent"),!0;{let t="Failed to resend email using ".concat(this.emailProvider.getProviderName());return await this.emailRepository.updateEmailStatus(e,"failed",t),!1}}catch(e){return console.error("Error resending email:",e),!1}}setTranslationService(e){this.translationService=e}setRenderingService(e){this.renderingService=e}getTranslationService(){return this.translationService}getRenderingService(){return this.renderingService}isInternationalizationAvailable(){return!!(this.translationService&&this.renderingService)}async getSupportedLocales(){if(!this.translationService)return[];try{return(await this.translationService.getSupportedLocales()).map(e=>e.code)}catch(e){return console.error("Error getting supported locales:",e),[]}}constructor(e,t,i,a){this.templateMap={"contact/user-confirmation":Q,"contact/admin-notification":et,"newsletter/subscription-confirmation":ei,"newsletter/unsubscription-confirmation":ea},this.emailProvider=e,this.emailRepository=t,this.translationService=i,this.renderingService=a}}var en=i(38127),es=i(98999),eo=i.n(es),el=i(8187),ec=i(49509);class ed{initialize(){if(this.initialized)return;let e=ec.env.MAILGUN_API_KEY;this.domain=ec.env.MAILGUN_DOMAIN||"mg.cablecreations.de";let t=ec.env.MAILGUN_REGION||"US";if(!e)throw Error("MAILGUN_API_KEY environment variable is required");if(!this.domain)throw Error("MAILGUN_DOMAIN environment variable is required");let i="EU"===t.toUpperCase()?"https://api.eu.mailgun.net":"https://api.mailgun.net",a=ec.env.MAILGUN_URL||i,r=new en.A(eo());this.mailgun=r.client({username:"api",key:e,url:a}),this.initialized=!0}async send(e){this.initialize();try{let t=e.html;if("object"==typeof e.html&&null!==e.html)try{t=await (0,el.XX)(e.html)}catch(e){console.warn("Failed to render React email component, using text fallback:",e),t=void 0}let i={from:e.from,to:e.to,subject:e.subject,text:e.text,...t&&{html:t}},a=await this.mailgun.messages.create(this.domain,i);return console.log("Email sent successfully via Mailgun:",{id:a.id,message:a.message,to:e.to,subject:e.subject}),!0}catch(e){return console.error("Failed to send email via Mailgun:",e),!1}}getProviderName(){return"Mailgun"}constructor(){this.initialized=!1}}class eu{async logEmail(e,t){if(!this.cookiesFn)throw console.warn("SupabaseEmailRepository: No cookies function provided, this operation requires server-side execution"),Error("Cannot log email from client component");let i=(0,w.d)(this.cookiesFn);try{let{data:a,error:r}=await i.from("email_logs").insert({to_email:e.to,from_email:e.from,subject:e.subject,content:e.text,html_content:e.html||null,status:t,metadata:e.metadata||null}).select().single();if(r)throw console.error("Error logging email:",r),r;return a.id}catch(e){throw console.error("Error in logEmail:",e),e}}async updateEmailStatus(e,t,i){if(!this.cookiesFn)return console.warn("SupabaseEmailRepository: No cookies function provided, this operation requires server-side execution"),!1;let a=(0,w.d)(this.cookiesFn);try{let r={status:t};"sent"===t&&(r.sent_at=new Date().toISOString()),"failed"===t&&i&&(r.error_message=i);let{error:n}=await a.from("email_logs").update(r).eq("id",e);if(n)return console.error("Error updating email status:",n),!1;return!0}catch(e){return console.error("Error in updateEmailStatus:",e),!1}}async getEmailById(e){if(!this.cookiesFn)return console.warn("SupabaseEmailRepository: No cookies function provided, this operation requires server-side execution"),null;let t=(0,w.d)(this.cookiesFn);try{let{data:i,error:a}=await t.from("email_logs").select("*").eq("id",e).single();if(a||!i)return console.error("Error fetching email:",a),null;return{id:i.id,message:{to:i.to_email||"",from:i.from_email||"",subject:i.subject||"",text:i.content||"",html:i.html_content||void 0,metadata:"object"==typeof i.metadata?i.metadata:void 0},status:i.status,retryCount:i.retry_count,errorMessage:i.error_message||void 0}}catch(e){return console.error("Error in getEmailById:",e),null}}async incrementRetryCount(e){if(!this.cookiesFn)return console.warn("SupabaseEmailRepository: No cookies function provided, this operation requires server-side execution"),!1;let t=(0,w.d)(this.cookiesFn);try{let{data:i,error:a}=await t.from("email_logs").select("retry_count").eq("id",e).single();if(a||!i)return console.error("Error fetching email for retry count update:",a),!1;let{error:r}=await t.from("email_logs").update({retry_count:(i.retry_count||0)+1}).eq("id",e);if(r)return console.error("Error incrementing retry count:",r),!1;return!0}catch(e){return console.error("Error in incrementRetryCount:",e),!1}}constructor(e=null){this.cookiesFn=e}}var eh=i(35624),em=i(96110);function ep(){let[e,t]=(0,r.useState)(!1),{hasInteracted:i}=(0,eh.uC)(),{isModalOpen:n,openModal:s,closeModal:o}=(0,em.p)(),l=function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0,i=e?new j(t||null):new y;return new g(new f(i,new V(new er(new ed,new eu(e&&t||null))),new G),new b(i),i)}(!1);return((0,r.useEffect)(()=>{(async()=>{try{let e="true"===localStorage.getItem("hasSeenBrochureModal");if(t(!0),n||e)return;let a=null,r=null;return a=setTimeout(()=>{i?s():r=setTimeout(()=>{"true"!==localStorage.getItem("hasSeenBrochureModal")&&s()},1e4)},1e4),()=>{a&&clearTimeout(a),r&&clearTimeout(r)}}catch(e){console.error("Error checking brochure seen status:",e),t(!0)}})()},[i,l,n,s]),e)?(0,a.jsx)(x,{isOpen:n,onClose:o}):null}},85909:(e,t,i)=>{"use strict";i.d(t,{Z:()=>a}),i(22295);class a{update(e,t){return"essential"!==e||t?new a({...this.toJSON(),[e]:t}):this}acceptAll(){return new a({essential:!0,analytics:!0,marketing:!0})}rejectNonEssential(){return new a({essential:!0,analytics:!1,marketing:!1})}toJSON(){return{essential:this.essential,analytics:this.analytics,marketing:this.marketing}}static fromJSON(e){return e?new a(e):new a}constructor(e={}){var t,i;this.essential=!0,this.analytics=null!==(t=e.analytics)&&void 0!==t&&t,this.marketing=null!==(i=e.marketing)&&void 0!==i&&i}}},86442:(e,t,i)=>{"use strict";i.d(t,{yP:()=>n.AnalyticsProvider,Ml:()=>b,xS:()=>w,sx:()=>f,Du:()=>j,Ui:()=>y,st:()=>s.s,Lq:()=>s.L});var a=i(881);class r{async execute(e){try{let{name:t,properties:i={},timestamp:r=new Date}=e,n=new a.XN({name:t,properties:i,timestamp:r});await this.analyticsService.trackEvent(n)}catch(e){console.error("Error tracking event:",e)}}constructor(e){this.analyticsService=e}}var n=i(62832),s=i(95627);i(90658),i(24898);var o=i(13770);class l{async execute(e){try{let{url:t,title:i,referrer:a}=e;if(t.startsWith("/admin")||t.includes("://")&&new URL(t).pathname.startsWith("/admin"))return;await this.analyticsService.trackPageView(t,i,a)}catch(e){console.error("Error tracking page view:",e)}}constructor(e){this.analyticsService=e}}var c=i(1696);class d{async trackAddToCart(e){try{let t={id:e.id,name:e.name,price:e.price,currency:e.currency,quantity:e.quantity},i=c.b.addToCart(t);await this.analyticsService.trackEvent(i)}catch(e){console.error("Error tracking add to cart event:",e)}}async trackRemoveFromCart(e){try{let t={id:e.id,name:e.name,price:e.price,currency:e.currency,quantity:e.quantity},i=c.b.removeFromCart(t);await this.analyticsService.trackEvent(i)}catch(e){console.error("Error tracking remove from cart event:",e)}}async trackBeginCheckout(e){try{let t={total:e.total,currency:e.currency,items:e.items.map(e=>({id:e.id,name:e.name,price:e.price,currency:e.currency,quantity:e.quantity}))},i=c.b.beginCheckout(t);await this.analyticsService.trackEvent(i)}catch(e){console.error("Error tracking begin checkout event:",e)}}async trackPurchase(e){try{let t={transaction_id:e.transaction_id,total:e.total,currency:e.currency,items:e.items.map(e=>({id:e.id,name:e.name,price:e.price,quantity:e.quantity}))},i=c.b.purchase(t);await this.analyticsService.trackEvent(i)}catch(e){console.error("Error tracking purchase event:",e)}}constructor(e){this.analyticsService=e}}var u=i(64697),h=i(44036);let m=new u.e,p=new h.l,x=new o.c(m,p),g=new r(x);new l(x);let v=new d(x),f=async(e,t)=>await g.execute({name:e,properties:t}),b=async e=>await v.trackAddToCart(e),y=async e=>await v.trackRemoveFromCart(e),w=async e=>await v.trackBeginCheckout(e),j=async e=>await v.trackPurchase(e)},86836:(e,t,i)=>{"use strict";i.d(t,{AnalyticsProviderWrapper:()=>n});var a=i(95155);i(12115);var r=i(86442);function n(e){let{children:t}=e;return(0,a.jsx)(r.yP,{children:t})}},88760:(e,t,i)=>{"use strict";i.d(t,{dj:()=>h});var a=i(12115);let r=0,n=new Map,s=e=>{if(n.has(e))return;let t=setTimeout(()=>{n.delete(e),d({type:"REMOVE_TOAST",toastId:e})},1e6);n.set(e,t)},o=(e,t)=>{switch(t.type){case"ADD_TOAST":return{...e,toasts:[t.toast,...e.toasts].slice(0,5)};case"UPDATE_TOAST":return{...e,toasts:e.toasts.map(e=>e.id===t.toast.id?{...e,...t.toast}:e)};case"DISMISS_TOAST":{let{toastId:i}=t;return i?s(i):e.toasts.forEach(e=>{s(e.id)}),{...e,toasts:e.toasts.map(e=>e.id===i||void 0===i?{...e,open:!1}:e)}}case"REMOVE_TOAST":if(void 0===t.toastId)return{...e,toasts:[]};return{...e,toasts:e.toasts.filter(e=>e.id!==t.toastId)}}},l=[],c={toasts:[]};function d(e){c=o(c,e),l.forEach(e=>{e(c)})}function u(e){let{...t}=e,i=(r=(r+1)%Number.MAX_VALUE).toString(),a=()=>d({type:"DISMISS_TOAST",toastId:i});return d({type:"ADD_TOAST",toast:{...t,id:i,open:!0,onOpenChange:e=>{e||a()}}}),{id:i,dismiss:a,update:e=>d({type:"UPDATE_TOAST",toast:{...e,id:i}})}}function h(){let[e,t]=a.useState(c);return a.useEffect(()=>(l.push(t),()=>{let e=l.indexOf(t);e>-1&&l.splice(e,1)}),[e]),{...e,toast:u,dismiss:e=>d({type:"DISMISS_TOAST",toastId:e})}}},93376:(e,t,i)=>{"use strict";i.d(t,{e:()=>r,V:()=>n});var a=i(85909);class r{async execute(){try{let[e,t]=await Promise.all([this.cookieConsentService.getConsent(),this.cookieConsentService.hasUserInteracted()]);return{consent:e,hasInteracted:t}}catch(e){return console.error("Error getting cookie consent:",e),{consent:new a.Z,hasInteracted:!1}}}constructor(e){this.cookieConsentService=e}}class n{async updateCategory(e){try{let{category:t,value:i}=e;return await this.cookieConsentService.updateConsent(t,i)}catch(e){return console.error("Error updating cookie consent category:",e),null}}async acceptAll(){try{return await this.cookieConsentService.acceptAll()}catch(e){return console.error("Error accepting all cookies:",e),null}}async rejectNonEssential(){try{return await this.cookieConsentService.rejectNonEssential()}catch(e){return console.error("Error rejecting non-essential cookies:",e),null}}constructor(e){this.cookieConsentService=e}}},95627:(e,t,i)=>{"use strict";i.d(t,{L:()=>r.usePageViewTracking,s:()=>a.useAnalytics});var a=i(35244),r=i(81023)},96110:(e,t,i)=>{"use strict";i.d(t,{BrochureModalContextProvider:()=>o,p:()=>s});var a=i(95155),r=i(12115);let n=(0,r.createContext)({isModalOpen:!1,openModal:()=>{},closeModal:()=>{}}),s=()=>(0,r.useContext)(n);function o(e){let{children:t}=e,[i,s]=(0,r.useState)(!1);return(0,a.jsx)(n.Provider,{value:{isModalOpen:i,openModal:()=>{localStorage.removeItem("hasSeenBrochureModal"),s(!0)},closeModal:()=>{s(!1),localStorage.setItem("hasSeenBrochureModal","true")}},children:t})}},96765:(e,t,i)=>{"use strict";i.d(t,{cn:()=>n});var a=i(52596),r=i(39688);function n(){for(var e=arguments.length,t=Array(e),i=0;i<e;i++)t[i]=arguments[i];return(0,r.QP)((0,a.$)(t))}},97124:(e,t,i)=>{"use strict";i.d(t,{X:()=>n,y:()=>s});var a=i(95155);i(12115);var r=i(37281);let n=e=>{let{className:t,...i}=e;return(0,a.jsx)(r.P.svg,{xmlns:"http://www.w3.org/2000/svg",className:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",animate:{rotate:360},transition:{repeat:1/0,duration:1,ease:"linear"},...i,children:(0,a.jsx)("path",{d:"M21 12a9 9 0 1 1-6.219-8.56"})})},s=e=>{let{className:t,...i}=e;return(0,a.jsx)(r.P.svg,{xmlns:"http://www.w3.org/2000/svg",className:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",animate:{rotate:360},transition:{repeat:1/0,duration:1,ease:"linear"},...i,children:(0,a.jsx)("path",{d:"M16.023 9.348h4.992v-.001M2.985 19.644v-4.992m0 0h4.992m-4.993 0l3.181 3.183a8.25 8.25 0 0013.803-3.7M4.031 9.865a8.25 8.25 0 0113.803-3.7l3.181 3.182m0-4.991v4.99"})})}},99459:(e,t,i)=>{"use strict";i.d(t,{Toaster:()=>g});var a=i(95155),r=i(12115),n=i(66964),s=i(96765),o=i(44475);let l=n.Kq,c=r.forwardRef((e,t)=>{let{className:i,...r}=e;return(0,a.jsx)(n.LM,{ref:t,className:(0,s.cn)("fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col md:max-w-[420px]",i),...r})});c.displayName=n.LM.displayName;let d={default:"bg-background border",destructive:"destructive group border-destructive bg-destructive text-destructive-foreground",warning:"warning group border-yellow-500 bg-yellow-50 text-yellow-800"},u=r.forwardRef((e,t)=>{let{className:i,variant:r="default",...o}=e;return(0,a.jsx)(n.bL,{ref:t,className:(0,s.cn)("group pointer-events-auto relative flex w-full items-center justify-between space-x-4 overflow-hidden rounded-md border p-6 pr-8 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full",d[r],i),...o})});u.displayName=n.bL.displayName,r.forwardRef((e,t)=>{let{className:i,...r}=e;return(0,a.jsx)(n.rc,{ref:t,className:(0,s.cn)("inline-flex h-8 shrink-0 items-center justify-center rounded-md border bg-transparent px-3 text-sm font-medium ring-offset-background transition-colors hover:bg-secondary focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 group-[.destructive]:border-muted/40 group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:bg-destructive group-[.destructive]:hover:text-destructive-foreground group-[.destructive]:focus:ring-destructive cursor-pointer",i),...r})}).displayName=n.rc.displayName;let h=r.forwardRef((e,t)=>{let{className:i,...r}=e;return(0,a.jsx)(n.bm,{ref:t,className:(0,s.cn)("absolute right-2 top-2 rounded-md p-1 text-foreground/50 opacity-0 transition-opacity hover:text-foreground focus:opacity-100 focus:outline-none focus:ring-2 group-hover:opacity-100 group-[.destructive]:text-red-300 group-[.destructive]:hover:text-red-50 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600 cursor-pointer",i),"toast-close":"",...r,children:(0,a.jsx)(o.M,{className:"h-4 w-4"})})});h.displayName=n.bm.displayName;let m=r.forwardRef((e,t)=>{let{className:i,...r}=e;return(0,a.jsx)(n.hE,{ref:t,className:(0,s.cn)("text-sm font-semibold",i),...r})});m.displayName=n.hE.displayName;let p=r.forwardRef((e,t)=>{let{className:i,...r}=e;return(0,a.jsx)(n.VY,{ref:t,className:(0,s.cn)("text-sm opacity-90",i),...r})});p.displayName=n.VY.displayName;var x=i(88760);function g(){let{toasts:e}=(0,x.dj)();return(0,a.jsxs)(l,{children:[e.map(function(e){let{id:t,title:i,description:r,action:n,...s}=e;return(0,a.jsxs)(u,{...s,children:[(0,a.jsxs)("div",{className:"grid gap-1",children:[i&&(0,a.jsx)(m,{children:i}),r&&(0,a.jsx)(p,{children:r})]}),n,(0,a.jsx)(h,{})]},t)}),(0,a.jsx)(c,{})]})}}},e=>{var t=t=>e(e.s=t);e.O(0,[2508,3442,54,6874,5591,1935,3063,4277,6454,7932,3533,6703,8585,5244,6129,9135,4503,6315,7358],()=>t(48061)),_N_E=e.O()}]); |