Introduction
CSS stands for 'cascading style sheet'. CSS
is made of three words i.e. 'cascade + style + sheet'. Cascade means an order follows by the browser.
Style+sheet means a sheet that is used for styling of the tag.
CSS is used to control the formatting of the HTML tag. Generally, formatting HTML tags had some limitations, but the style sheet opens a gateway for a web designer to create design and format according to their choice. Using the style sheet one can create styles for our web page and one can put multiple styles in HTML documents. Style sheet improves various feature like
fonts, size, weight, margin, indent, paragraph, background, graphics, etc.
Types of the style sheet
There are following three types of a style sheet in
HTML.
- Inline style sheet
- Internal(Embedded) style sheet
- External(Links) style sheet
Inline style sheet
In the inline style sheet, we can apply the style in the same line. It adds a specific style to the document controlled by the tags.
Example
- <html>
- <head>
- <title>Inline style sheet</title>
- </head>
- <body bgcolor="lime">
- <h1 style="background-color:yellow"id="h1">
- <center>Inline Style Sheet</center>
- </h1>
- <p style="font-size:25pt" "font-weight:bold" id="p1">
- In the inline style sheet we can apply style in same line. It adds a specific style to the document controlled
- by the tags.
- </p>
- <p>
- <span style="font-weight:bold" id=s1>
- B.Tech<br />
- MBA<br />
- MCA<br />
- </span>
- </p>
- </body>
- </html>
Output

Internal(Embedded) style sheet
Internal style sheet is also known as embedded
style sheet because in this style sheet embeds the style inside the <style>
tags and ends with the </style> tags.



Join the conversation! Your thoughts help the community grow.