/* =====================================================================
   LUMEN CAPITAL — Design System
   A premium dark fintech aesthetic: deep navy surfaces, violet/gold
   accents, glassmorphism cards, and confident typography.
   ===================================================================== */

:root {
  --bg: #080b12;
  --bg-elevated: #0c101a;
  --surface: #121826;
  --surface-2: #1a2233;
  --surface-hover: #202a40;
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.16);
  --text: #eef1f8;
  --text-muted: #96a0b8;
  --text-faint: #5c6684;

  --primary: #6d5bf0;
  --primary-light: #8b7bff;
  --primary-dark: #4c3dc7;
  --gold: #f0b90b;
  --gold-light: #ffd24d;
  --emerald: #22c55e;
  --emerald-light: #4ade80;
  --red: #f0465c;
  --amber: #f59e0b;
  --rose: #fb7185;
  --indigo: #6366f1;

  --grad-primary: linear-gradient(135deg, #6d5bf0 0%, #a45bf0 100%);
  --grad-gold: linear-gradient(135deg, #f0b90b 0%, #ffd24d 100%);
  --grad-hero: radial-gradient(circle at 20% 20%, rgba(109, 91, 240, 0.25), transparent 45%),
               radial-gradient(circle at 80% 0%, rgba(240, 185, 11, 0.12), transparent 40%),
               radial-gradient(circle at 50% 100%, rgba(34, 197, 94, 0.10), transparent 45%);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.25);
  --shadow-md: 0 8px 30px rgba(0, 0, 0, 0.35);
  --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.45);
  --shadow-glow: 0 0 0 1px rgba(109, 91, 240, 0.4), 0 8px 30px rgba(109, 91, 240, 0.25);

  --font-heading: 'Sora', 'Inter', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, sans-serif;
}

