| <!DOCTYPE html> |
| <html> |
| <head> |
| <style> |
| .outer { |
| width: 100px; |
| height: 100px; |
| -webkit-box-reflect: below 10px; |
| } |
| |
| .inner { |
| width: 100px; |
| height: 100px; |
| -webkit-box-reflect: right 10px; |
| background-color: green; |
| will-change: transform; |
| -webkit-mask-image: linear-gradient(-45deg, black, transparent); |
| mask-image: linear-gradient(-45deg, black, transparent); |
| } |
| |
| .child { |
| position: relative; |
| top: 100px; |
| left: 100px; |
| width: 100px; |
| height: 100px; |
| background-color: blue; |
| } |
| </style> |
| </head> |
| <body> |
| <p>You should see four mirrored square boxes with linear gradient green.</p> |
| <div class="outer"> |
| <div class="inner"> |
| <div class="child"> |
| </div> |
| </div> |
| </div> |
| </body> |
| </html> |