/* 重置行业图表样式，简化并解决冲突问题 */
.dy-industry-chart-container {
    background: #fff;
    border-radius: 10px;
    padding: 15px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
    margin: 15px auto;
    max-width: 100%;
    width: 100%;
    height: auto;
    min-height: 200px;
    overflow: hidden;
}

.dy-industry-chart-container h5 {
    font-size: 14px;
    margin: 0 0 15px 0;
    text-align: center;
    font-weight: 600;
    color: #333;
    padding-bottom: 5px;
    border-bottom: 1px solid #f0f0f0;
}

.dy-chart-wrapper {
    margin: 0 auto;
    position: relative;
    width: 100%;
    height: auto;
}

.dy-chart-caption {
    text-align: center;
    font-size: 12px;
    color: #666;
    margin-top: 15px;
    padding-top: 5px;
    border-top: 1px solid #f0f0f0;
}

/* ---------- 电商行业图表样式 ---------- */
.dy-performance-comparison {
    width: 100%;
    padding: 0 5px;
}

.dy-performance-item {
    margin-bottom: 12px;
    display: flex;
    align-items: center;
}

.dy-performance-label {
    width: 70px;
    font-size: 12px;
    color: #555;
    padding-right: 10px;
    flex-shrink: 0;
}

.dy-performance-bar {
    height: 24px;
    background: #4a90e2;
    border-radius: 4px;
    color: white;
    font-size: 12px;
    font-weight: 600;
    line-height: 24px;
    padding: 0 8px;
    text-align: right;
}

.dy-performance-bar.highlight {
    background: #ff4d89;
}

/* ---------- 美妆行业图表样式 ---------- */
.dy-donut-chart {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    position: relative;
    margin: 0 auto;
    background: #f5f5f5;
}

.dy-donut-segment {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    clip-path: polygon(50% 50%, 100% 0, 100% 50%);
    transform-origin: center;
}

.dy-donut-segment:nth-child(1) {
    background: #FE2C55;
    clip-path: polygon(50% 50%, 100% 0, 100% 100%, 0 100%, 0 0);
    clip-path: none;
    background: conic-gradient(#FE2C55 0% 40%, #25F4EE 40% 65%, #8134AF 65% 85%, #FF9A5A 85% 100%);
}

.dy-segment-label {
    display: none;
}

.dy-donut-center {
    position: absolute;
    width: 90px;
    height: 90px;
    background: white;
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.dy-donut-center span {
    font-size: 12px;
    color: #666;
}

.dy-donut-center strong {
    font-size: 14px;
    color: #333;
    margin-top: 3px;
}

/* 添加图例 */
.donut-legend {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-top: 15px;
}

.legend-item {
    display: flex;
    align-items: center;
    font-size: 12px;
    color: #333;
}

.legend-color {
    width: 10px;
    height: 10px;
    border-radius: 2px;
    margin-right: 5px;
}

.legend-item:nth-child(1) .legend-color { background: #FE2C55; }
.legend-item:nth-child(2) .legend-color { background: #25F4EE; }
.legend-item:nth-child(3) .legend-color { background: #8134AF; }
.legend-item:nth-child(4) .legend-color { background: #FF9A5A; }

/* ---------- 文旅行业图表样式 ---------- */
.dy-line-chart {
    height: 150px;
    width: 100%;
    position: relative;
    padding: 10px;
    margin-top: 20px;
}

.dy-chart-grid {
    height: 100%;
    position: relative;
    border-left: 1px solid #eee;
    border-bottom: 1px solid #eee;
}

.dy-grid-line {
    position: absolute;
    left: 0;
    right: 0;
    border-top: 1px dashed #eee;
}

.dy-grid-line:nth-child(1) { top: 0; }
.dy-grid-line:nth-child(2) { top: 33%; }
.dy-grid-line:nth-child(3) { top: 66%; }
.dy-grid-line:nth-child(4) { top: 100%; }

.dy-chart-axis-x {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
}

.dy-chart-axis-x span {
    font-size: 12px;
    color: #666;
    flex: 1;
    text-align: center;
}

.dy-chart-lines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 0 10px;
}

/* 添加图例 */
.line-legend {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 10px;
}

.line-legend-item {
    display: flex;
    align-items: center;
    font-size: 12px;
    color: #333;
}

.line-legend-color {
    width: 20px;
    height: 2px;
    margin-right: 5px;
}

.line-legend-item:nth-child(1) .line-legend-color { background: #FE2C55; }
.line-legend-item:nth-child(2) .line-legend-color { background: #25F4EE; }

/* 简化线条显示 */
.dy-chart-line:nth-child(1)::after {
    content: "";
    position: absolute;
    top: 20%;
    left: 0;
    width: 100%;
    height: 2px;
    background: #FE2C55;
    z-index: 2;
}

.dy-chart-line:nth-child(2)::after {
    content: "";
    position: absolute;
    top: 30%;
    left: 0;
    width: 100%;
    height: 2px;
    background: #25F4EE;
    z-index: 2;
}

/* ---------- 餐饮食品行业图表样式 ---------- */
.dy-stacked-bar-chart {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    height: 180px;
    gap: 40px;
    margin-top: 20px;
}

.dy-stacked-bar {
    width: 60px;
    display: flex;
    flex-direction: column-reverse;
    align-items: center;
    position: relative;
}

.dy-stack-segment {
    width: 100%;
    border-radius: 4px 4px 0 0;
    position: relative;
    margin-bottom: 1px;
}

/* 传统媒体柱子 */
.dy-stacked-bar:first-child .dy-stack-segment:nth-child(1) {
    background: #FF6B6B;
    height: 30%;
}

.dy-stacked-bar:first-child .dy-stack-segment:nth-child(2) {
    background: #4ECDC4;
    height: 25%;
}

.dy-stacked-bar:first-child .dy-stack-segment:nth-child(3) {
    background: #FFD166;
    height: 15%;
}

/* 抖音平台柱子 */
.dy-stacked-bar:last-child .dy-stack-segment:nth-child(1) {
    background: #FE2C55;
    height: 40%;
}

.dy-stacked-bar:last-child .dy-stack-segment:nth-child(2) {
    background: #25F4EE;
    height: 35%;
}

.dy-stacked-bar:last-child .dy-stack-segment:nth-child(3) {
    background: #8134AF;
    height: 20%;
}

.dy-stack-segment span {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    font-size: 12px;
    color: white;
    white-space: nowrap;
}

.dy-stack-label {
    position: absolute;
    bottom: -25px;
    font-size: 12px;
    text-align: center;
    color: #333;
    font-weight: 500;
    width: 100%;
}

/* 添加图例 */
.stack-legend {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-top: 30px;
}

.stack-legend-item {
    display: flex;
    align-items: center;
    font-size: 12px;
    color: #333;
}

.stack-legend-color {
    width: 10px;
    height: 10px;
    border-radius: 2px;
    margin-right: 5px;
}

/* 传统媒体图例颜色 */
.stack-legend-item:nth-child(1) .stack-legend-color { background: #FF6B6B; }
.stack-legend-item:nth-child(2) .stack-legend-color { background: #4ECDC4; }
.stack-legend-item:nth-child(3) .stack-legend-color { background: #FFD166; }

/* 抖音平台图例颜色 */
.stack-legend-item:nth-child(4) .stack-legend-color { background: #FE2C55; }
.stack-legend-item:nth-child(5) .stack-legend-color { background: #25F4EE; }
.stack-legend-item:nth-child(6) .stack-legend-color { background: #8134AF; } 