css实现结婚电子请帖效果

代码语言:html

所属分类:布局界面

代码描述:模拟西式请帖的布局效果

代码标签: 电子 请帖 效果

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


<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">

<style>
@import url("https://fonts.googleapis.com/css?family=Cormorant+Garamond:400,600&display=swap");
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  display: grid;
  height: 100vh;
  width: 100vw;
  justify-items: center;
  align-items: center;
  font-family: "Cormorant Garamond", serif;
  background: #D6D3D4;
}

.rsvp-container {
  margin: 0 auto;
  height: 700px;
  width: 500px;
  background: #D6D3D4;
  position: relative;
  z-index: 1;
  box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.3);
}
.rsvp-container:after {
  content: "";
  position: absolute;
  width: 400px;
  height: 600px;
  left: 50px;
  top: 50px;
  background: #fff;
  z-index: 1;
}
.rsvp-container:before {
  content: "";
  position: absolute;
  width: 100%;
  height: 100%;
  background: url("http://repo.bfw.wiki/bfwrepo/image/5e6189e5ee88c.png") center center no-repeat;
  background-size: cover;
  z-index: 3;
}

.rsvp-inner-container {
  position: relative;
  z-index: 4;
  padding: 130px;
}

h1 {
  font-size: 28px;
  font-weight: semi-bold;
  margin: 30px 0 5px 0;
}

h2 {
  font-size: 18px;
  margin: 0 0 20px 0;
  font-weight: normal;
}

fieldset {
  border: 0;
  margin-bottom: 20px;
}

.full-width label:nth-of-type(1) {
  display: block;
  font-size: 18px;
}

.full-width input {
  border: 0;
  border-bottom: 2px solid rgba(0, 0, 0, 0.5);
  width: 100%;
  line-height: 28px;
  font-size: 14px;
  outline: none;
  background: transparent;
}

.half-width label {
  display: inline-block;
  margin-right: 20px;
  line-height: 28px;
  font-size: 18px;
}

.half-width input {
  border: 0;
  border-bottom: 2px solid rgba(0, 0, 0, 0.5);
  line-height: 28px;
  font-size: 14px;
  outline: none;
  width: 70px;
  text-align: center;
}

.checkbox input {
  border: 2px solid rgba(0, 0, 0, 0.5);
  height: 28px;
  width: 28px;
  background-color: transparent !important;
}

/* The container */
.container {
  display: block;
  position: relative;
  padding-left: 35px;
  margin-bottom: 12px;
  cursor: pointer;
  font-size: 18px;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  line-height: 28px;
}

/* Hide the browser's default checkbox */
.container input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

/* Create a custom checkbox */
.checkmark {
  position: absolute;
  top: 0;
  left: 0;
  height: 27px;
  width: 27px;
  bac.........完整代码请登录后点击上方下载按钮下载查看

网友评论0