(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,63209,e=>{"use strict";let a=(0,e.i(75254).default)("circle-alert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);e.s(["AlertCircle",()=>a],63209)},14764,e=>{"use strict";let a=(0,e.i(75254).default)("send",[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]]);e.s(["Send",()=>a],14764)},71689,e=>{"use strict";let a=(0,e.i(75254).default)("arrow-left",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);e.s(["ArrowLeft",()=>a],71689)},92024,e=>{"use strict";var a=e.i(43476),t=e.i(71645),s=e.i(18566),r=e.i(14764),l=e.i(63209),i=e.i(71689),c=e.i(22016),o=e.i(95187);let n=(0,o.createServerReference)("40aac1caa2bd0e53e4fd3a40c6ba71fd2d364cc4a7",o.callServer,void 0,o.findSourceMapURL,"createPqr");var d=e.i(17927);function u(){let e=(0,s.useRouter)(),[o,u]=(0,t.useState)({categoria:"Académico",mensaje:""}),[x,m]=(0,t.useState)(null),[f,b]=(0,t.useState)(!1),[p,g]=(0,t.useState)(null);(0,t.useEffect)(()=>{(async()=>{let{data:{session:e}}=await d.supabase.auth.getSession();e?.user?.email&&m(e.user.email)})()},[]);let h=e=>{u({...o,[e.target.name]:e.target.value}),p&&g(null)},y=async a=>{if(a.preventDefault(),b(!0),g(null),!x){g("No se pudo detectar tu sesión. Por favor inicia sesión nuevamente."),b(!1);return}let t=await n({...o,email:x});b(!1),t.success?(alert(`\xa1Radicaci\xf3n Exitosa!

Tu n\xfamero de ticket es: ${t.ticketNumber}`),e.push("/estudiante/pqrs"),e.refresh()):g(t.error||"Error desconocido al radicar la PQR.")};return(0,a.jsxs)("div",{className:"p-8 max-w-3xl mx-auto h-full overflow-y-auto",children:[(0,a.jsxs)(c.default,{href:"/estudiante",className:"text-gray-500 hover:text-navy flex items-center gap-2 text-sm font-bold uppercase tracking-widest mb-6",children:[(0,a.jsx)(i.ArrowLeft,{size:16})," Volver al Tablero"]}),(0,a.jsxs)("div",{className:"bg-white p-8 rounded-xl shadow-sm border border-gray-100",children:[(0,a.jsx)("h1",{className:"text-2xl font-serif font-bold text-navy mb-2",children:"Radicar Nueva PQR"}),(0,a.jsx)("p",{className:"text-sm text-gray-500 mb-8",children:"Selecciona la categoría de tu solicitud y describe el caso detalladamente."}),p&&(0,a.jsxs)("div",{className:"bg-red-50 text-red-700 p-4 rounded-lg flex items-start gap-3 mb-6 border border-red-200",children:[(0,a.jsx)(l.AlertCircle,{size:20,className:"mt-0.5 flex-shrink-0"}),(0,a.jsx)("div",{className:"text-sm",children:p})]}),(0,a.jsxs)("form",{onSubmit:y,className:"space-y-6",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{className:"block text-xs font-bold text-navy uppercase tracking-widest mb-2",children:"Tu Correo Institucional / Registro"}),(0,a.jsx)("input",{type:"email",disabled:!0,value:x||"Cargando sesión...",className:"w-full border border-gray-100 bg-gray-50 rounded p-3 text-sm text-gray-400 cursor-not-allowed"}),(0,a.jsx)("span",{className:"text-xs text-gray-400 mt-1 block italic",children:"Tu solicitud quedará enlazada automáticamente a tu cuenta registrada."})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{className:"block text-xs font-bold text-navy uppercase tracking-widest mb-2",children:"Categoría del Ticket *"}),(0,a.jsxs)("select",{name:"categoria",required:!0,value:o.categoria,onChange:h,className:"w-full border border-gray-300 rounded p-3 text-sm focus:outline-none focus:border-yellow focus:ring-1 focus:ring-yellow",children:[(0,a.jsx)("option",{value:"Académico",children:"Académico (Notas, Horarios, Profesores)"}),(0,a.jsx)("option",{value:"Pagos",children:"Pagos y Cartera (Facturas, Cuotas)"}),(0,a.jsx)("option",{value:"Técnico",children:"Soporte Técnico (Plataforma, Acceso)"}),(0,a.jsx)("option",{value:"Otro",children:"Otro / Petición General"})]})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{className:"block text-xs font-bold text-navy uppercase tracking-widest mb-2",children:"Descripción Detallada *"}),(0,a.jsx)("textarea",{name:"mensaje",required:!0,value:o.mensaje,onChange:h,rows:5,className:"w-full border border-gray-300 rounded p-3 text-sm focus:outline-none focus:border-yellow focus:ring-1 focus:ring-yellow",placeholder:"Escribe aquí tu petición, queja o reclamo con el mayor nivel de detalle posible..."})]}),(0,a.jsx)("div",{className:"flex justify-end pt-4 border-t",children:(0,a.jsx)("button",{type:"submit",disabled:f,className:"bg-navy text-white px-8 py-3 text-sm font-bold uppercase tracking-widest flex items-center gap-2 hover:bg-[#8C1515] transition-colors rounded disabled:opacity-50",children:f?"Enviando...":(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(r.Send,{size:18})," Radicar PQR"]})})})]})]})]})}e.s(["default",()=>u],92024)}]);