/* Password Policy Styles */

.password-policy-container {
  position: relative;
  width: 100%;
}

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

.password-input-wrapper input[type="password"],
.password-input-wrapper input[type="text"] {
  padding-right: 2.5rem; /* Space for toggle button */
}

.password-toggle-btn {
  position: absolute;
  right: 0.75rem;
  padding: 0.25rem 0.5rem;
  cursor: pointer;
  transition: color 0.2s ease;
  border: none;
  background: transparent;
}

.password-toggle-btn:hover {
  opacity: 0.7;
}

.password-toggle-btn:focus {
  outline: 2px solid #3b82f6;
  outline-offset: 2px;
  border-radius: 0.25rem;
}

.password-requirements {
  display: none;
  animation: slideDown 0.2s ease-out;
  background-color: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 0.375rem;
  padding: 0.75rem;
  margin-top: 0.5rem;
}

.password-requirements.show {
  display: block;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-0.5rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.password-requirement {
  display: flex;
  align-items: center;
  transition: color 0.2s ease;
  font-size: 0.875rem;
}

.password-requirement.text-success {
  color: #16a34a;
}

.password-requirement.text-success i {
  color: #16a34a;
}

.password-requirement.text-danger {
  color: #dc2626;
}

.password-requirement.text-danger i {
  color: #dc2626;
}

.requirement-label {
  flex: 1;
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
  .password-requirements {
    background-color: #1f2937;
    border-color: #374151;
  }

  .password-toggle-btn {
    color: #9ca3af;
  }

  .password-toggle-btn:hover {
    color: #d1d5db;
  }

  .password-requirement.text-success {
    color: #4ade80;
  }

  .password-requirement.text-success i {
    color: #4ade80;
  }
}
