/* Rule Styles */
.vfe-rule-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.vfe-rule-card {
    background: #fff;
    border: 1px solid var(--vfe-border);
    border-radius: var(--vfe-radius-sm);
    padding: 16px;
    box-shadow: var(--vfe-shadow-sm);
}

.vfe-rule-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.vfe-rule-conditions {
    background: var(--vfe-bg);
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 12px;
}

.vfe-condition-row {
    display: flex;
    gap: 8px;
    margin-bottom: 8px;
    align-items: center;
}

.vfe-rule-actions {
    background: #f0fdf4;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #dcfce7;
}

.vfe-input-simple {
    border: 1px solid #e2e8f0;
    /* Visible border */
    background: #fff;
    border-radius: 6px;
    font-weight: 600;
    font-size: 16px;
    padding: 6px 10px;
    width: 60%;
    transition: all 0.2s ease;
}

.vfe-input-simple:focus {
    border-color: #ff5a5f;
    outline: none;
    box-shadow: 0 0 0 3px rgba(255, 90, 95, 0.1);
}

.vfe-rule-title-group {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.vfe-rule-summary-badge {
    background: #ecfdf5;
    color: #059669;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 700;
    border: 1px solid #d1fae5;
    white-space: nowrap;
}

.vfe-btn-icon {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 18px;
    padding: 4px;
    border-radius: 4px;
    transition: background 0.2s;
}

.vfe-btn-icon:hover {
    background: #fee2e2;
    color: #ef4444;
}

/* Global Input Safety */
.vfe-rule-card input,
.vfe-rule-card select {
    box-sizing: border-box;
    max-width: 100%;
}

.vfe-select-small,
.vfe-input-small {
    padding: 8px 12px;
    border: 1px solid var(--vfe-border);
    border-radius: 6px;
    font-size: 14px;
    background: #fff;
    /* Responsive width */
    min-width: 0;
}

/* Flex Container Safety */
.vfe-condition-row,
.vfe-flex-gap {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
    /* Wichtig: Umbruch erlauben */
}

/* Make inputs grow to fill available space but wrap if needed */
.vfe-flex-gap input,
.vfe-flex-gap select {
    flex: 1;
    min-width: 120px;
    /* Mindestbreite */
}

.vfe-full-width {
    width: 100%;
    margin-top: 12px;
    justify-content: center;
}