代码 一个简洁大气的登录表单的HTML和CSS代码

2024-11-18 13:14:02 +0800 CST views 487

该文本展示了一个简洁大气的登录表单的HTML和CSS代码。表单包含用户注册所需的输入字段,如全名、电子邮件和密码,并使用现代的样式设计,确保良好的用户体验。表单还包括一个登录链接,方便已有账户的用户访问。

<!DOCTYPE html>
<html lang="zh">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>简洁大气的登录表单</title>
    <style>
        body {
            padding: 200px;
            background-color: #000;
        }
        .form-box {
            max-width: 300px;
            background: #f1f7fe;
            overflow: hidden;
            border-radius: 16px;
            color: #010101;
        }
        .form {
            position: relative;
            display: flex;
            flex-direction: column;
            padding: 32px 24px 24px;
            gap: 16px;
            text-align: center;
        }
        .title {
            font-weight: bold;
            font-size: 1.6rem;
        }
        .subtitle {
            font-size: 1rem;
            color: #666;
        }
        .form-container {
            overflow: hidden;
            border-radius: 8px;
            background-color: #fff;
            margin: 1rem 0 .5rem;
            width: 100%;
        }
        .input {
            background: none;
            border: 0;
            outline: 0;
            height: 20px;
            width: 100%;
            border-bottom: 1px solid #eee;
            font-size: .9rem;
            padding: 8px 15px;
        }
        .form-section {
            padding: 16px;
            font-size: .85rem;
            background-color: #e0ecfb;
            box-shadow: rgb(0 0 0 / 8%) 0 -1px;
        }
        .form-section a {
            font-weight: bold;
            color: #0066ff;
            transition: color .3s ease;
        }
        .form-section a:hover {
            color: #005ce6;
            text-decoration: underline;
        }
        .form button {
            background-color: #0066ff;
            color: #fff;
            border: 0;
            border-radius: 24px;
            padding: 10px 16px;
            font-size: 1rem;
            font-weight: 600;
            cursor: pointer;
            transition: background-color .3s ease;
        }
        .form button:hover {
            background-color: #005ce6;
        }
    </style>
</head>
<body>
    <div class="form-box">
        <form class="form">
            <span class="title">Sign up</span>
            <span class="subtitle">Create a free account with your email.</span>
            <div class="form-container">
                <input type="text" class="input" placeholder="Full Name">
                <input type="email" class="input" placeholder="Email">
                <input type="password" class="input" placeholder="Password">
            </div>
            <button>Sign up</button>
        </form>
        <div class="form-section">
            <p>Have an account? <a href="">Log in</a></p>
        </div>
    </div>
</body>
</html>

images

复制全文 生成海报 前端开发 网页设计 用户体验

推荐文章

Vue3中如何处理SEO优化?
2024-11-17 08:01:47 +0800 CST
Python实现Zip文件的暴力破解
2024-11-19 03:48:35 +0800 CST
Node.js中接入微信支付
2024-11-19 06:28:31 +0800 CST
PHP 8.4 中的新数组函数
2024-11-19 08:33:52 +0800 CST
ElasticSearch简介与安装指南
2024-11-19 02:17:38 +0800 CST
MySQL死锁 - 更新插入导致死锁
2024-11-19 05:53:50 +0800 CST
Nginx 防止IP伪造,绕过IP限制
2025-01-15 09:44:42 +0800 CST
记录一次服务器的优化对比
2024-11-19 09:18:23 +0800 CST
js一键生成随机颜色:randomColor
2024-11-18 10:13:44 +0800 CST
html文本加载动画
2024-11-19 06:24:21 +0800 CST
XSS攻击是什么?
2024-11-19 02:10:07 +0800 CST
Rust 并发执行异步操作
2024-11-19 08:16:42 +0800 CST
如何在 Vue 3 中使用 Vuex 4?
2024-11-17 04:57:52 +0800 CST
底部导航栏
2024-11-19 01:12:32 +0800 CST
Go语言SQL操作实战
2024-11-18 19:30:51 +0800 CST
支付轮询打赏系统介绍
2024-11-18 16:40:31 +0800 CST
Golang实现的交互Shell
2024-11-19 04:05:20 +0800 CST
前端如何给页面添加水印
2024-11-19 07:12:56 +0800 CST
IP地址获取函数
2024-11-19 00:03:29 +0800 CST
Python设计模式之工厂模式详解
2024-11-19 09:36:23 +0800 CST
mysql 优化指南
2024-11-18 21:01:24 +0800 CST
linux设置开机自启动
2024-11-17 05:09:12 +0800 CST
地图标注管理系统
2024-11-19 09:14:52 +0800 CST
程序员茄子在线接单