/* ---------------------------------------------------------------------
   Reset & base
   --------------------------------------------------------------------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 15.5px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body.bg-mesh {
  background-image: var(--grad-hero);
  background-attachment: fixed;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 0.5em;
  letter-spacing: -0.01em;
}

p { margin: 0 0 1em; color: var(--text-muted); }
a { color: var(--primary-light); text-decoration: none; transition: color .15s ease; }
a:hover { color: var(--text); }
img { max-width: 100%; display: block; }
ul, ol { padding-left: 1.2em; color: var(--text-muted); }
code { background: var(--surface-2); padding: 2px 6px; border-radius: 6px; font-size: 0.9em; }
hr { border: none; border-top: 1px solid var(--border); margin: 2em 0; }
::selection { background: var(--primary); color: #fff; }

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}
.container-narrow { max-width: 760px; margin: 0 auto; padding: 0 24px; }

.text-muted { color: var(--text-muted) !important; }
.text-faint { color: var(--text-faint) !important; }
.text-gold { color: var(--gold) !important; }
.text-emerald { color: var(--emerald) !important; }
.text-red { color: var(--red) !important; }
.text-primary { color: var(--primary-light) !important; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.fw-600 { font-weight: 600; }
.fw-700 { font-weight: 700; }
.mono { font-variant-numeric: tabular-nums; }

.section { padding: 96px 0; }
.section-sm { padding: 56px 0; }
@media (max-width: 768px) {
  .section { padding: 64px 0; }
  .section-sm { padding: 40px 0; }
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--primary-light);
  background: rgba(109, 91, 240, 0.12);
  border: 1px solid rgba(109, 91, 240, 0.3);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 18px;
}
.eyebrow .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--emerald); box-shadow: 0 0 8px var(--emerald); }

/* ---------------------------------------------------------------------
   Buttons
   --------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 14.5px;
  padding: 12px 22px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease, border-color .15s ease, color .15s ease;
  text-decoration: none;
  white-space: nowrap;
  line-height: 1;
}
.btn:active { transform: translateY(1px); }
.btn-lg { padding: 15px 30px; font-size: 15.5px; border-radius: var(--radius-md); }
.btn-sm { padding: 8px 14px; font-size: 13px; border-radius: 8px; }
.btn-block { width: 100%; }

.btn-primary {
  background: var(--grad-primary);
  color: #fff;
  box-shadow: 0 8px 24px rgba(109, 91, 240, 0.35);
}
.btn-primary:hover { box-shadow: 0 10px 30px rgba(109, 91, 240, 0.5); color: #fff; transform: translateY(-1px); }

.btn-gold {
  background: var(--grad-gold);
  color: #1a1200;
  box-shadow: 0 8px 24px rgba(240, 185, 11, 0.3);
}
.btn-gold:hover { color: #1a1200; box-shadow: 0 10px 30px rgba(240, 185, 11, 0.45); transform: translateY(-1px); }

.btn-outline {
  background: transparent;
  color: var(--text);
  border-color: var(--border-strong);
}
.btn-outline:hover { border-color: var(--primary-light); color: var(--primary-light); background: rgba(109, 91, 240, 0.08); }

.btn-ghost { background: transparent; color: var(--text-muted); }
.btn-ghost:hover { color: var(--text); background: var(--surface-2); }

.btn-danger { background: rgba(240, 70, 92, 0.12); color: var(--red); border-color: rgba(240, 70, 92, 0.35); }
.btn-danger:hover { background: rgba(240, 70, 92, 0.2); color: #fff; }

.btn-success { background: rgba(34, 197, 94, 0.12); color: var(--emerald); border-color: rgba(34, 197, 94, 0.35); }
.btn-success:hover { background: rgba(34, 197, 94, 0.2); color: #fff; }

.btn:disabled, .btn.disabled { opacity: 0.5; cursor: not-allowed; pointer-events: none; }

/* ---------------------------------------------------------------------
   Cards / surfaces
   --------------------------------------------------------------------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
}
.card-sm { padding: 20px; border-radius: var(--radius-md); }

.glass-card {
  background: linear-gradient(180deg, rgba(255,255,255,0.045), rgba(255,255,255,0.01));
  border: 1px solid var(--border);
  backdrop-filter: blur(20px);
  border-radius: var(--radius-lg);
  padding: 28px;
}

.card-hover { transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease; }
.card-hover:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: var(--border-strong); }

/* ---------------------------------------------------------------------
   Badges
   --------------------------------------------------------------------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 4px 11px;
  border-radius: 999px;
  line-height: 1.6;
}
.badge-success { background: rgba(34, 197, 94, 0.14); color: var(--emerald-light); border: 1px solid rgba(34, 197, 94, 0.3); }
.badge-warning { background: rgba(245, 158, 11, 0.14); color: var(--amber); border: 1px solid rgba(245, 158, 11, 0.3); }
.badge-danger  { background: rgba(240, 70, 92, 0.14); color: var(--rose); border: 1px solid rgba(240, 70, 92, 0.3); }
.badge-neutral { background: var(--surface-2); color: var(--text-muted); border: 1px solid var(--border); }
.badge-primary { background: rgba(109, 91, 240, 0.14); color: var(--primary-light); border: 1px solid rgba(109, 91, 240, 0.3); }

/* ---------------------------------------------------------------------
   Forms
   --------------------------------------------------------------------- */
.form-group { margin-bottom: 20px; }
.form-label {
  display: block;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
}
.form-hint { font-size: 12.5px; color: var(--text-faint); margin-top: 6px; }
.form-control,
select.form-control,
textarea.form-control {
  width: 100%;
  background: var(--bg-elevated);
  border: 1px solid var(--border-strong);
  color: var(--text);
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 14.5px;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.form-control::placeholder { color: var(--text-faint); }
.form-control:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(109, 91, 240, 0.18);
}
textarea.form-control { resize: vertical; min-height: 110px; }
.input-group { position: relative; }
.input-group .form-control { padding-left: 40px; }
.input-group-icon {
  position: absolute; left: 14px; top: 50%; transform: translateY(-50%);
  color: var(--text-faint); font-size: 14px; pointer-events: none;
}
.form-error { color: var(--red); font-size: 12.5px; margin-top: 6px; }
.form-control.is-invalid { border-color: var(--red); }

