.buy_tc_parent {
    position: fixed; /* 使div固定位置 */
    top: 0; /* 距离顶部0 */
    left: 0; /* 距离左边0 */
    width: 100%; /* 宽度100% */
    height: 100%; /* 高度100% */
    z-index: 8888; /* 较大的z-index确保它在最上方 */
    background-color: rgba(0, 0, 0, 0.1); /* 半透明背景 */
    text-align: center;
}


.buy_tc{width: 400px;background: white; padding-bottom: 30px;box-shadow: 0 10px 30px rgb(0 0 0 / 15%)}
.buy_tc .title{font-size: 20px;margin: 10px 0;}
.buy_tc .bg-center{font-size: 16px;}
.buy_tc-content, .buy_tc-fl{font-size: 14px;}
.buy_tc-card-item{width: 60px; height: 60px;}
.buy_tc-card-item img{width: 25px;height: 25px;}
.buy_tc-card-item>div{font-size: 10px;}
.buy_tc-btn{margin: 15px 0 20px;}
.buy_tc-btn .buy_tc-btn-item{width: 81px;height: 27px;}


.buy_tc{
    width: 400px;
    height: auto;
    position: fixed;
    left: 50%;
    top: 50%;
    transform: translate(-50%,-50%);
    border-radius: 10px;
    z-index: 9;
}
.buy_tc .close{
    display: flex;
    justify-content: flex-end;
    margin-top: 20px;
    margin-right: 20px;
    cursor: pointer;
    z-index: 10000;
    position: relative;
    pointer-events: auto;
}
.buy_tc .title{
    text-align: center;
    font-size: 32px;
    margin:10px 0 18px 0;
}
.buy_tc .title span:first-child{
    color: #130F68;
}
.buy_tc .title span:last-child{
    color: #0065bd;
    font-weight: bold;
}
.buy_tc-content{
    font-size: 16px;
    text-align: center;
    color: #130F68;
    margin-bottom: 10px;
}
.buy_tc-fl{
    font-size: 16px;
    color: #FE8033;
    text-align: center;
    font-weight: bold;
    margin-bottom: 12px;
}
.buy_tc-card{
    display: flex;
    justify-content: center;
    gap: 10px;
    align-items: center;
}
.buy_tc-card-item{
    width: 90px;
    height: 90px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 0 2px 0 rgba(0,84,153,0.1);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
.buy_tc-card-item img{
    width: 40px;
    height: 40px;
    margin: 10px 0;
}
.buy_tc-card-item>div{
    color: #130F68;
    font-size: 14px;
    margin-bottom: 10px;
}
.buy_tc-btn{
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin: 30px 0 35px;
}
.buy_tc-btn .buy_tc-btn-item{
    width: 120px;
    height: 40px;
    cursor: pointer;
}

.buy_tc .title{font-size: 20px;margin: 10px 0;}
.buy_tc .bg-center{font-size: 16px;}
.buy_tc-content, .buy_tc-fl{font-size: 14px;}
.buy_tc-card-item{width: 60px; height: 60px;}
.buy_tc-card-item img{width: 25px;height: 25px;}
.buy_tc-card-item>div{font-size: 10px;}
.buy_tc-btn{margin: 15px 0 20px;}
.buy_tc-btn .buy_tc-btn-item{width: 81px;height: 27px;}

.buy_tc_container {
    width: 100%;
    max-width: 500px;
    background: white;
    border-radius: 16px;
    overflow: hidden;
}

.close-btn {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 1.2rem;
    cursor: pointer;
    background: none;
    border: none;
    color: white;
}

.payment-options {
    padding: 20px;
}

.option {
    display: flex;
    align-items: center;
    padding-left: 15px;
    border: 2px solid #e6e9f0;
    border-radius: 12px;
    margin-bottom: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.option.alipay:hover {
    border-color: #0088cc;
    background-color: #f0f8ff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 136, 204, 0.2);
}
}

.option:hover {
    border-color: #4a6bdf;
    transform: translateY(-2px);
}

.option.selected {
    border-color: #4a6bdf;
    background-color: #f0f4ff;
}

.option input[type="radio"] {
    margin-right: 15px;
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    font-size: 1.5rem;
    color: white;
}

.balance .icon {
    /*background: #ff7d4d;*/
}

.alipay .icon {
    /*background: #1677ff;*/
}

.wechat .icon {
    /*background: #07c160;*/
}

.label {
    flex: 1;
}

.label h3 {
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 4px;
}

.label p {
    color: #718096;
    font-size: 0.9rem;
}

.footer {
    padding: 20px;
    border-top: 1px solid #e6e9f0;
    text-align: center;
}

.confirm-btn {
    background: #4a6bdf;
    color: white;
    border: none;
    padding: 14px 28px;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
    width: 100%;
}

.confirm-btn:hover {
    background: #3a5bce;
}

.confirm-btn:active {
    transform: translateY(1px);
}

/* 手机端弹窗优化 */
@media (max-width: 600px) {
    .buy_tc_parent {
        display: none !important;  /* 默认隐藏，只有通过JS设置为block才显示 */
        padding: 0 !important;
        background-color: rgba(0, 0, 0, 0.5) !important;
        text-align: center !important;
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 100% !important;
        height: 100% !important;
        z-index: 8888 !important;
    }
    
    /* 当通过JS设置为block时显示 */
    .buy_tc_parent[style*="display: block"],
    .buy_tc_parent[style*="display:block"] {
        display: block !important;
    }

    .buy_tc {
        width: calc(100% - 40px) !important;
        max-width: 400px !important;
        position: fixed !important;
        left: 50% !important;
        top: 50% !important;
        transform: translate(-50%, -50%) !important;
        margin: 0 !important;
        right: auto !important;
        bottom: auto !important;
        max-height: 90vh !important;
        overflow-y: auto !important;
        z-index: 9999 !important;
        background: white !important;
        border-radius: 10px !important;
        box-shadow: 0 10px 30px rgb(0 0 0 / 15%) !important;
        will-change: transform !important;  /* 优化渲染性能 */
        backface-visibility: hidden !important;  /* 防止渲染问题 */
    }

    .buy_tc_container {
        border-radius: 16px;
        box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    }

    .pay_header {
        padding: 20px;
        text-align: center;
    }

    .pay_header h2 {
        font-size: 20px;
        line-height: 1.4;
        margin: 0;
    }

    .close-btn {
        right: 15px;
        top: 15px;
        width: 32px;
        height: 32px;
        display: flex;
        align-items: center;
        justify-content: center;
        background: rgba(255, 255, 255, 0.2);
        border-radius: 50%;
        color: #333;
        font-size: 18px;
        z-index: 10000;
        position: relative;
        pointer-events: auto;
        cursor: pointer;
    }
    
    .buy_tc .close {
        z-index: 10000;
        position: relative;
        pointer-events: auto;
        cursor: pointer;
    }

    .payment-options {
        padding: 20px;
    }

    .option {
        padding: 16px;
        margin-bottom: 12px;
        border-radius: 12px;
        transition: all 0.3s ease;
        min-height: 70px;
    }

    .option:hover {
        transform: translateY(-1px);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    }

    .option.selected {
        border-color: #4a6bdf;
        background: linear-gradient(135deg, #f0f4ff 0%, #e6f0ff 100%);
        transform: translateY(-1px);
        box-shadow: 0 4px 12px rgba(74, 107, 223, 0.2);
    }

    .option input[type="radio"] {
        width: 18px;
        height: 18px;
        margin-right: 12px;
        accent-color: #4a6bdf;
    }

    .label h4 {
        font-size: 14px;
        font-weight: 600;
        margin: 0 0 2px 0;
        color: #2d3748;
    }

    .icon {
        width: 48px;
        height: 48px;
        border-radius: 10px;
        margin-right: 12px;
        font-size: 20px;
        flex-shrink: 0;
    }

    .confirm-btn {
        padding: 16px;
        font-size: 16px;
        font-weight: 600;
        border-radius: 12px;
        margin-top: 10px;
        transition: all 0.3s ease;
    }

    .confirm-btn:hover {
        transform: translateY(-1px);
        box-shadow: 0 6px 20px rgba(74, 107, 223, 0.3);
    }

    .confirm-btn:active {
        transform: translateY(0);
    }
}

@media (max-width: 480px) {
    .buy_tc_parent {
        padding: 0 !important;
        display: none !important;  /* 默认隐藏，只有通过JS设置为block才显示 */
        background-color: rgba(0, 0, 0, 0.5) !important;
        text-align: center !important;
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 100% !important;
        height: 100% !important;
        z-index: 8888 !important;
    }
    
    /* 当通过JS设置为block时显示 */
    .buy_tc_parent[style*="display: block"],
    .buy_tc_parent[style*="display:block"] {
        display: block !important;
    }

    .buy_tc {
        width: calc(100% - 30px) !important;
        max-width: 380px !important;
        position: fixed !important;
        left: 50% !important;
        top: 50% !important;
        transform: translate(-50%, -50%) !important;
        margin: 0 !important;
        right: auto !important;
        bottom: auto !important;
        max-height: 90vh !important;
        overflow-y: auto !important;
        z-index: 9999 !important;
        background: white !important;
        border-radius: 10px !important;
        box-shadow: 0 10px 30px rgb(0 0 0 / 15%) !important;
    }

    .pay_header {
        padding: 15px;
    }

    .pay_header h2 {
        font-size: 18px;
    }

    .payment-options {
        padding: 15px;
    }

    .option {
        padding: 14px;
        min-height: 65px;
    }

    .label h4 {
        font-size: 13px;
    }

    .confirm-btn {
        padding: 14px;
        font-size: 15px;
    }
}