PageSourceSearch

https://countrystatecity.in/_next/static/chunks/78b832e235c8455e.js

js countrystatecity.in collected 2026-09-25 19:47:50 UTC 162,479 bytes, 27 lines download raw bytes

1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,88310,e=>{"use strict";var t=e.i(43476),i=e.i(71645),n=e.i(80064),s=e.i(18366),r=e.i(78784),a=e.i(68054),o=e.i(72520),l=e.i(22016),u=e.i(56728),h=e.i(59669);let d="ui-monospace, SFMono-Regular, Menlo, Consolas, 'Liberation Mono', monospace",c={curl:{title:"cURL",icon:a.Terminal,code:`curl https://api.countrystatecity.in/v1/countries/IN/states \\
2  -H "X-CSCAPI-KEY: YOUR_API_KEY"`},javascript:{title:"JavaScript",icon:h.default,code:`const res = await fetch(
3  "https://api.countrystatecity.in/v1/countries/IN/states",
4  { headers: { "X-CSCAPI-KEY": "YOUR_API_KEY" } }
5);
6
7const states = await res.json();`},python:{title:"Python",icon:u.default,code:`import requests
8
9res = requests.get(
10    "https://api.countrystatecity.in/v1/countries/IN/states",
11    headers={"X-CSCAPI-KEY": "YOUR_API_KEY"},
12)
13states = res.json()`}},p=`[
14  { "id": 4008, "name": "Maharashtra", "iso2": "MH" },
15  { "id": 4026, "name": "Karnataka",   "iso2": "KA" },
16  { "id": 4035, "name": "Tamil Nadu",  "iso2": "TN" },
17  { "id": 4021, "name": "Delhi",       "iso2": "DL" },
18  { "id": 4030, "name": "Gujarat",     "iso2": "GJ" }
19]`;function m(){let[e,s]=(0,i.useState)("curl"),r=(0,i.useMemo)(()=>
19c[e].code,[e]);return(0,t.jsx)("section",{className:"relative overflow-hidden bg-gradient-to-br from-white via-blue/[0.02] to-green/[0.03] py-10 lg:py-20",children:(0,t.jsxs)("div",{className:"container mx-auto px-4",children:[(0,t.jsxs)("div",{className:"text-center max-w-2xl mx-auto",children:[(0,t.jsxs)("div",{className:"inline-flex items-center gap-2 rounded-full bg-white/90 px-3 py-1 ring-1 ring-light shadow-sm",children:[(0,t.jsx)("span",{className:"h-1.5 w-1.5 rounded-full bg-green","aria-hidden":"true"}),(0,t.jsx)("span",{className:"text-[11px] font-semibold tracking-wider uppercase text-darkgray",children:"Quick start"})]}),(0,t.jsxs)("h2",{className:"mt-4 text-3xl md:text-4xl lg:text-5xl font-bold text-dark",children:["See the API"," ",(0,t.jsx)("span",{className:"bg-gradient-to-r from-blue to-green bg-clip-text text-transparent",children:"in action"})]}),(0,t.jsx)("p",{className:"mt-3 text-lg text-darkgray",children:"One authenticated request returns clean, structured JSON — countries, states, and cities, ready for your app."})]}),(0,t.jsxs)("div",{className:"mt-10 grid grid-cols-1 lg:grid-cols-2 gap-6 items-stretch max-w-5xl mx-auto",children:[(0,t.jsxs)("div",{className:"rounded-2xl bg-white/70 backdrop-blur-sm border border-light/60 shadow-[0_1px_0_rgba(15,23,42,0.04),0_8px_24px_rgba(2,6,23,0.06)] overflow-hidden flex flex-col",children:[(0,t.jsx)("div",{role:"tablist","aria-label":"Request examples",className:"flex flex-wrap items-center gap-2 border-b border-light/60 bg-white/80 p-2",children:Object.keys(c).map(i=>{let r=e===i,a=c[i].icon;return(0,t.jsxs)("button",{role:"tab","aria-selected":r,"aria-controls":"request-panel",id:`tab-${i}`,onClick:()=>s(i),className:(0,n.cn)("inline-flex items-center gap-2 rounded-full px-3 py-1.5 text-sm font-semibold transition-colors focus:outline-none focus-visible:ring-2 focus-visible:ring-blue",r?"bg-blue/10 text-blue ring-1 ring-blue":"text-darkgray hover:bg-white"),children:[(0,t.jsx)(a,{className:(0,n.cn)("h-4 w-4",r?"text-blue":"text-darkgray"),"aria-hidden":"true"}),c[i].title]},i)})}),(0,t.jsxs)("div",{id:"request-panel",role:"tabpanel","aria-labelledby":`tab-${e}`,className:"relative flex-1",children:[(0,t.jsx)(f,{text:r,label:"Copy request"}),(0,t.jsx)("pre",{className:"m-0 h-full overflow-x-auto p-4 md:p-6 text-sm leading-6 text-white bg-dark",style:{fontFamily:d},children:(0,t.jsx)("code",{children:r})})]})]}),(0,t.jsxs)("div",{className:"rounded-2xl bg-white/70 backdrop-blur-sm border border-light/60 shadow-[0_1px_0_rgba(15,23,42,0.04),0_8px_24px_rgba(2,6,23,0.06)] overflow-hidden flex flex-col",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between gap-2 border-b border-light/60 bg-white/80 p-2 pl-4",children:[(0,t.jsx)("span",{className:"text-xs text-darkgray truncate",style:{fontFamily:d},children:"GET /v1/countries/IN/states"}),(0,t.jsxs)("span",{className:"inline-flex items-center gap-1.5 rounded-full bg-green/10 px-2.5 py-1 text-xs font-semibold text-green",children:[(0,t.jsx)("span",{className:"h-1.5 w-1.5 rounded-full bg-green","aria-hidden":"true"}),"200 OK"]})]}),(0,t.jsxs)("div",{className:"relative flex-1",children:[(0,t.jsx)(f,{text:p,label:"Copy response"}),(0,t.jsx)("pre",{className:"m-0 h-full overflow-x-auto p-4 md:p-6 text-sm leading-6 text-white bg-dark",style:{fontFamily:d},children:(0,t.jsx)("code",{children:p})})]})]})]}),(0,t.jsx)("div",{className:"mt-8 flex flex-col sm:flex-row items-center justify-center gap-3",children:(0,t.jsxs)(l.default,{href:"https://docs.countrystatecity.in/",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 font-semibold text-blue hover:text-blue/80 transition-colors group",children:["Read the full docs",(0,t.jsx)(o.ArrowRight,{className:"w-4 h-4 group-hover:translate-x-0.5 transition-transform","aria-hidden":"true"})]})})]})})}function f({text:e,label:a="Copy"}){let[o,l]=(0,i.useState)(!1);async function u(){try{await navigator.clipboard.writeText(e),l(!0),setTimeout(()=>l(!1),1400)}catch{}}return(0,t.jsx)("div",{className:"absolute right-3 top-3 z-10",children:(0,t.jsxs)("button",{onClick:u,className:(0,n.cn)("inline-flex items-center gap-2 rounded-md border px-2.5 py-1.5 text-xs font-semibold shadow-sm transition-colors","border-light/60 bg-white/90 text-dark hover:bg-white",o?"ring-2 ring-green":"focus:outline-none focus:ring-2 focus:ring-blue"),"aria-live":"polite","aria-label":o?"Copied":a,children:[o?(0,t.jsx)(r.CheckIcon,{className:"h-4 w-4 text-green","aria-hidden":"true"}):(0,t.jsx)(s.CopyIcon,{className:"h-4 w-4 text-blue","aria-hidden":"true"}),(0,t.jsx)("span",{className:o?"text-green":"text-blue",children:o?"Copied":"Copy"})]})})}e.s(["default",()=>m])},20267,e=>{"use strict";var t=e.i(43476),i=e.i(71645),n=e.i(48787),s=e.i(84320),r=e.i(49973);let a="csc_total_requests";function o({className:e=""}){let{totalRequests:o,loading:l}=(0,r.usePlatformStats)(),[u,h]=function(){let e=(0,i.useRef)(null),[t,n]=(0,i.useState)(!1);return(0,i.useEffect)(()=>{let t=e.current;if(!t)return;let i=new IntersectionObserver(([e])=>{e.isIntersecting&&(n(!0),i.disconnect())},{threshold:.3});return i.observe(t),()=>i.disconnect()},[]),[e,t]}(),[{number:d}
19,c]=(0,s.useSpring)(()=>({number:o.value,immediate:!0}));return(0,i.useEffect)(()=>{let e=function(){try{let e=localStorage.getItem(a);return e?JSON.parse(e):null}catch{return null}}()?.value;null!=e&&c.set({number:e})},[c]),(0,i.useEffect)(()=>{h&&c.start({to:{number:o.value},delay:200,config:{mass:1,tension:20,friction:10}})},[c,h,o.value]),(0,i.useEffect)(()=>{l||function(e){try{localStorage.setItem(a,JSON.stringify(e))}catch{}}(o)},[l,o]),(0,t.jsx)("span",{ref:u,className:e,children:(0,t.jsx)(n.animated.span,{children:d.to(e=>`${e.toFixed(o.decimals)}${o.suffix}`)})})}e.s(["default",()=>o])},19614,e=>{"use strict";var t=e.i(43476),i=e.i(22016),n=e.i(10980),s=e.i(94983),r=e.i(90597),a=e.i(20267),o=e.i(48013),l=e.i(56679);function u(){let{contributorCount:e,loading:u}=(0,o.useGithubContributors)(),h=e?`${e}+`:"50+";return(0,t.jsx)("section",{className:"relative container mx-auto px-4 py-6 lg:py-12 !pt-0",children:(0,t.jsxs)("div",{className:"max-w-4xl mx-auto",children:[(0,t.jsxs)("div",{className:"text-center mb-6 md:mb-12",children:[(0,t.jsx)("h2",{className:"text-3xl md:text-4xl font-bold text-dark mb-4 tracking-tight",children:"Community & Support"}),(0,t.jsx)("p",{className:"text-lg text-darkgray",children:"Join our community of developers and get the help you need"})]}),(0,t.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-8 mb-6 md:mb-12",children:[(0,t.jsxs)(i.default,{href:"https://github.com",className:"group p-6 rounded-2xl bg-white/60 backdrop-blur-sm border border-light/50 hover:border-light transition-all duration-300 hover:shadow-lg",target:"_blank",rel:"noopener noreferrer",children:[(0,t.jsxs)("div",{className:"flex items-center gap-4 mb-4",children:[(0,t.jsx)("div",{className:"w-12 h-12 bg-dark/10 rounded-xl flex items-center justify-center group-hover:bg-dark/20 transition-colors duration-300",children:(0,t.jsx)(l.default,{className:"w-6 h-6 text-dark"})}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"text-xl font-semibold text-dark",children:"Open Source"}),(0,t.jsx)("p",{className:"text-sm text-darkgray",children:"Contribute to our GitHub repo"})]})]}),(0,t.jsx)("p",{className:"text-darkgray",children:"Explore our codebase, report issues, and contribute to making location data more accessible for everyone."})]}),(0,t.jsxs)(i.default,{href:"https://docs.countrystatecity.in/support",className:"group p-6 rounded-2xl bg-white/60 backdrop-blur-sm border border-light/50 hover:border-light transition-all duration-300 hover:shadow-lg",children:[(0,t.jsxs)("div",{className:"flex items-center gap-4 mb-4",children:[(0,t.jsx)("div",{className:"w-12 h-12 bg-blue/10 rounded-xl flex items-center justify-center group-hover:bg-blue/20 transition-colors duration-300",children:(0,t.jsx)(n.BookOpen,{className:"w-6 h-6 text-blue"})}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"text-xl font-semibold text-dark",children:"Support Docs"}),(0,t.jsx)("p",{className:"text-sm text-darkgray",children:"Get help when you need it"})]})]}),(0,t.jsx)("p",{className:"text-darkgray",children:"Comprehensive guides, API references, and troubleshooting tips to help you integrate quickly."})]})]}),(0,t.jsxs)("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-6",children:[(0,t.jsxs)("div",{className:"text-center",children:[(0,t.jsxs)("div",{className:"flex items-center justify-center gap-2 mb-2",children:[(0,t.jsx)(s.MessageCircle,{className:"w-5 h-5 text-success"}),(0,t.jsx)(a.default,{className:"text-2xl font-bold text-dark"})]}),(0,t.jsx)("p",{className:"text-sm text-darkgray",children:"Total API Requests"})]}),(0,t.jsxs)("div",{className:"text-center",children:[(0,t.jsxs)("div",{className:"flex items-center justify-center gap-2 mb-2",children:[(0,t.jsx)(l.default,{className:"w-5 h-5 text-dark"}),(0,t.jsx)("span",{className:"text-2xl font-bold text-dark",children:h})]}),(0,t.jsx)("p",{className:"text-sm text-darkgray",children:"Open source contributions"})]}),(0,t.jsxs)("div",{className:"text-center",children:[(0,t.jsxs)("div",{className:"flex items-center justify-center gap-2 mb-2",children:[(0,t.jsx)(r.Heart,{className:"w-5 h-5 text-danger"}),(0,t.jsx)("span",{className:"text-2xl font-bold text-dark",children:"99%"})]}),(0,t.jsx)("p",{className:"text-sm text-darkgray",children:"Developer satisfaction"})]})]})]})})}e.s(["default",()=>u])},67585,(e,t,i)=>{"use strict";Object.defineProperty(i,"__esModule",{value:!0}),Object.defineProperty(i,"BailoutToCSR",{enumerable:!0,get:function(){return s}});let n=e.r(32061);function s({reason:e,children:t}){if("undefined"==typeof window)throw Object.defineProperty(new n.BailoutToCSRError(e),"__NEXT_ERROR_CODE",{value:"E394",enumerable:!1,
19configurable:!0});return t}},9885,(e,t,i)=>{"use strict";function n(e){return e.split("/").map(e=>encodeURIComponent(e)).join("/")}Object.defineProperty(i,"__esModule",{value:!0}),Object.defineProperty(i,"encodeURIPath",{enumerable:!0,get:function(){return n}})},52157,(e,t,i)=>{"use strict";Object.defineProperty(i,"__esModule",{value:!0}),Object.defineProperty(i,"PreloadChunks",{enumerable:!0,get:function(){return l}});let n=e.r(43476),s=e.r(74080),r=e.r(63599),a=e.r(9885),o=e.r(43369);function l({moduleIds:e}){if("undefined"!=typeof window)return null;let t=r.workAsyncStorage.getStore();if(void 0===t)return null;let i=[];if(t.reactLoadableManifest&&e){let n=t.reactLoadableManifest;for(let t of e){if(!n[t])continue;let e=n[t].files;i.push(...e)}}if(0===i.length)return null;let l=(0,o.getDeploymentIdQueryOrEmptyString)();return(0,n.jsx)(n.Fragment,{children:i.map(e=>{let i=`${t.assetPrefix}/_next/${(0,a.encodeURIPath)(e)}${l}`;return e.endsWith(".css")?(0,n.jsx)("link",{precedence:"dynamic",href:i,rel:"stylesheet",as:"style",nonce:t.nonce},e):((0,s.preload)(i,{as:"script",fetchPriority:"low",nonce:t.nonce}),null)})})}},69093,(e,t,i)=>{"use strict";Object.defineProperty(i,"__esModule",{value:!0}),Object.defineProperty(i,"default",{enumerable:!0,get:function(){return u}});let n=e.r(43476),s=e.r(71645),r=e.r(67585),a=e.r(52157);function o(e){return{default:e&&"default"in e?e.default:e}}let l={loader:()=>Promise.resolve(o(()=>null)),loading:null,ssr:!0},u=function(e){let t={...l,...e},i=(0,s.lazy)(()=>t.loader().then(o)),u=t.loading;function h(e){let o=u?(0,n.jsx)(u,{isLoading:!0,pastDelay:!0,error:null}):null,l=!t.ssr||!!t.loading,h=l?s.Suspense:s.Fragment,d=t.ssr?(0,n.jsxs)(n.Fragment,{children:["undefined"==typeof window?(0,n.jsx)(a.PreloadChunks,{moduleIds:t.modules}):null,(0,n.jsx)(i,{...e})]}):(0,n.jsx)(r.BailoutToCSR,{reason:"next/dynamic",children:(0,n.jsx)(i,{...e})});return(0,n.jsx)(h,{...l?{fallback:o}:{},children:d})}return h.displayName="LoadableComponent",h}},70703,(e,t,i)=>{"use strict";Object.defineProperty(i,"__esModule",{value:!0}),Object.defineProperty(i,"default",{enumerable:!0,get:function(){return s}});let n=e.r(55682)._(e.r(69093));function s(e,t){let i={};"function"==typeof e&&(i.loader=e);let s={...i,...t};return(0,n.default)({...s,modules:s.loadableGenerated?.modules})}("function"==typeof i.default||"object"==typeof i.default&&null!==i.default)&&void 0===i.default.__esModule&&(Object.defineProperty(i.default,"__esModule",{value:!0}),Object.assign(i.default,i),t.exports=i.default)},87154,e=>{"use strict";let t,i;var n,s=e.i(43476),r=e.i(56902),a=e.i(10980),o=e.i(3116),l=e.i(9912),u=e.i(98919),h=e.i(70273);e.i(57688),e.i(22016);var d=e.i(71645);let c=(0,e.i(70703).default)(()=>e.A(65119).then(e=>e.CobeGlobe),{loadableGenerated:{modules:[97842]},ssr:!1,loading:()=>(0,s.jsx)("div",{className:"w-full aspect-square bg-gradient-to-b from-blue-950/20 to-transparent rounded-full"})});function p(){return(0,s.jsx)("div",{className:"flex flex-row items-center justify-center relative w-full","aria-hidden":"true",children:(0,s.jsx)("div",{className:"w-full relative overflow-hidden aspect-square",children:(0,s.jsx)(c,{markers:[{location:[37.7595,-122.4367],size:.03},{location:[40.7128,-74.006],size:.05},{location:[51.5072,-.1276],size:.05},{location:[48.8566,2.3522],size:.03},{location:[35.6762,139.6503],size:.05},{location:[22.3193,114.1694],size:.04},{location:[1.3521,103.8198],size:.04},{location:[-33.8688,151.2093],size:.04},{location:[28.6139,77.209],size:.04},{location:[55.7558,37.6173],size:.04},{location:[-23.5505,-46.6333],size:.04},{location:[52.52,13.405],size:.03},{location:[31.2304,121.4737],size:.04},{location:[34.0522,-118.2437],size:.03},{location:[41.9028,12.4964],size:.03}]})})})}var m=e.i(25913),f=e.i(97140),f=f;let g=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],v=new Set(g),y=e=>180*e/Math.PI,x=e=>w(y(Math.atan2(e[1],e[0]))),b={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>
19(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:x,rotateZ:x,skewX:e=>y(Math.atan(e[1])),skewY:e=>y(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},w=e=>((e%=360)<0&&(e+=360),e),j=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),T=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),S={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:j,scaleY:T,scale:e=>(j(e)+T(e))/2,rotateX:e=>w(y(Math.atan2(e[6],e[5]))),rotateY:e=>w(y(Math.atan2(-e[2],e[0]))),rotateZ:x,rotate:x,skewX:e=>y(Math.atan(e[4])),skewY:e=>y(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function P(e){return+!!e.includes("scale")}function k(e,t){let i,n;if(!e||"none"===e)return P(t);let s=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);if(s)i=S,n=s;else{let t=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);i=b,n=t}if(!n)return P(t);let r=i[t],a=n[1].split(",").map(A);return"function"==typeof r?r(a):a[r]}function A(e){return parseFloat(e.trim())}let C=e=>t=>"string"==typeof t&&t.startsWith(e),E=C("--"),M=C("var(--"),N=e=>!!M(e)&&V.test(e.split("/*")[0].trim()),V=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function R({top:e,left:t,right:i,bottom:n}){return{x:{min:t,max:i},y:{min:e,max:n}}}let D=(e,t,i)=>e+(t-e)*i;function L(e){return void 0===e||1===e}function I({scale:e,scaleX:t,scaleY:i}){return!L(e)||!L(t)||!L(i)}function O(e){return I(e)||F(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function F(e){var t,i;return(t=e.x)&&"0%"!==t||(i=e.y)&&"0%"!==i}function B(e,t,i,n,s){return void 0!==s&&(e=n+s*(e-n)),n+i*(e-n)+t}function $(e,t=0,i=1,n,s){e.min=B(e.min,t,i,n,s),e.max=B(e.max,t,i,n,s)}function _(e,{x:t,y:i}){$(e.x,t.translate,t.scale,t.originPoint),$(e.y,i.translate,i.scale,i.originPoint)}function U(e,t){e.min=e.min+t,e.max=e.max+t}function z(e,t,i,n,s=.5){let r=D(e.min,e.max,s);$(e,t,i,r,n)}function W(e,t){z(e.x,t.x,t.scaleX,t.scale,t.originX),z(e.y,t.y,t.scaleY,t.scale,t.originY)}function H(e,t){return R(function(e,t){if(!t)return e;let i=t({x:e.left,y:e.top}),n=t({x:e.right,y:e.bottom});return{top:i.y,left:i.x,bottom:n.y,right:n.x}}(e.getBoundingClientRect(),t))}let X=new Set(["width","height","top","left","right","bottom",...g]),Y=(e,t,i)=>i>t?t:i<e?e:i,G={test:e=>"number"==typeof e,parse:parseFloat,transform:e=>e},K={...G,transform:e=>Y(0,1,e)},q={...G,default:1},Z=e=>({test:t=>"string"==typeof t&&t.endsWith(e)&&1===t.split(" ").length,parse:parseFloat,transform:t=>`${t}${e}`}),J=Z("deg"),Q=Z("%"),ee=Z("px"),et=Z("vh"),ei=Z("vw"),en={...Q,parse:e=>Q.parse(e)/100,transform:e=>Q.transform(100*e)},es=e=>t=>t.test(e),er=[G,ee,Q,J,ei,et,{test:e=>"auto"===e,parse:e=>e}],ea=e=>er.find(es(e));e.i(47167);let eo=()=>{},el=()=>{},eu=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u,eh=e=>e===G||e===ee,ed=new Set(["x","y","z"]),ec=g.filter(e=>!ed.has(e)),ep={width:({x:e},{paddingLeft:t="0",paddingRight:i="0"})=>e.max-e.min-parseFloat(t)-parseFloat(i),height:({y:e},{paddingTop:t="0",paddingBottom:i="0"})=>e.max-e.min-parseFloat(t)-parseFloat(i),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>k(t,"x"),y:(e,{transform:t})=>k(t,"y")};ep.translateX=ep.x,ep.translateY=ep.y;let em=e=>e,ef={},eg=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function ev(e,t){let i=!1,n=!0,s={delta:0,timestamp:0,isProcessing:!1},r=()=>i=!0,a=eg.reduce((e,i)=>(e[i]=function(e,t){let i=new Set,n=new Set,s=!1,r=!1,a=new WeakSet,o={delta:0,timestamp:0,isProcessing:!1},l=0;function u(t){a.has(t)&&(h.schedule(t),e()),l++,t(o)}let h={schedule:(e,t=!1,r=!1)=>{let o=r&&s?i:n;return t&&a.add(e),o.has(e)||o.add(e),e},cancel:e=>{n.delete(e),a.delete(e)},process:e=>{if(o=e,s){r=!0;return}s=!0,[i,n]=[n,i],i.forEach(u),t,l=0,i.clear(),s=!1,r&&(r=!1,h.process(e))}};return h}(r,t?i:void 0),e),{}),{setup:o,read:l,resolveKeyframes:u,preUpdate:h,update:d,preRender:c,render:p,postRender:m}=a,f=()=>{let r=ef.useManualTiming?s.timestamp:performance.now();i=!1,ef.useManualTiming||(s.delta=n?1e3/60:Math.max(Math.min(r-s.timestamp,40),1)),s.timestamp=r,s.isProcessing=!0,o.process(s),l.process(s),u.process(s),h.process(s),d.process(s),c.process(s),p.process(s),m.process(s),s.isProcessing=!1,i&&t&&(n=!1,e(f))};return{schedule:eg.reduce((t,r)=>{let o=a[r];return t[r]=(t,r=!1,a=!1)=>(!i&&(i=!0,n=!0,s.isProcessing||e(f)),o.schedule(t,r,a)),t},{}),cancel:e=>{for(let t=0;t<eg.length;t++)a[eg[t]].cancel(e)},state:s,steps:a}}let{schedule:ey,cancel:ex,state:eb,steps:ew}=ev("undefined"!=typeof requestAnimationFrame?requestAnimationFrame:em,!0),ej=new Set,eT=!1,eS=!1,eP=!1;function ek(){if(eS){let e=Array.from(ej).filter(e=>e.needsMeasurement),t=new Set(e.map(e=>e.element)),i=new Map;
19t.forEach(e=>{let t,n=(t=[],ec.forEach(i=>{let n=e.getValue(i);void 0!==n&&(t.push([i,n.get()]),n.set(+!!i.startsWith("scale")))}),t);n.length&&(i.set(e,n),e.render())}),e.forEach(e=>e.measureInitialState()),t.forEach(e=>{e.render();let t=i.get(e);t&&t.forEach(([t,i])=>{e.getValue(t)?.set(i)})}),e.forEach(e=>e.measureEndState()),e.forEach(e=>{void 0!==e.suspendedScrollY&&window.scrollTo(0,e.suspendedScrollY)})}eS=!1,eT=!1,ej.forEach(e=>e.complete(eP)),ej.clear()}function eA(){ej.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(eS=!0)})}class eC{constructor(e,t,i,n,s,r=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...e],this.onComplete=t,this.name=i,this.motionValue=n,this.element=s,this.isAsync=r}scheduleResolve(){this.state="scheduled",this.isAsync?(ej.add(this),eT||(eT=!0,ey.read(eA),ey.resolveKeyframes(ek))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:e,name:t,element:i,motionValue:n}=this;if(null===e[0]){let s=n?.get(),r=e[e.length-1];if(void 0!==s)e[0]=s;else if(i&&t){let n=i.readValue(t,r);null!=n&&(e[0]=n)}void 0===e[0]&&(e[0]=r),n&&void 0===s&&n.set(e[0])}for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(e=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,e),ej.delete(this)}cancel(){"scheduled"===this.state&&(ej.delete(this),this.state="pending")}resume(){"pending"===this.state&&this.scheduleResolve()}}let eE=e=>Math.round(1e5*e)/1e5,eM=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu,eN=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,eV=(e,t)=>i=>!!("string"==typeof i&&eN.test(i)&&i.startsWith(e)||t&&null!=i&&Object.prototype.hasOwnProperty.call(i,t)),eR=(e,t,i)=>n=>{if("string"!=typeof n)return n;let[s,r,a,o]=n.match(eM);return{[e]:parseFloat(s),[t]:parseFloat(r),[i]:parseFloat(a),alpha:void 0!==o?parseFloat(o):1}},eD={...G,transform:e=>Math.round(Y(0,255,e))},eL={test:eV("rgb","red"),parse:eR("red","green","blue"),transform:({red:e,green:t,blue:i,alpha:n=1})=>"rgba("+eD.transform(e)+", "+eD.transform(t)+", "+eD.transform(i)+", "+eE(K.transform(n))+")"},eI={test:eV("#"),parse:function(e){let t="",i="",n="",s="";return e.length>5?(t=e.substring(1,3),i=e.substring(3,5),n=e.substring(5,7),s=e.substring(7,9)):(t=e.substring(1,2),i=e.substring(2,3),n=e.substring(3,4),s=e.substring(4,5),t+=t,i+=i,n+=n,s+=s),{red:parseInt(t,16),green:parseInt(i,16),blue:parseInt(n,16),alpha:s?parseInt(s,16)/255:1}},transform:eL.transform},eO={test:eV("hsl","hue"),parse:eR("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:i,alpha:n=1})=>"hsla("+Math.round(e)+", "+Q.transform(eE(t))+", "+Q.transform(eE(i))+", "+eE(K.transform(n))+")"},eF={test:e=>eL.test(e)||eI.test(e)||eO.test(e),parse:e=>eL.test(e)?eL.parse(e):eO.test(e)?eO.parse(e):eI.parse(e),transform:e=>"string"==typeof e?e:e.hasOwnProperty("red")?eL.transform(e):eO.transform(e),getAnimatableNone:e=>{let t=eF.parse(e);return t.alpha=0,eF.transform(t)}},eB=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu,e$="number",e_="color",eU=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function ez(e){let t=e.toString(),i=[],n={color:[],number:[],var:[]},s=[],r=0,a=t.replace(eU,e=>(eF.test(e)?(n.color.push(r),s.push(e_),i.push(eF.parse(e))):e.startsWith("var(")?(n.var.push(r),s.push("var"),i.push(e)):(n.number.push(r),s.push(e$),i.push(parseFloat(e))),++r,"${}")).split("${}");return{values:i,split:a,indexes:n,types:s}}function eW(e){return ez(e).values}function eH(e){let{split:t,types:i}=ez(e),n=t.length;return e=>{let s="";for(let r=0;r<n;r++)if(s+=t[r],void 0!==e[r]){let t=i[r];t===e$?s+=eE(e[r]):t===e_?s+=eF.transform(e[r]):s+=e[r]}return s}}let eX=e=>"number"==typeof e?0:eF.test(e)?eF.getAnimatableNone(e):e,eY={test:function(e){return isNaN(e)&&"string"==typeof e&&(e.match(eM)?.length||0)+(e.match(eB)?.length||0)>0},parse:eW,createTransformer:eH,getAnimatableNone:function(e){let t=eW(e);return eH(e)(t.map(eX))}},eG=new Set(["brightness","contrast","saturate","opacity"]);function eK(e){let[t,i]=e.slice(0,-1).split("(");if("drop-shadow"===t)return e;let[n]=i.match(eM)||[];if(!n)return e;let s=i.replace(n,""),r=+!!eG.has(t);return n!==i&&(r*=100),t+"("+r+s+")"}let eq=/\b([a-z-]*)\(.*?\)/gu,eZ={...eY,getAnimatableNone:e=>{let t=e.match(eq);return t?t.map(eK).join(" "):e}},eJ={...G,transform:Math.round},eQ={borderWidth:ee,borderTopWidth:ee,borderRightWidth:ee,borderBottomWidth:ee,borderLeftWidth:ee,borderRadius:ee,radius:ee,borderTopLeftRadius:ee,borderTopRightRadius:ee,borderBottomRightRadius:ee,borderBottomLeftRadius:ee,width:ee,maxWidth:ee,height:ee,maxHeight:ee,top:ee,right:ee,bottom:ee,left:ee,padding:ee,paddingTop:ee,paddingRight:ee,paddingBottom:ee,paddingLeft:ee,margin:ee,marginTop:ee,marginRight:ee,marginBottom:ee,marginLeft:ee,backgroundPositionX:ee,backgroundPositionY:ee,rotate:J,rotateX:J,rotateY:J,rotateZ:J,scale:q,scaleX:q,scaleY:q,scaleZ:q,skew:J,skewX:J,skewY:J,distance:ee,translateX:ee,translateY:ee,translateZ:ee,x:ee,y:ee,z:ee,perspective:ee,transformPerspective:ee,opacity:K,originX:en,originY:en,originZ:ee,zIndex:eJ,fillOpacity:K,strokeOpacity:K,numOctaves:eJ},e0={...eQ,color:eF,backgroundColor:eF,outlineColor:eF,fill:eF,stroke:eF,borderColor:eF,borderTopColor:eF,borderRightColor:eF,borderBottomColor:eF,borderLeftColor:eF,filter:eZ,WebkitFilter:eZ},e1=e=>e0[e];function e2(e,t){let i=e1(e);return i!==eZ&&(i=eY),i.getAnimatableNone?i.getAnimatableNone(t):void 0}
19let e3=new Set(["auto","none","0"]);class e5 extends eC{constructor(e,t,i,n,s){super(e,t,i,n,s,!0)}readKeyframes(){let{unresolvedKeyframes:e,element:t,name:i}=this;if(!t||!t.current)return;super.readKeyframes();for(let i=0;i<e.length;i++){let n=e[i];if("string"==typeof n&&N(n=n.trim())){let s=function e(t,i,n=1){el(n<=4,`Max CSS variable fallback depth detected in property "${t}". This may indicate a circular fallback dependency.`,"max-css-var-depth");let[s,r]=function(e){let t=eu.exec(e);if(!t)return[,];let[,i,n,s]=t;return[`--${i??n}`,s]}(t);if(!s)return;let a=window.getComputedStyle(i).getPropertyValue(s);if(a){let e=a.trim();return/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e)?parseFloat(e):e}return N(r)?e(r,i,n+1):r}(n,t.current);void 0!==s&&(e[i]=s),i===e.length-1&&(this.finalKeyframe=n)}}if(this.resolveNoneKeyframes(),!X.has(i)||2!==e.length)return;let[n,s]=e,r=ea(n),a=ea(s);if(r!==a)if(eh(r)&&eh(a))for(let t=0;t<e.length;t++){let i=e[t];"string"==typeof i&&(e[t]=parseFloat(i))}else ep[i]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){let{unresolvedKeyframes:e,name:t}=this,i=[];for(let t=0;t<e.length;t++)(null===e[t]||function(e){if("number"==typeof e)return 0===e;if(null===e)return!0;return"none"===e||"0"===e||/^0[^.\s]+$/u.test(e)}(e[t]))&&i.push(t);i.length&&function(e,t,i){let n,s=0;for(;s<e.length&&!n;){let t=e[s];"string"==typeof t&&!e3.has(t)&&ez(t).values.length&&(n=e[s]),s++}if(n&&i)for(let s of t)e[s]=e2(i,n)}(e,i,t)}measureInitialState(){let{element:e,unresolvedKeyframes:t,name:i}=this;if(!e||!e.current)return;"height"===i&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=ep[i](e.measureViewportBox(),window.getComputedStyle(e.current)),t[0]=this.measuredOrigin;let n=t[t.length-1];void 0!==n&&e.getValue(i,n).jump(n,!1)}measureEndState(){let{element:e,name:t,unresolvedKeyframes:i}=this;if(!e||!e.current)return;let n=e.getValue(t);n&&n.jump(this.measuredOrigin,!1);let s=i.length-1,r=i[s];i[s]=ep[t](e.measureViewportBox(),window.getComputedStyle(e.current)),null!==r&&void 0===this.finalKeyframe&&(this.finalKeyframe=r),this.removedTransforms?.length&&this.removedTransforms.forEac
19h(([t,i])=>{e.getValue(t).set(i)}),this.resolveNoneKeyframes()}}let e4=e=>!!(e&&e.getVelocity);function e6(){t=void 0}let e8={now:()=>(void 0===t&&e8.set(eb.isProcessing||ef.useManualTiming?eb.timestamp:performance.now()),t),set:e=>{t=e,queueMicrotask(e6)}};function e9(e,t){-1===e.indexOf(t)&&e.push(t)}function e7(e,t){let i=e.indexOf(t);i>-1&&e.splice(i,1)}class te{constructor(){this.subscriptions=[]}add(e){return e9(this.subscriptions,e),()=>e7(this.subscriptions,e)}notify(e,t,i){let n=this.subscriptions.length;if(n)if(1===n)this.subscriptions[0](e,t,i);else for(let s=0;s<n;s++){let n=this.subscriptions[s];n&&n(e,t,i)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}let tt={current:void 0};class ti{constructor(e,t={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=e=>{let t=e8.now();if(this.updatedAt!==t&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(e),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(let e of this.dependents)e.dirty()},this.hasAnimated=!1,this.setCurrent(e),this.owner=t.owner}setCurrent(e){this.current=e,this.updatedAt=e8.now(),null===this.canTrackVelocity&&void 0!==e&&(this.canTrackVelocity=!isNaN(parseFloat(this.current)))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return this.on("change",e)}on(e,t){this.events[e]||(this.events[e]=new te);let i=this.events[e].add(t);return"change"===e?()=>{i(),ey.read(()=>{this.events.change.getSize()||this.stop()})}:i}clearListeners(){for(let e in this.events)this.events[e].clear()}attach(e,t){this.passiveEffect=e,this.stopPassiveEffect=t}set(e){this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e)}setWithVelocity(e,t,i){this.set(t),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-i}jump(e,t=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,t&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(e){this.dependents||(this.dependents=new Set),this.dependents.add(e)}removeDependent(e){this.dependents&&this.dependents.delete(e)}get(){return tt.current&&tt.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){var e;let t=e8.now();if(!this.canTrackVelocity||void 0===this.prevFrameValue||t-this.updatedAt>30)return 0;let i=Math.min(this.updatedAt-this.prevUpdatedAt,30);return e=parseFloat(this.current)-parseFloat(this.prevFrameValue),i?1e3/i*e:0}start(e){return this.stop(),new Promise(t=>{this.hasAnimated=!0,this.animation=e(t),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function tn(e,t){return new ti(e,t)}let ts=[...er,eF,eY],{schedule:tr}=ev(queueMicrotask,!1),ta={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},to={};for(let e in ta)to[e]={isEnabled:t=>ta[e].some(e=>!!t[e])};let tl=()=>({translate:0,scale:1,origin:0,originPoint:0}),tu=()=>({x:tl(),y:tl()}),th=()=>({min:0,max:0}),td=()=>({x:th(),y:th()}),tc="undefined"!=typeof window,tp={current:null},tm={current:!1},tf=new WeakMap;function tg(e){return null!==e&&"object"==typeof e&&"function"==typeof e.start}function tv(e){return"string"==typeof e||Array.isArray(e)}let ty=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],tx=["initial",...ty];function tb(e){return tg(e.animate)||tx.some(t=>tv(e[t]))}function tw(e){return!!(tb(e)||e.variants)}function tj(e){let t=[{},{}];
19return e?.values.forEach((e,i)=>{t[0][i]=e.get(),t[1][i]=e.getVelocity()}),t}function tT(e,t,i,n){if("function"==typeof t){let[s,r]=tj(n);t=t(void 0!==i?i:e.custom,s,r)}if("string"==typeof t&&(t=e.variants&&e.variants[t]),"function"==typeof t){let[s,r]=tj(n);t=t(void 0!==i?i:e.custom,s,r)}return t}let tS=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class tP{scrapeMotionValuesFromProps(e,t,i){return{}}constructor({parent:e,props:t,presenceContext:i,reducedMotionConfig:n,blockInitialAnimation:s,visualState:r},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=eC,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{let e=e8.now();this.renderScheduledAt<e&&(this.renderScheduledAt=e,ey.render(this.render,!1,!0))};const{latestValues:o,renderState:l}=r;this.latestValues=o,this.baseTarget={...o},this.initialValues=t.initial?{...o}:{},this.renderState=l,this.parent=e,this.props=t,this.presenceContext=i,this.depth=e?e.depth+1:0,this.reducedMotionConfig=n,this.options=a,this.blockInitialAnimation=!!s,this.isControllingVariants=tb(t),this.isVariantNode=tw(t),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(e&&e.current);const{willChange:u,...h}=this.scrapeMotionValuesFromProps(t,{},this);for(const e in h){const t=h[e];void 0!==o[e]&&e4(t)&&t.set(o[e])}}mount(e){this.current=e,tf.set(e,this),this.projection&&!this.projection.instance&&this.projection.mount(e),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((e,t)=>this.bindToMotionValue(t,e)),tm.current||function(){if(tm.current=!0,tc)if(window.matchMedia){let e=window.matchMedia("(prefers-reduced-motion)"),t=()=>tp.current=e.matches;e.addEventListener("change",t),t()}else tp.current=!1}(),this.shouldReduceMotion="never"!==this.reducedMotionConfig&&("always"===this.reducedMotionConfig||tp.current),this.parent?.addChild(this),this.update(this.props,this.presenceContext)}unmount(){for(let e in this.projection&&this.projection.unmount(),ex(this.notifyUpdate),ex(this.render),this.valueSubscriptions.forEach(e=>e()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this),this.events)this.events[e].clear();for(let e in this.features){let t=this.features[e];t&&(t.unmount(),t.isMounted=!1)}this.current=null}addChild(e){this.children.add(e),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(e)}removeChild(e){this.children.delete(e),this.enteringChildren&&this.enteringChildren.delete(e)}bindToMotionValue(e,t){let i;this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)();let n=v.has(e);n&&this.onBindTransform&&this.onBindTransform();let s=t.on("change",t=>{this.latestValues[e]=t,this.props.onUpdate&&ey.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});window.MotionCheckAppearSync&&(i=window.MotionCheckAppearSync(this,e,t)),this.valueSubscriptions.set(e,()=>{s(),i&&i(),t.owner&&t.stop()})}sortNodePosition(e){return this.current&&this.sortInstanceNodePosition&&this.type===e.type?this.sortInstanceNodePosition(this.current,e.current):0}updateFeatures(){let e="animation";for(e in to){let t=to[e];if(!t)continue;let{isEnabled:i,Feature:n}=t;if(!this.features[e]&&n&&i(this.props)&&(this.features[e]=new n(this)),this.features[e]){let t=this.features[e];t.isMounted?t.update():(t.mount(),t.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):td()}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,t){this.latestValues[e]=t}update(e,t){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=t;for(let t=0;t<tS.length;t++){let i=tS[t];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);let n=e["on"+i];n&&(this.propEventSubscriptions[i]=this.on(i,n))}this.prevMotionValues=function(e,t,i){for(let n in t){let s=t[n],r=i[n];if(e4(s))e.addValue(n,s);else if(e4(r))e.addValue(n,tn(s,{owner:e}));else if(r!==s)if(e.hasValue(n)){let t=e.getValue(n);!0===t.liveStyle?t.jump(s):t.hasAnimated||t.set(s)}else{let t=e.getStaticValue(n);e.addValue(n,tn(void 0!==t?t:s,{owner:e}))}}for(let n in i)void 0===t[n]&&e.removeValue(n);return t}(this,this.scrapeMotionValuesFromProps(e,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(e){return this.props.variants?this.props.variants[e]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}
19addVariantChild(e){let t=this.getClosestVariantNode();if(t)return t.variantChildren&&t.variantChildren.add(e),()=>t.variantChildren.delete(e)}addValue(e,t){let i=this.values.get(e);t!==i&&(i&&this.removeValue(e),this.bindToMotionValue(e,t),this.values.set(e,t),this.latestValues[e]=t.get())}removeValue(e){this.values.delete(e);let t=this.valueSubscriptions.get(e);t&&(t(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,t){if(this.props.values&&this.props.values[e])return this.props.values[e];let i=this.values.get(e);return void 0===i&&void 0!==t&&(i=tn(null===t?void 0:t,{owner:this}),this.addValue(e,i)),i}readValue(e,t){let i=void 0===this.latestValues[e]&&this.current?this.getBaseTargetFromProps(this.props,e)??this.readValueFromInstance(this.current,e,this.options):this.latestValues[e];if(null!=i){let n,s;if("string"==typeof i&&(n=i,/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(n)||(s=i,/^0[^.\s]+$/u.test(s))))i=parseFloat(i);else{let n;n=i,!ts.find(es(n))&&eY.test(t)&&(i=e2(e,t))}this.setBaseTarget(e,e4(i)?i.get():i)}return e4(i)?i.get():i}setBaseTarget(e,t){this.baseTarget[e]=t}getBaseTarget(e){let t,{initial:i}=this.props;if("string"==typeof i||"object"==typeof i){let n=tT(this.props,i,this.presenceContext?.custom);n&&(t=n[e])}if(i&&void 0!==t)return t;let n=this.getBaseTargetFromProps(this.props,e);return void 0===n||e4(n)?void 0!==this.initialValues[e]&&void 0===t?void 0:this.baseTarget[e]:n}on(e,t){return this.events[e]||(this.events[e]=new te),this.events[e].add(t)}notify(e,...t){this.events[e]&&this.events[e].notify(...t)}scheduleRenderMicrotask(){tr.render(this.render)}}class tk extends tP{constructor(){super(...arguments),this.KeyframeResolver=e5}sortInstanceNodePosition(e,t){return 2&e.compareDocumentPosition(t)?1:-1}getBaseTargetFromProps(e,t){return e.style?e.style[t]:void 0}removeValueFromRenderState(e,{vars:t,style:i}){delete t[e],delete i[e]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:e}=this.props;e4(e)&&(this.childSubscription=e.on("change",e=>{this.current&&(this.current.textContent=`${e}`)}))}}let tA=(e,t)=>t&&"number"==typeof e?t.transform(e):e,tC={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},tE=g.length;function tM(e,t,i){let{style:n,vars:s,transformOrigin:r}=e,a=!1,o=!1;for(let e in t){let i=t[e];if(v.has(e)){a=!0;continue}if(E(e)){s[e]=i;continue}{let t=tA(i,eQ[e]);e.startsWith("origin")?(o=!0,r[e]=t):n[e]=t}}if(!t.transform&&(a||i?n.transform=function(e,t,i){let n="",s=!0;for(let r=0;r<tE;r++){let a=g[r],o=e[a];if(void 0===o)continue;let l=!0;if(!(l="number"==typeof o?o===+!!a.startsWith("scale"):0===parseFloat(o))||i){let e=tA(o,eQ[a]);if(!l){s=!1;let t=tC[a]||a;n+=`${t}(${e}) `}i&&(t[a]=e)}}return n=n.trim(),i?n=i(t,s?"":n):s&&(n="none"),n}(t,e.transform,i):n.transform&&(n.transform="none")),o){let{originX:e="50%",originY:t="50%",originZ:i=0}=r;n.transformOrigin=`${e} ${t} ${i}`}}function tN(e,{style:t,vars:i},n,s){let r,a=e.style;for(r in t)a[r]=t[r];for(r in s?.applyProjectionStyles(a,n),i)a.setProperty(r,i[r])}function tV(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}let tR={correct:(e,t)=>{if(!t.target)return e;if("string"==typeof e)if(!ee.test(e))return e;else e=parseFloat(e);let i=tV(e,t.target.x),n=tV(e,t.target.y);return`${i}% ${n}%`}},tD={borderRadius:{...tR,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:tR,borderTopRightRadius:tR,borderBottomLeftRadius:tR,borderBottomRightRadius:tR,boxShadow:{correct:(e,{treeScale:t,projectionDelta:i})=>{let n=eY.parse(e);if(n.length>5)return e;let s=eY.createTransformer(e),r=+("number"!=typeof n[0]),a=i.x.scale*t.x,o=i.y.scale*t.y;n[0+r]/=a,n[1+r]/=o;let l=D(a,o,.5);return"number"==typeof n[2+r]&&(n[2+r]/=l),"number"==typeof n[3+r]&&(n[3+r]/=l),s(n)}}};function tL(e,{layout:t,layoutId:i}){return v.has(e)||e.startsWith("origin")||(t||void 0!==i)&&(!!tD[e]||"opacity"===e)}function tI(e,t,i){let{style:n}=e,s={};for(let r in n)(e4(n[r])||t.style&&e4(t.style[r])||tL(r,e)||i?.getValue(r)?.liveStyle!==void 0)&&(s[r]=n[r]);return s}class tO extends tk{constructor(){super(...arguments),this.type="html",this.renderInstance=tN}readValueFromInstance(e,t){if(v.has(t))return this.projection?.isProjecting?P(t):((e,t)=>{let{transform:i="none"}=getComputedStyle(e);return k(i,t)})(e,t);{let i=window.getComputedStyle(e),n=(E(t)?i.getPropertyValue(t):i[t])||0;return"string"==typeof n?n.trim():n}}measureInstanceViewportBox(e,{transformPagePoint:t}){return H(e,t)}build(e,t,i){tM(e,t,i.transformTemplate)}scrapeMotionValuesFromProps(e,t,i){return tI(e,t,i)}}let tF=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),tB={offset:"stroke-dashoffset",array:"stroke-dasharray"},t$={offset:"strokeDashoffset",array:"strokeDasharray"};function t_(e,{attrX:t,attrY:i,attrScale:n,pathLength:s,pathSpacing:r=1,pathOffset:a=0,...o}
19,l,u,h){if(tM(e,o,u),l){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};let{attrs:d,style:c}=e;d.transform&&(c.transform=d.transform,delete d.transform),(c.transform||d.transformOrigin)&&(c.transformOrigin=d.transformOrigin??"50% 50%",delete d.transformOrigin),c.transform&&(c.transformBox=h?.transformBox??"fill-box",delete d.transformBox),void 0!==t&&(d.x=t),void 0!==i&&(d.y=i),void 0!==n&&(d.scale=n),void 0!==s&&function(e,t,i=1,n=0,s=!0){e.pathLength=1;let r=s?tB:t$;e[r.offset]=ee.transform(-n);let a=ee.transform(t),o=ee.transform(i);e[r.array]=`${a} ${o}`}(d,s,r,a,!1)}let tU=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]),tz=e=>"string"==typeof e&&"svg"===e.toLowerCase();function tW(e,t,i){let n=tI(e,t,i);for(let i in e)(e4(e[i])||e4(t[i]))&&(n[-1!==g.indexOf(i)?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i]=e[i]);return n}class tH extends tk{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=td}getBaseTargetFromProps(e,t){return e[t]}readValueFromInstance(e,t){if(v.has(t)){let e=e1(t);return e&&e.default||0}return t=tU.has(t)?t:tF(t),e.getAttribute(t)}scrapeMotionValuesFromProps(e,t,i){return tW(e,t,i)}build(e,t,i){t_(e,t,this.isSVGTag,i.transformTemplate,i.style)}renderInstance(e,t,i,n){for(let i in tN(e,t,void 0,n),t.attrs)e.setAttribute(tU.has(i)?i:tF(i),t.attrs[i])}mount(e){this.isSVGTag=tz(e.tagName),super.mount(e)}}let tX=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function tY(e){if("string"!=typeof e||e.includes("-"));else if(tX.indexOf(e)>-1||/[A-Z]/u.test(e))return!0;return!1}let tG=(0,d.createContext)({}),tK=(0,d.createContext)({strict:!1}),tq=(0,d.createContext)({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"}),tZ=(0,d.createContext)({});function tJ(e){return Array.isArray(e)?e.join(" "):e}let tQ=()=>({style:{},transform:{},transformOrigin:{},vars:{}});
19function t0(e,t,i){for(let n in t)e4(t[n])||tL(n,i)||(e[n]=t[n])}let t1=()=>({...tQ(),attrs:{}}),t2=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function t3(e){return e.startsWith("while")||e.startsWith("drag")&&"draggable"!==e||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||t2.has(e)}let t5=e=>!t3(e);try{n=(()=>{let e=Error("Cannot find module '@emotion/is-prop-valid'");throw e.code="MODULE_NOT_FOUND",e})().default,"function"==typeof n&&(t5=e=>e.startsWith("on")?!t3(e):n(e))}catch{}let t4=(0,d.createContext)(null);function t6(e){let t=(0,d.useRef)(null);return null===t.current&&(t.current=e()),t.current}function t8(e){return e4(e)?e.get():e}let t9=e=>(t,i)=>{let n=(0,d.useContext)(tZ),s=(0,d.useContext)(t4),r=()=>(function({scrapeMotionValuesFromProps:e,createRenderState:t},i,n,s){return{latestValues:function(e,t,i,n){let s={},r=n(e,{});for(let e in r)s[e]=t8(r[e]);let{initial:a,animate:o}=e,l=tb(e),u=tw(e);t&&u&&!l&&!1!==e.inherit&&(void 0===a&&(a=t.initial),void 0===o&&(o=t.animate));let h=!!i&&!1===i.initial,d=(h=h||!1===a)?o:a;if(d&&"boolean"!=typeof d&&!tg(d)){let t=Array.isArray(d)?d:[d];for(let i=0;i<t.length;i++){let n=tT(e,t[i]);if(n){let{transitionEnd:e,transition:t,...i}=n;for(let e in i){let t=i[e];if(Array.isArray(t)){let e=h?t.length-1:0;t=t[e]}null!==t&&(s[e]=t)}for(let t in e)s[t]=e[t]}}}return s}(i,n,s,e),renderState:t()}})(e,t,n,s);return i?r():t6(r)},t7=t9({scrapeMotionValuesFromProps:tI,createRenderState:tQ}),ie=t9({scrapeMotionValuesFromProps:tW,createRenderState:t1}),it=Symbol.for("motionComponentSymbol");function ii(e){return e&&"object"==typeof e&&Object.prototype.hasOwnProperty.call(e,"current")}let is="data-"+tF("framerAppearId"),ir=(0,d.createContext)({}),ia=tc?d.useLayoutEffect:d.useEffect;function io(e,{forwardMotionProps:t=!1}={},i,n){i&&function(e){for(let t in e)to[t]={...to[t],...e[t]}}(i);let r=tY(e)?ie:t7;function a(i,a){var o;let l,u={...(0,d.useContext)(tq),...i,layoutId:function({layoutId:e}){let t=(0,d.useContext)(tG).id;return t&&void 0!==e?t+"-"+e:e}(i)},{isStatic:h}=u,c=function(e){let{initial:t,animate:i}=function(e,t){if(tb(e)){let{initial:t,animate:i}=e;return{initial:!1===t||tv(t)?t:void 0,animate:tv(i)?i:void 0}}return!1!==e.inherit?t:{}}(e,(0,d.useContext)(tZ));return(0,d.useMemo)(()=>({initial:t,animate:i}),[tJ(t),tJ(i)])}(i),p=r(i,h);if(!h&&tc){(0,d.useContext)(tK).strict;let t=function(e){let{drag:t,layout:i}=to;if(!t&&!i)return{};let n={...t,...i};return{MeasureLayout:t?.isEnabled(e)||i?.isEnabled(e)?n.MeasureLayout:void 0,ProjectionNode:n.ProjectionNode}}(u);l=t.MeasureLayout,c.visualElement=function(e,t,i,n,s){let{visualElement:r}=(0,d.useContext)(tZ),a=(0,d.useContext)(tK),o=(0,d.useContext)(t4),l=(0,d.useContext)(tq).reducedMotion,u=(0,d.useRef)(null);n=n||a.renderer,!u.current&&n&&(u.current=n(e,{visualState:t,parent:r,props:i,presenceContext:o,blockInitialAnimation:!!o&&!1===o.initial,reducedMotionConfig:l}));let h=u.current,c=(0,d.useContext)(ir);h&&!h.projection&&s&&("html"===h.type||"svg"===h.type)&&function(e,t,i,n){let{layoutId:s,layout:r,drag:a,dragConstraints:o,layoutScroll:l,layoutRoot:u,layoutCrossfade:h}=t;e.projection=new i(e.latestValues,t["data-framer-portal-id"]?void 0:function e(t){if(t)return!1!==t.options.allowProjection?t.projection:e(t.parent)}(e.parent)),e.projection.setOptions({layoutId:s,layout:r,alwaysMeasureLayout:!!a||o&&ii(o),visualElement:e,animationType:"string"==typeof r?r:"both",initialPromotionConfig:n,crossfade:h,layoutScroll:l,layoutRoot:u})}(u.current,i,s,c);let p=(0,d.useRef)(!1);(0,d.useInsertionEffect)(()=>{h&&p.current&&h.update(i,o)});let m=i[is],f=(0,d.useRef)(!!m&&!window.MotionHandoffIsComplete?.(m)&&window.MotionHasOptimisedAnimation?.(m));return ia(()=>{h&&(p.current=!0,window.MotionIsMounted=!0,h.updateFeatures(),h.scheduleRenderMicrotask(),f.current&&h.animationState&&h.animationState.animateChanges())}),(0,d.useEffect)(()=>{h&&(!f.current&&h.animationState&&h.animationState.animateChanges(),f.current&&(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(m)}
19),f.current=!1),h.enteringChildren=void 0)}),h}(e,p,u,n,t.ProjectionNode)}return(0,s.jsxs)(tZ.Provider,{value:c,children:[l&&c.visualElement?(0,s.jsx)(l,{visualElement:c.visualElement,...u}):null,function(e,t,i,{latestValues:n},s,r=!1){let a=(tY(e)?function(e,t,i,n){let s=(0,d.useMemo)(()=>{let i=t1();return t_(i,t,tz(n),e.transformTemplate,e.style),{...i.attrs,style:{...i.style}}},[t]);if(e.style){let t={};t0(t,e.style,e),s.style={...t,...s.style}}return s}:function(e,t){let i,n,s={},r=(i=e.style||{},t0(n={},i,e),Object.assign(n,function({transformTemplate:e},t){return(0,d.useMemo)(()=>{let i=tQ();return tM(i,t,e),Object.assign({},i.vars,i.style)},[t])}(e,t)),n);return e.drag&&!1!==e.dragListener&&(s.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=!0===e.drag?"none":`pan-${"x"===e.drag?"y":"x"}`),void 0===e.tabIndex&&(e.onTap||e.onTapStart||e.whileTap)&&(s.tabIndex=0),s.style=r,s})(t,n,s,e),o=function(e,t,i){let n={};for(let s in e)("values"!==s||"object"!=typeof e.values)&&(t5(s)||!0===i&&t3(s)||!t&&!t3(s)||e.draggable&&s.startsWith("onDrag"))&&(n[s]=e[s]);return n}(t,"string"==typeof e,r),l=e!==d.Fragment?{...o,...a,ref:i}:{},{children:u}=t,h=(0,d.useMemo)(()=>e4(u)?u.get():u,[u]);return(0,d.createElement)(e,{...l,children:h})}(e,i,(o=c.visualElement,(0,d.useCallback)(e=>{e&&p.onMount&&p.onMount(e),o&&(e?o.mount(e):o.unmount()),a&&("function"==typeof a?a(e):ii(a)&&(a.current=e))},[o])),p,h,t)]})}a.displayName=`motion.${"string"==typeof e?e:`create(${e.displayName??e.name??""})`}`;let o=(0,d.forwardRef)(a);return o[it]=e,o}function il(e,t,i){let n=e.getProps();return tT(n,t,void 0!==i?i:n.custom,e)}function iu(e,t){return e?.[t]??e?.default??e}let ih=e=>Array.isArray(e);function id(e,t){let i=e.getValue("willChange");if(e4(i)&&i.add)return i.add(t);if(!i&&ef.WillChange){let i=new ef.WillChange("auto");e.addValue("willChange",i),i.add(t)}}function ic(e){e.duration=0,e.type="keyframes"}let ip=(e,t)=>i=>t(e(i)),im=(...e)=>e.reduce(ip),ig=e=>1e3*e,iv={layout:0,mainThread:0,waapi:0};function iy(e,t,i){return(i<0&&(i+=1),i>1&&(i-=1),i<1/6)?e+(t-e)*6*i:i<.5?t:i<2/3?e+(t-e)*(2/3-i)*6:e}function ix(e,t){return i=>i>0?t:e}let ib=(e,t,i)=>{let n=e*e,s=i*(t*t-n)+n;return s<0?0:Math.sqrt(s)},iw=[eI,eL,eO];function ij(e){let t=iw.find(t=>t.test(e));if(eo(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`,"color-not-animatable"),!t)return!1;let i=t.parse(e);return t===eO&&(i=function({hue:e,saturation:t,lightness:i,alpha:n}){e/=360,i/=100;let s=0,r=0,a=0;if(t/=100){let n=i<.5?i*(1+t):i+t-i*t,o=2*i-n;s=iy(o,n,e+1/3),r=iy(o,n,e),a=iy(o,n,e-1/3)}else s=r=a=i;return{red:Math.round(255*s),green:Math.round(255*r),blue:Math.round(255*a),alpha:n}}(i)),i}let iT=(e,t)=>{let i=ij(e),n=ij(t);if(!i||!n)return ix(e,t);let s={...i};return e=>(s.red=ib(i.red,n.red,e),s.green=ib(i.green,n.green,e),s.blue=ib(i.blue,n.blue,e),s.alpha=D(i.alpha,n.alpha,e),eL.transform(s))},iS=new Set(["none","hidden"]);function iP(e,t){return i=>D(e,t,i)}function ik(e){return"number"==typeof e?iP:"string"==typeof e?N(e)?ix:eF.test(e)?iT:iE:Array.isArray(e)?iA:"object"==typeof e?eF.test(e)?iT:iC:ix}function iA(e,t){let i=[...e],n=i.length,s=e.map((e,i)=>ik(e)(e,t[i]));return e=>{for(let t=0;t<n;t++)i[t]=s[t](e);return i}}function iC(e,t){let i={...e,...t},n={};for(let s in i)void 0!==e[s]&&void 0!==t[s]&&(n[s]=ik(e[s])(e[s],t[s]));return e=>{for(let t in n)i[t]=n[t](e);return i}}let iE=(e,t)=>{let i=eY.createTransformer(t),n=ez(e),s=ez(t);if(!(n.indexes.var.length===s.indexes.var.length&&n.indexes.color.length===s.indexes.color.length&&n.indexes.number.length>=s.indexes.number.length))return eo(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`,"complex-values-different"),ix(e,t);if(iS.has(e)&&!s.values.length||iS.has(t)&&!n.values.length)return iS.has(e)?i=>i<=0?e:t:i=>i>=1?t:e;return im(iA(function(e,t){let i=[],n={color:0,var:0,number:0};for(let s=0;s<t.values.length;s++){let r=t.types[s],a=e.indexes[r][n[r]],o=e.values[a]??0;i[s]=o,n[r]++}return i}(n,s),s.values),i)};function iM(e,t,i){return"number"==typeof e&&"number"==typeof t&&"number"==typeof i?D(e,t,i):ik(e)(e,t)}let iN=e=>{let t=({timestamp:t})=>e(t);return{start:(e=!0)=>ey.update(t,e),stop:()=>ex(t),now:()=>eb.isProcessing?eb.timestamp:e8.now()}},iV=(e,t,i=10)=>{let n="",s=Math.max(Math.round(t/i),2);for(let t=0;t<s;t++)n+=Math.round(1e4*e(t/(s-1)))/1e4+", ";return`linear(${n.substring(0,n.length-2)})`};function iR(e){let t=0,i=e.next(t);for(;!i.done&&t<2e4;)t+=50,i=e.next(t);return t>=2e4?1/0:t}function iD(e,t,i){var n,s;let r=Math.max(t-5,0);return n=i-e(r),(s=t-r)?1e3/s*n:0}let iL=.01,iI=2,iO=.005,iF=.5;function iB(e,t){return e*Math.sqrt(1-t*t)}let i$=["duration","bounce"],i_=["stiffness","damping","mass"];function iU(e,t){return t.some(t=>void 0!==e[t])}function iz(e=.3,t=.3){let i,n="object"!=typeof e?{visualDuration:e,keyframes:[0,1],bounce:t}:e,{restSpeed:s,restDelta:r}=n,a=n.keyframes[0],o=n.keyframes[n.keyframes.length-1],l={done:!1,value:a},{stiffness:u,damping:h,mass:d,duration:c,velocity:p,isResolvedFromDuration:m}=function(e){let t={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...e};if(!iU(e,i_)&&iU(e,i$))if(e.visualDuration){let i=2*Math.PI/(1.2*e.visualDuration),n=i*i,s=2*Y(.05,1,1-(e.bounce||0))*Math.sqrt(n);t={...t,mass:1,stiffness:n,damping:s}}else{let i=function({duration:e=800,bounce:t=.3,velocity:i=0,mass:n=1}){let s,r;eo(e<=ig(10),"Spring duration must be 10 seconds or less","spring-duration-limit");let a=1-t;a=Y(.05,1,a),e=Y(.01,10,e/1e3),a<1?(s=t=>{let n=t*a,s=n*e;return .001-(n-i)/iB(t,a)*Math.exp(-s)},r=t=>{let n=t*a*e,r=Math.pow(a,2)*Math.pow(t,2)*e,o=Math.exp(-n),l=iB(Math.pow(t,2),a);return(n*i+i-r)*o*(-s(t)+.001>0?-1:1)/l}):(s=t=>-.001+Math.exp(-t*e)*((t-i)*e+1),r=t=>e*e*(i-t)*Math.exp(-t*e));let o=function(e,t,i){let n=i;for(let i=1;i<12;i++)n-=e(n)/t(n);return n}(s,r,5/e);if(e=ig(e),isNaN(o))return{stiffness:100,damping:10,duration:e};{let t=Math.pow(o,2)*n;
19return{stiffness:t,damping:2*a*Math.sqrt(n*t),duration:e}}}(e);(t={...t,...i,mass:1}).isResolvedFromDuration=!0}return t}({...n,velocity:-((n.velocity||0)/1e3)}),f=p||0,g=h/(2*Math.sqrt(u*d)),v=o-a,y=Math.sqrt(u/d)/1e3,x=5>Math.abs(v);if(s||(s=x?iL:iI),r||(r=x?iO:iF),g<1){let e=iB(y,g);i=t=>o-Math.exp(-g*y*t)*((f+g*y*v)/e*Math.sin(e*t)+v*Math.cos(e*t))}else if(1===g)i=e=>o-Math.exp(-y*e)*(v+(f+y*v)*e);else{let e=y*Math.sqrt(g*g-1);i=t=>{let i=Math.exp(-g*y*t),n=Math.min(e*t,300);return o-i*((f+g*y*v)*Math.sinh(n)+e*v*Math.cosh(n))/e}}let b={calculatedDuration:m&&c||null,next:e=>{let t=i(e);if(m)l.done=e>=c;else{let n=0===e?f:0;g<1&&(n=0===e?ig(f):iD(i,e,t));let a=Math.abs(o-t)<=r;l.done=Math.abs(n)<=s&&a}return l.value=l.done?o:t,l},toString:()=>{let e=Math.min(iR(b),2e4),t=iV(t=>b.next(e*t).value,e,30);return e+"ms "+t},toTransition:()=>{}};return b}function iW({keyframes:e,velocity:t=0,power:i=.8,timeConstant:n=325,bounceDamping:s=10,bounceStiffness:r=500,modifyTarget:a,min:o,max:l,restDelta:u=.5,restSpeed:h}){let d,c,p=e[0],m={done:!1,value:p},f=i*t,g=p+f,v=void 0===a?g:a(g);v!==g&&(f=v-p);let y=e=>-f*Math.exp(-e/n),x=e=>v+y(e),b=e=>{let t=y(e),i=x(e);m.done=Math.abs(t)<=u,m.value=m.done?v:i},w=e=>{let t;if(t=m.value,void 0!==o&&t<o||void 0!==l&&t>l){var i;d=e,c=iz({keyframes:[m.value,(i=m.value,void 0===o?l:void 0===l||Math.abs(o-i)<Math.abs(l-i)?o:l)],velocity:iD(x,e,m.value),damping:s,stiffness:r,restDelta:u,restSpeed:h})}};return w(0),{calculatedDuration:null,next:e=>{let t=!1;return(c||void 0!==d||(t=!0,b(e),w(e)),void 0!==d&&e>=d)?c.next(e-d):(t||b(e),m)}}}iz.applyToOptions=e=>{let t=function(e,t=100,i){let n=i({...e,keyframes:[0,t]}),s=Math.min(iR(n),2e4);return{type:"keyframes",ease:e=>n.next(s*e).value/t,duration:s/1e3}}(e,100,iz);return e.ease=t.ease,e.duration=ig(t.duration),e.type="keyframes",e};let iH=(e,t,i)=>(((1-3*i+3*t)*e+(3*i-6*t))*e+3*t)*e;function iX(e,t,i,n){return e===t&&i===n?em:s=>0===s||1===s?s:iH(function(e,t,i,n,s){let r,a,o=0;do(r=iH(a=t+(i-t)/2,n,s)-e)>0?i=a:t=a;while(Math.abs(r)>1e-7&&++o<12)return a}(s,0,1,e,i),t,n)}let iY=iX(.42,0,1,1),iG=iX(0,0,.58,1),iK=iX(.42,0,.58,1),iq=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,iZ=e=>t=>1-e(1-t),iJ=iX(.33,1.53,.69,.99),iQ=iZ(iJ),i0=iq(iQ),i1=e=>(e*=2)<1?.5*iQ(e):.5*(2-Math.pow(2,-10*(e-1))),i2=e=>1-Math.sin(Math.acos(e)),i3=iZ(i2),i5=iq(i2),i4=e=>Array.isArray(e)&&"number"==typeof e[0],i6={linear:em,easeIn:iY,easeInOut:iK,easeOut:iG,circIn:i2,circInOut:i5,circOut:i3,backIn:iQ,backInOut:i0,backOut:iJ,anticipate:i1},i8=e=>{if(i4(e)){el(4===e.length,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");let[t,i,n,s]=e;return iX(t,i,n,s)}return"string"==typeof e?(el(void 0!==i6[e],`Invalid easing type '${e}'`,"invalid-easing-type"),i6[e]):e},i9=(e,t,i)=>{let n=t-e;return 0===n?1:(i-e)/n};function i7(e,t,{clamp:i=!0,ease:n,mixer:s}={}){let r=e.length;if(el(r===t.length,"Both input and output ranges must be the same length","range-length"),1===r)return()=>t[0];if(2===r&&t[0]===t[1])return()=>t[1];let a=e[0]===e[1];e[0]>e[r-1]&&(e=[...e].reverse(),t=[...t].reverse());let o=function(e,t,i){let n=[],s=i||ef.mix||iM,r=e.length-1;for(let i=0;i<r;i++){let r=s(e[i],e[i+1]);t&&(r=im(Array.isArray(t)?t[i]||em:t,r)),n.push(r)}return n}(t,n,s),l=o.length,u=i=>{if(a&&i<e[0])return t[0];let n=0;if(l>1)for(;n<e.length-2&&!(i<e[n+1]);n++);let s=i9(e[n],e[n+1],i);return o[n](s)};return i?t=>u(Y(e[0],e[r-1],t)):u}function ne({duration:e=300,keyframes:t,times:i,ease:n="easeInOut"}){var s;let r,a=Array.isArray(n)&&"number"!=typeof n[0]?n.map(i8):i8(n),o={done:!1,value:t[0]},l=i7((s=i&&i.length===t.length?i:(!function(e,t){let i=e[e.length-1];for(let n=1;n<=t;n++){let s=i9(0,t,n);e.push(D(i,1,s))}}(r=[0],t.length-1),r),s.map(t=>t*e)),t,{ease:Array.isArray(a)?a:t.map(()=>a||iK).splice(0,t.length-1)});return{calculatedDuration:e,next:t=>(o.value=l(t),o.done=t>=e,o)}}let nt=e=>null!==e;function ni(e,{repeat:t,repeatType:i="loop"},n,s=1){let r=e.filter(nt),a=s<0||t&&"loop"!==i&&t%2==1?0:r.length-1;return a&&void 0!==n?n:r[a]}let nn={decay:iW,inertia:iW,tween:ne,keyframes:ne,spring:iz};function ns(e){"string"==typeof e.type&&(e.type=nn[e.type])}class nr{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(e=>{this.resolve=e})}notifyFinished(){this.resolve()}then(e,t){return this.finished.then(e,t)}}let na=e=>e/100;class no extends nr{constructor(e){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{let{motionValue:e}=this.options;e&&e.updatedAt!==e8.now()&&this.tick(e8.now()),this.isStopped=!0,"idle"!==this.state&&(this.teardown(),this.options.onStop?.())},iv.mainThread++,this.options=e,this.initAnimation(),this.play(),!1===e.autoplay&&this.pause()}initAnimation(){let{options:e}=this;ns(e);let{type:t=ne,repeat:i=0,repeatDelay:n=0,repeatType:s,velocity:r=0}=e,{keyframes:a}=e,o=t||ne;o!==ne&&"number"!=typeof a[0]&&(this.mixKeyframes=im(na,iM(a[0],a[1])),a=[0,100]);let l=o({...e,keyframes:a});"mirror"===s&&(this.mirroredGenerator=o({...e,keyframes:[...a].reverse(),velocity:-r})),null===l.calculatedDuration&&(l.calculatedDuration=iR(l));let{calculatedDuration:u}=l;this.calculatedDuration=u,this.resolvedDuration=u+n,this.totalDuration=this.resolvedDuration*(i+1)-n,this.generator=l}updateTime(e){let t=Math.round(e-this.startTime)*this.playbackSpeed;null!==this.holdTime?this.currentTime=this.holdTime:this.currentTime=t}tick(e,t=!1){let{generator:i,totalDuration:n,mixKeyframes:s,mirroredGenerator:r,resolvedDuration:a,calculatedDuration:o}=this;if(null===this.startTime)return i.next(0);let{delay:l=0,keyframes:u,repeat:h,repeatType:d,repeatDelay:c,type:p,onUpdate:m,finalKeyframe:f}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-n/this.speed,this.startTime)),t?this.currentTime=e:this.updateTime(e);let g=this.currentTime-l*(this.playbackSpeed>=0?1:-1),v=this.playbackSpeed>=0?g<0:g>n;this.currentTime=Math.max(g,0),"finished"===this.state&&null===this.holdTime&&(this.currentTime=n);let y=this.currentTime,x=i;if(h){let e=Math.min(this.currentTime,n)/a,t=Math.floor(e),i=e%1;!i&&e>=1&&(i=1),1===i&&t--,(t=Math.min(t,h+1))%2&&("reverse"===d?(i=1-i,c&&(i-=c/a)):"mirror"===d&&(x=r)),y=Y(0,1,i)*a}let b=v?{done:!1,value:u[0]}:x.next(y);s&&(b.value=s(b.value));let{done:w}=b;v||null===o||(w=this.playbackSpeed>=0?this.currentTime>=n:this.currentTime<=0);let j=null===this.holdTime&&("finished"===this.state||"running"===this.state&&w);return j&&p!==iW&&(b.value=ni(u,this.options,f,this.speed)),m&&m(b.value),j&&this.finish(),b}then(e,t){return this.finished.then(e,t)}get duration(){return this.calculatedDuration/1e3}get iterationDuration(){let{delay:e=0}=this.options||{};return this.duration+e/1e3}get time(){return this.currentTime/1e3}set time(e){e=ig(e),this.currentTime=e,null===this.startTime||null!==this.holdTime||0===this.playbackSpeed?this.holdTime=e:this.driver&&(this.startTime=this.driver.now()-e/this.playbackSpeed),this.driver?.start(!1)}get speed(){return this.playbackSpeed}set speed(e){this.updateTime(e8.now());let t=this.playbackSpeed!==e;this.playbackSpeed=e,t&&(this.time=this.currentTime/1e3)}play(){if(this.isStopped)return;let{driver:e=iN,startTime:t}=this.options;this.driver||(this.driver=e(e=>this.tick(e))),this.options.onPlay?.();let i=this.driver.now();"finished"===this.state?(this.updateFinished(),this.startTime=i):null!==this.holdTime?this.startTime=i-this.holdTime:this.startTime||(this.startTime=t??i),"finished"===this.state&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(e8.now()),this.holdTime=this.currentTime}complete(){"running"!==this.state&&this.play(),this.state="finished",this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null,iv.mainThread--}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}attachTimeline(e){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),e.observe(this)}}function nl(e){let t;return()=>(void 0===t&&(t=e()),t)}let nu=nl(()=>void 0!==window.ScrollTimeline),nh={},nd=(i=nl(()=>{try{document.createElement("div").animate({opacity:0}
19,{easing:"linear(0, 1)"})}catch(e){return!1}return!0}),()=>nh.linearEasing??i()),nc=([e,t,i,n])=>`cubic-bezier(${e}, ${t}, ${i}, ${n})`,np={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:nc([0,.65,.55,1]),circOut:nc([.55,0,1,.45]),backIn:nc([.31,.01,.66,-.59]),backOut:nc([.33,1.53,.69,.99])};function nm(e){return"function"==typeof e&&"applyToOptions"in e}class nf extends nr{constructor(e){if(super(),this.finishedTime=null,this.isStopped=!1,!e)return;const{element:t,name:i,keyframes:n,pseudoElement:s,allowFlatten:r=!1,finalKeyframe:a,onComplete:o}=e;this.isPseudoElement=!!s,this.allowFlatten=r,this.options=e,el("string"!=typeof e.type,'Mini animate() doesn\'t support "type" as a string.',"mini-spring");const l=function({type:e,...t}){return nm(e)&&nd()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}(e);this.animation=function(e,t,i,{delay:n=0,duration:s=300,repeat:r=0,repeatType:a="loop",ease:o="easeOut",times:l}={},u){let h={[t]:i};l&&(h.offset=l);let d=function e(t,i){if(t)return"function"==typeof t?nd()?iV(t,i):"ease-out":i4(t)?nc(t):Array.isArray(t)?t.map(t=>e(t,i)||np.easeOut):np[t]}(o,s);Array.isArray(d)&&(h.easing=d);let c={delay:n,duration:s,easing:Array.isArray(d)?"linear":d,fill:"both",iterations:r+1,direction:"reverse"===a?"alternate":"normal"};u&&(c.pseudoElement=u);let p=e.animate(h,c);return p}(t,i,n,l,s),!1===l.autoplay&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!s){let e=ni(n,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(e):i.startsWith("--")?t.style.setProperty(i,e):t.style[i]=e,this.animation.cancel()}o?.(),this.notifyFinished()}}play(){this.isStopped||(this.animation.play(),"finished"===this.state&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch(e){}}stop(){if(this.isStopped)return;this.isStopped=!0;let{state:e}=this;"idle"!==e&&"finished"!==e&&(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){this.isPseudoElement||this.animation.commitStyles?.()}get duration(){return Number(this.animation.effect?.getComputedTiming?.().duration||0)/1e3}get iterationDuration(){let{delay:e=0}=this.options||{};return this.duration+e/1e3}get time(){return(Number(this.animation.currentTime)||0)/1e3}set time(e){this.finishedTime=null,this.animation.currentTime=ig(e)}get speed(){return this.animation.playbackRate}set speed(e){e<0&&(this.finishedTime=null),this.animation.playbackRate=e}get state(){return null!==this.finishedTime?"finished":this.animation.playState}get startTime(){return Number(this.animation.startTime)}set startTime(e){this.animation.startTime=e}attachTimeline({timeline:e,observe:t}){return(this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,e&&nu())?(this.animation.timeline=e,em):t(this)}}let ng={anticipate:i1,backInOut:i0,circInOut:i5};class nv extends nf{constructor(e){!function(e){"string"==typeof e.ease&&e.ease in ng&&(e.ease=ng[e.ease])}(e),ns(e),super(e),e.startTime&&(this.startTime=e.startTime),this.options=e}updateMotionValue(e){let{motionValue:t,onUpdate:i,onComplete:n,element:s,...r}=this.options;if(!t)return;if(void 0!==e)return void t.set(e);let a=new no({...r,autoplay:!1}),o=ig(this.finishedTime??this.time);t.setWithVelocity(a.sample(o-10).value,a.sample(o).value,10),a.stop()}}let ny=(e,t)=>"zIndex"!==t&&!!("number"==typeof e||Array.isArray(e)||"string"==typeof e&&(eY.test(e)||"0"===e)&&!e.startsWith("url(")),nx=new Set(["opacity","clipPath","filter","transform"]),nb=nl(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));class nw extends nr{constructor({autoplay:e=!0,delay:t=0,type:i="keyframes",repeat:n=0,repeatDelay:s=0,repeatType:r="loop",keyframes:a,name:o,motionValue:l,element:u,...h}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=e8.now();const d={autoplay:e,delay:t,type:i,repeat:n,repeatDelay:s,repeatType:r,name:o,motionValue:l,element:u,...h},c=u?.KeyframeResolver||eC;this.keyframeResolver=new c(a,(e,t,i)=>this.onKeyframesResolved(e,t,d,!i),o,l,u),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(e,t,i,n){this.keyframeResolver=void 0;let{name:s,type:r,velocity:a,delay:o,isHandoff:l,onUpdate:u}=i;this.resolvedAt=e8.now(),!function(e,t,i,n){let s=e[0];if(null===s)return!1;if("display"===t||"visibility"===t)return!0;let r=e[e.length-1],a=ny(s,t),o=ny(r,t);return eo(a===o,`You are trying to animate ${t} from "${s}" to "${r}". "${a?r:s}" is not an animatable value.`,"value-not-animatable"),!!a&&!!o&&(function(e){let t=e[0];if(1===e.length)return!0;for(let i=0;i<e.length;i++)if(e[i]!==t)return!0}(e)||("spring"===i||nm(i))&&n)}(e,s,r,a)&&((ef.instantAnimations||!o)&&u?.(ni(e,i,t)),e[0]=e[e.length-1],ic(i),i.repeat=0);let h={startTime:n?this.resolvedAt&&this.resolvedAt-this.createdAt>40?this.resolvedAt:this.createdAt:void 0,finalKeyframe:t,...i,keyframes:e},d=!l&&function(e){let{motionValue:t,name:i,repeatDelay:n,repeatType:s,damping:r,type:a}=e;if(!(t?.owner?.current instanceof HTMLElement))return!1;
19let{onUpdate:o,transformTemplate:l}=t.owner.getProps();return nb()&&i&&nx.has(i)&&("transform"!==i||!l)&&!o&&!n&&"mirror"!==s&&0!==r&&"inertia"!==a}(h)?new nv({...h,element:h.motionValue.owner.current}):new no(h);d.finished.then(()=>this.notifyFinished()).catch(em),this.pendingTimeline&&(this.stopTimeline=d.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=d}get finished(){return this._animation?this.animation.finished:this._finished}then(e,t){return this.finished.finally(e).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),eP=!0,eA(),ek(),eP=!1),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(e){this.animation.time=e}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(e){this.animation.speed=e}get startTime(){return this.animation.startTime}attachTimeline(e){return this._animation?this.stopTimeline=this.animation.attachTimeline(e):this.pendingTimeline=e,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}}let nj=e=>null!==e,nT={type:"spring",stiffness:500,damping:25,restSpeed:10},nS={type:"keyframes",duration:.8},nP={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},nk=(e,t,i,n={},s,r)=>a=>{let o=iu(n,e)||{},l=o.delay||n.delay||0,{elapsed:u=0}=n;u-=ig(l);let h={keyframes:Array.isArray(i)?i:[null,i],ease:"easeOut",velocity:t.getVelocity(),...o,delay:-u,onUpdate:e=>{t.set(e),o.onUpdate&&o.onUpdate(e)},onComplete:()=>{a(),o.onComplete&&o.onComplete()},name:e,motionValue:t,element:r?void 0:s};!function({when:e,delay:t,delayChildren:i,staggerChildren:n,staggerDirection:s,repeat:r,repeatType:a,repeatDelay:o,from:l,elapsed:u,...h}){return!!Object.keys(h).length}(o)&&Object.assign(h,((e,{keyframes:t})=>t.length>2?nS:v.has(e)?e.startsWith("scale")?{type:"spring",stiffness:550,damping:0===t[1]?2*Math.sqrt(550):30,restSpeed:10}:nT:nP)(e,h)),h.duration&&(h.duration=ig(h.duration)),h.repeatDelay&&(h.repeatDelay=ig(h.repeatDelay)),void 0!==h.from&&(h.keyframes[0]=h.from);let d=!1;if(!1!==h.type&&(0!==h.duration||h.repeatDelay)||(ic(h),0===h.delay&&(d=!0)),(ef.instantAnimations||ef.skipAnimations)&&(d=!0,ic(h),h.delay=0),h.allowFlatten=!o.type&&!o.ease,d&&!r&&void 0!==t.get()){let e=function(e,{repeat:t,repeatType:i="loop"},n){let s=e.filter(nj),r=t&&"loop"!==i&&t%2==1?0:s.length-1;return s[r]}(h.keyframes,o);if(void 0!==e)return void ey.update(()=>{h.onUpdate(e),h.onComplete()})}return o.isSync?new no(h):new nw(h)};function nA(e,t,{delay:i=0,transitionOverride:n,type:s}={}){let{transition:r=e.getDefaultTransition(),transitionEnd:a,...o}=t;n&&(r=n);let l=[],u=s&&e.animationState&&e.animationState.getState()[s];for(let t in o){let n=e.getValue(t,e.latestValues[t]??null),s=o[t];if(void 0===s||u&&function({protectedKeys:e,needsAnimating:t},i){let n=e.hasOwnProperty(i)&&!0!==t[i];return t[i]=!1,n}(u,t))continue;let a={delay:i,...iu(r||{},t)},h=n.get();if(void 0!==h&&!n.isAnimating&&!Array.isArray(s)&&s===h&&!a.velocity)continue;let d=!1;if(window.MotionHandoffAnimation){let i=e.props[is];if(i){let e=window.MotionHandoffAnimation(i,t,ey);null!==e&&(a.startTime=e,d=!0)}}id(e,t),n.start(nk(t,n,s,e.shouldReduceMotion&&X.has(t)?{type:!1}:a,e,d));let c=n.animation;c&&l.push(c)}return a&&Promise.all(l).then(()=>{ey.update(()=>{a&&function(e,t){let{transitionEnd:i={},transition:n={},...s}=il(e,t)||{};for(let t in s={...s,...i}){var r;let i=ih(r=s[t])?r[r.length-1]||0:r;e.hasValue(t)?e.getValue(t).set(i):e.addValue(t,tn(i))}}(e,a)})}),l}function nC(e,t,i,n=0,s=1){let r=Array.from(e).sort((e,t)=>e.sortNodePosition(t)).indexOf(t),a=e.size,o=(a-1)*n;return"function"==typeof i?i(r,a):1===s?r*n:o-r*n}function nE(e,t,i={}){let n=il(e,t,"exit"===i.type?e.presenceContext?.custom:void 0),{transition:s=e.getDefaultTransition()||{}}=n||{};i.transitionOverride&&(s=i.transitionOverride);let r=n?()=>
19Promise.all(nA(e,n,i)):()=>Promise.resolve(),a=e.variantChildren&&e.variantChildren.size?(n=0)=>{let{delayChildren:r=0,staggerChildren:a,staggerDirection:o}=s;return function(e,t,i=0,n=0,s=0,r=1,a){let o=[];for(let l of e.variantChildren)l.notify("AnimationStart",t),o.push(nE(l,t,{...a,delay:i+("function"==typeof n?0:n)+nC(e.variantChildren,l,n,s,r)}).then(()=>l.notify("AnimationComplete",t)));return Promise.all(o)}(e,t,n,r,a,o,i)}:()=>Promise.resolve(),{when:o}=s;if(!o)return Promise.all([r(),a(i.delay)]);{let[e,t]="beforeChildren"===o?[r,a]:[a,r];return e().then(()=>t())}}function nM(e,t){if(!Array.isArray(t))return!1;let i=t.length;if(i!==e.length)return!1;for(let n=0;n<i;n++)if(t[n]!==e[n])return!1;return!0}let nN=tx.length,nV=[...ty].reverse(),nR=ty.length;function nD(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function nL(){return{animate:nD(!0),whileInView:nD(),whileHover:nD(),whileTap:nD(),whileDrag:nD(),whileFocus:nD(),exit:nD()}}class nI{constructor(e){this.isMounted=!1,this.node=e}update(){}}let nO=0,nF={x:!1,y:!1};function nB(e,t,i,n={passive:!0}){return e.addEventListener(t,i,n),()=>e.removeEventListener(t,i)}let n$=e=>"mouse"===e.pointerType?"number"!=typeof e.button||e.button<=0:!1!==e.isPrimary;function n_(e){return{point:{x:e.pageX,y:e.pageY}}}function nU(e,t,i,n){return nB(e,t,e=>n$(e)&&i(e,n_(e)),n)}function nz(e){return e.max-e.min}function nW(e,t,i,n=.5){e.origin=n,e.originPoint=D(t.min,t.max,e.origin),e.scale=nz(i)/nz(t),e.translate=D(i.min,i.max,e.origin)-e.originPoint,(e.scale>=.9999&&e.scale<=1.0001||isNaN(e.scale))&&(e.scale=1),(e.translate>=-.01&&e.translate<=.01||isNaN(e.translate))&&(e.translate=0)}function nH(e,t,i,n){nW(e.x,t.x,i.x,n?n.originX:void 0),nW(e.y,t.y,i.y,n?n.originY:void 0)}function nX(e,t,i){e.min=i.min+t.min,e.max=e.min+nz(t)}function nY(e,t,i){e.min=t.min-i.min,e.max=e.min+nz(t)}function nG(e,t,i){nY(e.x,t.x,i.x),nY(e.y,t.y,i.y)}function nK(e){return[e("x"),e("y")]}let nq=({current:e})=>e?e.ownerDocument.defaultView:null,nZ=(e,t)=>Math.abs(e-t);class nJ{constructor(e,t,{transformPagePoint:i,contextWindow:n=window,dragSnapToOrigin:s=!1,distanceThreshold:r=3}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{var e,t;if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let i=n1(this.lastMoveEventInfo,this.history),n=null!==this.startEvent,s=(e=i.offset,t={x:0,y:0},Math.sqrt(nZ(e.x,t.x)**2+nZ(e.y,t.y)**2)>=this.distanceThreshold);if(!n&&!s)return;let{point:r}=i,{timestamp:a}=eb;this.history.push({...r,timestamp:a});let{onStart:o,onMove:l}=this.handlers;n||(o&&o(this.lastMoveEvent,i),this.startEvent=this.lastMoveEvent),l&&l(this.lastMoveEvent,i)},this.handlePointerMove=(e,t)=>{this.lastMoveEvent=e,this.lastMoveEventInfo=nQ(t,this.transformPagePoint),ey.update(this.updatePoint,!0)},this.handlePointerUp=(e,t)=>{this.end();let{onEnd:i,onSessionEnd:n,resumeAnimation:s}=this.handlers;if(this.dragSnapToOrigin&&s&&s(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let r=n1("pointercancel"===e.type?this.lastMoveEventInfo:nQ(t,this.transformPagePoint),this.history);this.startEvent&&i&&i(e,r),n&&n(e,r)},!n$(e))return;this.dragSnapToOrigin=s,this.handlers=t,this.transformPagePoint=i,this.distanceThreshold=r,this.contextWindow=n||window;const a=nQ(n_(e),this.transformPagePoint),{point:o}=a,{timestamp:l}=eb;this.history=[{...o,timestamp:l}];const{onSessionStart:u}=t;u&&u(e,n1(a,this.history)),this.removeListeners=im(nU(this.contextWindow,"pointermove",this.handlePointerMove),nU(this.contextWindow,"pointerup",this.handlePointerUp),nU(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),ex(this.updatePoint)}}function nQ(e,t){return t?{point:t(e.point)}:e}function n0(e,t){return{x:e.x-t.x,y:e.y-t.y}}function n1({point:e},t){return{point:e,delta:n0(e,n2(t)),offset:n0(e,t[0]),velocity:function(e,t){if(e.length<2)return{x:0,y:0};let i=e.length-1,n=null,s=n2(e);for(;i>=0&&(n=e[i],!(s.timestamp-n.timestamp>ig(.1)));)i--;if(!n)return{x:0,y:0};let r=(s.timestamp-n.timestamp)/1e3;if(0===r)return{x:0,y:0};let a={x:(s.x-n.x)/r,y:(s.y-n.y)/r};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}(t,.1)}}function n2(e){return e[e.length-1]}function n3(e,t,i){return{min:void 0!==t?e.min+t:void 0,max:void 0!==i?e.max+i-(e.max-e.min):void 0}}function n5(e,t){let i=t.min-e.min,n=t.max-e.max;return t.max-t.min<e.max-e.min&&([i,n]=[n,i]),{min:i,max:n}}function n4(e,t,i){return{min:n6(e,t),max:n6(e,i)}}function n6(e,t){return"number"==typeof e?e:e[t]||0}let n8=new WeakMap;
19class n9{constructor(e){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=td(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=e}start(e,{snapToCursor:t=!1,distanceThreshold:i}={}){let{presenceContext:n}=this.visualElement;if(n&&!1===n.isPresent)return;let s=e=>{let{dragSnapToOrigin:i}=this.getProps();i?this.pauseAnimation():this.stopAnimation(),t&&this.snapToCursor(n_(e).point)},r=(e,t)=>{let{drag:i,dragPropagation:n,onDragStart:s}=this.getProps();if(i&&!n&&(this.openDragLock&&this.openDragLock(),this.openDragLock=function(e){if("x"===e||"y"===e)if(nF[e])return null;else return nF[e]=!0,()=>{nF[e]=!1};return nF.x||nF.y?null:(nF.x=nF.y=!0,()=>{nF.x=nF.y=!1})}(i),!this.openDragLock))return;this.latestPointerEvent=e,this.latestPanInfo=t,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),nK(e=>{let t=this.getAxisMotionValue(e).get()||0;if(Q.test(t)){let{projection:i}=this.visualElement;if(i&&i.layout){let n=i.layout.layoutBox[e];n&&(t=nz(n)*(parseFloat(t)/100))}}this.originPoint[e]=t}),s&&ey.postRender(()=>s(e,t)),id(this.visualElement,"transform");let{animationState:r}=this.visualElement;r&&r.setActive("whileDrag",!0)},a=(e,t)=>{this.latestPointerEvent=e,this.latestPanInfo=t;let{dragPropagation:i,dragDirectionLock:n,onDirectionLock:s,onDrag:r}=this.getProps();if(!i&&!this.openDragLock)return;let{offset:a}=t;if(n&&null===this.currentDirection){this.currentDirection=function(e,t=10){let i=null;return Math.abs(e.y)>t?i="y":Math.abs(e.x)>t&&(i="x"),i}(a),null!==this.currentDirection&&s&&s(this.currentDirection);return}this.updateAxis("x",t.point,a),this.updateAxis("y",t.point,a),this.visualElement.render(),r&&r(e,t)},o=(e,t)=>{this.latestPointerEvent=e,this.latestPanInfo=t,this.stop(e,t),this.latestPointerEvent=null,this.latestPanInfo=null},l=()=>nK(e=>"paused"===this.getAnimationState(e)&&this.getAxisMotionValue(e).animation?.play()),{dragSnapToOrigin:u}=this.getProps();this.panSession=new nJ(e,{onSessionStart:s,onStart:r,onMove:a,onSessionEnd:o,resumeAnimation:l},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:u,distanceThreshold:i,contextWindow:nq(this.visualElement)})}stop(e,t){let i=e||this.latestPointerEvent,n=t||this.latestPanInfo,s=this.isDragging;if(this.cancel(),!s||!n||!i)return;let{velocity:r}=n;this.startAnimation(r);let{onDragEnd:a}=this.getProps();a&&ey.postRender(()=>a(i,n))}cancel(){this.isDragging=!1;let{projection:e,animationState:t}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;let{dragPropagation:i}=this.getProps();!i&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),t&&t.setActive("whileDrag",!1)}updateAxis(e,t,i){let{drag:n}=this.getProps();if(!i||!n7(e,n,this.currentDirection))return;let s=this.getAxisMotionValue(e),r=this.originPoint[e]+i[e];this.constraints&&this.constraints[e]&&(r=function(e,{min:t,max:i},n){return void 0!==t&&e<t?e=n?D(t,e,n.min):Math.max(e,t):void 0!==i&&e>i&&(e=n?D(i,e,n.max):Math.min(e,i)),e}(r,this.constraints[e],this.elastic[e])),s.set(r)}resolveConstraints(){let{dragConstraints:e,dragElastic:t}=this.getProps(),i=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,n=this.constraints;e&&ii(e)?this.constraints||(this.constraints=this.resolveRefConstraints()):e&&i?this.constraints=function(e,{top:t,left:i,bottom:n,right:s}){return{x:n3(e.x,i,s),y:n3(e.y,t,n)}}(i.layoutBox,e):this.constraints=!1,this.elastic=function(e=.35){return!1===e?e=0:!0===e&&(e=.35),{x:n4(e,"left","right"),y:n4(e,"top","bottom")}}(t),n!==this.constraints&&i&&this.constraints&&!this.hasMutatedConstraints&&nK(e=>{var t,n;let s;!1!==this.constraints&&this.getAxisMotionValue(e)&&(this.constraints[e]=(t=i.layoutBox[e],n=this.constraints[e],s={},void 0!==n.min&&(s.min=n.min-t.min),void 0!==n.max&&(s.max=n.max-t.min),s))})}resolveRefConstraints(){var e;let{dragConstraints:t,onMeasureDragConstraints:i}=this.getProps();if(!t||!ii(t))return!1;let n=t.current;el(null!==n,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.","drag-constraints-ref");let{projection:s}=this.visualElement;if(!s||!s.layout)return!1;let r=function(e,t,i){let n=H(e,i),{scroll:s}=t;return s&&(U(n.x,s.offset.x),U(n.y,s.offset.y)),n}(n,s.root,this.visualElement.getTransformPagePoint()),a=(e=s.layout.layoutBox,{x:n5(e.x,r.x),y:n5(e.y,r.y)});if(i){let e=i(function({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}(a));this.hasMutatedConstraints=!!e,e&&(a=R(e))}return a}startAnimation(e){let{drag:t,dragMomentum:i,dragElastic:n,dragTransition:s,dragSnapToOrigin:r,onDragTransitionEnd:a}=this.getProps(),o=this.constraints||{};return Promise.all(nK(a=>
19{if(!n7(a,t,this.currentDirection))return;let l=o&&o[a]||{};r&&(l={min:0,max:0});let u={type:"inertia",velocity:i?e[a]:0,bounceStiffness:n?200:1e6,bounceDamping:n?40:1e7,timeConstant:750,restDelta:1,restSpeed:10,...s,...l};return this.startAxisValueAnimation(a,u)})).then(a)}startAxisValueAnimation(e,t){let i=this.getAxisMotionValue(e);return id(this.visualElement,e),i.start(nk(e,i,0,t,this.visualElement,!1))}stopAnimation(){nK(e=>this.getAxisMotionValue(e).stop())}pauseAnimation(){nK(e=>this.getAxisMotionValue(e).animation?.pause())}getAnimationState(e){return this.getAxisMotionValue(e).animation?.state}getAxisMotionValue(e){let t=`_drag${e.toUpperCase()}`,i=this.visualElement.getProps();return i[t]||this.visualElement.getValue(e,(i.initial?i.initial[e]:void 0)||0)}snapToCursor(e){nK(t=>{let{drag:i}=this.getProps();if(!n7(t,i,this.currentDirection))return;let{projection:n}=this.visualElement,s=this.getAxisMotionValue(t);if(n&&n.layout){let{min:i,max:r}=n.layout.layoutBox[t];s.set(e[t]-D(i,r,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:e,dragConstraints:t}=this.getProps(),{projection:i}=this.visualElement;if(!ii(t)||!i||!this.constraints)return;this.stopAnimation();let n={x:0,y:0};nK(e=>{let t=this.getAxisMotionValue(e);if(t&&!1!==this.constraints){var i,s;let r,a,o,l=t.get();n[e]=(i={min:l,max:l},s=this.constraints[e],r=.5,a=nz(i),(o=nz(s))>a?r=i9(s.min,s.max-a,i.min):a>o&&(r=i9(i.min,i.max-o,s.min)),Y(0,1,r))}});let{transformTemplate:s}=this.visualElement.getProps();this.visualElement.current.style.transform=s?s({},""):"none",i.root&&i.root.updateScroll(),i.updateLayout(),this.resolveConstraints(),nK(t=>{if(!n7(t,e,null))return;let i=this.getAxisMotionValue(t),{min:s,max:r}=this.constraints[t];i.set(D(s,r,n[t]))})}addListeners(){if(!this.visualElement.current)return;n8.set(this.visualElement,this);let e=nU(this.visualElement.current,"pointerdown",e=>{let{drag:t,dragListener:i=!0}=this.getProps();t&&i&&this.start(e)}),t=()=>{let{dragConstraints:e}=this.getProps();ii(e)&&e.current&&(this.constraints=this.resolveRefConstraints())},{projection:i}=this.visualElement,n=i.addEventListener("measure",t);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),ey.read(t);let s=nB(window,"resize",()=>this.scalePositionWithinConstraints()),r=i.addEventListener("didUpdate",({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&(nK(t=>{let i=this.getAxisMotionValue(t);i&&(this.originPoint[t]+=e[t].translate,i.set(i.get()+e[t].translate))}),this.visualElement.render())});return()=>{s(),e(),n(),r&&r()}}getProps(){let e=this.visualElement.getProps(),{drag:t=!1,dragDirectionLock:i=!1,dragPropagation:n=!1,dragConstraints:s=!1,dragElastic:r=.35,dragMomentum:a=!0}=e;return{...e,drag:t,dragDirectionLock:i,dragPropagation:n,dragConstraints:s,dragElastic:r,dragMomentum:a}}}function n7(e,t,i){return(!0===t||t===e)&&(null===i||i===e)}let se=e=>(t,i)=>{e&&ey.postRender(()=>e(t,i))};var st=d;function si(e=!0){let t=(0,d.useContext)(t4);if(null===t)return[!0,null];let{isPresent:i,onExitComplete:n,register:s}=t,r=(0,d.useId)();(0,d.useEffect)(()=>{if(e)return s(r)},[e]);let a=(0,d.useCallback)(()=>e&&n&&n(r),[r,n,e]);return!i&&n?[!1,a]:[!0]}let sn={hasAnimatedSinceResize:!0,hasEverUpdated:!1},ss=!1;class sr extends st.Component{componentDidMount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:i,layoutId:n}=this.props,{projection:s}=e;s&&(t.group&&t.group.add(s),i&&i.register&&n&&i.register(s),ss&&s.root.didUpdate(),s.addEventListener("animationComplete",()=>{this.safeToRemove()}),s.setOptions({...s.options,onExitComplete:()=>this.safeToRemove()})),sn.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){let{layoutDependency:t,visualElement:i,drag:n,isPresent:s}=this.props,{projection:r}=i;return r&&(r.isPresent=s,ss=!0,n||e.layoutDependency!==t||void 0===t||e.isPresent!==s?r.willUpdate():this.safeToRemove(),e.isPresent!==s&&(s?r.promote():r.relegate()||ey.postRender(()=>{let e=r.getStack();e&&e.members.length||this.safeToRemove()}))),null}componentDidUpdate(){let{projection:e}=this.props.visualElement;e&&(e.root.didUpdate(),tr.postRender(()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:i}=this.props,{projection:n}=e;ss=!0,n&&(n.scheduleCheckAfterUnmount(),t&&t.group&&t.group.remove(n),i&&i.deregister&&i.deregister(n))}safeToRemove(){let{safeToRemove:e}=this.props;e&&e()}render(){return null}}function sa(e){let[t,i]=si(),n=(0,st.useContext)(tG);return(0,s.jsx)(sr,{...e,layoutGroup:n,switchLayoutGroup:(0,st.useContext)(ir),isPresent:t,safeToRemove:i})}function so(e){return"object"==typeof e&&null!==e}function sl(e){return so(e)&&"ownerSVGElement"in e}let su=(e,t)=>e.depth-t.depth;class sh{constructor(){this.children=[],this.isDirty=!1}add(e){e9(this.children,e),this.isDirty=!0}remove(e){e7(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(su),this.isDirty=!1,this.children.forEac
19h(e)}}let sd=["TopLeft","TopRight","BottomLeft","BottomRight"],sc=sd.length,sp=e=>"string"==typeof e?parseFloat(e):e,sm=e=>"number"==typeof e||ee.test(e);function sf(e,t){return void 0!==e[t]?e[t]:e.borderRadius}let sg=sy(0,.5,i3),sv=sy(.5,.95,em);function sy(e,t,i){return n=>n<e?0:n>t?1:i(i9(e,t,n))}function sx(e,t){e.min=t.min,e.max=t.max}function sb(e,t){sx(e.x,t.x),sx(e.y,t.y)}function sw(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function sj(e,t,i,n,s){return e-=t,e=n+1/i*(e-n),void 0!==s&&(e=n+1/s*(e-n)),e}function sT(e,t,[i,n,s],r,a){!function(e,t=0,i=1,n=.5,s,r=e,a=e){if(Q.test(t)&&(t=parseFloat(t),t=D(a.min,a.max,t/100)-a.min),"number"!=typeof t)return;let o=D(r.min,r.max,n);e===r&&(o-=t),e.min=sj(e.min,t,i,o,s),e.max=sj(e.max,t,i,o,s)}(e,t[i],t[n],t[s],t.scale,r,a)}let sS=["x","scaleX","originX"],sP=["y","scaleY","originY"];function sk(e,t,i,n){sT(e.x,t,sS,i?i.x:void 0,n?n.x:void 0),sT(e.y,t,sP,i?i.y:void 0,n?n.y:void 0)}function sA(e){return 0===e.translate&&1===e.scale}function sC(e){return sA(e.x)&&sA(e.y)}function sE(e,t){return e.min===t.min&&e.max===t.max}function sM(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function sN(e,t){return sM(e.x,t.x)&&sM(e.y,t.y)}function sV(e){return nz(e.x)/nz(e.y)}function sR(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class sD{constructor(){this.members=[]}add(e){e9(this.members,e),e.scheduleRender()}remove(e){if(e7(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){let e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(e){let t,i=this.members.findIndex(t=>e===t);if(0===i)return!1;for(let e=i;e>=0;e--){let i=this.members[e];if(!1!==i.isPresent){t=i;break}}return!!t&&(this.promote(t),!0)}promote(e,t){let i=this.lead;if(e!==i&&(this.prevLead=i,this.lead=e,e.show(),i)){i.instance&&i.scheduleRender(),e.scheduleRender(),e.resumeFrom=i,t&&(e.resumeFrom.preserveOpacity=!0),i.snapshot&&(e.snapshot=i.snapshot,e.snapshot.latestValues=i.animationValues||i.latestValues),e.root&&e.root.isUpdating&&(e.isLayoutDirty=!0);let{crossfade:n}=e.options;!1===n&&i.hide()}}exitAnimationComplete(){this.members.forEach(e=>{let{options:t,resumingFrom:i}=e;t.onExitComplete&&t.onExitComplete(),i&&i.options.onExitComplete&&i.options.onExitComplete()})}scheduleRender(){this.members.forEach(e=>{e.instance&&e.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}let sL=["","X","Y","Z"],sI=0;function sO(e,t,i,n){let{latestValues:s}=t;s[e]&&(i[e]=s[e],t.setStaticValue(e,0),n&&(n[e]=0))}function sF({attachResizeListener:e,defaultParent:t,measureScroll:i,checkIsScrollRoot:n,resetTransform:s}){return class{constructor(e={},i=t?.()){this.id=sI++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(s_),this.nodes.forEach(sG),this.nodes.forEach(sK),this.nodes.forEach(sU)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=e,this.root=i?i.root||i:this,this.path=i?[...i.path,i]:[],this.parent=i,this.depth=i?i.depth+1:0;for(let e=0;e<this.path.length;e++)this.path[e].shouldResetTransform=!0;this.root===this&&(this.nodes=new sh)}addEventListener(e,t){return this.eventHandlers.has(e)||this.eventHandlers.set(e,new te),this.eventHandlers.get(e).add(t)}notifyListeners(e,...t){let i=this.eventHandlers.get(e);i&&i.notify(...t)}hasListeners(e){return this.eventHandlers.has(e)}mount(t){if(this.instance)return;this.isSVG=sl(t)&&!(sl(t)&&"svg"===t.tagName),this.instance=t;let{layoutId:i,layout:n,visualElement:s}=this.options;if(s&&!s.current&&s.mount(t),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(n||i)&&(this.isLayoutDirty=!0),e){let i,n=0,s=()=>this.root.updateBlockedByResize=!1;ey.read(()=>{n=window.innerWidth}),e(t,()=>{let e=window.innerWidth;if(e!==n){let t,r;
19n=e,this.root.updateBlockedByResize=!0,i&&i(),t=e8.now(),r=({timestamp:e})=>{let i=e-t;i>=250&&(ex(r),s(i-250))},ey.setup(r,!0),i=()=>ex(r),sn.hasAnimatedSinceResize&&(sn.hasAnimatedSinceResize=!1,this.nodes.forEach(sY))}})}i&&this.root.registerSharedNode(i,this),!1!==this.options.animate&&s&&(i||n)&&this.addEventListener("didUpdate",({delta:e,hasLayoutChanged:t,hasRelativeLayoutChanged:i,layout:n})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}let r=this.options.transition||s.getDefaultTransition()||s1,{onLayoutAnimationStart:a,onLayoutAnimationComplete:o}=s.getProps(),l=!this.targetLayout||!sN(this.targetLayout,n),u=!t&&i;if(this.options.layoutRoot||this.resumeFrom||u||t&&(l||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);let t={...iu(r,"layout"),onPlay:a,onComplete:o};(s.shouldReduceMotion||this.options.layoutRoot)&&(t.delay=0,t.type=!1),this.startAnimation(t),this.setAnimationOrigin(e,u)}else t||sY(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=n})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);let e=this.getStack();e&&e.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),ex(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){!this.isUpdateBlocked()&&(this.isUpdating=!0,this.nodes&&this.nodes.forEach(sq),this.animationId++)}getTransformTemplate(){let{visualElement:e}=this.options;return e&&e.getProps().transformTemplate}willUpdate(e=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&function e(t){if(t.hasCheckedOptimisedAppear=!0,t.root===t)return;let{visualElement:i}=t.options;if(!i)return;let n=i.props[is];if(window.MotionHasOptimisedAnimation(n,"transform")){let{layout:e,layoutId:i}=t.options;window.MotionCancelOptimisedAnimation(n,"transform",ey,!(e||i))}let{parent:s}=t;s&&!s.hasCheckedOptimisedAppear&&e(s)}(this),this.root.isUpdating||this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let e=0;e<this.path.length;e++){let t=this.path[e];t.shouldResetTransform=!0,t.updateScroll("snapshot"),t.options.layoutRoot&&t.willUpdate(!1)}let{layoutId:t,layout:i}=this.options;if(void 0===t&&!i)return;let n=this.getTransformTemplate();this.prevTransformTemplateValue=n?n(this.latestValues,""):void 0,this.updateSnapshot(),e&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(sW);return}if(this.animationId<=this.animationCommitId)return void this.nodes.forEach(sH);this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(sX),this.nodes.forEach(sB),this.nodes.forEach(s$)):this.nodes.forEach(sH),this.clearAllSnapshots();let e=e8.now();eb.delta=Y(0,1e3/60,e-eb.timestamp),eb.timestamp=e,eb.isProcessing=!0,ew.update.process(eb),ew.preRender.process(eb),ew.render.process(eb),eb.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,tr.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(sz),this.sharedNodes.forEach(sZ)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,ey.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){ey.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){!this.snapshot&&this.instance&&(this.snapshot=this.measure(),!this.snapshot||nz(this.snapshot.measuredBox.x)||nz(this.snapshot.measuredBox.y)||(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let e=0;e<this.path.length;e++)this.path[e].updateScroll();let e=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected=td(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);let{visualElement:t}=this.options;t&&t.notify("LayoutMeasure",this.layout.layoutBox,e?e.layoutBox:void 0)}updateScroll(e="measure"){let t=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===e&&(t=!1),t&&this.instance){let t=n(this.instance);this.scroll={animationId:this.root.animationId,phase:e,isRoot:t,offset:i(this.instance),wasRoot:this.scroll?this.scroll.isRoot:t}}}resetTransform(){if(!s)return;let e=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,t=this.projectionDelta&&!sC(this.projectionDelta),i=this.getTransformTemplate(),n=i?i(this.latestValues,""):void 0,r=n!==this.prevTransformTemplateValue;e&&this.instance&&(t||O(this.latestValues)||r)&&(s(this.instance,n),this.shouldResetTransform=!1,this.scheduleRender())}measure(e=!0){var t;let i=this.measurePageBox(),n=this.removeElementScroll(i);return e&&(n=this.removeTransform(n)),s5((t=n).x),s5(t.y),{animationId:this.root.animationId,measuredBox:i,layoutBox:n,latestValues:{},source:this.id}}measurePageBox(){let{visualElement:e}=this.options;if(!e)return td();let t=e.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(s6))){let{scroll:e}=this.root;e&&(U(t.x,e.offset.x),U(t.y,e.offset.y))}return t}removeElementScroll(e){let t=td();if(sb(t,e),this.scroll?.wasRoot)return t;for(let i=0;i<this.path.length;i++){let n=this.path[i],{scroll:s,options:r}=n;n!==this.root&&s&&r.layoutScroll&&(s.wasRoot&&sb(t,e),U(t.x,s.offset.x),U(t.y,s.offset.y))}return t}applyTransform(e,t=!1){let i=td();sb(i,e);for(let e=0;e<this.path.length;e++){let n=this.path[e];!t&&n.options.layoutScroll&&n.scroll&&n!==n.root&&W(i,{x:-n.scroll.offset.x,y:-n.scroll.offset.y}),O(n.latestValues)&&W(i,n.latestValues)}return O(this.latestValues)&&W(i,this.latestValues),i}removeTransform(e){let t=td();sb(t,e);for(let e=0;e<this.path.length;e++){let i=this.path[e];if(!i.instance||!O(i.latestValues))continue;I(i.latestValues)&&i.updateSnapshot();let n=td();sb(n,i.measurePageBox()),sk(t,i.latestValues,i.snapshot?i.snapshot.layoutBox:void 0,n)}return O(this.latestValues)&&sk(t,this.latestValues),t}setTargetDelta(e){this.targetDelta=e,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(e){this.options={...this.options,...e,crossfade:void 0===e.crossfade||e.crossfade}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==eb.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(e=!1){let t=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=t.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=t.
19isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=t.isSharedProjectionDirty);let i=!!this.resumingFrom||this!==t;if(!(e||i&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;let{layout:n,layoutId:s}=this.options;if(!this.layout||!(n||s))return;this.resolvedRelativeTargetAt=eb.timestamp;let r=this.getClosestProjectingParent();if(r&&this.linkedParentVersion!==r.layoutVersion&&!r.options.layoutRoot&&this.removeRelativeTarget(),this.targetDelta||this.relativeTarget||(r&&r.layout?this.createRelativeTarget(r,this.layout.layoutBox,r.layout.layoutBox):this.removeRelativeTarget()),this.relativeTarget||this.targetDelta){if(this.target||(this.target=td(),this.targetWithTransforms=td()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target){var a,o,l;this.forceRelativeParentToResolveTarget(),a=this.target,o=this.relativeTarget,l=this.relativeParent.target,nX(a.x,o.x,l.x),nX(a.y,o.y,l.y)}else this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):sb(this.target,this.layout.layoutBox),_(this.target,this.targetDelta)):sb(this.target,this.layout.layoutBox);this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,r&&!!r.resumingFrom==!!this.resumingFrom&&!r.options.layoutScroll&&r.target&&1!==this.animationProgress?this.createRelativeTarget(r,this.target,r.target):this.relativeParent=this.relativeTarget=void 0)}}getClosestProjectingParent(){if(!(!this.parent||I(this.parent.latestValues)||F(this.parent.latestValues)))if(this.parent.isProjecting())return this.parent;else return this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(e,t,i){this.relativeParent=e,this.linkedParentVersion=e.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=td(),this.relativeTargetOrigin=td(),nG(this.relativeTargetOrigin,t,i),sb(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){let e=this.getLead(),t=!!this.resumingFrom||this!==e,i=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(i=!1),t&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(i=!1),this.resolvedRelativeTargetAt===eb.timestamp&&(i=!1),i)return;let{layout:n,layoutId:s}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(n||s))return;sb(this.layoutCorrected,this.layout.layoutBox);let r=this.treeScale.x,a=this.treeScale.y;!function(e,t,i,n=!1){let s,r,a=i.length;if(a){t.x=t.y=1;for(let o=0;o<a;o++){r=(s=i[o]).projectionDelta;let{visualElement:a}=s.options;(!a||!a.props.style||"contents"!==a.props.style.display)&&(n&&s.options.layoutScroll&&s.scroll&&s!==s.root&&W(e,{x:-s.scroll.offset.x,y:-s.scroll.offset.y}),r&&(t.x*=r.x.scale,t.y*=r.y.scale,_(e,r)),n&&O(s.latestValues)&&W(e,s.latestValues))}t.x<1.0000000000001&&t.x>.999999999999&&(t.x=1),t.y<1.0000000000001&&t.y>.999999999999&&(t.y=1)}}(this.layoutCorrected,this.treeScale,this.path,t),e.layout&&!e.target&&(1!==this.treeScale.x||1!==this.treeScale.y)&&(e.target=e.layout.layoutBox,e.targetWithTransforms=td());let{target:o}=e;if(!o){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}this.projectionDelta&&this.prevProjectionDelta?(sw(this.prevProjectionDelta.x,this.projectionDelta.x),sw(this.prevProjectionDelta.y,this.projectionDelta.y)):this.createProjectionDeltas(),nH(this.projectionDelta,this.layoutCorrected,o,this.latestValues),this.treeScale.x===r&&this.treeScale.y===a&&sR(this.projectionDelta.x,this.prevProjectionDelta.x)&&sR(this.projectionDelta.y,this.prevProjectionDelta.y)||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",o))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(e=!0){if(this.options.visualElement?.scheduleRender(),e){let e=this.getStack();e&&e.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=tu(),this.projectionDelta=tu(),this.projectionDeltaWithTransform=tu()}setAnimationOrigin(e,t=!1){let i,n=this.snapshot,s=n?n.latestValues:{},r={...this.latestValues},a=tu();this.relativeParent&&this.relativeParent.options.layoutRoot||(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!t;let o=td(),l=(n?n.source:void 0)!==(this.layout?this.layout.source:void 0),u=this.getStack(),h=!u||u.members.length<=1,d=!!(l&&!h&&
19!0===this.options.crossfade&&!this.path.some(s0));this.animationProgress=0,this.mixTargetDelta=t=>{let n=t/1e3;if(sJ(a.x,e.x,n),sJ(a.y,e.y,n),this.setTargetDelta(a),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout){var u,c,p,m,f,g;nG(o,this.layout.layoutBox,this.relativeParent.layout.layoutBox),p=this.relativeTarget,m=this.relativeTargetOrigin,f=o,g=n,sQ(p.x,m.x,f.x,g),sQ(p.y,m.y,f.y,g),i&&(u=this.relativeTarget,c=i,sE(u.x,c.x)&&sE(u.y,c.y))&&(this.isProjectionDirty=!1),i||(i=td()),sb(i,this.relativeTarget)}l&&(this.animationValues=r,function(e,t,i,n,s,r){s?(e.opacity=D(0,i.opacity??1,sg(n)),e.opacityExit=D(t.opacity??1,0,sv(n))):r&&(e.opacity=D(t.opacity??1,i.opacity??1,n));for(let s=0;s<sc;s++){let r=`border${sd[s]}Radius`,a=sf(t,r),o=sf(i,r);(void 0!==a||void 0!==o)&&(a||(a=0),o||(o=0),0===a||0===o||sm(a)===sm(o)?(e[r]=Math.max(D(sp(a),sp(o),n),0),(Q.test(o)||Q.test(a))&&(e[r]+="%")):e[r]=o)}(t.rotate||i.rotate)&&(e.rotate=D(t.rotate||0,i.rotate||0,n))}(r,s,this.latestValues,n,d,h)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=n},this.mixTargetDelta(1e3*!!this.options.layoutRoot)}startAnimation(e){this.notifyListeners("animationStart"),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&(ex(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=ey.update(()=>{var t,i,n;let s;sn.hasAnimatedSinceResize=!0,iv.layout++,this.motionValue||(this.motionValue=tn(0)),this.currentAnimation=(t=this.motionValue,i=[0,1e3],n={...e,velocity:0,isSync:!0,onUpdate:t=>{this.mixTargetDelta(t),e.onUpdate&&e.onUpdate(t)},onStop:()=>{iv.layout--},onComplete:()=>{iv.layout--,e.onComplete&&e.onComplete(),this.completeAnimation()}},(s=e4(t)?t:tn(t)).start(nk("",s,i,n)),s.animation),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);let e=this.getStack();e&&e.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(1e3),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let e=this.getLead(),{targetWithTransforms:t,target:i,layout:n,latestValues:s}=e;if(t&&i&&n){if(this!==e&&this.layout&&n&&s4(this.options.animationType,this.layout.layoutBox,n.layoutBox)){i=this.target||td();let t=nz(this.layout.layoutBox.x);i.x.min=e.target.x.min,i.x.max=i.x.min+t;let n=nz(this.layout.layoutBox.y);i.y.min=e.target.y.min,i.y.max=i.y.min+n}sb(t,i),W(t,s),nH(this.projectionDeltaWithTransform,this.layoutCorrected,t,s)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new sD),this.sharedNodes.get(e).add(t);let i=t.options.initialPromotionConfig;t.promote({transition:i?i.transition:void 0,preserveFollowOpacity:i&&i.shouldPreserveFollowOpacity?i.shouldPreserveFollowOpacity(t):void 0})}isLead(){let e=this.getStack();return!e||e.lead===this}getLead(){let{layoutId:e}=this.options;return e&&this.getStack()?.lead||this}getPrevLead(){let{layoutId:e}=this.options;return e?this.getStack()?.prevLead:void 0}getStack(){let{layoutId:e}=this.options;if(e)return this.root.sharedNodes.get(e)}promote({needsReset:e,transition:t,preserveFollowOpacity:i}={}){let n=this.getStack();n&&n.promote(this,i),e&&(this.projectionDelta=void 0,this.needsReset=!0),t&&this.setOptions({transition:t})}relegate(){let e=this.getStack();return!!e&&e.relegate(this)}resetSkewAndRotation(){let{visualElement:e}=this.options;if(!e)return;let t=!1,{latestValues:i}=e;if((i.z||i.rotate||i.rotateX||i.rotateY||i.rotateZ||i.skewX||i.skewY)&&(t=!0),!t)return;let n={};i.z&&sO("z",e,n,this.animationValues);for(let t=0;t<sL.length;t++)sO(`rotate${sL[t]}`,e,n,this.animationValues),sO(`skew${sL[t]}`,e,n,this.animationValues);for(let t in e.render(),n)e.setStaticValue(t,n[t]),this.animationValues&&(this.animationValues[t]=n[t]);e.scheduleRender()}applyProjectionStyles(e,t){if(!this.instance||this.isSVG)return;if(!this.isVisible){e.visibility="hidden";return}let i=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,e.visibility="",e.opacity="",e.pointerEvents=t8(t?.pointerEvents)||"",e.transform=i?i(this.latestValues,""):"none";return}let n=this.getLead();if(!this.projectionDelta||!this.layout||!n.target){this.options.layoutId&&(e.opacity=void 0!==this.latestValues.opacity?this.latestValues.opacity:1,e.pointerEvents=t8(t?.pointerEvents)||""),this.hasProjected&&!O(this.latestValues)&&(e.transform=i?i({},""):"none",this.hasProjected=!1);return}e.visibility="";let s=n.animationValues||n.latestValues;this.applyTransformsToTarget();let r=function(e,t,i){let n="",s=e.x.translate/t.x,r=e.y.translate/t.y,a=i?.z||0;if((s||r||a)&&(n=`translate3d(${s}px, ${r}px, ${a}px) `),(1!==t.x||1!==t.y)&&(n+=`scale(${1/t.x}, ${1/t.y}) `),i){let{transformPerspective:e,rotate:t,rotateX:s,rotateY:r,skewX:a,skewY:o}=i;e&&(n=`perspective(${e}px) ${n}`),t&&(n+=`rotate(${t}deg) `),s&&(n+=`rotateX(${s}deg) `),r&&(n+=`rotateY(${r}deg) `),a&&(n+=`skewX(${a}deg) `),o&&(n+=`skewY(${o}deg) `)}let o=e.x.scale*t.x,l=e.y.scale*t.y;return(1!==o||1!==l)&&(n+=`scale(${o}, ${l})`),n||"none"}(this.projectionDeltaWithTransform,this.treeScale,s);i&&(r=i(s,r)),e.transform=r;let{x:a,y:o}=this.projectionDelta;for(let t in e.transformOrigin=`${100*a.origin}% ${100*o.origin}% 0`,n.animationValues?e.opacity=n===this?s.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:s.opacityExit:e.opacity=n===this?void 0!==s.opacity?s.opacity:"":void 0!==s.opacityExit?s.opacityExit:0,tD){if(void 0===s[t])continue;let{correct:i,applyTo:a,isCSSVariable:o}=tD[t],l="none"===r?s[t]:i(s[t],n);if(a){let t=a.length;for(let i=0;i<t;i++)e[a[i]]=l}
19else o?this.options.visualElement.renderState.vars[t]=l:e[t]=l}this.options.layoutId&&(e.pointerEvents=n===this?t8(t?.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(e=>e.currentAnimation?.stop()),this.root.nodes.forEach(sW),this.root.sharedNodes.clear()}}}function sB(e){e.updateLayout()}function s$(e){let t=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){let{layoutBox:i,measuredBox:n}=e.layout,{animationType:s}=e.options,r=t.source!==e.layout.source;"size"===s?nK(e=>{let n=r?t.measuredBox[e]:t.layoutBox[e],s=nz(n);n.min=i[e].min,n.max=n.min+s}):s4(s,t.layoutBox,i)&&nK(n=>{let s=r?t.measuredBox[n]:t.layoutBox[n],a=nz(i[n]);s.max=s.min+a,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[n].max=e.relativeTarget[n].min+a)});let a=tu();nH(a,i,t.layoutBox);let o=tu();r?nH(o,e.applyTransform(n,!0),t.measuredBox):nH(o,i,t.layoutBox);let l=!sC(a),u=!1;if(!e.resumeFrom){let n=e.getClosestProjectingParent();if(n&&!n.resumeFrom){let{snapshot:s,layout:r}=n;if(s&&r){let a=td();nG(a,t.layoutBox,s.layoutBox);let o=td();nG(o,i,r.layoutBox),sN(a,o)||(u=!0),n.options.layoutRoot&&(e.relativeTarget=o,e.relativeTargetOrigin=a,e.relativeParent=n)}}}e.notifyListeners("didUpdate",{layout:i,snapshot:t,delta:o,layoutDelta:a,hasLayoutChanged:l,hasRelativeLayoutChanged:u})}else if(e.isLead()){let{onExitComplete:t}=e.options;t&&t()}e.options.transition=void 0}function s_(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function sU(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function sz(e){e.clearSnapshot()}function sW(e){e.clearMeasurements()}function sH(e){e.isLayoutDirty=!1}function sX(e){let{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function sY(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function sG(e){e.resolveTargetDelta()}function sK(e){e.calcProjection()}function sq(e){e.resetSkewAndRotation()}function sZ(e){e.removeLeadSnapshot()}function sJ(e,t,i){e.translate=D(t.translate,0,i),e.scale=D(t.scale,1,i),e.origin=t.origin,e.originPoint=t.originPoint}function sQ(e,t,i,n){e.min=D(t.min,i.min,n),e.max=D(t.max,i.max,n)}function s0(e){return e.animationValues&&void 0!==e.animationValues.opacityExit}let s1={duration:.45,ease:[.4,0,.1,1]},s2=e=>"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),s3=s2("applewebkit/")&&!s2("chrome/")?Math.round:em;function s5(e){e.min=s3(e.min),e.max=s3(e.max)}function s4(e,t,i){return"position"===e||"preserve-aspect"===e&&!(.2>=Math.abs(sV(t)-sV(i)))}function s6(e){return e!==e.root&&e.scroll?.wasRoot}let s8=sF({attachResizeListener:(e,t)=>nB(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),s9={current:void 0},s7=sF({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!s9.current){let e=new s8({});e.mount(window),e.setOptions({layoutScroll:!0}),s9.current=e}return s9.current},resetTransform:(e,t)=>{e.style.transform=void 0!==t?t:"none"},checkIsScrollRoot:e=>"fixed"===window.getComputedStyle(e).position});function re(e,t,i){if(e instanceof EventTarget)return[e];if("string"==typeof e){let n=document;t&&(n=t.current);let s=i?.[e]??n.querySelectorAll(e);return s?Array.from(s):[]}return Array.from(e)}function rt(e,t){let i=re(e),n=new AbortController;return[i,{passive:!0,...t,signal:n.signal},()=>n.abort()]}function ri(e){return!("touch"===e.pointerType||nF.x||nF.y)}function rn(e,t,i){let{props:n}=e;e.animationState&&n.whileHover&&e.animationState.setActive("whileHover","Start"===i);let s=n["onHover"+i];s&&ey.postRender(()=>s(t,n_(t)))}function rs(e){return so(e)&&"offsetHeight"in e}let rr=(e,t)=>!!t&&(e===t||rr(e,t.parentElement)),ra=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]),ro=new WeakSet;function rl(e){return t=>{"Enter"===t.key&&e(t)}}function ru(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}function rh(e){return n$(e)&&!(nF.x||nF.y)}function rd(e,t,i){let{props:n}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&n.whileTap&&e.animationState.setActive("whileTap","Start"===i);let s=n["onTap"+("End"===i?"":i)];s&&ey.postRender(()=>s(t,n_(t)))}let rc=new WeakMap,rp=new WeakMap,rm=e=>{let t=rc.get(e.target);t&&t(e)},rf=e=>{e.forEach(rm)},rg={some:0,all:1},rv=function(e,t){if("undefined"==typeof Proxy)return io;let i=new Map,n=(i,n)=>io(i,n,e,t);return new Proxy((e,t)=>n(e,t),{get:(s,r)=>"create"===r?n:(i.has(r)||i.set(r,io(r,void 0,e,t)),i.get(r))})}({animation:{Feature:class extends nI{constructor(e){super(e),e.animationState||(e.animationState=function(e){let t=t=>Promise.all(t.map(({animation:t,options:i})=>(function(e,t,i={}){let n;if(e.notify("AnimationStart",t),Array.isArray(t))n=Promise.all(t.map(t=>nE(e,t,i)));else if("string"==typeof t)n=nE(e,t,i);else{let s="function"==typeof t?il(e,t,i.custom):t;
19n=Promise.all(nA(e,s,i))}return n.then(()=>{e.notify("AnimationComplete",t)})})(e,t,i))),i=nL(),n=!0,s=t=>(i,n)=>{let s=il(e,n,"exit"===t?e.presenceContext?.custom:void 0);if(s){let{transition:e,transitionEnd:t,...n}=s;i={...i,...n,...t}}return i};function r(r){let{props:a}=e,o=function e(t){if(!t)return;if(!t.isControllingVariants){let i=t.parent&&e(t.parent)||{};return void 0!==t.props.initial&&(i.initial=t.props.initial),i}let i={};for(let e=0;e<nN;e++){let n=tx[e],s=t.props[n];(tv(s)||!1===s)&&(i[n]=s)}return i}(e.parent)||{},l=[],u=new Set,h={},d=1/0;for(let t=0;t<nR;t++){var c,p;let m=nV[t],f=i[m],g=void 0!==a[m]?a[m]:o[m],v=tv(g),y=m===r?f.isActive:null;!1===y&&(d=t);let x=g===o[m]&&g!==a[m]&&v;if(x&&n&&e.manuallyAnimateOnMount&&(x=!1),f.protectedKeys={...h},!f.isActive&&null===y||!g&&!f.prevProp||tg(g)||"boolean"==typeof g)continue;let b=(c=f.prevProp,"string"==typeof(p=g)?p!==c:!!Array.isArray(p)&&!nM(p,c)),w=b||m===r&&f.isActive&&!x&&v||t>d&&v,j=!1,T=Array.isArray(g)?g:[g],S=T.reduce(s(m),{});!1===y&&(S={});let{prevResolvedValues:P={}}=f,k={...P,...S},A=t=>{w=!0,u.has(t)&&(j=!0,u.delete(t)),f.needsAnimating[t]=!0;let i=e.getValue(t);i&&(i.liveStyle=!1)};for(let e in k){let t=S[e],i=P[e];if(!h.hasOwnProperty(e))(ih(t)&&ih(i)?nM(t,i):t===i)?void 0!==t&&u.has(e)?A(e):f.protectedKeys[e]=!0:null!=t?A(e):u.add(e)}f.prevProp=g,f.prevResolvedValues=S,f.isActive&&(h={...h,...S}),n&&e.blockInitialAnimation&&(w=!1);let C=x&&b,E=!C||j;w&&E&&l.push(...T.map(t=>{let i={type:m};if("string"==typeof t&&n&&!C&&e.manuallyAnimateOnMount&&e.parent){let{parent:n}=e,s=il(n,t);if(n.enteringChildren&&s){let{delayChildren:t}=s.transition||{};i.delay=nC(n.enteringChildren,e,t)}}return{animation:t,options:i}}))}if(u.size){let t={};if("boolean"!=typeof a.initial){let i=il(e,Array.isArray(a.initial)?a.initial[0]:a.initial);i&&i.transition&&(t.transition=i.transition)}u.forEach(i=>{let n=e.getBaseTarget(i),s=e.getValue(i);s&&(s.liveStyle=!0),t[i]=n??null}),l.push({animation:t})}let m=!!l.length;return n&&(!1===a.initial||a.initial===a.animate)&&!e.manuallyAnimateOnMount&&(m=!1),n=!1,m?t(l):Promise.resolve()}return{animateChanges:r,setActive:function(t,n){if(i[t].isActive===n)return Promise.resolve();e.variantChildren?.forEach(e=>e.animationState?.setActive(t,n)),i[t].isActive=n;let s=r(t);for(let e in i)i[e].protectedKeys={};return s},setAnimateFunction:function(i){t=i(e)},getState:()=>i,reset:()=>{i=nL()}}}(e))}updateAnimationControlsSubscription(){let{animate:e}=this.node.getProps();tg(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){let{animate:e}=this.node.getProps(),{animate:t}=this.node.prevProps||{};e!==t&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}}},exit:{Feature:class extends nI{constructor(){super(...arguments),this.id=nO++}update(){if(!this.node.presenceContext)return;let{isPresent:e,onExitComplete:t}=this.node.presenceContext,{isPresent:i}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===i)return;let n=this.node.animationState.setActive("exit",!e);t&&!e&&n.then(()=>{t(this.id)})}mount(){let{register:e,onExitComplete:t}=this.node.presenceContext||{};t&&t(this.id),e&&(this.unmount=e(this.id))}unmount(){}}},inView:{Feature:class extends nI{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){var e;let t;this.unmount();let{viewport:i={}}=this.node.getProps(),{root:n,margin:s,amount:r="some",once:a}=i,o={root:n?n.current:void 0,rootMargin:s,threshold:"number"==typeof r?r:rg[r]},l=e=>{let{isIntersecting:t}=e;if(this.isInView===t||(this.isInView=t,a&&!t&&this.hasEnteredView))return;t&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",t);let{onViewportEnter:i,onViewportLeave:n}=this.node.getProps(),s=t?i:n;s&&s(e)};return e=this.node.current,t=function({root:e,...t}){let i=e||document;rp.has(i)||rp.set(i,{});let n=rp.get(i),s=JSON.stringify(t);return n[s]||(n[s]=new IntersectionObserver(rf,{root:e,...t})),n[s]}(o),rc.set(e,l),t.observe(e),()=>{rc.delete(e),t.unobserve(e)}}mount(){this.startObserver()}update(){if("undefined"==typeof IntersectionObserver)return;let{props:e,prevProps:t}=this.node;["amount","margin","root"].some(function({viewport:e={}},{viewport:t={}}={}){return i=>e[i]!==t[i]}(e,t))&&this.startObserver()}unmount(){}}},tap:{Feature:class extends nI{mount(){let{current:e}=this.node;e&&(this.unmount=function(e,t,i={}){let[n,s,r]=rt(e,i),a=e=>{let n=e.currentTarget;if(!rh(e))return;ro.add(n);let r=t(n,e),a=(e,t)=>{window.removeEventListener("pointerup",o),window.removeEventListener("pointercancel",l),ro.has(n)&&ro.delete(n),rh(e)&&"function"==typeof r&&r(e,{success:t})},o=e=>{a(e,n===window||n===document||i.useGlobalTarget||rr(n,e.target))},l=e=>{a(e,!1)};window.addEventListener("pointerup",o,s),window.addEventListener("pointercancel",l,s)};
19return n.forEach(e=>{((i.useGlobalTarget?window:e).addEventListener("pointerdown",a,s),rs(e))&&(e.addEventListener("focus",e=>((e,t)=>{let i=e.currentTarget;if(!i)return;let n=rl(()=>{if(ro.has(i))return;ru(i,"down");let e=rl(()=>{ru(i,"up")});i.addEventListener("keyup",e,t),i.addEventListener("blur",()=>ru(i,"cancel"),t)});i.addEventListener("keydown",n,t),i.addEventListener("blur",()=>i.removeEventListener("keydown",n),t)})(e,s)),ra.has(e.tagName)||-1!==e.tabIndex||e.hasAttribute("tabindex")||(e.tabIndex=0))}),r}(e,(e,t)=>(rd(this.node,t,"Start"),(e,{success:t})=>rd(this.node,e,t?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}},focus:{Feature:class extends nI{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch(t){e=!0}e&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){this.isActive&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=im(nB(this.node.current,"focus",()=>this.onFocus()),nB(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}},hover:{Feature:class extends nI{mount(){let{current:e}=this.node;e&&(this.unmount=function(e,t,i={}){let[n,s,r]=rt(e,i),a=e=>{if(!ri(e))return;let{target:i}=e,n=t(i,e);if("function"!=typeof n||!i)return;let r=e=>{ri(e)&&(n(e),i.removeEventListener("pointerleave",r))};i.addEventListener("pointerleave",r,s)};return n.forEach(e=>{e.addEventListener("pointerenter",a,s)}),r}(e,(e,t)=>(rn(this.node,t,"Start"),e=>rn(this.node,e,"End"))))}unmount(){}}},pan:{Feature:class extends nI{constructor(){super(...arguments),this.removePointerDownListener=em}onPointerDown(e){this.session=new nJ(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:nq(this.node)})}createPanHandlers(){let{onPanSessionStart:e,onPanStart:t,onPan:i,onPanEnd:n}=this.node.getProps();return{onSessionStart:se(e),onStart:se(t),onMove:i,onEnd:(e,t)=>{delete this.session,n&&ey.postRender(()=>n(e,t))}}}mount(){this.removePointerDownListener=nU(this.node.current,"pointerdown",e=>this.onPointerDown(e))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}},drag:{Feature:class extends nI{constructor(e){super(e),this.removeGroupControls=em,this.removeListeners=em,this.controls=new n9(e)}mount(){let{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||em}unmount(){this.removeGroupControls(),this.removeListeners()}},ProjectionNode:s7,MeasureLayout:sa},layout:{ProjectionNode:s7,MeasureLayout:sa}},(e,t)=>tY(e)?new tH(t):new tO(t,{allowProjection:e!==d.Fragment}));var ry=e.i(80064);function rx({children:e,ref:t,...i}){var n;let r,a="object"==typeof e.type&&null!==e.type&&null!==(n=e.type)&&"object"==typeof n&&it in n,o=d.useMemo(()=>a?e.type:rv.create(e.type),[a,e.type]);if(!d.isValidElement(e))return null;let{ref:l,...u}=e.props,h=(r={...u,...i},(u.className||i.className)&&(r.className=(0,ry.cn)(u.className,i.className)),(u.style||i.style)&&(r.style={...u.style,...i.style}),r);return(0,s.jsx)(o,{...h,ref:function(...e){return t=>{e.forEach(e=>{e&&("function"==typeof e?e(t):e.current=t)})}}(l,t)})}function rb({hoverScale:e=1.05,tapScale:t=.95,asChild:i=!1,...n}){let r=i?rx:rv.button;return(0,s.jsx)(r,{whileTap:{scale:t},whileHover:{scale:e},...n})}let rw={some:0,all:1};function rj(e,t={}){let{inView:i,inViewOnce:n=!1,inViewMargin:s="0px"}=t,r=d.useRef(null);d.useImperativeHandle(e,()=>r.current);let a=function(e,{root:t,margin:i,amount:n,once:s=!1,initial:r=!1}={}){let[a,o]=(0,d.useState)(r);return(0,d.useEffect)(()=>{if(!e.current||s&&a)return;let r={root:t&&t.current||void 0,margin:i,amount:n};return function(e,t,{root:i,margin:n,amount:s="some"}={}){let r=re(e),a=new WeakMap,o=new IntersectionObserver(e=>{e.forEach(e=>{let i=a.get(e.target);if(!!i!==e.isIntersecting)if(e.isIntersecting){let i=t(e.target,e);
19"function"==typeof i?a.set(e.target,i):o.unobserve(e.target)}else"function"==typeof i&&(i(e),a.delete(e.target))})},{root:i,rootMargin:n,threshold:"number"==typeof s?s:rw[s]});return r.forEach(e=>o.observe(e)),()=>o.disconnect()}(e.current,()=>(o(!0),s?void 0:()=>o(!1)),r)},[t,e,i,s,n]),a}(r,{once:n,margin:s});return{ref:r,isInView:!i||a}}function rT(e){let t=d.createContext(void 0);return[({value:e,children:i})=>(0,s.jsx)(t.Provider,{value:e,children:i}),()=>{let i=d.useContext(t);if(void 0===i)throw Error(`useContext must be used within ${e??"a Provider"}`);return i}]}function rS(e){return"number"==typeof e?e:parseFloat(e)}function rP(e){let t=t6(()=>tn(e)),{isStatic:i}=(0,d.useContext)(tq);if(i){let[,i]=(0,d.useState)(e);(0,d.useEffect)(()=>t.on("change",i),[])}return t}function rk(e,t){let i=rP(t()),n=()=>i.set(t());return n(),ia(()=>{let t=()=>ey.preRender(n,!1,!0),i=e.map(e=>e.on("change",t));return()=>{i.forEach(e=>e()),ex(n)}}),i}function rA(e,t,i,n){if("function"==typeof e){let t;return tt.current=[],e(),t=rk(tt.current,e),tt.current=void 0,t}let s="function"==typeof t?t:function(...e){let t=!Array.isArray(e[0]),i=t?0:-1,n=e[0+i],s=i7(e[1+i],e[2+i],e[3+i]);return t?s(n):s}(t,i,n);return Array.isArray(e)?rC(e,s):rC([e],([e])=>s(e))}function rC(e,t){let i=t6(()=>[]);return rk(e,()=>{i.length=0;let n=e.length;for(let t=0;t<n;t++)i[t]=e[t].get();return t(i)})}function rE(e,t={}){let{isStatic:i}=(0,d.useContext)(tq),n=()=>e4(e)?e.get():e;if(i)return rA(n);let s=rP(n());return(0,d.useInsertionEffect)(()=>(function(e,t,i){let n,s=e.get(),r=null,a=s,o="string"==typeof s?s.replace(/[\d.-]/g,""):void 0,l=()=>{r&&(r.stop(),r=null)},u=()=>{l(),r=new no({keyframes:[rS(e.get()),rS(a)],velocity:e.getVelocity(),type:"spring",restDelta:.001,restSpeed:.01,...i,onUpdate:n})};if(e.attach((e,t)=>{a=e,n=e=>{var i,n;return t((i=e,(n=o)?i+n:i))},ey.postRender(u)},l),e4(t)){let i=t.on("change",t=>{var i,n;return e.set((i=t,(n=o)?i+n:i))}),n=e.on("destroy",i);return()=>{i(),n()}}return l})(s,e,t),[s,JSON.stringify(t)]),s}function rM(e,t){let i;return(...n)=>{window.clearTimeout(i),i=window.setTimeout(()=>e(...n),t)}}let rN=["x","y","top","bottom","left","right","width","height"];function rV({prevValue:e,value:t,place:i,transition:n,delay:r=0}){let a=Math.floor(e/i)%10,o=Math.floor(t/i)%10,l=rE(a,n);d.useEffect(()=>{let e=setTimeout(()=>{l.set(o)},r);return()=>clearTimeout(e)},[o,l,r]);let[u,{height:h}]=function({debounce:e,scroll:t,polyfill:i,offsetSize:n}={debounce:0,scroll:!1,offsetSize:!1}){var s,r,a;let o=i||("undefined"==typeof window?class{}:window.ResizeObserver);if(!o)throw Error("This browser does not support ResizeObserver out of the box. See: https://github.com/react-spring/react-use-measure/#resize-observer-polyfills");let[l,u]=(0,d.useState)({left:0,top:0,width:0,height:0,bottom:0,right:0,x:0,y:0}),h=(0,d.useRef)({element:null,scrollContainers:null,resizeObserver:null,lastBounds:l,orientationHandler:null}),c=e?"number"==typeof e?e:e.scroll:null,p=e?"number"==typeof e?e:e.resize:null,m=(0,d.useRef)(!1);(0,d.useEffect)(()=>(m.current=!0,()=>void(m.current=!1)));let[f,g,v]=(0,d.useMemo)(()=>{let e=()=>{let e,t;if(!h.current.element)return;let{left:i,top:s,width:r,height:a,bottom:o,right:l,x:d,y:c}=h.current.element.getBoundingClientRect(),p={left:i,top:s,width:r,height:a,bottom:o,right:l,x:d,y:c};h.current.element instanceof HTMLElement&&n&&(p.height=h.current.element.offsetHeight,p.width=h.current.element.offsetWidth),Object.freeze(p),m.current&&(e=h.current.lastBounds,t=p,!rN.every(i=>e[i]===t[i]))&&u(h.current.lastBounds=p)};return[e,p?rM(e,p):e,c?rM(e,c):e]},[u,n,c,p]);function y(){h.current.scrollContainers&&(h.current.scrollContainers.forEach(e=>e.removeEventListener("scroll",v,!0)),h.current.scrollContainers=null),h.current.resizeObserver&&(h.current.resizeObserver.disconnect(),h.current.resizeObserver=null),h.current.orientationHandler&&("orientation"in screen&&"removeEventListener"in screen.orientation?screen.orientation.removeEventListener("change",h.current.orientationHandler):"onorientationchange"in window&&window.removeEventListener("orientationchange",h.current.orientationHandler))}function x(){h.current.element&&(h.current.resizeObserver=new o(v),h.current.resizeObserver.observe(h.current.element),t&&h.current.scrollC
19ontainers&&h.current.scrollContainers.forEach(e=>e.addEventListener("scroll",v,{capture:!0,passive:!0})),h.current.orientationHandler=()=>{v()},"orientation"in screen&&"addEventListener"in screen.orientation?screen.orientation.addEventListener("change",h.current.orientationHandler):"onorientationchange"in window&&window.addEventListener("orientationchange",h.current.orientationHandler))}return s=v,r=!!t,(0,d.useEffect)(()=>{if(r)return window.addEventListener("scroll",s,{capture:!0,passive:!0}),()=>void window.removeEventListener("scroll",s,!0)},[s,r]),a=g,(0,d.useEffect)(()=>(window.addEventListener("resize",a),()=>void window.removeEventListener("resize",a)),[a]),(0,d.useEffect)(()=>{y(),x()},[t,v,g]),(0,d.useEffect)(()=>y,[]),[e=>{e&&e!==h.current.element&&(y(),h.current.element=e,h.current.scrollContainers=function e(t){let i=[];if(!t||t===document.body)return i;let{overflow:n,overflowX:s,overflowY:r}=window.getComputedStyle(t);return[n,s,r].some(e=>"auto"===e||"scroll"===e)&&i.push(t),[...i,...e(t.parentElement)]}(e),x())},l,f]}();return(0,s.jsxs)("span",{ref:u,"data-slot":"sliding-number-roller",style:{position:"relative",display:"inline-block",width:"1ch",overflowX:"visible",overflowY:"clip",lineHeight:1,fontVariantNumeric:"tabular-nums"},children:[(0,s.jsx)("span",{style:{visibility:"hidden"},children:"0"}),Array.from({length:10},(e,t)=>(0,s.jsx)(rR,{motionValue:l,number:t,height:h,transition:n},t))]})}function rR({motionValue:e,number:t,height:i,transition:n}){let r=rA(e,e=>{if(!i)return 0;let n=(10+t-e%10)%10,s=n*i;return n>5&&(s-=10*i),s});return i?(0,s.jsx)(rv.span,{"data-slot":"sliding-number-display",style:{y:r,position:"absolute",inset:0,display:"flex",alignItems:"center",justifyContent:"center"},transition:{...n,type:"spring"},children:t}):(0,s.jsx)("span",{style:{visibility:"hidden",position:"absolute"},children:t})}function rD({ref:e,number:t,fromNumber:i,onNumberChange:n,inView:r=!1,inViewMargin:a="0px",inViewOnce:o=!0,padStart:l=!1,decimalSeparator:u=".",decimalPlaces:h=0,thousandSeparator:c,transition:p={stiffness:200,damping:20,mass:.4},delay:m=0,...f}){let{ref:g,isInView:v}=rj(e,{inView:r,inViewOnce:o,inViewMargin:a}),y=d.useRef(0),x=void 0!==i,b=rP(i??0),w=rE(b,{stiffness:90,damping:50});d.useEffect(()=>{if(!x)return;let e=setTimeout(()=>{v&&b.set(t)},m);return()=>clearTimeout(e)},[x,v,t,b,m]);let[j,T]=d.useState(0);d.useEffect(()=>{if(x){let e,i,s="number"==typeof h&&h>=0?h:(i=(e=String(t)).indexOf("."))>=0?e.length-i-1:0,r=Math.pow(10,s),a=w.on("change",e=>{let t=s>0?Math.round(e*r)/r:Math.round(e);j!==t&&(T(t),n?.(t))});return()=>a()}T(v?Math.abs(Number(t)):0)},[x,w,v,t,h,n,j]);let S=d.useCallback(e=>null!=h?e.toFixed(h):e.toString(),[h]),[P,k=""]=S(j).split("."),A=l?Math.max(Math.floor(Math.abs(t)).toString().length,P.length):P.length,C=l?P.padStart(A,"0"):P,[E="",M=""]=S(y.current).split("."),N=l?E.padStart(A,"0"):E,V=d.useMemo(()=>N.length>A?N.slice(-A):N.padStart(A,"0"),[N,A]),R=d.useMemo(()=>k?M.length>k.length?M.slice(0,k.length):M.padEnd(k.length,"0"):"",[M,k]);d.useEffect(()=>{v&&(y.current=j)},[j,v]);let D=d.useMemo(()=>Array.from({length:A},(e,t)=>Math.pow(10,A-t-1)),[A]),L=d.useMemo(()=>k?Array.from({length:k.length},(e,t)=>Math.pow(10,k.length-t-1)):[],[k]),I=k?parseInt(k,10):0,O=R?parseInt(R,10):0;return(0,s.jsxs)("span",{ref:g,"data-slot":"sliding-number",style:{display:"inline-flex",alignItems:"center"},...f,children:[v&&0>Number(t)&&(0,s.jsx)("span",{style:{marginRight:"0.25rem"},children:"-"}),D.map((e,t)=>{let i=D.length-t-1;return(0,s.jsxs)(d.Fragment,{children:[(0,s.jsx)(rV,{prevValue:parseInt(V,10),value:parseInt(C??"0",10),place:e,transition:p}),void 0!==c&&i>0&&i%3==0&&(0,s.jsx)("span",{children:c})]},`int-${e}`)}),k&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("span",{children:u}),L.map(e=>(0,s.jsx)(rV,{prevValue:O,value:I,place:e,transition:p,delay:m},`dec-${e}`))]})]})}var rL=d;function rI(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}class rO extends rL.Component{getSnapshotBeforeUpdate(e){let t=this.props.childRef.current;
19if(t&&e.isPresent&&!this.props.isPresent){let e=t.offsetParent,i=rs(e)&&e.offsetWidth||0,n=this.props.sizeRef.current;n.height=t.offsetHeight||0,n.width=t.offsetWidth||0,n.top=t.offsetTop,n.left=t.offsetLeft,n.right=i-n.width-n.left}return null}componentDidUpdate(){}render(){return this.props.children}}function rF({children:e,isPresent:t,anchorX:i,root:n}){let r=(0,rL.useId)(),a=(0,rL.useRef)(null),o=(0,rL.useRef)({width:0,height:0,top:0,left:0,right:0}),{nonce:l}=(0,rL.useContext)(tq),u=function(...e){return d.useCallback(function(...e){return t=>{let i=!1,n=e.map(e=>{let n=rI(e,t);return i||"function"!=typeof n||(i=!0),n});if(i)return()=>{for(let t=0;t<n.length;t++){let i=n[t];"function"==typeof i?i():rI(e[t],null)}}}}(...e),e)}(a,e?.ref);return(0,rL.useInsertionEffect)(()=>{let{width:e,height:s,top:u,left:h,right:d}=o.current;if(t||!a.current||!e||!s)return;let c="left"===i?`left: ${h}`:`right: ${d}`;a.current.dataset.motionPopId=r;let p=document.createElement("style");l&&(p.nonce=l);let m=n??document.head;return m.appendChild(p),p.sheet&&p.sheet.insertRule(`
20          [data-motion-pop-id="${r}"] {
21            position: absolute !important;
22            width: ${e}px !important;
23            height: ${s}px !important;
24            ${c}px !important;
25            top: ${u}px !important;
26          }
27        `),()=>{m.contains(p)&&m.removeChild(p)}},[t]),(0,s.jsx)(rO,{isPresent:t,childRef:a,sizeRef:o,children:rL.cloneElement(e,{ref:u})})}let rB=({children:e,initial:t,isPresent:i,onExitComplete:n,custom:r,presenceAffectsLayout:a,mode:o,anchorX:l,root:u})=>{let h=t6(r$),c=(0,d.useId)(),p=!0,m=(0,d.useMemo)(()=>(p=!1,{id:c,initial:t,isPresent:i,custom:r,onExitComplete:e=>{for(let t of(h.set(e,!0),h.values()))if(!t)return;n&&n()},register:e=>(h.set(e,!1),()=>h.delete(e))}),[i,h,n]);return a&&p&&(m={...m}),(0,d.useMemo)(()=>{h.forEach((e,t)=>h.set(t,!1))},[i]),d.useEffect(()=>{i||h.size||!n||n()},[i]),"popLayout"===o&&(e=(0,s.jsx)(rF,{isPresent:i,anchorX:l,root:u,children:e})),(0,s.jsx)(t4.Provider,{value:m,children:e})};function r$(){return new Map}let r_=e=>e.key||"";function rU(e){let t=[];return d.Children.forEach(e,e=>{(0,d.isValidElement)(e)&&t.push(e)}),t}let rz=({children:e,custom:t,initial:i=!0,onExitComplete:n,presenceAffectsLayout:r=!0,mode:a="sync",propagate:o=!1,anchorX:l="left",root:u})=>{let[h,c]=si(o),p=(0,d.useMemo)(()=>rU(e),[e]),m=o&&!h?[]:p.map(r_),f=(0,d.useRef)(!0),g=(0,d.useRef)(p),v=t6(()=>new Map),[y,x]=(0,d.useState)(p),[b,w]=(0,d.useState)(p);ia(()=>{f.current=!1,g.current=p;for(let e=0;e<b.length;e++){let t=r_(b[e]);m.includes(t)?v.delete(t):!0!==v.get(t)&&v.set(t,!1)}},[b,m.length,m.join("-")]);let j=[];if(p!==y){let e=[...p];for(let t=0;t<b.length;t++){let i=b[t],n=r_(i);m.includes(n)||(e.splice(t,0,i),j.push(i))}return"wait"===a&&j.length&&(e=j),w(rU(e)),x(p),null}let{forceRender:T}=(0,d.useContext)(tG);return(0,s.jsx)(s.Fragment,{children:b.map(e=>{let d=r_(e),y=(!o||!!h)&&(p===b||m.includes(d));return(0,s.jsx)(rB,{isPresent:y,initial:(!f.current||!!i)&&void 0,custom:t,presenceAffectsLayout:r,mode:a,root:u,onExitComplete:y?void 0:()=>{if(!v.has(d))return;v.set(d,!0);let e=!0;v.forEach(t=>{t||(e=!1)}),e&&(T?.(),w(g.current),o&&c?.(),n&&n())},anchorX:l,children:e},d)})})},[rW,rH]=rT("ParticlesContext");function rX({ref:e,animate:t=!0,asChild:i=!1,inView:n=!1,inViewMargin:r="0px",inViewOnce:a=!0,children:o,style:l,...u}){let{ref:h,isInView:d}=rj(e,{inView:n,inViewOnce:a,inViewMargin:r}),c=i?rx:rv.div;return(0,s.jsx)(rW,{value:{animate:t,isInView:d},children:(0,s.jsx)(c,{ref:h,style:{position:"relative",...l},...u,children:o})})}function rY({side:e="top",align:t="center",count:i=6,radius:n=30,spread:r=360,duration:a=.8,holdDelay:o=.05,sideOffset:l=0,alignOffset:u=0,delay:h=0,transition:d,style:c,...p}){let{animate:m,isInView:f}=rH(),g="top"===e||"bottom"===e,v="start"===t?"0%":"end"===t?"100%":"50%",y={position:"absolute",top:g?"top"===e?`calc(0% - ${l}px)`:`calc(100% + ${l}px)`:`calc(${v} + ${u}px)`,left:g?`calc(${v} + ${u}px)`:"left"===e?`calc(0% - ${l}px)`:`calc(100% + ${l}px)`,transform:"translate(-50%, -50%)"},x=Math.PI/180*r/Math.max(1,i-1);return(0,s.jsx)(rz,{children:m&&f&&[...Array(i)].map((e,t)=>{let i=t*x,r=Math.cos(i)*n,l=Math.sin(i)*n;return(0,s.jsx)(rv.div,{style:{...y,...c},initial:{scale:0,opacity:0}
27,animate:{x:`${r}px`,y:`${l}px`,scale:[0,1,0],opacity:[0,1,0]},transition:{duration:a,delay:h+t*o,ease:"easeOut",...d},...p},t)})})}let[rG,rK]=rT("GithubStarsContext");function rq({ref:e,children:t,username:i,repo:n,value:r,delay:a=0,inView:o=!1,inViewMargin:l="0px",inViewOnce:u=!0,asChild:h=!1,...c}){let{ref:p,isInView:m}=rj(e,{inView:o,inViewOnce:u,inViewMargin:l}),[f,g]=d.useState(r??0),[v,y]=d.useState(0),[x,b]=d.useState(!0),w=d.useMemo(()=>v===f,[v,f]),j=h?rx:rv.div;return d.useEffect(()=>{if(void 0!==r&&i&&n)return;if(!m){g(0),b(!0);return}let e=setTimeout(()=>{fetch(`https://api.github.com/repos/${i}/${n}`).then(e=>e.json()).then(e=>{e&&"number"==typeof e.stargazers_count&&g(e.stargazers_count)}).catch(console.error).finally(()=>b(!1))},a);return()=>clearTimeout(e)},[i,n,r,m,a]),(0,s.jsx)(rG,{value:{stars:f,currentStars:v,isCompleted:w,isLoading:x,setStars:g,setCurrentStars:y},children:!x&&(0,s.jsx)(j,{ref:p,...c,children:t})})}function rZ({padStart:e=!0,...t}){let{stars:i,setCurrentStars:n}=rK();return(0,s.jsx)(rD,{number:i,fromNumber:0,onNumberChange:n,padStart:e,...t})}function rJ({icon:e,color:t="currentColor",activeClassName:i,className:n,...r}){let{stars:a,currentStars:o,isCompleted:l}=rK(),u=o/a*100;return(0,s.jsxs)("div",{style:{position:"relative"},children:[(0,s.jsx)(e,{"aria-hidden":"true",className:(0,ry.cn)(n),...r}),(0,s.jsx)(e,{"aria-hidden":"true",style:{position:"absolute",top:0,left:0,fill:t,stroke:t,clipPath:`inset(${100-(l?u:u-10)}% 0 0 0)`},className:(0,ry.cn)(n,i),...r})]})}function rQ({children:e,size:t=4,style:i,...n}){let{isCompleted:r}=rK();return(0,s.jsxs)(rX,{animate:r,children:[e,(0,s.jsx)(rY,{style:{backgroundColor:"currentcolor",borderRadius:"50%",width:t,height:t,...i},...n})]})}function r0(e){return(0,s.jsx)("svg",{role:"img",viewBox:"0 0 24 24",fill:"currentColor","aria-label":"GitHub",...e,children:(0,s.jsx)("path",{d:"M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12"})})}let r1=(0,m.cva)("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-[box-shadow,_color,_background-color,_border-color,_outline-color,_text-decoration-color,_fill,_stroke] disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",{variants:{variant:{default:"bg-primary text-primary-foreground shadow-xs hover:bg-primary/90",accent:"bg-accent text-accent-foreground shadow-xs hover:bg-accent/90",outline:"border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",ghost:"hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50"},size:{default:"h-9 px-4 py-2 has-[>svg]:px-3",sm:"h-8 rounded-md gap-1.5 px-3 has-[>svg]:px-2.5",lg:"h-10 rounded-md px-6 has-[>svg]:px-4"}},defaultVariants:{variant:"default",size:"default"}}),r2=(0,m.cva)("",{variants:{variant:{default:"fill-neutral-700 stroke-neutral-700 dark:fill-neutral-300 dark:stroke-neutral-300",accent:"fill-neutral-300 stroke-neutral-300 dark:fill-neutral-700 dark:stroke-neutral-700",outline:"fill-neutral-300 stroke-neutral-300 dark:fill-neutral-700 dark:stroke-neutral-700",ghost:"fill-neutral-300 stroke-neutral-300 dark:fill-neutral-700 dark:stroke-neutral-700"}},defaultVariants:{variant:"default"}});function r3({className:e,username:t,repo:i,value:n,delay:r,inView:a,inViewMargin:o,inViewOnce:l,variant:u,size:h,...d}){return(0,s.jsx)(rq,{asChild:!0,username:t,repo:i,value:n,delay:r,inView:a,inViewMargin:o,inViewOnce:l,children:(0,s.jsxs)(rb,{className:(0,ry.cn)(r1({variant:u,size:h,className:e})),...d,children:[(0,s.jsx)(r0,{}),(0,s.jsx)(rZ,{}),(0,s.jsx)(rQ,{className:"text-yellow-500",children:(0,s.jsx)(rJ,{icon:f.default,"data-variant":u,className:(0,ry.cn)(r2({variant:u})),activeClassName:"text-yellow-500",size:18})})]})})}function r5(){return(0,s.jsx)(r3,{variant:"outline",username:"dr5hn",repo:"countries-states-cities-database"})}var r4=e.i(81254),r6=e.i(20267),r8=e.i(49973);function r9({className:e=""}){let{countries:t,states:i,cities:n}=(0,r8.usePlatformStats)(),r=`${t.value}+`,a=`${i.value}${i.suffix}`,o=`${n.value}${n.suffix}`;return(0,s.jsxs)("span",{className:e,children:[r," countries, ",a," states and ",o," cities"]})}var r7=e.i(43699),ae=e.i(38514);function at(){let e=(0,r7.useInboundAttribution)(),t=(0,ae.withAttribution)("https://app.countrystatecity.in?utm_source=website&utm_medium=cta&utm_content=hero_signup",e);return(0,s.jsxs)("section",{className:"relative overflow-hidden bg-gradient-to-br from-white via-light/30 to-blue/5","aria-labelledby":"hero-heading",children:[(0,s.jsxs)("div",{className:"absolute inset-0 overflow-hidden",children:[(0,s.jsx)("div",{className:"absolute -top-40 -right-40 w-80 h-80 bg-blue/5 rounded-full blur-3xl"}),(0,s.jsx)("div",{className:"absolute -bottom-40 -left-40 w-80 h-80 bg-green/5 rounded-full blur-3xl"})]}),(0,s.jsx)("div",{className:"relative container mx-auto px-4 py-10 lg:py-20",children:(0,s.jsxs)("div",{className:"w-full grid grid-cols-1 lg:grid-cols-2 gap-4 md:gap-12 lg:gap-16 items-center",children:[(0,s.jsxs)("div",{className:"text-center lg:text-left",children:[(0,s.jsxs)("div",{className:"inline-flex items-center px-4 py-2 rounded-full bg-blue/10 border border-blue/20 text-blue text-sm font-medium mb-8",children:[(0,s.jsx)("span",{className:"w-2 h-2 bg-blue rounded-full mr-2 animate-pulse"}),"Trusted by ",r4.TEXT_STATS.developers," developers worldwide"]}),(0,s.jsxs)("h1",{id:"hero-heading",className:"text-3xl md:text-4xl lg:text-5xl font-bold mb-6 leading-tight",children:["Country State City API -"," ",(0,s.jsx)("span",{className:"bg-gradient-to-r from-blue to-green bg-clip-text text-transparent",children:"The World's Most Comprehensive"})," ","Geographic Database for Developers"]}
27),(0,s.jsxs)("p",{className:"text-xl text-darkgray mb-8 leading-relaxed max-w-2xl lg:max-w-none",children:["Build location-aware applications with accurate data from ",(0,s.jsx)("strong",{children:(0,s.jsx)(r9,{})}),". Trusted by ",r4.TEXT_STATS.developers," developers worldwide with ",(0,s.jsxs)("strong",{children:[(0,s.jsx)(r6.default,{})," total API requests"]})," and ",r4.TEXT_STATS.uptime," uptime guarantee."]}),(0,s.jsxs)("div",{className:"flex flex-col sm:flex-row sm:flex-wrap gap-4 justify-center lg:justify-start",children:[(0,s.jsx)(r.Button,{asChild:!0,className:"bg-blue hover:bg-blue/90 text-white font-semibold shadow-lg hover:shadow-xl transition-all duration-300 transform hover:-translate-y-0.5 px-8 py-4 text-lg cursor-pointer","aria-label":"Get started with CSC Database for free",children:(0,s.jsxs)("a",{href:t,target:"_blank",rel:"noopener noreferrer",children:[(0,s.jsx)(l.Rocket,{className:"w-5 h-5 mr-2","aria-hidden":"true"}),"Get Started for Free"]})}),(0,s.jsx)(r.Button,{asChild:!0,variant:"outline",className:"border-blue/30 text-blue hover:bg-blue/5 font-semibold px-8 py-4 text-lg",children:(0,s.jsxs)("a",{href:"https://docs.countrystatecity.in/",target:"_blank",rel:"noopener noreferrer",children:[(0,s.jsx)(a.BookOpen,{className:"w-5 h-5 mr-2","aria-hidden":"true"}),"Read the Docs"]})}),(0,s.jsx)(r5,{})]}),(0,s.jsxs)("div",{className:"mt-10 flex flex-wrap gap-x-8 gap-y-4 justify-center lg:justify-start",children:[(0,s.jsxs)("div",{className:"flex items-center gap-2 text-darkgray",children:[(0,s.jsx)(u.Shield,{className:"h-5 w-5 text-success"}),(0,s.jsxs)("span",{className:"font-semibold text-sm",children:[r4.TEXT_STATS.uptime," Uptime SLA"]})]}),(0,s.jsxs)("div",{className:"flex items-center gap-2 text-darkgray",children:[(0,s.jsx)(h.Star,{className:"h-5 w-5 text-orange"}),(0,s.jsx)("span",{className:"font-semibold text-sm",children:"4.9/5 Developer Rating"})]}),(0,s.jsxs)("div",{className:"flex items-center gap-2 text-darkgray",children:[(0,s.jsx)(o.Clock,{className:"h-5 w-5 text-blue"}),(0,s.jsx)("span",{className:"font-semibold text-sm",children:"Sub-200ms Response"})]})]})]}),(0,s.jsx)("div",{className:"relative",children:(0,s.jsx)(p,{})})]})})]})}e.s(["default",()=>at],87154)},73245,e=>{"use strict";var t=e.i(43476),i=e.i(22016);let n=(0,e.i(75254).default)("message-square",[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}]]);var s=e.i(40160),r=e.i(20535),a=e.i(72520),o=e.i(70273),l=e.i(68054);function u({Icon:e,accent:i="blue"}){return(0,t.jsx)("div",{className:`inline-flex h-12 w-12 items-center justify-center rounded-xl ${"green"===i?"text-green bg-green/10":"text-blue bg-blue/10"}`,children:(0,t.jsx)(e,{className:"h-6 w-6"})})}function h({href:e,accent:n="blue",label:s="Get started"}){return(0,t.jsxs)(i.default,{href:e,className:"inline-flex items-center gap-2 rounded-full px-4 py-2 text-sm font-semibold transition-all duration-200 bg-dark text-white hover:bg-dark/90","aria-label":s,children:[(0,t.jsx)("span",{children:s}),(0,t.jsx)(a.ArrowRight,{className:"h-4 w-4 transition-transform duration-200 group-hover:translate-x-0.5"})]})}function d({title:e,description:n,href:s="#",accent:r="blue",Icon:o,linkText:l="Learn more"}){return(0,t.jsxs)("div",{className:"border-2 border-blue/20 rounded-[calc(1rem-1px)] bg-white/80 backdrop-blur-sm border border-light/60 shadow-[0_1px_0_rgba(15,23,42,0.04),0_8px_24px_rgba(2,6,23,0.06)] hover:shadow-[0_1px_0_rgba(15,23,42,0.06),0_16px_40px_rgba(2,6,23,0.08)] transition-all duration-300 h-full relative p-6 sm:p-7 flex flex-col justify-between h-full",children:[(0,t.jsx)(i.default,{href:s,"aria-label":`Open ${e}`,className:"absolute inset-0 rounded-[calc(1rem-1px)] focus:outline-none focus-visible:ring-2 focus-visible:ring-blue/40"}),(0,t.jsxs)("div",{className:"relative z-10 flex items-start gap-4",children:[(0,t.jsx)(u,{Icon:o,accent:r}),(0,t.jsxs)("div",{className:"flex-1",children:[(0,t.jsx)("h3",{className:"text-xl font-semibold text-dark",children:e}),(0,t.jsx)("p",{className:"mt-2 text-darkgray leading-relaxed",children:n})]})]}),(0,t.jsxs)("div",{className:"relative z-10 mt-6 flex items-center justify-between",children:[(0,t.jsxs)(i.default,{href:s,className:`group/lnk inline-flex items-center gap-1.5 text-sm font-semibold ${"green"===r?"text-green hover:text-green/90":"text-blue hover:text-blue/90"}`,"aria-label":`Learn more about ${e}`,children:[l,(0,t.jsx)(a.ArrowRight,{className:"h-4 w-4 transition-transform duration-200 group-hover/lnk:translate-x-0.5"})]}),(0,t.jsx)("div",{className:"group",children:(0,t.jsx)(h,{href:s,accent:r,label:"Get started"})})]})]})}function c(){return(0,t.jsx)("section",{className:"relative bg-gradient-to-br from-white via-light/30 to-blue/5",children:(0,t.jsxs)("div",{className:"container mx-auto px-4 py-6 lg:py-12",children:[(0,t.jsxs)("div",{className:"flex flex-col items-center text-center",children:[(0,t.jsxs)("div",{className:"inline-flex items-center gap-2 rounded-full bg-white/90 px-3 py-1 ring-1 ring-light shadow-sm","aria-label":"Products",children:[(0,t.jsx)("span",{className:"h-1.5 w-1.5 rounded-full bg-green","aria-hidden":"true"}),(0,t.jsx)("span",{className:"text-[11px] font-semibold tracking-wider up
27percase text-darkgray",children:"Products"})]}),(0,t.jsx)("h2",{className:"mt-4 text-4xl md:text-5xl font-bold bg-gradient-to-r from-blue to-green bg-clip-text text-transparent",children:"Build with the tools you need"}),(0,t.jsx)("p",{className:"mt-2 text-darkgray",children:"A focused suite for location data: integrate, manage, and export."})]}),(0,t.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4 md:gap-6 mt-6 md:mt-12",children:[(0,t.jsx)(d,{title:"API Access",description:"Query countries, states, and cities via fast REST and GraphQL endpoints.",href:"/product/api",accent:"blue",linkText:"Get API Access",Icon:r.SquareTerminal}),(0,t.jsx)(d,{title:"Export Tool",description:"Download curated datasets in CSV, JSON, or SQL. Free and paid formats available.",href:"/product/export-tool",accent:"blue",linkText:"Start Exporting",Icon:s.Download}),(0,t.jsx)(d,{title:"CLI Tool",description:"Search, explore, and generate code from geographic data — right from your terminal.",href:"https://cli.countrystatecity.in",accent:"blue",linkText:"Install CLI",Icon:l.Terminal}),(0,t.jsx)(d,{title:"Database Repository",description:"Open-source geographical database with global coverage. Available via NPM, PyPI, and CLI with 12 export formats. ODbL licensed for data, MIT for packages.",href:"/product/database",accent:"green",linkText:"View on Github",Icon:o.Star}),(0,t.jsx)(d,{title:"Update Tool",description:"Submit feedback, report issues, or suggest new data.",href:"/product/update-tool",accent:"green",linkText:"Contribute Now",Icon:n})]})]})})}e.s(["default",()=>c],73245)},19968,e=>{"use strict";var t=e.i(43476),i=e.i(37727);let n=["Manually collecting country, state, and city data","Constantly fixing outdated location info","Dealing with inconsistent formats (CSV, JSON, SQL)","Writing your own location lookup logic","Hunting for API endpoints from unreliable sources"];function s(){return(0,t.jsx)("section",{className:"relative container mx-auto px-4 py-6 lg:py-12",children:(0,t.jsxs)("div",{className:"grid lg:grid-cols-2 gap-6 md:gap-12 lg:gap-20 items-center",children:[(0,t.jsx)("div",{className:"space-y-4 order-2 lg:order-1",children:n.map((e,n)=>(0,t.jsx)("div",{className:"relative bg-white/80 backdrop-blur-sm rounded-2xl p-6 border border-light/50 shadow-sm hover:shadow-lg hover:-translate-y-1 transition-all duration-300 animate-fadeInUp",style:{animationDelay:`${.1*n}s`},children:(0,t.jsxs)("div",{className:"flex items-center gap-4",children:[(0,t.jsx)("div",{className:"flex-shrink-0 w-6 h-6 bg-danger/10 rounded-full flex items-center justify-center",children:(0,t.jsx)(i.X,{className:"w-4 h-4 text-danger stroke-[3]"})}),(0,t.jsxs)("div",{className:"relative",children:[(0,t.jsx)("p",{className:"text-lightgray leading-relaxed font-medium",children:e}),(0,t.jsx)("div",{className:"absolute top-1/2 left-0 -translate-y-1/2 w-full h-0.5 bg-orange/60 rounded-full"})]})]})},n))}),(0,t.jsxs)("div",{className:"order-1 lg:order-2",children:[(0,t.jsx)("div",{className:"inline-flex items-center px-4 py-2 rounded-full bg-orange text-white text-sm font-bold uppercase tracking-wider mb-6",children:"Reliability"}),(0,t.jsx)("h2",{className:"text-4xl md:text-5xl lg:text-6xl font-bold text-dark mb-4 tracking-tight leading-tight",children:"Skip the hassle"}),(0,t.jsx)("p",{className:"text-xl text-darkgray leading-relaxed mb-4",children:"Stop wasting time wrangling location data. Whether you’re building an app, analyzing trends, or preparing a report, our API delivers accurate, up-to-date country, state, and city information in one request — ready in the format you need."}),(0,t.jsx)("p",{className:"text-sm text-lightgray",children:"Trusted by thousands of developers, analysts, and businesses worldwide."})]})]})})}e.s(["default",()=>s])},36680,e=>{"use strict";var t=e.i(43476),i=e.i(80064),n=e.i(70823);let s=({children:e,vertical:n=!1,repeat:s=4,pauseOnHover:r=!1,reverse:a=!1,className:o,applyMask:l=!0,...u})=>(0,t.jsxs)("div",{...u,className:(0,i.cn)("group/canopy relative flex h-full w-full overflow-hidden px-6 py-3 [--gap:24px] [gap:var(--gap)]",n?"flex-col":"flex-row",o),children:[Array.from({length:s}).map((s,o)=>(0,t.jsx)("div",{className:(0,i.cn)("flex shrink-0 [gap:var(--gap)]",{"group-hover/canopy:[animation-play-state:paused]":r,"[animation-direction:reverse]":a,"animate-canopy-horizontal flex-row":!n,"animate-canopy-vertical flex-col":n}
27),children:e},`item-${o}`)),l&&(0,t.jsx)("div",{className:(0,i.cn)("pointer-events-none absolute inset-0 z-10 h-full w-full from-white/50 from-5% via-transparent via-50% to-white/50 to-95% dark:from-gray-800/50 dark:via-transparent dark:to-gray-800/50",n?"bg-gradient-to-b":"bg-gradient-to-r")})]}),r=({testimonial:e,className:n})=>{let s=(e,t)=>`https://ui-avatars.com/api/?name=${encodeURIComponent(t||e)}&background=007bff&color=fff&size=128`;return(0,t.jsx)("div",{className:"rounded-2xl p-[1px] group-hover:from-blue/20 group-hover:to-green/10 transition-colors duration-300 group relative",children:(0,t.jsxs)("div",{className:(0,i.cn)("flex w-80 shrink-0 cursor-pointer overflow-hidden rounded-[calc(1rem-1px)] bg-white/80 backdrop-blur-sm border border-light/60 transition-all duration-300 p-6 flex flex-col h-full",n),children:[(0,t.jsxs)("div",{className:"flex items-start gap-4 mb-4",children:[(0,t.jsx)("div",{className:"relative h-12 w-12 shrink-0 overflow-hidden rounded-xl border-2 border-light/50 group-hover:border-blue/30 transition-colors duration-300",children:(0,t.jsx)("img",{src:e.avatar||s(e.name,e.company),alt:e.name,className:"h-full w-full object-cover",onError:t=>{t.target.src=s(e.name,e.company),t.target.onerror=null}})}),(0,t.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,t.jsx)("div",{className:"flex items-center gap-2 mb-1",children:(0,t.jsx)("span",{className:"text-xs text-blue font-medium",children:e.name})}),(0,t.jsxs)("div",{className:"text-xs text-lightgray",children:[(0,t.jsx)("span",{className:"font-medium",children:e.role}),e.company&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("span",{className:"mx-1",children:"•"}),(0,t.jsx)("span",{children:e.company})]})]})]})]}),(0,t.jsxs)("p",{className:"text-sm text-darkgray leading-relaxed line-clamp-3 flex-1",children:['"',e.testimonial,'"']}),(0,t.jsx)("div",{className:"absolute top-4 right-4 w-2 h-2 bg-blue/20 rounded-full opacity-0 group-hover:opacity-100 transition-opacity duration-300"}),(0,t.jsx)("div",{className:"absolute bottom-4 left-4 w-1 h-1 bg-green/30 rounded-full opacity-0 group-hover:opacity-100 transition-opacity duration-300"})]})})};e.s(["Testimonials",0,({data:e=n.default.testimonials,className:a,cardClassName:o})=>(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)("section",{className:"py-6 md:py-10 xl:py-16",children:[(0,t.jsxs)("div",{className:"text-center mb-6 md:mb-12 container mx-auto",children:[(0,t.jsx)("h2",{className:"text-3xl md:text-4xl font-bold text-dark mb-4 tracking-tight",children:"Loved by developers worldwide"}),(0,t.jsx)("p",{className:"text-lg text-darkgray",children:"See what developers are saying about the CountryStateCity API and tools"})]}),(0,t.jsx)("div",{className:(0,i.cn)("w-full overflow-x-hidden",a),children:[!1,!0].map((i,n)=>(0,t.jsx)(s,{reverse:i,className:"[--duration:200s]",pauseOnHover:!0,applyMask:!1,repeat:3,children:e.map(e=>(0,t.jsx)(r,{testimonial:e,className:o},e.name))},`Canopy-${n}`))})]})})])},17246,e=>{"use strict";var t=e.i(43476),i=e.i(48256),n=e.i(39312),s=e.i(58472),r=e.i(16715),a=e.i(90597),o=e.i(69638),l=e.i(81254),u=e.i(49973);let h=[{icon:n.Zap,title:"Lightning-Fast Geographic API",description:`Sub-${l.TEXT_STATS.responseTime.replace("<","")} response times with ${l.TEXT_STATS.uptime} uptime backed by global CDN. Perfect for real-time location features in web and mobile apps.`,color:"from-orange to-orange/90",details:[`${l.TEXT_STATS.responseTime} Response`,`${l.TEXT_STATS.uptime} Uptime`,"Global CDN","Auto-scaling"]},{icon:s.Code,title:"Developer-First Design",description:"RESTful APIs, comprehensive documentation, code examples in multiple languages. Built by developers, for developers.",color:"from-blue to-green",details:["REST APIs","Live Docs","Code Examples"]},{icon:r.RefreshCw,title:"Always Updated",description:"Community-driven updates, automated sync, and real-time data validation ensure maximum accuracy.",color:"from-blue to-blue/90",details:["Auto Sync","Community Updates","Data Validation","Version Control"]},{icon:a.Heart,title:"Open Source",description:"ODbL-1.0 Licensed core database with transparent development, community contributions, and full access.",color:"from-green to-green/90",details:["ODbL-1.0 License","Open Source","Community Driven","Transparent"]}];function d(){let{countries:e,states:n,cities:s}=(0,u.usePlatformStats)(),r=`${e.value}+`,a=`${n.value}${n.suffix}`,l=`${s.value}${s.suffix}`,d=[{icon:i.Globe,title:"Complete Global Coverage",description:`Access every country, state, and city worldwide with weekly updates. ${r} countries, ${a} states, ${l} cities at your fingertips.`,color:"from-blue to-blue/90",details:[`${r} Countries`,`${a} States`,`${l} Cities`,"Weekly Updates"]},...h];return(0,t.jsxs)("section",{className:"container mx-auto px-4 py-6 lg:py-12",children:[(0,t.jsxs)("div",{className:"text-center mb-10",children:[(0,t.jsxs)("div",{className:"inline-flex items-center gap-2 rounded-full bg-white/90 px-3 py-1 ring-1 ring-light shadow-sm transition-shadow hover:shadow-md","aria-label":"Why Choose Us",children:[(0,t.jsx)("span",{className:"h-1.5 w-1.5 rounded-full bg-blue animate-pulse","aria-hidden":"true"}),(0,t.jsx)("span",{className:"text-[11px] font-semibold tracking-wider up
27percase text-darkgray",children:"Why Choose Us"})]}),(0,t.jsx)("h2",{className:"mt-4 text-3xl md:text-4xl font-bold text-dark",children:"Why Developers Choose Our Geographic API"}),(0,t.jsx)("p",{className:"mt-3 text-darkgray",children:"Everything you need for geographical data in one comprehensive platform."})]}),(0,t.jsx)("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6 lg:gap-8",children:d.map((e,i)=>(0,t.jsx)("div",{className:"group relative",children:(0,t.jsx)("div",{className:"rounded-2xl p-[1px] bg-gradient-to-br from-light to-transparent group-hover:from-blue/20 group-hover:to-green/10 transition-colors duration-300 h-full",children:(0,t.jsx)("div",{className:"rounded-[calc(1rem-1px)] bg-white/80 backdrop-blur-sm border border-light/60 shadow-[0_1px_0_rgba(15,23,42,0.04),0_8px_24px_rgba(2,6,23,0.06)] hover:shadow-[0_1px_0_rgba(15,23,42,0.06),0_16px_40px_rgba(2,6,23,0.08)] transition-all duration-300 h-full",children:(0,t.jsxs)("div",{className:"relative p-6 sm:p-7 flex flex-col h-full",children:[(0,t.jsxs)("div",{className:"relative flex items-start gap-4 mb-4",children:[(0,t.jsx)("div",{className:`inline-flex h-12 w-12 items-center justify-center rounded-xl bg-gradient-to-r ${e.color} group-hover:scale-110 transition-transform duration-300 shadow-lg`,children:(0,t.jsx)(e.icon,{className:"h-6 w-6 text-white"})}),(0,t.jsx)("div",{className:"flex-1",children:(0,t.jsx)("h3",{className:"text-xl font-semibold text-dark",children:e.title})})]}),(0,t.jsx)("p",{className:"text-darkgray leading-relaxed mb-6",children:e.description}),(0,t.jsx)("div",{className:"grid grid-cols-2 gap-3 mt-auto",children:e.details.map((e,i)=>(0,t.jsxs)("div",{className:"flex items-center",children:[(0,t.jsx)(o.CheckCircle,{className:"h-4 w-4 text-success mr-2 flex-shrink-0"}),(0,t.jsx)("span",{className:"text-sm text-darkgray font-medium",children:e})]},i))})]})})})},i))})]})}e.s(["default",()=>d])}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.