/**
 *
 * This file may have been modified by Bytedance Inc. (“Bytedance Inc.'s Modifications”). 
 * All Bytedance Inc.'s Modifications are Copyright (year) Bytedance Inc..  
 * 
 * This source code is licensed under the Apache license.
 * See LICENSE file in the project root for license information.
 *
 */
@import './mixins/index.less';

// 文字
.reset-component() {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  color: @text-color;
  font-size: @font-size-base;
  font-variant: @font-variant-base;
  line-height: @line-height-base;
  list-style: none;
  font-feature-settings: @font-feature-settings-base;
}

.fontStyle(@size, @lineHeight, @weight) {
  font-size: @size;
  line-height: @lineHeight;
  font-weight: @weight;
}

// 	重要数据展示
.font-display-2(@size: @font-display-2-Size, @lineHeight:@font-display-2-Lineheight, @weight: @font-display-2-Weight) {
  .fontStyle(@size, @lineHeight, @weight);
}
// 	次级数据展示
.font-display-1(@size: @font-display-1-Size, @lineHeight:@font-display-1-Lineheight, @weight: @font-display-1-Weight) {
  .fontStyle(@size, @lineHeight, @weight);
}
// 	标题-大
.font-headtitle(@size: @font-headtitle-Size, @lineHeight:@font-headtitle-Lineheight, @weight: @font-headtitle-Weight) {
  .fontStyle(@size, @lineHeight, @weight);
}
// 	标题-常
.font-title-medium(@size: @font-title-Size, @lineHeight:@font-title-Lineheight, @weight: @font-title-Weight) {
  .fontStyle(@size, @lineHeight, @weight);
}
// 	副标题-加粗
.font-subtitle-medium(@size: @font-subtitle-medium-Size, @lineHeight:@font-subtitle-medium-Lineheight, @weight: @font-subtitle-medium-Weight) {
  .fontStyle(@size, @lineHeight, @weight);
}
// 	副标题-常规
.font-subtitle-regular(@size: @font-subtitle-regular-Size, @lineHeight:@font-subtitle-regular-Lineheight, @weight: @font-subtitle-regular-Weight) {
  .fontStyle(@size, @lineHeight, @weight);
}
// 	正文加粗
.font-body-medium(@size: @font-body-medium-Size, @lineHeight:@font-body-medium-Lineheight, @weight: @font-body-medium-Weight) {
  .fontStyle(@size, @lineHeight, @weight);
}
// 	正文常规
.font-body-regular(@size: @font-body-regular-Size, @lineHeight:@font-body-regular-Lineheight, @weight: @font-body-regular-Weight) {
  .fontStyle(@size, @lineHeight, @weight);
}
// 	次级正文加粗
.font-assets-caption-medium(@size: @font-assets-caption-medium-Size, @lineHeight:@font-assets-caption-medium-Lineheight, @weight: @font-assets-caption-medium-Weight) {
  .fontStyle(@size, @lineHeight, @weight);
}
// 	提示文字、标签、按钮、次级正文
.font-assets-caption-regular(@size: @font-assets-caption-regular-Size, @lineHeight:@font-assets-caption-regular-Lineheight, @weight: @font-assets-caption-regular-Weight) {
  .fontStyle(@size, @lineHeight, @weight);
}

// 正文、按钮、小标题
.fontStyle-3(@fontWeight: @Font-Weight-2) {
  .fontStyle(16px, 22px, @fontWeight);
}

// 提示文字、标签、小按钮、次级正文
.fontStyle-4(@fontWeight: @Font-Weight-2) {
  .fontStyle(14px, 20px, @fontWeight);
}

.fontStyle-5(@fontWeight: @Font-Weight-2) {
  .fontStyle(12px, 16px, @fontWeight);
}

// 正文、按钮、小标题
.fontStyle-4-normal() {
  .fontStyle-4(@Font-Weight-1);
}
// 提示文字、标签、小按钮、次级正文
.fontStyle-5-normal() {
  .fontStyle-5(@Font-Weight-1);
}

// 统一滚动条样式
.webkitScrollBarStyle() {
  /* 滚动槽 */
  &::-webkit-scrollbar {
    width: 6px;
    height: 6px;
  }

  &::-webkit-scrollbar-track {
    border-radius: 3px;
    background: rgba(0, 0, 0, 0);
    box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.08);
    -webkit-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.08);
  }

  /* 滚动条滑块 */
  &::-webkit-scrollbar-thumb {
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.32);
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.2);
    -webkit-box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.2);
  }
}
