*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background: #ffffff;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.login-wrapper {
  width: 100%;
  padding: 24px 24px 80px 24px; /* extra bottom padding shifts content upward */
  display: flex;
  justify-content: center;
}

.login-card {
  width: 100%;
  max-width: 400px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

/* ── Logo ── */
.logo-wrap {
  width: 100%;
  display: flex;
  justify-content: center;
  margin-bottom: 8px;
}

.logo {
  width: 160px;
  object-fit: contain;
}

/* ── Info tip ── */
.info-tip {
  width: 100%;
  display: flex;
  align-items: flex-start;
  gap: 9px;
  background: #f5f0fa;
  border-left: 3px solid #4f2170;
  border-radius: 6px;
  padding: 10px 13px;
}

.info-tip__icon {
  font-size: 15px;
  color: #4f2170;
  line-height: 1.5;
  flex-shrink: 0;
}

.info-tip__text {
  font-size: 13px;
  color: #5a4060;
  line-height: 1.55;
}

/* ── Email input ── */
.form-group {
  width: 100%;
}

.field-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #3a2a4a;
  margin-bottom: 6px;
}

.required {
  color: #e53935;
}

.email-input {
  width: 100%;
  padding: 13px 16px;
  font-size: 15px;
  border: 1.5px solid #d1d5db;
  border-radius: 8px;
  outline: none;
  color: #1a1a1a;
  transition: border-color 0.2s;
  background: #ffffff;
  -webkit-appearance: none;
}

.email-input::placeholder {
  color: #9ca3af;
}

.email-input:focus {
  border-color: #4f2170;
}

/* ── Button ── */
.btn-primary {
  width: 100%;
  padding: 13px;
  font-size: 15px;
  font-weight: 600;
  color: #ffffff;
  background-color: #4f2170;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.2s, opacity 0.2s;
  letter-spacing: 0.3px;
  -webkit-tap-highlight-color: transparent;
}

.btn-primary:hover:not(:disabled) {
  background-color: #3d1958;
}

.btn-primary:active:not(:disabled) {
  background-color: #2e1242;
}

.btn-primary:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* ── OTP input ── */
.otp-input {
  text-align: center;
  font-size: 22px;
  font-weight: 600;
  letter-spacing: 10px;
  color: #4f2170;
}

.otp-input::placeholder {
  letter-spacing: 6px;
  font-size: 16px;
  font-weight: 400;
  color: #c4b5d4;
}

.otp-error {
  display: block;
  margin-top: 6px;
  font-size: 12.5px;
  color: #e53935;
  min-height: 18px;
}

/* ── Button loader spinner ── */
.btn-primary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.btn-loader {
  width: 16px;
  height: 16px;
  border: 2.5px solid rgba(255, 255, 255, 0.4);
  border-top-color: #ffffff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  flex-shrink: 0;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ── Back button ── */
.btn-back {
  background: none;
  border: none;
  color: #4f2170;
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 0;
  letter-spacing: 0.2px;
  text-decoration: underline;
  text-underline-offset: 3px;
  -webkit-tap-highlight-color: transparent;
}

.btn-back:hover {
  color: #3d1958;
}

/* ── Mobile responsive ── */
@media (max-width: 480px) {
  body {
    align-items: flex-start;
  }

  .login-wrapper {
    padding: 60px 20px 40px 20px;
  }

  .login-card {
    max-width: 100%;
    gap: 18px;
  }

  .logo {
    width: 140px;
  }

  .email-input,
  .btn-primary {
    font-size: 16px; /* prevents iOS zoom on focus */
  }
}
