<template>
  <view class="rotate-tip" >
    <view class="tip" >
      <view class="icon"  >
        <img class="arrow arrow-ani"  :src="staticImg.rotateArrow" alt="">
        <img class="phone phone-ani" :src="staticImg.phone" alt="">
      </view>
      <view class="desc" >
        为了更好的体验，请使用竖屏浏览
      </view>
    </view>
  </view> 
</template>



<script setup lang="ts" >

import { useStaticImg } from '@/hooks/index'

const staticImg = useStaticImg()


</script>

<style lang="less">
.rotate-tip {
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.6);
  position: fixed;
  top: 0;
  left: 0;
  z-index: 10000;
  display: flex;
  justify-content: center;
  align-items: center;
  .tip {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    .icon {
      width: 144px;
      height: 144px;
      position: relative;
      .arrow {
        width: 144px;
        height: 144px;
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        transform-origin: 0% 0%;
      }
      .phone {
        width: 144px;
        height: 144px;
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        rotate: 90deg;
        transform-origin: 0% 0%;
      }
      .arrow-ani {
        animation: arrow-ani-keyframes 3s ease-in 0s infinite;
      }
      .phone-ani {
        animation: phone-ani-keyframes 3s ease-in 0s infinite;
      }
    }
    .desc {
      font-size: 16px;
      font-family: PingFang SC-Regular, PingFang SC;
      font-weight: 400;
      color: #FFFFFF;
      line-height: 22px;
    }
  }
}

@keyframes  arrow-ani-keyframes {
  0% {
    rotate: 0deg;
    opacity: 1;
  }
  25% {
    rotate: -90deg;
    opacity: 0;
  }
  100% {
    rotate: -90deg;
    opacity: 0;
  }
}

@keyframes phone-ani-keyframes {
  0% {
    rotate: 90deg;
  }
  25% {
    rotate: 90deg;
  }
  50% {
    rotate: 0deg;
  }
  100% {
    rotate: 0deg;
  }
}
</style>


