/* 基础样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 页面基础样式 */
body {
    background-color: #141428;
    color: #fff;
    padding: 50px 15px 60px 15px;
    width: 100%;
    max-width: 100vw;
    overflow-x: hidden;
    min-height: 100vh;
    -webkit-overflow-scrolling: touch;
}

/* 顶部导航 */
.vip-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 50px;
    background: #1a1a2e;
    display: flex;
    align-items: center;
    padding: 0 15px;
    z-index: 100;
}

.back-btn {
    background: none;
    border: none;
    color: #fff;
    font-size: 20px;
    padding: 8px;
    cursor: pointer;
}

.vip-header h1 {
    color: #fff;
    font-size: 18px;
    margin: 0 auto;
}

/* 内容容器 */
.vip-container, .coins-container {
   
    max-width: 480px;
    margin: 0 auto;
}

/* 会员权益卡片 */
.vip-benefits-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
}

.vip-benefits-card h2 {
    color: #fff;
    font-size: 18px;
    margin-bottom: 20px;
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.benefit-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
}

.benefit-item i {
    color: #ffd700;
    font-size: 24px;
}

.benefit-item span {
    color: #fff;
    font-size: 14px;
}

/* 限时特惠卡片样式 */
.discount-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 20px;
    
}

/* 滑动卡片容器 */
.card-slider {
    position: relative;
    margin: 20px 0;
    overflow: hidden;
}

.slider-container {
    display: flex;
    transition: transform 0.3s ease;
    margin-bottom: 20px;
}

.slider-item {
    min-width: 100%;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    position: relative;
}

/* 会员徽章 */
.vip-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
    position: relative;
    padding-right: 80px;
}

.vip-badge i {
    color: #ffd700;
    font-size: 24px;
}

.vip-badge span {
    color: #fff;
    font-size: 20px;
    font-weight: 600;
}

/* 价格部分 */
.price-section {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin-bottom: 25px;
}

.current-price {
    color: #ff4757;
    font-size: 32px;
    font-weight: bold;
}

.original-price {
    color: rgba(255, 255, 255, 0.4);
    font-size: 16px;
    text-decoration: line-through;
}

.discount-tag {
    color: #ff4757;
    font-size: 14px;
    background: rgba(255, 71, 87, 0.1);
    padding: 2px 8px;
    border-radius: 10px;
}

/* 会员特权列表 */
.vip-features {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.feature-item i {
    color: #4cd964;
    font-size: 16px;
}

.feature-item span {
    color: rgba(255, 255, 255, 0.8);
    font-size: 14px;
}

/* 滑动指示器 */
.slider-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 15px;
}

.dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transition: all 0.3s;
    cursor: pointer;
}

.dot.active {
    width: 18px;
    border-radius: 3px;
    background: #ffd700;
}

/* 支付按钮 */
.pay-button {
    width: 100%;
    background: linear-gradient(45deg, #ff4757, #ff6b81);
    border: none;
    border-radius: 12px;
    padding: 12px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: transform 0.2s;
}

.pay-button:active {
    transform: scale(0.98);
}

.button-price {
    color: #fff;
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 4px;
}

.button-desc {
    color: rgba(255, 255, 255, 0.8);
    font-size: 12px;
}

/* 支付弹窗样式 */
.pay-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.pay-modal.active {
    display: flex;
}

.modal-content {
    background: #1a1a2e;
    border-radius: 16px;
    width: 85%;
    max-width: 320px;
    overflow: hidden;
}

.modal-header {
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-header h3 {
    color: #fff;
    font-size: 16px;
}

.close-btn {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 18px;
    cursor: pointer;
}

.modal-body {
    padding: 20px;
    text-align: center;
}

.qr-code {
    width: 200px;
    height: 200px;
    margin: 0 auto 20px;
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
}

.qr-code img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pay-info {
    margin-bottom: 20px;
}

.pay-type {
    color: #fff;
    font-size: 16px;
    margin-bottom: 5px;
}

.pay-price {
    color: #ff4757;
    font-size: 24px;
    font-weight: bold;
}

.pay-tips {
    color: rgba(255, 255, 255, 0.6);
    font-size: 13px;
    line-height: 1.6;
}

/* 适配刘海屏 */
@supports (padding-top: env(safe-area-inset-top)) {
    body {
        padding-top: calc(50px + env(safe-area-inset-top));
    }
    
    .vip-header {
        padding-top: env(safe-area-inset-top);
        height: calc(50px + env(safe-area-inset-top));
    }
    
    .tab-container {
        top: calc(50px + env(safe-area-inset-top));
    }
    
    .tab-content {
        padding-top: calc(60px + env(safe-area-inset-top));
    }
}

/* Tab 切换样式 */
.tab-container {
    position: fixed;
    top: 50px;
    left: 0;
    right: 0;
    background: #1a1a2e;
    z-index: 99;
}

.tab-bar {
    display: flex;
    padding: 10px 20px;
    gap: 20px;
    max-width: 480px;
    margin: 0 auto;
}

.tab-item {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 8px;
    color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all 0.3s;
}

.tab-item.active {
    color: #ffd700;
    border-bottom-color: #ffd700;
}

.tab-item i {
    font-size: 16px;
}

/* Tab 内容区域 */
.tab-content {
    display: none;
   
}

.tab-content.active {
    display: block;
}

/* 金币页面样式 */
.balance-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
}

.balance-amount {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 15px 0;
}

.balance-amount i {
    color: #ffd700;
    font-size: 24px;
}

.balance-amount span {
    color: #fff;
    font-size: 32px;
    font-weight: bold;
}

.balance-details {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 15px;
}

.details-btn {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
    padding: 0;
    cursor: pointer;
}

.recharge-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
}

