/* Theme follows the shared auth palette. Artwork is a separate framed surface. */
body.signin-page {
  --signin-ink: var(--auth-ink, #211b28);
  --signin-muted: var(--auth-muted, #716875);
  --signin-line: var(--auth-line, #e6e0e7);
  --signin-lilac: #704279;
  --signin-action: #2b0a30;
  --signin-on-action: #ffffff;
  --signin-error: #9b3247;
  margin: 0;
  min-height: 100dvh;
  color-scheme: light;
}
html[data-theme="dark"] body.signin-page {
  --signin-lilac: #d9bfe0;
  --signin-action: #d9bfe0;
  --signin-on-action: #2b0a30;
  --signin-error: #ffabb9;
  color-scheme: dark;
}
/* Keep the familiar header, without duplicate account actions on this route. */
body.signin-page .site-header .nav-actions { display: none; }
body.signin-page .site-header .theme-toggle { width: 44px; height: 44px; flex-basis: 44px; }
@media (min-width: 781px) {
  html body.signin-page:has(#auth) .site-header .nav-links { background: transparent; }
}
.signin-layout {
  display: grid;
  grid-template-columns: minmax(0, 400px) minmax(0, 430px);
  justify-content: space-between;
  align-items: start;
  gap: 64px;
  width: min(1040px, calc(100% - 72px));
  margin: 48px auto 64px;
  color: var(--signin-ink);
}
.signin-access { min-width: 0; padding-top: 12px; }
.signin-heading { margin-bottom: 28px; }
.signin-heading h1 { margin: 0 0 10px; color: var(--signin-ink); font: 800 42px/1.1 'Manrope', sans-serif; letter-spacing: -.04em; }
.signin-heading p, .signin-loading { margin: 0; color: var(--signin-muted); font-size: 15px; line-height: 1.6; }
.signin-loading { padding: 24px 0; }
.signin-loading[hidden] { display: none; }
.signin-story { margin-top: -16px; }
.signin-art { display: block; width: 100%; max-width: 360px; height: auto; margin: 0 auto; color: var(--signin-lilac); }
.signin-art .art-grid { opacity: .12; }
.signin-art .art-traces { opacity: .35; }
.signin-art .art-brackets { color: var(--signin-ink); }
.signin-art .art-node { fill: var(--auth-page, #f8f5f8); }
.signin-story h2 { margin: 24px 0 12px; font: 800 36px/1.15 'Manrope', sans-serif; letter-spacing: -.04em; color: var(--signin-ink); }
.signin-story h2 span { color: var(--signin-lilac); font-weight: 500; }
.signin-story p { max-width: 43ch; margin: 0; color: var(--signin-muted); font-size: 14px; line-height: 1.7; }
.signin-explore { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; margin-top: 20px; color: var(--signin-muted); font-size: 13px; }
.signin-explore:hover { color: var(--signin-ink); }
html body.signin-page:has(#auth) form#auth { display: grid; gap: 18px; width: 100%; margin: 0 !important; padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; }
html body.signin-page:has(#auth) #auth[hidden] { display: none; }
html body.signin-page:has(#auth) #auth .google { display: flex; min-height: 50px; align-items: center; justify-content: center; gap: 11px; border: 1px solid var(--signin-line); border-radius: 7px; background: var(--auth-input, #fff); color: var(--signin-ink); text-decoration: none; font-size: 13px; }
html body.signin-page:has(#auth) #auth .google:hover { border-color: var(--signin-lilac); background: var(--auth-page, #f8f5f8); }
#auth .google svg { width: 19px; height: 19px; }
html body.signin-page:has(#auth) #auth .divider { display: flex; align-items: center; gap: 14px; color: var(--signin-muted); font: 12px 'Manrope', sans-serif; text-transform: none; }
#auth .divider::before, #auth .divider::after { content: ''; height: 1px; flex: 1; background: var(--signin-line); }
html body.signin-page:has(#auth) #auth .field-label { color: var(--signin-ink); font-size: 13px; font-weight: 650; }
html body.signin-page:has(#auth) #auth input { min-height: 50px; margin-top: 8px; padding: 11px 14px; border-color: var(--signin-line); border-radius: 7px; background: var(--auth-input, #fff); color: var(--signin-ink); font-size: 16px; caret-color: var(--signin-lilac); }
html body.signin-page:has(#auth) #auth input::placeholder { color: var(--signin-muted); opacity: 1; }
html body.signin-page:has(#auth) #auth input:focus { border-color: var(--signin-lilac); outline: 2px solid var(--signin-lilac); outline-offset: 2px; }
.password-label { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.password-label a { color: var(--signin-lilac); font-size: 12px; font-weight: 700; }
html body.signin-page:has(#auth) #auth .password-wrap { position: relative; margin-top: 8px; }
html body.signin-page:has(#auth) #auth .password-wrap input { margin-top: 0; padding-right: 66px; }
html body.signin-page:has(#auth) #auth .toggle { position: absolute; top: 4px; right: 4px; min-width: 52px; min-height: 42px; color: var(--signin-lilac); font-size: 11px; cursor: pointer; }
html body.signin-page:has(#auth) #auth #submit-button { min-height: 50px; margin-top: 1px; border-radius: 7px; border-color: var(--signin-action); background: var(--signin-action); color: var(--signin-on-action); font: 700 13px 'Manrope', sans-serif; cursor: pointer; transition: transform .18s, background .18s; }
html body.signin-page:has(#auth) #auth #submit-button:hover { filter: brightness(1.12); }
html body.signin-page:has(#auth) #auth #submit-button:active { transform: scale(.99); }
html body.signin-page:has(#auth) #auth #submit-button:disabled { cursor: wait; opacity: .65; }
html body.signin-page:has(#auth) #auth #message { color: var(--signin-error) !important; font-size: 13px; overflow-wrap: anywhere; }
#message:empty { display: none; }
html body.signin-page:has(#auth) #auth .switch { display: block; margin: 0; padding: 3px 0 0; border: 0; color: var(--signin-muted); font-size: 12px; text-align: center; }
html body.signin-page:has(#auth) #auth .switch a { color: var(--signin-lilac); font-weight: 700; }
.signin-page :focus-visible { outline: 3px solid #bc98c5; outline-offset: 3px; }
.signin-page ::selection { background: #d9bfe0; color: #2b0a30; }
@media (max-width: 900px) {
  .signin-layout { width: calc(100% - 48px); gap: 40px; grid-template-columns: minmax(0, 1fr) minmax(0, .85fr); }
  .signin-story h2 { font-size: 30px; }
}
@media (max-width: 700px) {
  .signin-layout { display: block; width: min(400px, calc(100% - 40px)); margin: 32px auto 48px; }
  .signin-access { padding-top: 0; }
  .signin-heading h1 { font-size: 36px; }
  .signin-heading { margin-bottom: 24px; }
  .signin-story { margin-top: 36px; padding-top: 32px; border-top: 1px solid var(--signin-line); }
  .signin-art { max-width: 260px; }
  .signin-story h2 { font-size: 30px; }
}
@media (prefers-reduced-motion: reduce) {
  .signin-page *, .signin-page *::before, .signin-page *::after { scroll-behavior: auto !important; animation: none !important; transition: none !important; }
}
