zoukankan      html  css  js  c++  java
  • 翘边阴影

    HTML代码:

    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="utf-8" />
    <title>css3实现曲线阴影和翘边阴影</title>
    <link rel="stylesheet" type="text/css" href="css/style.css"/>
    </head>
    <body>
    <div class="box">
    <ul>
    <li>
    <img src="img/1.jpg"/>
    </li>
    <li>
    <img src="img/2.jpg"/>
    </li>
    <li>
    <img src="img/3.jpg"/>
    </li>
    </ul>

    </div>
    </body>
    </html>

    CSS代码:

    .box{
    980px;
    height: auto;
    clear: both;
    overflow: hidden;
    margin: 20px auto;
    }

    .box li{
    300px;
    height: auto;
    float: left;
    margin: 20px,10px;
    background: #FFFFFF;
    border: 2px solid #efefef;
    position: relative;
    box-shadow: 0 1px 4px rgba(0,0,0,0.3),0 0 60px rgba(0,0,0,0.1) inset;
    -webkit-box-shadow: 0 1px 4px rgba(0,0,0,0.3),0 0 60px rgba(0,0,0,0.1) inset;
    -moz-box-shadow: 0 1px 4px rgba(0,0,0,0.3),0 0 60px rgba(0,0,0,0.1) inset;
    -o-box-shadow: 0 1px 4px rgba(0,0,0,0.3),0 0 60px rgba(0,0,0,0.1) inset;
    }

    .box li img{
    display: block;
    290px;
    height: 200px;
    margin: 5px;
    }

    .box li:after{
    content:' ' ;
    position: absolute;
    90%;
    height: 80%;
    left : 20px;
    bottom: 8px;
    background: transparent;
    z-index: -1;
    box-shadow:0 8px 20px rgba(0,0,0,0.6) ;
    -webkit-box-shadow:0 8px 20px rgba(0,0,0,0.6) ;
    -moz-box-shadow:0 8px 20px rgba(0,0,0,0.6) ;
    -o-box-shadow:0 8px 20px rgba(0,0,0,0.6) ;
    -webkit-transform: skew(-12deg) rotate(-4deg);
    -moz-transform: skew(-12deg) rotate(-4deg);
    -o-transform: skew(-12deg) rotate(-4deg);
    -ms-transform: skew(-12deg) rotate(-4deg);
    }

    .box li:before{
    content:' ' ;
    position: absolute;
    90%;
    height: 80%;
    right : 20px;
    bottom: 8px;
    background: transparent;
    z-index: -1;
    box-shadow:0 8px 20px rgba(0,0,0,0.6) ;
    -webkit-box-shadow:0 8px 20px rgba(0,0,0,0.6) ;
    -moz-box-shadow:0 8px 20px rgba(0,0,0,0.6) ;
    -o-box-shadow:0 8px 20px rgba(0,0,0,0.6) ;
    -webkit-transform: skew(12deg) rotate(4deg);
    -moz-transform: skew(12deg) rotate(4deg);
    -o-transform: skew(12deg) rotate(4deg);
    -ms-transform: skew(12deg) rotate(4deg);
    }

  • 相关阅读:
    Zabbix学习
    Ping 不通的原因分析
    【FAQ】P3. 为什么 torch.cuda.is_available() 是 False
    【PyTorch教程】P2. Python编辑器的选择、安装及配置
    PyTorch环境配置及安装
    更改文件夹图标
    卸载OpenIV
    一次写文,多平台直接粘贴&打造最流畅的写作流程
    Python字符串中删除特定字符
    Python字符串中添加、插入特定字符
  • 原文地址:https://www.cnblogs.com/150536FBB/p/8626795.html
Copyright © 2011-2022 走看看