﻿:root {
  --bg: #06111f;
  --bg2: #020814;
  --card: rgba(9, 28, 52, .78);
  --card2: rgba(12, 38, 69, .92);
  --text: #ffffff;
  --muted: #9fb3c9;
  --line: rgba(120, 170, 230, .18);
  --blue: #0a84ff;
  --blue2: #45c7ff;
  --green: #35d96b;
  --red: #ff4d55;
  --orange: #ff9f0a;
  --purple: #9b5cff;
  --gold: #ffd34d;
  --cyan: #30d5ff;
  --shadow: 0 24px 60px rgba(0,0,0,.42);
}

body.light {
  --bg: #f5f8ff;
  --bg2: #eaf2ff;
  --card: rgba(255,255,255,.86);
  --card2: rgba(255,255,255,.96);
  --text: #0f172a;
  --muted: #58708c;
  --line: rgba(15, 23, 42, .12);
  --shadow: 0 18px 42px rgba(30, 64, 120, .16);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 15% 0%, rgba(10,132,255,.22), transparent 28%),
    radial-gradient(circle at 85% 8%, rgba(155,92,255,.14), transparent 28%),
    linear-gradient(180deg, var(--bg), var(--bg2));
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.hidden { display: none !important; }

.login-bg {
  position: fixed;
  inset: 0;
  z-index: -2;
  overflow: hidden;
  background: #000;
}

.login-bg .slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transform: scale(1.06);
  transition: opacity 1.4s ease-in-out, transform 5s ease;
}

.login-bg .slide.active { opacity: .62; transform: scale(1); }

.login-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0,8,20,.96), rgba(0,18,40,.82), rgba(0,8,20,.68));
}

.login-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 28px;
}

.login-card {
  width: min(100%, 460px);
  padding: 28px;
  border-radius: 32px;
  background: rgba(10,28,52,.76);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  backdrop-filter: blur(22px);
}

.app-shell {
  display: grid;
  grid-template-columns: 250px 1fr;
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 22px 18px;
  border-right: 1px solid var(--line);
  background: rgba(3, 15, 31, .58);
  backdrop-filter: blur(24px);
}

