2022 taxes: IRS stated mistakes were made on Federal filings, but state said everything was 100% correct.

In August 2024, I received a letter from the IRS stating that a mistsake was made on my tax year 2022 filing and that instead of getting a $1000+ refund, I owed the IRS $378 which included penalties because of the time from my filing until the time they mailed the notice. At the same time, I received a note from my state giving me  a tax refund. That paperwork also stated that my taxes were 100% correct.  Given that the state also uses the federal tax, how can the federal be wrong but the state be correct?

 

To not incur more penalties, I mailed the IRS a check for the $378. But I wonder how I find out what mistake was made. I used TurboTax to do both my federal and state taxes and the program stated that my taxes were "100% correct." The information that I provided to Turbotax were from the same sources (main W2 job, 2 side businesses with minimal income, 1098-T from my school [I attend part-time]) as used in tax year 2021 but no errors were found on the 2021 return which was also made and filed using TurboTax.