Css curve shadow

Source: Internet
Author: User

Css curve shadow
Let's take a look at what we want to achieve

The principle is very simple. It is to generate the effect we see through the shadow superposition of several elements. It mainly applies the shadow style and the before and after elements, and directly goes to the Code: <喎?http: www.bkjia.com kf ware vc " target="_blank" class="keylink"> VcD4NCjxwPjxzdHJvbmc + aHRtbCC0 + sLro7o8L3N0cm9uZz48L3A + DQo8cHJlIGNsYXNzPQ = "brush: java;"> shadow effect

Css style code:

/*** Author: Qingtian tip; */body, h1, ul, li {margin: 0; padding: 0 ;}body {font-family: Arial; font-size: 20px;} ul, li {list-style: none ;}. wrap {width: 50%; height: 200px; background-color: # fff; margin: 50px auto; position: relative ;}. wrap h1 {line-height: 200px; text-align: center; font-size: 20px ;}. effect {-webkit-box-shadow: 0px 1px 4px rgba (0, 0, 0 ,. 3), 0px 0px 40px rgba (0, 0, 0 ,. 1) inset;-moz-box-shadow: 0px 1px 4px rgba (0, 0, 0 ,. 3), 0px 0px 40px rgba (0, 0, 0 ,. 1) inset;-o-box-shadow: 0px 1px 4px rgba (0, 0, 0 ,. 3), 0px 0px 40px rgba (0, 0, 0 ,. 1) inset;-mz-box-shadow: 0px 1px 4px rgba (0, 0, 0 ,. 3), 0px 0px 40px rgba (0, 0, 0 ,. 1) inset; box-shadow: 0px 1px 4px rgba (0, 0, 0 ,. 3), 0px 0px 40px rgba (0, 0, 0 ,. 1) inset ;}. effect: before ,. effect: after {content:; background-color: red; position: absolute; z-index:-1; left: 10px; right: 10px; top: 50%; bottom: 0px; -webkit-box-shadow: 0px 0px 20px rgba (0, 0, 0 ,. 8);-moz-box-shadow: 0px 0px 20px rgba (0, 0, 0 ,. 8);-o-box-shadow: 0px 0px 20px rgba (0, 0, 0 ,. 8);-mz-box-shadow: 0px 0px 20px rgba (0, 0, 0 ,. 8); box-shadow: 0px 0px 20px rgba (0, 0, 0 ,. 8); border-radius: 50px ;}

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.