/* Unified checkbox visuals for list-management tables.
   Scope intentionally limited to management pages to avoid auth/form checkboxes. */

:root {
    --table-list-checkbox-color: var(--color-primary, #F0B90B);
    --table-list-checkbox-ring: rgba(240, 185, 11, 0.2);
    --table-list-checkbox-ring-hover: rgba(240, 185, 11, 0.1);
}

#complaint-manage-content #complaint-select-all,
#complaint-manage-content .complaint-case-checkbox,
#cases-12315-content #select-all-12315,
#cases-12315-content .case-12315-checkbox,
#cases-12315-content .case-checkbox-12315,
#admin-lawsuit-manage-content #select-all-admin-lawsuit,
#admin-lawsuit-manage-content .lawsuit-manage-checkbox,
#civil-lawsuit-manage-content #select-all-civil-lawsuit,
#civil-lawsuit-manage-content .lawsuit-manage-checkbox,
#info-disclosure-manage-content #id-select-all,
#info-disclosure-manage-content .info-disclosure-select-checkbox,
#recon-platform-content #select-all-recon,
#recon-platform-content .recon-case-checkbox,
#recon-offline-content #recon-offline-select-all,
#recon-offline-content .recon-offline-row-checkbox,
#accounting-content #accounting-select-all,
#accounting-content .accounting-row-checkbox,
.select-all-checkbox,
.row-checkbox {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    width: 16px;
    height: 16px;
    border: 2px solid var(--text-tertiary, #848E9C);
    border-radius: 3px;
    background: var(--bg-card, #FFFFFF);
    cursor: pointer;
    position: relative;
    transition: all 0.2s ease;
    margin: 0;
    vertical-align: middle;
    flex-shrink: 0;
    accent-color: var(--table-list-checkbox-color);
}

#complaint-manage-content #complaint-select-all:hover,
#complaint-manage-content .complaint-case-checkbox:hover,
#cases-12315-content #select-all-12315:hover,
#cases-12315-content .case-12315-checkbox:hover,
#cases-12315-content .case-checkbox-12315:hover,
#admin-lawsuit-manage-content #select-all-admin-lawsuit:hover,
#admin-lawsuit-manage-content .lawsuit-manage-checkbox:hover,
#civil-lawsuit-manage-content #select-all-civil-lawsuit:hover,
#civil-lawsuit-manage-content .lawsuit-manage-checkbox:hover,
#info-disclosure-manage-content #id-select-all:hover,
#info-disclosure-manage-content .info-disclosure-select-checkbox:hover,
#recon-platform-content #select-all-recon:hover,
#recon-platform-content .recon-case-checkbox:hover,
#recon-offline-content #recon-offline-select-all:hover,
#recon-offline-content .recon-offline-row-checkbox:hover,
#accounting-content #accounting-select-all:hover,
#accounting-content .accounting-row-checkbox:hover,
.select-all-checkbox:hover,
.row-checkbox:hover {
    border-color: var(--table-list-checkbox-color);
    box-shadow: 0 0 0 2px var(--table-list-checkbox-ring-hover);
}

#complaint-manage-content #complaint-select-all:checked,
#complaint-manage-content .complaint-case-checkbox:checked,
#cases-12315-content #select-all-12315:checked,
#cases-12315-content .case-12315-checkbox:checked,
#cases-12315-content .case-checkbox-12315:checked,
#admin-lawsuit-manage-content #select-all-admin-lawsuit:checked,
#admin-lawsuit-manage-content .lawsuit-manage-checkbox:checked,
#civil-lawsuit-manage-content #select-all-civil-lawsuit:checked,
#civil-lawsuit-manage-content .lawsuit-manage-checkbox:checked,
#info-disclosure-manage-content #id-select-all:checked,
#info-disclosure-manage-content .info-disclosure-select-checkbox:checked,
#recon-platform-content #select-all-recon:checked,
#recon-platform-content .recon-case-checkbox:checked,
#recon-offline-content #recon-offline-select-all:checked,
#recon-offline-content .recon-offline-row-checkbox:checked,
#accounting-content #accounting-select-all:checked,
#accounting-content .accounting-row-checkbox:checked,
.select-all-checkbox:checked,
.row-checkbox:checked {
    background: var(--table-list-checkbox-color);
    border-color: var(--table-list-checkbox-color);
    box-shadow: 0 0 0 2px var(--table-list-checkbox-ring);
}

#complaint-manage-content #complaint-select-all:checked::after,
#complaint-manage-content .complaint-case-checkbox:checked::after,
#cases-12315-content #select-all-12315:checked::after,
#cases-12315-content .case-12315-checkbox:checked::after,
#cases-12315-content .case-checkbox-12315:checked::after,
#admin-lawsuit-manage-content #select-all-admin-lawsuit:checked::after,
#admin-lawsuit-manage-content .lawsuit-manage-checkbox:checked::after,
#civil-lawsuit-manage-content #select-all-civil-lawsuit:checked::after,
#civil-lawsuit-manage-content .lawsuit-manage-checkbox:checked::after,
#info-disclosure-manage-content #id-select-all:checked::after,
#info-disclosure-manage-content .info-disclosure-select-checkbox:checked::after,
#recon-platform-content #select-all-recon:checked::after,
#recon-platform-content .recon-case-checkbox:checked::after,
#recon-offline-content #recon-offline-select-all:checked::after,
#recon-offline-content .recon-offline-row-checkbox:checked::after,
#accounting-content #accounting-select-all:checked::after,
#accounting-content .accounting-row-checkbox:checked::after,
.select-all-checkbox:checked::after,
.row-checkbox:checked::after {
    content: '';
    position: absolute;
    left: 4.5px;
    top: 1.5px;
    width: 4px;
    height: 8px;
    border: solid #FFFFFF;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* List selection highlight: keep background only, no left stripe */
#complaint-manage-content #complaint-cases-table tbody tr:has(.complaint-case-checkbox:checked),
#complaint-manage-content #complaint-cases-table tbody tr:has(.row-checkbox:checked),
#cases-12315-content #12315-cases-table tbody tr:has(.case-12315-checkbox:checked),
#cases-12315-content #12315-cases-table tbody tr:has(.row-checkbox:checked) {
    background-color: rgba(240, 185, 11, 0.1);
    border-left: 0;
}

#complaint-manage-content #complaint-cases-table tbody tr:has(.complaint-case-checkbox:checked) > td:first-child,
#complaint-manage-content #complaint-cases-table tbody tr:has(.row-checkbox:checked) > td:first-child,
#cases-12315-content #12315-cases-table tbody tr:has(.case-12315-checkbox:checked) > td:first-child,
#cases-12315-content #12315-cases-table tbody tr:has(.row-checkbox:checked) > td:first-child {
    border-left: 0;
    box-shadow: none;
}