.checkbox-row { display: flex; align-items: flex-start; gap: 10px; font-size: 13.5px; color: var(--text-muted); }
.checkbox-row input { margin-top: 3px; }

select.form-control { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%2396a0b8' stroke-width='1.6' fill='none' fill-rule='evenodd'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px; }

/* Amount stepper for deposit/invest/withdraw */
.amount-display {
  font-family: var(--font-heading);
  font-size: 42px;
  font-weight: 700;
  text-align: center;
  padding: 20px 0;
}
.quick-amounts { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.quick-amounts button {
  flex: 1;
  min-width: 70px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 8px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  transition: all .15s ease;
}
.quick-amounts button:hover, .quick-amounts button.active { border-color: var(--primary); color: var(--primary-light); background: rgba(109,91,240,0.1); }

/* ---------------------------------------------------------------------
   Alerts / flash messages
   --------------------------------------------------------------------- */
.alert {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  margin-bottom: 16px;
  border: 1px solid transparent;
}
.alert-success { background: rgba(34, 197, 94, 0.1); border-color: rgba(34, 197, 94, 0.3); color: var(--emerald-light); }
.alert-danger  { background: rgba(240, 70, 92, 0.1); border-color: rgba(240, 70, 92, 0.3); color: var(--rose); }
.alert-warning { background: rgba(245, 158, 11, 0.1); border-color: rgba(245, 158, 11, 0.3); color: var(--amber); }
.alert-info    { background: rgba(109, 91, 240, 0.1); border-color: rgba(109, 91, 240, 0.3); color: var(--primary-light); }
.alert-close { margin-left: auto; cursor: pointer; opacity: 0.6; background: none; border: none; color: inherit; font-size: 16px; }
.alert-close:hover { opacity: 1; }

#flash-stack { position: fixed; top: 92px; right: 20px; z-index: 999; width: 360px; max-width: calc(100vw - 40px); display: flex; flex-direction: column; gap: 10px; }
#flash-stack .alert { box-shadow: var(--shadow-md); animation: slideIn .25s ease; }
@keyframes slideIn { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: translateX(0); } }

/* ---------------------------------------------------------------------
   Tables
   --------------------------------------------------------------------- */
.table-wrap { overflow-x: auto; border-radius: var(--radius-md); border: 1px solid var(--border); }
table.table { width: 100%; border-collapse: collapse; min-width: 640px; }
table.table th {
  text-align: left;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-faint);
  font-weight: 700;
  padding: 14px 18px;
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
table.table td {
  padding: 16px 18px;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
  vertical-align: middle;
}
table.table tbody tr { background: var(--surface); transition: background .15s ease; }
table.table tbody tr:hover { background: var(--surface-hover); }
table.table tbody tr:last-child td { border-bottom: none; }
.table-empty { padding: 48px 20px; text-align: center; color: var(--text-faint); }

/* ---------------------------------------------------------------------
   Progress bars
   --------------------------------------------------------------------- */
.progress { height: 8px; background: var(--surface-2); border-radius: 999px; overflow: hidden; }
.progress-bar { height: 100%; background: var(--grad-primary); border-radius: 999px; transition: width .4s ease; }
.progress-bar.gold { background: var(--grad-gold); }
.progress-bar.emerald { background: linear-gradient(135deg, var(--emerald), var(--emerald-light)); }

/* ---------------------------------------------------------------------
   Public navbar
   --------------------------------------------------------------------- */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(8, 11, 18, 0.75);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}
.navbar .container { display: flex; align-items: center; justify-content: space-between; height: 76px; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--font-heading); font-weight: 800; font-size: 19px; color: var(--text); }
.brand-mark {
  width: 34px; height: 34px; border-radius: 9px;
  background: var(--grad-primary);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px; color: #fff; box-shadow: 0 4px 14px rgba(109,91,240,.4);
}
.nav-links { display: flex; align-items: center; gap: 34px; }
.nav-links a { color: var(--text-muted); font-weight: 500; font-size: 14.5px; }
.nav-links a.active, .nav-links a:hover { color: var(--text); }
.nav-actions { display: flex; align-items: center; gap: 12px; }
.nav-toggle { display: none; background: none; border: none; color: var(--text); font-size: 22px; cursor: pointer; }

