100+ copy-paste UI components in plain HTML and CSS: no dependencies, no build step.

0 downloads

dbbasic-web-native/demo-auth-complete.html
Download zip
Clone
Clone with git
git clone https://gitstable.com/git/askrobots/dbbasic-web-native.git
HTTPS
https://gitstable.com/git/askrobots/dbbasic-web-native.git
SSH
ssh://git@gitstable.com:2222/askrobots/dbbasic-web-native.git

Cloning needs no sign-in. Pushing over HTTPS asks for your username and an access token. SSH needs your key under SSH keys.

danq9 Add canonical.html v1.0 - The single source of truth for usability standards fb6e650 1 year ago History
demo-auth-complete.html · 20.2 KB · 627 lines
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>Authentication Pages - Complete Collection</title>
7 <style>
8 * {
9 margin: 0;
10 padding: 0;
11 box-sizing: border-box;
12 }
13
14 @import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');
15
16 body {
17 font-family: 'Inter', sans-serif;
18 -webkit-font-smoothing: antialiased;
19 -moz-osx-font-smoothing: grayscale;
20 background: #f9fafb;
21 color: #1a1a1a;
22 }
23
24 .section-divider {
25 background: linear-gradient(to right, #f8f9fa, #ffffff);
26 padding: 20px 48px;
27 border-bottom: 1px solid #e5e7eb;
28 font-size: 11px;
29 font-weight: 600;
30 color: #6b7280;
31 text-transform: uppercase;
32 letter-spacing: 1.5px;
33 position: sticky;
34 top: 0;
35 z-index: 100;
36 backdrop-filter: blur(10px);
37 }
38
39 /* ========== AUTH LAYOUT ========== */
40 .auth-layout {
41 min-height: 100vh;
42 display: grid;
43 grid-template-columns: 1fr 1fr;
44 background: white;
45 }
46
47 .auth-left {
48 background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
49 padding: 80px;
50 display: flex;
51 flex-direction: column;
52 justify-content: center;
53 align-items: center;
54 color: white;
55 position: relative;
56 overflow: hidden;
57 }
58
59 .auth-left::before {
60 content: '';
61 position: absolute;
62 inset: 0;
63 background-image:
64 url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.06'/%3E%3C/svg%3E");
65 pointer-events: none;
66 }
67
68 .auth-left-content {
69 position: relative;
70 z-index: 1;
71 text-align: center;
72 max-width: 500px;
73 }
74
75 .auth-left h1 {
76 font-size: 48px;
77 font-weight: 900;
78 margin-bottom: 24px;
79 line-height: 1.1;
80 }
81
82 .auth-left p {
83 font-size: 18px;
84 line-height: 1.7;
85 opacity: 0.95;
86 }
87
88 .auth-illustration {
89 font-size: 120px;
90 margin-bottom: 40px;
91 }
92
93 .auth-right {
94 padding: 80px;
95 display: flex;
96 flex-direction: column;
97 justify-content: center;
98 }
99
100 .auth-form-container {
101 max-width: 450px;
102 width: 100%;
103 margin: 0 auto;
104 }
105
106 .logo {
107 font-size: 32px;
108 font-weight: 800;
109 background: linear-gradient(135deg, #7C3AED, #DB2777);
110 -webkit-background-clip: text;
111 -webkit-text-fill-color: transparent;
112 margin-bottom: 48px;
113 }
114
115 .auth-header {
116 margin-bottom: 40px;
117 }
118
119 .auth-header h2 {
120 font-size: 32px;
121 font-weight: 800;
122 color: #111827;
123 margin-bottom: 12px;
124 }
125
126 .auth-header p {
127 font-size: 16px;
128 color: #6b7280;
129 }
130
131 .form-group {
132 margin-bottom: 24px;
133 }
134
135 .form-label {
136 display: block;
137 font-size: 14px;
138 font-weight: 600;
139 color: #374151;
140 margin-bottom: 8px;
141 }
142
143 .form-input {
144 width: 100%;
145 padding: 14px 16px;
146 border: 2px solid #e5e7eb;
147 border-radius: 10px;
148 font-size: 16px;
149 transition: all 0.2s;
150 }
151
152 .form-input:focus {
153 outline: none;
154 border-color: #7C3AED;
155 box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.1);
156 }
157
158 .form-checkbox {
159 display: flex;
160 align-items: center;
161 gap: 8px;
162 }
163
164 .form-checkbox input {
165 width: 18px;
166 height: 18px;
167 cursor: pointer;
168 }
169
170 .form-checkbox label {
171 font-size: 14px;
172 color: #374151;
173 cursor: pointer;
174 }
175
176 .btn {
177 padding: 16px 32px;
178 border-radius: 10px;
179 font-weight: 600;
180 font-size: 16px;
181 cursor: pointer;
182 transition: all 0.3s;
183 border: none;
184 text-decoration: none;
185 width: 100%;
186 }
187
188 .btn-primary {
189 background: linear-gradient(135deg, #7C3AED, #DB2777);
190 color: white;
191 }
192
193 .btn-primary:hover {
194 transform: translateY(-2px);
195 box-shadow: 0 10px 30px rgba(124, 58, 237, 0.3);
196 }
197
198 .btn-social {
199 background: white;
200 color: #374151;
201 border: 2px solid #e5e7eb;
202 display: flex;
203 align-items: center;
204 justify-content: center;
205 gap: 12px;
206 margin-bottom: 12px;
207 }
208
209 .btn-social:hover {
210 border-color: #7C3AED;
211 background: #faf5ff;
212 }
213
214 .divider {
215 display: flex;
216 align-items: center;
217 gap: 16px;
218 margin: 32px 0;
219 }
220
221 .divider-line {
222 flex: 1;
223 height: 1px;
224 background: #e5e7eb;
225 }
226
227 .divider-text {
228 font-size: 14px;
229 color: #6b7280;
230 font-weight: 500;
231 }
232
233 .auth-footer {
234 text-align: center;
235 margin-top: 32px;
236 font-size: 14px;
237 color: #6b7280;
238 }
239
240 .auth-footer a {
241 color: #7C3AED;
242 text-decoration: none;
243 font-weight: 600;
244 }
245
246 .auth-footer a:hover {
247 text-decoration: underline;
248 }
249
250 /* ========== CENTERED AUTH LAYOUT ========== */
251 .auth-centered {
252 min-height: 100vh;
253 display: flex;
254 align-items: center;
255 justify-content: center;
256 background:
257 radial-gradient(at 20% 30%, rgba(99, 102, 241, 0.15) 0%, transparent 50%),
258 radial-gradient(at 80% 70%, rgba(168, 85, 247, 0.15) 0%, transparent 50%),
259 #f9fafb;
260 padding: 40px 24px;
261 }
262
263 .auth-card {
264 background: white;
265 border-radius: 20px;
266 padding: 48px;
267 max-width: 450px;
268 width: 100%;
269 box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
270 border: 1px solid #e5e7eb;
271 }
272
273 /* ========== 2FA CODE INPUT ========== */
274 .code-inputs {
275 display: flex;
276 gap: 12px;
277 justify-content: center;
278 margin: 32px 0;
279 }
280
281 .code-input {
282 width: 56px;
283 height: 56px;
284 text-align: center;
285 font-size: 24px;
286 font-weight: 700;
287 border: 2px solid #e5e7eb;
288 border-radius: 10px;
289 transition: all 0.2s;
290 }
291
292 .code-input:focus {
293 outline: none;
294 border-color: #7C3AED;
295 box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.1);
296 }
297
298 /* ========== SUCCESS STATE ========== */
299 .success-icon {
300 width: 80px;
301 height: 80px;
302 background: linear-gradient(135deg, #10b981, #059669);
303 border-radius: 50%;
304 display: flex;
305 align-items: center;
306 justify-content: center;
307 font-size: 40px;
308 margin: 0 auto 24px;
309 }
310
311 .alert {
312 padding: 16px;
313 border-radius: 10px;
314 margin-bottom: 24px;
315 font-size: 14px;
316 }
317
318 .alert-success {
319 background: #d1fae5;
320 color: #065f46;
321 border: 1px solid #a7f3d0;
322 }
323
324 .alert-error {
325 background: #fee2e2;
326 color: #991b1b;
327 border: 1px solid #fecaca;
328 }
329
330 .alert-warning {
331 background: #fef3c7;
332 color: #92400e;
333 border: 1px solid #fde68a;
334 }
335
336 @media (max-width: 1024px) {
337 .auth-layout {
338 grid-template-columns: 1fr;
339 }
340
341 .auth-left {
342 display: none;
343 }
344
345 .auth-right {
346 padding: 40px 24px;
347 }
348 }
349 </style>
350</head>
351<body>
352 <!-- SPLIT LAYOUT - LOGIN -->
353 <div class="section-divider">01 - Login (Split Layout)</div>
354 <div class="auth-layout">
355 <div class="auth-left">
356 <div class="auth-left-content">
357 <div class="auth-illustration">🔐</div>
358 <h1>Welcome back</h1>
359 <p>Access your dashboard and manage your projects with ease. Secure, fast, and reliable.</p>
360 </div>
361 </div>
362 <div class="auth-right">
363 <div class="auth-form-container">
364 <div class="logo">YourBrand</div>
365 <div class="auth-header">
366 <h2>Sign in to your account</h2>
367 <p>Enter your credentials to access your account</p>
368 </div>
369
370 <form>
371 <div class="form-group">
372 <label class="form-label">Email address</label>
373 <input type="email" class="form-input" placeholder="you@example.com">
374 </div>
375
376 <div class="form-group">
377 <label class="form-label">Password</label>
378 <input type="password" class="form-input" placeholder="••••••••">
379 </div>
380
381 <div class="form-group" style="display: flex; justify-content: space-between; align-items: center;">
382 <div class="form-checkbox">
383 <input type="checkbox" id="remember">
384 <label for="remember">Remember me</label>
385 </div>
386 <a href="#" style="font-size: 14px; color: #7C3AED; text-decoration: none; font-weight: 600;">Forgot password?</a>
387 </div>
388
389 <button type="submit" class="btn btn-primary">Sign in</button>
390 </form>
391
392 <div class="divider">
393 <div class="divider-line"></div>
394 <span class="divider-text">Or continue with</span>
395 <div class="divider-line"></div>
396 </div>
397
398 <button class="btn btn-social">
399 <span style="font-size: 20px;">🔵</span>
400 <span>Continue with Google</span>
401 </button>
402 <button class="btn btn-social">
403 <span style="font-size: 20px;">⚫</span>
404 <span>Continue with GitHub</span>
405 </button>
406
407 <div class="auth-footer">
408 Don't have an account? <a href="#">Sign up</a>
409 </div>
410 </div>
411 </div>
412 </div>
413
414 <!-- CENTERED - SIGN UP -->
415 <div class="section-divider">02 - Sign Up (Centered)</div>
416 <div class="auth-centered">
417 <div class="auth-card">
418 <div class="logo" style="text-align: center;">YourBrand</div>
419 <div class="auth-header" style="text-align: center;">
420 <h2>Create your account</h2>
421 <p>Get started with a free account</p>
422 </div>
423
424 <form>
425 <div class="form-group">
426 <label class="form-label">Full name</label>
427 <input type="text" class="form-input" placeholder="John Doe">
428 </div>
429
430 <div class="form-group">
431 <label class="form-label">Email address</label>
432 <input type="email" class="form-input" placeholder="you@example.com">
433 </div>
434
435 <div class="form-group">
436 <label class="form-label">Password</label>
437 <input type="password" class="form-input" placeholder="••••••••">
438 </div>
439
440 <div class="form-group">
441 <label class="form-label">Confirm password</label>
442 <input type="password" class="form-input" placeholder="••••••••">
443 </div>
444
445 <div class="form-group">
446 <div class="form-checkbox">
447 <input type="checkbox" id="terms">
448 <label for="terms">I agree to the Terms of Service and Privacy Policy</label>
449 </div>
450 </div>
451
452 <button type="submit" class="btn btn-primary">Create account</button>
453 </form>
454
455 <div class="auth-footer">
456 Already have an account? <a href="#">Sign in</a>
457 </div>
458 </div>
459 </div>
460
461 <!-- FORGOT PASSWORD -->
462 <div class="section-divider">03 - Forgot Password</div>
463 <div class="auth-centered">
464 <div class="auth-card">
465 <div style="text-align: center; font-size: 64px; margin-bottom: 24px;">🔑</div>
466 <div class="auth-header" style="text-align: center;">
467 <h2>Reset your password</h2>
468 <p>Enter your email and we'll send you a reset link</p>
469 </div>
470
471 <form>
472 <div class="form-group">
473 <label class="form-label">Email address</label>
474 <input type="email" class="form-input" placeholder="you@example.com">
475 </div>
476
477 <button type="submit" class="btn btn-primary">Send reset link</button>
478 </form>
479
480 <div class="auth-footer">
481 Remember your password? <a href="#">Sign in</a>
482 </div>
483 </div>
484 </div>
485
486 <!-- RESET PASSWORD -->
487 <div class="section-divider">04 - Reset Password</div>
488 <div class="auth-centered">
489 <div class="auth-card">
490 <div class="auth-header" style="text-align: center;">
491 <h2>Create new password</h2>
492 <p>Enter your new password below</p>
493 </div>
494
495 <div class="alert alert-warning">
496 ⚠️ Password must be at least 8 characters with uppercase, lowercase, and numbers
497 </div>
498
499 <form>
500 <div class="form-group">
501 <label class="form-label">New password</label>
502 <input type="password" class="form-input" placeholder="••••••••">
503 </div>
504
505 <div class="form-group">
506 <label class="form-label">Confirm new password</label>
507 <input type="password" class="form-input" placeholder="••••••••">
508 </div>
509
510 <button type="submit" class="btn btn-primary">Reset password</button>
511 </form>
512 </div>
513 </div>
514
515 <!-- TWO-FACTOR AUTHENTICATION -->
516 <div class="section-divider">05 - Two-Factor Authentication (2FA)</div>
517 <div class="auth-centered">
518 <div class="auth-card">
519 <div style="text-align: center; font-size: 64px; margin-bottom: 24px;">📱</div>
520 <div class="auth-header" style="text-align: center;">
521 <h2>Two-factor authentication</h2>
522 <p>Enter the 6-digit code from your authenticator app</p>
523 </div>
524
525 <form>
526 <div class="code-inputs">
527 <input type="text" class="code-input" maxlength="1" pattern="[0-9]">
528 <input type="text" class="code-input" maxlength="1" pattern="[0-9]">
529 <input type="text" class="code-input" maxlength="1" pattern="[0-9]">
530 <input type="text" class="code-input" maxlength="1" pattern="[0-9]">
531 <input type="text" class="code-input" maxlength="1" pattern="[0-9]">
532 <input type="text" class="code-input" maxlength="1" pattern="[0-9]">
533 </div>
534
535 <button type="submit" class="btn btn-primary">Verify code</button>
536 </form>
537
538 <div class="auth-footer">
539 Didn't receive a code? <a href="#">Resend</a>
540 </div>
541 </div>
542 </div>
543
544 <!-- EMAIL VERIFICATION -->
545 <div class="section-divider">06 - Email Verification Sent</div>
546 <div class="auth-centered">
547 <div class="auth-card" style="text-align: center;">
548 <div style="font-size: 64px; margin-bottom: 24px;">📧</div>
549 <div class="auth-header">
550 <h2>Check your email</h2>
551 <p>We've sent a verification link to<br><strong>john@example.com</strong></p>
552 </div>
553
554 <div class="alert alert-success">
555 ✓ Verification email sent successfully
556 </div>
557
558 <button class="btn btn-primary">Resend verification email</button>
559
560 <div class="auth-footer" style="margin-top: 24px;">
561 Wrong email? <a href="#">Change email address</a>
562 </div>
563 </div>
564 </div>
565
566 <!-- SUCCESS STATE -->
567 <div class="section-divider">07 - Success / Confirmation</div>
568 <div class="auth-centered">
569 <div class="auth-card" style="text-align: center;">
570 <div class="success-icon">✓</div>
571 <div class="auth-header">
572 <h2>Password reset successful!</h2>
573 <p>Your password has been changed successfully. You can now sign in with your new password.</p>
574 </div>
575
576 <button class="btn btn-primary">Continue to sign in</button>
577 </div>
578 </div>
579
580 <!-- ERROR STATE -->
581 <div class="section-divider">08 - Error State</div>
582 <div class="auth-centered">
583 <div class="auth-card">
584 <div class="auth-header" style="text-align: center;">
585 <h2>Sign in to your account</h2>
586 <p>Enter your credentials to continue</p>
587 </div>
588
589 <div class="alert alert-error">
590 ✕ Invalid email or password. Please try again.
591 </div>
592
593 <form>
594 <div class="form-group">
595 <label class="form-label">Email address</label>
596 <input type="email" class="form-input" value="wrong@example.com" style="border-color: #ef4444;">
597 </div>
598
599 <div class="form-group">
600 <label class="form-label">Password</label>
601 <input type="password" class="form-input" style="border-color: #ef4444;">
602 </div>
603
604 <button type="submit" class="btn btn-primary">Sign in</button>
605 </form>
606
607 <div class="auth-footer">
608 <a href="#">Forgot password?</a> • <a href="#">Need help?</a>
609 </div>
610 </div>
611 </div>
612
613 <!-- FOOTER NOTE -->
614 <div style="padding: 80px 24px; text-align: center; background: #f9fafb;">
615 <h2 style="margin-bottom: 16px; color: #111827;">Complete Authentication UI Collection</h2>
616 <p style="color: #6b7280; max-width: 700px; margin: 0 auto 32px; font-size: 18px; line-height: 1.7;">
617 Premium authentication pages with split layouts, centered cards, social login, 2FA,
618 email verification, success/error states - everything you need for auth flows.
619 </p>
620 <div style="display: flex; gap: 16px; justify-content: center; flex-wrap: wrap;">
621 <button class="btn btn-primary" style="width: auto;" onclick="window.location='demo-marketing-complete.html'">Marketing</button>
622 <button class="btn btn-primary" style="width: auto;" onclick="window.location='demo-ecommerce-complete.html'">eCommerce</button>
623 <button class="btn btn-primary" style="width: auto;" onclick="window.location='demo-dashboard-complete.html'">Dashboard</button>
624 </div>
625 </div>
626</body>
627</html>