/* ===== CFO Particular — Design System ===== */
:root {
  --accent: #7c3aed;
  --accent-2: #a855f7;
  --accent-soft: #efeafe;
  --accent-orange: #f97316;
  --green: #059669;
  --green-soft: #d1fae5;
  --red: #e11d48;
  --amber: #d97706;
  --blue: #2563eb;

  --bg: #f4f5f9;
  --surface: #ffffff;
  --surface-2: #eef0f6;
  --border: #e6e8f0;
  --border-strong: #d6d9e4;
  --text: #10131c;
  --text-2: #565b6e;
  --text-3: #8b90a3;
  --shadow-sm: 0 1px 2px rgba(16,24,40,.05);
  --shadow: 0 1px 2px rgba(16,24,40,.04), 0 4px 12px -4px rgba(16,24,40,.08);
  --shadow-lg: 0 2px 6px rgba(16,24,40,.04), 0 18px 36px -18px rgba(16,24,40,.22);
  --ring: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent);
  --radius: 16px;
  --radius-sm: 11px;
}
[data-theme="dark"] {
  --accent: #8b5cf6;
  --accent-2: #a855f7;
  --accent-soft: #241d3d;
  --green: #34d399;
  --green-soft: #10362b;
  --red: #fb7185;
  --amber: #fbbf24;
  --blue: #60a5fa;

  --bg: #0a0b10;
  --surface: #14161e;
  --surface-2: #1b1e28;
  --border: #262a36;
  --border-strong: #333846;
  --text: #eef0f6;
  --text-2: #a2a7ba;
  --text-3: #6a6f82;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.4);
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 8px 20px -8px rgba(0,0,0,.5);
  --shadow-lg: 0 2px 8px rgba(0,0,0,.4), 0 24px 48px -20px rgba(0,0,0,.7);
}

* { margin:0; padding:0; box-sizing:border-box; }
html { font-size: 15px; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg); color: var(--text);
  -webkit-font-smoothing: antialiased;
  transition: background .25s ease, color .25s ease;
}
#app { display:flex; min-height:100vh; }

