/* FambuyPay auth — calm split-card onboarding */

.fp-auth-wrap {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 1.5rem 1rem;
  background:
    radial-gradient(900px 420px at 10% -10%, rgba(26, 92, 255, 0.1), transparent 55%),
    radial-gradient(700px 360px at 100% 100%, rgba(18, 183, 106, 0.06), transparent 50%),
    #eef1f6;
}

.fp-auth-split {
  width: 100%;
  max-width: 920px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: #ffffff;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(15, 23, 42, 0.08), 0 1px 2px rgba(15, 23, 42, 0.04);
  animation: fp-auth-rise 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes fp-auth-rise {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.fp-auth-pane {
  padding: 2.15rem 2.25rem 2rem;
  min-height: 520px;
  display: flex;
  flex-direction: column;
}

.fp-auth-pane-form {
  background: #fff;
}

.fp-auth-pane-marketing {
  background:
    radial-gradient(420px 280px at 70% 20%, rgba(26, 92, 255, 0.08), transparent 60%),
    #f5f7fb;
  align-items: center;
  text-align: center;
  justify-content: space-between;
  gap: 1rem;
  position: relative;
}

.fp-auth-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--fp-ink);
  text-decoration: none;
  margin-bottom: 1.5rem;
}

.fp-auth-brand:hover { text-decoration: none; }

.fp-auth-brand .fp-mark {
  width: 32px;
  height: 32px;
  font-size: 0.8rem;
  animation: none;
  background: var(--fp-primary);
  box-shadow: none;
}

.fp-auth-title {
  font-family: var(--fp-font);
  font-size: 1.7rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--fp-ink);
  margin: 0 0 1.25rem;
  line-height: 1.22;
}

.fp-auth-sub {
  color: var(--fp-muted);
  margin: -0.75rem 0 1.25rem;
  font-size: 0.95rem;
}

.fp-auth-sub strong {
  color: var(--fp-ink);
  font-weight: 600;
}

.fp-auth-label {
  display: block;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--fp-ink);
  margin-bottom: 0.45rem;
}

.fp-auth-error { margin-bottom: 1rem; }

