<template>
	<view class="page">
		<image class="tpbg" src="https://t17.9026.com/web/statics/image/index/3.png" mode=""></image>
		<app-nav-bar v-if="true"
		             :fixed="true"
		             :background-color="''"
		             :xStyle="1"
		             :hasMallSetting="2"
					 :hasHeight="true"
					 @headHeight="headHeight"
		></app-nav-bar>
		<view class="w" :style="{'height':navbarHeight}"></view>
		<view class="center">
			<view class="main-left tagf">
				<view class="tag" :class="{'active':activeIndex===index?true:false}" v-for="(item,index) in ['全部','硬包装','软包装','热门商品站位']" :key="index" @click="selectTag(index)">
					{{item}}
				</view>
			</view>
			<view class="item" v-for="(item,index) in 6" :key="index">
				<view class="main-between img">
					<view style="width: 419rpx;height: 281rpx;">
						<image style="width: 419rpx;height: 281rpx;" src="https://t17.9026.com/web/statics/image/index/2.png" mode=""></image>
					</view>
					<view style="width: 206rpx;">
						<image style="width: 206rpx;height: 136rpx;" src="https://t17.9026.com/web/statics/image/index/2.png" mode=""></image>
						<image style="width: 206rpx;height: 136rpx;" src="https://t17.9026.com/web/statics/image/index/2.png" mode=""></image>
					</view>
				</view>
				<view class="main-between pl" @click="goPage">
					<view class="main-between-y">
						<view class="title t-omit">兴城人居ins软陶简洁大气套餐软陶简洁大气套餐软陶简洁大气套餐软陶简洁大气套餐软陶简洁大气套餐软陶简洁大气套餐</view>
						<view class="desc">已售:110套 | 266人收藏</view>
						<view class="price"><text>￥</text>299.00</view>
					</view>
					<view class="cross-bottom arrow-right">
						<image src="https://t17.9026.com/web/statics/image/index/arrow-right-gray.png" mode=""></image>
					</view>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	import appNavBar from '@/components/page-component/index/app-nav-bar.vue';
	export default {
		components:{
			appNavBar
		},
		data() {
			return {
				activeIndex:0,
				navbarHeight:'',
			};
		},
		methods:{
			selectTag(index){
				this.activeIndex=index
			},
			headHeight(e){
				this.navbarHeight=e+'px'
			},
			goPage(){
				uni.navigateTo({
					url:'/pages/case/projectInfo?id=10'
				})
			}
		}
	}
</script>

<style lang="scss" scoped>
	.page{
		position: relative;
		min-height: 100vh;
	}
	.tpbg{
		width: 750rpx;
		height: 368rpx;
		position: fixed;
		top: 0;
		left: 0;
		z-index: -1;
	}
	.w{
		width: 750rpx;
	}
	.center{
		width: 750rpx;
		height: auto;
		background: #F8F8F8;
		border-radius: 20rpx;
		overflow: hidden;
		padding: 36rpx;
		.tagf{
			padding-bottom: 26rpx;
		}
		.tag{
			min-width: 131rpx;
			height: 51rpx;
			background: #EFEFEF;
			border-radius: 10rpx;
			font-size: 24rpx;
			font-weight: 500;
			color: #999999;
			text-align: center;
			line-height: 51rpx;
			padding: 0 15rpx;
			margin-right: 20rpx;
		}
		.active{
			background: #A18353;
			color: #FFFFFF;
		}
		.item{
			width: 678rpx;
			height: 477rpx;
			background: #FFFFFF;
			border-radius: 8rpx;
			margin:0 auto 24rpx;
			padding: 27rpx 22rpx;
			.img{
				height: 281rpx;
				border-radius: 10rpx;
				overflow: hidden;
			}
			.pl{
				margin-top: 25rpx;
				.title{
					width: 620rpx;
					font-size: 32rpx;
					font-weight: bold;
					color: #222222;
				}
				.desc{
					font-size: 22rpx;
					font-weight: 500;
					color: #999999;
				}
				.price{
					font-size: 28rpx;
					font-weight: 500;
					color: #F93F3F;
				}
				.arrow-right{
					image{
						width: 15rpx;
						height: 26rpx;
					}
				}
			}
		}
	}
</style>
