:root {
  --c2-primary: #0d47a1;
  --c2-primary-2: #1565c0;
  --c2-bg: #eef4fb;
  --c2-ink: #0f172a;
  --c2-muted: #64748b;
  --c2-card: #ffffff;
  --c2-line: #d6e4f7;
  --c2-radius: 16px;
  --font: "Plus Jakarta Sans", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  font-family: var(--font);
  color: var(--c2-ink);
  background: var(--c2-bg);
}

.c2-login {
  min-height: 100%;
  display: grid;
  place-items: center;
  padding: 24px;
  background: #0d47a1;
}
.c2-login-card {
  width: min(420px, 100%);
  background: var(--c2-card);
  border-radius: 20px;
  padding: 28px;
  box-shadow: 0 24px 60px rgba(10, 40, 90, .28);
}
.c2-brand-mark {
  display: inline-block;
  font-size: .7rem;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--c2-primary);
}
.c2-login-logo {
  display: block;
  height: 42px;
  width: auto;
  margin-bottom: 10px;
}
.c2-brand h1 {
  margin: 6px 0 4px;
  font-size: 1.55rem;
  letter-spacing: -.02em;
}
.c2-brand p { margin: 0 0 18px; color: var(--c2-muted); font-size: .9rem; }
.c2-form { display: grid; gap: 12px; }
.c2-form label { display: grid; gap: 6px; font-size: .85rem; font-weight: 600; }
.c2-form input {
  border: 1px solid var(--c2-line);
  border-radius: 12px;
  padding: 12px 14px;
  font: inherit;
  background: #f8fbff;
}
.c2-form button {
  margin-top: 6px;
  border: 0;
  border-radius: 12px;
  padding: 13px 16px;
  font: inherit;
  font-weight: 700;
  color: #fff;
  background: #0d47a1;
  cursor: pointer;
}
.c2-form button:hover { background: #0a3d91; }
.c2-alert {
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 14px;
  font-size: .9rem;
}
.c2-hint { margin: 16px 0 0; color: var(--c2-muted); font-size: .8rem; }
.c2-hint a { color: var(--c2-primary); }

.c2-app {
  height: 100%;
  display: flex;
  flex-direction: row;
  align-items: stretch;
  background: #eef2f7;
}
.c2-map-page { background: #e8eef5; }

/* ---- Menu azul (navegação) ---- */
.c2-nav {
  width: 248px;
  flex-shrink: 0;
  align-self: stretch;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  background: #0d47a1;
  color: #fff;
  z-index: 1300;
}
.c2-nav-brand {
  display: flex;
  align-items: center;
  padding: 18px 16px;
  border-bottom: 1px solid rgba(255,255,255,.12);
}
.c2-nav-logo-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  background: transparent;
  border-radius: 0;
  padding: 4px 2px;
}
.c2-nav-logo-img {
  display: block;
  width: auto;
  height: 38px;
  max-width: 100%;
  object-fit: contain;
}
.c2-nav-menu {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 14px 12px 18px;
  flex: 1;
  overflow: auto;
}
.c2-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  color: rgba(255, 255, 255, .62);
  text-decoration: none;
  font-size: .84rem;
  font-weight: 500;
  letter-spacing: .01em;
  transition: background .15s, color .15s;
}
.c2-nav-item svg {
  opacity: .85;
  flex-shrink: 0;
}
.c2-nav-item:hover {
  background: rgba(255, 255, 255, .08);
  color: rgba(255, 255, 255, .92);
}
.c2-nav-item:hover svg { opacity: 1; }
.c2-nav-item.is-active {
  background: rgba(255, 255, 255, .14);
  color: #fff;
  font-weight: 600;
}
.c2-nav-item.is-active svg { opacity: 1; }
.c2-nav-item[aria-disabled="true"] { opacity: .45; pointer-events: none; }

