-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcourse.css
213 lines (192 loc) · 4.51 KB
/
course.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
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
@font-face {
font-family: "Outfit";
src: url("https://fonts.google.com/specimen/Outfit");
/* Weights: 300, 400, 600 */
}
:root {
/* Width layout */
--width-mobile: 375px;
--desktop: 1440px;
/* Colors */
--primary-Soft-blue: hsl(215, 51%, 70%);
--primary-Cyan: hsl(178, 100%, 50%);
--main-Very-dark-blue: hsl(217, 54%, 11%);
--card-Very-dark-blue: hsl(216, 50%, 16%);
--line-Very-dark-blue: hsl(215, 32%, 27%);
--neutral-White: hsl(0, 0%, 100%);
/* Font */
--Font-paragraph-size: 18px;
}
/* * {
margin: 0;
padding: 0;
box-sizing: border-box;
color: white;
} */
body {
background-color: var(--main-Very-dark-blue);
font-family: "Outfit", Arial, Helvetica, sans-serif;
line-height: 1.6;
}
@import url("https://pro.fontawesome.com/releases/v6.0.0-beta1/css/all.css");
.ol-cards,
.ol-cards * {
margin: 0;
padding: 0;
box-sizing: border-box;
}
.ol-cards {
--flapWidth: 2rem;
--flapHeigth: 1rem;
--iconSize: 3rem;
--numberSize: 3rem;
--colGapSize: 2rem;
width: min(100%, 40rem);
margin-inline: auto;
display: grid;
gap: 2rem;
padding-inline-start: var(--flapWidth);
font-family: sans-serif;
color: #222;
counter-reset: ol-cards-count;
list-style: none;
}
.ol-cards > li > a{
display: grid;
grid-template-areas:
"icon title nr"
"icon descr nr";
gap: 0 var(--colGapSize);
align-items: center;
padding: var(--colGapSize) var(--flapWidth) var(--colGapSize) 0;
border-radius: 1rem 5rem 5rem 1rem;
background-image: linear-gradient(to bottom right, #e9eaec, #ffffff);
counter-increment: ol-cards-count;
filter: drop-shadow(10px 10px 10px rgba(0, 0, 0, 0.25));
box-shadow: inset 2px 2px 2px white, inset -1px -1px 1px rgba(0, 0, 0, 0.25);
cursor: pointer;
transition: all .2s ease-in-out;
}
.ol-cards > li :hover{
transform: scale(1.04);
}
.ol-cards > li > a > .icon {
grid-area: icon;
background: var(--accent-color);
color: white;
font-size: var(--iconSize);
width: calc(2 * var(--flapWidth) + var(--iconSize));
padding-block: 1rem;
border-radius: 0 5rem 5rem 0;
margin-inline-start: calc(-1 * var(--flapWidth));
box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.25);
position: relative;
display: grid;
place-items: center;
}
.ol-cards > li > a > .icon::before {
content: "";
position: absolute;
width: var(--flapWidth);
height: calc(100% + calc(var(--flapHeigth) * 2));
left: 0;
top: calc(var(--flapHeigth) * -1);
clip-path: polygon(
0 var(--flapHeigth),
100% 0,
100% 100%,
0 calc(100% - var(--flapHeigth))
);
background-color: var(--accent-color);
background-image: linear-gradient(
90deg,
rgba(0, 0, 0, 0.5),
rgba(0, 0, 0, 0.2)
);
z-index: -1;
}
.ol-cards > li > a > .title {
grid-area: title;
font-weight: 600;
font-size: 1.25rem;
color: #222;
}
.ol-cards > li > a > div > .descr {
grid-area: descr;
color: #222;
text-transform: none;
font-size: 16px;
}
.ol-cards > li > a::after {
grid-area: nr;
content: counter(ol-cards-count, decimal-leading-zero);
color: var(--accent-color);
font-size: var(--numberSize);
font-weight: 700;
}
@media (max-width: 40rem) {
.ol-cards {
--flapWidth: 1rem;
--flapHeigth: 0.5rem;
--iconSize: 2rem;
--numberSize: 2rem;
--colGapSize: 1rem;
}
}
/* for demo */
/* body {
background-color: #c6c9ce;
padding: 2rem;
} */
/* h1 {
text-transform: uppercase;
font-family: sans-serif;
text-align: center;
color: #222;
} */
.card-container {
width: 60%;
}
.image-main {
width: 100%;
height: 250px;
}
/* The Modal (background) */
.modal {
display: none; /* Hidden by default */
position: fixed; /* Stay in place */
z-index: 10; /* Sit on top */
left: 0;
top: 0;
width: 100%; /* Full width */
height: 100%; /* Full height */
overflow: auto; /* Enable scroll if needed */
background-color: rgb(0,0,0); /* Fallback color */
background-color: rgba(0,0,0,0.4); /* Black w/ opacity */
}
/* Modal Content/Box */
.modal-content {
background-color: #fefefe;
margin: 15% auto; /* 15% from the top and centered */
padding: 20px;
border: 1px solid #888;
width: 80%; /* Could be more or less, depending on screen size */
}
/* The Close Button */
.close {
color: #aaa;
float: right;
font-size: 28px;
font-weight: bold;
}
.close:hover,
.close:focus {
color: black;
text-decoration: none;
cursor: pointer;
}
.previous {
color: white;
font-size: 20px;
text-transform: none;
}