<!-- @format -->

<script lang="ts" setup>
import solutionIcon01 from '~/assets/images/solutions_icon01.png'
import solutionIcon02 from '~/assets/images/solutions_icon02.png'
import solutionIcon03 from '~/assets/images/solutions_icon03.png'
import solutionIcon04 from '~/assets/images/solutions_icon04.png'

const solution = ref('ecommerce')
const list = ref([
  {
    key: 'ecommerce',
    title: 'Ecommerce',
  },
  {
    key: 'brands',
    title: 'Brands',
  },
  {
    key: 'retailers',
    title: 'Retailers',
  },
])
const solutions = ref([
  {
    title: 'Real-Time Trend Curation',
    img: solutionIcon01,
    subTitle:
      'Our team constantly monitors market shifts, viral demand, and emerging bestsellers to deliver high-potential products to you.',
  },
  {
    img: solutionIcon02,
    title: 'Real-Time Trend Curation',
    subTitle:
      'Our team constantly monitors market shifts, viral demand, and emerging bestsellers to deliver high-potential products to you.',
  },
  {
    img: solutionIcon03,
    title: 'Real-Time Trend Curation',
    subTitle:
      'Our team constantly monitors market shifts, viral demand, and emerging bestsellers to deliver high-potential products to you.',
  },
  {
    img: solutionIcon04,
    title: 'Real-Time Trend Curation',
    subTitle:
      'Our team constantly monitors market shifts, viral demand, and emerging bestsellers to deliver high-potential products to you.',
  },
])
</script>

<template>
  <div class="bg-#F3F4FB pt-250px pb-120px">
    <div class="w-1200-auto text-center">
      <h2 class="text-36px fw-800 text-#333 !mb-20px">
        Creative, Trend-Driven Solutions
      </h2>
      <div class="text-#999 text-22px mb-40px">
        EJET SPARK FOR
      </div>
      <div class="flex gap-20px justify-center mb-60px">
        <div
          v-for="(item, index) in list"
          :key="index"
          class="py-12px w-170px b-rd-200px text-18px cursor-pointer hover:bg-#9B6CFF hover:text-#fff transition-all duration-300"
          :class="
            solution === item.key
              ? '!bg-#9B6CFF !text-#fff'
              : 'bg-#fff text-#767676'
          "
          @click="solution = item.key"
        >
          <div>{{ item.title }}</div>
        </div>
      </div>
      <div class="flex gap-120px text-left">
        <div class="b-rd-10px w-360px overflow-hidden">
          <img
            src="~/assets/images/solutions_img01.png"
            class="w-100% h-258px"
            alt=""
          >
          <div
            class="py-20px px-30px b-rd-tl-10px b-rd-tr-10px mt--60px bg-#fff pos-relative z-100"
          >
            <h3 class="text-24px fw-bold text-#333">
              Ecommerce
            </h3>
            <div class="my-22px lh-24px text-#666">
              Scale Smarter with Viral-Ready Products for Online Growth
            </div>
            <el-button class="!bg-#fff !b-rd-6px !h-40px">
              <nuxt-link to="/solutions">
                View Catalogs
              </nuxt-link>
            </el-button>
          </div>
        </div>
        <div class="flex-1">
          <div class="grid grid-cols-2 gap-col-80px gap-row-50px">
            <div v-for="(item, index) in solutions" :key="index">
              <img :src="item.img" class="w-50px h-50px" alt="" srcset="">
              <h4 class="!mt-20px !mb-10px text-#333 text-18px fw-800">
                {{ item.title }}
              </h4>
              <div class="text-#666 lh-24px">
                {{ item.subTitle }}
              </div>
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>
</template>

<style lang="less" scoped></style>