.recharge-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.recharge-item {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 15px;
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
}

.recharge-item:hover {
    border-color: #1890ff;
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.recharge-item.selected {
    border-color: #1890ff;
    background: rgba(24,144,255,0.05);
}

.recharge-item.recommended {
    border-color: #52c41a;
}

.coin-amount {
    font-size: 18px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.bonus-tag {
    background: #f5222d;
    color: white;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
}

.recommend-tag {
    position: absolute;
    top: -10px;
    right: 10px;
    background: #52c41a;
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
}

.price {
    color: #f5222d;
    font-size: 20px;
    font-weight: bold;
}

.recharge-btn {
    width: 100%;
    height: 44px;
    background: linear-gradient(45deg, #ffd700, #ffaa00);
    border: none;
    border-radius: 22px;
    color: #fff;
    font-size: 16px;
    cursor: pointer;
}

/* 消费明细弹窗样式 */
.history-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.history-modal.active {
    display: flex;
}

.transaction-list {
    max-height: 400px;
    overflow-y: auto;
}

.transaction-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.transaction-title {
    color: #fff;
    font-size: 15px;
    margin-bottom: 5px;
}

.transaction-time {
    color: rgba(255, 255, 255, 0.4);
    font-size: 12px;
}

.transaction-amount {
    font-size: 16px;
    font-weight: bold;
}

.transaction-amount.increase {
    color: #4cd964;
}

.transaction-amount.decrease {
    color: #ff4757;
}

/* 高级会员卡样式 */
.slider-item.premium {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.1), rgba(218, 165, 32, 0.1));
    border: 1px solid rgba(255, 215, 0, 0.3);
}

.slider-item.supreme {
    background: linear-gradient(135deg, rgba(147, 112, 219, 0.1), rgba(138, 43, 226, 0.1));
    border: 1px solid rgba(147, 112, 219, 0.3);
}

.premium-tag, .supreme-tag {
    position: absolute;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: bold;
    white-space: nowrap;
    z-index: 1;
}

.premium-tag {
    background: linear-gradient(45deg, #ffd700, #daa520);
    color: #000;
    box-shadow: 0 2px 8px rgba(255, 215, 0, 0.3);
}

.supreme-tag {
    background: linear-gradient(45deg, #9370db, #8a2be2);
    color: #fff;
    box-shadow: 0 2px 8px rgba(147, 112, 219, 0.3);
}

/* 不同会员卡图标样式 */
.slider-item.premium .vip-badge i {
    color: #ffd700;
    font-size: 28px;
}

.slider-item.supreme .vip-badge i {
    color: #9370db;
    font-size: 26px;
}

/* 支付弹窗样式 */
.payment-info {
    margin-bottom: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
}

.payment-methods {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.payment-method {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
}

.payment-method:hover {
    border-color: #1890ff;
}

.method-icon {
    font-size: 24px;
}

.pay-btn {
    width: 100%;
    padding: 12px;
    background: #1890ff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
}

.pay-btn:hover {
    background: #40a9ff;
}

/* 余额更新动画 */
.balance-amount span {
    transition: all 0.3s ease;
}

.balance-amount span.balance-updated {
    animation: balanceUpdate 0.5s ease;
}

@keyframes balanceUpdate {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.2);
        color: #4cd964;
    }
    100% {
        transform: scale(1);
    }
}

/* 支付成功提示 */
.payment-success-toast {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(76, 217, 100, 0.9);
    color: white;
    padding: 12px 24px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 10000;
    animation: toastIn 0.3s ease;
}

@keyframes toastIn {
    from {
        opacity: 0;
        transform: translate(-50%, -20px);
    }
    to {
        opacity: 1;
        transform: translate(-50%, 0);
    }
} 