ENHANCED: Added support for non-ASCII Unicode brackets.