{"version":3,"file":"LazySection_2.CHnLCm02.mjs","names":["useState","useRef"],"sources":["https:/framerusercontent.com/modules/h43Zi1McG8DTbUy7e8Ly/3kbAK5nJpcBiZVvVUJEG/LazySection_2.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{useState,useEffect,useRef}from\"react\";let hasScrolled=false;const pendingCallbacks=new Set;if(typeof window!==\"undefined\"){window.addEventListener(\"scroll\",()=>{hasScrolled=true;pendingCallbacks.forEach(cb=>cb());pendingCallbacks.clear();},{passive:true,once:true});}export function withLazySection(Component){return function LazySection(props){// Always start false on both SSR and client first render to avoid React #422 hydration mismatch\nconst[ready,setReady]=useState(false);const wrapperRef=useRef(null);useEffect(()=>{// In Framer canvas (iframe), or if user already scrolled, show immediately\nif(window.parent!==window||hasScrolled){setReady(true);return;}const trigger=()=>setReady(true);pendingCallbacks.add(trigger);// eslint-disable-next-line consistent-return\nreturn()=>{pendingCallbacks.delete(trigger);};// eslint-disable-next-line react-hooks/exhaustive-deps\n},[]);// After section mounts, re-trigger Framer's appear animations\nuseEffect(()=>{if(!ready)return;const raf=requestAnimationFrame(()=>{window.dispatchEvent(new Event(\"scroll\"));window.dispatchEvent(new Event(\"resize\"));});// Fallback: force visible any appear-animated elements that\n// IntersectionObserver missed because they mounted mid-scroll\nconst timer=setTimeout(()=>{const wrapper=wrapperRef.current;if(!wrapper)return;wrapper.querySelectorAll(\"[data-framer-appear-id]\").forEach(el=>{if(window.getComputedStyle(el).opacity===\"0\"){el.style.setProperty(\"opacity\",\"1\",\"important\");el.style.setProperty(\"transform\",\"none\",\"important\");el.style.setProperty(\"transition\",\"opacity 0.3s ease, transform 0.3s ease\",\"important\");}});},500);return()=>{cancelAnimationFrame(raf);clearTimeout(timer);};},[ready]);if(!ready)return null;return /*#__PURE__*/_jsx(\"div\",{ref:wrapperRef,style:{display:\"contents\"},children:/*#__PURE__*/_jsx(Component,{...props})});};}\nexport const __FramerMetadata__ = {\"exports\":{\"withLazySection\":{\"type\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