
/* Finanças Mestre · ECS — mesma identidade do Estoque Pro */
:root {
  --bg: #f4f6f9;
  --bg-card: #ffffff;
  --border: #e5e9f0;
  --border-gold: rgba(184, 148, 42, 0.4);
  --gold: #b8942a;
  --gold-light: #c9a227;
  --gold-dark: #8a7020;
  --text: #1a2332;
  --text-muted: #6b7280;
  --sidebar-bg: #1a2332;
  --green: #16a34a;
  --green-bg: #dcfce7;
  --orange: #ea580c;
  --orange-bg: #ffedd5;
  --red: #dc2626;
  --red-bg: #fee2e2;
  --shadow: 0 4px 20px rgba(26, 35, 50, 0.06);
  --shadow-gold: 0 4px 20px rgba(184, 148, 42, 0.12);
  --radius: 12px;
  --sidebar: 260px;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
}
.hidden { display: none !important; }

/* Login */
.login-screen {
  min-height: 100vh; display: grid; place-items: center;
  background: linear-gradient(135deg, #1a2332 0%, #2c3e50 50%, #1a2332 100%);
  padding: 20px;
}
.login-card {
  width: 100%; max-width: 380px; background: #fff; border-radius: 16px;
  padding: 28px 24px; box-shadow: var(--shadow-gold);
  border: 1px solid var(--border-gold);
}
.login-logo { display: block; width: 128px; height: 128px; object-fit: contain; margin: 0 auto 16px; filter: drop-shadow(0 4px 12px rgba(201,162,39,.35)); }
.login-card h1 {
  color: var(--gold-dark); font-size: 20px; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase; text-align: center; margin: 0 0 4px;
}
.login-sub { text-align: center; font-size: 12px; color: var(--text-muted); margin: 0 0 18px; }
.login-card label { display: block; font-size: 11px; font-weight: 600; color: var(--text-muted); margin: 10px 0 4px; }
.login-card input {
  width: 100%; padding: 11px 12px; border: 1px solid var(--border); border-radius: 10px; font: inherit;
}
.login-card input:focus {
  outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(184,148,42,.15);
}
.btn-block { width: 100%; margin-top: 16px; }
.login-hint { font-size: 11px; color: var(--text-muted); text-align: center; margin-top: 12px; }
.login-footer-brand {
  margin-top: 18px; padding-top: 12px; border-top: 1px solid var(--border);
  font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--gold-dark); text-align: center; font-weight: 700;
}

/* App shell */
#app { display: flex; min-height: 100vh; }
.sidebar {
  width: var(--sidebar); background: var(--sidebar-bg); color: #e8eef5;
  position: fixed; inset: 0 auto 0 0; z-index: 40;
  display: flex; flex-direction: column; padding: 16px 12px;
  transform: translateX(0); transition: transform .2s;
  height: 100%; height: 100dvh; max-height: 100dvh;
  overflow: hidden;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}
