/**
 * TopPicks – Editor Styles
 * Gutenberg editor overrides and UI for the block.
 */

/* Make the block selectable and visually clear in editor */
.wp-block-toppicks-picks-section {
    position: relative;
}

/* Card controls in editor */
.tp-editor-card-controls {
    display: flex;
    gap: 4px;
    position: absolute;
    top: 6px;
    right: 6px;
    opacity: 0;
    transition: opacity 0.15s ease;
    z-index: 2;
}
.tp-card:hover .tp-editor-card-controls {
    opacity: 1;
}

.tp-editor-card-controls button {
    background: #1e1e1e;
    color: #fff;
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    line-height: 1;
    padding: 0;
    transition: background 0.15s ease;
}
.tp-editor-card-controls button:hover {
    background: #d63638;
}
.tp-editor-card-controls button.tp-move-btn:hover {
    background: #0E7AE5;
}

/* Inline editable fields in editor */
.tp-card [contenteditable="true"],
.tp-card input[type="text"],
.tp-card textarea {
    border: 1px dashed transparent;
    background: transparent;
    transition: border-color 0.15s ease;
}
.tp-card [contenteditable="true"]:focus,
.tp-card input[type="text"]:focus,
.tp-card textarea:focus {
    border-color: #0E7AE5;
    outline: none;
    border-radius: 3px;
}

/* Add card button */
.tp-editor-add-card {
    border: 2px dashed var(--tp-card-border, #E5E7EB);
    border-radius: var(--tp-radius-card, 10px);
    padding: 16px;
    text-align: center;
    cursor: pointer;
    color: var(--tp-text-muted, #6B7280);
    font-size: 13px;
    font-weight: 600;
    transition: border-color 0.2s ease, color 0.2s ease;
    background: transparent;
    width: 100%;
    font-family: inherit;
}
.tp-editor-add-card:hover {
    border-color: #0E7AE5;
    color: #0E7AE5;
}
.tp-editor-add-card.tp-disabled {
    opacity: 0.4;
    cursor: not-allowed;
    pointer-events: none;
}

/* Free limit notice */
.tp-free-limit-notice {
    font-size: 11px;
    color: #9CA3AF;
    text-align: center;
    margin-top: 8px;
    font-style: italic;
}

/* Inspector panel card list */
.tp-inspector-card-item {
    padding: 10px 12px;
    background: #f0f0f0;
    border-radius: 6px;
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.tp-inspector-card-item__name {
    font-size: 13px;
    font-weight: 600;
    color: #1e1e1e;
}
.tp-inspector-card-item__badge {
    font-size: 10px;
    color: #6B7280;
}
