Skip to content

Commit 9c06cdb

Browse files
style
1 parent a13b2a1 commit 9c06cdb

File tree

1 file changed

+160
-10
lines changed

1 file changed

+160
-10
lines changed

style/index.css

+160-10
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
/* Variables */
22
/*Applying colors*/
3+
body {
4+
background-color: black;
5+
}
6+
37
.scene1 {
48
background: linear-gradient(180deg, rgb(157, 221, 247) 67%, rgb(83, 154, 184) 67%);
59
}
@@ -20,6 +24,18 @@
2024
background: black;
2125
}
2226

27+
.scene6 {
28+
background: black;
29+
}
30+
31+
.scene7 {
32+
background-color: black;
33+
}
34+
35+
.scene8 {
36+
background-color: black;
37+
}
38+
2339
main div:nth-of-type(n + 3) {
2440
color: lightgrey;
2541
}
@@ -28,7 +44,7 @@ body {
2844
margin: 0;
2945
}
3046

31-
main > div {
47+
main > div:nth-of-type(-n+5) {
3248
display: grid;
3349
grid-template-columns: 1fr 1fr;
3450
grid-template-rows: 1fr 1fr;
@@ -39,20 +55,34 @@ main > div {
3955
width: 30vw;
4056
margin: 0 auto;
4157
opacity: 0;
58+
position: sticky;
59+
top: 25px;
4260
}
4361

4462
/* general layout for side plant images*/
4563
.background-plants-right {
4664
width: 9vw;
4765
float: right;
66+
opacity: 0;
67+
}
68+
69+
.plantContainer {
70+
overflow: hidden;
4871
}
4972

5073
.background-plants-left {
5174
width: 9vw;
75+
opacity: 0;
5276
}
5377

54-
/* SCENE 1 */
5578
/* Style for scene 1 and the elenent in it */
79+
.bottle {
80+
position: absolute;
81+
width: 5vw;
82+
left: 32vw;
83+
transform: translateY(4vw);
84+
}
85+
5686
.cloud {
5787
width: 50%;
5888
}
@@ -70,20 +100,140 @@ main > div {
70100
margin: 0 auto;
71101
}
72102

73-
.floatingBottleTrash {
74-
opacity: 20%;
75-
width: 50vw;
103+
.scene6 {
104+
height: 100vh;
105+
}
106+
.scene6 h3 {
107+
position: sticky;
108+
top: 50vh;
109+
margin: 7vw 0;
110+
}
111+
112+
.scene7 {
113+
height: 100vh;
114+
background-image: url("../images/healthy-earth.png");
115+
background-repeat: no-repeat;
116+
background-position: center;
117+
background-attachment: fixed;
118+
}
119+
.scene7 div {
120+
height: 100vh;
121+
}
122+
123+
.scene8 {
124+
height: 100vh;
125+
background-image: url("../images/dead-earth.png");
126+
background-repeat: no-repeat;
127+
background-position: center;
128+
background-attachment: fixed;
76129
}
77130

78131
body {
79132
font-family: sans-serif;
80133
}
81134

82-
.scene-text-conteiner {
135+
.scene-text-conteiner, p {
83136
font-size: 1.5rem;
84137
}
85138

86-
.show {
87-
transform: translateY(-20px);
88-
opacity: 1;
89-
}/*# sourceMappingURL=index.css.map */
139+
h3 {
140+
font-size: 5rem;
141+
text-align: center;
142+
}
143+
144+
@keyframes textboxInn {
145+
0% {
146+
transform: translateY(0);
147+
opacity: 0;
148+
}
149+
100% {
150+
transform: translateY(-40px);
151+
opacity: 1;
152+
}
153+
}
154+
@keyframes plantLeftInn {
155+
0% {
156+
opacity: 1;
157+
transform: rotate(13deg) translateX(-90px);
158+
}
159+
40% {
160+
opacity: 1;
161+
transform: rotate(38deg) translateX(0px);
162+
}
163+
60% {
164+
opacity: 1;
165+
transform: rotate(38deg) translateX(0px);
166+
}
167+
80% {
168+
opacity: 1;
169+
transform: rotate(38deg) translateX(0px);
170+
}
171+
100% {
172+
opacity: 1;
173+
transform: rotate(38deg) translateX(0px);
174+
}
175+
}
176+
@keyframes plantRightInn {
177+
0% {
178+
opacity: 1;
179+
transform: rotate(-13deg) translateX(90px);
180+
}
181+
40% {
182+
opacity: 1;
183+
transform: rotate(-30deg) translateX(0px);
184+
}
185+
60% {
186+
opacity: 1;
187+
transform: rotate(-30deg) translateX(0px);
188+
}
189+
80% {
190+
opacity: 1;
191+
transform: rotate(-30deg) translateX(0px);
192+
}
193+
100% {
194+
opacity: 1;
195+
transform: rotate(-30deg) translateX(0px);
196+
}
197+
}
198+
@keyframes bottleThrow {
199+
0% {
200+
transform: translateY(4vw);
201+
}
202+
60% {
203+
transform: translateX(20vw) translateY(-20vw) rotate(-200deg);
204+
}
205+
100% {
206+
transform: translateX(20vw) translateY(10vw) rotate(-400deg);
207+
position: fixed;
208+
}
209+
}
210+
.showTextAnimation {
211+
animation-name: textboxInn;
212+
transition: 0.8s;
213+
animation-duration: 1s;
214+
animation-delay: 0.7s;
215+
animation-fill-mode: forwards;
216+
}
217+
218+
.showPlantLeftAnimation {
219+
animation-name: plantLeftInn;
220+
transition: 0.8s;
221+
animation-duration: 3s;
222+
animation-delay: 0.9s;
223+
animation-fill-mode: forwards;
224+
}
225+
226+
.showPlantRightAnimation {
227+
animation-name: plantRightInn;
228+
animation-duration: 1s;
229+
animation-delay: 0.9s;
230+
animation-fill-mode: forwards;
231+
}
232+
233+
.throwBottleAnimation {
234+
animation-name: bottleThrow;
235+
transition: 2s;
236+
animation-duration: 3s;
237+
animation-delay: 2s;
238+
animation-fill-mode: forwards;
239+
}/*# sourceMappingURL=index.css.map */

0 commit comments

Comments
 (0)