This clinical trial is designed to observe the effect of dexmedetomidine nasal spray on the incidence of postoperative delirium in elderly patients undergoing thoracoscopic lung resection. Eligible elderly patients scheduled for thoracoscopic lung resection will be randomly divided into two groups: the dexmedetomidine group will receive dexmedetomidine hydrochloride nasal spray, while the placebo group will be administered an equivalent volume of placebo nasal spray. The primary outcome is the incidence of postoperative delirium within 3 days after surgery. Secondary outcomes include the severity and duration of delirium, as well as postoperative pain, subjective sleep quality, and the incidence of adverse events, which will be compared between the two groups to evaluate the safety and efficacy of dexmedetomidine nasal spray.