/* ============================================================
   ADMIN LAYOUT STYLES — Modern Minimalist Light Theme
   Inspired by Tabler, Vercel, Shopify admin patterns
   ============================================================ */

/* --- Layout Shell --- */
.admin-layout {
  display: flex;
  min-height: 100vh;
}

/* --- Sidebar --- */
.admin-sidebar {
  width: var(--sidebar-width);
  background: var(--color-sidebar-bg);
  color: var(--color-sidebar-text);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: var(--z-sticky);
  transition: transform var(--duration-normal) var(--ease-default), width var(--duration-normal) var(--ease-default);
  overflow-y: auto;
  border-right: 1px solid var(--color-border);
}
.admin-sidebar::-webkit-scrollbar { width: 4px; }
.admin-sidebar::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 4px; }

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: 20px var(--space-5);
  border-bottom: 1px solid var(--color-border-light);
  text-decoration: none;
  color: var(--color-text-primary);
  transition: opacity 0.2s;
}
.sidebar-brand:hover {
  opacity: 0.95;
}
.sidebar-brand-logo {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  object-fit: contain;
  background: linear-gradient(135deg, var(--color-primary), #10b981);
  box-shadow: 0 0 12px rgba(45, 194, 117, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--fs-lg);
  color: #ffffff;
  flex-shrink: 0;
}
.sidebar-brand-name {
  font-family: var(--font-display);
  font-size: var(--fs-md);
  font-weight: 700;
  white-space: nowrap;
  letter-spacing: 0.5px;
  color: var(--color-text-primary);
}

.sidebar-nav {
  flex: 1;
  padding: var(--space-3) var(--space-2);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.sidebar-section {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.sidebar-section-label {
  padding: var(--space-2) var(--space-3) var(--space-1) var(--space-3);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #94a3b8;
}
.sidebar-link {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: 9px 14px;
  color: var(--color-sidebar-text);
  font-size: var(--fs-sm);
  text-decoration: none;
  border-radius: var(--radius-md);
  transition: all var(--duration-fast) var(--ease-default);
  font-weight: 500;
  position: relative;
}
.sidebar-link:hover {
  background: var(--color-sidebar-hover);
  color: var(--color-text-primary);
  transform: translateX(2px);
}
.sidebar-link.active {
  background: linear-gradient(90deg, color-mix(in srgb, var(--color-primary) 8%, transparent) 0%, color-mix(in srgb, var(--color-primary) 2%, transparent) 100%);
  color: var(--color-primary);
  font-weight: 600;
  border-left: 3px solid var(--color-primary);
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  padding-left: 11px;
}
.sidebar-link-icon {
  width: 20px;
  text-align: center;
  font-size: var(--fs-base);
  opacity: 0.55;
  flex-shrink: 0;
  transition: color 0.2s;
}
.sidebar-link:hover .sidebar-link-icon {
  opacity: 0.9;
}

/* Sidebar alert badge (pending counts) */
.sidebar-badge {
  margin-left: auto;
  min-width: 18px;
  height: 18px;
  padding: 0 6px;
  border-radius: 999px;
  background: #ef4444;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
  box-shadow: 0 0 0 2px color-mix(in srgb, #ef4444 30%, transparent);
  animation: sidebarBadgePulse 1.8s ease-in-out infinite;
}
@keyframes sidebarBadgePulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(239,68,68,0.5); }
  50% { box-shadow: 0 0 0 4px rgba(239,68,68,0); }
}
.sidebar-link.active .sidebar-link-icon {
  opacity: 1;
  color: var(--color-primary);
}

/* Sidebar Badge Counter */
.sidebar-badge {
  margin-left: auto;
  background: var(--color-danger);
  color: #ffffff;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--radius-full);
  line-height: 1.2;
  min-width: 18px;
  text-align: center;
}
.sidebar-badge-info {
  background: var(--color-primary);
}

.sidebar-footer {
  padding: var(--space-3) var(--space-3);
  border-top: 1px solid var(--color-border);
  background: var(--color-sidebar-hover);
}
.sidebar-user {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}
.sidebar-user-avatar {
  width: 34px;
  height: 34px;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--fs-sm);
  font-weight: 700;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}
.sidebar-user-info {
  flex: 1;
  min-width: 0;
}
.sidebar-user-name {
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--color-text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sidebar-user-role {
  font-size: 10px;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}

/* --- Main Content Area --- */
.admin-main {
  flex: 1;
  margin-left: var(--sidebar-width);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background: var(--color-bg);
}

/* --- Top Header --- */
.admin-header {
  height: var(--header-height);
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--space-6);
  position: sticky;
  top: 0;
  z-index: var(--z-sticky);
  box-shadow: 0 1px 3px rgba(0,0,0,0.03);
}
.admin-header-left {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  flex: 1;
}
.admin-header-title {
  font-family: var(--font-display);
  font-size: var(--fs-lg);
  font-weight: var(--fw-semibold);
  color: var(--color-text-primary);
}
.admin-header-right {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

/* Header Search Bar */
.header-search {
  position: relative;
  max-width: 280px;
  margin-left: var(--space-4);
}
.header-search-input {
  width: 100%;
  padding: 7px 14px 7px 36px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  background: var(--color-bg);
  font-size: var(--fs-sm);
  color: var(--color-text-primary);
  transition: all var(--duration-fast) var(--ease-default);
}
.header-search-input:focus {
  outline: none;
  border-color: var(--color-primary);
  background: var(--color-surface);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--color-primary) 10%, transparent);
}
.header-search-input::placeholder {
  color: var(--color-text-muted);
}
.header-search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-text-muted);
  font-size: var(--fs-sm);
  pointer-events: none;
}

