/*
 * Licensed to the Apache Software Foundation (ASF) under one or more
 * contributor license agreements.  See the NOTICE file distributed with
 * this work for additional information regarding copyright ownership.
 * The ASF licenses this file to You 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.
 */

html,
body,
#root {
  height: 100%;
  margin: 0;
  padding: 0;
  overflow-x: auto;
  overflow-y: auto;
  font-family:
    -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Sans',
    sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji';
}

// .login-form style --- start ----
.content {
  padding: 32px 0 24px;
}

.top {
  text-align: center;
}

.header {
  position: relative;
  height: 100px;
  font-weight: 600;
  font-size: 4rem;
  font-family: PMingLiU-ExtB, 'Helvetica Neue', Arial, Helvetica, sans-serif;
  line-height: 10vh;
}

.logo {
  position: absolute;
  top: 10vh;
  left: 20vw;
  display: flex;
  flex: auto;
  flex-flow: column-reverse;
  width: 28vw;
}

.desc {
  margin-top: 2rem;
  margin-bottom: 1rem;
  font-weight: 600;
  font-size: 24px;
  //color: @text-color-secondary;
  //font-size: @font-size-base;
}

.loginformMain {
  z-index: 1;
  display: flex;
  flex: auto;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  max-height: max-content;
  padding: 0 6vh 30vh 2vh;
  background-repeat: no-repeat;
  background-position: left center;
  background-size: cover;

  .form {
    position: relative;
    height: 100 * 100vw / 320;
    margin-bottom: -15vh;
    margin-left: 60vw;
    border-radius: 10px;
    box-shadow: 0 0 10px 5px rgba(0, 0, 0, 0.4);
  }

  .loginform {
    padding: 2vh 2vw;
  }
}

// .login-form style --- end ----

// scrollbar style --- start ----
::-webkit-scrollbar {
  width: 0.3vw;
  height: 0.5vh;
}

::-webkit-scrollbar-thumb {
  background-color: #8db7fd;
  border-radius: 10px;
  box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
}

::-webkit-scrollbar-thumb:hover {
  background-color: #aaa;
}

::-webkit-scrollbar-thumb:active {
  background-color: #999;
}

::-webkit-scrollbar-corner {
  background-color: #f5f5f5;
}

.monaco-scrollable-element > .scrollbar > .slider {
  background: #8db7fd !important;
}

// scrollbar style --- end ----

.colorWeak {
  filter: invert(80%);
}

.ant-layout {
  min-height: 100vh;
}

.ant-pro-sider.ant-layout-sider.ant-pro-sider-fixed {
  left: unset;
}

canvas {
  display: block;
}

body {
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

ul,
ol {
  list-style: none;
}

@media (max-width: 768px) {
  .ant-table {
    width: 100%;
    overflow-x: auto;

    &-thead > tr,
    &-tbody > tr {
      > th,
      > td {
        white-space: pre;

        > span {
          display: block;
        }
      }
    }
  }
}

.options-button {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background-color: rgba(79, 79, 79, 0.04);
  border: none;
}

.blue-icon {
  width: border-box;
  height: border-box;
  color: rgb(24, 144, 255);
}

.ant-pro-page-container-children-content {
  height: 78vh;
}

.ant-pro-query-filter {
  padding: 0;
}

.ant-pro-card-body {
  height: max-content;
  padding: 0;
}

.hidden-overflow {
  overflow: hidden;
}

.ant-list .ant-list-pagination {
  margin-block-start: 0; // 去除 分页组件和 上边表格的间距
}

.ant-table-wrapper {
  overflow-x: hidden;
  overflow-y: hidden;
  overflow-block: auto;
}

.child-list {
  margin-left: 4vw;
  padding: 0;
  border-bottom-color: red;
}

.treeList {
  height: 100%;
  overflow-x: auto;
  overflow-y: auto;

  .ant-tree-list-holder-inner {
    z-index: auto;
    min-width: max-content;
  }

  .tree-search-value {
    //color: #00EE76;
    color: #c00b26;
    font-size: 15px;
    background-color: rgba(3, 102, 214, 0.5);
  }
}

.siderTree {
  height: 100%;
  overflow-x: auto;
  overflow-y: auto;

  .ant-tree {
    min-width: max-content;

    .ant-tree-node-content-wrapper {
      display: flex;
    }
  }
}

.ant-tree-node-content-wrapper {
  display: flex;
}

.ant-spin-nested-loading {
  height: inherit;
}

.ant-spin-container {
  height: inherit;
}

.gitCodeTree {
  min-height: 73vh;
  max-height: 73vh;
}

.schemaTree {
  height: 100%;
  overflow-y: auto;
}

.code-content-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: 70vh;
  max-height: 70vh;
  color: #999;
}

