/* Estilos Customizados - SAUDU */
/* Layout com Menu Lateral Minimizável */

/* Importação da fonte Inter */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

/* Fix para modal sem backdrop */
#modalHistoricoFipe,
#modalHistoricoQuilometragem {
  z-index: 9999 !important;
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100% !important;
  background-color: rgba(0, 0, 0, 0.5) !important;
  display: none !important;
}

#modalHistoricoFipe.show,
#modalHistoricoQuilometragem.show {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

#modalHistoricoFipe .modal-dialog,
#modalHistoricoQuilometragem .modal-dialog {
  z-index: 10000 !important;
  position: relative !important;
  margin: 0 !important;
  max-width: 90% !important;
  max-height: 90% !important;
}

#modalHistoricoFipe .modal-content,
#modalHistoricoQuilometragem .modal-content {
  background-color: var(--card-bg) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: 8px !important;
  box-shadow: var(--shadow-lg) !important;
}

/* Remover qualquer backdrop que possa aparecer */
.modal-backdrop {
  display: none !important;
}

/* Garantir que o body não seja afetado */
body.modal-open {
  overflow: auto !important;
  padding-right: 0 !important;
}

/* Reset e configurações base */
* {
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  line-height: 1.6;
  font-weight: 400;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

/* Formatação brasileira para campos de data */
input[type="date"] {
  position: relative;
}

input[type="date"]::-webkit-calendar-picker-indicator {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
}

input[type="date"]:lang(pt-BR) {
  text-align: left;
}

input[type="date"]:invalid::before {
  content: "dd/mm/aaaa";
  color: #999;
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
}

/* Tema escuro: garantir legibilidade em campos de data */
[data-theme="dark"] input[type="date"] {
  color: var(--text-primary);
}
[data-theme="dark"] input[type="date"]::-webkit-datetime-edit,
[data-theme="dark"] input[type="date"]::-webkit-datetime-edit-text,
[data-theme="dark"] input[type="date"]::-webkit-datetime-edit-month-field,
[data-theme="dark"] input[type="date"]::-webkit-datetime-edit-day-field,
[data-theme="dark"] input[type="date"]::-webkit-datetime-edit-year-field {
  color: var(--text-primary);
}
[data-theme="dark"] input[type="date"]::-webkit-calendar-picker-indicator {
  filter: invert(1);
  opacity: 0.8;
}
[data-theme="dark"] input[type="date"]:invalid::before {
  color: var(--text-secondary);
}

/* Tipografia */
h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: 1rem;
}

h1 { font-size: 2.5rem; font-weight: 700; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

.text-small { font-size: 0.875rem; }

/* Layout principal */
.main-container {
  min-height: 100vh;
  background-color: var(--light-bg);
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
}

/* Sidebar */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  width: 280px;
  background: var(--card-bg);
  background-color: #ffffff !important;
  border-right: 1px solid var(--border-color);
  transition: all 0.3s ease;
  z-index: 1040;
  display: flex;
  flex-direction: column;
  box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
}

/* ===== Veículos: Cards responsivos no mobile ===== */
@media (max-width: 767.98px) {
  .vehicle-card-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .vehicle-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 12px;
    box-shadow: var(--shadow);
  }
  .vehicle-card .vc-header h6 {
    margin-bottom: 2px;
  }
  .vehicle-card .vc-body {
    margin-top: 8px;
    display: grid;
    gap: 6px;
  }
  .vehicle-card .vc-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }
  .vehicle-card .vc-label {
    color: var(--text-secondary);
    font-size: 0.875rem;
  }
  .vehicle-card .vc-value {
    color: var(--text-primary);
    font-weight: 500;
  }
  .vehicle-card .vc-inline-actions .btn {
    flex-shrink: 0;
  }
  .vehicle-card .vc-actions {
    margin-top: 10px;
  }
  .vehicle-card .icon-circle {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--hover-bg);
  }
}

.sidebar.minimized {
  width: 70px;
}

.sidebar-header {
  padding: 1.5rem 1rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 80px;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--primary-color);
}

.brand-text {
  transition: opacity 0.3s ease;
}

.sidebar.minimized .brand-text {
  opacity: 0;
  width: 0;
  overflow: hidden;
}

