{
  "version": 3,
  "sources": ["ssg:https://framerusercontent.com/modules/gHIyrUrVK90l1zdQ5quO/HBA2sBisArsEpyF29U1B/Card_Tilt.js"],
  "sourcesContent": ["import{jsx as _jsx}from\"react/jsx-runtime\";import{motion,useMotionValue,useTransform,useSpring}from\"framer-motion\";export function with3DTilt(Component){return props=>{// Create motion values for the mouse position (x and y)\nconst x=useMotionValue(.5);const y=useMotionValue(.5);// Calculate rotation values based on the mouse position\nconst rotateX=useTransform(y,[-1,1],[30,-30]);const rotateY=useTransform(x,[-1,1],[-30,30]);// Apply a smooth spring animation to the rotation values\nconst animatedRotateX=useSpring(rotateX,{stiffness:300,damping:30});const animatedRotateY=useSpring(rotateY,{stiffness:300,damping:30});// Update the motion values on mouse move\nconst handleMouseMove=event=>{const rect=event.currentTarget.getBoundingClientRect();const mouseX=event.clientX-rect.left;const mouseY=event.clientY-rect.top;x.set(mouseX/rect.width);y.set(mouseY/rect.height);};return /*#__PURE__*/_jsx(Component,{...props,as:motion.div,style:{...props.style,rotateX:animatedRotateX,rotateY:animatedRotateY,transformOrigin:\"center\"},onMouseMove:handleMouseMove,onMouseLeave:()=>{x.set(.5);y.set(.5);}});};}\nexport const __FramerMetadata__ = {\"exports\":{\"with3DTilt\":{\"type\":\"reactHoc\",\"name\":\"with3DTilt\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Card_Tilt.map"],
  "mappings": "qEAA0H,SAASA,EAAWC,EAAU,CAAC,OAAOC,GAAO,CACvK,IAAMC,EAAEC,EAAe,EAAE,EAAQC,EAAED,EAAe,EAAE,EAC9CE,EAAQC,EAAaF,EAAE,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,GAAG,CAAC,EAAQG,EAAQD,EAAaJ,EAAE,CAAC,GAAG,CAAC,EAAE,CAAC,IAAI,EAAE,CAAC,EACpFM,EAAgBC,EAAUJ,EAAQ,CAAC,UAAU,IAAI,QAAQ,EAAE,CAAC,EAAQK,EAAgBD,EAAUF,EAAQ,CAAC,UAAU,IAAI,QAAQ,EAAE,CAAC,EAChII,EAAgBC,GAAO,CAAC,IAAMC,EAAKD,EAAM,cAAc,sBAAsB,EAAQE,EAAOF,EAAM,QAAQC,EAAK,KAAWE,EAAOH,EAAM,QAAQC,EAAK,IAAIX,EAAE,IAAIY,EAAOD,EAAK,KAAK,EAAET,EAAE,IAAIW,EAAOF,EAAK,MAAM,CAAE,EAAE,OAAoBG,EAAKhB,EAAU,CAAC,GAAGC,EAAM,GAAGgB,EAAO,IAAI,MAAM,CAAC,GAAGhB,EAAM,MAAM,QAAQO,EAAgB,QAAQE,EAAgB,gBAAgB,QAAQ,EAAE,YAAYC,EAAgB,aAAa,IAAI,CAACT,EAAE,IAAI,EAAE,EAAEE,EAAE,IAAI,EAAE,CAAE,CAAC,CAAC,CAAE,CAAE",
  "names": ["with3DTilt", "Component", "props", "x", "useMotionValue", "y", "rotateX", "useTransform", "rotateY", "animatedRotateX", "useSpring", "animatedRotateY", "handleMouseMove", "event", "rect", "mouseX", "mouseY", "p", "motion"]
}
