纯css实现折叠的卡片动画效果
代码语言:html
所属分类:动画
代码描述:纯css实现折叠的卡片动画效果
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<link href="https://fonts.googleapis.com/css2?family=Bebas+Neue&family=Bitter:wght@400;700&family=Righteous&display=swap" rel="stylesheet">
<style>
:root {
--base-grid: 8px;
--colour-body-background: #d84c6e;
--colour-background: #fff;
--colour-background-folded: #f5f5f5;
--colour-background-stripes: rgba(255,255,255,.5);
--colour-text: #1a1a1a;
}
*, :after, :before {
box-sizing: border-box;
margin: 0;
}
body {
background: var(--colour-body-background);
font-family: Bitter;
padding: calc(var(--base-grid)*10);
}
.articles {
margin: calc(var(--base-grid)*2) auto calc(var(--base-grid)*5);
display: grid;
grid-row-gap: calc(var(--base-grid)*8);
grid-column-gap: calc(var(--base-grid)*6);
grid-template-columns: repeat(auto-fit,minmax(calc(var(--base-grid)*35),1fr));
justify-items: center;
}
.articles__article {
cursor: po.........完整代码请登录后点击上方下载按钮下载查看
















网友评论0