<template>
  <view class="withdraw-record-container">
    <!-- 顶部导航栏 -->
    <view class="nav-bar">
      <view class="back" @tap="goBack">
        <uni-icons type="left" size="20"></uni-icons>
      </view>
      <text class="title">提现记录</text>
    </view>
    <view class="main-content">
      <view class="record-list-card">
        <view class="record-item" v-for="(item, idx) in records" :key="idx">
          <view class="record-info">
            <text class="record-title">提现记录</text>
            <text class="record-date">{{ item.date }}</text>
          </view>
          <text class="record-amount">¥{{ item.amount }}</text>
        </view>
      </view>
    </view>
  </view>
</template>

<script>
export default {
  data() {
    return {
      records: [
        { date: '04-27', amount: 10 },
        { date: '04-23', amount: 60 },
        { date: '04-17', amount: 10 },
        { date: '04-12', amount: 110 },
        { date: '04-12', amount: 180 },
        { date: '04-09', amount: 30 },
        { date: '04-09', amount: 130 },
        { date: '04-07', amount: 160 },
        { date: '03-29', amount: 170 }
      ]
    }
  },
  methods: {
    goBack() {
      uni.navigateBack();
    }
  }
}
</script>

<style lang="scss" scoped>
.withdraw-record-container {
  min-height: 100vh;
  background: #f7f7f7;
}
.nav-bar {
  display: flex;
  align-items: center;
  height: calc(150rpx + var(--status-bar-height));
  padding: 0 32rpx;
  padding-top: var(--status-bar-height);
  background: #fff;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 999;
  box-sizing: border-box;
  box-shadow: 0 2rpx 8rpx rgba(0,0,0,0.03);
  .back {
    padding: 20rpx;
    margin-left: -20rpx;
  }
  .title {
    flex: 1;
    text-align: center;
    font-size: 34rpx;
    font-weight: 500;
    color: #222;
  }
}
.main-content {
  margin-top: calc(150rpx + var(--status-bar-height));
  margin-bottom: 40rpx;
}
.record-list-card {
  background: #fff;
  border-radius: 40rpx;
  margin: 0 32rpx 32rpx 32rpx;
  padding: 0 0 0 0;
  box-shadow: 0 2rpx 8rpx rgba(0,0,0,0.03);
}
.record-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 38rpx 36rpx 38rpx 36rpx;
  border-bottom: 2rpx solid #f3f3f3;
  &:last-child {
    border-bottom: none;
  }
}
.record-info {
  display: flex;
  flex-direction: column;
}
.record-title {
  font-size: 30rpx;
  color: #222;
  font-weight: 500;
  margin-bottom: 8rpx;
}
.record-date {
  font-size: 26rpx;
  color: #b3b3b3;
  font-weight: 400;
}
.record-amount {
  font-size: 32rpx;
  color: #222;
  font-weight: 500;
}
</style>
 