单个div布局实现一个老鼠玩具背部旋钮的效果代码

代码语言:html

所属分类:布局界面

代码描述:单个div布局实现一个老鼠玩具背部旋钮的效果代码

代码标签: 实现 一个 老鼠 玩具 背部 旋钮 效果

下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开


<!DOCTYPE html>
<html lang="en" >

<head>

  <meta charset="UTF-8">

  
<style>
body {
  min-height: 220px;
  height: 100vh;
  position: relative;
  background-color: #deb887;
}
div {
  position: absolute;
  left: 50%;
  top: 50%;
}
div:before,
div:after {
  display: block;
  content: '';
  position: absolute;
}
@media (max-width: 400px) {
  div:not(.no-scale) {
    -webkit-transform: scale(0.8);
            transform: scale(0.8);
  }
}
#winding {
  width: 15.5em;
  height: 8em;
  margin-left: -7.25em;
  margin-top: -4em;
  background-repeat: no-repeat;
  background-image: radial-gradient(circle, rgba(255,250,205,0) 25%, #fffacd 25.5%, #fffacd 50.5%, rgba(255,250,205,0) 51%), radial-gradient(circle, rgba(240,230,140,0) 25%, #f0e68c 25.5%, #f0e68c 50%, rgba(240,230,140,0) 50.5%), radial-gradient(circle, #552a0c 50%, rgba(139,69,19,0) 51%);
  background-size: 4em 4em, 4em 4em, 3.4em 3.4em;
  background-position: 30% 0, 55% 0, left -0.45em bottom 0.8em;
  border-radius: 0 4em 6em 0;
  border-top: 0.1em solid transparent;
  border-right: 0.7em solid #8b4513;
  border-bottom: 0.7em solid #8b4513;
}
#winding:before {
  width: 13.5em;
  height: 5em;
  bottom: -1em;
  right: 2.6em;
  background-color: #d2691e;
  background-repeat: no-repeat;
  background-image: radial-gradient(circle, #311807 50%, rgba(139,69,19,0) 51%);
  background-size: 4.5em 4.5em;
  background-position: right 0.3em bottom -1.3em;
  border-top-left-radius: 10.........完整代码请登录后点击上方下载按钮下载查看

网友评论0