From CHAMP macuser_22
In 2017 and before it was possible to deduct a loss of unrecorded "basis" in the Roth when ALL existing Roth accounts are closed, as a miscellaneous itemized deduction subject to a 2% or AGI floor. It would not be of any benefit if you cannot otherwise itemize.
The TCJA (Tax Cuts and Jobs Act) eliminated that deduction for tax years 2018-2025. If you anticipate that you will be able to itemize in 2025 or later, and the loss will exceed the 2% AGI floor, you can leave a small amount in the Roth and not close it until the TCJA expires and that deduction is restored. (Of course there is not guarantee that Congress will not pass some other law.)