/* Header Icon Button */
.header-icon-btn {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background: transparent;
  border: 1px solid transparent;
  color: var(--color-text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--duration-fast);
  position: relative;
  font-size: var(--fs-base);
}
.header-icon-btn:hover {
  background: var(--color-bg);
  color: var(--color-text-primary);
  border-color: var(--color-border);
}
.header-icon-btn .notification-dot {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 8px;
  height: 8px;
  background: var(--color-danger);
  border-radius: var(--radius-full);
  border: 2px solid var(--color-surface);
}

.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: var(--fs-xl);
  color: var(--color-text-secondary);
  padding: var(--space-2);
  cursor: pointer;
}

/* --- Breadcrumb --- */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--fs-sm);
  color: var(--color-text-muted);
  margin-bottom: var(--space-4);
}
.breadcrumb a {
  color: var(--color-text-muted);
  text-decoration: none;
  transition: color var(--duration-fast);
}
.breadcrumb a:hover {
  color: var(--color-primary);
}
.breadcrumb-separator {
  font-size: 10px;
  opacity: 0.5;
}
.breadcrumb-current {
  color: var(--color-text-primary);
  font-weight: var(--fw-medium);
}

/* --- Page Content --- */
.admin-content {
  flex: 1;
  padding: var(--space-6);
  max-width: var(--max-content-width);
  width: 100%;
  margin-left: auto;
  margin-right: auto;
}

/* --- Page Header --- */
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-4);
  margin-bottom: var(--space-6);
}
.page-title {
  font-size: var(--fs-2xl);
  font-weight: var(--fw-bold);
}
.page-subtitle {
  font-size: var(--fs-sm);
  color: var(--color-text-muted);
  margin-top: var(--space-1);
}

/* --- Stats Grid --- */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--space-4);
  margin-bottom: var(--space-6);
}
.stat-card {
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--color-border-light);
  display: flex;
  align-items: center;
  gap: var(--space-4);
  position: relative;
  overflow: hidden;
  transition: border-color var(--duration-normal) var(--ease-default), box-shadow var(--duration-normal) var(--ease-default), transform var(--duration-normal) var(--ease-default);
  cursor: default;
}
.stat-card:hover {
  box-shadow: var(--shadow-hover);
  border-color: var(--color-border);
  transform: translateY(-2px);
}
.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--color-border);
  z-index: 2;
}
.stat-card:has(.stat-icon-primary)::before { background: var(--color-primary); }
.stat-card:has(.stat-icon-success)::before { background: var(--color-success); }
.stat-card:has(.stat-icon-used)::before { background: var(--color-used); }
.stat-card:has(.stat-icon-danger)::before { background: var(--color-danger); }
.stat-card:has(.stat-icon-warning)::before { background: var(--color-warning); }
.stat-card:has(.stat-icon-info)::before { background: var(--color-info); }

