@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;500;600;700;800&family=Inter:wght@300;400;500;600&family=DM+Mono:ital,wght@0,400;0,500&display=swap');

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0
}

:root {
  --bg: #070c17;
  --s1: #0d1526;
  --s2: #131f35;
  --s3: #1a2a42;
  --s4: #213352;
  --b: rgba(100, 140, 230, .07);
  --b2: rgba(100, 140, 230, .14);
  --b3: rgba(100, 140, 230, .22);
  --t1: #e8edf5;
  --t2: #8a9ab5;
  --t3: #4a5a70;
  --accent: #00e5a0;
  --a05: rgba(0, 229, 160, .05);
  --a10: rgba(0, 229, 160, .1);
  --a20: rgba(0, 229, 160, .2);
  --red: #ff5c7a;
  --r10: rgba(255, 92, 122, .1);
  --r20: rgba(255, 92, 122, .2);
  --gold: #ffc947;
  --g10: rgba(255, 201, 71, .1);
  --blue: #4dabf7;
  --bl10: rgba(77, 171, 247, .1);
  --purple: #a78bfa;
  --p10: rgba(167, 139, 250, .1);
  --orange: #fb923c;
  --o10: rgba(251, 146, 60, .1);
  --teal: #2dd4bf;
  --tl10: rgba(45, 212, 191, .1);
  --sidebar-w: 240px;
  --topbar-h: 60px;
  --r: 12px;
  --rs: 8px;
  --rl: 16px;
  --shadow: 0 8px 40px rgba(0, 0, 0, .5);
  --shadow-sm: 0 2px 12px rgba(0, 0, 0, .35);
  --font: Inter, sans-serif;
  --font-d: 'Syne', sans-serif;
  --font-m: 'DM Mono', monospace;
  --ease: .18s cubic-bezier(.4, 0, .2, 1);
}

.light {
  --bg: #f0f4fa;
  --s1: #fff;
  --s2: #f5f8ff;
  --s3: #eaeff8;
  --s4: #dde6f5;
  --b: rgba(0, 0, 0, .06);
  --b2: rgba(0, 0, 0, .1);
  --b3: rgba(0, 0, 0, .16);
  --t1: #0a1020;
  --t2: #4a5a70;
  --t3: #94a3b8;
  --shadow: 0 8px 40px rgba(0, 0, 0, .1);
  --shadow-sm: 0 2px 12px rgba(0, 0, 0, .07);
}

html,
body {
  height: 100%;
  background: var(--bg);
  color: var(--t1);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased
}

/* ── LAYOUT ─────────────────────────────────────── */
#app {
  display: flex;
  height: 100vh;
  overflow: hidden
}

#login-screen {
  width: 100%
}

.sidebar {
  width: var(--sidebar-w);
  background: var(--s1);
  border-right: 1px solid var(--b);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  overflow: hidden;
  transition: width var(--ease);
  z-index: 100
}

.sidebar.collapsed {
  width: 64px
}

.sb-logo {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--b);
  min-height: var(--topbar-h)
}

.logo-mark {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--accent), #00a870);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-d);
  font-weight: 800;
  font-size: 13px;
  color: #070c17;
  flex-shrink: 0;
  letter-spacing: -.5px
}

.logo-text {
  font-family: var(--font-d);
  font-weight: 700;
  font-size: 15px;
  color: var(--t1);
  white-space: nowrap;
  transition: opacity var(--ease)
}

.sidebar.collapsed .logo-text {
  opacity: 0;
  pointer-events: none;
  width: 0;
  overflow: hidden
}

.sb-nav {
  flex: 1;
  padding: 10px 10px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow-y: auto
}

.sb-nav::-webkit-scrollbar {
  width: 0
}

.nav-section {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--t3);
  padding: 12px 8px 4px;
  white-space: nowrap;
  transition: opacity var(--ease)
}

.sidebar.collapsed .nav-section {
  opacity: 0;
  height: 0;
  padding: 0;
  overflow: hidden
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 9px 10px;
  border-radius: var(--rs);
  cursor: pointer;
  transition: background var(--ease), color var(--ease);
  color: var(--t2);
  white-space: nowrap;
  user-select: none
}

.nav-item:hover {
  background: var(--s3);
  color: var(--t1)
}

.nav-item.active {
  background: var(--a10);
  color: var(--accent)
}

.nav-item.active .ni {
  color: var(--accent)
}

.ni {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center
}

.ni svg {
  width: 16px;
  height: 16px;
  stroke-width: 1.8
}

.nav-label {
  font-size: 13px;
  font-weight: 500;
  transition: opacity var(--ease)
}

.sidebar.collapsed .nav-label {
  opacity: 0;
  pointer-events: none;
  width: 0;
  overflow: hidden
}

.sb-footer {
  padding: 10px 10px;
  border-top: 1px solid var(--b);
  display: flex;
  flex-direction: column;
  gap: 3px
}

.user-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 8px;
  border-radius: var(--rs);
  cursor: pointer;
  transition: background var(--ease)
}

.user-row:hover {
  background: var(--s3)
}

.avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), #00a870);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  color: #070c17;
  flex-shrink: 0
}

.user-info-sb {
  overflow: hidden;
  transition: opacity var(--ease)
}

.sidebar.collapsed .user-info-sb {
  opacity: 0;
  pointer-events: none;
  width: 0
}

.user-name-sb {
  font-size: 13px;
  font-weight: 600;
  color: var(--t1);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis
}

