:root {
  --auth-flow-blue: #1768ff;
  --auth-flow-navy: #081b3a;
  --auth-flow-muted: #6d7e97;
  --auth-flow-line: #d9e4f2;
}

/* The recovery form is the primary task on small screens. */
@media (max-width: 600px) {
  .auth-flow-body[data-approved-route="auth/forgot-password"] .auth-flow-panel {
    order: -1;
  }
}

.auth-flow-body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: #f3f7fc;
}

.auth-flow-brand-header {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 20;
  padding: clamp(20px, 3vw, 34px);
}

.auth-flow-brand-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: max-content;
  padding: 7px 9px;
  border-radius: 15px;
  transition: background-color .16s ease, transform .16s ease;
}

.auth-flow-brand-link:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, .72);
}

.auth-flow-brand-link .logo-mark {
  width: 44px;
  height: 44px;
  flex: none;
}

.auth-flow-brand-link .logo-copy {
  display: grid;
  gap: 1px;
  line-height: 1;
}

.auth-flow-brand-link .logo-copy b {
  color: var(--auth-flow-navy);
  font-size: 20px;
  line-height: 1.05;
}

.auth-flow-brand-link .logo-copy small {
  margin: 0;
  color: #7185a1;
  font-size: 9px;
  font-weight: 750;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.auth-flow-experience {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: clamp(104px, 13vh, 136px) 20px clamp(34px, 6vh, 66px);
  background:
    radial-gradient(circle at 12% 20%, rgba(23, 104, 255, .11), transparent 31%),
    linear-gradient(180deg, #f6f9ff 0%, #eef4fd 100%);
}

.auth-flow-surface {
  width: min(100%, 980px);
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(360px, .92fr);
  overflow: hidden;
  border: 1px solid var(--auth-flow-line);
  border-radius: 28px;
  background: #fff;
  box-shadow: 0 28px 70px rgba(34, 64, 112, .14);
}

.auth-flow-context {
  min-height: 560px;
  padding: clamp(36px, 5vw, 62px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 36px;
  color: #fff;
  background:
    radial-gradient(circle at 100% 100%, rgba(26, 206, 239, .38), transparent 40%),
    linear-gradient(145deg, #071b3b, #1057c8 72%, #168fd8);
}

.auth-flow-context .auth-context-kicker {
  display: block;
  margin-bottom: 18px;
  color: #9ed8ff;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.auth-flow-context h1 {
  max-width: 520px;
  margin-bottom: 0;
  color: #fff;
  font-size: clamp(32px, 4.2vw, 50px);
  line-height: 1.06;
  letter-spacing: -.045em;
}

.auth-flow-context p {
  max-width: 490px;
  margin: 18px 0 0;
  color: #c9d9ed;
  font-size: 16px;
  line-height: 1.65;
}

.auth-flow-context-list {
  display: grid;
  gap: 13px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: #eaf3ff;
  font-size: 13px;
  font-weight: 750;
}

.auth-flow-context-list li {
  display: flex;
  align-items: center;
  gap: 10px;
}

.auth-flow-context-list span {
  width: 27px;
  height: 27px;
  display: grid;
  flex: none;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, .13);
}

.auth-flow-panel.auth-card {
  width: auto;
  align-self: center;
  padding: clamp(34px, 5vw, 58px);
  border: 0;
  border-radius: 0;
  background: #fff;
  box-shadow: none;
}

.auth-flow-panel.auth-card > h1 {
  margin: 8px 0 0;
  color: var(--auth-flow-navy);
  font-size: clamp(27px, 3vw, 36px);
  line-height: 1.12;
  letter-spacing: -.035em;
}

.auth-flow-panel.auth-card > .lead {
  margin: 11px 0 28px;
  color: var(--auth-flow-muted);
  font-size: 13px;
}

.auth-flow-panel .section-kicker {
  color: var(--auth-flow-blue);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.auth-flow-panel .field {
  gap: 8px;
  margin-top: 18px;
}

.auth-flow-panel .field label {
  color: #314968;
  font-size: 12px;
}

.auth-flow-panel .input,
.auth-flow-panel .select {
  min-height: 49px;
  border-radius: 13px;
  font-size: 14px;
}

.auth-flow-panel .btn {
  min-height: 49px;
  font-size: 13px;
}

.auth-flow-panel > .btn,
.auth-flow-panel .auth-status > .btn {
  width: 100%;
}

.auth-flow-panel .auth-status {
  padding: 8px 0 0;
}

.auth-flow-panel .auth-status h2 {
  margin-bottom: 8px;
  color: var(--auth-flow-navy);
  font-size: 19px;
}

.auth-flow-panel .auth-status > p {
  margin-bottom: 18px;
}

.auth-flow-panel .alert {
  margin-top: 20px;
}

.auth-flow-panel .auth-help a {
  color: var(--auth-flow-blue);
  font-weight: 850;
}

@media (max-width: 900px) {
  .auth-flow-surface {
    width: min(100%, 620px);
    grid-template-columns: 1fr;
  }

  .auth-flow-context {
    min-height: auto;
    padding: 34px;
  }

  .auth-flow-context h1 {
    max-width: 540px;
    font-size: clamp(29px, 7vw, 40px);
  }

  .auth-flow-context-list {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    font-size: 10px;
  }
}

@media (max-width: 640px) {
  .auth-flow-brand-header {
    padding: 16px;
  }

  .auth-flow-brand-link {
    gap: 9px;
    padding: 5px 7px;
  }

  .auth-flow-brand-link .logo-mark {
    width: 38px;
    height: 38px;
  }

  .auth-flow-brand-link .logo-copy b {
    font-size: 18px;
  }

  .auth-flow-experience {
    padding: 88px 12px 32px;
  }

  .auth-flow-surface {
    border-radius: 20px;
  }

  .auth-flow-context {
    padding: 27px 23px;
  }

  .auth-flow-context p {
    font-size: 14px;
  }

  .auth-flow-context-list {
    grid-template-columns: 1fr;
  }

  .auth-flow-panel.auth-card {
    padding: 30px 23px;
  }
}

html[data-theme="dark"] body.auth-flow-body {
  --auth-flow-navy: #f4f7fc;
  --auth-flow-muted: #9aabc2;
  --auth-flow-line: #2a3950;
  color-scheme: dark;
  color: #d8e2f0;
  background: #0b1220;
}

html[data-theme="dark"] .auth-flow-experience {
  background:
    radial-gradient(circle at 12% 20%, rgba(23, 104, 255, .18), transparent 31%),
    linear-gradient(180deg, #0e1829 0%, #0b1220 100%);
}

html[data-theme="dark"] .auth-flow-surface,
html[data-theme="dark"] .auth-flow-panel.auth-card {
  border-color: var(--auth-flow-line);
  background: #111b2b;
  color: #d8e2f0;
}

html[data-theme="dark"] .auth-flow-brand-link:hover {
  background: rgba(23, 34, 53, .82);
}

html[data-theme="dark"] .auth-flow-panel .input,
html[data-theme="dark"] .auth-flow-panel .select,
html[data-theme="dark"] .auth-flow-panel input,
html[data-theme="dark"] .auth-flow-panel textarea {
  border-color: var(--auth-flow-line);
  background: #172235;
  color: #f4f7fc;
}

html[data-theme="dark"] .auth-flow-panel .field label,
html[data-theme="dark"] .auth-flow-panel .auth-status h2 {
  color: #d8e2f0;
}

@media (prefers-reduced-motion: no-preference) {
  .auth-flow-brand-header {
    animation: auth-flow-brand-enter 360ms cubic-bezier(.22, 1, .36, 1) both;
  }

  .auth-flow-surface {
    animation: auth-flow-surface-enter 440ms cubic-bezier(.22, 1, .36, 1) both;
  }

  .auth-flow-context {
    animation: auth-flow-context-enter 520ms cubic-bezier(.22, 1, .36, 1) 50ms both;
  }

  .auth-flow-panel {
    animation: auth-flow-panel-enter 480ms cubic-bezier(.22, 1, .36, 1) 110ms both;
  }
}

@keyframes auth-flow-brand-enter {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes auth-flow-surface-enter {
  from { opacity: 0; transform: translateY(12px) scale(.992); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes auth-flow-context-enter {
  from { opacity: 0; transform: translateX(-14px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes auth-flow-panel-enter {
  from { opacity: 0; transform: translateX(14px); }
  to { opacity: 1; transform: translateX(0); }
}

@media (prefers-reduced-motion: reduce) {
  .auth-flow-brand-header,
  .auth-flow-surface,
  .auth-flow-context,
  .auth-flow-panel {
    animation: none;
  }
}
