* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Inter','Segoe UI',sans-serif; background: #f0f2f5; color: #1a1a2e; display: flex; min-height: 100vh; }

body.login-page {
  display: flex; align-items: center; justify-content: center;
  background: url('/assets/images/login-bg.jpg') center/cover no-repeat fixed;
  min-height: 100vh; position: relative;
}
body.login-page::before {
  content: ''; position: fixed; inset: 0;
  background: rgba(0,0,0,0.35); z-index: 0;
}
.login-container { width: 100%; position: relative; z-index: 1; }
.login-box { background: rgba(255,255,255,0.92); backdrop-filter: blur(10px); padding: 45px; border-radius: 16px; width: 420px; max-width: 92%; margin: auto; box-shadow: 0 20px 60px rgba(0,0,0,0.3); }
.login-box h1 { text-align: center; margin-bottom: 5px; font-size: 28px; }
.login-box h1 span { color: #e94560; }
.login-box p.sub { text-align: center; color: #888; font-size: 13px; margin-bottom: 28px; }
.login-box .btn-block { width: 100%; padding: 14px; }

.sidebar {
  width: 220px; background: #1a1a2e; color: white; position: fixed; top: 0; left: 0; height: 100%; z-index: 100;
  display: flex; flex-direction: column;
}
.sidebar .logo { padding: 24px 20px 20px; font-size: 22px; font-weight: 800; letter-spacing: -0.5px; border-bottom: 1px solid rgba(255,255,255,0.06); }
.sidebar .logo span { color: #e94560; }
.sidebar .logo small { display: block; font-size: 11px; font-weight: 400; opacity: 0.35; margin-top: 2px; }
.sidebar nav { flex: 1; padding: 12px 0; overflow-y: auto; }
.sidebar nav a {
  display: flex; align-items: center; gap: 12px; padding: 11px 20px; margin: 2px 8px; border-radius: 8px;
  color: rgba(255,255,255,0.55); text-decoration: none; transition: all 0.2s; font-size: 13px; font-weight: 500;
}
.sidebar nav a:hover { background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.9); }
.sidebar nav a.active { background: rgba(233,69,96,0.15); color: #e94560; }
.sidebar nav a .icon { font-size: 18px; width: 22px; text-align: center; flex-shrink: 0; }
.sidebar-footer { padding: 16px; border-top: 1px solid rgba(255,255,255,0.06); }
.sidebar-footer .user-info { font-size: 12px; color: rgba(255,255,255,0.5); margin-bottom: 8px; }
.sidebar-footer .user-info small { display: block; }
.sidebar-footer .logout-btn { display: block; padding: 8px; background: rgba(255,255,255,0.06); border: none; color: rgba(255,255,255,0.6); border-radius: 8px; cursor: pointer; font-size: 13px; text-align: center; text-decoration: none; transition: 0.2s; }
.sidebar-footer .logout-btn:hover { background: rgba(233,69,96,0.2); color: #e94560; }

.main-content { margin-left: 220px; flex: 1; padding: 24px; min-height: 100vh; }

.page-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; padding-bottom: 16px; border-bottom: 1px solid #e8e8e8; flex-wrap: wrap; gap: 12px; }
.page-header h1 { font-size: 24px; font-weight: 700; letter-spacing: -0.5px; }
.header-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }

.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 16px; margin-bottom: 24px; }
.stat-card {
  background: white; padding: 20px; border-radius: 12px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04); display: flex; flex-direction: column; transition: 0.2s;
}
.stat-card:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.08); }
.stat-card .stat-icon { font-size: 22px; margin-bottom: 8px; }
.stat-card .stat-value { font-size: 26px; font-weight: 700; letter-spacing: -1px; }
.stat-card .stat-label { font-size: 12px; color: #888; margin-top: 2px; font-weight: 500; text-transform: uppercase; letter-spacing: 0.3px; }
.stat-card .stat-desc { font-size: 11px; color: #10b981; margin-top: 4px; font-weight: 600; }
.stat-card .stat-desc.danger { color: #ef4444; }
.text-warning { color: #f59e0b; }

.card { background: white; border-radius: 12px; box-shadow: 0 1px 3px rgba(0,0,0,0.04); margin-bottom: 24px; overflow: hidden; }
.card-header { padding: 16px 24px; border-bottom: 1px solid #f0f0f0; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; }
.card-header h2 { font-size: 15px; font-weight: 600; }
.card-body { padding: 16px 24px; overflow-x: auto; }

.table { width: 100%; border-collapse: collapse; font-size: 13px; }
.table th { background: #f8f9fa; padding: 11px 14px; text-align: left; font-weight: 600; font-size: 11px; text-transform: uppercase; letter-spacing: 0.5px; color: #888; white-space: nowrap; }
.table td { padding: 11px 14px; border-top: 1px solid #f0f0f0; vertical-align: middle; }
.table tbody tr { transition: 0.15s; }
.table tbody tr:nth-child(even) { background: #fafbfc; }
.table tbody tr:hover { background: #f0f2ff; }
.table .actions { display: flex; gap: 4px; flex-wrap: nowrap; }
.table .badge { padding: 3px 10px; border-radius: 20px; font-size: 10px; font-weight: 600; display: inline-block; letter-spacing: 0.2px; }
.badge-success { background: #d4edda; color: #155724; }
.badge-warning { background: #fff3cd; color: #856404; }
.badge-danger { background: #f8d7da; color: #721c24; }
.badge-info { background: #d1ecf1; color: #0c5460; }
.badge-secondary { background: #e2e3e5; color: #383d41; }

.search-box { display: flex; gap: 8px; flex-wrap: wrap; }
.search-box input, .search-box select { padding: 8px 14px; border: 2px solid #e8e8e8; border-radius: 8px; font-size: 13px; outline: none; transition: 0.2s; }
.search-box input:focus, .search-box select:focus { border-color: #1a1a2e; }

.btn { padding: 8px 18px; border: none; border-radius: 8px; cursor: pointer; font-size: 13px; font-weight: 600; transition: all 0.2s; display: inline-flex; align-items: center; gap: 6px; text-decoration: none; }
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: #1a1a2e; color: white; }
.btn-primary:hover { background: #570d1f; }
.btn-danger { background: #ef4444; color: white; }
.btn-danger:hover { background: #dc2626; }
.btn-success { background: #10b981; color: white; }
.btn-success:hover { background: #059669; }
.btn-warning { background: #f59e0b; color: white; }
.btn-warning:hover { background: #d97706; }
.btn-secondary { background: #6b7280; color: white; }
.btn-secondary:hover { background: #4b5563; }
.btn-info { background: #0ea5e9; color: white; }
.btn-sm { padding: 5px 10px; font-size: 11px; border-radius: 6px; }

.form-group { margin-bottom: 16px; }
.form-group label { display: block; margin-bottom: 6px; font-weight: 600; font-size: 13px; color: #444; }
.form-group input, .form-group select, .form-group textarea {
  width: 100%; padding: 10px 14px; border: 2px solid #e8e8e8; border-radius: 8px; font-size: 13px; outline: none; transition: 0.2s;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { border-color: #1a1a2e; }
.form-group textarea { resize: vertical; min-height: 60px; }
.form-row { display: flex; gap: 16px; flex-wrap: wrap; }
.form-row .form-group { flex: 1; min-width: 130px; }

.modal { display: none; position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.5); z-index: 200; align-items: center; justify-content: center; }
.modal.active { display: flex; }
.modal-content { background: white; border-radius: 16px; padding: 28px; width: 640px; max-width: 94%; max-height: 88vh; overflow-y: auto; position: relative; box-shadow: 0 20px 60px rgba(0,0,0,0.15); }
.modal-lg { width: 860px; }
.modal-close { position: absolute; top: 16px; right: 18px; font-size: 22px; cursor: pointer; background: none; border: none; color: #999; transition: 0.2s; width: 32px; height: 32px; border-radius: 6px; display: flex; align-items: center; justify-content: center; }
.modal-close:hover { background: #f0f0f0; color: #333; }
.modal h2 { margin-bottom: 20px; font-size: 20px; font-weight: 700; }
.modal-footer { margin-top: 20px; padding-top: 16px; border-top: 1px solid #f0f0f0; display: flex; justify-content: flex-end; gap: 10px; }

.alert { padding: 14px 20px; border-radius: 10px; margin-bottom: 20px; font-size: 13px; font-weight: 600; }
.alert-success { background: #d4edda; color: #155724; border: 1px solid #c3e6cb; }
.alert-error { background: #f8d7da; color: #721c24; border: 1px solid #f5c6cb; }

.progress-bar { height: 6px; background: #e8e8e8; border-radius: 4px; overflow: hidden; margin: 4px 0; }
.progress-bar .progress-fill { height: 100%; border-radius: 4px; transition: width 0.4s; }
.progress-fill.green { background: #10b981; }
.progress-fill.yellow { background: #f59e0b; }
.progress-fill.red { background: #ef4444; }

.pagination { display: flex; gap: 6px; justify-content: center; padding: 16px 0; }
.page-link { padding: 6px 12px; border: 1px solid #e8e8e8; border-radius: 6px; text-decoration: none; color: #333; font-size: 13px; transition: 0.2s; }
.page-link:hover { background: #f0f2ff; }
.page-link.active { background: #1a1a2e; color: white; border-color: #1a1a2e; }

.empty-state { text-align: center; padding: 40px; color: #888; }

@media (max-width: 768px) {
  .sidebar { width: 200px; }
  .main-content { margin-left: 200px; padding: 16px; }
  .stats-grid { grid-template-columns: repeat(2,1fr); gap: 10px; }
  .page-header { flex-direction: column; align-items: flex-start; }
  .form-row { flex-direction: column; gap: 0; }
}
