<!DOCTYPE html>
<base href="http://www.example.com/">
<svg>
  <mask id="mask">
    <rect y="50" width="100" height="50" fill="white"/>
  </mask>
  <rect width="100" height="50" fill="green"/>
  <g mask="url(#mask)">
    <rect width="100" height="50" fill="red"/>
    <rect y="50" width="100" height="50" fill="green"/>
  </g>
</svg>
