-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathherosection.html
More file actions
445 lines (353 loc) · 13.3 KB
/
Copy pathherosection.html
File metadata and controls
445 lines (353 loc) · 13.3 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
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Croloft - Link Everything</title>
<style>
:root {
--inter: 'Circular Std', sans-serif;
--brand-blue: #0047FF;
--brand-yellow: #ccff00;
/* --- PRECISION VARIABLES --- */
/* We use a larger height to ensure letters like 'g' don't get cut off */
--item-height: 100px;
/* This ensures the visual baseline of "LINK" matches the scrolling words */
--baseline-offset: 0;
}
body {
margin: 0;
padding: 0;
font-family: var(--inter);
background-color: var(--brand-blue);
color: white;
overflow-x: hidden;
}
/* --- HERO SECTION --- */
.hero {
height: 100vh;
display: flex;
align-items: center;
justify-content: center;
background: radial-gradient(circle at center, #000000 0%, #000000 100%);
}
.hero-wrap {
display: flex;
align-items: center;
justify-content: center;
gap: 24px; /* Space between LINK and the words */
}
.static-link {
font-size: 80px;
font-weight: 400;
letter-spacing: -2px;
/* Geometry enforcement for alignment */
height: var(--item-height);
line-height: var(--item-height);
display: flex;
align-items: center;
padding-bottom: var(--baseline-offset); /* Slight lift to match optical baseline */
}
.window {
/* We show exactly 3 items: top (faded), center (active), bottom (faded) */
height: calc(var(--item-height) * 3);
overflow: hidden;
display: block;
position: relative;
/* Gradient mask for the fade effect */
-webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 35%, black 30%, transparent 100%);
mask-image: linear-gradient(to bottom, transparent 0%, black 35%, black 65%, transparent 100%);
}
.track {
display: flex;
flex-direction: column;
/* 15s total for 5 steps = 3s per word */
animation: slideItems 10s cubic-bezier(0.85, 0, 0.15, 1) infinite;
}
.word {
height: var(--item-height);
font-size: 80px;
font-weight: 500;
letter-spacing: -2px;
display: flex;
align-items: center; /* Vertically centers text in the box */
padding-bottom: var(--baseline-offset);
/* Default State: Faded Blue-ish White */
color: rgba(255, 255, 255, 0.3);
/* Smooth transition for the color snap */
transition: color 0.3s ease-out;
white-space: nowrap;
}
/* The class Javascript will add */
.word.active-word {
color: var(--brand-yellow) !important;
text-shadow: 0 0 30px rgba(255, 215, 0, 0.3); /* Subtle glow */
}
/* --- ANIMATION LOGIC --- */
/* Moves the strip up one unit at a time */
@keyframes slideItems {
0%, 16% { transform: translateY(calc(var(--item-height) * -1)); } /* Item 1 Center */
20%, 36% { transform: translateY(calc(var(--item-height) * -2)); } /* Item 2 Center */
40%, 56% { transform: translateY(calc(var(--item-height) * -3)); } /* Item 3 Center */
60%, 76% { transform: translateY(calc(var(--item-height) * -4)); } /* Item 4 Center */
80%, 96% { transform: translateY(calc(var(--item-height) * -5)); } /* Item 5 Center */
100% { transform: translateY(calc(var(--item-height) * -6)); } /* Reset Loop */
}
/* The loop reset logic requires cloning the first items to the end.
0% starts at index 1 because index 0 is a buffer for the top fade.
*/
@media (max-width: 768px) {
.static-link, .word { font-size: 40px; }
.hero-wrap { flex-direction: column; gap: 0; }
.window { height: calc(var(--item-height) * 3); }
:root { --item-height: 60px; }
.header { padding: 0 20px; }
.nav-links, .search-container { display: none; }
}
</style>
</head>
<body>
<section class="hero">
<div class="hero-wrap">
<div class="static-link">LINK</div>
<div class="window" id="scrollWindow">
<div class="track">
<div class="word">Blockchains</div>
<div class="word">Everything</div>
<div class="word">Stocks</div>
<div class="word">Treasuries</div>
<div class="word">Banks</div>
<div class="word">Blockchains</div>
<div class="word">Everything</div>
</div>
</div>
</div>
</section>
<script>
document.addEventListener('DOMContentLoaded', () => {
// Intersection Observer configuration
// This creates a "trigger line" exactly in the middle of the window
const observerOptions = {
root: document.querySelector('#scrollWindow'),
rootMargin: "-50% 0px -50% 0px", // Slices off top 50% and bottom 50% so only the exact center pixel triggers
threshold: 0
};
const observer = new IntersectionObserver((entries) => {
entries.forEach(entry => {
if (entry.isIntersecting) {
// When it hits the center line, make it yellow
entry.target.classList.add('active-word');
} else {
// When it leaves the center line, make it grey
entry.target.classList.remove('active-word');
}
});
}, observerOptions);
// Start observing all words
document.querySelectorAll('.word').forEach(word => {
observer.observe(word);
});
});
</script>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Tech Features Component</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=Inter:wght@400;500;600;700&display=swap" rel="stylesheet">
<style>
.techfeat-wrapper-x9z {
margin: 0;
padding: 0;
box-sizing: border-box;
}
.techfeat-wrapper-x9z *,
.techfeat-wrapper-x9z *::before,
.techfeat-wrapper-x9z *::after {
box-sizing: inherit;
}
.techfeat-section-x9z {
background: linear-gradient(180deg, #1d1e1f 0%, #000000 100%);
padding: 80px 40px 100px;
font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
.techfeat-header-x9z {
max-width: 1200px;
margin: 0 auto 30px;
}
.techfeat-title-x9z {
color: #ffffff;
font-size: 45px;
font-weight: 500;
line-height: 1.2;
margin: 0 0 24px 0;
letter-spacing: -0.02em;
}
.techfeat-subtitle-x9z {
color: #9ea6bc;
font-size: 19px;
font-weight: 600;
line-height: 1;
margin: 0;
max-width: 900px;
}
.techfeat-grid-x9z {
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 30px;
max-width: 1200px;
margin: 0 auto;
}
.techfeat-card-x9z {
background: rgba(30, 37, 54, 0.5);
border-radius: 16px;
padding: 0;
overflow: hidden;
transition: transform 0.3s ease, background 0.3s ease;
}
.techfeat-icon-container-x9z {
width: 100%;
height: 320px;
display: flex;
align-items: center;
justify-content: center;
background: transparent;
position: relative;
overflow: hidden;
}
.techfeat-icon-x9z {
width: 280px;
height: 280px;
object-fit: contain;
filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.5));
}
.techfeat-content-x9z {
padding: 30px;
}
.techfeat-card-title-x9z {
color: #ffffff;
font-size: 20px;
font-weight: 550;
letter-spacing: -0.02em;
margin: 0 0 12px 0;
}
.techfeat-card-description-x9z {
color: #8b92a7;
font-size: 18px;
font-weight: 600;
margin: 0 0 18px 0;
letter-spacing: -0.02em;
}
.techfeat-button-x9z {
background: #174879c0;
color: #9dd2fa;
border: none;
border-radius: 8px;
padding: 14px 24px;
font-size: 16px;
font-weight: 600;
font-family: 'Inter', sans-serif;
cursor: pointer;
transition: all 0.3s ease;
display: inline-block;
text-decoration: none;
}
.techfeat-button-x9z:hover {
background: #2563a8;
color: #7cc5ff;
transform: translateY(-1px);
}
@media (max-width: 1200px) {
.techfeat-grid-x9z {
grid-template-columns: repeat(2, 1fr);
}
}
@media (max-width: 768px) {
.techfeat-section-x9z {
padding: 60px 24px 80px;
}
.techfeat-title-x9z {
font-size: 36px;
margin-bottom: 20px;
}
.techfeat-subtitle-x9z {
font-size: 18px;
}
.techfeat-grid-x9z {
grid-template-columns: 1fr;
gap: 24px;
}
.techfeat-icon-container-x9z {
height: 260px;
}
.techfeat-icon-x9z {
width: 220px;
height: 220px;
}
.techfeat-card-title-x9z {
font-size: 24px;
}
.techfeat-card-description-x9z {
font-size: 16px;
}
}
</style>
</head>
<body class="techfeat-wrapper-x9z">
<section class="techfeat-section-x9z">
<div class="techfeat-header-x9z">
<h1 class="techfeat-title-x9z">Built for rapid deployment</h1>
<p class="techfeat-subtitle-x9z">
Achieve faster time-to-market with our proprietary technology,
protected by industry-leading security standards.
</p>
</div>
<div class="techfeat-grid-x9z">
<!-- Security Card -->
<div class="techfeat-card-x9z">
<div class="techfeat-icon-container-x9z">
<img src="your-security-icon.png" alt="Security" class="techfeat-icon-x9z">
</div>
<div class="techfeat-content-x9z">
<h2 class="techfeat-card-title-x9z">Security</h2>
<p class="techfeat-card-description-x9z">
Leading the industry in licenses and certifications
</p>
<button class="techfeat-button-x9z">See our security features</button>
</div>
</div>
<!-- Components Card -->
<div class="techfeat-card-x9z">
<div class="techfeat-icon-container-x9z">
<img src="your-components-icon.png" alt="Components" class="techfeat-icon-x9z">
</div>
<div class="techfeat-content-x9z">
<h2 class="techfeat-card-title-x9z">Components</h2>
<p class="techfeat-card-description-x9z">
Embeddable components for any enterprise application
</p>
<button class="techfeat-button-x9z">Build your component now</button>
</div>
</div>
<!-- API Card -->
<div class="techfeat-card-x9z">
<div class="techfeat-icon-container-x9z">
<img src="your-api-icon.png" alt="API" class="techfeat-icon-x9z">
</div>
<div class="techfeat-content-x9z">
<h2 class="techfeat-card-title-x9z">API</h2>
<p class="techfeat-card-description-x9z">
Embed turn-key integration modules directly into your platform
</p>
<button class="techfeat-button-x9z">Connect now</button>
</div>
</div>
</div>
</section>
</body>
</html>