/* ============================================================================
   Organizational Chart CSS - CPDMS
   Exact visual match to Department Organizational Chart Specification
   ============================================================================ */

.org-outer-frame {
    width: 100%;
    max-width: 1180px;
    margin: 4px auto 25px auto;
    background-color: #eed6d6;
    border: 2px solid #235294;
    border-radius: 8px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
    overflow: hidden;
}

.org-header-banner {
    background: linear-gradient(180deg, #285da2 0%, #1c457f 100%);
    color: #ffffff;
    text-align: center;
    padding: 12px 20px;
    font-family: Arial, 'Segoe UI', sans-serif;
    font-size: 24px;
    font-weight: 800;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    border-bottom: 2px solid #163a6c;
}

.org-chart-scroll {
    width: 100%;
    overflow-x: auto;
    padding: 30px 20px 40px 20px;
    display: flex;
    justify-content: center;
    background-color: #eed6d6;
    min-height: 460px;
}

/* ============================================================================
   Table-Based Precision Tree Connector Architecture
   Guarantees 100% solid, perfectly aligned, gap-free lines and arrows
   ============================================================================ */
.org-chart-table {
    margin: 0 auto;
    border-collapse: separate !important;
    border-spacing: 0 !important;
}

.org-node-cell {
    text-align: center;
    vertical-align: top;
    padding: 0;
}

/* Vertical Stem directly beneath parent */
.org-stem-cell {
    text-align: center;
    vertical-align: top;
    height: 25px;
    padding: 0;
    line-height: 0;
}

.org-stem-line {
    width: 2px;
    height: 18px;
    background: #222222;
    margin: 0 auto;
}

/* Horizontal crossbar row */
.org-h-cell {
    height: 1px !important;
    line-height: 0 !important;
    font-size: 0 !important;
    padding: 0 !important;
}

.org-h-left {
    border-top: 2px solid #222222;
}

.org-h-right {
    border-top: 2px solid #222222;
}

.org-h-cell.no-border {
    border-top: none !important;
}

/* Dropdown line from horizontal bar into each child */
.org-drop-cell {
    text-align: center;
    vertical-align: top;
    height: 23px;
    padding: 0;
    line-height: 0;
}

.org-drop-line {
    width: 2px;
    height: 16px;
    background: #222222;
    margin: 0 auto;
}

/* Downward pointing arrow */
.org-arrow {
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 7px solid #222222;
    margin: 0 auto;
    line-height: 0;
    font-size: 0;
}

/* Child cell wrapper */
.org-child-cell {
    text-align: center;
    vertical-align: top;
    padding: 0 16px;
}

/* ============================================================================
   Node Cards & Pills Styling (Matches Screenshot 1 Exactly)
   All cards are uniform in width ("Ekdam Level Mai") and sized roomier
   ============================================================================ */
.node-member-box {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    cursor: default;
    position: relative;
    width: 280px;
    max-width: 280px;
    box-sizing: border-box;
    transition: transform 0.15s;
}

.node-member-box:hover {
    transform: translateY(-2px);
}

/* 3D Glossy Designation Pill - Full Format (Spans ~88% of Box Width) */
.node-pill {
    display: inline-block;
    width: 88%;
    box-sizing: border-box;
    padding: 5px 12px;
    border-radius: 9999px;
    color: #ffffff;
    font-family: Arial, 'Segoe UI', sans-serif;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.25), inset 0 1px 1px rgba(255, 255, 255, 0.45);
    margin-bottom: -11px;
    position: relative;
    z-index: 3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    border: 1px solid rgba(0, 0, 0, 0.25);
    text-align: center;
}

/* Specific 3D gradients matching screenshot */
.node-pill[data-level="green"],
.node-pill-green {
    background: linear-gradient(180deg, #6ca733 0%, #4a7722 100%) !important;
    border-color: #3d641c !important;
}

.node-pill[data-level="orange"],
.node-pill-orange {
    background: linear-gradient(180deg, #ea7823 0%, #c45709 100%) !important;
    border-color: #a34604 !important;
}

.node-pill[data-level="purple"],
.node-pill-purple {
    background: linear-gradient(180deg, #6c47a0 0%, #4b2b79 100%) !important;
    border-color: #3b1f62 !important;
}

.node-pill[data-level="blue"],
.node-pill-blue {
    background: linear-gradient(180deg, #028ddc 0%, #005ea7 100%) !important;
    border-color: #004b86 !important;
}

/* White Name Box - Uniform Width & Roomier Size */
.node-name-box {
    background: #ffffff;
    border: 1.5px solid #2d2d2d;
    border-radius: 6px;
    width: 100%;
    box-sizing: border-box;
    padding: 16px 14px 10px 14px;
    font-family: Arial, 'Segoe UI', sans-serif;
    font-size: 14px;
    font-weight: 700;
    color: #111111;
    letter-spacing: 0.4px;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.2);
    text-align: center;
    white-space: nowrap;
    position: relative;
    z-index: 2;
}

.node-name-box.vacant {
    color: #cc0000 !important;
    font-weight: 800 !important;
}

/* Large Rounded "PROJECT MONITORING UNIT" Box */
.node-unit-box {
    background: #ffffff;
    border: 1.5px solid #c8c8c8;
    border-radius: 18px;
    padding: 30px 20px;
    font-family: Arial, 'Segoe UI', sans-serif;
    font-size: 16px;
    font-weight: 800;
    color: #000000;
    letter-spacing: 0.6px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.18);
    width: 220px;
    max-width: 220px;
    min-height: 160px;
    box-sizing: border-box;
    text-align: center;
    line-height: 1.35;
    text-transform: uppercase;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s;
    position: relative;
    z-index: 2;
}

.node-unit-box:hover {
    transform: translateY(-2px);
}

.org-empty-state {
    padding: 60px 20px;
    text-align: center;
    color: #555555;
    font-size: 16px;
}

.org-empty-state i {
    font-size: 36px;
    color: #3668a2;
    margin-bottom: 12px;
    display: block;
}

@media (max-width: 768px) {
    .org-header-banner {
        font-size: 19px;
        padding: 10px 14px;
    }
    .node-member-box {
        width: 200px;
        max-width: 200px;
    }
    .node-name-box {
        font-size: 12px;
        padding: 13px 8px 7px 8px;
    }
    .node-pill {
        font-size: 10.5px;
        padding: 3px 8px;
        margin-bottom: -9px;
        width: 90%;
    }
    .node-unit-box {
        width: 170px;
        font-size: 13.5px;
        padding: 20px 14px;
        min-height: 130px;
    }
}

/* Page Level Breadcrumb & Layout */
.ci-team-breadcrumb {
    width: 100% !important;
    padding: 10px 18px !important;
    border-radius: 4px !important;
    display: flex !important;
    margin-top: 10px !important;
    background-color: #e5e7eb !important;
}

.ci-team-breadcrumb-list {
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
    display: inline-flex !important;
    align-items: center !important;
}

.ci-team-heading {
    display: block !important;
    clear: both !important;
    font-size: 28px !important;
    font-family: 'Poppins', sans-serif !important;
    margin: 1rem 0 !important;
    text-align: left !important;
    font-weight: 700 !important;
}

.ci-team-heading-en {
    color: #3668a2 !important;
}

.ci-team-heading-hi {
    color: #fcb045 !important;
}

.ci-team-tree-wrapper {
    display: inline-block !important;
    margin: 0 auto !important;
}

.ci-team-back-btn {
    margin-top: 15px !important;
    margin-bottom: 25px !important;
    display: inline-flex !important;
    align-items: center !important;
}
