import{a4 as S,bI as M,bJ as I,bK as C,x as g,y as h,j as r,B as p,g as Y,v as W,I as U,a2 as $,aF as N,bL as P,T as F,a8 as G}from"./index-B1H8BCL7.js";import{d as H}from"./Close-CR51dqFW.js";const L=S("MuiBox",["root"]),R=M({defaultClassName:L.root,generateClassName:I.generate}),_=({onSubmit:x,submitLabel:l,submitDisabled:t})=>{const a=C(),e=g(h),o=(e==null?void 0:e.navType)||"light",s=o==="dark",n=o==="ultra-dark";return r.jsx(p,{children:r.jsx(Y,{variant:"outlined",color:"primary",onClick:x,disabled:t,sx:{transition:"all 0.25s ease",...n&&{borderColor:a.palette.primary.main,color:"#ffffff","&:hover":{transform:"translateY(-2px) scale(1.05)",borderColor:a.palette.primary.dark,backgroundColor:"rgba(9, 89, 67, 0.1)",boxShadow:"0 6px 10px rgba(255,255,255,0.1)"},"&:disabled":{borderColor:"rgba(255, 255, 255, 0.3)",color:"rgba(255, 255, 255, 0.3)"}},"&:hover":{transform:"translateY(-2px) scale(1.05)",boxShadow:s?"0 6px 10px rgba(255,255,255,0.1)":"0 6px 10px rgba(0,0,0,0.25)",backgroundColor:s?"rgba(255, 255, 255, 0.1)":"rgba(0, 0, 0, 0.05)"},"&:active":{transform:"translateY(0px) scale(0.98)",boxShadow:s?"0 2px 4px rgba(255,255,255,0.05)":"0 2px 4px rgba(0,0,0,0.15)"}},children:l||"Submit"})})},A=({onClose:x,disableClose:l})=>{const t=C(),a=g(h),e=(a==null?void 0:a.navType)||"light",o=e==="dark",s=e==="ultra-dark",n=o||s,d=s?"#ffffff":o?t.palette.text.primary:"#333333";return r.jsx(R,{sx:{display:"flex",alignItems:"center"},children:r.jsx(W,{title:"Close",arrow:!0,children:r.jsx("span",{children:r.jsx(U,{onClick:x,disabled:l,sx:{color:d,transition:"all 0.25s ease","&:hover":{transform:"translateY(-2px) scale(1.05)",boxShadow:n?"0 6px 10px rgba(255,255,255,0.1)":"0 6px 10px rgba(0,0,0,0.25)",backgroundColor:n?"rgba(255, 255, 255, 0.1)":"rgba(0, 0, 0, 0.05)"},"&:active":{transform:"translateY(0px) scale(0.98)",boxShadow:n?"0 2px 4px rgba(255,255,255,0.05)":"0 2px 4px rgba(0,0,0,0.15)"}},children:r.jsx(H,{})})})})})},y={xs:360,sm:420,md:480,lg:620,xl:780,xxl:920,full:1100},K=({open:x,onClose:l,width:t="md",title:a,children:e,onSubmit:o,submitLabel:s,submitDisabled:n,disableClose:d})=>{const j=$(),v=N(j.breakpoints.down("sm")),b=g(h),m=(b==null?void 0:b.navType)||"light",i=m==="dark",c=m==="ultra-dark",u=i||c,w=typeof t=="number"?t:y[t]||y.md,D=v?"100vw":w,B=c?"#0a0a0a":i?"#1e293b":"#ffffff",k=c?"#111111":i?"#1a2332":"#f8fafc",T=c?"#ffffff":i?"#e2e8f0":"#1e293b",f=c?"rgba(255,255,255,0.08)":i?"#334155":"#e2e8f0";return r.jsxs(P,{anchor:"right",open:x,onClose:d?void 0:l,PaperProps:{sx:{width:D,maxWidth:"100vw",display:"flex",flexDirection:"column",backgroundColor:B,borderLeft:`1px solid ${f}`}},children:[r.jsxs(p,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",px:2.5,py:1.5,backgroundColor:k,borderBottom:`1px solid ${f}`,flexShrink:0,minHeight:52},children:[r.jsx(F,{sx:{fontWeight:600,fontSize:"0.9375rem",color:T,letterSpacing:"0.01em"},children:a}),r.jsx(A,{onClose:l,disableClose:d})]}),r.jsx(p,{sx:{flexGrow:1,overflowY:"auto",px:2.5,py:2,"&::-webkit-scrollbar":{width:"6px"},"&::-webkit-scrollbar-track":{background:"transparent"},"&::-webkit-scrollbar-thumb":{background:u?"rgba(255,255,255,0.15)":"#cbd5e1",borderRadius:"3px","&:hover":{background:u?"rgba(255,255,255,0.25)":"#94a3b8"}}},children:e}),o&&r.jsxs(r.Fragment,{children:[r.jsx(G,{sx:{borderColor:f}}),r.jsx(p,{sx:{display:"flex",justifyContent:"flex-end",alignItems:"center",gap:1.5,px:2.5,py:1.5,backgroundColor:k,flexShrink:0},children:r.jsx(_,{onSubmit:o,submitDisabled:n,submitLabel:s})})]})]})};export{R as B,K as D,A as M};
