import{i as e,n as t,t as n}from"./app-Cl8XxplU.js";import{t as r}from"./GuestLayout-CLB6iWnB.js";var i=n();function a({message:e}){return e?(0,i.jsx)(`p`,{className:`mt-1 text-sm text-red-600`,children:e}):null}function o({token:n,email:o}){let{data:s,setData:c,post:l,processing:u,errors:d,reset:f}=e({token:n,email:o,password:``,password_confirmation:``});return(0,i.jsxs)(r,{children:[(0,i.jsx)(t,{title:`إعادة تعيين كلمة المرور`}),(0,i.jsx)(`h2`,{className:`text-xl font-bold text-gray-900 mb-6 text-center`,children:`إعادة تعيين كلمة المرور`}),(0,i.jsxs)(`form`,{onSubmit:e=>{e.preventDefault(),l(route(`password.store`),{onFinish:()=>f(`password`,`password_confirmation`)})},className:`space-y-4`,children:[(0,i.jsxs)(`div`,{children:[(0,i.jsx)(`label`,{className:`block text-sm font-medium text-gray-700 mb-1`,children:`البريد الإلكتروني`}),(0,i.jsx)(`input`,{type:`email`,value:s.email,onChange:e=>c(`email`,e.target.value),className:`w-full rounded-lg border border-gray-300 px-4 py-2.5 text-sm focus:border-amber-500 focus:outline-none focus:ring-1 focus:ring-amber-500`,autoComplete:`username`,dir:`ltr`}),(0,i.jsx)(a,{message:d.email})]}),(0,i.jsxs)(`div`,{children:[(0,i.jsx)(`label`,{className:`block text-sm font-medium text-gray-700 mb-1`,children:`كلمة المرور الجديدة`}),(0,i.jsx)(`input`,{type:`password`,value:s.password,onChange:e=>c(`password`,e.target.value),className:`w-full rounded-lg border border-gray-300 px-4 py-2.5 text-sm focus:border-amber-500 focus:outline-none focus:ring-1 focus:ring-amber-500`,autoComplete:`new-password`,autoFocus:!0}),(0,i.jsx)(a,{message:d.password})]}),(0,i.jsxs)(`div`,{children:[(0,i.jsx)(`label`,{className:`block text-sm font-medium text-gray-700 mb-1`,children:`تأكيد كلمة المرور`}),(0,i.jsx)(`input`,{type:`password`,value:s.password_confirmation,onChange:e=>c(`password_confirmation`,e.target.value),className:`w-full rounded-lg border border-gray-300 px-4 py-2.5 text-sm focus:border-amber-500 focus:outline-none focus:ring-1 focus:ring-amber-500`,autoComplete:`new-password`}),(0,i.jsx)(a,{message:d.password_confirmation})]}),(0,i.jsx)(`button`,{type:`submit`,disabled:u,className:`w-full rounded-lg bg-amber-700 text-white py-3 text-sm font-semibold hover:bg-amber-800 transition-colors disabled:opacity-60 disabled:cursor-not-allowed`,children:u?`جارٍ التعيين...`:`إعادة تعيين كلمة المرور`})]})]})}export{o as default};