:root {
    --sidebar-width: 292px;
    --primary: #5b2cff;
    --primary-dark: #3817bd;
    --ink: #101828;
    --muted: #667085;
    --line: #e6eaf2;
    --soft: #f6f8fb;
}

* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: #f7f9fc;
    color: var(--ink);
}
a { text-decoration: none; }

.auth-bg {
    min-height: 100vh;
    display: grid;
    place-items: center;
    background: radial-gradient(circle at top left, #6d4dff 0, transparent 34%), linear-gradient(135deg, #071225, #0d1830 60%, #050b16);
}
.auth-card {
    width: min(440px, calc(100vw - 32px));
    background: rgba(255,255,255,.96);
    border-radius: 24px;
    padding: 36px;
    box-shadow: 0 24px 70px rgba(0,0,0,.25);
}
.logo-tile {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, #2f7dff, #7b2cff);
    color: #fff;
    font-weight: 800;
    font-size: 22px;
    box-shadow: 0 12px 24px rgba(91,44,255,.28);
}
.admin-shell { display: flex; min-height: 100vh; }
.sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: var(--sidebar-width);
    background: linear-gradient(180deg, #06122a, #020912);
    padding: 24px 18px;
    color: #fff;
    overflow-y: auto;
    z-index: 1000;
}
.sidebar-brand { display: flex; align-items: center; gap: 14px; padding: 0 0 22px; border-bottom: 1px solid rgba(255,255,255,.08); }
.sidebar-brand h1 { font-size: 20px; margin: 0; line-height: 1.1; }
.sidebar-brand span { color: #9daac3; font-size: 13px; }
.sidebar-nav { margin-top: 22px; display: grid; gap: 6px; }
.sidebar-link {
    display: flex; align-items: center; gap: 14px;
    color: rgba(255,255,255,.86);
    padding: 13px 14px;
    border-radius: 12px;
    font-weight: 500;
}
.sidebar-link:hover, .sidebar-link.active { color: #fff; background: linear-gradient(135deg, #6039ff, #7138ff); box-shadow: 0 10px 24px rgba(91,44,255,.25); }
.sidebar-link.text-danger:hover { background: rgba(255,71,87,.12); color: #ff6b81 !important; box-shadow: none; }
.content-wrap { margin-left: var(--sidebar-width); width: calc(100% - var(--sidebar-width)); min-height: 100vh; }
.topbar {
    height: 88px; background: rgba(255,255,255,.9); backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--line); display: flex; align-items: center;
    padding: 0 26px; gap: 20px; position: sticky; top: 0; z-index: 900;
}
.page-title { margin: 0; font-size: 23px; font-weight: 800; }
.page-subtitle { margin: 2px 0 0; color: var(--muted); }
.top-search { max-width: 420px; margin-left: auto; position: relative; }
.top-search .form-control { border-radius: 12px; padding: 12px 44px 12px 16px; }
.top-search i { position: absolute; right: 15px; top: 50%; transform: translateY(-50%); color: #52617a; }
.admin-avatar { width: 44px; height: 44px; border-radius: 50%; background: linear-gradient(135deg,#18b28d,#5b2cff); display: grid; place-items: center; color: #fff; font-weight: 700; }
.main { padding: 24px 26px 34px; }
.card-clean {
    background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: 0 8px 30px rgba(16,24,40,.04);
}
.stat-card { padding: 24px; min-height: 132px; display: flex; gap: 18px; align-items: center; }
.stat-icon { width: 60px; height: 60px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-size: 26px; flex: none; }
.bg-purple { background: linear-gradient(135deg,#6f3cff,#4b30e8); }
.bg-blue { background: linear-gradient(135deg,#25a8ff,#1f6bf2); }
.bg-green { background: linear-gradient(135deg,#36c789,#11a86a); }
.bg-orange { background: linear-gradient(135deg,#ffad42,#ff7d28); }
.bg-red { background: linear-gradient(135deg,#ff6878,#ff334e); }
.bg-teal { background: linear-gradient(135deg,#1fc7bb,#0b9e8d); }
.stat-label { color: #344054; font-size: 14px; margin-bottom: 6px; }
.stat-value { font-size: 28px; font-weight: 800; letter-spacing: -.03em; }
.stat-growth { color: #079455; font-size: 13px; }
.table { vertical-align: middle; }
.table th { color: #475467; font-weight: 700; font-size: 13px; background: #fbfcff; }
.thumb { width: 46px; height: 46px; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); background: #f2f4f7; }
.thumb-sm { width: 34px; height: 34px; object-fit: cover; border-radius: 8px; }
.form-control, .form-select { border-color: #d9e1ee; border-radius: 11px; }
.btn { border-radius: 11px; font-weight: 600; }
.btn-primary { background: linear-gradient(135deg,#6236ff,#4324d9); border: none; }
.btn-outline-primary { border-color: #6236ff; color: #4b22e8; }
.btn-outline-primary:hover { background: #6236ff; border-color: #6236ff; }
.badge { font-weight: 600; }
.footer { color: #53657e; font-size: 13px; padding: 10px 0 24px; text-align: center; }
.section-title { font-size: 17px; font-weight: 800; margin: 0; }
.meta-muted { color: var(--muted); font-size: 13px; }
.empty-state { padding: 42px; text-align: center; color: #667085; }
.actions-cell { white-space: nowrap; }

@media (max-width: 992px) {
    :root { --sidebar-width: 0px; }
    .sidebar { transform: translateX(-100%); transition: .25s ease; }
    .sidebar.open { transform: translateX(0); width: 280px; }
    .content-wrap { margin-left: 0; width: 100%; }
    .top-search { display: none; }
}


/* ===== MODERN ADMIN UI UPGRADE ===== */

body{
  background:#0b0f1a;
  color:#e6e6e6;
  font-family:system-ui,-apple-system,Segoe UI,Roboto;
}

.sidebar{
  background:rgba(255,255,255,0.04);
  backdrop-filter: blur(12px);
  border-right:1px solid rgba(255,255,255,0.08);
}

.card, .panel{
  background:rgba(255,255,255,0.06);
  border-radius:16px;
  border:1px solid rgba(255,255,255,0.08);
  box-shadow:0 10px 30px rgba(0,0,0,0.3);
}

button, .btn{
  border-radius:10px;
  background:linear-gradient(135deg,#6c5ce7,#00d2ff);
  color:white;
  border:none;
}

input, select, textarea{
  background:rgba(255,255,255,0.06);
  border:1px solid rgba(255,255,255,0.08);
  color:white;
  border-radius:10px;
  padding:10px;
}

table{
  width:100%;
  border-collapse:collapse;
}

table tr{
  border-bottom:1px solid rgba(255,255,255,0.06);
}

table td, table th{
  padding:12px;
}

