Complete the code to nest the color property inside the p selector.
p {
[1]: blue;
}margin or background.The color property sets the text color inside the p selector.
Complete the code to nest the :hover pseudo-class inside the a selector.
a {
color: blue;
[1] {
color: red;
}
}:active or :visited which have different effects.The :hover pseudo-class changes the link color when the mouse is over it.
Fix the error in nesting the span selector inside the div selector.
div {
background: gray;
[1] {
color: white;
}
}span which changes it to class or id selector.To nest the span selector inside div, just write span without extra symbols.
Fill both blanks to nest the h1 selector and its :after pseudo-element inside the header selector.
header {
[1] {
font-size: 2rem;
[2] {
content: ' - Welcome';
}
}
}:before instead of :after for the pseudo-element.footer instead of h1.The h1 selector is nested inside header, and its :after pseudo-element adds content after the heading.
Fill all three blanks to nest the nav selector, its ul child, and the :hover pseudo-class for li inside nav.
nav {
[1] {
list-style: none;
[2] {
padding: 0.5rem;
[3] {
background-color: lightgray;
}
}
}
}a instead of li or ul in nesting.:active or other pseudo-classes instead of :hover.The ul is nested inside nav, then li inside ul, and :hover pseudo-class inside li to style on mouse hover.