:root {
  --bg: #0a0f1e;
  --bg2: #111827;
  --bg3: #1a2235;
  --bg4: #232d42;
  --surface: #1e2a3a;
  --surface2: #253349;
  --border: rgba(99,179,237,0.12);
  --border2: rgba(99,179,237,0.22);
  --accent: #38bdf8;
  --accent2: #818cf8;
  --accent3: #34d399;
  --accent4: #fb923c;
  --danger: #f87171;
  --text: #f0f6ff;
  --text2: #94a3b8;
  --text3: #64748b;
  --gold: #fbbf24;
  --gold2: #f59e0b;
  --r: 12px;
  --r2: 18px;
  --r3: 24px;
}
* { margin:0; padding:0; box-sizing:border-box; }
body {
  font-family: 'DM Sans', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  padding-top: env(safe-area-inset-top);
  padding-bottom: env(safe-area-inset-bottom);
}

/* SIDEBAR */
.sidebar {
  width: 240px;
  min-height: 100vh;
  background: var(--bg2);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  left: 0; top: 0; bottom: 0;
  z-index: 100;
}
.logo {
  padding: 28px 24px 20px;
  border-bottom: 1px solid var(--border);
}
.logo-mark {
  font-family: 'DM Serif Display', serif;
  font-size: 22px;
  color: var(--accent);
  letter-spacing: -0.5px;
}
.logo-sub {
  font-size: 11px;
  color: var(--text3);
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin-top: 2px;
}
.nav { padding: 16px 12px; flex: 1; }
.nav-label {
  font-size: 10px;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  color: var(--text3);
  padding: 8px 12px 6px;
  margin-top: 8px;
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  cursor: pointer;
  color: var(--text2);
  font-size: 14px;
  font-weight: 400;
  transition: all 0.15s;
  margin-bottom: 2px;
}
.nav-item:hover { background: var(--bg3); color: var(--text); }
.nav-item.active {
  background: rgba(56,189,248,0.12);
  color: var(--accent);
  font-weight: 500;
}
.nav-icon { font-size: 16px; width: 20px; text-align: center; }
.sidebar-footer {
  padding: 16px;
  border-top: 1px solid var(--border);
}
.profile-pill {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 10px;
  background: var(--bg3);
}
.avatar {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 600; color: #fff;
  flex-shrink: 0;
}
.profile-name { font-size: 13px; font-weight: 500; }
.profile-plan { font-size: 11px; color: var(--accent); }

/* MAIN */
.main {
  margin-left: 240px;
  flex: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.topbar {
  padding: 20px 32px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg2);
  position: sticky; top: 0; z-index: 50;
}
.page-title { font-size: 20px; font-weight: 600; letter-spacing: -0.3px; }
.topbar-actions { display: flex; gap: 10px; align-items: center; }
.btn {
  padding: 8px 16px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  font-weight: 500;
  transition: all 0.15s;
}
.btn-ghost {
  background: var(--bg3);
  color: var(--text2);
  border: 1px solid var(--border);
}
.btn-ghost:hover { background: var(--bg4); color: var(--text); }
.btn-primary {
  background: var(--accent);
  color: #0a0f1e;
}
.btn-primary:hover { opacity: 0.9; transform: translateY(-1px); }
.btn-gold {
  background: var(--gold);
  color: #1a0f00;
}
.btn-success {
  background: var(--accent3);
  color: #002916;
}

.content { padding: 28px 32px; flex: 1; }

/* SECTIONS (tabs) */
.section { display: none; }
.section.active { display: block; }

/* CARDS */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 20px 24px;
  min-width: 0;
}
.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.card-title { font-size: 14px; font-weight: 500; color: var(--text2); }
.card-value { font-size: 28px; font-weight: 600; letter-spacing: -1px; }
.card-delta {
  font-size: 12px;
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
}
.delta-up { color: var(--accent3); }
.delta-down { color: var(--danger); }

