.page-my-coupons {
  // 头部切换栏
  .tab {
    width: 750rpx;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 30rpx 0;
    background: #fff;
    border-radius: 0 0 10rpx 10rpx;
    &.unused{
      .item {
        width: 33%;
      }
    }
    &.used{
      .item {
        width: 50%;
      }
    }
    .item {
      text-align: center;
      line-height: 28rpx;
      &.active{
        color: #fc1b35;
        font-weight: 600;
      }
    }
  }
  // 优惠券列表
  .coupons-box {
    padding: 0 30rpx;
    padding-bottom: 40rpx;
    .coupon-tit {
      margin-top: 40rpx;
      .tit-text {
        font-weight: 600;
      }
      .tit-des {
        color: #999;
        font-size: 20rpx;
        margin-left: -6rpx;
      }
    }
    .coupon-item {
      margin: 30rpx 0;
      overflow: hidden;
      .item-box {
        display: flex;
        position: relative;
        &::before,&::after{
          position: absolute;
          right: 214rpx;
          display: block;
          width: 20rpx;
          height: 20rpx;
          border-radius: 50%;
          background: #f2f3f7;
          content: " ";
          font-size: 0;
          z-index: 5;
        }
        &::before {
          top: -10rpx;
          box-shadow: 0 -2rpx 2rpx rgba(0,0,0,.06) inset;
        }
        &::after {
          bottom: -10rpx;
          box-shadow: 0 2rpx 2rpx rgba(0,0,0,.06) inset;
        }
      }
      .c-price {
        padding: 20rpx;
        color: #fff;
        width: 184rpx;
        border-radius: 0 10rpx 10rpx 0;
        box-shadow: 0 0 6rpx rgba(0,0,0,.05);
        background: linear-gradient(to right, #5695d6, #6779da);
        display: flex;
        align-items: center;
        justify-content: center;
        position: relative;
        z-index: 1;
        .price {
          justify-content: center;
          font-weight: 600;
          color: #fff;
          .big {
            font-size: 48rpx;
          }
          .small {
            font-size: 24rpx;
            margin-right: 6rpx;
          }
        }
        .c-condition {
          text-align: center;
          text-overflow: ellipsis;
          overflow: hidden;
        }
        .btn {
          width: 120rpx;
          text-align: center;
          height: 36rpx;
          line-height: 36rpx;
          font-size: 20rpx;
          color: #6779da;
          background: #fff;
          border-radius: 36rpx;
          margin: 10rpx auto 0;
        }
      }
      &.general {
        .c-price {
          background: linear-gradient(to right, #f45c43, #fc1b35);
        }
        .btn {
          color: #fc1b35;
        }
        .text-box {
          border-right: 2rpx dashed #f45c43;
          .c-des {
            .c-style {
              background: #fc1b35;
            }
          }
        }
      }
      &.unavailable {
        .c-price {
          background: #ccc;
        }
        .text-box {
          border-right: 2rpx dashed #ccc;
          .c-des {
            .c-style {
              background: #ccc;
            }
          }
        }
      }

      .text-box {
        flex: 1;
        padding: 20rpx 30rpx 20rpx 20rpx;
        background: #fff;
        box-shadow: 0 0 6rpx rgba(0,0,0,.05);
        border-right: 2rpx dashed #5695d6;
        border-radius: 10rpx 0 0 10rpx;
        .c-des {
          position: relative;
          z-index: 1;
          height: 36rpx;
          line-height: 36rpx;
          overflow: hidden;
          text-overflow: ellipsis;
          display: -webkit-box;
          -webkit-line-clamp: 1;
          -webkit-box-orient: vertical;
          .c-style {
            display: inline-block;
            vertical-align: top;
            margin-top: 4rpx;
            background: #6779da;
            color: #fff;
            height: 28rpx;
            line-height: 28rpx;
            padding: 0 10rpx;
            font-size: 18rpx;
            border-radius: 28rpx;
          }
          .text {
            margin-left: 10rpx;
            font-weight: 600;
          }
        }
        .c-time {
          margin-top: 16rpx;
          font-size: 20rpx;
          display: -webkit-box;
          -webkit-box-orient: vertical;
          -webkit-line-clamp: 1;
          overflow: hidden;
          text-overflow: ellipsis;
        }
        .c-det {
          display: flex;
          align-items: center;
          margin-top: 18rpx;
          justify-content: space-between;
          .text {
            font-size: 20rpx;
            color: #999;
          }
          .arrow {
            background: #ddd;
            width: 22rpx;
            height: 22rpx;
            border-radius: 50%;
            position: relative;
            &::after {
              position: absolute;
              top: 6rpx;
              left: 8rpx;
              display: block;
              content: " ";
              width: 6rpx;
              height: 6rpx;
              border: 2rpx solid #fff;
              border-width: 0 2rpx 2rpx 0;
              transform: rotate(45deg);
            }
            &.up-arrow {
              &::after {
                top: 8rpx;
                border-width: 2rpx 0 0 2rpx;
              }
            }
          }
        }
      }
      .un-icon {
        position: absolute;
        right: 270rpx;
        bottom: 18rpx;
        width: 80rpx;
        height: 80rpx;
        font-size: 0;
      }
      .c-det-box {
        position: relative;
        z-index: 8;
        box-shadow: 0 10rpx 12rpx -4rpx #f2f3f7 inset;
        background: #fff;
        padding: 0 30rpx;
        border-radius: 0 0 10rpx 10rpx;
        transition: all 0.2s linear;
        height: 0;
        box-sizing: border-box;
        &.active{
          display: block;
          height: auto;
          padding: 20rpx 30rpx 14rpx;
          .det-item {
            display: block;
          }
        }
        .det-item {
          color: #999;
          line-height: 36rpx;
          font-size: 20rpx;
          display: none;
          word-break: break-word;
          word-wrap: break-word;
        }
      }
    }
  }
  /* 底部 */
  .coupon-foot {
    z-index: 9;
    position: fixed;
    padding-bottom: env(safe-area-inset-bottom);
    bottom: 0;
    left: 0;
    right: 0;
    max-width: 750rpx;
    margin: auto;
    width: 750rpx;
    background: #fff;
    border-radius: 10rpx 10rpx 0 0;
    box-shadow: 0 -6rpx 6rpx rgba(0,0,0,.01);
    box-sizing: border-box;
    display: flex;
    align-items: center;
    .coupon-btn {
      position: relative;
      width: 50%;
      box-sizing: border-box;
      text-align: center;
      font-weight: bold;
      padding: 36rpx 0;
      font-size: 28rpx;
      color: #aaa;
      &:first-child {
        &::after {
          position: absolute;
          right: 0;
          top: 50%;
          transform: translateY(-50%);
          display: block;
          content: '';
          width: 2rpx;
          height: 20rpx;
          background: #ccc;
        }
      }
      &:last-child {
        color: #fc1b35;
      }
    }
    .btn {
      height: 70rpx;
      line-height: 70rpx;
      border-radius: 70rpx;
      background: #fc1b35;
      color: #fff;
      font-size: 26rpx;
      font-weight: 600;
      text-align: center;
    }
  }
}
