<template>
  <div class="w-full" v-bind="$attrs">
    <div class="title_text flex items-center">
      <span :style="{ marginLeft: `${gap}px`, marginRight: `${gap}px` }">{{ title }}</span>
    </div>
    <div class="text-36px text-center text-#9BABBA leading-50px">
      Date range: Last 60 days
      <span class="ml-20px text-24px text-#9BABBA">As of {{ time }}</span>
    </div>
  </div>
</template>

<script setup lang="ts">
import { defineProps } from 'vue';

defineProps({
  title: {
    type: String,
    default: '',
  },
  time: {
    type: String,
    default: '',
  },
  gap: {
    type: Number,
    default: 90,
  },
});
</script>

<style lang="less" scoped>
.title_text {
  font-size: 56px;
  line-height: 78px;
  text-align: center;
  font-family: "PingFangSC-Semibold", sans-serif;
  &::before {
    content: '';
    display: block;
    flex: 1;
    height: 0;
    border: 2px solid;
    border-image: linear-gradient(270deg, rgba(38, 126, 209, 1), rgba(38, 126, 209, 0)) 2 2;
  }
  &::after {
    content: '';
    display: block;
    flex: 1;
    width: 262px;
    height: 0;
    border: 2px solid;
    border-image: linear-gradient(270deg, rgba(38, 126, 209, 0), rgba(38, 126, 209, 1)) 2 2;
  }
}
</style>
