本来想多做几个了 无奈最近太忙 于是模仿做了一个在codepen看到的圣诞雪景球   算是送给自己的圣诞礼物

演示地址:http://www.qdfuns.com/notes/26668/d5e1776243f8272941de3e65dd094db2.html

想看原文的地址在这里http://codepen.io/chilliconcode/pen/rWpvOe

 <html lang="en">
<head>
<meta charset="UTF-8">
<title>CSS动画圣诞雪景球</title>
<embed src="age/sd.mp3" autostart="true" loop="-1" controls="ControlPanel" width="0" height="0">
<style type="text/css">
@charset "UTF-8";
body{
background:#4bb093;
}
ul,ol,li{
list-style-type:none;
}
body,div,ul,li,p{ margin:0; padding:0;}
img{border:0;}
.snow_globe{
width: 400px;
height: 400px;
margin:100px auto;
position: relative;
}
.circular_white{
width: 400px;
height: 400px;
border-radius:100%;
position: absolute;
background:rgba(255, 255, 255, 0.5);
}
.cir_cen{
width: 380px;
height: 380px;
z-index: 3;
margin-top: 10px;
margin-left: 10px;
display: inline-block;
border-radius:100%;
position: absolute;
background: -webkit-linear-gradient(top, rgba(255, 255, 255, 0) 68%, #f5f5f5 68%, #ebeff5 79%, #c7d7e0 100%);
}
.step{
width: 356px;
height: 40px;
background: #fff;
position: relative;
top: 236px;
border-radius: 100%;
margin: auto;
}
.son_btm{
width: 110px;
height: 110px;
margin:150px 0 0 135px;
border-radius: 100%;
position: absolute;
background:#fff;
box-shadow: -5px 10px 20px -10px #cccccc;
z-index: 99;
}
.son_top{
width: 80px;
height: 80px;
margin:90px 0 0 150px;
border-radius: 100%;
position: absolute;
background:#fff;
z-index: 99;
}
.eye{
width: 6px;
height: 6px;
z-index:99;
background:#613900;
border-radius:100%;
margin-top: 110px;
margin-left: 170px;
position: absolute;
}
.eye_2{
width: 8px;
height: 8px;
z-index: 99;
background: #613900;
border-radius: 100%;
margin-top: 108px;
margin-left: 190px;
position: absolute;
}
.nose{
background-color: transparent;
display: inline-block;
position: absolute;
top: 120px;
left: 140px;
border-top: 8px solid transparent;
border-bottom: 8px solid transparent;
border-right: 40px solid #f97d00;
border-radius: 30px;
z-index: 99;
}
.scarf{
width: 70px;
height: 10px;
background-color: #ec4800;
position: absolute;
top: 150px;
left: 155px;
z-index: 99;
transform: rotate(3deg);
border-radius: 30%;
}
.scarf_2{
width: 10px;
height: 30px;
background-color: #d34100;
display: inline-block;
position: absolute;
top: 145px;
left: 200px;
z-index: 99;
transform: rotate(-25deg);
border-radius: 30%;
}
.hat{
width: 100px;
height: 15px;
border-radius: 50%;
background-color: #613900;
position: absolute;
z-index: 99;
top: 90px;
left: 145px;
transform: rotate(10deg);
}
.hat_2{
width: 80px;
height: 40px;
background-color: #613900;
display: inline-block;
position: relative;
top: -35px;
left: 10px;
}
.ribbon {
height: 10px;
width: 80px;
background-color: #ec4800;
position: relative;
top: -65px;
left: 10px;
z-index: 6;
}
.hat_3{
z-index: 5;
display: inline-block;
position: relative;
top: -100px;
left: 10px;
width: 80px;
height: 5px;
border-radius: 50%;
background-color: #3b2200;
}
.shape{
width: 5px;
height: 5px;
margin-top: 140px;
margin-left: 50px;
z-index: 99;
border-radius: 100%;
position: absolute;
border-radius:100%;
box-shadow: 119px 0px 0px 0px #ed5614, 125px 2px 0px 0px #ed5614, 132px 2px 0px 0px #ed5614, 138px -2px 0px 0px #ed5614;
}
.shape_1{
width: 10px;
height: 10px;
margin-top: 160px;
margin-left: 50px;
z-index: 99;
position: absolute;
border-radius: 100%;
box-shadow: 130px 15px 0px -2px #613900, 130px 28px 0px -1px #613900, 130px 41px 0px 0px #613900, 130px 55px 0px 0px #613900;
} .snowflake{
overflow: hidden;
} .snow {
width: 380px;
height: 350px;
border-radius: 100%;
position: absolute;
top: 10px;
left: 10px;
overflow: hidden;
opacity: 0.8;
}
/* 雪花是胡乱写的... 这个方法模仿自http://codepen.io/chilliconcode/pen/rWpvOe */
.snow_1 {
color: #fff;
opacity: 0.5;
animation: sfanim linear 30s;
-webkit-animation: sfanim linear 30s;
animation-iteration-count: infinite;
-webkit-animation-iteration-count: infinite;
text-shadow:0px 20px, -6px 20px, -13px 20px, -20px 18px, -19px 20px, 380px 171px, 550px 80px, 269px 50px, 20px 151px, 221px 344px, 229px 136px, 237px 280px, 303px 30px, 211px 314px, 378px 285px, 388px 117px, 70px 295px, 149px 318px, 96px 66px, 129px 217px, 138px 218px, 241px 310px, 231px 368px, 18px 327px, 173px 213px, 118px 10px, 246px 208px, 159px 244px, 268px 376px, 167px 262px, 85px 238px, 277px 47px, 386px 192px, 259px 364px, 325px 327px, 279px 201px, 303px 517px, 32px 489px, 323px 519px, 98px 583px, 126px 635px, 0px 571px, 380px 461px, 269px 417px, 0px 551px, 121px 744px, 229px 536px, 237px 680px, 303px 430px, 211px 714px, 378px 685px, 10px 687px, 93px 745px, 292px 724px, 223px 692px, 156px 560px, 253px 458px, 205px 595px, 145px 506px, 79px 712px, 182px 759px, 279px 499px, 349px 524px, 5px 433px, 216px 547px,120px 666px, 50px 666px, 214px 421px, 364px 404px, 202px 652px, 354px 632px, 312px 500px;
} .snow_2 {
color: #fff;
animation: sfanim linear 15s;
-webkit-animation: sfanim linear 15s;
animation-iteration-count: infinite;
-webkit-animation-iteration-count: infinite;
text-shadow: 600px 500px, 50px 625px, 351px 741px, 20px 632px, 250px 652px, 388px 698px, 235px 762px, 50px 714px, 385px 742px, 185px 635px, 156px 560px, 364px 485px, 340px 620px, 394px 428px, 187px 748px, 217px 624px, 356px 630px, 33px 758px, 238px 762px, 357px 586px, 253px 798px, 68px 786px, 164px 662px, 119px 598px, 221px 557px, 126px 537px, 282px 503px, 11px 455px, 219px 632px, 60px 597px, 41px 529px, 247px 451px, 217px 644px, 304px 400px, 214px 421px, 287px 757px, 76px 404px, 376px 735px, 169px 572px, 245px 790px, 66px 717px, 375px 85px, 11px 289px, 254px 384px, 5px 286px, 266px 305px, 388px 298px, 180px 307px, 36px 13px, 74px 295px, 238px 290px, 384px 235px, 1px 294px, 45px 138px, 131px 350px, 258px 120px, 157px 305px, 96px 349px, 325px 319px, 132px 288px, 167px 111px, 41px 129px, 247px 51px, 217px 244px, 304px 0px, 214px 21px, 287px 357px, 76px 4px, 376px 335px, 169px 172px, 245px 390px, 66px 317px;
} @keyframes sfanim {
0% {
-webkit-transform: translate(0px, -500px);
transform: translate(0px, -500px);
}
100% {
-webkit-transform: translate(0px, 100px);
transform: translate(0px, 100px);
}
} @-webkit-keyframes sfanim {
0% {
-webkit-transform: translate(0px, -500px);
transform: translate(0px, -500px);
}
100% {
-webkit-transform: translate(0px, 100px);
transform: translate(0px, 100px);
}
}
.toum {
width: 400px;
height: 400px;
border-radius: 100%;
position: absolute;
background:linear-gradient(315deg, rgba(255, 255, 255,0.9) 0%, rgba(253, 251, 251, 0.2) 47%, rgb(191, 253, 239) 100%);
background:-webkit-linear-gradient(315deg, rgba(255, 255, 255,0.9) 0%, rgba(253, 251, 251, 0.2) 47%, rgb(191, 253, 239) 100%);
} .arch {
width: 560px;
height: 133.33333px;
position: absolute;
bottom: -342px;
margin-left: -80px;
position: relative;
-webkit-clip-path: polygon(30% 10%, 70% 10%, 80% 100%, 20% 100%);
z-index: 99999;
overflow: hidden;
}
.arch_1 {
height: 180px;
width: 400px;
border-radius: 100%;
border: 20px solid #ffcb12;
position: absolute;
bottom: 74px;
left: 60px;
}
.arch_2 {
height: 180px;
width: 400px;
border-radius: 100%;
border: 40px solid #ebbb11;
position: absolute;
bottom: 35px;
left: 46px;
}
.shadow{
width: 400px;
height: 40px;
background: #449e85;
position: relative;
top: 280px;
border-radius: 100%;
margin: auto;
}
</style>
</head>
<body>
<div class="snow_globe">
<div class="circular_white"></div>
<div class="cir_cen">
<div class="step"></div>
</div>
<div class="snowman">
<div class="son_btm"></div>
<div class="son_top"></div>
<div class="shape"></div>
<div class="shape_1"></div>
<div class="hat">
<div class="hat_2"></div>
<div class="ribbon"></div>
<div class="hat_3"></div>
</div>
<div class="eye"></div>
<div class="eye_2"></div>
<div class="nose"></div>
<div class="scarf"></div>
<div class="scarf_2"></div>
</div>
<div class="snowflake">
<div class="snow">
<div class="snow_1">
<p>*</p>
</div>
<div class="snow_2">
<p>*</p>
</div>
</div>
</div>
<div class="toum"></div>
<div class="arch">
<div class="arch_1"></div>
<div class="arch_2"></div>
</div>
<div class="shadow"></div>
</div> </body>
</html>

  

css3圣诞雪景球的更多相关文章

  1. css3圣诞雪景球开源

    css3圣诞雪景球开源 <!DOCTYPE html><html lang="en"><head> <meta charset=" ...

  2. css3 圣诞红包雨效果

    <!DOCTYPE html> <html> <head lang="en"> <meta charset="UTF-8&quo ...

  3. 用js,css3 做的一个球

    用css3属性很容易做一个立方体,但是要做一个球体,会相对复杂些 原理是:球可以看做是由无数个圆圈构成,然后就可以用圆圈来做球, 下面的例子是我做的一个小球,由72个圆圈组成.如果把每个圆圈的背景颜色 ...

  4. CSS3弹力球

    如下代码实现方块在限定区域内不停弹跳. <!DOCTYPE html> <html> <head> <style> div { width:100px; ...

  5. 慕课网H5圣诞主题

    继七夕之后,我又出了一个圣诞主题的课程.圣诞主题是基于HTML5+CSS+JS编写与实现的,同时也是七夕主题的故事延续.圣诞主题依旧延续着七夕主题设计的思路,引入了3个经典的场景页面,在每个场景中表述 ...

  6. Web 前端开发精华文章推荐(jQuery、HTML5、CSS3)【系列十二】

    2012年12月12日,[<Web 前端开发人员和设计师必读文章>系列十二]和大家见面了.梦想天空博客关注 前端开发 技术,分享各种增强网站用户体验的 jQuery 插件,展示前沿的 HT ...

  7. CSS3动画几个平时没注意的属性

    一.timing-function: steps() 一开始在使用CSS3的时候并没有太注意这个timing-function,只是注意到自定义贝塞尔曲线. 1)一个项目中的实例 先来看看左边加了st ...

  8. css3实践之摩天轮式图片轮播+3D正方体+3D标签云(perspective、transform-style、perspective-origin)

    本文主要通过摩天轮式图片轮播的例子来讲解与css3 3D有关的一些属性. demo预览: 摩天轮式图片轮播(貌似没兼容360 最好用chrome) 3D正方体(chrome only) 3D标签云(c ...

  9. cubic-bezier贝塞尔曲线css3动画工具

    今天在一本叫<HTML5触摸界面设计与开发>上看到一个做弹跳球的复杂动画效果,首先加速下降,停止,然后弹起时逐渐减速.是用cubic-bezier贝塞尔曲线来完成的.所以特地去学习了一下关 ...

随机推荐

  1. .NET DateTime类型变量作为参数时设置默认值

    一个小的 Tips. .NET 中函数参数的默认值需要是编译时常量.如果参数是引用类型,可以设置Null,如果是值类型,可以设置相应的编译时常量,如整型可以用整数,但对于DateTime(结构体,值类 ...

  2. 成就PHP高手的五个必由之路

    亲们,此文时转载过来的,不是原创!特此说明一下 原文名称:5 ways to be a better php developer原文链接:http://www.developertutorials.c ...

  3. 【工匠大道】Mac下Java开发环境配置简述

    本文地址 原文地址 分享提纲: 1. 下载JDK1.7 2. 配置java_home 3 .安装tomcat 4 .安装eclipse或者myeclipse 5.  mysql安装 破解版下载请参考M ...

  4. 9.1.3 .net framework通过业务逻辑层自动生成WebApi的做法

    首先需要说明的是这是.net framework的一个组件,而不是针对.net core的.目前工作比较忙,因此.net core的转换正在编写过程中,有了实现会第一时间贴出来. 接下来进入正题.对于 ...

  5. 如何利用FineReport制作动态树报表

    在对数据字段进行分类管理时,利用动态树折叠数据是一个很好的方法,也就是点击数据前面的加号才展开对应下面的数据,如下图.那这样的效果在制作报表时该如何实现呢? 下面以报表工具FineReport为例介绍 ...

  6. 实现一个基于 SharePoint 2013 的 Timecard 应用(上)

    在 SharePoint 2013 上面实现一个 Timecard 应用的想法来自一个真实的需求,而实现的方案在我脑海里面盘旋已经很久了,终于这几天准备安排点儿时间将它实现出来. “ We start ...

  7. low security dvwa--SQL Injection

    登录dvwa后,点击左边的"SQL Injection",出现以下界面: 下面做一些学习总结. 第一步:用 "order by n" 获得表中的属性列数,它的意 ...

  8. Google C++单元测试框架GoogleTest---Google Mock简介--概念及基础语法

    就在昨天终于做了gtest的分享,我的预研工作终于结束了,感觉离我辞职的日子不远了,毕竟是专注java二百年啊,要告别实习啦.. 这篇是GoogleMock的简介文档,会在后边附带一个自己的例子. 一 ...

  9. java web 之客户关系管理系统

    这个周末真的是觉得自己学会了一个比较高大上的本领,为什么这么觉得呢?那是因为星期六的时候觉得自己可以看看源码能做出来,可是让我头疼的是花费了一上午的时间还是没有弄出来,还好上天给了我机会,要是没有老师 ...

  10. 【代码笔记】iOS-由身份证号码返回性别

    一,代码. - (void)viewDidLoad { [super viewDidLoad]; // Do any additional setup after loading the view. ...