*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary: #818cf8;
  --primary-hover: #6366f1;
  --primary-light: rgba(99,102,241,0.15);
  --income: #34d399;
  --income-light: rgba(52,211,153,0.12);
  --expense: #f87171;
  --expense-light: rgba(248,113,113,0.12);
  --net: #a5b4fc;
  --net-light: rgba(165,180,252,0.12);
  --text: #f1f5f9;
  --text-secondary: #cbd5e1;
  --muted: #64748b;
  --border: #1e293b;
  --bg: #0a0f1e;
  --card: #111827;
  --card-hover: #1a2332;
  --sidebar-bg: #0d1117;
  --topbar-bg: #111827;
  --sidebar-w: 228px;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(0,0,0,0.4), 0 1px 2px rgba(0,0,0,0.3);
}

html { font-size: 15px; }

body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  display: flex;
  min-height: 100vh;
  line-height: 1.5;
}

/* ── Sidebar ── */
.sidebar {
  width: var(--sidebar-w);
  background: var(--sidebar-bg);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 100;
}

.sidebar-header {
  padding: 22px 18px 18px;
  border-bottom: 1px solid var(--border);
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo h1 {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
}

.logo .year {
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.04em;
}

.sidebar-nav {
  padding: 10px 10px;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 2px;
}

.nav-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.nav-bottom {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-bottom: 8px;
  border-top: 1px solid var(--border);
  padding-top: 8px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 14px;
  background: none;
  border: none;
  border-radius: 8px;
  color: var(--muted);
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  transition: background 0.15s, color 0.15s;
}

.nav-item svg { flex-shrink: 0; }
.nav-item:hover { background: rgba(255,255,255,0.05); color: var(--text-secondary); }
.nav-item.active {
  background: var(--primary-light);
  color: var(--primary);
  font-weight: 600;
}

/* ── Top Bar ── */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  height: 60px;
  background: var(--topbar-bg);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 50;
}

.topbar-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
}

.topbar-month {
  display: flex;
  align-items: center;
  gap: 10px;
}

.topbar-month label {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  white-space: nowrap;
}

.topbar-month select {
  padding: 7px 32px 7px 12px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: #1a2332;
  color: var(--text);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  outline: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%2364748b' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  transition: border-color 0.15s;
}

