Grow your business, income, & life

20+ yrs of experience to offer you education and business services that launch and grow your business

CSS3 Tutorial for Beginners: 40 Inserting A Box Shadow

This is Sasha and thanks for joining me here for another CSS training video where I share with you how to modify and manipulate your business page when it comes to CSS. It’s convenient if you have an online business. Now today, we’re going to take a look at the box-shadow property, and I’ll show you how to use it and how I use it. Let’s take a quick look.

What I’ve done here to illustrate this example, I have a div that’s a wrap and then a UL menu. We have an unordered list with three little menu items. That’s the only HTML that we have happening. Pretty much everything else is the menu except this wrap.

This is the div wrap that I have right there set up. The thing you need to pay attention to really is just this one line, and it’s this box shadow line, and here I have offset X offset Y, and then there’s a blur radius, and then you can choose your color. That’s the structure of this rule, the way that it’s set up with these attributes.

--------------------- HTML CODE ------------------

 

 

 

 

 

 


--------------------- CSS CODE ------------------

body {margin:30px 0;}

.wrap {
	display: block;
	background: #42c494;
	overflow: auto;
	margin: 0 auto;
	width: 400px;
	
	/* offset-x | offset-y | blur-radius | color */
	box-shadow: 3px 3px 5px #3a3a3a;
}

.menu {
	list-style: none;
	margin:0; padding:0;
}

.menu li {
	float:left;
	font-family: gotham;
	color: #fff;
	padding: 15px 20px;
	cursor: pointer;
	border-right: 1px solid #ccc;
	text-shadow: 0px 0px 2px #1f705a;
}


What you do is if you’re looking to create this little box shadow and you can probably see it right under the menu right there, typically when I span this menu, the reason I’ve done it only 400 is so that you could see the box shadow. But if I remove that, when I span that menu, you can see a little drop-down, and it’s convenient for that little shadow to show up right there.

What you can do is I can bump this to let’s say 12 pixels on the X, 12 on the Y and then 5 pixels on the blur. If I did only the X, let me go ahead and put the width back for you so you can see it in all directions to make it a little bit easier. If I did 22 on the X, you could see it moves that box shadow. If I did, let’s bring that back, if I did, let’s say, 40 on the Y, you can see it moves it down.

--------------------- HTML CODE ------------------

 

 

 

 

 

 


--------------------- CSS CODE ------------------

body {margin:30px 0;}

.wrap {
	display: block;
	background: #42c494;
	overflow: auto;
	margin: 0 auto;
	width: 400px;
	
	/* offset-x | offset-y | blur-radius | color */
	box-shadow: 12px 42px 5px #3a3a3a;
}

.menu {
	list-style: none;
	margin:0; padding:0;
}

.menu li {
	float:left;
	font-family: gotham;
	color: #fff;
	padding: 15px 20px;
	cursor: pointer;
	border-right: 1px solid #ccc;
	text-shadow: 0px 0px 2px #1f705a;
}


Y is up and down, X is left and right. Also, the other thing is this blur. How does this blur work? Well, if I have 5, it’s just a slight blur. If I have let’s say 15, you can see how it blurs that much more, okay? That’s adding a little bit of shadow.

--------------------- HTML CODE ------------------

 

 

 

 

 

 


--------------------- CSS CODE ------------------

body {margin:30px 0;}

.wrap {
	display: block;
	background: #42c494;
	overflow: auto;
	margin: 0 auto;
	width: 400px;
	
	/* offset-x | offset-y | blur-radius | color */
	box-shadow: 12px 12px 15px #3a3a3a;
}

.menu {
	list-style: none;
	margin:0; padding:0;
}

.menu li {
	float:left;
	font-family: gotham;
	color: #fff;
	padding: 15px 20px;
	cursor: pointer;
	border-right: 1px solid #ccc;
	text-shadow: 0px 0px 2px #1f705a;
}


How do I personally use it? Well, typically in menus, I do – sometimes a very soft shadow so I might do 5 pixels, it might be even 2 pixels or something like that, and then my blur might let’s say, maybe 4 pixels. You can see that slight little edge on the bottom and then I don’t usually use a hard color.

I do something very soft. You can see it right there under that menu because if I get rid of this, I’ll show you what that looks like, it’s just flat. It’s a flat view. If I add just a slight little shadow, it gives that bit effect and sometimes it’s convenient, you know, to split or provide a small dimension. That’s one way of doing things.

--------------------- HTML CODE ------------------

 

 

 

 

 

 


--------------------- CSS CODE ------------------

body {margin:30px 0;}

.wrap {
	display: block;
	background: #42c494;
	overflow: auto;
	margin: 0 auto;
	width: 400px;
	
	/* offset-x | offset-y | blur-radius | color */
	box-shadow: 2px 2px 4px #ccc;
}

.menu {
	list-style: none;
	margin:0; padding:0;
}

.menu li {
	float:left;
	font-family: gotham;
	color: #fff;
	padding: 15px 20px;
	cursor: pointer;
	border-right: 1px solid #ccc;
	text-shadow: 0px 0px 2px #1f705a;
}