.user-email-sb {
  font-size: 11px;
  color: var(--t3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis
}

.theme-row {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 8px 10px;
  border-radius: var(--rs);
  cursor: pointer;
  color: var(--t2);
  font-size: 13px;
  font-weight: 500;
  transition: background var(--ease), color var(--ease)
}

.theme-row:hover {
  background: var(--s3);
  color: var(--t1)
}

.sidebar.collapsed .theme-row span {
  display: none
}

.sidebar.collapsed .sb-footer .ui-toggle-wrap {
  display: none !important
}

.sidebar.collapsed .sb-logout-label {
  display: none
}

/* ── MAIN ────────────────────────────────────────── */
.main {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden
}

.topbar {
  height: var(--topbar-h);
  border-bottom: 1px solid var(--b);
  display: flex;
  align-items: center;
  padding: 0 20px;
  gap: 14px;
  flex-shrink: 0;
  background: var(--bg)
}

.topbar-toggle {
  width: 34px;
  height: 34px;
  border-radius: var(--rs);
  border: 1px solid var(--b2);
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--t2);
  transition: background var(--ease), color var(--ease);
  flex-shrink: 0
}

.topbar-toggle:hover {
  background: var(--s2);
  color: var(--t1)
}

.topbar-toggle svg {
  width: 15px;
  height: 15px;
  stroke-width: 1.8
}

.topbar-bc {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px
}

.bc-title {
  font-family: var(--font-d);
  font-weight: 700;
  font-size: 15px;
  color: var(--t1)
}

.bc-sep {
  color: var(--t3);
  font-size: 13px
}

.bc-sub {
  font-size: 13px;
  color: var(--t3)
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 8px
}

.iBtn {
  width: 34px;
  height: 34px;
  border-radius: var(--rs);
  border: 1px solid var(--b2);
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--t2);
  transition: background var(--ease), color var(--ease)
}

.iBtn:hover {
  background: var(--s2);
  color: var(--t1)
}

.iBtn svg {
  width: 15px;
  height: 15px;
  stroke-width: 1.8
}

.screen {
  flex: 1;
  overflow-y: auto;
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 18px
}

.screen::-webkit-scrollbar {
  width: 4px
}

.screen::-webkit-scrollbar-thumb {
  background: var(--s4);
  border-radius: 4px
}

/* ── SCREEN HEADER ───────────────────────────────── */
.sh {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap
}

.sh-l {
  display: flex;
  flex-direction: column;
  gap: 3px
}

.sh-title {
  font-family: var(--font-d);
  font-weight: 700;
  font-size: 21px;
  color: var(--t1)
}

.sh-sub {
  font-size: 12px;
  color: var(--t3)
}

.sh-r {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap
}

/* ── BUTTONS ─────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 13px;
  border-radius: var(--rs);
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--ease);
  border: none;
  font-family: var(--font);
  white-space: nowrap
}

.btn svg {
  width: 13px;
  height: 13px;
  stroke-width: 2
}

.btn-primary {
  background: var(--accent);
  color: #070c17
}

.btn-primary:hover {
  background: #00c98d
}

.btn-secondary {
  background: var(--s2);
  color: var(--t1);
  border: 1px solid var(--b2)
}

.btn-secondary:hover {
  background: var(--s3)
}

.btn-ghost {
  background: transparent;
  color: var(--t2);
  border: 1px solid var(--b2)
}

.btn-ghost:hover {
  background: var(--s2);
  color: var(--t1)
}

.btn-danger {
  background: var(--r10);
  color: var(--red);
  border: 1px solid var(--r20)
}

.btn-danger:hover {
  background: var(--r20)
}

.btn-sm {
  padding: 5px 10px;
  font-size: 11.5px
}

.btn-icon {
  width: 30px;
  height: 30px;
  padding: 0;
  justify-content: center;
  border-radius: 6px;
  background: transparent;
  color: var(--t3);
  border: 1px solid transparent
}

.btn-icon:hover {
  background: var(--s3);
  color: var(--t2);
  border-color: var(--b2)
}

.btn-icon svg {
  width: 13px;
  height: 13px
}

/* ── SUMMARY STRIP ───────────────────────────────── */
.strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px
}

.stat {
  background: var(--s1);
  border: 1px solid var(--b);
  border-radius: var(--r);
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  transition: border-color var(--ease), box-shadow var(--ease)
}

.stat:hover {
  border-color: var(--b2);
  box-shadow: var(--shadow-sm)
}

.stat-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--t3)
}

.stat-val {
  font-family: var(--font-d);
  font-weight: 700;
  font-size: 20px;
  color: var(--t1);
  line-height: 1.1
}

.stat-val.pos {
  color: var(--accent)
}

.stat-val.neg {
  color: var(--red)
}

.stat-val.gld {
  color: var(--gold)
}

.stat-val.blu {
  color: var(--blue)
}

.stat-badge {
  font-size: 10px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 999px
}

.badge-up {
  background: var(--a10);
  color: var(--accent)
}

.badge-dn {
  background: var(--r10);
  color: var(--red)
}

.badge-neu {
  background: var(--s3);
  color: var(--t2)
}

.badge-gld {
  background: var(--g10);
  color: var(--gold)
}

/* ── CARDS ───────────────────────────────────────── */
.card {
  background: var(--s1);
  border: 1px solid var(--b);
  border-radius: var(--r);
  overflow: visible
}

.card-hd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--b)
}

.card-hd-r {
  display: flex;
  align-items: center;
  gap: 8px
}

.card-title {
  font-family: var(--font-d);
  font-weight: 600;
  font-size: 13px;
  color: var(--t1);
  display: flex;
  align-items: center;
  gap: 7px
}

.card-title svg {
  width: 14px;
  height: 14px;
  stroke-width: 1.8;
  color: var(--t3)
}

.card-body {
  padding: 18px
}

/* ── TABLES ──────────────────────────────────────── */
.tbl-wrap {
  overflow-x: auto
}

.tbl {
  width: 100%;
  border-collapse: collapse
}

.tbl th {
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--t3);
  padding: 9px 14px;
  text-align: left;
  border-bottom: 1px solid var(--b);
  white-space: nowrap;
  cursor: pointer;
  user-select: none;
  transition: color var(--ease)
}

