olute;
    height: 300px;
    width: 300px;
    margin: 50px;
    border: 1px solid blue;
    transform-style: preserve-3d;
  }

  #card {
    position: absolute;
    top: 50px;
    left: 50px;
    height: 200px;
    width: 200px;
    background-color: #81AA8A;
    transform-origin: right top;
    transform: rotateY(45deg);
  }

  #card:hover {
    background-color: orange;
  }
</style>

<body>
  <div id="scene">
    <div id="container">
      <div id="card"></div>
    </div>
  </div>
</body>

<script>
  cl