/**
 * @license
 * Copyright 2024 The Model Explorer Authors. All Rights Reserved.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 * ==============================================================================
 */

.container {
  width: 100%;
  height: 100%;
  overflow: hidden;
  position: relative;

  svg-rednerer,
  webgl-rednerer {
    width: 100%;
    height: 100%;
  }

  .toolbar {
    position: absolute;
    top: 8px;
    left: 12px;
    padding: 0 8px 0 6px;
    box-sizing: border-box;
    height: 40px;
    display: flex;
    background-color: #edf2fa;
    border-radius: 99px;
    align-items: center;
    outline: 2px solid white;

    &.in-popup {
      padding-left: 10px;
    }

    &:has(search-bar::ng-deep input:focus) {
      border-color: #1a73e8;
    }

    search-bar {
      margin-right: 4px;
    }

    &.pushed-down {
      top: 44px;
    }

    .mat-icon-container {
      width: 24px;
      height: 24px;
      display: flex;
      align-items: center;
      justify-content: center;

      &.enabled {
        background-color: #ffdeb1;
        outline: 1px solid #ea8600;
        border-radius: 4px;
      }

      &.disable {
        opacity: 0.2;
        pointer-events: none;
      }
    }

    mat-icon.toolbar-icon {
      font-size: 20px;
      width: 20px;
      height: 20px;
      cursor: pointer;
      opacity: 0.6;

      &:hover {
        opacity: 0.9;
      }

      &.expand-all,
      &.collapse-all {
        font-size: 18px;
        width: 18px;
        height: 18px;
      }

      &.flatten-layers {
        font-size: 20px;
        width: 20px;
        height: 20px;
        border: 1px solid transparent;
      }

      &.trace {
        transform: rotate(90deg);
        border: 1px solid transparent;
      }
    }

    .vertical-divider {
      width: 1px;
      border-left: 1px solid #d0d0d0;
      margin: 2px 5px;
      height : 20px;
    }

    edge-overlays-dropdown {
      margin-left: 4px;
    }
  }

  subgraph-breadcrumbs {
    position: absolute;
    top: 8px;
    left: 12px;
  }
}

::ng-deep bubble-container:has(.model-explorer-view-popup) {
  border-top-left-radius: 0;
  border-top-right-radius: 0;
}

::ng-deep .model-explorer-download-png-menu {
  .menu-item {
    /* stylelint-disable-next-line declaration-no-important -- override MDC */
    letter-spacing: normal !important;
    /* stylelint-disable-next-line declaration-no-important -- override MDC */
    font-family: 'Google Sans Text', Arial, Helvetica, sans-serif !important;
    font-size: 12px;
    padding: 0 8px;
    cursor: pointer;
    display: flex;
    align-items: center;

    &:hover {
      background-color: #eee;
    }
  }

  .transparent-background-toggle {
    display: flex;
    align-items: center;
    font-size: 12px;
    letter-spacing: normal;
    padding: 6px 8px 0 4px;
    border-top: 1px solid #ddd;
    margin-top: 8px;
    cursor: pointer;

    input {
      cursor: inherit;
    }
  }
}
