* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scrollbar-gutter: stable; background: var(--background); }
html[data-theme="dark"] { background: #0a0a0a; }
body {
  margin: 0;
  color: var(--foreground);
  font: 430 16px/24px var(--font-sans);
  letter-spacing: -.011em;
  -webkit-font-smoothing: antialiased;
}
.auth-shell {
  --muted-foreground: #6d737c;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 20px;
  background: var(--background);
}
[data-theme="dark"] .auth-shell {
  --background: #0a0a0a;
  --muted-foreground: #a1a1a1;
  --vela-control-bg: rgb(255 255 255 / 5%);
  --vela-control-border: rgb(255 255 255 / 14%);
  --vela-control-shadow: inset 0 1px 0 rgb(255 255 255 / 7%), 0 1px 2px rgb(0 0 0 / 24%);
}
h1, h2, h3, p, ol { margin: 0; }
.auth-columns { width: 100%; max-width: 352px; display: flex; flex-direction: column; align-items: center; gap: 48px 80px; }
.auth-entry, .guide { width: 100%; max-width: 352px; }
.auth-header { display: flex; flex-direction: column; gap: 8px; padding-bottom: 32px; }
.product { display: flex; gap: 8px; align-items: center; }
.product img { width: 5.7rem; height: 28px; object-fit: contain; object-position: left; }
.product-name { color: var(--muted-foreground); margin-top: 2px; }
.audience { color: var(--muted-foreground); font-size: 12px; line-height: 20px; padding: 0 6px; border: 1px solid var(--border); border-radius: 4px; }
#hint { color: var(--muted-foreground); font-size: 14px; line-height: 20px; max-width: 30ch; overflow-wrap: anywhere; }
.panel { background: var(--vela-panel); border: 1px solid var(--vela-panel-border); border-radius: 10px; }
#signin { display: flex; flex-direction: column; gap: 16px; padding: 20px; }
h1 { font-size: 18px; line-height: 28px; font-weight: 550; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field-heading { display: flex; align-items: baseline; justify-content: space-between; }
.field label { font-size: 14px; line-height: 14px; font-weight: 500; }
input, button { font: inherit; color: inherit; letter-spacing: inherit; }
.field input {
  width: 100%; min-width: 0; height: 44px; padding: 4px 12px;
  background: var(--vela-control-bg); border: 1px solid var(--vela-control-border); border-radius: 9px;
  box-shadow: var(--vela-control-shadow); appearance: none; outline: none;
}
.field input:disabled { opacity: .5; }
.field input:read-only { color: var(--muted-foreground); }
.field input:focus-visible, button:focus-visible {
  border-color: var(--ring); outline: 3px solid color-mix(in srgb, var(--ring) 25%, transparent);
}
.field input[aria-invalid="true"] { border-color: var(--destructive); }
button { cursor: pointer; }
button:disabled { cursor: wait; }
.primary {
  width: 100%; height: 44px; margin-top: 4px; padding: 0 16px;
  border: 1px solid var(--vela-primary-button-border); border-radius: 8px;
  color: var(--vela-action-foreground); background: var(--vela-primary-button-bg);
  box-shadow: var(--vela-button-shadow); font-size: 14px; line-height: 20px; font-weight: 500;
}
.primary:hover:enabled { box-shadow: var(--vela-button-shadow-hover); }
.primary:active:enabled { box-shadow: var(--vela-button-shadow-active); transform: scale(.98); }
#change-email { background: none; border: 0; padding: 0; color: var(--muted-foreground); font-size: 12px; line-height: 14px; }
#change-email:hover { color: var(--foreground); text-decoration: underline; }
#error { color: var(--destructive); font-size: 14px; line-height: 20px; }
.guide h2 { padding: 16px 16px 0; font-size: 14px; line-height: 20px; font-weight: 550; }
.guide ol { padding: 0; list-style: none; }
.guide li { display: flex; align-items: flex-start; gap: 12px; padding: 16px; }
.guide li + li { border-top: 1px solid var(--border); }
.guide svg { width: 18px; height: 18px; flex: none; margin-top: 2px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.guide h3 { font-size: 14px; line-height: 20px; font-weight: 500; }
.guide p { margin-top: 4px; font-size: 14px; line-height: 20px; color: var(--muted-foreground); text-wrap: pretty; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
@media (min-width: 640px) {
  .field input, .primary { height: 40px; font-size: 14px; line-height: 20px; }
  .guide h2, .guide li { padding-inline: 20px; }
}
@media (min-width: 1024px) {
  .auth-columns { max-width: none; flex-direction: row; justify-content: center; }
  .auth-entry { flex: 0 0 352px; }
  .guide { max-width: 384px; }
}
@media (prefers-reduced-motion: reduce) {
  .primary:active:enabled { transform: none; }
}
