StevenExtraAnalyzer's picture
Initial DeepSite commit
86752df verified
Raw History Blame Contribute Delete
27.5 kB
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Login - BudgetDate</title>
<script src="https://cdn.tailwindcss.com"></script>
<script src="https://unpkg.com/lucide@latest"></script>
<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@300;400;500;600;700&family=Playfair+Display:wght@400;500;600;700&display=swap" rel="stylesheet">
<script>
tailwind.config = {
theme: {
extend: {
fontFamily: {
sans: ['Inter', 'sans-serif'],
serif: ['Playfair Display', 'serif'],
},
colors: {
rose: {
50: '#fff1f2',
100: '#ffe4e6',
400: '#fb7185',
500: '#f43f5e',
600: '#e11d48',
},
warm: {
50: '#fafaf9',
100: '#f5f5f4',
800: '#292524',
900: '#1c1917',
}
}
}
}
}
</script>
<style>
.gradient-bg {
background: linear-gradient(135deg, #fff1f2 0%, #fef3c7 50%, #fff7ed 100%);
}
.glass-effect {
background: rgba(255, 255, 255, 0.95);
backdrop-filter: blur(10px);
}
.tab-active {
border-bottom: 3px solid #e11d48;
color: #e11d48;
}
.tab-inactive {
border-bottom: 3px solid transparent;
color: #78716c;
}
.tab-inactive:hover {
color: #e11d48;
}
</style>
</head>
<body class="font-sans text-warm-800 gradient-bg min-h-screen flex flex-col">
<!-- Navigation -->
<nav class="w-full glass-effect border-b border-rose-100">
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
<div class="flex justify-between items-center h-20">
<a href="index.html" class="flex items-center gap-2">
<i data-lucide="heart" class="w-8 h-8 text-rose-500"></i>
<span class="font-serif text-2xl font-bold text-warm-900">BudgetDate</span>
</a>
<a href="index.html" class="flex items-center gap-2 text-warm-600 hover:text-rose-600 transition-colors">
<i data-lucide="arrow-left" class="w-4 h-4"></i>
<span>Back to Home</span>
</a>
</div>
</div>
</nav>
<!-- Main Content -->
<main class="flex-grow flex items-center justify-center py-12 px-4 sm:px-6 lg:px-8">
<div class="max-w-md w-full">
<!-- Plan Badge (if coming from pricing) -->
<div id="planBadge" class="hidden mb-6 text-center">
<div class="inline-flex items-center gap-2 bg-rose-100 text-rose-700 px-4 py-2 rounded-full text-sm font-medium">
<i data-lucide="crown" class="w-4 h-4"></i>
<span id="planText">Joining Date Club</span>
</div>
</div>
<!-- Auth Container -->
<div class="bg-white rounded-3xl shadow-2xl overflow-hidden">
<!-- Tabs -->
<div class="flex border-b border-warm-100">
<button id="loginTab" onclick="switchTab('login')" class="flex-1 py-4 text-center font-semibold text-lg tab-active transition-colors">
Login
</button>
<button id="registerTab" onclick="switchTab('register')" class="flex-1 py-4 text-center font-semibold text-lg tab-inactive transition-colors">
Register
</button>
</div>
<!-- Login Form -->
<div id="loginForm" class="p-8">
<div class="text-center mb-8">
<h2 class="font-serif text-2xl font-bold text-warm-900 mb-2">Welcome Back</h2>
<p class="text-warm-600 text-sm">Sign in to access your saved dates and bookings</p>
</div>
<form class="space-y-5" onsubmit="handleLogin(event)">
<div>
<label class="block text-sm font-medium text-warm-700 mb-1">Email Address</label>
<div class="relative">
<i data-lucide="mail" class="w-5 h-5 text-warm-400 absolute left-3 top-1/2 transform -translate-y-1/2"></i>
<input type="email" required class="w-full pl-10 pr-4 py-3 rounded-xl border border-warm-200 focus:border-rose-500 focus:ring-2 focus:ring-rose-200 outline-none transition-all" placeholder="you@example.com">
</div>
</div>
<div>
<label class="block text-sm font-medium text-warm-700 mb-1">Password</label>
<div class="relative">
<i data-lucide="lock" class="w-5 h-5 text-warm-400 absolute left-3 top-1/2 transform -translate-y-1/2"></i>
<input type="password" required class="w-full pl-10 pr-4 py-3 rounded-xl border border-warm-200 focus:border-rose-500 focus:ring-2 focus:ring-rose-200 outline-none transition-all" placeholder="••••••••">
</div>
</div>
<div class="flex items-center justify-between text-sm">
<label class="flex items-center gap-2 cursor-pointer">
<input type="checkbox" class="rounded border-warm-300 text-rose-600 focus:ring-rose-500">
<span class="text-warm-600">Remember me</span>
</label>
<a href="#" class="text-rose-600 hover:text-rose-700 font-medium">Forgot password?</a>
</div>
<button type="submit" class="w-full bg-rose-600 text-white py-3 rounded-xl font-semibold hover:bg-rose-700 transition-all transform hover:scale-[1.02] shadow-lg shadow-rose-200 flex items-center justify-center gap-2">
<span>Sign In</span>
<i data-lucide="arrow-right" class="w-4 h-4"></i>
</button>
</form>
<!-- Social Login -->
<div class="mt-8">
<div class="relative">
<div class="absolute inset-0 flex items-center">
<div class="w-full border-t border-warm-200"></div>
</div>
<div class="relative flex justify-center text-sm">
<span class="px-2 bg-white text-warm-500">Or continue with</span>
</div>
</div>
<div class="mt-6 grid grid-cols-3 gap-3">
<!-- Google Sign In -->
<button onclick="handleGoogleLogin()" class="flex items-center justify-center gap-2 px-3 py-3 border border-warm-200 rounded-xl hover:bg-warm-50 transition-colors hover:border-red-300">
<svg class="w-5 h-5" viewBox="0 0 24 24">
<path fill="#4285F4" d="M22.56 12.25c0-.78-.07-1.53-.2-2.25H12v4.26h5.92c-.26 1.37-1.04 2.53-2.21 3.31v2.77h3.57c2.08-1.92 3.28-4.74 3.28-8.09z"/>
<path fill="#34A853" d="M12 23c2.97 0 5.46-.98 7.28-2.66l-3.57-2.77c-.98.66-2.23 1.06-3.71 1.06-2.86 0-5.29-1.93-6.16-4.53H2.18v2.84C3.99 20.53 7.7 23 12 23z"/>
<path fill="#FBBC05" d="M5.84 14.09c-.22-.66-.35-1.36-.35-2.09s.13-1.43.35-2.09V7.07H2.18C1.43 8.55 1 10.22 1 12s.43 3.45 1.18 4.93l2.85-2.22.81-.62z"/>
<path fill="#EA4335" d="M12 5.38c1.62 0 3.06.56 4.21 1.64l3.15-3.15C17.45 2.09 14.97 1 12 1 7.7 1 3.99 3.47 2.18 7.07l3.66 2.84c.87-2.6 3.3-4.53 6.16-4.53z"/>
</svg>
<span class="text-sm font-medium">Google</span>
</button>
<!-- Facebook Login -->
<button onclick="handleFacebookLogin()" class="flex items-center justify-center gap-2 px-3 py-3 border border-warm-200 rounded-xl hover:bg-warm-50 transition-colors hover:border-blue-300">
<svg class="w-5 h-5 text-blue-600" fill="currentColor" viewBox="0 0 24 24">
<path d="M24 12.073c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.99 4.388 10.954 10.125 11.854v-8.385H7.078v-3.47h3.047V9.43c0-3.007 1.792-4.669 4.533-4.669 1.312 0 2.686.235 2.686.235v2.953H15.83c-1.491 0-1.956.925-1.956 1.874v2.25h3.328l-.532 3.47h-2.796v8.385C19.612 23.027 24 18.062 24 12.073z"/>
</svg>
<span class="text-sm font-medium">Facebook</span>
</button>
<!-- WhatsApp -->
<button onclick="handleWhatsAppLogin()" class="flex items-center justify-center gap-2 px-3 py-3 border border-warm-200 rounded-xl hover:bg-warm-50 transition-colors hover:border-green-300">
<svg class="w-5 h-5 text-green-500" fill="currentColor" viewBox="0 0 24 24">
<path d="M17.472 14.382c-.297-.149-1.758-.867-2.03-.967-.273-.099-.471-.148-.67.15-.197.297-.767.966-.94 1.164-.173.199-.347.223-.644.075-.297-.15-1.255-.463-2.39-1.475-.883-.788-1.48-1.761-1.653-2.059-.173-.297-.018-.458.13-.606.134-.133.298-.347.446-.52.149-.174.198-.298.298-.497.099-.198.05-.371-.025-.52-.075-.149-.669-1.612-.916-2.207-.242-.579-.487-.5-.669-.51-.173-.008-.371-.01-.57-.01-.198 0-.52.074-.792.372-.272.298-1.04 1.016-1.04 2.479 0 1.462 1.065 2.875 1.213 3.074.149.198 2.096 3.2 5.077 4.487.709.306 1.262.489 1.694.625.712.227 1.36.195 1.871.118.571-.085 1.758-.719 2.006-1.413.248-.694.248-1.289.173-1.413-.074-.124-.272-.198-.57-.347m-5.421 7.403h-.004a9.87 9.87 0 01-5.031-1.378l-.361-.214-3.741.982.998-3.648-.235-.374a9.86 9.86 0 01-1.51-5.26c.001-5.45 4.436-9.884 9.888-9.884 2.64 0 5.122 1.03 6.988 2.898a9.825 9.825 0 012.893 6.994c-.003 5.45-4.437 9.884-9.885 9.884m8.413-18.297A11.815 11.815 0 0012.05 0C5.495 0 .16 5.335.157 11.892c0 2.096.547 4.142 1.588 5.945L.057 24l6.305-1.654a11.882 11.882 0 005.683 1.448h.005c6.554 0 11.89-5.335 11.893-11.893a11.821 11.821 0 00-3.48-8.413z"/>
</svg>
<span class="text-sm font-medium">WhatsApp</span>
</button>
</div>
</div>
</div>
<!-- Register Form -->
<div id="registerForm" class="p-8 hidden">
<div class="text-center mb-8">
<h2 class="font-serif text-2xl font-bold text-warm-900 mb-2">Create Account</h2>
<p class="text-warm-600 text-sm">Join thousands of happy couples</p>
</div>
<form class="space-y-4" onsubmit="handleRegister(event)">
<div class="grid grid-cols-2 gap-4">
<div>
<label class="block text-sm font-medium text-warm-700 mb-1">First Name</label>
<input type="text" required class="w-full px-4 py-3 rounded-xl border border-warm-200 focus:border-rose-500 focus:ring-2 focus:ring-rose-200 outline-none transition-all" placeholder="John">
</div>
<div>
<label class="block text-sm font-medium text-warm-700 mb-1">Last Name</label>
<input type="text" required class="w-full px-4 py-3 rounded-xl border border-warm-200 focus:border-rose-500 focus:ring-2 focus:ring-rose-200 outline-none transition-all" placeholder="Doe">
</div>
</div>
<div>
<label class="block text-sm font-medium text-warm-700 mb-1">Email Address</label>
<div class="relative">
<i data-lucide="mail" class="w-5 h-5 text-warm-400 absolute left-3 top-1/2 transform -translate-y-1/2"></i>
<input type="email" required class="w-full pl-10 pr-4 py-3 rounded-xl border border-warm-200 focus:border-rose-500 focus:ring-2 focus:ring-rose-200 outline-none transition-all" placeholder="you@example.com">
</div>
</div>
<div>
<label class="block text-sm font-medium text-warm-700 mb-1">Phone Number</label>
<div class="relative">
<i data-lucide="smartphone" class="w-5 h-5 text-warm-400 absolute left-3 top-1/2 transform -translate-y-1/2"></i>
<input type="tel" required class="w-full pl-10 pr-4 py-3 rounded-xl border border-warm-200 focus:border-rose-500 focus:ring-2 focus:ring-rose-200 outline-none transition-all" placeholder="07XX XXX XXX">
</div>
</div>
<div>
<label class="block text-sm font-medium text-warm-700 mb-1">Password</label>
<div class="relative">
<i data-lucide="lock" class="w-5 h-5 text-warm-400 absolute left-3 top-1/2 transform -translate-y-1/2"></i>
<input type="password" required minlength="6" class="w-full pl-10 pr-4 py-3 rounded-xl border border-warm-200 focus:border-rose-500 focus:ring-2 focus:ring-rose-200 outline-none transition-all" placeholder="••••••••">
</div>
<p class="text-xs text-warm-500 mt-1">Must be at least 6 characters</p>
</div>
<div>
<label class="flex items-start gap-2 cursor-pointer">
<input type="checkbox" required class="mt-1 rounded border-warm-300 text-rose-600 focus:ring-rose-500">
<span class="text-sm text-warm-600">I agree to the <a href="#" class="text-rose-600 hover:underline">Terms of Service</a> and <a href="#" class="text-rose-600 hover:underline">Privacy Policy</a></span>
</label>
</div>
<button type="submit" class="w-full bg-rose-600 text-white py-3 rounded-xl font-semibold hover:bg-rose-700 transition-all transform hover:scale-[1.02] shadow-lg shadow-rose-200 flex items-center justify-center gap-2">
<span>Create Account</span>
<i data-lucide="user-plus" class="w-4 h-4"></i>
</button>
</form>
<p class="mt-6 text-center text-sm text-warm-600">
Already have an account?
<button onclick="switchTab('login')" class="text-rose-600 font-semibold hover:underline">Sign in</button>
</p>
</div>
</div>
<!-- Trust Badges -->
<div class="mt-8 flex items-center justify-center gap-6 text-warm-500 text-sm">
<div class="flex items-center gap-2">
<i data-lucide="shield-check" class="w-4 h-4 text-green-500"></i>
<span>Secure</span>
</div>
<div class="flex items-center gap-2">
<i data-lucide="lock" class="w-4 h-4 text-green-500"></i>
<span>Encrypted</span>
</div>
<div class="flex items-center gap-2">
<i data-lucide="heart" class="w-4 h-4 text-rose-500"></i>
<span>Trusted by 2,000+</span>
</div>
</div>
</div>
</main>
<!-- Google Sign-In API -->
<script src="https://accounts.google.com/gsi/client" async defer></script>
<!-- Facebook SDK -->
<script>
window.fbAsyncInit = function() {
FB.init({
appId : 'YOUR_FACEBOOK_APP_ID', // Replace with your Facebook App ID
cookie : true,
xfbml : true,
version : 'v18.0'
});
};
(function(d, s, id){
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) {return;}
js = d.createElement(s); js.id = id;
js.src = "https://connect.facebook.net/en_US/sdk.js";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));
</script>
<script>
// Initialize Lucide icons
lucide.createIcons();
// Check URL parameters for tab and plan
window.addEventListener('DOMContentLoaded', () => {
const urlParams = new URLSearchParams(window.location.search);
const action = urlParams.get('action');
const plan = urlParams.get('plan');
// Show plan badge if coming from pricing
if (plan) {
const planBadge = document.getElementById('planBadge');
const planText = document.getElementById('planText');
planBadge.classList.remove('hidden');
if (plan === 'premium') {
planText.textContent = 'Joining Date Club';
} else if (plan === 'ultimate') {
planText.textContent = 'Joining Ultimate Romance';
}
}
// Switch to register tab if specified
if (action === 'register') {
switchTab('register');
}
// Initialize Google Sign-In
initializeGoogleSignIn();
});
// Google Sign-In Handler
function initializeGoogleSignIn() {
if (typeof google !== 'undefined') {
google.accounts.id.initialize({
client_id: 'YOUR_GOOGLE_CLIENT_ID', // Replace with your Google Client ID
callback: handleGoogleCredentialResponse,
auto_select: false,
cancel_on_tap_outside: true
});
}
}
function handleGoogleCredentialResponse(response) {
// Decode the JWT token to get user info
const credential = response.credential;
const payload = JSON.parse(atob(credential.split('.')[1]));
console.log('Google User:', payload);
// Show success message
showSocialSuccess('Google', payload.name, payload.email);
}
function handleGoogleLogin() {
if (typeof google !== 'undefined' && google.accounts.id) {
google.accounts.id.prompt((notification) => {
if (notification.isNotDisplayed() || notification.isSkippedMoment()) {
// Fall back to popup if prompt is not displayed
google.accounts.id.renderButton(
document.createElement('div'),
{ theme: 'outline', size: 'large' }
);
}
});
} else {
// Fallback: Show coming soon message or redirect
showSocialLoginMessage('Google');
}
}
// Facebook Login Handler
function handleFacebookLogin() {
if (typeof FB !== 'undefined') {
FB.login(function(response) {
if (response.authResponse) {
FB.api('/me', {fields: 'name,email,picture'}, function(userInfo) {
console.log('Facebook User:', userInfo);
showSocialSuccess('Facebook', userInfo.name, userInfo.email);
});
} else {
console.log('User cancelled login or did not fully authorize.');
}
}, {scope: 'public_profile,email'});
} else {
showSocialLoginMessage('Facebook');
}
}
// WhatsApp Login Handler
function handleWhatsAppLogin() {
// WhatsApp doesn't have a traditional OAuth flow, so we'll open WhatsApp with a pre-filled message
const phoneNumber = '254712345678'; // Replace with your business WhatsApp number
const message = 'Hi! I would like to create an account with BudgetDate via WhatsApp.';
const whatsappUrl = `https://wa.me/${phoneNumber}?text=${encodeURIComponent(message)}`;
window.open(whatsappUrl, '_blank');
}
// Helper function to show social login success
function showSocialSuccess(provider, name, email) {
const loginForm = document.getElementById('loginForm');
const registerForm = document.getElementById('registerForm');
// Hide both forms
loginForm.classList.add('hidden');
registerForm.classList.add('hidden');
// Show success message
const container = loginForm.parentElement;
const successDiv = document.createElement('div');
successDiv.className = 'p-8 text-center';
successDiv.innerHTML = `
<div class="w-16 h-16 bg-green-100 rounded-full flex items-center justify-center mx-auto mb-4">
<i data-lucide="check" class="w-8 h-8 text-green-600"></i>
</div>
<h3 class="font-serif text-2xl font-bold text-warm-900 mb-2">Welcome!</h3>
<p class="text-warm-600 mb-4">Successfully signed in with ${provider}</p>
<div class="bg-warm-50 rounded-xl p-4 mb-6">
<p class="font-semibold text-warm-900">${name}</p>
<p class="text-sm text-warm-600">${email}</p>
</div>
<button onclick="window.location.href='index.html'" class="w-full bg-rose-600 text-white py-3 rounded-xl font-semibold hover:bg-rose-700 transition-colors">
Continue to Dashboard
</button>
`;
container.appendChild(successDiv);
lucide.createIcons();
}
// Helper function for missing credentials
function showSocialLoginMessage(provider) {
alert(`${provider} Sign-In is coming soon! Please use email registration for now.`);
}
// Tab switching
function switchTab(tab) {
const loginTab = document.getElementById('loginTab');
const registerTab = document.getElementById('registerTab');
const loginForm = document.getElementById('loginForm');
const registerForm = document.getElementById('registerForm');
if (tab === 'login') {
loginTab.classList.add('tab-active');
loginTab.classList.remove('tab-inactive');
registerTab.classList.add('tab-inactive');
registerTab.classList.remove('tab-active');
loginForm.classList.remove('hidden');
registerForm.classList.add('hidden');
} else {
registerTab.classList.add('tab-active');
registerTab.classList.remove('tab-inactive');
loginTab.classList.add('tab-inactive');
loginTab.classList.remove('tab-active');
registerForm.classList.remove('hidden');
loginForm.classList.add('hidden');
}
}
// Handle Login
function handleLogin(event) {
event.preventDefault();
// Show loading state
const button = event.target.querySelector('button[type="submit"]');
const originalText = button.innerHTML;
button.innerHTML = '<i data-lucide="loader-2" class="w-4 h-4 animate-spin"></i> Signing in...';
button.disabled = true;
lucide.createIcons();
// Simulate API call
setTimeout(() => {
// Show success message
event.target.innerHTML = `
<div class="text-center py-4">
<div class="w-16 h-16 bg-green-100 rounded-full flex items-center justify-center mx-auto mb-4">
<i data-lucide="check" class="w-8 h-8 text-green-600"></i>
</div>
<h3 class="font-serif text-xl font-bold text-warm-900 mb-2">Welcome Back!</h3>
<p class="text-warm-600">Redirecting to your dashboard...</p>
</div>
`;
lucide.createIcons();
// Redirect to home after delay
setTimeout(() => {
window.location.href = 'index.html';
}, 1500);
}, 1500);
}
// Handle Register
function handleRegister(event) {
event.preventDefault();
// Show loading state
const button = event.target.querySelector('button[type="submit"]');
const originalText = button.innerHTML;
button.innerHTML = '<i data-lucide="loader-2" class="w-4 h-4 animate-spin"></i> Creating account...';
button.disabled = true;
lucide.createIcons();
// Simulate API call
setTimeout(() => {
// Show success message
event.target.innerHTML = `
<div class="text-center py-4">
<div class="w-16 h-16 bg-green-100 rounded-full flex items-center justify-center mx-auto mb-4">
<i data-lucide="check" class="w-8 h-8 text-green-600"></i>
</div>
<h3 class="font-serif text-xl font-bold text-warm-900 mb-2">Account Created!</h3>
<p class="text-warm-600">Welcome to BudgetDate. Redirecting...</p>
</div>
`;
lucide.createIcons();
// Redirect to home after delay
setTimeout(() => {
window.location.href = 'index.html';
}, 1500);
}, 1500);
}
</script>
</body>
</html>