<template>
  <div class="stat-cards-container">
    <div class="stat-card" v-for="(item, idx) in props.numberList" :key="idx">
      <div class="stat-card-title">{{ item.title }}</div>
      <div class="stat-card-value">
        <div class="card-value-top">
          <div>
            <p class="pro-title">11月完成</p>
            <p class="pro-value">1.1亿元</p>
          </div>
          <div>
            <p class="pro-title">第三季度完成</p>
            <p class="pro-value">4.21亿元</p>
          </div>
        </div>
        <div class="card-value-bottom">
          <div>
            <p class="pro-title">2025年累计完成</p>
            <p class="pro-value">112.1亿元</p>
          </div>
          <div class="value-bottom-right">
            <p class="comparison">累计同期环比</p>
            <p class="comparison-value">+1.2%</p>
          </div>
        </div>
      </div>
    </div>
  </div>
</template>

<script setup>
import { onMounted, reactive, watch, ref } from "vue";
const props = defineProps({
  numberList: {
    type: Array,
    default: () => [],
  },
});
</script>

<style scoped lang="less">
.stat-cards-container {
  display: flex;
  justify-content: center;
  align-items: center;
  .stat-card {
    .vw(width, 170);
    .vw(border-radius, 5);
    .vw(padding, 10);
    .vw(margin,10);
    background-image: url("../assets/images/complete.png");
    background-repeat: no-repeat;
    background-size: 100% 100%;
    background-position: center;
    .stat-card-title {
      .font(12);
      text-align: center;
    }
    .stat-card-value {
      .font(12);
      .card-value-top,
      .card-value-bottom {
        display: flex;
        justify-content: space-between;
        p {
          height: 10px;
        }
        .pro-title {
          .font(12);
        }
        .pro-value {
          .font(16);
          color: @Color;
        }
        .comparison {
          .font(10);
        }
        .comparison-value {
          color: green;
        }
      }
      .value-bottom-right {
        .vh(margin-top,13);
      }
    }
  }
}
</style>
