/* =============================================================
   Dr Unlocker — Premium Dark/Gold Design System
   Inspired by Haafedk aesthetic: deep black + amber accents,
   real Font Awesome icons, Poppins + Cairo typography.
   ============================================================= */
@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;500;600;700;800;900&family=Poppins:wght@400;500;600;700;800;900&display=swap');

/* ---------- Theme tokens (default: dark) ---------- */
:root, [data-theme="dark"] {
  --bg:            #0a0a0a;
  --bg-2:          #0d0d0d;
  --surface:       #141414;
  --surface-2:     #1a1a1a;
  --surface-3:     #202020;
  --surface-hover: #262626;
  --line:          #262626;
  --line-strong:   #2f2f2f;
  --line-soft:     rgba(255,255,255,.06);

  --text:          #f5f5f5;
  --text-soft:     #d1d5db;
  --muted:         #9ca3af;
  --muted-2:       #6b7280;

  --gold:          #f5a623;
  --gold-hover:    #ffb534;
  --gold-soft:     rgba(245,166,35,.14);
  --gold-glow:     rgba(245,166,35,.35);

  --primary:       var(--gold);
  --primary-2:     var(--gold-hover);

  --success:       #22c55e;
  --success-soft:  rgba(34,197,94,.13);
  --danger:        #ef4444;
  --danger-soft:   rgba(239,68,68,.14);
  --warning:       #f59e0b;
  --info:          #38bdf8;
  --purple:        #a78bfa;
  --pink:          #ec4899;

  --shadow-lg:     0 30px 70px rgba(0,0,0,.55);
  --shadow-md:     0 14px 34px rgba(0,0,0,.4);
  --shadow-sm:     0 4px 12px rgba(0,0,0,.35);
  --shadow-glow:   0 10px 34px var(--gold-glow);

  --radius-sm:     10px;
  --radius:        14px;
  --radius-lg:     20px;
  --radius-pill:   999px;

  color-scheme: dark;
}

[data-theme="light"] {
  --bg:            #f7f7f8;
  --bg-2:          #ffffff;
  --surface:       #ffffff;
  --surface-2:     #f8f9fb;
  --surface-3:     #f2f4f7;
  --surface-hover: #eef1f6;
  --line:          #e5e7eb;
  --line-strong:   #d5d8e0;
  --line-soft:     rgba(15,23,42,.06);

  --text:          #0f172a;
  --text-soft:     #334155;
  --muted:         #6b7280;
  --muted-2:       #94a3b8;

  --gold:          #d97706;
  --gold-hover:    #b45309;
  --gold-soft:     rgba(217,119,6,.12);
  --gold-glow:     rgba(217,119,6,.25);

  --primary:       var(--gold);
  --primary-2:     var(--gold-hover);

  --shadow-lg:     0 20px 45px rgba(15,25,60,.10);
  --shadow-md:     0 8px 24px rgba(15,25,60,.08);
  --shadow-sm:     0 2px 8px rgba(15,25,60,.06);
  --shadow-glow:   0 8px 20px var(--gold-glow);

  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  min-width: 320px;
  color: var(--text);
  font: 500 15px/1.7 Cairo, Poppins, system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  background:
    radial-gradient(1200px 500px at 80% -100px, var(--gold-soft), transparent 60%),
    radial-gradient(900px 400px at -100px 300px, rgba(245,166,35,.08), transparent 60%),
    var(--bg);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: inherit; text-decoration: none; }
img, svg { max-width: 100%; display: block; }
button { font-family: inherit; }
::selection { background: var(--gold); color: #1a1000; }

b, strong, .num, .stat strong, .brand, h1, h2, h3, h4 { font-family: Poppins, Cairo, sans-serif; }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--surface-3); border-radius: 20px; }
::-webkit-scrollbar-thumb:hover { background: var(--gold); }

.container { width: min(1240px, calc(100% - 32px)); margin: 0 auto; }

/* ---------- Top navigation ---------- */
.topbar {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px max(20px, calc((100% - 1240px) / 2));
  background: color-mix(in oklab, var(--bg) 88%, transparent);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--line-soft);
}
.brand {
  display: flex; align-items: center; gap: 12px;
  font: 800 18px/1 Poppins, Cairo;
  color: var(--text);
}
.brand-mark {
  width: 44px; height: 44px; border-radius: 12px;
  display: grid; place-items: center;
  background: linear-gradient(135deg, var(--gold), var(--gold-hover));
  box-shadow: var(--shadow-glow);
  color: #1a1000; font: 900 15px Poppins;
}
.brand small {
  display: block; margin-top: 3px;
  font: 500 10.5px/1 Poppins;
  letter-spacing: 1.5px; color: var(--muted);
  text-transform: uppercase;
}

