/* Detected Cheaters Page Styles */

.detected-cheaters-container {
  max-width: 87.5rem;
  margin: 0 auto;
  padding: 10rem 1.25rem 2rem 1.25rem; /* Increased top padding to account for breadcrumbs and user profile sticky */
  min-height: calc(100vh - 12.5rem);
}

/* Page Header */
.page-header {
  text-align: center;
  margin-bottom: 2.5rem;
  padding: 2rem 0;
  background: linear-gradient(135deg, rgba(138, 43, 226, 0.1) 0%, rgba(138, 43, 226, 0.05) 100%);
  border-radius: 0.75rem;
  border: 1px solid rgba(138, 43, 226, 0.2);
}

.page-title {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 0.5rem;
  font-family: 'Orbitron', sans-serif;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.page-title i {
  font-size: 2rem;
}

.page-subtitle {
  font-size: 1.125rem;
  color: rgba(255, 255, 255, 0.7);
  font-family: 'Rajdhani', sans-serif;
}

/* Statistics Bar */
.stats-bar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
  gap: 1.25rem;
  margin-bottom: 2.5rem;
}

.stat-item {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(138, 43, 226, 0.3);
  border-radius: 0.5rem;
  padding: 1.25rem;
  text-align: center;
  transition: all 0.3s ease;
}

.stat-item:hover {
  background: rgba(138, 43, 226, 0.1);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(138, 43, 226, 0.2);
}

.stat-value {
  display: block;
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary-color);
  font-family: 'Orbitron', sans-serif;
  margin-bottom: 0.25rem;
}

.stat-label {
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.6);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Search and Filters (Phase 3) */
.search-filters-container {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 0.5rem;
  padding: 1.5rem;
  margin-bottom: 2rem;
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  align-items: center;
}

.search-bar {
  flex: 1;
  min-width: 18.75rem;
  display: flex;
  gap: 0.5rem;
}

.search-input {
  flex: 1;
  padding: 0.75rem 1rem;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(138, 43, 226, 0.3);
  border-radius: 0.375rem;
  color: white;
  font-size: 1rem;
  transition: all 0.3s ease;
}

.search-input:focus {
  outline: none;
  border-color: var(--primary-color);
  background: rgba(0, 0, 0, 0.5);
}

.search-btn {
  padding: 0.75rem 1.25rem;
  background: var(--primary-color);
  border: none;
  border-radius: 0.375rem;
  color: white;
  cursor: pointer;
  transition: all 0.3s ease;
}

.search-btn:hover {
  background: var(--primary-hover);
  transform: translateY(-2px);
}