There’s also a few other variations that you could do with this. For example if you’re looking for a color of, let’s just say, using RGB values and then alpha based values, so you could see I can do transparency. Let’s just do 0.5. You could right there, I could have a little bit of a transparent area with RGB A values.

--------------------- HTML CODE ------------------

 

 

 

 

 

 


--------------------- CSS CODE ------------------

body {margin:30px 0;}

.wrap {
	display: block;
	background: #42c494;
	overflow: auto;
	margin: 0 auto;
	width: 400px;
	
	/* offset-x | offset-y | blur-radius | color */
	box-shadow: 2px 2px 2px 1px rgba(0, 0, 0, 0.5);
}

.menu {
	list-style: none;
	margin:0; padding:0;
}

.menu li {
	float:left;
	font-family: gotham;
	color: #fff;
	padding: 15px 20px;
	cursor: pointer;
	border-right: 1px solid #ccc;
	text-shadow: 0px 0px 2px #1f705a;
}


I could also do a box shadow inset, okay? Here’s a little bit of inset and I’m going to change this to 0.3 and 0.3 and make it gold and you can see that gets on the inside there. Now, when I roll over naturally that changes because I have hover property on there, but you can see the inside effect that happens and, let’s see, another one I want to show you and that is to create multiple box shadows.

--------------------- HTML CODE ------------------

 

 

 

 

 

 


--------------------- CSS CODE ------------------

body {margin:30px 0;}

.wrap {
	display: block;
	background: #42c494;
	overflow: auto;
	margin: 0 auto;
	width: 400px;
	
	/* offset-x | offset-y | blur-radius | color */
	box-shadow: inset .3em .3em gold;
}

.menu {
	list-style: none;
	margin:0; padding:0;
}

.menu li {
	float:left;
	font-family: gotham;
	color: #fff;
	padding: 15px 20px;
	cursor: pointer;
	border-right: 1px solid #ccc;
	text-shadow: 0px 0px 2px #1f705a;
}


Here, if we do read and let’s make this blue, okay? You could see if I zoom out, I could create multiple box shadows, and the way that these works is you do one box shadow separate it by a comma and create a second one or a third one or a fourth one and that creates multiple box shadows for you.

The great thing here, of course, with multiple box-shadow is you could go ahead and, you know, change the colors to whatever you want. I could make it a green color there. I could also use the same kind of manipulation, you know, as far as the movement, the blur amount, let’s say here -1, let’s say 0.5 em on that one and 0.5 em there.

--------------------- HTML CODE ------------------

 

 

 

 

 

 


--------------------- CSS CODE ------------------

body {margin:30px 0;}

.wrap {
	display: block;
	background: #42c494;
	overflow: auto;
	margin: 0 auto;
	width: 400px;
	
	/* offset-x | offset-y | blur-radius | color */
	box-shadow: 3px 3px red, -1em 0 0.4em blue;
}

.menu {
	list-style: none;
	margin:0; padding:0;
}

.menu li {
	float:left;
	font-family: gotham;
	color: #fff;
	padding: 15px 20px;
	cursor: pointer;
	border-right: 1px solid #ccc;
	text-shadow: 0px 0px 2px #1f705a;
}


You can see I can overlay those or if I do a negative, you can do a negative. You can have a box shadow at the top, on the left, on the bottom, on the right. It creates that effect.

If you ultimately want kind of like a glowing shadow, you could do, let’s say, maybe 0 pixels and 0 pixels and then you have a 5 and then you get kind of this glow effect. You could do maybe 15, and you can see how that creates that kind of glow effect box around that one.

--------------------- HTML CODE ------------------

 

 

 

 

 

 


--------------------- CSS CODE ------------------

body {margin:30px 0;}

.wrap {
	display: block;
	background: #42c494;
	overflow: auto;
	margin: 0 auto;
	width: 400px;
	
	/* offset-x | offset-y | blur-radius | color */
	box-shadow: 0px 0px 15px red;
}

.menu {
	list-style: none;
	margin:0; padding:0;
}

.menu li {
	float:left;
	font-family: gotham;
	color: #fff;
	padding: 15px 20px;
	cursor: pointer;
	border-right: 1px solid #ccc;
	text-shadow: 0px 0px 2px #1f705a;
}


There’s a lot of ways to use this box-shadow property. It just comes down to what you’re trying to do. As you can see, there’s a subtle view right there. We’ll make it a little darker so you could see it. It creates a bit glow around that.

That’s the box-shadow property, and it’s convenient to add subtle effects. I don’t recommend you do it, you know, very strong unless you’re looking to do that for a purpose. For example, I try to avoid things that are very stiff like that in here unless, of course, your design calls for it.

Download our online toolbox for free! Simply click the get it now button below and see the must-have tools for online business owners!

Struggling to make your blog business profitable? Want to turn your hobby blog into an income-generating blog? Learn the right way to plan a highly successful and profitable blog business.

Learn how to create Pinterest Pins that are attractive, click-worthy, and make people want to click your Pins! Great skill to have to promote your content or make side-income designing Pinterest Pins for others.

