CSS : (Cascading style sheet) USing css we apply styles in HTML. only CSS useful for applying syles in HTML. CSS code we always embedded in HTML. Advantage of CSS: ---------------------------- --code reusability --css saves our time --Easy to maintain the code --css javscript,vbscript ,Angular, React(Compatability) --Using CSS we apply mutiple properties(background, text, border, image) syntax Of CSS: ---------------- selector{property: value} h1{color:red} ---declaration--- OR selector{property1: value1,property2: value2,property3:value3.......} h1{color:red, size: 12px, background-color:red} h1 { color:red; background-color:yellow; } Selectors in CSS: ------------------------ selector it is one of the tag name or element for applying styles mainly 3 types of selectors 1. class selector 2. id selector 3. mutiple selector How we embedded css in html is we use one of the main tag i.e here style tag it has some ofthe attributes. that attribute is type 1. class Selectors: ------------------------- in css class selector follows with class attribute and there value. whenever we add styles in style tag, we should starts with '.' dot operator with attribute value.

Hello World

Heading tag in html

2. Id selectors: -------------------------------- in css id selector must follows one of the attribute in tag name or element name declaration--- i.e id attribute , and for adding id selector styles then it start with # symbol character.

Hello World

Heading tag in html

3. Group Selectors: --------------------------------------------------------

Welcome to CSS program

Welcome to HTML programm

Welcome to javascript program

group selector =================================================== Add all tag in single then we apply styles known as group selector

Welcome to CSS program

Welcome to HTML programm

Welcome to javascript program

CSS comments: ------------------------------------------ comments simply ignored by interpreter html, css, javscript the code which is executed by " interpreter "" c, c++ the program 'compiler' commenents are not executed by the interpreter. /* comment code */

Welcome to CSS program

Welcome to HTML programm

Welcome to javascript program

Where we include the css : -------------------------------------- if u want to include the css code in html then u follows the following ways. There are 3 ways to incllude css code in html 1. external style sheet 2. Internal style sheet(Embedded style sheet) 3. inline style sheet 1. External style sheet: --------------------------------------- With an external style sheet you can change the look of an entire website by using just one file. External style sheet we include from outside of the html programm. We save the external style sheet prrogram as with .css extension. and that should be included in html file by using one of the tag i.e first.html -----------------------------------

Welcome to CSS program

Welcome to HTML programm

Welcome to javascript program

mystyle.css: ========================== h1 { color:red; text-align:left; } h2 { color:blue; text-align: center; } p { color:yellow; text-align: right; } 2. Internal style sheet or Embedded style sheet: ------------------------------------------------------------- Internal style mean adding styles in Head section in html is known as Internal style sheet.

Welcome to CSS program

Welcome to HTML programm

Welcome to javascript program

3. Inline style sheet: ----------------------------------------- Inline style may be used to apply a unique style for a single element.

Welcome to CSS program

Welcome to HTML programm

Welcome to javascript program

CSS- Background: ------------------------------------------------------ The CSS background properties are used to define the background effects for elements. background-color background-image background-repeat background-position 1. background-color: The background-color property specified the background-color of an element. Example: body { background-color: red; }

Welcome to CSS program

Welcome to HTML programm

Welcome to javascript program

Example2: -------------- in the below example program image file repeated in y dimension similerly we change the value as repeat-x dimesnion or repeat

Welcome to CSS program

Welcome to HTML programm

Welcome to javascript program

CSS Border Properties: ------------------------------ In css the following are the border properties . They are 1. dotted 2.dashed 3. solid 4. double 5.groove.... border properties

Welcome to Border properties

Welcome to Border properties

Welcome to Border properties

Welcome to Border properties

Welcome to Border properties

Welcome to Border properties

example2: border properties

Welcome to Border properties

Welcome to Border properties

Welcome to Border properties

Welcome to Border properties

CSS Margins: ---------------------- The Css margin prooperties are used to create space around elements outside of any defined borders. margin-top margin-right margin-bottom margin-left border properties

CSS Margins: ---------------------- The Css margin prooperties are used to create space around elements outside of any defined borders. margin-top margin-right margin-bottom margin-left

CSS Padding: ------------------------------------------------ providing space around the element padding-top padding-bottom padding-left padding-right
CSS Margins:
----------------------
The Css margin prooperties are used to create
space around elements outside of any defined borders.

margin-top
margin-right
margin-bottom
margin-left
CSS Margins:
----------------------
The Css margin prooperties are used to create
space around elements outside of any defined borders.

margin-top
margin-right
margin-bottom
margin-left
CSS text properties: ---------------------------

Css Text properties

CSS Text align properties

css text color properties

CSS TExt decoration properties

CSS text transfomation properties