/* GRID LAYOUTS */
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 24px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 24px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 24px; }
.grid-21 { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; margin-bottom: 24px; }
.grid-12 { display: grid; grid-template-columns: 1fr 2fr; gap: 20px; margin-bottom: 24px; }

/* CHART WRAPPER */
.chart-wrap { position: relative; width: 100%; height: 220px; min-width: 0; }
.chart-wrap canvas { display: block; width: 100% !important; height: 100% !important; }

/* TRANSACTION LIST */
.tx-list { display: flex; flex-direction: column; gap: 2px; }
.tx-item {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  transition: background 0.1s;
  cursor: default;
}
.tx-item:hover { background: var(--bg3); }
.tx-icon {
  width: 36px; height: 36px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}
.tx-info { flex: 1; min-width: 0; }
.tx-name { font-size: 13px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tx-cat { font-size: 11px; color: var(--text3); margin-top: 1px; }
.tx-amount { font-size: 13px; font-weight: 600; flex-shrink: 0; }
.tx-date { font-size: 11px; color: var(--text3); flex-shrink: 0; }

/* BADGE */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 500;
}
.badge-blue { background: rgba(56,189,248,0.12); color: var(--accent); }
.badge-green { background: rgba(52,211,153,0.12); color: var(--accent3); }
.badge-red { background: rgba(248,113,113,0.12); color: var(--danger); }
.badge-orange { background: rgba(251,146,60,0.12); color: var(--accent4); }
.badge-purple { background: rgba(129,140,248,0.12); color: var(--accent2); }
.badge-gold { background: rgba(251,191,36,0.12); color: var(--gold); }

/* UPLOAD ZONE */
.upload-zone {
  border: 2px dashed var(--border2);
  border-radius: var(--r2);
  padding: 40px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  background: var(--bg3);
  position: relative;
}
.upload-zone:hover { border-color: var(--accent); background: rgba(56,189,248,0.04); }
.upload-zone.dragging { border-color: var(--accent); background: rgba(56,189,248,0.08); }
.upload-icon { font-size: 40px; margin-bottom: 12px; }
.upload-title { font-size: 16px; font-weight: 500; margin-bottom: 6px; }
.upload-sub { font-size: 13px; color: var(--text3); }

