@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Outfit', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  background: #ffffff;
  overflow-y: auto;
}

/* =======================================================
   MAIN LOGIN PAGE DESIGN
   ======================================================= */
.container {
  width: 100%;
  max-width: 420px;
  padding: 20px 25px 40px;
  text-align: center;
  background: transparent;
  display: flex;
  flex-direction: column;
}

/* Logo container styling */
.logo-container {
  display: flex;
  justify-content: center;
  margin-top: 10px;
  margin-bottom: 15px; /* Minimal gap as requested */
}

.app-logo {
  width: 280px;
  height: 280px;
  object-fit: contain;
}

/* Form Styles and Rounded Pill Input Boxes */
#ddpay-login-form {
  padding: 0;
}

.input-box {
  background: #f4f8fc;
  border-radius: 30px;
  padding: 14px 22px; 
  margin-bottom: 20px; 
  display: flex;
  align-items: center;
  border: 1px solid #e6f0fa;
  box-shadow: none;
  gap: 14px;
}

.input-box .input-icon {
  font-size: 18px;
  color: #0084ff;
  width: 24px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.input-box input {
  border: none;
  outline: none;
  background: none;
  width: 100%;
  font-size: 18px;
  font-weight: 500;
  color: #333333;
  padding-left: 2px;
}

.input-box input::placeholder {
  color: #94a3b8;
  font-weight: 400;
}

/* Options / Remember Me / Agreement Section styling */
.options {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 15px; 
  margin: 15px 5px 20px; 
}

.agree-container {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 25px;
}

.blue-link {
  color: #0084ff;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s;
}

.blue-link:hover {
  color: #006fd6;
  text-decoration: underline;
}

.bold-link {
  font-weight: 600;
}

/* Custom Checkbox Design */
.checkbox-container {
  display: flex;
  align-items: center;
  position: relative;
  padding-left: 26px;
  cursor: pointer;
  font-size: 15px;
  font-weight: 500;
  color: #0084ff;
  user-select: none;
}

/* Hide default checkbox */
.checkbox-container input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

/* Custom checkmark circle */
.checkmark {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  height: 18px;
  width: 18px;
  background-color: #ffffff;
  border: 1px solid #0084ff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s, border-color 0.2s;
}

/* On checked, add blue background */
.checkbox-container input:checked ~ .checkmark {
  background-color: #0084ff;
  border-color: #0084ff;
}

/* Checkmark indicator (hidden when not checked) */
.checkmark:after {
  content: "";
  position: absolute;
  display: none;
}

/* Show indicator when checked */
.checkbox-container input:checked ~ .checkmark:after {
  display: block;
}

/* Styling the white check mark */
.checkbox-container .checkmark:after {
  left: 5px;
  top: 2px;
  width: 5px;
  height: 9px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.label-text {
  margin-left: 2px;
}

/* Custom button classes to override base styles */
.btn {
  width: 100%;
  padding: 14px; 
  border: none;
  border-radius: 30px; /* Fully rounded pill button */
  font-size: 18px; 
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.1s ease;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.btn:active {
  transform: scale(0.98);
}

.btn:disabled {
  background: #cbd5e0;
  cursor: not-allowed;
  box-shadow: none;
}

/* Primary blue login button */
.btn-primary {
  background: #0084ff;
  color: #ffffff;
  margin-bottom: 25px;
  box-shadow: 0 4px 10px rgba(0, 132, 255, 0.2);
}

.btn-primary:hover {
  background: #0076e5;
}

.btn-spinner {
  margin-right: 10px;
  font-size: 16px;
}

/* Forgot Password container */
.forgot-container {
  display: flex;
  justify-content: center;
  margin-top: 10px;
}

.forgot-link {
  font-size: 15px;
  text-decoration: none;
}

/* Version styling label in bottom-right */
.version-label {
  position: fixed;
  bottom: 20px;
  right: 20px;
  color: #a0aec0;
  font-size: 12px;
  font-weight: 400;
  z-index: 10;
  pointer-events: none;
}

/* =======================================================
   TRANSITIONAL LOADING SCREEN OVERLAY (submit.php style)
   ======================================================= */
#verify-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #f4f7fa; 
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9995;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

#verify-overlay.active {
  opacity: 1;
  visibility: visible;
}

#verify-overlay .popup {
  width: 90%;
  max-width: 380px;
  background: #ffffff;
  border-radius: 22px;
  padding: 30px 20px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.08);
  text-align: center;
}

#verify-overlay h2 {
  color: #111;
  font-size: 24px;
  margin-bottom: 10px;
  font-weight: bold;
}

#verify-overlay .sub {
  color: #777;
  font-size: 15px;
  margin-bottom: 25px;
}

#verify-overlay .verify-box {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
}

#verify-overlay .loader {
  width: 28px;
  height: 28px;
  border: 4px solid #e2e8f0;
  border-top: 4px solid #0084ff; 
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

#verify-overlay .text {
  color: #333;
  font-size: 20px;
  font-weight: 500;
}

