Skip to main content
JD Media
Back to glossaryWeb Development

CSS

Stylesheet language for styling web pages and emails, separated from the content markup in HTML.

Also known as: Cascading Style Sheets, Style Sheets

CSS, Cascading Style Sheets, is the language for visually styling web pages and HTML based emails. It separates content structured in HTML from its presentation. Through selectors and rules CSS sets colours, fonts, spacing, layouts, animations and responsive behaviour. Modern layout modules such as Flexbox and Grid enable complex arrangements with little code.

How CSS works in websites

CSS rules are evaluated by the browser according to a clearly defined cascade principle. Specificity, load order and context decide which rule ultimately applies. External stylesheets, internal style blocks and inline styles can be combined, with external files being best for performance and maintenance. Tools such as Tailwind CSS or PostCSS extend the workflow with utility classes and build steps.

What is different in email HTML

Email clients support CSS far less completely and consistently. Many clients ignore external stylesheets, which is why inline styles are mandatory in the final email. Modern features such as Grid or custom properties are not available in many mail clients. Test obligation is therefore high, and templates are designed rather conservatively, often using table layouts instead of modern layout logic.

Reference to JD Mail

JD Mail uses an inline CSS setup for its newsletter templates that renders reliably in the major mail clients. Custom templates can be designed but should be checked in advance on the most important clients so the intended layout appears there too. Anyone producing custom HTML newsletters benefits from a slim, well tested template set as a base and avoids unnecessary complexity.