<template>
	<view class="relative" style="height: 100vh;">
		<image style="width: 100%;height: 600rpx;" src="../../static/image/index/vip_bg.png"></image>
		<view class="p14">
			<view class="flex jc-sb ai-c">
				<view class="option_tem relative" :class="checkedPrice===item.priceId?'checked_item':''" v-for="(item,index) of priceList" :key="index" @click="checkPrice(item.priceId,item.money)">
					<text class="fw600 fs16 cor-333">{{item.title}}</text>
					<view class="mt5">
						<text class="fs14" style="color: #FF6E02;">¥</text>
						<text class="fs30 fw600" style="color: #FF6E02;">{{item.money}}</text>
					</view>
					<text class="fs12 cor-999">长期有效</text>
					<view class="bottom_box fs12 cor-333" :class="checkedPrice===item.priceId?'checked_bottom':''">赠送vip题库</view>
					<view class="tag" v-if="item.all">
						<text style="transform:scale(0.83);">合买更优惠</text>
						</view>
				</view>
			</view>
			<view class="mt15 intr_box">
				<view class="fw600 fs16 cor-000">免费获赠<text style="color: #FF6E02;">价值68元</text>的VIP题库</view>
				<view class="flex ai-c jc-sb mt15">
					<view class="flex ai-c">
						<image style="width: 63rpx;height: 63rpx;margin-right: 5px;" src="../../static/image/index/vip500.png"></image>
						<view class="vip_item">含精简500题</view>
					</view>
					<view class="flex ai-c">
						<image style="width: 63rpx;height: 63rpx;margin-right: 5px;" src="../../static/image/index/vipmijuan.png"></image>
						<view class="vip_item">含考前密卷2套</view>
					</view>
				</view>
			</view>
		</view>
		<view class="wp100 p14" style="position: absolute;left: 0;bottom:20px">
			<view class="sub_btn flex ai-c jc-sb">
				<text class="cor-fff fs14">¥<text class="fs24 cor-fff">{{nowPrice}}</text></text>
				<image style="width: 276rpx;height: 88rpx;margin-top: -5px;" src="../../static/image/index/buy.png"></image>
			</view>
		</view>
		</view>
</template>

<script>
	export default {
		data(){
			return{
				nowPrice:168,
				checkedPrice:0,
				priceList:[{
					priceId:0,
					title:'科一精品课',
					money:168,
					all:false
				},
				{
					priceId:1,
					title:'科四精品课',
					money:168,
					all:false
				},
				{
					priceId:2,
					title:'科一+科四',
					money:268,
					all:true,
				}]
			}
		},
		methods:{
			checkPrice(val,price){
				this.checkedPrice=val
				this.nowPrice=price
			}
		}
		}
</script>

<style scoped>
	.option_tem{
		width: 220rpx;
		height: 241rpx;
		text-align: center;
		background: #FFFFFF;
		border: 2px solid #D8D8D8;
		border-radius: 16rpx 46rpx 16rpx 16rpx;
		padding: 14px;
	}
	.checked_item{
		width: 228rpx;
		background: #FFF0E5;
		border: 4px solid #FF6E02;
	}
	.bottom_box{
		width: 214rpx;
		height: 40rpx;
		line-height: 40rpx;
		text-align: center;
		background: rgb(239,239,239);
		border-radius: 0 0 16rpx 16rpx;
		position: absolute;
		bottom: 0;
		left: 0;
	}
	.checked_bottom{
		width: 218rpx;
		border-radius: 0 0 16rpx 12rpx;
		background-color: #FF6E02;
		color:#fff
	}
	.tag{
		width: 122rpx;
		height: 36rpx;
		background: linear-gradient(90deg, #E66501 0%, #F8A42C 100%);
		border-radius: 8rpx 20rpx 8rpx 8rpx;
		line-height: 36rpx;
		text-align: center;
		font-size: 12px;
		color: #FFFC27;
		position: absolute;
		left: 10rpx;
		top:-18rpx
	}
	.intr_box{
		width: 100%;
		text-align: center;
		padding: 40rpx;
		background: #FFF0E5;
		border-radius: 16rpx;
	}
	.vip_item{
		width: 208rpx;
		height: 54rpx;
		line-height: 54rpx;
		text-align: center;
		font-size: 14px;
		background: #F3D7C2;
		border-radius: 0rpx 10rpx 10rpx 10rpx;
	}
	.sub_btn{
		width:100%;
		height: 110rpx;
		border: 4px solid #F59B26;
		background: linear-gradient(0deg, #E66501 0%, #F8A42C 100%);
		box-shadow: 0rpx 16rpx 20rpx 1rpx rgba(245,155,38,0.78);
		border-radius: 55rpx;
		padding: 14rpx;
	}
</style>