PageSourceSearch

https://kometri.com/assets/HomePage-DC9Y1UCo.js

js kometri.com collected 2026-10-02 01:35:01 UTC 45,444 bytes, 1 lines download raw bytes

1import{j as e}from"./vendor-query-CsYqNbmM.js";import{c as _e,r as n,L as _,N as ze}from"./vendor-react-CkrtinOd.js";import{t as te,z as Ae,u as De,H as Pe,B as O}from"./index-BGtza9SP.js";import{u as Ge}from"./usePageTitle-BiT9KTac.js";import{d as le}from"./discoverApi-GjuhMc7F.js";import{A as B,D as Ke}from"./DiscoverCard-BicwFTkR.js";import{u as oe}from"./vendor-i18n-l7OMnJqp.js";import{m as C}from"./proxy-DpZWPpz2.js";import{f as F,m as $e,n as Oe,A as ve,o as E,p as Be,q as Fe,r as We,X as He,P as Me,W as Ne,s as Y,M as Ue,Z as Je,u as Ye,v as qe,w as Ze}from"./vendor-ui-Dv3q5jvr.js";import{R as pe,a as ge,p as Xe}from"./redditBetaIntent-gSL3GJK0.js";import"./agent-Cz1qD7uu.js";import"./transliterate-lY8u3lJP.js";import"./index-B5VnwfK1.js";const R={},Qe=[{code:"es",names:["spanish","español","espanol","castellano","іспанська","іспанська мова","hiszpański","hiszpanski"]},{code:"it",names:["italian","italiano","італійська","італійська мова","włoski","wloski"]},{code:"fr",names:["french","français","francais","французька","французька мова","francuski"]},{code:"de",names:["german","deutsch","німецька","німецька мова","niemiecki"]},{code:"ja",names:["japanese","japonés","japonais","日本語","nihongo","японська","японська мова","japoński","japonski"]},{code:"ko",names:["korean","coreano","coréen","한국어","hangul","корейська","корейська мова","koreański","koreanski"]},{code:"pl",names:["polish","polski","polaco","polonais","польська","польська мова"]},{code:"zh",names:["mandarin","chinese","chino","chinois","中文","汉语","zhongwen","hanyu","китайська","мандаринська","chiński","chinski"]},{code:"pt",names:["portuguese","português","portugues","portugais","португальська","португальський","portugalski"]},{code:"ar",names:["arabic","arabe","العربية","арабська","арабська мова","arabski"]},{code:"nl",names:["dutch","nederlands","néerlandais","neerlandais","нідерландська","голландська","holenderski","niderlandzki"]},{code:"sv",names:["swedish","svenska","suédois","suedois","шведська","шведський","szwedzki"]},{code:"tr",names:["turkish","türkçe","turkce","turc","турецька","турецький","turecki"]},{code:"uk",names:["ukrainian","українська","ukrainien","ukraiński","ukrainski"]},{code:"en",names:["english","anglais","ingles","inglés","англійська","англійська мова","angielski"]}];for(const{code:t,names:a}of Qe){R[t]=t;for(const p of a)R[p.toLowerCase()]=t}function we(t){const a=t.trim().toLowerCase();if(!a)return null;const p=a.split(/\s+/);for(let l=Math.min(2,p.length);l>=1;l--){const g=p.slice(0,l).join(" ");if(R[g])return R[g]}for(const l of p)if(R[l])return R[l];return null}function ke(t,a){const l=t.trim().toLowerCase().split(/\s+/);return l.length===1?R[l[0]]===a:l.length===2&&R[l.join(" ")]===a}const et=[{code:"es",name:"Spanish",flag:"🇪🇸"},{code:"fr",name:"French",flag:"🇫🇷"},{code:"de",name:"German",flag:"🇩🇪"},{code:"it",name:"Italian",flag:"🇮🇹"},{code:"pt",name:"Portuguese",flag:"🇵🇹"},{code:"uk",name:"Ukrainian",flag:"🇺🇦"},{code:"ja",name:"Japanese",flag:"🇯🇵"},{code:"ko",name:"Korean",flag:"🇰🇷"},{code:"en",name:"English",flag:"🇬🇧"},{code:"pl",name:"Polish",flag:"🇵🇱"},{code:"tr",name:"Turkish",flag:"🇹🇷"}],w=3,fe=10,he=5,be=["Italian for ordering food in Rome","Spanish for travel","Japanese N5 kanji","Polish for my partner's family","French for business meetings","Korean for K-pop lyrics","German for tech jobs"],tt=3e3,W="tryit_session_v2";function at(){try{const t=sessionStorage.getItem(W)||localStorage.getItem(W);return t?JSON.parse(t):null}catch{return null}}function ne(t){const a=JSON.stringify(t);try{sessionStorage.setItem(W,a)}catch{}try{localStorage.setItem(W,a)}catch{}}function st(){const{t,i18n:a}=oe("home"),[p]=_e(),[l,g]=n.useState(null),[r,d]=n.useState(""),[x,V]=n.useState(""),[u,h]=n.useState(null),[b,N]=n.useState([]),[z,K]=n.useState(0),[v,q]=n.useState(!1),[y,L]=n.useState(null),[A,T]=n.useState([]),[D,o]=n.useState(0),[c,j]=n.useState(!1),[Z,$]=n.useState(!1),[I,ae]=n.useState(0),[H,Se]=n.useState(!1),[Ce,ie]=n.useState(!1),de=n.useRef(null),se=n.useRef(null),X=n.useRef(null),[M,Ee]=n.useState({atStart:!0,atEnd:!1});n.useEffect(()=>{if(l||!H||x.trim().length>0)return;const s=setInterval(()=>{ae(i=>(i+1)%be.length)},tt);return()=>clearInterval(s)},[l,x,H]);const U=a.language?.split("-")[0]||"en",k=b[z]??null,f=A.length,J=f>
1=w?"saves":D>=fe?"swipes":null,Q=n.useCallback(()=>{const s=X.current;if(!s)return;const i=s.scrollWidth-s.clientWidth,m=8;Ee({atStart:s.scrollLeft<=m,atEnd:s.scrollLeft>=i-m})},[]),ce=n.useCallback(s=>{const i=X.current;i&&i.scrollBy({left:s*i.clientWidth*.82,behavior:"smooth"})},[]);n.useEffect(()=>{if(l)return;const s=X.current;if(!s)return;s.scrollLeft=0,Q();const i=new ResizeObserver(Q);return i.observe(s),()=>i.disconnect()},[l,Q]),n.useEffect(()=>{const s=p.get("lang"),i=p.get("topic");if(s){g(s),d(i??""),T([]),o(0),j(!1),P(s,i??"");return}const m=at();if(!m||!m.lang)return;g(m.lang),d(m.topic??""),T(m.savedCards??[]),o(m.swipedTotal),(m.savedCards?.length??0)>=w||(m.swipedTotal??0)>=fe||P(m.lang,m.topic??"")},[]),n.useEffect(()=>{l&&ne({lang:l,topic:r,savedCards:A,swipedTotal:D})},[l,r,A,D]),n.useEffect(()=>{J&&!c&&(j(!0),te("demo_hit_signup_gate",{reason:J,language:l,save_count:f,swipe_count:D}))},[J,c,l,f,D]);const P=n.useCallback(async(s,i,m=[])=>{q(!0),L(null);const S=550,Ie=performance.now();try{const ee=await le.getAnonFeed({language:s,level:"A2",source_language:U,count:he,exclude_words:m,topic:i||null}),G=performance.now()-Ie;G<S&&await new Promise(Re=>setTimeout(Re,S-G)),ee.cards.length===0?L("no_cards"):(N(ee.cards),K(0))}catch(ee){const G=ee;G.status===429?L("rate_limited"):G.details?.detail?.code==="content_blocked"||G.details?.code==="content_blocked"?L("content_blocked"):L(G.message||"fetch_failed")}finally{q(!1)}},[U]),Ve=n.useCallback(s=>{ne({lang:s,topic:"",savedCards:[],swipedTotal:0}),g(s),d(""),V(""),h(null),T([]),o(0),j(!1),te("demo_started",{language:s,source:"chip"}),P(s,"")},[P]),Le=n.useCallback(()=>{const s=x.trim();if(!s)return;const i=we(s);if(!i){h("no_language_detected");return}const S=ke(s,i)?"":s;ne({lang:i,topic:S,savedCards:[],swipedTotal:0}),h(null),g(i),d(S),T([]),o(0),j(!1),P(i,S)},[x,P]),me=n.useCallback(()=>{!k||c||(ie(!0),o(s=>s+1),K(s=>s+1))},[k,c]),ue=n.useCallback(()=>{!k||c||(ie(!0),T(s=>[...s,k]),o(s=>s+1),K(s=>s+1),te("demo_card_saved",{language:l,save_index:A.length+1}))},[k,c,l,A.length]);n.useEffect(()=>{if(!l||J)return;if(b.length-z<=1&&!Z&&!v&&b.length>0){$(!0);const i=b.map(m=>m.front_text);le.getAnonFeed({language:l,level:"A2",source_language:U,count:he,exclude_words:i,topic:r||null}).then(m=>{N(S=>[...S,...m.cards])}).catch(()=>{}).finally(()=>$(!1))}},[z,b,l,U,Z,v,J,r]);const Te=n.useCallback(()=>{if(l)try{const s=new URL(window.location.origin);s.searchParams.set("lang",l),r&&s.searchParams.set("topic",r);const i=s.toString(),m=()=>{try{window.prompt(t("tryit_share_copy_manual",{defaultValue:"Copy this link:"}),i)}catch{}};navigator.clipboard?.writeText?navigator.clipboard.writeText(i).then(()=>{Ae.success(t("tryit_share_copied",{defaultValue:"Link copied — share it with a friend!"}))}).catch(m):m()}catch{}},[l,r,t]),re=n.useCallback(()=>{g(null),d(""),V(""),h(null),N([]),K(0),T([]),o(0),j(!1),L(null);try{sessionStorage.removeItem(W)}catch{}try{localStorage.removeItem(W)}catch{}},[]),xe=`linear-gradient(to right, ${M.atStart?"black 0%":"transparent 0%, black 56px"}, black calc(100% - ${M.atEnd?"0px":"56px"}), ${M.atEnd?"black 100%":"transparent 100%"})`;return e.jsx("div",{className:"max-w-md mx-auto w-full",children:e.jsx(B,{mode:"wait",children:l?e.jsxs(C.div,{initial:{opacity:0,y:16,scale:.97},animate:{opacity:1,y:0,scale:1},exit:{opacity:0,y:-8},transition:{duration:.32,ease:[.22,1,.36,1]},className:"relative",children:[e.jsxs("div",{className:"flex items-center justify-between mb-3 px-1",children:[e.jsx("button",{onClick:re,className:"text-xs text-muted-foreground hover:text-foreground transition-colors underline-offset-2 hover:underline",children:t("tryit_change_language",{defaultValue:"← Change language"})}),e.jsx("div",{className:"text-xs font-semibold text-success dark:text-success",children:t("tryit_saved_count",{count:f,total:w,defaultValue:`Saved ${f} of ${w}`})})]}),e.jsxs("div",{className:"relative",style:{minHeight:360},children:[v&&e.jsxs("div",{className:"absolute inset-0 rounded-3xl border-2 border-dashed border-border bg-muted/30 flex flex-col items-center justify-center gap-3 z-10 pointer-events-none",children:[e.jsxs("div",{className:"relative",children:[e.jsx("div",{className:"absolute inset-0 rounded-full bg-primary/20 animate-ping"}),e.jsx(F,{className:"relative h-9 w-9 text-primary"})]}),e.jsx("p",{className:"text-sm font-medium text-muted-foreground animate-pulse",children:t("tryit_generating",{defaultValue:"Generating your first cards…"})})]}),y==="rate_limited"&&!v&&e.jsxs("div",{className:"absolute inset-0 bg-card border border-primary/30 rounded-3xl flex flex-col items-center justify-center gap-4 px-8 text-center z-10",children:[e.jsx(F,{className:"h-8 w-8 text-primary"}),e.jsx("p",{className:"text-sm font-semibold text-foreground leading-snug",children:t("tryit_rate_limited",{defaultValue:"You're really into this! Sign up free to keep going."})}),e.jsxs(_,{to:"/login?intent=save_discover",className:"inline-flex items-center gap-2 text-sm font-semibold text-primary-foreground bg-primary hover:bg-primary/90 transition-colors px-5 py-2 rounded-full",children:[t("tryit_gate_cta",{defaultValue:"Sign up free"}),e.jsx(E,{className:"h-4 w-4"})]})]}),y==="content_blocked"&&!v&&e.jsxs("div",{className:"absolute inset-0 bg-card border border-amber-500/30 rounded-3xl flex flex-col items-center justify-center gap-4 px-8 text-center z-10",children:[e.jsx("p",{className:"text-sm font-medium text-amber-600 dar
1k:text-amber-400 leading-snug",children:t("common:content_blocked",{defaultValue:"Your message was flagged. Please keep it focused on language learning."})}),e.jsx("button",{onClick:re,className:"flex items-center gap-2 text-sm font-medium text-primary bg-primary/10 hover:bg-primary/15 transition-colors px-4 py-2 rounded-full",children:t("tryit_change_language",{defaultValue:"← Change language"})})]}),y&&y!=="rate_limited"&&y!=="content_blocked"&&!v&&e.jsxs("div",{className:"absolute inset-0 bg-card border border-border rounded-3xl flex flex-col items-center justify-center gap-4 px-8 text-center z-10",children:[e.jsx("p",{className:"text-sm font-semibold text-foreground",children:t("tryit_error",{defaultValue:"Something went wrong"})}),e.jsxs("button",{onClick:()=>l&&P(l,r),className:"flex items-center gap-2 text-sm font-medium text-primary bg-primary/10 hover:bg-primary/15 transition-colors px-4 py-2 rounded-full",children:[e.jsx(Be,{className:"h-4 w-4"})," ",t("tryit_try_again",{defaultValue:"Try again"})]})]}),!v&&!y&&k&&e.jsx("div",{className:"absolute inset-0",children:e.jsx(B,{mode:"wait",children:e.jsx(Ke,{ref:se,card:k,onSkip:me,onAdd:ue},k.front_text+z)})}),e.jsx(B,{children:c&&e.jsx(C.div,{initial:{opacity:0}
1,animate:{opacity:1},exit:{opacity:0},transition:{duration:.25},className:"absolute inset-0 z-20 backdrop-blur-md bg-background/70 rounded-3xl flex items-center justify-center px-6",children:e.jsxs(C.div,{initial:{scale:.92,opacity:0},animate:{scale:1,opacity:1},exit:{scale:.92,opacity:0},transition:{type:"spring",stiffness:320,damping:28},className:"bg-card border border-border rounded-2xl shadow-2xl p-6 text-center max-w-sm",children:[e.jsx("div",{className:"w-12 h-12 mx-auto mb-3 rounded-full bg-primary/10 flex items-center justify-center",children:e.jsx(Fe,{className:"h-5 w-5 text-primary"})}),e.jsx("h3",{className:"text-lg font-bold text-foreground mb-1.5",children:f>=w?t("tryit_gate_title_strong",{count:f,defaultValue:`You've saved ${f} cards 🎉`}):f>0?t("tryit_gate_title_light",{defaultValue:"Save these for later?"}):t("tryit_gate_title_empty",{defaultValue:"Not quite right?"})}),e.jsx("p",{className:"text-sm text-muted-foreground mb-5 leading-relaxed",children:f>=w?t("tryit_gate_body_strong",{defaultValue:"Sign up to keep them forever and unlock spaced repetition — takes 5 seconds."}):f>0?t("tryit_gate_body_light",{defaultValue:"Sign up to save what you've found and unlock spaced repetition — takes 5 seconds."}):t("tryit_gate_body_empty",{defaultValue:"Sign up to set your level and topic — we'll match cards to you. Takes 5 seconds."})}),e.jsxs(_,{to:"/login?intent=save_discover",className:"flex items-center justify-center gap-2 w-full bg-primary hover:bg-primary/90 text-primary-foreground font-semibold py-3 rounded-xl transition-colors",children:[t("tryit_gate_cta",{defaultValue:"Sign up free"}),e.jsx(E,{className:"h-4 w-4"})]}),e.jsxs("div",{className:"flex items-center justify-center gap-4 mt-3",children:[e.jsx("button",{onClick:re,className:"text-xs text-muted-foreground hover:text-foreground transition-colors",children:t("tryit_gate_dismiss",{defaultValue:"Or try a different language"})}),e.jsx("span",{className:"text-muted-foreground/30",children:"·"}),e.jsxs("button",{onClick:Te,className:"inline-flex items-center gap-1 text-xs text-muted-foreground hover:text-foreground transition-colors",children:[e.jsx(We,{className:"h-3 w-3"}),t("tryit_share_button",{defaultValue:"Share this deck"})]})]})]})})})]}),!c&&!v&&!y&&k&&e.jsxs(e.Fragment,{children:[e.jsx(B,{children:!Ce&&e.jsx(C.p,{initial:{opacity:0,y:-4},animate:{opacity:1,y:0},exit:{opacity:0,y:-4},transition:{duration:.25},className:"text-center text-xs text-muted-foreground mt-4 -mb-1",children:t("tryit_swipe_hint",{defaultValue:"💡 Swipe the card or tap below"})})}),e.jsxs("div",{className:"flex items-center justify-center gap-8 mt-3",children:[e.jsxs("button",{onClick:()=>se.current?.flyOff("left")??me(),"aria-label":t("common:discover_skip",{defaultValue:"Skip"}),className:"group flex flex-col items-center gap-1",children:[e.jsx("div",{className:"w-14 h-14 rounded-full border-2 border-red-400/70 bg-red-50 dark:bg-red-900/10 flex items-center justify-center text-red-400 group-hover:border-red-400 group-hover:bg-red-100 dark:group-hover:bg-red-900/20 group-active:scale-95 transition-all",children:e.jsx(He,{className:"h-6 w-6"})}),e.jsx("span",{className:"text-[10px] font-medium text-muted-foreground",children:t("common:discover_skip",{defaultValue:"Skip"})})]}),e.jsxs("button",{onClick:()=>se.current?.flyOff("right")??ue(),"aria-label":t("common:discover_save",{defaultValue:"Save"}),className:"group flex flex-col items-center gap-1",children:[e.jsx("div",{className:"w-14 h-14 rounded-full border-2 border-success/70 bg-success/10 dark:bg-success/10 flex items-center justify-center text-success group-hover:border-success group-hover:bg-success/15 dark:group-hover:bg-success/20 group-active:scale-95 transition-all shadow-lg shadow-success/10",children:e.jsx(Me,{className:"h-6 w-6"})}),e.jsx("span",{className:"text-[10px] font-medium text-muted-foreground",children:t("common:discover_save",{defaultValue:"Save"})})]})]})]}),f>=1&&f<w&&!c&&e.jsx("p",{className:"text-center text-xs text-muted-foreground/80 mt-3 font-medium",children:f===w-1?t("tryit_almost_there",{defaultValue:"✨ 1 more save and they're yours forever"}):t("tryit_subtle_hint",{remaining:w-f,defaultValue:`${w-f} more saves until signup`})})]},"deck"):e.jsxs(C.div,{initial:{opacity:0,y:8}
1,animate:{opacity:1,y:0},exit:{opacity:0,y:-12},transition:{duration:.22,ease:[.22,1,.36,1]},className:"text-center",children:[e.jsxs("div",{className:"inline-flex items-center gap-2 mb-3 px-3 py-1.5 rounded-full bg-primary/10 text-primary text-xs font-semibold",children:[e.jsx(F,{className:"h-3.5 w-3.5"}),t("tryit_pill",{defaultValue:"Try it now — no signup"})]}),e.jsx("p",{className:"text-lg sm:text-xl font-bold text-foreground mb-1",children:t("tryit_prompt",{defaultValue:"What do you want to learn?"})}),e.jsx("p",{className:"text-xs text-muted-foreground mb-5",children:t("tryit_prompt_subtitle",{defaultValue:"Swipe a few cards in 30 seconds. No signup needed."})}),e.jsxs("div",{className:"relative -mx-1",children:[e.jsx("div",{ref:X,onScroll:Q,className:"grid grid-flow-col grid-rows-2 auto-cols-[calc((100%-1rem)/3.35)] sm:auto-cols-[calc((100%-1.5rem)/4.35)] gap-2 sm:gap-3 overflow-x-auto scroll-smooth snap-x snap-mandatory scrollbar-none px-1 pb-1",style:{scrollbarWidth:"none",maskImage:xe,WebkitMaskImage:xe},children:et.filter(s=>s.code!==U).map(s=>e.jsxs("button",{onClick:()=>Ve(s.code),className:"group snap-start flex min-h-[104px] flex-col items-center justify-center gap-1.5 py-3 px-2 rounded-2xl bg-card hover:bg-muted/50 border border-border hover:border-primary/40 transition-all active:scale-95",children:[e.jsx("span",{className:"text-2xl",children:s.flag}),e.jsx("span",{className:"text-xs font-medium text-foreground/80 group-hover:text-foreground",children:t(`tryit_lang_${s.code}`,{defaultValue:s.name})})]},s.code))}),e.jsxs("div",{className:"flex items-center justify-center gap-2 mt-2",children:[e.jsx("button",{type:"button",onClick:()=>ce(-1),disabled:M.atStart,className:"inline-flex h-7 w-7 items-center justify-center rounded-full border border-border bg-card text-muted-foreground transition-colors hover:border-primary/40 hover:text-foreground disabled:cursor-not-allowed disabled:opacity-35","aria-label":t("tryit_languages_previous",{defaultValue:"Previous languages"}),children:e.jsx($e,{className:"h-4 w-4"})}),e.jsx("button",{type:"button",onClick:()=>ce(1),disabled:M.atEnd,className:"inline-flex h-7 w-7 items-center justify-center rounded-full border border-border bg-card text-muted-foreground transition-colors hover:border-primary/40 hover:text-foreground disabled:cursor-not-allowed disabled:opacity-35","aria-label":t("tryit_languages_next",{defaultValue:"More languages"}),children:e.jsx(Oe,{className:"h-4 w-4"})})]})]}),e.jsxs("div",{className:"mt-4",children:[e.jsx("button",{type:"button",onClick:()=>{Se(s=>!s),H||setTimeout(()=>de.current?.focus(),100)},className:"inline-flex items-center gap-1.5 text-xs font-medium text-muted-foreground hover:text-foreground transition-colors",children:H?t("tryit_hide_goal",{defaultValue:"× Hide goal input"}):t("tryit_describe_goal",{defaultValue:"+ Describe your goal"})}),e.jsx(B,{initial:!1,children:H&&e.jsx(C.div,{initial:{height:0,opacity:0},animate:{height:"auto",opacity:1},exit:{height:0,opacity:0},transition:{duration:.22,ease:[.22,1,.36,1]},className:"overflow-hidden",children:e.jsxs("form",{onSubmit:s=>{s.preventDefault(),Le()},className:"mt-3",children:[e.jsxs("div",{className:`relative flex items-center rounded-2xl border bg-card transition-colors ${u?"border-red-400 focus-within:border-red-500":"border-border focus-within:border-primary"}`,children:[e.jsx("input",{ref:de,type:"text",value:x,onChange:s=>{V(s.target.value),u&&h(null)},placeholder:be[I],className:"flex-1 bg-transparent px-4 py-3 text-sm text-foreground placeholder:text-muted-foreground focus:outline-none rounded-2xl","aria-label":t("tryit_goal_aria",{defaultValue:"Describe what you want to learn"})}),e.jsx("button",{type:"submit",disabled:!x.trim(),className:"m-1 shrink-0 inline-flex items-center justify-center w-8 h-8 rounded-xl bg-primary text-primary-foreground disabled:bg-muted disabled:text-muted-foreground/60 transition-colors active:scale-95","aria-label":t("tryit_submit_goal",{defaultValue:"Generate cards"}),children:e.jsx(ve,{className:"h-4 w-4",strokeWidth:2.5})})]}),u&&e.jsx("p",{className:"text-xs text-red-500 mt-2 text-left px-1",children:t("tryit_goal_no_lang",{defaultValue:'Add a language — try "Italian for travel" or "Japanese N5".'})})]})})})]})]},"picker")})})}const ye="tryit_session_v2",je=["Italian for travel","Spanish for ordering coffee","Japanese N5 kanji","French for office meetings","Polish basics for visiting family","Korean for K-pop lyrics"],rt=3e3,nt=[{code:"es",flag:"🇪🇸"},{code:"fr",flag:"🇫🇷"},{code:"de",flag:"🇩🇪"},{code:"it",flag:"🇮🇹"},{code:"ja",flag:"🇯🇵"},{code:"ko",flag:"🇰🇷"},{code:"pl",flag:"🇵🇱"},{code:"pt",flag:"🇵🇹"}];function lt(t){const a=t.trim();return a.length<4||/^(.)\1+$/.test(a)?!1:/[aeiouаеиіїоуeyаоуыэіїі]/i.test(a)&&/[a-zа-яії]{2,}/i.test(a)}function ot(){const{t,i18n:a}=oe("home"),p=a.language?.split("-")[0]||"en",[l,g]=n.useState(""),[r,d]=n.useState(null),[x,V]=n.useState(!1),[u,h]=n.useState([]),[b,N]=n.useState(null),[z,K]=n.useState(0),v=n.useRef(null),q=t(`demo_generate_ph_${z+1}`,{defaultValue:je[z]});n.useEffect(()=>{if(l.trim().length>0||u.length>0||x)return;const o=setInterval(()=>{K(c=>(c+1)%je.length)},rt);return()=>clearInterval(o)},[l,u.length,x]);const y=n.useCallback(async(o,c)=>{d(null),N(o),V(!0),h([]);const j=600,Z=performance.now();try{const $=await le.getAnonFeed({language:o,level:"A2",source_language:p,count:5,topic:c||null}),I=performance.now()-Z;I<j&&await new Promise(ae=>setTimeout(ae,j-I)),h($.cards)}catch($){const I=$;I.status===429?d("rate_limited"):I.details?.detail?.code==="content_blocked"||I.details?.code==="content_blocked"?d("content_blocked"):d("generation_failed")}finally{V(!1)}},[p]),L=n.useCallback(()=>{const o=l.trim();if(!o||x)return;const c=we(o);if(!c){N(null),h([]),d("pick_language");return}const j=ke(o,c)?"":o;y(c,j)},[l,x,y]),A=n.useCallback(o=>{const c=l.trim(),j=lt(c)?c:"";y(o,j)},[l,y]),T=n.useCallback(()=>{g(""),h([]),N(null),d(null),setTimeout(()=>v.current?.focus(),50)},[]),D=n.useCallback(()=>
1{if(!b||u.length===0)return;const o=JSON.stringify({lang:b,topic:l,savedCards:u,swipedTotal:u.length});try{sessionStorage.setItem(ye,o)}catch{}try{localStorage.setItem(ye,o)}catch{}},[b,l,u]);return e.jsxs("div",{className:"bg-card rounded-2xl border border-border shadow-lg overflow-hidden",children:[e.jsxs("div",{className:"flex items-center gap-2 px-4 py-3 border-b border-border bg-muted/30",children:[e.jsx("div",{className:"w-7 h-7 rounded-full bg-gradient-to-br from-amber-500 to-orange-500 flex items-center justify-center",children:e.jsx(Ne,{className:"w-3.5 h-3.5 text-white"})}),e.jsx("p",{className:"text-sm font-medium text-foreground",children:t("demo_generate_title",{defaultValue:"Deck Generator"})}),b&&e.jsx("span",{className:"ml-auto text-[10px] font-bold uppercase tracking-widest text-primary bg-primary/10 px-2 py-0.5 rounded-full",children:b.toUpperCase()})]}),e.jsxs("div",{className:"p-4 space-y-3",children:[e.jsxs("form",{onSubmit:o=>{o.preventDefault(),L()},className:"rounded-xl border border-border bg-muted/30 px-3 py-3 transition-colors focus-within:border-primary/70 focus-within:bg-card focus-within:ring-2 focus-within:ring-primary/15",children:[e.jsx("label",{htmlFor:"homepage-deck-topic",className:"block text-xs font-semibold text-foreground mb-1",children:t("demo_generate_prompt",{defaultValue:"What do you want to learn?"})}),e.jsx("p",{className:"text-[11px] text-muted-foreground mb-2",children:t("demo_generate_hint",{defaultValue:"Type a language and topic — for example, “Japanese N5 kanji”."})}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("input",{ref:v,id:"homepage-deck-topic",type:"text",value:l,onChange:o=>{g(o.target.value),r&&d(null),u.length>0&&(h([]),N(null))},placeholder:q,disabled:x,className:"min-w-0 flex-1 bg-transparent text-sm font-medium text-foreground placeholder:text-muted-foreground focus:outline-none disabled:opacity-50","aria-label":t("demo_generate_aria",{defaultValue:"Type a topic to generate cards for"})}),u.length===0?e.jsxs("button",{type:"submit",disabled:!l.trim()||x,className:"shrink-0 inline-flex h-9 items-center justify-center gap-1.5 rounded-lg bg-primary px-3 text-xs font-semibold text-primary-foreground transition-colors hover:bg-primary/90 disabled:bg-muted disabled:text-muted-foreground/60 active:scale-95",children:[e.jsx(ve,{className:"h-4 w-4",strokeWidth:2.5}),t("demo_generate_button",{defaultValue:"Generate deck"})]}):e.jsx("button",{type:"button",onClick:T,className:"shrink-0 text-xs font-semibold text-primary hover:underline px-2 py-1",children:t("demo_generate_new",{defaultValue:"New"})})]})]}),r==="pick_language"&&e.jsxs("div",{className:"space-y-2 px-1 animate-in fade-in duration-200",children:[e.jsx("p",{className:"text-xs text-muted-foreground",children:t("demo_generate_pick_lang",{defaultValue:"Pick a language to start:"})}),e.jsx("div",{className:"flex flex-wrap gap-1.5",children:nt.filter(o=>o.code!==a.language).map(o=>e.jsxs("button",{type:"button",onClick:()=>A(o.code),className:"inline-flex items-center gap-1.5 text-xs font-medium text-foreground bg-muted/60 hover:bg-primary/15 hover:text-primary border border-border hover:border-primary/30 rounded-full px-2.5 py-1 transition-colors",children:[e.jsx("span",{className:"text-sm leading-none",children:o.flag}),t(`tryit_lang_${o.code}`,{defaultValue:o.code.toUpperCase()})]},o.code))})]}),r==="content_blocked"&&e.jsx("p",{className:"text-xs text-amber-600 dark:text-amber-400 px-1",children:t("common:content_blocked",{defaultValue:"Your message was flagged for inappropriate content. Please keep it focused on language learning."})}),r==="rate_limited"&&e.jsxs("div",{className:"flex items-center justify-between gap-2 px-3 py-2 rounded-lg bg-primary/8 border border-primary/20 animate-in fade-in duration-200",children:[e.jsx("p",{className:"text-xs text-foreground leading-snug",children:t("demo_generate_rate_limited",{defaultValue:"You're on a roll! Sign up free to keep generating."})}),e.jsxs(_,{to:"/login?intent=save_discover",className:"shrink-0 inline-flex items-center gap-1 text-xs font-semibold text-primary hover:underline",children:[t("demo_generate_save_cta",{defaultValue:"Sign up"}),e.jsx(E,{className:"h-3 w-3"})]})]}),r==="generation_failed"&&e.jsx("p",{className:"text-xs text-red-500 px-1",children:t("demo_generate_error",{defaultValue:"Generation failed. Try again."})}),x&&e.jsxs("div",{className:"flex items-center justify-center gap-2 py-2 px-4 roun
1ded-lg text-sm font-medium bg-primary/10 text-primary",children:[e.jsx("div",{className:"h-3.5 w-3.5 border-2 border-primary border-t-transparent rounded-full animate-spin"}),t("demo_generating",{defaultValue:"Generating cards…"})]}),e.jsx(B,{children:!x&&u.length>0&&e.jsx(C.div,{initial:{opacity:0},animate:{opacity:1},transition:{staggerChildren:.08},className:"space-y-1.5",children:u.map((o,c)=>e.jsxs(C.div,{initial:{opacity:0,y:8},animate:{opacity:1,y:0},transition:{duration:.3,delay:c*.08},className:"flex items-center justify-between rounded-lg border border-primary/20 bg-primary/5 px-3 py-2",children:[e.jsx("span",{className:"text-sm font-medium text-foreground",children:o.front_text}),e.jsx("span",{className:"text-xs text-muted-foreground truncate ml-3 max-w-[55%]",children:o.back_text})]},o.front_text+c))})}),!x&&u.length>0&&e.jsxs(C.div,{initial:{opacity:0,y:4},animate:{opacity:1,y:0},transition:{delay:u.length*.08+.2},className:"flex items-center justify-between gap-2 pt-1",children:[e.jsxs("div",{className:"flex items-center gap-1.5 px-2.5 py-1 rounded-full bg-success/10 dark:bg-success/10 border border-success/30 dark:border-success/20",children:[e.jsx(Y,{className:"w-3 h-3 text-success"}),e.jsx("span",{className:"text-[11px] text-success dark:text-success font-medium",children:t("demo_generate_done",{count:u.length,defaultValue:`${u.length} cards ready`})})]}),e.jsxs(_,{to:"/login?intent=save_discover",onClick:D,className:"inline-flex items-center gap-1 text-xs font-semibold text-primary hover:underline",children:[e.jsx(F,{className:"h-3 w-3"}),t("demo_generate_save_cta",{defaultValue:"Sign up to save"}),e.jsx(E,{className:"h-3 w-3"})]})]})]})]})}const it=[{word:"Ciao",top:"18%",left:"6%",delay:"0s",size:"1.1rem",rot:"-12deg"},{word:"Hola",top:"22%",right:"7%",delay:"1.4s",size:"1.2rem",rot:"8deg"},{word:"Bonjour",top:"68%",left:"4%",delay:"2.7s",size:"0.9rem",rot:"-6deg"},{word:"日本語",top:"60%",right:"5%",delay:"0.9s",size:"0.95rem",rot:"10deg"},{word:"Привіт",top:"40%",left:"2.5%",delay:"3.2s",size:"0.85rem",rot:"-15deg"},{word:"Danke",top:"78%",right:"8%",delay:"1.8s",size:"1rem",rot:"5deg"},{word:"Grazie",top:"12%",right:"14%",delay:"2.1s",size:"0.9rem",rot:"-8deg"},{word:"Merci",top:"52%",left:"9%",delay:"0.5s",size:"0.95rem",rot:"12deg"}];function vt(){const{isAuthenticated:t}=De(),{t:a}=oe("home"),[p]=_e(),l=p.get("source")===pe&&p.get("intent")===ge;if(Ge(),n.useEffect(()=>{Xe(p)&&te("beta_entry_opened",{source:pe,intent:ge})},[p]),t)return e.jsx(ze,{to:"/dashboard",replace:!0});const g=[{step:"1",titleKey:"step1_title",descKey:"step1_desc",icon:Ue,delay:"0ms"},{step:"2",titleKey:"step2_title",descKey:"step2_desc",icon:F,delay:"100ms"},{step:"3",titleKey:"step3_title",descKey:"step3_desc",icon:Je,delay:"200ms"}];return e.jsxs("div",{className:"min-h-screen bg-background",children:[e.jsxs(Pe,{children:[e.jsx("title",{children:"Kometri — Your conversations, remembered."}),e.jsx("meta",{name:"description",content:"Talk with an AI language tutor. Kometri catches the words worth keeping and brings them back at the right time."}),e.jsx("link",{rel:"canonical",href:"https://kometri.com/"}),e.jsx("meta",{name:"robots",content:"index, follow, max-image-preview:large, max-snippet:-1, max-video-preview:-1"}),e.jsx("meta",{property:"og:url",content:"https://kometri.com/"}),e.jsx("meta",{property:"og:title",content:"Kometri — Your conversations, remembered."}),e.jsx("meta",{property:"og:description",content:"Words that find their way back. Talk naturally, keep the vocabulary that matters, and remember it for good."})]}),e.jsxs("section",{className:"relative py-12 sm:py-28 overflow-hidden",children:[e.jsxs("div",{className:"absolute inset-0 pointer-events-none",children:[e.jsx("div",{className:"absolute top-0 left-1/2 -translate-x-1/2 w-[900px] h-[550px] bg-gradient-to-br from-primary/25 to-[#355126]/5 rounded-full blur-3xl"}),e.jsx("div",{className:"absolute bottom-0 right-1/4 w-[500px] h-[300px] bg-gradient-to-tl from-primary/10 to-transparent rounded-full blur-3xl"})]}),e.jsx("div",{className:"hidden sm:block absolute inset-0 overflow-hidden pointer-events-none select-none",children:it.map((r,d)=>
1e.jsx("span",{className:"absolute font-bold text-foreground/[0.055] dark:text-foreground/[0.04]",style:{top:r.top,left:r.left,right:r.right,fontSize:r.size,transform:`rotate(${r.rot})`,animation:"float 5s ease-in-out infinite",animationDelay:r.delay},children:r.word},d))}),e.jsxs("div",{className:"max-w-5xl mx-auto px-4 sm:px-6 lg:px-8 relative",children:[l&&e.jsxs("div",{className:"mx-auto mb-6 max-w-2xl rounded-2xl border border-primary/30 bg-primary/10 p-4 text-center animate-in",children:[e.jsx("p",{className:"text-sm font-semibold text-foreground",children:a("reddit_beta_title")}),e.jsx("p",{className:"mt-1 text-sm text-muted-foreground",children:a("reddit_beta_subtitle")}),e.jsx(_,{to:"/login?source=reddit&intent=generate_deck",className:"mt-3 inline-block",children:e.jsxs(O,{variant:"brand",size:"sm",children:[a("reddit_beta_cta")," ",e.jsx(E,{className:"ml-1.5 h-4 w-4"})]})})]}),e.jsxs("div",{className:"text-center animate-in mb-6 sm:mb-8",children:[e.jsx("div",{className:"flex justify-center mb-4 sm:mb-6",children:e.jsxs("span",{className:"inline-flex items-center gap-1.5 px-3 py-1.5 rounded-full bg-primary/20 border border-primary/35 text-xs font-semibold text-language",children:[e.jsx(F,{className:"w-3 h-3"}),a("hero_pre_title")]})}),e.jsxs("h1",{className:"text-3xl sm:text-6xl lg:text-7xl font-extrabold tracking-tight text-foreground leading-[1.1]",children:[a("hero_title")," ",e.jsx("span",{className:"text-language",children:a("hero_gradient")})]}),e.jsx("p",{className:"mt-4 sm:mt-6 text-base sm:text-xl leading-relaxed text-muted-foreground max-w-2xl mx-auto",children:a("hero_subtitle")})]}),e.jsx(st,{}),t&&e.jsx("div",{className:"mt-8 sm:mt-12 text-center",children:e.jsx(_,{to:"/dashboard",children:e.jsxs(O,{variant:"brand",size:"lg",children:[a("go_to_dashboard"),e.jsx(E,{className:"ml-2 h-4 w-4"})]})})})]})]}),e.jsxs("section",{className:"relative overflow-hidden py-14 sm:py-32 border-t border-border",children:[e.jsx("div",{className:"pointer-events-none absolute inset-x-0 top-0 h-full bg-[radial-gradient(ellipse_at_50%_38%,hsl(var(--primary)/0.075),transparent_56%)]"}),e.jsxs("div",{className:"relative max-w-5xl mx-auto px-4 sm:px-6 lg:px-8",children:[e.jsxs("div",{className:"text-center mb-8 sm:mb-16 animate-in",children:[e.jsx("h2",{className:"text-2xl sm:text-4xl font-bold tracking-tight text-foreground",children:a("how_it_works")}),e.jsx("p",{className:"mt-2 sm:mt-4 text-sm sm:text-lg text-muted-foreground max-w-xl mx-auto",children:a("how_subtitle")}),e.jsx("div",{className:"mt-5 flex justify-center gap-1.5","aria-hidden":"true",children:g.map((r,d)=>e.jsx("span",{className:`h-1.5 rounded-full ${d===0?"w-7 bg-primary":"w-1.5 bg-primary/30"}`},r.step))})]}),e.jsxs("div",{className:"relative overflow-hidden rounded-[28px] border border-border/70 bg-card/65 shadow-[0_20px_60px_-35px_hsl(var(--primary)/0.45)] sm:hidden",children:[e.jsx("div",{className:"pointer-events-none absolute left-[43px] top-12 bottom-12 w-px bg-gradient-to-b from-primary/70 via-primary/25 to-primary/5"}),g.map((r,d)=>e.jsxs("article",{className:`relative grid grid-cols-[52px_1fr] gap-4 px-5 py-6 ${d<g.length-1?"border-b border-border/55":""}`,children:[e.jsxs("div",{className:"relative z-10 flex h-12 w-12 items-center justify-center rounded-2xl border border-primary/25 bg-gradient-to-br from-primary/20 to-success/5 shadow-[0_8px_20px_-12px_hsl(var(--primary)/0.8)]",children:[e.jsx(r.icon,{className:"h-5 w-5 text-primary",strokeWidth:2.35}),e.jsx("span",{className:"absolute -right-1.5 -top-1.5 flex h-5 w-5 items-center justify-center rounded-full bg-primary text-[10px] font-bold text-primary-foreground shadow shadow-primary/35",children:r.step})]}),e.jsxs("div",{className:"min-w-0 pt-0.5",children:[e.jsxs("span",{className:"text-[10px] font-bold tracking-[0.16em] text-primary/75",children:["0",r.step]}),e.jsx("h3",{className:"mt-1 text-[17px] font-semibold tracking-tight text-foreground",children:a(r.titleKey)}),e.jsx("p",{className:"mt-2 text-sm leading-6 text-muted-foreground",children:a(r.descKey)})]})]},r.step))]}),e.jsx("div",{className:"relative hidden sm:grid grid-cols-3 gap-6",children:g.map((r,d)=>e.jsxs("div",{className:"animate-slide-up relative flex flex-col items-center text-center p-7 rounded-2xl border border-border/60 bg-card/80 hover:-translate-y-1 hover:border-primary/30 hover:shadow-xl hover:shadow-
1primary/5 transition-all duration-300",style:{animationDelay:r.delay},children:[e.jsxs("div",{className:"relative z-10 mb-5",children:[e.jsx("div",{className:"flex h-16 w-16 items-center justify-center rounded-2xl bg-gradient-to-br from-primary/20 to-success/5 border border-primary/25 shadow-[0_10px_25px_-15px_hsl(var(--primary)/0.9)]",children:e.jsx(r.icon,{className:"h-7 w-7 text-primary"})}),e.jsx("span",{className:"absolute -top-2.5 -right-2.5 flex h-6 w-6 items-center justify-center rounded-full bg-primary text-primary-foreground text-[11px] font-bold shadow shadow-primary/30",children:r.step})]}),d<g.length-1&&e.jsx("span",{"aria-hidden":"true",className:"pointer-events-none absolute -right-6 top-11 z-0 h-px w-6 bg-gradient-to-r from-primary/25 via-primary/60 to-primary/25"}),e.jsxs("span",{className:"text-[10px] font-bold tracking-[0.16em] text-primary/75",children:["0",r.step]}),e.jsx("h3",{className:"text-lg font-semibold text-foreground",children:a(r.titleKey)}),e.jsx("p",{className:"mt-2 text-sm leading-relaxed text-muted-foreground",children:a(r.descKey)})]},r.step))})]})]}),e.jsx("section",{className:"py-16 sm:py-32 border-t border-border",children:e.jsx("div",{className:"max-w-5xl mx-auto px-4 sm:px-6 lg:px-8",children:e.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-10 lg:gap-12 items-center",children:[e.jsxs("div",{className:"animate-slide-up",children:[e.jsxs("div",{className:"inline-flex items-center gap-2 px-3 py-1.5 rounded-full bg-amber-500/10 border border-amber-500/20 mb-4",children:[e.jsx(Ne,{className:"h-3.5 w-3.5 text-amber-500"}),e.jsx("span",{className:"text-xs font-semibold text-amber-600 dark:text-amber-400",children:a("demo_generate_badge")})]}),e.jsx("h2",{className:"text-2xl sm:text-4xl font-bold tracking-tight text-foreground",children:a("demo_generate_heading")}),e.jsx("p",{className:"mt-4 text-base sm:text-lg text-muted-foreground leading-relaxed",children:a("demo_generate_desc")}),e.jsx("ul",{className:"mt-6 space-y-3",children:["demo_generate_point1","demo_generate_point2","demo_generate_point3"].map(r=>e.jsxs("li",{className:"flex items-start gap-3 text-sm text-muted-foreground",children:[e.jsx(Y,{className:"h-4 w-4 text-amber-500 flex-shrink-0 mt-0.5"}),a(r)]},r))})]}),e.jsx("div",{className:"animate-slide-up",style:{animationDelay:"100ms"},children:e.jsx(ot,{})})]})})}),e.jsx("section",{className:"py-12 sm:py-28 border-t border-border",children:e.jsxs("div",{className:"max-w-5xl mx-auto px-4 sm:px-6 lg:px-8",children:[e.jsxs("div",{className:"text-center mb-8 sm:mb-12 animate-in",children:[e.jsx("h2",{className:"text-2xl sm:text-4xl font-bold tracking-tight text-foreground",children:a("comparison_title")}),e.jsx("p",{className:"mt-2 sm:mt-3 text-sm sm:text-base text-muted-foreground",children:a("comparison_subtitle")})]}),e.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-4 sm:gap-5",children:[{titleKey:"comparison_vs_anki_title",bodyKey:"comparison_vs_anki_body",icon:Ye,iconBg:"bg-blue-500/10",iconFg:"text-blue-500",cardBg:"bg-gradient-to-br from-blue-500/[0.06] to-transparent",cardBorder:"border-blue-500/15 hover:border-blue-500/30"},{titleKey:"comparison_vs_duolingo_title",bodyKey:"comparison_vs_duolingo_body",icon:qe,iconBg:"bg-success/10",iconFg:"text-success",cardBg:"bg-gradient-to-br from-success/[0.06] to-transparent",cardBorder:"border-success/15 hover:border-success/30"},{titleKey:"comparison_vs_quizlet_title",bodyKey:"comparison_vs_quizlet_body",icon:Ze,iconBg:"bg-violet-500/10",iconFg:"text-violet-500",cardBg:"bg-gradient-to-br from-violet-500/[0.06] to-transparent",cardBorder:"border-violet-500/15 hover:border-violet-500/30"}].map(({titleKey:r,bodyKey:d,icon:x,iconBg:V,iconFg:u,cardBg:h,cardBorder:b},N)=>e.jsxs("div",{className:`animate-slide-up ${h} border ${b} rounded-2xl p-6 flex flex-col gap-4 transition-colors`,style:{animationDelay:`${N*80}ms`},children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx("div",{className:`w-9 h-9 rounded-lg ${V} flex items-center justify-center flex-shrink-0`,children:e.jsx(x,{className:`h-4 w-4 ${u}`,strokeWidth:2.25})}),e.jsx("h3",{className:"text-lg font-bold text-foreground tracking-tight",children:a(r)})]}),e.jsx("p",{className:"text-[15px] text-muted-foreground leading-[1.65]",children:a(d)})]},r))}),e.jsx("div",{className:"mt-6 sm:mt-8 flex justify-center animate-in",children:e.jsxs(_,{to:"/import/anki",className:"inline-flex items-center gap-2 px-4 py-2.5 rounded-full border border-border bg-card hover:bg-muted/50 transition-colors text-sm",children:[e.jsx("span",{className:"text-foreground font-medium",children:a("comparison_anki_migrate_cta")}),e.jsx(E,{className:"h-4 w-4 text-muted-foreground"})]})})]})}),!1,e.jsx("section",{className:"py-12 sm:py-32 border-t border-border",children:e.jsxs("div",{className:"max-w-4xl mx-auto px-4 sm:px-6 lg:px-8",children:[e.jsxs("div",{className:"text-center mb-8 sm:mb-16 animate-in",children:[e.jsx("h2",{className:"text-2xl sm:text-4xl font-bold tracking-tight text-foreground",children:a("pricing_title")}),e.jsx("p",{className:"mt-2 sm:mt-4 text-sm sm:text-lg text-muted-foreground max-w-xl mx-auto",children:a("pricing_subtitle")})]}),e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-4 sm:gap-6 max-w-4xl mx-auto",children:[e.jsxs("div",{className:"animate-slide-up rounded-2xl border border-border/60 bg-gradient-to-b from-slate-500/[0.04] to-transparent p-5 sm:p-8 flex flex-col",children:[e.jsxs("div",{children:[e.jsx("h3",{className:"text-lg font-semibold text-foreground",children:a("plan_free")}),e.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:a("plan_free_desc")})]}),e.jsxs("div",{className:"mt-5 flex items-end gap-1",children:[e.jsx("span",{className:"text-5xl font-extrabold tracking-tight text-foreground",children:"$0"}),e.jsxs("span",{className:"text-muted-foreground mb-1.5 text-sm",children:["/",a("plan_month")]})]}),e.jsx("ul",{className:"mt-6 space-y-2.5 flex-1",children:[a("plan_free_flashcards"),a("plan_free_decks"),a("plan_free_ai")].map(r=>e.jsxs("li",{className:"flex items-center gap-2.5 text-sm text-muted-foreground",children:[e.jsx("div",{className:"flex-shrink-0 h-4 w-4 roun
1ded-full bg-slate-500/10 flex items-center justify-center",children:e.jsx(Y,{className:"h-2.5 w-2.5 text-slate-500"})}),r]},r))}),e.jsx("div",{className:"mt-8",children:e.jsx(_,{to:"/login",children:e.jsx(O,{variant:"outline",size:"lg",className:"w-full",children:a("get_started")})})})]}),e.jsxs("div",{className:"animate-slide-up rounded-2xl border-2 border-primary/60 bg-gradient-to-b from-primary/[0.08] to-transparent p-5 sm:p-8 relative flex flex-col shadow-lg shadow-primary/10",style:{animationDelay:"80ms"},children:[e.jsx("div",{className:"absolute -top-3.5 left-1/2 -translate-x-1/2 px-3 py-1 bg-primary rounded-full text-xs font-semibold text-primary-foreground shadow shadow-primary/30 whitespace-nowrap",children:a("plan_popular")}),e.jsxs("div",{children:[e.jsx("h3",{className:"text-lg font-semibold text-foreground",children:a("plan_pro")}),e.jsx("p",{className:"text-xs text-language dark:text-language mt-0.5",children:a("plan_pro_desc")})]}),e.jsxs("div",{className:"mt-5 flex items-end gap-1",children:[e.jsx("span",{className:"text-5xl font-extrabold tracking-tight text-foreground",children:"$4.99"}),e.jsxs("span",{className:"text-muted-foreground mb-1.5 text-sm",children:["/",a("plan_month")]})]}),e.jsx("ul",{className:"mt-6 space-y-2.5 flex-1",children:[a("plan_pro_flashcards"),a("plan_pro_decks"),a("plan_pro_ai")].map(r=>e.jsxs("li",{className:"flex items-center gap-2.5 text-sm text-foreground/80",children:[e.jsx("div",{className:"flex-shrink-0 h-4 w-4 rounded-full bg-primary/15 flex items-center justify-center",children:e.jsx(Y,{className:"h-2.5 w-2.5 text-language"})}),r]},r))}),e.jsx("div",{className:"mt-8",children:e.jsx(_,{to:"/pricing",children:e.jsx(O,{variant:"brand",size:"lg",className:"w-full",children:a("plan_upgrade")})})})]}),e.jsxs("div",{className:"animate-slide-up rounded-2xl border border-violet-500/20 bg-gradient-to-b from-violet-500/[0.06] to-transparent p-5 sm:p-8 flex flex-col",style:{animationDelay:"160ms"},children:[e.jsxs("div",{children:[e.jsx("h3",{className:"text-lg font-semibold text-foreground",children:a("plan_premium")}),e.jsx("p",{className:"text-xs text-violet-600 dark:text-violet-400 mt-0.5",children:a("plan_premium_desc")})]}),e.jsxs("div",{className:"mt-5 flex items-end gap-1",children:[e.jsx("span",{className:"text-5xl font-extrabold tracking-tight text-foreground",children:"$14.99"}),e.jsxs("span",{className:"text-muted-foreground mb-1.5 text-sm",children:["/",a("plan_month")]})]}),e.jsx("ul",{className:"mt-6 space-y-2.5 flex-1",children:[a("plan_premium_unlimited"),a("plan_premium_ai"),a("plan_premium_ai_quota")].map(r=>e.jsxs("li",{className:"flex items-center gap-2.5 text-sm text-foreground/80",children:[e.jsx("div",{className:"flex-shrink-0 h-4 w-4 rounded-full bg-violet-500/10 flex items-center justify-center",children:e.jsx(Y,{className:"h-2.5 w-2.5 text-violet-500"})}),r]},r))}),e.jsx("div",{className:"mt-8",children:e.jsx(_,{to:"/pricing",children:e.jsx(O,{variant:"default",size:"lg",className:"w-full border-violet-500/20 hover:border-violet-500/40",children:a("plan_upgrade")})})})]})]}),e.jsxs("div",{className:"text-center mt-6 space-y-2",children:[e.jsx("p",{className:"text-xs text-muted-foreground",children:a("pricing_trust")}),e.jsxs(_,{to:"/pricing",className:"text-sm font-medium text-primary hover:text-primary/80 transition-colors",children:[a("full_pricing_details")," ",e.jsx(E,{className:"inline h-4 w-4 ml-1"})]})]})]})}),!t&&e.jsx("section",{className:"border-t border-border",children:e.jsxs("div",{className:"max-w-2xl mx-auto px-4 sm:px-6 lg:px-8 py-12 sm:py-28 text-center",children:[e.jsx("p",{className:"text-xs sm:text-sm font-medium text-primary mb-2 sm:mb-3",children:a("cta_ready")}),e.jsx("h2",{className:"text-2xl sm:text-4xl font-bold tracking-tight text-foreground",children:a("cta_title")}),e.jsx("p",{className:"mt-4 text-muted-foreground max-w-md mx-auto",children:a("cta_subtitle")}),e.jsx("div",{className:"mt-8 flex items-center justify-center gap-3",children:e.jsx(_,{to:"/login",children:e.jsxs(O,{variant:"brand",size:"lg",className:"btn-attention",children:[a("cta_button"),e.jsx(E,{className:"ml-2 h-4 w-4"})]})})}),e.jsx("p",{className:"mt-4 text-xs text-muted-foreground",children:a("no_credit_card")})]})})]})}export{vt as default};

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.