/* Keep the existing sign-in artwork above the global theme's canvas. */
html[class] body.auth-login-page {
  background-image:
    linear-gradient(90deg, rgba(1, 8, 20, .7), rgba(3, 12, 28, .48) 48%, rgba(1, 8, 20, .3)),
    var(--signin-backdrop-image) !important;
  background-position: center !important;
  background-size: cover !important;
  background-repeat: no-repeat !important;
  background-attachment: fixed !important;
}
html.bracketr-theme-light[class] body.auth-login-page {
  background-image:
    linear-gradient(90deg, rgba(241, 244, 248, .9), rgba(241, 244, 248, .62) 48%, rgba(241, 244, 248, .35)),
    var(--signin-backdrop-image) !important;
}
html.bracketr-theme-light .auth-login-page::before {
  background: linear-gradient(90deg, rgba(241, 244, 248, .35), transparent);
}
html.bracketr-theme-light .auth-login-page::after {
  background: linear-gradient(180deg, transparent, rgba(241, 244, 248, .6));
}
.auth-login-page .public-language-selector {
  position: static;
  display: flex;
  justify-content: flex-end;
  margin: 0 0 22px;
  max-width: 100%;
}
.auth-login-page .auth-card-heading { padding-top: 0; }
.auth-login-page .public-language-selector select {
  width: auto;
  max-width: 100%;
  min-height: 44px;
  padding-left: 42px;
}
@supports (appearance: base-select) {
  .auth-login-page .public-language-selector select.brk-language-flags-rich {
    display: flex;
    align-items: center;
    padding: 8px 12px;
  }
  .auth-login-page .public-language-selector select > button {
    min-height: 0;
    width: auto;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    background: transparent;
    color: inherit;
    font: inherit;
  }
}
.auth-login-page .public-language-selector select:focus-visible {
  outline: 2px solid var(--blue2);
  outline-offset: 3px;
}

/* Fit the ordinary sign-in and security steps without wasting vertical space. */
.auth-login-page .auth-login-shell {
  min-height: 100dvh;
  padding: 20px 0;
}
.auth-login-page .auth-login-card {
  padding: 24px;
}
.auth-login-page .public-language-selector { margin-bottom: 12px; }
.auth-login-page .auth-card-heading {
  gap: 8px;
  margin-bottom: 20px;
}
.auth-login-page .auth-card-heading img { width: min(190px, 72%); }
.auth-login-page .auth-card-heading h2 {
  margin-top: 8px;
  font-size: 1.5rem;
  line-height: 1.2;
}
.auth-login-page .auth-primary-form,
.auth-login-page .auth-secondary-form,
.auth-login-page .auth-social-actions { gap: 10px; }
.auth-login-page input:not([type="checkbox"]):not([type="radio"]) {
  min-height: 48px;
}
.auth-login-page .auth-actions-row button,
.auth-login-page .auth-button-row button,
.auth-login-page .auth-inline-links .auth-link-button,
.auth-login-page .auth-provider-button,
.auth-login-page .auth-code-mode-toggle {
  min-height: 44px;
  margin-top: 0;
  padding-top: 8px;
  padding-bottom: 8px;
}
.auth-login-page .auth-divider { margin: 14px 0; }
.auth-login-page .auth-remember-help,
.auth-login-page .auth-social-actions > p {
  line-height: 1.4;
}
.auth-login-page .message:empty { display: none; }

@media (max-width: 980px) {
  /* The card already carries the brand. Avoid stacking the full hero above it. */
  .auth-login-page .auth-login-hero { display: none; }
  .auth-login-page .auth-login-shell {
    width: min(480px, calc(100% - 24px));
    gap: 0;
    padding: 16px 0;
  }
}
@media (max-width: 560px) {
  .auth-login-page .auth-login-card { padding: 20px; }
  .auth-login-page .auth-inline-links {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
  }
  .auth-login-page .auth-inline-links > * { min-width: 0; }
}
@media (max-height: 740px) {
  .auth-login-page .auth-login-shell { padding-top: 12px; padding-bottom: 12px; }
  .auth-login-page .auth-login-card { padding: 16px; }
  .auth-login-page .auth-card-heading img { width: min(170px, 72%); }
  .auth-login-page .auth-card-heading { margin-bottom: 10px; }
  .auth-login-page .public-language-selector { margin-bottom: 8px; }
}