/* ===== Sidebar ===== */
.sidebar {
  width: 248px; flex-shrink:0; display:flex; flex-direction:column;
  background: var(--surface); border-right:1px solid var(--border);
  padding: 20px 14px; position:sticky; top:0; height:100vh;
}
.logo { display:flex; align-items:center; gap:10px; padding:4px 8px 20px; }
.logo-mark {
  width:38px; height:38px; border-radius:11px; display:flex; align-items:center; justify-content:center;
  background: linear-gradient(135deg, var(--accent), #a855f7); color:#fff; font-weight:800; font-size:19px;
  box-shadow: 0 4px 12px rgba(124,58,237,.35);
}
.logo-text { display:flex; flex-direction:column; line-height:1.15; }
.logo-text strong { font-size:14.5px; }
.logo-text span { font-size:11px; color:var(--text-3); }
.nav { display:flex; flex-direction:column; gap:2px; flex:1; }
.nav-item {
  display:flex; align-items:center; gap:11px; padding:9px 12px; border-radius:10px;
  color:var(--text-2); text-decoration:none; font-size:13.5px; font-weight:500;
  transition: all .15s ease;
}
.nav-item .ico { display:inline-flex; align-items:center; justify-content:center; width:20px; height:20px; opacity:.85; }
.nav-item:hover { background:var(--surface-2); color:var(--text); }
.nav-item.active { background:var(--accent-soft); color:var(--accent); font-weight:600; }
.nav-item.active .ico { opacity:1; }

/* ===== Ícones SVG (estilo consistente) ===== */
[data-icon] svg { display:block; }
.ico, .tico { display:inline-flex; align-items:center; justify-content:center; }
.btn-ic { display:inline-flex; align-items:center; justify-content:center; gap:8px; }
.btn-ic svg { display:block; }
.sidebar-footer { display:flex; flex-direction:column; gap:8px; padding-top:14px; border-top:1px solid var(--border); }

/* ===== Main / Topbar ===== */
.main { flex:1; min-width:0; display:flex; flex-direction:column; }
.topbar {
  display:flex; align-items:center; gap:14px; padding:14px 28px;
  position:sticky; top:0; z-index:20;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(12px);
  border-bottom:1px solid var(--border);
}
.search-wrap { flex:1; max-width:520px; position:relative; display:flex; align-items:center; }
.search-wrap::before {
  content:''; position:absolute; left:14px; width:16px; height:16px; pointer-events:none; opacity:.55;
  background:currentColor; color:var(--text-3);
  -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m21 21-4.3-4.3'/%3E%3C/svg%3E") center/contain no-repeat;
          mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m21 21-4.3-4.3'/%3E%3C/svg%3E") center/contain no-repeat;
}
.search-wrap input {
  width:100%; padding:10px 16px 10px 40px; border-radius:12px; border:1px solid var(--border);
  background:var(--surface); color:var(--text); font-size:13.5px; font-family:inherit; outline:none;
  transition: border .15s, box-shadow .15s;
}
.search-wrap input:focus { border-color:var(--accent); box-shadow:var(--ring); }
.topbar-actions { display:flex; gap:8px; margin-left:auto; align-items:center; }
.view-container { padding: 26px 28px 60px; animation: fadeIn .3s ease; }
@keyframes fadeIn { from { opacity:0; transform:translateY(6px); } to { opacity:1; transform:none; } }

/* ===== Buttons / inputs ===== */
.btn {
  padding:9px 15px; border-radius:11px; border:1px solid var(--border); cursor:pointer;
  background:var(--surface); color:var(--text); font-size:13px; font-weight:600; font-family:inherit;
  transition: all .15s ease; box-shadow:var(--shadow-sm);
}
.btn:hover { background:var(--surface-2); border-color:var(--border-strong); }
.btn:active { transform:translateY(.5px); }
.btn:focus-visible { outline:none; box-shadow:var(--ring); }
.btn-primary { background:linear-gradient(180deg, var(--accent), color-mix(in srgb, var(--accent) 86%, #000)); border-color:transparent; color:#fff; box-shadow:0 4px 14px -4px color-mix(in srgb, var(--accent) 60%, transparent); }
.btn-primary:hover { filter:brightness(1.06); background:linear-gradient(180deg, var(--accent), color-mix(in srgb, var(--accent) 86%, #000)); }
.btn-ghost { background:transparent; box-shadow:none; }
.btn-block { width:100%; }
.btn-icon { width:38px; height:38px; padding:0; display:flex; align-items:center; justify-content:center; border-radius:11px; color:var(--text-2); }
.btn-icon:hover { color:var(--text); }
.btn-sm { padding:6px 11px; font-size:12px; border-radius:9px; }
.select {
  padding:9px 30px 9px 12px; border-radius:11px; border:1px solid var(--border); cursor:pointer;
  background:var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%238b90a3' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 10px center;
  color:var(--text); font-size:13px; font-family:inherit; font-weight:600; box-shadow:var(--shadow-sm);
  appearance:none; -webkit-appearance:none;
}
.select:focus-visible { outline:none; border-color:var(--accent); box-shadow:var(--ring); }

/* ===== Cards / grids ===== */
.grid { display:grid; gap:16px; }
.kpi-grid { grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.card {
  background:var(--surface); border:1px solid var(--border); border-radius:var(--radius);
  padding:20px; box-shadow:var(--shadow);
}
.kpi-grid > .card { transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease; }
.kpi-grid > .card:hover { transform:translateY(-2px); box-shadow:var(--shadow-lg); border-color:var(--border-strong); }
.card h3 { font-size:12.5px; font-weight:600; color:var(--text-2); margin-bottom:14px; display:flex; align-items:center; justify-content:space-between; letter-spacing:.005em; }
.kpi-label { font-size:11.5px; font-weight:600; color:var(--text-3); text-transform:uppercase; letter-spacing:.05em; }
.kpi-value { font-size:25px; font-weight:800; letter-spacing:-.025em; margin-top:7px; font-variant-numeric: tabular-nums; }
.kpi-sub { font-size:12px; color:var(--text-3); margin-top:6px; }
.kpi-sub .up { color:var(--green); font-weight:600; }
.kpi-sub .down { color:var(--red); font-weight:600; }
.pos { color:var(--green); } .neg { color:var(--red); }

.section-title { font-size:16px; font-weight:700; margin:28px 0 14px; letter-spacing:-.015em; }
.page-title { font-size:23px; font-weight:800; letter-spacing:-.03em; margin-bottom:4px; }
.page-sub { font-size:13px; color:var(--text-2); margin-bottom:22px; }

/* ===== Tables ===== */
.table-wrap { overflow-x:auto; border-radius:var(--radius); border:1px solid var(--border); background:var(--surface); box-shadow:var(--shadow); }
table { width:100%; border-collapse:collapse; font-size:13px; }
th { text-align:left; padding:11px 16px; font-size:11.5px; font-weight:600; color:var(--text-3); text-transform:uppercase; letter-spacing:.05em; border-bottom:1px solid var(--border); white-space:nowrap; }
td { padding:11px 16px; border-bottom:1px solid var(--border); vertical-align:middle; }
tr:last-child td { border-bottom:none; }
tbody tr { transition: background .12s; }
tbody tr:hover { background:var(--surface-2); }
td.num { text-align:right; font-variant-numeric: tabular-nums; font-weight:600; white-space:nowrap; }

/* ===== Badges / tags ===== */
.tag {
  display:inline-flex; align-items:center; gap:5px; padding:3px 10px; border-radius:999px;
  font-size:11.5px; font-weight:600; background:var(--surface-2); color:var(--text-2); white-space:nowrap;
}
.tag.transfer { background:color-mix(in srgb, var(--blue) 14%, transparent); color:var(--blue); }
.tag.income { background:color-mix(in srgb, var(--green) 14%, transparent); color:var(--green); }
.tag.expense { background:color-mix(in srgb, var(--red) 12%, transparent); color:var(--red); }
.tag.accent { background:var(--accent-soft); color:var(--accent); }
.tag.warn { background:color-mix(in srgb, var(--amber) 15%, transparent); color:var(--amber); }

/* ===== Insights ===== */
.insight {
  display:flex; gap:12px; padding:13px 16px; border-radius:12px; align-items:flex-start;
  background:var(--surface); border:1px solid var(--border); font-size:13px; line-height:1.5;
}
.insight .dot { width:8px; height:8px; border-radius:50%; margin-top:6px; flex-shrink:0; }
.insight.info .dot { background:var(--blue); }
.insight.good .dot { background:var(--green); }
.insight.warn .dot { background:var(--amber); }
.insight.alert .dot { background:var(--red); }

/* ===== Charts ===== */
.chart-box { position:relative; height:260px; }
.chart-box.tall { height:320px; }
.chart-box.short { height:200px; }

/* ===== Timeline ===== */
.tl { position:relative; padding-left:26px; }
.tl::before { content:''; position:absolute; left:8px; top:6px; bottom:6px; width:2px; background:var(--border); border-radius:2px; }
.tl-item { position:relative; padding:8px 0 8px 8px; }
.tl-item::before { content:''; position:absolute; left:-23px; top:15px; width:10px; height:10px; border-radius:50%; background:var(--surface); border:2.5px solid var(--accent); }
.tl-item.future::before { border-color:var(--amber); border-style:dashed; }
.tl-date { font-size:11px; font-weight:700; color:var(--text-3); text-transform:uppercase; letter-spacing:.05em; }
.tl-body { display:flex; align-items:center; justify-content:space-between; gap:12px; font-size:13.5px; margin-top:2px; }

/* ===== Upload zone ===== */
.upzone {
  border:2px dashed var(--border); border-radius:var(--radius); padding:44px; text-align:center;
  color:var(--text-2); cursor:pointer; transition:all .2s; background:var(--surface);
}
.upzone:hover, .upzone.drag { border-color:var(--accent); background:var(--accent-soft); color:var(--accent); }
.upzone strong { display:block; font-size:16px; margin-bottom:6px; color:var(--text); }

/* ===== Cartão visual ===== */
.ccard {
  border-radius:18px; padding:22px; color:#fff; position:relative; overflow:hidden; min-height:150px;
  background: linear-gradient(135deg, #4c1d95, #7c3aed 55%, #a855f7);
  box-shadow: 0 10px 30px rgba(124,58,237,.35);
  display:flex; flex-direction:column; justify-content:space-between;
}
.ccard.alt { background: linear-gradient(135deg, #7c2d12, #ea580c 55%, #f97316); box-shadow:0 10px 30px rgba(249,115,22,.3); }
.ccard.alt2 { background: linear-gradient(135deg, #0f172a, #1e3a8a 55%, #3b82f6); box-shadow:0 10px 30px rgba(59,130,246,.3); }
.ccard .inst { font-weight:700; font-size:15px; }
.ccard .meta { font-size:12px; opacity:.85; }
.ccard .amount { font-size:23px; font-weight:800; font-variant-numeric:tabular-nums; }
.limitbar { height:6px; border-radius:99px; background:rgba(255,255,255,.25); margin-top:8px; overflow:hidden; }
.limitbar > div { height:100%; background:#fff; border-radius:99px; }

/* ===== Progress / misc ===== */
.progress { height:7px; border-radius:99px; background:var(--surface-2); overflow:hidden; }
.progress > div { height:100%; border-radius:99px; background:var(--accent); }
.empty {
  padding:52px 24px; text-align:center; color:var(--text-3); font-size:14px;
  border:1px dashed var(--border); border-radius:var(--radius); background:var(--surface);
}
.empty strong { display:block; font-size:16px; color:var(--text-2); margin-bottom:6px; }
.row { display:flex; align-items:center; gap:10px; }
.row.between { justify-content:space-between; }
.muted { color:var(--text-3); font-size:12px; }
.mt { margin-top:16px; } .mb { margin-bottom:16px; }

/* ===== Toasts ===== */
.toast-wrap { position:fixed; bottom:22px; right:22px; display:flex; flex-direction:column; gap:8px; z-index:100; }
.toast {
  padding:12px 18px; border-radius:12px; background:var(--text); color:var(--bg); font-size:13px; font-weight:500;
  box-shadow:0 8px 24px rgba(0,0,0,.25); animation: slideUp .25s ease; max-width:380px;
}
.toast.err { background:var(--red); color:#fff; }
@keyframes slideUp { from { opacity:0; transform:translateY(10px); } to { opacity:1; transform:none; } }

/* ===== Drag overlay ===== */
.drop-overlay {
  display:none; position:fixed; inset:0; z-index:200; background:color-mix(in srgb, var(--accent) 12%, rgba(0,0,0,.45));
  backdrop-filter: blur(4px); align-items:center; justify-content:center;
}
.drop-overlay.on { display:flex; }
.drop-box {
  padding:38px 60px; border:3px dashed #fff; border-radius:22px; color:#fff; font-size:20px; font-weight:700;
}

/* ===== Print / relatório ===== */
.print-area { display:none; }
@media print {
  body > #app, .toast-wrap, .drop-overlay { display:none !important; }
  .print-area { display:block !important; }
  body { background:#fff !important; color:#111 !important; }
  @page { margin: 14mm; }
}
.report {
  font-family:'Inter', sans-serif; color:#1a1a1a; max-width:800px; margin:0 auto; font-size:12.5px;
}
.report .rep-head { display:flex; justify-content:space-between; align-items:center; border-bottom:3px solid #7c3aed; padding-bottom:14px; margin-bottom:20px; }
.report h1 { font-size:22px; letter-spacing:-.02em; }
.report h2 { font-size:15px; margin:22px 0 10px; color:#7c3aed; }
.report .rep-kpis { display:grid; grid-template-columns:repeat(4,1fr); gap:10px; }
.report .rep-kpi { border:1px solid #e5e7eb; border-radius:10px; padding:12px; }
.report .rep-kpi .l { font-size:10px; text-transform:uppercase; color:#6b7280; font-weight:700; letter-spacing:.04em; }
.report .rep-kpi .v { font-size:16px; font-weight:800; margin-top:4px; }
.report table { font-size:11.5px; }
.report td, .report th { padding:7px 10px; }
.report .rep-comment { background:#f5f3ff; border-left:3px solid #7c3aed; padding:10px 14px; border-radius:0 8px 8px 0; margin:8px 0; }

/* ===== Barra inferior (tab bar) — só no celular ===== */
.tabbar { display:none; }
.sheet-overlay { display:none; }

@media (max-width: 900px) {
  /* Esconde a barra lateral e mostra a barra de baixo */
  .sidebar { display:none; }
  #app { display:block; }
  .main { min-height:100vh; }

  /* Topbar compacto: nada de corte. Busca ocupa a linha toda; ações embaixo se precisar */
  .topbar {
    flex-wrap:wrap; gap:8px; padding:10px 14px;
    padding-top:calc(10px + env(safe-area-inset-top));
  }
  .search-wrap { order:2; flex:1 1 100%; max-width:none; }
  .topbar-actions { order:1; width:100%; justify-content:space-between; margin-left:0; gap:6px; }
  #monthFilter { flex:1; min-width:0; }
  .user-chip { flex-shrink:0; }

  .view-container { padding:16px 14px calc(90px + env(safe-area-inset-bottom)); }
  .page-title { font-size:20px; }

  /* Gráficos/seções em 1 coluna; KPIs em 2 (mais compacto e sem corte) */
  .grid { grid-template-columns:1fr !important; }
  .kpi-grid { grid-template-columns:1fr 1fr !important; }
  .kpi-value { font-size:18px; }
  .kpi-label { font-size:10.5px; }
  .card { padding:16px; }
  .chart-box, .chart-box.tall, .chart-box.short { height:240px; }
  .report .rep-kpis { grid-template-columns:repeat(2,1fr); }
  /* KPI de conta única (ex.: cripto) pode ocupar a linha toda */
  .kpi-grid > .card:last-child:nth-child(odd) { grid-column:1 / -1; }

  /* Tabela responsiva (Transações): vira cartões, valor sempre visível */
  .rtable thead { display:none; }
  .rtable, .rtable tbody { display:block; width:100%; }
  .rtable tr {
    display:block; position:relative; padding:12px 96px 12px 2px;
    border-bottom:1px solid var(--border);
  }
  .rtable td { display:block; border:none; padding:0; }
  .rtable .c-desc { font-size:13.5px; font-weight:600; line-height:1.35; }
  .rtable .c-date { font-size:11px; color:var(--text-3); margin-bottom:2px; }
  .rtable .c-acc { font-size:11px; color:var(--text-3); margin-top:2px; }
  .rtable .c-cat { margin-top:8px; }
  .rtable .c-cat select { width:auto; max-width:100%; }
  .rtable .c-val {
    position:absolute; top:12px; right:2px; font-size:15px; font-weight:700;
    text-align:right; white-space:nowrap;
  }
  .rtable tr:hover { background:transparent; }

  /* ===== A barra de baixo ===== */
  .tabbar {
    display:flex; position:fixed; bottom:0; left:0; right:0; z-index:60;
    background:color-mix(in srgb, var(--surface) 92%, transparent);
    backdrop-filter:saturate(180%) blur(16px);
    border-top:1px solid var(--border);
    padding:6px 4px calc(6px + env(safe-area-inset-bottom));
    justify-content:space-around; align-items:center;
  }
  .tab {
    flex:1; background:none; border:none; cursor:pointer; color:var(--text-3);
    display:flex; flex-direction:column; align-items:center; gap:3px;
    font-size:10.5px; font-weight:600; font-family:inherit; padding:6px 2px; border-radius:12px;
    transition:color .15s;
  }
  .tab .tico { display:flex; align-items:center; justify-content:center; height:24px; }
  .tab.active { color:var(--accent); }
  .tab-fab .tico {
    width:46px; height:46px; border-radius:16px; display:flex; align-items:center; justify-content:center;
    background:linear-gradient(140deg, var(--accent), var(--accent-2)); color:#fff; margin-top:-16px;
    box-shadow:0 8px 18px -4px color-mix(in srgb, var(--accent) 60%, transparent);
  }
  .tab-fab { color:var(--accent); }

  /* ===== Folha "Mais" ===== */
  .sheet-overlay {
    display:block; position:fixed; inset:0; z-index:70; background:rgba(0,0,0,.45);
    opacity:0; pointer-events:none; transition:opacity .2s;
  }
  .sheet-overlay.on { opacity:1; pointer-events:auto; }
  .sheet {
    position:absolute; left:0; right:0; bottom:0; background:var(--surface);
    border-radius:22px 22px 0 0; padding:10px 18px calc(24px + env(safe-area-inset-bottom));
    transform:translateY(100%); transition:transform .25s ease; box-shadow:0 -10px 40px rgba(0,0,0,.3);
  }
  .sheet-overlay.on .sheet { transform:none; }
  .sheet-handle { width:40px; height:4px; border-radius:99px; background:var(--border); margin:6px auto 14px; }
  .sheet-title { font-size:13px; font-weight:700; color:var(--text-3); text-transform:uppercase; letter-spacing:.05em; margin-bottom:12px; }
  .sheet-grid { display:grid; grid-template-columns:repeat(4,1fr); gap:10px; }
  .sheet-item {
    background:var(--surface-2); border:1px solid var(--border); border-radius:15px; cursor:pointer;
    display:flex; flex-direction:column; align-items:center; gap:8px; padding:15px 6px;
    font-size:11px; font-weight:600; color:var(--text-2); font-family:inherit; text-align:center;
  }
  .sheet-item span[data-icon] { display:flex; align-items:center; justify-content:center; color:var(--accent); }
  .sheet-item:active { background:var(--accent-soft); transform:scale(.97); }
}

/* Em telas grandes a barra de baixo nunca aparece */
@media (min-width: 901px) { .tabbar, .sheet-overlay { display:none !important; } }

/* ===== Login / Perfis ===== */
.login-screen {
  position: fixed; inset: 0; z-index: 300; display: flex; align-items: center; justify-content: center;
  background: radial-gradient(1200px 600px at 50% -10%, color-mix(in srgb, var(--accent) 22%, var(--bg)), var(--bg));
  padding: 24px;
}
.login-card {
  width: 100%; max-width: 400px; background: var(--surface); border: 1px solid var(--border);
  border-radius: 22px; box-shadow: 0 20px 60px rgba(0,0,0,.25); padding: 32px 28px; text-align: center;
  animation: fadeIn .3s ease;
}
.login-logo {
  width: 60px; height: 60px; border-radius: 17px; margin: 0 auto 16px; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--accent), #a855f7); color: #fff; font-weight: 800; font-size: 30px;
  box-shadow: 0 8px 24px rgba(124,58,237,.4);
}
.login-card h1 { font-size: 20px; letter-spacing: -.02em; }
.login-card .sub { font-size: 13px; color: var(--text-2); margin: 6px 0 26px; }
.profile-grid { display: flex; gap: 14px; justify-content: center; }
.profile-btn {
  flex: 1; max-width: 150px; background: var(--surface-2); border: 2px solid transparent; border-radius: 16px;
  padding: 20px 12px; cursor: pointer; transition: all .15s ease;
}
.profile-btn:hover { border-color: var(--accent); transform: translateY(-2px); }
.profile-av {
  width: 62px; height: 62px; border-radius: 50%; margin: 0 auto 10px; display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 800; font-size: 27px;
}
.profile-btn .pname { font-size: 15px; font-weight: 700; }
.profile-btn .pmeta { font-size: 11px; color: var(--text-3); margin-top: 3px; }
.pin-row { display: flex; gap: 10px; justify-content: center; margin: 22px 0 8px; }
.pin-dot { width: 44px; height: 52px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface-2);
  font-size: 22px; text-align: center; font-weight: 700; color: var(--text); }
.pin-dot:focus { border-color: var(--accent); outline: none; }
.login-back { background: none; border: none; color: var(--text-3); font-size: 12px; cursor: pointer; margin-top: 14px; }
.login-err { color: var(--red); font-size: 12.5px; min-height: 16px; margin-top: 6px; }

/* Barra de usuário no topo */
.user-chip { display: flex; align-items: center; gap: 8px; padding: 5px 10px 5px 6px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--border); cursor: pointer; font-size: 12.5px; font-weight: 600; }
.user-chip .av { width: 26px; height: 26px; border-radius: 50%; color: #fff; font-weight: 800; font-size: 13px;
  display: flex; align-items: center; justify-content: center; }
.sync-badge { font-size: 11px; padding: 2px 8px; border-radius: 999px; font-weight: 600; }
.sync-badge.on { background: color-mix(in srgb, var(--green) 15%, transparent); color: var(--green); }
.sync-badge.off { background: var(--surface-2); color: var(--text-3); }

/* Cartão de configuração da nuvem */
.field { text-align: left; margin-bottom: 12px; }
.field label { display: block; font-size: 12px; font-weight: 600; color: var(--text-2); margin-bottom: 5px; }
.field input { width: 100%; padding: 9px 12px; border-radius: 10px; border: 1px solid var(--border);
  background: var(--surface); color: var(--text); font-size: 13px; font-family: inherit; }
.field input:focus { border-color: var(--accent); outline: none; }
.by-tag { font-size: 10.5px; color: var(--text-3); }
