HTML、CSS招财猫

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

	<head>

		<meta charset="UTF-8">

		<link rel="apple-touch-icon" type="image/png"
			href="https://cpwebassets.codepen.io/assets/favicon/apple-touch-icon-5ae1a0698dcc2402e9712f7d01ed509a57814f994c660df9f7a952f3060705ee.png" />
		<meta name="apple-mobile-web-app-title" content="CodePen">

		<link rel="shortcut icon" type="image/x-icon"
			href="https://cpwebassets.codepen.io/assets/favicon/favicon-aec34940fbc1a6e787974dcd360f2c6b63348d4b1f4e06c77743096d55480f33.ico" />

		<link rel="mask-icon" type="image/x-icon"
			href="https://cpwebassets.codepen.io/assets/favicon/logo-pin-8f3771b1072e3c38bd662872f6b673a722f4b3ca2421637d5596661b4e2132cc.svg"
			color="#111" />


		<title>新年快乐</title>




		<style>
			body {
				background-color: darkslategrey;
			}

			.wrapper {
				display: flex;
				width: 100%;
				height: 100%;
				margin-top: 20px;
				flex-direction: column;
				justify-content: center;
				align-items: center;
			}

			.container {
				position: relative;
				width: 340px;
				display: flex;
				justify-content: space-between;
				flex-direction: column;
				/*   transform: scale(0.5); */
			}

			.ears {
				display: flex;
				width: 100%;
				justify-content: space-between;
			}

			.ear-left-out {
				height: 110px;
				width: 110px;
				border: solid 8px black;
				background-color: white;
				border-radius: 26% 74% 72% 28% / 28% 38% 62% 72%;
				position: relative;
				transform: rotate(3deg);
			}

			.ear-left-inner {
				height: 60px;
				position: absolute;
				top: 30px;
				left: 30px;
				width: 60px;
				background-color: #DF4A63;
				border-radius: 26% 74% 72% 28% / 28% 38% 62% 72%;
				border: solid 8px black;
			}

			.ear-right-out {
				height: 110px;
				width: 110px;
				border: solid 8px black;
				background-color: white;
				border-radius: 26% 74% 72% 28% / 28% 38% 62% 72%;
				position: relative;
				transform: rotate(84deg);
			}

			.ear-right-inner {
				height: 60px;
				position: absolute;
				top: 30px;
				right: 30px;
				width: 60px;
				background-color: #DF4A63;
				border-radius: 26% 74% 72% 28% / 28% 38% 62% 72%;
				transform: rotate(88deg);
				border: solid 8px black;
			}

			.head {
				height: 250px;
				width: 300px;
				top: 10px;
				left: 10px;
				border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
				border: solid 8px black;
				background-color: white;
				position: absolute;
				z-index: 2;
			}

			.eyes {
				display: flex;
				justify-content: space-around;
				padding-top: 85px;
				height: 35px;
			}

			.eye-left::after {
				content: ' ';
				position: absolute;
				height: 12px;
				display: inline-block;
				width: 12px;
				left: 1px;
				top: 0px;
				background-color: black;
				border-radius: 61%;
			}

			.eye-left::before {
				content: ' ';
				position: absolute;
				height: 12px;
				display: inline-block;
				width: 12px;
				right: 1px;
				top: 0px;
				background-color: black;
				border-radius: 61%;
			}

			.eye-left {
				z-index: 1;
				width: 74px;
				height: 74px;
				border: 12px solid;
				border-color: black transparent transparent transparent;
				-webkit-border-radius: 50%;
				-moz-border-radius: 50%;
				border-radius: 50%;
				-webkit-transform: rotate(30deg);
				-moz-transform: rotate(30deg);
				transform: rotate(3deg);
			}

			.eye-right::after {
				content: ' ';
				position: absolute;
				height: 12px;
				display: inline-block;
				width: 12px;
				left: 1px;
				top: 0px;
				background-color: black;
				border-radius: 61%;
			}

			.eye-right::before {
				content: ' ';
				position: absolute;
				height: 12px;
				display: inline-block;
				width: 12px;
				right: 1px;
				top: 0px;
				background-color: black;
				border-radius: 61%;
			}

			.eye-right {
				z-index: 1;
				width: 74px;
				height: 74px;
				border: 12px solid;
				border-color: black transparent transparent transparent;
				-webkit-border-radius: 50%;
				-moz-border-radius: 50%;
				border-radius: 50%;
				-webkit-transform: rotate(30deg);
				-moz-transform: rotate(30deg);
				transform: rotate(-3deg);
			}

			.face-center {
				display: flex;
				width: 100%;
			}

			.face-wrapper {
				/*   position: relative;   */
			}

			.mustache-left {
				background-color: black;
				width: 50px;
				height: 8px;
				border-radius: 7% 93% 93% 7% / 47% 53% 47% 53%;
				position: absolute;
				top: 140px;
				left: 14px;
			}

			.mustache-right-bottom {
				background-color: black;
				width: 50px;
				height: 8px;
				border-radius: 93% 7% 7% 93% / 53% 47% 53% 47%;
				position: absolute;
				top: 155px;
				left: 240px;
				transform: rotate(8deg);
			}

			.mustache-right {
				background-color: black;
				width: 50px;
				height: 8px;
				border-radius: 93% 7% 7% 93% / 53% 47% 53% 47%;
				position: absolute;
				top: 140px;
				left: 240px;
			}

			.mustache-left-bottom {
				background-color: black;
				width: 50px;
				height: 8px;
				border-radius: 7% 93% 93% 7% / 47% 53% 47% 53%;
				position: absolute;
				top: 155px;
				left: 14px;
				transform: rotate(-8deg);
			}

			.nose {
				position: absolute;
				top: 130px;
				left: 135px;
				height: 20px;
				width: 35px;
				background-color: black;
				border-radius: 46% 54% 49% 51% / 66% 65% 35% 34%;
			}

			.mouth {
				position: absolute;
				z-index: 1;
				top: 110px;
				left: 80px;
				width: 60px;
				height: 60px;
				border: 8px solid;
				border-color: transparent black black transparent;
				-webkit-border-radius: 50%;
				-moz-border-radius: 50%;
				border-radius: 50%;
				-webkit-transform: rotate(30deg);
				-moz-transform: rotate(30deg);
				transform: rotate(45deg);
			}

			.mouth-right {
				position: absolute;
				z-index: 1;
				top: 110px;
				left: 147px;
				width: 60px;
				height: 60px;
				border: 8px solid;
				border-color: transparent black black transparent;
				-webkit-border-radius: 50%;
				-moz-border-radius: 50%;
				border-radius: 50%;
				-webkit-transform: rotate(30deg);
				-moz-transform: rotate(30deg);
				transform: rotate(45deg);
			}

			.necklace {
				height: 95px;
				background-color: #DF4A63;
				margin-top: 70px;
				border-radius: 50% 50% 50% 50% / 0% 0% 100% 100%;
				width: 250px;
				align-self: center;
				border: solid 8px black;
				position: relative;
				z-index: 1;
			}

			.bell {
				background-color: #F9D552;
				border-radius: 50%;
				position: absolute;
				top: 82px;
				left: 90px;
				height: 50px;
				width: 50px;
				border: solid 8px black;
			}

			.reflect {
				height: 13px;
				width: 20px;
				background-color: white;
				border-radius: 50%;
				position: absolute;
				top: 5px;
				right: 9px;
				transform: rotate(25deg);
			}

			.bell:before {
				content: '';
				height: 16px;
				width: 16px;
				border-radius: 50%;
				background-color: black;
				position: absolute;
				bottom: 3px;
				left: 18px;
			}

			.bell:after {
				content: '';
				height: 15px;
				width: 8px;
				background-color: black;
				position: absolute;
				bottom: 0px;
				left: 22px;
			}

			.arm-top-left-wrapper {
				z-index: 0;
			}

			.arm-top-left {
				position: absolute;
				display: flex;
				top: 200px;
				width: 220px;
				left: 6px;
				height: 240px;
				background: #fff;
				border: 8px solid black;
				transform: rotate(50deg);
				border-radius: 50%;
				border-color: transparent transparent black black;
			}

			.arm-top-left-tip:after {
				content: '';
				position: absolute;
				height: 67px;
				width: 49px;
				background: white;
				border-radius: 50%;
				bottom: -21px;
				left: 17px;
				transform: rotate(17deg);
			}

			.arm-top-left-tip {
				left: 70px;
				bottom: 132px;
				position: absolute;
				display: flex;
				z-index: 1;
				background: white;
				width: 68px;
				height: 60px;
				border: 8px solid black;
				transform: rotate(92deg);
				border-radius: 50%;
				border-color: black black transparent black;
			}

			@keyframes arm-right {
				0% {
					transform: rotate(35deg);
					transform-origin: center;
				}

				50% {
					transform-origin: left;
					transform: rotate(35deg) translateY(-10px) translateX(-10px) scaleY(0.8);
				}

				100% {
					transform-origin: center;
					transform: rotate(35deg);
				}
			}

			.arm-top-right {
				position: absolute;
				display: flex;
				z-index: -1;
				top: 132px;
				width: 106px;
				right: -26px;
				height: 200px;
				background: #fff;
				border: 8px solid black;
				transform: rotate(35deg);
				border-radius: 50%;
				border-color: transparent black transparent transparent;
				animation: arm-right 1.5s both infinite;
			}

			@keyframes arm-tip-right {
				0% {
					top: 128px;
				}

				50% {
					top: 175px;
				}

				100% {
					top: 128px;
				}
			}

			.arm-top-right-tip {
				position: absolute;
				display: flex;
				z-index: 0;
				/*       transform: rotate(-15deg); */
				/*     top: 128px; */
				top: 175px;
				right: -66px;
				width: 85px;
				background: white;
				height: 60px;
				border: 8px solid black;
				border-radius: 50%;
				border-color: black black black transparent;
				animation: arm-tip-right 1.5s both infinite;
			}

			.back-legs {
				width: 100%;
				height: 200px;
				position: relative;
				display: flex;
				justify-content: space-between;
			}

			.back-leg-left {
				width: 120px;
				height: 180px;
				z-index: -2;
				border-radius: 53% 47% 50% 50% / 59% 61% 39% 41%;
				background-color: white;
				position: relative;
				padding-top: 30px;
				border: solid 8px black;
				border-color: transparent transparent transparent black;
				transform: rotate(10deg);
			}

			.back-leg-right {
				width: 120px;
				height: 180px;
				z-index: -2;
				border-radius: 47% 53% 50% 50% / 61% 59% 41% 39%;
				background-color: white;
				position: relative;
				padding-top: 30px;
				border: solid 8px black;
				border-color: black black transparent transparent;
				transform: rotate(-10deg);
			}

			.paws {
				position: relative;
				width: 100%;
				height: 100px;
				margin-top: -28px;
				display: flex;
				justify-content: space-between;
			}

			.paw-left {
				height: 60px;
				width: 100px;
				margin-right: 4px;
				border-radius: 47% 53% 50% 50% / 60% 60% 40% 40%;
				border: solid 8px black;
				background-color: white;
			}

			.paw-right {
				height: 60px;
				width: 100px;
				margin-left: 4px;
				border-radius: 47% 53% 50% 50% / 60% 60% 40% 40%;
				border: solid 8px black;
				background-color: white;
			}

			.gold {
				height: 217px;
				width: 136px;
				background: #F9D552;
				border: solid 8px black;
				left: 115px;
				bottom: 8px;
				border-radius: 61px;
				position: absolute;
				transform: rotate(45deg);
			}

			.gold:after {
				content: '';
				height: 50px;
				width: 22px;
				border-radius: 50%;
				background: white;
				position: absolute;
				transform: rotate(45deg);
				top: 4px;
				left: 17px;
			}

			.carving {
				position: absolute;
				display: inline-block;
				font-family: 'Ma Shan Zheng', cursive;
				z-index: 1;
				top: 26px;
				left: 40px;
				width: 50px;
				font-size: 40px;
				font-weight: 600;
				line-height: 40px;
				color: red;
			}
		</style>

		<script>
			window.console = window.console || function(t) {};
		</script>



		<script>
			if (document.location.search.match(/type=embed/gi)) {
				window.parent.postMessage("resize", "*");
			}
		</script>


	</head>

	<body translate="no">
		<link rel="stylesheet" type="text/css" href="https://fonts.googleapis.com/css?family=Ma Shan Zheng" />

		<div class="wrapper">
			<div class="container">
				<div class="ears">
					<div class="ear-left-out"></div>
					<div class="ear-left-inner"></div>
					<div class="ear-right-out"></div>
					<div class="ear-right-inner"></div>
				</div>
				<div class="head">
					<div class="eyes">
						<div class="eye-left"></div>
						<div class="eye-right"></div>
					</div>
					<div class="face-center">
						<div class="face-wrapper">
							<div class="mustache-left"></div>
							<div class="mustache-left-bottom"></div>
						</div>
						<div class="face-wrapper">
							<div class="mustache-right"></div>
							<div class="mustache-right-bottom"></div>
						</div>
						<div class="face-wrapper">
							<div class="nose"></div>
							<div class="mouth"></div>
							<div class="mouth-right"></div>
						</div>
					</div>
				</div>
				<div class="necklace">
					<div class="bell">
						<div class="reflect"> </div>
					</div>
				</div>
				<div class="arm-top-left-wrapper">
					<div class="arm-top-left"></div>
					<div class="arm-top-left-tip">
					</div>
					<div class="gold">
						<span class="carving">
							新年快乐
						</span>
					</div>

				</div>
				<div class="arm-top-right"></div>
				<div class="arm-top-right-tip"></div>
				<div class="back-legs">
					<div class="back-leg-left"></div>
					<div class="back-leg-right"></div>
				</div>
				<div class="paws">
					<div class="paw-left"></div>
					<div class="paw-right"></div>
				</div>
			</div>
		</div>





	</body>

</html>

 

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

喜欢爱笑的女孩子

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值