@font-face {
	font-family: 'myFont';
	/* #ifdef MP */
	src: url('data:font/ttf;charset=utf-8;base64,[encoded data, 35544 characters]') format('truetype');
	/* #endif */
	/* #ifndef MP */
	src: url('@/common/css/custom.ttf') format('truetype');
	/* #endif */
}

view {
	line-height: 1.8;
	font-family: 'PingFang SC', 'Roboto Medium';
	font-size: $font-size-base;
	color: $color-title;
}
page {
	background-color: $color-bg;
}

:root {
	$base-color: #ff4544;
	$base-help-color: #ffb644; //辅助颜色
	--tab-bar-height: 112rpx;
}

.uni-input-input:-webkit-autofill {
	-webkit-transition-delay: 111111s;
	-webkit-transition: color 11111s ease-out, background-color 111111s ease-out;
}

.color-base-text {
	color: $base-color !important;
}

//背景色
.color-base-bg {
	background-color: $base-color !important;
}

.color-base-bg-before {
	&::after,
	&::before {
		background: $base-color !important;
	}
}

.color-base-text-before {
	&::after,
	&::before {
		color: $base-color !important;
	}
}

// 浅主色调背景
.color-base-bg-light {
	// background-color: lighten($base-color, 35%) !important;
}

//边框
.color-base-border {
	border-color: $base-color !important;
	&-top {
		border-top-color: $base-color !important;
	}
	&-bottom {
		border-bottom-color: $base-color !important;
	}
	&-right {
		border-right-color: $base-color !important;
	}
	&-left {
		border-left-color: $base-color !important;
	}
}

// ***************文字颜色***************

// 主标题
.color-title {
	color: $color-title !important;
}

// 副标题
.color-sub {
	color: $color-sub !important;
}

// 辅助提示色
.color-tip {
	color: $color-tip !important;
}

// 灰背景色
.color-bg {
	background-color: $color-bg !important;
}

// 分割线
.color-line {
	color: $color-line !important;
}

// 分割线边框
.color-line-border {
	border-color: $color-line !important;
}

// 禁用色
.color-disabled {
	color: $color-disabled !important;
}

// ***************文字大小***************
input {
	max-height: unset;
	min-height: unset;
	font-size: $font-size-base;
}

// 14px，正文文字
.font-size-base {
	font-size: $font-size-base !important;
}

// 16px，用于标题、导航栏
.font-size-toolbar {
	font-size: $font-size-toolbar !important;
}

// 13px，副标题
.font-size-sub {
	font-size: $font-size-sub !important;
}

// 12px，辅助性文字/大标签
.font-size-tag {
	font-size: $font-size-tag !important;
}

// 11px，商品列表角标
.font-size-goods-tag {
	font-size: $font-size-goods-tag !important;
}

// 10px，活动角标（拼团等角标）/小标签文字
.font-size-activity-tag {
	font-size: $font-size-activity-tag !important;
}

//内边距
.padding {
	padding: $padding !important;
	&-top {
		padding-top: $padding !important;
	}
	&-right {
		padding-right: $padding !important;
	}
	&-bottom {
		padding-bottom: $padding !important;
	}
	&-left {
		padding-left: $padding !important;
	}
}

//外边距
.margin {
	margin: $margin-updown $margin-both !important;
	&-top {
		margin-top: $margin-updown !important;
	}
	&-right {
		margin-right: $margin-both !important;
	}
	&-bottom {
		margin-bottom: $margin-updown !important;
	}
	&-left {
		margin-left: $margin-both !important;
	}
}

/**
 * 按钮
 * size='mini' 小规格的
 * type='default' 普通的
 * type='primary' 主色背景+白色字
 * .button-border 主色边框+主色字 
 * .shadow 主色阴影
 * .default 去除margin
 * .disabled 禁止状态
 */
button {
	margin: 0 30rpx;
	font-size: $font-size-base;
	border-radius: 10rpx;
	line-height: 2.8;
	&[type='primary'] {
		background-color: $base-color;
		color: var(--btn-text-color);
		&[plain] {
			background-color: transparent;
			color: $base-color;
			border-color: $base-color;
		}
	}
	&[type='default'] {
		background: #fff;
		border: 2rpx solid $color-line;
	}
	&[size='mini'] {
		margin: 0 !important;
		line-height: 2.3;
		font-size: $font-size-tag;
		&[type='default'] {
			background-color: #fff;
		}
	}
	&.button-hover[type='primary'] {
		background-color: $base-color;
	}
	&[type='primary'][plain],
	&.button-hover[type='primary'][plain] {
		color: $base-color;
		border-color: $base-color;
	}
	&.button-hover[type='primary'] {
		color: var(--btn-text-color);
	}

	&[disabled],
	&.disabled {
		background: $color-line !important;
		color: rgba(0, 0, 0, 0.3) !important;
		border-color: $color-line !important;
	}
	&::after {
		border: none !important;
	}
}

