Sometimes, if you have money in an FSA, you can spend it after being terminated (I think). So it is important to know when the FSA really ended. For example, if you are simply not allowed to make a claim after termination, that's when it ended. If you are allowed to make a claim after termination until the money is used up, then it ended when the money was used up.
As long as you are covered by an HDHP on December 1, 2024, and have no other coverage that disqualifies you, AND you plan on keeping your HDHP coverage for all of 2025, you can use the last month rule to contribute up to $4150 for 2024 (for single HDHP) or $8300 (for family HDHP) plus an additional $1000 catch-up contribution if you are age 55 or older. You can make contributions out of pocket directly to the HSA bank, and take a tax deduction for them on your tax return. You can make contributions that are retroactive for 2024 as late as April 15, 2025, but you need to make sure they are recorded properly by the HSA bank and not recorded as 2025 contributions.