* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background: #f7fafc;
  min-height: 100vh;
  padding: 20px;
}

.header {
  background: white;
  padding: 20px 30px;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  margin-bottom: 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header h1 {
  color: #2d3748;
  font-size: 28px;
  font-weight: 700;
}

.header .breadcrumb {
  color: #718096;
  font-size: 14px;
}

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.stat-card {
  background: white;
  padding: 25px;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.stat-card .label {
  color: #718096;
  font-size: 13px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.stat-card .value {
  color: #2d3748;
  font-size: 32px;
  font-weight: 700;
}

.stat-card .icon {
  font-size: 40px;
  margin-bottom: 15px;
}

.container {
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  padding: 30px;
}

.container h2 {
  color: #2d3748;
  font-size: 22px;
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 2px solid #e2e8f0;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
}

th {
  background: #f7fafc;
  padding: 14px 16px;
  text-align: left;
  font-weight: 600;
  font-size: 13px;
  color: #4a5568;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 2px solid #e2e8f0;
}

th.sortable {
  cursor: pointer;
  user-select: none;
  position: relative;
  padding-right: 30px;
}

th.sortable::after {
  content: '⇅';
  position: absolute;
  right: 10px;
  opacity: 0.3;
  font-size: 14px;
}

th.sortable:hover::after {
  opacity: 0.6;
}

th.sortable.asc::after {
  content: '▲';
  opacity: 1;
  color: #667eea;
}

th.sortable.desc::after {
  content: '▼';
  opacity: 1;
  color: #667eea;
}

td {
  padding: 14px 16px;
  border-bottom: 1px solid #e2e8f0;
  color: #4a5568;
  font-size: 14px;
}

tr:hover {
  background: #f7fafc;
}

.badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge.admin {
  background: #fed7d7;
  color: #c53030;
}

.badge.user {
  background: #c6f6d5;
  color: #22543d;
}

.badge.enabled {
  background: #9ae6b4;
  color: #22543d;
}

.badge.disabled {
  background: #fed7d7;
  color: #c53030;
}

.error-message {
  background: #fed7d7;
  color: #c53030;
  padding: 16px 20px;
  border-radius: 8px;
  margin-bottom: 20px;
  font-size: 14px;
  display: none;
}

.error-message.show {
  display: block;
}

.loading {
  text-align: center;
  padding: 40px;
  color: #718096;
  font-size: 16px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.spinner {
  display: inline-block;
  width: 24px;
  height: 24px;
  border: 3px solid #cbd5e0;
  border-top-color: #667eea;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  margin-right: 10px;
  vertical-align: middle;
}

.back-button {
  display: inline-block;
  padding: 10px 20px;
  background: #667eea;
  color: white;
  text-decoration: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  transition: background 0.2s;
}

.back-button:hover {
  background: #5a67d8;
}

.date-cell {
  color: #718096;
  font-size: 13px;
}

.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: #a0aec0;
}

.empty-state .icon {
  font-size: 64px;
  margin-bottom: 20px;
}

.account-type-select {
  padding: 6px 30px 6px 10px;
  border: 2px solid #e2e8f0;
  border-radius: 6px;
  background: white;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%234a5568' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
}

.account-type-select:hover {
  border-color: #cbd5e0;
}

.account-type-select:focus {
  outline: none;
  border-color: #667eea;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.account-type-select.normal {
  color: #065f46;
  background-color: #d1fae5;
  border-color: #6ee7b7;
}

.account-type-select.test {
  color: #92400e;
  background-color: #fef3c7;
  border-color: #fbbf24;
}

/* Account approval -- assets/js/admin.js statusCell() */
.status-cell { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.badge.status-approved { background: #d1fae5; color: #065f46; }
.badge.status-pending { background: #fef3c7; color: #92400e; }
.badge.status-rejected { background: #fee2e2; color: #991b1b; }
.status-btn { border: none; border-radius: 6px; padding: 4px 10px; font-size: 0.8rem; font-weight: 600; cursor: pointer; }
.status-btn.approve { background: #10b981; color: #fff; }
.status-btn.reject { background: #f1f5f9; color: #991b1b; border: 1px solid #fecaca; }
.status-btn:focus-visible { outline: 3px solid #a5b4fc; outline-offset: 2px; }