.c2-admin-grid {
  align-items: start;
}
.c2-count-inline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.5rem;
  height: 1.5rem;
  margin-left: 6px;
  padding: 0 6px;
  border-radius: 999px;
  background: #eef4fb;
  color: #0d47a1;
  font-size: .75rem;
  font-weight: 700;
  vertical-align: middle;
}
.c2-table-wrap {
  overflow-x: auto;
  margin-top: 8px;
}
.c2-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .88rem;
}
.c2-table th,
.c2-table td {
  padding: 10px 8px;
  text-align: left;
  border-bottom: 1px solid #e2e8f0;
  vertical-align: middle;
}
.c2-table th {
  color: var(--c2-muted);
  font-size: .72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.c2-table-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: flex-end;
  white-space: nowrap;
}
.c2-table-actions a {
  color: #0d47a1;
  font-weight: 600;
  text-decoration: none;
}
.c2-table-actions a:hover { text-decoration: underline; }
.c2-inline-form { display: inline; margin: 0; }
.c2-link-danger {
  border: 0;
  background: none;
  padding: 0;
  color: #b91c1c;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}
.c2-link-danger:hover { text-decoration: underline; }
.c2-check-fieldset {
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 12px 14px;
  margin: 0;
  display: grid;
  gap: 8px;
}
.c2-check-fieldset legend {
  padding: 0 4px;
  font-size: .85rem;
  font-weight: 600;
}
.c2-check {
  display: flex !important;
  align-items: center;
  gap: 8px;
  font-weight: 500 !important;
}
.c2-check input { width: auto; margin: 0; }

.c2-main-body {
  flex: 1;
  min-height: 0;
  overflow: auto;
  background: #eef2f7;
}
.c2-main-body.is-map {
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 0;
}
.c2-page {
  padding: 20px 24px 32px;
  max-width: 1100px;
}
.c2-lead {
  margin: 0 0 20px;
  color: var(--c2-muted);
  font-size: .95rem;
}
.c2-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}
.c2-kpi {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 14px 16px;
}
.c2-kpi p {
  margin: 0;
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #94a3b8;
}
.c2-kpi strong {
  display: block;
  margin-top: 2px;
  font-size: 1.4rem;
}
.c2-kpi-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.c2-kpi-icon.online { background: #ecfdf5; color: #059669; }
.c2-kpi-icon.offline { background: #f1f5f9; color: #94a3b8; }
.c2-kpi-icon.moving { background: #eff6ff; color: #2563eb; }
.c2-kpi-icon.pos { background: #eef4fb; color: #0d47a1; }
.c2-cards-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.c2-panel-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  padding: 22px;
}
.c2-panel-kicker {
  margin: 0;
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #94a3b8;
}
.c2-panel-card h2 {
  margin: 8px 0 8px;
  font-size: 1.2rem;
}
.c2-panel-card > p {
  margin: 0 0 16px;
  color: var(--c2-muted);
  font-size: .9rem;
  line-height: 1.45;
}
.c2-report-form {
  display: grid;
  gap: 12px;
}
.c2-report-form label {
  display: grid;
  gap: 6px;
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #94a3b8;
}
.c2-report-form input,
.c2-report-form select {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 11px 12px;
  font: inherit;
  font-size: .88rem;
  font-weight: 600;
  color: var(--c2-ink);
  text-transform: none;
  letter-spacing: 0;
  background: #fff;
}
.c2-report-range {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.c2-report-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.c2-report-result { margin-top: 16px; }
.c2-report-status {
  margin: 12px 0 0;
  font-size: .88rem;
  color: var(--c2-muted);
}
.c2-report-status.is-error { color: #b91c1c; }
.c2-btn-ghost {
  background: #fff;
  color: var(--c2-ink);
  border: 1px solid #e2e8f0;
}
.c2-btn-ghost:hover { background: #f8fafc; }
.c2-dl {
  margin: 0;
  display: grid;
  gap: 12px;
}
.c2-dl > div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: .9rem;
}
.c2-dl dt { color: var(--c2-muted); }
.c2-dl dd { margin: 0; font-weight: 700; text-align: right; }
.c2-note {
  margin: 16px 0 0;
  padding: 12px 14px;
  border-radius: 12px;
  background: #f8fafc;
  color: var(--c2-muted);
  font-size: .8rem;
}
.c2-flash {
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 16px;
  font-size: .9rem;
  font-weight: 600;
}
.c2-flash.ok { background: #ecfdf5; color: #047857; border: 1px solid #a7f3d0; }
.c2-flash.err { background: #fef2f2; color: #b91c1c; border: 1px solid #fecaca; }

/* ---- Área principal ---- */
.c2-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.c2-page-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 20px 10px;
  background: #f4f7fb;
  border-bottom: 1px solid #dde7f3;
  position: relative;
  z-index: 2000;
}
.c2-page-eyebrow {
  margin: 0;
  font-size: .65rem;
  font-weight: 500;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: #9aa8bc;
}
.c2-page-head h1 {
  margin: 3px 0 0;
  font-size: .98rem;
  font-weight: 600;
  letter-spacing: -.005em;
  color: #334155;
  line-height: 1.3;
}
.c2-page-head-actions {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}
.c2-status-online {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: .82rem;
  font-weight: 700;
  color: #047857;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  border-radius: 999px;
  padding: 6px 12px;
}
.c2-status-online i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  display: block;
  box-shadow: 0 0 0 0 rgba(16, 185, 129, .55);
  animation: c2-pulse-online 1.8s ease-out infinite;
}
@keyframes c2-pulse-online {
  0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, .55); }
  70% { box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
  100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}
.c2-user-menu {
  position: relative;
}
.c2-user-avatar {
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: #0d47a1;
  color: #fff;
  font: inherit;
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .02em;
  cursor: pointer;
  display: grid;
  place-items: center;
  box-shadow: 0 0 0 2px #fff, 0 0 0 3px #bfdbfe;
}
.c2-user-avatar:hover {
  background: #0a3d91;
}
.c2-user-avatar[aria-expanded="true"] {
  box-shadow: 0 0 0 2px #fff, 0 0 0 3px #0d47a1;
}
.c2-user-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 2100;
  min-width: 220px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  box-shadow: 0 14px 36px rgba(15, 23, 42, .14);
  padding: 10px;
}
.c2-user-dropdown[hidden] {
  display: none !important;
}
.c2-user-dropdown-meta {
  display: grid;
  gap: 2px;
  padding: 6px 8px 10px;
  border-bottom: 1px solid #eef2f7;
  margin-bottom: 8px;
}
.c2-user-dropdown-meta strong {
  font-size: .88rem;
  color: #0f172a;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.c2-user-dropdown-meta span {
  font-size: .75rem;
  color: #64748b;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.c2-user-dropdown-meta em {
  margin-top: 4px;
  font-style: normal;
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: #94a3b8;
}
.c2-user-dropdown-logout {
  display: block;
  border-radius: 10px;
  padding: 10px 12px;
  font-size: .88rem;
  font-weight: 700;
  color: #b91c1c;
  text-decoration: none;
}
.c2-user-dropdown-logout:hover {
  background: #fef2f2;
}
/* legado */
.c2-sys-ok {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: .82rem;
  font-weight: 700;
  color: #047857;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  border-radius: 999px;
  padding: 6px 12px;
}
.c2-sys-ok i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  display: block;
}

.c2-map-stage {
  position: relative;
  flex: 1;
  min-height: 0;
}
.c2-map { width: 100%; height: 100%; background: #dbe4ef; }

.is-hidden { display: none !important; }
.min-w-0 { min-width: 0; }

.c2-icon-btn {
  border: 0;
  background: transparent;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  color: var(--c2-muted);
  cursor: pointer;
  font-size: 1rem;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.c2-icon-btn:hover { background: #f1f5f9; color: var(--c2-ink); }

/* ---- Painel frota flutuante ---- */
.c2-fleet-panel {
  position: absolute;
  left: 16px;
  top: 16px;
  z-index: 1100;
  width: min(340px, calc(100% - 2rem));
  max-height: calc(100% - 2rem);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: rgba(255,255,255,.96);
  border: 1px solid rgba(148,163,184,.25);
  border-radius: 18px;
  box-shadow: 0 18px 40px rgba(15, 23, 42, .12);
  backdrop-filter: blur(12px);
}
.c2-fleet-panel.is-collapsed .c2-fleet-collapse { display: none; }
.c2-fleet-panel.is-collapsed #fleetToggleIcon { transform: rotate(180deg); }
.c2-fleet-head { padding: 16px 16px 0; }
.c2-fleet-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 12px;
}
.c2-fleet-title-row h2 {
  margin: 0;
  font-size: .95rem;
  font-weight: 700;
  letter-spacing: -.015em;
  color: #0f172a;
}
.c2-fleet-total {
  font-weight: 500;
  color: #64748b;
  letter-spacing: 0;
}
#fleetToggleIcon { transition: transform .2s ease; }
.c2-filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0 10px;
}
.c2-filter-chip {
  appearance: none;
  border: 1.5px solid transparent;
  border-radius: 999px;
  padding: 5px 10px;
  background: #fff;
  font: inherit;
  font-size: .68rem;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  transition: background .15s ease, color .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.c2-filter-chip.is-moving {
  border-color: #1e3a8a;
  color: #1e3a8a;
}
.c2-filter-chip.is-stopped,
.c2-filter-chip.is-ignition {
  border-color: #16a34a;
  color: #15803d;
}
.c2-filter-chip.is-offline {
  border-color: #ef4444;
  color: #dc2626;
}
.c2-filter-chip.is-battery {
  border-color: #f59e0b;
  color: #d97706;
}
.c2-filter-chip:hover {
  box-shadow: 0 1px 4px rgba(15, 23, 42, .08);
}
.c2-filter-chip.is-active.is-moving {
  background: #1e3a8a;
  border-color: #1e3a8a;
  color: #fff;
}
.c2-filter-chip.is-active.is-stopped,
.c2-filter-chip.is-active.is-ignition {
  background: #16a34a;
  border-color: #16a34a;
  color: #fff;
}
.c2-filter-chip.is-active.is-offline {
  background: #ef4444;
  border-color: #ef4444;
  color: #fff;
}
.c2-filter-chip.is-active.is-battery {
  background: #f59e0b;
  border-color: #f59e0b;
  color: #fff;
}
.c2-fleet-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}
.c2-fleet-toolbar .c2-search-wrap {
  flex: 1;
  min-width: 0;
  margin-bottom: 0;
}
.c2-live {
  margin-left: 0;
  flex-shrink: 0;
  border-radius: 999px;
  padding: 4px 9px;
  background: #e8f0fe;
  color: var(--c2-primary);
  letter-spacing: .04em;
  transition: transform .2s ease;
  font-size: .65rem;
  font-weight: 700;
}
.c2-live.is-pulse { transform: scale(1.05); }
.c2-search-wrap {
  position: relative;
  margin-bottom: 12px;
}
.c2-search-wrap svg {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  pointer-events: none;
}
.c2-search-wrap input {
  width: 100%;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 11px 12px 11px 36px;
  font: inherit;
  font-size: .88rem;
  font-weight: 600;
  outline: none;
  background: #fff;
}
.c2-search-wrap input:focus {
  border-color: #93c5fd;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, .1);
}
.c2-fleet-scroll {
  min-height: 0;
  flex: 1;
  overflow-y: auto;
  border-top: 1px solid #f1f5f9;
}

/* Lista limpa — linhas com divisória, sem cards empilhados */
.c2-fleet-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.c2-fleet-list > li {
  margin: 0;
  padding: 0;
  border-bottom: 1px solid #f1f5f9;
}
.c2-fleet-list > li:last-child { border-bottom: 0; }
.c2-fleet-item {
  display: flex;
  width: 100%;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 16px;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
  font: inherit;
  color: inherit;
  transition: background .12s;
}
.c2-fleet-item:hover { background: #f8fafc; }
.c2-fleet-item.is-active { background: #eef4fb; }
.c2-fleet-item .c2-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 6px;
}
.c2-dot.online { background: #10b981; }
.c2-dot.moving { background: #2563eb; }
.c2-dot.offline { background: #cbd5e1; }
.c2-fleet-item .meta {
  min-width: 0;
  flex: 1;
}
.c2-fleet-item .meta-top {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.c2-fleet-item .meta-top strong {
  font-size: .9rem;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.c2-fleet-item .meta-sub {
  display: block;
  margin-top: 3px;
  color: #94a3b8;
  font-size: .75rem;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.c2-fleet-empty {
  margin: 0;
  padding: 28px 16px;
  text-align: center;
  color: var(--c2-muted);
  font-size: .88rem;
}

.c2-card-plate {
  background: #1e293b;
  color: #fff;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: .65rem;
  font-weight: 600;
  letter-spacing: .06em;
  padding: 2px 6px;
  border-radius: 4px;
  flex-shrink: 0;
  line-height: 1.3;
}

.c2-btn {
  border: 0;
  border-radius: 12px;
  padding: 11px 16px;
  font: inherit;
  font-weight: 800;
  font-size: .88rem;
  color: #fff;
  background: #0f172a;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.c2-btn:hover { background: #1e293b; }
.c2-btn:disabled { opacity: .6; cursor: wait; }
.c2-btn-block { width: 100%; justify-content: center; background: #0d47a1; }
.c2-btn-block:hover { background: #0a3d91; }
.c2-btn-history { background: #0f172a; }

.c2-vehicle-card {
  position: absolute;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  z-index: 1100;
  width: min(700px, calc(100% - 1.5rem));
  background: rgba(255, 255, 255, .97);
  border: 1px solid rgba(148,163,184,.25);
  border-radius: 18px;
  padding: 18px 20px;
  box-shadow: 0 18px 40px rgba(15, 23, 42, .14);
  backdrop-filter: blur(12px);
}
.c2-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.c2-card-identity {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.c2-card-identity strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: .95rem;
}
.c2-card-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #94a3b8;
  flex-shrink: 0;
}
.c2-card-updated {
  margin: 8px 0 0;
  color: #94a3b8;
  font-size: .75rem;
}
.c2-card-address {
  margin: 4px 0 0;
  color: #64748b;
  font-size: .8rem;
  font-weight: 600;
}
.c2-card-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 14px;
}
.c2-card-stats-4 { grid-template-columns: repeat(4, 1fr); }
.c2-card-stats > div,
.c2-stat {
  background: #f8fafc;
  border-radius: 12px;
  padding: 10px 8px;
  text-align: center;
}
.c2-card-stats span,
.c2-stat-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  font-size: .62rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #94a3b8;
}
.c2-ignition {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.c2-ignition.is-on { color: #15803d; }
.c2-ignition.is-off { color: #64748b; }
.c2-motion {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.c2-motion .c2-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin: 0;
}
.c2-card-stats strong {
  display: block;
  margin-top: 4px;
  font-size: 1rem;
}
.c2-card-stats em { font-style: normal; }
.c2-card-stats small {
  font-size: .7rem;
  font-weight: 700;
  color: #94a3b8;
}
.c2-mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: .72rem !important;
  font-weight: 700;
  line-height: 1.35;
  word-break: break-all;
}
.c2-card-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 14px;
}
.c2-btn-danger {
  background: #e11d48;
}
.c2-btn-danger:hover { background: #be123c; }
.c2-btn-success {
  background: #059669;
}
.c2-btn-success:hover { background: #047857; }
.c2-block-modal {
  position: absolute;
  inset: 0;
  z-index: 1500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(15, 23, 42, .45);
  backdrop-filter: blur(4px);
}
.c2-block-modal.hidden { display: none !important; }
.c2-block-dialog {
  width: min(420px, 100%);
  background: #fff;
  border-radius: 18px;
  padding: 20px;
  box-shadow: 0 24px 48px rgba(15, 23, 42, .2);
}
.c2-block-dialog-top {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}
.c2-block-icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  flex-shrink: 0;
}
.c2-block-icon.is-block {
  background: #ffe4e6;
  color: #e11d48;
}
.c2-block-icon.is-unblock {
  background: #d1fae5;
  color: #059669;
}
.c2-block-dialog h2 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 750;
  color: #0f172a;
}
.c2-block-dialog p {
  margin: 6px 0 0;
  font-size: .88rem;
  line-height: 1.45;
  color: #64748b;
}
.c2-block-dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 18px;
}
[data-map-toast],
.c2-map-toast {
  position: absolute;
  top: auto;
  left: 50%;
  right: auto;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 1600;
  width: max-content;
  max-width: min(420px, calc(100% - 2rem));
  height: auto;
  max-height: none;
  margin: 0;
  padding: 10px 14px;
  border-radius: 12px;
  border: 0;
  background: #0f172a;
  color: #fff;
  font-size: .82rem;
  font-weight: 600;
  line-height: 1.35;
  box-shadow: 0 12px 28px rgba(15, 23, 42, .28);
  pointer-events: none;
}
.c2-map-toast.is-error,
[data-map-toast].is-error {
  background: #fff1f2;
  color: #be123c;
  border: 1px solid #fecdd3;
  pointer-events: auto;
}

.c2-history-panel {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 1200;
  width: min(380px, calc(100% - 1.5rem));
  max-height: calc(100% - 2rem);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: rgba(255, 255, 255, .97);
  border: 1px solid rgba(148,163,184,.25);
  border-radius: 18px;
  box-shadow: 0 18px 40px rgba(15, 23, 42, .14);
  backdrop-filter: blur(12px);
  padding: 16px;
}
.c2-history-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}
.c2-history-label {
  margin: 0 0 6px;
  font-size: .62rem;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--c2-primary);
}
.c2-history-presets {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-top: 14px;
}
.c2-history-presets button {
  border: 1px solid #e2e8f0;
  background: #fff;
  border-radius: 10px;
  padding: 8px 4px;
  font: inherit;
  font-size: .72rem;
  font-weight: 800;
  cursor: pointer;
  color: var(--c2-ink);
}
.c2-history-presets button:hover {
  border-color: #93c5fd;
  color: var(--c2-primary);
}
.c2-history-range {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 12px 0;
}
.c2-history-range label {
  display: grid;
  gap: 4px;
  font-size: .62rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #94a3b8;
}
.c2-history-range input {
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 8px;
  font: inherit;
  font-size: .75rem;
  font-weight: 600;
  color: var(--c2-ink);
  text-transform: none;
  letter-spacing: 0;
}
.c2-history-body {
  margin-top: 14px;
  overflow: auto;
  min-height: 0;
}
.c2-history-status {
  margin: 0;
  text-align: center;
  color: var(--c2-muted);
  font-size: .88rem;
}
.c2-history-status.is-error { color: #b91c1c; }
.c2-history-stats { grid-template-columns: 1fr 1fr; }
.c2-history-points {
  margin: 12px 0 0;
  text-align: center;
  color: var(--c2-muted);
  font-size: .75rem;
}
.c2-history-endpoint {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 3px solid #fff;
  color: #fff;
  font: 800 11px/1 var(--font);
  box-shadow: 0 4px 12px rgba(15, 23, 42, .35);
}

.c2-marker {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  transform: translateY(-8px);
}
.c2-marker-img {
  position: relative;
  filter: drop-shadow(0 6px 8px rgba(15, 23, 42, .35));
}
.c2-marker-img img { display: block; width: 100%; height: 100%; object-fit: contain; }
.c2-marker-badge {
  position: absolute;
  right: -3px;
  top: -2px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 3px solid #fff;
  box-shadow: 0 2px 5px rgba(15,23,42,.3);
}
.c2-marker-plate {
  background: #0f172a;
  color: #fff;
  font: 800 10px/1 ui-monospace, monospace;
  letter-spacing: .08em;
  padding: 3px 6px;
  border-radius: 6px;
  white-space: nowrap;
  box-shadow: 0 3px 10px rgba(15,23,42,.3);
}
.c2-marker-fallback {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 3px solid #fff;
  box-shadow: 0 4px 12px rgba(15,23,42,.3);
}

@media (max-width: 1100px) {
  .c2-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .c2-cards-grid { grid-template-columns: 1fr; }
}

@media (max-width: 960px) {
  .c2-nav { width: 76px; }
  .c2-nav-item span { display: none; }
  .c2-nav-item { justify-content: center; padding: 12px; }
  .c2-nav-item svg { margin: 0; }
  .c2-nav-brand { padding: 12px 8px; }
  .c2-nav-logo-wrap { padding: 8px; }
  .c2-nav-logo-img { height: 22px; }
  .c2-card-stats-4 { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
  .c2-app { flex-direction: column; }
  .c2-nav {
    width: 100%;
    min-height: 0;
    flex-direction: row;
    align-items: center;
    overflow-x: auto;
  }
  .c2-nav-menu { flex-direction: row; padding: 8px; flex: 1; }
  .c2-fleet-panel {
    left: 10px;
    right: 10px;
    width: auto;
    max-height: 42%;
  }
  .c2-vehicle-card { bottom: 10px; padding: 14px; }
  .c2-history-panel {
    top: auto;
    bottom: 12px;
    left: 12px;
    right: 12px;
    width: auto;
    max-height: 55%;
  }
}

/* Relatórios inteligentes */
.c2-reports-page .c2-reports-kpi {
  margin-bottom: 18px;
}
.c2-report-types {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}
.c2-report-type {
  display: grid;
  gap: 4px;
  text-align: left;
  padding: 14px 16px;
  border: 1.5px solid #e2e8f0;
  border-radius: 14px;
  background: #fff;
  cursor: pointer;
  font: inherit;
  color: inherit;
  transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
.c2-report-type strong {
  font-size: .92rem;
  font-weight: 750;
  color: #0f172a;
}
.c2-report-type span {
  font-size: .78rem;
  color: #64748b;
  line-height: 1.35;
}
.c2-report-type:hover {
  border-color: #93c5fd;
  box-shadow: 0 4px 14px rgba(13, 71, 161, .08);
}
.c2-report-type.is-active {
  border-color: #0d47a1;
  background: #eef4fb;
  box-shadow: 0 0 0 1px #0d47a1 inset;
}
.c2-report-type-link {
  text-decoration: none;
}
.c2-report-panel {
  margin-top: 4px;
}
.c2-report-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}
.c2-report-presets button {
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  color: #334155;
  border-radius: 999px;
  padding: 5px 11px;
  font: inherit;
  font-size: .75rem;
  font-weight: 650;
  cursor: pointer;
}
.c2-report-presets button:hover {
  border-color: #93c5fd;
  color: #0d47a1;
  background: #eff6ff;
}
.c2-report-controls {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.c2-report-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 10px;
  margin: 16px 0;
}
.c2-report-kpi-item {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 12px 14px;
}
.c2-report-kpi-item span {
  display: block;
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: #94a3b8;
  margin-bottom: 4px;
}
.c2-report-kpi-item strong {
  font-size: 1.15rem;
  font-weight: 750;
  color: #0f172a;
}
.c2-report-kpi-item small {
  font-size: .75rem;
  font-weight: 600;
  color: #64748b;
}
.c2-report-map-wrap {
  margin: 8px 0 16px;
}
.c2-report-map {
  height: 360px;
  border-radius: 14px;
  border: 1px solid #e2e8f0;
  overflow: hidden;
  background: #dbe4ef;
}
.c2-report-map-legend {
  margin: 8px 0 0;
  font-size: .78rem;
  color: #64748b;
}
.c2-btn-pdf {
  background: #0d47a1;
}
.c2-btn-pdf:hover { background: #0a3d91; }
.c2-km-hero {
  margin: 8px 0 18px;
  border-radius: 18px;
  border: 1px solid #c9daf0;
  background: #fff;
  box-shadow: 0 10px 28px rgba(13, 71, 161, .08);
  overflow: hidden;
}
.c2-km-hero-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 22px 18px;
  background:
    linear-gradient(135deg, #0d47a1 0%, #1565c0 55%, #1e88e5 100%);
  color: #fff;
}
.c2-km-hero-kicker {
  margin: 0 0 6px;
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .72);
}
.c2-km-hero-label {
  margin: 0 0 6px;
  font-size: .9rem;
  font-weight: 600;
  color: rgba(255, 255, 255, .9);
}
.c2-km-hero-value {
  margin: 0;
  font-size: 2.55rem;
  font-weight: 800;
  letter-spacing: -.04em;
  color: #fff;
  line-height: 1.05;
}
.c2-km-hero-value em {
  font-style: normal;
}
.c2-km-hero-value small {
  font-size: 1rem;
  font-weight: 700;
  color: rgba(255, 255, 255, .78);
  margin-left: 2px;
}
.c2-km-hero-badge {
  flex: 0 0 auto;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .06em;
  color: #0d47a1;
  background: rgba(255, 255, 255, .95);
  box-shadow: 0 6px 16px rgba(0, 0, 0, .12);
}
.c2-km-hero-meta {
  display: grid;
  grid-template-columns: 1.6fr .6fr 1fr;
  gap: 0;
  background: #f8fbff;
  border-top: 1px solid #dbe7f5;
}
.c2-km-hero-meta-item {
  padding: 14px 18px;
  border-right: 1px solid #e2e8f0;
  min-width: 0;
}
.c2-km-hero-meta-item:last-child {
  border-right: 0;
}
.c2-km-hero-meta-item span {
  display: block;
  font-size: .68rem;
  font-weight: 750;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: #94a3b8;
  margin-bottom: 4px;
}
.c2-km-hero-meta-item strong {
  display: block;
  font-size: .92rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.35;
  word-break: break-word;
}
@media (max-width: 720px) {
  .c2-km-hero-value { font-size: 2rem; }
  .c2-km-hero-meta {
    grid-template-columns: 1fr;
  }
  .c2-km-hero-meta-item {
    border-right: 0;
    border-bottom: 1px solid #e2e8f0;
  }
  .c2-km-hero-meta-item:last-child {
    border-bottom: 0;
  }
}
.c2-report-sections {
  display: grid;
  gap: 22px;
  margin: 8px 0 16px;
}
.c2-report-section h3 {
  margin: 0 0 10px;
  font-size: 1rem;
  color: #0f172a;
}
.c2-report-section-note {
  margin: -4px 0 10px;
  font-size: .78rem;
  color: #64748b;
}
.c2-report-section .c2-table-wrap {
  margin: 0;
}
@media (max-width: 980px) {
  .c2-report-types { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .c2-report-controls { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .c2-report-types { grid-template-columns: 1fr; }
  .c2-report-controls { grid-template-columns: 1fr; }
  .c2-report-map { height: 280px; }
}
