/* 基础样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
}

body {
    background-color: #f5f5f5;
    padding-bottom: 60px; /* 移动端底部导航预留空间 */
}

/* 头部样式 */
.header {
    background-color: #4CAF50;
    padding: 15px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.logo {
    height: 36px;
    width: auto;
}

.site-name {
    color: white;
    font-size: 18px;
    font-weight: bold;
}

/* 桌面端导航 */
.desktop-nav {
    display: none;
    gap: 20px;
}

.desktop-nav a {
    color: white;
    text-decoration: none;
    padding: 5px 10px;
    border-radius: 4px;
    transition: all 0.3s;
}

.desktop-nav a:hover {
    background-color: rgba(255,255,255,0.2);
}

.desktop-nav a.active {
    background-color: rgba(255,255,255,0.2) !important;
    font-weight: bold;
}

/* 路径导航 */
.breadcrumbs {
    padding: 12px 20px;
    background-color: white;
    font-size: 14px;
    color: #666;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.breadcrumbs a {
    color: #4CAF50;
    text-decoration: none;
}

.breadcrumbs span {
    margin: 0 5px;
    color: #ccc;
}

/* 内容区域 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 15px;
}

.section-title {
    font-size: 18px;
    color: #333;
    margin: 20px 0 10px;
    padding-bottom: 5px;
    border-bottom: 1px solid #eee;
}

/* 用户信息卡片 */
.user-card {
    background-color: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 15px;
}

.avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background-color: #4CAF50;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: bold;
}

.user-details {
    flex: 1;
}

.username {
    font-size: 20px;
    font-weight: bold;
    color: #333;
    margin-bottom: 5px;
}

.vip-tag {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 12px;
    margin-right: 5px;
}

.vip-tag.vip {
    background-color: #ffc107;
    color: #333;
}

.vip-tag.svip {
    background-color: #9c27b0;
    color: white;
}

.user-stats {
    display: flex;
    gap: 15px;
    margin-top: 15px;
}

.stat-item {
    flex: 1;
    text-align: center;
    padding: 10px;
    background-color: #f9f9f9;
    border-radius: 6px;
}

.stat-value {
    font-size: 18px;
    font-weight: bold;
    color: #4CAF50;
}

.stat-label {
    font-size: 12px;
    color: #666;
    margin-top: 3px;
}

/* 退出登录按钮 */
.logout-btn {
    display: block;
    width: 100%;
    max-width: 120px;
    margin: 15px auto 0;
    padding: 8px 15px;
    background-color: #ff4d4f;
    color: white;
    border: none;
    border-radius: 4px;
    text-align: center;
    text-decoration: none;
    font-size: 14px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.logout-btn:hover {
    background-color: #f5222d;
}

/* 充值区域 */
.recharge-section {
    background-color: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.package-group-title {
    font-size: 16px;
    font-weight: bold;
    margin: 15px 0 10px;
    color: #333;
}

/* 套餐选项 */
.recharge-packages {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
    margin: 15px 0;
}

.package-option {
    position: relative;
    border: 2px solid #eee;
    border-radius: 6px;
    padding: 12px 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
}

.package-option:hover {
    border-color: #4CAF50;
}

.package-option.selected {
    border-color: #4CAF50;
    background-color: #f5faf5;
}

.package-option input[type="radio"] {
    position: absolute;
    opacity: 0;
}

.package-content {
    display: flex;
    flex-direction: column;
}

.package-amount {
    font-size: 18px;
    font-weight: bold;
    color: #333;
}

.package-xxb {
    font-size: 12px;
    color: #666;
    margin-top: 4px;
}






/* 自定义充值选项 */
.custom-amount-group {
    margin: 15px 0;
    display: flex;
    flex-direction: column;
    gap: 10px; /* 统一选项间距 */
}

.custom-amount-option {
    position: relative;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 15px;
    cursor: pointer;
    transition: all 0.3s ease; /* 平滑过渡效果 */
    min-height: 60px; /* 确保选项高度一致 */
    box-sizing: border-box; /* 包含边框计算 */
}

.custom-amount-option:hover {
    border-color: #4CAF50;
    box-shadow: 0 2px 5px rgba(76, 175, 80, 0.1); /* 增加hover阴影 */
}

.custom-amount-option.selected {
    border-color: #4CAF50;
    background-color: #f5faf5;
}

/* 添加选中状态指示器 */
.custom-amount-option.selected::after {
    content: "✓";
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #4CAF50;
    font-size: 18px;
    font-weight: bold;
}

.custom-amount-option input[type="radio"] {
    position: absolute;
    opacity: 0;
}

.custom-input-container {
    display: flex;
    align-items: center;
    margin-top: 8px;
    width: 100%; /* 确保占满容器 */
}

.currency-symbol {
    font-size: 18px;
    color: #333;
    margin-right: 5px;
    min-width: 18px; /* 固定符号宽度 */
}

.custom-amount-option input[type="number"] {
    flex: 1;
    padding: 10px;
    border: 1px solid #d9d9d9;
    border-radius: 4px;
    font-size: 16px;
    outline: none;
    transition: border-color 0.3s;
    box-sizing: border-box; /* 包含边框计算 */
}

.custom-amount-option input[type="number"]:focus {
    border-color: #4CAF50;
    box-shadow: 0 0 0 2px rgba(76, 175, 80, 0.2); /* 焦点高亮效果 */
}

.input-suffix {
    font-size: 16px;
    color: #666;
    margin-left: 5px;
    white-space: nowrap; /* 防止后缀换行 */
}

.custom-tip {
    font-size: 12px;
    color: #999;
    margin-top: 8px;
    line-height: 1.5; /* 改善文字可读性 */
}

/* 支付方式 */
.pay-methods {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
    margin: 15px 0;
    padding: 5px 0; /* 增加上下内边距 */
}

.pay-method {
    position: relative;
    border: 2px solid #eee;
    border-radius: 6px;
    padding: 15px 10px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    min-height: 80px; /* 确保支付方式高度一致 */
    display: flex;
    flex-direction: column;
    justify-content: center; /* 内容垂直居中 */
    box-sizing: border-box;
}

.pay-method:hover {
    border-color: #4CAF50;
    box-shadow: 0 2px 8px rgba(76, 175, 80, 0.15);
}

.pay-method.selected {
    border-color: #4CAF50;
    background-color: #f5faf5;
}

/* 支付方式选中指示器 */
.pay-method.selected::after {
    content: "✓";
    position: absolute;
    right: 8px;
    top: 8px;
    color: #4CAF50;
    font-size: 16px;
    font-weight: bold;
    background: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.pay-method input[type="radio"] {
    position: absolute;
    opacity: 0;
}

.method-name {
    font-size: 14px;
    color: #333;
    word-break: keep-all; /* 防止名称断裂 */
}

/* 响应式调整 */
@media (max-width: 480px) {
    .pay-methods {
        grid-template-columns: repeat(2, 1fr); /* 移动端每行显示2个 */
    }
    
    .custom-amount-option {
        padding: 12px;
    }
    
    .custom-amount-option input[type="number"] {
        padding: 8px;
        font-size: 15px;
    }
}





















/* 充值按钮 */
.recharge-btn {
    width: 100%;
    padding: 12px;
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.2s;
}

.recharge-btn:hover {
    background-color: #45a049;
}

.error-message {
    color: #f44336;
    margin: 10px 0;
    text-align: center;
    padding: 10px;
    background-color: #fff0f0;
    border-radius: 4px;
}

.success-message {
    color: #4CAF50;
    margin: 10px 0;
    text-align: center;
    padding: 10px;
    background-color: #f0fff0;
    border-radius: 4px;
}

/* 下载历史 */
.download-history {
    background-color: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.download-item {
    padding: 15px 0;
    border-bottom: 1px solid #eee;
}

.download-item:last-child {
    border-bottom: none;
}

.download-info {
    display: flex;
    gap: 10px;
    align-items: center;
}

.download-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.download-icon.pdf {
    color: #f44336;
}

.download-icon.word {
    color: #2196F3;
}

.download-details {
    flex: 1;
}

.download-title {
    font-size: 16px;
    color: #333;
    margin-bottom: 5px;
}

.download-meta {
    font-size: 12px;
    color: #666;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.download-action {
    margin-left: 10px;
}

.download-btn {
    padding: 8px 15px;
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.download-btn:hover {
    background-color: #45a049;
}

.no-downloads {
    text-align: center;
    padding: 30px 0;
    color: #888;
}

/* 充值记录 */
.pay-records {
    background-color: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.record-item {
    padding: 15px 0;
    border-bottom: 1px solid #eee;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
}

.record-item:last-child {
    border-bottom: none;
}

.record-info {
    flex: 1;
    min-width: 200px;
}

.record-number {
    font-size: 14px;
    color: #666;
    margin-bottom: 5px;
}

.record-project {
    font-size: 16px;
    font-weight: bold;
    color: #333;
}

.record-time {
    font-size: 12px;
    color: #999;
    margin-top: 5px;
}

.record-method {
    font-size: 12px;
    color: #999;
}

.record-status {
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: bold;
}

.status-pending {
    background-color: #fff3e0;
    color: #ff9800;
}

.status-paid {
    background-color: #e8f5e9;
    color: #4caf50;
}

.no-records {
    text-align: center;
    padding: 30px 0;
    color: #888;
}

/* 充值确认弹窗 */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    display: none;
}

.modal.active {
    display: flex;
}

.modal-content {
    background-color: white;
    border-radius: 8px;
    padding: 20px;
    max-width: 400px;
    width: 90%;
    position: relative;
}

.modal-close {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 20px;
    color: #666;
    cursor: pointer;
}

.modal-title {
    font-size: 18px;
    font-weight: bold;
    color: #333;
    margin-bottom: 15px;
    text-align: center;
}

.modal-body {
    margin-bottom: 20px;
}

.modal-item {
    margin: 10px 0;
    display: flex;
    justify-content: space-between;
}

.modal-label {
    color: #666;
}

.modal-value {
    font-weight: bold;
}

.pay-image {
    margin: 15px 0;
    text-align: center;
}

.pay-image img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    border: 1px solid #eee;
}

.modal-actions {
    display: flex;
    gap: 10px;
}

.modal-btn {
    flex: 1;
    padding: 10px;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
}

.modal-btn-cancel {
    background-color: #f0f0f0;
    color: #333;
}

.modal-btn-confirm {
    background-color: #4CAF50;
    color: white;
}

/* 移动端底部导航 */
.mobile-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    background-color: white;
    border-top: 1px solid #eee;
    height: 60px;
    z-index: 1000;
}

.nav-item {
    flex: 1;
    text-align: center;
    padding: 10px 0;
    text-decoration: none;
    color: #666;
    font-size: 12px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.nav-item.active {
    color: #4CAF50 !important;
    font-weight: bold;
}

.nav-icon {
    font-size: 20px;
    margin-bottom: 3px;
}

/* 版权信息 */
.copyright {
    text-align: center;
    color: #888;
    font-size: 12px;
    padding: 20px 0;
    margin-top: 30px;
    border-top: 1px solid #eee;
}

/* 响应式适配 - 移动端 */
@media (max-width: 768px) {
    .user-stats {
        flex-wrap: wrap;
    }
    
    .stat-item {
        flex: 1 1 calc(50% - 10px);
    }
    
    .recharge-packages {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .pay-methods {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .logout-btn {
        max-width: 100%;
        margin-top: 10px;
    }
}

/* 响应式适配 - 桌面端 */
@media (min-width: 768px) {
    body {
        padding-bottom: 0;
    }
    
    .desktop-nav {
        display: flex;
    }
    
    .mobile-nav {
        display: none;
    }
    
    .user-card {
        display: flex;
        gap: 30px;
        align-items: center;
    }
    
    .user-info {
        margin-bottom: 0;
    }
    
    .user-stats {
        margin-top: 0;
        gap: 20px;
    }
    
    .stat-item {
        min-width: 120px;
    }
    
    .recharge-packages {
        grid-template-columns: repeat(5, 1fr);
    }
    
    .pay-methods {
        grid-template-columns: repeat(4, 1fr);
    }
}