@@ -7,32 +7,38 @@ Dark green: #28b485
7
7
8
8
*/
9
9
10
- * {
10
+ * ,
11
+ * ::before ,
12
+ * ::after {
11
13
margin : 0 ;
12
14
padding : 0 ;
13
- box-sizing : border-box;
15
+ box-sizing : inherit;
16
+ }
17
+ html {
18
+ /*font-size: 10px; /* root pixel size, rem reference (1 rem)*/
19
+ font-size : 62.5% ;
14
20
}
15
-
16
21
body {
17
22
font-family : "Lato" , sans-serif;
18
23
font-weight : 400 ;
19
- font-size : 16px ;
24
+ /* font-size: 16px; */
20
25
line-height : 1.7 ;
21
26
color : # 777 ;
22
- padding : 10px ;
27
+ padding : 1rem ;
28
+ box-sizing : border-box;
23
29
}
24
30
25
- .logo -box {
31
+ .header__logo -box {
26
32
position : absolute;
27
- top : 40 px ;
28
- left : 40 px ;
33
+ top : 4 rem ;
34
+ left : 4 rem ;
29
35
}
30
36
31
- .logo {
32
- height : 35 px ;
37
+ .header__logo {
38
+ height : 3.5 rem ;
33
39
}
34
40
35
- .text -box {
41
+ .header__text -box {
36
42
position : absolute;
37
43
top : 40% ;
38
44
left : 50% ;
@@ -54,35 +60,35 @@ body {
54
60
color : # FFF ;
55
61
text-transform : uppercase;
56
62
backface-visibility : hidden; /* hide the background so that when children animates, it doesn't interfere */
57
- margin-bottom : 60 px ;
63
+ margin-bottom : 6 rem ;
58
64
}
59
65
60
- .heading-primary-main {
66
+ .heading-primary-- main {
61
67
display : block;
62
- font-size : 60 px ;
68
+ font-size : 6 rem ;
63
69
font-weight : 400 ;
64
- letter-spacing : 35 px ;
70
+ letter-spacing : 3.5 rem ;
65
71
animation-name : moveInLeft;
66
72
animation-duration : 1s ;
67
73
animation-timing-function : ease-out;
68
74
/* animation-iteration-count: 3; */
69
75
}
70
76
71
- .heading-primary-sub {
77
+ .heading-primary-- sub {
72
78
display : block;
73
- font-size : 20 px ;
79
+ font-size : 2 rem ;
74
80
font-weight : 700 ;
75
- letter-spacing : 17.4 px ;
81
+ letter-spacing : 1.75 rem ;
76
82
animation : moveInRight 1s ease-out;
77
83
}
78
84
79
85
@keyframes moveInLeft {
80
86
0% {
81
87
opacity : 0 ;
82
- transform : translateX (-100 px );
88
+ transform : translateX (-10 rem );
83
89
}
84
90
80% {
85
- transform : translateX (10 px );
91
+ transform : translateX (1 rem );
86
92
}
87
93
100% {
88
94
opacity : 1 ;
@@ -93,10 +99,10 @@ body {
93
99
@keyframes moveInRight {
94
100
0% {
95
101
opacity : 0 ;
96
- transform : translateX (100 px );
102
+ transform : translateX (10 rem );
97
103
}
98
104
80% {
99
- transform : translateX (-10 px );
105
+ transform : translateX (-1 rem );
100
106
}
101
107
100% {
102
108
opacity : 1 ;
@@ -107,7 +113,7 @@ body {
107
113
@keyframes moveInBottom {
108
114
0% {
109
115
opacity : 0 ;
110
- transform : translateY (30 px );
116
+ transform : translateY (3 rem );
111
117
}
112
118
100% {
113
119
opacity : 1 ;
@@ -118,25 +124,26 @@ body {
118
124
.btn : link , .btn : visited {
119
125
text-transform : uppercase;
120
126
text-decoration : none;
121
- padding : 15 px 40 px ;
127
+ padding : 1.5 rem 4 rem ;
122
128
display : inline-block;
123
- border-radius : 100 px ;
129
+ border-radius : 10 rem ;
124
130
transition : all .2s ;
125
131
position : relative;
132
+ font-size : 1.6rem ;
126
133
}
127
134
128
135
.btn : hover {
129
136
transform : translateY (-3px );
130
137
/* box-shadow: x-dir y-dir blur color */
131
- box-shadow : 0 10 px 20 px rgba (0 , 0 , 0 , .2 );
138
+ box-shadow : 0 1 rem 2 rem rgba (0 , 0 , 0 , .2 );
132
139
}
133
140
134
141
.btn : active { /* clicked state */
135
142
transform : translateY (-1px ); /* minus 1 to initial state not to hover */
136
- box-shadow : 0 5 px 10 px rgba (0 , 0 , 0 , .2 );
143
+ box-shadow : 0 .5 rem 1 rem rgba (0 , 0 , 0 , .2 );
137
144
}
138
145
139
- .btn-white {
146
+ .btn-- white {
140
147
background-color : # fff ;
141
148
color : # 777 ;
142
149
}
@@ -154,7 +161,7 @@ body {
154
161
transition : all .4s ;
155
162
}
156
163
157
- .btn-white ::after {
164
+ .btn-- white ::after {
158
165
background-color : # fff ;
159
166
}
160
167
@@ -163,7 +170,7 @@ body {
163
170
opacity : 0 ;
164
171
}
165
172
166
- .btn-animated {
173
+ .btn-- animated {
167
174
animation : moveInBottom .5s ease-out .75s ;
168
175
animation-fill-mode : backwards; /* apply all initial 0% state of the animation before the animation starts */
169
176
}
0 commit comments