全国联动css,CSS3 齿轮啮合联动动画

CSS

语言:

CSSSCSS

确定

body {

background: radial-gradient(circle, #333, #111);

overflow: hidden;

}

.cog {

position: absolute;

width: 200px;

height: 200px;

top: 50%;

left: 50%;

border-radius: 200px;

margin: -100px 0 0 -230px;

background-image: radial-gradient(#666 60%, rgba(0, 0, 0, 0) 61%), repeating-conic-gradient(#666 0 15deg, transparent 0 30deg);

animation-name: rotate;

animation-duration: 6s;

animation-iteration-count: infinite;

animation-timing-function: linear;

}

.cog:before {

content: "";

position: absolute;

width: 50%;

height: 50%;

top: 25%;

left: 25%;

border-radius: 400px;

background-image: radial-gradient(#2e2e2e 20%, #666 21%, #666 30%, rgba(0, 0, 0, 0) 31%), repeating-conic-gradient(#2e2e2e 0 45deg, transparent 0 90deg);

}

@keyframes rotate {

from {

transform: rotate(0);

}

to {

transform: rotate(360deg);

}

}

.cog-2,

.cog-3 {

animation-direction: reverse;

width: 100px;

height: 100px;

margin: 20px 0 0 -58px;

animation-duration: 3s;

background-image: radial-gradient(#666 50%, rgba(0, 0, 0, 0) 51%), repeating-conic-gradient(#666 0 30deg, transparent 0 60deg);

}

.cog-3 {

animation-direction: normal;

margin: -23px 0 0 20px;

}

.cog-bg1 {

animation-direction: reverse;

width: 300px;

height: 300px;

margin: -150px 0 0 -200px;

animation-duration: 9s;

background-image: radial-gradient(#252525 65%, rgba(0, 0, 0, 0) 65%), repeating-conic-gradient(#252525 0 10deg, transparent 0 20deg);

}

.cog-bg1:before {

width: 70%;

height: 70%;

top: 15%;

left: 15%;

background-image: radial-gradient(#333 20%, #252525 21%, #252525 30%, rgba(0, 0, 0, 0) 31%), repeating-conic-gradient(#333 0 45deg, transparent 0 90deg);

}

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值