Adverse events ( AEs ) , defined as unintended patient harm related to healthcare provided rather than an underlying medical condition , represent a significant threat to patient safety and public health .