.nav { display: flex; align-items: center; gap: 6px; }
.nav a, .nav > button {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 14px; border-radius: 10px;
  background: transparent; border: 1px solid transparent;
  color: var(--text-soft);
  font: 600 13.5px/1 Poppins, Cairo;
  cursor: pointer; transition: all .18s ease;
}
.nav a:hover, .nav > button:hover {
  background: var(--surface-2); color: var(--text);
  border-color: var(--line);
}
.nav .cta {
  background: linear-gradient(135deg, var(--gold), var(--gold-hover));
  color: #1a1000; border-color: transparent;
  box-shadow: var(--shadow-glow);
  font-weight: 700;
}
.nav .cta:hover {
  color: #1a1000; background: linear-gradient(135deg, var(--gold-hover), var(--gold));
  transform: translateY(-1px);
}
.nav .cta i { color: #1a1000; }

.theme-toggle {
  width: 40px; height: 40px; border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--surface); color: var(--text);
  display: grid; place-items: center; cursor: pointer;
  transition: all .18s ease;
}
.theme-toggle:hover { transform: translateY(-1px); background: var(--surface-2); border-color: var(--gold); color: var(--gold); }

/* ---------- Announcement bar ---------- */
.announcement {
  display: flex; align-items: center; justify-content: center; gap: 14px;
  padding: 10px 20px; font: 600 13px/1.5 Cairo, Poppins;
  background: linear-gradient(90deg, var(--surface), var(--surface-2), var(--surface));
  color: var(--text-soft);
  border-bottom: 1px solid var(--line-soft);
}
.announcement i { color: var(--gold); }
.announcement b { color: var(--gold); }

/* ---------- Pill chips ---------- */
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 16px; border-radius: var(--radius-pill);
  font: 700 12px/1 Poppins, Cairo;
  color: var(--gold);
  background: var(--gold-soft);
  border: 1px solid rgba(245,166,35,.35);
}
.chip i { font-size: 12px; }

