/*
 * Review Editor — side-by-side translation diff workspace
 * assets/css/review-editor.css
 */

/* ===== Layout ===== */
.aitrfoel-review-wrap {
    max-width: 1320px;
}

.aitrfoel-review-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin: 16px 0 20px;
    padding: 16px 20px;
    background: #fff;
    border: 1px solid #e6e8ee;
    border-radius: 10px;
}

.aitrfoel-review-title-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.aitrfoel-review-page-title {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    color: #0e1116;
    line-height: 1.3;
}

.aitrfoel-review-lang-badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    background: #eef2fe;
    color: #1447e6;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.aitrfoel-review-header-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* ===== Notice ===== */
.aitrfoel-review-notice {
    margin: 0 0 16px;
    padding: 10px 16px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
}

.aitrfoel-review-notice.is-success {
    background: #e6f7ef;
    color: #065f46;
    border: 1px solid #bbf7d0;
}

.aitrfoel-review-notice.is-error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

/* ===== Table ===== */
.aitrfoel-review-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border: 1px solid #e6e8ee;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,.06);
    table-layout: fixed;
}

.aitrfoel-review-table thead th {
    background: #f8f9fb;
    padding: 12px 16px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #6b7280;
    border-bottom: 1px solid #e6e8ee;
    text-align: left;
}

.aitrfoel-review-col-num {
    width: 48px;
    text-align: center !important;
}

.aitrfoel-review-col-source,
.aitrfoel-review-col-trans {
    width: calc(50% - 24px);
}

.aitrfoel-review-table tbody tr {
    border-bottom: 1px solid #f0f1f4;
    transition: background 0.12s;
}

.aitrfoel-review-table tbody tr:last-child {
    border-bottom: none;
}

.aitrfoel-review-table tbody tr:hover {
    background: #fafafa;
}

.aitrfoel-review-table tbody tr.is-editing {
    background: #fafcff;
}

.aitrfoel-review-table td {
    padding: 12px 16px;
    vertical-align: top;
    font-size: 14px;
    line-height: 1.55;
    color: #0e1116;
}

.aitrfoel-review-col-num {
    color: #9ca3af;
    font-size: 12px;
    text-align: center;
    padding-top: 16px;
}

.aitrfoel-review-source {
    color: #374151;
    border-right: 1px solid #e6e8ee;
}

/* ===== Editable translation cell ===== */
.aitrfoel-review-display {
    cursor: pointer;
    min-height: 24px;
    border-radius: 4px;
    padding: 2px 4px;
    margin: -2px -4px;
    transition: background 0.1s;
}

.aitrfoel-review-display:hover {
    background: #eef2fe;
}

.aitrfoel-review-ta {
    width: 100%;
    box-sizing: border-box;
    padding: 8px 10px;
    font-size: 14px;
    line-height: 1.5;
    font-family: inherit;
    border: 1.5px solid #1447e6;
    border-radius: 6px;
    resize: vertical;
    outline: none;
    color: #0e1116;
    background: #fff;
    transition: box-shadow 0.15s;
}

.aitrfoel-review-ta:focus {
    box-shadow: 0 0 0 3px rgba(20, 71, 230, 0.15);
}

.aitrfoel-review-edit-actions {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}

/* Saved flash */
@keyframes aitrfoel-saved-flash {
    0%   { background: #e6f7ef; }
    100% { background: transparent; }
}

.aitrfoel-review-row.just-saved td {
    animation: aitrfoel-saved-flash 1.2s ease forwards;
}

/* ===== Empty state ===== */
.aitrfoel-review-empty {
    padding: 40px;
    text-align: center;
    background: #fff;
    border: 1px solid #e6e8ee;
    border-radius: 10px;
    color: #6b7280;
    font-size: 14px;
}
