It's mostly down to the rider. Wout Van Aert was annihilating people's road bike records on a city rental bike - a hugely heavy dutch style:
https://road.cc/content/news/wout-va...ionship-301061
But in terms of the bike itself, you can get flat bar road bikes that will be pretty much as fast as the drop bar equivalent.
I suspect it felt fast because there's a remote chance the bike was about the right size for you for a change and it was in good condition.