@font-face {
  font-family: 'FangZhengZhongyi';
  src: url(/assets/fonts/fangzhengzhongyi-normal.ttf) format('truetype');
  font-weight: normal;
}

@font-face {
  font-family: 'DIN';
  src: url(/assets/fonts/D-DIN.otf) format('truetype');
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'DIN';
  src: url(/assets/fonts/D-DIN-Bold.otf) format('truetype');
  font-weight: bold;
  font-style: normal;
}

@font-face {
  font-family: 'DIN';
  src: url(/assets/fonts/D-DIN-Italic.otf) format('truetype');
  font-weight: normal;
  font-style: italic;
}

.font-fangzheng {
  font-family: 'FangZhengZhongyi';
}

.font-din {
  font-family: 'DIN';
}

.v-font {
  font-family:
    v-sans,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    sans-serif,
    'Apple Color Emoji',
    'Segoe UI Emoji',
    'Segoe UI Symbol';
}
.ant-btn > .anticon {
  vertical-align: baseline;
  svg {
    vertical-align: bottom;
    line-height: 22px;
  }
}

.fangzheng-blue-white {
  text-shadow: 0px 2px 8px rgba(5, 28, 55, 0.12);
  background: linear-gradient(
    180deg,
    rgba(14, 197, 236, 0.96) 0%,
    rgba(49, 190, 255, 0.96) 0%,
    rgba(239, 252, 254, 0.96) 58.7646484375%
  );
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-family: 'FangZhengZhongyi';
}

.custom-scroll-bar {
  &::-webkit-scrollbar {
    display: block;
    width: 8px;
    height: 8px;
  }
  &::-webkit-scrollbar-thumb {
    background: rgba(224, 226, 226, 0.45);
    border-radius: 30px;
    box-shadow:
      inset 2px 2px 2px rgba(189, 189, 189, 0.25),
      inset -2px -2px 2px rgba(209, 209, 209, 0.25);
  }
  &::-webkit-scrollbar-track {
    background: transparent;
  }
}

.cdk-virtual-scrollable {
  .custom-scroll-bar();
}
.ant-dropdown-menu {
  .custom-scroll-bar();
}
textarea {
  .custom-scroll-bar();
}

.ant-tag-blue {
  color: var(--ant-primary-color);
  background: #e6f7ff;
  border-color: #a9c1ff;
}

.page-headline-font {
  font-weight: 500;
  font-size: 24px;
  color: #131523;
  text-shadow: inset 0px 1px 3px rgba(0, 0, 0, 0.5);
}

.precaution-button {
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  --ant-error-color: #f43f5e;
}
.precaution-secondary {
  border-radius: 4px;
  --ant-primary-color: #d9e4ff;
  --ant-primary-color-hover: #b2caff;
  --ant-primary-color-active: #839dfd;
  --ant-error-color: #ffd9d9;
  &.ant-btn-dangerous {
    color: #f43f5e;
  }
  &:hover,
  &:active {
    color: #1e5eff;
  }
  color: #1e5eff;
}

.precaution-green {
  border-radius: 4px;
  --ant-primary-color: #06a561;
  --ant-primary-color-hover: #1cbb76;
  --ant-primary-color-active: #06834d;
  &:hover,
  &:active {
    color: white;
  }
  color: white;
}

.precaution-panel {
  background: #ffffff;
  box-shadow: 0px 1px 4px 0px rgba(21, 34, 50, 0.08);
  border-radius: 4px;
  padding: 14px 24px 14px 24px;
  color: #333333;
}

.precaution-table {
  border-radius: 10px;
  .ant-table-title {
    padding: 0;
  }
  thead {
    border-radius: 10px;
    overflow: hidden;
    > tr {
      border-radius: 10px;
      overflow: hidden;

      > th {
        padding: 18px 18px;
        color: #7d8da6;
        font-weight: 500;
        border-bottom: 1px solid transparent;
        font-size: 16px;
        background-color: #f6f7fa;
        &::before {
          display: none;
        }
        &:last-child {
          border-top-right-radius: 10px !important;
        }
        &:first-child {
          border-top-left-radius: 10px !important;
        }
      }
    }
  }
  tbody {
    tr {
      td {
        color: rgba(22, 23, 54, 0.8);
        border-bottom: 1px solid rgba(151, 151, 151, 0.3);
        padding: 16px;
      }
      &:last-child {
        td {
          border-bottom: none;
        }
      }
    }
  }
  nz-pagination {
    .ant-pagination-item-active {
      border-color: transparent;
      background-color: #ecf2ff;
      border-radius: 4px;
    }
    .ant-pagination-prev {
      margin-right: 8px !important;
    }
    .ant-pagination-next {
      margin-left: 8px !important;
    }
  }
  .ant-table-body {
    .custom-scroll-bar();
  }
  .ant-table-content {
    .custom-scroll-bar();
  }
}

.precaution-input {
  border-color: #d9e1ec;
  border-radius: 4px;
  ::placeholder {
    color: #a1a7c4;
  }
}

.precaution-select {
  .ant-select-selector {
    border-color: #d9e1ec !important;
    border-radius: 4px !important;
  }
  .ant-select-arrow {
    color: #7e84a3;
  }
}

.precaution-pagination {
  .ant-pagination-item-active {
    border-color: transparent;
    background-color: #ecf2ff;
    border-radius: 4px;
  }
  .ant-pagination-prev {
    margin-right: 8px !important;
  }
  .ant-pagination-next {
    margin-left: 8px !important;
  }
}

.precaution-button-group {
  label {
    &:first-child {
      border-radius: 4px 0 0 4px;
    }
    &:last-child {
      border-radius: 0 4px 4px 0;
    }
  }
}

.precaution-select-dropdown {
  .ant-select-item {
    box-sizing: border-box;
    border: 1px solid transparent;
    padding: 4px 12px;
  }
  .ant-select-item-option-active:not(.ant-select-item-option-disabled) {
    background-color: var(--ant-primary-1);
    font-weight: normal;
  }
  .ant-select-item-option-selected:not(.ant-select-item-option-disabled) {
    font-weight: normal;
    border: 1px solid #d7dbec;
    border-radius: 4px;
    color: var(--ant-primary-color);
  }

  .ant-cascader-menu-item-active:not(.ant-cascader-menu-item-disabled),
  .ant-cascader-menu-item-active:not(.ant-cascader-menu-item-disabled):hover {
    background-color: var(--ant-primary-1);
    border: 1px solid #d7dbec;
    font-weight: normal;
    border-radius: 4px;
    color: var(--ant-primary-color);
  }
  .ant-cascader-menu-item {
    box-sizing: border-box;
    border: 1px solid transparent;
    &:hover {
      background-color: var(--ant-primary-1);
    }
  }
}

.precaution-dropdown {
  .ant-dropdown-menu-item {
    &:hover {
      background-color: var(--ant-primary-1);
    }
  }
}
.precaution-modal {
  --ant-error-color: #ff0000;
  .ant-modal-header {
    border-radius: 8px 8px 0 0;
  }
  .ant-modal-content {
    border-radius: 8px;
  }
  .ant-modal-confirm-btns,
  .ant-modal-footer {
    .ant-btn {
      .precaution-button();
    }
  }
}

.rounded-alert {
  .ant-alert {
    border-radius: 4px;
  }
}