.tbl th:hover {
  color: var(--t2)
}

.tbl th.sa::after {
  content: ' ↑'
}

.tbl th.sd::after {
  content: ' ↓'
}

.tbl td {
  padding: 11px 14px;
  border-bottom: 1px solid var(--b);
  color: var(--t1);
  font-size: 13px;
  vertical-align: middle
}

.tbl tr:last-child td {
  border-bottom: none
}

.tbl tr:hover td {
  background: var(--s2)
}

.tbl .mono {
  font-family: var(--font-m);
  font-size: 12.5px
}

.tbl .pos {
  color: var(--accent)
}

.tbl .neg {
  color: var(--red)
}

.tbl .muted {
  color: var(--t3);
  font-size: 11.5px
}

.tbl .actions {
  display: flex;
  gap: 4px;
  opacity: 0;
  transition: opacity var(--ease)
}

.tbl tr:hover .actions {
  opacity: 1
}

/* ── PILLS ───────────────────────────────────────── */
.pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 600;
  white-space: nowrap
}

.p-stock {
  background: var(--bl10);
  color: var(--blue)
}

.p-mf {
  background: var(--p10);
  color: var(--purple)
}

.p-fd {
  background: var(--g10);
  color: var(--gold)
}

.p-bond {
  background: rgba(100, 200, 255, .1);
  color: #64c8ff
}

.p-epf {
  background: var(--a10);
  color: var(--accent)
}

.p-esop {
  background: var(--o10);
  color: var(--orange)
}

.p-re {
  background: var(--tl10);
  color: var(--teal)
}

.p-gold {
  background: var(--g10);
  color: var(--gold)
}

.p-other {
  background: var(--s3);
  color: var(--t2)
}

.p-home {
  background: var(--tl10);
  color: var(--teal)
}

.p-vehicle {
  background: var(--bl10);
  color: var(--blue)
}

.p-personal {
  background: var(--o10);
  color: var(--orange)
}

.p-education {
  background: var(--p10);
  color: var(--purple)
}

/* ── FILTER TABS ─────────────────────────────────── */
.filter-tabs {
  display: flex;
  gap: 2px;
  flex-wrap: wrap;
  padding: 3px;
  background: var(--s2);
  border-radius: 9px;
  border: 1px solid var(--b);
  width: fit-content
}

.ftab {
  padding: 5px 11px;
  border-radius: 7px;
  font-size: 11.5px;
  font-weight: 500;
  cursor: pointer;
  color: var(--t2);
  transition: all var(--ease);
  white-space: nowrap;
  border: none;
  background: transparent;
  font-family: var(--font)
}

.ftab:hover {
  color: var(--t1)
}

.ftab.active {
  background: var(--s1);
  color: var(--t1);
  box-shadow: var(--shadow-sm)
}

/* ── INPUTS ──────────────────────────────────────── */
.inp {
  background: var(--s2);
  border: 1px solid var(--b2);
  border-radius: var(--rs);
  padding: 8px 11px;
  color: var(--t1);
  font-family: var(--font);
  font-size: 13px;
  width: 100%;
  transition: border-color var(--ease), box-shadow var(--ease)
}

.inp:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--a10)
}

.inp::placeholder {
  color: var(--t3)
}

.inp-sm {
  padding: 5px 9px;
  font-size: 12px
}

.inp-grp {
  display: flex;
  flex-direction: column;
  gap: 5px
}

.inp-label {
  font-size: 11.5px;
  font-weight: 500;
  color: var(--t2)
}

.sel {
  background: var(--s2);
  border: 1px solid var(--b2);
  border-radius: var(--rs);
  padding: 8px 30px 8px 11px;
  color: var(--t1);
  font-family: var(--font);
  font-size: 13px;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238a9ab5' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 9px center;
  width: 100%
}

.sel:focus {
  outline: none;
  border-color: var(--accent)
}

/* ── PROGRESS ────────────────────────────────────── */
.prog {
  height: 4px;
  background: var(--s3);
  border-radius: 999px;
  overflow: hidden
}

.prog-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), #00c98d);
  transition: width .7s cubic-bezier(.4, 0, .2, 1)
}

.prog-fill.red {
  background: linear-gradient(90deg, var(--red), #ff8a9a)
}

.prog-fill.gold {
  background: linear-gradient(90deg, var(--gold), #ffd980)
}

.prog-fill.blue {
  background: linear-gradient(90deg, var(--blue), #7ecbff)
}

/* ── MODALS ──────────────────────────────────────── */
.modal-bg {
  position: fixed;
  inset: 0;
  background: rgba(4, 8, 18, .82);
  backdrop-filter: blur(4px);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  animation: fIn .2s forwards
}

@keyframes fIn {
  to {
    opacity: 1
  }
}

.modal {
  background: var(--s1);
  border: 1px solid var(--b2);
  border-radius: var(--rl);
  width: 100%;
  max-width: 540px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow);
  transform: translateY(16px);
  animation: sUp .2s forwards
}

.modal-lg {
  max-width: 760px
}

.modal-xl {
  max-width: 940px
}

@keyframes sUp {
  to {
    transform: translateY(0)
  }
}

.modal-hd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 22px;
  border-bottom: 1px solid var(--b);
  position: sticky;
  top: 0;
  background: var(--s1);
  z-index: 2
}

.modal-title {
  font-family: var(--font-d);
  font-weight: 700;
  font-size: 15px;
  color: var(--t1)
}

.modal-close {
  width: 28px;
  height: 28px;
  border-radius: var(--rs);
  border: 1px solid var(--b2);
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--t2);
  transition: all var(--ease)
}

.modal-close:hover {
  background: var(--r10);
  color: var(--red);
  border-color: var(--r20)
}

.modal-close svg {
  width: 13px;
  height: 13px;
  stroke-width: 2
}

