Fixed: Scope visibility for functions and variables