S
S
sfincs2019-01-18 18:32:37
css
sfincs, 2019-01-18 18:32:37

How to make a shadow at the bottom of the menu stick?

There is a site that is being done on wp, I want to make the sticky menu cast a shadow only at the bottom.
When the page is not scrolled and the meta grabs the header and fits completely into its area, then the shadow does not drop. Like this: My real menu on which I want to make a shadow (the shadow disappears when everything is fine): 5c41f07f52cb6085770439.png
When you scroll the header will go into the sunset and only the menu sticks at the top remain, then a shadow should appear at the bottom of the menu. Example : 5c41f10f16748158754478.png
As an example, a real site. I want to do something similar. Preferably without js if possible since I work on Wordpress (scroll): https://zdravcity.ru

Answer the question

In order to leave comments, you need to log in

1 answer(s)
O
Orkhan Hasanli, 2019-01-18
@sfincs

It's simple:
use CSS box-shadow
And here's a generator so you don't have to write it yourself - https://www.cssmatic.com/box-shadow
Here's an instruction on how to create a fixed header - https://www.w3schools.com/ howto/howto_js_sticky_he...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question