/* ============================================================
   Metal Works — Production Status wall board
   Styled to match the PowerFab Explorer app.
   Designed for viewing from across a room (large type,
   high contrast). Scales to any 16:9 monitor.
   Metal Works — PM drill-down board.
   ============================================================ */

:root {
    --navy: #37474F;
    --blue: #1976D2;
    --grey: #607D8B;
    --hdr: #CFD8DC;
    --light: #ECEFF1;
    --line: #E0E0E0;
    --red-bg: #FFCDD2;
    --yellow-bg: #FFECB3;
    --green-tx: #2E7D32;
    --red-tx: #C62828;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    height: 100%;
    width: 100%;
    overflow: hidden;
    font-family: "Segoe UI", Arial, sans-serif;
    color: #212121;
    background: #fff;
}

.topbar {
    height: 8vh;
    min-height: 54px;
    background: var(--navy);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 2.2vw;
}

.brand {
    font-size: 3.0vh;
    font-weight: 600;
    letter-spacing: .5px;
}

.right {
    display: flex;
    align-items: baseline;
    gap: 1.4vw;
}

.pmname {
    font-size: 3.4vh;
    font-weight: 800;
    color: #fff;
}

.stamp {
    font-size: 1.8vh;
    color: #B0BEC5;
}

.strip {
    display: flex;
    align-items: center;
    background: var(--hdr);
    color: var(--navy);
    font-weight: 700;
    font-size: 2.2vh;
    padding: 1vh 1.4vw;
}

.c-label {
    flex: 1 1 auto;
}

.c-pct {
    width: 14vw;
    text-align: center;
}

.tree {
    height: 76vh;
    overflow-y: auto;
    animation: fade .5s ease;
}

@keyframes fade {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.row {
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--line);
}

    .row .label {
        flex: 1 1 auto;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .row .pct {
        width: 14vw;
        text-align: center;
        font-weight: 800;
        padding: .4vh 0;
        border-radius: 6px;
    }

.job > .row {
    padding: 1.4vh 1.4vw;
    background: #F7F9FA;
    cursor: pointer;
}

    .job > .row:hover {
        background: #EEF3F5;
    }

    .job > .row .label {
        font-size: 3.0vh;
        font-weight: 800;
        color: var(--navy);
    }

    .job > .row .pct {
        font-size: 3.0vh;
    }

.job.open > .row {
    background: #E3F2FD;
}

.caret {
    display: inline-block;
    width: 2.2vw;
    font-size: 2.4vh;
    color: var(--grey);
}

.rel > .row {
    padding: 1.1vh 1.4vw 1.1vh 3vw;
    background: #fff;
    cursor: pointer;
}

    .rel > .row:hover {
        background: #F5F5F5;
    }

    .rel > .row .label {
        font-size: 2.5vh;
        font-weight: 600;
        color: #263238;
    }

    .rel > .row .pct {
        font-size: 2.5vh;
    }

.asm .row {
    padding: .8vh 1.4vw .8vh 5vw;
    background: #FCFCFD;
}

    .asm .row .label {
        font-size: 2.1vh;
        color: #37474F;
    }

    .asm .row .pct {
        font-size: 2.1vh;
    }

.children {
    display: none;
}

.open > .children {
    display: block;
}

.pct.p-na {
    color: #90A4AE;
}

.pct.p-zero {
    color: var(--red-tx);
}

.pct.p-low {
    background: var(--red-bg);
}

.pct.p-mid {
    background: var(--yellow-bg);
}

.pct.p-done {
    color: var(--green-tx);
}

.footbar {
    height: 8vh;
    min-height: 44px;
    background: var(--light);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.2vw;
    padding: 0 2.2vw;
    position: relative;
}

.navbtn {
    background: #CFD8DC;
    color: var(--navy);
    border: none;
    cursor: pointer;
    font-size: 3vh;
    line-height: 1;
    padding: .4vh 1.4vw;
    border-radius: 6px;
}

    .navbtn:hover {
        background: #B0BEC5;
    }

.dots {
    display: flex;
    gap: 1vw;
}

.dot {
    width: 1.3vh;
    height: 1.3vh;
    border-radius: 50%;
    background: #B0BEC5;
}

    .dot.active {
        background: var(--blue);
    }

.counter {
    position: absolute;
    right: 2.2vw;
    font-size: 2vh;
    color: var(--grey);
    font-weight: 600;
}

.message {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4vh;
    color: var(--grey);
    text-align: center;
    padding: 4vw;
}