/* AI CHAT */
.ai-panel {
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  display: flex;
  flex-direction: column;
  height: 400px;
}
.ai-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.msg {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.msg.user { flex-direction: row-reverse; }
.msg-avatar {
  width: 28px; height: 28px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 600;
}
.msg.ai .msg-avatar { background: linear-gradient(135deg,#38bdf8,#818cf8); color:#fff; }
.msg.user .msg-avatar { background: var(--bg4); color: var(--text2); }
.msg-bubble {
  max-width: 75%;
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 13px;
  line-height: 1.55;
}
.msg.ai .msg-bubble { background: var(--surface2); color: var(--text); border-bottom-left-radius: 4px; }
.msg.user .msg-bubble { background: rgba(56,189,248,0.15); color: var(--text); border-bottom-right-radius: 4px; }
.ai-input-row {
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  display: flex;
  gap: 8px;
}
.ai-input {
  flex: 1;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 14px;
  color: var(--text);
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  outline: none;
  transition: border-color 0.15s;
}
.ai-input:focus { border-color: var(--accent); }
.ai-input::placeholder { color: var(--text3); }
.ai-send {
  background: var(--accent);
  color: #0a0f1e;
  border: none;
  border-radius: 10px;
  padding: 10px 14px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.15s;
}
.ai-send:hover { opacity: 0.9; }

/* INVESTMENT CARD */
.inv-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 18px 20px;
  transition: all 0.2s;
  cursor: pointer;
}
.inv-card:hover { border-color: var(--border2); transform: translateY(-2px); }
.inv-ticker { font-family: 'DM Mono', monospace; font-size: 11px; color: var(--text3); margin-bottom: 4px; }
.inv-name { font-size: 14px; font-weight: 500; margin-bottom: 10px; }
.inv-price { font-size: 22px; font-weight: 600; letter-spacing: -0.5px; }
.inv-change { font-size: 12px; margin-top: 3px; }
.inv-rec {
  margin-top: 12px;
  padding: 8px 10px;
  background: var(--bg3);
  border-radius: 8px;
  font-size: 12px;
  color: var(--text2);
  border-left: 3px solid;
}
.rec-comprar { border-color: var(--accent3); }
.rec-aguardar { border-color: var(--gold); }
.rec-vender { border-color: var(--danger); }

/* PROGRESS BAR */
.progress-wrap { margin-bottom: 14px; }
.progress-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.progress-label { font-size: 13px; font-weight: 400; }
.progress-vals { font-size: 12px; color: var(--text2); }
.progress-bar { height: 8px; background: var(--bg4); border-radius: 99px; overflow: hidden; }
.progress-fill { height: 100%; border-radius: 99px; transition: width 0.6s ease; }

/* TIPOGRAFIA */
.section-title {
  font-family: 'DM Serif Display', serif;
  font-size: 26px;
  letter-spacing: -0.5px;
  margin-bottom: 6px;
}
.section-sub {
  font-size: 14px;
  color: var(--text2);
  margin-bottom: 24px;
}

/* TYPING INDICATOR */
.typing-dots span {
  display: inline-block;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--text3);
  animation: bounce 1.2s infinite;
  margin: 0 2px;
}
.typing-dots span:nth-child(2) { animation-delay: 0.2s; }
.typing-dots span:nth-child(3) { animation-delay: 0.4s; }
@keyframes bounce {
  0%,80%,100% { transform: translateY(0); }
  40% { transform: translateY(-6px); }
}

/* SCORE GAUGE */
.score-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 0;
}
.score-ring {
  position: relative;
  width: 140px; height: 140px;
}
.score-ring svg { transform: rotate(-90deg); }
.score-num {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%,-50%);
  font-size: 32px;
  font-weight: 700;
  color: var(--accent3);
  letter-spacing: -1px;
}
.score-label {
  font-size: 12px;
  color: var(--accent3);
  font-weight: 500;
  margin-top: 10px;
}

/* ALERT BOX */
.alert {
  padding: 12px 16px;
  border-radius: 10px;
  font-size: 13px;
  margin-bottom: 12px;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.alert-warn { background: rgba(251,191,36,0.08); border: 1px solid rgba(251,191,36,0.2); color: var(--gold); }
.alert-info { background: rgba(56,189,248,0.08); border: 1px solid rgba(56,189,248,0.2); color: var(--accent); }
.alert-danger { background: rgba(248,113,113,0.08); border: 1px solid rgba(248,113,113,0.2); color: var(--danger); }
.alert-success { background: rgba(52,211,153,0.08); border: 1px solid rgba(52,211,153,0.2); color: var(--accent3); }

/* DIVIDER */
.divider { height: 1px; background: var(--border); margin: 20px 0; }

/* TABLE */
.data-table { width: 100%; border-collapse: collapse; }
.data-table th {
  text-align: left; font-size: 11px; font-weight: 500;
  color: var(--text3); letter-spacing: 0.8px; text-transform: uppercase;
  padding: 8px 12px; border-bottom: 1px solid var(--border);
}
.data-table td {
  padding: 11px 12px;
  font-size: 13px;
  border-bottom: 1px solid var(--border);
  color: var(--text2);
}
.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: var(--bg3); color: var(--text); }

/* SCROLLBAR */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--bg4); border-radius: 4px; }

/* LOADING SPINNER */
.spinner {
  width: 20px; height: 20px;
  border: 2px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  margin: auto;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* MONTH SELECTOR */
.month-tabs {
  display: flex;
  gap: 4px;
  background: var(--bg3);
  padding: 4px;
  border-radius: 10px;
}
.month-tab {
  padding: 6px 12px;
  border-radius: 7px;
  font-size: 12px;
  cursor: pointer;
  color: var(--text3);
  transition: all 0.15s;
}
.month-tab.active {
  background: var(--surface2);
  color: var(--text);
  font-weight: 500;
}

/* CATEGORY CHIP */
.cat-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 12px;
  cursor: pointer;
  border: 1px solid var(--border);
  color: var(--text2);
  transition: all 0.15s;
}
.cat-chip.active, .cat-chip:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(56,189,248,0.08);
}

