<template>
  <div class="foot-mian">
    <div class="foot-box">
      <div class="foot-content">
        <div class="left-content">
          <div>
            <a href="http://jsj.moe.gov.cn" target="_blank"> {{ $t('foot.link1') }} </a>
          </div>
          <!-- <div>
            <a href="http://www.pbcsf.tsinghua.edu.cn" target="_blank"> {{ $t('foot.link2') }} </a>
          </div> -->
          <!-- <div>
            合作大学官网
          </div> -->
        </div>
        <div :class="$cookies.get('lang') == 'en-US' ? 'center-content f-size' : 'center-content'">
          <div class="address" v-html="$t('foot.address')"></div>
          <div class="phone" v-html="$t('foot.contact')"></div>
          <div class="mail" v-html="$t('foot.email')"></div>
        </div>
        <div class="right-content">
          <img src="https://webapp-pub.ezijing.com/project/marywood/ezijing-code.jpg" class="code" />
          <div class="tips-txt">
            <img src="https://zws-imgs-pub.ezijing.com/static/public/184235d9f6edbb39d52fc6f77339ff5b.png" alt="" />
            <div class="txt">{{ $t('foot.weChat') }}</div>
          </div>
        </div>
        <div class="right-content">
          <img src="https://webapp-pub.ezijing.com/project/marywood/ezijing_xet_x.png" alt="" class="code" />
          <div class="tips-txt">
            <img src="https://webapp-pub.ezijing.com/www/pc/icon_gongkaike.png" alt="" />
            <div class="txt">{{ $t('foot.ezjClass') }}</div>
          </div>
        </div>
      </div>
      <div class="links" v-html="$t('foot.relation')"></div>
    </div>
    <div class="copyright" style="height: 40px; line-height: 40px; color: rgba(153, 153, 153, 1); background: #fff">
      <div class="inner" style="width: 100%; justify-content: center; display: flex">
        <p style="font-size: 12px">
          Copyright © 2017 Zijing Education. All rights reserved. 清控紫荆（北京）教育科技股份有限公司
        </p>
        <a
          target="_blank"
          href="https://tsm.miit.gov.cn/dxxzsp/"
          style="color: rgba(153, 153, 153, 1); text-decoration: none; margin-left: 10px"
        >
          <p style="font-size: 12px">京ICP证150431号</p>
        </a>
        <a
          target="_blank"
          class="record"
          href="http://www.beian.gov.cn/portal/registerSystemInfo?recordcode=11010802023681"
          style="color: rgba(153, 153, 153, 1);text-decoration: none;align-items: center;display: flex;margin-right: 5px;"
        >
          <img
            src="https://zws-imgs-pub.ezijing.com/e0a0ec47dfdfc1e0797b1d5254021d00.png"
            alt=""
            style="width: 20px; height: 20px; margin: 0 6px; display: block"
          />
          <p style="font-size: 12px">安备 11010802023681号</p>
        </a>
        <a
          target="_blank"
          href="https://beian.miit.gov.cn/#/Integrated/index"
          style="color: rgba(153, 153, 153, 1); text-decoration: none"
        >
          <p style="font-size: 12px">{{ icpNumber }}</p>
        </a>
      </div>
    </div>
  </div>
</template>
<script>
export default {
  computed: {
    icpNumber() {
      const map = [
        { icp: '京ICP备15016866号-4', host: 'seg-aisa.cn' },
        { icp: '京ICP备15016866号-5', host: 'segedu.cn' },
        { icp: '京ICP备15016866号-6', host: 'segcdc.cn' },
        { icp: '京ICP备15016866号-7', host: 'segcdc.com' },
        { icp: '京ICP备15016866号-8', host: 'segshms.cn' },
        { icp: '京ICP备15016866号-9', host: 'segshms.com' },
        { icp: '京ICP备15016866号-10', host: 'segcrcs.com' },
        { icp: '京ICP备15016866号-11', host: 'segcrcs.cn' },
        { icp: '京ICP备15016866号-12', host: 'seghim.cn' },
        { icp: '京ICP备15016866号-13', host: 'seghim.com' },
        { icp: '京ICP备15016866号-14', host: 'seg-aisa.com' },
        { icp: '京ICP备15016866号-1', host: 'ezijing.com' }
      ]
      const found = map.find(item => {
        return process.browser && location.hostname.includes(item.host)
      })
      return found ? found.icp : '京ICP备15016866号-1'
    }
  }
}
</script>
<style lang="scss" scoped>
.foot-mian {
  width: 100%;
  min-width: 1200px;
  background: rgba(170, 25, 65, 1);
  .links {
    padding-top: 12px;
    font-size: 14px;
    font-weight: 300;
    line-height: 24px;
    color: #ffffff;
    opacity: 0.6;
    width: 1200px;
    margin: 0 auto;
  }
  .foot-box {
    padding: 80px 0 35px;
    width: 1200px;
    margin: 0 auto;
  }
  .foot-content {
    // height: 300px;
    display: flex;
    .left-content {
      div {
        opacity: 0.7;
        font-size: 18px;
        font-weight: 300;
        line-height: 50px;
        color: #ffffff;
        text-decoration: underline;
        letter-spacing: 3px;
      }
    }
    .center-content {
      font-size: 18px;
      line-height: 32px;
      color: #ffffff;
      letter-spacing: 4px;
      opacity: 0.7;
      margin-left: 88px;
      white-space: nowrap;
      .address {
        max-width: 610px;
      }
      &.f-size {
        font-size: 16px;
      }
    }
    .right-content {
      margin-left: auto;
      padding-top: 20px;
      .code {
        width: 120px;
        display: block;
      }
      .tips-txt {
        padding-top: 20px;
        display: flex;
        align-items: center;
        justify-content: center;
        img {
          width: 21px;
          display: block;
        }
        .txt {
          font-size: 14px;
          color: #ffffff;
          margin-left: 7px;
        }
      }
    }
  }
}
</style>