.fp-auth-form {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.fp-auth-field { margin-bottom: 0.85rem; }

.fp-auth-phone-input {
  display: flex;
  align-items: center;
  width: 100%;
  border: 1.5px solid #d0d5dd;
  border-radius: 12px;
  background: #fff;
  overflow: hidden;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
  position: relative;
}

.fp-auth-phone-input.is-valid {
  border-color: #12b76a;
}

.fp-auth-phone-input:focus-within {
  border-color: var(--fp-primary);
  box-shadow: 0 0 0 3px rgba(26, 92, 255, 0.15);
}

.fp-auth-cc {
  flex-shrink: 0;
  padding: 0.95rem 0 0.95rem 1rem;
  font-weight: 600;
  font-size: 0.98rem;
  color: var(--fp-ink);
  white-space: nowrap;
  user-select: none;
}

.fp-auth-input {
  flex: 1;
  min-width: 0;
  border: none;
  background: transparent;
  padding: 0.95rem 2.5rem 0.95rem 0.65rem;
  font: inherit;
  font-size: 1rem;
  color: var(--fp-ink);
}

.fp-auth-input::placeholder { color: #98a2b3; }
.fp-auth-input:focus { outline: none; }

.fp-auth-valid-icon {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  line-height: 0;
}

.fp-auth-input-solo {
  width: 100%;
  border: 1.5px solid #d0d5dd;
  border-radius: 12px;
  padding: 0.95rem 1rem;
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.fp-auth-input-solo:focus {
  outline: none;
  border-color: var(--fp-primary);
  box-shadow: 0 0 0 3px rgba(26, 92, 255, 0.15);
}

/* Password control: the wrapper is the bordered box, the toggle sits inside it */
.fp-auth-password {
  position: relative;
  display: block;
  width: 100%;
  border: 1.5px solid #d0d5dd;
  border-radius: 12px;
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.fp-auth-password:focus-within {
  border-color: var(--fp-primary);
  box-shadow: 0 0 0 3px rgba(26, 92, 255, 0.15);
}

.fp-auth-password .fp-auth-password-input {
  display: block;
  width: 100%;
  flex: none;
  border: 0;
  border-radius: 10px;
  background: transparent;
  padding: 0.95rem 3.25rem 0.95rem 1rem;
  box-shadow: none;
}

.fp-auth-password .fp-auth-password-input:focus {
  outline: none;
  box-shadow: none;
}

.fp-auth-password .fp-auth-pw-toggle {
  position: absolute;
  top: 50%;
  right: 0.45rem;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #667085;
  cursor: pointer;
  line-height: 0;
  transition: color 0.15s ease, background-color 0.15s ease;
}

.fp-auth-password .fp-auth-pw-toggle:hover {
  color: var(--fp-ink);
  background: #f2f4f7;
}

.fp-auth-password .fp-auth-pw-toggle:focus-visible {
  outline: 2px solid var(--fp-primary);
  outline-offset: 1px;
}

.fp-auth-pw-toggle .fp-auth-pw-icon {
  display: block;
  flex-shrink: 0;
  pointer-events: none;
}

.fp-auth-pw-toggle .fp-auth-pw-icon-hide,
.fp-auth-pw-toggle[aria-pressed="true"] .fp-auth-pw-icon-show { display: none; }
.fp-auth-pw-toggle[aria-pressed="true"] .fp-auth-pw-icon-hide { display: block; }

.fp-auth-switch {
  display: inline-block;
  align-self: flex-start;
  background: none;
  border: none;
  padding: 0;
  margin: 0.15rem 0 1.25rem;
  color: var(--fp-primary);
  font: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  text-decoration: none;
}

.fp-auth-switch:hover { text-decoration: underline; }

.fp-auth-remember {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.35rem;
  color: #667085;
  font-size: 0.95rem;
}

.fp-auth-toggle {
  position: relative;
  display: inline-flex;
  cursor: pointer;
  flex-shrink: 0;
}

.fp-auth-toggle input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.fp-auth-toggle-track {
  display: block;
  width: 44px;
  height: 26px;
  border-radius: 999px;
  background: #d0d5dd;
  position: relative;
  transition: background 0.2s ease;
}

.fp-auth-toggle-thumb {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(16, 24, 40, 0.2);
  transition: transform 0.2s ease;
}

.fp-auth-toggle input:checked + .fp-auth-toggle-track {
  background: var(--fp-primary);
}

.fp-auth-toggle input:checked + .fp-auth-toggle-track .fp-auth-toggle-thumb {
  transform: translateX(18px);
}

.fp-auth-continue {
  width: 100%;
  border: none;
  border-radius: 12px;
  padding: 0.95rem 1.15rem;
  font: inherit;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  background: #d0d5dd;
  color: #667085;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
  margin-top: auto;
}

.fp-auth-continue:disabled {
  cursor: not-allowed;
  background: #e4e7ec;
  color: #98a2b3;
}

.fp-auth-continue:not(:disabled) {
  background: var(--fp-primary);
  color: #fff;
  box-shadow: 0 6px 16px rgba(26, 92, 255, 0.25);
}

.fp-auth-continue:not(:disabled):hover {
  background: var(--fp-primary-dark);
  transform: translateY(-1px);
}

.fp-auth-or {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 1.15rem 0;
  color: #98a2b3;
  font-size: 0.8rem;
  font-weight: 600;
}

.fp-auth-or::before,
.fp-auth-or::after {
  content: "";
  flex: 1;
  height: 1px;
  background: #e4e7ec;
}

.fp-auth-passkey-btn {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  border: none;
  border-radius: 10px;
  padding: 0.9rem 1rem;
  font: inherit;
  font-weight: 600;
  font-size: 0.98rem;
  cursor: pointer;
  background: #e8f0ff;
  color: var(--fp-primary);
  transition: background 0.15s ease;
}

.fp-auth-passkey-btn:hover {
  background: #d6e6ff;
}

.fp-auth-alias {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  align-self: flex-start;
  border: 1px solid transparent;
  background: #f4f6fa;
  border-radius: 999px;
  padding: 0.4rem 0.85rem;
  font: inherit;
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--fp-ink);
  cursor: pointer;
  margin-bottom: 1.25rem;
  transition: background 0.15s ease;
}

.fp-auth-alias:hover {
  border-color: transparent;
  background: #e8ecf2;
}

.fp-auth-otp-lead {
  text-align: center;
  color: var(--fp-ink);
  font-size: 0.98rem;
  margin: 0 0 1.25rem;
}

.fp-auth-otp-boxes {
  display: flex;
  justify-content: center;
  gap: 0.55rem;
  margin-bottom: 0.85rem;
}

.fp-auth-otp-digit {
  width: 52px;
  height: 56px;
  text-align: center;
  font-size: 1.35rem;
  font-weight: 600;
  border: 1.5px solid #d0d5dd;
  border-radius: 12px;
  background: #fff;
  color: var(--fp-ink);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.fp-auth-otp-digit:focus {
  outline: none;
  border-color: var(--fp-primary);
  box-shadow: 0 0 0 3px rgba(26, 92, 255, 0.15);
}

.fp-auth-resend,
.fp-auth-resend-form .fp-auth-resend {
  background: none;
  border: none;
  color: var(--fp-primary);
  font: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  padding: 0;
  margin: 0 0 0.25rem;
  align-self: flex-start;
}

.fp-auth-resend:hover { text-decoration: underline; }

.fp-auth-ussd {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  color: var(--fp-ink);
  font-size: 0.98rem;
  margin-bottom: 1.35rem;
}

.fp-auth-ussd code {
  font-family: inherit;
  font-weight: 700;
  background: none;
}

.fp-auth-copy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: none;
  color: var(--fp-muted);
  cursor: pointer;
  padding: 0.2rem;
  border-radius: 6px;
}

.fp-auth-copy:hover { color: var(--fp-primary); background: #e8f0ff; }

.fp-auth-gender {
  display: flex;
  gap: 1.5rem;
  margin-top: 0.35rem;
}

.fp-auth-radio {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.98rem;
  color: var(--fp-ink);
  cursor: pointer;
}

.fp-auth-radio input {
  width: 18px;
  height: 18px;
  accent-color: var(--fp-primary);
}

.fp-auth-footer {
  margin: 1.35rem 0 0;
  color: var(--fp-muted);
  font-size: 0.9rem;
  text-align: center;
}

.fp-auth-alt {
  margin-top: 0.85rem;
  text-align: center;
}

.fp-auth-back {
  background: none;
  border: none;
  color: var(--fp-muted);
  font: inherit;
  font-size: 0.9rem;
  cursor: pointer;
  padding: 0.35rem;
}

.fp-auth-back:hover { color: var(--fp-ink); }

/* Marketing carousel */
.fp-auth-carousel {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 100%;
  max-width: 360px;
}

.fp-auth-slide { animation: fp-auth-fade 0.4s ease; }

@keyframes fp-auth-fade {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.fp-auth-art {
  position: relative;
  height: 220px;
  margin: 0 auto 1.25rem;
  width: 100%;
  max-width: 280px;
}

.fp-auth-art-phone {
  position: absolute;
  left: 50%;
  top: 20px;
  transform: translateX(-40%);
  width: 110px;
  height: 180px;
  background: linear-gradient(160deg, #3b82f6, #1a5cff);
  border-radius: 18px;
  box-shadow: 0 12px 28px rgba(26, 92, 255, 0.28);
  padding: 10px;
}

.fp-auth-art-screen {
  height: 100%;
  background: #fff;
  border-radius: 10px;
  display: grid;
  place-items: center;
}

.fp-auth-art-cart {
  width: 36px;
  height: 36px;
  border: 3px solid #1a5cff;
  border-radius: 8px;
  position: relative;
}

.fp-auth-art-cart::after {
  content: "";
  position: absolute;
  bottom: -8px;
  left: 6px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #1a5cff;
  box-shadow: 14px 0 0 #1a5cff;
}

.fp-auth-float {
  position: absolute;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 6px 16px rgba(16, 24, 40, 0.12);
  font-size: 0.65rem;
  font-weight: 800;
  color: #1a5cff;
  animation: fp-float 3.2s ease-in-out infinite;
}

@keyframes fp-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.fp-auth-float-visa {
  width: 48px;
  height: 48px;
  left: 8px;
  top: 36px;
  animation-delay: 0.2s;
}

.fp-auth-float-mc {
  width: 42px;
  height: 42px;
  right: 18px;
  top: 24px;
  animation-delay: 0.6s;
}

.fp-auth-float-mc::before,
.fp-auth-float-mc::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  border-radius: 50%;
}

.fp-auth-float-mc::before { background: #eb001b; left: 8px; }
.fp-auth-float-mc::after { background: #f79e1b; right: 8px; opacity: 0.9; }

.fp-auth-float-mask {
  width: 46px;
  height: 46px;
  right: 10px;
  bottom: 40px;
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  animation-delay: 1s;
}

.fp-auth-float-person {
  width: 52px;
  height: 52px;
  left: 24px;
  bottom: 28px;
  background: linear-gradient(180deg, #93c5fd, #1a5cff);
  animation-delay: 0.4s;
}

.fp-auth-float-person::before {
  content: "";
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #fff;
  margin-top: -6px;
}

.fp-auth-art-laptop {
  position: absolute;
  left: 50%;
  top: 40px;
  transform: translateX(-50%);
  width: 200px;
}

.fp-auth-art-laptop-screen {
  height: 120px;
  background: linear-gradient(160deg, #dbeafe, #eff6ff);
  border: 3px solid #334155;
  border-radius: 10px 10px 4px 4px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.fp-auth-art-laptop::after {
  content: "";
  display: block;
  height: 10px;
  background: #64748b;
  border-radius: 0 0 8px 8px;
  margin: 0 -8px;
}

.fp-auth-art-fingerprint {
  width: 28px;
  height: 28px;
  border: 2.5px solid #1a5cff;
  border-radius: 50%;
  box-shadow: inset 0 0 0 5px #fff, inset 0 0 0 7px #1a5cff;
}

.fp-auth-art-url {
  font-size: 0.65rem;
  color: #64748b;
  background: #fff;
  border-radius: 999px;
  padding: 0.2rem 0.55rem;
  border: 1px solid #e2e8f0;
}

.fp-auth-float-key {
  width: 44px;
  height: 44px;
  left: 16px;
  top: 48px;
  background: #fff;
}

.fp-auth-float-key::before {
  content: "";
  width: 12px;
  height: 12px;
  border: 2.5px solid #1a5cff;
  border-radius: 50%;
  box-shadow: 10px 4px 0 -5px #1a5cff, 10px 8px 0 -5px #1a5cff;
}

.fp-auth-float-face {
  width: 48px;
  height: 48px;
  right: 12px;
  top: 56px;
  animation-delay: 0.5s;
}

.fp-auth-float-face::before {
  content: "";
  width: 22px;
  height: 22px;
  border: 2px solid #1a5cff;
  border-radius: 6px;
}

.fp-auth-marketing-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--fp-ink);
  margin: 0 0 0.5rem;
  letter-spacing: -0.01em;
}

.fp-auth-marketing-body {
  margin: 0;
  color: #667085;
  font-size: 0.9rem;
  line-height: 1.45;
}

.fp-auth-dots {
  display: flex;
  gap: 0.45rem;
  justify-content: center;
  margin-top: 1rem;
}

.fp-auth-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  padding: 0;
  background: #d0d5dd;
  cursor: pointer;
}

.fp-auth-dot.is-active { background: var(--fp-primary); }

/* Passkey modal */
.fp-shell.is-blurred {
  filter: blur(5px);
  pointer-events: none;
  user-select: none;
}

.fp-passkey-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: 1.25rem;
  background: rgba(16, 24, 40, 0.28);
  backdrop-filter: blur(2px);
  animation: fp-auth-fade 0.3s ease;
}

.fp-passkey-modal {
  width: 100%;
  max-width: 520px;
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.16);
  display: grid;
  grid-template-columns: 140px 1fr;
  overflow: hidden;
  animation: fp-auth-rise 0.35s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.fp-passkey-art {
  background: #e8f0ff;
  display: grid;
  place-items: center;
  padding: 1.5rem;
}

.fp-passkey-body {
  padding: 1.5rem 1.5rem 1.25rem;
}

.fp-passkey-body h2 {
  margin: 0 0 0.5rem;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--fp-ink);
}

.fp-passkey-body p {
  margin: 0 0 1.35rem;
  color: #667085;
  font-size: 0.95rem;
  line-height: 1.45;
}

.fp-passkey-actions {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.fp-passkey-primary {
  background: none;
  border: none;
  color: var(--fp-primary);
  font: inherit;
  font-weight: 700;
  font-size: 0.98rem;
  cursor: pointer;
  padding: 0;
}

.fp-passkey-primary:hover { text-decoration: underline; }

.fp-passkey-secondary {
  background: none;
  border: none;
  color: #98a2b3;
  font: inherit;
  font-weight: 600;
  font-size: 0.98rem;
  cursor: pointer;
  padding: 0;
}

.fp-passkey-secondary:hover { color: #667085; }

@media (max-width: 820px) {
  .fp-auth-split {
    grid-template-columns: 1fr;
    max-width: 440px;
  }

  .fp-auth-pane-marketing {
    min-height: 0;
    padding: 1.5rem 1.5rem 1.25rem;
    order: 2;
  }

  .fp-auth-art { height: 160px; max-width: 220px; }

  .fp-passkey-modal {
    grid-template-columns: 1fr;
  }

  .fp-passkey-art {
    min-height: 100px;
  }
}

@media (max-width: 480px) {
  .fp-auth-pane {
    padding: 1.5rem 1.25rem 1.35rem;
    min-height: 0;
  }

  .fp-auth-title { font-size: 1.45rem; }

  .fp-auth-wrap {
    padding: 1rem 0.75rem;
    align-items: flex-start;
    padding-top: 2rem;
  }

  .fp-auth-otp-digit {
    width: 44px;
    height: 50px;
  }
}
