:root {
  --auth-ink: #182327;
  --auth-muted: #657277;
  --auth-brand: #03a96f;
  --auth-line: #dce6e2;
  --auth-page: #f3f8f5;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background:
    radial-gradient(circle at 15% 5%, rgb(3 192 127 / 12%), transparent 30rem),
    var(--auth-page);
  color: var(--auth-ink);
  font: 16px/1.5 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.auth-shell {
  width: min(100% - 32px, 520px);
  margin: 0 auto;
  padding: clamp(32px, 8vh, 88px) 0 48px;
}

.auth-brand {
  display: inline-block;
  margin: 0 0 22px;
  color: var(--auth-ink);
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -.04em;
  text-decoration: none;
}

.auth-brand span { color: var(--auth-brand); }

.auth-card {
  padding: clamp(26px, 6vw, 44px);
  border: 1px solid var(--auth-line);
  border-radius: 24px;
  background: rgb(255 255 255 / 94%);
  box-shadow: 0 26px 70px rgb(24 35 39 / 10%);
}

.auth-card h1 {
  margin: 0;
  font-size: clamp(26px, 6vw, 32px);
  line-height: 1.2;
  letter-spacing: -.04em;
}

.auth-actions { display: grid; gap: 12px; margin-top: 30px; }

.auth-button {
  display: flex;
  min-height: 54px;
  align-items: center;
  justify-content: center;
  gap: 11px;
  padding: 12px 18px;
  border: 1px solid transparent;
  border-radius: 14px;
  font: inherit;
  font-weight: 750;
  cursor: pointer;
  text-decoration: none;
  transition: transform 140ms ease, box-shadow 140ms ease, background 140ms ease;
}

.auth-button:hover { transform: translateY(-1px); }
.auth-button:focus-visible { outline: 3px solid rgb(3 169 111 / 28%); outline-offset: 3px; }
.auth-button:disabled { cursor: wait; opacity: .68; transform: none; }
.auth-button--telegram { background: #229ed9; color: #fff; box-shadow: 0 10px 24px rgb(24 35 39 / 14%); }
.auth-button--telegram:hover { background: #168dcc; }
.auth-button--secondary { border-color: var(--auth-line); background: #fff; color: var(--auth-ink); }
.auth-button--secondary:hover { background: #f8fbfa; }

.auth-provider-mark {
  display: grid;
  width: 25px;
  height: 25px;
  place-items: center;
  border-radius: 50%;
  background: rgb(255 255 255 / 18%);
  font-size: 14px;
}

.auth-provider-mark--yandex { background: #fc3f1d; color: #fff; font-weight: 800; }
.auth-status { margin-top: 18px; padding: 12px 14px; border-radius: 12px; background: #eaf7f2; color: #245444; }
.auth-status[data-state="error"] { background: #fff0ed; color: #8f2c1e; }

@media (prefers-reduced-motion: reduce) { .auth-button { transition: none; } }


/* Public sign-in surface; legal document and acceptance layouts stay independent. */
@font-face {
  font-family: "SellPal Auth";
  src: url("/static/vendor/green-os/fonts/Manrope-Variable.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}

.login-page {
  display: grid;
  align-items: center;
  background: #edf4ef;
  font-family: "SellPal Auth", system-ui, sans-serif;
}

.login-page .auth-shell { width: min(100% - 40px, 508px); padding: 48px 0; }
.login-page .auth-brand { display: block; width: fit-content; margin: 0 auto 32px; font-size: 32px; }
.login-page .auth-brand span { color: #006a46; }
.login-page .auth-card {
  padding: 40px;
  border: 0;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 16px 48px rgb(24 55 40 / 7%);
}
.login-page .auth-card h1 { font-size: 34px; font-weight: 750; letter-spacing: -.035em; }
.auth-intro { margin: 14px 0 0; color: #52635a; font-size: 16px; line-height: 1.65; }
.login-page .auth-actions { margin-top: 28px; }
.login-page .auth-button--secondary { background: #182327; color: #fff; border-color: transparent; }
.login-page .auth-button--secondary:hover { background: #2d3c35; }
.login-page .auth-button { border-radius: 12px; font-size: 16px; font-weight: 650; }
.login-page .auth-provider-mark--yandex { width: 28px; height: 28px; background: #fff; color: #e52a16; font-size: 18px; }
.auth-registration { margin: 16px 0 0; color: #52635a; font-size: 13px; line-height: 1.65; }
.auth-note { margin: 26px 0 12px; padding-top: 24px; border-top: 1px solid var(--auth-line); color: #52635a; font-size: 13px; line-height: 1.75; }
.auth-note a, .auth-documents { color: #006a46; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.auth-documents { display: inline-block; padding: 6px 0; font-size: 13px; }
.auth-home { display: block; width: fit-content; margin: 22px auto 0; padding: 8px; color: #52635a; font-size: 13px; text-underline-offset: 4px; }
.login-page a:focus-visible, .login-page button:focus-visible { outline: 3px solid #006a46; outline-offset: 4px; }
.auth-note a:hover, .auth-documents:hover, .auth-home:hover { color: #004c32; }
.login-page ::selection { color: #182327; background: #b5ead5; }

@media (max-width: 540px) {
  .login-page .auth-shell { width: min(100% - 32px, 508px); padding: 28px 0; }
  .login-page .auth-brand { margin-bottom: 24px; }
  .login-page .auth-card { padding: 28px 24px; }
  .login-page .auth-card h1 { font-size: 28px; }
  .login-page .auth-button { padding-inline: 12px; }
}
