/* See license.txt for terms of usage */

/******************************************************************************/
/* Splitter */

.splitterBox {
  height: 100%;
  width: 100%;
  overflow: hidden;
}

/* Flex support for horizontal splitter (vertical flex TBD) */
.splitterBox[mode="horizontal"] {
  display: flex;
  flex-direction: column;

  justify-content: flex-start; /* align items in Main Axis */
  align-items: stretch; /* align items in Cross Axis */
  align-content: stretch; /* Extra space in Cross Axis */
}

.splitterBox[mode="vertical"] {
  flex: 1 1 auto;
  display: flex;
}

.splitterBox[mode="vertical"] .leftPanel {
  height: 100%;
  flex: 1;
  order: 1;
}

.splitterBox[mode="vertical"] .rightPanel {
  height: 100%;
  width: 40%;
  order: 3;
}

.splitterBox[mode="horizontal"] .leftPanel {
  width: 100%;
  order: 1;
}

.splitterBox[mode="horizontal"] .rightPanel {
  width: 100%;
  order: 3;
}

/* Flex support for horizontal splitter */
.splitterBox[mode="horizontal"] .leftPanel {
  flex: 1;

  width: 100%;
  height: 100%;

  display: flex;
  flex-direction: column;

  justify-content: flex-start; /* align items in Main Axis */
  align-items: stretch; /* align items in Cross Axis */
  align-content: stretch; /* Extra space in Cross Axis */
}

.splitterBox[mode="vertical"] .leftPanel {
  flex: 1;

  width: 100%;
  height: 100%;

  display: flex;
  flex-direction: row;

  justify-content: flex-start; /* align items in Main Axis */
  align-items: stretch; /* align items in Cross Axis */
  align-content: stretch; /* Extra space in Cross Axis */
}

.splitterBox .splitter {
  background-color: rgb(231, 241, 251);
  order: 2;
}

.splitterBox .splitter.vertical {
  width: 4px;
  height: 100%;
  cursor: e-resize;
}

.splitterBox .splitter.horizontal {
  height: 4px;
  width: 100%;
  cursor: s-resize;
}

.splitterBox .splitter > .innerBox {
  visibility: visible;
  height: 30px;
  width: 4px;
  background-color: rgb(219, 234, 249);
  background-image: linear-gradient(rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0.2));
  border-bottom: 1px solid rgb(170, 188, 207);
  cursor: default;
  margin: 0;
  padding: 1px 0;
}

/******************************************************************************/
/* Resizing */

/* When splitter resizing is in progress set the cursor for all elements
 since the mouse doesn't have to be always just over the resizer and this
 avoids cursor flashing. */
body[resizing="vertical"] * {
  cursor: col-resize !important;
}

body[resizing="horizontal"] * {
  cursor: row-resize !important;
}

/******************************************************************************/
/* Theme Light & Dark */

.theme-dark .splitterBox .splitter > .innerBox {
  display: none;
}

.theme-dark .splitterBox .splitter {
  background-color: #343c45;
}

.theme-light .splitterBox .splitter > .innerBox {
  height: 24px;
  width: 4px;
  border-bottom: 1px solid #010101;
  background-color: #343c45;
}

.theme-light .splitterBox .splitter {
  background-color: transparent;
}

.theme-light .splitterBox .splitter.vertical {
  width: 4px;
  border-left: 1px solid #010101;
  background-color: transparent;
}
