/* ======================================================
   FORGOT PASSWORD PAGE CSS
   File: frontend/authCSS/forgot-password.css
   Purpose:
   - Styles only the forgot password page
   - Keeps forgot password design separated from global style.css
====================================================== */

/* ======================================================
   SECTION 1: Page background and layout
   Centers the forgot password card.
====================================================== */

.forgot-page {
  min-height: 100vh;
  background:
    linear-gradient(rgba(15, 23, 42, 0.65), rgba(15, 23, 42, 0.48)),
    url("../images/background.jpg") center/cover no-repeat;

  display: flex;
  align-items: center;
  justify-content: center;

  padding: 40px 16px;
  color: #0f172a;

  overflow-x: hidden;
  overflow-y: auto;
}

.forgot-card {
  width: 100%;
  max-width: 520px;
  background: rgba(255, 255, 255, 0.97);
  border-radius: 30px;
  padding: 34px 30px;
  box-shadow: 0 24px 50px rgba(2, 37, 117, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.7);
}

.forgot-card * {
  box-sizing: border-box;
}

.forgot-badge {
  display: inline-flex;
  padding: 9px 13px;
  border-radius: 999px;
  background: #ecfeff;
  color: #0f766e;
  font-weight: 800;
  font-size: 0.85rem;
  margin-bottom: 16px;
  border: 1px solid #99f6e4;
}

.forgot-card h1 {
  margin: 0 0 8px;
  color: #0f172a;
  font-size: 2rem;
}

.forgot-card p {
  margin: 0 0 20px;
  color: #64748b;
  line-height: 1.65;
}

/* ======================================================
   SECTION 2: Form styling
   Styles inputs, labels, and buttons.
====================================================== */

.forgot-form {
  display: grid;
  gap: 14px;
  width: 100%;
}

.form-group label {
  display: block;
  margin-bottom: 7px;
  color: #0f172a;
  font-weight: 800;
}

.form-group input {
  width: 100%;
  max-width: 100%;
  padding: 14px 15px;
  border: 1px solid #cbd5e1;
  border-radius: 16px;
  outline: none;
  font-size: 1rem;
  background: #fff;
}

.form-group input:focus {
  border-color: #14b8a6;
  box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.15);
}

/* ======================================================
   SECTION 3: OTP section
   Hidden by default, visible after OTP is sent.
====================================================== */

.otp-section {
  display: none;
  background: #f8fafc;
  border: 1px solid #dbe7ef;
  border-radius: 18px;
  padding: 16px;
  margin-top: 0;
}

.otp-section.show {
  display: block;
}

.action-row {
  display: grid;
  gap: 10px;
  margin-top: 6px;
}

/* ======================================================
   SECTION 4: Buttons
   Primary button for send/reset, secondary for resend/back.
====================================================== */

.primary-btn,
.secondary-btn {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  padding: 14px 16px;
  border: none;
  border-radius: 16px;
  font-weight: 800;
  font-size: 1rem;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  transition: 0.2s ease;
}

.primary-btn {
  background: linear-gradient(135deg, #14b8a6, #0f9488);
  color: white;
  box-shadow: 0 14px 28px rgba(20, 184, 166, 0.2);
}

.secondary-btn {
  background: #e2e8f0;
  color: #0f172a;
}

.primary-btn:hover:not(:disabled),
.secondary-btn:hover:not(:disabled) {
  transform: translateY(-1px);
  filter: brightness(1.03);
}

.primary-btn:disabled,
.secondary-btn:disabled {
  opacity: 0.75;
  cursor: not-allowed;
  transform: none;
  filter: none;
}

.primary-btn:disabled {
  background: linear-gradient(135deg, #14b8a6, #0f9488);
  color: white;
}

.secondary-btn:disabled {
  background: #e2e8f0;
  color: #0f172a;
}

/* ======================================================
   SECTION 5: Message styling
   Shows OTP/reset messages below the form.
====================================================== */

.message {
  margin-top: 14px;
  text-align: center;
  font-weight: 800;
  line-height: 1.5;
}

/* ======================================================
   SECTION 6: Resend OTP timer text
   Shows countdown before user can resend another OTP.
====================================================== */

.resend-timer-text {
  margin: 8px 0 0;
  text-align: center;
  color: #64748b;
  font-size: 0.9rem;
  font-weight: 800;
}

/* ======================================================
   SECTION 7: Large form height handling
   If OTP form becomes tall, keep it readable on small screens.
====================================================== */

@media (max-height: 760px) {
  .forgot-page {
    align-items: flex-start;
  }
}

/* ======================================================
   SECTION 8: Mobile responsiveness
   Adjusts spacing for phones.
====================================================== */

@media (max-width: 480px) {
  .forgot-card {
    padding: 24px 18px;
    border-radius: 22px;
  }

  .forgot-card h1 {
    font-size: 1.65rem;
  }
}