SQL Triggers not preventing insert
The problem with your code is that you are declaring your variable as varchar without any length. With variable declarations, varchar defaults to a length of 1 (note that in other scenarios it will have a different default length).

As a best practice, you should always specify a length on the varchar datatype. For more details, see this article on the issue.