.topbar-month select:focus { border-color: var(--primary); }
.topbar-month select option { background: #1a2332; color: var(--text); }

/* ── Main ── */
.main {
  margin-left: var(--sidebar-w);
  flex: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.tab-content { display: none; padding: 24px 28px; }
.tab-content.active { display: block; }

/* ── Cards ── */
.card {
  background: var(--card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

/* ── Summary Cards ── */
.summary-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 20px;
}

.summary-cards .card {
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.card-icon {
  width: 50px; height: 50px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.income-icon { background: var(--income-light); color: var(--income); }
.expense-icon { background: var(--expense-light); color: var(--expense); }
.net-icon { background: var(--net-light); color: var(--net); }

.card-info { display: flex; flex-direction: column; min-width: 0; }

.card-label {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 4px;
  font-weight: 500;
}

.card-value {
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-value.positive { color: var(--income); }
.card-value.negative { color: var(--expense); }

/* ── Charts ── */
.charts-row {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 16px;
  margin-bottom: 20px;
}

.chart-box {
  background: var(--card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  padding: 20px;
}

.chart-box h3 {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

.donut-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  max-height: 220px;
}

/* ── Category Progress ── */
.progress-card {
  padding: 20px;
}

.progress-card h3 {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 18px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

.progress-row {
  display: grid;
  grid-template-columns: 180px 1fr 130px;
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
}

.progress-row:last-child { margin-bottom: 0; }

.progress-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
}

.dot {
  width: 9px; height: 9px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}

.progress-bar-wrap {
  height: 6px;
  background: var(--border);
  border-radius: 4px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  border-radius: 4px;
  transition: width 0.4s ease;
  min-width: 2px;
}

.progress-amount {
  font-size: 13px;
  font-weight: 600;
  text-align: right;
  color: var(--text);
}

/* ── Income Tab ── */
.income-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 16px;
}

.income-source-card { padding: 20px; }

.income-source-card h3 {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text);
}

.payday-row { display: flex; gap: 12px; }
.payday-input { flex: 1; }

.payday-input label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.input-peso {
  display: flex;
  align-items: center;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  background: #1a2332;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.input-peso:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-light);
}

.input-peso span {
  padding: 0 8px 0 10px;
  font-size: 13px;
  color: var(--muted);
  font-weight: 600;
  user-select: none;
}

.input-peso input {
  flex: 1;
  border: none;
  padding: 9px 10px 9px 0;
  font-size: 14px;
  color: var(--text);
  outline: none;
  background: transparent;
  min-width: 0;
}

input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button { -webkit-appearance: none; }

.additional-funds {
  padding: 20px;
  margin-bottom: 16px;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.section-header h3 {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
}

.btn-outline {
  background: var(--primary-light);
  color: var(--primary);
  border: 1px solid rgba(129,140,248,0.3);
  padding: 7px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}

.btn-outline:hover { background: rgba(99,102,241,0.25); }

.fund-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.fund-item:last-child { border-bottom: none; }

.fund-name { flex: 1; font-size: 14px; font-weight: 500; color: var(--text-secondary); }
.fund-amount { font-size: 14px; font-weight: 600; color: var(--income); }

.btn-icon {
  background: none;
  border: none;
  color: var(--muted);
  font-size: 17px;
  cursor: pointer;
  padding: 3px 7px;
  border-radius: 6px;
  line-height: 1;
  transition: background 0.1s, color 0.1s;
}

.btn-icon:hover { background: var(--expense-light); color: var(--expense); }

.income-footer {
  background: var(--card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 20px;
  box-shadow: var(--shadow);
}

.income-total-label {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.income-total-label span {
  font-size: 12px;
  color: var(--muted);
  font-weight: 500;
}

.income-total-label strong {
  font-size: 22px;
  font-weight: 700;
  color: var(--income);
  margin-top: 2px;
}

/* ── Expense Categories ── */
.expense-categories { display: flex; flex-direction: column; gap: 14px; }

.expenses-topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.expenses-grand-total {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  flex-shrink: 0;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 18px;
  min-width: 180px;
}

.expenses-grand-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.expenses-grand-amount {
  font-size: 20px;
  font-weight: 700;
  color: var(--expense);
  margin-top: 2px;
}

.cat-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.cat-tab {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.1s;
  text-align: left;
  min-width: 0;
}

.cat-tab:hover { background: var(--card-hover); border-color: var(--cat-color); }

.cat-tab.active {
  background: var(--card-hover);
  border-color: var(--cat-color);
  box-shadow: 0 0 0 1px var(--cat-color);
}

.cat-tab-dot {
  width: 9px; height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
}

.cat-tab-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  white-space: nowrap;
}

.cat-tab.active .cat-tab-label { color: var(--text); }

.cat-tab-total {
  font-size: 12px;
  color: var(--muted);
  font-weight: 500;
  white-space: nowrap;
}

.category-section {
  background: var(--card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.category-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
}

.category-header-left { display: flex; flex-direction: column; }

.category-title { font-size: 14px; font-weight: 700; color: var(--text); }
.category-total { font-size: 12px; color: var(--muted); margin-top: 2px; }

.btn-add-tx {
  background: var(--primary-light);
  color: var(--primary);
  border: 1px solid rgba(129,140,248,0.3);
  padding: 7px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}

.btn-add-tx:hover { background: rgba(99,102,241,0.25); }

.tx-list { padding: 0 20px; }

.empty-msg {
  font-size: 13px;
  color: var(--muted);
  padding: 14px 0;
  font-style: italic;
}

.tx-item {
  display: grid;
  grid-template-columns: 100px 1fr 130px 34px;
  align-items: center;
  gap: 8px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}

.tx-item:last-child { border-bottom: none; }
.tx-date { color: var(--muted); font-size: 12px; white-space: nowrap; }
.tx-particular { font-weight: 500; color: var(--text-secondary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tx-amount { font-weight: 700; text-align: right; color: var(--text); }

/* ── Annual Summary Charts ── */
.summary-charts-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 20px;
}

/* ── Annual Summary ── */
.table-wrap {
  overflow-x: auto;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.summary-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--card);
  white-space: nowrap;
}

.summary-table th,
.summary-table td {
  padding: 11px 14px;
  text-align: right;
  font-size: 13px;
  border-bottom: 1px solid var(--border);
}

.summary-table th:first-child,
.summary-table td:first-child { text-align: left; min-width: 160px; }

.summary-table thead th {
  background: #0d1117;
  font-weight: 600;
  font-size: 11px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.summary-table tr:last-child td { border-bottom: none; }
.summary-table tbody tr:hover td { background: rgba(255,255,255,0.02); }

.row-income td { color: var(--income); font-weight: 700; background: rgba(52,211,153,0.05); }
.row-total td { font-weight: 700; background: rgba(248,113,113,0.05); }
.row-net td { font-weight: 700; background: rgba(129,140,248,0.07); }

.positive { color: var(--income); }
.negative { color: var(--expense); }

/* ── Buttons ── */
.btn-primary {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 10px 22px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, transform 0.1s;
  white-space: nowrap;
}

.btn-primary:hover { background: var(--primary-hover); }
.btn-primary:active { transform: scale(0.98); }

.btn-ghost {
  background: none;
  border: 1.5px solid var(--border);
  padding: 10px 18px;
  border-radius: 8px;
  font-size: 14px;
  cursor: pointer;
  color: var(--muted);
  transition: background 0.15s, color 0.15s;
}

.btn-ghost:hover { background: rgba(255,255,255,0.05); color: var(--text-secondary); }

/* ── Modal ── */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  z-index: 200;
  align-items: center;
  justify-content: center;
  padding: 20px;
  backdrop-filter: blur(4px);
}

.modal-overlay.open { display: flex; }

.modal {
  background: #1a2332;
  border: 1px solid var(--border);
  border-radius: 16px;
  width: 100%;
  max-width: 400px;
  box-shadow: 0 24px 64px rgba(0,0,0,0.5);
  animation: modal-in 0.18s ease;
}

@keyframes modal-in {
  from { transform: translateY(-12px) scale(0.97); opacity: 0; }
  to   { transform: translateY(0) scale(1); opacity: 1; }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 22px 16px;
  border-bottom: 1px solid var(--border);
}

.modal-header h3 { font-size: 15px; font-weight: 700; color: var(--text); }

.modal-close {
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
  color: var(--muted);
  padding: 4px 8px;
  border-radius: 6px;
  line-height: 1;
  transition: background 0.1s, color 0.1s;
}

.modal-close:hover { background: rgba(255,255,255,0.07); color: var(--text); }

.modal-body { padding: 18px 22px; }

.form-group { margin-bottom: 14px; }
.form-group:last-child { margin-bottom: 0; }

.form-group label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.form-group input[type="text"],
.form-group input[type="date"] {
  width: 100%;
  padding: 9px 12px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
  color: var(--text);
  outline: none;
  background: #0f172a;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.form-group input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-light);
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 14px 22px 20px;
}

/* ── Toast ── */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #1e293b;
  border: 1px solid var(--border);
  color: var(--text);
  padding: 12px 20px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 500;
  z-index: 300;
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity 0.2s, transform 0.2s;
  box-shadow: 0 8px 24px rgba(0,0,0,0.4);
}

.toast.show { opacity: 1; pointer-events: auto; transform: translateY(0); }

/* ── Admin Page ── */
.admin-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0;
}

.admin-tab {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 10px 18px;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  color: var(--muted);
  font-size: 13.5px;
  font-weight: 500;
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s;
}

.admin-tab:hover { color: var(--text-secondary); }
.admin-tab.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }
.admin-tab svg { opacity: 0.7; }
.admin-tab.active svg { opacity: 1; }

.admin-panel { display: none; }
.admin-panel.active { display: block; }

.admin-section-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}

.admin-section-header h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
}

.admin-badge {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--border);
  padding: 2px 10px;
  border-radius: 20px;
}

/* Changelog */
.changelog-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
}

.changelog-list::before {
  content: '';
  position: absolute;
  left: 16px;
  top: 0; bottom: 0;
  width: 1px;
  background: var(--border);
}

.changelog-item {
  position: relative;
  padding: 0 0 28px 48px;
}

.changelog-item::before {
  content: '';
  position: absolute;
  left: 10px;
  top: 6px;
  width: 13px; height: 13px;
  border-radius: 50%;
  background: var(--primary);
  border: 2px solid var(--bg);
  z-index: 1;
}

.changelog-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}

