/* Premium Authentication Page Stylesheet - Login Computers */

:root {
  --bg-app-dark: #0f172a;
  --bg-card: rgba(255, 255, 255, 0.85);
  --text-main: #1e293b;
  --text-muted: #64748b;
  --primary: #4f46e5;
  --primary-hover: #4338ca;
  --secondary: #3b82f6;
  --success: #10b981;
  --danger: #ef4444;
  --border-color: rgba(226, 232, 240, 0.8);
  --border-radius: 16px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --font-sans: 'Google Sans Flex', 'Google Sans', 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

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

body.auth-page {
  font-family: var(--font-sans);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(-45deg, #0f172a, #1e1b4b, #311042, #1e293b);
  background-size: 400% 400%;
  animation: gradientBG 15s ease infinite;
  padding: 20px;
  overflow-x: hidden;
}

@keyframes gradientBG {
  0% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

/* Auth Container & Glassmorphism Card */
.auth-container {
  width: 100%;
  max-width: 450px;
  perspective: 1000px;
}

.auth-card {
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: var(--border-radius);
  padding: 40px 32px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
  animation: cardEntrance 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  opacity: 0;
  transform: translateY(30px);
}

@keyframes cardEntrance {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Logo and Header */
.auth-header {
  text-align: center;
  margin-bottom: 32px;
}

.auth-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  height: auto;
  max-width: 100%;
  background: transparent;
  color: #ffffff;
  border-radius: 12px;
  margin-bottom: 16px;
  box-shadow: none;
}

.auth-logo img {
  width: 100px;
  max-width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
}

.auth-title {
  color: var(--text-main);
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-bottom: 8px;
}

.auth-subtitle {
  color: var(--text-muted);
  font-size: 0.875rem;
}

/* Forms & Inputs */
.form-group {
  margin-bottom: 20px;
  position: relative;
}

.form-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 6px;
}

.input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.input-wrapper i.prefix-icon {
  position: absolute;
  left: 14px;
  color: var(--text-muted);
  font-size: 1.1rem;
  transition: var(--transition);
  pointer-events: none;
}

.auth-input {
  width: 100%;
  padding: 12px 14px 12px 42px;
  font-size: 0.95rem;
  font-family: var(--font-sans);
  color: var(--text-main);
  background: rgba(248, 250, 252, 0.8);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  outline: none;
  transition: var(--transition);
}

.auth-input:focus {
  background: #ffffff;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.15);
}

.auth-input:focus+i.prefix-icon {
  color: var(--primary);
}

/* Password Toggle Visibility Button */
.btn-toggle-password {
  position: absolute;
  right: 14px;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.btn-toggle-password:hover {
  color: var(--primary);
}

/* Alerts */
.auth-alert {
  padding: 12px 16px;
  border-radius: 10px;
  font-size: 0.875rem;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 10px;
  animation: alertFadeIn 0.3s ease-out;
}

@keyframes alertFadeIn {
  from {
    opacity: 0;
    transform: translateY(-5px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.auth-alert-danger {
  background: #fef2f2;
  border: 1px solid #fee2e2;
  color: var(--danger);
}

.auth-alert-success {
  background: #ecfdf5;
  border: 1px solid #d1fae5;
  color: var(--success);
}

/* Links & Helper Texts */
.form-options {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 24px;
}

.auth-link {
  color: var(--primary);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  transition: var(--transition);
}

.auth-link:hover {
  color: var(--primary-hover);
  text-decoration: underline;
}

/* Buttons */
.btn-auth-submit {
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #ffffff;
  border: none;
  border-radius: 10px;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.25);
}

.btn-auth-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(79, 70, 229, 0.35);
}

.btn-auth-submit:active {
  transform: translateY(0);
}

/* Footer of the Card */
.auth-footer {
  text-align: center;
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* Debug output for developer email testing */
.debug-reset-box {
  margin-top: 20px;
  padding: 16px;
  background: #fffbeb;
  border: 1px solid #fef3c7;
  border-radius: 10px;
  color: #b45309;
  font-size: 0.85rem;
}

.debug-reset-box p {
  margin-bottom: 8px;
  font-weight: 600;
}

.debug-reset-link {
  display: inline-block;
  background: #ffffff;
  border: 1px solid #f59e0b;
  color: #d97706;
  padding: 8px 12px;
  border-radius: 6px;
  text-decoration: none;
  word-break: break-all;
  font-family: monospace;
  font-weight: bold;
  transition: var(--transition);
}

.debug-reset-link:hover {
  background: #fffbeb;
}

/* Mobile & Tablet Responsiveness for Auth Pages */
@media (max-width: 480px) {
  body.auth-page {
    padding: 16px 12px;
  }

  .auth-card {
    padding: 28px 20px;
    border-radius: 14px;
  }

  .auth-title {
    font-size: 1.3rem;
  }

  .auth-subtitle {
    font-size: 0.8rem;
  }

  .auth-logo img {
    width: 85px;
  }

  .auth-input {
    padding: 11px 12px 11px 38px;
    font-size: 0.9rem;
  }

  .btn-auth-submit {
    padding: 12px;
    font-size: 0.9rem;
  }
}