:root {
  --color-bg: #f5f7fa;
  --color-surface: #ffffff;
  --color-text: #1a1a1a;
  --color-text-secondary: #374151;
  --color-text-muted: #6b7280;
  --color-border: #e5e7eb;
  --color-border-light: #f3f4f6;
  --color-primary: #667eea;
  --color-primary-light: #e0e7ff;
  --color-primary-ink: #1e3c72;
  --color-secondary: #374151;
  --color-danger: #ef4444;
  --color-danger-light: #fee2e2;
  --color-success: #10b981;
  --color-success-light: #d1fae5;
  --color-warning: #f59e0b;
  --color-warning-light: #fef3c7;
  --color-info: #3b82f6;
  --color-info-light: #dbeafe;
  --color-subtle-bg: #f7fafc;
  --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 6px rgba(0,0,0,0.07);
  --shadow-lg: 0 10px 15px rgba(0,0,0,0.1);
  --spacing-xs: 4px;
  --spacing-sm: 8px;
  --spacing-md: 12px;
  --spacing-lg: 16px;
  --spacing-xl: 24px;
  --spacing-2xl: 32px;
  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-full: 999px;
  --transition-fast: 0.15s ease;
  --transition-base: 0.3s ease;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

body {
  background: var(--color-bg);
  color: var(--color-text);
  font-size: 14px;
  line-height: 1.6;
}

/* =========================================
   LAYOUT / CONTAINERS
========================================= */
.app-header {
  background: var(--gradient-primary);
  color: white;
  padding: var(--spacing-md) var(--spacing-xl);
  box-shadow: var(--shadow-md);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.app-header h1 {
  font-size: 20px;
  font-weight: 700;
}

.user-info {
  font-size: 14px;
  font-weight: 500;
  opacity: 0.9;
}

.dashboard-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: var(--spacing-xl);
  min-height: 100vh;
}

/* =========================================
   CARDS / PANELS
========================================= */
.content-section {
  background: var(--color-surface);
  padding: var(--spacing-xl);
  border-radius: var(--radius-lg);
  margin-bottom: var(--spacing-xl);
  box-shadow: var(--shadow-md);
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  border-bottom: 2px solid var(--color-border-light);
}

.section-header h2 {
  font-size: 18px;
  color: var(--color-text);
}

/* =========================================
   KPIS GRID
========================================= */
.kpis-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--spacing-lg);
  margin-bottom: var(--spacing-xl);
}

.kpi-card {
  background: var(--color-surface);
  padding: var(--spacing-lg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: var(--spacing-xs);
  border-left: 4px solid var(--color-primary);
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.kpi-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.kpi-card.blue { border-left-color: var(--color-info); }
.kpi-card.purple { border-left-color: var(--color-primary); }
.kpi-card.green { border-left-color: var(--color-success); }

.kpi-label {
  font-size: 12px;
  color: var(--color-text-muted);
  text-transform: uppercase;
  font-weight: 600;
}

.kpi-value {
  font-size: 28px;
  font-weight: 700;
  color: var(--color-text);
  line-height: 1.2;
}

/* =========================================
   TABLE
========================================= */
.table-wrapper {
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.data-table th {
  background: var(--color-border-light);
  padding: var(--spacing-md) var(--spacing-lg);
  text-align: left;
  font-weight: 600;
  color: var(--color-text-secondary);
  white-space: nowrap;
}

.data-table td {
  padding: var(--spacing-md) var(--spacing-lg);
  border-bottom: 1px solid var(--color-border-light);
}

.data-table tbody tr {
  transition: background var(--transition-fast);
  cursor: pointer;
}

.data-table tbody tr:hover {
  background: var(--color-primary-light);
}

/* =========================================
   BADGES
========================================= */
.badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
}

.badge.status-liberados, .badge.status-finalizados {
  background: var(--color-success-light);
  color: #065f46;
}

.badge.status-aguardando, .badge.status-registrados, .badge.status-atracados {
  background: var(--color-info-light);
  color: #0c4a6e;
}

.badge.status-previstos {
  background: var(--color-warning-light);
  color: #92400e;
}

.badge.status-quitado {
  background: var(--color-success-light);
  color: #065f46;
}

.badge.status-aberto {
  background: var(--color-danger-light);
  color: #7f1d1d;
}

.type-icon {
  margin-right: 6px;
  font-size: 16px;
  vertical-align: middle;
}

/* =========================================
   FORMS
========================================= */
.form-group {
  display: flex;
  flex-direction: column;
}
.form-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--color-text-secondary);
  margin-bottom: 4px;
}
.form-control {
  padding: 8px 12px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: inherit;
  color: var(--color-text);
  outline: none;
  transition: border-color var(--transition-fast);
}
.form-control:focus {
  border-color: var(--color-primary);
}

