div+css布局实现兔子爱心卡通效果代码

代码语言:html

所属分类:布局界面

代码描述:div+css布局实现兔子爱心卡通效果代码

代码标签: div css 布局 兔子 爱心 卡通

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

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

<head>
  <meta charset="UTF-8">
  
  
  
<style>
body {
  background: #fec;
  margin: 0;
  padding: 0;
  display: grid;
  place-items: center;
  min-height: 100vh;
  overflow: hidden;
}

article {
  --skin: #fff;
  --line: #b86;
  --accent: #fcb;
  --shadow: #fed;
  --shadow2: #fba;
  position: relative;
  font-size: 0.8vmin;
  aspect-ratio: 1;
  width: 80em;
  
  *, *::before, *::after {
    position: absolute;
    box-sizing: border-box;
  }
  
  h1 {
    width: 1px;
    height: 1px;
    overflow: hidden;
  }
  
  .shadow {
    width: 75%;
    height: 10%;
    border-radius: 50%;
    background: var(--accent);
    top: 102%;
    left: 53%;
    translate: -50% -50%;
  }
  
  .body {
    width: 52%;
    height: 69%;
    bottom: -5%;
    left: 50%;
    translate: -50%;
    
    .something {
      width: 50%;
      aspect-ratio: 1;
      rotate: 40deg;
      top: 8%;
      left: 10%;
      
     .........完整代码请登录后点击上方下载按钮下载查看

网友评论0