/* Subtle corner glow */
.stat-card::after {
  content: '';
  position: absolute;
  right: -24px;
  bottom: -24px;
  width: 96px;
  height: 96px;
  border-radius: var(--radius-full);
  filter: blur(32px);
  opacity: 0.04;
  pointer-events: none;
  z-index: 1;
}
.stat-card:has(.stat-icon-primary)::after { background: var(--color-primary); }
.stat-card:has(.stat-icon-success)::after { background: var(--color-success); }
.stat-card:has(.stat-icon-used)::after { background: var(--color-used); }
.stat-card:has(.stat-icon-danger)::after { background: var(--color-danger); }
.stat-card:has(.stat-icon-warning)::after { background: var(--color-warning); }
.stat-card:has(.stat-icon-info)::after { background: var(--color-info); }

.stat-icon {
  width: 46px;
  height: 46px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--fs-lg);
  flex-shrink: 0;
  z-index: 2;
}
.stat-icon-primary { background: var(--color-primary-light); color: var(--color-primary); }
.stat-icon-success { background: #f0fdf4; color: var(--color-success); }
.stat-icon-used { background: #f8fafc; color: var(--color-used); }
.stat-icon-danger { background: #fef2f2; color: var(--color-danger); }
.stat-icon-warning { background: #fffbef; color: var(--color-warning); }
.stat-icon-info { background: #eff6ff; color: var(--color-info); }
.stat-info {
  flex: 1;
  min-width: 0;
  z-index: 2;
}
.stat-value {
  font-family: var(--font-display);
  font-size: var(--fs-2xl);
  font-weight: var(--fw-bold);
  color: var(--color-text-primary);
  line-height: 1;
}
.stat-label {
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
  margin-top: 4px;
  font-weight: var(--fw-medium);
}
.stat-trend {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 11px;
  font-weight: 600;
  margin-top: 4px;
  padding: 2px 6px;
  border-radius: var(--radius-full);
}
.stat-trend-up {
  color: #16a34a;
  background: #f0fdf4;
}
.stat-trend-down {
  color: #dc2626;
  background: #fef2f2;
}
.stat-trend-neutral {
  color: #64748b;
  background: #f8fafc;
}

/* --- Quick Actions Row --- */
.quick-actions {
  display: flex;
  gap: var(--space-3);
  margin-bottom: var(--space-6);
  flex-wrap: wrap;
}
.quick-action-btn {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: 10px 18px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  color: var(--color-text-secondary);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  cursor: pointer;
  transition: all var(--duration-fast);
  text-decoration: none;
  box-shadow: var(--shadow-xs);
}
.quick-action-btn:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
  background: color-mix(in srgb, var(--color-primary) 3%, var(--color-surface));
  box-shadow: var(--shadow-sm);
  transform: translateY(-1px);
}
.quick-action-btn i {
  font-size: var(--fs-base);
  opacity: 0.7;
}
.quick-action-btn:hover i {
  opacity: 1;
}

/* --- Dashboard Content Grid --- */
.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-6);
}
.dashboard-grid-full {
  grid-column: 1 / -1;
}

/* --- Activity Timeline --- */
.activity-timeline {
  display: flex;
  flex-direction: column;
}
.activity-item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--color-border-light);
  transition: background var(--duration-fast);
}
.activity-item:last-child {
  border-bottom: none;
}
.activity-item:hover {
  background: var(--color-bg);
  margin: 0 calc(var(--space-3) * -1);
  padding-left: var(--space-3);
  padding-right: var(--space-3);
  border-radius: var(--radius-md);
}
.activity-icon {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 11px;
}
.activity-icon-login { background: #eff6ff; color: #3b82f6; }
.activity-icon-ticket { background: #f0fdf4; color: #22c55e; }
.activity-icon-checkin { background: #faf5ff; color: #a855f7; }
.activity-icon-cancel { background: #fef2f2; color: #ef4444; }
.activity-icon-edit { background: #fffbeb; color: #f59e0b; }
.activity-icon-system { background: #f8fafc; color: #64748b; }
.activity-content {
  flex: 1;
  min-width: 0;
}
.activity-text {
  font-size: var(--fs-sm);
  color: var(--color-text-primary);
  line-height: 1.4;
}
.activity-text strong {
  font-weight: var(--fw-semibold);
}
.activity-time {
  font-size: 11px;
  color: var(--color-text-muted);
  margin-top: 2px;
}

/* --- Tabs Component --- */
.tabs {
  display: flex;
  border-bottom: 2px solid var(--color-border-light);
  gap: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin-bottom: var(--space-6);
}
.tab-item {
  padding: var(--space-3) var(--space-4);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--color-text-muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: all var(--duration-fast);
  white-space: nowrap;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.tab-item:hover {
  color: var(--color-text-primary);
  border-bottom-color: var(--color-border);
}
.tab-item.active {
  color: var(--color-primary);
  border-bottom-color: var(--color-primary);
  font-weight: var(--fw-semibold);
}
.tab-count {
  background: var(--color-bg);
  color: var(--color-text-muted);
  font-size: 11px;
  padding: 1px 7px;
  border-radius: var(--radius-full);
  font-weight: 600;
}
.tab-item.active .tab-count {
  background: color-mix(in srgb, var(--color-primary) 10%, transparent);
  color: var(--color-primary);
}

/* --- Dropdown Menu --- */
.dropdown {
  position: relative;
  display: inline-block;
}
.dropdown-menu {
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  min-width: 200px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: var(--space-1) 0;
  z-index: var(--z-dropdown);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: all var(--duration-fast) var(--ease-default);
}
.dropdown.open .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.dropdown-item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: 8px 16px;
  font-size: var(--fs-sm);
  color: var(--color-text-secondary);
  text-decoration: none;
  cursor: pointer;
  transition: all var(--duration-fast);
  border: none;
  background: none;
  width: 100%;
  text-align: left;
}
.dropdown-item:hover {
  background: var(--color-bg);
  color: var(--color-text-primary);
}
.dropdown-item i {
  width: 16px;
  text-align: center;
  opacity: 0.6;
}
.dropdown-divider {
  height: 1px;
  background: var(--color-border-light);
  margin: var(--space-1) 0;
}

/* --- Modal/Dialog --- */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(15, 23, 42, 0.4);
  backdrop-filter: blur(4px);
  z-index: var(--z-modal);
  display: none;
  align-items: center;
  justify-content: center;
  padding: var(--space-6);
}
.modal-overlay.active {
  display: flex;
}
.modal {
  background: var(--color-surface);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-modal);
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  animation: modalSlideIn var(--duration-normal) var(--ease-out);
}
@keyframes modalSlideIn {
  from { opacity: 0; transform: translateY(16px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-5) var(--space-6);
  border-bottom: 1px solid var(--color-border-light);
}
.modal-title {
  font-size: var(--fs-lg);
  font-weight: var(--fw-semibold);
}
.modal-close {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  border: none;
  background: transparent;
  color: var(--color-text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--duration-fast);
  font-size: var(--fs-md);
}
.modal-close:hover {
  background: var(--color-bg);
  color: var(--color-text-primary);
}
.modal-body {
  padding: var(--space-5) var(--space-6);
}
.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-6);
  border-top: 1px solid var(--color-border-light);
}

/* --- Progress Bar --- */
.progress-bar {
  width: 100%;
  height: 6px;
  background: var(--color-bg);
  border-radius: var(--radius-full);
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  border-radius: var(--radius-full);
  transition: width var(--duration-slow) var(--ease-out);
  background: var(--color-primary);
}
.progress-fill-success { background: var(--color-success); }
.progress-fill-warning { background: var(--color-warning); }
.progress-fill-danger { background: var(--color-danger); }

/* --- Skeleton Loading --- */
.skeleton {
  background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
  background-size: 200% 100%;
  animation: skeletonShimmer 1.5s ease-in-out infinite;
  border-radius: var(--radius-md);
}
@keyframes skeletonShimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
.skeleton-text { height: 14px; margin-bottom: 8px; }
.skeleton-title { height: 24px; width: 60%; margin-bottom: 12px; }
.skeleton-avatar { width: 40px; height: 40px; border-radius: var(--radius-full); }
.skeleton-card { height: 120px; }
.skeleton-table-row { height: 48px; margin-bottom: 4px; }

/* --- Toast Notifications --- */
.toast-container {
  position: fixed;
  top: var(--space-6);
  right: var(--space-6);
  z-index: var(--z-toast);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.toast {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-5);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  min-width: 320px;
  max-width: 480px;
  animation: toastSlideIn var(--duration-normal) var(--ease-out);
}
@keyframes toastSlideIn {
  from { opacity: 0; transform: translateX(100%); }
  to { opacity: 1; transform: translateX(0); }
}
.toast-icon {
  flex-shrink: 0;
  font-size: var(--fs-lg);
}
.toast-success .toast-icon { color: var(--color-success); }
.toast-error .toast-icon { color: var(--color-danger); }
.toast-warning .toast-icon { color: var(--color-warning); }
.toast-info .toast-icon { color: var(--color-info); }
.toast-content {
  flex: 1;
}
.toast-title {
  font-size: var(--fs-sm);
  font-weight: var(--fw-semibold);
  color: var(--color-text-primary);
}
.toast-message {
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
  margin-top: 2px;
}
.toast-close {
  background: none;
  border: none;
  color: var(--color-text-muted);
  cursor: pointer;
  padding: var(--space-1);
  border-radius: var(--radius-sm);
  transition: all var(--duration-fast);
}
.toast-close:hover {
  background: var(--color-bg);
  color: var(--color-text-primary);
}

/* --- Empty State Enhanced --- */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--space-12) var(--space-6);
  text-align: center;
}
.empty-state-icon {
  width: 72px;
  height: 72px;
  border-radius: var(--radius-full);
  background: var(--color-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: var(--color-text-muted);
  margin-bottom: var(--space-4);
}
.empty-state-title {
  font-size: var(--fs-lg);
  font-weight: var(--fw-semibold);
  color: var(--color-text-primary);
  margin-bottom: var(--space-1);
}
.empty-state-text {
  font-size: var(--fs-sm);
  color: var(--color-text-muted);
  max-width: 360px;
  line-height: var(--lh-relaxed);
}
.empty-state-action {
  margin-top: var(--space-5);
}

/* --- Filter Chips --- */
.filter-chips {
  display: flex;
  gap: var(--space-2);
  flex-wrap: wrap;
  margin-bottom: var(--space-4);
}
.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: 5px 12px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  font-size: var(--fs-xs);
  font-weight: var(--fw-medium);
  color: var(--color-text-secondary);
  background: var(--color-surface);
  cursor: pointer;
  transition: all var(--duration-fast);
  text-decoration: none;
}
.filter-chip:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}
.filter-chip.active {
  background: color-mix(in srgb, var(--color-primary) 8%, transparent);
  border-color: var(--color-primary);
  color: var(--color-primary);
}
.filter-chip-remove {
  font-size: 10px;
  margin-left: 2px;
  opacity: 0.5;
}
.filter-chip:hover .filter-chip-remove {
  opacity: 1;
}