@media (max-width: 900px) {
  .nav-links { position: fixed; top: 76px; left: 0; right: 0; background: var(--bg-elevated); flex-direction: column; align-items: stretch; padding: 10px 24px 24px; gap: 4px; border-bottom: 1px solid var(--border); transform: translateY(-130%); transition: transform .25s ease; }
  .nav-links.open { transform: translateY(0); }
  .nav-links a { padding: 12px 0; border-bottom: 1px solid var(--border); }
  .nav-toggle { display: block; }
}

/* ---------------------------------------------------------------------
   Hero
   --------------------------------------------------------------------- */
.hero { padding: 100px 0 70px; position: relative; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 60px; align-items: center; }
.hero h1 { font-size: 54px; margin-bottom: 22px; }
.hero h1 .accent { background: var(--grad-primary); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-lead { font-size: 17.5px; max-width: 520px; margin-bottom: 34px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 40px; }
.hero-trust { display: flex; gap: 28px; flex-wrap: wrap; color: var(--text-faint); font-size: 13px; }
.hero-trust strong { color: var(--text); display: block; font-size: 20px; font-family: var(--font-heading); }

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 38px; }
}

.hero-visual { position: relative; }
.hero-card-float {
  position: absolute;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  box-shadow: var(--shadow-lg);
  animation: float 5s ease-in-out infinite;
}
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-12px); } }

/* ---------------------------------------------------------------------
   Stat strip
   --------------------------------------------------------------------- */
.stat-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.stat-strip .stat-item { text-align: center; }
.stat-strip .stat-num { font-family: var(--font-heading); font-size: 34px; font-weight: 800; color: var(--text); }
.stat-strip .stat-label { color: var(--text-faint); font-size: 13px; text-transform: uppercase; letter-spacing: .04em; margin-top: 4px; }
@media (max-width: 700px) { .stat-strip { grid-template-columns: repeat(2, 1fr); gap: 30px; } }

/* ---------------------------------------------------------------------
   Plan cards
   --------------------------------------------------------------------- */
.plans-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
@media (max-width: 1100px) { .plans-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .plans-grid { grid-template-columns: 1fr; } }

.plan-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 30px 26px;
  display: flex;
  flex-direction: column;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.plan-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: var(--border-strong); }
.plan-card.featured { border-color: rgba(109,91,240,.55); box-shadow: var(--shadow-glow); background: linear-gradient(180deg, rgba(109,91,240,.08), var(--surface) 40%); }
.plan-featured-tag {
  position: absolute; top: -13px; left: 50%; transform: translateX(-50%);
  background: var(--grad-primary); color: #fff; font-size: 11.5px; font-weight: 700;
  padding: 5px 14px; border-radius: 999px; text-transform: uppercase; letter-spacing: .05em;
  box-shadow: 0 6px 16px rgba(109,91,240,.5);
}
.plan-icon { font-size: 30px; margin-bottom: 14px; }
.plan-name { font-size: 19px; margin-bottom: 4px; }
.plan-tagline { font-size: 13px; color: var(--text-faint); margin-bottom: 20px; min-height: 32px; }
.plan-roi { font-family: var(--font-heading); font-size: 38px; font-weight: 800; }
.plan-roi span { font-size: 15px; color: var(--text-faint); font-weight: 500; }
.plan-meta { list-style: none; padding: 0; margin: 20px 0 26px; display: flex; flex-direction: column; gap: 11px; }
.plan-meta li { display: flex; justify-content: space-between; font-size: 13.5px; color: var(--text-muted); border-bottom: 1px dashed var(--border); padding-bottom: 11px; }
.plan-meta li b { color: var(--text); font-weight: 600; }
.plan-card .btn { margin-top: auto; }

/* ---------------------------------------------------------------------
   How it works / steps
   --------------------------------------------------------------------- */
