After you file

Did you review lines 18-23 ... the 1040X doesn't account for what was originally applied it only accounts for the original  refund.  So if you really do have a balance due and you pay it with the amended return then the original applied amount should be left alone but there are no guarantees.  Check your return/account transcripts online later to be sure.