{"version":3,"file":"shared-lib.DrC7TTW7.mjs","names":[],"sources":["https:/framerusercontent.com/modules/RQXQZKgnWL4YZx8JtmwZ/TPMRglL6rt6znHy6YUOM/ShineLoop.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{useEffect}from\"react\";// Framer's Loop effect is stripped on layers inside a component, and a Motion\n// `animate` prop is ignored here, so the sweep runs as a plain CSS animation.\n// The 16deg tilt lives in the keyframes because a CSS transform replaces the\n// layer's own transform for the duration of the animation.\nconst KEYFRAMES=`@keyframes kropiqShine {\n  0%   { transform: translateX(0px) rotate(16deg); }\n  33%  { transform: translateX(520px) rotate(16deg); }\n  100% { transform: translateX(520px) rotate(16deg); }\n}`;export function withShineLoop(Component){return props=>{useEffect(()=>{if(typeof document===\"undefined\")return;if(document.getElementById(\"kropiq-shine-kf\"))return;const el=document.createElement(\"style\");el.id=\"kropiq-shine-kf\";el.textContent=KEYFRAMES;document.head.appendChild(el);},[]);return /*#__PURE__*/_jsx(Component,{...props,style:{...props.style,animation:\"kropiqShine 2.7s cubic-bezier(0.32,0,0.24,1) infinite\"}});};}// Button sweep: one pass of about 0.9s, then a pause, on a 3.6s cycle\n// (user, 2026-10-14: \"the shine frequency on buttons is low\"; was 7s). It is drawn as a\n// ::before on the layer itself, so it also works on component instances.\nconst SLOW_CSS=`@keyframes kropiqShineSlow {\n  0%   { transform: translateX(0) rotate(16deg); }\n  25%  { transform: translateX(420%) rotate(16deg); }\n  100% { transform: translateX(420%) rotate(16deg); }\n}\n.kq-shine-slow { overflow: hidden !important; isolation: isolate; }\n.kq-shine-slow::before {\n  content: \"\";\n  position: absolute;\n  top: -60%;\n  left: -55%;\n  width: 38%;\n  height: 220%;\n  pointer-events: none;\n  z-index: 2;\n  background: linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.5) 50%, rgba(255,255,255,0) 100%);\n  animation: kropiqShineSlow 3.6s cubic-bezier(0.32,0,0.24,1) 0.8s infinite;\n}\n.kq-shine-slow.kq-shine-warm::before {\n  background: linear-gradient(90deg, rgba(244,123,32,0) 0%, rgba(244,123,32,0.18) 50%, rgba(244,123,32,0) 100%);\n}\n@media (prefers-reduced-motion: reduce) {\n  .kq-shine-slow::before { animation: none; display: none; }\n}`;function useSlowShineStyles(){useHoverStyles();useEffect(()=>{if(typeof document===\"undefined\")return;if(document.getElementById(\"kropiq-shine-slow\"))return;const el=document.createElement(\"style\");el.id=\"kropiq-shine-slow\";el.textContent=SLOW_CSS;document.head.appendChild(el);},[]);}// White shine, for orange or purple buttons.\nexport function withShineSlow(Component){return props=>{useSlowShineStyles();const className=[props.className,\"kq-shine-slow\"].filter(Boolean).join(\" \");return /*#__PURE__*/_jsx(Component,{...props,className:className});};}// Faint marigold shine, for white buttons.\nexport function withShineSlowWarm(Component){return props=>{useSlowShineStyles();const className=[props.className,\"kq-shine-slow kq-shine-warm\"].filter(Boolean).join(\" \");return /*#__PURE__*/_jsx(Component,{...props,className:className});};}// Sequential sweep for a row of buttons (v6 homepage course cards): every\n// few seconds the shine passes over the visible buttons one after another,\n// left to right. Buttons scrolled out of their row are skipped.\nconst SEQ_CSS=`@keyframes kropiqShineSeq {\n  0%   { transform: translateX(0) rotate(16deg); opacity: 1; }\n  100% { transform: translateX(420%) rotate(16deg); opacity: 1; }\n}\n.kq-shine-seq { overflow: hidden !important; isolation: isolate; }\n.kq-shine-seq::before {\n  content: \"\";\n  position: absolute;\n  top: -60%;\n  left: -55%;\n  width: 38%;\n  height: 220%;\n  pointer-events: none;\n  z-index: 2;\n  opacity: 0;\n  background: linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.5) 50%, rgba(255,255,255,0) 100%);\n}\n.kq-shine-seq.kq-seq-run::before {\n  animation: kropiqShineSeq 0.9s cubic-bezier(0.32,0,0.24,1) 1;\n}\n@media (prefers-reduced-motion: reduce) {\n  .kq-shine-seq::before { display: none; }\n}`;const SEQ_STEP=320// ms between neighbouring buttons\n;const SEQ_PAUSE=4200// ms of rest after the last button\n;let seqStarted=false;function isShown(el){const r=el.getBoundingClientRect();if(r.width===0||r.bottom<0||r.top>window.innerHeight)return false;if(r.right<=0||r.left>=window.innerWidth)return false;let p=el.parentElement;while(p&&p!==document.body){const cs=getComputedStyle(p);// Only real scroll/clip containers count; Framer also wraps layers\n// in zero-size or display: contents elements that must be ignored.\nif(cs.overflowX!==\"visible\"&&cs.display!==\"contents\"){const pr=p.getBoundingClientRect();const mid=r.left+r.width/2;if(pr.width>0&&(mid<pr.left||mid>pr.right))return false;}p=p.parentElement;}return true;}function runSequence(){const els=Array.from(document.querySelectorAll(\".kq-shine-seq\"));const shown=els.filter(isShown).sort((a,b)=>a.getBoundingClientRect().left-b.getBoundingClientRect().left);shown.forEach((el,i)=>{setTimeout(()=>{el.classList.remove(\"kq-seq-run\");void el.offsetWidth;el.classList.add(\"kq-seq-run\");},i*SEQ_STEP);});const next=Math.max(1,shown.length)*SEQ_STEP+900+SEQ_PAUSE;setTimeout(runSequence,next);}export function withShineSequence(Component){return props=>{useHoverStyles();useEffect(()=>{if(typeof document===\"undefined\")return;if(!document.getElementById(\"kropiq-shine-seq\")){const el=document.createElement(\"style\");el.id=\"kropiq-shine-seq\";el.textContent=SEQ_CSS;document.head.appendChild(el);}if(seqStarted)return;if(window.matchMedia(\"(prefers-reduced-motion: reduce)\").matches)return;seqStarted=true;setTimeout(runSequence,1200);},[]);const className=[props.className,\"kq-shine-seq\"].filter(Boolean).join(\" \");return /*#__PURE__*/_jsx(Component,{...props,className:className});};}// Shine layers use ::before because Framer draws layer borders in ::after.\n// Hover emphasis for every CTA (user, 2026-10-14: \"the hover effect needs\n// another animation that emphasizes the button\"). On top of the lift/scale\n// hoverEffect: an immediate, brighter shine sweep and the caret/icon nudging\n// right. Applies to the shine classes above and to kq-hover-shine (buttons\n// with no idle shine: outlined, white and footer buttons).\nconst HOVER_CSS=`@keyframes kropiqShineHover {\n  0%   { transform: translateX(0) rotate(16deg); opacity: 1; }\n  100% { transform: translateX(420%) rotate(16deg); opacity: 1; }\n}\n.kq-hover-shine { overflow: hidden !important; isolation: isolate; }\n.kq-hover-shine::before {\n  content: \"\";\n  position: absolute;\n  top: -60%;\n  left: -55%;\n  width: 38%;\n  height: 220%;\n  pointer-events: none;\n  z-index: 2;\n  opacity: 0;\n  background: linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.45) 50%, rgba(255,255,255,0) 100%);\n}\n.kq-hover-shine.kq-shine-warm::before {\n  background: linear-gradient(90deg, rgba(244,123,32,0) 0%, rgba(244,123,32,0.22) 50%, rgba(244,123,32,0) 100%);\n}\n.kq-shine-slow:hover::before, .kq-shine-seq:hover::before, .kq-hover-shine:hover::before {\n  animation: kropiqShineHover 0.7s cubic-bezier(0.32,0,0.24,1) 1 both;\n}\n.kq-shine-slow svg, .kq-shine-seq svg, .kq-hover-shine svg {\n  transition: transform 0.35s cubic-bezier(0.34,1.56,0.64,1);\n}\n.kq-shine-slow:hover svg, .kq-shine-seq:hover svg, .kq-hover-shine:hover svg {\n  transform: translateX(4px);\n}\n@media (prefers-reduced-motion: reduce) {\n  .kq-hover-shine::before { display: none; }\n  .kq-shine-slow:hover svg, .kq-shine-seq:hover svg, .kq-hover-shine:hover svg { transform: none; }\n}`;function useHoverStyles(){useEffect(()=>{if(typeof document===\"undefined\")return;if(document.getElementById(\"kropiq-shine-hover\"))return;const el=document.createElement(\"style\");el.id=\"kropiq-shine-hover\";el.textContent=HOVER_CSS;document.head.appendChild(el);},[]);}// Hover-only shine (white), for outlined buttons on dark backgrounds.\nexport function withHoverShine(Component){return props=>{useHoverStyles();const className=[props.className,\"kq-hover-shine\"].filter(Boolean).join(\" \");return /*#__PURE__*/_jsx(Component,{...props,className:className});};}// Hover-only shine (marigold), for white or light buttons.\nexport function withHoverShineWarm(Component){return props=>{useHoverStyles();const className=[props.className,\"kq-hover-shine kq-shine-warm\"].filter(Boolean).join(\" \");return /*#__PURE__*/_jsx(Component,{...props,className:className});};}\nexport const __FramerMetadata__ = {\"exports\":{\"withHoverShineWarm\":{\"type\":\"reactHoc\",\"name\":\"withHoverShineWarm\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withShineSlowWarm\":{\"type\":\"reactHoc\",\"name\":\"withShineSlowWarm\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withShineSlow\":{\"type\":\"reactHoc\",\"name\":\"withShineSlow\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withHoverShine\":{\"type\":\"reactHoc\",\"name\":\"withHoverShine\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withShineLoop\":{\"type\":\"reactHoc\",\"name\":\"withShineLoop\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withShineSequence\":{\"type\":\"reactHoc\",\"name\":\"withShineSequence\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./ShineLoop.map"],"mappings":"gIAkCG,SAAS,GAAoB,CAAC,EAAe,EAAE,MAAc,CAAyC,GAArC,OAAO,SAAW,KAAsB,SAAS,eAAe,mBAAmB,EAAE,OAAO,IAAM,EAAG,SAAS,cAAc,OAAO,EAAE,EAAG,GAAG,oBAAoB,EAAG,YAAY,EAAS,SAAS,KAAK,YAAY,CAAE,CAAE,EAAE,CAAC,CAAC,CAAE,CAC/R,SAAgB,EAAc,EAAU,CAAC,MAAO,IAAO,CAAC,EAAmB,EAAE,IAAM,EAAU,CAAC,EAAM,UAAU,eAAe,CAAC,CAAC,OAAO,OAAO,CAAC,CAAC,KAAK,GAAG,EAAE,OAAoB,EAAK,EAAU,CAAC,GAAG,EAAgB,WAAS,CAAC,CAAE,CAAE,CA4BxM,SAAS,EAAQ,EAAG,CAAC,IAAM,EAAE,EAAG,sBAAsB,EAAoE,GAA/D,EAAE,QAAQ,GAAG,EAAE,OAAO,GAAG,EAAE,IAAI,EAAO,aAA4B,EAAE,OAAO,GAAG,EAAE,MAAM,EAAO,WAAW,MAAO,GAAM,IAAI,EA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