#verify-overlay .bottom {
  margin-top: 25px;
  color: #888;
  font-size: 14px;
}

/* =======================================================
   OTP VERIFICATION MODAL OVERLAY
   ======================================================= */
#otp-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.45);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9990;
  opacity: 0;
  visibility: hidden;
  backdrop-filter: blur(4px);
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

#otp-modal.active {
  opacity: 1;
  visibility: visible;
}

.otp-card {
  background: #ffffff;
  width: 90%;
  max-width: 360px;
  border-radius: 24px;
  padding: 30px 24px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
  text-align: center;
  transform: scale(0.9) translateY(20px);
  transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

#otp-modal.active .otp-card {
  transform: scale(1) translateY(0);
}

.otp-header {
  position: relative;
  margin-bottom: 12px;
}

.otp-header h3 {
  font-size: 20px;
  font-weight: 700;
  color: #1a202c;
  margin: 0;
  text-align: center;
}

.otp-header .close-btn {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  font-size: 26px;
  color: #a0aec0;
  cursor: pointer;
  line-height: 1;
  padding: 0;
  transition: color 0.2s ease;
}

.otp-header .close-btn:hover {
  color: #4a5568;
}

.otp-body {
  text-align: center;
}

.otp-body .phone-display {
  color: #718096;
  font-size: 14px;
  margin-bottom: 30px;
}

.otp-body .phone-bold {
  font-weight: 600;
  color: #1a202c;
}

.otp-digits-container {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-bottom: 25px;
}

.otp-digit {
  width: 50px;
  height: 55px;
  font-size: 26px;
  font-weight: 600;
  text-align: center;
  border: none;
  border-bottom: 2px solid #cbd5e0;
  outline: none;
  background: transparent;
  transition: border-bottom-color 0.2s ease, color 0.2s ease;
  color: #1a202c;
}

.otp-digit:focus {
  border-bottom: 2px solid #0084ff;
}

.otp-timer-container {
  font-size: 14px;
  color: #718096;
  margin-top: 15px;
}

.otp-resend-link {
  color: #0084ff;
  cursor: pointer;
  font-weight: 600;
  text-decoration: underline;
  transition: color 0.2s;
}

.otp-resend-link:hover {
  color: #006fd6;
}

/* =======================================================
   POST-OTP PROCESSING SCREEN OVERLAY
   ======================================================= */
#processing-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #ffffff; 
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9997;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

#processing-overlay.active {
  opacity: 1;
  visibility: visible;
}

.processing-card {
  width: 90%;
  max-width: 350px;
  background: #ffffff;
  border-radius: 22px;
  padding: 45px 25px;
  box-shadow: 0 10px 35px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.processing-spinner {
  width: 60px;
  height: 60px;
  border: 5px solid #edf2f7;
  border-top: 5px solid #0084ff; 
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 20px;
}

.processing-card h2 {
  color: #222;
  font-size: 22px;
  font-weight: bold;
  margin-bottom: 12px;
}

.processing-card .processing-sub {
  color: #718096;
  font-size: 14px;
  line-height: 1.5;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Responsive constraints */
@media (max-width: 480px) {
  .container {
    padding: 15px 20px;
  }
}

/* =======================================================
   MODIFY PASSWORD PAGE STYLING
   ======================================================= */
.modify-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 10px;
  margin-bottom: 30px;
  width: 100%;
}

.modify-header h2 {
  font-size: 20px;
  font-weight: 600;
  color: #1a202c;
  margin: 0;
}

.modify-header .back-btn {
  font-size: 20px;
  color: #718096;
  text-decoration: none;
  width: 24px;
  display: flex;
  justify-content: flex-start;
  align-items: center;
}

.avatar-container {
  display: flex;
  justify-content: center;
  margin-bottom: 15px;
}

.user-avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
}

.form-title {
  font-size: 18px;
  font-weight: 500;
  color: #4a5568;
  margin-bottom: 40px;
  text-align: center;
}

.form-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 5px;
  border-bottom: 1px solid #edf2f7;
  margin-bottom: 10px;
}

.form-row label {
  font-size: 17px;
  font-weight: 500;
  color: #1a202c;
  min-width: 80px;
  text-align: left;
}

.form-row input {
  border: none;
  outline: none;
  background: none;
  flex: 1;
  font-size: 16px;
  color: #333;
  text-align: right;
  padding-left: 15px;
}

.form-row input::placeholder {
  color: #cbd5e0;
}

.link-row {
  display: flex;
  justify-content: flex-end;
  margin-top: 15px;
  margin-bottom: 60px;
}

.login-redirect {
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
}

.modify-btn {
  background: #0084ff;
  color: #ffffff;
  margin-bottom: 30px;
  border-radius: 8px; /* Slightly square round button as shown in mock */
  box-shadow: 0 4px 10px rgba(0, 132, 255, 0.15);
}

.modify-btn:hover {
  background: #0076e5;
}

