Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to make shadows with CSS3
#1
Example:

<!DOCTYPE html>
<html>
<head>
  <title>Shadows Example</title>
  <style>
    /* Apply a box shadow to the div element */
    div {
      width: 200px;
      height: 100px;
      background-color: lightblue;
      box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.5);
    }
  </style>
</head>
<body>
  <div>This div has a shadow.</div>
</body>
</html>

Explanation:

CSS box-shadow property is used to create a shadow effect for an element. In this example, the div element has a light blue background color and a box shadow with horizontal and vertical offsets of 5 pixels each, a blur radius of 10 pixels, and a shadow color defined using RGBA notation.
Also follow me on Youtube for videos about video games:
https://www.youtube.com/channel/UCxfkGVU...2mQ/videos
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  How to make a grid layout with CSS3 Qomplainerz 0 200 07-26-2023, 07:03 PM
Last Post: Qomplainerz
  How to make a flexbox in CSS3 Qomplainerz 0 212 07-26-2023, 07:02 PM
Last Post: Qomplainerz
  How to make animations with CSS3 Qomplainerz 0 200 07-26-2023, 07:01 PM
Last Post: Qomplainerz
  How to make transitions with CSS3 Qomplainerz 0 221 07-26-2023, 06:59 PM
Last Post: Qomplainerz
  How to make gradients with CSS3 Qomplainerz 0 188 07-26-2023, 06:57 PM
Last Post: Qomplainerz
  How to make rounded corners with CSS3 Qomplainerz 0 167 07-26-2023, 06:51 PM
Last Post: Qomplainerz

Forum Jump:


Users browsing this thread: 1 Guest(s)