.sidebar-toggle {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 0.375rem;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.sidebar-toggle:hover {
  background-color: var(--hover-bg);
  color: var(--primary-color);
  transform: scale(1.1);
}

.sidebar-toggle i {
  transition: all 0.3s ease;
}

.sidebar.minimized .sidebar-toggle i {
  transform: rotate(180deg);
}

/* Sidebar Content */
.sidebar-content {
  flex: 1;
  padding: 1rem 0;
  overflow-y: auto;
}

.sidebar-nav {
  list-style: none;
  padding: 0;
  margin: 0;
}

.nav-item {
  margin-bottom: 0.5rem;
}

.nav-link {
  display: flex;
  align-items: center;
  padding: 0.75rem 1.5rem;
  color: var(--text-muted);
  text-decoration: none;
  transition: all 0.2s ease;
  border-radius: 0;
  position: relative;
}

.nav-link:hover {
  background-color: var(--hover-bg);
  color: var(--text-color);
}

.nav-link.active {
  background-color: var(--primary-color);
  color: white;
}

.nav-link.active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background-color: var(--accent-color);
}

.nav-text {
  transition: opacity 0.3s ease;
}

.sidebar.minimized .nav-text {
  opacity: 0;
  width: 0;
  overflow: hidden;
}

/* Gráficos responsivos */
.chart-container {
  position: relative;
  width: 100%;
  height: 320px;
}

@media (max-width: 576px) {
  .chart-container {
    height: 260px;
  }
}

/* Seções do menu */
.nav-section {
  margin-bottom: 0.5rem;
}

.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.5rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 0;
  transition: all 0.3s ease;
  cursor: pointer;
  user-select: none;
  border-bottom: 1px solid var(--border-color);
}

.section-title:hover {
  background-color: var(--hover-bg);
  color: var(--text-color);
}

.section-title .dropdown-icon {
  font-size: 0.75rem;
  transition: transform 0.2s ease;
}

.nav-section.collapsed .section-title .dropdown-icon {
  transform: rotate(-90deg);
}

/* Destaque visual para seções abertas */
.nav-section:not(.collapsed) {
  border-left: 4px solid var(--accent-color);
  background: var(--hover-bg);
  border-radius: 0 6px 6px 0;
}

.nav-section:not(.collapsed) .section-title {
  color: var(--text-color);
  font-weight: 600;
}

.nav-section:not(.collapsed) .section-title .dropdown-icon {
  transform: rotate(0deg);
  color: var(--primary-color);
}

.sidebar.minimized .section-title {
  opacity: 0;
  height: 0;
  padding: 0;
  margin: 0;
  overflow: hidden;
}

.section-items {
  list-style: none;
  padding: 0;
  margin: 0;
  max-height: 500px;
  overflow: hidden;
  transition: max-height 0.3s ease, opacity 0.2s ease;
  opacity: 1;
}

.nav-section.collapsed .section-items {
  max-height: 0;
  opacity: 0;
}

.section-items .nav-link {
  padding-left: 2rem;
  font-size: 0.9rem;
}

/* Submenus aninhados: títulos menores e indentados */
.section-items .nav-section .section-title {
  padding-left: 1.75rem;
  font-size: 0.85rem;
  opacity: 0.95;
}

.sidebar.minimized .section-items .nav-link {
  padding-left: 1.5rem;
}

/* Sidebar Footer */
.sidebar-footer {
  padding: 1rem;
  border-top: 1px solid var(--border-color);
}

.user-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.user-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--primary-color);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 600;
  font-size: 0.9rem;
  flex-shrink: 0;
}

.user-details {
  flex: 1;
  min-width: 0;
  transition: opacity 0.3s ease;
}

.sidebar.minimized .user-details {
  opacity: 0;
  width: 0;
  overflow: hidden;
}

/* Dropdown no estado minimizado */
.sidebar.minimized .nav-section .section-title {
  padding: 0.75rem;
  justify-content: center;
}

.sidebar.minimized .nav-section .section-title .dropdown-icon {
  display: none;
}

.sidebar.minimized .nav-section .section-items {
  max-height: 0 !important;
  opacity: 0 !important;
  overflow: hidden;
}

/* Tooltip para seções minimizadas */
.sidebar.minimized .nav-section .section-title {
  position: relative;
}

.sidebar.minimized .nav-section .section-title::after {
  content: attr(data-title);
  position: absolute;
  left: 100%;
  top: 50%;
  transform: translateY(-50%);
  background: #333;
  color: white;
  padding: 0.5rem 0.75rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 1000;
  margin-left: 0.5rem;
}

.sidebar.minimized .nav-section .section-title:hover::after {
  opacity: 1;
}

.user-name {
  display: block;
  font-weight: 500;
  color: var(--text-color);
  font-size: 0.9rem;
  margin-bottom: 0.25rem;
}

.user-actions {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.theme-toggle,
.logout-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.25rem;
  border-radius: 0.25rem;
  transition: all 0.2s ease;
  font-size: 0.8rem;
  text-decoration: none;
}