/* =========================================
   BUTTONS
========================================= */
.btn {
  padding: var(--spacing-sm) var(--spacing-lg);
  border: none;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-base);
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-sm);
}

.btn-secondary {
  background: var(--color-surface);
  color: var(--color-primary);
  border: 1px solid var(--color-primary);
}

.btn-secondary:hover {
  background: var(--color-primary-light);
}

/* =========================================
   DETAILS VIEW (TRACKING)
========================================= */
.view {
  display: none;
  animation: fadeIn 0.3s ease;
}

.view.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.header-actions {
  margin-bottom: var(--spacing-lg);
}

.details-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--spacing-xl);
}

@media (min-width: 900px) {
  .details-grid {
    grid-template-columns: 2fr 1fr;
  }
}

.info-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-xl);
}

.info-item {
  background: var(--color-subtle-bg);
  padding: var(--spacing-md);
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
}

.info-item .label {
  font-size: 11px;
  color: var(--color-text-muted);
  text-transform: uppercase;
  font-weight: 600;
  margin-bottom: 4px;
}

.info-item .val {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text);
}

/* =========================================
   STEPPER / TIMELINE
========================================= */
.stepper {
  display: flex;
  justify-content: space-between;
  position: relative;
  margin: var(--spacing-xl) 0;
  padding-bottom: var(--spacing-xl);
}

.stepper::before {
  content: '';
  position: absolute;
  top: 15px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--color-border);
  z-index: 1;
}

.step {
  position: relative;
  z-index: 2;
  text-align: center;
  flex: 1;
}

.step-marker {
  width: 32px;
  height: 32px;
  background: var(--color-surface);
  border: 2px solid var(--color-border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--spacing-sm) auto;
  font-weight: bold;
  color: var(--color-text-muted);
  transition: all var(--transition-base);
}

.step.completed .step-marker {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: white;
}

.step.completed ~ .step .step-marker {
  /* Future steps */
}

/* Fill the line up to the active step */
.step.active .step-marker {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px var(--color-primary-light);
  color: var(--color-primary);
}

.step-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--color-text-secondary);
}

.step-date {
  font-size: 11px;
  color: var(--color-text-muted);
  margin-top: 2px;
}

