{"version":3,"file":"uAt_D9PCB.DZScOD2M.mjs","names":[],"sources":["https:/framerusercontent.com/modules/GP5HyUpRrIMAOWhVNlXd/WKwHPMVuFqMUrQS2ZzkP/CheckoutInteractions.js","https:/framerusercontent.com/modules/OqlLxphtezzsSH42E3Gu/sYzDznLUoepBi5EW3gtA/uAt_D9PCB.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{useEffect}from\"react\";// Checkout interactions: highlights the selected Shipping Method / Payment Type row\n// and animates focus rings on every input inside the checkout.\n// withAuthForm reuses the same styles for the login / register pages and masks password fields.\nconst STYLE_ID=\"orveli-checkout-interactions\";const EASE=\"0.3s cubic-bezier(0.4, 0, 0.2, 1)\";const ACTIVE_BORDER=\"var(--token-c16915f9-c3dd-4957-8d57-f2112de78d30)\"// light-54\n;const IDLE_BORDER=\"var(--token-e05ad323-7320-4bf5-98d7-b5b8780bbd5f)\"// light-24\n;const ACTIVE_FILL=\"rgba(241, 230, 216, 0.04)\";const HOVER_BORDER=\"var(--token-b2a5b244-b133-442a-a1f5-b2189eeed2bb)\"// light-42\n;const CSS=`\n.orv-checkout label[data-framer-name=\"Radio\"] {\n    transition: background-color ${EASE};\n}\n.orv-checkout label[data-framer-name=\"Radio\"]::after {\n    transition: border-color ${EASE};\n}\n.orv-checkout label[data-framer-name=\"Radio\"]:not(:has(input:checked)) {\n    --border-color: ${IDLE_BORDER} !important;\n    background-color: transparent !important;\n}\n.orv-checkout label[data-framer-name=\"Radio\"]:not(:has(input:checked)):hover {\n    --border-color: ${HOVER_BORDER} !important;\n}\n.orv-checkout label[data-framer-name=\"Radio\"]:has(input:checked) {\n    --border-color: ${ACTIVE_BORDER} !important;\n    background-color: ${ACTIVE_FILL} !important;\n}\n.orv-checkout .framer-form-text-input,\n.orv-checkout .framer-form-select-wrapper,\n.orv-checkout .framer-form-boolean-input,\n.orv-checkout input,\n.orv-checkout select {\n    --framer-input-focused-transition: ${EASE} !important;\n}\n`;function useCheckoutStyles(){useEffect(()=>{if(typeof document===\"undefined\")return;if(document.getElementById(STYLE_ID))return;const style=document.createElement(\"style\");style.id=STYLE_ID;style.textContent=CSS;document.head.appendChild(style);},[]);}export function withCheckoutInteractions(Component){return props=>{useCheckoutStyles();const className=[props.className,\"orv-checkout\"].filter(Boolean).join(\" \");return /*#__PURE__*/_jsx(Component,{...props,className:className});};}// Inputs whose name contains \"password\" are switched to type=\"password\"\nexport function withAuthForm(Component){return props=>{useCheckoutStyles();useEffect(()=>{if(typeof document===\"undefined\")return;document.querySelectorAll(\".orv-checkout input[name]\").forEach(input=>{const name=input.name.toLowerCase();if(!name.includes(\"password\"))return;input.type=\"password\";input.autocomplete=name.includes(\"confirm\")||name.includes(\"create\")?\"new-password\":\"current-password\";});// Accounts aren't live yet: a Framer form would email the password\n// in plain text, so any form holding a password field never submits.\n// Capturing on document runs before React's own submit handling.\nconst onSubmit=event=>{const form=event.target;if(!form?.closest?.(\".orv-checkout\"))return;if(!form.querySelector('input[name*=\"assword\" i]'))return;event.preventDefault();event.stopImmediatePropagation();form.querySelectorAll('input[name*=\"assword\" i]').forEach(input=>{input.value=\"\";});showNotice(ACCOUNTS_NOTICE);};document.addEventListener(\"submit\",onSubmit,true);return()=>document.removeEventListener(\"submit\",onSubmit,true);},[]);const className=[props.className,\"orv-checkout\"].filter(Boolean).join(\" \");return /*#__PURE__*/_jsx(Component,{...props,className:className});};}const ACCOUNTS_NOTICE=\"Customer accounts are coming soon — you can check out as a guest in the meantime.\";function showNotice(message){document.getElementById(\"orveli-auth-notice\")?.remove();const note=document.createElement(\"div\");note.id=\"orveli-auth-notice\";note.setAttribute(\"role\",\"status\");note.textContent=message;Object.assign(note.style,{position:\"fixed\",left:\"50%\",bottom:\"32px\",transform:\"translate(-50%, 12px)\",opacity:\"0\",zIndex:\"9999\",padding:\"14px 22px\",borderRadius:\"1000px\",background:\"rgb(32, 25, 20)\",color:\"rgb(241, 230, 216)\",border:\"1px solid rgba(241, 230, 216, 0.16)\",fontFamily:'\"Manrope\", sans-serif',fontSize:\"14px\",letterSpacing:\"0.04px\",boxShadow:\"0 12px 32px rgba(0, 0, 0, 0.25)\",transition:`opacity ${EASE}, transform ${EASE}`,pointerEvents:\"none\",maxWidth:\"calc(100vw - 32px)\",textAlign:\"center\"});document.body.appendChild(note);requestAnimationFrame(()=>{note.style.opacity=\"1\";note.style.transform=\"translate(-50%, 0)\";});window.setTimeout(()=>{note.style.opacity=\"0\";note.style.transform=\"translate(-50%, 12px)\";window.setTimeout(()=>note.remove(),320);},3200);}\nexport const __FramerMetadata__ = {\"exports\":{\"withCheckoutInteractions\":{\"type\":\"reactHoc\",\"name\":\"withCheckoutInteractions\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withAuthForm\":{\"type\":\"reactHoc\",\"name\":\"withAuthForm\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./CheckoutInteractions.map","// Generated by Framer (6964d48)\nimport{fontStore}from\"framer\";fontStore.loadFonts([]);export const fonts=[{explicitInter:true,fonts:[]}];export const css=[\".framer-NnUaq .framer-styles-preset-1uz9atz:not(.rich-text-wrapper), .framer-NnUaq .framer-styles-preset-1uz9atz.rich-text-wrapper a { --framer-link-hover-text-color: var(--token-1acb016d-0daf-48f9-ba9c-e47d3b61801f); --framer-link-text-color: var(--token-9cfac7b5-00f9-4c4c-af5a-06b7039d1e9f); --framer-link-text-decoration: underline; --framer-link-text-decoration-offset: 4px; --framer-link-text-decoration-thickness: 1px; transition-delay: 0s; transition-duration: 0.2s; transition-property: color,text-decoration-color,text-decoration-thickness,text-underline-offset; transition-timing-function: cubic-bezier(0.44, 0, 0.56, 1); }\"];export const className=\"framer-NnUaq\";\nexport const __FramerMetadata__ = {\"exports\":{\"css\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"className\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"fonts\":{\"type\":\"variable\",\"annot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