import{j as e}from"./query-vendor-CZu0EHPe.js";import{f as d,r as l,L as o}from"./react-vendor-0bvDbF03.js";import{S as x,B as n,H as u}from"./index-Ddmt5XbY.js";import{B as h}from"./BreadcrumbNavigation-CKxM9NzV.js";import{u as p}from"./i18n-vendor-Cl4-lKeC.js";import{B as c}from"./book-open-FKdwgD56.js";import{S as g}from"./search-lYLVg_5l.js";import{A as b}from"./arrow-left-DWNOHOEa.js";import"./supabase-vendor-CNV44oIa.js";import"./helmet-vendor-NlTFkN97.js";const L=()=>{const{t:s}=p("notfound"),a=d(),[i,m]=l.useState([]);return l.useEffect(()=>{console.error("404 Error: User attempted to access non-existent route:",a.pathname);const t=a.pathname.toLowerCase(),r=[];t.includes("story")&&r.push("stories"),t.includes("read")&&r.push("reading-cart"),t.includes("progress")&&r.push("progress"),t.includes("vocab")&&r.push("vocabulary"),t.includes("about")&&r.push("about"),t.includes("contact")&&r.push("contact"),(t.includes("subscription")||t.includes("subscribe"))&&r.push("subscription"),m(r.slice(0,3))},[a.pathname]),e.jsxs(e.Fragment,{children:[e.jsx(x,{title:s("meta.title"),description:s("meta.description"),noIndex:!0}),e.jsxs("div",{className:"container px-4 md:px-6 py-8 max-w-4xl mx-auto",children:[e.jsx(h,{items:[{name:"Home",path:"/"},{name:"404 Error",path:a.pathname}]}),e.jsxs("div",{className:"text-center max-w-2xl mx-auto",children:[e.jsx("div",{className:"mb-8 flex justify-center",children:e.jsxs("div",{className:"relative",children:[e.jsx("div",{className:"absolute -inset-6 rounded-full bg-nature-coral opacity-30 blur-xl animate-pulse"}),e.jsx("div",{className:"relative bg-gradient-to-br from-nature-coral to-nature-red p-6 rounded-full",children:e.jsx(c,{className:"h-16 w-16 text-white"})})]})}),e.jsx("h1",{className:"text-7xl font-bold mb-4 bg-gradient-to-r from-nature-red to-nature-coral bg-clip-text text-transparent",children:"404"}),e.jsx("h2",{className:"text-3xl font-semibold mb-4 text-nature-red",children:s("heading.main")}),e.jsx("p",{className:"text-lg text-nature-green mb-2",children:s("heading.description")}),e.jsxs("p",{className:"text-sm text-muted-foreground mb-8",children:[s("heading.attemptedPath")," ",e.jsx("code",{className:"bg-gray-100 px-2 py-1 rounded text-xs",children:a.pathname})]}),i.length>0&&e.jsxs("div",{className:"mb-8 p-4 bg-nature-yellow/10 rounded-xl border border-nature-yellow/20",children:[e.jsxs("h3",{className:"text-sm font-medium text-nature-green mb-3 flex items-center gap-2",children:[e.jsx(g,{className:"h-4 w-4"}),s("suggestions.title")]}),e.jsx("div",{className:"flex flex-wrap gap-2 justify-center",children:i.map(t=>e.jsx(o,{to:`/${t}`,children:e.jsx(n,{variant:"outline",size:"sm",className:"border-nature-teal text-nature-teal hover:bg-nature-teal/10",children:t.charAt(0).toUpperCase()+t.slice(1).replace("-"," ")})},t))})]}),e.jsxs("div",{className:"flex flex-col sm:flex-row gap-4 justify-center mb-8",children:[e.jsx(o,{to:"/",children:e.jsxs(n,{size:"lg",className:"bg-nature-teal hover:bg-nature-teal/80 text-white flex items-center gap-2",children:[e.jsx(u,{className:"h-5 w-5"}),s("buttons.returnHome")]})}),e.jsx(o,{to:"/stories",children:e.jsxs(n,{size:"lg",variant:"outline",className:"border-nature-coral text-nature-coral hover:bg-nature-coral/10 flex items-center gap-2",children:[e.jsx(c,{className:"h-5 w-5"}),s("buttons.exploreStories")]})}),e.jsxs(n,{size:"lg",variant:"ghost",onClick:()=>window.history.back(),className:"text-nature-green hover:bg-nature-green/10 flex items-center gap-2",children:[e.jsx(b,{className:"h-5 w-5"}),s("buttons.goBack")]})]}),e.jsxs("div",{className:"bg-white rounded-xl p-6 shadow-md border border-gray-100",children:[e.jsx("h3",{className:"text-lg font-semibold text-nature-red mb-3",children:s("help.title")}),e.jsx("p",{className:"text-nature-green mb-4",children:s("help.description")}),e.jsx(o,{to:"/contact",children:e.jsx(n,{variant:"outline",className:"border-nature-green text-nature-green hover:bg-nature-green/10",children:s("help.contactSupport")})})]})]})]})]})};export{L as default};
//# sourceMappingURL=NotFound-BPBNWCGx.js.map