/* --- Toolbar (Bulk Actions) --- */
.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-3) var(--space-4);
  background: color-mix(in srgb, var(--color-primary) 3%, var(--color-surface));
  border: 1px solid color-mix(in srgb, var(--color-primary) 15%, transparent);
  border-radius: var(--radius-lg);
  margin-bottom: var(--space-4);
  animation: alertSlideIn var(--duration-normal) var(--ease-out);
}
.toolbar-info {
  font-size: var(--fs-sm);
  color: var(--color-text-secondary);
  font-weight: var(--fw-medium);
}
.toolbar-actions {
  display: flex;
  gap: var(--space-2);
}

/* --- Info List (Key-Value pairs) --- */
.info-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.info-item {
  display: flex;
  align-items: flex-start;
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--color-border-light);
}
.info-item:last-child {
  border-bottom: none;
}
.info-label {
  width: 140px;
  flex-shrink: 0;
  font-size: var(--fs-sm);
  color: var(--color-text-muted);
  font-weight: var(--fw-medium);
}
.info-value {
  flex: 1;
  font-size: var(--fs-sm);
  color: var(--color-text-primary);
  font-weight: var(--fw-medium);
}

/* --- Summary Bar --- */
.summary-bar {
  display: flex;
  align-items: center;
  gap: var(--space-6);
  padding: var(--space-3) var(--space-5);
  background: var(--color-bg);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border-light);
  margin-bottom: var(--space-4);
}
.summary-item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.summary-item-value {
  font-family: var(--font-display);
  font-size: var(--fs-lg);
  font-weight: var(--fw-bold);
  color: var(--color-text-primary);
}
.summary-item-label {
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
}
.summary-divider {
  width: 1px;
  height: 28px;
  background: var(--color-border);
}

