import{l as c,f as u,b2 as m,j as e,bn as x,O as d,g as i,L as l,C as h,b as g,w as p}from"./main-TIUJvpaR.js";function v({children:t}){const{isLoggedIn:r,getRedirectUri:o}=c(),{isInsideSettingsPreview:s}=u(),a=o(),{pathname:n}=m();return r&&!s&&a!==n?e.jsx(x,{to:a,replace:!0}):t||e.jsx(d,{})}const f=""+new URL("auth-bg-hj6TjfiU.svg",import.meta.url).href;function b(){const{branding:t}=i();return e.jsxs("div",{className:"mt-auto flex items-center gap-30 pb-32 pt-42 text-sm text-muted",children:[e.jsxs(l,{className:"transition-colors hover:text-fg-base",to:"/",children:["© ",t.site_name]}),e.jsx(h,{menu:"auth-page-footer",orientation:"horizontal",itemClassName:"hover:text-fg-base transition-colors"})]})}function w({heading:t,children:r,message:o}){const{branding:s}=i(),a=g(),{trans:n}=p();return e.jsxs("main",{className:"flex h-screen flex-col items-center overflow-y-auto bg-alt px-14 pt-70 dark:bg md:px-10vw",style:{backgroundImage:a?void 0:`url("${f}")`},children:[e.jsx(l,{to:"/",className:"mb-40 block flex-shrink-0","aria-label":n({message:"Go to homepage"}),children:e.jsx("img",{src:a?s.logo_light:s==null?void 0:s.logo_dark,className:"m-auto block h-42 w-auto",alt:""})}),e.jsxs("div",{className:"mx-auto w-full max-w-440 rounded-panel bg-elevated px-40 pb-32 pt-40 shadow md:shadow-xl",children:[t&&e.jsx("h1",{className:"mb-20 text-xl",children:t}),r]}),o&&e.jsx("div",{className:"mt-36 text-sm",children:o}),e.jsx(b,{})]})}export{w as A,v as G};
