/* Admin Panel Styles */

.main-container {
  max-width: 1800px;
  margin: 0 auto;
  padding: 2rem;
}

/* Controls Section */
.controls-section {
  display: flex;
  gap: 2rem;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
  padding: 1.5rem;
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.add-user-form {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex: 1;
}

.input-field {
  padding: 0.625rem 0.875rem;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-size: 0.875rem;
  font-family: inherit;
  transition: all 0.2s;
  min-width: 200px;
}

.input-field:focus {
  outline: none;
  border-color: #059669;
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.1);
}

.input-field::placeholder {
  color: #94a3b8;
}

.bulk-actions {
  display: flex;
  gap: 0.5rem;
}

.btn-danger {
  background: #dc2626;
  color: white;
}

.btn-danger:hover:not(:disabled) {
  background: #b91c1c;
}

.btn-danger:disabled {
  background: #fca5a5;
  cursor: not-allowed;
  opacity: 0.6;
}

/* Table Section */
.table-section {
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  overflow: hidden;
}

.table-container {
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.admin-table thead {
  background: #f8fafc;
  border-bottom: 2px solid #e2e8f0;
}

.admin-table th {
  padding: 1rem 0.875rem;
  text-align: left;
  font-weight: 600;
  color: #1e293b;
  position: sticky;
  top: 0;
  background: #f8fafc;
  z-index: 10;
  white-space: nowrap;
}

.admin-table td {
  padding: 0.875rem;
  border-bottom: 1px solid #f1f5f9;
}

.admin-table tbody tr {
  transition: background 0.2s;
}

.admin-table tbody tr:hover {
  background: #f8fafc;
}

/* Column widths */
.col-checkbox {
  width: 40px;
  text-align: center;
}

.col-name {
  min-width: 150px;
}

.col-email {
  min-width: 200px;
}

.col-admin {
  width: 80px;
  text-align: center;
}

/* User info cells */
.user-name {
  font-weight: 600;
  color: #1e293b;
}

.user-email {
  color: #64748b;
  font-family: 'Consolas', 'Monaco', monospace;
  font-size: 0.8125rem;
}

/* Checkboxes */
.admin-table input[type="checkbox"] {
  width: 16px;
  height: 16px;
  cursor: pointer;
  accent-color: #059669;
}

.admin-table input[type="checkbox"]:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.admin-table td {
  text-align: center;
}

.admin-table td:nth-child(2),
.admin-table td:nth-child(3) {
  text-align: left;
}

/* Module toggle columns */
.admin-table th[data-module] {
  font-size: 0.8125rem;
  text-align: center;
  min-width: 90px;
}

/* Empty/loading states */
.loading-row,
.empty-row {
  text-align: center;
  padding: 3rem !important;
  color: #64748b;
  font-style: italic;
}

/* Responsive */
@media (max-width: 1400px) {
  .admin-table {
    font-size: 0.8125rem;
  }
  
  .admin-table th,
  .admin-table td {
    padding: 0.75rem 0.625rem;
  }
  
  .controls-section {
    flex-direction: column;
    align-items: stretch;
  }
  
  .add-user-form {
    flex-wrap: wrap;
  }
}

@media (max-width: 768px) {
  .main-container {
    padding: 1rem;
  }
  
  .controls-section {
    padding: 1rem;
  }
  
  .add-user-form {
    flex-direction: column;
  }
  
  .input-field {
    width: 100%;
    min-width: unset;
  }
  
  .table-container {
    overflow-x: scroll;
  }
  
  .admin-table {
    min-width: 1000px;
  }
}

/* Notification overrides for admin page */
.notification {
  position: fixed;
  top: 80px;
  right: 20px;
  z-index: 10000;
  padding: 1rem 1.5rem;
  background: white;
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
  transform: translateX(400px);
  transition: transform 0.3s ease;
  max-width: 400px;
}

.notification.show {
  transform: translateX(0);
}

.notification.success {
  border-left: 4px solid #059669;
}

.notification.error {
  border-left: 4px solid #dc2626;
}

.notification.warning {
  border-left: 4px solid #f59e0b;
}

.notification.info {
  border-left: 4px solid #3b82f6;
}

.notification-content {
  font-size: 0.875rem;
  color: #1e293b;
}

