Refactored - extracted keyboard class