estimated tax and federal underpayment penalty

Hello Expert, I am retired and I paid total federal income tax about $2000 in 2022. I was not expecting any tax liability in 2023 so I did not make any estimated tax payments. However, I had a large investment income in the last few days of December 2023 because one of my stock holdings was bought out by another company resulting in capital gain (I did not plan to sell my stocks in 2023 originally). Now my tax liability for 2023 is about $10,000. I understand that normally if I paid estimated tax more than my total tax due in the prior year ($2000 in 2022), I will not be subject to penalty for the 2023 tax year. Because I did not pay any estimated tax for the first 3 quarters of 2023, my question is if I pay $3000 estimated tax for the 4th quarter prior to the Jan 16th 2024 deadline, would I avoid the penalty since I paid more than the $2000 total due of 2022? Or do I have to pay $9000 (90% of the estimated 2023 total due) by the Jan 16th deadline in order to avoid the federal underpayment tax penalty? Is there any IRS publication / guideline specific about this situation? Thank you!