Skip to content

Commit 201fd29

Browse files
authored
feat: adds John's css implementation (#558)
* feat: add body, header, & hero CSS elements to the lesson 22 homework. * chore: touch up .hero-title class & and just added program classes. * chore: add box-shadow to .hero-text & adjust .programs padding. * chore: Touch up the header. * chore: add media queries for responsiveness. * chore: adjust media queries for better responsiveness and added footer.
1 parent c36112b commit 201fd29

File tree

4 files changed

+344
-0
lines changed

4 files changed

+344
-0
lines changed

lesson_22/JBey-CD-Clone/hero.jpg

329 KB
Loading

lesson_22/JBey-CD-Clone/index.html

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
<html>
2+
<head>
3+
<title>Homepage</title>
4+
<meta name="viewport" content="width=device-width, initial-scale=1" />
5+
<link rel="stylesheet" id="redux-google-fonts-salient_redux-css" href="https://fonts.googleapis.com/css?family=Poppins%3A600%2C400%7CMontserrat%3A800%2C900%2C700&amp;ver=1597678827" type="text/css" media="all">
6+
<link rel='stylesheet' href='https://fonts.googleapis.com/css?family=Poppins%3A600%2C400%7CMontserrat%3A800%2C900%2C700&#038;ver=1597678827' type='text/css' media='all' />
7+
<link rel="stylesheet" type="text/css" href="style.css">
8+
</head>
9+
<body>
10+
<header class="header">
11+
<div class="header-logo">
12+
<a href="index.html">
13+
<img src="logo.png" alt="Code Differently Logo" />
14+
</a>
15+
</div>
16+
<ul class="header-top-menu">
17+
<li><a href="#">Home</a></li>
18+
<li><a href="#">About</a></li>
19+
<li><a href="#">Contact</a></li>
20+
</ul>
21+
<div class="header-cta">
22+
<a class="sign-up-button" href="#">Sign Up</a>
23+
</div>
24+
</header>
25+
<div class="main">
26+
<div class="content">
27+
<article>
28+
<section class="hero-section">
29+
<div class="hero-overlay"></div>
30+
<div class="hero-content">
31+
<h2 class="hero-title">Together we can move the needle of <em class="highlight">diversity in tech.</em></h2>
32+
<div class="hero-text"><span>Code Differently</span> provides hands on training and education through coding classes that gives participants the technical and cognitive skills they need to excel in technology-driven workplaces.</div>
33+
</div>
34+
</section>
35+
<section class="programs-section">
36+
<h2>Our <em class="highlight">Programs</em></h2>
37+
<ul class="programs">
38+
<li class="program">
39+
<h3>1000 Kids Coding</h3>
40+
<p>The Code Differently 1000 Kids Coding program was created to expose New Castle County students to computing and programming. The 1000 Kids Coding courses are designed for all experience levels, no experience required.</p>
41+
</li>
42+
<li class="program">
43+
<h3>Return Ready</h3>
44+
<p>The Code Differently Workforce Training Initiatives were created to help individuals underrepresented in tech reinvent their skills to align with the changing workforce market. If you are ready to start your tech journey, join our talent community today.</p>
45+
</li>
46+
<li class="program">
47+
<h3>Pipeline DevShops</h3>
48+
<p>Pipeline DevShop is a youth work-based learning program. Youth participants experience working in a real software development environment while sharpening their technology and soft skills.</p>
49+
</li>
50+
<li class="program">
51+
<h3>Platform Programs</h3>
52+
<p>Platform programs are designed for high school graduates, college students, career changers, or professionals looking to develop the technology job readiness skills for today’s workforce.</p>
53+
</li>
54+
</ul>
55+
</section>
56+
</article>
57+
</div>
58+
</div>
59+
<footer class="footer">
60+
&copy; 2024 Code Differently
61+
</footer>
62+
</body>
63+
</html>

lesson_22/JBey-CD-Clone/logo.png

29.2 KB
Loading

lesson_22/JBey-CD-Clone/style.css