.modal-body {
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 14px
}

.modal-ft {
  padding: 14px 22px;
  border-top: 1px solid var(--b);
  display: flex;
  justify-content: flex-end;
  gap: 8px
}

/* ── LOGIN ───────────────────────────────────────── */
.login-wrap {
  display: flex;
  height: 100vh;
  align-items: center;
  justify-content: center;
  background: var(--bg)
}

.login-card {
  background: var(--s1);
  border: 1px solid var(--b2);
  border-radius: var(--rl);
  padding: 44px;
  width: 100%;
  max-width: 400px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 26px;
  box-shadow: var(--shadow)
}

.login-logo {
  width: 54px;
  height: 54px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--accent), #00a870);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-d);
  font-weight: 800;
  font-size: 21px;
  color: #070c17
}

.login-card h1 {
  font-family: var(--font-d);
  font-weight: 800;
  font-size: 26px;
  color: var(--t1);
  text-align: center
}

.login-card p {
  font-size: 13.5px;
  color: var(--t3);
  text-align: center;
  line-height: 1.6;
  margin-top: -16px
}

.login-btns {
  display: flex;
  flex-direction: column;
  gap: 9px;
  width: 100%
}

.btn-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 11px 18px;
  border-radius: var(--rs);
  border: 1px solid var(--b2);
  background: var(--s2);
  color: var(--t1);
  font-size: 13.5px;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--ease);
  font-family: var(--font);
  width: 100%
}

.btn-google:hover {
  background: var(--s3)
}

.login-div {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  color: var(--t3);
  font-size: 11.5px
}

.login-div::before,
.login-div::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--b2)
}

.login-feats {
  display: flex;
  flex-direction: column;
  gap: 7px;
  width: 100%
}

.login-feat {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 12.5px;
  color: var(--t3)
}

.feat-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0
}

/* ── WALKTHROUGH ─────────────────────────────────── */
.wt-bg {
  position: fixed;
  inset: 0;
  background: rgba(4, 8, 18, .92);
  backdrop-filter: blur(8px);
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px
}

.wt-card {
  background: var(--s1);
  border: 1px solid var(--b2);
  border-radius: var(--rl);
  padding: 44px;
  max-width: 460px;
  width: 100%;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  box-shadow: var(--shadow)
}

.wt-icon {
  width: 68px;
  height: 68px;
  border-radius: 18px;
  background: var(--a10);
  border: 1px solid var(--a20);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent)
}

.wt-icon svg {
  width: 30px;
  height: 30px;
  stroke-width: 1.5
}

.wt-title {
  font-family: var(--font-d);
  font-weight: 700;
  font-size: 21px;
  color: var(--t1)
}

.wt-desc {
  font-size: 13.5px;
  color: var(--t2);
  line-height: 1.7
}

.wt-dots {
  display: flex;
  gap: 5px
}

.wt-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--s4);
  transition: all var(--ease)
}

.wt-dot.active {
  width: 20px;
  border-radius: 999px;
  background: var(--accent)
}

.wt-nav {
  display: flex;
  gap: 9px;
  width: 100%;
  justify-content: center;
  margin-top: 6px
}

/* ── DASHBOARD ───────────────────────────────────── */
.fire-banner {
  background: linear-gradient(135deg, rgba(0, 229, 160, .08), rgba(77, 171, 247, .05));
  border: 1px solid rgba(0, 229, 160, .18);
  border-radius: var(--r);
  padding: 22px 26px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap
}

.fire-num {
  font-family: var(--font-d);
  font-weight: 800;
  font-size: 34px;
  color: var(--accent);
  line-height: 1
}

.fire-label {
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--t3)
}

.dash-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px
}

.dash-card {
  background: var(--s1);
  border: 1px solid var(--b);
  border-radius: var(--r);
  padding: 18px;
  cursor: pointer;
  transition: all var(--ease);
  display: flex;
  flex-direction: column;
  gap: 11px
}

.dash-card:hover {
  border-color: var(--b2);
  box-shadow: var(--shadow-sm);
  transform: translateY(-2px)
}

.dash-icon {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center
}

.dash-icon svg {
  width: 18px;
  height: 18px;
  stroke-width: 1.8
}

.dash-val {
  font-family: var(--font-d);
  font-weight: 700;
  font-size: 19px;
  color: var(--t1)
}

.dash-lbl {
  font-size: 11.5px;
  color: var(--t3);
  font-weight: 500;
  margin-bottom: 2px
}

.dash-sub {
  font-size: 11.5px;
  color: var(--t3);
  margin-top: 1px
}

/* ── MONTHLY ─────────────────────────────────────── */
.sec-hd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 12px 18px;
  border-bottom: 1px solid var(--b);
  transition: background var(--ease);
  user-select: none
}

.sec-hd:hover {
  background: var(--s2)
}

.sec-hd-l {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--t1)
}

.sec-hd-l svg {
  width: 14px;
  height: 14px;
  stroke-width: 1.8
}

.chevron {
  color: var(--t3);
  transition: transform var(--ease);
  width: 14px;
  height: 14px;
  stroke-width: 2
}

.chevron.open {
  transform: rotate(180deg)
}

.sec-body {
  overflow: hidden;
  transition: height var(--ease)
}

/* ── CHECKLIST ───────────────────────────────────── */
.cl-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 18px;
  border-bottom: 1px solid var(--b);
  font-size: 13px;
  color: var(--t1)
}

.cl-item:last-child {
  border-bottom: none
}

.cl-box {
  width: 17px;
  height: 17px;
  border-radius: 5px;
  border: 1.5px solid var(--b2);
  cursor: pointer;
  transition: all var(--ease);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center
}

.cl-box.done {
  background: var(--accent);
  border-color: var(--accent)
}

.cl-box.done svg {
  width: 10px;
  height: 10px;
  stroke-width: 3;
  color: #070c17
}

