#editor2d-container {
  position: relative;
  display: none;
  z-index: 9;
  width: 50%;
  height: 100vh;
  overflow: hidden;
  background-color: var(--primary-color);
}

#editor2d-container.expand {
  position: fixed;
  width: 100vw;
  height: 100vh;
  top: 0;
  left: 0;
}

#editor2d {
  width: 100%;
  height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr;
}

#top-menu {
  padding: var(--margin-2);
  display: flex;
  gap: var(--margin-4);
  justify-content: space-between;
  background-color: var(--secondary-color);
  position: relative;
  overflow-y: auto;
}

#top-menu .left,
#top-menu .right {
  display: flex;
  gap: var(--margin-2);
}

#e2d-warning {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background-color: var(--danger-color);
  color: var(--primary-color);
  display: none;
  justify-content: center;
  align-items: center;
  padding: var(--margin-3);
}

#editor2d-canvas {
  overflow: hidden;
  background-color: var(--primary-color);
}

@media screen and (orientation: portrait) {
  #editor2d-container {
    width: 100%;
  }

  #editor2d-container #editor2d {
    height: 50vh;
  }

  #editor2d-container.expand #editor2d {
    height: 100vh;
  }
}
