body {
    font-size: .875rem;
    background-color: #f8f9fc;
}
.feather {
    width: 16px;
    height: 16px;
    vertical-align: text-bottom;
}
.sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 100;
    padding: 48px 0 0;
    box-shadow: inset -1px 0 0 rgba(0, 0, 0, .1);
}
.sidebar .nav-link {
    font-weight: 500;
    color: #adb5bd;
    padding: 0.5rem 1rem;
    border-radius: 0.25rem;
    margin: 0.1rem 0.5rem;
}
.sidebar .nav-link:hover {
    background-color: rgba(13, 110, 253, 0.2);
    color: #fff;
}
.sidebar .nav-link.active {
    color: #fff;
    background-color: rgba(13, 110, 253, 0.3);
}
.sidebar .nav-link .bi {
    margin-right: 8px;
}
.sidebar .nav-link.text-danger:hover {
    background-color: rgba(220, 53, 69, 0.2);
    color: #ff6b6b !important;
}
main {
    padding-top: 1.5rem;
}
.card {
    border: none;
    border-radius: 10px;
    transition: box-shadow 0.3s ease;
}
.card:hover {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15) !important;
}
.card-header {
    border-radius: 10px 10px 0 0 !important;
    font-size: 0.9rem;
}
.stat-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: default;
    overflow: hidden;
    position: relative;
}
.stat-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.2) !important;
}
.stat-card .card-body {
    padding: 1.5rem;
}
.stat-card::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    pointer-events: none;
}
.stat-card .bi {
    transition: transform 0.3s ease;
}
.stat-card:hover .bi {
    transform: scale(1.1);
}
.table th {
    font-weight: 600;
    font-size: 0.85rem;
}
.table td {
    vertical-align: middle;
}
.dataTables_wrapper .dataTables_filter input {
    border: 1px solid #dee2e6;
    border-radius: 5px;
    padding: 0.375rem 0.75rem;
}
.dataTables_wrapper .dataTables_length select {
    border: 1px solid #dee2e6;
    border-radius: 5px;
    padding: 0.375rem 0.75rem;
}
.badge {
    font-weight: 500;
    padding: 0.35em 0.65em;
}
.progress {
    border-radius: 10px;
    background-color: #e9ecef;
}
.progress-bar {
    border-radius: 10px;
    transition: width 1s ease;
}
/* Dashboard specific */
.border-bottom-dash {
    border-bottom: 1px dashed #dee2e6;
}
/* Organizational Chart Styles */
.org-chart {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2rem 0;
    gap: 0;
}

.org-level {
    display: flex;
    justify-content: center;
    width: 100%;
    padding: 0.5rem 0;
}

.org-level-1 .org-node {
    min-width: 250px;
}

.org-level-2 .org-node-group {
    display: flex;
    gap: 4rem;
    justify-content: center;
    flex-wrap: wrap;
}

.org-level-3 .org-node-group {
    display: flex;
    gap: 4rem;
    justify-content: center;
    flex-wrap: wrap;
}

.org-level-3-group {
    margin-left: -150px; /* align to the left under IT Fungsional */
}

.org-node {
    display: flex;
    justify-content: center;
}

.org-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.2rem 1.8rem;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    min-width: 220px;
    cursor: default;
    border: none;
}

.org-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15) !important;
}

.org-card-primary {
    background: linear-gradient(135deg, #0d6efd, #0a58ca);
    color: #fff;
}

.org-card-secondary {
    background: linear-gradient(135deg, #198754, #146c43);
    color: #fff;
}

.org-card-tertiary {
    background: linear-gradient(135deg, #6c757d, #5c636a);
    color: #fff;
}

.org-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.org-info h6 {
    font-weight: 600;
    font-size: 0.85rem;
    white-space: nowrap;
}

.org-info small {
    font-size: 0.7rem;
    opacity: 0.9;
    display: block;
}

/* Connector lines */
.org-connector {
    display: flex;
    justify-content: center;
    height: 40px;
    width: 100%;
    position: relative;
}

.org-connector-line {
    width: 2px;
    height: 100%;
    background-color: #adb5bd;
}

.org-connector-left {
    margin-left: -150px; /* offset to align under IT Fungsional */
}

@media (max-width: 767.98px) {
    .sidebar {
        position: static;
        padding-top: 0;
    }
    .org-level-2 .org-node-group,
    .org-level-3 .org-node-group {
        flex-direction: column;
        align-items: center;
        gap: 1.5rem;
    }
    .org-card {
        min-width: 180px;
    }
    .org-info h6 {
        white-space: normal;
    }
    .org-connector-left {
        margin-left: 0;
    }
    .org-level-3-group {
        margin-left: 0;
    }
}
