/* ===== MOD SCANNER (page-specific) ===== */
/* Shared tokens and button/upload styles live in style.css and
   file-upload.css; this file holds only what is unique to this tool. */

/* Large spinner on the loading card (uses the global "spin" keyframes) */
.loading-spinner-lg {
  width: 50px;
  height: 50px;
  border: 4px solid var(--surface-hover);
  border-top-color: var(--primary);
  border-radius: 50%;
  margin: 0 auto 1.5rem;
  animation: spin 1s linear infinite;
}

#loading {
  text-align: center;
}

/* Scan statistics */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1.5rem;
}

.stat-card {
  text-align: center;
  padding: 1.5rem;
  background: var(--background);
  border-radius: 8px;
  border: 1px solid var(--border);
}

.stat-number {
  font-size: 2.5rem;
  font-weight: bold;
  color: var(--primary);
  margin-bottom: 0.5rem;
  font-variant-numeric: tabular-nums;
}

.stat-label {
  color: var(--text-secondary);
  font-size: 1rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Filter controls */
.mod-controls {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  align-items: center;
}

/* The category toggle chips inside .mod-controls */
.chip-row {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

#searchBox {
  flex: 1;
  min-width: 250px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  color: var(--text-primary);
  padding: 10px 14px;
  border-radius: 5px;
  font-size: 1rem;
}

#searchBox:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.18);
}

/* Results sections rendered by mod-scanner.js */
.mod-category-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin: 0 0 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
}

.mod-category-desc {
  color: var(--text-secondary);
  font-style: italic;
  background: var(--surface-hover);
  padding: 0.75rem 1rem;
  border-radius: 6px;
  margin: 0 0 1rem;
}

.mod-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.mod-name {
  flex: 1;
  min-width: 0;
}

.mod-name a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
}

.mod-badge {
  color: var(--text-on-accent);
  padding: 0.25rem 0.75rem;
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 600;
  flex-shrink: 0;
}

.empty-state {
  text-align: center;
  padding: 3rem 2rem;
  color: var(--text-secondary);
}

/* Status messages */
.error-message {
  color: var(--error);
  background: rgba(var(--error-rgb), 0.1);
  border-left: 4px solid var(--error);
  padding: 15px;
  margin: 15px 0;
  border-radius: 4px;
}

.success-message {
  color: var(--success);
  background: rgba(var(--success-rgb), 0.1);
  border-left: 4px solid var(--success);
  padding: 15px;
  margin: 15px 0;
  border-radius: 4px;
}
