title: SVG filter in Firefox breaks z-index
body: <p>I am creating tabbed menu with SVG images as background. I need the the tabs to overlap each other in reverse order - first over second, second over third. And I need svg shadow, to work in Firefox.</p>
  
  <p>Howerer, when I apply the shadow, the z-index of .after element gets broken which breaks the overlap. Is there any way to change stacking order/fix this?
  Here is sample source:</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{
      background-color: grey;
      padding-top:20px;
      padding-bottom: 20px;
  }
  ul.tabs-nav{
   margin: 0px;
   padding: 0px;
   list-style-type: none;
   margin-left: 10px;
   height: 40px;
   overflow: hidden;
  }
  ul.tabs-nav li{
   margin: 0px -38px 0px 0px;
   padding: 0px;
   display: block;
   float: left;
   text-decoration: none;
   filter: url("#drop-shadow");
  }
  ul.tabs-nav li a{
   background-color: #5d6c7a;
   text-decoration: none;
   height:40px;
   line-height: 40px;
   float:left;
   color: white;
   font-size: 14px;
   vertical-align: baseline;
   padding-left: 10px;
   padding-right: 10px;
  }
  
  ul.tabs-nav span.before{
   background-image: url("https://dl.dropboxusercontent.com/u/10056766/fiddle/tab_grey.svg");
      background-position: left top;
   display: block;
   float: left;
   height: 40px;
   width: 40px;
   position: relative;  
  }
  
  ul.tabs-nav span.after{
   background-image: url("https://dl.dropboxusercontent.com/u/10056766/fiddle/tab_grey.svg");
      background-position: right top;
   display: block;
   float: left;
   height: 40px;
   width: 40px;
   position: relative;
   z-index:1;
  }
  
  ul.tabs-nav li:first-child span.before{
   background-image: url("https://dl.dropboxusercontent.com/u/10056766/fiddle/tab_white.svg");
      background-position: left top;
   display: block;
   float: left;
   height: 40px;
   width: 40px;
   position: relative;  
  }
  
  ul.tabs-nav li:first-child span.after{
   background-image: url("https://dl.dropboxusercontent.com/u/10056766/fiddle/tab_white.svg");
      background-position: right top;
   display: block;
   float: left;
   height: 40px;
   width: 40px;
   position: relative;
   z-index:1;
  }
  
  ul.tabs-nav li:first-child a{
      background-color: white;
      color: black;
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;div&gt;
  &lt;ul class="tabs-nav" style="padding: 0;"&gt;
  
   &lt;li style="z-index: 10;" class="tab
   tabs-active
   "&gt;&lt;span class="before"&gt;&lt;/span&gt;&lt;a href="/foo.jsp" class=""&gt;User&lt;/a&gt;&lt;span class="after"&gt;&lt;/span&gt;&lt;/li&gt;
   &lt;li style="z-index: 8;" class="tab
   "&gt;&lt;span class="before"&gt;&lt;/span&gt;&lt;a href="/foo.jsp" class=""&gt;Developer&lt;/a&gt;&lt;span class="after"&gt;&lt;/span&gt;&lt;/li&gt;
   &lt;li class="tab
   "&gt;&lt;span class="before"&gt;&lt;/span&gt;&lt;a href="/foo.jsp" class=""&gt;Users&lt;/a&gt;&lt;span class="after"&gt;&lt;/span&gt;&lt;/li&gt;
   &lt;li class="tab
   "&gt;&lt;span class="before"&gt;&lt;/span&gt;&lt;a href="/foo.jsp" class=""&gt;Roles&lt;/a&gt;&lt;span class="after"&gt;&lt;/span&gt;&lt;/li&gt;
   &lt;li class="tab
   "&gt;&lt;span class="before"&gt;&lt;/span&gt;&lt;a href="/foo.jsp" class=""&gt;Attributes&lt;/a&gt;&lt;span class="after"&gt;&lt;/span&gt;&lt;/li&gt;
   &lt;li class="tab
   "&gt;&lt;span class="before"&gt;&lt;/span&gt;&lt;a href="/foo.jsp" class=""&gt;Screens&lt;/a&gt;&lt;span class="after"&gt;&lt;/span&gt;&lt;/li&gt;
   &lt;li class="tab
   "&gt;&lt;span class="before"&gt;&lt;/span&gt;&lt;a href="/foo.jsp" class=""&gt;Locales&lt;/a&gt;&lt;span class="after"&gt;&lt;/span&gt;&lt;/li&gt;
   &lt;li class="tab
   "&gt;&lt;span class="before"&gt;&lt;/span&gt;&lt;a href="/foo.jsp" class=""&gt;Providers&lt;/a&gt;&lt;span class="after"&gt;&lt;/span&gt;&lt;/li&gt;
   &lt;/ul&gt;
      
  &lt;/div&gt;
  
  &lt;svg height="0" xmlns="http://www.w3.org/2000/svg"&gt;
  
  &lt;filter id="drop-shadow"&gt;
  
  &lt;feGaussianBlur in="SourceAlpha" stdDeviation="2.2"/&gt;
  
  &lt;feOffset dx="12" dy="2" result="offsetblur"/&gt;
  
  &lt;feFlood flood-color="rgba(0,0,0,0.2)"/&gt;
  
  &lt;feComposite in2="offsetblur" operator="in"/&gt;
  
  &lt;feMerge&gt;
  
  &lt;feMergeNode/&gt;
  
  &lt;feMergeNode in="SourceGraphic"/&gt;
  
  &lt;/feMerge&gt;
  
  &lt;/filter&gt;
  
  &lt;/svg&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p><a href="http://jsfiddle.net/mark_bacon/5vnefef5/3/" rel="nofollow">http://jsfiddle.net/mark_bacon/5vnefef5/3/</a></p>
  
  <p>Turn off filter of li element and you will see how it should look.</p>