Lines changed: 281 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,281 @@
1+
/* The * is the universal seelctor that targets every element in the file */
2+
* {
3+
margin: 0;
4+
padding: 0;
5+
box-sizing: border-box;
6+
}
7+
8+
/* This covers the entire viewport */
9+
body {
10+
font-family: 'Poppins', sans-serif;
11+
color: #333;
12+
line-height: 1.6;
13+
overflow-x: hidden;
14+
}
15+
16+
a {
17+
text-decoration: none;
18+
color: inherit;
19+
}
20+
21+
ul {
22+
list-style: none;
23+
}
24+
25+
/* Header styles */
26+
.header {
27+
display: flex;
28+
justify-content: space-between;
29+
align-items: center;
30+
padding: 20px 5%;
31+
background-color: #fff;
32+
position: sticky;
33+
top: 0;
34+
z-index: 100;
35+
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
36+
padding: 20px;
37+
}
38+
39+
.header-logo img {
40+
height: 60px;
41+
width: auto;
42+
}
43+
44+
.header-top-menu {
45+
display: flex;
46+
padding-right: 2%;
47+
justify-content: space-between;
48+
width: 20%;
49+
margin-left: auto;
50+
}
51+
52+
.header-top-menu li a {
53+
font-family: 'Montserrat', sans-serif;
54+
font-weight: 600;
55+
font-size: 16px;
56+
color: #333;
57+
transition: color 0.3s ease;
58+
}
59+
60+
.header-top-menu li a {
61+
position: relative;
62+
display: inline-block;
63+
text-decoration: none; /* Remove default underline */
64+
}
65+
66+
.header-top-menu li a::after {
67+
content: '';
68+
position: absolute;
69+
bottom: -4px;
70+
left: 0;
71+
width: 0%;
72+
height: 2px;
73+
background-color: #f47d26;
74+
transition: width 0.2s ease-in-out;
75+
}
76+
77+
.header-top-menu li a:hover::after {
78+
width: 100%;
79+
}
80+
81+
.header-cta .sign-up-button {
82+
background-color: #f47d26;
83+
color: white;
84+
padding: 7px 7px;
85+
border-radius: 5px;
86+
font-family: 'Montserrat', sans-serif;
87+
font-weight: 700;
88+
font-size: 15px;
89+
text-transform: uppercase;
90+
letter-spacing: 1px;
91+
transition: background-color 0.3s ease;
92+
}
93+
94+
.header-cta .sign-up-button:hover {
95+
background-color: #f47d26;
96+
}
97+
98+
/* Hero section */
99+
.hero-section {
100+
color: white;
101+
position: relative;
102+
display: flex;
103+
background-image: linear-gradient(rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.3)),
104+
url("hero.jpg");
105+
background-size: cover;
106+
background-attachment: fixed;
107+
background-position: center;
108+
height: 100%;
109+
align-items: center;
110+
text-align: center;
111+
min-width: 30%;
112+
background-position-y: 50px;
113+
padding-top: 80px;
114+
}
115+
116+
.hero-content {
117+
text-align: left;
118+
padding-right: 400px;
119+
120+
}
121+
122+
/* This targets "together we can move the needle" */
123+
.hero-title {
124+
font-family: 'montserrat', sans-serif;
125+
font-size: 45px;
126+
line-height: 1.2em;
127+
margin-bottom: 20px;
128+
margin-top: -200px;
129+
font-weight: 800;
130+
}
131+
132+
/* This targets "provides hands on training" */
133+
.hero-text {
134+
background-color: #243e90;
135+
padding: 30px;
136+
padding-left: 140px;
137+
box-shadow: 45px 0 0 #243e90;
138+
margin-right: 145px;
139+
font-size: 17px;
140+
font-weight: 400;
141+
line-height: 20px;
142+
-webkit-font-smoothing: antialiased;
143+
font-family: 'poppins', sans-serif;
144+
145+
}
146+
147+
/* This targets diversity in tech */
148+
.hero-section h2 .highlight {
149+
font-family: 'montserrat', sans-serif;
150+
font-style: normal;
151+
text-decoration: underline;
152+
text-decoration-color: #f47d26;
153+
text-decoration-thickness: 10px;
154+
text-underline-offset: -4px;
155+
text-decoration-skip-ink: none;
156+
font-weight: 800;
157+
}
158+
159+
.hero-text span {
160+
color: #f47d26;
161+
font-weight: bold;
162+
}
163+
164+
/* It's time for the program classes. */
165+
166+
/* This creates a grid layout for the program classes */
167+
.programs {
168+
display: grid;
169+
grid-template-columns: 1fr 1fr;
170+
gap: 35px;
171+
-webkit-font-smoothing: antialiased;
172+
color: #676767;
173+
font-size: 15px;
174+
175+
}
176+
177+
.programs-section {
178+
padding: 200px;
179+
padding-top: 130px;
180+
}
181+
182+
/* This targets our programs */
183+
.programs-section h2 .highlight {
184+
font-family: 'montserrat';
185+
font-style: normal;
186+
text-decoration: underline;
187+
text-decoration-color: #f47d26;
188+
text-decoration-thickness: 10px;
189+
text-underline-offset: -4px;
190+
text-decoration-skip-ink: none;
191+
192+
}
193+
194+
.programs-section h2 {
195+
font-family: 'montserrat';
196+
font-weight: 900;
197+
padding-bottom: 45px;
198+
display: inline-block;
199+
font-size: 30px;
200+
color: #444;
201+
font-size: 28px;
202+
-webkit-font-smoothing: antialiased;
203+
letter-spacing: 0;
204+
font-style: normal;
205+
}
206+
207+
.programs li h3 {
208+
margin-bottom: 20px;
209+
font-family: 'montserrat';
210+
font-weight: 700;
211+
color: #444;
212+
}
213+
214+
.footer {
215+
border-top: 2px solid #9a41029d;
216+
text-align: center;
217+
background: #fff;
218+
padding: 5.5%;
219+
font-size: 13px;
220+
}
221+
222+
/* Media queries for responsiveness */
223+
@media screen and (min-width: 357px) and (max-width: 999px) {
224+
.header-top-menu {
225+
226+
align-items: center;
227+
flex-direction: column;
228+
gap: 8px;
229+
}
230+
231+
.header-cta .sign-up-button {
232+
233+
padding: 8px 15px;
234+
}
235+
236+
.header-logo img {
237+
height: 50px;
238+
}
239+
240+
.hero-section {
241+
padding: 80px 50px;
242+
text-align: center;
243+
background-position: 90% 100%;
244+
height: 55vh;
245+
}
246+
247+
.hero-content {
248+
padding-right: 0;
249+
}
250+
251+
.hero-title {
252+
font-size: 30px;
253+
margin-top: 40px;
254+
}
255+
256+
.hero-text {
257+
font-size: 20px;
258+
font-family: 'Poppins', sans-serif;
259+
color: white;
260+
margin: 0;
261+
padding: 30px 45px;
262+
width: 100vw;
263+
position: relative;
264+
left: 50%;
265+
right: 50%;
266+
margin-left: -50vw;
267+
}
268+
269+
.programs {
270+
grid-template-columns: 1fr;
271+
gap: 20px;
272+
}
273+
274+
.programs-section {
275+
padding: 100px 20px;
276+
}
277+
278+
.programs-section h2 {
279+
font-size: 24px;
280+
}
281+
}

0 commit comments

Comments
 (0)