Skip to content

Commit c75e617

Browse files
committed
section 3 done
1 parent 740c4ad commit c75e617

File tree

2 files changed

+61
-2
lines changed

2 files changed

+61
-2
lines changed

starter/03-CSS-Fundamentals/challange/index.html

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,9 @@
99
<body>
1010
<div class="container">
1111
<article class="product">
12-
<h2 class="product-title">Converse Chuck Taylor All Star Low Top</h2>
12+
<div class="product-title-container">
13+
<h2 class="product-title">Converse Chuck Taylor All Star Low Top</h2>
14+
</div>
1315
<img
1416
src="https://i.ibb.co/Jr7Wh1d/challenges.jpg"
1517
alt="Chuck Taylor All Star Shoe"
@@ -27,7 +29,14 @@ <h2 class="product-title">Converse Chuck Taylor All Star Low Top</h2>
2729
<a class="more-info" href="https://www.converse.com"
2830
>More information &rarr;</a
2931
>
30-
32+
<ol class="variant-list">
33+
<li></li>
34+
<li></li>
35+
<li></li>
36+
<li></li>
37+
<li></li>
38+
<li></li>
39+
</ol>
3140
<h3 class="product-details-header">Product details</h3>
3241
<ul class="product-details-list">
3342
<li>Lightweight, durable canvas sneaker</li>

starter/03-CSS-Fundamentals/challange/style.css

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,30 @@ h3 {
2828
.container {
2929
width: 800px;
3030
margin: 0 auto;
31+
padding-top: 20px;
3132
}
3233

3334
.product {
3435
border: 4px black solid;
3536
width: 100%;
3637
}
3738

39+
.product-title-container {
40+
position: relative;
41+
}
42+
43+
.product-title-container::after {
44+
content: "sale";
45+
text-transform: uppercase;
46+
background-color: red;
47+
color: white;
48+
padding: 5px 15px;
49+
position: absolute;
50+
top: -15px;
51+
left: -15px;
52+
letter-spacing: 2px;
53+
}
54+
3855
.product-title {
3956
font-size: 22px;
4057
text-transform: uppercase;
@@ -66,6 +83,39 @@ h3 {
6683
text-decoration: none;
6784
}
6885

86+
.variant-list {
87+
list-style: none;
88+
}
89+
90+
.variant-list li {
91+
display: inline-block;
92+
width: 20px;
93+
height: 20px;
94+
margin: 30px 5px;
95+
}
96+
97+
.variant-list li:first-child {
98+
background-color: black;
99+
margin-left: 2px;
100+
}
101+
102+
.variant-list li:nth-child(2) {
103+
background-color: blue;
104+
}
105+
106+
.variant-list li:nth-child(3) {
107+
background-color: red;
108+
}
109+
.variant-list li:nth-child(4) {
110+
background-color: yellow;
111+
}
112+
.variant-list li:nth-child(5) {
113+
background-color: green;
114+
}
115+
.variant-list li:nth-child(6) {
116+
background-color: brown;
117+
}
118+
69119
.product-details-header {
70120
text-transform: uppercase;
71121
}

0 commit comments

Comments
 (0)