-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdatinpage2.html
477 lines (429 loc) · 15.3 KB
/
datinpage2.html
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
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>ConnectHeart - Find Your Match</title>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css">
<style>
:root {
--primary-color: #ff4757;
--secondary-color: #2f3542;
--accent-color: #ff6b81;
--light-color: #ffffff;
}
* {
margin: 0;
padding: 0;
box-sizing: border-box;
font-family: 'Poppins', sans-serif;
}
body {
background: linear-gradient(135deg, #fff5f5 0%, #fff0f7 100%);
color: var(--secondary-color);
}
.header {
background: rgba(255, 71, 87, 0.95);
padding: 1rem;
position: fixed;
width: 100%;
top: 0;
z-index: 1000;
box-shadow: 0 2px 15px rgba(0,0,0,0.1);
backdrop-filter: blur(10px);
}
.nav-container {
max-width: 1200px;
margin: 0 auto;
display: flex;
justify-content: space-between;
align-items: center;
}
.logo {
color: var(--light-color);
font-size: 2rem;
font-weight: 700;
text-decoration: none;
transition: transform 0.3s;
display: flex;
align-items: center;
gap: 0.5rem;
}
.logo i {
animation: float 3s ease-in-out infinite;
}
.nav-links {
display: flex;
gap: 2rem;
}
.nav-links a {
color: var(--light-color);
text-decoration: none;
padding: 0.5rem 1rem;
border-radius: 20px;
transition: all 0.3s;
position: relative;
}
.nav-links a::after {
content: '';
position: absolute;
width: 0;
height: 2px;
background: var(--light-color);
bottom: 0;
left: 0;
transition: width 0.3s;
}
.nav-links a:hover::after {
width: 100%;
}
.hero {
height: 90vh;
display: flex;
align-items: center;
justify-content: center;
text-align: center;
margin-top: 80px;
background: linear-gradient(rgba(0,0,0,0.4), rgba(0,0,0,0.4)),
url('https://images.unsplash.com/photo-1531427186611-ecfd6d936c79?ixlib=rb-1.2.1&auto=format&fit=crop&w=1950&q=80');
background-size: cover;
background-position: center;
background-attachment: fixed;
}
.hero-content {
max-width: 800px;
padding: 2rem;
}
.hero-content h1 {
font-size: 4rem;
color: var(--light-color);
margin-bottom: 1.5rem;
text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}
.search-container {
display: flex;
gap: 1.5rem;
justify-content: center;
margin: 2rem 0;
flex-wrap: wrap;
}
.search-btn {
padding: 1.2rem 2.5rem;
border: none;
border-radius: 30px;
background: var(--primary-color);
color: white;
cursor: pointer;
transition: all 0.3s;
display: flex;
align-items: center;
gap: 0.8rem;
font-weight: 500;
box-shadow: 0 4px 15px rgba(255,71,87,0.3);
}
.search-btn:hover {
background: var(--accent-color);
transform: translateY(-3px);
box-shadow: 0 6px 20px rgba(255,107,129,0.4);
}
.profiles-grid {
max-width: 1400px;
margin: 4rem auto;
display: grid;
grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
gap: 2.5rem;
padding: 0 2rem;
}
.profile-card {
background: white;
border-radius: 20px;
padding: 1.5rem;
box-shadow: 0 10px 30px rgba(0,0,0,0.1);
transition: transform 0.3s, box-shadow 0.3s;
cursor: pointer;
position: relative;
overflow: hidden;
}
.profile-card:hover {
transform: translateY(-10px);
box-shadow: 0 15px 40px rgba(0,0,0,0.15);
}
.profile-img {
width: 100%;
height: 300px;
border-radius: 15px;
object-fit: cover;
margin-bottom: 1.5rem;
transition: transform 0.3s;
}
.profile-card:hover .profile-img {
transform: scale(1.03);
}
.profile-badge {
position: absolute;
top: 20px;
right: 20px;
background: var(--primary-color);
color: white;
padding: 0.5rem 1rem;
border-radius: 20px;
font-size: 0.9rem;
}
.modal {
display: none;
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: rgba(0,0,0,0.5);
justify-content: center;
align-items: center;
z-index: 1001;
backdrop-filter: blur(5px);
}
.modal-content {
background: white;
padding: 2.5rem;
border-radius: 20px;
max-width: 500px;
width: 90%;
animation: modalEnter 0.4s ease-out;
}
@keyframes modalEnter {
from {
transform: translateY(-50px);
opacity: 0;
}
to {
transform: translateY(0);
opacity: 1;
}
}
.form-group {
margin-bottom: 1.5rem;
}
input, select, textarea {
width: 100%;
padding: 1rem;
border: 2px solid #eee;
border-radius: 12px;
margin-top: 0.5rem;
transition: border-color 0.3s;
}
input:focus, select:focus, textarea:focus {
border-color: var(--primary-color);
outline: none;
}
.skeleton {
animation: skeleton-loading 1s linear infinite alternate;
background: #eee;
border-radius: 15px;
}
@keyframes skeleton-loading {
0% { background-color: #f5f5f5 }
100% { background-color: #e0e0e0 }
}
@keyframes float {
0% { transform: translateY(0px) }
50% { transform: translateY(-10px) }
100% { transform: translateY(0px) }
}
@media (max-width: 768px) {
.hero-content h1 {
font-size: 2.8rem;
}
.search-btn {
width: 100%;
justify-content: center;
}
}
</style>
</head>
<body>
<header class="header">
<nav class="nav-container">
<a href="#" class="logo">
<i class="fas fa-heart"></i>ConnectHeart
</a>
<div class="nav-links">
<a href="#home">Home</a>
<a href="#search">Search</a>
<a href="#post">Post Ad</a>
</div>
</nav>
</header>
<section class="hero" id="home">
<div class="hero-content">
<h1>Find Your Perfect Match</h1>
<div class="search-container">
<button class="search-btn" onclick="showSearchModal()">
<i class="fas fa-search"></i> Search Partners
</button>
<button class="search-btn" onclick="showPostModal()">
<i class="fas fa-plus"></i> Post Your Ad
</button>
</div>
</div>
</section>
<section class="profiles-grid" id="profiles">
<!-- Profile cards will be dynamically loaded here -->
</section>
<!-- Modals -->
<div id="searchModal" class="modal">
<div class="modal-content">
<span class="close" onclick="this.parentElement.parentElement.style.display='none'">×</span>
<h2>Search Filters</h2>
<form id="searchForm">
<div class="form-group">
<label for="searchGender">I'm looking for</label>
<select id="searchGender" name="gender">
<option value="male">Male</option>
<option value="female">Female</option>
<option value="other">Other</option>
</select>
</div>
<div class="form-group">
<label for="searchAge">Age Range</label>
<div class="range-container">
<input type="range" id="searchAge" name="age" min="18" max="60" value="25">
<span class="range-value">25</span>
</div>
</div>
<div class="form-group">
<label for="searchLocation">Location</label>
<input type="text" id="searchLocation" name="location" placeholder="Enter city or zip code">
</div>
<div class="form-group">
<label for="searchInterests">Interests</label>
<input type="text" id="searchInterests" name="interests" placeholder="e.g. hiking, movies, cooking">
</div>
<button type="submit" class="search-btn">
<i class="fas fa-search"></i> Find Matches
</button>
</form>
</div>
</div>
<div id="postModal" class="modal">
<div class="modal-content">
<h2>Create Your Profile</h2>
<form id="postForm">
<div class="form-group">
<label for="postName">Your Name</label>
<input type="text" id="postName" name="name" required>
</div>
<div class="form-group">
<label for="postAge">Your Age</label>
<input type="number" id="postAge" name="age" min="18" max="99" required>
</div>
<div class="form-group">
<label for="postGender">Gender</label>
<select id="postGender" name="gender" required>
<option value="male">Male</option>
<option value="female">Female</option>
<option value="other">Other</option>
</select>
</div>
<div class="form-group">
<label for="postLocation">Location</label>
<input type="text" id="postLocation" name="location" required>
</div>
<div class="form-group">
<label for="postBio">About You</label>
<textarea id="postBio" name="bio" rows="4" required></textarea>
</div>
<div class="form-group">
<label for="postInterests">Your Interests</label>
<input type="text" id="postInterests" name="interests" placeholder="e.g. hiking, movies, cooking">
</div>
<div class="form-group">
<label for="postPhoto">Profile Photo</label>
<input type="file" id="postPhoto" name="photo" accept="image/*">
</div>
<button type="submit" class="search-btn">
<i class="fas fa-check"></i> Create Profile
</button>
</form>
</div>
</div>
<script>
const profiles = [
{
name: "Sarah",
age: 28,
location: "New York",
gender: "female",
image: 'https://images.unsplash.com/photo-1494790108377-be9c29b29330?ixlib=rb-1.2.1&ixid=MnwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8&auto=format&fit=crop&w=687&q=80'
},
{
name: "Mike",
age: 32,
location: "London",
gender: "male",
image: 'https://images.unsplash.com/photo-1506794778202-cad84cf45f1d?ixlib=rb-1.2.1&ixid=MnwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8&auto=format&fit=crop&w=687&q=80'
}
];
// Enhanced profile loading with skeleton effect
function loadProfiles() {
const grid = document.querySelector('.profiles-grid');
// Show skeleton loading
grid.innerHTML = Array(4).fill(`
<div class="profile-card">
<div class="skeleton" style="height: 300px"></div>
<div class="skeleton" style="height: 20px; width: 60%"></div>
<div class="skeleton" style="height: 16px; width: 40%"></div>
</div>
`).join('');
// Simulate loading delay
setTimeout(() => {
grid.innerHTML = profiles.map(profile => `
<div class="profile-card">
${Math.random() > 0.5 ? `<div class="profile-badge">New</div>` : ''}
<img src="${profile.image}" class="profile-img" loading="lazy">
<h3>${profile.name}, ${profile.age}</h3>
<p>${profile.location}</p>
<div class="profile-actions">
<button class="search-btn" onclick="animateLike(this)">
<i class="fas fa-heart"></i> Like
</button>
</div>
</div>
`).join('');
}, 1500);
}
function animateLike(button) {
button.classList.add('liked');
setTimeout(() => button.classList.remove('liked'), 1000);
}
// Modal handling
function showSearchModal() {
document.getElementById('searchModal').style.display = 'flex';
}
function showPostModal() {
document.getElementById('postModal').style.display = 'flex';
}
// Close modal when clicking outside
window.onclick = function(event) {
if (event.target.className === 'modal') {
event.target.style.display = 'none';
}
}
// Initialize
document.addEventListener('DOMContentLoaded', () => {
loadProfiles();
// Add floating animation to logo
const logo = document.querySelector('.logo i');
logo.style.animation = 'float 3s ease-in-out infinite';
});
// Smooth scroll
document.querySelectorAll('a[href^="#"]').forEach(anchor => {
anchor.addEventListener('click', function (e) {
e.preventDefault();
document.querySelector(this.getAttribute('href')).scrollIntoView({
behavior: 'smooth'
});
});
});
</script>
</body>
</html>