/* Estilos para el sistema de validación de contraseñas */

.password-strength {
  font-size: 12px;
  margin-top: 5px;
}

/* Contenedor para la barra de fortaleza y texto */
.password-strength-container {
  display: flex;
  align-items: center;
  margin-bottom: 5px;
}

/* Barra de progreso de fortaleza */
.password-strength-bar {
  width: 100px;
  height: 8px;
  background-color: #e9ecef;
  border-radius: 4px;
  overflow: hidden;
  position: relative;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
}

.password-strength-progress {
  height: 100%;
  border-radius: 4px;
  transition: all 0.3s ease;
  position: relative;
}

/* Efecto de brillo en la barra */
.password-strength-progress::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 50%;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.3), transparent);
  border-radius: 4px 4px 0 0;
}

.password-strength span {
  padding: 2px 8px;
  border-radius: 3px;
  display: inline-block;
}

.password-criteria {
  font-size: 11px;
  margin-top: 3px;
}

.password-criteria small {
  color: #6d0d0a;
}

.text-success {
  color: #28a745 !important;
}

.text-warning {
  color: #ffc107 !important;
}

.text-danger {
  color: #dc3545 !important;
}

/* Estilos para campos de contraseña con validación */
.password-field {
  position: relative;
}

.password-field .form-control:focus {
  border-color: #80bdff;
  box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.password-field.has-error .form-control {
  border-color: #dc3545;
  box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}

.password-field.has-success .form-control {
  border-color: #28a745;
  box-shadow: 0 0 0 0.2rem rgba(40, 167, 69, 0.25);
}

/* Animaciones para el indicador de fortaleza */
.password-strength span {
  transition: all 0.3s ease;
}

.password-strength .text-success {
  animation: fadeInGreen 0.5s ease;
}

.password-strength .text-warning {
  animation: fadeInYellow 0.5s ease;
}

.password-strength .text-danger {
  animation: fadeInRed 0.5s ease;
}

/* Animación para la barra de progreso */
.password-strength-progress {
  animation: slideIn 0.5s ease;
}

@keyframes slideIn {
  from {
    width: 0%;
    opacity: 0.7;
  }
  to {
    opacity: 1;
  }
}

/* Responsive para pantallas pequeñas */
@media (max-width: 768px) {
  .password-strength-container {
    flex-direction: column;
    align-items: flex-start;
  }

  .password-strength-bar {
    width: 80px;
    margin-bottom: 5px;
  }

  .password-strength-container span {
    margin-left: 0 !important;
  }
}

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

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

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

.text-change {
  text-transform: none !important;
  text-align: justify !important;
  font-size: 12px !important;
  letter-spacing: 2px !important;
  font-weight: normal !important;
}