@use 'element-plus/theme-chalk/src/common/var.scss' as *;
@use 'element-plus/theme-chalk/src/mixins/config.scss' as *;
@use 'element-plus/theme-chalk/src/mixins/mixins.scss' as *;

@include b(video) {
  $poster: #{&}__poster;
  position: relative;
  box-sizing: border-box;

  &__poster {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    img {
      display: block;
      max-height: 100%;
      max-width: 100%;
      object-fit: contain;
      margin: 0 auto;
    }
  }

  &__player {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    video {
      max-height: 100%;
      max-width: 100%;
      margin: 0 auto;
    }
  }

  &__duration {
    position: absolute;
    right: 10px;
    bottom: 4px;
    color: #fff;
    z-index: 1;
  }

  &__action {
    height: 100%;
    width: 100%;
    position: absolute;
    left: 0;
    top: 0;
    margin: 0;
    padding: 0;
    background: transparent;
    cursor: pointer;
  }

  &__btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
  }
}
