helloThien commited on
Commit
c79342b
·
verified ·
1 Parent(s): 7c2cb7f

Upload folder using huggingface_hub

Browse files
Files changed (1) hide show
  1. index.html +476 -19
index.html CHANGED
@@ -1,19 +1,476 @@
1
- <!doctype html>
2
- <html>
3
- <head>
4
- <meta charset="utf-8" />
5
- <meta name="viewport" content="width=device-width" />
6
- <title>My static Space</title>
7
- <link rel="stylesheet" href="style.css" />
8
- </head>
9
- <body>
10
- <div class="card">
11
- <h1>Welcome to your static Space!</h1>
12
- <p>You can modify this app directly by editing <i>index.html</i> in the Files and versions tab.</p>
13
- <p>
14
- Also don't forget to check the
15
- <a href="https://huggingface.co/docs/hub/spaces" target="_blank">Spaces documentation</a>.
16
- </p>
17
- </div>
18
- </body>
19
- </html>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>Hi. | Modern Greeting Experience</title>
7
+
8
+ <!-- Google Fonts -->
9
+ <link rel="preconnect" href="https://fonts.googleapis.com">
10
+ <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
11
+ <link href="https://fonts.googleapis.com/css2?family=Outfit:wght@300;500;700;900&family=Space+Grotesk:wght@300;500;700&display=swap" rel="stylesheet">
12
+
13
+ <!-- FontAwesome for Icons -->
14
+ <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
15
+
16
+ <style>
17
+ /* --- CSS Variables & Reset --- */
18
+ :root {
19
+ --bg-dark: #0f172a;
20
+ --bg-darker: #020617;
21
+ --primary: #6366f1; /* Indigo */
22
+ --secondary: #ec4899; /* Pink */
23
+ --accent: #8b5cf6; /* Violet */
24
+ --text-main: #f8fafc;
25
+ --text-muted: #94a3b8;
26
+ --glass-bg: rgba(255, 255, 255, 0.03);
27
+ --glass-border: rgba(255, 255, 255, 0.05);
28
+ --card-hover: rgba(255, 255, 255, 0.08);
29
+ --shadow: 0 10px 40px -10px rgba(0,0,0,0.5);
30
+ --font-display: 'Outfit', sans-serif;
31
+ --font-body: 'Space Grotesk', sans-serif;
32
+ }
33
+
34
+ * {
35
+ margin: 0;
36
+ padding: 0;
37
+ box-sizing: border-box;
38
+ }
39
+
40
+ body {
41
+ background-color: var(--bg-dark);
42
+ color: var(--text-main);
43
+ font-family: var(--font-body);
44
+ line-height: 1.6;
45
+ overflow-x: hidden;
46
+ min-height: 100vh;
47
+ display: flex;
48
+ flex-direction: column;
49
+ background-image:
50
+ radial-gradient(circle at 15% 50%, rgba(99, 102, 241, 0.15) 0%, transparent 50%),
51
+ radial-gradient(circle at 85% 30%, rgba(236, 72, 153, 0.15) 0%, transparent 50%);
52
+ }
53
+
54
+ /* --- Animations --- */
55
+ @keyframes float {
56
+ 0% { transform: translateY(0px); }
57
+ 50% { transform: translateY(-20px); }
58
+ 100% { transform: translateY(0px); }
59
+ }
60
+
61
+ @keyframes fadeIn {
62
+ from { opacity: 0; transform: translateY(20px); }
63
+ to { opacity: 1; transform: translateY(0); }
64
+ }
65
+
66
+ @keyframes gradientText {
67
+ 0% { background-position: 0% 50%; }
68
+ 50% { background-position: 100% 50%; }
69
+ 100% { background-position: 0% 50%; }
70
+ }
71
+
72
+ @keyframes pulseGlow {
73
+ 0% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.4); }
74
+ 70% { box-shadow: 0 0 0 20px rgba(99, 102, 241, 0); }
75
+ 100% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0); }
76
+ }
77
+
78
+ /* --- Header / Navigation --- */
79
+ header {
80
+ position: fixed;
81
+ top: 0;
82
+ width: 100%;
83
+ padding: 1.5rem 5%;
84
+ display: flex;
85
+ justify-content: space-between;
86
+ align-items: center;
87
+ z-index: 1000;
88
+ backdrop-filter: blur(12px);
89
+ background: rgba(15, 23, 42, 0.7);
90
+ border-bottom: 1px solid var(--glass-border);
91
+ transition: all 0.3s ease;
92
+ }
93
+
94
+ .logo {
95
+ font-family: var(--font-display);
96
+ font-weight: 700;
97
+ font-size: 1.5rem;
98
+ letter-spacing: -0.02em;
99
+ color: var(--text-main);
100
+ text-decoration: none;
101
+ display: flex;
102
+ align-items: center;
103
+ gap: 0.5rem;
104
+ }
105
+
106
+ .logo i {
107
+ color: var(--primary);
108
+ }
109
+
110
+ .anycoder-link {
111
+ font-size: 0.875rem;
112
+ color: var(--text-muted);
113
+ text-decoration: none;
114
+ padding: 0.5rem 1rem;
115
+ border: 1px solid var(--glass-border);
116
+ border-radius: 50px;
117
+ background: var(--glass-bg);
118
+ transition: all 0.3s ease;
119
+ font-weight: 500;
120
+ }
121
+
122
+ .anycoder-link:hover {
123
+ color: var(--primary);
124
+ border-color: var(--primary);
125
+ background: rgba(99, 102, 241, 0.1);
126
+ }
127
+
128
+ /* --- Main Content --- */
129
+ main {
130
+ flex: 1;
131
+ display: flex;
132
+ flex-direction: column;
133
+ align-items: center;
134
+ justify-content: center;
135
+ padding: 8rem 1.5rem 4rem;
136
+ max-width: 1200px;
137
+ margin: 0 auto;
138
+ width: 100%;
139
+ }
140
+
141
+ /* --- Hero Section --- */
142
+ .hero {
143
+ text-align: center;
144
+ margin-bottom: 4rem;
145
+ position: relative;
146
+ z-index: 1;
147
+ }
148
+
149
+ .greeting-container {
150
+ margin-bottom: 1.5rem;
151
+ position: relative;
152
+ display: inline-block;
153
+ }
154
+
155
+ .main-text {
156
+ font-family: var(--font-display);
157
+ font-size: clamp(5rem, 15vw, 12rem);
158
+ font-weight: 900;
159
+ line-height: 0.9;
160
+ background: linear-gradient(135deg, #fff 0%, #94a3b8 50%, #6366f1 100%);
161
+ background-size: 200% 200%;
162
+ -webkit-background-clip: text;
163
+ background-clip: text;
164
+ color: transparent;
165
+ animation: gradientText 6s ease infinite;
166
+ letter-spacing: -0.05em;
167
+ display: block;
168
+ cursor: pointer;
169
+ transition: transform 0.3s ease;
170
+ }
171
+
172
+ .main-text:hover {
173
+ transform: scale(1.02);
174
+ }
175
+
176
+ .sub-text {
177
+ font-size: clamp(1.1rem, 2vw, 1.5rem);
178
+ color: var(--text-muted);
179
+ max-width: 600px;
180
+ margin: 0 auto 2.5rem;
181
+ font-weight: 300;
182
+ animation: fadeIn 1s ease-out 0.5s backwards;
183
+ }
184
+
185
+ /* --- Interactive Button --- */
186
+ .action-btn {
187
+ background: linear-gradient(90deg, var(--primary), var(--accent));
188
+ color: white;
189
+ border: none;
190
+ padding: 1rem 2.5rem;
191
+ font-size: 1.1rem;
192
+ border-radius: 12px;
193
+ font-family: var(--font-display);
194
+ font-weight: 600;
195
+ cursor: pointer;
196
+ position: relative;
197
+ overflow: hidden;
198
+ transition: transform 0.2s ease, box-shadow 0.3s ease;
199
+ box-shadow: 0 4px 15px rgba(99, 102, 241, 0.4);
200
+ animation: fadeIn 1s ease-out 0.8s backwards;
201
+ }
202
+
203
+ .action-btn::before {
204
+ content: '';
205
+ position: absolute;
206
+ top: 0;
207
+ left: -100%;
208
+ width: 100%;
209
+ height: 100%;
210
+ background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
211
+ transition: 0.5s;
212
+ }
213
+
214
+ .action-btn:hover {
215
+ transform: translateY(-2px);
216
+ box-shadow: 0 8px 25px rgba(99, 102, 241, 0.6);
217
+ }
218
+
219
+ .action-btn:hover::before {
220
+ left: 100%;
221
+ }
222
+
223
+ .action-btn:active {
224
+ transform: translateY(1px);
225
+ }
226
+
227
+ /* --- Features Grid --- */
228
+ .features {
229
+ display: grid;
230
+ grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
231
+ gap: 2rem;
232
+ width: 100%;
233
+ margin-top: 2rem;
234
+ }
235
+
236
+ .card {
237
+ background: var(--glass-bg);
238
+ border: 1px solid var(--glass-border);
239
+ padding: 2rem;
240
+ border-radius: 24px;
241
+ backdrop-filter: blur(10px);
242
+ transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
243
+ position: relative;
244
+ overflow: hidden;
245
+ animation: fadeIn 1s ease-out 1.1s backwards;
246
+ }
247
+
248
+ .card:nth-child(2) {
249
+ animation-delay: 1.3s;
250
+ }
251
+
252
+ .card:nth-child(3) {
253
+ animation-delay: 1.5s;
254
+ }
255
+
256
+ .card:hover {
257
+ transform: translateY(-10px);
258
+ background: var(--card-hover);
259
+ border-color: rgba(99, 102, 241, 0.3);
260
+ box-shadow: var(--shadow);
261
+ }
262
+
263
+ .card-icon {
264
+ font-size: 2rem;
265
+ margin-bottom: 1.5rem;
266
+ background: rgba(99, 102, 241, 0.1);
267
+ width: 60px;
268
+ height: 60px;
269
+ display: flex;
270
+ align-items: center;
271
+ justify-content: center;
272
+ border-radius: 16px;
273
+ color: var(--primary);
274
+ }
275
+
276
+ .card h3 {
277
+ font-family: var(--font-display);
278
+ font-size: 1.25rem;
279
+ margin-bottom: 0.75rem;
280
+ color: var(--text-main);
281
+ }
282
+
283
+ .card p {
284
+ color: var(--text-muted);
285
+ font-size: 0.95rem;
286
+ }
287
+
288
+ /* --- Decorative Elements --- */
289
+ .floating-shape {
290
+ position: absolute;
291
+ border-radius: 50%;
292
+ filter: blur(80px);
293
+ z-index: -1;
294
+ opacity: 0.6;
295
+ }
296
+
297
+ .shape-1 {
298
+ top: 20%;
299
+ left: 10%;
300
+ width: 300px;
301
+ height: 300px;
302
+ background: var(--primary);
303
+ animation: float 8s ease-in-out infinite;
304
+ }
305
+
306
+ .shape-2 {
307
+ bottom: 20%;
308
+ right: 10%;
309
+ width: 250px;
310
+ height: 250px;
311
+ background: var(--secondary);
312
+ animation: float 10s ease-in-out infinite reverse;
313
+ }
314
+
315
+ /* --- Footer --- */
316
+ footer {
317
+ text-align: center;
318
+ padding: 2rem;
319
+ color: var(--text-muted);
320
+ font-size: 0.9rem;
321
+ border-top: 1px solid var(--glass-border);
322
+ background: rgba(2, 6, 23, 0.5);
323
+ }
324
+
325
+ /* --- Responsive Tweaks --- */
326
+ @media (max-width: 768px) {
327
+ header {
328
+ padding: 1rem 5%;
329
+ }
330
+
331
+ .main-text {
332
+ font-size: 4.5rem;
333
+ }
334
+
335
+ .features {
336
+ grid-template-columns: 1fr;
337
+ }
338
+ }
339
+ </style>
340
+ </head>
341
+ <body>
342
+
343
+ <!-- Decorative Background Shapes -->
344
+ <div class="floating-shape shape-1"></div>
345
+ <div class="floating-shape shape-2"></div>
346
+
347
+ <!-- Header -->
348
+ <header>
349
+ <a href="#" class="logo">
350
+ <i class="fa-solid fa-wave-square"></i>
351
+ Hi.App
352
+ </a>
353
+ <!-- CRITICAL LINK -->
354
+ <a href="https://huggingface.co/spaces/akhaliq/anycoder" target="_blank" class="anycoder-link">
355
+ Built with anycoder <i class="fa-solid fa-arrow-up-right-from-square" style="font-size: 0.7em; margin-left: 4px;"></i>
356
+ </a>
357
+ </header>
358
+
359
+ <!-- Main Content -->
360
+ <main>
361
+
362
+ <!-- Hero Section -->
363
+ <section class="hero">
364
+ <div class="greeting-container">
365
+ <h1 class="main-text" id="greeting-text">Hi.</h1>
366
+ </div>
367
+ <p class="sub-text">
368
+ A minimal, responsive, and interactive greeting experience.<br>
369
+ Start a conversation with the digital world.
370
+ </p>
371
+
372
+ <button class="action-btn" id="greet-btn" onclick="changeGreeting()">
373
+ <i class="fa-solid fa-language"></i> Say Hello
374
+ </button>
375
+ </section>
376
+
377
+ <!-- Feature Cards -->
378
+ <section class="features">
379
+ <article class="card">
380
+ <div class="card-icon">
381
+ <i class="fa-solid fa-bolt"></i>
382
+ </div>
383
+ <h3>Instant Interaction</h3>
384
+ <p>Experience seamless transitions and immediate feedback with vanilla JavaScript logic.</p>
385
+ </article>
386
+
387
+ <article class="card">
388
+ <div class="card-icon">
389
+ <i class="fa-solid fa-layer-group"></i>
390
+ </div>
391
+ <h3>Modern Aesthetics</h3>
392
+ <p>Styled with modern CSS variables, glassmorphism effects, and fluid typography.</p>
393
+ </article>
394
+
395
+ <article class="card">
396
+ <div class="card-icon">
397
+ <i class="fa-solid fa-mobile-screen"></i>
398
+ </div>
399
+ <h3>Fully Responsive</h3>
400
+ <p>Adapts perfectly to any screen size, ensuring a great look on mobile, tablet, and desktop.</p>
401
+ </article>
402
+ </section>
403
+
404
+ </main>
405
+
406
+ <!-- Footer -->
407
+ <footer>
408
+ <p>&copy; 2023 Hi.App. Designed for the web.</p>
409
+ </footer>
410
+
411
+ <!-- JavaScript Logic -->
412
+ <script>
413
+ // Data for greeting rotation
414
+ const greetings = [
415
+ { text: "Hi.", lang: "English" },
416
+ { text: "Hola.", lang: "Spanish" },
417
+ { text: "Bonjour.", lang: "French" },
418
+ { text: "Ciao.", lang: "Italian" },
419
+ { text: "Hallo.", lang: "German" },
420
+ { text: "Olá.", lang: "Portuguese" },
421
+ { text: "你好.", lang: "Chinese" },
422
+ { text: "こんにちは.", lang: "Japanese" },
423
+ { text: "안녕하세요.", lang: "Korean" },
424
+ { text: "مرحبا.", lang: "Arabic" },
425
+ { text: "Привет.", lang: "Russian" }
426
+ ];
427
+
428
+ let currentIndex = 0;
429
+ const greetingElement = document.getElementById('greeting-text');
430
+ const btnElement = document.getElementById('greet-btn');
431
+ let isAnimating = false;
432
+
433
+ function changeGreeting() {
434
+ if (isAnimating) return;
435
+ isAnimating = true;
436
+
437
+ // 1. Fade out
438
+ greetingElement.style.opacity = '0';
439
+ greetingElement.style.transform = 'translateY(-20px) rotateX(90deg)';
440
+ greetingElement.style.transition = 'all 0.4s ease';
441
+
442
+ // 2. Change text and fade in after short delay
443
+ setTimeout(() => {
444
+ // Increment index
445
+ currentIndex = (currentIndex + 1) % greetings.length;
446
+ const nextGreeting = greetings[currentIndex];
447
+
448
+ // Update DOM
449
+ greetingElement.innerText = nextGreeting.text;
450
+
451
+ // Optional: Update button text to show language
452
+ btnElement.innerHTML = `<i class="fa-solid fa-language"></i> ${nextGreeting.lang}`;
453
+
454
+ // Fade in
455
+ greetingElement.style.opacity = '1';
456
+ greetingElement.style.transform = 'translateY(0) rotateX(0)';
457
+
458
+ isAnimating = false;
459
+ }, 400);
460
+ }
461
+
462
+ // Add subtle mouse parallax effect to the main text
463
+ document.addEventListener('mousemove', (e) => {
464
+ const x = (window.innerWidth - e.pageX * 2) / 100;
465
+ const y = (window.innerHeight - e.pageY * 2) / 100;
466
+
467
+ // Apply slight rotation/shift to the main text
468
+ greetingElement.style.transform = `perspective(1000px) rotateY(${x * 0.5}deg) rotateX(${y * -0.5}deg)`;
469
+ });
470
+
471
+ // Add click effect to the main text itself
472
+ greetingElement.addEventListener('click', changeGreeting);
473
+ greetingElement.style.cursor = "pointer";
474
+ </script>
475
+ </body>
476
+ </html>