Cohomological boundedness for flat bundles on surfaces and applications