-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
230 lines (199 loc) · 11.9 KB
/
index.html
File metadata and controls
230 lines (199 loc) · 11.9 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Friendship Zone</title>
<link rel="stylesheet" href="style.css" />
<!-- Poppins Font -->
<link href="https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap" rel="stylesheet" />
<!-- Tailwind CSS CDN -->
<script src="https://cdn.tailwindcss.com"></script>
</head>
<body>
<!-- Navbar -->
<nav class="bg-white shadow-md sticky top-0 z-50">
<div class="max-w-7xl mx-auto px-4 py-3 flex items-center justify-between">
<!-- Brand -->
<div class="text-2xl font-bold text-blue-600">Friendship Zone</div>
<!-- Desktop Menu -->
<div class="space-x-6 text-gray-700 font-medium hidden md:flex">
<button onclick="showPage('homepage')" class="hover:text-blue-600 transition">Home</button>
<button onclick="showPage('friendList')" class="hover:text-blue-600 transition">Friend List</button>
<button onclick="showPage('registrationForm')" class="hover:text-blue-600 transition">Register</button>
</div>
<!-- Mobile Menu Button -->
<div class="md:hidden">
<button id="menuToggle" class="text-gray-700 hover:text-blue-600 focus:outline-none">
<svg class="h-6 w-6" fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
d="M4 6h16M4 12h16M4 18h16" />
</svg>
</button>
</div>
</div>
<!-- Mobile Menu Links -->
<div id="mobileMenu" class="md:hidden hidden px-4 pb-4 space-y-2">
<button onclick="showPage('homepage'); toggleMobileMenu()" class="block w-full text-left text-gray-700 hover:text-blue-600">Home</button>
<button onclick="showPage('friendList'); toggleMobileMenu()" class="block w-full text-left text-gray-700 hover:text-blue-600">Friend List</button>
<button onclick="showPage('registrationForm'); toggleMobileMenu()" class="block w-full text-left text-gray-700 hover:text-blue-600">Register</button>
</div>
</nav>
<!-- Homepage -->
<div id="homepage" class="page active-page">
<div class="container mx-auto px-4 py-12">
<div class="text-center mb-12">
<h1 class="text-5xl font-bold text-blue-600 mb-4">Welcome to Friendship Zone</h1>
<p class="text-xl text-gray-600 max-w-2xl mx-auto">Connect with friends, share interests, and build meaningful relationships in our friendly community.</p>
</div>
<div class="flex justify-center mb-20">
<div class="w-full max-w-6xl">
<svg viewBox="0 0 1200 600" xmlns="http://www.w3.org/2000/svg" class="w-full h-auto">
<!-- Background -->
<rect width="1200" height="600" fill="#f0f9ff" rx="30" ry="30" />
<!-- Abstract background circles -->
<circle cx="150" cy="120" r="90" fill="#dbeafe" opacity="0.5"/>
<circle cx="1050" cy="460" r="100" fill="#dbeafe" opacity="0.5"/>
<circle cx="1100" cy="140" r="60" fill="#dbeafe" opacity="0.4"/>
<!-- Person 1 -->
<circle cx="320" cy="330" r="90" fill="#3b82f6"/>
<circle cx="320" cy="230" r="60" fill="#93c5fd"/>
<path d="M290 215 Q320 185 350 215" stroke="#1e3a8a" stroke-width="4" fill="none"/>
<circle cx="300" cy="210" r="7" fill="#1e3a8a"/>
<circle cx="340" cy="210" r="7" fill="#1e3a8a"/>
<!-- Person 2 -->
<circle cx="600" cy="330" r="90" fill="#6366f1"/>
<circle cx="600" cy="230" r="60" fill="#c7d2fe"/>
<path d="M570 215 Q600 185 630 215" stroke="#3730a3" stroke-width="4" fill="none"/>
<circle cx="580" cy="210" r="7" fill="#3730a3"/>
<circle cx="620" cy="210" r="7" fill="#3730a3"/>
<!-- Person 3 -->
<circle cx="880" cy="330" r="90" fill="#10b981"/>
<circle cx="880" cy="230" r="60" fill="#a7f3d0"/>
<path d="M850 215 Q880 185 910 215" stroke="#065f46" stroke-width="4" fill="none"/>
<circle cx="860" cy="210" r="7" fill="#065f46"/>
<circle cx="900" cy="210" r="7" fill="#065f46"/>
<!-- Connection lines -->
<line x1="410" y1="330" x2="510" y2="330" stroke="#60a5fa" stroke-width="6"/>
<line x1="690" y1="330" x2="790" y2="330" stroke="#60a5fa" stroke-width="6"/>
</svg>
</div>
</div>
</div>
<div class="flex flex-col md:flex-row gap-8 justify-center mb-12">
<div class="bg-white rounded-xl shadow-lg p-6 flex-1 max-w-md card">
<div class="text-blue-500 text-4xl mb-4">👥</div>
<h3 class="text-xl font-semibold mb-2">Find Friends</h3>
<p class="text-gray-600">Discover people with similar interests and connect with them in our friendly community.</p>
<button onclick="showPage('friendList')" class="mt-4 bg-blue-500 hover:bg-blue-600 text-white px-6 py-2 rounded-lg btn-primary">Browse Friends</button>
</div>
<div class="bg-white rounded-xl shadow-lg p-6 flex-1 max-w-md card">
<div class="text-blue-500 text-4xl mb-4">✏️</div>
<h3 class="text-xl font-semibold mb-2">Join Us</h3>
<p class="text-gray-600">Become a member of our growing community by registering your profile today.</p>
<button onclick="showPage('registrationForm')" class="mt-4 bg-blue-500 hover:bg-blue-600 text-white px-6 py-2 rounded-lg btn-primary">Register Now</button>
</div>
</div>
</div>
</div>
<!-- Friend List -->
<div id="friendList" class="page">
<div class="container mx-auto px-4 py-12">
<h1 class="text-4xl font-bold text-blue-600 mb-8 text-center">Friend List</h1>
<div class="mb-8">
<div class="max-w-md mx-auto">
<div class="relative">
<input type="text" id="searchInput" placeholder="Search by name or interest..."
class="w-full px-4 py-3 rounded-lg border border-gray-300 focus:outline-none form-input"
oninput="filterFriends()">
<div class="absolute right-3 top-3 text-gray-400">
<svg xmlns="http://www.w3.org/2000/svg" class="h-6 w-6" fill="none" viewBox="0 0 24 24" stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z" />
</svg>
</div>
</div>
</div>
</div>
<div id="friendsContainer" class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6">
<!-- Friends will be dynamically loaded here -->
</div>
<div id="noResults" class="hidden text-center py-12">
<div class="text-4xl mb-4">🔍</div>
<h3 class="text-xl font-medium text-gray-700">No friends found</h3>
<p class="text-gray-500 mt-2">Try a different search term</p>
</div>
</div>
</div>
<!-- Registration Form -->
<div id="registrationForm" class="page">
<div class="container mx-auto px-4 py-12">
<div class="max-w-2xl mx-auto bg-white rounded-xl shadow-lg p-8">
<h1 class="text-3xl font-bold text-blue-600 mb-6 text-center">Join Friendship Zone</h1>
<form id="registerForm" class="space-y-6" onsubmit="handleRegistration(event)">
<div>
<label for="name" class="block text-gray-700 font-medium mb-2">Full Name</label>
<input type="text" id="name" name="name" class="w-full px-4 py-3 rounded-lg border border-gray-300 focus:outline-none form-input" required>
<div id="nameError" class="text-red-500 text-sm mt-1 hidden">Please enter your name</div>
</div>
<div>
<label for="age" class="block text-gray-700 font-medium mb-2">Age</label>
<input type="number" id="age" name="age" min="13" max="120" class="w-full px-4 py-3 rounded-lg border border-gray-300 focus:outline-none form-input" required>
<div id="ageError" class="text-red-500 text-sm mt-1 hidden">Please enter a valid age (13-120)</div>
</div>
<div>
<label for="email" class="block text-gray-700 font-medium mb-2">Email Address</label>
<input type="email" id="email" name="email" class="w-full px-4 py-3 rounded-lg border border-gray-300 focus:outline-none form-input" required>
<div id="emailError" class="text-red-500 text-sm mt-1 hidden">Please enter a valid email address</div>
</div>
<div>
<label for="gender" class="block text-gray-700 font-medium mb-2">Gender</label>
<select id="gender" name="gender" class="w-full px-4 py-3 rounded-lg border border-gray-300 focus:outline-none form-input" required>
<option value="" disabled selected>Select your gender</option>
<option value="male">Male</option>
<option value="female">Female</option>
<option value="non-binary">Non-binary</option>
<option value="prefer-not-to-say">Prefer not to say</option>
</select>
<div id="genderError" class="text-red-500 text-sm mt-1 hidden">Please select your gender</div>
</div>
<div>
<label for="interests" class="block text-gray-700 font-medium mb-2">Interests</label>
<textarea id="interests" name="interests" rows="4" class="w-full px-4 py-3 rounded-lg border border-gray-300 focus:outline-none form-input" placeholder="Tell us about your interests..." required></textarea>
<div id="interestsError" class="text-red-500 text-sm mt-1 hidden">Please share some of your interests</div>
</div>
<div class="pt-4">
<button type="submit" class="w-full bg-blue-500 hover:bg-blue-600 text-white font-medium py-3 rounded-lg transition-all btn-primary">Register</button>
</div>
</form>
</div>
</div>
</div>
<!-- Registration Confirmation -->
<div id="registrationConfirmation" class="page">
<div class="container mx-auto px-4 py-12">
<div class="max-w-xl mx-auto bg-white rounded-xl shadow-lg p-8 text-center">
<div class="text-green-500 text-6xl mb-6">✅</div>
<h1 class="text-3xl font-bold text-gray-800 mb-4">Thank you for joining Friendship Zone!</h1>
<p class="text-gray-600 mb-8">Your registration was successful. We're excited to have you as part of our community!</p>
<div class="flex flex-col sm:flex-row gap-4 justify-center">
<button onclick="showPage('homepage')" class="bg-blue-500 hover:bg-blue-600 text-white px-6 py-3 rounded-lg btn-primary">Back to Homepage</button>
<button onclick="showPage('friendList')" class="bg-blue-100 hover:bg-blue-200 text-blue-700 px-6 py-3 rounded-lg btn-primary">View Friend List</button>
</div>
</div>
</div>
</div>
<!-- Admin Registration Confirmation -->
<div id="registrationConfirmationAdmin" class="page">
<div class="container mx-auto px-4 py-12">
<div class="max-w-xl mx-auto bg-white rounded-xl shadow-lg p-8 text-center">
<div class="text-blue-500 text-6xl mb-6">👑</div>
<h1 class="text-3xl font-bold text-gray-800 mb-4">Admin successfully registered.</h1>
<p class="text-gray-600 mb-8">Welcome to the admin panel. You now have access to all administrative features.</p>
<button onclick="showPage('homepage')" class="bg-blue-500 hover:bg-blue-600 text-white px-6 py-3 rounded-lg btn-primary">Back to Homepage</button>
</div>
</div>
</div>
<!-- Custom JS -->
<script src="script.js" defer></script>
</body>
</html>