/* INVESTMENT ALLOCATION */
.alloc-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}
.alloc-item:last-child { border-bottom: none; }
.alloc-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.alloc-name { flex: 1; font-size: 13px; }
.alloc-pct { font-size: 13px; font-weight: 500; }
.alloc-val { font-size: 12px; color: var(--text3); }

/* GOAL CARD */
.goal-card {
  background: var(--bg3);
  border-radius: var(--r);
  padding: 16px;
  margin-bottom: 12px;
}

/* NOTIFICATION DOT */
.notif-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}

/* FADE IN */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
.fade-in { animation: fadeIn 0.3s ease forwards; }

/* SELECT / INPUT global */
select, input[type=text], input[type=number], input[type=date] {
  background: var(--bg3);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 8px;
  padding: 8px 12px;
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  outline: none;
}
select:focus, input:focus { border-color: var(--accent); }
option { background: var(--bg2); }

/* FILE INPUT */
#fileInput { display: none; }

/* RESPONSIVE tweaks */
@media (max-width: 1100px) {
  .grid-4 { grid-template-columns: repeat(2,1fr); }
  .grid-21, .grid-12 { grid-template-columns: 1fr; }
}

/* HAMBURGER & MOBILE SIDEBAR */
.hamburger-btn {
  display: none;
  position: fixed;
  top: 16px; left: 16px;
  z-index: 200;
  background: var(--bg2);
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 22px;
  padding: 6px 10px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s;
}
.hamburger-btn:hover { background: var(--bg3); }
.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 99;
}
.sidebar-overlay.show { display: block; }

@media (max-width: 768px) {
  .hamburger-btn { display: block; }
  .sidebar {
    transform: translateX(-100%);
    transition: transform 0.3s ease;
  }
  .sidebar.open { transform: translateX(0); }
  .main { margin-left: 0; }
  .topbar { padding: 16px; padding-left: 56px; }
  .content { padding: 16px; }
  .grid-4 { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .grid-21 { grid-template-columns: 1fr; }
  .grid-12 { grid-template-columns: 1fr; }
  .fab { bottom: 20px; right: 20px; width: 48px; height: 48px; font-size: 24px; }
}

/* MODAL */
.modal-overlay {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.6);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.2s ease;
}
.modal-overlay.show {
  display: flex;
}
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes slideUp {
  from { transform: scale(0.95) translateY(10px); opacity: 0; }
  to { transform: scale(1) translateY(0); opacity: 1; }
}
.modal-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 28px;
  width: 90%;
  max-width: 500px;
  animation: slideUp 0.3s ease;
  position: relative;
}
.modal-title {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.modal-close {
  background: none;
  border: none;
  color: var(--text2);
  font-size: 24px;
  cursor: pointer;
  padding: 0;
  width: 32px; height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s;
}
.modal-close:hover { color: var(--text); }
.form-group {
  margin-bottom: 16px;
}
.form-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text2);
  display: block;
  margin-bottom: 6px;
}
.form-input, .form-select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg3);
  color: var(--text);
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  transition: border-color 0.15s;
}
.form-input:focus, .form-select:focus {
  outline: none;
  border-color: var(--accent);
  background: rgba(56,189,248,0.04);
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.form-actions {
  display: flex;
  gap: 12px;
  margin-top: 24px;
}
.form-actions .btn {
  flex: 1;
}

/* FLOATING ACTION BUTTON */
.fab {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  color: #fff;
  border: none;
  font-size: 28px;
  cursor: pointer;
  z-index: 90;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(56,189,248,0.4);
}
.fab:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(56,189,248,0.6);
}
.fab:active {
  transform: scale(0.95);
}

