美文网首页
css毛玻璃

css毛玻璃

作者: xueyueshuai | 来源:发表于2022-04-24 10:20 被阅读0次
<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        body {
            /* background: url("http://jianzhan.dev.xinzhidi.cn/upload/20210907/d4e864db010f9743cb6cd0b3600975d0.jpg") 0 / cover fixed; */
            height: 200vh;
        }

        main::before {
            background: url("http://jianzhan.dev.xinzhidi.cn/upload/20210907/d4e864db010f9743cb6cd0b3600975d0.jpg") 0 / cover fixed;
        }

        main {
            position: absolute;
            top: 0;
            bottom: 0;
            left: 0;
            right: 0;
            width: 800px;
            height: 500px;
            line-height: 2;
            margin: auto;
            border-radius: 5px;
            background: rgba(255, 255, 255, .3);
            box-shadow: 3px 3px 6px 3px rgba(0, 0, 0, .3);
            overflow: hidden;
        }

        main::before {
            content: '';
            position: absolute;
            top: 0;
            bottom: 0;
            left: 0;
            right: 0;
            filter: blur(20px);
            z-index: -1;
            margin: -30px;
        }
    </style>
</head>

<body>
    <main>
        aaaaa
    </main>
</body>

</html>

相关文章

网友评论

      本文标题:css毛玻璃

      本文链接:https://www.haomeiwen.com/subject/mfhjrrtx.html