/* Email Test Section */
.email-test-section {
    margin-bottom: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}

.cleanup-status {
    color: #50575e;
    font-size: 13px;
}

/* Message alignment */
.test-email-message {
    order: 1;
    font-size: 14px;
}

.test-email-message.success {
    color: #48bb78;
}

.test-email-message.error {
    color: #dc3232;
}

/* Email Log Table */
.divewp-email-log-table.divewp-table {
    table-layout: fixed;
    width: 100%;
    border-collapse: separate;
    background: #fff;
    margin: 0;
}

/* Column widths */
.divewp-email-log-table th:nth-child(1),
.divewp-email-log-table td:nth-child(1) {
    width: 8%;
    /* Date column */
}

.divewp-email-log-table th:nth-child(2),
.divewp-email-log-table td:nth-child(2) {
    width: 8%;
    /* Status column */
}

.divewp-email-log-table th:nth-child(3),
.divewp-email-log-table td:nth-child(3) {
    width: 25%;
    /* Initiator column */
    word-wrap: break-word;
    white-space: normal;
}

.divewp-email-log-table th:nth-child(4),
.divewp-email-log-table td:nth-child(4) {
    width: 14%;
    /* From column */
}

.divewp-email-log-table th:nth-child(5),
.divewp-email-log-table td:nth-child(5) {
    width: 29%;
    /* To column */
}

.divewp-email-log-table th:nth-child(6),
.divewp-email-log-table td:nth-child(6) {
    width: 16%;
    /* Subject column */
    word-wrap: break-word;
    white-space: normal;
    padding-right: 16px;
}

/* Table cell styles */
.divewp-email-log-table th,
.divewp-email-log-table td {
    padding: 5px;
    text-align: left;
    border-bottom: 1px solid #edf2f7;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Table container */
.divewp-table-container {
    width: 100%;
    overflow-x: hidden;
}

/* Test Email Button - matching User Events button style */
.divewp-header-actions #divewp-send-test-email {
    background-color: #4299e1;
    color: #fff;
    border-color: #4299e1;
    border-radius: 6px;
    padding: 4px 12px 4px 8px;
    height: auto;
    min-height: 30px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease;
    display: flex;
    align-items: center;
    gap: 4px;
}

.divewp-header-actions #divewp-send-test-email::before {
    content: "\f465";
    /* dashicons-email */
    font-family: dashicons;
    font-size: 16px;
    line-height: 1;
    display: inline-block;
    vertical-align: middle;
}

.divewp-header-actions #divewp-send-test-email:hover {
    background-color: #3182ce;
    border-color: #3182ce;
}

.divewp-header-actions #divewp-send-test-email:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Actions container */
.divewp-actions {
    order: 2;
}

/* Buttons - Match User Events Styling */
.divewp-action-button {
    margin: 0 8px 8px 0;
    padding: 8px 14px;
    border-radius: 3px;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
}

.divewp-action-button .dashicons {
    margin-right: 6px;
    font-size: 16px;
    width: auto;
    height: auto;
}

.divewp-refresh-button {
    background: #f0f6fc;
    border: 1px solid #c3d4e3;
    color: #2271b1;
}

.divewp-refresh-button::before {
    content: "\f463"; /* dashicons-update */
    font-family: dashicons;
    margin-right: 6px;
}

.divewp-refresh-button:hover {
    background: #e1e9f1;
    border-color: #a8b9c8;
}

.divewp-delete-button {
    background: #f8ebeb;
    border: 1px solid #e0b4b4;
    color: #cc1818;
}

.divewp-delete-button::before {
    content: "\f182"; /* dashicons-trash */
    font-family: dashicons;
    margin-right: 6px;
}

.divewp-delete-button:hover {
    background: #f5e0e0;
    border-color: #d99494;
}

.divewp-test-button {
    background: #e6f4e9;
    border: 1px solid #b8e0be;
    color: #1a743b;
}

.divewp-test-button:hover {
    background: #d4ebd9;
    border-color: #9dccaa;
}

/* Loading state - matches user events */
.divewp-action-button.loading {
    pointer-events: none;
    opacity: 0.7;
}

.divewp-action-button.loading::before {
    content: "\f463"; /* dashicons-update */
    font-family: dashicons;
    animation: divewp-spin 1s linear infinite;
    margin-right: 6px;
}

/* Hide original dashicon when loading */
.divewp-action-button.loading .dashicons {
    display: none;
}