-
Notifications
You must be signed in to change notification settings - Fork 0
/
style.css
102 lines (82 loc) · 1.63 KB
/
style.css
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
html{
box-sizing: border-box;
}
*, *:before *:after{
margin: 0;
padding: 0;
box-sizing: border-box;
}
body{
/* border: 2px solid red; */
font-family: 'Instrument Sans', 'Pangolin';
background: #d1dedd;
margin: 2rem;
}
ul, li{
list-style: none;
}
h1, h2, h3{
color: #767f7e;
}
p{
color: #828b8a;
}
header{
/* border: 2px solid green; */
max-width: 1200px;
margin: 0 auto;
border-bottom: 1px solid #bbc7c7;
}
.grid-container{
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 3rem;
max-width: 1200px;
margin: 2rem auto;
}
.featured img, article img{
width: 100%;
/* each image will take 100% of the assigned column */
border: 4px solid whitesmoke;
border-radius: 8px;
}
.article-image img{
/* border: none; */
height: 250px;
}
article.featured{
text-align: justify;
grid-column: span 3;
/* child itself can be a grid */
/* nested grid */
display: grid;
grid-template-columns: 1fr 1fr;
gap: 4rem;
align-items: center;
border-bottom: 1px solid #bbc7c7;
padding-bottom: 3rem;
}
article h3, article p{
margin: 1.6rem 0.8rem;
}
/* Responsive */
@media(max-width: 945px){
.featured img{
height: 300px;
}
.article-image{
grid-column: span 3;
display: grid;
grid-template-columns: 1fr 1fr;
gap: 4rem;
align-items: center;
}
}
@media(max-width: 760px) {
article.featured, .article-image{
display: block;
}
.article-image{
margin: 0 2rem;
}
}