.cl-item.done-item>span {
  color: var(--t3);
  text-decoration: line-through
}

/* ── NOTES ───────────────────────────────────────── */
.note {
  background: var(--s2);
  border: 1px solid var(--b);
  border-radius: var(--rs);
  padding: 11px 13px;
  font-size: 12.5px;
  color: var(--t1);
  line-height: 1.6;
  position: relative;
  display: flex;
  gap: 10px
}

.note.pinned {
  border-color: rgba(0, 229, 160, .2);
  background: rgba(0, 229, 160, .04)
}

.note-pin {
  width: 5px;
  border-radius: 999px;
  background: var(--accent);
  flex-shrink: 0;
  opacity: 0
}

.note.pinned .note-pin {
  opacity: 1
}

.note-acts {
  display: flex;
  gap: 3px;
  margin-left: auto;
  flex-shrink: 0
}

/* ── SYNC INDICATOR ──────────────────────────────── */
.sync {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--t3);
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--s2);
  border: 1px solid var(--b)
}

.sync-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 2s infinite
}

@keyframes pulse {

  0%,
  100% {
    opacity: 1;
    transform: scale(1)
  }

  50% {
    opacity: .4;
    transform: scale(.8)
  }
}

.sync-dot.off {
  background: var(--red);
  animation: none
}

/* ── LIVE BADGE ──────────────────────────────────── */
.live {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 10px;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: .06em
}

.live-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 2s infinite
}

/* ── LOAN CARDS ──────────────────────────────────── */
.loan-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
  gap: 14px
}

.loan-card {
  background: var(--s1);
  border: 1px solid var(--b);
  border-radius: var(--r);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 13px;
  cursor: pointer;
  transition: all var(--ease)
}

.loan-card:hover {
  border-color: var(--b2);
  box-shadow: var(--shadow-sm)
}

.loan-stats-g {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px
}

.lsg-label {
  font-size: 10.5px;
  color: var(--t3);
  margin-bottom: 2px
}

.lsg-val {
  font-family: var(--font-m);
  font-size: 12.5px;
  font-weight: 500;
  color: var(--t1)
}

/* ── AMORTIZATION ────────────────────────────────── */
.amort-paid td {
  color: var(--t3) !important
}

.amort-current td {
  background: var(--a05) !important
}

.amort-current td:first-child {
  border-left: 2px solid var(--accent)
}

/* ── CHARTS ──────────────────────────────────────── */
.chart-area {
  background: var(--s1);
  border: 1px solid var(--b);
  border-radius: var(--r)
}

.chart-wrap {
  position: relative;
  height: 220px
}

.charts-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px
}

/* ── PORTFOLIO ───────────────────────────────────── */
.alloc-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  padding: 5px 0;
  border-bottom: 1px solid var(--b)
}

.alloc-row:last-child {
  border-bottom: none
}

.alloc-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0
}

.alloc-lbl {
  flex: 1;
  color: var(--t2)
}

.alloc-pct {
  font-family: var(--font-m);
  font-size: 11px;
  color: var(--t3);
  min-width: 36px;
  text-align: right
}

.alloc-val {
  font-family: var(--font-m);
  font-size: 11.5px;
  color: var(--t1);
  min-width: 70px;
  text-align: right
}

/* ── SMART FILL ──────────────────────────────────── */
.sf-item {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 9px 0;
  border-bottom: 1px solid var(--b)
}

.sf-item:last-child {
  border-bottom: none
}

.sf-name {
  flex: 1;
  font-size: 13px;
  color: var(--t1)
}

.sf-freq {
  font-size: 11px;
  color: var(--t3)
}

.sf-amt {
  font-family: var(--font-m);
  font-size: 13px;
  font-weight: 500;
  color: var(--t1)
}

/* ── IMPORT ──────────────────────────────────────── */
.dropzone {
  border: 2px dashed var(--b2);
  border-radius: var(--r);
  padding: 36px;
  text-align: center;
  cursor: pointer;
  transition: all var(--ease);
  color: var(--t3)
}

.dropzone:hover {
  border-color: var(--accent);
  background: var(--a05);
  color: var(--accent)
}

.broker-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 7px
}

.broker-btn {
  background: var(--s2);
  border: 1.5px solid var(--b2);
  border-radius: var(--rs);
  padding: 10px 8px;
  text-align: center;
  cursor: pointer;
  transition: all var(--ease);
  font-size: 11.5px;
  font-weight: 500;
  color: var(--t2)
}

.broker-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--a05)
}

.broker-btn.sel {
  border-color: var(--accent);
  background: var(--a10);
  color: var(--accent)
}

/* ── INSIGHT ITEMS ───────────────────────────────── */
.insight {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 10px 12px;
  background: var(--s2);
  border-radius: var(--rs);
  font-size: 13px;
  color: var(--t1);
  line-height: 1.55
}

.insight-ico {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 13px;
  margin-top: 1px
}

/* ── MISC UTILITIES ──────────────────────────────── */
.divider {
  height: 1px;
  background: var(--b);
  margin: 2px 0
}

.row {
  display: flex;
  align-items: center;
  gap: 8px
}

.col {
  display: flex;
  flex-direction: column;
  gap: 8px
}

.g-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px
}

.g-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px
}

.text-mono {
  font-family: var(--font-m)
}

.text-pos {
  color: var(--accent)
}

.text-neg {
  color: var(--red)
}

.text-gld {
  color: var(--gold)
}

.text-muted {
  color: var(--t3)
}

.text-sm {
  font-size: 11.5px
}

.text-d {
  font-family: var(--font-d);
  font-weight: 700
}

.ml-auto {
  margin-left: auto
}

.w-full {
  width: 100%
}

.hide {
  display: none !important
}