.steps-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
@media (max-width: 900px) { .steps-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .steps-grid { grid-template-columns: 1fr; } }
.step-card { text-align: left; }
.step-num {
  width: 44px; height: 44px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center; font-family: var(--font-heading); font-weight: 800;
  color: var(--primary-light); margin-bottom: 16px; font-size: 16px;
}

/* ---------------------------------------------------------------------
   Testimonials / FAQ
   --------------------------------------------------------------------- */
.testimonial-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
@media (max-width: 900px) { .testimonial-grid { grid-template-columns: 1fr; } }
.testimonial-card .stars { color: var(--gold); margin-bottom: 12px; letter-spacing: 2px; }
.testimonial-person { display: flex; align-items: center; gap: 12px; margin-top: 18px; }
.testimonial-avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--grad-primary); display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px; color: #fff; }

.accordion-item { border-bottom: 1px solid var(--border); }
.accordion-header { display: flex; align-items: center; justify-content: space-between; padding: 20px 4px; cursor: pointer; font-weight: 600; font-size: 15px; }
.accordion-header .icon { transition: transform .2s ease; color: var(--text-faint); }
.accordion-item.open .accordion-header .icon { transform: rotate(45deg); }
.accordion-body { max-height: 0; overflow: hidden; transition: max-height .25s ease; }
.accordion-item.open .accordion-body { max-height: 400px; }
.accordion-body p { padding: 0 4px 20px; }

/* ---------------------------------------------------------------------
   Footer
   --------------------------------------------------------------------- */
.site-footer { background: var(--bg-elevated); border-top: 1px solid var(--border); padding: 64px 0 28px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
.footer-grid h5 { font-size: 13px; text-transform: uppercase; letter-spacing: .05em; color: var(--text-faint); margin-bottom: 16px; }
.footer-grid a { display: block; color: var(--text-muted); font-size: 14px; margin-bottom: 10px; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; padding-top: 24px; border-top: 1px solid var(--border); color: var(--text-faint); font-size: 13px; flex-wrap: wrap; gap: 12px; }
.footer-disclaimer { max-width: 900px; margin: 0 auto 40px; font-size: 12px; color: var(--text-faint); text-align: center; line-height: 1.7; }

/* =====================================================================
   APP SHELL (user + admin dashboards)
   ===================================================================== */
.app-shell { display: flex; min-height: 100vh; }

.sidebar {
  width: 260px;
  flex-shrink: 0;
  background: var(--bg-elevated);
  border-right: 1px solid var(--border);
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  z-index: 50;
}
.sidebar-brand { padding: 24px 22px; border-bottom: 1px solid var(--border); }
.sidebar-nav { padding: 18px 14px; flex: 1; }
.sidebar-section-label { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--text-faint); padding: 16px 12px 8px; }
.sidebar-link {
  display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-radius: 10px;
  color: var(--text-muted); font-size: 14px; font-weight: 500; margin-bottom: 2px; transition: all .15s ease;
}
.sidebar-link i, .sidebar-link .ico { width: 18px; text-align: center; font-size: 15px; color: var(--text-faint); }
.sidebar-link:hover { background: var(--surface-2); color: var(--text); }
.sidebar-link.active { background: rgba(109,91,240,.14); color: var(--primary-light); }
.sidebar-link.active i, .sidebar-link.active .ico { color: var(--primary-light); }
.sidebar-link .count { margin-left: auto; background: var(--red); color: #fff; font-size: 10.5px; font-weight: 700; padding: 2px 7px; border-radius: 999px; }
.sidebar-footer { padding: 16px; border-top: 1px solid var(--border); }

.main-content { flex: 1; min-width: 0; }
.topbar {
  height: 72px; display: flex; align-items: center; justify-content: space-between;
  padding: 0 28px; border-bottom: 1px solid var(--border); background: rgba(8,11,18,.7); backdrop-filter: blur(12px);
  position: sticky; top: 0; z-index: 40;
}
.topbar-title { font-family: var(--font-heading); font-size: 19px; font-weight: 700; }
.topbar-actions { display: flex; align-items: center; gap: 18px; }
.sidebar-toggle { display: none; background: none; border: none; color: var(--text); font-size: 20px; cursor: pointer; }

.user-chip { display: flex; align-items: center; gap: 10px; cursor: pointer; }
.avatar-circle {
  width: 36px; height: 36px; border-radius: 50%; background: var(--grad-primary);
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px; color: #fff; flex-shrink: 0;
}
.avatar-circle.sm { width: 28px; height: 28px; font-size: 11px; }
.avatar-circle.lg { width: 64px; height: 64px; font-size: 22px; }

.page-body { padding: 28px; max-width: 1360px; }

.bell-btn { position: relative; background: none; border: none; color: var(--text-muted); font-size: 18px; cursor: pointer; }
.bell-dot { position: absolute; top: -2px; right: -2px; width: 9px; height: 9px; border-radius: 50%; background: var(--red); border: 2px solid var(--bg-elevated); }

@media (max-width: 980px) {
  .sidebar { position: fixed; left: 0; top: 0; transform: translateX(-100%); transition: transform .25s ease; box-shadow: var(--shadow-lg); }
  .sidebar.open { transform: translateX(0); }
  .sidebar-toggle { display: block; }
  .page-body { padding: 18px; }
  .topbar { padding: 0 16px; }
}
.sidebar-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 45; }
.sidebar-overlay.show { display: block; }

