<template>
  <van-popup get-container="body" v-model="popup" round :style="{ width: '292px' }" @close="cancel">
    <div class="pop">
      <div class="body flex">
        <img class="img" src="/img/auth/icon4.png" alt="极度证券">
        <div class="title">
          <!-- 认证提示 -->
          {{ $t('home.l41') }}
        </div>
        <div class="tip">
          <!-- 请完成个人身份认证后再使用法币存取款 -->
          {{ $t('home.l40') }}
        </div>
      </div>
      <div class="btn-box flex">
        <div class="btn rtn" @click="cancel">
          <!-- 取消 -->
          {{ $t('common.l2') }}
        </div>
        <div class="btn ltn" @click="$router.push('/auth')">
          <!-- 立即认证 -->
          {{ $t('home.l42') }}
        </div>
      </div>
    </div>
  </van-popup>
</template>
<script>
export default {
  data () {
    return {
      popup: false
    }
  },
  beforeDestroy() {
    this.popup = false
  },
  created () {
    this.popup = true
  },
  methods: {
    cancel() {
      this.$emit('cancel')
    }
  }
}
</script>
<style lang="less" scoped>
.pop {
  padding: 27px 20px 16px;
}
.body {
  flex-direction: column;
  justify-content: center;
  text-align: center;
  padding-bottom: 27px;
  line-height: 1;
  .img {
    width: 51px;
    margin-bottom: 18px;
  }
  .title {
    font-weight: 600;
    font-size: 18px;
    margin-bottom: 11px;
  }
  .tip {
    font-size: 14px;
    color: #8C8C8C;
  }
}
.btn-box {
  column-gap: 16px;
  .btn {
    text-align: center;
    cursor: pointer;
    border-radius: 6px;
    line-height: 38px;
    flex: 1;
    font-weight: 600;
    font-size: 16px;
  }
  .ltn {
    background-color: #000000;
    color: #fff;
    border: 1px solid #000;
  }
  .rtn {
    border: 1px solid #DEDEDE;
  }
}
</style>