.changelog-version {
  font-size: 13px;
  font-weight: 700;
  color: var(--primary);
  font-family: 'Courier New', monospace;
}

.changelog-date {
  font-size: 12px;
  color: var(--muted);
}

.changelog-tag {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.tag-new { background: rgba(52,211,153,0.15); color: #34d399; }
.tag-improvement { background: rgba(129,140,248,0.15); color: #818cf8; }
.tag-release { background: rgba(251,191,36,0.15); color: #fbbf24; }
.tag-fix { background: rgba(248,113,113,0.15); color: #f87171; }

.changelog-item h4 {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

.changelog-item ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.changelog-item ul li {
  font-size: 13px;
  color: var(--text-secondary);
  padding-left: 14px;
  position: relative;
  line-height: 1.5;
}

.changelog-item ul li::before {
  content: '–';
  position: absolute;
  left: 0;
  color: var(--muted);
}

/* Documentation */
.doc-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.doc-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}

.doc-card-icon {
  width: 40px; height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}

.doc-card h4 {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 10px;
}

.doc-card p {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: 10px;
}

.doc-card p:last-child { margin-bottom: 0; }

.doc-card strong { color: var(--text); font-weight: 600; }
.doc-card em { color: var(--muted); font-style: normal; }

.doc-card code {
  font-family: 'Courier New', monospace;
  font-size: 12px;
  background: rgba(255,255,255,0.07);
  border: 1px solid var(--border);
  padding: 1px 6px;
  border-radius: 4px;
  color: var(--primary);
}

.doc-card ul {
  list-style: none;
  margin: 8px 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.doc-card ul li {
  font-size: 13px;
  color: var(--text-secondary);
  padding-left: 14px;
  position: relative;
  line-height: 1.5;
}

.doc-card ul li::before {
  content: '·';
  position: absolute;
  left: 3px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.2;
}

/* Workflow */
.workflow-intro {
  background: var(--primary-light);
  border: 1px solid rgba(129,140,248,0.2);
  border-radius: var(--radius);
  padding: 14px 18px;
  margin-bottom: 24px;
}

.workflow-intro p {
  font-size: 13.5px;
  color: var(--text-secondary);
  line-height: 1.6;
}

.workflow-steps {
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
}

.workflow-steps::before {
  content: '';
  position: absolute;
  left: 19px;
  top: 40px;
  bottom: 40px;
  width: 1px;
  background: linear-gradient(to bottom, var(--primary), rgba(129,140,248,0.2));
}

.workflow-step {
  display: flex;
  gap: 20px;
  padding-bottom: 28px;
}

.workflow-step:last-child { padding-bottom: 0; }

.step-number {
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  z-index: 1;
  box-shadow: 0 0 0 4px var(--bg);
}

.step-content { flex: 1; padding-top: 6px; }

.step-content h4 {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

.step-content p {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: 8px;
}

.step-content ul {
  list-style: none;
  margin: 8px 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.step-content ul li {
  font-size: 13px;
  color: var(--text-secondary);
  padding-left: 14px;
  position: relative;
  line-height: 1.5;
}

.step-content ul li::before {
  content: '–';
  position: absolute;
  left: 0;
  color: var(--muted);
}

.step-content strong { color: var(--text); font-weight: 600; }
.step-content em { color: var(--primary); font-style: normal; }

.step-tip {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 12px;
  background: rgba(251,191,36,0.08);
  border: 1px solid rgba(251,191,36,0.2);
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 12.5px;
  color: #fbbf24;
  line-height: 1.5;
}

.step-tip svg { flex-shrink: 0; margin-top: 1px; }

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #1e293b; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #334155; }

/* ── Responsive ── */
@media (max-width: 1100px) {
  .charts-row { grid-template-columns: 1fr 1.5fr; }
}

@media (max-width: 900px) {
  .summary-cards { grid-template-columns: 1fr 1fr; }
  .income-grid { grid-template-columns: 1fr; }
  .charts-row { grid-template-columns: 1fr; }
  .progress-row { grid-template-columns: 140px 1fr 110px; }
}
