.tr-page { padding: 2rem; direction: ltr; max-width: 1200px; }

.tr-header h1 { font-size: 1.6rem; font-weight: 700; margin-bottom: 0.25rem; }
.tr-subtitle { color: #888; font-size: 0.9rem; margin-bottom: 1.5rem; }

/* Stats row */
.tr-stats {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
}

.tr-stat {
  background: #f8f9fa;
  border: 2px solid #e9ecef;
  border-radius: 8px;
  padding: 0.6rem 1.2rem;
  cursor: pointer;
  text-align: center;
  transition: all 0.15s;
}

.tr-stat:hover { border-color: #adb5bd; }
.tr-stat.active { border-color: #0071E3; background: #e8f4ff; }

.tr-stat-num { display: block; font-size: 1.4rem; font-weight: 700; color: #333; }
.tr-stat-label { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.5px; color: #888; }

/* Toolbar */
.tr-toolbar {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
  align-items: center;
}

.tr-search {
  flex: 1;
  min-width: 200px;
  padding: 0.55rem 0.85rem;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 0.9rem;
  outline: none;
}
.tr-search:focus { border-color: #0071E3; box-shadow: 0 0 0 3px rgba(0,113,227,0.1); }

.tr-select {
  padding: 0.55rem 0.85rem;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 0.9rem;
  background: #fff;
}

.tr-loading, .tr-empty { text-align: center; padding: 3rem; color: #999; font-size: 1rem; }

/* Cards */
.tr-cards { display: flex; flex-direction: column; gap: 1rem; }

.tr-card {
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 1.25rem;
  background: #fff;
  transition: border-color 0.15s;
}

.tr-card:hover { border-color: #c5c8cc; }
.tr-card--pending { border-left: 4px solid #0071E3; }
.tr-card--applied { border-left: 4px solid #28a745; opacity: 0.65; }
.tr-card--rejected { border-left: 4px solid #dc3545; opacity: 0.65; }
.tr-card--skipped { border-left: 4px solid #6c757d; opacity: 0.65; }

/* Card meta */
.tr-card-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}

.tr-num { font-weight: 700; color: #555; font-size: 0.85rem; }

.tr-badge {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.tr-badge--vue { background: #42b88322; color: #2d9a6a; }
.tr-badge--db { background: #0071E322; color: #0056b3; }
.tr-badge--curr { background: #c652dd22; color: #9b30c9; }
.tr-badge--pending { background: #fff3cd; color: #856404; }
.tr-badge--applied { background: #d1e7dd; color: #155724; }
.tr-badge--rejected { background: #f8d7da; color: #842029; }
.tr-badge--skipped { background: #e2e3e5; color: #383d41; }

.tr-source {
  font-family: 'SF Mono', 'Fira Code', monospace;
  font-size: 0.78rem;
  color: #555;
  background: #f5f5f5;
  padding: 0.1rem 0.4rem;
  border-radius: 3px;
}

.tr-location { font-size: 0.78rem; color: #999; }

/* Info row */
.tr-info-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}

.tr-info-label {
  display: block;
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #aaa;
  margin-bottom: 0.2rem;
}

.tr-info-text { font-size: 0.82rem; color: #666; line-height: 1.4; }

/* Text comparison */
.tr-compare {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 0.75rem;
  align-items: start;
  margin-bottom: 1rem;
}

.tr-text-block label {
  display: block;
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #aaa;
  margin-bottom: 0.35rem;
}

.tr-saving { color: #0071E3; font-weight: 400; text-transform: none; letter-spacing: 0; }

.tr-text-block--old p {
  background: #fff8f0;
  border: 1px solid #ffe0b2;
  border-radius: 6px;
  padding: 0.75rem;
  font-size: 0.9rem;
  line-height: 1.7;
  direction: rtl;
  margin: 0;
  min-height: 4rem;
}

.tr-text-block--new textarea {
  width: 100%;
  border: 1px solid #c8e6c9;
  border-radius: 6px;
  padding: 0.75rem;
  font-size: 0.9rem;
  line-height: 1.7;
  direction: rtl;
  font-family: inherit;
  resize: vertical;
  background: #f0fff0;
  min-height: 4rem;
  outline: none;
  box-sizing: border-box;
}
.tr-text-block--new textarea:focus { border-color: #28a745; box-shadow: 0 0 0 3px rgba(40,167,69,0.1); }
.tr-text-block--new textarea:disabled { background: #f5f5f5; border-color: #ddd; color: #888; }

.tr-arrow-col { display: flex; align-items: center; padding-top: 1.5rem; }

.tr-arrow-btn {
  background: #f8f9fa;
  border: 1px solid #ddd;
  border-radius: 6px;
  padding: 0.5rem 0.65rem;
  cursor: pointer;
  color: #666;
  transition: all 0.15s;
}
.tr-arrow-btn:hover { background: #e9ecef; border-color: #adb5bd; color: #333; }

/* Actions */
.tr-actions { display: flex; gap: 0.5rem; }

.tr-btn {
  padding: 0.5rem 1rem;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  transition: all 0.15s;
}
.tr-btn:disabled { opacity: 0.6; cursor: not-allowed; }

.tr-btn--apply { background: #28a745; color: #fff; }
.tr-btn--apply:hover:not(:disabled) { background: #218838; }

.tr-btn--skip { background: #f0f0f0; color: #555; }
.tr-btn--skip:hover:not(:disabled) { background: #e0e0e0; }

.tr-btn--reject { background: #dc3545; color: #fff; }
.tr-btn--reject:hover:not(:disabled) { background: #c82333; }

.tr-done-label {
  font-size: 0.8rem;
  color: #999;
  font-style: italic;
  padding-top: 0.25rem;
}

/* Toast */
.tr-toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  padding: 0.75rem 1.25rem;
  border-radius: 8px;
  font-size: 0.9rem;
  box-shadow: 0 4px 16px rgba(0,0,0,0.15);
  z-index: 9999;
  max-width: 400px;
}
.tr-toast--success { background: #28a745; color: #fff; }
.tr-toast--error { background: #dc3545; color: #fff; }

.fade-enter-active, .fade-leave-active { transition: opacity 0.3s; }
.fade-enter-from, .fade-leave-to { opacity: 0; }

@media (max-width: 768px) {
  .tr-compare { grid-template-columns: 1fr; }
  .tr-arrow-col { display: none; }
  .tr-info-row { grid-template-columns: 1fr; }
}
