/* 全局基础 */
* { box-sizing: border-box; }
html, body { height: 100%; }
body {
    margin: 0;
    font: 14px/1.6 "PingFang SC", "Segoe UI", Roboto, "Helvetica Neue", Arial, "Microsoft YaHei", sans-serif;
    background: #04051A;
    overflow: hidden;
}

/* 外层包裹，负责留空与居中 */
#screen-wrapper {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: transparent; /* 留空区域 */
}

/* 舞台固定设计尺寸，通过JS等比缩放 */
#stage {
    width: 3840px;
    height: 2160px;
    transform-origin: top left;
    position: relative;
}

/* 头部 */
.header {
    position: absolute;
    left: 0; right: 0; top: 0;
    height: 106px;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}
.header-title { height: 110px; object-fit: contain; }

.header-right {
    position: absolute; right: 49px; top: 109px;
    pointer-events: auto;
    font-weight: 600;
    font-size: 38px;
    color: #FFFFFF;
    line-height: 43px;
}

.clock { letter-spacing: 1px; }

/* 三栏布局 */
.layout {
    position: absolute; 
    inset: 170px 0 0 0;
    display: grid;
    grid-template-columns: 837px 1168px 846px 868px;
    gap: 40px;
}
.col { display: flex; flex-direction: column; gap: 36px; }

/* 面板 */
.panel {
    position: relative;
    background: #0C113C;
    padding-top: 31px;
    padding-left: 28px;
}

.panel-title {
    font-weight: bold;
    font-size: 32px;
    color: #13CCB1;
    line-height: 31px;
}

.panel-title-sub {
    font-size: 24px;
}

.panel-title-sub-line {
    width: 190px;
    height: 6px;
    background: #13CCB1;
    margin-top: 17px;
}

.panel-body { height: 100%; }

/* 占位图/图表占位 */
.charts-placeholder, .donut-placeholder, .chart { height: 100%; }
.chart {
    height: 360px;
    border-radius: 10px;
    background: repeating-linear-gradient(90deg, rgba(90,150,255,.15) 0, rgba(90,150,255,.15) 2px, transparent 2px, transparent 28px),
                linear-gradient(180deg, rgba(48,86,154,.35), rgba(14,31,67,.2));
}

.donut {
    padding-bottom: 40px;
}

.donut .panel-body { display: grid; place-items: center; padding: 20px; }
.donut-title {
    color: #FFFFFF !important;
    text-decoration: underline;
    text-decoration-color: #13CCB1;
    text-underline-offset: 8px;
    text-decoration-thickness: 2px;
}

.donut-chart-container {
    position: relative;
    width: 520px;
    height: 640px;
}

.donut-chart-svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.donut-segment {
    stroke-width: 2;
    stroke: #FFFFFF;
}

.donut-label-group {
    position: absolute;
    pointer-events: none;
}

.donut-label-box {
    background: rgba(0,0,0,0.55);
    border-radius: 6px;
}

.donut-label-text {
    font-size: 18px;
    color: #FFFFFF;
    font-weight: normal;
    display: block;
}

.donut-label-value {
    font-size: 24px;
    color: #FFFFFF;
    font-weight: bold;
    display: block;
    margin-top: 4px;
}

.donut-label-dot {
    position: absolute;
    width: 6px;
    height: 6px;
    background: #FFFFFF;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
}

/* 左侧卡片 */
.grid { display: grid; gap: 18px; }
.grid-3x2 { grid-template-columns: repeat(3, 1fr); }
.card {
    display: grid; place-items: center; text-align: center;
    border-radius: 12px; border: 1px solid rgba(120,180,255,.25);
    background: linear-gradient(180deg, rgba(28,72,160,.35), rgba(8,18,40,.25));
    color: #bfe7ff;
}
.card.circle { border-radius: 999px; aspect-ratio: 1 / 1; min-height: 220px; }
.card .num { font-size: 56px; font-weight: 700; line-height: 1; }
.card .label { margin-top: 6px; font-size: 28px; color: #a8dbff; }
.card.alt { background: linear-gradient(180deg, rgba(32,96,140,.35), rgba(8,18,40,.25)); }

/* 城市统计容器 */
.city-stats-container {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    position: relative;
    width: 100%;
    overflow: hidden;
    margin-top: 37px;
    padding-left: 25px;
    padding-right: 10px;
}

.city-stats-grid {
    flex: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 20px 45px;
    align-content: flex-start;
    align-items: flex-start;
    min-width: 0;
    margin-bottom: 34px;
    padding-left: 2px;
}

.city-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    flex-shrink: 0;
}

.city-cards {
    display: flex;
    gap: 30px;
    align-items: center;
    flex-wrap: nowrap;
}

.city-card {
    position: relative;
    width: 153px;
    height: 153px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background-size: 153px 153px;
    background-position: center;
    background-repeat: no-repeat;
}

