       .cert-member-page {
            width: 100%;
            margin: 32px auto 60px;
            padding: 0 24px;
        }

        .cert-member-card {
            background: #ffffff;
            border: 1px solid #e6e9ef;
            border-radius: 16px;
            box-shadow: 0 12px 35px rgba(15, 23, 42, 0.06);
            overflow: hidden;
        }

        .cert-members-header {
            display: flex;
            justify-content: space-between;
            gap: 20px;
            padding: 26px 28px;
            border-bottom: 1px solid #edf0f5;
            align-items: center;
            background: #fafbfc;
        }

        .cert-members-header h2 {
            margin: 0;
            font-size: 24px;
            font-weight: 800;
            color: #0f172a;
        }

        .cert-members-header p {
            margin: 6px 0 0;
            color: #64748b;
            font-size: 14px;
        }

        .cert-members-search {
            display: flex;
            gap: 10px;
            min-width: 730px;
        }

        .cert-members-search input {
            width: 100%;
            border: 1px solid #d9e0ea;
            border-radius: 12px;
            padding: 12px 14px;
            outline: none;
        }

        .cert-members-search input:focus {
            border-color: #2563eb;
            box-shadow: 0 0 0 4px rgba(37, 99, 235, .12);
        }

        .cert-members-search button,
        .cert-member-edit-btn,
        .cert-save-btn,
        .cert-load-more-btn {
            border: 0;
            border-radius: 12px;
            padding: 11px 16px;
            background: #2563eb;
            color: #fff;
            font-weight: 700;
            display: inline-flex;
            align-items: center;
            gap: 6px;
            cursor: pointer;
            white-space: nowrap;
        }

        .cert-members-search button:hover,
        .cert-save-btn:hover,
        .cert-load-more-btn:hover {
            background: #1d4ed8;
        }

        .cert-member-edit-btn {
            background: #eef4ff;
            color: #1d4ed8;
        }

        .cert-member-edit-btn:hover {
            background: #dbeafe;
        }

        .cert-row-actions {
            display: flex;
            justify-content: flex-end;
            align-items: center;
            gap: 8px;
        }

        .cert-member-history-btn {
            border: 0;
            border-radius: 12px;
            padding: 11px 16px;
            background: #f8fafc;
            color: #334155;
            font-weight: 800;
            display: inline-flex;
            align-items: center;
            gap: 6px;
            cursor: pointer;
            white-space: nowrap;
        }

        .cert-member-history-btn:hover {
            background: #e2e8f0;
        }

        .cert-members-list-wrap {
            width: 100%;
            overflow-x: auto;
        }

        .cert-members-table {
            width: 100%;
            border-collapse: collapse;
        }

        .cert-members-table th,
        .cert-members-table td {
            padding: 14px 18px;
            border-bottom: 1px solid #eef2f7;
            text-align: left;
            vertical-align: middle;
            font-size: 14px;
        }

        .cert-members-table th {
            color: #475569;
            font-size: 13px;
            background: #fafbfc;
            font-weight: 800;
        }

        .cert-members-table td {
            color: #0f172a;
        }

        .cert-list-footer {
            display: flex;
            justify-content: center;
            padding: 22px 20px 28px;
        }

        .cert-load-more-btn {
            background: #eef4ff;
            color: #1d4ed8;
        }

        .cert-load-more-btn:hover {
            background: #dbeafe;
        }

        .cert-page-message {
            padding: 24px;
            text-align: center;
            color: #64748b;
        }

        .cert-page-message.error {
            color: #dc2626;
        }

        .cert-modal-backdrop {
            position: fixed;
            inset: 0;
            background: rgba(15, 23, 42, 0.55);
            z-index: 99999;
            align-items: center;
            justify-content: center;
            padding: 24px;
        }

        .cert-edit-modal {
            width: 100%;
            max-width: 920px;
            max-height: 92vh;
            background: #fff;
            border-radius: 18px;
            box-shadow: 0 30px 90px rgba(15, 23, 42, 0.35);
            overflow: hidden;
            display: flex;
            flex-direction: column;
        }

        .cert-edit-modal-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 20px 24px;
            border-bottom: 1px solid #edf0f5;
            background: #fafbfc;
        }

        .cert-edit-modal-header h3 {
            margin: 0;
            font-size: 20px;
            font-weight: 800;
            color: #0f172a;
        }

        .cert-edit-modal-header button {
            border: 0;
            background: #f1f5f9;
            border-radius: 10px;
            padding: 8px;
            cursor: pointer;
            color: #334155;
        }

        #certMemberEditBody {
            padding: 24px;
            overflow-y: auto;
        }

        .cert-form-grid {
            display: grid;
            grid-template-columns: repeat(2, minmax(0, 1fr));
            gap: 16px;
        }

        .cert-form-grid label {
            display: flex;
            flex-direction: column;
            gap: 7px;
            font-weight: 700;
            color: #334155;
            font-size: 13px;
        }

        .cert-form-grid input,
        .cert-form-grid select,
        .cert-form-grid textarea {
            border: 1px solid #d9e0ea;
            border-radius: 12px;
            padding: 12px 14px;
            font-weight: 500;
            outline: none;
        }

        .cert-form-grid input:focus,
        .cert-form-grid select:focus,
        .cert-form-grid textarea:focus {
            border-color: #2563eb;
            box-shadow: 0 0 0 4px rgba(37, 99, 235, .12);
        }

        .cert-form-grid textarea {
            min-height: 90px;
            resize: vertical;
        }

        .cert-form-full {
            grid-column: 1 / -1;
        }

        .cert-modal-actions {
            display: flex;
            justify-content: flex-end;
            gap: 10px;
            margin-top: 22px;
        }

        .cert-cancel-btn {
            border: 0;
            border-radius: 12px;
            padding: 11px 16px;
            background: #e2e8f0;
            color: #334155;
            font-weight: 700;
            cursor: pointer;
        }

        .cert-cancel-btn:hover {
            background: #cbd5e1;
        }

        .cert-history-modal {
            width: 100%;
            max-width: 1280px;
            max-height: 90vh;
            background: #ffffff;
            border-radius: 18px;
            box-shadow: 0 30px 90px rgba(15, 23, 42, 0.35);
            overflow: hidden;
            display: flex;
            flex-direction: column;
        }

        .cert-history-modal-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            gap: 18px;
            padding: 20px 24px;
            border-bottom: 1px solid #edf0f5;
            background: #fafbfc;
        }

        .cert-history-modal-header h3 {
            margin: 0;
            color: #0f172a;
            font-size: 20px;
            font-weight: 900;
        }

        .cert-history-modal-header p {
            margin: 5px 0 0;
            color: #64748b;
            font-size: 13px;
        }

        .cert-history-modal-header button {
            border: 0;
            background: #f1f5f9;
            border-radius: 10px;
            padding: 8px;
            cursor: pointer;
            color: #334155;
        }

        .cert-history-modal-header button:hover {
            background: #e2e8f0;
        }

        #certMemberHistoryBody {
            padding: 24px;
            overflow-y: auto;
        }

        .cert-history-table-wrap {
            width: 100%;
            overflow-x: auto;
            border: 1px solid #edf0f5;
            border-radius: 14px;
            background: #fff;
        }

        .cert-history-table {
            width: 100%;
            border-collapse: collapse;
        }

        .cert-history-table th,
        .cert-history-table td {
            padding: 13px 15px;
            border-bottom: 1px solid #eef2f7;
            text-align: left;
            vertical-align: middle;
            font-size: 13px;
            color: #0f172a;
        }

        .cert-history-table th {
            background: #fafbfc;
            color: #475569;
            font-weight: 900;
        }

        .cert-history-table tr:last-child td {
            border-bottom: 0;
        }

        .cert-history-empty {
            padding: 28px;
            text-align: center;
            color: #64748b;
            border: 1px dashed #cbd5e1;
            border-radius: 14px;
            background: #f8fafc;
        }

        @media (max-width: 800px) {
            .cert-member-page {
                padding: 0 14px;
                margin-top: 20px;
            }

            .cert-members-header {
                flex-direction: column;
                align-items: stretch;
            }

            .cert-members-search {
                min-width: 0;
                flex-direction: column;
            }

            .cert-form-grid {
                grid-template-columns: 1fr;
            }

            .cert-row-actions {
                flex-direction: column;
                align-items: flex-end;
            }

            .cert-member-history-btn,
            .cert-member-edit-btn {
                width: 100%;
                justify-content: center;
            }

            .cert-history-modal {
                max-height: 92vh;
            }
        }


        .cert-disabled-input {
    background: #f8fafc !important;
    color: #64748b !important;
    cursor: not-allowed !important;
}
.cert-member-status-cell {
    display: flex;
    flex-direction: column;
    gap: 7px;
    min-width: 135px;
}

