Skip to content

Commit 3a9179f

Browse files
authored
Merge pull request #2 from marcuma/03-css-fundementals
03 css fundementals
2 parents 5b7d8a0 + 8edcadb commit 3a9179f

File tree

2 files changed

+124
-17
lines changed

2 files changed

+124
-17
lines changed
Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
h1,
2+
h2,
3+
h3,
4+
h4,
5+
p,
6+
li {
7+
font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
8+
color: #444;
9+
}
10+
11+
h1,
12+
h2,
13+
h3 {
14+
color: #1098ad;
15+
}
16+
17+
h1 {
18+
font-size: 26px;
19+
text-transform: uppercase;
20+
font-style: italic;
21+
}
22+
23+
h2 {
24+
font-size: 40px;
25+
}
26+
27+
h3 {
28+
font-size: 30px;
29+
}
30+
31+
h4 {
32+
font-size: 20px;
33+
text-transform: uppercase;
34+
text-align: center;
35+
}
36+
37+
p {
38+
font-size: 22px;
39+
line-height: 1.5;
40+
}
41+
42+
li {
43+
font-size: 20px;
44+
}
45+
46+
/* footer p {
47+
font-size: 16px;
48+
text-align: center;
49+
} */
50+
51+
#copyright {
52+
font-size: 16px;
53+
text-align: center;
54+
}
55+
56+
#author {
57+
font-style: italic;
58+
font-size: 18px;
59+
}
60+
61+
.related-author {
62+
font-style: italic;
63+
font-weight: bold;
64+
font-family: "Franklin Gothic Medium", "Arial Narrow", Arial, sans-serif;
65+
font-size: 18px;
66+
}
67+
68+
.related {
69+
list-style: none;
70+
}
71+
72+
.main-header {
73+
background-color: #f7f7f7;
74+
}
75+
76+
aside {
77+
background-color: #f7f7f7;
78+
border-top: 5px solid #1098ad;
79+
border-bottom: 5px solid #1098ad;
80+
}
81+
82+
.border {
83+
border-bottom: 5px solid #3a3b3b;
84+
}
85+
86+
li:first-child {
87+
font-weight: bold;
88+
}
89+
90+
li:last-child {
91+
font-style: italic;
92+
}
93+
94+
li:nth-child(even) {
95+
/* color: red; */
96+
}
97+
98+
/* Style Hyperlinks */
99+
a:link {
100+
color: #1098ad;
101+
text-decoration: none;
102+
}
103+
104+
a:visited {
105+
color: #1098ad;
106+
}
107+
108+
a:hover {
109+
color: orangered;
110+
font-weight: bold;
111+
}

starter/03-CSS-Fundamentals/index.html

Lines changed: 13 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,12 @@
22
<html lang="en">
33
<head>
44
<meta charset="UTF-8" />
5+
<link rel="stylesheet" href="css/style.css" />
56
<title>The Basic Language of the Web: HTML</title>
67
</head>
78

89
<body>
9-
<!--
10-
<h1>The Basic Language of the Web: HTML</h1>
11-
<h2>The Basic Language of the Web: HTML</h2>
12-
<h3>The Basic Language of the Web: HTML</h3>
13-
<h4>The Basic Language of the Web: HTML</h4>
14-
<h5>The Basic Language of the Web: HTML</h5>
15-
<h6>The Basic Language of the Web: HTML</h6>
16-
-->
17-
18-
<header>
10+
<header class="main-header">
1911
<h1>📘 The Code Magazine</h1>
2012

2113
<nav>
@@ -28,7 +20,7 @@ <h1>📘 The Code Magazine</h1>
2820

2921
<article>
3022
<header>
31-
<h2>The Basic Language of the Web: HTML</h2>
23+
<h2 class="border">The Basic Language of the Web: HTML</h2>
3224

3325
<img
3426
src="img/laura-jones.jpg"
@@ -37,7 +29,9 @@ <h2>The Basic Language of the Web: HTML</h2>
3729
width="50"
3830
/>
3931

40-
<p>Posted by <strong>Laura Jones</strong> on Monday, June 21st 2027</p>
32+
<p id="author">
33+
Posted by <strong>Laura Jones</strong> on Monday, June 21st 2027
34+
</p>
4135

4236
<img
4337
src="img/post-img.jpg"
@@ -112,7 +106,7 @@ <h3>Why should you learn HTML?</h3>
112106
<aside>
113107
<h4>Related posts</h4>
114108

115-
<ul>
109+
<ul class="related">
116110
<li>
117111
<img
118112
src="img/related-1.jpg"
@@ -121,12 +115,12 @@ <h4>Related posts</h4>
121115
width="75"
122116
/>
123117
<a href="#">How to Learn Web Development</a>
124-
<p>By Jonas Schmedtmann</p>
118+
<p class="related-author">By Jonas Schmedtmann</p>
125119
</li>
126120
<li>
127121
<img src="img/related-2.jpg" alt="Lightning" width="75" heigth="75" />
128122
<a href="#">The Unknown Powers of CSS</a>
129-
<p>By Jim Dillon</p>
123+
<p class="related-author">By Jim Dillon</p>
130124
</li>
131125
<li>
132126
<img
@@ -136,11 +130,13 @@ <h4>Related posts</h4>
136130
height="75"
137131
/>
138132
<a href="#">Why JavaScript is Awesome</a>
139-
<p>By Matilda</p>
133+
<p class="related-author">By Matilda</p>
140134
</li>
141135
</ul>
142136
</aside>
143137

144-
<footer>Copyright &copy; 2027 by The Code Magazine.</footer>
138+
<footer>
139+
<p id="copyright">Copyright &copy; 2027 by The Code Magazine.</p>
140+
</footer>
145141
</body>
146142
</html>

0 commit comments

Comments
 (0)