/* Public website — dabeng/OrgChart (read-only, themed) */
.ws-org-section,
#struktur-organisasi-chart {
    width: 100%;
    text-align: center;
}

.ws-org-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 16px;
    text-align: left;
}

.ws-org-hint {
    font-size: 13px;
    color: #6c757d;
    margin: 0;
}

.ws-org-zoom {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
}

.ws-org-zoom button {
    width: 36px;
    height: 36px;
    border: 1px solid #dee2e6;
    background: #fff;
    border-radius: 8px;
    cursor: pointer;
    color: #1b6b3a;
    font-size: 16px;
    line-height: 1;
    transition: background 0.2s, border-color 0.2s;
}

.ws-org-zoom button:hover {
    background: #eaf5ee;
    border-color: #27ae60;
}

/* Scroll area — chart centered inside */
.ws-org-chart-wrap {
    background: #f8faf9;
    border: 1px solid #e8eeeb;
    border-radius: 14px;
    padding: 24px 16px;
    min-height: 420px;
    overflow: auto;
    text-align: center;
    -webkit-overflow-scrolling: touch;
}

#ws-org-chart-container {
    display: block;
    width: 100%;
    min-height: 380px;
    text-align: center;
    margin: 0 auto;
}

/* Center the table-based chart (override theme / plugin defaults) */
.ws-org-chart-wrap .orgchart,
#ws-org-chart-container .orgchart {
    display: inline-block !important;
    float: none !important;
    margin-left: auto !important;
    margin-right: auto !important;
    text-align: left !important;
    background: transparent !important;
    background-image: none !important;
    border: none !important;
    padding: 16px 20px !important;
    position: relative !important;
    left: auto !important;
    top: auto !important;
    transform-origin: top center !important;
}

.ws-org-chart-wrap .orgchart table,
#ws-org-chart-container .orgchart table {
    margin-left: auto !important;
    margin-right: auto !important;
}

.ws-org-chart-wrap .orgchart .node,
#ws-org-chart-container .orgchart .node {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    overflow: visible !important;
    width: auto !important;
    height: auto !important;
    min-width: 120px !important;
    max-width: 170px !important;
    margin: 0 0 20px 0 !important;
    padding: 0 !important;
}

.ws-org-chart-wrap .orgchart .node:hover,
#ws-org-chart-container .orgchart .node:hover {
    background-color: transparent !important;
}

.ws-org-chart-wrap .orgchart .node .title,
#ws-org-chart-container .orgchart .node .title {
    display: none !important;
    height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    border: none !important;
    overflow: hidden !important;
}

.ws-org-chart-wrap .orgchart .node .content,
#ws-org-chart-container .orgchart .node .content {
    padding: 6px 8px 4px !important;
    text-align: center !important;
    background: transparent !important;
    border: none !important;
    height: auto !important;
    min-height: 0 !important;
    white-space: normal !important;
}

/* Connector lines — green (not default red) */
.ws-org-chart-wrap .orgchart .lines .downLine,
#ws-org-chart-container .orgchart .lines .downLine {
    background-color: #27ae60 !important;
}
.ws-org-chart-wrap .orgchart .lines .topLine,
#ws-org-chart-container .orgchart .lines .topLine {
    border-top: 2px solid #27ae60 !important;
}
.ws-org-chart-wrap .orgchart .lines .rightLine,
#ws-org-chart-container .orgchart .lines .rightLine {
    border-right: 2px solid #27ae60 !important;
}
.ws-org-chart-wrap .orgchart .lines .leftLine,
#ws-org-chart-container .orgchart .lines .leftLine {
    border-left: 2px solid #27ae60 !important;
}

.ws-org-chart-wrap .orgchart .node[data-node-id="0"],
#ws-org-chart-container .orgchart .node[data-node-id="0"] {
    visibility: hidden !important;
    pointer-events: none !important;
}

.ws-org-node-photo {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #fff;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    display: block;
    margin: 0 auto 8px;
    background: #e8eeeb;
}

.ws-org-node-name {
    font-size: 13px;
    font-weight: 700;
    color: #1a2e22;
    line-height: 1.35;
    margin-bottom: 4px;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.ws-org-node-role {
    display: inline-block;
    font-size: 11.5px;
    color: #1b6b3a;
    font-weight: 600;
    line-height: 1.25;
    background: rgba(234, 245, 238, 0.95);
    border-radius: 20px;
    padding: 2px 9px;
}

.ws-org-loading {
    padding: 48px 20px;
    color: #6c757d;
    font-size: 15px;
}

.ws-org-empty {
    text-align: center;
    padding: 48px 24px;
    color: #6c757d;
}

@media (max-width: 768px) {
    .ws-org-chart-wrap {
        padding: 12px 8px;
        min-height: 320px;
    }

    .ws-org-chart-wrap .orgchart .node,
    #ws-org-chart-container .orgchart .node {
        min-width: 100px !important;
        max-width: 140px !important;
    }
}