.cert-member-status-badge {
    width: fit-content;
    min-width: 98px;
    min-height: 30px;
    padding: 6px 12px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    font-size: 12px;
    font-weight: 900;
    line-height: 1;
    white-space: nowrap;
}

.cert-member-status-badge::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 999px;
    flex: 0 0 auto;
}

.cert-member-status-badge.status-active {
    color: #166534;
    background: #dcfce7;
    border: 1px solid #86efac;
}

.cert-member-status-badge.status-active::before {
    background: #16a34a;
    box-shadow: 0 0 0 4px rgba(22, 163, 74, .12);
}

.cert-member-status-badge.status-inactive {
    color: #991b1b;
    background: #fee2e2;
    border: 1px solid #fca5a5;
}

.cert-member-status-badge.status-inactive::before {
    background: #dc2626;
    box-shadow: 0 0 0 4px rgba(220, 38, 38, .12);
}

.cert-member-status-badge.status-pending {
    color: #92400e;
    background: #fef3c7;
    border: 1px solid #fcd34d;
}

.cert-member-status-badge.status-pending::before {
    background: #f59e0b;
    box-shadow: 0 0 0 4px rgba(245, 158, 11, .14);
}

.cert-member-status-dates {
    display: flex;
    flex-direction: column;
    gap: 2px;
    color: #64748b;
    font-size: 12px;
    line-height: 1.35;
}