.main {
  padding: 20px 24px 34px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.brand-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-logo {
  width: 58px;
  min-width: 58px;
  height: 34px;
  filter: drop-shadow(0 10px 18px rgba(69,199,255,.22));
}

.brand-logo svg { width: 100%; height: auto; overflow: visible; }

.truck-body { fill: #58c7ff; stroke: #050507; stroke-width: 6; stroke-linejoin: round; }
.truck-window { fill: rgba(255,255,255,.92); stroke: #050507; stroke-width: 5; stroke-linejoin: round; }
.truck-tail { fill: #ff2d8f; stroke: #050507; stroke-width: 4; }
.truck-light { fill: #fff7a8; stroke: #050507; stroke-width: 4; }
.wheel { fill: #8f8f94; stroke: #050507; stroke-width: 6; }
.wheel-inner { fill: #fff; stroke: #050507; stroke-width: 3; }
.truck-text { fill: #fff; font-size: 22px; font-weight: 900; font-family: Arial, sans-serif; letter-spacing: -.7px; }

.brand-title {
  font-size: 22px;
  font-weight: 950;
  letter-spacing: -.8px;
  line-height: .95;
  white-space: nowrap;
}

.brand-sub {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.theme-toggle {
  width: auto;
  min-width: 96px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 9px 12px;
  border-radius: 18px;
  box-shadow: none;
}

.theme-dot {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 0 0 4px rgba(10,132,255,.24);
}

.profile-mini {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 20px;
  background: var(--card);
  border: 1px solid var(--line);
}

.avatar {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #58c7ff, #7c4dff);
  font-weight: 900;
  color: #fff;
}

.notification {
  position: relative;
  width: 42px;
  height: 42px;
  border-radius: 16px;
  background: var(--card);
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
}

.badge {
  position: absolute;
  top: -7px;
  right: -7px;
  min-width: 22px;
  height: 22px;
  border-radius: 999px;
  background: linear-gradient(180deg, #ff6b72, #e02d3a);
  color: #fff;
  font-size: 12px;
  display: grid;
  place-items: center;
  font-weight: 900;
  box-shadow: 0 8px 18px rgba(255,77,85,.32);
}

.nav {
  margin-top: 26px;
  display: grid;
  gap: 8px;
}

.nav-item {
  position: relative;
  border: 0;
  border-radius: 14px;
  padding: 13px 14px;
  background: transparent;
  color: var(--muted);
  font-weight: 750;
  text-align: left;
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}

.nav-item.active,
.nav-item:hover {
  color: var(--text);
  background: rgba(10,132,255,.20);
}

.nav-badge {
  margin-left: auto;
  background: var(--red);
  color: #fff;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 900;
}

.help-box {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 22px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--card);
  color: var(--muted);
}

.page { display: none; }
.page.active { display: block; animation: pageIn .22s ease-out; }

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

.card {
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 26px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(22px);
}

.card-pad { padding: 20px; }

h1, h2, h3, p { margin-top: 0; }
h1 { font-size: 28px; letter-spacing: -.8px; }
h2 { font-size: 24px; letter-spacing: -.6px; }
h3 { font-size: 18px; letter-spacing: -.4px; }
.small, .muted { color: var(--muted); font-size: 13px; line-height: 1.45; }

button {
  border: 0;
  border-radius: 16px;
  padding: 13px 16px;
  background: linear-gradient(180deg, #1990ff, #0672e8);
  color: white;
  font-weight: 850;
  cursor: pointer;
  box-shadow: 0 14px 26px rgba(10,132,255,.22);
}

button.secondary {
  background: rgba(255,255,255,.06);
  border: 1px solid var(--line);
  box-shadow: none;
}

button.green { background: linear-gradient(180deg, #42e075, #21a74d); }
button.red { background: linear-gradient(180deg, #ff6068, #d92c38); }
button.orange { background: linear-gradient(180deg, #ffb340, #ef8300); }
button.purple { background: linear-gradient(180deg, #a36bff, #6f40d8); }

input {
  width: 100%;
  padding: 15px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.09);
  color: var(--text);
  margin: 8px 0;
  outline: none;
  font-size: 15px;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: 18px;
}

.hero {
  min-height: 250px;
  padding: 20px;
  overflow: hidden;
  position: relative;
  background:
    linear-gradient(90deg, rgba(5,20,42,.98) 0%, rgba(5,20,42,.78) 45%, rgba(5,20,42,.10) 100%),
    url("assets/imagens/imagem1.jpg");
  background-size: cover;
  background-position: center right;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 11px;
  border-radius: 999px;
  font-weight: 850;
  font-size: 12px;
  background: rgba(10,132,255,.16);
  color: #6cc7ff;
}

.pill.red { background: rgba(255,77,85,.18); color: #ff7982; }
.pill.green { background: rgba(53,217,107,.16); color: #5cff8b; }
.pill.gold { background: rgba(255,211,77,.16); color: #ffd34d; }
.pill.purple { background: rgba(155,92,255,.16); color: #b995ff; }

.route-title {
  font-size: 30px;
  font-weight: 950;
  margin: 16px 0 12px;
}

.info-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  color: #d8e8ff;
  margin-bottom: 18px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.stat-card {
  padding: 16px;
  min-height: 130px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 20px;
}

.stat-icon { font-size: 28px; margin-bottom: 12px; }
.stat-value { font-size: 24px; font-weight: 950; }
.positive { color: var(--green); }
.negative { color: var(--red); }
.gold { color: var(--gold); }

.module-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
  margin: 18px 0;
}

.module-card {
  min-height: 160px;
  padding: 18px;
  position: relative;
  overflow: hidden;
}

.module-card .icon { font-size: 38px; margin-bottom: 18px; }
.module-card h3 { margin-bottom: 6px; }
.module-card .arrow { position: absolute; right: 16px; bottom: 16px; }

.blue-card { background: linear-gradient(135deg, rgba(10,132,255,.38), rgba(7,30,65,.88)); }
.green-card { background: linear-gradient(135deg, rgba(53,217,107,.30), rgba(7,40,28,.88)); }
.gold-card { background: linear-gradient(135deg, rgba(255,211,77,.28), rgba(54,39,7,.88)); }
.purple-card { background: linear-gradient(135deg, rgba(155,92,255,.34), rgba(25,13,62,.88)); }
.orange-card { background: linear-gradient(135deg, rgba(255,159,10,.30), rgba(54,25,5,.88)); }
.cyan-card { background: linear-gradient(135deg, rgba(48,213,255,.28), rgba(5,45,58,.88)); }

.trip-grid {
  display: grid;
  grid-template-columns: .42fr .58fr;
  gap: 18px;
}

.trip-panel {
  padding: 20px;
  background:
    linear-gradient(90deg, rgba(5,20,42,.98), rgba(5,20,42,.72)),
    url("assets/imagens/imagem2.jpg");
  background-size: cover;
  background-position: center right;
}

.trip-layout {
  display: grid;
  grid-template-columns: 190px 1fr 1fr 190px;
  gap: 16px;
  align-items: stretch;
}

.trip-point {
  border-left: 3px solid rgba(155,92,255,.7);
  padding-left: 15px;
  margin: 15px 0;
}

.field {
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.field .label { color: var(--muted); font-size: 12px; }
.field .value { font-size: 18px; font-weight: 900; margin-top: 4px; }

.schedule, .weather-box {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255,255,255,.05);
}

.weather-temp { font-size: 32px; font-weight: 950; }

.bonus-grid {
  display: grid;
  grid-template-columns: 250px 1fr;
  gap: 18px;
}

.ring {
  width: 190px;
  height: 190px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  margin: 10px auto;
  background: conic-gradient(var(--green) 0 72%, rgba(255,255,255,.12) 72% 100%);
  position: relative;
}

.ring::after {
  content: "";
  position: absolute;
  inset: 14px;
  border-radius: inherit;
  background: #07162a;
}

.ring > div {
  position: relative;
  z-index: 2;
  text-align: center;
}

.ring strong { font-size: 34px; }

.extract-list {
  display: grid;
  gap: 10px;
}

.extract-item {
  display: grid;
  grid-template-columns: 40px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 11px;
  border-radius: 16px;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.06);
}

.round-icon {
  width: 40px;
  height: 40px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: rgba(10,132,255,.18);
}

.security-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 14px;
}

.message-row, .audio-row, .pdf-row, .quick-row {
  display: grid;
  grid-template-columns: 38px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 10px;
  border-radius: 16px;
  background: rgba(255,255,255,.045);
  margin-top: 8px;
}

.banner {
  margin-top: 18px;
  padding: 18px;
  border-radius: 24px;
  border: 1px solid rgba(53,217,107,.30);
  background: linear-gradient(90deg, rgba(53,217,107,.16), rgba(10,132,255,.08));
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.page-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}

.back-home {
  width: auto;
  box-shadow: none;
  background: rgba(255,255,255,.06);
  border: 1px solid var(--line);
}

@media (max-width: 1200px) {
  .app-shell { grid-template-columns: 1fr; }
  .sidebar { position: static; height: auto; display: none; }
  .main { padding: 16px; }
  .dashboard-grid, .trip-grid, .bonus-grid, .security-grid { grid-template-columns: 1fr; }
  .module-grid { grid-template-columns: repeat(2, 1fr); }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .trip-layout { grid-template-columns: 1fr; }
}

.brand-title span {
  display: inline-block;
  font-size: 19px;
  opacity: .96;
}

.sidebar .brand-wrap {
  align-items: center;
  gap: 10px;
}

.sidebar .brand-title {
  font-size: 20px;
}

.sidebar .brand-title span {
  font-size: 18px;
}

.truck-text {
  display: none;
}

/* 1554-32-AJUSTES-VISUAIS */
body:not(.light) {
  color: #f8fbff;
}

body:not(.light) .small,
body:not(.light) .muted {
  color: #d3e3f7 !important;
}

body:not(.light) .card,
body:not(.light) .stat-card,
body:not(.light) .schedule,
body:not(.light) .weather-box,
body:not(.light) .message-row,
body:not(.light) .audio-row,
body:not(.light) .pdf-row,
body:not(.light) .quick-row {
  color: #f8fbff;
}

body.light {
  color: #0f172a;
}

body.light .small,
body.light .muted {
  color: #38506b !important;
}

body.light .card:not(.module-card):not(.hero):not(.trip-panel),
body.light .stat-card,
body.light .schedule,
body.light .weather-box,
body.light .message-row,
body.light .audio-row,
body.light .pdf-row,
body.light .quick-row {
  background: rgba(255,255,255,.92) !important;
  color: #0f172a !important;
}

body.light .sidebar {
  background: rgba(236,245,255,.94) !important;
}

body.light .nav-item {
  color: #1e293b !important;
}

body.light .nav-item.active,
body.light .nav-item:hover {
  color: #ffffff !important;
}

.module-card,
.hero,
.trip-panel {
  color: #ffffff !important;
}

.module-card .small,
.hero .small,
.trip-panel .small {
  color: rgba(255,255,255,.86) !important;
}

.brand-logo {
  width: 78px !important;
  min-width: 78px !important;
  height: auto !important;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 180 / 78;
}

.brand-logo svg {
  width: 78px !important;
  height: auto !important;
  max-height: 40px !important;
  overflow: visible !important;
  object-fit: contain !important;
}

.sidebar .brand-logo {
  width: 74px !important;
  min-width: 74px !important;
}

.sidebar .brand-wrap {
  align-items: center !important;
  gap: 10px !important;
  flex-wrap: nowrap !important;
}

.brand-title {
  line-height: .98 !important;
  white-space: nowrap !important;
}

.brand-title span {
  color: inherit;
  display: inline-block;
}

.truck-text {
  display: none !important;
}

.support-email {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: #ffffff;
  background: linear-gradient(180deg, #1990ff, #0672e8);
  padding: 10px 14px;
  border-radius: 14px;
  font-weight: 900;
  margin-top: 8px;
}

.logout-btn {
  min-width: 72px;
  box-shadow: none !important;
}

.notification {
  cursor: pointer;
}

.sw-footer {
  margin: 26px 0 4px;
  padding: 18px;
  text-align: center;
  color: var(--muted);
  font-weight: 800;
  letter-spacing: .2px;
  border-top: 1px solid var(--line);
}

.sw-w {
  color: #35a7ff;
  font-weight: 950;
}

.sw-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(0, 8, 20, .72);
  backdrop-filter: blur(10px);
}

.sw-modal {
  width: min(720px, 100%);
  border-radius: 26px;
  background: rgba(8, 26, 48, .96);
  color: #ffffff;
  border: 1px solid rgba(120, 170, 230, .26);
  box-shadow: 0 28px 80px rgba(0,0,0,.5);
  overflow: hidden;
}

body.light .sw-modal {
  background: rgba(255,255,255,.98);
  color: #0f172a;
}

.sw-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--line);
}

.sw-modal-head h2 {
  margin: 0;
}

.sw-modal-body {
  padding: 20px;
  line-height: 1.55;
}

.sw-modal-close {
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 999px;
  font-size: 26px;
  line-height: 1;
  box-shadow: none;
  background: rgba(255,255,255,.08);
}

@media (max-width: 720px) {
  .brand-logo,
  .brand-logo svg {
    width: 62px !important;
  }

  .header-actions {
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .logout-btn {
    min-width: 64px;
  }
}

.brand-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
}

.truck-logo {
  width: 74px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0 10px 18px rgba(0,122,255,.22));
}

.truck-logo svg {
  width: 100%;
  height: auto;
  overflow: visible;
}

.truck-body {
  fill: #58c7ff;
  stroke: #050507;
  stroke-width: 6;
  stroke-linejoin: round;
}

.truck-window {
  fill: rgba(255,255,255,.9);
  stroke: #050507;
  stroke-width: 5;
  stroke-linejoin: round;
}

.truck-tail {
  fill: #ff2d8f;
  stroke: #050507;
  stroke-width: 4;
}

.truck-light {
  fill: #fff7a8;
  stroke: #050507;
  stroke-width: 4;
}

.wheel {
  fill: #8f8f94;
  stroke: #050507;
  stroke-width: 6;
}

.wheel-inner {
  fill: #ffffff;
  stroke: #050507;
  stroke-width: 3;
}

.truck-text {
  fill: #ffffff;
  font-size: 22px;
  font-weight: 900;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  letter-spacing: -.7px;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 92px;
  justify-content: center;
}

.theme-dot {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: #ffffff;
  box-shadow: 0 0 0 4px rgba(0,122,255,.22);
}

@media (max-width: 420px) {
  .truck-logo {
    width: 58px;
  }

  .brand {
    font-size: 20px;
  }

  .brand-wrap {
    gap: 8px;
  }
}
