﻿:root {
    --primary: #18AACC;
    --primary-dark: #1190AC;
    --primary-light: #e6f7fb;
    --primary-mid: #b3e8f5;
    --accent: #0d7fa0;
    --text-dark: #1a2332;
    --text-muted: #6c7a8d;
    --border: #dce8ed;
    --bg: #ffffff;
    --bg-soft: #f4fbfd;
    --success: #28a745;
    --warning: #ffc107;
    --danger: #dc3545;
}
/******pagimnation*****/
.paginationPanel {
    float: right;
    padding: 8px 8px;
    /* border: solid thin #ccc; */
    border-radius: 5px;
    margin-bottom: 7px;
    box-shadow: 0 1px 15px 1px rgba(69, 65, 78, .08);
    border: 1px solid rgba(0, 0, 0, .07);
    font-size: 13px;
    background: #fff;
}

    .paginationPanel a {
        margin: 0px 1px;
        cursor: pointer;
        background: #f1f1f1;
        width: 18px;
        height: 18px;
        display: inline-block;
        border-radius: 50%;
        text-align: center;
        color: #757575;
        font-size: 11px;
        line-height: 20px;
        font-weight: bold;
    }

        .paginationPanel a:hover, .paginationPanel a.active {
            background: #18aacc;
            color: #fff;
            background: #c5eef7;
            color: #18aacc;
        }

    .paginationPanel .paginationpage {
        max-width: 32px;
        text-align: center;
        height: 21px;
        border: solid thin #ccc;
    }

    .paginationPanel select {
        max-width: 48px;
        text-align: center;
        height: 21px;
        border: solid thin #ccc;
    }

    .paginationPanel button {
        background: #edfbfe;
        color: #18aacc;
        border: none;
        border-radius: 3px;
        cursor: pointer;
        font-size: 11px;
        line-height: 19px;
        font-weight: bold;
    }

    .paginationPanel .borderleft {
        border-left: solid thin #dadada;
    }
/******pagimnation*****/

.alert {
    padding: 10px 14px 10px 12px;
    margin-bottom: 6px;
    font-weight: bold;
    margin-top: -4px;
}

.footerFixed {
    position: fixed;
    background: #fff;
    right: 0px;
    left: 50px;
    bottom: 0px;
    z-index: 999;
    padding: 5px 10px;
    border-top: solid thin #ccc;
    display: none;
}

.table tbody tr td {
    padding: 3px 6px;
}

.lastCol {
    position: sticky !important;
    overflow: visible !important;
}

    .lastCol:after {
        position: absolute;
        top: 0;
        bottom: -1px;
        right: -14px;
        width: 13px;
        transform: translate(-100%);
        transition: box-shadow .3s;
        content: "";
        pointer-events: none;
        box-shadow: inset -10px 0 8px -8px #00000026;
    }

.costsetting {
    float: left;
    border: solid thin #ccc;
    padding: 5px 8px;
    border-radius: 10px;
    margin-left: 10px;
    margin-top: -6px;
}

    .costsetting .select2-container--default .select2-selection--single {
        height: 29px;
        width: 160px;
    }

        .costsetting .select2-container--default .select2-selection--single .select2-selection__rendered {
            line-height: 22px;
        }

        .costsetting .select2-container--default .select2-selection--single .select2-selection__arrow b {
            top: 41%;
        }

    .costsetting label {
        margin-top: 4px;
    }

.specialText {
    color: #1479f7;
    font-weight: bold;
    cursor: pointer;
}

.btnSelectWBS {
    font-size: 17px;
    margin-right: 4px;
    margin-top: 1px;
}

.searchPanel {
    margin-bottom: 10px;
}

.form-control, .select2-container--default .select2-selection--single {
    border-radius: 6px;
}


label {
    color: #333;
}

.btnSelectWBS {
    font-size: 17px;
    margin-right: 4px;
    margin-top: 1px;
    position: absolute;
    top: 26px;
    right: 17px;
    color: #1479f7;
    cursor: pointer;
    z-index: 9;
}

.form-control {
    border-radius: 4px;
    background: #fff;
    border: 1px solid #e5e5e5;
}

span.dynatree-node a i {
    font-style: initial;
}

.treebg {
    overflow: auto;
    height: 60vh !important;
    border: solid thin #eaecf1;
    margin-top: 8px;
    box-shadow: rgba(50, 50, 93, 0.25) 0px -62px 13px -111px inset, rgba(0, 0, 0, 0.3) 0px -2px 19px -10px inset;
    box-shadow: none;
    padding: 0px;
    border-top-left-radius: 0px;
    border-top-right-radius: 0px;
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
}

span.dynatree-icon {
    display: none;
}

span.dynatree-node a {
    font-size: 13px;
    display: inline-block;
    /* vertical-align: top; */
    padding-left: 0px;
    padding-right: 3px;
    padding-top: 2px;
    padding-bottom: 2px;
    margin-left: 0px;
    color: #333;
    font-weight: 500;
}

ul.dynatree-container img {
    width: 15px;
    height: 15px;
    vertical-align: -2px;
}

ul.dynatree-container li {
    padding: 4px 0px;
}

span.dynatree-node .taskSet {
    color: #0c82eb !important;
}

span.dynatree-node p {
    margin-bottom: 0px;
}

span.dynatree-active a {
    background-color: #ffffff !important;
    color: #1479f7 !important;
    border: solid thin #1479f7;
    padding-left: 5px !important;
    padding-right: 5px !important;
    border-radius: 4px;
    padding-top: 5px !important;
}