uni-button:after {
	border: none !important;
}

// 复选框
uni-checkbox .uni-checkbox-input.uni-checkbox-input-checked {
	color: $base-color !important;
}

uni-checkbox:not([disabled]) .uni-checkbox-input:hover {
	border-color: $base-color !important;
}

.form-component uni-checkbox .uni-checkbox-input.uni-checkbox-input-checked {
	background-color: $base-color !important;
	border-color: $base-color !important;
}

// 开关
uni-switch .uni-switch-input.uni-switch-input-checked {
	background-color: $base-color !important;
	border-color: $base-color !important;
}

// 单选
uni-radio .uni-radio-input-checked {
	background-color: $base-color !important;
	border-color: $base-color !important;
}

// 滑块
uni-slider .uni-slider-track {
	background-color: $base-color !important;
}

.uni-tag--primary {
	color: #fff !important;
	background-color: $base-color !important;
	border-color: $base-color !important;
}

.uni-tag--primary.uni-tag--inverted {
	color: $base-color !important;
	background-color: #fff !important;
	border-color: $base-color !important;
}

// 圆角
.border-radius {
	border-radius: $border-radius !important;
}

.uni-tag--inverted {
	border-color: $color-line !important;
	color: $color-title !important;
}

// ***************商品详情***************
//商品详情，优惠券弹出层，项
// .goods-coupon-popup-layer .coupon-body .item {
// 	background-color: lighten($base-color, 45%) !important;
// 	view {
// 		color: lighten($base-color, 10%) !important;
// 	}
// }

// 商品详情加入购物车背景色
.color-join-cart {
	background-color: $base-help-color !important;
}

// 商品详情，sku选中
.sku-layer .body-item .sku-list-wrap {
	.items {
		// background-color: #f5f5f5 !important;
		&.selected {
			// background-color: lighten($base-color, 35%) !important;
			// background-color: lighten($base-color, 45%) !important;
			color: $base-color !important;
			border-color: $base-color !important;
		}
		&.disabled {
			color: $color-sub !important;
			cursor: not-allowed !important;
			pointer-events: none !important;
			opacity: 0.5 !important;
			box-shadow: none !important;
			filter: grayscale(100%);
		}
	}
}

.goods-detail .goods-coupon-popup-layer .coupon-info button {
	// background: linear-gradient(to right, #ff4544, lighten(#ff4544, 10%));
	// background: linear-gradient(to right, $base-color, lighten($base-color, 10%));
}

// 秒杀商品详情
.goods-detail .seckill-wrap {
	// background: linear-gradient(to right, $base-color, lighten($base-color, 20%)) !important;
}

.goods-detail .goods-module-wrap .original-price .seckill-save-price {
	// background: lighten($base-color, 40%) !important;
	color: $base-color !important;
}

// 拼团商品详情
.goods-detail .goods-pintuan {
	background: rgba($base-color, 0.2);
	.price-info {
		// background: linear-gradient(to right, $base-color, lighten($base-color, 10%)) !important;
	}
}

// 预售商品详情
.goods-detail .presale-rule {
	.process-item .number {
		background: rgba($base-color, 0.2);
	}
}

// 专题商品详情
.goods-detail .topic-wrap .price-info {
	// background: linear-gradient(to right, $base-color, #ff7877) !important;
}

// 团购商品详情
.goods-detail .goods-groupbuy {
	background: rgba($base-color, 0.2);
	.price-info {
		// background: linear-gradient(to right, $base-color, lighten($base-color, 10%)) !important;
	}
}

// 商品详情优惠券
.newdetail .coupon .coupon-item {
	&::after,
	&::before {
		border-color: $base-color !important;
	}
}

// 商品详情，数量加减
.sku-layer .body-item .number-wrap .number {
	button,
	input {
		border-color: rgba(229, 229, 229, 0.5) !important;
		background-color: rgba(229, 229, 229, 0.4) !important;
	}
}

// ***************订单***************
// 订单列表按钮样式
.order-box-btn {
	&.order-pay {
		background: $base-color;
	}
}

.ns-gradient-otherpages-fenxiao-apply-apply-bg {
	// background: linear-gradient(to left, $base-color, lighten($base-color, 20%));
}

.ns-gradient-otherpages-member-widthdrawal-withdrawal {
	// background: linear-gradient(to left, $base-color, lighten($base-color, 20%));
}

.ns-gradient-otherpages-member-balance-balance-rechange {
	// background: linear-gradient(to bottom, $base-color, #fd7e4b);
}

.ns-gradient-pages-member-index-index {
	// background: linear-gradient(to left, lighten($base-color, 10%), darken($base-color, 1%));
}

.ns-gradient-promotionpages-pintuan-share-share {
	// background-image: linear-gradient(to right, mix($base-color, #fff), $base-color);
}