/* ---------------------------------------------------------------------
   Dashboard widgets
   --------------------------------------------------------------------- */
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-bottom: 24px; }
@media (max-width: 1100px) { .stat-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .stat-grid { grid-template-columns: 1fr; } }

.stat-card { padding: 22px; }
.stat-card .stat-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.stat-icon { width: 40px; height: 40px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 17px; }
.stat-icon.violet { background: rgba(109,91,240,.14); color: var(--primary-light); }
.stat-icon.gold { background: rgba(240,185,11,.14); color: var(--gold); }
.stat-icon.emerald { background: rgba(34,197,94,.14); color: var(--emerald); }
.stat-icon.rose { background: rgba(251,113,133,.14); color: var(--rose); }
.stat-value { font-family: var(--font-heading); font-size: 27px; font-weight: 800; }
.stat-label { font-size: 12.5px; color: var(--text-faint); margin-top: 4px; }
.stat-delta { font-size: 12px; font-weight: 700; }
.stat-delta.up { color: var(--emerald); }
.stat-delta.down { color: var(--red); }

.dash-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; align-items: start; }
@media (max-width: 1000px) { .dash-grid { grid-template-columns: 1fr; } }

.card-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.card-title { font-size: 16px; font-weight: 700; margin: 0; }
.card-title .sub { display: block; font-size: 12.5px; font-weight: 400; color: var(--text-faint); margin-top: 3px; }

.investment-row { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--border); }
.investment-row:last-child { border-bottom: none; }
.inv-plan-icon { width: 42px; height: 42px; border-radius: 10px; background: var(--surface-2); display: flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0; }
.investment-row .inv-info { flex: 1; min-width: 0; }
.investment-row .inv-name { font-weight: 600; font-size: 14px; }
.investment-row .inv-sub { font-size: 12.5px; color: var(--text-faint); }
.investment-row .inv-right { text-align: right; flex-shrink: 0; }

