1import{c as g,T as p,j as e,m}from"./index-BRzzGLJ_.js";import{S as f}from"./shield-check-CJiDpbD3.js";import{C as u}from"./circle-check-BxhQ4ys1.js";const j=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"M12 8v4",key:"1got3b"}],["path",{d:"M12 16h.01",key:"1drbdi"}]],v=g("shield-alert",j),h={SAFE:{label:"Safe",color:"var(--safe)",glow:"glow-safe",Icon:f},SUSPICIOUS:{label:"Suspicious",color:"var(--warning)",glow:"glow-warning",Icon:p},DANGEROUS:{label:"Dangerous",color:"var(--danger)",glow:"glow-danger animate-pulse-danger",Icon:v}};function N(s,l){if(!l?.length)return s;let t=[s];for(let n=0;n<l.length;n++){const{phrase:o,color:c}=l[n];if(!o)continue;const x=c==="red"?"bg-danger/30 text-foreground rounded px-1":"bg-warning/30 text-foreground rounded px-1",i=[];for(const r of t){if(typeof r!="string"){i.push(r);continue}const a=r.toLowerCase().indexOf(o.toLowerCase());if(a===-1){i.push(r);continue}i.push(r.slice(0,a)),i.push(e.jsx("mark",{className:x,children:r.slice(a,a+o.length)},`hl-${n}-${a}`)),i.push(r.slice(a+o.length))}t=i}return e.jsx(e.Fragment,{children:t})}function k({result:s,originalInput:l,vtStats:t}){const n=h[s.verdict]??h.SUSPICIOUS,o=n.Icon,c="GX-"+Math.random().toString(36).slice(2,10).toUpperCase(),x=new Date().toLocaleString("en-IN",{hour12:!1}),i=s.verdict==="DANGEROUS"?"animate-shake":"",r=s.verdict==="SUSPICIOUS"?"animate-float":"";return e.jsxs(m.div,{initial:{opacity:0,y:30},animate:{opacity:1,y:0},transition:{duration:.4,ease:"easeOut"},className:"space-y-6",children:[e.jsx("div",{className:"overflow-hidden rounded-t-2xl border border-b-0 border-[color:var(--neon)]/40 bg-[#06091a] text-[color:var(--neon)] font-mono text-[10px] uppercase tracking-widest",children:e.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-x-4 gap-y-1 px-4 py-2",children:[e.jsx("span",{className:"font-bold",children:"â¡ GuardianX Threat Intelligence Report"}),e.jsxs("span",{className:"opacity-70",children:["Scan ID: ",e.jsx("span",{className:"text-foreground",children:c})]}),e.jsx("span",{className:"opacity-70",children:x}),e.jsx("span",{className:"rounded-full bg-[color:var(--safe)]/20 px-2 py-0.5 text-[color:var(--safe)]",children:"â Analysis Complete"})]})}),e.jsxs("div",{className:`relative -mt-6 overflow-hidden rounded-2xl border p-6 ${n.glow} ${i} ${r}`,style:{borderColor:n.color,background:`color-mix(in oklab, ${n.color} 10%, transparent)`},children:[e.jsxs("div",{className:"flex items-center gap-4",children:[e.jsx("div",{className:"relative flex h-14 w-14 items-center justify-center rounded-full",style:{background:n.color,color:"var(--background)"},children:s.verdict==="SAFE"?e.jsx("svg",{viewBox:"0 0 24 24",width:"28",height:"28",fill:"none",stroke:"currentColor",strokeWidth:"3",strokeLinecap:"round",strokeLinejoin:"round",children:e.jsx("path",{className:"draw-check",d:"M4 12 L10 18 L20 6"})}):e.jsx(o,{className:"h-7 w-7",strokeWidth:2.5})}),e.jsxs("div",{className:"flex-1",children:[e.jsx("div",{className:"font-display text-3xl font-bold",style:{color:n.color},children:s.verdict}),e.jsx("div",{className:"text-sm text-muted-foreground",children:s.scamCategory})]}),e.jsxs("div",{className:"text-right",children:[e.jsx("div",{className:"text-xs uppercase tracking-wide text-muted-foreground",children:"Confidence"}),e.jsxs("div",{className:"font-display text-2xl font-bold",children:[s.confidence,"%"]})]})]}),e.jsx("div",{className:"mt-4 h-1.5 w-full rounded-full bg-white/10",children:e.jsx(m.div,{initial:{width:0},animate:{width:`${s.confidence}%`},transition:{duration:.8,ease:"easeOut"},className:"h-full rounded-full",style:{background:n.color}})}),t&&e.jsxs("div",{className:"mt-3 text-xs text-foreground/90",children:["ð¬ VirusTotal: ",e.jsxs("span",{className:t.malicious>0?"text-[color:var(--danger)] font-semibold":"text-[color:var(--safe)]",children:[t.malicious,"/",t.total]})," engines flagged this"]})]}),l&&s.highlightedPhrases?.length>0&&e.jsxs("div",{className:"rounded-xl glass p-4",children:[e.jsx("div",{className:"mb-2 text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:"Original Content"}),e.jsx("div",{className:"whitespace-pre-wrap text-sm leading-relaxed",children:N(l,s.highlightedPhrases)})]}),s.redFlags?.length>0&&s.verdict!=="SAFE"&&e.jsxs("div",{children:[e.jsx("h3",{className:"font-display text-lg font-semibold",children:"ð© Red Flags"}),e.jsx("div",{className:"mt-3 space-y-2",children:s.redFlags.map((a,d)=>e.jsx(m.div,{initial:{opacity:0,x:-10}
1,animate:{opacity:1,x:0},transition:{delay:d*.06},className:"rounded-lg border border-danger/30 bg-danger/5 p-3",children:e.jsxs("div",{className:"flex items-start justify-between gap-3",children:[e.jsxs("div",{children:[e.jsx("div",{className:"font-semibold",children:a.flag}),e.jsx("div",{className:"mt-1 text-sm text-muted-foreground",children:a.explanation})]}),e.jsx("span",{className:`shrink-0 rounded-full px-2 py-0.5 text-[10px] font-semibold uppercase ${a.severity==="high"?"bg-danger/20 text-[color:var(--danger)]":a.severity==="medium"?"bg-warning/20 text-[color:var(--warning)]":"bg-muted text-muted-foreground"}`,children:a.severity})]})},d))})]}),s.safeSignals?.length>0&&e.jsxs("div",{children:[e.jsx("h3",{className:"font-display text-lg font-semibold",children:"â
Safe Signals"}),e.jsx("ul",{className:"mt-2 space-y-1",children:s.safeSignals.map((a,d)=>e.jsxs("li",{className:"flex items-start gap-2 text-sm",children:[e.jsx(u,{className:"mt-0.5 h-4 w-4 shrink-0 text-[color:var(--safe)]"}),e.jsx("span",{children:a})]},d))})]}),e.jsxs("div",{className:"rounded-xl glass p-4",children:[e.jsx("div",{className:"mb-1 text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:"What this means"}),e.jsx("p",{className:"text-sm leading-relaxed",children:s.explanation})]}),e.jsxs("div",{className:"rounded-xl border border-primary/30 bg-primary/5 p-4",children:[e.jsx("div",{className:"mb-1 text-xs font-semibold uppercase tracking-wide text-primary",children:"What to do"}),e.jsx("p",{className:"whitespace-pre-line text-sm leading-relaxed",children:s.recommendation})]}),e.jsxs("div",{className:"grid gap-4 md:grid-cols-2",children:[s.emotionTactics?.length>0&&e.jsxs("div",{className:"rounded-xl glass p-4",children:[e.jsx("div",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:"Emotion tactics used"}),e.jsx("div",{className:"mt-2 flex flex-wrap gap-1.5",children:s.emotionTactics.map(a=>e.jsx("span",{className:"rounded-full bg-warning/15 text-foreground border border-warning/30 px-2.5 py-0.5 text-xs",children:a},a))})]}),s.entities&&e.jsxs("div",{className:"rounded-xl glass p-4 text-sm",children:[e.jsx("div",{className:"text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:"Extracted"}),e.jsx("div",{className:"mt-2 grid grid-cols-2 gap-x-3 gap-y-1",children:Object.entries(s.entities).map(([a,d])=>Array.isArray(d)&&d.length>0?e.jsxs("div",{className:"col-span-2",children:[e.jsxs("span",{className:"text-xs uppercase text-muted-foreground",children:[a,":"]})," ",e.jsx("span",{className:"text-foreground",children:d.join(", ")})]},a):null)})]})]}),s.relatedScamType&&e.jsxs("div",{className:"rounded-xl border border-warning/30 bg-warning/5 p-3 text-sm",children:["â ï¸ Matches known India scam pattern: ",e.jsx("span",{className:"font-semibold",children:s.relatedScamType})]})]})}export{k as V};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.