/* ===========================================
   PELAJAR & DISABILITAS LIST SPECIFIC STYLES
   Styles khusus untuk pelajar_list.html dan disabilitas_list.html
   =========================================== */

/* Avatar Small */
.avatar-sm {
    width: 40px !important;
    height: 40px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    border: 2px solid #e0e0e0 !important;
    background-color: #f8f9fa !important;
    flex-shrink: 0 !important;
}

/* Avatar placeholder styling */
.avatar-sm.bg-light {
    background-color: #f8f9fa !important;
    border: 2px solid #dee2e6 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.avatar-sm i {
    color: #6c757d !important;
    font-size: 1.2rem !important;
}

/* Force dark text colors for light theme */
.table {
    color: #212529 !important;
    background-color: #ffffff !important;
}

.table th,
.table td {
    color: #212529 !important;
}

.td-name,
.td-name * {
    color: #212529 !important;
}

.td-name .fw-bold,
.td-name .text-dark,
.td-name div {
    color: #212529 !important;
    font-weight: 600 !important;
}

.td-name .text-muted,
.td-name .small {
    color: #6c757d !important;
}

.td-nik {
    color: #495057 !important;
}

/* Badge overrides for light mode */
.badge-light {
    background: #f8f9fa !important;
    color: #212529 !important;
    border: 1px solid #dee2e6 !important;
}

.td-no .badge,
.td-no .badge-light {
    color: #212529 !important;
    background: #f8f9fa !important;
}

/* Table Column Widths */
.th-checkbox, .td-checkbox {
    width: 40px;
    padding: 0.5rem 0.25rem !important;
}

.th-no, .td-no {
    width: 50px;
    text-align: center;
    padding: 0.5rem 0.25rem !important;
}

.th-name, .td-name {
    min-width: 180px;
    padding: 0.5rem 0.75rem !important;
}

.th-nik, .td-nik {
    width: 130px;
    padding: 0.5rem 0.5rem !important;
    white-space: nowrap;
}

.th-type, .td-type,
.th-age, .td-age,
.th-level, .td-level {
    width: 110px;
    padding: 0.5rem 0.5rem !important;
    text-align: center;
}

.th-severity, .td-severity,
.th-status, .td-status {
    width: 100px;
    padding: 0.5rem 0.5rem !important;
    text-align: center;
}

.th-school, .td-school {
    min-width: 150px;
    padding: 0.5rem 0.75rem !important;
}

.th-action, .td-action {
    width: 120px;
    padding: 0.5rem 0.5rem !important;
    text-align: center;
}

/* ===========================================
   MOBILE RESPONSIVE (max-width: 575.98px)
   =========================================== */
