import{i as e,n as t,t as n}from"./app-G6wC4CCm.js";import{d as r,g as i}from"./ui-D0zPIw82.js";import{r as a}from"./theme-Cl--dRB8.js";import{t as o}from"./shared-DxO_QzGG.js";import{t as s}from"./BackToHomeLink-BpDHgWuv.js";var c=n();function l({token:n,email:l}){a();let{data:u,setData:d,post:f,processing:p,errors:m,reset:h}=e({token:n,email:l??``,password:``,password_confirmation:``});return(0,c.jsxs)(c.Fragment,{children:[(0,c.jsx)(t,{title:`Choose a new password`}),(0,c.jsx)(`main`,{className:`min-h-screen bg-background font-sans text-foreground antialiased overflow-hidden`,children:(0,c.jsxs)(`div`,{className:`relative mx-auto min-h-screen max-w-6xl border-x border-border/60`,children:[(0,c.jsx)(o,{className:`left-0 top-0`}),(0,c.jsx)(o,{className:`left-full top-0`}),(0,c.jsx)(o,{className:`left-0 top-full`}),(0,c.jsx)(o,{className:`left-full top-full`}),(0,c.jsxs)(`div`,{className:`mx-auto flex min-h-screen max-w-md flex-col justify-center px-6 py-10`,children:[(0,c.jsx)(s,{}),(0,c.jsxs)(`div`,{className:`ms-card rounded-2xl border border-border bg-card p-6 shadow-sm sm:p-8`,children:[(0,c.jsxs)(`h1`,{className:`font-display text-3xl font-medium leading-[1.1] tracking-tight text-foreground sm:text-4xl`,children:[`Choose a new `,(0,c.jsx)(`em`,{className:`italic text-accent`,children:`password`}),`.`]}),(0,c.jsx)(`p`,{className:`mt-5 text-base leading-relaxed text-muted-foreground`,children:`Pick something at least 8 characters long.`}),(0,c.jsxs)(`form`,{onSubmit:e=>{e.preventDefault(),f(`/reset-password`,{onFinish:()=>h(`password`,`password_confirmation`)})},className:`mt-6 space-y-4`,children:[(0,c.jsx)(r,{id:`email`,label:`Email`,type:`email`,autoComplete:`email`,value:u.email,onChange:e=>d(`email`,e.target.value),error:m.email,required:!0}),(0,c.jsx)(r,{id:`password`,label:`New password`,type:`password`,autoComplete:`new-password`,value:u.password,onChange:e=>d(`password`,e.target.value),error:m.password,required:!0,autoFocus:!0}),(0,c.jsx)(r,{id:`password_confirmation`,label:`Confirm new password`,type:`password`,autoComplete:`new-password`,value:u.password_confirmation,onChange:e=>d(`password_confirmation`,e.target.value),required:!0}),(0,c.jsx)(i,{type:`submit`,disabled:p,size:`lg`,className:`w-full`,children:p?`Saving…`:`Reset password`})]})]})]})]})})]})}export{l as default};