@import url('https://fonts.googleapis.com/css?family=Roboto');

:not(:defined) {
  display: none!important;
}

:root {
  --surface-color: rgb(80, 80, 80);
  --background-color: #333;
  --foreground-color: white;
  --accent-color: rgb(50, 125, 217);
  --accent-color-2: rgb(90, 123, 148);

  --tab-size: 40px;
  --sidebar-width: calc(var(--tab-size) + 3px);
  --body-side-padding: 12px;

  --scrollbar-width: 5px;
  --scrollbar-background-color: var(--surface-color);
  --scrollbar-color: var(--accent-color-2);
  --scrollbar-color-r: 90;
  --scrollbar-color-g: 123;
  --scrollbar-color-b: 148;
  --scrollbar-opacity: 1;
  --scrollbar-radius: 50px;

  --editor-width: 400px;
  --editor-body-width: calc(var(--editor-width) - var(--sidebar-width));
  --editor-body-content-width: calc(var(--editor-body-width) - 2 * var(--body-side-padding));

  --font: 14px / 1 'Roboto', sans-serif;

  --number-input-slider-color: var(--accent-color-2);
  --number-input-slider-color-hover: var(--accent-color-2);
  --number-input-background-color: #535353;
  --number-input-background-color-hover: #6e6e6e;
  --number-input-arrow-background-color: var(--number-input-background-color);
  --number-input-arrow-background-color-hover: #6e6e6e;
}


body {
  margin: 0;
  padding: 0;
  width: 100vw;
  height: 100dvh;
  display: flex;
}

vntana-viewer {
  height: 100%;
  flex-grow: 1;
  flex-shrink: 1;
}

editor-menu:not([collapsed]) {
  position: relative; 
  height: 100%;
  width: var(--editor-width);
  min-width: var(--editor-width);
  max-width: var(--editor-width);
  overflow-x: hidden;
  flex: 0 0 auto;
}

[slot="header"] {
  flex: 0 0 auto;
  width: var(--editor-body-width);
}

[slot="footer"] {
  height: 50px;
  width: var(--editor-body-width);
  flex: 0 0 50px;
  box-sizing: border-box;
  border-top: 1px solid var(--surface-color);
  overflow-x: hidden;

  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;

  :last-child {
    margin-right: 10px;
  }

  :is(button, file-load-button) {
    box-sizing: border-box;
    border: 0;
    color: var(--foreground-color);
    background-color: var(--accent-color-2);
    border-radius: 3px;
    font: var(--font);
    font-weight: bold;
    font-size: 0.8em;
    width: 60px;
    height: 70%;

    &:hover {
      color: var(--accent-color-2);
      background-color: var(--foreground-color);
    }
  }
}

editor-menu > :not([slot]) {
  height: 100%;
  font: var(--font);
}

editor-menu > :not([slot]) > :not(:first-child) {
  margin-top: 20px;
}

.tooltip {
  position: relative;
  display: inline-block;
}

.tooltip .tooltiptext {
  visibility: hidden;
  width: fit-content;
  background-color: black;
  color: #fff;
  text-align: center;
  border-radius: 6px;
  padding: 5px 0;
  position: absolute;
  z-index: 1;
  bottom: 105%;
  transition: opacity 0.3s;
  opacity: 0;
}

.tooltip:hover .tooltiptext {
  visibility: visible;
  transition-delay: 0.35s;
  opacity: 1;
}