/* BILL (credit card) expandable rows */
.bill-parent:hover { background: var(--bg4) !important; }
.bill-child td { border-top: 1px solid var(--border); }
.bill-child:last-child td { border-bottom: 1px solid var(--border); }

/* AUTH GATE */
.auth-gate {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.auth-gate.hidden { display: none; }
.auth-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r3);
  padding: 48px 36px;
  width: 100%;
  max-width: 400px;
}
.auth-logo {
  font-family: 'DM Serif Display', serif;
  font-size: 28px;
  color: var(--accent);
  text-align: center;
  letter-spacing: -0.5px;
  margin-bottom: 4px;
}
.auth-sub {
  text-align: center;
  color: var(--text3);
  font-size: 12px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin-bottom: 32px;
}

/* SYNC INDICATOR */
#syncStatus .syncing { animation: pulse 1s infinite; }
@keyframes pulse { 0%,100% { opacity:1; } 50% { opacity:0.3; } }

/* ============================================================ */
/* PLANEJAMENTO MÉDICA (PJ-PF) — módulo fiscal                   */
/* ============================================================ */
.pm-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 18px;
}
.pm-bloco {
  display: flex;
  flex-direction: column;
}
.pm-valor-destaque {
  font-size: 32px;
  font-weight: 700;
  margin: 8px 0 4px;
  letter-spacing: -0.5px;
}
.pm-badge {
  font-size: 12px;
  font-weight: 500;
  margin-bottom: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.pm-stats {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 13px;
  border-top: 1px solid var(--border);
  padding-top: 12px;
  margin-top: 4px;
}
.pm-stat {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
.pm-stat span {
  color: var(--text2);
}
.pm-stat b {
  color: var(--text);
  font-weight: 600;
  white-space: nowrap;
}
.pm-pgbl-bar {
  width: 100%;
  height: 10px;
  background: var(--bg3);
  border-radius: 5px;
  overflow: hidden;
}
.pm-pgbl-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent) 0%, var(--accent2) 100%);
  border-radius: 5px;
  transition: width 0.4s ease;
}
.pm-atalhos-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
}
.pm-atalho {
  padding: 12px 14px;
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: var(--r);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.15s ease;
  color: var(--text2);
}
.pm-atalho:hover {
  background: var(--surface2);
  border-color: var(--border2);
  color: var(--text);
  transform: translateY(-1px);
}
.alert-warn {
  background: rgba(251,191,36,0.08);
  border: 1px solid rgba(251,191,36,0.25);
  border-radius: var(--r);
  padding: 12px 14px;
  color: var(--gold);
}
.alert-danger {
  background: rgba(248,113,113,0.08);
  border: 1px solid rgba(248,113,113,0.25);
  border-radius: var(--r);
  padding: 12px 14px;
  color: var(--danger);
}
@media (max-width: 768px) {
  .pm-valor-destaque { font-size: 26px; }
  .pm-header { flex-direction: column; align-items: flex-start; }
}


/* Toggle switch (usado em Configurações → Módulos) */
.toggle-switch { position: relative; display: inline-block; width: 44px; height: 24px; flex-shrink: 0; }
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-switch .slider { position: absolute; cursor: pointer; inset: 0; background: var(--bg3); border-radius: 24px; transition: .2s; }
.toggle-switch .slider::before { content: ""; position: absolute; height: 18px; width: 18px; left: 3px; top: 3px; background: #fff; border-radius: 50%; transition: .2s; }
.toggle-switch input:checked + .slider { background: var(--accent); }
.toggle-switch input:checked + .slider::before { transform: translateX(20px); }

/* Sugestões do Consultor IA — o hover vinha de onmouseover/onmouseout inline,
   removidos junto com os demais handlers inline (ver setupDelegatedActions). */
.ai-suggestion:hover { border-color: var(--accent) !important; color: var(--text) !important; }
