{"version":3,"file":"MotionBackdrop.CBorXut7.mjs","names":["useRef"],"sources":["https:/framerusercontent.com/modules/RUC1G37wmqZEq7XXc7Yf/4P82zm6dhLRbYTsmlFfI/MotionBackdrop.js"],"sourcesContent":["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{addPropertyControls,ControlType,useIsStaticRenderer}from\"framer\";import{motion,useInView,useReducedMotion}from\"framer-motion\";import{useRef}from\"react\";/**\n * Motion Backdrop\n *\n * A decorative, non-interactive background that animates once when it\n * scrolls into view. \"line\" draws a rising path with three nodes; \"dots\"\n * fades a subtle dot grid in. Respects reduced-motion and renders a static\n * final state on the Framer canvas.\n *\n * @framerIntrinsicWidth 900\n * @framerIntrinsicHeight 560\n *\n * @framerSupportedLayoutWidth any-prefer-fixed\n * @framerSupportedLayoutHeight any-prefer-fixed\n */export default function MotionBackdrop(props){const{variant=\"line\",lineColor=\"#0A7590\",accentColor=\"#EA641E\",dotColor=\"#0F172A\",strokeWidth=3,opacity=1}=props;const ref=useRef(null);const isStatic=useIsStaticRenderer();const reduce=useReducedMotion();const inView=useInView(ref,{once:true,amount:.4});const showFinal=isStatic||reduce===true;const containerStyle={...props.style,position:\"relative\",width:\"100%\",height:\"100%\",overflow:\"hidden\",pointerEvents:\"none\",opacity};if(variant===\"dots\"){const patternId=\"mb-dots-pattern\";return /*#__PURE__*/_jsx(\"div\",{ref:ref,style:containerStyle,\"aria-hidden\":\"true\",children:/*#__PURE__*/_jsxs(motion.svg,{width:\"100%\",height:\"100%\",initial:showFinal?false:{opacity:0,scale:.94},animate:showFinal?{opacity:1,scale:1}:{opacity:inView?1:0,scale:inView?1:.94},transition:{duration:.5,ease:[.22,1,.36,1]},style:{display:\"block\",transformOrigin:\"60% 40%\"},children:[/*#__PURE__*/_jsx(\"defs\",{children:/*#__PURE__*/_jsx(\"pattern\",{id:patternId,width:\"28\",height:\"28\",patternUnits:\"userSpaceOnUse\",children:/*#__PURE__*/_jsx(\"circle\",{cx:\"2\",cy:\"2\",r:\"1.6\",fill:dotColor,opacity:\"0.13\"})})}),/*#__PURE__*/_jsx(\"rect\",{width:\"100%\",height:\"100%\",fill:`url(#${patternId})`})]})});}const viewW=900;const viewH=560;const path=\"M -20 470 L 130 410 L 300 470 L 470 300 L 650 360 L 850 180 L 940 210\";const nodes=[{x:300,y:470,r:6,fill:lineColor,o:.42,delay:.42},{x:650,y:360,r:6,fill:lineColor,o:.42,delay:.5},{x:850,y:180,r:8.5,fill:accentColor,o:.7,delay:.58}];return /*#__PURE__*/_jsx(\"div\",{ref:ref,style:containerStyle,\"aria-hidden\":\"true\",children:/*#__PURE__*/_jsxs(\"svg\",{width:\"100%\",height:\"100%\",viewBox:`0 0 ${viewW} ${viewH}`,preserveAspectRatio:\"xMidYMid slice\",style:{display:\"block\"},children:[/*#__PURE__*/_jsx(motion.path,{d:path,fill:\"none\",stroke:lineColor,strokeOpacity:.28,strokeWidth:strokeWidth,strokeLinecap:\"round\",strokeLinejoin:\"round\",initial:showFinal?false:{pathLength:0},animate:showFinal?{pathLength:1}:{pathLength:inView?1:0},transition:{duration:.7,ease:[.4,0,.2,1]}}),nodes.map((n,i)=>/*#__PURE__*/_jsx(motion.circle,{cx:n.x,cy:n.y,r:n.r,fill:n.fill,fillOpacity:n.o,initial:showFinal?false:{scale:0,opacity:0},animate:showFinal?{scale:1,opacity:1}:{scale:inView?1:0,opacity:inView?1:0},transition:{duration:.24,ease:[.22,1,.36,1],delay:showFinal?0:n.delay},style:{transformBox:\"fill-box\",transformOrigin:\"center\"}},i))]})});}addPropertyControls(MotionBackdrop,{variant:{type:ControlType.Enum,title:\"Style\",options:[\"line\",\"dots\"],optionTitles:[\"Drawn line\",\"Dot field\"],defaultValue:\"line\",displaySegmentedControl:true},lineColor:{type:ControlType.Color,title:\"Line\",defaultValue:\"#0A7590\",hidden:({variant})=>variant===\"dots\"},accentColor:{type:ControlType.Color,title:\"Accent\",defaultValue:\"#EA641E\",hidden:({variant})=>variant===\"dots\"},strokeWidth:{type:ControlType.Number,title:\"Stroke\",defaultValue:3,min:1,max:8,step:.5,unit:\"px\",hidden:({variant})=>variant===\"dots\"},dotColor:{type:ControlType.Color,title:\"Dots\",defaultValue:\"#0F172A\",hidden:({variant})=>variant===\"line\"},opacity:{type:ControlType.Number,title:\"Opacity\",defaultValue:1,min:0,max:1,step:.05}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"MotionBackdrop\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutWidth\":\"any-prefer-fixed\",\"framerSupportedLayoutHeight\":\"any-prefer-fixed\",\"framerContractVersion\":\"1\",\"framerIntrinsicWidth\":\"900\",\"framerIntrinsicHeight\":\"560\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./MotionBackdrop.map"],"mappings":"wPAaG,SAAwB,EAAe,EAAM,CAAC,GAAK,CAAC,UAAQ,OAAO,YAAU,UAAU,cAAY,UAAU,WAAS,UAAU,cAAY,EAAE,UAAQ,GAAG,EAAY,EAAIA,EAAO,IAAI,EAAQ,EAAS,EAAoB,EAAQ,EAAO,EAAiB,EAAQ,EAAO,EAAU,EAAI,CAAC,KAAK,GAAK,OAAO,EAAE,CAAC,EAAQ,EAAU,GAAU,IAAS,GAAW,EAAe,CAAC,GAAG,EAAM,MAAM,SAAS,WAAW,MAAM,OAAO,OAAO,OAAO,SAAS,SAAS,cAAc,OAAO,SAAO,EAAE,GAAG,IAAU,OAAO,CAAC,IAAM,EAAU,kBAAkB,OAAoB,EAAK,MAAM,CAAK,MAAI,MAAM,EAAe,cAAc,OAAO,SAAsB,EAAM,EAAO,IAAI,CAAC,MAAM,OAAO,OAAO,OAAO,QAAQ,IAAgB,CAAC,QAAQ,EAAE,MAAM,GAAG,EAAE,QAAQ,EAAU,CAAC,QAAQ,EAAE,MAAM,CAAC,EAAE,CAAC,QAAQ,KAAW,MAAM,EAAO,EAAE,GAAG,EAAE,WAAW,CAAC,SAAS,GAAG,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