/* --- Event Card (Card Grid Layout) --- */
.event-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--space-4);
}
.event-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--duration-normal);
  cursor: pointer;
  text-decoration: none;
  color: inherit;
}
.event-card:hover {
  border-color: var(--color-border);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}
.event-card-banner {
  width: 100%;
  height: 160px;
  object-fit: cover;
  background: linear-gradient(135deg, var(--color-bg) 0%, var(--color-border-light) 100%);
}
.event-card-body {
  padding: var(--space-4);
}
.event-card-title {
  font-size: var(--fs-base);
  font-weight: var(--fw-semibold);
  color: var(--color-text-primary);
  margin-bottom: var(--space-2);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.event-card-meta {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
}
.event-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-3) var(--space-4);
  border-top: 1px solid var(--color-border-light);
}

/* --- Enhanced Pagination --- */
.pagination {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-3) var(--space-4);
  border-top: 1px solid var(--color-border-light);
}
.pagination-info {
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
}
.pagination-controls {
  display: flex;
  gap: 2px;
  align-items: center;
}
.pagination-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  height: 32px;
  padding: 0 var(--space-2);
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--color-text-secondary);
  background: transparent;
  cursor: pointer;
  transition: all var(--duration-fast);
  text-decoration: none;
}
.pagination-btn:hover:not(:disabled) {
  background: var(--color-bg);
  border-color: var(--color-border);
}
.pagination-btn.active {
  background: var(--color-primary);
  color: var(--color-text-inverse);
  border-color: var(--color-primary);
}
.pagination-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.pagination-ellipsis {
  padding: 0 var(--space-1);
  color: var(--color-text-muted);
  font-size: var(--fs-sm);
}

