/* ========== CONTAINER ========== */
.grouping-container {
  max-width: 98%;
  padding: 0 20px;
  margin: 0 auto;
}

/* ========== HERO SECTION ========== */
.grouping-hero {
  position: relative;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  padding: 80px 20px;
  border-radius: 24px;
  margin-bottom: 40px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(102, 126, 234, 0.3);
}

.hero-gradient-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.hero-content-wrapper {
  position: relative;
  z-index: 2;
  text-align: center;
  color: white;
}

.hero-icon-container {
  margin-bottom: 30px;
}

.icon-circle {
  width: 100px;
  height: 100px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(10px);
  animation: float 3s ease-in-out infinite;
}

.icon-circle i {
  font-size: 3rem;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.hero-main-title {
  font-size: 3rem;
  font-weight: 800;
  margin-bottom: 15px;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.2);
}

.hero-description {
  font-size: 1.2rem;
  opacity: 0.95;
}

.floating-element {
  position: absolute;
  width: 60px;
  height: 60px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  animation: float-random 15s ease-in-out infinite;
}

.element-1 { top: 10%; left: 5%; animation-delay: 0s; }
.element-2 { top: 60%; right: 10%; animation-delay: -5s; }
.element-3 { bottom: 20%; left: 15%; animation-delay: -10s; }

@keyframes float-random {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  33% { transform: translate(30px, -30px) rotate(120deg); }
  66% { transform: translate(-20px, 20px) rotate(240deg); }
}

/* ========== LAYOUT ========== */
.grouping-layout {
  display: grid;
  grid-template-columns: 350px 1fr;
  gap: 30px;
  margin-bottom: 40px;
}

/* ========== STATS CARD ========== */
.stats-card-modern {
  background: white;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

.card-header-modern {
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: white;
  padding: 20px;
  display: flex;
  align-items: center;
  font-size: 1.1rem;
  font-weight: 700;
}

.stats-list-container {
  padding: 20px;
  max-height: 600px;
  overflow-y: auto;
}

.stat-item-modern {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px;
  background: #f8f9ff;
  border-radius: 12px;
  margin-bottom: 10px;
  transition: all 0.3s ease;
}

.stat-item-modern:hover {
  background: linear-gradient(90deg, #e8ecff, #f0f4ff);
  transform: translateX(5px);
}

.stat-item-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

.stat-icon {
  color: #667eea;
  font-size: 1.2rem;
}

.stat-name {
  font-weight: 600;
  color: #2c3e50;
}

.stat-badge {
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: white;
  padding: 6px 16px;
  border-radius: 20px;
  font-weight: 700;
  font-size: 0.9rem;
}

/* ========== UNASSIGNED CARD ========== */
.unassigned-card-modern {
  background: white;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

.header-left {
  display: flex;
  align-items: center;
}

.header-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.select-modern {
  padding: 8px 16px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.2);
  color: white;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.select-modern:focus {
  outline: none;
  background: rgba(255, 255, 255, 0.3);
}

.select-modern option {
  color: #2c3e50;
  background: white;
}

.btn-assign-modern {
  padding: 8px 20px;
  background: rgba(255, 255, 255, 0.2);
  color: white;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-assign-modern:not(:disabled):hover {
  background: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}

.btn-assign-modern:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.table-wrapper-modern {
  padding: 20px;
}

.select-all-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 15px;
  background: #f8f9fa;
  border-radius: 12px;
  margin-bottom: 15px;
}

.checkbox-modern {
  width: 20px;
  height: 20px;
  cursor: pointer;
  accent-color: #667eea;
}

.select-all-label {
  font-weight: 600;
  color: #2c3e50;
  margin: 0;
  cursor: pointer;
}

.unassigned-table-modern {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 8px;
  font-size: 0.9rem;
}

.unassigned-table-modern thead th {
  background: #f8f9fa;
  color: #495057;
  font-weight: 600;
  padding: 12px;
  text-align: center;
  white-space: nowrap;
  font-size: 0.85rem;
  text-transform: uppercase;
}

.unassigned-table-modern tbody tr {
  background: #f8f9ff;
  transition: all 0.3s ease;
}

.unassigned-table-modern tbody tr:hover {
  background: linear-gradient(90deg, #e8ecff, #f0f4ff);
  transform: scale(1.01);
}

.unassigned-table-modern tbody td {
  padding: 12px;
  text-align: center;
  vertical-align: middle;
}

.user-id-badge {
  background: linear-gradient(135deg, #0dcaf0, #0891b2);
  color: white;
  padding: 4px 12px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.85rem;
  display: inline-block;
}

.score-badge {
  background: linear-gradient(135deg, #28a745, #20c997);
  color: white;
  padding: 4px 12px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.85rem;
  display: inline-block;
}

.date-cell {
  font-family: monospace;
  color: #6c757d;
  font-size: 0.85rem;
}

.empty-state-modern {
  text-align: center;
  padding: 80px 20px;
  color: #28a745;
}

.empty-state-modern i {
  font-size: 4rem;
  margin-bottom: 20px;
  opacity: 0.5;
}

.empty-state-modern p {
  font-size: 1.2rem;
  font-weight: 600;
  margin: 0;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
  .grouping-layout {
    grid-template-columns: 1fr;
  }
  
  .header-actions {
    flex-wrap: wrap;
  }
}

@media (max-width: 768px) {
  .hero-main-title {
    font-size: 2rem;
  }
  
  .card-header-modern {
    flex-direction: column;
    gap: 15px;
  }
  
  .header-actions {
    width: 100%;
  }
  
  .select-modern,
  .btn-assign-modern {
    flex: 1;
  }
}