/* 管理后台「用户分组」+「报表中心」样式（引用 admin.css 的 :root 设计变量） */

/* ============ 用户分组 ============ */
.group-name-cell {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
}

.group-name-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 10px;
    border-radius: 999px;
    background: rgba(79, 70, 229, 0.08);
    color: var(--admin-primary, #4f46e5);
    font-size: 12px;
    font-weight: 500;
    max-width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.group-name-badge.ungrouped {
    background: rgba(100, 116, 139, 0.1);
    color: var(--admin-text-muted, #64748b);
}

.group-member-count {
    color: var(--admin-text-muted, #64748b);
    font-size: 12px;
    font-weight: 400;
}

.group-remark-text {
    color: var(--admin-text-muted, #64748b);
    font-size: 12px;
    max-width: 260px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    display: inline-block;
}

/* ============ 报表中心 ============ */
.report-summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
    margin-bottom: 18px;
}

.report-summary-card {
    background: var(--admin-card-bg, #ffffff);
    border: 1px solid var(--admin-border, #e2e8f0);
    border-radius: 10px;
    padding: 16px 18px;
}

.report-summary-card .label {
    color: var(--admin-text-muted, #64748b);
    font-size: 13px;
    margin-bottom: 6px;
}

.report-summary-card .value {
    font-size: 22px;
    font-weight: 600;
    color: var(--admin-text, #1e293b);
}

.report-chart-container {
    width: 100%;
    height: 380px;
    background: var(--admin-card-bg, #ffffff);
    border: 1px solid var(--admin-border, #e2e8f0);
    border-radius: 10px;
    padding: 12px;
    margin-bottom: 18px;
}

.report-month-filter {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.report-month-filter input[type="month"],
.report-month-filter .report-month-input {
    padding: 6px 10px;
    border: 1px solid var(--admin-border, #e2e8f0);
    border-radius: 8px;
    font-size: 13px;
    color: var(--admin-text, #1e293b);
    min-width: 110px;
    background: var(--admin-card-bg, #ffffff);
    cursor: pointer;
}

/* flatpickr 月份弹层需盖过弹窗遮罩 */
.flatpickr-calendar.monthSelect {
    z-index: 60;
}

.report-drilldown-hint {
    color: var(--admin-text-muted, #64748b);
    font-size: 12px;
}

/* 汇总表中分组行可点击下钻 */
.report-summary-table tbody tr.clickable {
    cursor: pointer;
}

.report-summary-table tbody tr.clickable:hover {
    background: rgba(79, 70, 229, 0.04);
}

.report-group-cell {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* 分组名列：整行可点击下钻，组名以链接样式（蓝字 + 下划线）提示可交互 */
.report-group-link {
    color: var(--admin-primary, #4f46e5);
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-color: rgba(79, 70, 229, 0.45);
    transition: color 0.15s ease, text-decoration-color 0.15s ease;
}

.report-group-link:hover {
    color: var(--admin-primary-hover, #4338ca);
    text-decoration-color: currentColor;
}

/* 未分组行同样保留链接提示（灰色系，与"未分组"徽章一致） */
tr.clickable:hover .report-group-link {
    text-decoration-color: currentColor;
}

.report-group-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.report-group-dot.ungrouped {
    background: #cbd5e1;
}

.report-detail-total {
    font-weight: 600;
    color: var(--admin-text, #1e293b);
}

.report-error {
    padding: 14px 18px;
    border-radius: 8px;
    background: rgba(239, 68, 68, 0.06);
    border: 1px solid rgba(239, 68, 68, 0.25);
    color: var(--admin-danger, #ef4444);
    font-size: 13px;
}
