You are overthinking in my opinion. If you max the Roth, HSA, and 401k both years and manage to save some in taxable invest you are doing great.
It's not going to matter that much what the order is, theoretically I guess it may be better to put investments to work right away versus holding them in savings until next Jan, but again you are doing good either way.