/* --- Mobile Responsive --- */
@media (max-width: 1024px) {
  .admin-sidebar {
    transform: translateX(-100%);
  }
  .admin-sidebar.open {
    transform: translateX(0);
  }
  .admin-main {
    margin-left: 0;
  }
  .mobile-menu-toggle {
    display: block;
  }
  .sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: calc(var(--z-sticky) - 1);
  }
  .sidebar-overlay.active {
    display: block;
  }
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
  .header-search {
    display: none;
  }
  div[style*="grid-template-columns: 1fr 2fr"] {
    grid-template-columns: 1fr !important;
    height: auto !important;
  }
}

@media (max-width: 640px) {
  .admin-content {
    padding: var(--space-4);
  }
  .admin-header {
    padding: 0 var(--space-4);
  }
  .page-header {
    flex-direction: column;
    align-items: flex-start;
  }
  .stats-grid {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-3);
  }
  .stat-card {
    padding: var(--space-3);
    gap: var(--space-3);
  }
  .stat-icon {
    width: 38px;
    height: 38px;
    font-size: var(--fs-base);
  }
  .stat-value {
    font-size: var(--fs-lg);
  }
  .quick-actions {
    flex-direction: column;
  }
  .quick-action-btn {
    justify-content: center;
  }
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
  .event-card-grid {
    grid-template-columns: 1fr;
  }
  .tabs {
    gap: 0;
    -webkit-overflow-scrolling: touch;
  }
  .pagination {
    flex-direction: column;
    gap: var(--space-3);
  }
  .summary-bar {
    flex-wrap: wrap;
    gap: var(--space-3);
  }
  .toast-container {
    right: var(--space-3);
    left: var(--space-3);
  }
  .toast {
    min-width: auto;
  }
  div[style*="grid-template-columns"] {
    grid-template-columns: 1fr !important;
  }
  div[style*="display: flex; gap: var(--space-2);"] {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
  }
  div[style*="display: flex; gap: var(--space-2);"] > * {
    width: 100%;
    text-align: center;
  }
}