.theme-toggle:hover,
.logout-btn:hover {
  background-color: var(--hover-bg);
  color: var(--text-color);
}

.theme-icon::before {
  content: '🌙';
}

[data-theme="dark"] .theme-icon::before {
  content: '☀️';
}

/* Top Bar */
.topbar {
  position: fixed;
  top: 0;
  left: 280px;
  right: 0;
  height: 80px;
  background: var(--card-bg);
  border-bottom: 1px solid var(--border-color);
  z-index: 1020;
  transition: all 0.3s ease;
  width: calc(100% - 280px);
}

.sidebar.minimized ~ .topbar {
  left: 70px;
  width: calc(100% - 70px);
}

.topbar-content {
  display: flex;
  align-items: center;
  height: 100%;
  padding: 0 2rem;
  gap: 1rem;
}

.mobile-menu-toggle {
  display: none;
  flex-direction: column;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  gap: 3px;
}

.mobile-menu-toggle span {
  width: 20px;
  height: 2px;
  background-color: var(--text-color);
  transition: all 0.3s ease;
}

.page-title h1 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-color);
}

/* Main Content */
.main-content {
  margin-left: 280px;
  margin-top: 80px;
  min-height: calc(100vh - 80px);
  padding-top: 0.75rem; /* espaçamento sutil abaixo da topbar */
  padding-bottom: 4rem;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 1;
  width: calc(100% - 280px);
}

.sidebar.minimized ~ .main-content {
  margin-left: 70px;
  width: calc(100% - 70px);
}

/* Footer */
.main-footer {
  margin-top: auto;
  padding: 1.5rem 2rem;
  border-top: 1px solid var(--border-color);
  background: var(--card-bg);
  background-color: #ffffff !important;
  z-index: 10;
  position: relative;
  margin-left: 0;
  transition: all 0.3s ease;
}

.footer-content {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

/* Login Layout */
.login-layout {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.login-header {
  background: var(--card-bg);
  border-bottom: 1px solid var(--border-color);
}

.login-content {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

/* Responsividade */
@media (max-width: 768px) {
  .sidebar {
    transform: translateX(-100%);
    width: 280px;
  }
  
  .sidebar.mobile-open {
    transform: translateX(0);
  }
  
  .topbar {
    left: 0;
    width: 100%;
  }

  /* Garantir que regras de sidebar minimizado não afetem layout no mobile */
  .sidebar.minimized ~ .topbar {
    left: 0;
    width: 100%;
  }
  .sidebar.minimized ~ .main-content {
    margin-left: 0;
    width: 100%;
  }
  
  .main-content {
    margin-left: 0;
    width: 100%;
  }
  
  .mobile-menu-toggle {
    display: flex;
  }
  
  .topbar-content {
    padding: 0 1rem;
  }
}

/* ===== Ajustes de posicionamento para Modais ===== */
/* Garantir que o modal fique acima da topbar e posicionado com medidas responsivas */
#modalDividasMes {
  z-index: 1060; /* acima da topbar (1020) e backdrop (1050) */
}

#modalDividasMes .modal-dialog {
  margin-top: 12vh;   /* offset responsivo abaixo da topbar */
  margin-bottom: 4vh; /* evitar encostar no rodapé da viewport */
  max-width: min(650px, 80vw); /* largura mais contida e responsiva */
}

/* Manter cabeçalho/rodapé visíveis e rolar apenas o corpo */
#modalDividasMes .modal-content {
  max-height: 86vh;           /* limitar altura total para caber na viewport */
  display: flex;              /* permitir layout flex para controle de áreas */
  flex-direction: column;     /* header, body, footer em coluna */
}

#modalDividasMes .modal-header,
#modalDividasMes .modal-footer {
  flex-shrink: 0;             /* não encolher ao rolar */
}

#modalDividasMes .modal-body {
  overflow-y: auto;           /* rolagem interna do conteúdo */
}

@media (max-width: 768px) {
  #modalDividasMes .modal-dialog {
    margin-top: 12vh;   /* manter offset no mobile também */
    margin-bottom: 2vh; /* reduzir margem inferior em telas menores */
    max-width: 92vw;    /* levemente menor que total da viewport no mobile */
  }
  #modalDividasMes .modal-content {
    max-height: 90vh;   /* permitir um pouco mais de altura no mobile */
  }

  /* Modal Transferência entre contas - 65% da tela no mobile */
  #modalTransferencia .modal-dialog {
    max-width: 92vw;
    margin: 3vh auto;
  }
  #modalTransferencia .modal-content {
    max-height: 65vh;
    display: flex;
    flex-direction: column;
    background-color: var(--card-bg);
  }
  #modalTransferencia .modal-header,
  #modalTransferencia .modal-footer {
    flex-shrink: 0;
    background-color: var(--card-bg);
  }
  #modalTransferencia .modal-body {
    overflow-y: auto;
    background-color: var(--card-bg);
  }

  /* Reabilitar backdrop apenas para Transferência no mobile */
  body.modal-open #modalTransferencia.show ~ .modal-backdrop {
    display: block !important;
    background-color: rgba(0, 0, 0, 0.5) !important;
  }
}

