Code refactoring and optimization:
- Modularization of functions.
- Use of CSS class to highlight unread links.
- Improved handling of DOM elements with the 'DOMContentLoaded' event.
- Combination of style selectors for better performance and maintainability.