/* Scoring Command Center Styles */

.scoring-app {
  padding-top: 48px;
  max-width: 1200px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.scoring-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0 16px;
  border-bottom: 1px solid #e5e7eb;
}

.scoring-header h1 {
  font-size: 20px;
  font-weight: 600;
  color: #111827;
  margin: 0;
}

.scoring-header-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.scoring-filter-btn {
  padding: 6px 12px;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  background: #fff;
  color: #374151;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.15s;
}

.scoring-filter-btn:hover {
  background: #f3f4f6;
}

.scoring-filter-btn.active {
  background: #1f2937;
  color: #fff;
  border-color: #1f2937;
}

/* Job List Table */
.scoring-jobs-section {
  margin-top: 16px;
}

.scoring-jobs-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.scoring-jobs-table th {
  text-align: left;
  padding: 8px 12px;
  color: #6b7280;
  font-weight: 500;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-bottom: 1px solid #e5e7eb;
  user-select: none;
}

.scoring-jobs-table td {
  padding: 10px 12px;
  border-bottom: 1px solid #f3f4f6;
  color: #374151;
  vertical-align: middle;
}

.scoring-jobs-table tr {
  cursor: pointer;
  transition: background 0.1s;
}

.scoring-jobs-table tr:hover {
  background: #f9fafb;
}

.scoring-jobs-table tr.selected {
  background: #eff6ff;
}

.scoring-jobs-table tr.selected:hover {
  background: #dbeafe;
}

/* Status badges */
.status-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 600;
  text-transform: capitalize;
}

.status-badge.running {
  background: #dbeafe;
  color: #1d4ed8;
}

.status-badge.complete {
  background: #d1fae5;
  color: #065f46;
}

.status-badge.cancelled {
  background: #fef3c7;
  color: #92400e;
}

.status-badge.error {
  background: #fee2e2;
  color: #991b1b;
}

/* Progress bar */
.progress-cell {
  display: flex;
  align-items: center;
  gap: 8px;
}

.progress-bar-container {
  flex: 1;
  height: 6px;
  background: #e5e7eb;
  border-radius: 3px;
  overflow: hidden;
  min-width: 60px;
}

.progress-bar-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.3s ease;
  background: #3b82f6;
}

.progress-bar-fill.complete {
  background: #10b981;
}

.progress-text {
  font-size: 12px;
  color: #6b7280;
  white-space: nowrap;
  min-width: 60px;
}

/* Cancel button */
.cancel-btn {
  padding: 4px 10px;
  border: 1px solid #fca5a5;
  border-radius: 4px;
  background: #fff;
  color: #dc2626;
  font-size: 11px;
  cursor: pointer;
  transition: all 0.15s;
}

.cancel-btn:hover {
  background: #fef2f2;
}

.cancel-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Job Detail Section */
.scoring-detail-section {
  margin-top: 24px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  overflow: hidden;
}

.scoring-detail-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: #f9fafb;
  border-bottom: 1px solid #e5e7eb;
}

.scoring-detail-header h2 {
  font-size: 14px;
  font-weight: 600;
  color: #111827;
  margin: 0;
}

.scoring-detail-header .meta {
  font-size: 12px;
  color: #6b7280;
}

.scoring-detail-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.scoring-detail-table th {
  text-align: left;
  padding: 8px 16px;
  color: #6b7280;
  font-weight: 500;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-bottom: 1px solid #e5e7eb;
  background: #fafafa;
}

.scoring-detail-table td {
  padding: 8px 16px;
  border-bottom: 1px solid #f3f4f6;
  color: #374151;
}

/* Score badges (matching screener) */
.score-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 700;
  min-width: 24px;
  text-align: center;
}

.score-badge.score-a {
  background: #d1fae5;
  color: #065f46;
}

.score-badge.score-b-plus {
  background: #dbeafe;
  color: #1d4ed8;
}

.score-badge.score-b {
  background: #fef3c7;
  color: #92400e;
}

.score-badge.score-c {
  background: #fee2e2;
  color: #991b1b;
}

/* Domain status icons */
.domain-status {
  display: flex;
  align-items: center;
  gap: 6px;
}

.domain-status .status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.domain-status .status-dot.running {
  background: #3b82f6;
  animation: pulse-dot 1.5s infinite;
}

.domain-status .status-dot.pending {
  background: #d1d5db;
}

.domain-status .status-dot.complete {
  background: #10b981;
}

.domain-status .status-dot.error {
  background: #ef4444;
}

.domain-status .status-dot.cancelled {
  background: #f59e0b;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

/* Error tooltip */
.error-text {
  color: #dc2626;
  font-size: 11px;
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: help;
}

/* Empty state */
.scoring-empty {
  text-align: center;
  padding: 48px 24px;
  color: #9ca3af;
}

.scoring-empty svg {
  margin-bottom: 12px;
  opacity: 0.4;
}

.scoring-empty p {
  font-size: 14px;
  margin: 0;
}

.scoring-empty .hint {
  font-size: 12px;
  margin-top: 4px;
}

/* Type badge */
.type-badge {
  display: inline-block;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 500;
  text-transform: capitalize;
}

.type-badge.company {
  background: #ede9fe;
  color: #5b21b6;
}

.type-badge.team {
  background: #fce7f3;
  color: #9d174d;
}

/* Auto-refresh indicator */
.auto-refresh-indicator {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: #9ca3af;
}

.auto-refresh-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  animation: pulse-dot 2s infinite;
}

/* Responsive */
@media (max-width: 768px) {
  .scoring-app {
    padding-left: 12px;
    padding-right: 12px;
  }

  .scoring-jobs-table th:nth-child(5),
  .scoring-jobs-table td:nth-child(5) {
    display: none;
  }
}
