/**
 * app_main_tab_v3 图表通用样式
 * 包含所有图表容器的通用样式
 */

/* 图表容器通用样式 */
.chart-container {
    width: 100%;
    height: 400px;
    min-height: 300px;
    border: 1px solid #ddd;
    background-color: #fff;
    position: relative;
}

/* ===== ECharts 折叠开关 ===== */
.chart-toggle-btn {
    position: absolute;
    top: 2px;
    left: 2px;
    z-index: 10;
    cursor: pointer;
    user-select: none;
    font-size: 11px;
    color: rgba(100, 116, 139, 0.5);
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 3px;
    padding: 1px 5px;
    line-height: 1.4;
    transition: all 0.15s ease;
    white-space: nowrap;
}
.chart-toggle-btn:hover {
    color: rgba(100, 116, 139, 0.9);
    background: rgba(255, 255, 255, 0.85);
    border-color: rgba(148, 163, 184, 0.5);
}

/* 折叠提示文字 */
.toggle-hint {
    font-size: 10px;
    margin-left: 2px;
    opacity: 0.6;
}

/* 折叠占位条样式 — 收起后仅保留按钮所在最小高度 */
.chart-collapsed {
    height: 26px !important;
    min-height: 26px !important;
    padding: 0 !important;
    margin: 0 !important;
    border: none !important;
    border-bottom: 1px solid #e5e7eb !important;
    background: transparent !important;
    overflow: visible !important;
}

/* 默认宽度；九转 / 高低切等 Tab 内会在各自模板里用更具体的选择器 + CSS 变量覆盖 */
[data-chart] {
    width: 900px;
    min-height: 200px;
    flex-shrink: 0;
}

/* ── 手机适配(仅 ≤767px 生效，PC 端零回归)：图表宽度自适应 ── */
@media (max-width: 767px) {
    [data-chart] { width: 100%; min-width: 100%; flex-shrink: 1; }
}

[data-chart-container] {
    width: auto;
    flex-shrink: 0;
}

