"Ariana ain't the only one that do it grande
Knew I'd be his fiancé when he was broke on Causeway, yuuuh"
Submit URL here: https://forms.gle/DmTgMUiGPUURWPmD7
This Friday Jan. 28th 6:00pm ET
Text
It is best practice to put CSS in it's own file and link to it from the <head> !
<link rel="stylesheet" href="css/style.css">
p{
color: red;
font-weight: bold;
}
p{
color: red;
font-weight: bold;
}
p{
color: red;
font-weight: bold;
}
p{
color: blue;
}
What comes below, can override what came above
h1{
color: red;
}
h2{
color: #FF0000;
}
p{
color: rgba(255,0,0,1);
}
span{
color: hsla(0, 100%, 50%,1);
}
<head>
<link href="https://fonts.googleapis.com/css2?family=Source+Sans+Pro:wght@300;
400;700&display=swap" rel="stylesheet">
</head>
p{
font-family: 'Source Sans Pro', 'Helvetica' sans-serif;
}
html
css
<head>
<link href="https://fonts.googleapis.com/css2?family=Source+Sans+Pro:wght@300;
400;700&display=swap" rel="stylesheet">
</head>
p{
font-family: 'Source Sans Pro', 'Helvetica' sans-serif;
font-weight: 700;
}
html
css
https://lmgtfy.com/?q=italicize+text+html+mdn&s=d
section > p {
color: red;
}
<section>
<p>Hello, Twitch!</p>
</section>
section p {
color: red;
}
<section>
<article>
<p>Hello, Twitch!</p>
</article>
</section>
p + p {
color: red;
}
<section>
<p>Hello, Twitch!</p>
<p>Hello, Youtube!</p>
</section>
#zebra {
color: red;
}
Only one id with the same value per document
<section>
<p>Hello, Twitch!</p>
<p id="zebra">Hello, Youtube!</p>
</section>
.bob {
color: red;
}
Multiple with same value allowed per document
<section>
<p class="robot">Hello, Twitch!</p>
<p id="zebra" class="bob">Hello, Youtube!</p>
<p class="bob">Goodbye, Mixer!</p>
</section>
p.robot.unicorn {
color: red;
}
<section>
<p class="robot unicorn">Hello, Twitch!</p>
<p id="zebra" class="bob">Hello, Youtube!</p>
<p class="bob">Goodbye, Mixer!</p>
</section>
#dietCoke .dominosPizza {
color: red;
}
<section id="dietCoke">
<p class="robot unicorn">Hello, Twitch!</p>
<p id="zebra" class="bob dominosPizza">Hello, Youtube!</p>
<p class="bob">Goodbye, Mixer!</p>
</section>
.bob {
color: red !important;
}
<section id="dietCoke">
<p class="robot unicorn">Hello, Twitch!</p>
<p id="zebra" class="bob dominosPizza">Hello, Youtube!</p>
<p class="bob">Goodbye, Mixer!</p>
</section>
not that kind...
By css-tricks
To Complete The Three Layouts
Read: https://learn.shayhowe.com/advanced-html-css/responsive-web-design/