/* =====================================================================
   Premium MLM Software — futuristic theme (on Bootstrap 5.3)
   Matte-black canvas · teal → electric-cyan accent (matches imaginatrix.app)
   Dark (default) + light, both around the same accent.
   ===================================================================== */
:root {
    --bg-0: #030809;
    --bg-1: #06100f;
    --bg-2: #0a1a19;
    --bg-3: #0e2422;

    --teal: #147d6c;
    --cyan: #1effff;
    --cyan-soft: #64f4e6;

    --brand: #1effff;
    --brand-rgb: 30, 255, 255;
    --brand-2: #147d6c;
    --brand-3: #64f4e6;
    --brand-grad: linear-gradient(120deg, #147d6c 0%, #1effff 100%);
    --brand-grad-soft: linear-gradient(120deg, rgba(20,125,108,.9), rgba(30,255,255,.9));
    --glow: 0 0 24px rgba(30, 255, 255, .22), 0 0 60px rgba(30, 255, 255, .06);

    --sidebar-w: 266px;
    --topbar-h: 66px;
    --radius: 16px;
    --radius-sm: 11px;
    --ease: cubic-bezier(.22, 1, .36, 1);

    --font-display: "Space Grotesk", "Segoe UI", sans-serif;
    --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
    --font-mono: "JetBrains Mono", "Consolas", monospace;
}

/* ---------------- Dark (default, matte black) ---------------- */
:root,
[data-bs-theme="dark"] {
    color-scheme: dark;
    --bs-primary: #1effff;
    --bs-primary-rgb: 30, 255, 255;
    --bs-body-bg: #030809;
    --bs-body-color: #b8d6d1;
    --bs-emphasis-color: #eafffb;
    --bs-border-color: rgba(30, 255, 255, .12);
    --bs-link-color: #64f4e6;
    --bs-link-hover-color: #1effff;

    --app-surface: rgba(9, 22, 20, .55);
    --app-surface-2: rgba(10, 26, 25, .8);
    --app-solid: #08120f;
    --app-border: rgba(30, 255, 255, .12);
    --app-border-strong: rgba(30, 255, 255, .28);
    --app-muted: #7d9b96;
    --app-sidebar-bg: rgba(4, 11, 11, .72);
    --app-topbar-bg: rgba(4, 11, 11, .62);
    --card-shadow: 0 1px 2px rgba(0, 0, 0, .5), 0 12px 32px rgba(0, 0, 0, .28);
    --ambient: 1;
}

/* ---------------- Light (teal-tinted) ---------------- */
[data-bs-theme="light"] {
    color-scheme: light;
    --bs-primary: #0c8f7d;
    --bs-primary-rgb: 12, 143, 125;
    --bs-body-bg: #eef4f3;
    --bs-body-color: #2b4a45;
    --bs-emphasis-color: #08302a;
    --bs-border-color: #d7e7e3;
    --bs-link-color: #0c8f7d;
    --bs-link-hover-color: #0a7263;

    --brand: #0c8f7d;
    --brand-rgb: 12, 143, 125;
    --brand-grad: linear-gradient(120deg, #0c8f7d 0%, #14b8b0 100%);
    --glow: 0 0 0 rgba(0, 0, 0, 0);

    --app-surface: #ffffff;
    --app-surface-2: #f6faf9;
    --app-solid: #ffffff;
    --app-border: #dceae6;
    --app-border-strong: #bfe0d9;
    --app-muted: #5f857e;
    --app-sidebar-bg: #ffffff;
    --app-topbar-bg: rgba(255, 255, 255, .86);
    --card-shadow: 0 1px 2px rgba(16, 42, 38, .05), 0 10px 26px rgba(16, 42, 38, .06);
    --ambient: 0;
}

* { -webkit-font-smoothing: antialiased; }
body {
    font-family: var(--font-body);
    background: var(--bs-body-bg);
    color: var(--bs-body-color);
    min-height: 100vh;
    overflow-x: hidden;
}
h1, h2, h3, h4, h5, h6, .fw-bold, .fw-bolder { font-family: var(--font-display); letter-spacing: -.01em; }
a { text-decoration: none; }
.text-muted, .text-secondary { color: var(--app-muted) !important; }

/* Gradient text helper */
.grad-text {
    background: var(--brand-grad); -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: transparent;
}

/* ---------------- Ambient matte-black backdrop (dark only) ---------------- */
body::before, body::after {
    content: ""; position: fixed; inset: 0; z-index: -2; pointer-events: none;
    opacity: var(--ambient); transition: opacity .4s;
}
/* aurora glow */
body::before {
    background:
        radial-gradient(50vw 50vw at 82% -8%, rgba(20, 125, 108, .35), transparent 60%),
        radial-gradient(46vw 46vw at 2% 108%, rgba(30, 255, 255, .12), transparent 62%);
    filter: blur(30px);
}
/* faint HUD grid */
body::after {
    background-image:
        linear-gradient(rgba(30, 255, 255, .035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(30, 255, 255, .035) 1px, transparent 1px);
    background-size: 60px 60px;
    -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, #000 25%, transparent 88%);
    mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, #000 25%, transparent 88%);
}

/* ---------------- App shell ---------------- */
.app-body { display: flex; min-height: 100vh; }
.app-sidebar {
    position: fixed; inset: 0 auto 0 0; z-index: 1040;
    width: var(--sidebar-w); height: 100vh; overflow-y: auto;
    background: var(--app-sidebar-bg);
    backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
    border-right: 1px solid var(--app-border);
    display: flex; flex-direction: column;
    transition: transform .28s var(--ease);
}
.app-main { flex: 1; margin-left: var(--sidebar-w); min-width: 0; display: flex; flex-direction: column; }
.app-content { padding: 26px; flex: 1; }
.app-footer {
    padding: 16px 26px; border-top: 1px solid var(--app-border);
    color: var(--app-muted); font-family: var(--font-mono); font-size: .78rem;
    display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px;
}
.app-footer a { color: var(--cyan-soft); }

/* Sidebar brand */
.sb-brand {
    display: flex; align-items: center; gap: 12px;
    height: var(--topbar-h); padding: 0 20px;
    border-bottom: 1px solid var(--app-border);
    color: var(--bs-emphasis-color); font-weight: 700; letter-spacing: -.2px;
    font-family: var(--font-display);
    position: sticky; top: 0; background: var(--app-sidebar-bg); z-index: 2;
    backdrop-filter: blur(16px);
}
.sb-logo {
    width: 36px; height: 36px; border-radius: 10px; flex: 0 0 36px;
    background: var(--brand-grad); color: #03110f;
    display: grid; place-items: center; font-size: 1.05rem;
    box-shadow: 0 4px 16px rgba(var(--brand-rgb), .4);
}
.sb-brand small {
    display: block; font-weight: 500; font-size: .62rem; color: var(--app-muted);
    letter-spacing: .18em; text-transform: uppercase; font-family: var(--font-mono);
}

/* Sidebar nav */
.sb-nav { padding: 14px 12px; flex: 1; }
.sb-head {
    font-family: var(--font-mono); font-size: .64rem; text-transform: uppercase;
    letter-spacing: .18em; color: var(--app-muted); padding: 15px 12px 7px; font-weight: 500;
}
.sb-head::before { content: "// "; color: var(--teal); }
.sb-link {
    position: relative; display: flex; align-items: center; gap: 12px;
    padding: 10px 13px; margin-bottom: 2px; border-radius: 11px;
    color: var(--bs-body-color); font-weight: 500; font-size: .9rem;
    transition: background .2s, color .2s, box-shadow .3s;
}
.sb-link i { font-size: 1.05rem; width: 20px; text-align: center; opacity: .85; }
.sb-link:hover { background: rgba(var(--brand-rgb), .08); color: var(--cyan); }
.sb-link.active {
    background: linear-gradient(100deg, rgba(var(--brand-rgb), .16), rgba(var(--brand-rgb), .03));
    color: var(--cyan);
    box-shadow: inset 0 0 0 1px rgba(var(--brand-rgb), .25), 0 0 22px rgba(var(--brand-rgb), .08);
}
.sb-link.active::before {
    content: ""; position: absolute; left: 0; top: 22%; bottom: 22%; width: 3px;
    border-radius: 3px; background: var(--brand-grad); box-shadow: 0 0 10px var(--cyan);
}
.sb-link.active i { opacity: 1; }
.sb-link .badge { margin-left: auto; }

/* ---------------- Topbar ---------------- */
.app-topbar {
    position: sticky; top: 0; z-index: 1030;
    height: var(--topbar-h); padding: 0 24px;
    display: flex; align-items: center; gap: 14px;
    background: var(--app-topbar-bg);
    backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--app-border);
}
.app-topbar h1 { font-family: var(--font-display); font-size: 1.05rem; font-weight: 700; margin: 0; color: var(--bs-emphasis-color); }
.topbar-btn {
    width: 40px; height: 40px; border-radius: 11px; border: 1px solid var(--app-border);
    background: var(--app-surface); color: var(--bs-body-color);
    display: inline-grid; place-items: center; font-size: 1.1rem;
    transition: color .2s, border-color .2s, box-shadow .2s;
}
.topbar-btn:hover { color: var(--cyan); border-color: var(--app-border-strong); box-shadow: var(--glow); }
.sidebar-toggle { display: none; }

/* ---------------- Cards & surfaces ---------------- */
.card {
    position: relative;
    background: var(--app-surface);
    backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--app-border);
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    transition: border-color .35s var(--ease), box-shadow .35s var(--ease), transform .35s var(--ease);
}
.card-header {
    background: transparent; border-bottom: 1px solid var(--app-border);
    font-family: var(--font-display); font-weight: 600; padding: 16px 20px;
    color: var(--bs-emphasis-color);
}
.card-body { padding: 20px; }

/* Stat / KPI cards — glow + HUD corner brackets */
.stat-card { overflow: hidden; }
.stat-card::after {
    content: ""; position: absolute; inset: 0;
    background: radial-gradient(170px circle at var(--sx, 85%) var(--sy, 0%), rgba(var(--brand-rgb), .13), transparent 65%);
    pointer-events: none; opacity: 0; transition: opacity .4s;
}
.stat-card:hover { border-color: var(--app-border-strong); box-shadow: var(--card-shadow), var(--glow); transform: translateY(-3px); }
.stat-card:hover::after { opacity: 1; }
.stat-icon {
    width: 48px; height: 48px; border-radius: 13px; display: grid; place-items: center;
    font-size: 1.3rem; flex: 0 0 48px;
    border: 1px solid rgba(var(--brand-rgb), .18);
}
.stat-label { font-family: var(--font-mono); font-size: .68rem; color: var(--app-muted); font-weight: 500; text-transform: uppercase; letter-spacing: .12em; }
.stat-value { font-family: var(--font-display); font-size: 1.55rem; font-weight: 700; letter-spacing: -.5px; color: var(--bs-emphasis-color); line-height: 1.12; }

.bg-grad { background: var(--brand-grad) !important; color: #03110f !important; }
.bg-soft-primary { background: rgba(var(--brand-rgb), .12); color: var(--cyan); }
.bg-soft-success { background: rgba(35, 209, 139, .14); color: #34e0a1; }
.bg-soft-warning { background: rgba(255, 196, 84, .14); color: #ffc454; }
.bg-soft-info    { background: rgba(30, 255, 255, .12); color: var(--cyan); }
.bg-soft-danger  { background: rgba(255, 107, 122, .16); color: #ff6b7a; }
[data-bs-theme="light"] .bg-soft-primary,
[data-bs-theme="light"] .bg-soft-info { color: #0c8f7d; }
[data-bs-theme="light"] .bg-soft-success { color: #16a34a; }
[data-bs-theme="light"] .bg-soft-warning { color: #d97706; }
[data-bs-theme="light"] .bg-soft-danger { color: #dc2626; }

/* Tables */
.table { --bs-table-bg: transparent; --bs-table-color: var(--bs-body-color); margin-bottom: 0; }
.table thead th {
    font-family: var(--font-mono); font-size: .68rem; text-transform: uppercase; letter-spacing: .08em;
    color: var(--app-muted); font-weight: 500; border-bottom: 1px solid var(--app-border); white-space: nowrap;
}
.table td, .table th { padding: 13px 14px; vertical-align: middle; border-color: var(--app-border); color: var(--bs-body-color); }
.table-hover tbody tr:hover > * { background: rgba(var(--brand-rgb), .05); color: var(--bs-emphasis-color); }
.table-active > * { background: rgba(var(--brand-rgb), .08) !important; }

/* Avatars */
.avatar { width: 38px; height: 38px; border-radius: 11px; display: inline-grid; place-items: center; font-family: var(--font-display); font-weight: 700; font-size: .8rem; color: #03110f; background: var(--brand-grad); flex: 0 0 auto; }
.avatar-sm { width: 30px; height: 30px; font-size: .7rem; border-radius: 9px; }
.avatar-lg { width: 60px; height: 60px; font-size: 1.2rem; border-radius: 17px; }

/* Badges & chips */
.badge { font-family: var(--font-mono); font-weight: 500; letter-spacing: .02em; padding: .4em .7em; }
.chip {
    display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px; border-radius: 999px;
    font-family: var(--font-mono); font-size: .74rem; font-weight: 500;
    border: 1px solid var(--app-border); background: var(--app-surface); color: var(--bs-body-color);
}

/* Buttons */
.btn { font-family: var(--font-display); font-weight: 600; border-radius: 11px; transition: transform .25s var(--ease), box-shadow .3s var(--ease), filter .2s; }
.btn-primary { background: var(--brand-grad); border: none; color: #03110f; box-shadow: 0 4px 16px rgba(var(--brand-rgb), .22); }
.btn-primary:hover, .btn-primary:focus { color: #03110f; filter: brightness(1.08); transform: translateY(-2px); box-shadow: 0 8px 26px rgba(var(--brand-rgb), .36); }
.btn-soft { background: rgba(var(--brand-rgb), .1); color: var(--cyan); border: 1px solid rgba(var(--brand-rgb), .16); }
.btn-soft:hover { background: rgba(var(--brand-rgb), .16); color: var(--cyan); box-shadow: var(--glow); }
.btn-outline-secondary { color: var(--bs-body-color); border-color: var(--app-border); }
.btn-outline-secondary:hover { background: rgba(var(--brand-rgb), .08); color: var(--cyan); border-color: var(--app-border-strong); }
[data-bs-theme="light"] .btn-primary, [data-bs-theme="light"] .bg-grad, [data-bs-theme="light"] .avatar, [data-bs-theme="light"] .sb-logo { color: #fff !important; }
[data-bs-theme="light"] .btn-soft { color: #0c8f7d; }

/* Forms */
.form-control, .form-select {
    border-radius: 11px; border-color: var(--app-border); background: var(--app-surface); color: var(--bs-body-color); padding: .6rem .85rem;
}
.form-control::placeholder { color: var(--app-muted); opacity: .7; }
.form-control:focus, .form-select:focus {
    border-color: var(--cyan); background: var(--app-surface-2); color: var(--bs-emphasis-color);
    box-shadow: 0 0 0 .18rem rgba(var(--brand-rgb), .16);
}
.form-label { font-family: var(--font-mono); font-weight: 500; font-size: .74rem; letter-spacing: .06em; text-transform: uppercase; color: var(--app-muted); margin-bottom: .4rem; }
.input-group-text { background: var(--app-surface); border-color: var(--app-border); color: var(--app-muted); }
.form-check-input:checked { background-color: var(--cyan); border-color: var(--cyan); }
.form-text { color: var(--app-muted); }

/* Modals / dropdowns / offcanvas */
.modal-content, .offcanvas { background: var(--app-solid); border: 1px solid var(--app-border-strong); border-radius: var(--radius); box-shadow: 0 24px 70px rgba(0, 0, 0, .55); }
.modal-header, .offcanvas-header, .modal-footer { border-color: var(--app-border); }
.modal-title, .offcanvas-title { font-family: var(--font-display); color: var(--bs-emphasis-color); }
.dropdown-menu {
    border: 1px solid var(--app-border-strong); border-radius: 13px; background: var(--app-solid);
    box-shadow: 0 14px 40px rgba(0, 0, 0, .5); backdrop-filter: blur(14px);
}
.dropdown-item { color: var(--bs-body-color); }
.dropdown-item:hover { background: rgba(var(--brand-rgb), .1); color: var(--cyan); }
.dropdown-header { font-family: var(--font-mono); font-size: .68rem; letter-spacing: .08em; text-transform: uppercase; color: var(--app-muted); }
.list-group-item { background: transparent; border-color: var(--app-border); color: var(--bs-body-color); }
.alert { border-radius: 12px; }
.progress { background: rgba(var(--brand-rgb), .1); border-radius: 999px; }
.progress-bar { background: var(--brand-grad); }

/* ---------------- Image placeholders (replace manually) ---------------- */
.img-ph {
    position: relative; overflow: hidden;
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
    border: 1.5px dashed var(--app-border-strong); border-radius: var(--radius);
    background:
        repeating-linear-gradient(45deg, rgba(var(--brand-rgb), .04) 0 12px, transparent 12px 24px),
        var(--app-surface);
    color: var(--app-muted); text-align: center; padding: 22px; min-height: 150px;
}
.img-ph i { font-size: 1.8rem; color: var(--cyan); opacity: .8; }
.img-ph .ph-label { font-family: var(--font-mono); font-size: .72rem; letter-spacing: .06em; }
.img-ph::after {
    content: ""; position: absolute; left: 0; right: 0; top: -30%; height: 30%;
    background: linear-gradient(180deg, transparent, rgba(var(--brand-rgb), .12), transparent);
    animation: ph-scan 3.6s var(--ease) infinite;
}
@keyframes ph-scan { to { top: 130%; } }

/* ---------------- Animations ---------------- */
/* scroll reveals (landing) — gated on .anim so no-JS never hides content */
.anim [data-reveal] { opacity: 0; transform: translateY(22px); transition: opacity .7s var(--ease), transform .7s var(--ease); transition-delay: var(--rd, 0s); }
.anim [data-reveal].in { opacity: 1; transform: none; }
/* panel entrance (admin/member) — backwards fill = no flicker, hover still works */
@media (prefers-reduced-motion: no-preference) {
    .app-content .card { animation: rise .55s var(--ease) backwards; }
    .app-content .row > div:nth-child(2) .card { animation-delay: .07s; }
    .app-content .row > div:nth-child(3) .card { animation-delay: .13s; }
    .app-content .row > div:nth-child(4) .card { animation-delay: .19s; }
    .app-content > .page-title { animation: rise .5s var(--ease) backwards; }
}
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .anim [data-reveal] { opacity: 1 !important; transform: none !important; } .img-ph::after { animation: none; } }

/* ---------------- Genealogy trees ---------------- */
.tree-scroll { overflow: auto; padding: 8px; }
.bin-tree, .bin-tree ul { position: relative; padding-top: 22px; display: flex; justify-content: center; }
.bin-tree ul { list-style: none; margin: 0; }
.bin-tree li { list-style: none; position: relative; padding: 22px 10px 0; text-align: center; }
.bin-tree li::before, .bin-tree li::after { content: ""; position: absolute; top: 0; right: 50%; width: 50%; height: 22px; border-top: 2px solid var(--app-border-strong); }
.bin-tree li::after { right: auto; left: 50%; border-left: 2px solid var(--app-border-strong); }
.bin-tree li:only-child::after, .bin-tree li:only-child::before { display: none; }
.bin-tree li:first-child::before, .bin-tree li:last-child::after { border: 0 none; }
.bin-tree li:last-child::before { border-right: 2px solid var(--app-border-strong); border-radius: 0 6px 0 0; }
.bin-tree li:first-child::after { border-radius: 6px 0 0 0; }
.bin-tree ul ul::before { content: ""; position: absolute; top: 0; left: 50%; height: 22px; border-left: 2px solid var(--app-border-strong); }
.node {
    display: inline-flex; flex-direction: column; align-items: center; gap: 4px;
    min-width: 98px; padding: 11px 12px; border-radius: 13px;
    background: var(--app-surface); border: 1px solid var(--app-border);
    box-shadow: var(--card-shadow); text-decoration: none; color: var(--bs-body-color);
    transition: transform .2s var(--ease), border-color .2s, box-shadow .3s;
}
.node:hover { transform: translateY(-3px); border-color: var(--cyan); color: var(--bs-body-color); box-shadow: var(--glow); }
.node .avatar { width: 40px; height: 40px; }
.node .n-name { font-family: var(--font-display); font-size: .8rem; font-weight: 600; color: var(--bs-emphasis-color); }
.node .n-code { font-family: var(--font-mono); font-size: .66rem; color: var(--app-muted); }
.node.empty { border-style: dashed; opacity: .6; }
.node.empty .avatar { background: var(--app-border); color: var(--app-muted); }
.uni-tree { list-style: none; margin: 0; padding: 0; }
.uni-tree ul { list-style: none; margin: 0; padding-left: 26px; border-left: 1.5px dashed var(--app-border-strong); }
.uni-node { display: flex; align-items: center; gap: 10px; padding: 9px 13px; margin: 6px 0; border: 1px solid var(--app-border); border-radius: 11px; background: var(--app-surface); }

/* ---------------- Auth pages ---------------- */
.auth-wrap { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; }
.auth-aside { position: relative; overflow: hidden; background: linear-gradient(150deg, #06100f, #030809); color: var(--cyan-soft); padding: 48px; display: flex; flex-direction: column; justify-content: space-between; border-right: 1px solid var(--app-border); }
.auth-aside::before { content: ""; position: absolute; inset: 0; background: radial-gradient(60% 50% at 85% 8%, rgba(20,125,108,.5), transparent 60%), radial-gradient(50% 40% at 0% 100%, rgba(30,255,255,.14), transparent 60%); filter: blur(20px); }
.auth-aside::after {
    content: ""; position: absolute; inset: 0; pointer-events: none;
    background-image: linear-gradient(rgba(30,255,255,.05) 1px, transparent 1px), linear-gradient(90deg, rgba(30,255,255,.05) 1px, transparent 1px);
    background-size: 46px 46px; -webkit-mask-image: radial-gradient(ellipse at center, #000, transparent 75%); mask-image: radial-gradient(ellipse at center, #000, transparent 75%);
}
.auth-aside > * { position: relative; z-index: 1; }
.auth-aside h2 { color: #eafffb; }
.auth-form-side { display: flex; align-items: center; justify-content: center; padding: 40px 24px; background: var(--bs-body-bg); }
.auth-card { width: 100%; max-width: 420px; }
.auth-card h3 { color: var(--bs-emphasis-color); }
.auth-feature { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 18px; }
.auth-feature i { font-size: 1.15rem; color: var(--cyan); background: rgba(30,255,255,.1); width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; flex: 0 0 40px; border: 1px solid var(--app-border); }
@media (max-width: 900px) { .auth-wrap { grid-template-columns: 1fr; } .auth-aside { display: none; } }

/* ---------------- Misc ---------------- */
.page-title { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 22px; }
.page-title h2 { font-family: var(--font-display); font-size: 1.4rem; font-weight: 700; margin: 0; letter-spacing: -.4px; color: var(--bs-emphasis-color); }
.divider-y { border-top: 1px solid var(--app-border); }
.list-tight li { padding: 9px 0; border-bottom: 1px dashed var(--app-border); }
.list-tight li:last-child { border-bottom: 0; }
code { color: var(--cyan-soft); }

/* Marquee (landing) */
.mq { overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.mq-track { display: flex; gap: 40px; width: max-content; animation: mq 26s linear infinite; }
.mq:hover .mq-track { animation-play-state: paused; }
.mq-track span { font-family: var(--font-display); font-weight: 600; font-size: 1.1rem; color: var(--app-muted); white-space: nowrap; display: inline-flex; align-items: center; gap: 40px; }
.mq-track span::after { content: "✦"; color: var(--cyan); }
@keyframes mq { to { transform: translateX(-50%); } }

/* Scrollbar */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(var(--brand-rgb), .18); border-radius: 6px; }
::-webkit-scrollbar-thumb:hover { background: rgba(var(--brand-rgb), .35); }

/* DataTables tweaks */
.dataTables_wrapper .dt-input, .dataTables_wrapper .dt-search input, .dataTables_wrapper select { background: var(--app-surface); border: 1px solid var(--app-border); color: var(--bs-body-color); border-radius: 9px; }
.dataTables_wrapper .dt-paging .dt-paging-button { color: var(--bs-body-color) !important; }
.dataTables_wrapper .dt-paging .dt-paging-button.current { background: var(--brand-grad) !important; color: #03110f !important; border: none !important; border-radius: 8px; }
.dataTables_wrapper .dt-info, .dataTables_wrapper label { color: var(--app-muted); }

/* ---------------- Responsive ---------------- */
@media (max-width: 992px) {
    .app-sidebar { transform: translateX(-100%); box-shadow: 0 0 50px rgba(0, 0, 0, .5); }
    body.sidebar-open .app-sidebar { transform: translateX(0); }
    .app-main { margin-left: 0; }
    .sidebar-toggle { display: inline-grid; }
    .sidebar-backdrop { position: fixed; inset: 0; z-index: 1035; background: rgba(0, 0, 0, .55); opacity: 0; visibility: hidden; transition: opacity .2s; }
    body.sidebar-open .sidebar-backdrop { opacity: 1; visibility: visible; }
}