.timeline-item { display: flex; gap: 14px; padding-bottom: 22px; position: relative; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-item::before { content: ''; position: absolute; left: 5px; top: 22px; bottom: 0; width: 1px; background: var(--border); }
.timeline-item:last-child::before { display: none; }
.timeline-dot { width: 11px; height: 11px; border-radius: 50%; background: var(--primary); margin-top: 4px; flex-shrink: 0; box-shadow: 0 0 0 3px rgba(109,91,240,.2); }
.timeline-dot.success { background: var(--emerald); box-shadow: 0 0 0 3px rgba(34,197,94,.2); }
.timeline-dot.warning { background: var(--amber); box-shadow: 0 0 0 3px rgba(245,158,11,.2); }

.countdown { display: flex; gap: 8px; }
.countdown .unit { background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px; padding: 8px 6px; text-align: center; min-width: 46px; }
.countdown .unit b { display: block; font-family: var(--font-heading); font-size: 17px; }
.countdown .unit span { font-size: 9.5px; color: var(--text-faint); text-transform: uppercase; }

/* Wallet / QR box */
.wallet-box { background: var(--bg-elevated); border: 1px solid var(--border-strong); border-radius: var(--radius-md); padding: 20px; }
.wallet-address { font-family: 'SF Mono', 'Consolas', monospace; font-size: 13px; background: var(--surface-2); padding: 12px 14px; border-radius: 8px; word-break: break-all; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.copy-btn { background: var(--surface-hover); border: 1px solid var(--border-strong); color: var(--text-muted); border-radius: 6px; padding: 6px 10px; cursor: pointer; font-size: 12px; flex-shrink: 0; }
.copy-btn:hover { color: var(--text); }
.qr-box { width: 150px; height: 150px; background: #fff; border-radius: 10px; margin: 0 auto 16px; display: flex; align-items: center; justify-content: center; padding: 10px; }

.method-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 20px; }
.method-tab { padding: 10px 16px; border-radius: 10px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text-muted); cursor: pointer; font-size: 13.5px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.method-tab.active { border-color: var(--primary); color: var(--primary-light); background: rgba(109,91,240,.1); }

/* Login / register auth screens */
.auth-shell { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
@media (max-width: 900px) { .auth-shell { grid-template-columns: 1fr; } }
.auth-visual { background: var(--bg-elevated); position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: center; padding: 60px; }
.auth-visual::before { content: ''; position: absolute; inset: 0; background: var(--grad-hero); }
.auth-form-side { display: flex; align-items: center; justify-content: center; padding: 40px 24px; }
.auth-box { width: 100%; max-width: 400px; }
.auth-box .brand { margin-bottom: 32px; }
@media (max-width: 900px) { .auth-visual { display: none; } }

/* Misc utility */
.divider-or { display: flex; align-items: center; gap: 14px; color: var(--text-faint); font-size: 12.5px; margin: 22px 0; }
.divider-or::before, .divider-or::after { content: ''; flex: 1; height: 1px; background: var(--border); }

.pagination { display: flex; gap: 6px; margin-top: 20px; flex-wrap: wrap; }
.pagination a, .pagination span { padding: 8px 13px; border-radius: 8px; border: 1px solid var(--border); color: var(--text-muted); font-size: 13px; }
.pagination a:hover { border-color: var(--primary); color: var(--primary-light); }
.pagination .current { background: var(--primary); color: #fff; border-color: var(--primary); }

.empty-state { text-align: center; padding: 60px 20px; color: var(--text-faint); }
.empty-state .empty-icon { font-size: 40px; margin-bottom: 14px; opacity: .6; }

.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 22px; overflow-x: auto; }
.tab-link { padding: 12px 18px; font-size: 13.5px; font-weight: 600; color: var(--text-faint); border-bottom: 2px solid transparent; white-space: nowrap; }
.tab-link.active { color: var(--text); border-color: var(--primary); }

.modal-backdrop { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.6); z-index: 200; align-items: center; justify-content: center; padding: 20px; }
.modal-backdrop.show { display: flex; }
.modal-box { background: var(--surface); border: 1px solid var(--border-strong); border-radius: var(--radius-lg); padding: 26px; max-width: 460px; width: 100%; box-shadow: var(--shadow-lg); }

.kpi-inline { display: flex; align-items: baseline; gap: 8px; }
.kpi-inline .big { font-family: var(--font-heading); font-size: 24px; font-weight: 800; }

.spinner { width: 16px; height: 16px; border: 2px solid rgba(255,255,255,.3); border-top-color: #fff; border-radius: 50%; animation: spin .6s linear infinite; display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }

.scroll-x { overflow-x: auto; }
[data-aos] { }

/* Print-friendly receipt (optional) */
@media print { .sidebar, .topbar, .no-print { display: none !important; } }
