CardItem.sass 3.32 KB
/* packageStudyCenter/pages/myTask/components/CardItem/CardItem.wxss */
.item-container {
  position: relative;
  width: 100%;
  background-color: #fff;
  border-radius: var(--fontSize24);
  overflow: hidden;
  font-size: 0;
  box-shadow: 0 var(--fontSize4) var(--fontSize16) 0 #2a61eb1a;
}
.image-box {
  height: var(--fontSize180);
  .item-img {
    width: 100%;
    height: 100%;
  }
  .image-tag {
    position: absolute;
    left: 0;
    top: 0;
    width: var(--fontSize94);
    height: var(--fontSize48);
  }
  .tag {
    position: absolute;
    top: var(--fontSize16);
    right: var(--fontSize24);
    width: var(--fontSize72);
    height: var(--fontSize40);
    border-radius: var(--fontSize4);
    color: #FFFFFF;
    font-size: var(--fontSize24);
    text-align: center;
    line-height: var(--fontSize40);
    background: #00000059;
  }
}
.item-content {
  padding: var(--fontSize14);
  .item-title {
    font-size: 30rpx;
    color: #292D33;
    font-weight: 500;
    margin-bottom: var(--fontSize8);
    width: var(--fontSize307);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .item {
    position: relative;
    display: flex;
    align-items: center;
    font-size: var(--fontSize24);
    margin-bottom: var(--fontSize4);
    &.transparent {
      opacity: 0;
    }
    .label {
      flex-shrink: 0;
      width: var(--fontSize96);
      color: #999EA8;
      margin-right: var(--fontSize20);
      &.custom {
        width: var(--fontSize144);
      }
    }
    .value {
      color: #666666;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      .split {
        margin: 0 var(--fontSize8);
      }
      .green {
        color: #2CCA74;
      }
      .red {
        color: #EB4E4E;
      }
    }
  }
}
.dot-value {
  width: 12rpx;
  height: 12rpx;
  border-radius: 50%;
  background: #2CCA74;
  margin-right: 8rpx;
}

.green {
  color: #2CCA74;
}

.progress-box {
  width: var(--fontSize129);
  height: var(--fontSize12);
  background: linear-gradient(128.8deg, rgba(117, 188, 255, .35) 0%, rgba(44, 102, 247, .35) 100%);
  border-radius: var(--fontSize8);
}

.progress-text {
  color: #3B73FF;
  font-size: 24rpx;
  position: absolute;
  top: 50%;
  right: 0;
  transform: translateY(-50%);
}

.progress-bar {
  height: 100%;
  background: linear-gradient(128.8deg, #75bcff 0%, #2c66f7 100%);
  border-radius: 8rpx;
}

.score-box {
  display: flex;
  align-items: center;
  .score-text {
    flex-shrink: 0;
    width: var(--fontSize40);
    font-size: var(--fontSize28);
    color: #666666;
    margin-left: var(--fontSize12);
  }
}

.item-btn {
  margin-top: var(--fontSize8);
  width: var(--fontSize307);
  height: var(--fontSize56);
  border-radius: var(--fontSize24);
  background: #F1F7FE;
  font-size: var(--fontSize26);
  color: #2C66F7;
  text-align: center;
  line-height: var(--fontSize56);
  &.transparent {
    opacity: 0;
  }
}

.completed-bg {
  width: var(--fontSize112);
  height: var(--fontSize112);
  position: absolute;
  bottom: var(--fontSize16);
  right: var(--fontSize16);
}

.studied-box {
  display: flex;
  align-items: center;
  font-size: var(--fontSize24);
  color: #999EA8;
  margin-top: var(--fontSize4);
  .icon {
    flex-shrink: 0;
    width: var(--fontSize32);
    height: var(--fontSize32);
    margin-right: var(--fontSize8);
  }
}
.transparent {
  opacity: 0;
}