@media (max-width: 420px) {
  .stats-grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
   ADMIN LOGIN PAGE
   Modern minimalist split-layout login
   ============================================================ */
.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-bg);
  position: relative;
  overflow: hidden;
  padding: var(--space-6);
}
.login-page::before {
  content: '';
  position: absolute;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(45, 194, 117, 0.06) 0%, rgba(0, 0, 0, 0) 70%);
  top: -200px;
  right: -200px;
  z-index: 1;
  pointer-events: none;
}
.login-page::after {
  content: '';
  position: absolute;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(255, 111, 60, 0.04) 0%, rgba(0, 0, 0, 0) 70%);
  bottom: -200px;
  left: -200px;
  z-index: 1;
  pointer-events: none;
}
.login-card {
  background: #ffffff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: 40px var(--space-8);
  width: 100%;
  max-width: 440px;
  box-shadow: 0 10px 25px -5px rgba(0,0,0,0.05), 0 8px 10px -6px rgba(0,0,0,0.05);
  z-index: 2;
  position: relative;
  transition: border-color 0.3s var(--ease-default), box-shadow 0.3s var(--ease-default);
}
.login-card:hover {
  box-shadow: 0 20px 25px -5px rgba(0,0,0,0.08), 0 10px 10px -5px rgba(0,0,0,0.04);
  border-color: #cbd5e1;
}
.login-header {
  text-align: center;
  margin-bottom: var(--space-6);
}
.login-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, var(--color-primary), #10b981);
  color: #ffffff;
  font-size: 24px;
  margin-bottom: var(--space-4);
  box-shadow: 0 8px 24px rgba(45, 194, 117, 0.25);
}
.login-title {
  font-family: var(--font-display);
  font-size: var(--fs-2xl);
  font-weight: 700;
  color: #0f172a;
  margin-bottom: var(--space-1);
}
.login-subtitle {
  font-size: var(--fs-sm);
  color: #64748b;
}
.login-card .form-label {
  color: #475569;
  font-weight: 500;
  font-size: var(--fs-sm);
  margin-bottom: var(--space-2);
}
.login-card .form-input {
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  color: #0f172a !important;
  padding: 12px 16px !important;
  font-size: var(--fs-base) !important;
  border-radius: var(--radius-md) !important;
  transition: all 0.2s !important;
}
.login-card .form-input::placeholder {
  color: #94a3b8 !important;
}
.login-card .form-input:focus {
  background: #ffffff !important;
  border-color: var(--color-primary) !important;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--color-primary) 15%, transparent) !important;
  outline: none !important;
}
.login-card .alert-error {
  background: #fef2f2 !important;
  border: 1px solid #fecaca !important;
  color: #dc2626 !important;
  border-radius: var(--radius-md) !important;
  padding: var(--space-3) var(--space-4) !important;
  margin-bottom: var(--space-4) !important;
  font-size: var(--fs-sm) !important;
  display: flex !important;
  align-items: center !important;
  gap: var(--space-2) !important;
}
.login-card a {
  color: #64748b;
  text-decoration: none;
  transition: color 0.2s;
  font-weight: 500;
}
.login-card a:hover {
  color: var(--color-primary);
}

