Files
doormilebuild/build/_next/static/chunks/0ckcqe5on274m.js
2026-06-08 16:39:29 +05:30

1 line
18 KiB
JavaScript

(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,64083,e=>{"use strict";var t=e.i(43476),r=e.i(71645),n=e.i(75056),i=e.i(25234),o=e.i(28600),s=e.i(79877),a=e.i(33623);let l="#020617",c="#00E5FF",u="#22C55E",h="#EF4444",p=(e,t,r)=>e+(t-e)*r;function m(e,t,r){let n,i=(n=(r-e)/(t-e||1))<0?0:n>1?1:n;return i*i*(3-2*i)}function f(e,t,r,n){return p(e,t,1-Math.exp(-r*n))}function d(e){let t=43758.5453*Math.sin(127.1*e+311.7);return t-Math.floor(t)}var g=e.i(90072);let x=new g.Color(c),j=new g.Color(h),M=new g.Color(u),y=Array.from({length:5},(e,t)=>{let r=t/5*Math.PI*2+.3,n=7+3*d(7*t+1),i=Math.cos(r)*n,o=Math.sin(r)*n;return new g.Vector3(i,.1,o)}),v=r.default.memo(function({progress:e}){let n=(0,r.useRef)(null),o=(0,r.useRef)([]),s=(0,r.useRef)([]),a=(0,r.useRef)([]),l=(0,r.useRef)(0),u=(0,r.useMemo)(()=>y.map(e=>{let t=[new g.Vector3(0,.15,0),new g.Vector3(.5*e.x,.6,.5*e.z),new g.Vector3(e.x,.15,e.z)];return new g.CatmullRomCurve3(t).getPoints(24)}),[]);return(0,i.useFrame)((t,r)=>{let i=e.current??0;l.current=f(l.current,i,3,r);let c=l.current,u=t.clock.elapsedTime;n.current&&(n.current.position.y=.04*Math.sin(1.2*u)),o.current.forEach((e,t)=>{e&&(e.rotation.y=u*(.8+.2*t))}),s.current.forEach((e,t)=>{if(e){let r=m(.45,.8,c);e.color.copy(j).lerp(t%2==0?x:M,r),e.opacity=p(.12,.7,r)*(.8+.2*Math.sin(4*u-.5*t))}}),a.current.forEach((e,t)=>{if(e){let r=m(.5,.82,c);e.color.copy(j).lerp(t%2==0?x:M,r),e.opacity=p(.06,.22,r)*(.85+.15*Math.sin(3*u-t))}})}),(0,t.jsxs)("group",{children:[(0,t.jsx)("gridHelper",{args:[60,48,c,c],position:[0,-.01,0],children:(0,t.jsx)("lineBasicMaterial",{attach:"material",color:c,transparent:!0,opacity:.05})}),u.map((e,r)=>(0,t.jsxs)("line",{children:[(0,t.jsx)("bufferGeometry",{children:(0,t.jsx)("float32BufferAttribute",{attach:"attributes-position",args:[new Float32Array(e.flatMap(e=>[e.x,e.y,e.z])),3]})}),(0,t.jsx)("lineBasicMaterial",{ref:e=>{s.current[r]=e},transparent:!0,opacity:.15,depthWrite:!1})]},`corr${r}`)),(0,t.jsxs)("group",{ref:n,position:[0,0,0],children:[(0,t.jsxs)("mesh",{position:[0,.35,0],children:[(0,t.jsx)("boxGeometry",{args:[2.2,.7,1.8]}),(0,t.jsx)("meshBasicMaterial",{color:"#0B1220"})]}),(0,t.jsxs)("mesh",{position:[0,.35,0],children:[(0,t.jsx)("boxGeometry",{args:[2.2,.7,1.8]}),(0,t.jsx)("meshBasicMaterial",{color:c,wireframe:!0,transparent:!0,opacity:.65})]}),[-.6,0,.6].map((e,r)=>(0,t.jsxs)("mesh",{position:[e,.18,.91],children:[(0,t.jsx)("boxGeometry",{args:[.3,.35,.06]}),(0,t.jsx)("meshBasicMaterial",{color:c,transparent:!0,opacity:.8})]},r)),(0,t.jsxs)("mesh",{position:[0,.85,0],children:[(0,t.jsx)("boxGeometry",{args:[1.2,.3,1]}),(0,t.jsx)("meshBasicMaterial",{color:c,transparent:!0,opacity:.15})]}),(0,t.jsxs)("mesh",{position:[0,.85,0],children:[(0,t.jsx)("boxGeometry",{args:[1.2,.3,1]}),(0,t.jsx)("meshBasicMaterial",{color:c,wireframe:!0,transparent:!0,opacity:.9})]}),[-.4,.4].map((e,r)=>(0,t.jsxs)("mesh",{position:[e,.71,-.4],rotation:[.15,0,0],children:[(0,t.jsx)("boxGeometry",{args:[.5,.03,.6]}),(0,t.jsx)("meshBasicMaterial",{color:"#1e293b"})]},r)),(0,t.jsxs)("group",{position:[0,1,0],children:[(0,t.jsxs)("mesh",{position:[0,.4,0],children:[(0,t.jsx)("cylinderGeometry",{args:[.03,.03,.8,8]}),(0,t.jsx)("meshBasicMaterial",{color:c})]}),(0,t.jsxs)("mesh",{position:[0,.8,0],children:[(0,t.jsx)("sphereGeometry",{args:[.12,16,16]}),(0,t.jsx)("meshBasicMaterial",{color:"#ffffff"})]})]}),(0,t.jsxs)("mesh",{rotation:[-Math.PI/2,0,0],position:[0,.02,0],children:[(0,t.jsx)("ringGeometry",{args:[1.8,2.2,32]}),(0,t.jsx)("meshBasicMaterial",{color:c,transparent:!0,opacity:.3,blending:g.AdditiveBlending})]})]})]})}),b=new g.Vector3(0,.5,0);function A(e){return new g.CatmullRomCurve3(e,!1,"catmullrom",.5)}let B=null;function w(){if(B)return B;let e=[],t=[];for(let r=0;r<5;r++){let n=r/5*Math.PI*2+.3,i=7+3*d(7*r+1),o=Math.cos(n)*i,s=Math.sin(n)*i,a=2+Math.floor(2*d(7*r+2)),l=[b.clone()];l.push(new g.Vector3(.35*o,.45+1.4,.35*s));let c=[];for(let e=0;e<a;e++){let n=(d(31*r+5*e+3)-.5)*3.2,i=(d(31*r+5*e+4)-.5)*3.2,a=new g.Vector3(o+n,.45,s+i);c.push(a),t.push(a),l.push(a.clone())}e.push({curve:A(l),nodes:c})}let r=[],n=[];for(let e=0;e<6;e++){let t=4+Math.floor(3*d(13*e+1)),i=[b.clone()],o=d(13*e+2)*Math.PI*2,s=[];for(let r=0;r<t;r++){o+=(d(13*e+3*r+3)-.5)*2.6;let a=2.6+6.4*d(13*e+3*r+4),l=Math.cos(o)*a+(d(17*e+r)-.5)*2.6,c=Math.sin(o)*a+(d(19*e+r)-.5)*2.6,u=.45+1.1*d(23*e+r),h=new g.Vector3(l,u,c);if(i.push(h),r===t-1){let e=new g.Vector3(l,.45,c);n.push(e),s.push(e)}}r.push({curve:A(i),nodes:s})}return B={chaotic:r,optimized:e,chaosNodes:n,optimizedNodes:t}}let R=r.default.memo(function({position:e,color:n,maxScale:o=2.2,pulseSpeed:s=2.4}){let a=(0,r.useRef)(null),l=(0,r.useRef)(null);return(0,i.useFrame)(e=>{if(!a.current||!l.current)return;let t=s/4*e.clock.elapsedTime%1;a.current.scale.setScalar(.4+t*(o-.4)),l.current.opacity=.72*Math.sin((1-t)*Math.PI)}),(0,t.jsxs)("mesh",{ref:a,position:[e.x,.03,e.z],rotation:[-Math.PI/2,0,0],children:[(0,t.jsx)("ringGeometry",{args:[.22,.28,24]}),(0,t.jsx)("meshBasicMaterial",{ref:l,color:n,transparent:!0,opacity:0,depthWrite:!1,blending:g.AdditiveBlending})]})}),P=new g.Vector3,S=new g.Vector3,G=r.default.memo(function({progress:e,chaoticCurves:n}){let o=4*n.length,s=(0,r.useRef)([]),a=(0,r.useRef)([]),l=(0,r.useMemo)(()=>Array.from({length:o},(e,t)=>d(13*t+3)),[o]),c=(0,r.useMemo)(()=>Array.from({length:2*n.length},(e,t)=>t%2/2),[n.length]);return(0,i.useFrame)(t=>{let r=1-m(.48,.6,e.current??0),i=r>.01;if(s.current.forEach(e=>{e&&(e.visible=i)}),a.current.forEach(e=>{e&&(e.visible=i)}),!i)return;let u=t.clock.elapsedTime;for(let e=0;e<o;e++){let t=s.current[e];if(!t)continue;let i=n[Math.floor(e/4)],o=.05+.03*d(9*e),a=(l[e]+u*o)%1;i.getPointAt(a,P),t.position.copy(P),t.material.opacity=.6*r*Math.sin(a*Math.PI)}for(let e=0;e<2*n.length;e++){let t=a.current[e];if(!t)continue;let i=n[Math.floor(e/2)],o=(c[e]+.04*u)%1;i.getPointAt(o,P),i.getTangentAt(o,S),t.position.copy(P),t.rotation.y=Math.atan2(S.x,S.z),t.traverse(e=>{let t=e.material;t&&"opacity"in t&&(t.opacity=.5*r*Math.sin(o*Math.PI))})}}),(0,t.jsxs)("group",{children:[Array.from({length:o}).map((e,r)=>(0,t.jsxs)("mesh",{ref:e=>{s.current[r]=e},visible:!1,children:[(0,t.jsx)("sphereGeometry",{args:[.06,6,6]}),(0,t.jsx)("meshBasicMaterial",{color:h,transparent:!0,opacity:0,depthWrite:!1,blending:g.AdditiveBlending})]},`cp-${r}`)),Array.from({length:2*n.length}).map((e,r)=>(0,t.jsx)("group",{ref:e=>{a.current[r]=e},visible:!1,children:(0,t.jsxs)("mesh",{rotation:[Math.PI/2,0,0],children:[(0,t.jsx)("coneGeometry",{args:[.06,.16,4]}),(0,t.jsx)("meshBasicMaterial",{color:h,transparent:!0,opacity:0,depthWrite:!1,blending:g.AdditiveBlending})]})},`cc-${r}`))]})}),E=new g.Vector3,T=new g.Vector3,k=r.default.memo(function({progress:e,optimizedCurves:n}){let o=6*n.length,s=(0,r.useRef)([]),a=(0,r.useRef)([]),l=(0,r.useRef)([]),h=(0,r.useMemo)(()=>Array.from({length:o},(e,t)=>d(17*t+4)),[o]),p=(0,r.useMemo)(()=>Array.from({length:3*n.length},(e,t)=>t%3/3),[n.length]);return(0,i.useFrame)(t=>{let r=m(.52,.7,e.current??0),i=r>.01;if(s.current.forEach(e=>{e&&(e.visible=i)}),a.current.forEach(e=>{e&&(e.visible=i)}),l.current.forEach(e=>{e&&(e.visible=i)}),!i)return;let c=t.clock.elapsedTime;for(let e=0;e<o;e++){let t=s.current[e];if(!t)continue;let i=n[Math.floor(e/6)],o=.08+.04*d(11*e),a=(h[e]+c*o)%1;i.getPointAt(a,E),t.position.copy(E),t.material.opacity=.75*r*Math.sin(a*Math.PI);let l=.04+.012*Math.sin(6*c+e);t.scale.setScalar(l/.05)}for(let e=0;e<3*n.length;e++){let t=a.current[e];if(!t)continue;let i=n[Math.floor(e/3)],o=(p[e]+.16*c)%1;i.getPointAt(o,E),i.getTangentAt(o,T),t.position.copy(E),t.rotation.y=Math.atan2(T.x,T.z),t.rotation.x=Math.atan2(T.y,Math.sqrt(T.x*T.x+T.z*T.z))-Math.PI/2,t.traverse(e=>{let t=e.material;t&&"opacity"in t&&(t.opacity=.85*r*Math.sin(o*Math.PI))})}for(let e=0;e<n.length;e++){let t=l.current[e];if(!t)continue;let i=n[e],o=(.55*c+.2*e)%1;i.getPointAt(o,E),t.position.copy(E),t.material.opacity=.9*r*Math.sin(o*Math.PI);let s=.08+.02*Math.sin(12*c+e);t.scale.setScalar(s/.07)}}),(0,t.jsxs)("group",{children:[Array.from({length:o}).map((e,r)=>{let n=Math.floor(r/6)%2==0?c:u;return(0,t.jsxs)("mesh",{ref:e=>{s.current[r]=e},visible:!1,children:[(0,t.jsx)("sphereGeometry",{args:[.05,8,8]}),(0,t.jsx)("meshBasicMaterial",{color:n,transparent:!0,opacity:0,depthWrite:!1,blending:g.AdditiveBlending})]},`op-${r}`)}),Array.from({length:3*n.length}).map((e,r)=>{let n=Math.floor(r/3)%2==0?c:u;return(0,t.jsx)("group",{ref:e=>{a.current[r]=e},visible:!1,children:(0,t.jsxs)("mesh",{rotation:[Math.PI/2,0,0],children:[(0,t.jsx)("coneGeometry",{args:[.07,.2,4]}),(0,t.jsx)("meshBasicMaterial",{color:n,transparent:!0,opacity:0,depthWrite:!1,blending:g.AdditiveBlending})]})},`oc-${r}`)}),n.map((e,r)=>(0,t.jsxs)("mesh",{ref:e=>{l.current[r]=e},visible:!1,children:[(0,t.jsx)("sphereGeometry",{args:[.07,12,12]}),(0,t.jsx)("meshBasicMaterial",{color:r%2==0?c:u,transparent:!0,opacity:0,depthWrite:!1,blending:g.AdditiveBlending})]},`pulse-${r}`))]})}),z=r.default.memo(function({progress:e,reduced:n=!1,isMobile:o=!1}){let{chaotic:s,optimized:a,chaosNodes:l,optimizedNodes:p}=(0,r.useMemo)(()=>w(),[]),f=(0,r.useRef)([]),d=(0,r.useRef)([]),x=(0,r.useRef)(null),j=(0,r.useRef)(null),M=(e,t)=>{if(!e.index)return;let r=Math.max(0,36*Math.floor(e.index.count*t/36));e.setDrawRange(0,r)};return(0,i.useFrame)(t=>{let r=e.current??0,n=t.clock.elapsedTime,i=1-m(.4,.56,r),o=(1-m(.38,.55,r))*.85,s=.7+.18*Math.sin(7*n);for(let e of f.current)e?.geo&&(M(e.geo,i),e.mat&&(e.mat.opacity=o*s));let a=m(.55,.74,r),l=m(.55,.66,r);for(let e=0;e<d.current.length;e++){let t=d.current[e];if(t?.geo&&(M(t.geo,a),t.mat)){let r=.52+.12*Math.sin(3*n-.7*e);t.mat.opacity=l*r}}if(x.current){let e=1e-4+(1-m(.4,.55,r));x.current.scale.setScalar(e)}if(j.current){let e=m(.6,.82,r),t=e*(1+.06*Math.sin(4*n)*e);j.current.scale.setScalar(1e-4+t)}}),(0,t.jsxs)("group",{children:[s.map((e,r)=>(0,t.jsxs)("mesh",{frustumCulled:!1,children:[(0,t.jsx)("tubeGeometry",{ref:e=>{e&&(f.current[r]={...f.current[r]??{},geo:e})},args:[e.curve,120,.08,6,!1]}),(0,t.jsx)("meshBasicMaterial",{ref:e=>{e&&(f.current[r]={...f.current[r]??{},mat:e})},color:h,transparent:!0,opacity:.85,depthWrite:!1,blending:n?g.NormalBlending:g.AdditiveBlending})]},`c${r}`)),a.map((e,r)=>(0,t.jsxs)("mesh",{frustumCulled:!1,children:[(0,t.jsx)("tubeGeometry",{ref:e=>{e&&(d.current[r]={...d.current[r]??{},geo:e})},args:[e.curve,120,.1,6,!1]}),(0,t.jsx)("meshBasicMaterial",{ref:e=>{e&&(d.current[r]={...d.current[r]??{},mat:e})},color:r%2==0?c:u,transparent:!0,opacity:0,depthWrite:!1,blending:n?g.NormalBlending:g.AdditiveBlending})]},`o${r}`)),(0,t.jsx)("group",{ref:x,children:l.map((e,r)=>(0,t.jsxs)("group",{children:[(0,t.jsxs)("mesh",{position:e,children:[(0,t.jsx)("sphereGeometry",{args:[.18,12,12]}),(0,t.jsx)("meshBasicMaterial",{color:h,transparent:!0,opacity:.9,blending:g.AdditiveBlending})]}),(0,t.jsx)(R,{position:e,color:h})]},`cn-group-${r}`))}),(0,t.jsx)("group",{ref:j,scale:1e-4,children:p.map((e,r)=>(0,t.jsxs)("group",{children:[(0,t.jsxs)("mesh",{position:e,children:[(0,t.jsx)("sphereGeometry",{args:[.15,14,14]}),(0,t.jsx)("meshBasicMaterial",{color:u,transparent:!0,opacity:.95,blending:g.AdditiveBlending})]}),(0,t.jsx)(R,{position:e,color:u,maxScale:1.8,pulseSpeed:3})]},`on-group-${r}`))}),!o&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(G,{progress:e,chaoticCurves:s.map(e=>e.curve)}),(0,t.jsx)(k,{progress:e,optimizedCurves:a.map(e=>e.curve)})]})]})}),V=new g.Vector3,C=new g.Vector3,I=new g.Vector3,F=r.default.memo(function({texture:e,tint:r,width:n,aspect:i}){let o=n/i;return(0,t.jsxs)("mesh",{position:[0,o/2.4,0],children:[(0,t.jsx)("planeGeometry",{args:[n,o]}),(0,t.jsx)("meshBasicMaterial",{map:e,color:r,transparent:!0,depthWrite:!1,side:g.DoubleSide,toneMapped:!1})]})}),$=new g.Vector3(0,.5,0),W=r.default.memo(function({progress:e,reduced:n=!1}){let{chaotic:o,optimized:s}=(0,r.useMemo)(()=>w(),[]),a=["truck","van","bike"],l=(0,r.useMemo)(()=>Array.from({length:7},(e,t)=>({curve:o[t%o.length].curve,type:a[t%3],speed:.018+.03*d(5*t+1),offset:d(5*t+2),color:h,nodes:o[t%o.length].nodes||[]})),[o]),p=(0,r.useMemo)(()=>Array.from({length:5},(e,t)=>({curve:s[t%s.length].curve,type:a[t%3],speed:.05+.025*d(7*t+1),offset:d(7*t+2),color:t%2==0?c:u,nodes:s[t%s.length].nodes||[]})),[s]),f=(0,r.useRef)([]),x=(0,r.useRef)([]),j=(0,r.useRef)([]),M=(0,r.useMemo)(()=>{let e=new g.TextureLoader().load("/images/truck.png");return e.colorSpace=g.SRGBColorSpace,e.anisotropy=8,e},[]),y=1080/948,v=(0,r.useRef)([]),b=(0,r.useRef)([]),A=(e,t,r,n,i,o)=>{if(!e||!t?.curve)return;let s=o>.02;if(e.visible=s,!s)return;let a=r[n];(void 0===a||Number.isNaN(a))&&(a=r[n]=t.offset??0),t.curve.getPointAt(a,V);let l=V.distanceTo($);t.nodes&&t.nodes.length>0&&t.nodes.forEach(e=>{let t=V.distanceTo(e);t<l&&(l=t)});let c=.2+1.05*m(.4,2.5,l);a=(a+i*t.speed*c)%1,r[n]=a,t.curve.getPointAt(a,V),t.curve.getTangentAt(a,C),e.position.copy(V),e.rotation.y=Math.atan2(C.x,C.z),e.traverse(e=>{let t=e.material;t&&"opacity"in t&&(t.opacity=o*B(e))})},B=e=>{let t=e.material;return!t||t.map||t.wireframe||t.color&&0xffffff===t.color.getHex()||t.color&&0xef4444===t.color.getHex()?1:.2};return(0,i.useFrame)((t,r)=>{v.current.length!==l.length&&(v.current=l.map(e=>e.offset)),b.current.length!==p.length&&(b.current=p.map(e=>e.offset));let n=e.current??0,i=t.clock.elapsedTime,o=Math.min(.06,r),s=m(.1,.22,n)*(1-m(.7,.82,n))*(.85+.1*Math.sin(6*i)),a=m(.68,.82,n),c=t.camera;for(let e=0;e<l.length;e++){A(f.current[e],l[e],v.current,e,o,s);let t=f.current[e];t&&t.visible&&(t.rotation.y=Math.atan2(c.position.x-t.position.x,c.position.z-t.position.z))}for(let e=0;e<p.length;e++){A(x.current[e],p[e],b.current,e,o,a);let t=x.current[e];t&&t.visible&&(t.rotation.y=Math.atan2(c.position.x-t.position.x,c.position.z-t.position.z));let r=b.current[e],n=p[e]?.curve;if(!(!n||void 0===r||Number.isNaN(r)))for(let t=0;t<16;t++){let o=j.current[16*e+t];if(!o)continue;if(a<.02){o.visible=!1;continue}let s=r-(t+1)*.011;s<0&&(s=0),o.visible=!0,n.getPointAt(s,I),o.position.copy(I);let l=1-t/16,c=.05+.13*l;o.scale.setScalar(c/.1),o.material.opacity=a*l*l*(.65+.35*Math.sin(9*i-.7*t))}}}),(0,t.jsxs)("group",{children:[l.map((e,r)=>(0,t.jsx)("group",{ref:e=>{f.current[r]=e},children:(0,t.jsx)(F,{texture:M,tint:"#ff5a5a",width:1.61,aspect:y})},`cv${r}`)),p.map((e,r)=>(0,t.jsx)("group",{visible:!1,ref:e=>{x.current[r]=e},children:(0,t.jsx)(F,{texture:M,tint:"#d7dce4",width:1.75,aspect:y})},`ov${r}`)),p.map((e,r)=>Array.from({length:16},(i,o)=>(0,t.jsxs)("mesh",{visible:!1,ref:e=>{j.current[16*r+o]=e},children:[(0,t.jsx)("sphereGeometry",{args:[.1,8,8]}),(0,t.jsx)("meshBasicMaterial",{color:e.color,transparent:!0,opacity:0,depthWrite:!1,blending:n?g.NormalBlending:g.AdditiveBlending})]},`ot-${r}-${o}`)))]})}),N=r.default.memo(function({offset:e,index:n,progress:o,color:s}){let a=(0,r.useRef)(null),l=(0,r.useRef)(null),c=(0,r.useRef)([]),u=(0,r.useMemo)(()=>Array.from({length:3},(e,t)=>t/3),[]);(0,i.useFrame)(t=>{let r=o.current??0,i=t.clock.elapsedTime,s=m(.2,.4,r)*(1-m(.72,.85,r)),h=s>.01;a.current&&(a.current.visible=h),l.current&&h&&(l.current.opacity=s*(.15+.08*Math.sin(12*i+n))),c.current.forEach((t,r)=>{if(!t||(t.visible=h,!h))return;let o=.8+.4*d(5*n+r),a=(u[r]+o/3*i)%1;t.position.copy(e).multiplyScalar(a),t.material.opacity=s*Math.sin(a*Math.PI)*.8;let l=.04+.015*Math.sin(8*i+r);t.scale.setScalar(l/.06)})});let h=(0,r.useMemo)(()=>{let t=new g.BufferGeometry,r=new Float32Array([0,0,0,e.x,e.y,e.z]);return t.setAttribute("position",new g.BufferAttribute(r,3)),t},[e]);return(0,t.jsxs)("group",{children:[(0,t.jsx)("lineSegments",{ref:a,geometry:h,children:(0,t.jsx)("lineBasicMaterial",{ref:l,color:s,transparent:!0,opacity:0,depthWrite:!1,blending:g.AdditiveBlending})}),Array.from({length:3}).map((e,r)=>(0,t.jsxs)("mesh",{ref:e=>{c.current[r]=e},visible:!1,children:[(0,t.jsx)("sphereGeometry",{args:[.06,8,8]}),(0,t.jsx)("meshBasicMaterial",{color:s,transparent:!0,opacity:0,depthWrite:!1,blending:g.AdditiveBlending})]},r))]})}),Y=r.default.memo(function({progress:e}){let n=(0,r.useRef)(null),o=(0,r.useMemo)(()=>Array.from({length:5},(e,t)=>{let r=t/5*Math.PI*2+.3,n=7+3*d(7*t+1),i=Math.cos(r)*n,o=Math.sin(r)*n;return new g.Vector3(i,-3.3,o)}),[]);return(0,i.useFrame)(e=>{let t=e.clock.elapsedTime;n.current&&(n.current.position.y=3.4+.12*Math.sin(.8*t))}),(0,t.jsxs)("group",{ref:n,position:[0,3.4,0],children:[(0,t.jsxs)("mesh",{children:[(0,t.jsx)("sphereGeometry",{args:[.06,12,12]}),(0,t.jsx)("meshBasicMaterial",{color:u,blending:g.AdditiveBlending})]}),o.map((r,n)=>(0,t.jsx)(N,{offset:r,index:n,progress:e,color:n%2==0?c:u},`calc-beam-${n}`))]})}),D={radiusStart:17,radiusEnd:13,heightStart:9,heightEnd:6.5,lookAtY:2.4,fov:50},H={radiusStart:19,radiusEnd:15,heightStart:9.5,heightEnd:7,lookAtY:2.6,fov:54},K={radiusStart:16,radiusEnd:12,heightStart:8.5,heightEnd:6,lookAtY:2.3,fov:58};function U({progress:e,framing:t}){let n=(0,r.useRef)(0),s=(0,o.useThree)(e=>e.camera);return(0,r.useEffect)(()=>{"fov"in s&&(s.fov=t.fov,s.updateProjectionMatrix())},[s,t.fov]),(0,i.useFrame)((r,i)=>{let o=e.current??0;n.current=f(n.current,o,1.5,i);let s=n.current,a=r.clock.elapsedTime,l=p(t.radiusStart,t.radiusEnd,s),c=p(-.5,.45,s)+.02*a,u=p(t.heightStart,t.heightEnd,s)+.3*Math.sin(.4*a),h=r.camera;h.position.x=Math.sin(c)*l,h.position.z=Math.cos(c)*l,h.position.y=u,h.lookAt(0,t.lookAtY,0)}),null}let L=r.default.memo(function({progress:e,reduced:r=!1,isMobile:i=!1,isTablet:o=!1,active:c=!0}){let u=i?K:o?H:D;return(0,t.jsxs)(n.Canvas,{flat:!0,dpr:[1,i||r?1.25:1.5],camera:{position:[0,u.heightStart,u.radiusStart],fov:u.fov,near:.1,far:120},gl:{antialias:!i,powerPreference:"high-performance",alpha:!1},frameloop:c?"always":"never",children:[(0,t.jsx)("color",{attach:"background",args:[l]}),(0,t.jsx)("fog",{attach:"fog",args:[l,18,52]}),(0,t.jsx)("ambientLight",{intensity:.6}),(0,t.jsx)(U,{progress:e,framing:u}),(0,t.jsx)(v,{progress:e,count:i?48:90,reduced:r}),(0,t.jsx)(z,{progress:e,reduced:r,isMobile:i}),(0,t.jsx)(W,{progress:e,reduced:r}),(0,t.jsx)(Y,{progress:e,reduced:r}),!r&&(0,t.jsx)(s.EffectComposer,{multisampling:2*!i,children:(0,t.jsx)(s.Bloom,{mipmapBlur:!0,intensity:i?.5:1,luminanceThreshold:.15,luminanceSmoothing:.04,radius:i?.55:.75,kernelSize:a.KernelSize.MEDIUM})})]})});e.s(["default",0,L],64083)},29539,e=>{e.n(e.i(64083))}]);