/* Navegação 3D do motorista (tela cheia). Cores do projeto: grafite, claro e escuro. */
html.n3d-open, html.n3d-open body { overflow: hidden; overscroll-behavior: none; }
.n3d { --n-bg: #151618; --n-fill: #1f2124; --n-tx: #f1f2f3; --n-mut: #9aa0a6; --n-ln: rgba(255,255,255,.12); --n-acc: #f1f2f3; --n-acc-tx: #151618;
  position: fixed; inset: 0; z-index: 9000; background: var(--n-bg); color: var(--n-tx); font-family: inherit; }
html[data-theme="light"] .n3d { --n-bg: #e9ebed; --n-fill: #ffffff; --n-tx: #1d1f22; --n-mut: #5d646b; --n-ln: rgba(0,0,0,.12); --n-acc: #2a2d31; --n-acc-tx: #ffffff; }
/* !important: o CSS do MapLibre (carregado depois) manda .maplibregl-map { position: relative } e o mapa ficaria com altura zero */
.n3d .n3d-map { position: absolute !important; inset: 0; width: 100%; height: 100%; }
.n3d-map .maplibregl-canvas { outline: none; }
.n3d-top { position: absolute; left: 12px; right: 12px; top: max(12px, env(safe-area-inset-top)); display: flex; align-items: center; gap: 14px; padding: 12px 16px;
  background: var(--n-fill); border: 1px solid var(--n-ln); border-radius: 20px; box-shadow: 0 10px 30px rgba(0,0,0,.28); }
.n3d-ar { flex: none; width: 56px; height: 56px; border-radius: 16px; background: var(--n-acc); color: var(--n-acc-tx); display: grid; place-items: center; transition: transform .25s ease; }
.n3d-tx { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.n3d-dist { font-size: 26px; line-height: 1.1; font-weight: 600; letter-spacing: -.01em; }
.n3d-txt { font-size: 15px; line-height: 1.3; color: var(--n-mut); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.n3d-note { position: absolute; left: 12px; right: 12px; top: calc(max(12px, env(safe-area-inset-top)) + 92px); padding: 10px 14px; border-radius: 14px; background: var(--n-fill); border: 1px solid var(--n-ln); font-size: 14px; line-height: 1.35; }
.n3d-bot { position: absolute; left: 12px; right: 12px; bottom: max(12px, env(safe-area-inset-bottom)); display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px 12px 18px;
  background: var(--n-fill); border: 1px solid var(--n-ln); border-radius: 22px; box-shadow: 0 10px 30px rgba(0,0,0,.28); }
.n3d-info { display: flex; flex-direction: column; min-width: 0; }
.n3d-eta { font-size: 18px; font-weight: 600; }
.n3d-to { font-size: 13px; color: var(--n-mut); }
.n3d-acts { display: flex; gap: 8px; flex: none; }
.n3d-btn { appearance: none; border: 1px solid var(--n-ln); background: transparent; color: var(--n-tx); border-radius: 999px; padding: 11px 16px; font: inherit; font-size: 14px; cursor: pointer; min-height: 44px; }
.n3d-btn:focus-visible { outline: 2px solid var(--n-acc); outline-offset: 2px; }
.n3d-x { background: var(--n-acc); color: var(--n-acc-tx); border-color: transparent; font-weight: 600; }
.n3d-car { width: 28px; height: 47px; display: block; filter: drop-shadow(0 4px 6px rgba(0,0,0,.55)); }
.n3d-carsvg { display: block; }
.n3d-carsvg .b { fill: #f1f2f3; stroke: #151618; stroke-width: 1.2; }
.n3d-carsvg .g { fill: #151618; }
.n3d-carsvg .w { fill: #5b626b; }
.n3d-carsvg .l { fill: #ffd54a; }
html[data-theme="light"] .n3d-carsvg .b { fill: #2a2d31; stroke: #ffffff; }
html[data-theme="light"] .n3d-carsvg .g { fill: #e9ebed; }
html[data-theme="light"] .n3d-carsvg .w { fill: #1d1f22; }
.crr-navs .crr-n3d { grid-column: 1 / -1; display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
@media (prefers-reduced-motion: reduce) { .n3d-ar { transition: none; } }

/* botão "3D" na barra de navegação da tela da corrida (ao lado de Maps e Waze) */
.ap-nbt .ap-n3d { appearance: none; border: 0; padding: 8px 14px; border-radius: 99px; background: var(--pv-text); color: var(--pv-card); font: inherit; font-size: 12px; font-weight: 600; cursor: pointer; }
.ap-nbt .ap-n3d:focus-visible { outline: 2px solid var(--pv-text); outline-offset: 2px; }
