India beat Bangladesh by three wickets to win their seventh Asia Cup title in a pulsating last-ball finish.