/**
 * WAAP Seller 前台样式
 */

/* 商品展示 */
.wseller-products {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.wseller-products h2 {
    text-align: center;
    margin-bottom: 30px;
    font-size: 28px;
}

.upgrade-info {
    background: #f0f7fc;
    border-left: 4px solid #0073aa;
    padding: 15px 20px;
    margin: 20px 0;
    border-radius: 0 4px 4px 0;
}

/* 标签切换 */
.product-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    border-bottom: 2px solid #eee;
    justify-content: center;
}

.tab-btn {
    padding: 15px 40px;
    border: none;
    background: none;
    cursor: pointer;
    font-size: 16px;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all 0.3s;
}

.tab-btn:hover {
    color: #0073aa;
}

.tab-btn.active {
    border-bottom-color: #0073aa;
    color: #0073aa;
    font-weight: bold;
}

.tab-panel {
    display: none;
}

.tab-panel.active {
    display: block;
}

/* 定价卡片 */
.pricing-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.pricing-card {
    background: #fff;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.pricing-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.pricing-card h3 {
    font-size: 24px;
    margin-bottom: 10px;
    color: #333;
}

.pricing-card .description {
    color: #666;
    margin-bottom: 20px;
}

.pricing-options {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.price-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 2px solid transparent;
    transition: border-color 0.3s;
}

.price-option:hover {
    border-color: #0073aa;
}

.price-option.featured {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    position: relative;
}

.price-option.featured .badge {
    position: absolute;
    top: -10px;
    right: 10px;
    background: #e74c3c;
    color: #fff;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: bold;
}

.price-option .period {
    font-weight: bold;
}

.price-option .price {
    font-size: 20px;
}

.price-option .price del {
    color: #999;
    font-size: 14px;
    margin-right: 5px;
}

.price-option.featured .price del {
    color: rgba(255,255,255,0.6);
}

.price-option .button {
    padding: 8px 20px;
}

.discount-info {
    background: #fff8e5;
    border: 1px solid #ffba00;
    border-radius: 4px;
    padding: 10px 15px;
    margin-top: 15px;
    text-align: center;
    color: #856404;
}

/* 结算页面 */
.wseller-checkout {
    max-width: 800px;
    margin: 50px auto;
    padding: 0 20px;
}

.checkout-container {
    background: #fff;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.wseller-checkout h1 {
    margin-bottom: 30px;
    text-align: center;
    font-size: 28px;
}

.error-message {
    background: #f8d7da;
    color: #721c24;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.order-summary {
    margin-bottom: 30px;
}

.order-summary h2 {
    font-size: 20px;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #eee;
}

.order-table {
    width: 100%;
    border-collapse: collapse;
}

.order-table td {
    padding: 12px 0;
    border-bottom: 1px solid #eee;
}

.order-table td:first-child {
    color: #666;
    width: 120px;
    font-weight: 500;
}

.price-row {
    font-size: 20px;
}

.price-row del {
    color: #999;
    margin-right: 10px;
}

.discount-price {
    color: #e74c3c;
    font-size: 24px;
}

.discount-tag {
    background: #e74c3c;
    color: #fff;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    margin-left: 10px;
}

.checkout-form h2 {
    font-size: 20px;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #eee;
}

.payment-methods {
    margin-bottom: 30px;
}

.payment-method {
    display: flex;
    align-items: center;
    padding: 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    cursor: pointer;
    margin-bottom: 10px;
    transition: border-color 0.3s;
}

.payment-method:hover,
.payment-method.active {
    border-color: #0073aa;
    background: #f0f7fc;
}

.payment-method input {
    margin-right: 10px;
}

.checkout-actions {
    text-align: center;
}

.agreement {
    margin-bottom: 20px;
    color: #666;
}

.agreement input {
    margin-right: 5px;
}

.button-large {
    padding: 15px 40px;
    font-size: 18px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    color: #fff;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
}

.button-large:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

/* 用户中心 */
.wseller-user-center {
    max-width: 1200px;
    margin: 50px auto;
    padding: 0 20px;
}

.user-center-container {
    display: flex;
    gap: 30px;
}

.user-sidebar {
    width: 200px;
    flex-shrink: 0;
}