@media (max-width: 576px) {
  .footer-content {
    flex-direction: column;
    text-align: center;
  }
  
  .page-title h1 {
    font-size: 1.25rem;
  }
}

/* Animações */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.fade-in {
  animation: fadeIn 0.3s ease-out;
}

/* Cards e componentes existentes */
.card {
  border: 1px solid var(--border-color);
  border-radius: 0.75rem;
  background: var(--card-bg);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  transition: all 0.2s ease;
  overflow: hidden;
}

/* Tabelas com arredondamento */
.table-responsive {
  border-radius: 0.75rem;
  overflow: hidden;
}

.table {
  border-radius: 0.75rem;
  overflow: hidden;
}

.table thead th:first-child {
  border-top-left-radius: 0.75rem;
}

.table thead th:last-child {
  border-top-right-radius: 0.75rem;
}

.table tbody tr:last-child td:first-child {
  border-bottom-left-radius: 0.75rem;
}

.table tbody tr:last-child td:last-child {
  border-bottom-right-radius: 0.75rem;
}

.card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transform: translateY(-2px);
}

.btn {
  border-radius: 0.5rem;
  font-weight: 500;
  transition: all 0.2s ease;
}

.btn-primary {
  background: var(--primary-color);
  border-color: var(--primary-color);
}

.btn-primary:hover {
  background: var(--primary-hover);
  border-color: var(--primary-hover);
  transform: translateY(-1px);
}

.form-control {
  border-radius: 0.5rem;
  border: 1px solid var(--border-color);
  transition: all 0.2s ease;
}

.form-control:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.25);
}

/* Utilitários */
.text-gradient {
  background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.animate-in {
  animation: fadeIn 0.5s ease-out;
}

/* Overlay para mobile */
.sidebar-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1030;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.sidebar-overlay.active {
  opacity: 1;
  visibility: visible;
}

@media (min-width: 769px) {
  .sidebar-overlay {
    display: none;
  }
}

/* Ícones circulares com fundo transparente */
.icon-circle {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent !important;
  font-size: 1.25rem;
}

/* Estilos para o Perfil do Usuário */
.user-avatar-large {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
}

.user-initial-large {
  font-size: 2rem;
  font-weight: 700;
}

/* Dropdown do usuário */
.user-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  background: white;
  border: 1px solid #ddd;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  min-width: 200px;
  z-index: 1000;
  padding: 8px 0;
  margin-top: 4px;
}

.user-dropdown .dropdown-item {
  padding: 0.75rem 1.25rem;
  font-size: 0.9rem;
  border-radius: 0;
  transition: all 0.2s ease;
}

.user-dropdown .dropdown-item:hover {
  background-color: var(--light-bg);
  color: var(--primary-color);
}

.user-dropdown .dropdown-item.text-danger:hover {
  background-color: rgba(220, 53, 69, 0.1);
  color: #dc3545;
}

.user-dropdown .dropdown-divider {
  margin: 0.5rem 0;
  border-color: var(--border-color);
}

/* Animações para o dropdown */
.user-info .dropdown-toggle::after {
  display: none;
}

.user-avatar.dropdown:hover,
.user-name.dropdown-toggle:hover {
  opacity: 0.8;
  transform: scale(1.02);
  transition: all 0.2s ease;
}

/* Estilos para formulário de perfil */
.form-control:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.15);
}

.input-group .btn-outline-secondary {
  border-color: var(--border-color);
  color: var(--text-muted);
}

.input-group .btn-outline-secondary:hover {
  background-color: var(--light-bg);
  border-color: var(--primary-color);
  color: var(--primary-color);
}