.section-count {
  background: var(--s3);
  color: var(--t2);
  font-size: 10.5px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 999px;
  font-family: var(--font-m)
}

@media(max-width:900px) {
  .sidebar {
    width: 64px
  }

  .sidebar .logo-text,
  .sidebar .nav-label,
  .sidebar .nav-section,
  .sidebar .user-info-sb,
  .sidebar .theme-row span {
    opacity: 0;
    width: 0;
    overflow: hidden
  }

  .sidebar .sb-footer .ui-toggle-wrap {
    display: none !important
  }

  .sidebar .sb-logout-label {
    display: none
  }

  .dash-grid {
    grid-template-columns: 1fr
  }
}

@media(max-width:600px) {
  .screen {
    padding: 14px
  }

  .strip {
    grid-template-columns: 1fr 1fr
  }

  .charts-row {
    grid-template-columns: 1fr
  }

  .g-2,
  .g-3 {
    grid-template-columns: 1fr
  }

  .dash-grid {
    grid-template-columns: 1fr
  }
}

/* ── MOBILE BOTTOM NAV ─────────────────────────────── */
.bottom-nav {
  display: none
}

@media(max-width:768px) {
  .sidebar {
    display: none !important
  }

  .topbar-toggle {
    display: none !important
  }

  .bottom-nav {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--s1);
    border-top: 1px solid var(--b);
    z-index: 100;
    padding: 6px 0 max(env(safe-area-inset-bottom), 6px)
  }

  .screen {
    padding-bottom: 80px
  }

  #bc-sep,
  #bc-sub {
    display: none
  }
}

.bnav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 6px 4px;
  cursor: pointer;
  color: var(--t3);
  transition: color var(--ease);
  font-size: 10px;
  font-weight: 500;
  user-select: none
}

.bnav-item:hover {
  color: var(--t2)
}

.bnav-item.active {
  color: var(--accent)
}

.bnav-item svg {
  width: 20px;
  height: 20px;
  stroke-width: 1.75
}

/* ── ACCORDION PANELS ──────────────────────────────── */
.acc-wrap {
  background: var(--s1);
  border: 1px solid var(--b);
  border-radius: var(--r);
  overflow: visible
}

.acc-panel {
  border-bottom: 1px solid var(--b)
}

.acc-panel:last-child {
  border-bottom: none
}

.acc-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  cursor: pointer;
  transition: background var(--ease);
  user-select: none;
  border-radius: 0
}

.acc-head:hover {
  background: var(--s2)
}

.acc-head-l {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 13px;
  color: var(--t1)
}

.acc-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0
}

.acc-head-r {
  display: flex;
  align-items: center;
  gap: 12px
}

.acc-total {
  font-family: var(--font-m);
  font-size: 13px;
  font-weight: 500
}

.acc-body {
  display: none
}

.acc-body.open {
  display: block
}

.acc-footer {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-top: 1px solid var(--b);
  background: var(--s2)
}

.chevron {
  transition: transform .2s ease;
  flex-shrink: 0
}

.chevron.open {
  transform: rotate(180deg)
}

/* ── INVESTMENT CARDS ──────────────────────────────── */
.inv-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 12px;
  padding: 16px
}

.inv-card {
  background: var(--s2);
  border: 1px solid var(--b);
  border-radius: var(--r);
  overflow: hidden;
  transition: border-color var(--ease), box-shadow var(--ease)
}

/* ═══════════════════════════════════════════════════════════
   AI ADVISOR MODULE
═══════════════════════════════════════════════════════════ */

/* ── Empty state ── */
.adv2-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .85rem;
  min-height: 52vh;
  padding: 3rem 1.5rem;
  text-align: center;
}
.adv2-empty-icon  { font-size: 3rem; line-height: 1; opacity: .55; }
.adv2-empty-title { font-family: var(--font-d); font-size: 20px; font-weight: 700; color: var(--t1); }
.adv2-empty-desc  { font-size: 13.5px; color: var(--t2); max-width: 360px; line-height: 1.65; }
.adv2-empty-btns  { display: flex; gap: .5rem; flex-wrap: wrap; justify-content: center; margin-top: .25rem; }

/* ── Insight cards ── */
.adv2-insights-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: .65rem;
}
.adv2-ic {
  display: flex;
  align-items: flex-start;
  gap: .6rem;
  padding: .8rem .9rem;
  border-radius: var(--rs);
  border: 1px solid var(--b);
  background: var(--s2);
  animation: fadeUp .35s ease both;
}
.adv2-ic-risk    { border-color: rgba(255,92,122,.25);   background: rgba(255,92,122,.05); }
.adv2-ic-opp     { border-color: rgba(0,229,160,.2);     background: rgba(0,229,160,.04); }
.adv2-ic-info    { border-color: rgba(77,171,247,.2);    background: rgba(77,171,247,.04); }
.adv2-ic-neutral { border-color: var(--b); }
.adv2-ic-icon    { font-size: 1.1rem; flex-shrink: 0; line-height: 1.5; }
.adv2-ic-text    { font-size: 12.5px; color: var(--t1); line-height: 1.55; }
.adv2-ic-text ul { padding-left: 1.1rem; margin: .2rem 0; }
.adv2-ic-text li { margin-bottom: .15rem; }
.adv2-ic-text p  { margin: 0; }

/* Loading pulse */
.adv2-loading { display: flex; align-items: center; gap: .5rem; font-size: 12.5px; color: var(--t3); }
.adv2-pulse {
  width: 8px; height: 8px; border-radius: 50%; background: var(--purple);
  animation: adv2Pulse 1.1s ease-in-out infinite;
  flex-shrink: 0;
}
@keyframes adv2Pulse {
  0%, 100% { opacity: .25; transform: scale(.8); }
  50%       { opacity: 1;   transform: scale(1.2); }
}

/* ── Chat card ── */
.adv2-chat-card { display: flex; flex-direction: column; gap: .75rem; padding: 18px; }