.user-nav {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.user-nav a {
    display: block;
    padding: 15px 20px;
    color: #333;
    text-decoration: none;
    border-bottom: 1px solid #eee;
    transition: all 0.3s;
}

.user-nav a:hover,
.user-nav a.active {
    background: #f0f7fc;
    color: #0073aa;
}

.user-content {
    flex: 1;
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.user-content h2 {
    margin-top: 0;
    margin-bottom: 20px;
    font-size: 24px;
}

.dashboard-stats {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    padding: 25px 40px;
    border-radius: 8px;
    text-align: center;
    flex: 1;
}

.stat-number {
    display: block;
    font-size: 36px;
    font-weight: bold;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 14px;
    opacity: 0.9;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.data-table th {
    background: #f8f9fa;
    font-weight: 600;
}

.data-table code {
    background: #f0f0f0;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 12px;
}

.data-table .button-small {
    padding: 5px 10px;
    font-size: 12px;
    margin-right: 5px;
}

/* 支付成功页面 */
.wseller-success {
    max-width: 600px;
    margin: 100px auto;
    padding: 0 20px;
    text-align: center;
}

.success-container {
    background: #fff;
    padding: 60px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.success-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #46b450 0%, #389e42 100%);
    color: #fff;
    border-radius: 50%;
    font-size: 40px;
    line-height: 80px;
    margin: 0 auto 30px;
}

.success-container h1 {
    margin-bottom: 20px;
    color: #333;
}

.success-container p {
    color: #666;
    margin-bottom: 10px;
}

/* 订单倒计时 */
.countdown-timer {
    font-family: 'Courier New', monospace;
    font-weight: bold;
    font-size: 16px;
    color: #d32f2f;
    background: #ffebee;
    padding: 4px 8px;
    border-radius: 4px;
    display: inline-block;
}

.countdown-warning {
    color: #ff6f00 !important;
    background: #fff3e0 !important;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.status-expired {
    color: #999;
    font-style: italic;
}

.success-actions {
    margin-top: 30px;
}

.success-actions .button {
    margin: 0 10px;
    padding: 12px 30px;
}

/* 优惠券样式 */
.coupon-section {
    margin-bottom: 30px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

.coupon-input-group {
    display: flex;
    gap: 10px;
}

.coupon-input {
    flex: 1;
    padding: 12px 15px;
    border: 2px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    text-transform: uppercase;
}

.coupon-input:focus {
    border-color: #0073aa;
    outline: none;
}

.coupon-input-group .button {
    padding: 12px 25px;
    background: #0073aa;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.coupon-input-group .button:hover {
    background: #005a87;
}

.coupon-error {
    color: #dc3232;
    margin-top: 10px;
    font-size: 14px;
}

.coupon-applied {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: #e8f5e9;
    border-radius: 4px;
    border-left: 4px solid #4caf50;
}

.coupon-code {
    font-weight: bold;
    font-size: 16px;
    color: #333;
}

.coupon-discount {
    background: #4caf50;
    color: #fff;
    padding: 4px 10px;
    border-radius: 4px;
    font-weight: bold;
}

.coupon-success {
    color: #4caf50;
    font-size: 14px;
}

/* 返利余额样式 */
.affiliate-section {
    margin-bottom: 30px;
    padding: 20px;
    background: #f0f7ff;
    border-radius: 8px;
    border-left: 4px solid #2196f3;
}

.affiliate-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.affiliate-checkbox input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.affiliate-label {
    font-weight: bold;
    color: #333;
}

.affiliate-balance {
    margin-left: auto;
    color: #2196f3;
    font-weight: bold;
    font-size: 16px;
}

.affiliate-deduction {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px dashed #ccc;
    color: #4caf50;
    font-weight: bold;
}

.discount-text {
    color: #e74c3c;
}

.final-price-row {
    font-size: 18px;
    border-top: 2px solid #eee;
    padding-top: 10px;
}

.final-price-row td {
    padding-top: 15px;
}

/* 用户中心推广页面样式 */
.affiliate-info {
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.affiliate-link-section {
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid #eee;
}

.affiliate-link-section h3 {
    margin-bottom: 15px;
    color: #333;
}

.affiliate-link-box {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.affiliate-link-box input {
    flex: 1;
    padding: 12px 15px;
    border: 2px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    background: #f9f9f9;
}

.affiliate-link-box .button {
    padding: 12px 25px;
    background: #4caf50;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    white-space: nowrap;
}

.affiliate-link-box .button:hover {
    background: #45a049;
}

.affiliate-tip {
    color: #666;
    font-size: 14px;
}

.affiliate-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.affiliate-stat {
    text-align: center;
    padding: 25px;
}

.affiliate-stat.highlight {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
}

.affiliate-stat.highlight .stat-label {
    color: rgba(255,255,255,0.8);
}

.affiliate-balance-info {
    background: #e8f5e9;
    padding: 20px;
    border-radius: 8px;
    border-left: 4px solid #4caf50;
}

.affiliate-balance-info p {
    margin: 0;
    color: #2e7d32;
}

/* 响应式 */
@media (max-width: 768px) {
    .user-center-container {
        flex-direction: column;
    }
    
    .user-sidebar {
        width: 100%;
    }
    
    .dashboard-stats {
        flex-direction: column;
    }
    
    .pricing-cards {
        grid-template-columns: 1fr;
    }
    
    .checkout-container {
        padding: 20px;
    }
    
    .product-tabs {
        flex-direction: column;
    }
    
    .tab-btn {
        width: 100%;
        text-align: center;
    }
}
