/* O estilo do mapa. Estava dentro do index.html até 30/11/2026. */
:root {
  /* Uma carta do sul nas cores que um pinguim enxerga bem: frias, e o dourado. Nenhum vermelho (D270).
     Plano: o mapa ocupa a tela; o painel das camadas fica ao lado (embaixo, no celular). */
  color-scheme: dark;
  --mar: #0f2646;
  --fundo: #081527;
  --painel: #0c1b33;
  --linha: #25405f;
  --gelo: #eef4f9;
  --gelo-sombra: #b9cbda;
  --tinta: #0b1a30;
  --texto: #e8eff7;
  --texto-fraco: #9db2c8;
  --ouro: #e6b94d;
  --aurora: #62e6a6;
  --violeta: #a696f6;
  --verde: #3c9f73;
  --ciano: #6cc9ea;
  --f-mapa: 'Spectral', 'Iowan Old Style', 'Palatino Linotype', Georgia, serif;
  --f-texto: 'IBM Plex Sans', 'Segoe UI', system-ui, sans-serif;
}
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body { background: var(--fundo); color: var(--texto); font-family: var(--f-texto); font-size: 15px; line-height: 1.5; }
.pagina { display: grid; grid-template-columns: minmax(0, 1fr) 372px; height: 100%; }
.quadro { position: relative; min-width: 0; min-height: 0; background: radial-gradient(circle at 50% 50%, #0c1f3b, var(--fundo) 75%); }
#mapa { display: block; width: 100%; height: 100%; touch-action: none; cursor: grab; user-select: none; }
#mapa.arrastando { cursor: grabbing; }

.painel { border-left: 1px solid var(--linha); background: var(--painel); overflow-y: auto; padding: 22px 20px 28px; display: flex; flex-direction: column; gap: 20px; }
h1 { font-family: var(--f-mapa); font-weight: 600; font-size: 27px; line-height: 1.15; margin: 0; letter-spacing: 0.01em; text-wrap: balance; }
.sub { margin: 6px 0 0; color: var(--texto-fraco); font-size: 14px; }
h2 { font-size: 12px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--texto-fraco); margin: 0 0 10px; }
h3 { font-family: var(--f-mapa); font-size: 18px; font-weight: 600; margin: 0 0 4px; }

.lista-camadas { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 6px 10px; }
.lista-camadas label { display: flex; align-items: center; gap: 8px; padding: 5px 8px; border: 1px solid var(--linha); border-radius: 6px; cursor: pointer; font-size: 14px; min-height: 34px; }
.lista-camadas label:hover { border-color: var(--ciano); }
.lista-camadas input { accent-color: var(--ouro); width: 15px; height: 15px; margin: 0; flex: none; }
.lista-camadas input:focus-visible { outline: 2px solid var(--ouro); outline-offset: 2px; }
.lista-camadas label:has(input:checked) { background: #13294a; border-color: #3a5b84; }

.explica-item { border-top: 1px solid var(--linha); padding: 14px 0 4px; }
.explica-item p { margin: 0 0 8px; color: #cfdbe8; font-size: 14px; }
.explica-item .ref, .cartao-d { color: var(--texto-fraco); font-size: 12px; font-variant-numeric: tabular-nums; }
.legenda { list-style: none; margin: 0 0 8px; padding: 0; display: grid; gap: 4px; }
.legenda li { display: flex; align-items: center; gap: 9px; font-size: 13px; color: #cfdbe8; }
.legenda svg { width: 22px; height: 22px; flex: none; overflow: visible; }
.legenda svg.am-l { width: 26px; height: 12px; }
.am-q { width: 22px; height: 14px; border-radius: 3px; flex: none; border: 1px solid #ffffff22; }
.am-t { font-family: var(--f-mapa); font-style: italic; color: var(--ciano); width: 26px; font-size: 12px; flex: none; }
.am-q-noite { background: #2a1f6e; } .am-q-penumbra { background: #5a4fb0; } .am-q-sol { background: #eef4f9; }
.am-q-aurora { background: var(--aurora); } .am-q-gelo { background: #cfe0ec; } .am-q-plataforma { background: repeating-linear-gradient(125deg, #d6e4ee 0 3px, #a9c0d2 3px 5px); }
.am-q-farto { background: #2b7fa8; } .am-q-verde { background: var(--verde); } .am-q-cinza { background: #1a1d24; }
.am-q-humano { background: #3b4a5f; } .am-q-cinturao { background: #1a3558; }
.rodape { color: var(--texto-fraco); font-size: 12.5px; border-top: 1px solid var(--linha); padding-top: 14px; margin-top: auto; }
.rodape p { margin: 0 0 6px; }

.controles { position: absolute; left: 14px; bottom: 14px; display: flex; gap: 6px; }
.controles button, .estacao label { font: inherit; font-size: 14px; color: var(--texto); background: #0c1b33e6; border: 1px solid var(--linha); border-radius: 6px; min-width: 36px; height: 36px; padding: 0 11px; cursor: pointer; }
.controles button:hover, .estacao label:hover { border-color: var(--ciano); }
.controles button:focus-visible, .estacao input:focus-visible + span { outline: 2px solid var(--ouro); outline-offset: 2px; }
.estacao { position: absolute; left: 14px; top: 14px; display: flex; gap: 0; border: 0; margin: 0; padding: 0; }
.estacao legend { position: absolute; left: -9999px; }
.estacao label { display: flex; align-items: center; padding: 0; border-radius: 0; }
.estacao label:first-of-type { border-radius: 6px 0 0 6px; }
.estacao label:last-of-type { border-radius: 0 6px 6px 0; border-left: 0; }
.estacao input { position: absolute; opacity: 0; }
.estacao span { padding: 0 13px; line-height: 34px; border-radius: 5px; }
.estacao input:checked + span { background: var(--ouro); color: var(--tinta); font-weight: 600; }

.cartao { position: absolute; right: 14px; bottom: 14px; width: min(340px, calc(100% - 28px)); background: #0c1b33f2; border: 1px solid #3a5b84; border-left: 3px solid var(--ouro); border-radius: 8px; padding: 14px 40px 14px 16px; box-shadow: 0 8px 28px #0008; }
.cartao[hidden] { display: none; }
.cartao-tipo { font-size: 11.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ouro); margin: 0 0 2px; }
.cartao-nome { font-family: var(--f-mapa); font-size: 21px; font-weight: 600; line-height: 1.2; margin: 0 0 6px; text-wrap: balance; }
.cartao-texto { margin: 0 0 8px; font-size: 14px; color: #d6e1ed; }
.cartao-d { margin: 0; }
#fechar-cartao { position: absolute; right: 8px; top: 8px; width: 28px; height: 28px; border: 0; border-radius: 5px; background: transparent; color: var(--texto-fraco); font-size: 18px; line-height: 1; cursor: pointer; }
#fechar-cartao:hover { color: var(--texto); background: #ffffff14; }
#fechar-cartao:focus-visible { outline: 2px solid var(--ouro); }

/* ---- o desenho ---- */
.grade { fill: none; stroke: #ffffff; stroke-opacity: 0.07; stroke-width: 1; vector-effect: non-scaling-stroke; }
.moldura { fill: none; stroke: #5f7ea3; stroke-width: 1.5; vector-effect: non-scaling-stroke; }
.rot-grade { font-family: var(--f-texto); font-size: 9.5px; fill: #7f97b3; }
.cinturao { fill: #5f8fd0; fill-opacity: 0.09; }
.humana { fill: #36465b; stroke: #5b6f88; stroke-width: 0.8; vector-effect: non-scaling-stroke; }
.gelo-mar { fill: #cfe0ec; fill-opacity: 0.5; stroke: #e6f0f7; stroke-opacity: 0.55; stroke-width: 1; stroke-dasharray: 2 3; vector-effect: non-scaling-stroke; }
#mapa[data-estacao="inverno"] .so-verao, #mapa[data-estacao="verao"] .so-inverno { display: none; }
.farto { fill: #2f9fd0; fill-opacity: 0.42; }
.terra { fill: var(--gelo); }
.costa { fill: none; stroke: #7f9bb5; stroke-width: 1.1; vector-effect: non-scaling-stroke; stroke-linejoin: round; }
.rifte { fill: #9fc0d8; fill-opacity: 0.55; }
.verde-base { fill: #7fc09a; fill-opacity: 0.75; }
.rocha-base { fill: #5c6a7c; fill-opacity: 0.5; }
.nivel { fill: none; stroke: #9ab4ca; stroke-width: 0.9; vector-effect: non-scaling-stroke; }
.plataforma { fill: url(#h-plataforma); fill-opacity: 0.92; }
.falesia { fill: none; stroke: #54728f; stroke-width: 2.2; vector-effect: non-scaling-stroke; stroke-linecap: round; }
.pico { fill: none; stroke: #4c657f; stroke-width: 1.3; vector-effect: non-scaling-stroke; stroke-linejoin: round; stroke-linecap: round; }
.pico.vulcao { stroke: #2b3646; }
.ilha { fill: var(--gelo); stroke: #7f9bb5; stroke-width: 0.9; vector-effect: non-scaling-stroke; }
.ilha-fogo { fill: #56647a; stroke: #2b3646; }
.canal { fill: none; stroke: #5d86ab; stroke-width: 1.1; vector-effect: non-scaling-stroke; stroke-linecap: round; }

.luz-noite { fill: #1d1466; fill-opacity: 0.42; }
.luz-penumbra { fill: #4a3fb0; fill-opacity: 0.26; }
.luz-linha { fill: none; stroke: var(--violeta); stroke-width: 1.2; stroke-dasharray: 5 4; vector-effect: non-scaling-stroke; }
.rotulo-arco { font-family: var(--f-mapa); font-style: italic; font-size: 13px; text-anchor: middle; letter-spacing: 0.08em; paint-order: stroke; stroke-linejoin: round; }
.luz-texto { fill: #e3dcff; stroke: #1d1466; stroke-width: 3px; }
.mar-texto { fill: #bfe6f6; stroke: var(--mar); stroke-width: 3px; }
.jogos-texto { fill: #f4dfa6; stroke: var(--mar); stroke-width: 3px; font-size: 11.5px; }
.cinturao-texto { fill: #8fb0d6; stroke: var(--mar); stroke-width: 3px; font-size: 12px; letter-spacing: 0.16em; }
.aurora-faixa { fill: var(--aurora); fill-opacity: 0.42; }
.aurora-linha { fill: none; stroke: #c9ffe4; stroke-width: 1.4; stroke-opacity: 0.85; vector-effect: non-scaling-stroke; }
.aurora-centro { stroke: var(--aurora); stroke-width: 1.5; vector-effect: non-scaling-stroke; }
.volta-fora { fill: none; stroke: var(--ciano); stroke-width: 2; stroke-dasharray: 10 6; vector-effect: non-scaling-stroke; }
.seta-fora { fill: var(--ciano); }
.volta-dentro { fill: none; stroke: #9fd6c9; stroke-width: 1.5; stroke-dasharray: 3 4; vector-effect: non-scaling-stroke; }
.seta-dentro { fill: #9fd6c9; }
.passagem { fill: var(--tinta); stroke: var(--ciano); stroke-width: 1.6; vector-effect: non-scaling-stroke; }
.rota { fill: none; stroke: #f1f6fb; stroke-width: 1.8; vector-effect: non-scaling-stroke; stroke-linecap: round; }
.rota-marcha { stroke: #23405e; stroke-dasharray: 1 5; stroke-width: 2.4; }
.saida { stroke: var(--violeta); stroke-dasharray: 7 5; }
.rota-volta { stroke: #f1f6fb; stroke-opacity: 0.55; stroke-width: 1.2; }
.cinza { fill: #0a0c11; fill-opacity: 0.5; }
.cinza-forte { fill-opacity: 0.75; }
.pomes { fill: none; stroke: var(--ouro); stroke-width: 1.6; stroke-dasharray: 1.5 5; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.seta-pomes { fill: var(--ouro); }
.leva { fill: none; stroke: #bfe6f6; stroke-width: 1.4; vector-effect: non-scaling-stroke; }
.seta-leva { fill: #bfe6f6; }
.silencio { fill: none; stroke: var(--violeta); stroke-width: 1.4; stroke-dasharray: 9 4 2 4; stroke-opacity: 0.85; vector-effect: non-scaling-stroke; }

.s-ponto { fill: var(--tinta); stroke: #ffffff; stroke-width: 1.7; }
.s-fino { stroke-width: 1.3; }
.s-ouro { fill: var(--ouro); stroke: var(--tinta); stroke-width: 1.4; stroke-linejoin: round; }
.s-anel-ouro { fill: none; stroke: var(--ouro); stroke-width: 1.5; }
.s-miolo { fill: var(--tinta); }
.s-arco { fill: var(--violeta); stroke: #ffffff; stroke-width: 1.3; }
.s-misterio { fill: #0c1b33; stroke: var(--violeta); stroke-width: 1.5; }
.s-interrog { font-family: var(--f-mapa); font-weight: 600; font-size: 11.5px; fill: #e3dcff; text-anchor: middle; }
.s-pedra { stroke: var(--tinta); stroke-width: 1.3; stroke-linejoin: round; }
.s-p-mar { fill: #8fb3cf; } .s-p-vento { fill: #d9c79a; } .s-p-gelo { fill: #ffffff; } .s-p-fundo { fill: #3d6fb0; } .s-p-fogo { fill: #3a3f4b; stroke: #e8eff7; }
.s-humano { fill: #7d8794; stroke: var(--tinta); stroke-width: 1.3; }
.s-humano-x { stroke: var(--tinta); stroke-width: 1.2; fill: none; }
.s-calor-halo { fill: var(--ouro); fill-opacity: 0.35; }
.s-calor { fill: #fff3cf; stroke: #b8862a; stroke-width: 1.2; }
.s-planta { fill: none; stroke: #1f7a52; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.s-alga { fill: none; stroke: #7fd4a6; stroke-width: 1.7; stroke-linecap: round; }
.s-ordem { fill: var(--ciano); stroke: var(--tinta); stroke-width: 1.2; }
.s-ordem-n { font-family: var(--f-texto); font-weight: 600; font-size: 10px; fill: var(--tinta); }

.rot-lugar, .rot-regiao, .rot-movel, .rot-mesa, .rot-humana { font-family: var(--f-mapa); paint-order: stroke; stroke-linejoin: round; stroke-width: 3.2px; }
.rot-lugar { font-size: 13.5px; }
.rot-capital { font-size: 16px; font-weight: 600; }
.rot-jogos { font-size: 14px; font-weight: 600; }
.rot-vila { font-size: 12px; font-style: italic; }
.rot-arco { font-size: 12.5px; }
.em-terra { fill: var(--tinta); stroke: #f4f8fbdd; }
.no-mar { fill: #f1f6fb; stroke: #0b1c36e6; }
.rot-regiao { font-size: 15px; letter-spacing: 0.2em; text-transform: uppercase; }
.reg-gelo { fill: #46617c; stroke: #eef4f9cc; }
.reg-mar { fill: #cfe0ee; stroke: #0b1c36cc; }
.reg-agua { fill: #9fd0ea; stroke: #0b1c36cc; font-style: italic; text-transform: none; letter-spacing: 0.1em; font-size: 14.5px; }
.rot-sub { font-size: 10.5px; letter-spacing: 0.24em; }
.rot-movel { font-size: 12px; font-style: italic; fill: #bfe6f6; stroke: #0b1c36e6; letter-spacing: 0.04em; }
.rot-mesa { font-size: 12px; font-style: italic; fill: #bfe6f6; stroke: #0b1c36e6; }
.rot-mesa-forte { font-size: 14px; font-weight: 500; fill: #ffffff; }
.rot-humana { font-size: 12.5px; letter-spacing: 0.14em; text-transform: uppercase; fill: #a9b8c9; stroke: #0b1c36cc; }
.rot-pequeno { font-size: 10px; }
.clicavel { cursor: pointer; }
.clicavel:focus { outline: none; }
.clicavel:focus-visible > *:first-child, .clicavel.escolhido > *:first-child { filter: drop-shadow(0 0 3px var(--ouro)) drop-shadow(0 0 5px var(--ouro)); }
.clicavel:hover .rot-lugar, .clicavel:hover .rot-regiao, .clicavel:hover .rot-movel, .clicavel.escolhido text { fill: var(--ouro); }
.clicavel:hover .em-terra, .clicavel.escolhido .em-terra, .clicavel:hover .reg-gelo, .clicavel.escolhido .reg-gelo { fill: #7a5200; }
.am-l path { fill: none; stroke-width: 2; }
.am-l-fora { stroke: var(--ciano); stroke-dasharray: 6 3; } .am-l-dentro { stroke: #9fd6c9; stroke-dasharray: 2 3; }
.am-l-rota { stroke: #f1f6fb; } .am-l-saida { stroke: var(--violeta); stroke-dasharray: 5 3; }
.am-l-pomes { stroke: var(--ouro); stroke-dasharray: 1.5 4; stroke-linecap: round; } .am-l-silencio { stroke: var(--violeta); stroke-dasharray: 6 3 1.5 3; }

@media (max-width: 880px) {
  html, body { height: auto; }
  .pagina { display: block; height: auto; }
  .quadro { height: min(100vw, 78vh); }
  .painel { border-left: 0; border-top: 1px solid var(--linha); overflow: visible; }
  .cartao { left: 14px; right: 14px; bottom: 60px; width: auto; }
}
@media (prefers-reduced-motion: no-preference) { .lista-camadas label { transition: border-color 0.15s, background 0.15s; } }
/* era um style="" no HTML; a política de segurança fechada não aceita estilo embutido */
h2.cartao-nome-h2 { text-transform: none; letter-spacing: 0; color: var(--texto); }
