js+css实现圣诞节下雪卡片动画代码

代码语言:html

所属分类:动画

代码描述:js+css实现圣诞节下雪卡片动画代码

代码标签: js css 圣诞节 下雪 卡片 动画 代码

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

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

<head>
  <meta charset="UTF-8">

  <link href="https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&family=Mountains+of+Christmas:wght@400;700&display=swap" rel="stylesheet" />
  
  
  
<style>
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  margin: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  background: #0a192f;
  overflow: hidden;
  font-family: "Mountains of Christmas", cursive;
}

.frame {
  position: relative;
  width: 420px;
  height: 500px;
  border-radius: 24px;
  overflow: hidden;
  background: radial-gradient(circle at 50% 20%, #0c2a4d 0%, #091a33 100%);
  box-shadow:
        0 25px 60px rgba(0, 0, 0, 0.8),
        inset 0 0 80px rgba(20, 60, 100, 0.1),
        0 0 0 1px rgba(200, 230, 255, 0.1);
  border: 1px solid rgba(200, 230, 255, 0.08);
}

.frame::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 24px;
  background: radial-gradient(circle at 50% 120%, rgba(255, 255, 255, 0.03) 0%, transparent 70%);
  box-shadow: inset 0 0 120px rgba(0, 0, 0, 0.4);
  pointer-events: none;
  z-index: 1;
}

.title {
  position: absolute;
  top: 24px;
  width: 100%;
 .........完整代码请登录后点击上方下载按钮下载查看

网友评论0