/* Quick chips */
.adv2-chips { display: flex; flex-wrap: wrap; gap: .4rem; }
.adv2-chip {
  background: var(--s3);
  border: 1px solid var(--b2);
  border-radius: 999px;
  color: var(--t2);
  font-size: 11.5px;
  padding: .3rem .75rem;
  cursor: pointer;
  transition: border-color var(--ease), color var(--ease), background var(--ease);
  white-space: nowrap;
}
.adv2-chip:hover { border-color: var(--purple); color: var(--purple); background: var(--p10); }

/* Chat history */
.adv2-chat {
  background: var(--s2);
  border: 1px solid var(--b);
  border-radius: var(--r);
  padding: 1rem;
  min-height: 180px;
  max-height: 400px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: .75rem;
  scroll-behavior: smooth;
}

/* Welcome bubble */
.adv2-welcome { display: flex; align-items: flex-start; gap: .65rem; }
.adv2-welcome-avatar { font-size: 1.2rem; flex-shrink: 0; line-height: 1.5; }
.adv2-welcome-bubble {
  background: var(--s3);
  border: 1px solid var(--b2);
  border-radius: 10px 10px 10px 3px;
  padding: .65rem .9rem;
  font-size: 12.5px;
  color: var(--t2);
  line-height: 1.6;
}

/* Chat bubbles */
.adv2-msg {
  max-width: 86%;
  font-size: 13px;
  line-height: 1.6;
  animation: fadeUp .2s ease both;
}
.adv2-msg-user {
  align-self: flex-end;
  background: var(--p10);
  border: 1px solid rgba(167,139,250,.25);
  border-radius: 10px 10px 3px 10px;
  padding: .6rem .9rem;
  color: var(--t1);
}
.adv2-msg-assistant {
  align-self: flex-start;
  background: var(--s3);
  border: 1px solid var(--b2);
  border-radius: 3px 10px 10px 10px;
  padding: .7rem .9rem;
  color: var(--t1);
}
.adv2-msg-assistant[data-tone="warn"] {
  border-color: rgba(255,201,71,.3);
  background: rgba(255,201,71,.05);
}
.adv2-msg-assistant[data-tone="good"] {
  border-color: rgba(0,229,160,.2);
  background: rgba(0,229,160,.04);
}
.adv2-msg p  { margin: 0 0 .35rem; }
.adv2-msg p:last-child { margin-bottom: 0; }
.adv2-msg ul { padding-left: 1.2rem; margin: .25rem 0; }
.adv2-msg li { margin-bottom: .15rem; }

/* Headings inside assistant messages */
.adv2-msg .adv2-h2 {
  font-size: 13px; font-weight: 700; color: var(--t1);
  margin: .65rem 0 .25rem; padding-bottom: .2rem;
  border-bottom: 1px solid var(--bdr);
}
.adv2-msg .adv2-h3 {
  font-size: 12px; font-weight: 700; color: var(--t2);
  margin: .5rem 0 .15rem;
}

/* Tables inside assistant messages */
.adv2-table-wrap { overflow-x: auto; margin: .4rem 0; border-radius: var(--rs); }
.adv2-table {
  border-collapse: collapse; font-size: 11.5px;
  width: 100%; min-width: 220px;
}
.adv2-table th {
  padding: .3rem .55rem; text-align: left; font-weight: 600;
  font-size: 10.5px; text-transform: uppercase; letter-spacing: .3px;
  color: var(--t3); background: var(--s2);
  border-bottom: 1px solid var(--bdr);
}
.adv2-table td {
  padding: .28rem .55rem;
  border-bottom: 1px solid var(--bdr);
}
.adv2-table tr:last-child td { border-bottom: none; }
.adv2-table td:not(:first-child) { text-align: right; }

.adv2-followup {
  margin-top: .55rem;
  padding: .4rem .7rem;
  background: var(--p10);
  border: 1px solid rgba(167,139,250,.22);
  border-radius: var(--rs);
  font-size: 11.5px;
  color: var(--purple);
}

/* Typing dots */
.adv2-typing { display: flex; align-items: center; gap: .45rem; }
.adv2-dots   { display: flex; gap: 4px; align-items: center; }
.adv2-dots span {
  width: 6px; height: 6px; border-radius: 50%; background: var(--purple);
  animation: adv2Bounce 1s infinite ease-in-out;
}
.adv2-dots span:nth-child(1) { animation-delay: 0s;   }
.adv2-dots span:nth-child(2) { animation-delay: .17s; }
.adv2-dots span:nth-child(3) { animation-delay: .34s; }
@keyframes adv2Bounce {
  0%, 60%, 100% { transform: translateY(0);    opacity: .35; }
  30%            { transform: translateY(-5px); opacity: 1;   }
}

/* Error banner */
.adv2-err-banner {
  padding: .55rem .85rem;
  background: var(--r10);
  border: 1px solid rgba(255,92,122,.25);
  border-radius: var(--rs);
  font-size: 12.5px;
  color: var(--red);
}

/* Input bar */
.adv2-input-bar {
  display: flex;
  gap: .5rem;
  align-items: flex-end;
  background: var(--s2);
  border: 1px solid var(--b2);
  border-radius: var(--r);
  padding: .5rem .5rem .5rem .85rem;
  transition: border-color var(--ease);
}
.adv2-input-bar:focus-within { border-color: var(--purple); }
.adv2-textarea {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--t1);
  font-family: var(--font);
  font-size: 13.5px;
  resize: none;
  min-height: 22px;
  max-height: 100px;
  line-height: 1.5;
  overflow-y: auto;
}
.adv2-textarea::placeholder { color: var(--t3); }
.adv2-send { flex-shrink: 0; }

