<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">{{ item.value }}</div>
      <div class="amount">
        <div>
          <p class="amount-title">实际完成金额</p>
          <p class="amount-value">2.87<span>亿元</span></p>
        </div>
        <div>
          <p class="amount-title">计划完成金额</p>
          <p class="amount-value">4.21<span>亿元</span></p>
        </div>
      </div>
    </div>
  </div>
</template>

<script setup>
const props = defineProps({
  numberList: {
    type: Array,
    default: () => [],
  },
});
</script>

<style scoped lang="less">
.stat-cards-container {
  display: flex;
  .stat-card {
    .vw(width, 170);
    .vw(border-radius, 5);
    .vw(padding, 10);
    .vw(margin,10);
    background-image: url("@/assets/images/total2.png");
    background-repeat: no-repeat;
    background-size: 100% 100%;
    background-position: center;
    .stat-card-title {
      .font(12);
      font-weight: 700;
    }
    .stat-card-value {
      .font(20);
      color: @Color;
      font-family: "DIN";
    }
    .amount {
      display: flex;
      justify-content: space-between;
      .amount-title {
        .font(10);
        .vh(height, 5);
      }
      .amount-value {
        .font(16);
        color: @Color;
        font-family: "DIN";
        font-weight: 100;
        span {
          .font(10);
          font-weight: 400;
        }
      }
    }
  }
}
</style>
