#workspace {
    display: none;
    text-align: center;
    background: #f6f7fa;
    margin-top: 0.75rem;
    border: 1px solid #eee;
    border-radius: 3px;
}

.night #workspace{
    background: #181a1b;
    border: 1px solid #444;
}

.control-bar {
    padding: 0.5rem;
    border-bottom: 1px solid #eee;
    margin-bottom: 0.75rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.night .control-bar{
    border-bottom: 1px solid #444;
}

.control-bar>div:nth-child(1)>div:nth-child(1){
    margin-right: 0.5rem;
}

.control-bar>div:nth-child(2)>div:nth-child(1) {
    margin-right: 0.5rem;
}

.mode-group {
    border-radius: 6px;
    float: left;
    overflow: hidden;
    background-color: #fff;
    border: 1px solid #eee;
}

.night .mode-group {
    border: 1px solid #444;
    background-color: #232627;
}

.pdfbut{
    padding: 0.2rem 0.5rem;
    border: 0;
    background-color: #fff;
    cursor: pointer;
}

.pdfbut.r{
    border-right: 1px solid #eee;
}

.night .pdfbut.r{
    border-right: 1px solid #444;
}

.pdfbut.l{
    border-left: 1px solid #eee;
}

.night .pdfbut.l{
    border-left: 1px solid #444;
}


.night .pdfbut{
    color: #bbb;
    background-color: #232627;
}

.pdfbut i{
    font-size: 0.5rem;
}

.pdfbut.act{
    background-color: #1e9fff;
    color: #fff;
}

#pageInfo,#zoomInfo,#qualityInfo{
    padding: 0.2rem 0.5rem;
}

.night #pageInfo,.night #zoomInfo,.night #qualityInfo{
    background-color: #232627;
    color: #bbb;
    border:0;
}

.canvas-wrapper {
    position: relative;
    display: inline-block;
    border-radius: 3px;
    margin: 0 auto;
    overflow: hidden;
    cursor: default;
    padding: 0 0.5rem;
}

.canvas-wrapper canvas{
    width: 100%;
    display: block;
    border: 1px solid #eee;
}

#cut-line {
    position: absolute;
    background-color: rgba(255, 0, 0, 0.8);
    z-index: 10;
    left: 50%;
    width: 2px;
    height: 100%;
    top: 0;
    cursor: ew-resize;
    box-shadow: 0 0 4px rgba(255, 255, 255, 0.8);
    transition: top 0.2s, left 0.2s;

    will-change: transform;
    transition: none; 
}

#cut-line.mode-horizontal {
    left: 0;
    top: 50%;
    width: 100%;
    height: 2px;
    cursor: ns-resize;
}

#tooltip {
    position: fixed;
    background: rgba(0, 0, 0, 0.85);
    color: #fff;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 12px;
    pointer-events: none;
    white-space: nowrap;
    z-index: 9999;
    display: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
    border: 1px solid #555;
    font-family: Consolas, Monaco, monospace;
}

#cut-line.mode-horizontal::after {
    content: "↕";
}

.tips {
    margin-top: 10px;
    color: #888;
    font-size: 12px;
}

.action-area {
    margin-top: 0.75rem;
    text-align: center;
    padding-bottom: 0.75rem;
    display: flex;
    justify-content: center;
    gap: 0.75rem;
}

.action-area button{
    padding: 0.25rem 0.75rem;
    background-color: #FF9800;
    color: #fff;
    border: 0;
    border-radius: 3px;
    font-size: 0.65rem;
    cursor: pointer;
}

.action-area button.clears{
    background-color: #607D8B;
}

@media screen and (max-width: 1008px){
    .control-bar {
        display: flex;
        justify-content: flex-start;
        align-items: flex-start;
        flex-direction: column;
        gap: 0.5rem;
    }
}

@media screen and (max-width: 886px){
    .control-bar {
        display: flex;
        justify-content: space-between;
        align-items: flex-start;
        flex-direction: row;
        gap: 0.5rem;
    }
}

@media screen and (max-width: 725px){
    .control-bar {
        display: flex;
        justify-content: flex-start;
        align-items: flex-start;
        flex-direction: column;
        gap: 0.5rem;
    }
}

@media screen and (max-width: 415px){
    .control-bar>div:nth-child(1){
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
}

@media screen and (max-width: 290px){
    .control-bar>div:nth-child(2){
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
}