/* ── Responsive ── */
@media (max-width: 900px) {
  .adv2-insights-grid { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .adv2-chip { font-size: 11px; padding: .28rem .65rem; }
  .adv2-chat { max-height: 320px; }
  .adv2-msg  { max-width: 92%; }
}

.inv-card:hover {
  border-color: var(--b2);
  box-shadow: var(--shadow-sm)
}

.inv-card-head {
  padding: 14px 16px 12px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  border-bottom: 1px solid var(--b)
}

.inv-card-name {
  font-weight: 600;
  font-size: 13.5px;
  color: var(--t1);
  line-height: 1.3
}

.inv-card-ticker {
  font-size: 11px;
  color: var(--t3);
  font-family: var(--font-m);
  margin-top: 2px
}

.inv-card-body {
  padding: 14px 16px
}

.inv-card-val {
  font-family: var(--font-d);
  font-weight: 700;
  font-size: 20px;
  color: var(--t1);
  line-height: 1;
  margin-bottom: 3px
}

.inv-card-pnl {
  font-size: 12.5px;
  font-weight: 500;
  margin-bottom: 10px
}

.inv-card-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--b)
}

.ics-label {
  font-size: 10.5px;
  color: var(--t3);
  margin-bottom: 2px
}

.ics-val {
  font-family: var(--font-m);
  font-size: 12px;
  color: var(--t1)
}

.inv-card-actions {
  display: flex;
  gap: 6px;
  margin-top: 12px;
  justify-content: flex-end
}

/* ── VIEW TOGGLE ───────────────────────────────────── */
.view-toggle {
  display: flex;
  gap: 2px;
  background: var(--s2);
  border: 1px solid var(--b2);
  border-radius: var(--rs);
  padding: 2px
}

.vt-btn {
  width: 30px;
  height: 28px;
  border: none;
  border-radius: 6px;
  background: transparent;
  cursor: pointer;
  color: var(--t3);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--ease)
}

.vt-btn.active {
  background: var(--s1);
  color: var(--t1);
  box-shadow: var(--shadow-sm)
}

.vt-btn svg {
  width: 13px;
  height: 13px;
  stroke-width: 1.8
}

/* ── SEARCH WRAPPER ────────────────────────────────── */
.search-wrap {
  position: relative;
  display: inline-flex;
  align-items: center
}

.search-ico {
  position: absolute;
  left: 9px;
  color: var(--t3);
  pointer-events: none;
  display: flex;
  align-items: center;
  line-height: 0
}

.search-wrap .inp {
  padding-left: 30px
}

/* ── TOPBAR THEME BTN ──────────────────────────────── */
.theme-iBtn {
  width: 34px;
  height: 34px;
  border-radius: var(--rs);
  border: 1px solid var(--b2);
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--t2);
  transition: background var(--ease), color var(--ease)
}

.theme-iBtn:hover {
  background: var(--s2);
  color: var(--t1)
}

.theme-iBtn svg {
  width: 15px;
  height: 15px;
  stroke-width: 1.8
}

/* ── LIFESTYLE TRACKER ─────────────────────────────── */
.ls-good-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px
}

.ls-good-card {
  background: var(--s1);
  border: 1px solid var(--b);
  border-radius: var(--rl);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: border-color .15s, transform .15s;
  position: relative;
  overflow: hidden
}

.ls-good-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--red), var(--gold));
  opacity: .65
}

.ls-good-card:hover {
  border-color: rgba(255, 107, 107, .4);
  transform: translateY(-2px)
}

.ls-good-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: rgba(255, 107, 107, .1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  line-height: 1;
  flex-shrink: 0
}

.ls-upgrade-note {
  background: rgba(167, 139, 250, .07);
  border: 1px solid rgba(167, 139, 250, .2);
  border-radius: var(--rs);
  padding: 7px 10px;
  font-size: 12px;
  color: var(--t2);
  line-height: 1.5
}

.ls-w-ok {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 20px;
  background: rgba(0, 229, 160, .12);
  color: var(--accent);
  border: 1px solid rgba(0, 229, 160, .3)
}

.ls-w-soon {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 20px;
  background: rgba(255, 201, 71, .12);
  color: var(--gold);
  border: 1px solid rgba(255, 201, 71, .3)
}

.ls-w-exp {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 20px;
  background: rgba(255, 107, 107, .12);
  color: var(--red);
  border: 1px solid rgba(255, 107, 107, .3)
}

.ls-w-none {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 20px;
  background: var(--s2);
  color: var(--t3);
  border: 1px solid var(--b2)
}

.ls-event-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: var(--s1);
  border: 1px solid var(--b);
  border-radius: var(--r);
  padding: 12px 14px;
  transition: border-color .15s, background .15s
}

.ls-event-row:hover {
  border-color: var(--b3);
  background: var(--s2)
}

.ls-ev-today {
  border-color: rgba(0, 229, 160, .35) !important;
  background: rgba(0, 229, 160, .04) !important
}

.ls-ev-past {
  opacity: .7
}

.ls-event-icon {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  background: var(--s2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0
}

.ls-days-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 7px;
  border-radius: 20px;
  white-space: nowrap;
  font-family: var(--font-m)
}

.ls-day-today {
  background: rgba(0, 229, 160, .15);
  color: var(--accent);
  border: 1px solid rgba(0, 229, 160, .35)
}

.ls-day-soon {
  background: rgba(255, 201, 71, .12);
  color: var(--gold);
  border: 1px solid rgba(255, 201, 71, .3)
}

.ls-day-up {
  background: rgba(77, 171, 247, .12);
  color: var(--blue);
  border: 1px solid rgba(77, 171, 247, .3)
}

.ls-day-past {
  background: rgba(255, 107, 107, .1);
  color: var(--red);
  border: 1px solid rgba(255, 107, 107, .25);
  opacity: .8
}

@media(max-width:700px) {
  .ls-good-grid {
    grid-template-columns: 1fr
  }
}