zoukankan      html  css  js  c++  java
  • css3 鼠标经过外层阴影

    <!DOCTYPE html>
    <html lang="en">
    <head>
    <meta charset="UTF-8">
    <title>Document</title>
    <style>
    body{
        background-color: #eee;
    }
    .box{
        width: 200px;
        height: 350px;
        background-color: #fff;
        position: relative;
    }
    .box:hover{
        box-shadow:0 0 18px rgba(0,0,0,0.4);
    }
    .box:hover:before{position:absolute; content:""; bottom:10px; left:0; height:20px; width:50%; box-shadow:0 15px 10px rgba(0,0,0,0.3); -webkit-transform:rotate(-6deg); -moz-transform:rotate(-6deg); -o-transform:rotate(-6deg); -ms-transform:rotate(-6deg); transform:rotate(-6deg); z-index:-1}
    .box:hover:after{position:absolute; content:""; bottom:10px; left:0; height:20px; width:50%; box-shadow:0 15px 10px rgba(0,0,0,0.3); -webkit-transform:rotate(-6deg); -moz-transform:rotate(-6deg); -o-transform:rotate(-6deg); -ms-transform:rotate(-6deg); transform:rotate(-6deg); z-index:-1;right:0; left:auto; -webkit-transform:rotate(6deg); -moz-transform:rotate(6deg); -o-transform:rotate(6deg); -ms-transform:rotate(6deg); transform:rotate(6deg)}
    </style>
    </head>
    <body>
        <div class="box"></div>
    </body>
    </html>

    效果如下图所示:

    高否?富否?帅否? 否? 滚去学习!
  • 相关阅读:
    新概念4-38
    新概念4-37
    新概念4-36
    新概念4-35
    国史通鉴-03 天下为私 04
    新概念4-34
    西门子 框架断路器 及其他中低压配电设备资料查询
    OPC UA 的本质
    经典Scout添加等时同步设备
    同步报故障解同步启动
  • 原文地址:https://www.cnblogs.com/baixc/p/4317227.html
Copyright © 2011-2022 走看看