The two are completely plausibly related. Drinking age has a direct affect on the amount of drunk driving on roads and therefore the safety of them. The main group behind the push to 21 was Mothers Against Drunk Driving.
In fact, the Supreme Court case about this was where they came up with the rule!
https://en.wikipedia.org/wiki/South_Dakota_v._Dole
The actual test is:
The spending must promote "the general welfare."
The condition must be unambiguous.
The condition should relate "to the federal interest in particular national projects or programs."
The condition imposed on the states must not, in itself, be unconstitutional.
The condition must not be coercive.
That seems to not be the case in practice. Highway funding is dependent on states setting a legal drinking age no lower than 21. Those two things are not plausibly related. And it's definitely coercive.