.ocr-workspace-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-bottom: 10px;
    padding: 8px;
    border: 1px solid #d8dfe8;
    border-radius: 8px;
    background: #f7f9fc;
}

.ocr-toolbar-search {
    flex: 1 1 320px;
    min-width: 220px;
    position: relative;
}

.ocr-toolbar-search i {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: #5b6b7a;
    font-size: 12px;
}

.ocr-toolbar-search input {
    width: 100%;
    padding: 7px 10px 7px 30px;
    border: 1px solid #cfd8e3;
    border-radius: 6px;
    background: #fff;
}

#process-review-low-confidence.active {
    background: #f8b300;
    color: #1d1d1d;
    border-color: #f8b300;
}

.process-active-field-tracker {
    margin-top: 8px;
    padding: 6px 10px;
    border-radius: 6px;
    border: 1px solid #d9e7ff;
    background: #eef5ff;
    color: #114889;
    font-size: 12px;
    font-weight: 600;
}

.process-ocr-overlay {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    z-index: 4;
    pointer-events: none;
}

.process-ocr-region {
    position: absolute;
    border: 1px solid rgba(26, 115, 232, 0.55);
    background: rgba(255, 235, 59, 0.24);
    box-shadow: 0 0 0 rgba(26, 115, 232, 0);
    border-radius: 3px;
    padding: 0;
    pointer-events: auto;
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.25s ease, opacity 0.2s ease;
}

.process-ocr-region.region-line-item {
    background: rgba(255, 224, 130, 0.25);
    border-color: rgba(22, 117, 214, 0.5);
}

.process-ocr-region.region-search {
    background: rgba(255, 193, 7, 0.35);
    border-color: rgba(255, 152, 0, 0.85);
}

.process-ocr-region.is-hover {
    transform: scale(1.01);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.22);
}

.process-ocr-region.is-active {
    border-color: #0f5dc9;
    background: rgba(255, 235, 59, 0.38);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.3);
}

.process-ocr-region.is-pulse {
    animation: processOcrPulse 0.95s ease-out;
}

@keyframes processOcrPulse {
    0% { box-shadow: 0 0 0 0 rgba(15, 93, 201, 0.42); }
    100% { box-shadow: 0 0 0 12px rgba(15, 93, 201, 0); }
}

.default-field.ocr-high-confidence {
    border-left: 4px solid #1f9d69 !important;
}

.default-field.ocr-medium-confidence {
    border-left: 4px solid #e0a000 !important;
}

.default-field.ocr-low-confidence {
    border-left: 4px solid #d94841 !important;
    background: rgba(217, 72, 65, 0.05) !important;
}

.default-field.is-confidence-muted {
    opacity: 0.45;
}

.default-field.duplicate-value {
    border-color: #e08a00 !important;
    box-shadow: 0 0 0 0.15rem rgba(224, 138, 0, 0.2) !important;
}

.ocr-confidence-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-left: 8px;
    padding: 2px 7px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    vertical-align: middle;
}

.ocr-confidence-chip.high {
    color: #0f6a44;
    background: #d8f3e5;
}

.ocr-confidence-chip.medium {
    color: #7b5b00;
    background: #fff4cc;
}

.ocr-confidence-chip.low {
    color: #8c251f;
    background: #ffe1de;
}

.possible-match-wrapper {
    margin-top: 6px;
}

.possible-match-label {
    display: block;
    margin-bottom: 4px;
    font-size: 11px;
    font-weight: 600;
    color: #4b5c6d;
}

.duplicate-warning {
    display: block;
    margin-top: 4px;
    font-size: 11px;
}

.process-validation-chip {
    margin-top: 6px;
    display: inline-flex;
    align-items: center;
    padding: 3px 8px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
}

.process-validation-chip.warn {
    color: #8f4200;
    background: #ffe7cf;
}

.process-validation-chip.hint {
    color: #13547f;
    background: #deefff;
}

.default-field.field-validation-warning {
    border-color: #f39a3b !important;
}

.cell-active {
    outline: 2px solid #2a78df;
    outline-offset: -2px;
    background: rgba(42, 120, 223, 0.1) !important;
}

@media (max-width: 768px) {
    .ocr-workspace-toolbar {
        gap: 6px;
    }

    .ocr-toolbar-search {
        flex-basis: 100%;
    }

    .process-active-field-tracker {
        font-size: 11px;
    }
}