span.dynatree-node .MatSet {
    color: #646566 !important;
}

span.dynatree-node .labSet {
    color: #646566 !important;
}

span.dynatree-node .EquipSet {
    color: #646566 !important;
}

span.dynatree-node .QualSet {
    color: #646566 !important;
}

span.dynatree-active a .taskSet, span.dynatree-active a .MatSet, span.dynatree-active a .labSet, span.dynatree-active a .EquipSet, span.dynatree-active a .QualSet {
    color: #1479f7 !important;
}

.tableTreeClick {
    cursor: pointer;
    font-size: 16px;
    vertical-align: -2px;
}

.table > tbody > tr > td {
    padding: 7px 14px;
}

.ml50 {
    margin-left: 40px;
    color: #0098b3;
    font-size: 13px;
    font-weight: 500;
}

.flagGroup td {
    background: #f4f4f4;
    color: #3d506d !important;
}

/* Progress bar */
.mini-progress {
    width: 90px;
    height: 8px;
    background: #c7c7c7;
    border-radius: 4px;
    overflow: hidden;
}

.mini-progress-fill {
    height: 100%;
    border-radius: 4px;
    background: linear-gradient(90deg, var(--primary), #22bfe0);
    transition: width .6s ease;
}

/* Cost centre cell */
.cc-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: var(--primary-light);
    color: var(--primary-dark);
    border: 1px solid #9addf0;
    border-radius: 20px;
    padding: 3px 10px;
    font-size: .76rem;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
}

    .cc-badge:hover {
        background: var(--primary);
        color: #fff;
        border-color: var(--primary);
    }

.cc-unlinked {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: #fff5e6;
    color: #b06000;
    border: 1px dashed #f0b040;
    border-radius: 20px;
    padding: 3px 10px;
    font-size: .76rem;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
}

    .cc-unlinked:hover {
        background: #ffe4b0;
        border-color: #e09000;
    }

.offcanvas-header {
    box-shadow: rgba(100, 100, 111, 0.2) 0px 7px 29px 0px;
}

.offcanvas-footer {
    padding: 10px;
    box-shadow: rgba(100, 100, 111, 0.2) 0px 7px 29px 0px;
    background: #f4f4f4;
    border-top: solid thin #cfcfcf;
}

.offcanvas-title {
    font-size: 15px;
}

.table-responsive {
    border-radius: 8px;
    box-shadow: rgba(0, 0, 0, 0.12) 0px 1px 3px, rgba(0, 0, 0, 0.24) 0px 1px 2px;
}

#BuildingLinking {
    display: none
}







/* 🔥 OFFCANVAS BODY FIX */
#offcanvasCostCentre .offcanvas-body {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 10px;
}

/* 🔥 SEARCH BOX */
#offcanvasCostCentre input {
    flex-shrink: 0;
}

/* 🔥 TREE AREA SCROLL */
#ccTree {
    flex: 1;
    overflow-y: auto !important;
    max-height: none !important;
    border: 1px solid #ddd;
    padding: 8px;
}

/* 🔥 SAVE BUTTON FIX */
#offcanvasCostCentre .mt-3 {
    flex-shrink: 0;
    padding-top: 10px;
    background: #fff;
    border-top: 1px solid #ddd;
    text-align: right;
}

#ccTree {
    min-width: 200px;
}


#ccFooter button {
    position: sticky;
    bottom: 0;
}



#ccTree {
    font-size: 13px;
}

.cc-node {
    line-height: 24px;
    cursor: pointer;
}

    .cc-node i {
        margin-right: 5px;
        color: #333;
    }

.cc-leaf-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #999;
    border-radius: 50%;
    margin-right: 8px;
}

.cc-text {
    color: #333;
}

.cc-node:hover .cc-text {
    color: #007bff;
}







/* NORMAL NODE */
.cc-node {
    cursor: pointer;
    padding: 3px 6px;
    border-radius: 4px;
}

    /* HOVER */
    .cc-node:hover {
        background: #f3f7ff;
    }

/* 🔥 SELECTED NODE (LIKE SCREENSHOT) */
.cc-selected {
    background: #eaf2ff;
    border: 1px solid #2d7ef7;
    border-radius: 4px;
    color: #000;
}



.company-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--primary-light);
    border: 1px solid var(--primary-mid);
    border-radius: 9px;
    padding: 4px 5px;
    font-size: 0.80rem;
    font-weight: 600;
    color: var(--accent);
    margin-top: 2px;
    animation: fadeIn .4s ease;
}


.cc-selected {
    background: #eaf2ff;
    border: 1px solid #2d7ef7;
    border-radius: 4px;
}

.status-pill {
    background: #1e88e5;
    color: #fff;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
}


.cc-node {
    padding: 4px 6px;
    cursor: pointer;
}

    .cc-node:hover {
        background: #e9f2ff;
    }

.cc-selected {
    background: #0d6efd !important;
    color: #fff !important;
    border-radius: 4px;
    padding: 4px 6px;
}

    .cc-selected span {
        color: #fff !important;
    }



.cc-content.cc-selected {
    background: #0d6efd !important;
    color: #fff !important;
}


#ccTree {
    position: relative;
}

/* Loader Overlay */
#ccTreeLoader {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255,255,255,0.6);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.loader-spinner {
    width: 28px;
    height: 28px;
    border: 3px solid #ccc;
    border-top: 3px solid #0d6efd;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    100% {
        transform: rotate(360deg);
    }
}

.cc-node i {
    margin-right: 4px;
}