/* =============================================
   SELF MADE SOCIETY — Admin Panel Stylesheet
   ============================================= */

/* ===== SIDEBAR (Dashboard & Admin) ===== */
.sidebar {
  position: fixed; left: 0; top: 0; bottom: 0; width: 258px;
  background: var(--navy); z-index: 900; overflow-y: auto;
  transition: transform .3s ease;
}
.sidebar::-webkit-scrollbar { width: 3px; }
.sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,.2); }

.sidebar-brand {
  padding: 20px 22px 16px; border-bottom: 1px solid rgba(255,255,255,.08);
  display: flex; align-items: center; gap: 10px;
}
.sidebar-brand-text { font-family: 'Poppins',sans-serif; font-size: .85rem; font-weight: 700; color: #fff; line-height: 1.2; }
.sidebar-brand-sub  { font-size: .65rem; color: var(--orange); font-weight: 600; letter-spacing: .5px; }

.sidebar-section-label {
  padding: 18px 22px 6px; font-size: .63rem; font-weight: 700;
  letter-spacing: 2px; text-transform: uppercase; color: rgba(255,255,255,.35);
}
.sidebar-item {
  display: flex; align-items: center; gap: 12px; padding: 11px 22px;
  color: rgba(255,255,255,.65); font-size: .855rem; font-weight: 500;
  transition: var(--tr); border-left: 3px solid transparent;
}
.sidebar-item i { width: 18px; text-align: center; font-size: .9rem; }
.sidebar-item:hover, .sidebar-item.active {
  color: #fff; background: rgba(255,255,255,.08); border-left-color: var(--orange);
}
.sidebar-item .sidebar-badge {
  margin-left: auto; background: var(--orange); color: #fff;
  font-size: .65rem; font-weight: 700; padding: 1px 7px; border-radius: 100px;
}

/* Main content (dashboard) */
.dash-content {
  margin-left: 258px; min-height: 100vh; background: var(--bg);
  transition: margin .3s ease;
}
.topbar {
  background: var(--surface); padding: 14px 28px;
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between;
  position: sticky; top: 0; z-index: 100; box-shadow: var(--shadow-xs);
}

/* Dash Stat Card */
.dash-stat {
  background: var(--surface); border-radius: var(--radius);
  padding: 20px 22px; box-shadow: var(--shadow-xs);
  display: flex; align-items: center; gap: 16px;
}
.dash-stat-icon {
  width: 50px; height: 50px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.25rem; flex-shrink: 0;
}
.dash-stat-num { font-family: 'Poppins',sans-serif; font-size: 1.6rem; font-weight: 800; color: var(--navy); }
.dash-stat-label { font-size: .78rem; font-weight: 600; color: var(--text-muted); }
.dash-stat-change { font-size: .75rem; font-weight: 600; margin-top: 2px; }
.change-up   { color: var(--green); }
.change-down { color: #dc2626; }

/* ===== DATA TABLE ===== */
.data-table { width: 100%; border-collapse: collapse; }
.data-table thead { position: sticky; top: 0; }
.data-table th {
  background: var(--bg); padding: 11px 16px; text-align: left;
  font-size: .72rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .6px; color: var(--text-muted); border-bottom: 2px solid var(--border);
  white-space: nowrap;
}
.data-table td {
  padding: 13px 16px; font-size: .86rem; border-bottom: 1px solid #F3F4F6;
  vertical-align: middle; color: var(--text);
}
.data-table tr:last-child td { border-bottom: none; }
.data-table tbody tr:hover td { background: #FAFBFF; }

/* ===== MOBILE SIDEBAR OVERLAY ===== */
.sidebar-overlay {
  display: none; position: fixed; inset: 0;
  background: rgba(0,0,0,.45); z-index: 850;
}
.sidebar-overlay.active { display: block; }

@media (max-width: 1024px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .dash-content { margin-left: 0 !important; }
}

/* ===== ADMIN LAYOUT ===== */
.admin-body { margin: 0; padding: 0; background: var(--bg); }
.admin-main {
  margin-left: 258px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: margin .3s ease;
}
.admin-content {
  padding: 28px 32px;
  flex: 1;
}
@media (max-width: 1024px) {
  .admin-main  { margin-left: 0; }
  .admin-content { padding: 20px 16px; }
}
