-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.css
More file actions
111 lines (92 loc) · 2.03 KB
/
index.css
File metadata and controls
111 lines (92 loc) · 2.03 KB
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
103
104
105
106
107
108
109
110
111
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@100..900&display=swap');
/* CSS RESET for this challenge*/
*, *::before, *::after {
box-sizing: border-box;
}
body, h1, p {
margin-block-end: 0;
}
body {
min-height: 100vh;
line-height: 1.2;
}
h1 {
line-height: 1.27;
text-wrap: balance;
}
img, picture {
max-width: 100%;
display: block;
}
/* CUSTOM PROPERTIES */
:root {
/* Color */
--primary-white: hsl(0, 0%, 100%);
--primary-lightGray: hsl(212, 45%, 89%);
--primary-grayishBlue: hsl(220, 15%, 55%);
--primary-darkBlue: hsl(218, 44%, 22%);
--clr-bodyBG: var(--primary-lightGray);
--clr-cardBG: var(--primary-white);
--clr-h1: var(--primary-darkBlue);
--clr-body: var(--primary-grayishBlue);
--clr-attribution: hsl(228, 45%, 44%);
/* Typography */
--ff: 'Outfit', sans-serif;
--fs-h1: 1.375rem;
--fs-body: .9375rem;
--fs-attribution: clamp(0.6875rem, 0.6223rem + 0.3261vi, 0.875rem);
--fw-400: 400;
--fw-700: 700;
}
/* Centering content for the Challenge */
body {
min-height: 100vh;
display: grid;
grid-template-rows: 1fr auto;
justify-items: center;
}
main {
align-self: center;
}
/* ---------------------------------- */
/* LAYOUT */
body {
background: var(--clr-bodyBG);
font-family: var(--ff);
}
.card {
display: flex;
flex-direction: column;
max-width: 20rem;
margin-inline: auto;
background: var(--clr-cardBG);
padding: 1em;
border-radius: 20px;
text-align: center;
}
.card img {
border-radius: 10px;
}
.card__content {
padding-inline: 1em;
}
.card h1 {
font-size: var(--fs-h1);
font-weight: var(--fw-700);
color: var(--clr-h1);
margin-block-start: 1.5rem;
}
.card p {
color: var(--clr-body);
font-size: var(--fs-body);
letter-spacing: 0.012rem;
margin-block-end: 1.5rem;
}
.attribution {
font-size: var(--fs-attribution);
text-align: center;
}
.attribution a {
color: var(--clr-attribution);
font-weight: var(--fw-700);
}