@media (max-width: 575.98px) {
    /* Page header compact */
    .row.mb-4 {
        margin-bottom: 0.75rem !important;
    }
    
    .h3.mb-1 {
        font-size: 1rem !important;
        margin-bottom: 0.25rem !important;
    }
    
    .text-muted.small {
        font-size: 0.7rem !important;
    }
    
    /* Card header compact */
    .card-header {
        padding: 0.5rem 0.75rem !important;
    }
    
    .card-header h6 {
        font-size: 0.85rem !important;
        margin: 0 !important;
    }
    
    /* Card body tighter */
    .card-body {
        padding: 0 !important;
    }
    
    /* Table ultra compact on mobile */
    .table {
        font-size: 0.75rem;
        margin-bottom: 0 !important;
    }
    
    .table th,
    .table td {
        padding: 0.4rem 0.2rem !important;
        vertical-align: middle;
    }
    
    .table th {
        font-size: 0.7rem;
        font-weight: 600;
    }
    
    /* Checkbox column ultra compact */
    .th-checkbox, .td-checkbox {
        width: 32px !important;
        padding: 0.3rem 0.1rem !important;
    }
    
    .td-checkbox .custom-control {
        padding-left: 1.2rem !important;
        min-height: 1rem;
    }
    
    .td-checkbox .custom-control-label::before,
    .td-checkbox .custom-control-label::after {
        width: 0.85rem !important;
        height: 0.85rem !important;
        top: 0 !important;
    }
    
    /* Name column takes most space */
    .th-name, .td-name {
        min-width: 0 !important;
        width: auto !important;
        padding: 0.4rem 0.3rem !important;
    }
    
    /* Action column - wider for 3 buttons */
    .th-action, .td-action {
        width: 80px !important;
        min-width: 80px !important;
        padding: 0.3rem 0.2rem !important;
    }
    
    /* Avatar smaller on mobile - hide on mobile */
    .avatar-sm {
        display: none !important;
    }
    
    /* Badges smaller on mobile */
    .badge-sm {
        font-size: 0.6rem;
        padding: 0.1rem 0.3rem;
    }
    
    /* Mobile action buttons group */
    .btn-group-mobile {
        display: flex !important;
        gap: 0.15rem;
        flex-wrap: nowrap;
    }
    
    /* Button ultra compact */
    .btn-action-mobile {
        padding: 0.15rem 0.25rem !important;
        font-size: 0.65rem !important;
        border-width: 1px;
        min-width: 0 !important;
        flex: 0 0 auto;
    }
    
    .btn-action-mobile i {
        font-size: 0.65rem;
        margin: 0;
    }
    
    /* Button colors for mobile */
    .btn-action-mobile.btn-outline-primary {
        color: #007bff;
        border-color: #007bff;
    }
    
    .btn-action-mobile.btn-outline-primary:hover,
    .btn-action-mobile.btn-outline-primary:active {
        background: #007bff !important;
        color: white !important;
    }
    
    .btn-action-mobile.btn-outline-warning {
        color: #ffc107;
        border-color: #ffc107;
    }
    
    .btn-action-mobile.btn-outline-warning:hover,
    .btn-action-mobile.btn-outline-warning:active {
        background: #ffc107 !important;
        color: #212529 !important;
    }
    
    .btn-action-mobile.btn-outline-danger {
        color: #dc3545;
        border-color: #dc3545;
    }
    
    .btn-action-mobile.btn-outline-danger:hover,
    .btn-action-mobile.btn-outline-danger:active {
        background: #dc3545 !important;
        color: white !important;
    }
    
    /* Text sizes */
    .td-name .fw-bold {
        font-size: 0.8rem;
        line-height: 1.2;
        margin-bottom: 0.1rem;
    }
    
    .td-name .small {
        font-size: 0.68rem;
        line-height: 1.3;
        margin-bottom: 0.05rem;
    }
    
    /* Remove icons on mobile for space */
    .td-name .small i {
        display: none;
    }
    
    /* Spacing adjustments */
    .td-name .mt-1 {
        margin-top: 0.15rem !important;
    }
    
    .td-name .me-1, .td-name .mr-1 {
        margin-right: 0.2rem !important;
    }
    
    .td-name .ms-1, .td-name .ml-1 {
        margin-left: 0.2rem !important;
    }
    
    .td-name .ms-2, .td-name .ml-2 {
        margin-left: 0.4rem !important;
    }
    
    /* Tighter line spacing */
    .td-name > div {
        line-height: 1.2;
    }
    
    /* Info text compact */
    .mt-3 .text-muted {
        font-size: 0.7rem !important;
    }
    
    /* Filter card compact */
    .filter-card {
        margin-bottom: 0.75rem !important;
    }
    
    .filter-card .card-header {
        padding: 0.5rem 0.75rem !important;
    }
    
    .filter-card .card-body {
        padding: 0.75rem !important;
    }
}

/* ===========================================
   TABLET (576px - 767.98px)
   =========================================== */
@media (min-width: 576px) and (max-width: 767.98px) {
    .avatar-sm {
        width: 32px;
        height: 32px;
    }
    
    .th-name, .td-name {
        min-width: 160px;
    }
    
    .table {
        font-size: 0.85rem;
    }
}

/* ===========================================
   DESKTOP (min-width: 768px)
   =========================================== */
@media (min-width: 768px) {
    .avatar-sm {
        width: 35px;
        height: 35px;
    }
    
    .table {
        font-size: 0.875rem;
    }
    
    /* Show avatar on desktop */
    .avatar-sm {
        display: inline-block !important;
    }
    
    /* Show icons on desktop */
    .td-name .small i {
        display: inline-block;
    }
    
    /* Desktop action buttons - compact and clean */
    .td-action {
        white-space: nowrap;
    }
    
    .td-action > div {
        display: inline-flex;
        gap: 0.25rem;
    }
    
    .td-action .btn {
        padding: 0.25rem 0.5rem !important;
        font-size: 0.875rem !important;
        margin: 0;
        display: inline-flex;
        align-items: center;
    }
    
    .td-action .btn i {
        font-size: 0.875rem;
        margin: 0;
    }
    
    .td-action .btn-sm {
        padding: 0.25rem 0.5rem !important;
        font-size: 0.875rem !important;
    }
    
    .td-action .btn-outline-primary {
        border-color: #007bff;
        color: #007bff;
    }
    
    .td-action .btn-outline-primary:hover {
        background-color: #007bff;
        color: white;
    }
    
    .td-action .btn-outline-warning {
        border-color: #ffc107;
        color: #856404;
    }
    
    .td-action .btn-outline-warning:hover {
        background-color: #ffc107;
        color: #212529;
    }
    
    .td-action .btn-outline-danger {
        border-color: #dc3545;
        color: #dc3545;
    }
    
    .td-action .btn-outline-danger:hover {
        background-color: #dc3545;
        color: white;
    }
    
    /* Hide mobile button group on desktop */
    .btn-group-mobile {
        display: none !important;
    }
}

/* ===========================================
   END OF PELAJAR & DISABILITAS CSS
   =========================================== */