/* =========================================
   FINANCIAL PANEL
========================================= */
.fin-panel {
  background: var(--color-subtle-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
}

.fin-panel h3 {
  font-size: 16px;
  margin-bottom: var(--spacing-md);
  padding-bottom: var(--spacing-sm);
  border-bottom: 1px solid var(--color-border);
}

.fin-row {
  display: flex;
  justify-content: space-between;
  padding: var(--spacing-sm) 0;
  font-size: 13px;
}

.fin-row.total {
  font-weight: 700;
  font-size: 16px;
  border-top: 2px solid var(--color-border);
  margin-top: var(--spacing-sm);
  padding-top: var(--spacing-md);
}

.numeric {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}

/* =========================================
   HOME 2 (SAAS LAYOUT)
========================================= */
.saas-layout {
  display: flex;
  height: 100vh;
  overflow: hidden;
}

.sidebar {
  width: 260px;
  background: var(--color-sidebar-bg, #111827);
  color: white;
  display: flex;
  flex-direction: column;
}

.sidebar-logo {
  padding: var(--spacing-xl);
  font-size: 20px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.sidebar-nav {
  padding: var(--spacing-lg) 0;
  display: flex;
  flex-direction: column;
}

.nav-item {
  padding: var(--spacing-md) var(--spacing-xl);
  color: rgba(255,255,255,0.7);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  transition: all var(--transition-fast);
}

.nav-item:hover, .nav-item.active {
  background: rgba(255,255,255,0.1);
  color: white;
  border-left: 4px solid var(--color-primary);
}

.main-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: var(--color-bg);
  overflow-y: auto;
}

.topbar {
  background: var(--color-surface);
  height: 70px;
  padding: 0 var(--spacing-xl);
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: var(--shadow-sm);
  z-index: 10;
}

.search-bar {
  display: flex;
  align-items: center;
  background: var(--color-bg);
  padding: var(--spacing-sm) var(--spacing-md);
  border-radius: var(--radius-full);
  width: 300px;
}

.search-bar input {
  border: none;
  background: transparent;
  outline: none;
  padding-left: var(--spacing-sm);
  width: 100%;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: var(--spacing-lg);
}

.user-profile {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
}

.avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--color-primary);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

.user-details {
  display: flex;
  flex-direction: column;
}
.user-details .name { font-weight: 600; font-size: 13px; }
.user-details .role { font-size: 11px; color: var(--color-text-muted); }

.dashboard-content {
  padding: var(--spacing-xl);
}

.welcome-banner {
  background: var(--gradient-primary);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  color: white;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-xl);
  box-shadow: var(--shadow-md);
}

.macro-kpis {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--spacing-lg);
  margin-bottom: var(--spacing-xl);
}

.macro-card {
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  display: flex;
  align-items: center;
  gap: var(--spacing-lg);
  box-shadow: var(--shadow-sm);
}

.macro-icon {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
}

.macro-info {
  display: flex;
  flex-direction: column;
}
.macro-info .label { font-size: 12px; color: var(--color-text-muted); text-transform: uppercase; font-weight: 600; }
.macro-info .value { font-size: 24px; font-weight: 700; color: var(--color-text); }

.dashboard-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: var(--spacing-xl);
}

.quick-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--spacing-md);
}

.action-card {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  padding: var(--spacing-md);
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
  color: var(--color-text-secondary);
}

.action-card:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
  background: var(--color-primary-light);
}

.action-card i {
  font-size: 24px;
}

.activity-feed {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
}

.activity-item {
  display: flex;
  gap: var(--spacing-md);
  padding-bottom: var(--spacing-md);
  border-bottom: 1px solid var(--color-border-light);
}

.activity-icon {
  color: var(--color-success);
  margin-top: 2px;
}

.activity-title {
  font-size: 13px;
  color: var(--color-text);
}

.activity-desc {
  font-size: 12px;
  color: var(--color-text-secondary);
  margin-top: 2px;
}

.activity-time {
  font-size: 11px;
  color: var(--color-text-muted);
  margin-top: 4px;
}

/* =========================================
   MODALS
========================================= */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-base);
  backdrop-filter: blur(2px);
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.modal-container {
  background: var(--color-surface);
  width: 90%;
  max-width: 500px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  transform: translateY(20px);
  transition: transform var(--transition-base);
}

.modal-overlay.active .modal-container {
  transform: translateY(0);
}

