/* The React login and the public registration form use the same opening spread. */
#auth.gateway, .edition:has(.auth-layout) {
  --auth-width:min(1344px,calc(100% - clamp(40px,8vw,136px)));
  --auth-header:76px;
  --auth-gutter:clamp(26px,4.2vw,64px);
  --auth-serif:"Iowan Old Style",Baskerville,"Times New Roman","Songti SC",STSong,serif;
  --auth-sans:"Helvetica Neue","PingFang SC","Microsoft YaHei",sans-serif;
}
html.chat-edition #auth.gateway {
  color-scheme:only light;
  --ed-page:#f5f2ea; --ed-paper:#fffcf5; --ed-ink:#29231f; --ed-text:#463b31;
  --ed-muted:#685e55; --ed-line:#d8cfc1; --ed-stroke:#b5a898; --ed-inset:#efe9de;
  --ed-brand:#382921; --ed-on:#fffaf4; --ed-accent:#963e23;
}
#auth .gateway-top, .edition:has(.auth-layout) .bar {box-sizing:border-box;height:var(--auth-header)}
.edition:has(.auth-layout) .bar-in {height:100%;min-height:0}
#auth .gateway-brand, .edition:has(.auth-layout) .bar .brand {
  gap:9px;font:600 33px/1 var(--auth-serif);letter-spacing:-.05em;
}
#auth .gateway-brand img, .edition:has(.auth-layout) .bar .brand img {
  width:30px;height:30px;border-radius:0;background:none;filter:none;
}
#auth .auth-layout, .edition main>.wrap:has(>.auth-layout) {width:var(--auth-width);max-width:none;margin-inline:auto}
:is(#auth,.edition) .auth-layout {
  box-sizing:border-box;display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.08fr);
  grid-template-areas:"form art";gap:0;align-items:stretch;
  min-height:clamp(568px,42vw,606px);margin-block:clamp(20px,2.6vw,40px) 32px;
  padding:0;overflow:hidden;border:1px solid #d8cfc1;border-radius:20px;background:#fffcf5;
  box-shadow:0 8px 28px -16px #4b2f1c30;animation:none;
}
:is(#auth,.edition) .auth-layout :is(.gateway-access,.entry-panel) {
  grid-area:form;display:flex;align-items:flex-start;justify-content:center;align-self:stretch;
  min-width:0;padding:var(--auth-gutter);scroll-margin-block-start:16px;
}
:is(#auth,.edition) .auth-layout :is(.gateway-form,.entry-content) {
  width:100%;max-width:400px;margin:0;font:400 15px/1.55 var(--auth-sans);
}
:is(#auth,.edition) .auth-layout h1 {
  margin:0;font:600 clamp(34px,3.1vw,48px)/1.18 var(--auth-serif);letter-spacing:-.045em;color:#29231f;
}
:is(#auth,.edition) .auth-layout :is(.gateway-intro,.entry-lede) {
  min-height:3.2em;margin:12px 0 24px;font:400 15px/1.6 var(--auth-sans);color:#685e55;
}
:is(#auth,.edition) .auth-layout form {display:grid;gap:16px;margin:0}
:is(#auth,.edition) .auth-layout :is(.gateway-field,.field) {display:block;margin:0}
.auth-layout .field small {display:block;margin-top:5px}
:is(#auth,.edition) .auth-layout label {
  display:block;margin:0 0 7px;font:600 14px/1.4 var(--auth-sans);
}
:is(#auth.gateway,.edition) .auth-layout input:where(:not([type="checkbox"])) {
  display:block;box-sizing:border-box;width:100%;height:48px;min-height:48px;padding:0 14px;
  font:400 16px/1.5 var(--auth-sans);border:1px solid #cdbfaf;border-radius:12px;background:#fdfaf4;
}
:is(#auth.gateway,.edition) .auth-layout input[name=password] {padding-inline-end:50px}
:is(#auth,.edition) .auth-layout :is(.gateway-submit,.entry-submit) {
  margin:0;min-height:48px;border-radius:12px;font:600 15px/1.4 var(--auth-sans);
}
:is(#auth,.edition) .auth-layout :is(.gateway-switch,.switch) {
  display:flex;align-items:center;justify-content:center;gap:6px;margin:12px 0 0;font:400 14px/1.5 var(--auth-sans);
}
.auth-layout .auth-art {
  grid-area:art;position:relative;min-width:0;isolation:isolate;overflow:hidden;
  display:flex;flex-direction:column;justify-content:space-between;gap:12px;font:400 15px/1.5 var(--auth-sans);
  padding:clamp(28px,3.6vw,56px);background:#361915;color:#fff0dc;
}
.auth-layout .auth-art-photo,.auth-layout .auth-art::after {
  position:absolute;inset:0;width:100%;height:100%;pointer-events:none;
}
.auth-layout .auth-art-photo {z-index:-2;display:block;object-fit:cover;object-position:52% 50%}
.auth-layout .auth-art::after {
  content:"";z-index:-1;background:linear-gradient(115deg,#210c107a,transparent 70%),linear-gradient(0deg,#200c0dcc,transparent 35%);
}
.auth-layout .auth-art-title {
  margin:0;color:#fff3df;font:normal clamp(60px,6.6vw,102px)/.94 var(--auth-serif);letter-spacing:-.06em;white-space:nowrap;
}
.auth-layout .auth-art-title i {font-weight:400;color:#efc6a1}
.auth-layout :is(.auth-art-channels,.auth-art-note) {font:550 14px/1.5 var(--auth-sans);margin:0;color:#fff3df}
.auth-layout .auth-art-channels,.auth-layout .auth-art-note a {display:inline-flex;align-items:center;gap:10px}
.auth-layout .auth-art-note a {min-height:44px;width:fit-content;color:inherit;text-decoration:none}
.auth-layout .auth-art-note a:hover {text-decoration:underline;text-underline-offset:4px}
.auth-layout .auth-art-note a:focus-visible {outline:2px solid currentColor;outline-offset:2px}
.auth-layout .auth-art-note p {margin:0;max-width:30em;font:400 13px/1.6 var(--auth-sans);color:#fff3df}
@media (max-width:1000px) {
  #auth.gateway, .edition:has(.auth-layout) {--auth-header:64px}
}
@media (max-width:760px) {
  #auth.gateway, .edition:has(.auth-layout) {
    --auth-header:calc(60px + env(safe-area-inset-top));--auth-width:min(540px,calc(100% - 32px));
    --auth-gutter:clamp(20px,5.5vw,30px);
  }
  #auth .gateway-top, .edition:has(.auth-layout) .bar {padding-top:env(safe-area-inset-top)}
  #auth .gateway-top {padding-inline:16px}
  #auth .gateway-brand, .edition:has(.auth-layout) .bar .brand {font-size:28px}
  :is(#auth,.edition) .auth-layout {
    grid-template-columns:minmax(0,1fr);grid-template-areas:"art" "form";min-height:0;margin-block:16px 24px;
  }
  :is(#auth,.edition) .auth-layout :is(.gateway-access,.entry-panel) {padding:var(--auth-gutter) var(--auth-gutter) 12px}
  :is(#auth,.edition) .auth-layout :is(.gateway-form,.entry-content) {max-width:none}
  :is(#auth,.edition) .auth-layout h1 {font-size:clamp(28px,7vw,34px)}
  :is(#auth,.edition) .auth-layout :is(.gateway-intro,.entry-lede) {margin:8px 0 18px}
  .auth-layout .auth-art {
    height:clamp(116px,28vw,146px);padding:16px var(--auth-gutter);
    flex-direction:row;align-items:flex-end;gap:8px;
  }
  .auth-layout .auth-art-title {font-size:clamp(38px,9vw,50px)}
  .auth-layout :is(.auth-art-channels,.auth-art-note) {font-size:12px}
  .auth-layout .auth-art-note p {position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
  .auth-layout .auth-art-note a {margin-block-end:-12px;gap:4px}
  .auth-layout .auth-art-photo {object-position:52% 44%}
}
@media (max-width:359px) {
  .auth-layout .auth-art-channels {gap:4px}
}
