<template>
  <section class="border6" :class="'border6-' + theme">
    <div class="border6-title">
      <img src="../asset/ic-badge.png" v-if="theme === '1'" />
      <h2>{{ title }}</h2>
    </div>
    <div class="slot">
      <slot/>
    </div>
  </section>
</template>

<script>
export default {
  name: 'border6',

  props: ['title', 'theme']
}
</script>

<style lang="scss" scoped>
.border6 {
  height: 100%;

  .border6-title {
    display: flex;
    position: relative;
    height: 40px;
    // line-height: 26px;
    padding: 4px 0 0 22px;
    box-sizing: border-box;
    font-family: PingFangSC-Medium, PingFang SC;
    background-image: url(../asset/title6.png);
    background-position: bottom;
    background-size: 100% 7px;
    background-repeat: no-repeat;

    h2 {
      line-height: 1;
      color: #fff;
      font-size: 20px;
      font-weight: normal;
      letter-spacing: 1px;
    }

    img {
      width: 28px;
      height: 28px;
      margin-right: 8px;
    }

    &:after {
      position: absolute;
      top: 16px;
      left: 0;
      z-index: 1;
      width: 6px;
      height: 6px;
      border-radius: 50%;
      background: #52575aff;
      content: '';
    }
  }

  &.border6-1 .border6-title {
    background-image: url(../asset/title-6-dj.png);
    background-position: bottom;

    &:after {
      background: #FFA086;
    }
  }

  .slot {
    height: calc(100% - 40px);
    padding-top: 19px;
  }
}
</style>
