Can this be done?
How can I make the middle of the background completely transparent?
This would make the middle part transparent, and would have nothing applied to it.
https://jsfiddle.net/racsob9v/
It looks like this now.
I'm trying to do this.
html,
body {
height: 100%;
padding: 0;
margin: 0;
}
body {
background: url(https://picsum.photos/id/1015/1500/1500) no-repeat;
background-attachment: fixed;
background-size: cover;
}
.outer {
display: table;
height: 100%;
margin: 0 auto;
width: 100%;
overflow: hidden;
}
.tcell {
display: table-cell;
vertical-align: middle;
padding: 8px 8px;
}
.curtain {
max-width: 640px;
margin: auto;
border: 15px solid transparent;
border-radius: 12px;
background: linear-gradient(to bottom right, gray, black), url("https://i.imgur.com/pwdit9N.png"), linear-gradient(to bottom right, #eee, #ccc);
background-origin: padding-box, border-box, border-box;
background-clip: padding-box, border-box, border-box;
box-shadow: 0 -1px white, 0 -1px 0 1px #bbb, 0 2px 0 1px #aaa, 0 2px 10px 1px rgb(0 0 0 / 20%);
}
.curtain-ratio-keeper {
position: relative;
width: 100%;
height: 0;
padding-top: 56.25%;
overflow: hidden;
background: transparent;
}
<div class="outer">
<div class="tcell">
<div class="curtain">
<div class="curtain-ratio-keeper">
</div>
</div>
</div>
</div>