/* --- Utility: Section Header (for cards) --- */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-4);
  padding-bottom: var(--space-3);
  border-bottom: 1px solid var(--color-border-light);
}
.section-title {
  font-size: var(--fs-base);
  font-weight: var(--fw-semibold);
  color: var(--color-text-primary);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.section-title i {
  color: var(--color-text-muted);
  font-size: var(--fs-sm);
}

/* --- Welcome Banner --- */
.welcome-banner {
  background: linear-gradient(135deg, var(--color-primary) 0%, #10b981 100%);
  border-radius: var(--radius-xl);
  padding: var(--space-6) var(--space-8);
  margin-bottom: var(--space-6);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
}
.welcome-banner::before {
  content: '';
  position: absolute;
  right: -30px;
  top: -30px;
  width: 200px;
  height: 200px;
  border-radius: var(--radius-full);
  background: rgba(255,255,255,0.08);
  pointer-events: none;
}
.welcome-banner::after {
  content: '';
  position: absolute;
  right: 60px;
  bottom: -40px;
  width: 140px;
  height: 140px;
  border-radius: var(--radius-full);
  background: rgba(255,255,255,0.05);
  pointer-events: none;
}
.welcome-text h2 {
  color: #ffffff;
  font-size: var(--fs-xl);
  font-weight: var(--fw-bold);
  margin-bottom: var(--space-1);
}
.welcome-text p {
  color: rgba(255,255,255,0.8);
  font-size: var(--fs-sm);
}
.welcome-actions {
  display: flex;
  gap: var(--space-3);
  z-index: 2;
}
.welcome-btn {
  padding: 8px 20px;
  border-radius: var(--radius-md);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  text-decoration: none;
  transition: all var(--duration-fast);
}
.welcome-btn-primary {
  background: rgba(255,255,255,0.2);
  color: #ffffff;
  border: 1px solid rgba(255,255,255,0.3);
}
.welcome-btn-primary:hover {
  background: rgba(255,255,255,0.3);
  color: #ffffff;
}


/* ════════════════════════════════════════════════════════════
   Admin notification bell dropdown
   ════════════════════════════════════════════════════════════ */
.notif-wrap { position: relative; }
.notif-dot {
  position: absolute; top: 6px; right: 6px;
  width: 9px; height: 9px; border-radius: 50%;
  background: #ef4444; border: 2px solid var(--color-surface, #fff);
  animation: sidebarBadgePulse 1.8s ease-in-out infinite;
}
.notif-panel {
  position: absolute; top: calc(100% + 10px); right: 0;
  width: 360px; max-width: calc(100vw - 32px);
  background: var(--color-surface, #fff);
  border: 1px solid var(--color-border, #e5e7eb);
  border-radius: 14px;
  box-shadow: 0 20px 50px -16px rgba(16,24,40,0.35);
  z-index: 1000; overflow: hidden;
  animation: notifPop 0.18s ease;
}
@keyframes notifPop { from { transform: translateY(-6px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.notif-panel__head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; border-bottom: 1px solid var(--color-border-light, #eef0f3);
  font-weight: 700; font-size: var(--fs-sm); color: var(--color-text);
}
.notif-refresh { border: 0; background: transparent; color: var(--color-text-muted); cursor: pointer; font-size: 14px; }
.notif-refresh:hover { color: var(--color-primary); }
.notif-panel__list { max-height: 420px; overflow-y: auto; }
.notif-empty { padding: 32px 16px; text-align: center; color: var(--color-text-muted); font-size: var(--fs-sm); }
.notif-item {
  display: flex; gap: 12px; padding: 12px 16px; text-decoration: none;
  border-bottom: 1px solid var(--color-border-light, #f1f5f9);
  transition: background 0.12s;
}
.notif-item:hover { background: var(--color-bg, #f8fafc); }
.notif-item.unread { background: color-mix(in srgb, var(--color-primary) 6%, transparent); }
.notif-item__icon {
  width: 38px; height: 38px; border-radius: 10px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; font-size: 15px;
}
.notif-item__body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.notif-item__title { font-size: 13px; font-weight: 700; color: var(--color-text); }
.notif-item__text { font-size: 12px; color: var(--color-text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.notif-item__time { font-size: 11px; color: var(--color-text-muted); opacity: 0.8; }
.notif-panel__foot {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 16px; border-top: 1px solid var(--color-border-light, #eef0f3);
}
.notif-page-btn {
  border: 1px solid var(--color-border); background: var(--color-surface);
  border-radius: 8px; padding: 5px 12px; font-size: 12px; font-weight: 600;
  cursor: pointer; color: var(--color-text);
}
.notif-page-btn:hover { border-color: var(--color-primary); color: var(--color-primary); }
#notifPageInfo { font-size: 12px; color: var(--color-text-muted); }