.modal-header {
  padding: var(--spacing-lg) var(--spacing-xl);
  border-bottom: 1px solid var(--color-border-light);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h3 {
  margin: 0;
  font-size: 16px;
  color: var(--color-text);
}

.btn-close {
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
  color: var(--color-text-muted);
}

.modal-body {
  padding: var(--spacing-xl);
  font-size: 14px;
}

.modal-footer {
  padding: var(--spacing-md) var(--spacing-xl);
  border-top: 1px solid var(--color-border-light);
  display: flex;
  justify-content: flex-end;
  gap: var(--spacing-md);
  background: var(--color-subtle-bg);
  border-bottom-left-radius: var(--radius-lg);
  border-bottom-right-radius: var(--radius-lg);
}

.receipt-info {
  background: var(--color-subtle-bg);
  padding: var(--spacing-md);
  border-radius: var(--radius-md);
  border: 1px dashed var(--color-border);
  margin-bottom: var(--spacing-lg);
  text-align: center;
}
.receipt-info h4 { font-size: 24px; color: var(--color-primary); margin-bottom: var(--spacing-xs); }

/* =========================================
   TOPBAR & NOTIFICATIONS
========================================= */
.btn-icon {
  background: none;
  border: none;
  font-size: 20px;
  color: var(--color-text-secondary);
  cursor: pointer;
  position: relative;
  padding: 8px;
  border-radius: 50%;
  transition: background var(--transition-fast);
}

.btn-icon:hover {
  background: var(--color-border-light);
}

.badge-dot {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 8px;
  height: 8px;
  background: var(--color-danger);
  border-radius: 50%;
  border: 2px solid var(--color-surface);
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 320px;
  background: var(--color-surface);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--color-border-light);
  opacity: 0;
  pointer-events: none;
  transform: translateY(-10px);
  transition: all var(--transition-fast);
  z-index: 100;
}

.dropdown-menu.active {
  opacity: 1;
  pointer-events: all;
  transform: translateY(0);
}

.dropdown-header {
  padding: var(--spacing-md) var(--spacing-lg);
  border-bottom: 1px solid var(--color-border-light);
  font-weight: 600;
  font-size: 14px;
}

.dropdown-list {
  max-height: 300px;
  overflow-y: auto;
}

.dropdown-item {
  display: flex;
  gap: var(--spacing-md);
  padding: var(--spacing-md) var(--spacing-lg);
  border-bottom: 1px solid var(--color-border-light);
  cursor: pointer;
  transition: background var(--transition-fast);
}

.dropdown-item:hover {
  background: var(--color-subtle-bg);
}

.dropdown-item.unread {
  background: var(--color-info-light);
}

.dropdown-item.unread:hover {
  background: #cde0fc;
}

.dropdown-item .icon {
  font-size: 16px;
  margin-top: 2px;
}

.dropdown-item .content p {
  font-size: 13px;
  color: var(--color-text);
  margin-bottom: 4px;
  line-height: 1.4;
}

.dropdown-item .content span {
  font-size: 11px;
  color: var(--color-text-muted);
}

.dropdown-footer {
  padding: var(--spacing-md);
  text-align: center;
}

.dropdown-footer a {
  font-size: 13px;
  color: var(--color-primary);
  text-decoration: none;
  font-weight: 500;
}

/* =========================================
   MAPA DE ORIGENS
========================================= */
.map-pin {
  position: absolute;
  color: var(--color-primary);
  font-size: 20px;
  cursor: pointer;
  transform: translate(-50%, -100%);
  z-index: 10;
}

.map-pin .pulse {
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 16px;
  height: 16px;
  background: var(--color-primary);
  border-radius: 50%;
  transform: translate(-50%, 50%);
  z-index: -1;
  animation: pulse-ring 2s infinite;
}

.map-pin .pin-label {
  position: absolute;
  top: -24px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-surface);
  color: var(--color-primary-ink);
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 600;
  border-radius: var(--radius-sm);
  white-space: nowrap;
  box-shadow: var(--shadow-sm);
  pointer-events: none;
}

@keyframes pulse-ring {
  0% { transform: translate(-50%, 50%) scale(0.5); opacity: 0.8; }
  100% { transform: translate(-50%, 50%) scale(3); opacity: 0; }
}

.stats-row {
  display: flex;
  justify-content: space-between;
  padding: var(--spacing-sm) 0;
  border-bottom: 1px solid var(--color-border-light);
  font-size: 14px;
}
.stats-row:last-child { border-bottom: none; }
.stats-row strong { color: var(--color-primary-ink); }

