How to cut out a drop shadow inside the container?
<p>The idea is to create a 2.5D effect like this</p>

<p><div class="snippet" data-lang="js" data-hide="false">
<div class="snippet-code">
<pre class="snippet-code-css lang-css prettyprint-override"><code>DIV {
  width:100px;
  height:100px;
  box-shadow: 0px 0px 5px 0px rgba(0,0,0,0.75);
  background-color:rgba(255,255,255,0.4);
  z-index:1;
  position:absolute;
  }

P{
  top:83px;
  position:absolute;
  z-index:0;
  }</code></pre>
<pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;div&gt;I appear to be layered on top&lt;/div&gt;

&lt;p&gt;Ey! Get off me!&lt;/p&gt;</code></pre>
</div>
</div>
</p>

<p>So basically a shadow around a semi-transparent rectangle. However, the dropshadow effect in WPF does not look the same as box-shadow in CSS. For one, it shadows actual opaque things that its applied on, not just a box around it. To get around that, I tried applying it on just a border like this</p>

<pre><code>    &lt;Border BorderThickness="1px" BorderBrush="Black"&gt;
        &lt;Border.Effect&gt;
            &lt;DropShadowEffect ShadowDepth="0"&gt;&lt;/DropShadowEffect&gt;
        &lt;/Border.Effect&gt;
    &lt;/Border&gt;
</code></pre>

<p>But its still different in 2 ways </p>

<ol>
<li>The visible border - thats OK, I can incorporate it into the shadow by playing with the opacity</li>
<li>The shadow is also cast on the inside of the border - not Ok, it destroys the illusion and I don't know how to fix it</li>
</ol>

<p>Would it be possible to somehow cut out the effect on the inside of the container?</p>