forked from heygen-com/hyperframes
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex_moon_before_suitcase_wheels.html
More file actions
236 lines (228 loc) · 9.68 KB
/
Copy pathindex_moon_before_suitcase_wheels.html
File metadata and controls
236 lines (228 loc) · 9.68 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
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
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
<!DOCTYPE html>
<html lang="vi">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=1080, height=1920, initial-scale=1.0">
<title>Nghịch Lý Phát Minh #03 - Mặt Trăng & Vali Kéo</title>
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Be+Vietnam+Pro:wght@600;700;800&family=Montserrat:wght@700;800;900&display=swap" rel="stylesheet">
<script src="https://cdnjs.cloudflare.com/ajax/libs/gsap/3.12.2/gsap.min.js"></script>
<style>
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
body {
width: 1080px;
height: 1920px;
background-color: #120E0E;
color: #FFF8E7;
font-family: "Be Vietnam Pro", sans-serif;
overflow: hidden;
position: relative;
}
#stage {
width: 1080px;
height: 1920px;
position: relative;
background: radial-gradient(circle at 50% 35%, #241A18 0%, #171110 55%, #0D0909 100%);
}
.bg-glow {
position: absolute;
top: 25%;
left: 50%;
transform: translate(-50%, -50%);
width: 950px;
height: 950px;
background: radial-gradient(circle, rgba(192, 57, 43, 0.12) 0%, rgba(212, 175, 55, 0.04) 50%, transparent 75%);
border-radius: 50%;
filter: blur(60px);
pointer-events: none;
}
.top-badge-container {
position: absolute;
top: 210px;
left: 50%;
transform: translateX(-50%);
width: 440px;
height: 60px;
background: rgba(18, 14, 14, 0.88);
border: 1.5px solid #D4AF37;
border-radius: 10px;
display: flex;
align-items: center;
justify-content: center;
box-shadow: 0 0 22px rgba(212, 175, 55, 0.35);
z-index: 100;
}
.top-badge-text {
font-family: "Montserrat", sans-serif;
font-weight: 800;
font-size: 24px;
letter-spacing: 2px;
color: #D4AF37;
text-transform: uppercase;
}
.main-visual-wrapper {
position: absolute;
top: 300px;
left: 50%;
transform: translateX(-50%);
width: 880px;
height: 1100px;
border-radius: 20px;
overflow: hidden;
box-shadow: 0 0 55px rgba(192, 57, 43, 0.4), 0 0 25px rgba(0, 0, 0, 0.85);
border: 1.5px solid rgba(212, 175, 55, 0.45);
z-index: 10;
background: #0D0909;
}
.scene-image {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
object-fit: cover;
opacity: 0;
transform: scale(1.24) translateY(45px);
transform-origin: center center;
}
.subtitle-zone {
position: absolute;
top: 1440px;
left: 50%;
transform: translateX(-50%);
width: 880px;
min-height: 220px;
background: rgba(18, 14, 14, 0.94);
border: 1.5px solid rgba(212, 175, 55, 0.45);
border-radius: 18px;
padding: 20px 32px;
display: flex;
align-items: center;
justify-content: center;
text-align: center;
box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8);
z-index: 100;
}
.subtitle-text {
position: absolute;
width: 816px;
font-family: "Be Vietnam Pro", sans-serif;
font-weight: 700;
font-size: 34px;
line-height: 1.45;
color: #FFF8E7;
opacity: 0;
transform: translateY(15px);
}
.subtitle-text .highlight {
color: #FFD700;
text-shadow: 0 0 12px rgba(255, 215, 0, 0.45);
}
.corner-accent {
position: absolute;
width: 14px;
height: 14px;
border-color: #D4AF37;
border-style: solid;
pointer-events: none;
z-index: 101;
}
.top-left { top: 12px; left: 12px; border-width: 2px 0 0 2px; }
.top-right { top: 12px; right: 12px; border-width: 2px 2px 0 0; }
.bottom-left { bottom: 12px; left: 12px; border-width: 0 0 2px 2px; }
.bottom-right { bottom: 12px; right: 12px; border-width: 0 2px 2px 0; }
</style>
</head>
<body>
<div id="stage" class="clip" data-composition-id="moon_before_suitcase_wheels" data-width="1080" data-height="1920" data-duration="32.498" data-start="0">
<div class="bg-glow"></div>
<div class="top-badge-container">
<div class="top-badge-text">NGHỊCH LÝ PHÁT MINH #03</div>
</div>
<div class="main-visual-wrapper">
<img id="img_01" class="scene-image" data-layout-allow-overflow src="public/images/moon_before_suitcase_wheels/01.jpg" alt="Moon landing lunar module">
<img id="img_02" class="scene-image" data-layout-allow-overflow src="public/images/moon_before_suitcase_wheels/02.jpg" alt="Astronaut in cosmic space">
<img id="img_03" class="scene-image" data-layout-allow-overflow src="public/images/moon_before_suitcase_wheels/03.jpg" alt="Passengers carrying heavy luggage">
<img id="img_04" class="scene-image" data-layout-allow-overflow src="public/images/moon_before_suitcase_wheels/04.jpg" alt="Bernard Sadow suitcase patent sketch">
<img id="img_05" class="scene-image" data-layout-allow-overflow src="public/images/moon_before_suitcase_wheels/05.jpg" alt="Department store rejection">
<img id="img_06" class="scene-image" data-layout-allow-overflow src="public/images/moon_before_suitcase_wheels/06.jpg" alt="Robert Plath rollaboard revolution">
<img id="img_07" class="scene-image" data-layout-allow-overflow src="public/images/moon_before_suitcase_wheels/07.jpg" alt="Space travel vs luggage paradox">
</div>
<div class="subtitle-zone">
<div class="corner-accent top-left"></div>
<div class="corner-accent top-right"></div>
<div class="corner-accent bottom-left"></div>
<div class="corner-accent bottom-right"></div>
<div id="sub_01" class="subtitle-text">Con người đã <span class="highlight">lên Mặt Trăng</span> trước khi vali có bánh xe.</div>
<div id="sub_02" class="subtitle-text">Tháng 7 năm 1969, <span class="highlight">Neil Armstrong</span> bước xuống bề mặt Mặt Trăng.</div>
<div id="sub_03" class="subtitle-text">Cùng lúc đó, hành khách đi máy bay vẫn phải <span class="highlight">xách và vác những chiếc vali nặng trịch</span>.</div>
<div id="sub_04" class="subtitle-text">Năm 1970, <span class="highlight">Bernard Sadow</span> mới nộp bằng sáng chế cho vali 4 bánh nhỏ kéo bằng dây.</div>
<div id="sub_05" class="subtitle-text">Ý tưởng đó bị từ chối, vì họ nghĩ <span class="highlight">đàn ông sẽ không chịu kéo vali</span>.</div>
<div id="sub_06" class="subtitle-text">Tới 1987, phi công <span class="highlight">Robert Plath</span> mới thêm cán kéo đứng và 2 bánh xe kiểu hiện đại.</div>
<div id="sub_07" class="subtitle-text">Ta giải được bài toán <span class="highlight">bay tới thiên thể khác</span>, trước khi giải bài toán không phải khiêng hành lý!</div>
</div>
</div>
<audio id="sound_01" class="clip" src="public/audio/moon_before_suitcase_wheels/cut_01.mp3" data-start="0.0" data-duration="2.152"></audio>
<audio id="sound_02" class="clip" src="public/audio/moon_before_suitcase_wheels/cut_02.mp3" data-start="2.152" data-duration="3.861"></audio>
<audio id="sound_03" class="clip" src="public/audio/moon_before_suitcase_wheels/cut_03.mp3" data-start="6.013" data-duration="4.245"></audio>
<audio id="sound_04" class="clip" src="public/audio/moon_before_suitcase_wheels/cut_04.mp3" data-start="10.258" data-duration="7.032"></audio>
<audio id="sound_05" class="clip" src="public/audio/moon_before_suitcase_wheels/cut_05.mp3" data-start="17.29" data-duration="3.88"></audio>
<audio id="sound_06" class="clip" src="public/audio/moon_before_suitcase_wheels/cut_06.mp3" data-start="21.17" data-duration="6.84"></audio>
<audio id="sound_07" class="clip" src="public/audio/moon_before_suitcase_wheels/cut_07.mp3" data-start="28.01" data-duration="4.488"></audio>
<audio id="bgm" class="clip" src="bgm.mp3" data-start="0" data-duration="32.498" data-track-index="2" data-volume="0.14" data-media-start="0"></audio>
<script>
document.addEventListener("DOMContentLoaded", () => {
const cuts = [
{ img: "#img_01", sub: "#sub_01", start: 0.0, duration: 2.152 },
{ img: "#img_02", sub: "#sub_02", start: 2.152, duration: 3.861 },
{ img: "#img_03", sub: "#sub_03", start: 6.013, duration: 4.245 },
{ img: "#img_04", sub: "#sub_04", start: 10.258, duration: 7.032 },
{ img: "#img_05", sub: "#sub_05", start: 17.29, duration: 3.88 },
{ img: "#img_06", sub: "#sub_06", start: 21.17, duration: 6.84 },
{ img: "#img_07", sub: "#sub_07", start: 28.01, duration: 4.488 }
];
const tl = gsap.timeline({ paused: true });
cuts.forEach((cut) => {
const cutEnd = cut.start + cut.duration;
tl.to(cut.img, {
opacity: 1,
y: 20,
scale: 1.28,
duration: 0.4,
ease: "power2.out"
}, cut.start);
tl.to(cut.img, {
scale: 1.34,
y: 10,
duration: Math.max(0.1, cut.duration - 0.4),
ease: "none"
}, cut.start + 0.4);
tl.to(cut.img, {
opacity: 0,
duration: 0.2,
ease: "power2.in"
}, cutEnd - 0.2);
tl.to(cut.sub, {
opacity: 1,
y: 0,
duration: 0.3,
ease: "power3.out"
}, cut.start + 0.05);
tl.to(cut.sub, {
opacity: 0,
y: -10,
duration: 0.15,
ease: "power2.in"
}, cutEnd - 0.15);
});
window.__timelines = window.__timelines || {};
window.__timelines["moon_before_suitcase_wheels"] = tl;
});
</script>
</body>
</html>