.clear-fix {
    clear: both;
}

header h1{
    font-size: 20px;
    background-color: lightgray;
    padding: 20px; 
    border-radius: 5px;
    text-align: center;
}

header p{
    font-size: 16px;
    padding: 0px;
    margin-top: 0px;
    margin-bottom: 0px;
    border-radius: 5px;
    text-align: center;
}

.container {
    display: flex; /* 开启弹性布局 */
    width: 100%;
    align-items: stretch; /* 两栏等高 */
}

.panel_left {
    flex: 40%;
    margin-top: -10px;
    margin-bottom: -10px;
    /*border: 1px solid #ccc;*/
    font-size: 12px;
    box-sizing: border-box;
    /*background-color: grey;*/

    display: flex;  /* 开启弹性布局 */
    flex-direction: column;
    min-height: 0;  /* 允许子元素收缩，避免溢出 */
}

.panel_right {
    flex: 60%;
    margin-top: -10px;
    margin-bottom: -10px;
    margin-left: 10px;
    /*border: 1px solid #ccc;*/
    font-size: 11px;
    box-sizing: border-box;
    /*background-color:lightyellow;*/

    min-height: 0;
}

.chart_head_bar {
    display: flex;
    flex-wrap: nowrap; /* 不换行 */
    gap: 10px; /* 元素间距 */
    align-items: center; /* 垂直居中 */
    margin-top: 5px;
    font-size: 12px;
    label {
        width: 20%;
        align-items: center;
    }
    .chart_toggle_group {
        width: 80%;
        display: flex;
        align-items: center;
        gap: 32px;
        background: #f1f5f9;
        padding: 4px 18px 4px 20px;
        border-radius: 10px;
    }
    .chart_toggle_group span {
        font-weight: 450;
        color: #1e293b;
    }
    .btn {
        background: white;
        border: none;
        padding: 0px 22px;
        border-radius: 40px;
        font-weight: 450;
        font-size: 13px;
        color: #1e293b;
        box-shadow: 0 2px 6px rgba(0,0,0,0.03);
        transition: 0.2s;
        cursor: pointer;
        border: 1px solid #d1d9e6;
    }
    .btn-primary {
        background: #3b82f6;
        border-color: #3b82f6;
        color: white;
        box-shadow: 0 4px 8px rgba(59,130,246,0.2);
    }
    .btn-primary:hover {
        background: #2563eb;
        border-color: #2563eb;
        transform: scale(0.97);
    }
    .btn-outline {
        background: transparent;
        border: 1px solid #cbd5e1;
    }
    .btn-outline:hover {
        background: #e9edf2;
    }
}

.empty-row {
    height: 10px;
}
.empty-column {
    width: 1%;
}
.cell-hidden {
    /*display: none;*/
    visibility: hidden;
    pointer-events: none;       /* 禁止鼠标交互 */
}
.cell-delete {
    display: none;
    pointer-events: none;       /* 禁止鼠标交互 */
}
.cell-blurred {
    filter: blur(4px);          /* 模糊半径可调 */
    transition: filter 0.3s;    /* 平滑过渡 */
    user-select: none;          /* 禁止选中文本 */
}

/***** 左半屏修饰 *****/
.panel_left_title_box {
    /* 左上抬头进行左右分区排布 */
    display: flex;
    justify-content: space-between; /* 左右两端对齐（如不需要贴边可选 flex-start） */
    align-items: center;            /* 垂直居中对齐 */
    margin: 0px 5px -10px 5px;
    padding: 0px;
}

#Title_left{
    /* 标题和版本号 */
    h1 {font-size: 16px; margin: 0px 5px; padding: 10px 10px 0 10px;}
    p  {font-size: 12px; margin: 0px 5px; padding: 0 10px 10px 10px;}
    border-radius: 5px;
    text-align: left;
}

#Title_middle{
    /* 空白占位 */
    margin-right: auto;
    padding: 0px 10px 0 10px;
    border-radius: 5px;
    text-align: left;
}

#Title_right{
    /* 五角星图片 */
    padding: 0px 10px 0 10px;
    border-radius: 5px;
    text-align: left;
}

