Revert "adjust margin and padding in gallery"

This reverts commit 7e140bbf9de7a0b1b3e75d5819f0af57bbfcdba9.