.sidebar > nav {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-y;
  padding-bottom: 8px;
}
.sidebar-brand { flex-shrink: 0; }
.sidebar-foot {
  flex-shrink: 0;
  margin-top: 0;
  padding-top: 12px;
  border-top: 1px solid rgba(255,255,255,.08);
  background: var(--sidebar-bg);
}
body.menu-open {
  overflow: hidden !important;
  position: fixed;
  width: 100%;
  height: 100%;
}
body.menu-open .main {
  pointer-events: none;
  touch-action: none;
}
.sidebar-brand {
  display: flex; gap: 10px; align-items: center; padding: 6px 8px 16px;
  border-bottom: 1px solid rgba(184,148,42,.25); margin-bottom: 8px;
}
.sidebar-brand img { width: 48px; height: 48px; object-fit: contain; border-radius: 10px; background: rgba(255,255,255,.06); padding: 2px; }
.brand-text {
  font-weight: 700; font-size: 12px; letter-spacing: 0.06em;
  color: var(--gold-light); text-transform: uppercase;
}
.sidebar-brand small { display: block; font-size: 10px; opacity: .65; }
.nav-section {
  padding: 12px 12px 4px; font-size: 9px; text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--gold); font-weight: 700; opacity: .9;
}
.nav-item {
  display: flex; align-items: center; gap: 8px;
  color: #c5d0dc; text-decoration: none; padding: 10px 12px;
  border-radius: 8px; font-size: 13px; border-left: 3px solid transparent;
}
.nav-item:hover { background: rgba(255,255,255,.06); color: #fff; }
.nav-item.active {
  background: rgba(184,148,42,.15); color: var(--gold-light);
  border-left-color: var(--gold); font-weight: 600;
}
.nav-icon { width: 1.25em; text-align: center; }
.user-label { font-size: 11px; color: #94a3b8; margin-bottom: 8px; padding: 0 4px; }
.btn-ghost {
  width: 100%; background: transparent; border: 1px solid rgba(184,148,42,.35);
  color: var(--gold-light); border-radius: 8px; padding: 8px; cursor: pointer; font: inherit; font-size: 12px;
}
.main { margin-left: var(--sidebar); flex: 1; min-width: 0; }
.topbar {
  display: flex; align-items: center; gap: 12px; padding: 12px 18px;
  background: rgba(255,255,255,.9); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 20;
}
.topbar h1 { margin: 0; font-size: 17px; flex: 1; font-weight: 700; }
.clock { font-size: 11px; color: var(--text-muted); }
.btn-menu {
  display: none; background: rgba(184,148,42,.1); border: 1px solid var(--border-gold);
  color: var(--gold-dark); width: 40px; height: 40px; border-radius: 10px; font-size: 18px; cursor: pointer;
}
.content { padding: 16px 18px 48px; }
.cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 14px; }
.card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 14px 16px; box-shadow: var(--shadow);
}
.card-label { font-size: 11px; color: var(--text-muted); margin-bottom: 4px; text-transform: uppercase; letter-spacing: .04em; }
.card-value { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; }
.card-value.pos { color: var(--green); }
.card-value.neg { color: var(--red); }
.panel {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); overflow: hidden; margin-bottom: 14px;
}
.panel-header {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 12px 14px; border-bottom: 1px solid var(--border);
  background: linear-gradient(90deg, rgba(184,148,42,.06), transparent);
}
.panel-header h3 { margin: 0; font-size: 14px; font-weight: 700; }
.panel-body { padding: 14px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-group { display: flex; flex-direction: column; gap: 4px; }
.form-group.full { grid-column: 1 / -1; }
.form-group label { font-size: 11px; color: var(--text-muted); font-weight: 600; }
input, select, textarea {
  border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px;
  font: inherit; background: #fff; color: var(--text);
}
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(184,148,42,.12);
}
.btn {
  border: 0; border-radius: 10px; padding: 10px 14px; font: inherit; font-weight: 600; cursor: pointer;
}
.btn-primary {
  background: linear-gradient(135deg, var(--gold-dark), var(--gold-light)); color: #fff;
  box-shadow: var(--shadow-gold);
}
.btn-outline { background: #fff; border: 1px solid var(--border); color: var(--text); }
.btn-danger { background: var(--red); color: #fff; }
.btn-sm { padding: 6px 10px; font-size: 12px; }
.table-wrap { overflow: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { padding: 10px 8px; border-bottom: 1px solid var(--border); text-align: left; }
th {
  font-size: 10px; text-transform: uppercase; letter-spacing: .05em; color: var(--text-muted);
}
.badge {
  display: inline-block; padding: 3px 8px; border-radius: 999px; font-size: 11px; font-weight: 700;
}
.badge-pago { background: var(--green-bg); color: #166534; }
.badge-pend { background: var(--orange-bg); color: #9a3412; }
.badge-rec { background: var(--green-bg); color: #166534; }
.badge-fix { background: var(--orange-bg); color: #9a3412; }
.badge-var { background: var(--red-bg); color: #991b1b; }
.section-title {
  margin: 16px 0 8px; padding: 8px 10px; border-radius: 10px; font-size: 12px; font-weight: 800;
}
.section-rec { background: var(--green-bg); color: #166534; }
.section-fix { background: var(--orange-bg); color: #9a3412; }
.section-var { background: var(--red-bg); color: #991b1b; }
.toolbar { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.toast {
  position: fixed; bottom: 18px; left: 50%; transform: translateX(-50%);
  background: #1a2332; color: #fff; padding: 12px 16px; border-radius: 12px; z-index: 100;
  box-shadow: var(--shadow); max-width: 90vw; font-size: 13px;
}
.toast.ok { background: #065f46; }
.toast.err { background: #991b1b; }
.month-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.month-card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px;
  padding: 12px; cursor: pointer; transition: .15s;
}
.month-card:hover { border-color: var(--gold); box-shadow: var(--shadow-gold); }
.month-card strong { display: block; margin-bottom: 6px; }
.month-card span { font-size: 12px; color: var(--text-muted); display: block; }
.empty { text-align: center; color: var(--text-muted); padding: 24px; }
.plan-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.plan-card {
  border: 1px solid var(--border); border-radius: 14px; padding: 16px; background: #fff;
}
.plan-card.featured {
  border-color: var(--gold); box-shadow: var(--shadow-gold);
  background: linear-gradient(180deg, rgba(184,148,42,.08), #fff);
}
.plan-card h4 { margin: 0 0 6px; color: var(--gold-dark); }
.plan-card ul { margin: 10px 0; padding-left: 18px; font-size: 13px; color: var(--text-muted); }
.sidebar-backdrop {
  display: none; position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 30;
}
@media (max-width: 960px) {
  .cards { grid-template-columns: 1fr 1fr; }
  .form-grid, .plan-grid { grid-template-columns: 1fr; }
  .sidebar { transform: translateX(-105%); }
  .sidebar.open { transform: translateX(0); }
  .sidebar-backdrop.show { display: block; }
  .main { margin-left: 0; }
  .btn-menu { display: inline-grid; place-items: center; }
}
@media (max-width: 520px) {
  .cards { grid-template-columns: 1fr; }
}

/* Matriz categorias (planilha) */
.matriz-wrap { overflow-x: auto; }
table.matriz-cat { font-size: 12px; min-width: 900px; }
table.matriz-cat th { position: sticky; top: 0; background: #1a2332; color: #c9a227; z-index: 1; white-space: nowrap; }
table.matriz-cat td.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
table.matriz-cat td.zero { color: #94a3b8; }
table.matriz-cat .cat-name { font-weight: 600; white-space: nowrap; }
table.matriz-cat tr.sec td { background: #1a2332; color: #c9a227; font-weight: 700; letter-spacing: .04em; font-size: 11px; }
table.matriz-cat tr.row-rec { background: #f0fdf4; }
table.matriz-cat tr.row-desp { background: #fff7ed; }
table.matriz-cat tr.tot-row { background: #f1f5f9; font-weight: 700; }
table.matriz-cat tr.tot-row td { border-top: 2px solid #b8942a; }

.card-highlight { border-color: rgba(184,148,42,.45); box-shadow: var(--shadow-gold); }
.card-sub { font-size: 11px; color: var(--text-muted); margin-top: 4px; }

/* PWA install banner */
.install-banner {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 9999;
  padding: 12px 14px calc(12px + env(safe-area-inset-bottom));
  background: rgba(26, 35, 50, 0.97);
  color: #fff;
  box-shadow: 0 -8px 24px rgba(0,0,0,.2);
}
.install-banner.hidden { display: none !important; }
.install-banner-inner {
  max-width: 720px; margin: 0 auto;
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between;
}
.install-banner-text { display: flex; flex-direction: column; gap: 2px; font-size: 13px; }
.install-banner-text strong { color: #c9a227; font-size: 14px; }
.install-banner-text span { opacity: .85; font-size: 12px; }
.install-banner-actions { display: flex; gap: 8px; }
.install-banner .btn-outline { background: transparent; border: 1px solid rgba(255,255,255,.35); color: #fff; }

/* PWA install banner */
.pwa-install {
  position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 9999;
  background: #1a2332; color: #fff; border-radius: 14px;
  border: 1px solid rgba(184,148,42,.5);
  box-shadow: 0 8px 32px rgba(0,0,0,.35);
  padding: 12px 14px; max-width: 420px; margin: 0 auto;
}
.pwa-install-inner { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.pwa-install-text { flex: 1; min-width: 140px; }
.pwa-install-text strong { display: block; color: #c9a227; font-size: 14px; }
.pwa-install-text span { font-size: 12px; opacity: .85; }
.pwa-install-actions { display: flex; gap: 8px; }
.pwa-install-hint { margin: 8px 0 0; font-size: 11px; opacity: .9; line-height: 1.4; }

/* ===== Comercial EC$ 360 ===== */
.landing {
  min-height: 100vh; display: flex; flex-direction: column;
  background: radial-gradient(ellipse at top, #1a2332 0%, #0a0a0c 55%);
  color: #f5f5f5; padding: 24px 16px 40px;
}
.landing-hero { max-width: 480px; margin: 0 auto; text-align: center; }
.landing-hero .brand { color: #c9a227; letter-spacing: .12em; font-size: 12px; font-weight: 700; margin-bottom: 8px; }
.landing-hero h1 { font-size: 1.75rem; margin: 8px 0 12px; line-height: 1.25; }
.landing-hero p.lead { color: #a8a29a; font-size: 15px; line-height: 1.5; margin-bottom: 20px; }
.landing-benefits { text-align: left; max-width: 420px; margin: 0 auto 24px; }
.landing-benefits li { margin: 10px 0; font-size: 14px; color: #e7e5e4; list-style: none; padding-left: 28px; position: relative; }
.landing-benefits li::before { content: "✓"; position: absolute; left: 0; color: #c9a227; font-weight: 700; }
.plan-cards { display: grid; gap: 12px; max-width: 420px; margin: 0 auto 20px; }
.plan-card {
  background: #1a1a1a; border: 1px solid #333; border-radius: 14px; padding: 16px; text-align: left;
}
.plan-card.featured { border-color: #c9a227; box-shadow: 0 0 0 1px rgba(201,162,39,.35); }
.plan-card h3 { margin: 0 0 4px; color: #c9a227; font-size: 15px; }
.plan-card .price { font-size: 1.5rem; font-weight: 700; margin: 6px 0; }
.plan-card .price span { font-size: 13px; font-weight: 500; color: #a8a29a; }
.plan-card ul { margin: 8px 0 0; padding-left: 18px; color: #a8a29a; font-size: 13px; }
.trial-banner {
  background: linear-gradient(90deg, #1a2332, #2a2210);
  border: 1px solid rgba(201,162,39,.4);
  border-radius: 10px; padding: 10px 14px; margin: 12px 16px;
  font-size: 13px; color: #e8d48b; display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; align-items: center;
}
.trial-banner strong { color: #c9a227; }
.onboarding-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,.72); z-index: 10000;
  display: flex; align-items: center; justify-content: center; padding: 16px;
}
.onboarding-card {
  background: #12151c; border: 1px solid #333; border-radius: 16px;
  max-width: 420px; width: 100%; padding: 22px; color: #f5f5f5;
  max-height: 90vh; overflow: auto;
}
.onboarding-card h2 { margin: 0 0 8px; font-size: 1.25rem; }
.onboarding-card .step { color: #c9a227; font-size: 12px; letter-spacing: .08em; font-weight: 700; margin-bottom: 6px; }
.onboarding-card label { display: block; font-size: 12px; color: #a8a29a; margin: 12px 0 4px; }
.onboarding-card input, .onboarding-card select {
  width: 100%; padding: 10px 12px; border-radius: 8px; border: 1px solid #333;
  background: #0a0a0c; color: #fff; font: inherit;
}
.onboarding-actions { display: flex; gap: 8px; margin-top: 18px; flex-wrap: wrap; }
.empty-state {
  text-align: center; padding: 40px 20px; color: #a8a29a;
}
.empty-state h3 { color: #f5f5f5; margin-bottom: 8px; }
.badge-plano {
  display: inline-block; padding: 2px 10px; border-radius: 999px;
  background: rgba(201,162,39,.15); color: #c9a227; font-size: 11px; font-weight: 700;
}
.cta-upgrade {
  margin: 12px 0; padding: 12px; border-radius: 10px;
  background: rgba(201,162,39,.08); border: 1px dashed rgba(201,162,39,.4);
  font-size: 13px;
}


/* Módulo Investimentos — contraste legível (tema claro do app) */
.inv-grid { display: grid; gap: 12px; grid-template-columns: 1fr; }
@media(min-width:720px){ .inv-grid { grid-template-columns: 1fr 1fr; } }
.inv-card {
  background: #fff;
  border: 1px solid var(--border, #e5e7eb);
  border-radius: 14px;
  padding: 14px 16px;
  box-shadow: 0 1px 3px rgba(0,0,0,.06);
}
.inv-card h4 { margin: 0 0 6px; color: var(--gold-dark, #8a7020); font-size: 15px; font-weight: 700; }
.inv-card .rate { font-size: 1.35rem; font-weight: 700; color: var(--text, #1a2332); }
.inv-card .rate small { font-size: 12px; color: var(--text-muted, #6b7280); font-weight: 500; }
.inv-card .meta { font-size: 13px; color: var(--text-muted, #4b5563); margin-top: 8px; line-height: 1.45; }
.inv-badge {
  display: inline-block; font-size: 10px; padding: 3px 8px; border-radius: 999px;
  background: #f5f0e0; color: #8a7020; font-weight: 700; margin-left: 6px;
}
.inv-badge.safe { background: #dcfce7; color: #166534; }
.inv-badge.warn { background: #fee2e2; color: #991b1b; }
.inv-sim { display: grid; gap: 10px; }
.inv-sim label { font-size: 12px; color: var(--text-muted, #4b5563); font-weight: 600; }
.inv-sim input, .inv-sim select {
  width: 100%; padding: 12px; border-radius: 8px; border: 1px solid var(--border, #d1d5db);
  background: #fff; color: var(--text, #1a2332); font: inherit; font-size: 15px;
}
.inv-sim input:focus, .inv-sim select:focus {
  outline: none; border-color: var(--gold, #c9a227); box-shadow: 0 0 0 3px rgba(184,148,42,.2);
}
.inv-result {
  margin-top: 12px; padding: 16px; border-radius: 12px;
  background: #1a2332; border: 1px solid #c9a227;
  color: #f5f5f5;
}
.inv-result .big { font-size: 1.6rem; font-weight: 700; color: #e8d48b; }
.inv-result strong { color: #fff; }
.inv-edu {
  font-size: 14px; color: #374151; line-height: 1.55; padding: 14px;
  border-left: 4px solid var(--gold-dark, #8a7020);
  background: #faf6eb; border-radius: 0 10px 10px 0;
  margin: 12px 0;
}
.inv-edu strong { color: #1a2332; }
.inv-table {
  width: 100%; border-collapse: collapse; font-size: 14px; margin-top: 12px;
  background: #fff; border-radius: 10px; overflow: hidden;
  border: 1px solid var(--border, #e5e7eb);
}
.inv-table th {
  text-align: left; color: #1a2332; padding: 12px 10px;
  border-bottom: 2px solid #c9a227; background: #faf6eb;
  font-size: 11px; text-transform: uppercase; letter-spacing: .04em; font-weight: 700;
}
.inv-table td {
  padding: 12px 10px; border-bottom: 1px solid #e5e7eb;
  color: #1a2332; font-weight: 500;
}
.inv-table td:nth-child(2),
.inv-table td:nth-child(3) { font-variant-numeric: tabular-nums; font-weight: 600; }
.inv-table tr:last-child td { border-bottom: none; }
.inv-table tr:hover td { background: #f9fafb; }
/* ganho na tabela — cor via inline; reforço */
.inv-table .ganho-pos { color: #166534 !important; font-weight: 700; }
.panel-body .inv-table + p,
.panel-body ol { color: #374151; }

/* Marca EC$ 360° em todas as telas */
.ecs-brand-bar {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 12px; background: #0a0a0c; border-bottom: 1px solid rgba(201,162,39,.35);
}
.ecs-brand-bar img { height: 36px; width: auto; max-width: 120px; object-fit: contain; }
.ecs-brand-bar .ecs-tag { font-size: 11px; color: #c9a227; font-weight: 700; letter-spacing: .06em; }
.login-logo-img, .brand-logo { max-height: 72px; width: auto; object-fit: contain; }


/* iOS PWA */
html, body { -webkit-text-size-adjust: 100%; }
body { padding-top: env(safe-area-inset-top); padding-bottom: env(safe-area-inset-bottom); }
.top, header, .app-header { padding-top: max(8px, env(safe-area-inset-top)); }
.nav, .sidebar, aside { padding-bottom: env(safe-area-inset-bottom); }
input, select, textarea, button { font-size: 16px !important; }

/* ============================================================
   EC$ 360° · UI BANK 2026 — ousado, acima de apps de banco
   ============================================================ */
:root {
  --navy: #0f172a;
  --navy-2: #1e293b;
  --gold: #d4af37;
  --gold-2: #f0d060;
  --cream: #faf8f3;
  --line: #e8e4dc;
  --muted: #64748b;
  --ok: #10b981;
  --bad: #ef4444;
  --card-radius: 20px;
  --bottom-nav-h: 72px;
  --shadow: 0 8px 32px rgba(15,23,42,.12);
  --shadow-gold: 0 12px 40px rgba(212,175,55,.35);
}

/* —— Login cinematic —— */
.login-screen {
  background: radial-gradient(ellipse at 30% 20%, #1e293b 0%, #0f172a 55%, #020617 100%) !important;
  min-height: 100dvh;
}
.login-card {
  background: rgba(255,255,255,.04) !important;
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(212,175,55,.35) !important;
  border-radius: 28px !important;
  box-shadow: 0 24px 80px rgba(0,0,0,.45), inset 0 1px 0 rgba(255,255,255,.08) !important;
  padding: 36px 28px !important;
}
.login-card h1 {
  background: linear-gradient(135deg, #f0d060, #d4af37 40%, #a68b2a);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent !important;
  font-weight: 800 !important;
  letter-spacing: -.02em;
}
.login-logo {
  width: 88px !important;
  height: 88px !important;
  filter: drop-shadow(0 8px 24px rgba(212,175,55,.4));
}
.login-card .btn-primary {
  background: linear-gradient(135deg, #f0d060, #d4af37) !important;
  color: #0f172a !important;
  border: 0 !important;
  border-radius: 16px !important;
  font-weight: 800 !important;
  padding: 16px !important;
  box-shadow: var(--shadow-gold);
  text-transform: none;
  font-size: 16px;
}

/* —— Sidebar premium (menu lateral) —— */
.sidebar {
  background: linear-gradient(180deg, #0f172a 0%, #1e293b 100%) !important;
  border-right: 1px solid rgba(212,175,55,.12);
  box-shadow: 8px 0 40px rgba(0,0,0,.25);
}
.sidebar-brand {
  padding: 22px 18px !important;
  border-bottom: 1px solid rgba(255,255,255,.06);
  display: flex;
  align-items: center;
  gap: 12px;
}
.sidebar-brand img {
  width: 52px !important;
  height: 52px !important;
  border-radius: 14px !important;
  background: linear-gradient(135deg, rgba(212,175,55,.2), rgba(212,175,55,.05)) !important;
  padding: 4px !important;
  box-shadow: 0 4px 16px rgba(212,175,55,.25);
}
.sidebar-brand .brand-text {
  font-size: 15px !important;
  font-weight: 800 !important;
  color: #fff !important;
  letter-spacing: -.01em;
}
.sidebar-brand small {
  color: var(--gold) !important;
  opacity: 1 !important;
  font-weight: 600 !important;
  font-size: 11px !important;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.nav-section {
  font-size: 10px !important;
  font-weight: 700 !important;
  letter-spacing: .12em !important;
  text-transform: uppercase !important;
  color: rgba(212,175,55,.7) !important;
  padding: 18px 18px 8px !important;
  margin: 0 !important;
}
.nav-item {
  margin: 3px 10px !important;
  padding: 12px 14px !important;
  border-radius: 14px !important;
  font-size: 13.5px !important;
  font-weight: 600 !important;
  color: rgba(248,250,252,.75) !important;
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  transition: all .18s ease !important;
  border: 1px solid transparent !important;
}
.nav-item .nav-icon {
  width: 36px;
  height: 36px;
  border-radius: 11px;
  background: rgba(255,255,255,.06);
  display: grid;
  place-items: center;
  font-size: 16px;
  flex-shrink: 0;
  transition: all .18s;
}
.nav-item:hover {
  background: rgba(255,255,255,.07) !important;
  color: #fff !important;
  border-color: rgba(255,255,255,.06) !important;
}
.nav-item:hover .nav-icon {
  background: rgba(212,175,55,.15);
}
.nav-item.active {
  background: linear-gradient(135deg, rgba(212,175,55,.22), rgba(212,175,55,.08)) !important;
  color: #fff !important;
  border-color: rgba(212,175,55,.35) !important;
  box-shadow: 0 4px 20px rgba(212,175,55,.12);
}
.nav-item.active .nav-icon {
  background: linear-gradient(135deg, #d4af37, #a68b2a);
  color: #0f172a;
  box-shadow: 0 4px 12px rgba(212,175,55,.4);
}
.sidebar-foot {
  border-top: 1px solid rgba(255,255,255,.06) !important;
  padding: 14px !important;
  font-size: 11px;
  color: rgba(255,255,255,.4);
}

/* —— Cards estilo banco —— */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
}
.card {
  background: #fff !important;
  border: 1px solid var(--line) !important;
  border-radius: var(--card-radius) !important;
  padding: 18px 16px !important;
  box-shadow: 0 2px 12px rgba(15,23,42,.04) !important;
  transition: transform .15s, box-shadow .15s;
}
.card:active { transform: scale(.98); }
.card-label {
  font-size: 11px !important;
  font-weight: 700 !important;
  letter-spacing: .06em !important;
  text-transform: uppercase !important;
  color: var(--muted) !important;
  margin-bottom: 8px !important;
}
.card-value {
  font-size: 22px !important;
  font-weight: 800 !important;
  letter-spacing: -.03em !important;
  color: var(--navy) !important;
  line-height: 1.15 !important;
}
.card-value.pos { color: var(--ok) !important; }
.card-value.neg { color: var(--bad) !important; }
.card-highlight {
  background: linear-gradient(145deg, #0f172a, #1e293b) !important;
  border: 1px solid rgba(212,175,55,.4) !important;
  color: #fff !important;
  box-shadow: var(--shadow-gold) !important;
}
.card-highlight .card-label { color: rgba(240,208,96,.85) !important; }
.card-highlight .card-value { color: #fff !important; }
.card-highlight .card-sub { color: rgba(255,255,255,.55) !important; font-size: 12px; margin-top: 6px; }

/* Hero saldo (dashboard) */
.hero-saldo {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #0f172a 100%);
  border-radius: 24px;
  padding: 28px 22px 24px;
  color: #fff;
  position: relative;
  overflow: hidden;
  margin-bottom: 16px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(212,175,55,.25);
}
.hero-saldo::before {
  content: '';
  position: absolute;
  top: -40%;
  right: -20%;
  width: 70%;
  height: 140%;
  background: radial-gradient(circle, rgba(212,175,55,.18), transparent 65%);
  pointer-events: none;
}
.hero-saldo .hero-label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgba(240,208,96,.9);
  margin-bottom: 6px;
  position: relative;
}
.hero-saldo .hero-value {
  font-size: 36px;
  font-weight: 800;
  letter-spacing: -.04em;
  line-height: 1.1;
  position: relative;
}
.hero-saldo .hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
  position: relative;
}
.hero-chip {
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  color: rgba(255,255,255,.85);
}
.hero-chip strong { color: var(--gold-2); }

/* Quick actions grid */
.quick-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin: 16px 0;
}
.quick-btn {
  border: 0;
  background: #fff;
  border-radius: 18px;
  padding: 14px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  box-shadow: 0 2px 12px rgba(15,23,42,.06);
  border: 1px solid var(--line);
  cursor: pointer;
  font-family: inherit;
  transition: transform .12s;
}
.quick-btn:active { transform: scale(.96); }
.quick-btn .qi {
  width: 44px; height: 44px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  font-size: 20px;
  background: linear-gradient(135deg, rgba(212,175,55,.2), rgba(212,175,55,.06));
}
.quick-btn span:last-child {
  font-size: 11px;
  font-weight: 700;
  color: var(--navy);
  text-align: center;
}

/* Topbar */
.topbar {
  background: rgba(250,248,243,.92) !important;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line) !important;
}
.btn-menu {
  width: 44px !important;
  height: 44px !important;
  border-radius: 14px !important;
  background: #fff !important;
  border: 1px solid var(--line) !important;
  box-shadow: 0 2px 8px rgba(15,23,42,.06);
}

/* Painéis */
.panel {
  background: #fff !important;
  border: 1px solid var(--line) !important;
  border-radius: 20px !important;
  box-shadow: 0 2px 16px rgba(15,23,42,.04) !important;
  overflow: hidden;
}
.panel-header {
  padding: 16px 18px !important;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, #fff, #faf8f3);
}
.panel-header h3 {
  font-weight: 800 !important;
  letter-spacing: -.02em;
  color: var(--navy) !important;
}

/* Botões */
.btn-primary {
  background: linear-gradient(135deg, #d4af37, #b8942a) !important;
  color: #0f172a !important;
  border: 0 !important;
  border-radius: 14px !important;
  font-weight: 800 !important;
  box-shadow: 0 6px 20px rgba(212,175,55,.35);
}
.btn-success {
  background: linear-gradient(135deg, #10b981, #059669) !important;
  border: 0 !important;
  border-radius: 14px !important;
  font-weight: 700 !important;
}
.btn-outline {
  border: 1.5px solid var(--gold) !important;
  color: #8a7020 !important;
  background: transparent !important;
  border-radius: 14px !important;
  font-weight: 700 !important;
}

/* Inputs */
input, select, textarea {
  border-radius: 14px !important;
  border: 1.5px solid var(--line) !important;
  padding: 14px 16px !important;
  background: #fff !important;
  font-size: 15px !important;
}
input:focus, select:focus, textarea:focus {
  border-color: var(--gold) !important;
  box-shadow: 0 0 0 4px rgba(212,175,55,.15) !important;
  outline: none !important;
}

/* Bottom nav — ousado */
.bottom-nav {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  height: calc(var(--bottom-nav-h) + env(safe-area-inset-bottom));
  padding-bottom: env(safe-area-inset-bottom);
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid rgba(15,23,42,.06);
  display: none;
  align-items: stretch;
  justify-content: space-around;
  z-index: 80;
  box-shadow: 0 -8px 40px rgba(15,23,42,.1);
}
.bottom-nav button {
  flex: 1;
  border: 0;
  background: transparent;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  font-size: 10px;
  font-weight: 700;
  color: var(--muted);
  padding: 8px 2px 10px;
  font-family: inherit;
  letter-spacing: .02em;
}
.bottom-nav button .bn-icon {
  width: 32px; height: 32px;
  display: grid;
  place-items: center;
  font-size: 20px;
  border-radius: 12px;
  transition: all .15s;
}
.bottom-nav button.on {
  color: var(--navy);
}
.bottom-nav button.on .bn-icon {
  background: linear-gradient(135deg, rgba(212,175,55,.3), rgba(212,175,55,.1));
  color: #8a7020;
  transform: translateY(-2px);
}
.bottom-nav button.bn-fab .bn-icon {
  width: 56px; height: 56px;
  margin-top: -22px;
  border-radius: 18px;
  background: linear-gradient(145deg, #f0d060, #d4af37 40%, #a68b2a);
  color: #0f172a;
  font-size: 28px;
  font-weight: 800;
  box-shadow: 0 8px 28px rgba(212,175,55,.5), inset 0 1px 0 rgba(255,255,255,.4);
  border: 3px solid #fff;
}
.bottom-nav button.bn-fab {
  color: #8a7020;
}

@media (max-width: 900px) {
  .bottom-nav { display: flex !important; }
  .main {
    padding-bottom: calc(var(--bottom-nav-h) + env(safe-area-inset-bottom) + 16px) !important;
  }
  .sidebar {
    width: min(320px, 88vw) !important;
    border-radius: 0 24px 24px 0;
  }
  body { background: #f3f1eb !important; }
  .content, #content { padding: 12px !important; }
  .quick-grid { grid-template-columns: repeat(4, 1fr); }
  .hero-saldo .hero-value { font-size: 32px; }
}

@media (min-width: 901px) {
  .bottom-nav { display: none !important; }
  .quick-grid { grid-template-columns: repeat(4, 1fr); max-width: 420px; }
}

/* Toast */
.toast {
  border-radius: 16px !important;
  background: #0f172a !important;
  color: #faf8f3 !important;
  border: 1px solid rgba(212,175,55,.45) !important;
  font-weight: 700 !important;
  box-shadow: 0 12px 40px rgba(0,0,0,.3) !important;
}

/* Lista de lançamentos mais “banco” */
.lanc-row, .list-item, tr {
  transition: background .12s;
}

/* ============================================================
   Bank 2026 · uniformidade em TODAS as telas
   ============================================================ */
body { background: #f3f1eb !important; }
.main, #app .main { background: transparent !important; }
#content, .content {
  max-width: 1100px;
}
.page-title, #page-title {
  font-weight: 800 !important;
  letter-spacing: -.02em !important;
  color: #0f172a !important;
}
.topbar h1, .topbar .title {
  font-weight: 800 !important;
}

/* Tabelas modernas */
.table-wrap {
  border-radius: 16px;
  border: 1px solid var(--line, #e8e4dc);
  overflow: auto;
  background: #fff;
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
table thead th {
  background: #0f172a !important;
  color: #f0d060 !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  letter-spacing: .04em !important;
  text-transform: uppercase !important;
  padding: 12px 14px !important;
  border: 0 !important;
  position: sticky;
  top: 0;
  z-index: 1;
}
table tbody td {
  padding: 12px 14px !important;
  border-bottom: 1px solid #f1efe8 !important;
  color: #0f172a;
  vertical-align: middle;
}
table tbody tr:last-child td { border-bottom: 0 !important; }
table tbody tr:hover td { background: #faf8f3 !important; }

/* Listas de lançamentos */
.lanc-item, .list-row, .mes-item, .agenda-item {
  background: #fff;
  border: 1px solid var(--line, #e8e4dc);
  border-radius: 14px;
  padding: 12px 14px;
  margin-bottom: 8px;
  box-shadow: 0 1px 6px rgba(15,23,42,.04);
}

/* Empty states */
.empty-state {
  text-align: center;
  padding: 36px 16px !important;
  color: #64748b !important;
  background: #fff !important;
  border-radius: 16px;
  border: 1px dashed #e8e4dc;
}

/* Formulários em grid mais arejados */
.form-grid, .form-row {
  gap: 12px !important;
}
.form-group label {
  font-size: 11px !important;
  font-weight: 700 !important;
  letter-spacing: .04em !important;
  text-transform: uppercase !important;
  color: #64748b !important;
}

/* Badges status */
.badge, .status-pago, .status-pendente {
  border-radius: 999px !important;
  font-weight: 700 !important;
  font-size: 11px !important;
  padding: 4px 10px !important;
}

/* CEO charts mobile */
@media (max-width: 700px) {
  .ceo-charts { grid-template-columns: 1fr !important; }
  .quick-grid { grid-template-columns: repeat(4, 1fr) !important; }
  .quick-btn span:last-child { font-size: 10px !important; }
}

/* Scrollbar sutil */
#content::-webkit-scrollbar { width: 6px; }
#content::-webkit-scrollbar-thumb { background: #d4af37; border-radius: 99px; }


/* —— Dashboard estilo app banco (arte EC$ 360°) —— */
.dash-bank { max-width: 480px; margin: 0 auto; padding-bottom: 8px; }
.dash-greet { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 14px; gap: 10px; }
.dash-hello { font-size: 1.25rem; font-weight: 800; color: var(--text, #f1f5f9); }
.dash-sub { font-size: 12px; color: var(--muted, #94a3b8); margin-top: 2px; }
.dash-nav-m { display: flex; gap: 6px; }
.dash-saldo-card {
  background: linear-gradient(145deg, #1a2438 0%, #0f1624 100%);
  border: 1px solid rgba(201, 162, 39, 0.35);
  border-radius: 18px;
  padding: 18px 16px 16px;
  margin-bottom: 12px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
}
.dash-saldo-label {
  font-size: 12px;
  color: #94a3b8;
  font-weight: 600;
  letter-spacing: 0.02em;
  display: flex;
  align-items: center;
  gap: 6px;
}
.dash-eye { color: #c9a227; font-size: 8px; }
.dash-saldo-value {
  font-size: 2rem;
  font-weight: 800;
  margin: 6px 0 4px;
  letter-spacing: -0.02em;
}
.dash-saldo-value.pos { color: #e8c547; }
.dash-saldo-value.neg { color: #fca5a5; }
.dash-saldo-hint { font-size: 11px; color: #64748b; margin-bottom: 10px; }
.dash-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.dash-chip {
  font-size: 11px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 999px;
  padding: 4px 10px;
  color: #cbd5e1;
}
.dash-chip strong { color: #f1f5f9; }
.dash-chip.gold { border-color: rgba(201, 162, 39, 0.45); color: #e8c547; }
.dash-chip.gold strong { color: #e8c547; }

.dash-resumo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 12px;
}
.dash-resumo-box {
  background: #121a2b;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 14px;
  padding: 12px;
}
.dash-resumo-lab {
  font-size: 11px;
  color: #94a3b8;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
}
.dash-resumo-lab .dot {
  width: 8px; height: 8px; border-radius: 50%;
  display: inline-block;
}
.dash-resumo-lab .dot.green { background: #34d399; }
.dash-resumo-lab .dot.red { background: #f87171; }
.dash-resumo-val { font-size: 1.15rem; font-weight: 800; }
.dash-resumo-val.pos { color: #34d399; }
.dash-resumo-val.neg { color: #f87171; }
.dash-mini { font-size: 10px; color: #64748b; margin-top: 2px; }

.dash-panel {
  background: #121a2b;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 14px;
  padding: 14px;
  margin-bottom: 12px;
}
.dash-panel-title {
  font-size: 13px;
  font-weight: 700;
  color: #e8c547;
  margin-bottom: 12px;
}
.dash-cat-row { margin-bottom: 12px; }
.dash-cat-top {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  margin-bottom: 4px;
}
.dash-cat-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.dash-cat-name { flex: 1; color: #e2e8f0; font-weight: 600; }
.dash-cat-pct { color: #94a3b8; font-weight: 700; }
.dash-cat-track {
  height: 6px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 99px;
  overflow: hidden;
}
.dash-cat-fill { height: 100%; border-radius: 99px; }
.dash-cat-val { font-size: 11px; color: #94a3b8; margin-top: 2px; }
.dash-empty { font-size: 13px; color: #64748b; margin: 0; }

.dash-kpi {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 14px;
}
.dash-kpi-item {
  background: #0f1624;
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 12px;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.dash-kpi-item span { font-size: 10px; text-transform: uppercase; letter-spacing: 0.04em; color: #64748b; font-weight: 700; }
.dash-kpi-item strong { font-size: 14px; color: #f1f5f9; }
.dash-kpi-item strong.pos { color: #34d399; }
.dash-kpi-item strong.neg { color: #f87171; }
.dash-foot { font-size: 12px; color: #94a3b8; text-align: center; margin: 8px 0 0; }
.dash-foot .pos { color: #34d399; }
.dash-foot .neg { color: #f87171; }

.dash-tip {
  margin-top: 10px;
  font-size: 13px;
  line-height: 1.5;
  color: #1e3a8a;
  background: #dbeafe;
  border: 1px solid #93c5fd;
  border-left: 4px solid #2563eb;
  padding: 10px 12px;
  border-radius: 10px;
  max-width: 100%;
  font-weight: 600;
  box-shadow: 0 1px 2px rgba(37, 99, 235, 0.08);
}
.dash-tip::first-line { font-weight: 700; }
.dash-donut-wrap {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: nowrap;
}
.dash-donut-chart {
  flex: 0 0 120px;
  width: 120px;
  height: 120px;
}
.dash-donut-svg { width: 100%; height: 100%; }
.dash-donut-label { fill: #94a3b8; font-size: 7px; font-family: system-ui, sans-serif; }
.dash-donut-pct { fill: #e8c547; font-size: 8px; font-weight: 700; font-family: system-ui, sans-serif; }
.dash-donut-legend {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.dash-leg-row {
  display: grid;
  grid-template-columns: 10px 1fr auto auto;
  gap: 6px;
  align-items: center;
  font-size: 11px;
}
.dash-leg-dot { width: 8px; height: 8px; border-radius: 50%; }
.dash-leg-name { color: #e2e8f0; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dash-leg-pct { color: #94a3b8; font-weight: 700; }
.dash-leg-val { color: #cbd5e1; font-size: 10px; }
@media (max-width: 360px) {
  .dash-donut-wrap { flex-direction: column; align-items: stretch; }
  .dash-donut-chart { margin: 0 auto; }
}


.bottom-nav-6 button {
  font-size: 9px;
  padding: 4px 2px;
  min-width: 0;
  flex: 1 1 0;
}
.bottom-nav-6 button .bn-icon {
  font-size: 16px;
}
.bottom-nav-6 button.bn-fab .bn-icon {
  font-size: 18px;
}
