It seems strange to be mashing two languages together in a single document. Is this common practice?
One the web it is not unusual to see two languages mashed together in this way especially if we are looking at older sites. For example, some sites similarly couple the PHP and HTML languages.
While this type of tight coupling may not be all that uncommon, it is not a great habit to get into. As developers we should strive to “separate our concerns”. In the case of CSS, this means that we will usually want to keep our CSS out of our HTML document. In other words, it is best practice to use .css files rather than defining our styles inline or within the
<style> tag. For a deeper dive into when inline styles might be advisable, take a look at this article.
In the next exercise you will learn how to create separate stylesheets!