/* Cards do perfil */
.card {
  transition: all 0.3s ease;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

/* Estilos para gráficos */
.chart-container {
  position: relative;
  width: 100%;
  height: 400px;
  padding: 0;
  margin: 0;
  display: flex;
  align-items: stretch;
}

.chart-container canvas {
  width: 100% !important;
  height: 100% !important;
  display: block;
  box-sizing: border-box;
}

/* Garantir que o card-body não tenha padding extra que cause espaços em branco */
.card-body:has(.chart-container) {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  height: 100%;
}

/* Remover margens e paddings extras do canvas */
.card-body canvas {
  width: 100% !important;
  height: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
  outline: none !important;
}

/* Responsividade para gráficos */
@media (max-width: 1200px) {
  .chart-container {
    height: 350px;
  }
}

@media (max-width: 768px) {
  .chart-container {
    height: 300px;
  }
}

@media (max-width: 576px) {
  .chart-container {
    height: 250px;
  }
  
  .card-body:has(.chart-container) {
    padding: 0.75rem;
  }
}

/* Responsividade para perfil */
@media (max-width: 768px) {
  .user-avatar-large {
    width: 60px;
    height: 60px;
  }
  
  .user-initial-large {
    font-size: 1.5rem;
  }
  
  .user-dropdown {
    min-width: 180px;
  }
}

/* Responsivo: botão 'Verificar E-mail' no topo */
@media (max-width: 576px) {
  .btn-verify-email {
    font-size: 0.875rem; /* ~14px */
    padding: 0.375rem 0.5rem;
    line-height: 1.2;
  }
}

/* ===== Mobile: Ajustes cadastro e termos ===== */
@media (max-width: 576px) {
  /* Dashboard Home: resumo em grid 2x2 com tipografia e ícones reduzidos */
  .dashboard-summary .card-body h6,
  .summary-grid .card-body h6 {
    font-size: 0.8rem;
  }
  .dashboard-summary .card-body h4,
  .summary-grid .card-body h4 {
    font-size: 1rem;
  }
  /* Alguns resumos usam h5 para valores (ex.: Cartão de Crédito) */
  .dashboard-summary .card-body h5,
  .summary-grid .card-body h5 {
    font-size: 1rem;
  }
  .dashboard-summary .card-body i,
  .summary-grid .card-body i {
    font-size: 1rem; /* sobrescreve fa-lg no mobile */
  }
  .dashboard-summary .summary-icon,
  .summary-grid .summary-icon {
    padding: 0.5rem !important; /* reduzir padding para ícone */
  }
  /* Ocultar ícones dos cards no mobile e remover margem do texto */
  .dashboard-summary .d-flex > .flex-shrink-0,
  .summary-grid .d-flex > .flex-shrink-0 {
    display: none !important;
  }
  .dashboard-summary .d-flex > .flex-grow-1.ms-3,
  .summary-grid .d-flex > .flex-grow-1.ms-3 {
    margin-left: 0 !important;
  }

  /* Colorir textos de receita e despesa em mobile (somente texto) */
  .dashboard-summary .summary-receita .card-body h4,
  .dashboard-summary .summary-receita .card-body h6,
  .summary-grid .summary-receita .card-body h4,
  .summary-grid .summary-receita .card-body h6 {
    color: var(--bs-success) !important;
  }
  .dashboard-summary .summary-despesa .card-body h4,
  .dashboard-summary .summary-despesa .card-body h6,
  .summary-grid .summary-despesa .card-body h4,
  .summary-grid .summary-despesa .card-body h6 {
    color: var(--bs-danger) !important;
  }
  /* Reduzir padding lateral do container em páginas públicas (login-layout) */
  .login-layout .container-fluid.px-4 {
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
  }

  /* Cadastro: inputs grandes e tipografia */
  .cadastro-page .form-control-lg,
  .cadastro-page .form-select-lg {
    padding: 0.45rem 0.8rem;
    font-size: 0.95rem;
  }

  .cadastro-page label.form-label {
    font-size: 0.95rem;
  }

  .cadastro-page .card-body {
    padding: 1rem;
  }

  .cadastro-page .row.mb-3 { margin-bottom: 0.75rem !important; }
  .cadastro-page .form-group.mb-3 { margin-bottom: 0.75rem !important; }
  .cadastro-page .form-group.mb-4 { margin-bottom: 1rem !important; }

  .cadastro-page .card-title { font-size: 1rem; }
  .cadastro-page .form-step-indicator i { font-size: 1rem; }
  .cadastro-page .text-muted.small { font-size: 0.85rem; }

  .cadastro-page .d-flex.gap-3.mt-4 .btn {
    padding: 0.55rem 0.75rem;
    font-size: 0.95rem;
  }

  /* Termos: tipografia e espaçamento */
  .terms-page .card-body { padding: 1rem; }
  .terms-page h2.h4 { font-size: 1.05rem; }
  .terms-page h3.h5 { font-size: 0.98rem; margin-top: 0.5rem; }
  .terms-page p,
  .terms-page li { font-size: 0.95rem; }
}
