forked from local-host-8080/demo-html-css
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c75bf8d
commit 4df576b
Showing
7 changed files
with
368 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
@import url('https://fonts.googleapis.com/css?family=Poppins:200,300,400,500,600,700,800,900&display=swap'); | ||
*{ | ||
margin: 0; | ||
padding: 0; | ||
box-sizing: border-box; | ||
font-family: 'Poppins', sans-serif; | ||
} | ||
body{ | ||
display: flex; | ||
justify-content: center; | ||
align-items: center; | ||
min-height: 100vh; | ||
background: linear-gradient(#0f4675, #0f4675 50%, #fff 50%, #fff 100%); | ||
} | ||
.container{ | ||
width: 1100px; | ||
display: flex; | ||
justify-content: space-between; | ||
flex-wrap: wrap; | ||
} | ||
.container .box{ | ||
position: relative; | ||
width: 320px; | ||
background: #fff; | ||
padding: 100px 40px 60px; | ||
box-shadow: 0 15px 45px rgba(0,0,0,.1); | ||
} | ||
.container .box:before{ | ||
content: ''; | ||
position: absolute; | ||
top: 0; | ||
left: 0; | ||
width: 100%; | ||
height: 100%; | ||
background: #ff226d; | ||
transform: scaleY(0); | ||
transform-origin: top; | ||
transition: transform 0.5s; | ||
} | ||
.container .box:hover:before{ | ||
transform: scaleY(1); | ||
transform-origin: bottom; | ||
transition: transform 0.5s; | ||
} | ||
.container .box h2{ | ||
position: absolute; | ||
left: 40px; | ||
top: 60px; | ||
font-size: 4em; | ||
font-weight: 800; | ||
z-index: 1; | ||
opacity: 0.1; | ||
transition: 0.5s; | ||
} | ||
.container .box:hover h2{ | ||
opacity: 1; | ||
color: #fff; | ||
transform: translateY(-40px); | ||
} | ||
.container .box h3{ | ||
position: relative; | ||
font-size: 1.5em; | ||
z-index: 2; | ||
color: #333; | ||
transition: 0.5s; | ||
} | ||
.container .box p{ | ||
position: relative; | ||
z-index: 2; | ||
color: #555; | ||
transition: 0.5s; | ||
} | ||
.container .box:hover h3, | ||
.container .box:hover p{ | ||
color: #fff; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
<!DOCTYPE html> | ||
<html lang="Zh-CN"> | ||
<head> | ||
<meta charset="utf-8"> | ||
<title>31-Card-Effect</title> | ||
<!-- Link CSS --> | ||
<link rel="stylesheet" href="css/style.css"> | ||
</head> | ||
<body> | ||
<div class="container"> | ||
<div class="box"> | ||
<h2>01</h2> | ||
<h3>Service One</h3> | ||
<p>这些年一直在提醒自己一件事情,千万不要感动自己,大部分人看似努力,不过是愚蠢导致的。什么熬夜看书到天亮,连续几天只睡几小时,多久没放假了。如果这些东西也值得炫耀,那么富士康流水线上任何一个人都比你努力多了。人难免天生有自怜情绪,唯有时刻保持清醒,才能看清真正的价值在哪里。<br> | ||
―――于宙 《我们这一代人的困惑》 | ||
</p> | ||
</div> | ||
<div class="box"> | ||
<h2>02</h2> | ||
<h3>Service Two</h3> | ||
<p>这些年一直在提醒自己一件事情,千万不要感动自己,大部分人看似努力,不过是愚蠢导致的。什么熬夜看书到天亮,连续几天只睡几小时,多久没放假了。如果这些东西也值得炫耀,那么富士康流水线上任何一个人都比你努力多了。人难免天生有自怜情绪,唯有时刻保持清醒,才能看清真正的价值在哪里。<br> | ||
―――于宙 《我们这一代人的困惑》 | ||
</p> | ||
</div> | ||
<div class="box"> | ||
<h2>03</h2> | ||
<h3>Service Three</h3> | ||
<p>这些年一直在提醒自己一件事情,千万不要感动自己,大部分人看似努力,不过是愚蠢导致的。什么熬夜看书到天亮,连续几天只睡几小时,多久没放假了。如果这些东西也值得炫耀,那么富士康流水线上任何一个人都比你努力多了。人难免天生有自怜情绪,唯有时刻保持清醒,才能看清真正的价值在哪里。<br> | ||
―――于宙 《我们这一代人的困惑》 | ||
</p> | ||
</div> | ||
</div> | ||
</body> | ||
</html> |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.