.monaco-float {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  box-shadow: 0 0 2px 1px rgba(171, 165, 165, 0.32);

  .float-button {
    position: absolute;
    transform: translate(5%, 15%);

    .back-bottom {
      transform: rotate(180deg);
    }
  }

  .full-screen {
    position: absolute;
    top: 0;
    right: 2vw;
    width: 40px;
    height: 40px;
    transform: translate(5%, 15%);
  }
}

/**
 * if i18n is too long, it will break line ,
 * so we need to use pre-wrap , but it will first break line at space, so we need to use nowrap
 */
.needWrap {
  align-content: center;
  white-space: pre-wrap;
}

.query-form {
  position: absolute;
  left: 0;
  width: max-content;
}

.tiny-charts {
  position: absolute;
  top: 15px;
  right: 12px;
}

.radio-group-chart {
  position: absolute;
  top: 15px;
  right: 10px;
}

.tag-content {
  align-content: center;
  align-items: center;
}

.ant-pro-checkcard-title {
  overflow: unset;
}

h5 {
  margin-bottom: 0;
  margin-left: 0.5rem;
}

// theme
// light
.show {
  opacity: 1;
  animation: show-anim 0.5s;
}

.hide {
  opacity: 0;
  animation: hide-anim 0.5s;
}

@keyframes show-anim {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

@keyframes hide-anim {
  0% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}

.title {
  overflow: visible;
  font-weight: 500;
  font-size: 15px;
  font-family: 'SimHei', serif;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.container-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  line-height: 32px;
  padding-inline: 10px;
  padding-block: 1px;
  border-block: 1px solid;
}

// 滚动条
.content-scroll {
  overflow-y: auto;
  direction: ltr;
  scrollbar-color: #d4aa70 #e4e4e4;
  scrollbar-width: thin;
}

.editor-full-screen {
  .ant-tabs-tabpane {
    height: 100vh;
  }
}

.data-studio-tabs {
  .ant-tabs-nav {
    .ant-tabs-nav-wrap {
      .ant-tabs-tab {
        padding: 8px 8px;
      }

      .ant-tabs-tab-active {
        box-sizing: content-box;
        border-block-end: 3px solid #8db7fd;
        padding-block-end: 3px;
      }
    }
  }
}

.data-studio-form {
  .ant-form-item {
    margin-bottom: 5px !important;
  }
}

.ant-pro-form-list-item {
  display: flex !important;
  align-items: baseline !important;
}

.ant-pro-checkcard {
  overflow: hidden;

  .ant-pro-checkcard-body {
    width: 100vw;
  }
}

// ====================  lineage style start ====================

.butterfly-lineage-dag .table-node.focus {
  border-width: 10px;
  border-radius: 4px;
  box-shadow: 0 0 5px #0d74e8;
}

.butterfly-lineage-dag .table-node:hover {
  border-width: 10px;
  border-radius: 4px;
  box-shadow: 0 0 5px #0d74e8;
}

.butterfly-lineage-dag .table-node .field {
  display: flex;
  flex-flow: row;
  justify-content: space-between;
  height: 20px;
  border-width: 10px;
  border-radius: 4px;
}

.field.hover-chain {
  width: 97%;
  background: #0d74e8 !important;
}

.butterfly-lineage-dag .table-node .title-con {
  .title {
    display: inline-flex;
    align-items: center;
    width: 100%;
    height: 40px;
    max-height: 4vh;
    padding-left: 5px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    background: #63e0e0;
    border-radius: 4px;
    box-shadow: #0d74e8;

    .ant-typography {
      display: flex;
      flex-flow: row;
      align-items: center;
      justify-content: space-between;
    }
  }
}

.butterfly-lineage-dag .table-node .field .point.left-point {
  left: -10px;
  z-index: 9999;
}

.butterfly-lineage-dag .table-node .field .point.right-point {
  right: -10px;
  z-index: 9999;
}

.butterfly-lineage-dag .table-node .title-con {
  position: relative;
  display: flex;
  min-width: 40%;
}

.butterfly-lineage-dag .butterflies-link.hover-chain {
  transition: all 0.5s ease-in-out;
  // 线条缓慢流动
  animation: 30s linear 0s infinite normal none running running-line;
  stroke: #02f657;
  stop-opacity: 1;
}

.butterfly-lineage-dag .butterflies-arrow.hover-chain {
  transition: all 0.5s ease-in-out;
  animation: 30s linear 0s infinite normal none running running-line;
  fill: #28da8f;
  stroke: #28da8f;
}

.butterfly-lineage-dag .table-node .field.hover-chain .point {
  background: #0095ff;
  transition: all 0.5s ease-in-out;
}

.butterfly-lineage-dag .table-node .field {
  position: relative;
  align-items: center;
  height: 26px !important;
  margin: 0 6px;
  padding: 4px 4px 4px 6px;
  white-space: nowrap;
}

.butterfly-lineage-dag .table-node .field.hover-chain {
  color: #fff;
  transition: all 0.5s ease-in-out;
}

.butterfly-lineage-dag .table-node .title-con .operator {
  position: absolute;
  top: 2px;
  right: 5px;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  height: 100%;
  max-height: 4vh;
  margin: 0 20px;

  .operator-item {
    margin-left: 15px;
  }
}

.butterflies-link {
  transition: all 0.5s ease-in-out; // 线条缓慢流动
  fill: none; // 线条填充色
  stroke: #04671f; // 线条颜色
  stroke-width: 1.5px; // 线条宽度
  stroke-dasharray: 5, 8; // 线条样式 5px实线 8px空白
  stroke-dashoffset: -2px; // 线条偏移量
  stroke-linecap: round; // 线条两端样式
  stroke-linejoin: round; // 线条连接样式 miter-clip斜角 miter斜角 round圆角 bevel斜角
}

.butterflies-link:hover {
  right: 0; // 激活连接线 右边距
}

.butterflies-arrow {
  padding-right: 10px !important; // 箭头右边距
  transition: all 0.5s ease-in-out; // 线条缓慢流动
  fill: #04671f; // 箭头颜色
  stroke: #04671f; // 箭头颜色
  stroke-width: 4px; // 箭头宽度
}

.butterflies-arrow:hover {
  right: 0;
  background: #0366d6;
}

// ====================  lineage style end ====================

.card-list-item-wrapper {
  display: flex;
}

.card-list-item {
  width: 100%;
  margin: 0;
}

.card-list-item {
  transition: 0.3s;
}

.card-button-list {
  display: none;
}

.card-list-item:hover .card-button-list {
  display: block;
}

.card-list-item:hover {
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

// 自定义语言会把 '' 中间的内容加粗 , 在这里重置 不加粗
span .mtkb {
  font-weight: inherit;
}

// =============================  layout split pane style start =============================
.split-pane {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  overflow: hidden;
}

.Resizer {
  z-index: 1;
  box-sizing: border-box;
  background: #000;
  background-clip: padding-box;
  opacity: 0.2;
}

.Resizer:hover {
  transition: all 2s ease;
}

.Resizer.horizontal {
  height: 11px;
  margin: -5px 0;
  border-top: 5px solid rgba(255, 255, 255, 0);
  border-bottom: 5px solid rgba(255, 255, 255, 0);
  cursor: row-resize;
}

.Resizer.horizontal:hover,
.Resizer.horizontal.resizing {
  border-top: 5px solid rgba(0, 0, 0, 0.5);
  border-bottom: 5px solid rgba(0, 0, 0, 0.5);
}

.Resizer.vertical {
  width: 11px;
  height: 98%;
  margin: 0 -5px;
  border-right: 5px solid rgba(255, 255, 255, 0);
  border-left: 5px solid rgba(255, 255, 255, 0);
  cursor: col-resize;
}

.Resizer.vertical:hover,
.Resizer.vertical.resizing {
  border-right: 5px solid rgba(0, 0, 0, 0.5);
  border-left: 5px solid rgba(0, 0, 0, 0.5);
}

.DragLayer {
  z-index: 1;
  pointer-events: none;
}

.DragLayer.resizing {
  pointer-events: auto;
}

.DragLayer.horizontal {
  cursor: row-resize;
}

.DragLayer.vertical {
  cursor: col-resize;
}

// =============================  layout split pane style end =============================

.ant-notification-notice-wrapper {
  top: 80px !important;
}

// 组件鼠标悬停时 圆角 50% 背景色灰色
.icon-btn-hover {
  :hover {
    background-color: #aba4a4;
    border-radius: 50%;
  }
}

.ant-page-header-breadcrumb {
  padding-left: 25px;
}
