/**
 * CommentAce - Comment Editing & Delete Styles
 */

/* Owner actions container */
.cace-comment-owner-actions {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-left: 10px;
}

/* Base button styles */
.cace-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.2s ease;
    background: transparent;
}

/* Edit button */
.cace-btn-edit {
    background: #f0f0f0;
    color: #333;
}

.cace-btn-edit:hover {
    background: #0073aa;
    color: #fff;
}

/* Delete button */
.cace-btn-delete {
    padding: 4px 8px;
    background: transparent;
    color: #999;
}

.cace-btn-delete:hover {
    background: #dc3545;
    color: #fff;
}

/* Icons */
.cace-icon {
    display: inline-block;
    width: 14px;
    height: 14px;
    font-size: 14px;
    line-height: 1;
}

.cace-icon-edit:before {
    content: "✏";
}

.cace-icon-delete:before {
    content: "🗑";
}

/* Editing state */
.cace-editing .comment-content {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 4px;
    margin: 10px 0;
}

.cace-edit-wrapper {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.cace-edit-textarea {
    width: 100%;
    min-height: 100px;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: inherit;
    font-size: inherit;
    line-height: 1.5;
    resize: vertical;
    box-sizing: border-box;
}

.cace-edit-textarea:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 1px #0073aa;
}

.cace-edit-textarea.cace-validation-error {
    border-color: #ff0036;
    box-shadow: 0 0 0 1px #ff0036;
}

.cace-edit-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.cace-edit-save,
.cace-edit-cancel {
    padding: 8px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.cace-edit-save {
    background: #0073aa;
    color: #fff;
}

.cace-edit-save:hover {
    background: #005a87;
}

.cace-edit-save:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.cace-edit-cancel {
    background: #ddd;
    color: #333;
}

.cace-edit-cancel:hover {
    background: #ccc;
}

/* Processing state */
.cace-editing.cace-processing .cace-edit-wrapper {
    opacity: 0.6;
    pointer-events: none;
}

.cace-editing.cace-processing .cace-edit-save:before {
    display: inline-block;
    margin-right: 6px;
    font: 14px/1 cace;
    vertical-align: middle;
    content: "\e103";
    -webkit-animation: cace-anim-spin 2s infinite linear;
    animation: cace-anim-spin 2s infinite linear;
}