/* ---------- Buttons ---------- */
.btn {
  --btn-bg: var(--surface-2);
  --btn-color: var(--text);
  --btn-border: var(--line);
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 12px 22px;
  border-radius: 12px; border: 1px solid var(--btn-border);
  background: var(--btn-bg); color: var(--btn-color);
  font: 700 14px/1 Poppins, Cairo; cursor: pointer;
  transition: transform .12s ease, box-shadow .18s ease, filter .15s ease, background .18s ease, border-color .18s ease;
  text-decoration: none;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.btn.wide { width: 100%; }
.btn i { font-size: 14px; }

.btn.primary {
  --btn-bg: linear-gradient(135deg, var(--gold), var(--gold-hover));
  --btn-color: #1a1000;
  --btn-border: transparent;
  box-shadow: var(--shadow-glow);
  font-weight: 800;
}
.btn.primary:hover { background: linear-gradient(135deg, var(--gold-hover), var(--gold)); box-shadow: 0 14px 40px var(--gold-glow); }
.btn.primary i { color: #1a1000; }

.btn.dark {
  --btn-bg: var(--surface-2);
  --btn-color: var(--text);
  --btn-border: var(--line);
}
.btn.dark:hover { --btn-bg: var(--surface-3); --btn-border: var(--gold); color: var(--gold); }
.btn.dark:hover i { color: var(--gold); }

.btn.ghost {
  --btn-bg: transparent;
  --btn-border: var(--line);
  color: var(--text-soft);
}
.btn.ghost:hover { color: var(--gold); border-color: var(--gold); background: var(--gold-soft); }

.btn.success { --btn-bg: linear-gradient(135deg, var(--success), #4ade80); --btn-color: #04150a; --btn-border: transparent; }
.btn.danger  { --btn-bg: linear-gradient(135deg, var(--danger), #f87171);   --btn-color: #fff; --btn-border: transparent; }
.btn.warning { --btn-bg: linear-gradient(135deg, #f59e0b, #fbbf24);         --btn-color: #1a1000; --btn-border: transparent; }

.btn.sm { padding: 8px 14px; font-size: 12.5px; border-radius: 10px; gap: 6px; }
.btn.sm i { font-size: 11px; }
.btn.icon { padding: 8px; width: 36px; height: 36px; gap: 0; }

/* ---------- Forms ---------- */
.field { display: block; margin-bottom: 14px; }
.field > span, label > span, .field-label {
  display: block; margin-bottom: 8px;
  font: 800 12px/1 Poppins, Cairo;
  color: var(--gold);
  letter-spacing: .5px;
  text-transform: uppercase;
}

.input-wrap {
  position: relative;
  display: flex; align-items: center;
}
.input-wrap > i {
  position: absolute;
  inset-inline-start: 16px;
  color: var(--muted);
  font-size: 14px;
  pointer-events: none;
  transition: color .15s;
  z-index: 2;
}
.input-wrap > input,
.input-wrap > select { padding-inline-start: 42px; }
.input-wrap:focus-within > i { color: var(--gold); }

input, select, textarea {
  width: 100%;
  padding: 13px 16px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  font: 500 14px/1.4 Cairo, Poppins;
  transition: border-color .15s, background .15s, box-shadow .15s;
}
textarea { min-height: 100px; resize: vertical; }
input:focus, select:focus, textarea:focus {
  outline: 0;
  border-color: var(--gold);
  box-shadow: 0 0 0 4px var(--gold-soft);
  background: var(--surface-2);
}
input::placeholder, textarea::placeholder { color: var(--muted-2); }
select { appearance: none; -webkit-appearance: none; padding-inline-end: 40px; }
select:not([multiple]) {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239ca3af' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: left 14px center;
  background-size: 14px;
}

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
@media (max-width: 700px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }

/* ---------- Card / Panel ---------- */
.card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-md);
}
.card h2 { margin: 0 0 6px; font: 800 22px/1.25 Poppins, Cairo; color: var(--text); }
.card h3 { margin: 0 0 6px; font: 700 18px/1.3 Poppins, Cairo; color: var(--text); }
.card p.lead { color: var(--muted); margin: 0 0 20px; font-size: 14px; }

.section { margin: 60px 0; }
.section-title {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 16px; margin-bottom: 26px; flex-wrap: wrap;
}
.section-title h2 { margin: 0; font: 900 28px/1.2 Poppins, Cairo; color: var(--text); }
.section-title p { margin: 6px 0 0; color: var(--muted); font-size: 14px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--gold);
  font: 800 11px/1 Poppins;
  letter-spacing: 2px;
  margin-bottom: 10px;
  text-transform: uppercase;
}
.eyebrow::before { content: ""; width: 22px; height: 2px; background: var(--gold); }

/* ---------- Hero ---------- */
.hero {
  display: grid; grid-template-columns: 1.15fr 0.85fr;
  align-items: center; gap: 50px;
  padding: 80px 0 50px;
}
.hero h1 {
  margin: 16px 0 18px; font: 900 60px/1.05 Poppins, Cairo; letter-spacing: -0.02em;
  color: var(--text);
}
.hero h1 em {
  font-style: normal;
  background: linear-gradient(135deg, var(--gold), var(--gold-hover));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero p { color: var(--muted); font-size: 17px; max-width: 540px; line-height: 1.8; }
.hero-actions { display: flex; gap: 12px; margin: 26px 0 12px; flex-wrap: wrap; }

.hero-stats {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px;
  margin-top: 40px; padding-top: 30px;
  border-top: 1px solid var(--line-soft);
}
.hero-stats .item strong {
  display: block; font: 800 28px/1 Poppins; color: var(--gold);
  margin-bottom: 6px;
}
.hero-stats .item span { color: var(--muted); font-size: 12px; font-weight: 600; letter-spacing: .5px; text-transform: uppercase; }

.hero-form {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 34px;
  box-shadow: var(--shadow-lg);
  position: relative;
}
.hero-form .form-icon {
  width: 76px; height: 76px; border-radius: 20px;
  display: grid; place-items: center; margin: 0 auto 18px;
  background: linear-gradient(135deg, var(--gold), var(--gold-hover));
  color: #1a1000; font-size: 30px;
  box-shadow: var(--shadow-glow);
}
.hero-form h2 { text-align: center; font: 800 26px Poppins, Cairo; margin: 8px 0 4px; }
.hero-form .lead { text-align: center; color: var(--muted); margin: 0 0 26px; }

/* ---------- Stat cards ---------- */
.stats {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 14px; margin: 6px 0 22px;
}
.stat {
  position: relative; overflow: hidden;
  padding: 22px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  transition: transform .15s, border-color .18s;
}
.stat:hover { transform: translateY(-2px); border-color: var(--gold); }
.stat span.label {
  display: block; color: var(--muted);
  font: 700 11.5px/1 Poppins, Cairo;
  letter-spacing: .8px;
  text-transform: uppercase;
}
.stat strong { display: block; margin-top: 8px; font: 800 28px/1.15 Poppins; color: var(--text); }
.stat .icon {
  position: absolute; inset-inline-end: 22px; top: 22px;
  width: 42px; height: 42px; border-radius: 12px;
  display: grid; place-items: center;
  background: var(--gold-soft);
  color: var(--gold);
  font-size: 18px;
}
.stat.cyan   .icon { background: rgba(56,189,248,.13); color: var(--info); }
.stat.green  .icon { background: var(--success-soft); color: var(--success); }
.stat.pink   .icon { background: rgba(236,72,153,.13); color: var(--pink); }
.stat.purple .icon { background: rgba(167,139,250,.13); color: var(--purple); }
.stat.orange .icon { background: rgba(251,146,60,.14); color: #fb923c; }
.stat.yellow .icon { background: var(--gold-soft); color: var(--gold); }
.stat.red    .icon { background: var(--danger-soft); color: var(--danger); }

/* ---------- Badges ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 12px; border-radius: var(--radius-pill);
  font: 700 11px/1 Poppins, Cairo; letter-spacing: .3px;
  background: var(--surface-2); color: var(--text-soft);
  border: 1px solid var(--line);
}
.badge i { font-size: 10px; }
.badge-success { color: var(--success); background: var(--success-soft); border-color: rgba(34,197,94,.3); }
.badge-warn    { color: var(--gold); background: var(--gold-soft); border-color: rgba(245,166,35,.3); }
.badge-danger  { color: var(--danger); background: var(--danger-soft); border-color: rgba(239,68,68,.3); }
.badge-muted   { color: var(--muted); background: var(--surface-2); }
.badge-gold    { color: var(--gold); background: var(--gold-soft); border-color: rgba(245,166,35,.4); font-weight: 800; }

/* ---------- Tables ---------- */
.table-wrap {
  overflow: auto; border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
}
table.data {
  width: 100%; min-width: 720px;
  border-collapse: separate; border-spacing: 0;
  font-size: 13.5px;
}
table.data thead th {
  position: sticky; top: 0; z-index: 1;
  background: var(--surface-2);
  color: var(--muted);
  font: 700 11.5px/1 Poppins, Cairo;
  letter-spacing: .6px;
  text-align: start;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  text-transform: uppercase;
}
table.data tbody td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--line-soft);
  color: var(--text-soft);
  vertical-align: middle;
}
table.data tbody tr:last-child td { border-bottom: 0; }
table.data tbody tr:hover td { background: var(--surface-2); }
table.data td b { color: var(--text); font-weight: 700; }
table.data td small { display: block; color: var(--muted); margin-top: 2px; font-size: 11.5px; }
table.data .actions { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }

/* ---------- Dashboard shell ---------- */
.shell {
  display: grid; grid-template-columns: 268px 1fr;
  gap: 24px; padding: 24px 0 40px;
  align-items: flex-start;
}
.shell aside {
  position: sticky; top: 84px;
  padding: 20px;
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}
.shell aside .user {
  display: flex; align-items: center; gap: 12px;
  padding: 4px 4px 18px;
  border-bottom: 1px solid var(--line-soft);
  margin-bottom: 14px;
}
.shell aside .avatar {
  width: 48px; height: 48px; border-radius: 12px;
  display: grid; place-items: center;
  background: linear-gradient(135deg, var(--gold), var(--gold-hover));
  color: #1a1000;
  font: 800 15px Poppins;
  box-shadow: var(--shadow-glow);
}
.shell aside .user b { display: block; color: var(--text); font-size: 14px; font-weight: 700; }
.shell aside .user small { color: var(--muted); font-size: 11.5px; }

.side-nav { display: flex; flex-direction: column; gap: 3px; }
.side-nav a {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 14px; border-radius: 10px;
  color: var(--text-soft); font-size: 13.5px; font-weight: 600;
  border: 1px solid transparent;
  transition: all .16s ease;
}
.side-nav a i { width: 16px; text-align: center; color: var(--muted); font-size: 14px; transition: color .15s; }
.side-nav a:hover { background: var(--surface-2); color: var(--text); }
.side-nav a:hover i { color: var(--gold); }
.side-nav a.active {
  background: var(--gold-soft);
  color: var(--gold);
  border-color: rgba(245,166,35,.28);
  font-weight: 700;
}
.side-nav a.active i { color: var(--gold); }
.side-nav hr { border: 0; border-top: 1px solid var(--line-soft); margin: 10px 0; }

.shell main { min-width: 0; }
.page-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 12px; flex-wrap: wrap; margin-bottom: 26px;
}
.page-head h1 {
  margin: 0; font: 900 30px/1.15 Poppins, Cairo; color: var(--text);
  display: flex; align-items: center; gap: 12px;
}
.page-head h1 i { color: var(--gold); font-size: 24px; }
.page-head p { margin: 6px 0 0; color: var(--muted); font-size: 14px; }
.page-head .tools { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }

/* ---------- Tabs ---------- */
.tabs {
  display: flex; gap: 4px; flex-wrap: wrap;
  padding: 6px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 22px;
}
.tabs a {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 16px; border-radius: 10px;
  color: var(--muted); font-size: 13px; font-weight: 700;
  transition: all .16s;
  white-space: nowrap;
}
.tabs a i { font-size: 12px; }
.tabs a:hover { color: var(--text); background: var(--surface-2); }
.tabs a.active {
  background: linear-gradient(135deg, var(--gold), var(--gold-hover));
  color: #1a1000;
  box-shadow: var(--shadow-glow);
}
.tabs a.active i { color: #1a1000; }

/* ---------- Filter bar ---------- */
.filter-bar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 14px 16px; margin-bottom: 16px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
}
.filter-bar .input-wrap { flex: 1; min-width: 220px; }
.filter-bar select { min-width: 140px; }

/* ---------- Pagination ---------- */
.pager { display: flex; gap: 6px; justify-content: center; margin: 22px 0; flex-wrap: wrap; }
.pager button, .pager a {
  min-width: 38px; height: 38px; padding: 0 12px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 10px; border: 1px solid var(--line);
  background: var(--surface); color: var(--text-soft);
  font: 700 12.5px Poppins; cursor: pointer;
  transition: all .15s;
}
.pager a:hover { border-color: var(--gold); color: var(--gold); }
.pager .current {
  background: linear-gradient(135deg, var(--gold), var(--gold-hover));
  color: #1a1000; border-color: transparent;
  box-shadow: var(--shadow-glow);
}

/* ---------- Toast ---------- */
.toast {
  position: fixed; z-index: 90;
  bottom: 24px; inset-inline-start: 24px;
  display: flex; align-items: center; gap: 12px;
  padding: 14px 20px; min-width: 280px; max-width: 420px;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-lg);
  color: var(--text); font-weight: 600;
  transform: translateY(20px); opacity: 0; pointer-events: none;
  transition: transform .25s, opacity .25s;
}
.toast::before {
  font-family: "Font Awesome 6 Free"; font-weight: 900;
  font-size: 16px; content: "\f05a";
  color: var(--info);
}
.toast.show { transform: translateY(0); opacity: 1; pointer-events: auto; }
.toast.success { border-color: rgba(34,197,94,.4); }
.toast.success::before { content: "\f058"; color: var(--success); }
.toast.error   { border-color: rgba(239,68,68,.4); }
.toast.error::before { content: "\f057"; color: var(--danger); }

/* ---------- Alerts ---------- */
.alert {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 18px; border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text-soft);
  margin-bottom: 16px;
  font-size: 14px;
}
.alert i { color: var(--gold); font-size: 16px; }
.alert.success { border-color: rgba(34,197,94,.4); background: var(--success-soft); color: var(--success); }
.alert.error   { border-color: rgba(239,68,68,.4); background: var(--danger-soft); color: var(--danger); }
.alert.warning { border-color: rgba(245,166,35,.4); background: var(--gold-soft); color: var(--gold); }

/* ---------- Chart card ---------- */
.chart-card {
  padding: 24px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}
.chart-card h3 { margin: 0 0 4px; font: 800 18px Poppins, Cairo; color: var(--text); display: flex; align-items: center; gap: 10px; }
.chart-card h3 i { color: var(--gold); }
.chart-card p  { margin: 0 0 16px; color: var(--muted); font-size: 13px; }
.chart-holder { position: relative; height: 300px; }

/* ---------- Features ---------- */
.features {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin: 30px 0;
}
.features article {
  padding: 28px; border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  transition: all .18s;
}
.features article:hover {
  transform: translateY(-3px);
  border-color: var(--gold);
  box-shadow: var(--shadow-md);
}
.feature-icon {
  width: 56px; height: 56px; border-radius: 14px;
  background: var(--gold-soft); color: var(--gold);
  display: grid; place-items: center;
  font-size: 22px;
  margin-bottom: 16px;
}
.features article h3 { margin: 0 0 8px; font: 800 20px Poppins, Cairo; color: var(--text); }
.features article p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.7; }
@media (max-width: 800px) { .features { grid-template-columns: 1fr; } }

/* ---------- Roles cards ---------- */
.roles {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px;
  margin-top: 20px;
}
.roles article {
  padding: 26px 22px; border-radius: var(--radius-lg);
  background: var(--surface); border: 1px solid var(--line);
  text-align: center; transition: all .18s;
}
.roles article:hover { border-color: var(--gold); transform: translateY(-2px); }
.roles .role-icon {
  width: 60px; height: 60px; border-radius: 16px;
  background: var(--gold-soft); color: var(--gold);
  display: grid; place-items: center; font-size: 24px;
  margin: 0 auto 14px;
}
.roles article h3 { margin: 0 0 8px; font: 700 18px Poppins, Cairo; }
.roles article p { margin: 0; color: var(--muted); font-size: 13.5px; }
@media (max-width: 800px) { .roles { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */
footer {
  padding: 30px 0; text-align: center;
  color: var(--muted); font-size: 13px;
  border-top: 1px solid var(--line-soft); margin-top: 60px;
  background: var(--bg-2);
}
footer .container { display: flex; flex-direction: column; align-items: center; gap: 14px; }
footer .brand { justify-content: center; }
footer .socials { display: flex; justify-content: center; gap: 10px; margin-top: 4px; }
footer .socials a {
  width: 40px; height: 40px; border-radius: 10px;
  display: grid; place-items: center;
  border: 1px solid var(--line); background: var(--surface);
  color: var(--muted); font-size: 15px;
  transition: all .15s;
}
footer .socials a:hover { color: var(--gold); border-color: var(--gold); background: var(--gold-soft); }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero { grid-template-columns: 1fr; padding: 40px 0 20px; gap: 30px; }
  .hero h1 { font-size: 42px; }
  .hero-stats { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .shell { grid-template-columns: 1fr; }
  .shell aside { position: static; padding: 16px; }
  .side-nav { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 4px; }
  .side-nav hr { display: none; }
}
@media (max-width: 640px) {
  .container { width: min(100% - 24px, 1240px); }
  .topbar { padding: 10px 14px; }
  .brand small { display: none; }
  .nav a:not(.cta):not(.theme-toggle) span { display: none; }
  .nav a:not(.cta):not(.theme-toggle) { padding: 9px 11px; }
  .hero { padding-top: 24px; }
  .hero h1 { font-size: 32px; }
  .page-head h1 { font-size: 22px; }
  .card, .hero-form { padding: 20px; }
  .stat strong { font-size: 24px; }
  .tabs { padding: 4px; }
  .tabs a { padding: 8px 12px; font-size: 12px; }
}

/* ---------- Utilities ---------- */
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.row-inline  { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.mt-0 { margin-top: 0; } .mt-1 { margin-top: 8px; } .mt-2 { margin-top: 16px; } .mt-3 { margin-top: 24px; }
.mb-0 { margin-bottom: 0; } .mb-1 { margin-bottom: 8px; } .mb-2 { margin-bottom: 16px; } .mb-3 { margin-bottom: 24px; }
.text-muted { color: var(--muted); }
.text-gold  { color: var(--gold); }
.text-danger { color: var(--danger); }
.text-success { color: var(--success); }
.text-center { text-align: center; }
.hidden { display: none !important; }
.spinner {
  width: 16px; height: 16px; border-radius: 50%;
  border: 2px solid rgba(255,255,255,.2);
  border-top-color: currentColor;
  animation: spin .9s linear infinite;
  display: inline-block; vertical-align: middle;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Auth grid preserved ---------- */
.auth-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 900px) { .auth-grid { grid-template-columns: 1fr; } }

/* ---------- Download banner ---------- */
.download-banner {
  display: flex; align-items: center; gap: 16px;
  padding: 16px 20px; border-radius: 14px;
  background: linear-gradient(135deg, rgba(245,166,35,.12), rgba(245,166,35,.04));
  border: 1px solid rgba(245,166,35,.28);
  box-shadow: 0 4px 20px rgba(245,166,35,.10);
}
.download-banner .dlb-icon {
  width: 44px; height: 44px; border-radius: 12px; flex-shrink: 0;
  display: grid; place-items: center; font-size: 18px;
  background: linear-gradient(135deg, var(--gold), var(--gold-hover));
  color: #1a1000; box-shadow: var(--shadow-glow);
}
.download-banner .dlb-body { flex: 1; min-width: 0; }
.download-banner .dlb-body b { display: block; color: var(--text); font-size: 14.5px; font-weight: 800; }
.download-banner .dlb-body small { color: var(--muted); font-size: 12px; }
.download-banner .dlb-actions { display: flex; gap: 8px; flex-shrink: 0; }
@media (max-width: 600px) {
  .download-banner { flex-wrap: wrap; }
  .download-banner .dlb-actions { width: 100%; }
  .download-banner .dlb-actions .btn { flex: 1; }
}

/* ---------- Small: better card hierarchy ---------- */
.card + .card { margin-top: 16px; }
.section-title h2 i { color: var(--gold); margin-inline-end: 6px; }
code {
  background: var(--surface-2);
  padding: 2px 6px;
  border-radius: 6px;
  font-size: 12px;
  color: var(--text-soft);
  border: 1px solid var(--line);
}

/* ---------- Modal ---------- */
.modal-root {
  position: fixed; inset: 0; z-index: 100;
  display: grid; place-items: center;
  opacity: 0; pointer-events: none;
  transition: opacity .2s ease;
}
.modal-root.show { opacity: 1; pointer-events: auto; }
.modal-scrim {
  position: absolute; inset: 0;
  background: rgba(0,0,0,.65);
  backdrop-filter: blur(6px);
}
.modal-card {
  position: relative;
  width: min(520px, calc(100% - 40px));
  max-height: 88vh; overflow: auto;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 28px;
  transform: translateY(8px) scale(.98);
  transition: transform .22s ease;
}
.modal-root.show .modal-card { transform: translateY(0) scale(1); }
.modal-close {
  position: absolute; top: 14px; inset-inline-end: 14px;
  width: 34px; height: 34px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--surface-2);
  color: var(--text-soft); font-size: 14px; cursor: pointer;
  display: grid; place-items: center;
  transition: all .15s;
}
.modal-close:hover { color: var(--gold); border-color: var(--gold); }
.modal-head { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; padding-inline-end: 40px; }
.modal-icon {
  width: 44px; height: 44px; border-radius: 12px;
  display: grid; place-items: center; flex-shrink: 0;
  background: var(--gold-soft); color: var(--gold); font-size: 18px;
}
.modal-head h3 { margin: 0; font: 800 20px Poppins, Cairo; color: var(--text); }
.modal-body { color: var(--text-soft); font-size: 14.5px; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--line-soft); }
@media (max-width: 500px) {
  .modal-card { padding: 20px; }
  .modal-actions { flex-direction: column-reverse; }
  .modal-actions .btn { width: 100%; }
}

/* ---------- Bulk actions bar ---------- */
.bulk-bar {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px; margin-bottom: 12px;
  border-radius: 12px;
  background: var(--surface); border: 1px dashed var(--gold);
  visibility: hidden; opacity: 0;
  transition: opacity .2s;
}
.bulk-bar.active { visibility: visible; opacity: 1; }
.bulk-bar b { color: var(--gold); font-weight: 800; font-family: Poppins; }
.bulk-actions { margin-inline-start: auto; display: flex; gap: 8px; flex-wrap: wrap; }

.checkbox-cell { width: 42px; }
input[type="checkbox"] {
  width: 18px; height: 18px;
  accent-color: var(--gold);
  cursor: pointer;
}

/* ---------- Bell notification badge ---------- */
.bell {
  position: relative;
}
.bell .dot {
  position: absolute; top: 6px; inset-inline-end: 6px;
  min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 999px;
  background: var(--danger); color: #fff;
  font: 700 10.5px/18px Poppins;
  text-align: center;
  box-shadow: 0 0 0 2px var(--bg);
}