.ns-gradient-promotionpages-payment {
	// background: linear-gradient(to right, mix($base-color, #fff), $base-color) !important;
}

.ns-gradient-promotionpages-pintuan-payment {
	background: rgba($base-color, 0.08) !important;
}

.ns-gradient-diy-goods-list {
	border-color: rgba($base-color, 0.2) !important;
}

.ns-gradient-detail-coupons-right-border {
	border-right-color: rgba($base-color, 0.2) !important;
}

.ns-gradient-detail-coupons {
	background-color: rgba($base-color, 0.8) !important;
}

.ns-pages-goods-category-category {
	// background-image: linear-gradient(135deg, $base-color, #ff7444) !important;
}

.ns-gradient-pintuan-border-color {
	border-color: rgba($base-color, 0.2) !important;
}

.goods-list.single-column .pro-info button,
.goods-list.single-column .pro-info .buy-btn {
	// background: linear-gradient(to right, mix($base-color, #fff), $base-color) !important;
}

.goods-list.single-column .pintuan-info .pintuan-num {
	// background: mix($base-color, #fff, 30%) !important;
}
.goods-list.single-column .pintuan-info .pinfan-num {
	// background: mix($base-color, #fff, 10%) !important;
}

.order-box-btn {
	display: inline-block;
	line-height: 56rpx;
	padding: 0 30rpx;
	font-size: 26rpx;
	color: $color-title;
	border: 1.5px solid #999;
	box-sizing: border-box;
	border-radius: 60rpx;
	margin-left: $margin-both;
	&.order-pay {
		color: #fff;
		border-color: #fff;
	}
	&.color-base-bg {
		color: #fff;
	}
}

// ***************消费券***************
// 消费券背景色渐变
.balance-wrap {
	// background: linear-gradient(to right, $base-color, mix($base-color, #fff, 70%)) !important;
}

.color-base-text-light {
	// color: mix($base-color, #fff, 50%) !important;
}
//瓜分红包规则背景
.ns-rule-bg {
	background: rgba(#fff, 0.1) !important;
}

// 解决uni.showModal弹窗标题继承父级样式
uni-modal .uni-modal__hd {
	font-size: 36rpx;
}

// 解决弹框的字体大小
uni-toast {
	.uni-simple-toast__text {
		font-size: 26rpx;
		padding: 20rpx 40rpx;
		border-radius: 10rpx;
	}
	.uni-toast {
		width: 200rpx;
	}
	.uni-icon_toast.uni-loading {
		margin: 40rpx 0 0;
		width: 76rpx;
		height: 76rpx;
	}
	.uni-toast__content {
		font-size: 28rpx;
		margin: 0 0 30rpx;
	}
}

.iconfont {
	font-size: 32rpx;
}

/* 兼容苹果X以上的手机样式 */
.iphone-x {
	/* 	padding-bottom: 68rpx !important; */
	padding-bottom: constant(safe-area-inset-bottom);
	padding-bottom: env(safe-area-inset-bottom);
}

.iphone-x-fixed {
	bottom: 68rpx !important;
}

// ***************其他***************
/* 隐藏滚动条 */
::-webkit-scrollbar {
	width: 0;
	height: 0;
	color: transparent;
}

scroll-view ::-webkit-scrollbar {
	width: 0;
	height: 0;
	background-color: transparent;
}

/deep/::-webkit-scrollbar {
	width: 0;
	height: 0;
	background-color: transparent;
	display: none;
}

/* 单行超出隐藏 */
.using-hidden {
	word-break: break-all;
	text-overflow: ellipsis;
	overflow: hidden;
	display: -webkit-box;
	-webkit-line-clamp: 1;
	-webkit-box-orient: vertical;
	white-space: break-spaces;
}
/* 多行超出隐藏 */
.multi-hidden {
	word-break: break-all;
	text-overflow: ellipsis;
	overflow: hidden;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
}

// 价格样式
.price-color{
	color: var(--price-color)!important;
}
.price-style{
	font-family: 'myFont','-apple-system', 'BlinkMacSystemFont', 'Helvetica Neue', 'Helvetica', 'Segoe UI', 'Arial', 'Roboto', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft Yahei','sans-serif';
	// font-family: 'PingFang SC', 'Roboto Medium';
	color: var(--price-color)!important;
	font-weight: 500!important;
	&.large{
		font-size: 32rpx!important;
	}
	&.small{
		font-size: 24rpx!important;
	}
}
 
.price-font{
	font-family: 'myFont','-apple-system', 'BlinkMacSystemFont', 'Helvetica Neue', 'Helvetica', 'Segoe UI', 'Arial', 'Roboto', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft Yahei','sans-serif';
	// font-family: 'PingFang SC', 'Roboto Medium';
	font-weight: 500!important;
}

/deep/ .reward-popup .uni-popup__wrapper-box {
	background: none !important;
	max-width: unset !important;
	max-height: unset !important;
	overflow: unset !important;
}