<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>盒子阴影</title>
    <style>
        .box {
            width: 200px;
            height: 200px;
            background-color: orange;
            margin: 200px auto;
            /*opacity: 0;*/
            transition: .3s;
        }

        .box {
            /*x轴偏移 y轴偏移 虚化程度 阴影宽度 阴影颜色*/
            /*box-shadow: -300px 0 10px 0 red, 300px 0 10px 0 blue;*/
        }
        .box:hover {
            margin-top: 195px;
            box-shadow: 0 5px 10px 0 #333;
        }

    </style>
</head>
<body>
    <div class="box"></div>
</body>
</html>

相关文章:

  • 2021-10-26
  • 2021-10-09
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-26
  • 2022-02-18
  • 2022-12-23
猜你喜欢
  • 2021-12-18
  • 2021-10-03
  • 2022-12-23
  • 2021-05-23
  • 2021-10-11
  • 2021-05-27
相关资源
相似解决方案