.city-card.fleet {
    background-image: url('./images/icon2.png');
}

.city-card.driver {
    background-image: url('./images/icon1.png');
}

.city-card-icon {
    display: none;
}

.city-card .num {
    font-weight: bold;
    font-size: 45px;
    color: #66FF33;
}

.city-card .num2 {
    font-weight: bold;
    font-size: 45px;
    color: #66FFFF;
}

.city-card .label {
    font-weight: bold;
    font-size: 18px;
    color: #FFFFFF;
}

.city-name {
    font-weight: bold;
    font-size: 20px;
    color: #FFFFFF;
    text-align: center;
}

.city-stats-arrow {
    position: absolute;
    right: 0;
    top: 32%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: opacity 0.3s;
    flex-shrink: 0;
    margin-left: 10px;
}

.city-stats-arrow:hover {
    opacity: 0.8;
}

.city-stats-arrow img {
    width: 60px;
    height: 60px;
    object-fit: contain;
}

/* 中间区域 */
.col-center { 
    align-items: flex-start; 
    flex-direction: row;
    gap: 40px;
    position: relative;
}
.energy-list { 
    position: absolute;
    left: 55px;
    top: 39px;
    width: auto; 
    min-width: 280px;
    display: flex; 
    flex-direction: column; 
    gap: 35px; 
    align-items: flex-start;
    flex-shrink: 0;
    z-index: 10;
}
.energy-item { 
    display: flex; 
    gap: 25px; 
    align-items: center; 
    width: 100%;
}
.energy-item img { 
    width: 90px; 
    height: 90px; 
}
.energy-text {
    display: flex;
    flex-direction: column;
    gap: 0;
}
.energy-label {
    font-size: 32px;
    color: #FFFFFF;
    font-weight: bold;
}
.energy-count-wrapper {
    display: flex;
    align-items: baseline;
    gap: 0;
    line-height: 1;
}
.energy-count {
    font-size: 54px;
    color: #35D6DA;
    font-weight: bold;
}
.energy-unit {
    font-size: 24px;
    color: #FFFFFF;
    font-weight: normal;
}

.map-wrap { 
    position: absolute;
    left: -20px;
    top: 219px;
    width: 1168px;
    height: 1625px;

    font-weight: bold;
    font-size: 32px;
    color: #FFFFFF;
}
.map-wrap img { 
    width: 100%; 
    height: 100%;
}

.map-text1 {
    position: absolute;
    top: 25px;
    right: 50px;
}

.map-text2 {
    position: absolute;
    top: 202px;
    right: 229px;
}

.map-text3 {
    position: absolute;
    top: 390px;
    right: 324px;
}

.map-text4 {
    position: absolute;
    top: 477px;
    right: 107px;
}

.map-text5 {
    position: absolute;
    top: 580px;
    right: 309px;
}

.map-text6 {
    position: absolute;
    top: 642px;
    right: 655px;
}

.map-text7 {
    position: absolute;
    top: 725px;
    right: 116px;
}

.map-text8 {
    position: absolute;
    top: 955px;
    right: 676px;
}

.map-text9 {
    position: absolute;
    top: 935px;
    right: 190px;
}

.map-text10 {
    position: absolute;
    top: 1195px;
    right: 790px;
}

.map-text11 {
    position: absolute;
    top: 1235px;
    right: 220px;
}


/* 列表 */
.list .list-body { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; font-size: 24px; color: #d5eeff; }
.list .list-body li { padding: 10px 12px; background: rgba(16,42,88,.35); border: 1px solid rgba(86,160,255,.18); border-radius: 8px; }

/* 调度任务统计样式 */
.task-stats-container, .fuel-stats-container {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    position: relative;
    width: 100%;
    overflow: hidden;
    margin-top: 17px;
    padding-bottom: 20px;
}

.task-stats-chart {
    flex: 1;
    min-width: 0;
    padding-right: 110px;
}

.fuel-stats-chart {
    flex: 1;
    min-width: 0;
    padding-right: 110px;
    position: relative;
}

.task-chart-wrapper {
    display: flex;
    flex-direction: row;
    gap: 20px;
    height: 100%;
    align-items: center;
}

.fuel-chart-wrapper {
    display: flex;
    flex-direction: row;
    gap: 20px;
    height: 100%;
    align-items: center;
    width: 100%;
    position: relative;
}

.task-chart-legend, .fuel-chart-legend {
    display: flex;
    flex-direction: column;
    gap: 40px;
    flex-shrink: 0;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.legend-color {
    width: 20px;
    height: 20px;
    border-radius: 2px;
}

.legend-color.completed {
    background: #66FFFF;
}

.legend-color.in-progress {
    background: #F6C401;
}

.legend-color.pending {
    background: #23E7A9;
}

/* 里程能耗统计图例颜色 */
.legend-color.fuel-legend-mileage {
    background: #7EC8E3; /* 浅蓝色 - 匹配里程柱子 */
}

.legend-color.fuel-legend-fuel {
    background: #F6C401; /* 黄色 - 匹配油耗柱子 */
}

.legend-color.fuel-legend-carbon {
    background: #D3D3D3; /* 浅灰色 - 匹配碳排放柱子 */
}

.legend-label {
    font-size: 20px;
    color: #FFFFFF;
}

.task-bars-container {
    display: flex;
    justify-content: space-around;
    align-items: flex-end;
    gap: 20px;
    flex: 1;
    min-height: 393px;
    padding: 0 20px;
    min-width: 0;
}

.fuel-bars-container {
    display: flex;
    justify-content: space-around;
    align-items: flex-end;
    gap: 20px;
    flex: 1;
    min-height: 393px;
    padding: 0 20px;
    min-width: 0;
    background: #0C113C;
    border-radius: 8px;
    position: relative;
}

.task-bar-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    flex: 1;
    max-width: 150px;
}

.fuel-bar-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    flex: 1;
    max-width: 180px;
}