.filters {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.filter-select {
  padding: 0.75rem 1rem;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(138, 43, 226, 0.3);
  border-radius: 0.375rem;
  color: white;
  font-size: 1rem;
  cursor: pointer;
}

.clear-filters-btn {
  padding: 0.75rem 1rem;
  background: rgba(255, 59, 48, 0.2);
  border: 1px solid rgba(255, 59, 48, 0.4);
  border-radius: 0.375rem;
  color: #ff3b30;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.clear-filters-btn:hover {
  background: rgba(255, 59, 48, 0.3);
  transform: translateY(-2px);
}

/* Table Container */
.table-container {
  background: rgba(255, 255, 255, 0.02);
  border-radius: 0.75rem;
  padding: 1.5rem;
  border: 1px solid rgba(138, 43, 226, 0.2);
}

/* Loading State */
.table-loading {
  text-align: center;
  padding: 4rem 2rem;
}

.loading-spinner {
  width: 3rem;
  height: 3rem;
  border: 0.25rem solid rgba(138, 43, 226, 0.2);
  border-top: 0.25rem solid var(--primary-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 1.5rem;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 4rem 2rem;
}

.empty-icon {
  font-size: 4rem;
  color: rgba(138, 43, 226, 0.5);
  margin-bottom: 1.5rem;
}

.empty-state h3 {
  font-size: 1.5rem;
  color: white;
  margin-bottom: 0.5rem;
}

.empty-state p {
  color: rgba(255, 255, 255, 0.6);
}

/* Table Styles */
.table-wrapper {
  overflow-x: auto;
  margin-bottom: 1.5rem;
}

.cheaters-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}

.cheaters-table thead {
  background: rgba(138, 43, 226, 0.1);
}

.cheaters-table th {
  padding: 1rem;
  text-align: left;
  font-weight: 600;
  color: var(--primary-color);
  text-transform: uppercase;
  font-size: 0.875rem;
  letter-spacing: 0.05em;
  border-bottom: 2px solid rgba(138, 43, 226, 0.3);
  white-space: nowrap;
}

.cheaters-table th.sortable {
  cursor: pointer;
  user-select: none;
  transition: color 0.3s ease;
}

.cheaters-table th.sortable:hover {
  color: var(--primary-hover);
}

.sort-icon {
  margin-left: 0.5rem;
  font-size: 0.75rem;
  opacity: 0.5;
  transition: opacity 0.3s ease;
}

.cheaters-table th.sortable:hover .sort-icon {
  opacity: 1;
}

.cheaters-table th.sorted-asc .sort-icon::before {
  content: '\f0de'; /* fa-sort-up */
}

.cheaters-table th.sorted-desc .sort-icon::before {
  content: '\f0dd'; /* fa-sort-down */
}

.cheaters-table tbody tr {
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  transition: background-color 0.3s ease;
}

.cheaters-table tbody tr:hover {
  background: rgba(138, 43, 226, 0.05);
}

.cheaters-table td {
  padding: 1rem;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.9375rem;
}

/* Suspect Name with Steam Link */
.suspect-name {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
}

.suspect-name a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

.suspect-name a:hover {
  color: var(--primary-hover);
  text-decoration: underline;
}

.steam-icon {
  color: #66c0f4;
  font-size: 1rem;
}

/* Conviction Type Badges */
.conviction-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 1rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.conviction-badge.cheater {
  background: rgba(255, 59, 48, 0.2);
  color: #ff3b30;
  border: 1px solid rgba(255, 59, 48, 0.4);
}

.conviction-badge.griefer {
  background: rgba(255, 149, 0, 0.2);
  color: #ff9500;
  border: 1px solid rgba(255, 149, 0, 0.4);
}

.conviction-badge.both {
  background: rgba(138, 43, 226, 0.2);
  color: var(--primary-color);
  border: 1px solid rgba(138, 43, 226, 0.4);
}

/* Times Caught - Clickable dropdown trigger */
.times-caught {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.5rem;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 0.25rem;
  cursor: pointer;
  transition: all 0.3s ease;
  user-select: none;
}

.times-caught:hover {
  background: rgba(138, 43, 226, 0.2);
  transform: translateY(-1px);
}

.times-caught-count {
  font-weight: 700;
  color: var(--primary-color);
}

.times-caught i {
  transition: transform 0.3s ease;
  color: var(--primary-color);
  font-size: 0.75rem;
}

/* Case Number Link */
.case-link {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
  cursor: pointer;
}

.case-link:hover {
  color: var(--primary-hover);
  text-decoration: underline;
}

/* Action Buttons */
.action-btn {
  padding: 0.5rem 1rem;
  background: var(--primary-color);
  border: none;
  border-radius: 0.25rem;
  color: white;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.action-btn:hover {
  background: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(138, 43, 226, 0.3);
}

/* Pagination */
.pagination-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.pagination-info {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.9375rem;
}

.pagination-controls {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.pagination-btn {
  padding: 0.5rem 1rem;
  background: rgba(138, 43, 226, 0.2);
  border: 1px solid rgba(138, 43, 226, 0.4);
  border-radius: 0.25rem;
  color: white;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.pagination-btn:hover:not(:disabled) {
  background: var(--primary-color);
  transform: translateY(-2px);
}

.pagination-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.page-numbers {
  display: flex;
  gap: 0.5rem;
}

.page-num {
  width: 2.5rem;
  height: 2.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.25rem;
  color: white;
  cursor: pointer;
  transition: all 0.3s ease;
}

.page-num:hover {
  background: rgba(138, 43, 226, 0.2);
  border-color: rgba(138, 43, 226, 0.4);
}

.page-num.active {
  background: var(--primary-color);
  border-color: var(--primary-color);
  font-weight: 600;
}

/* Repeat Offender Dropdown (Phase 4) */
.dropdown-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 1;
  transition: opacity 0.3s ease;
}

.dropdown-overlay.hidden {
  display: none;
}

.dropdown-content {
  background: #1a1a2e;
  border-radius: 0.75rem;
  max-width: 37.5rem;
  width: 90%;
  max-height: 80vh;
  overflow: hidden;
  border: 2px solid rgba(138, 43, 226, 0.4);
}

.dropdown-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.25rem;
  background: rgba(138, 43, 226, 0.1);
  border-bottom: 1px solid rgba(138, 43, 226, 0.3);
}

.dropdown-header h3 {
  margin: 0;
  color: white;
  font-size: 1.25rem;
}

.close-dropdown {
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.6);
  font-size: 1.5rem;
  cursor: pointer;
  transition: color 0.3s ease;
}

.close-dropdown:hover {
  color: white;
}

.dropdown-body {
  padding: 1.25rem;
  max-height: calc(80vh - 5rem);
  overflow-y: auto;
}

.cases-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.case-item {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.5rem;
  padding: 1rem;
  transition: all 0.3s ease;
}

.case-item:hover {
  background: rgba(138, 43, 226, 0.1);
  border-color: rgba(138, 43, 226, 0.3);
}

/* Responsive Design */
@media (max-width: 768px) {
  .detected-cheaters-container {
    padding: 1rem;
  }

  .page-title {
    font-size: 1.75rem;
  }

  .stats-bar {
    grid-template-columns: repeat(2, 1fr);
  }

  .search-filters-container {
    flex-direction: column;
    gap: 1rem;
  }

  .search-bar {
    width: 100%;
  }

  .filters {
    width: 100%;
    justify-content: space-between;
  }

  .table-wrapper {
    overflow-x: scroll;
  }

  .cheaters-table {
    min-width: 50rem;
  }

  .pagination-container {
    flex-direction: column;
    gap: 1rem;
    align-items: stretch;
  }

  .pagination-controls {
    justify-content: center;
  }
}

/* Case History Dropdown Styles */
.case-history-row {
  background: rgba(30, 30, 30, 0.95);
  animation: slideDown 0.3s ease;
}

.case-history-row.collapsing {
  animation: slideUp 0.3s ease;
}

@keyframes slideDown {
  from {
    opacity: 0;
    max-height: 0;
  }
  to {
    opacity: 1;
    max-height: 500px;
  }
}

@keyframes slideUp {
  from {
    opacity: 1;
    max-height: 500px;
  }
  to {
    opacity: 0;
    max-height: 0;
  }
}

.case-history-cell {
  padding: 0;
  border-top: 2px solid var(--primary-color);
}

.case-history-container {
  padding: 1.5rem;
  background: linear-gradient(135deg, rgba(138, 43, 226, 0.05) 0%, rgba(30, 30, 30, 0.95) 100%);
}

.case-history-header {
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(138, 43, 226, 0.3);
}

.case-history-header h4 {
  margin: 0;
  color: var(--primary-color);
  font-size: 1.125rem;
  font-weight: 600;
  font-family: 'Orbitron', sans-serif;
}

.case-history-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.case-history-item {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.5rem;
  padding: 1rem;
  transition: all 0.3s ease;
}

.case-history-item:hover {
  background: rgba(138, 43, 226, 0.1);
  border-color: rgba(138, 43, 226, 0.3);
  transform: translateX(0.25rem);
}

.case-history-main {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.case-history-link {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: color 0.3s ease;
  cursor: pointer;
}

.case-history-link:hover {
  color: var(--primary-hover);
  text-decoration: underline;
}

.case-history-link i {
  font-size: 0.875rem;
}

.case-history-details {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.875rem;
}

.case-history-detail {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  color: rgba(255, 255, 255, 0.7);
}

.case-history-detail i {
  font-size: 0.75rem;
  color: rgba(138, 43, 226, 0.7);
}

/* Mini badges for conviction types in dropdown */
.mini-badge {
  padding: 0.125rem 0.5rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.mini-badge.cheater {
  background: rgba(255, 0, 0, 0.2);
  color: #ff4444;
  border: 1px solid rgba(255, 0, 0, 0.3);
}

.mini-badge.griefer {
  background: rgba(255, 165, 0, 0.2);
  color: #ffa500;
  border: 1px solid rgba(255, 165, 0, 0.3);
}

.mini-badge.both {
  background: linear-gradient(135deg, rgba(255, 0, 0, 0.2) 0%, rgba(255, 165, 0, 0.2) 100%);
  color: #ff7777;
  border: 1px solid rgba(255, 100, 100, 0.3);
}

/* Loading and empty states for dropdown */
.case-history-loading,
.case-history-empty {
  padding: 2rem;
  text-align: center;
  color: rgba(255, 255, 255, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

.case-history-loading i {
  color: var(--primary-color);
  font-size: 1.25rem;
}

.case-history-empty i {
  color: rgba(255, 255, 255, 0.4);
  font-size: 1.25rem;
}
