diff --git a/Css-files/login1.css b/Css-files/login1.css
index 14133ddd..b12daffb 100644
--- a/Css-files/login1.css
+++ b/Css-files/login1.css
@@ -229,4 +229,20 @@ body * {
width: 90%;
}
}
+.forgot-password {
+ text-align: right;
+ margin-bottom: 15px;
+}
+
+.forgot-password a {
+ color: #3bb77e;
+ text-decoration: none;
+ font-size: 14px;
+ font-weight: 500;
+}
+
+.forgot-password a:hover {
+ text-decoration: underline;
+}
+
diff --git a/Html-files/forget_pass.html b/Html-files/forget_pass.html
new file mode 100644
index 00000000..dede9ad8
--- /dev/null
+++ b/Html-files/forget_pass.html
@@ -0,0 +1,65 @@
+
+
+
+
+
+
+
+
+
+
+
+ Forgot Password
+
+
+
+
+
+
Reset Your Password
Enter your email to reset your password
+
+
+
+
+
+
Forgot Password
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Html-files/login.html b/Html-files/login.html
index 747fd03c..74ccabad 100644
--- a/Html-files/login.html
+++ b/Html-files/login.html
@@ -41,6 +41,9 @@ LOGIN
+
OR
@@ -95,6 +98,40 @@
alert("Form submitted successfully!");
}
}
+ document.querySelector('.forgot-password a').addEventListener('click', function(event) {
+ event.preventDefault();
+ // Implement the functionality here, e.g., open a modal or redirect to a password recovery page
+ alert("Redirecting to password recovery page...");
+ window.location.href = 'forget_pass.html'; // Change this to the actual URL
+});
+
+ // Google Sign-In
+ document.getElementById('google-login').addEventListener('click', () => {
+ const provider = new firebase.auth.GoogleAuthProvider();
+ auth.signInWithPopup(provider)
+ .then((result) => {
+ const user = result.user;
+ // Save user info to Realtime Database if new user
+ if (result.additionalUserInfo.isNewUser) {
+ return database.ref('users/' + user.uid).set({
+ name: user.displayName,
+ email: user.email,
+ username: user.email.split('@')[0]
+ });
+ }
+ })
+ .then(() => {
+ alert('Logged in with Google!');
+ window.location.href = '../index.html'; // Redirect to homepage or dashboard
+ })
+ .catch((error) => {
+ console.error('Error logging in with Google:', error);
+ alert(error.message);
+ });
+ });
+
+