changed $element to $select for clarity and added some styles
merge fix