THEME: Enhancing Thematic Investing with Semantic Stock Representations and Temporal Dynamics