Naming rules:
use letters, numbers, slashes, or minus signs. Don’t start with numbers.
CSS Syntax:
/*
Selectors{
attribute:value;
attribute:value;
attribute:value;
}
*/
Comment methods in CSS: /*...*/
Inline style (inline style):
Use the style attribute in the HTML tag to set the CSS style.
<a style="color:green;"></a>
Internal Style (inline style)
<head>
<style type="text/css">
a{color:green;}
</style>
</head>
External import mode (external link-in)
Use the <link/>
tag in the <head>
tag to import an external CSS file to act on the HTML page, thus implementing the CSS style settings.
<head>
<link href="mystyle.css" type="text/css" rel="stylesheet"/>
</head>
pay attention:
The precedence of three CSS styles: