/* ===========================
   VIP Growth System 样式文件
   =========================== */

/* CSS变量定义 */
:root {
    --primary-gradient: linear-gradient(90deg, #53FECD 0%, #2C74C9 100%);
    --bg-dark: #0a0e27;
    --bg-card: rgba(20, 25, 45, 0.8);
    --border-color: rgba(60, 80, 150, 0.3);
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --text-muted: rgba(255, 255, 255, 0.5);
    --accent-cyan: #53FECD;
    --accent-blue: #2C74C9;
}

/* 全局容器 */
.vip-growth-container {
    max-width: 1200px;
    margin: 30px auto;
    padding: 0 20px;
}

/* ===========================
   顶部区域：用户信息 + 标题
   =========================== */
.vip-header-section {
    display: flex;
    gap: 24px;
    margin-bottom: 30px;
    align-items: flex-start;
}

/* 左侧用户信息边栏 */
.user-profile-sidebar {
    width: 260px;
    height: 286px;
    flex-shrink: 0;
    background: var(--bg-card);
    border-radius: 15px;
    padding: 26px 20px;
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* 右侧标题区域 */
.vip-title-area {
    width: 916px;
    height: 286px;
    flex-shrink: 0;
    background: var(--bg-card);
    border-radius: 15px;
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    box-sizing: border-box;
    padding: 30px 40px;
}

.vip-title-wrapper {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.user-avatar-section {
    text-align: center;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.user-avatar-img {
    width: 84px;
    height: 84px;
    border-radius: 50%;
    border: 4px solid var(--accent-cyan);
    box-shadow: 0 0 20px rgba(83, 254, 205, 0.4);
    margin-bottom: 15px;
    object-fit: cover;
}

.user-name {
    height: 39px;
    font-family: 'PingFang SC', 'PingFang SC', sans-serif;
    font-weight: 600;
    font-size: 28px;
    color: #FFFFFF;
    text-align: left;
    font-style: normal;
    text-transform: none;
    margin: 0 0 8px 0;
}

.user-email {
    height: 31px;
    font-family: 'PingFang SC', 'PingFang SC', sans-serif;
    font-weight: 600;
    font-size: 15px;
    color: #777777;
    text-align: left;
    font-style: normal;
    text-transform: none;
    margin: 0;
    word-break: break-all;
}

.btn-share-level {
    width: 222px;
    height: 48px;
    background: var(--primary-gradient);
    border: none;
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(83, 254, 205, 0.3);
}

.btn-share-level:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(83, 254, 205, 0.5);
}

.btn-share-level i {
    margin-right: 8px;
}

/* ===========================
   游客状态样式
   =========================== */

/* 游客头像区域 */
.guest-avatar-section {
    text-align: center;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.guest-icon {
    font-size: 84px;
    color: rgba(255, 255, 255, 0.3);
    margin-bottom: 15px;
}

.guest-icon i {
    display: block;
}

.guest-name {
    height: 39px;
    font-family: 'PingFang SC', 'PingFang SC', sans-serif;
    font-weight: 600;
    font-size: 28px;
    color: #FFFFFF;
    text-align: center;
    margin: 0 0 8px 0;
}

.guest-hint {
    font-family: 'PingFang SC', 'PingFang SC', sans-serif;
    font-weight: 600;
    font-size: 14px;
    color: #777777;
    text-align: center;
    margin: 0;
}

/* 游客操作按钮容器 */
.guest-action-buttons {
    display: flex;
    flex-direction: row;
    gap: 8px;
    width: 100%;
}

/* 游客按钮样式 */
.btn-guest-login,
.btn-guest-signup {
    flex: 1;
    height: 38px;
    background: var(--primary-gradient);
    border: none;
    border-radius: 6px;
    color: var(--text-primary);
    font-size: 13px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(83, 254, 205, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.btn-guest-login:hover,
.btn-guest-signup:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(83, 254, 205, 0.5);
}

.btn-guest-login i,
.btn-guest-signup i {
    font-size: 14px;
}

/* ===========================
   主内容区（全宽显示）
   =========================== */
.vip-main-content {
    width: 100%;
}

.vip-title {
    font-size: 36px;
    font-weight: bold;
    color: var(--text-primary);
    margin: 0 0 20px 0;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ===========================
   统计卡片网格（2行x3列）
   =========================== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    flex: 1;
}

.stat-card {
    height: 74px;
    background: linear-gradient(90deg, #53FECD 0%, #2C74C9 100%);
    border-radius: 4px;
    padding: 12px 18px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    box-sizing: border-box;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(83, 254, 205, 0.5);
}

.stat-icon {
    width: 50px;
    height: 50px;
    flex-shrink: 0;
    object-fit: contain;
}

.stat-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
}

.stat-value {
    font-size: 32px;
    font-weight: bold;
    color: var(--text-primary);
    line-height: 1;
}

.stat-label {
    font-size: 12px;
    color: var(--text-primary);
    line-height: 1.3;
}

/* ===========================
   VIP徽章展示区
   =========================== */
.vip-badges-section {
    margin-bottom: 40px;
    -webkit-overflow-scrolling: touch;
}

.vip-badges-row {
    display: flex;
    gap: 18px;
    min-width: min-content;
}

.vip-badge-card {
    width: 185px;
    height: 280px;
    background: var(--bg-card);
    border: 2px solid var(--border-color);
    border-radius: 10px;
    padding: 32px;
    text-align: center;
    backdrop-filter: blur(5px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-sizing: border-box;
    position: relative;
    overflow: hidden;
}

.vip-badge-card:hover {
    transform: translateY(-3px);
    border-color: var(--accent-cyan);
    box-shadow: 0 6px 20px rgba(83, 254, 205, 0.3);
}

.vip-badge-card.active {
    background: linear-gradient(158deg, #155191 0%, #0A142F 100%);
    border-radius: 8px;
    border: 1px solid #FFFFFF;
    box-shadow: 0 0 15px rgba(83, 254, 205, 0.5);
}

.badge-now-tag {
    position: absolute;
    top: 15px;
    right: -35px;
    width: 150px;
    height: 35px;
    background: linear-gradient(90deg, #53FECD 0%, #2C74C9 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'PingFang SC', 'PingFang SC', sans-serif;
    font-weight: 400;
    font-size: 18px;
    color: #FFFFFF;
    text-align: center;
    transform: rotate(45deg);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.badge-icon {
    width: 120px;
    height: 120px;
    object-fit: contain;
    margin-bottom: 12px;
}

.badge-level {
    height: 47px;
    font-family: 'Oswald', 'Oswald', sans-serif;
    font-weight: 600;
    font-size: 32px;
    color: #FFFFFF;
    text-align: left;
    font-style: normal;
    text-transform: none;
    margin: 0 0 5px 0;
}

.badge-exp {
    font-size: 12px;
    color: var(--text-secondary);
    margin: 0;
}

/* ===========================
   VIP权益表格
   =========================== */
.vip-table-section {
    margin-bottom: 40px;
}

.section-title {
    font-size: 24px;
    font-weight: bold;
    color: var(--text-primary);
    margin: 0 0 20px 0;
}

.vip-privileges-table {
    width: 100%;
    min-width: 1200px;
    border-collapse: collapse;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.vip-privileges-table thead {
    background: var(--primary-gradient);
}

.vip-privileges-table thead th {
    padding: 15px;
    text-align: center;
    color: var(--text-primary);
    font-size: 14px;
    font-weight: bold;
    height: 50px;
}

.vip-privileges-table tbody tr {
    background: var(--bg-card);
    border-bottom: 1px solid var(--border-color);
    transition: background 0.3s ease;
}

.vip-privileges-table tbody tr:nth-child(even) {
    background: rgba(255, 255, 255, 0.05);
}

.vip-privileges-table tbody tr:hover {
    background: rgba(83, 254, 205, 0.1);
}

.vip-privileges-table tbody td {
    padding: 15px;
    text-align: center;
    color: var(--text-primary);
    font-size: 14px;
    height: 60px;
    vertical-align: middle;
}

.table-badge-icon {
    width: 60px;
    height: 60px;
    object-fit: contain;
    vertical-align: middle;
}

.table-coin-icon {
    width: 50px;
    height: 50px;
    object-fit: contain;
    vertical-align: middle;
    margin-right: 5px;
}

/* ===========================
   底部信息区
   =========================== */
.vip-info-section {
    /* 无背景，使用页面背景 */
}

.info-block {
    margin-bottom: 30px;
}

.info-block:last-child {
    margin-bottom: 0;
}

.info-block h3 {
    height: auto;
    min-height: 39px;
    font-family: 'Oswald', 'Oswald', sans-serif;
    font-weight: 600;
    font-size: 26px;
    color: #FFFFFF;
    text-align: left;
    font-style: normal;
    text-transform: none;
    margin: 0 0 12px 0;
}

.info-block p {
    height: auto;
    min-height: auto;
    font-family: 'PingFang TC', 'PingFang TC', sans-serif;
    font-weight: 600;
    font-size: 18px;
    color: #777777;
    text-align: left;
    font-style: normal;
    text-transform: none;
    line-height: 1.6;
    margin: 0 0 8px 0;
}

.info-block p:last-child {
    margin-bottom: 0;
}

.info-block ol {
    margin: 10px 0;
    padding-left: 20px;
    font-family: 'PingFang TC', 'PingFang TC', sans-serif;
    font-weight: 600;
    font-size: 18px;
    color: #777777;
    line-height: 1.6;
}

.info-block ol li {
    margin-bottom: 8px;
}

.info-block strong {
    color: #FFFFFF;
    font-weight: 600;
}

/* ===========================
   响应式设计
   =========================== */

/* 平板端 (768px - 1199px) */
@media (max-width: 1199px) and (min-width: 768px) {

    /* 容器自适应 */
    .vip-growth-container {
        max-width: 100%;
        padding: 0 15px;
    }

    /* 顶部区域自适应 */
    .vip-header-section {
        gap: 20px;
    }

    /* 用户边栏：减小宽度 */
    .user-profile-sidebar {
        width: 220px;
        height: auto;
        min-height: 280px;
        padding: 20px 15px;
    }

    /* VIP标题区域：自适应宽度 */
    .vip-title-area {
        width: auto;
        flex: 1;
        height: auto;
        min-height: 280px;
        padding: 25px 30px;
    }

    /* 按钮全宽 */
    .btn-share-level {
        width: 100%;
        max-width: 200px;
    }

    /* 统计卡片：2列布局，优化间距 */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .stat-card {
        height: 70px;
        padding: 10px 15px;
    }

    .stat-icon {
        width: 45px;
        height: 45px;
    }

    .stat-value {
        font-size: 28px;
    }

    .stat-label {
        font-size: 11px;
    }

    /* VIP Title */
    .vip-title {
        font-size: 32px;
        margin-bottom: 16px;
    }

    /* VIP徽章：启用横向滚动 */
    .vip-badges-section {
        overflow-x: auto;
        margin-bottom: 30px;
    }

    .vip-badge-card {
        width: 160px;
        height: 240px;
        padding: 25px;
    }

    .badge-icon {
        width: 100px;
        height: 100px;
    }

    .badge-level {
        font-size: 28px;
    }
}

/* 移动端 (< 768px) */
@media (max-width: 767px) {

    /* 容器 */
    .vip-growth-container {
        margin: 20px auto;
        padding: 0 12px;
    }

    /* 顶部区域：垂直布局 */
    .vip-header-section {
        flex-direction: column;
        gap: 15px;
        margin-bottom: 20px;
    }

    /* 用户边栏：全宽，高度自适应 */
    .user-profile-sidebar {
        width: 100%;
        height: auto;
        padding: 20px 15px;
    }

    /* VIP标题区域：全宽，高度自适应 */
    .vip-title-area {
        width: 100%;
        height: auto;
        padding: 20px 15px;
    }

    /* 用户头像区域 */
    .user-avatar-img {
        width: 80px;
        height: 80px;
    }

    .user-name {
        font-size: 22px;
        height: auto;
    }

    .user-email {
        font-size: 14px;
        height: auto;
    }

    /* 按钮全宽 */
    .btn-share-level {
        width: 100%;
        height: 44px;
        font-size: 13px;
    }

    /* 游客按钮移动端优化 */
    .btn-guest-login,
    .btn-guest-signup {
        height: 40px;
        font-size: 12px;
    }

    /* VIP标题 */
    .vip-title {
        font-size: 26px;
        margin-bottom: 15px;
    }

    /* 统计卡片：单列，高度自适应 */
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .stat-card {
        height: auto;
        min-height: 70px;
        padding: 12px 15px;
    }

    .stat-icon {
        width: 45px;
        height: 45px;
    }

    .stat-value {
        font-size: 26px;
    }

    .stat-label {
        font-size: 11px;
    }

    /* VIP徽章：启用横向滚动 */
    .vip-badges-section {
        overflow-x: auto;
        margin-bottom: 25px;
        padding-bottom: 5px;
    }

    .vip-badges-row {
        padding-right: 12px;
    }

    .vip-badge-card {
        width: 140px;
        height: 200px;
        padding: 15px;
    }

    .badge-icon {
        width: 80px;
        height: 80px;
        margin-bottom: 8px;
    }

    .badge-level {
        font-size: 20px;
        height: auto;
    }

    .badge-exp {
        font-size: 11px;
    }

    .badge-now-tag {
        height: 30px;
        font-size: 16px;
    }

    /* 表格区域 */
    .section-title {
        font-size: 20px;
        margin-bottom: 15px;
    }

    .vip-table-section {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin-bottom: 25px;
    }

    .vip-privileges-table {
        min-width: 600px;
    }

    .vip-privileges-table thead th {
        padding: 12px 10px;
        font-size: 13px;
        height: auto;
    }

    .vip-privileges-table tbody td {
        padding: 12px 10px;
        font-size: 13px;
        height: auto;
    }

    .table-badge-icon {
        width: 50px;
        height: 50px;
    }

    .table-coin-icon {
        width: 40px;
        height: 40px;
    }

    /* 信息区域 */
    .vip-info-section {
        padding: 0;
    }

    .info-block {
        margin-bottom: 25px;
    }

    .info-block h3 {
        font-size: 18px;
        height: auto;
        margin-bottom: 10px;
    }

    .info-block p {
        font-size: 14px;
        height: auto;
        line-height: 1.6;
        margin-bottom: 6px;
    }

    .info-block ol {
        font-size: 14px;
        padding-left: 20px;
    }

    .info-block ol li {
        margin-bottom: 8px;
    }
}

/* 滚动条美化 */
.vip-badges-section::-webkit-scrollbar,
.vip-table-section::-webkit-scrollbar {
    height: 8px;
}

.vip-badges-section::-webkit-scrollbar-track,
.vip-table-section::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

.vip-badges-section::-webkit-scrollbar-thumb,
.vip-table-section::-webkit-scrollbar-thumb {
    background: var(--primary-gradient);
    border-radius: 4px;
}

.vip-badges-section::-webkit-scrollbar-thumb:hover,
.vip-table-section::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(90deg, #2C74C9 0%, #53FECD 100%);
}

/* ===========================
   EXP History 弹窗样式
   =========================== */

/* 弹窗遮罩层 */
.history-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }

    to {
        opacity: 0;
    }
}

/* 关闭按钮 */
.modal-close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 28px;
    color: #999;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    width: 30px;
    height: 30px;
    transition: color 0.3s;
}

.modal-close-btn:hover {
    color: #333;
}

/* 弹窗标题 */
.modal-title {
    font-size: 20px;
    font-weight: bold;
    color: #333;
    margin: 0 0 20px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--accent-blue);
}

.modal-title i {
    margin-right: 8px;
    color: var(--accent-blue);
}

/* EXP历史弹窗 */
.exp-history-modal {
    background: white;
    border-radius: 8px;
    padding: 18px;
    max-width: 450px;
    width: 90%;
    max-height: 50vh;
    display: flex;
    flex-direction: column;
    position: relative;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* 时间轴容器 */
.exp-timeline-container {
    flex: 1;
    overflow-y: auto;
    margin-bottom: 12px;
    padding: 8px 8px 8px 0;
    position: relative;
}

/* 时间轴垂直线条 */
.exp-timeline-container::before {
    content: '';
    position: absolute;
    left: 12px;
    top: 15px;
    height: var(--timeline-height, 100%);
    width: 2px;
    background: linear-gradient(to bottom, #e0e0e0 0%, #f0f0f0 100%);
}

/* 时间轴项 */
.timeline-item {
    display: flex;
    gap: 12px;
    margin-bottom: 18px;
    position: relative;
    padding-left: 3px;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

/* 时间轴图标容器 */
.timeline-icon {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    flex-shrink: 0;
    font-size: 11px;
    position: relative;
    z-index: 1;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.15);
}

/* 时间轴内容 */
.timeline-content {
    flex: 1;
}

.timeline-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.timeline-source {
    font-weight: 600;
    color: #333;
    font-size: 13px;
}

.timeline-time {
    font-size: 11px;
    color: #999;
    white-space: nowrap;
}

.timeline-description {
    font-size: 12px;
    color: #666;
    margin-bottom: 6px;
    line-height: 1.4;
}

.timeline-exp {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.exp-change {
    font-weight: 600;
    font-size: 14px;
}

.exp-change.positive {
    color: #5FB878;
}

.exp-change.negative {
    color: #FF5722;
}

.exp-balance {
    font-size: 11px;
    color: #999;
    background: #f5f5f5;
    padding: 2px 8px;
    border-radius: 10px;
}

/* 加载更多 */
.load-more-container {
    text-align: center;
    padding-top: 10px;
}

.btn-load-more {
    background: var(--primary-gradient);
    color: white;
    border: none;
    padding: 10px 25px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(83, 254, 205, 0.3);
}

.btn-load-more:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(83, 254, 205, 0.4);
}

/* 加载和无数据状态 */
.timeline-loading,
.no-records {
    text-align: center;
    padding: 40px 20px;
    color: #999;
}

.timeline-loading i {
    font-size: 24px;
    margin-bottom: 10px;
}

.no-records {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.no-records i {
    font-size: 48px;
    color: #ddd;
    margin-bottom: 15px;
}

.no-records p {
    font-size: 14px;
    color: #999;
}

/* 响应式设计 - EXP弹窗 */
@media (max-width: 768px) {
    .exp-history-modal {
        width: 95%;
        max-height: 55vh;
        padding: 15px;
    }

    .modal-title {
        font-size: 17px;
        margin-bottom: 15px;
    }

    .timeline-source {
        font-size: 12px;
    }

    .timeline-time {
        font-size: 10px;
    }
}