An All-Around Solution
Write the hidden element ~ its text and its CSS ~ in the DOM part of the script.
Include the alternative, alert message in the ELSE part of the script for earlier browsers.
Make the same message available in the page with noscript content.
Now, the CSS is in the script, and the noscript content is available in the page.