JSFiddle - React, Tailwind, and code Playground

HTML

<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width">
  <title>JS Bin</title>
</head>
<body>
<div class="header">test</div>
  <div class="slider"></div>
</body>
</html>

CSS

body{
  padding: 0px;
}

.header{
  height: 20px;
  background-color: red;  
  position: relative;
  z-index: 1000;
}

.slider{
  position: relative;
  z-index: 1;
  height: 300px;
  background-color: grey;
}

.slider::before {
  box-shadow: 0 2px 8px #000;
  content: "";
  position: absolute;
  top: -8px;
  width: 100%;
  height: 8px;
}