.panel_left_input_box table {
    margin-top: 0px;
    width: 100%;
    flex: 0 0 auto;             /* 输入区不伸缩 */
    border-collapse: collapse;
    /*text-align: center;*/
    font-family: Arial, sans-serif;
    /*font-size: 18px;*/
    td, th {
        border-top: 1px solid #000;
        border-bottom: 1px solid #000;
        vertical-align: middle;
    }
    input[type="text"], input[type="number"], select {
        text-align: right;
        width: 100%;
        box-sizing: border-box;
        border: 1px solid #999;
        /*background-color: #fff2cc;*/
    }
    .table_project_name th {
        text-align: left;
        font-weight: bold;
        background-color: #d3d3d3;
    }
    .table_project_name td {
        text-align: center;
        /*background-color: #d9e1f2;*/
    }
    .cell_label_value {
        text-align: right;
        background-color: #e7e6e6;
    }
    .unit_vol::after {
        content: "V";         /* 自动显示的字符V */
        margin-left: 2px;     /* 与数字之间的间距 */
    }
    .unit_percent::after {
        content: "%";         /* 自动显示的字符% */
        margin-left: 2px;     /* 与数字之间的间距 */
    }
    .cell_input_l {
        text-align: right;
        background-color: #fff6cc;
        width: 125px;
        .input-with-unit {
            position: relative;
            display: inline-block;
        }
        .input-with-unit input {
            padding-right: 15px; /* 留出摆放单位的空间 */
        }
        .input-with-unit input[name="Q_MVcompensation"]{
            padding-right: 25px; /* 留出摆放单位的空间 */
        }
        .input-with-unit select {
            padding-right: 16px; /* 留出摆放单位的空间 */
        }
        .input-with-unit span {
            background-color: #fff6cc;
            position: absolute;
            right: 5px; /* 调整单位的位置 */
            top: 50%;
            transform: translateY(-50%);
            color: #666;
            pointer-events: none; /* 让点击单位时能直接聚焦到输入框 */
        }
    }
    .cell_input_r {
        text-align: right;
        background-color: #fff6cc;
        width: 85px;
        .input-with-unit {
            position: relative;
            display: inline-block;
        }
        .input-with-unit input, select{
            padding-right: 15px; /* 留出摆放单位的空间 */
        }
        .input-with-unit input[name="AUXConsumption"]{
            padding-right: 25px; /* 留出摆放单位的空间 */
        }
        .input-with-unit span {
            background-color: #fff6cc;
            position: absolute;
            right: 5px; /* 调整单位的位置 */
            top: 50%;
            transform: translateY(-50%);
            color: #666;
            pointer-events: none; /* 让点击单位时能直接聚焦到输入框 */
        }
    }
    .cell_pink {
        background-color: #FFC7CE;
        color: #9C0006;
        font-weight: bold;
    }
}

.panel_left_chart {
    flex: 1 1 0;
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
    position: relative;
    .cell_alarm {
        color: #9C0006;
        font-weight: bold;
        font-size: 14px;
    }
}

.panel_left_chart canvas {
    flex: 1 1 0;
    margin-top: 0px;
    width: 100%;

    min-height: 0;
    display: block;
    align-self: center;
}

/***** 右半屏修饰 *****/
.panel_right mark {
    display: block;
    /*background-color: #f9f9f9;*/
    margin: 5px 0px;
    padding: 2px;
}

.panel_right_display_box table {
    margin-top: 0px;
    width: 100%;
    border-collapse: collapse;
    font-family: Arial, sans-serif;
    tr {
        height: 18px; /* 每行统一高度，按需调整 */
    }
    .readonly {
        /*background-color: #e7e6e6;
        border: none;*/
        cursor: default;
        pointer-events: none; /* 禁止点击 */
    }
    .cell_label {
        text-align: center;
        width: 10%;
    }
    .cell_label_value {
        text-align: center;
        background-color: #ddebf7;
    }
    .cell_label_name {
        text-align: left;
        /*font-weight: bold;*/
        white-space: nowrap; /*强制文字不许换行*/
        width: 1%;
        background-color: #d0cece;
    }
    .cell_label_unit {
        margin: 0px 2px;
        text-align: center;
        width: 30px;
        background-color: #e7e6e6;
    }
    .cell_darkblue {
        background-color: #4472c4;
        color: white;
    }
    .cell_green {
        background-color: #c6e0b4;
    }
    .cell_pink {
        background-color: #FFC7CE;
        color: #9C0006;
        font-weight: bold;
    }
    .cell_bold {
        font-weight: bolder;
    }
    .cell_input {
        text-align: center;
        background-color: #fff2cc;
    }
    
    input[type="text"], input[type="number"], select {
        margin: -10px -20px;
        border: 1px solid #999;
        padding: 0px;
        text-align: center;
        width: 100%; /*5em*/
        font-size: 11px;
        font-weight: bolder;
        /*box-sizing: border-box;*/
    }
    
/*
    input[type="checkbox"] {
        width: auto;
        cursor: pointer;
        margin: 0 auto;
        vertical-align: middle;
    }
*/
}

footer {
    text-align: center;
    font-family: Arial, sans-serif;
    font-size: 14px;
    color: gray;
    padding: 10px;
}