/* =========================================
   CHAT WIDGET
========================================= */
.chat-widget {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 320px;
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  border: 1px solid var(--color-border-light);
  overflow: hidden;
  z-index: 999;
  transform: translateY(120%);
  transition: transform var(--transition-base);
}

.chat-widget.active {
  transform: translateY(0);
}

.chat-header {
  background: var(--gradient-primary);
  color: white;
  padding: var(--spacing-md) var(--spacing-lg);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.chat-messages {
  height: 250px;
  padding: var(--spacing-md);
  overflow-y: auto;
  background: var(--color-subtle-bg);
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
}

.chat-msg {
  display: flex;
  max-width: 85%;
}
.chat-msg.analyst {
  align-self: flex-start;
}
.chat-msg.me {
  align-self: flex-end;
}
.chat-msg .bubble {
  padding: 8px 12px;
  border-radius: var(--radius-md);
  font-size: 13px;
  line-height: 1.4;
}
.chat-msg.analyst .bubble {
  background: white;
  color: var(--color-text);
  border: 1px solid var(--color-border);
  border-top-left-radius: 0;
}
.chat-msg.me .bubble {
  background: var(--color-primary);
  color: white;
  border-top-right-radius: 0;
}

.chat-input {
  padding: var(--spacing-sm) var(--spacing-md);
  border-top: 1px solid var(--color-border);
  background: white;
}
.chat-input input {
  width: 100%;
  border: none;
  outline: none;
  padding: 8px 0;
  font-size: 13px;
}

/* =========================================
   RESPONSIVIDADE MOBILE
========================================= */
@media (max-width: 768px) {
  /* Layout Base e Sidebar -> Bottom Nav */
  .saas-layout {
    flex-direction: column;
  }
  
  .sidebar {
    width: 100%;
    height: 65px;
    flex-direction: row;
    position: fixed;
    bottom: 0;
    left: 0;
    z-index: 1000;
    border-top: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
  }
  
  .sidebar-logo {
    display: none;
  }
  
  .sidebar-nav {
    flex-direction: row;
    width: 100%;
    padding: 0;
    justify-content: space-around;
  }
  
  .nav-item {
    flex-direction: column;
    padding: 8px 0;
    font-size: 10px;
    gap: 4px;
    flex: 1;
    justify-content: center;
    border-left: none !important;
    border-top: 3px solid transparent;
  }
  
  .nav-item:hover, .nav-item.active {
    border-top: 3px solid var(--color-primary);
    background: transparent;
  }

  .nav-item i {
    font-size: 20px;
  }
  
  /* Main Wrapper */
  .main-wrapper {
    margin-bottom: 65px; /* Libera espaco para a Bottom Nav */
  }

  /* Topbar */
  .topbar {
    padding: 0 var(--spacing-sm);
  }
  
  .search-bar {
    display: none; /* Esconde barra de pesquisa em telas muito pequenas */
  }

  /* Grids e Layouts Internos */
  .details-grid {
    grid-template-columns: 1fr !important;
  }
  
  .info-cards {
    grid-template-columns: 1fr 1fr !important;
  }
  
  /* Quick Actions Scroll Horizontal */
  .quick-actions {
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: var(--spacing-sm);
    -webkit-overflow-scrolling: touch;
  }
  
  .action-card {
    flex: 0 0 auto;
    min-width: 160px;
  }
  
  /* Tabela de Dados - Scroll */
  .table-wrapper {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  /* Mapa de Origens (Flexbox) */
  #view-mapa .content-section > div[style*="display: flex"] {
    flex-direction: column !important;
  }
  
  .map-container {
    min-height: 250px;
    width: 100%;
  }

  /* Chat Widget */
  .chat-widget {
    width: calc(100% - 32px);
    right: 16px;
    bottom: 80px; /* Acima da Bottom Nav */
  }

  /* Modais */
  .modal-container {
    width: 95%;
    margin: var(--spacing-sm);
    max-height: 80vh;
    overflow-y: auto;
  }
}
