Added support for both top and bottom platforms