:root {
  color-scheme: dark;
  --background: #0b0b0e;
  --panel: #111114;
  --field: #1a1a20;
  --text: #f5f5f7;
  --muted: #b2b2be;
  --border: #71717c;
  --red: #cf2035;
  --focus: #ff7d8d;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.5;
  scrollbar-color: #62626e var(--panel);
}

* { box-sizing: border-box; }
body { margin: 0; }
::selection { color: var(--background); background: var(--focus); }

.login-shell {
  min-width: 280px;
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  grid-template-columns: 70% 30%;
  grid-template-rows: minmax(600px, 1fr) auto;
  color: var(--text);
  background: var(--background);
}

.login-splash {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 96px;
  padding: clamp(48px, 5.2vw, 80px) 8%;
}

.splash-art, .splash-shade { position: absolute; z-index: -1; inset: 0; }
.splash-art { display: block; opacity: .95; }
/* Preserve a page rendered by the previous process during the asset rollout. */
.splash-art:not(picture) { background: url('/assets/horizon.png') center / cover; filter: saturate(.2); opacity: .65; }
.splash-art img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.splash-shade { background: linear-gradient(90deg, #08080c40, transparent 68%), linear-gradient(0deg, #0b0b0e99, transparent 65%); }
.splash-brand { display: block; width: 360px; max-width: 100%; height: auto; }
.splash-brand[src="/assets/dot-wordmark.svg"] { width: 184px; }
.splash-copy { max-width: 660px; }
.splash-title { margin: 0 0 24px; font-size: clamp(42px, 4.7vw, 76px); font-weight: 500; line-height: 1.08; letter-spacing: -.035em; }
.splash-description { margin: 0; color: #d0d0d8; font-size: 17px; line-height: 1.7; }

.login-panel {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 64px clamp(24px, 2.7vw, 48px);
  border-left: 1px solid #ffffff0c;
  background: var(--panel);
}

.login-content { width: 100%; max-width: 400px; }
.mobile-brand { display: none; width: 288px; max-width: 100%; height: auto; margin-bottom: 48px; }
.mobile-brand[src="/assets/dot-wordmark.svg"] { width: 176px; }
h1 { margin: 0 0 12px; font-size: clamp(25px, 2.1vw, 34px); font-weight: 500; line-height: 1.2; letter-spacing: -.025em; text-wrap: balance; }
.login-description { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.7; }
form { margin-top: 32px; }
.login-field + .login-field { margin-top: 22px; }
label { display: block; margin-bottom: 9px; color: #d5d5de; font-size: 13px; font-weight: 500; }
input, button { font: inherit; touch-action: manipulation; }
input:not([type="hidden"]) {
  width: 100%;
  min-width: 0;
  height: 50px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 9px;
  color: var(--text);
  background: var(--field);
  caret-color: var(--focus);
}
input::placeholder { color: #a4a4b0; }
input:not([type="hidden"]):hover { border-color: #9898a5; }
input:focus-visible { border-color: var(--focus); background: #1d1d24; }
.login-submit {
  width: 100%;
  min-height: 50px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 28px;
  padding: 12px 16px;
  border: 0;
  border-radius: 9px;
  color: #fff;
  background: var(--red);
  font-size: 14px;
  font-weight: 650;
  cursor: pointer;
}
.login-submit svg { flex-shrink: 0; }
.login-submit:hover { background: #dd2940; }
.login-submit:active { background: #bd1c30; }
.login-submit:disabled { color: #bbb; background: #3a3a43; cursor: default; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 4px; }
.login-note { margin: 20px 0 0; color: var(--muted); font-size: 12px; line-height: 1.7; }
.login-error { margin: 24px 0 0; padding: 14px 16px; border: 1px solid #b25562; border-radius: 9px; background: #30181d; color: #ffbdc7; font-size: 14px; line-height: 1.6; overflow-wrap: anywhere; }
.login-error + form { margin-top: 24px; }
.login-footer { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 64px; padding: 12px 36px; border-top: 1px solid #ffffff12; color: var(--muted); background: #101013; font-size: 12px; }
.login-footer a { display: inline-flex; align-items: center; min-height: 40px; color: inherit; text-decoration: underline; text-underline-offset: 4px; }
.login-footer a:hover { color: var(--text); }
.login-skip { position: absolute; left: 24px; top: -80px; z-index: 2; padding: 12px 16px; border-radius: 8px; color: var(--background); background: var(--text); }
.login-skip:focus { top: 16px; }

@media (max-width: 800px) {
  .login-shell { grid-template-columns: 1fr; grid-template-rows: 1fr auto; }
  .login-splash { display: none; }
  .login-panel { padding: 48px 24px; border: 0; }
  .mobile-brand { display: block; }
  h1 { font-size: 28px; }
  .login-footer { padding: 10px 24px; }
}

@media (max-height: 700px) and (min-width: 801px) {
  .login-shell { grid-template-rows: minmax(540px, 1fr) auto; }
  .login-splash { padding-top: 48px; padding-bottom: 48px; }
  .login-panel { padding-top: 40px; padding-bottom: 40px; }
  .splash-title { font-size: clamp(42px, 4.7vw, 64px); }
}