Get Notified When This Freebie Comes Out! - It Shouldn't Be Long... 

Just enter your email address below and be first to get notified when we release this freebie!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Get MyOnline Business Toolbox
 

Had enough of the expensive and useless online business tools?

 

Stop wasting your money and time and get my list of awesome business tools.

 

Just enter your email address below so we know where to send it.

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Get Notified When This Freebie Comes Out! - It Shouldn't Be Long... 

Just enter your email address below and be first to get notified when we release this freebie!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Video Gear Guide for YouTubers

Are you ready to improve your YouTube channel? If you want to see the best YouTube gear for YouTubers, then download my latest gear guide!

 

Enter your email below to get started...

FREE DOWNLOAD

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Get Notified When This Freebie Comes Out! - It Shouldn't Be Long... 

Just enter your email address below and be first to get notified when we release this freebie!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Get Notified When This Freebie Comes Out! - It Shouldn't Be Long... 

Just enter your email address below and be first to get notified when we release this freebie!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Get Notified When This Freebie Comes Out! - It Shouldn't Be Long... 

Just enter your email address below and be first to get notified when we release this freebie!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Get Notified When This Freebie Comes Out! - It Shouldn't Be Long... 

Just enter your email address below and be first to get notified when we release this freebie!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Get Notified When This Freebie Comes Out! - It Shouldn't Be Long... 

Just enter your email address below and be first to get notified when we release this freebie!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Get Notified When This Freebie Comes Out! - It Shouldn't Be Long... 

Just enter your email address below and be first to get notified when we release this freebie!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Get Notified When This Freebie Comes Out! - It Shouldn't Be Long... 

Just enter your email address below and be first to get notified when we release this freebie!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Get Notified When This Freebie Comes Out! - It Shouldn't Be Long... 

Just enter your email address below and be first to get notified when we release this freebie!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Get Notified When This Freebie Comes Out! - It Shouldn't Be Long... 

Just enter your email address below and be first to get notified when we release this freebie!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Wow! Get Ready to Start your Online Business Journey!

Just enter your email address below and be one of the fast growing online businesses roght now!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Get Notified When This Freebie Comes Out! - It Shouldn't Be Long... 

Just enter your email address below and be first to get notified when we release this freebie!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Want to Create Videos that Convert Viewers into Buyers?

Are you tired of making videos that don't produce results?

 

Get my Video Formula cheat sheet and see how to create videos that get clicks and attracts buyers!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Download My Youtube Video Creation Checklist for FREE...
 

Overwhelmed by number of tasks that you need to do to make high-quality YouTube videos?

 

Then grab this YouTube Video Creation Checklist if a strategic procedure list for producing your YouTube videos.

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Download My List of The 125 Most Profitable YouTube Niches

This is a List of the 125 Most Profitable YouTube Niches that might be a real eye-opener for you.


Sign up for FREE and gain some extraordinary ideas...

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Profit from My 35 Local Strategies to Make Extra Money
 

Are you interested in making some money on the side? That don't need to be extra hard.

 

You can use My 35 Local Strategies to Make Extra Money and in seriously short time reap the benefits.

 

Grab this opportunity by entering your email below...

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

FREE Guide to the Best Cameras for a Youtuber

Eager to find out which cameras are the top choices to producing and recording videos?

 

Grab my FREE Guide below by entering your email address... 

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

225 Profitable Pinterest Niches

Are you interested in learning which Pinterest niches are profitable?

 

Grab our FREE Pinterest Niche Guide by entering your email below

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

How to Get Started Selling Your Own Digital Products

Get my free mini-series by entering your email address below

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Want to Find a Profitable Niche?

If you are interested in starting an online business and want to find the perfect niche to start making tons of money.

 

Then grab our FREE email series on how to find a highly profitable niche!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Want to Get My Quick-Start Guide to Build Your Empire?

If you are interested in starting your own online business and making money online.

 

Then grab our quick email series on how to start a profitable business fast!

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Learn How to Get Thousands of

Visitors to Your Website
 

This FREE email series will show you exactly how to get thousands of real visitors to your website even if you are an absolute beginner.

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

5,000 SUBSCRIBERS

Derek will teach you simple tactics to attract life-long customers through real-world examples.

FOR FREE?

Want to learn how to get

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Download My List of The 125 Most Profitable YouTube Niches

Get my list of the 125 Most Profitable YouTube Niches. It will be an eye-opener for you!


Sign up for FREE and get extraordinary ideas...

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

Download My List of The 125 Most Profitable YouTube Niches

Get my list of the 125 Most Profitable YouTube Niches. It will be an eye-opener for you!


Sign up for FREE and get extraordinary ideas...

AWESOME!

In order for you to get your goodies and freebies you have to confirm your email address.

 

To confirm your email address, just go to your email inbox (or check your spam) and click the link that's inside the email that states you want to receive messages from us.

 

That's its!

Just one more thing... 

don't call us.
we will coconut
you

organic pop up market store is heading your way​