.task-total-label {
    font-weight: bold;
    font-size: 24px;
    color: #FFFFFF;
    margin-bottom: 5px;
}

.task-bar {
    width: 31px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-height: 60px;
    border-radius: 4px 4px 0 0;
    overflow: hidden;
}

/* 里程能耗统计专用样式 */
.fuel-bars-set {
    display: flex;
    gap: 12px;
    align-items: flex-end;
    justify-content: center;
    height: 220px;
}

.fuel-bar {
    width: 18px;
    min-height: 10px;
    border-radius: 9px 9px 0 0;
    transition: opacity 0.2s;
    cursor: pointer;
}

.fuel-bar:hover {
    opacity: 0.8;
}

.fuel-bar-mileage {
    background: #7EC8E3; /* 浅蓝色 */
}

.fuel-bar-fuel {
    background: #F6C401; /* 黄色/金色 */
}

.fuel-bar-carbon {
    background: #D3D3D3; /* 浅灰色 */
}

.fuel-city-label {
    font-weight: bold;
    font-size: 20px;
    color: #FFFFFF;
    text-align: center;
    margin-top: 10px;
}

.fuel-tooltip {
    position: absolute;
    background: rgba(12, 17, 60, 0.8);
    border: 2px dashed #7EC8E3;
    border-radius: 4px;
    padding: 12px 16px;
    display: none;
    z-index: 100;
    min-width: 180px;
    pointer-events: none;
}

.tooltip-item {
    font-size: 18px;
    color: #FFFFFF;
    margin-bottom: 8px;
    line-height: 1.5;
}

.tooltip-item:last-child {
    margin-bottom: 0;
}

.tooltip-value {
    color: #7EC8E3;
    font-weight: bold;
}

.task-segment {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: opacity 0.2s;
}

.task-segment.completed {
    background: #78ffd3;
}

.task-segment.in-progress {
    background: #ffd34a;
}

.task-segment.pending {
    background: #579dff;
}

.segment-value {
    font-weight: bold;
    font-size: 18px;
    color: #000000;
    text-align: center;
}

.task-city-label {
    font-weight: bold;
    font-size: 20px;
    color: #FFFFFF;
    text-align: center;
    margin-top: 10px;
}

.task-stats-arrow {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: opacity 0.3s;
    flex-shrink: 0;
    z-index: 10;
}

.task-stats-arrow:hover {
    opacity: 0.8;
}

.task-stats-arrow img {
    width: 60px;
    height: 60px;
    object-fit: contain;
}

/* 司机报案记录表格样式 */
.report-table.panel {
    padding: 20px;
}

.report-table-container {
    margin-top: 17px;
    height: 388px;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 10px;
    /* Firefox 滚动条样式 */
    scrollbar-width: thin;
    scrollbar-color: #66FFFF rgba(16, 42, 88, 0.35);
}

.report-table-container::-webkit-scrollbar {
    width: 3px;
}

.report-table-container::-webkit-scrollbar-track {
    background: rgba(16, 42, 88, 0.35);
    border-radius: 3px;
}

.report-table-container::-webkit-scrollbar-thumb {
    background: #66FFFF;
    border-radius: 3px;
}

.report-table-container::-webkit-scrollbar-thumb:hover {
    background: #66FFFF;
    opacity: 0.8;
}

.report-table {
    width: 100%;
    border-collapse: collapse;
    font-weight: 400;
    font-size: 24px;
    color: #FFFFFF;
}

.report-table thead {
    position: sticky;
    top: 0;
    z-index: 10;
}

.report-table th {
    text-align: left;
    background: #0C113C;
    border-bottom: 1px solid rgba(86, 160, 255, 0.3);
    white-space: normal;
    line-height: 1.4;
}

.report-table td {
    padding: 6px 0;
}

/* 响应缩放时避免抗锯齿导致的糊化（最佳实践：关闭文本平滑的可选项，按需添加） */
#stage { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }



