/* 用户中心通用样式 - 简约紧凑风格 */

/* 基础页面样式 */
.compact-page {
    font-size: 15px;
    line-height: 1.5;
    background: #f8f9fa;
    min-height: 100vh;
    padding: 20px 0;
}

/* 面包屑导航 */
.breadcrumb {
    background: none;
    padding: 8px 0;
    margin-bottom: 16px;
    font-size: 14px;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: ">";
    color: #6c757d;
}

.breadcrumb-item a {
    color: #1890ff;
    text-decoration: none;
}

.breadcrumb-item a:hover {
    color: #40a9ff;
    text-decoration: underline;
}

.breadcrumb-item.active {
    color: #6c757d;
}

/* 页面标题 */
.page-title {
    font-size: 22px;
    font-weight: 600;
    margin-bottom: 6px;
    color: #262626;
}

.page-subtitle {
    font-size: 14px;
    color: #6c757d;
    margin-bottom: 16px;
}

/* 紧凑卡片样式 */
.compact-card {
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    background: #ffffff;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
    margin-bottom: 12px;
}

.compact-card .card-header {
    background: #fafafa;
    border-bottom: 1px solid #e8e8e8;
    padding: 10px 14px;
    font-size: 14px;
    font-weight: 600;
    color: #262626;
    border-radius: 6px 6px 0 0;
}

.compact-card .card-body {
    padding: 14px;
}

/* 紧凑统计区域 */
.compact-stats {
    padding: 10px 14px;
    background: #f8f9fa;
    border-radius: 4px;
    margin-bottom: 8px;
    border: 1px solid #f0f0f0;
}

/* 紧凑徽章 */
.compact-badge {
    font-size: 12px;
    padding: 3px 7px;
    border-radius: 3px;
    margin-right: 4px;
    display: inline-block;
    font-weight: 500;
}

/* 紧凑表格 */
.compact-table {
    background: #ffffff !important;
    border: 1px solid #e8e8e8;
    border-radius: 4px;
    overflow: hidden;
}

.compact-table-row {
    padding: 10px 14px;
    border-bottom: 1px solid #f0f0f0;
    background: #ffffff;
    transition: background-color 0.2s ease;
}

.compact-table-row:hover {
    background: #f5f5f5;
}

.compact-table-row:last-child {
    border-bottom: none;
}

/* 文本统计样式 */
.text-stat {
    font-size: 17px;
    font-weight: 600;
}

.text-stat-sm {
    font-size: 15px;
    font-weight: 500;
}

.text-stat-xs {
    font-size: 13px;
    font-weight: 500;
}

/* 风险指示器 */
.risk-indicator {
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 500;
    display: inline-block;
}

/* 紧凑按钮 */
.btn-compact {
    padding: 4px 12px;
    font-size: 13px;
    border-radius: 3px;
    line-height: 1.4;
}

/* 紧凑警告框 */
.alert-compact {
    padding: 10px 14px;
    margin-bottom: 8px;
    font-size: 14px;
    border-radius: 4px;
}

/* 加载状态 */
.loading-compact {
    padding: 20px 0;
    text-align: center;
}

.loading-compact .spinner-border {
    width: 1.5rem;
    height: 1.5rem;
}

.loading-compact small {
    color: #6c757d;
    font-size: 13px;
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 30px 20px;
    color: #6c757d;
}

.empty-state i {
    font-size: 2rem;
    margin-bottom: 12px;
    color: #d9d9d9;
}

.empty-state h6 {
    font-size: 15px;
    font-weight: 500;
    margin-bottom: 6px;
    color: #262626;
}

.empty-state small {
    font-size: 13px;
    color: #8c8c8c;
}

/* 数据网格 */
.data-grid {
    display: grid;
    gap: 8px;
    margin-bottom: 12px;
}

.data-grid-2 {
    grid-template-columns: 1fr 1fr;
}

.data-grid-3 {
    grid-template-columns: 1fr 1fr 1fr;
}

.data-grid-4 {
    grid-template-columns: 1fr 1fr 1fr 1fr;
}

.data-grid-5 {
    grid-template-columns: 1fr 1fr 1fr 1fr 1fr;
}

/* APY概览专用样式 - 确保在所有屏幕尺寸下都横向显示 */
#apyOverview .data-grid-5 {
    grid-template-columns: 1fr 1fr 1fr 1fr 1fr !important;
    display: grid !important;
}

/* 数据项 */
.data-item {
    padding: 10px;
    background: #f8f9fa;
    border-radius: 3px;
    text-align: center;
}

.data-item-label {
    font-size: 12px;
    color: #8c8c8c;
    margin-bottom: 4px;
}

.data-item-value {
    font-size: 14px;
    font-weight: 500;
    color: #262626;
}

/* 标签组 */
.tag-group {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-bottom: 8px;
}

/* 操作栏 */
.action-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
    margin-bottom: 16px;
}

.action-bar .title-section {
    flex: 1;
}

.action-bar .button-section {
    flex-shrink: 0;
}

/* 状态标识 */
.status-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-right: 6px;
}

.status-dot.success {
    background-color: #52c41a;
}

.status-dot.warning {
    background-color: #faad14;
}

.status-dot.danger {
    background-color: #ff4d4f;
}

.status-dot.info {
    background-color: #1890ff;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .compact-page {
        padding: 10px;
        font-size: 13px;
    }

    .page-title {
        font-size: 18px;
    }

    .data-grid-2,
    .data-grid-3,
    .data-grid-4 {
        grid-template-columns: 1fr;
    }

    /* APY概览保持5列横向显示，但调整间距和字体 */
    #apyOverview .data-grid-5 {
        grid-template-columns: repeat(5, 1fr) !important;
        gap: 4px !important;
    }

    #apyOverview .data-item {
        padding: 6px 4px !important;
    }

    #apyOverview .data-item-label {
        font-size: 10px !important;
    }

    #apyOverview .data-item-value {
        font-size: 16px !important;
    }

    .action-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }

    .compact-stats {
        padding: 6px 8px;
    }

    .compact-table-row {
        padding: 6px 8px;
    }
}

@media (max-width: 576px) {
    .compact-page {
        padding: 8px;
        font-size: 12px;
    }

    .page-title {
        font-size: 16px;
    }

    .compact-card .card-header {
        padding: 6px 8px;
        font-size: 12px;
    }

    .compact-card .card-body {
        padding: 8px;
    }

    /* 超小屏幕APY概览优化 */
    #apyOverview .data-grid-5 {
        grid-template-columns: repeat(5, 1fr) !important;
        gap: 2px !important;
    }

    #apyOverview .data-item {
        padding: 4px 2px !important;
    }

    #apyOverview .data-item-label {
        font-size: 9px !important;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    #apyOverview .data-item-value {
        font-size: 14px !important;
    }
}