/* Navegador de mapa das trilhas gravadas (Ushuaia 2023): estilos genéricos, sem dados.
   Carregado depois de viagens-v61.css; seletores prefixados com .vnav (marcação em assets/js/viagens-mapa-navegador.js).
   Sem JavaScript o mapa estático e a navegação em texto continuam visíveis; a barra de controles só aparece com .is-ready. */

.vnav { position: relative; min-width: 0; margin-top: 1.25rem; background: var(--v61-sea-deep); color: #fff; border-radius: .5rem; overflow: hidden; box-shadow: 0 1.25rem 2.5rem -1rem rgba(13, 49, 73, .55); }
.vnav-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: .2rem 1rem; padding: .7rem 1rem .55rem; border-bottom: 2px solid var(--v61-terra); }
.vnav-head .v61-plate-kicker { color: var(--v61-gold); }
.vnav-head h2 { font: 400 clamp(1.4rem, 1.2rem + 1vw, 2rem)/1.15 var(--v61-serif); }

.vnav-bar { display: none; flex-wrap: wrap; gap: .5rem; align-items: center; padding: .65rem 1rem; }
.vnav.is-ready .vnav-bar { display: flex; }
.vnav button, .vnav select { min-height: 2.75rem; padding: 0 .9rem; font: 600 .9375rem/1 var(--v61-sans); color: var(--v61-ink); background: #faf4e6; border: 1px solid #e6d9b8; border-radius: .5rem; box-shadow: 0 1px 2px rgba(0, 0, 0, .28); cursor: pointer; max-width: 100%; }
.vnav select { min-width: 0; flex: 1 1 11rem; }
.vnav button:hover, .vnav select:hover { background: #fff9ec; border-color: var(--v61-terra-light); }
.vnav button:disabled { opacity: .5; cursor: default; }
.vnav-zoom { display: inline-flex; gap: .5rem; margin-left: auto; }
.vnav-zoom button { width: 2.75rem; padding: 0; font-size: 1.25rem; }
.vnav :focus-visible { outline: 3px solid #fff; outline-offset: 2px; box-shadow: 0 0 0 6px var(--v61-sea); }

.vnav-infobar { position: absolute; z-index: 3; width: min(22rem, calc(100% - 1.5rem)); max-height: calc(100% - 1.5rem); overflow: auto; box-sizing: border-box; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .4rem 1rem; margin: 0; padding: .6rem .8rem; background: #faf3e2; color: #2a1c10; border: 1px solid #cdbb96; border-radius: .5rem; }
.vnav-infobar[hidden] { display: none; }
.vnav-card-copy { flex: 1 1 18rem; min-width: 0; overflow-wrap: anywhere; }
.vnav-card-title { margin: 0 0 .2rem; font: 700 .9375rem/1.3 var(--v61-sans); }
.vnav-info { margin: 0; font: 400 .9375rem/1.4 var(--v61-sans); color: inherit; }
.vnav-infobar :focus-visible { outline-color: #144a62; box-shadow: none; }

.vnav-stage { position: relative; height: clamp(24rem, 62svh, 40rem); background: #86bccd; }
@media (min-width: 900px) { .vnav-stage { height: clamp(30rem, 80svh, 56rem); } }
.vnav-map { position: absolute; inset: 0; touch-action: none; cursor: grab; }
.vnav-map:active { cursor: grabbing; }
.vnav-map[hidden] { display: none; }
.vnav-map svg { display: block; width: 100%; height: 100%; }
.vnav:not(.is-ready) .vnav-map { cursor: default; }

/* V4B (#134): base de atlas com direção de arte da referência aprovada (oceano azul-turquesa, relevo bege/verde/branco, rota terracota) */
.vnav .v4-relief { image-rendering: auto; }
.vnav .v4-river { fill: none; stroke: #3f86ab; stroke-opacity: .7; stroke-width: .6; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.vnav .v4-river-maj { stroke-opacity: .85; stroke-width: 1.1; }
.vnav .v4-lake { fill: #bfe0e6; stroke: #3f86ab; stroke-width: .7; vector-effect: non-scaling-stroke; }
/* fronteira: traço fino; o tracejado (definido pelo JS em unidades do mapa) só é aplicado com o mapa parado: com non-scaling-stroke custava ~40% dos quadros */
.vnav .v4-border { fill: none; stroke: #5a4632; stroke-opacity: .75; stroke-width: 1; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.vnav .v4-border.dash { stroke-dasharray: 5 3.5; }
.vnav .v4-coast { fill: none; stroke: #2f6477; stroke-opacity: .65; stroke-width: .7; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.vnav .v4-city { fill: #c2481b; stroke: #fff8ec; stroke-width: 2.2; vector-effect: non-scaling-stroke; pointer-events: none; }
.vnav .v4-city-dot { display: none; }
.vnav .v4-cities, .vnav .v4-labels, .vnav .v4-statics { pointer-events: none; }
.vnav .v4-slabel { font-family: var(--v61-serif); font-style: italic; font-weight: 700; fill: #2a1c10; stroke: #faf3e2; stroke-width: 220; paint-order: stroke; stroke-linejoin: round; dominant-baseline: central; }
.vnav.is-ready .v4-statics { display: none; }
.vnav .v4-l { font-family: var(--v61-serif); fill: #2a1c10; stroke: #faf3e2; stroke-linejoin: round; paint-order: stroke; dominant-baseline: central; text-rendering: geometricPrecision; }
.vnav .v4-box { fill: #faf3e2; fill-opacity: .95; stroke: #6b5638; stroke-opacity: .45; vector-effect: non-scaling-stroke; stroke-width: .8; pointer-events: none; }
.vnav .v4-l-city { font-style: italic; font-weight: 700; stroke: none; }
.vnav .v4-l-pais { font-family: var(--v61-sans); font-weight: 700; fill: #36291a; stroke: #f1ead2; }
.vnav .v4-l-oceano { font-style: italic; fill: #144a62; stroke: #cfe8ee; }
.vnav .v4-l-regiao, .vnav .v4-l-serra, .vnav .v4-l-area { font-style: italic; fill: #4b3414; stroke: #f1ead2; }
.vnav .v4-l-lago, .vnav .v4-l-rio, .vnav .v4-l-agua { font-style: italic; fill: #12435f; stroke: #e1f0f3; }
.vnav .v4-l[visibility="hidden"], .vnav .v4-box[visibility="hidden"] { display: none; }
.vnav-cs { fill: none; stroke: #fff6e6; stroke-width: 6.8; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; opacity: .9; pointer-events: none; }
.vnav-cs.dim { opacity: .25; }
.vnav-cs.sel { stroke-width: 8.6; opacity: .95; }
.vnav-rt { fill: none; stroke: #bf4519; stroke-width: 2.8; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; opacity: .95; pointer-events: none; }
.vnav-rt.dim { opacity: .3; }
.vnav-rt.sel { stroke: #8f2a0c; stroke-width: 4.4; opacity: 1; }
.vnav-hit { fill: none; stroke: transparent; stroke-width: 16; vector-effect: non-scaling-stroke; pointer-events: stroke; cursor: pointer; }
.vnav-hit:hover + .vnav-rt { stroke-width: 4; opacity: 1; }
.vnav-hit:focus-visible { outline: none; box-shadow: none; }
.vnav-hit:focus-visible + .vnav-rt { stroke: #144a62; stroke-width: 5; opacity: 1; }

.vnav-note { padding: .6rem 1rem; font: 400 .9375rem/1.45 var(--v61-sans); color: #fff; }
.vnav-note[hidden] { display: none; }
.vnav-text { padding: 0 1rem .9rem; font: 400 .9375rem/1.45 var(--v61-sans); }
.vnav-text summary { cursor: pointer; font-weight: 600; padding: .4rem 0; }
.vnav-days { display: grid; grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr)); gap: .15rem 1rem; list-style: none; margin: .4rem 0 0; padding: 0; }
.vnav-text a { color: var(--v61-gold); }
.vnav-credit { padding: .1rem 1rem 1rem; font: 400 .8125rem/1.45 var(--v61-sans); color: #c5d6de; }

@media (max-width: 640px) {
  .vnav-bar { display: none; }
  .vnav.is-ready .vnav-bar { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .vnav-bar select { grid-column: 1 / -1; order: -1; width: 100%; }
  .vnav-zoom { grid-column: 2; justify-self: end; }
  .vnav-stage { height: clamp(21rem, 58svh, 30rem); }
  .vnav-infobar { flex-wrap: nowrap; gap: .4rem; padding: .4rem .5rem; }
  .vnav-card-copy { flex: 1 1 0; }
  .vnav-card-title { margin-bottom: .1rem; font-size: .75rem; }
  .vnav-info { font-size: .8125rem; }
  .vnav-infobar button { flex: 0 0 auto; padding: 0 .5rem; }
}

@media (prefers-reduced-motion: reduce) {
  .vnav-rt, .vnav-cs { transition: none; }
}
@media (prefers-reduced-motion: no-preference) {
  .vnav-rt, .vnav-cs { transition: opacity .25s, stroke-width .25s; }
}


/* V4B (#134): legenda sobre o mapa (canto inferior direito), bússola e escala (canto superior direito), mini-mapa (canto superior esquerdo) */
.vnav-legend { position: absolute; right: .75rem; bottom: .75rem; z-index: 2; display: grid; gap: .3rem; padding: .6rem .8rem .65rem; background: rgba(250, 243, 226, .96); color: #2a1c10; border: 1px solid #cdbb96; border-radius: .55rem; box-shadow: 0 .3rem .9rem rgba(13, 49, 73, .35); font: 400 .8125rem/1.25 var(--v61-sans); pointer-events: none; }
.vnav-legend-t { margin: 0 0 .15rem; padding-bottom: .3rem; border-bottom: 1px solid #cdbb96; font: 600 .75rem/1.2 var(--v61-serif); letter-spacing: .14em; text-transform: uppercase; }
.vnav-key { display: inline-flex; align-items: center; gap: .5rem; }
.vnav-key svg { flex: none; }
.vnav-compass { position: absolute; right: .9rem; top: .7rem; z-index: 2; display: flex; flex-direction: column; align-items: center; gap: .45rem; pointer-events: none; }
.vnav-north { display: block; filter: drop-shadow(0 1px 1px rgba(250, 243, 226, .8)); }
.vnav-scale { display: flex; align-items: flex-end; gap: .3rem; padding: .25rem .4rem; background: rgba(250, 243, 226, .9); border-radius: .3rem; font: 600 .6875rem/1 var(--v61-sans); color: #2a1c10; }
.vnav-scale i { display: block; width: 6px; height: 56px; border-left: 2px solid #2a1c10; border-top: 2px solid #2a1c10; border-bottom: 2px solid #2a1c10; box-sizing: border-box; }
.vnav-scale span { white-space: nowrap; align-self: center; writing-mode: horizontal-tb; }
.vnav-mini { position: absolute; left: .6rem; top: .6rem; width: 5.5rem; background: #86bccd; border: 2px solid #faf3e2; border-radius: 3px; box-shadow: 0 .2rem .6rem rgba(13, 49, 73, .45); pointer-events: none; z-index: 2; line-height: 0; }
.vnav-mini[hidden] { display: none; }
.vnav-mini svg { display: block; width: 100%; height: auto; }
.vnav-mini-view { fill: rgba(176, 58, 20, .18); stroke: #b03a14; stroke-width: 2; vector-effect: non-scaling-stroke; }
.vnav-credit a { color: var(--v61-gold); }
@media (max-width: 640px) {
  .vnav-mini { width: 4.2rem; left: .4rem; top: .4rem; }
  .vnav-compass { right: .5rem; top: .4rem; }
  .vnav-north { width: 18px; height: 33px; }
}
/* telas estreitas: o JS move a legenda para uma faixa abaixo do mapa (não cobre rótulos) */
.vnav-legend.is-strip { position: static; margin: .6rem 1rem 0; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: .3rem .8rem; box-shadow: none; }
.vnav-legend.is-strip .vnav-legend-t { grid-column: 1 / -1; }
@media (max-width: 360px) { .vnav-mini { width: 3.6rem; } .vnav-legend.is-strip { grid-template-columns: minmax(0, 1fr); } }

/* V4C: atribuição acessível e rótulo explícito da barra vertical. */
.vnav-credit summary { cursor: pointer; padding: .5rem 0; font-weight: 600; color: #fff; }
.vnav-credit p { margin: .3rem 0 0; }
.vnav-scale { display: grid; grid-template-columns: 6px auto; }
.vnav:not(.is-ready) .vnav-scale { display: none; }
.vnav-scale-label { grid-column: 1 / -1; font: inherit; white-space: nowrap; }
