:root {
  --bg: #fff;
  --card: #ffffff;
  --text: #101010;
  --muted: #6b7a99;
  --primary-start: #2f7bf6;
  --primary-end: #21a1ff;
  --primary: #1976d2;
  --input-bg: #f7f9fe;
  --input-border: #cfe0ff;
  --shadow: 0 20px 60px rgba(31, 62, 119, 0.18);
  --radius: 22px;
  --active-blue: #1976d2;
  --main-white: #fff;
  --main-grey: rgb(16, 16, 16, 0.6);
  --main-blue: #c4def4;
  --main-dark-grey: #101010;
  --main-ease: cubic-bezier(0.65, 0.05, 0.36, 1);
  --login-input-font-size: clamp(1rem, 2.1vh, 1.25rem);
  --login-label-font-size: clamp(1.125rem, 2.5vh, 1.5rem);
  --login-floating-label-font-size: clamp(0.875rem, 1.7vh, 1rem);
  --login-button-font-size: clamp(1.125rem, 2.3vh, 1.375rem);
  --login-actions-margin-top: clamp(0.15rem, 1.25vh, 0.75rem);
  --login-subtitle-margin: clamp(1.25rem, 3.6vh, 2.25rem);
  --login-control-height: clamp(3.1rem, 7.5vh, 4.5rem);
  --card-padding: clamp(1.25rem, 4.2vh, 3rem);
  --band-height: clamp(18rem, 25vh, 640px);
}
* {
  box-sizing: border-box;
}
html,
body {
  font-family: "Instrument Sans", sans-serif;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 36px;
  padding: 0;
  overflow-x: hidden;
  min-height: 100vh;
  padding: 1.5rem 0;
  height: 100%;
}
.form-container {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
}
.band {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  height: var(--band-height);
  background: linear-gradient(
    90deg,
    #339aff 0%,
    #1976d2 17.79%,
    #004c98 48.08%,
    #1976d2 82.69%,
    #339aff 100%
  );

  filter: saturate(110%);
  opacity: 0.85;
}
.card {
  position: relative;
  width: 100%;
  max-width: 732px;
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: 0px 4px 78.3px 0px #00000026;
  padding: var(--card-padding) 64px;
  border: 2px solid #c4def4;
  z-index: 1;
}

.logo {
  position: relative;
}
.logo::after {
  content: "";
  height: 1px;
  width: 200px;
  background: var(--main-grey);
  opacity: 0.2;
  display: block;
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translate(-50%, -50%);
}
.title {
  margin: 0 auto;
  max-width: 604px;
  font-size: clamp(1.85rem, min(5.2vh, 8.5vw), 3.1rem);
  line-height: 1.05;
  text-align: center;
  font-weight: 600;
}
.subtitle {
  text-align: center;
  margin: var(--login-subtitle-margin) 0;
  color: #101010;
  font-size: 1.125rem;
}
.subtitle a {
  color: var(--primary);
  font-weight: 600;
}
.forgot-link {
  margin: 0;
}

.invalid {
  border-color: #f06262;
  /* box-shadow: 0 0 0 4px rgba(240, 98, 98, 0.12); */
}
.error-wrapper {
  margin-top: 6px;
  height: 16px;
}
.error {
  color: #e94848;
  font-size: 13px;
  display: none;
}
.error.show {
  display: block;
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.mfs-method-selector {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.mfa-options {
  display: flex;
  gap: 16px;
}

.mfa-option {
  display: flex;
  align-items: center;
  padding: 12px 24px;
  border-radius: 8px;
  cursor: pointer;
  border: 1px solid #d0d7de;
  transition: background-color 0.2s ease;
  font-size: 14px;
}

.mfa-option:hover {
  background: #f5f5f5;
}

/* Hide radio */
.mfa-option input[type="radio"] {
  display: none;
}

/* Selected state */
.mfa-option input[type="radio"]:checked + * {
  color: #1976d2;
  font-weight: 500;
}

.mfa-option:has(input[type="radio"]:checked) {
  border-color: transparent;
  background: linear-gradient(90deg, #4481eb 0%, #04befe 100%);
  transition: background-color 0.2s ease;
  color: #fff;
}

.actions {
  display: flex;
  gap: 24px;
  align-items: stretch;
  margin-top: var(--login-actions-margin-top);
  flex-wrap: wrap;
  height: var(--login-control-height);
  .btn {
    font-size: var(--login-input-font-size);
  }
}

/* Login-only override: merchant_game_list_inputs.css is loaded after this file.
   The extra specificity keeps shared outlined inputs untouched elsewhere. */
.login-form .outlined-input input {
  height: var(--login-control-height);
  font-size: var(--login-input-font-size);
}
.login-form .outlined-input label {
  font-size: var(--login-input-font-size);
}

.btn {
  font-family: "Instrument Sans", sans-serif;
  font-size: 22px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  border: 0;
  cursor: pointer;
  text-decoration: none;
  user-select: none;
  transition:
    transform 0.04s,
    box-shadow 0.2s,
    background 0.2s,
    opacity 0.2s,
    filter 0.2s;
  white-space: nowrap;
}
.btn:active {
  transform: translateY(1px);
}
.btn-primary {
  background: linear-gradient(90deg, #4481eb 0%, #04befe 100%);
  color: #fff;
  flex: 1;
}

.btn-primary:disabled {
  cursor: wait;
  opacity: 0.65;
  filter: saturate(65%);
  box-shadow: none;
}

.btn-primary:disabled:active {
  transform: none;
}
.btn-secondary {
  background: #eaf1ff;
  color: var(--primary);
  flex: 2;
}

@media (max-width: 520px) {
  body {
    padding: 16px;
  }
  .band {
    display: none;
  }
  .card {
    border: 2px solid transparent;
    padding: 0;
    box-shadow: none;
  }
  .subtitle {
    font-size: 1rem;
  }
  .mfs-method-selector {
    flex-direction: column;
    gap: 12px;
  }
  .actions {
    flex-direction: column;
    flex-wrap: nowrap;
    height: 100%;
  }
  .btn {
    font-size: 1.125rem;
    min-height: 3.5rem;
  }
}

.inline-error {
  color: red;
}