.cert-member-status-dates small {
    color: #94a3b8;
    font-weight: 700;
    margin-right: 4px;
}

.cert-member-status-dates b {
    color: #334155;
    font-weight: 800;
}

.cert-doc-actions {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex: 0 0 auto;
}

.cert-doc-delete-btn {
    min-height: 36px;
    padding: 8px 12px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #991b1b;
    background: #fee2e2;
    border: 1px solid #fca5a5;
    font-size: 13px;
    font-weight: 900;
    cursor: pointer;
    white-space: nowrap;
}

.cert-doc-delete-btn:hover {
    color: #7f1d1d;
    background: #fecaca;
}

.cert-doc-empty-message {
    padding: 12px;
    border-radius: 14px;
    background: #ffffff;
    border: 1px dashed #cbd5e1;
    color: #64748b;
    font-size: 13px;
    font-weight: 800;
}

.cert-list-doc-cell {
    min-width: 105px;
}

.cert-list-doc-view-btn {
    min-height: 32px;
    padding: 7px 11px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #1d4ed8;
    background: #eef4ff;
    border: 1px solid #bfdbfe;
    font-size: 12px;
    font-weight: 900;
    text-decoration: none;
    white-space: nowrap;
}

.cert-list-doc-view-btn:hover {
    color: #1e40af;
    background: #dbeafe;
    text-decoration: none;
}

.cert-list-doc-empty {
    color: #cbd5e1;
    font-size: 16px;
    font-weight: 900;
}

.cert-doc-hidden {
    display: none !important;
}


.cert-export-backdrop {
    position: fixed;
    inset: 0;
    z-index: 99999;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(15, 23, 42, 0.55);
    backdrop-filter: blur(3px);
}

.cert-export-modal {
    width: min(620px, calc(100vw - 32px));
    background: #ffffff;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 24px 80px rgba(15, 23, 42, 0.28);
    border: 1px solid #e2e8f0;
}

.cert-export-modal-header {
    min-height: 96px;
    padding: 24px 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    border-bottom: 1px solid #e5e7eb;
    background: #ffffff;
}

.cert-export-modal-header h3 {
    margin: 0;
    color: #0f172a;
    font-size: 24px;
    font-weight: 900;
}

.cert-export-modal-header p {
    margin: 6px 0 0;
    color: #64748b;
    font-size: 13px;
    font-weight: 700;
}

.cert-export-close-btn {
    width: 48px;
    height: 48px;
    border: 0;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #f8fafc;
    color: #334155;
    cursor: pointer;
}

.cert-export-form {
    padding: 24px 28px 28px;
}

.cert-export-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.cert-export-field label {
    display: block;
    margin-bottom: 8px;
    color: #334155;
    font-size: 13px;
    font-weight: 900;
}

.cert-export-field input {
    width: 100%;
    height: 52px;
    padding: 0 14px;
    border-radius: 14px;
    border: 1px solid #cbd5e1;
    background: #ffffff;
    color: #0f172a;
    font-size: 15px;
    font-weight: 800;
}

.cert-export-actions {
    margin-top: 26px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
}

.cert-export-open-btn {
    min-height: 46px;
    padding: 0 20px;
    border-radius: 12px;
    border: 0;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #1d4ed8;
    color: #ffffff;
    font-weight: 900;
    cursor: pointer;
}

@media (max-width: 700px) {
    .cert-export-grid {
        grid-template-columns: 1fr;
    }

    .cert-export-actions {
        flex-direction: column-reverse;
        align-items: stretch;
    }

    .cert-export-actions button {
        width: 100%;
    }
}