/* css/nyo.css — interfaz de nyo.im: tema oscuro, barra superior, columnas laterales y barra de vuelo. Se carga después de app.css. */
:root {
  --ink: #eef2f8; --muted: #9aa6ba; --card: rgba(10, 16, 30, 0.86); --line: rgba(255, 255, 255, 0.09);
  --accent: #1f6ff2; --accent2: #3d8bff; --bar: rgba(7, 12, 24, 0.9); --r: 14px;
  font-family: "Inter", "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
}
html, body { background: #0b1220; }
#map { background: #0b1220; }
.card { box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35); border: 1px solid rgba(255, 255, 255, 0.07); }
svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.maplibregl-ctrl-bottom-right, .maplibregl-ctrl-bottom-left .maplibregl-ctrl-scale { display: none; }
.maplibregl-ctrl-bottom-left { bottom: 80px; }
.maplibregl-ctrl-attrib { background: rgba(7, 12, 24, 0.7) !important; color: #9aa6ba; }
.maplibregl-ctrl-attrib a { color: #c9d3e3 !important; }
.maplibregl-ctrl-bottom-right { display: block !important; bottom: 80px; }
.maplibregl-ctrl-bottom-right .maplibregl-ctrl-group { display: none; }
.attrib { display: none; }

/* ---------- barra superior */
.bar { position: fixed; z-index: 15; background: var(--bar); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); color: var(--ink); }
#topbar { top: 0; left: 0; right: 0; height: 56px; display: flex; align-items: center; gap: 14px; padding: 0 16px; border-bottom: 1px solid var(--line); }
.tb-logo { display: flex; align-items: center; gap: 8px; font-size: 22px; font-weight: 800; letter-spacing: -0.02em; white-space: nowrap; }
.tb-logo svg { width: 40px; height: 24px; stroke-width: 1.6; }
.tb-sep { width: 1px; height: 28px; background: var(--line); flex: none; }
.tb-mode { display: flex; align-items: baseline; gap: 14px; min-width: 0; white-space: nowrap; overflow: hidden; }
.tb-mode b { color: var(--accent2); font-size: 18px; }
.tb-sub { color: #c9d3e3; font-size: 14px; overflow: hidden; text-overflow: ellipsis; }
#topbar .search { position: relative; top: auto; left: auto; transform: none; flex: 1; min-width: 160px; max-width: 360px; width: auto; margin-left: auto; height: 36px;
  background: rgba(255, 255, 255, 0.07); border-radius: 10px; border: 1px solid var(--line); box-shadow: none; padding: 0 10px; }
#topbar .search input { padding: 0; font-size: 13.5px; color: var(--ink); }
#topbar .s-icon { font-size: 17px; }
.results { background: #111a2c; border: 1px solid var(--line); }
.results button:hover, .results button:focus { background: #1a2640; }
.tb-live { display: flex; align-items: center; gap: 7px; padding: 5px 13px; border-radius: 99px; border: 1px solid rgba(46, 204, 113, 0.35); background: rgba(46, 204, 113, 0.08); color: #6fe3a1; font-weight: 700; font-size: 14px; white-space: nowrap; }
.tb-live i { width: 9px; height: 9px; border-radius: 50%; background: #2ecc71; box-shadow: 0 0 8px #2ecc71; animation: pulse 2s infinite; }
.tb-place, .tb-clock { white-space: nowrap; font-size: 14px; color: #dfe6f1; font-variant-numeric: tabular-nums; }
#clock { font-size: inherit; font-weight: 500; margin: 0; display: inline; }
#date { display: inline; color: inherit; font-size: inherit; }
.tb-btn { display: flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 9px; border: 0; background: none; color: #dfe6f1; cursor: pointer; text-decoration: none; font: 800 12px/1 inherit; }
.tb-btn:hover { background: rgba(255, 255, 255, 0.08); }
.tb-btn svg { width: 22px; height: 22px; }
.tb-btn.lang { border: 1.5px solid var(--line); width: auto; padding: 0 8px; height: 28px; font-size: 12px; }
#topbar .fab { display: none; position: static; box-shadow: none; background: none; }

/* ---------- columnas */
.col { position: fixed; top: 68px; bottom: 84px; z-index: 10; display: flex; flex-direction: column; gap: 10px; pointer-events: none; }
.col > * { pointer-events: auto; }
.col-left { left: 12px; width: 300px; }
.col-right { right: 12px; width: 270px; }
.panel { position: fixed; top: 68px; right: auto; transform: none; }
.card-h { display: flex; align-items: center; justify-content: space-between; margin: 0; padding: 12px 14px; font-size: 15.5px; font-weight: 600; color: var(--ink); text-transform: none; letter-spacing: 0; border-bottom: 1px solid var(--line); }
.card-h small { font-weight: 400; color: var(--muted); font-size: 13px; }
.card-h[data-fold] { cursor: pointer; user-select: none; }
.chev { width: 9px; height: 9px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(-135deg); margin-top: 4px; transition: transform 0.2s; }
.card.folded .chev { transform: rotate(45deg); margin-top: -4px; }
.card.folded .card-b { display: none; }
.card.folded .card-h { border-bottom: 0; }
.layers { padding: 0; display: flex; flex-direction: column; min-height: 0; flex: 0 1 auto; }
.layers .card-b { overflow-y: auto; padding: 4px 12px 10px; scrollbar-width: thin; }
.events { padding: 0; display: flex; flex-direction: column; min-height: 120px; flex: 1 1 0; }
.events.folded { flex: 0 0 auto; min-height: 0; }
.events .card-b { overflow-y: auto; flex: 1; scrollbar-width: thin; }
.layers.folded { flex: 0 0 auto; }

/* filas de capa con interruptor */
.lyr { display: flex; align-items: center; gap: 11px; padding: 8px 2px; border-top: 1px solid var(--line); font-size: 14px; }
.lyr:first-child { border-top: 0; }
.lyr .ico { width: 22px; height: 22px; flex: none; color: #dfe6f1; }
.lyr-name { flex: 1; min-width: 0; font-weight: 500; }
.lyr-t { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.lyr .sub { color: var(--muted); font-size: 11.5px; line-height: 1.35; }
.lyr .badge { font-size: 9.5px; padding: 1px 6px; font-weight: 700; }
.sw { appearance: none; -webkit-appearance: none; flex: none; width: 38px !important; height: 22px !important; border-radius: 99px; background: #3a4458; position: relative; cursor: pointer; transition: background 0.2s; margin: 0; }
.sw::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform 0.2s; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4); }
.sw:checked { background: var(--accent); }
.sw:checked::after { transform: translateX(16px); }
.legend { color: var(--muted); font-size: 11px; margin: 8px 0 0; line-height: 1.5; }
.legend b { color: #dfe6f1; }

/* eventos en vivo */
.ev-list { display: flex; flex-direction: column; }
.ev { display: flex; gap: 10px; align-items: flex-start; padding: 10px 14px; border: 0; border-top: 1px solid var(--line); background: none; color: var(--ink); text-align: left; font: inherit; cursor: pointer; width: 100%; }
.ev:first-child { border-top: 0; }
.ev:hover, .ev.sel { background: rgba(61, 139, 255, 0.12); }
.ev-i { width: 26px; height: 26px; border-radius: 7px; display: flex; align-items: center; justify-content: center; flex: none; color: #fff; }
.ev-i svg { width: 17px; height: 17px; }
.ev-b { flex: 1; min-width: 0; }
.ev-t { display: flex; gap: 8px; align-items: baseline; }
.ev-t b { flex: 1; font-size: 14px; font-weight: 600; }
.ev-t time { font-size: 11.5px; color: var(--muted); white-space: nowrap; }
.ev-d { font-size: 12.5px; color: #c9d3e3; margin-top: 2px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.ev-empty { padding: 14px; color: var(--muted); font-size: 13px; }

/* derecha: clima, aeronaves, minimapa */
.weather { padding: 14px 16px; }
.w-main { gap: 14px; }
.w-icon { font-size: 44px; }
.w-temp { font-size: 26px; font-weight: 700; line-height: 1.1; }
.w-cond { font-weight: 500; font-size: 13.5px; color: #dfe6f1; margin-top: 2px; }
.w-wind { font-size: 13px; color: #dfe6f1; margin-top: 2px; }
.w-grid { color: var(--muted); }
.aircraft { padding: 0; }
.ac-list { padding: 4px 0 6px; }
.ac { display: flex; align-items: center; gap: 10px; padding: 7px 14px; font-size: 13.5px; cursor: pointer; border: 0; background: none; color: var(--ink); width: 100%; font-family: inherit; }
.ac:hover { background: rgba(255, 255, 255, 0.06); }
.ac svg { width: 20px; height: 20px; flex: none; stroke-width: 1.5; }
.ac b { flex: 1; text-align: left; font-weight: 500; }
.ac span { color: #dfe6f1; font-variant-numeric: tabular-nums; }
.ac-empty { padding: 8px 14px; color: var(--muted); font-size: 12.5px; }
.mini { position: relative; height: 220px; padding: 0; overflow: hidden; flex: none; }
#minimap { position: absolute; inset: 0; filter: invert(0.92) hue-rotate(185deg) saturate(0.55) brightness(0.95); }
.mini-me { position: absolute; left: 50%; top: 50%; width: 22px; height: 22px; margin: -11px 0 0 -11px; fill: #fff; stroke: #1f6ff2; stroke-width: 1.5; filter: drop-shadow(0 0 4px #1f6ff2); }
.mini-l { position: absolute; right: 12px; bottom: 10px; font-size: 22px; font-weight: 800; color: #fff; text-shadow: 0 2px 6px #000; }

/* ---------- barra de vuelo */
#flightbar { left: 12px; right: 12px; bottom: 12px; height: 62px; border-radius: 14px; border: 1px solid var(--line); display: flex; align-items: center; gap: 16px; padding: 0 12px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4); }
.fb-mode { display: flex; align-items: center; gap: 8px; height: 44px; padding: 0 12px; border-radius: 10px; border: 1px solid rgba(61, 139, 255, 0.45); font-size: 15px; white-space: nowrap; }
.fb-mode svg { width: 24px; height: 24px; }
.fb-mode select { background: none; border: 0; color: var(--ink); font: 700 15px inherit; cursor: pointer; outline: none; padding-right: 4px; }
.fb-mode select option { background: #111a2c; }
.seg { display: inline-flex; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.04); }
.seg button, .seg a { display: flex; align-items: center; gap: 7px; border: 0; background: none; color: #dfe6f1; padding: 0 16px; font: 500 14.5px inherit; cursor: pointer; text-decoration: none; height: 100%; white-space: nowrap; }
.seg.big { height: 44px; }
.seg button svg { width: 18px; height: 18px; }
.seg .on { background: var(--accent); color: #fff; }
.seg button:disabled { opacity: 0.45; cursor: default; }
.fb-stat { font-size: 14.5px; color: #c9d3e3; white-space: nowrap; padding-left: 16px; border-left: 1px solid var(--line); }
.fb-stat b { color: #fff; margin-left: 8px; font-weight: 700; font-variant-numeric: tabular-nums; }
.fb-follow { font-size: 13px; color: #8fb8ff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; flex: 0 1 auto; }
.sp { flex: 1; }
.fb-btn { width: 44px; height: 44px; border-radius: 10px; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.04); color: #fff; display: flex; align-items: center; justify-content: center; cursor: pointer; flex: none; }
.fb-btn:hover { background: rgba(255, 255, 255, 0.1); }
.fb-btn svg { width: 22px; height: 22px; }
.fb-btn.busy { animation: pulse 1s infinite; }
.fb-zoom { display: flex; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); }
.fb-zoom .fb-btn { border: 0; border-radius: 0; }
.fb-zoom .fb-btn + .fb-btn { border-left: 1px solid var(--line); }

/* ajustes y ayuda */
.popover { position: fixed; top: 64px; right: 60px; z-index: 30; width: 300px; padding: 12px 14px; color: var(--ink); font-size: 13.5px; }
.popover[hidden] { display: none; }
.popover .opt { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 7px 0; border-top: 1px solid var(--line); }
.popover .opt:first-child { border-top: 0; }
.popover select { background: #111a2c; color: var(--ink); border: 1px solid var(--line); border-radius: 8px; padding: 4px 6px; font: inherit; font-size: 13px; }
.popover .seg { height: 30px; }
.popover .seg a { padding: 0 10px; font-size: 12.5px; }
#pop-help { width: 360px; right: 16px; }
#pop-help p { margin: 8px 0 0; color: #c9d3e3; line-height: 1.45; }
#pop-help .muted { color: var(--muted); font-size: 11.5px; }

/* ventanas del mapa en oscuro */
.maplibregl-popup-content { background: #111a2c !important; color: var(--ink); border: 1px solid var(--line); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5) !important; border-radius: 12px !important; }
.maplibregl-popup-tip { border-top-color: #111a2c !important; border-bottom-color: #111a2c !important; }
.maplibregl-popup-close-button { color: #c9d3e3; }
.pop, .pop b, .pop .np-title { color: var(--ink) !important; }
.pop div:not(.pop-h) { color: #c9d3e3; }
.pop a { color: #8fb8ff; }
.pop .alert-line { background: rgba(242, 183, 5, 0.12) !important; color: #ffd76a !important; }

/* aviso de sismo */
.alerta { top: 68px; background: #2a1410; border-color: #e4572e; color: #ffd2c4; }

/* etiquetas de zonas y pines de eventos */
.zlabel { padding: 5px 11px; border-radius: 8px; background: rgba(10, 16, 30, 0.88); color: #fff; font-size: 13px; font-weight: 600; white-space: nowrap; border: 1px solid rgba(255, 255, 255, 0.12); box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35); pointer-events: none; width: max-content; }
.zlabel::after { content: ""; position: absolute; left: 50%; bottom: -6px; margin-left: -6px; border: 6px solid transparent; border-bottom: 0; border-top-color: rgba(10, 16, 30, 0.88); }
.epin { width: 40px; height: 48px; cursor: pointer; filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.45)); }
.epin svg.pin { width: 40px; height: 48px; stroke: none; }
.epin .ei { position: absolute; left: 9px; top: 8px; width: 22px; height: 22px; color: #fff; }
.epin.sel { animation: bob 1s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-5px); } }

/* helicóptero 3D */
#heli3d { position: fixed; left: 0; top: 0; width: 100%; height: 100%; z-index: 6; pointer-events: none; display: none; }
body.flying.has-heli3d #heli3d { display: block; }
body.flying.has-heli3d .heli { display: none !important; }
body.flying:not(.has-heli3d):not(.heli2d) .heli, body.flying:not(.has-heli3d):not(.heli2d) .heli-shadow { visibility: hidden; }
body.flying .search, body.flying .brand { display: flex; }
body.flying:not(.panel-open) .panel { display: flex; }
body.flying .heli-ui { display: block; }
.joy, .alt-btns { display: none; }
@media (pointer: coarse) { body.flying .joy { display: block; bottom: 96px; } body.flying .alt-btns { display: flex; bottom: 96px; } }
.joy { background: rgba(10, 16, 30, 0.6); border-color: rgba(255, 255, 255, 0.2); }
.alt-btns button { color: var(--ink); }

/* pantallas medianas y chicas */
@media (max-width: 1280px) { .tb-sub, .tb-place { display: none; } }
@media (max-width: 1100px) { .fb-stat:nth-of-type(3), .fb-follow { display: none; } .col-right { width: 240px; } }
@media (max-width: 900px) {
  .tb-mode, .tb-clock, #topbar .search { display: none; }
  #topbar .fab { display: flex; }
  .col-left { transform: translateX(-110%); transition: transform 0.25s; z-index: 20; }
  body.panel-open .col-left { transform: none; }
  .col-right { top: auto; bottom: 84px; width: 200px; }
  .col-right .aircraft, .col-right .mini { display: none; }
  .fb-stat, .seg.big { display: none; }
  body.flying .fb-stat { display: inline; }
}
.layers h2.card-h { margin: 0; font-size: 15.5px; text-transform: none; letter-spacing: 0; color: var(--ink); }
.layers { max-height: 58%; }
.layers.folded { max-height: none; }

/* máquina del tiempo */
.timeline { left: 12px; right: 12px; bottom: 82px; height: 54px; border-radius: 14px; border: 1px solid var(--line); display: flex; align-items: center; gap: 10px; padding: 0 12px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4); }
.timeline[hidden] { display: none; }
body.tm-open .col { bottom: 146px; }
.tl-live { display: flex; align-items: center; gap: 7px; height: 36px; padding: 0 12px; border-radius: 9px; border: 1px solid rgba(46, 204, 113, 0.4); background: rgba(46, 204, 113, 0.1); color: #6fe3a1; font: 700 13px inherit; cursor: pointer; white-space: nowrap; }
.tl-live i { width: 8px; height: 8px; border-radius: 50%; background: #2ecc71; }
.fb-btn.sm { width: 36px; height: 36px; }
.fb-btn.sm svg { width: 18px; height: 18px; }
#tl-play .i-pause, body.tm-playing #tl-play .i-play { display: none; }
body.tm-playing #tl-play .i-pause { display: block; }
#tl-speed { height: 36px; }
#tl-speed button { padding: 0 10px; font-size: 13px; }
.tl-track { position: relative; flex: 1; height: 36px; min-width: 120px; }
.tl-track canvas { position: absolute; inset: 0; width: 100%; height: 100%; border-radius: 8px; background: rgba(255, 255, 255, 0.04); }
.tl-track input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; background: none; -webkit-appearance: none; appearance: none; cursor: pointer; }
.tl-track input::-webkit-slider-thumb { -webkit-appearance: none; width: 4px; height: 36px; border-radius: 2px; background: #ffb13b; box-shadow: 0 0 8px #ffb13b; }
.tl-track input::-moz-range-thumb { width: 4px; height: 36px; border: 0; border-radius: 2px; background: #ffb13b; }
.tl-time { min-width: 150px; text-align: right; font-variant-numeric: tabular-nums; font-size: 14px; color: #ffd27a; font-weight: 600; white-space: nowrap; }
#btn-tm.on { background: #ffb13b; color: #1d2433; border-color: #ffb13b; }
body.replay .tb-live { border-color: rgba(255, 177, 59, 0.5); background: rgba(255, 177, 59, 0.1); color: #ffd27a; }
body.replay .tb-live i { background: #ffb13b; box-shadow: 0 0 8px #ffb13b; }
body.replay .tb-clock { color: #ffd27a; }
@media (max-width: 900px) { #tl-speed, #tl-back, #tl-fwd { display: none; } .tl-time { min-width: 0; font-size: 12px; } }

.b-replay { background: #c98a12; }
/* con aviones 3D, el ícono plano se oculta (la ficha sigue funcionando) */
body.has-planes3d .plane { visibility: hidden !important; pointer-events: none !important; }

/* controles propios: menús desplegables, barras de desplazamiento, avisos y foco */
.dd-native { position: absolute !important; opacity: 0 !important; pointer-events: none !important; width: 1px !important; height: 1px !important; }
.dd { position: relative; display: inline-flex; }
.dd-btn { display: flex; align-items: center; gap: 8px; height: 32px; padding: 0 10px; border-radius: 8px; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.06); color: var(--ink); font: 600 13.5px inherit; cursor: pointer; white-space: nowrap; }
.dd-btn:hover, .dd.open .dd-btn { background: rgba(255, 255, 255, 0.12); }
.dd-c { width: 7px; height: 7px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); margin: -3px 0 0 2px; }
.dd-menu { position: absolute; z-index: 50; min-width: 100%; padding: 5px; border-radius: 10px; background: #111a2c; border: 1px solid rgba(255, 255, 255, 0.12); box-shadow: 0 14px 40px rgba(0, 0, 0, 0.55); top: calc(100% + 6px); right: 0; }
.dd-menu[hidden] { display: none; }
#flightbar .dd-menu { top: auto; bottom: calc(100% + 10px); left: 0; right: auto; }
.dd-o { display: block; width: 100%; text-align: left; padding: 8px 12px; border: 0; border-radius: 7px; background: none; color: #dfe6f1; font: 500 13.5px inherit; cursor: pointer; white-space: nowrap; }
.dd-o:hover { background: rgba(61, 139, 255, 0.18); color: #fff; }
.dd-o.on { color: #8fb8ff; font-weight: 700; }
.fb-mode .dd-btn { border: 0; background: none; font-size: 15px; font-weight: 700; padding: 0 2px; height: 40px; }
* { scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, 0.18) transparent; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.16); border-radius: 8px; border: 2px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, 0.28); background-clip: padding-box; }
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--accent2); outline-offset: 2px; border-radius: 8px; }
input[type="search"]::-webkit-search-cancel-button { -webkit-appearance: none; }
.toast { position: fixed; left: 50%; bottom: 96px; transform: translate(-50%, 20px); z-index: 60; padding: 11px 18px; border-radius: 12px; background: #111a2c; color: var(--ink); border: 1px solid rgba(255, 255, 255, 0.12); box-shadow: 0 14px 40px rgba(0, 0, 0, 0.5); font-size: 14px; opacity: 0; pointer-events: none; transition: opacity 0.2s, transform 0.2s; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.maplibregl-popup-close-button { font-size: 18px; width: 26px; height: 26px; border-radius: 7px; right: 4px; top: 4px; }
.maplibregl-popup-close-button:hover { background: rgba(255, 255, 255, 0.1) !important; }
/* modo pantalla (kiosco): solo el mapa, la barra superior y el sobrevuelo */
body.kiosk .col, body.kiosk #flightbar, body.kiosk #timeline, body.kiosk .search { display: none !important; }
body.kiosk .maplibregl-ctrl-bottom-left { bottom: 12px; }
.tour-cap { position: fixed; left: 50%; top: 72px; transform: translateX(-50%); z-index: 12; padding: 8px 16px; border-radius: 12px; background: rgba(10, 16, 30, 0.82); border: 1px solid var(--line); color: #fff; font-size: 15px; font-weight: 600; display: none; white-space: nowrap; }
body.touring .tour-cap { display: block; }
.tour-cap small { color: var(--muted); font-weight: 500; margin-left: 8px; }

#btn-sound .snd-off, body.muted #btn-sound .snd-on { display: none; }
body.muted #btn-sound .snd-off { display: inline; }
body.muted #btn-sound { color: var(--muted); }

/* tarjetas flotantes */
.floats { position: fixed; inset: 0; z-index: 8; pointer-events: none; overflow: hidden; }
.fcard { position: absolute; left: 0; top: 0; pointer-events: auto; cursor: pointer; will-change: transform; }
.fcard .fc-b { position: relative; padding: 7px 10px; border-radius: 10px; background: rgba(10, 16, 30, 0.84); border: 1px solid rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); box-shadow: 0 8px 22px rgba(0, 0, 0, 0.4); color: #fff; font-size: 12px; white-space: nowrap; margin-bottom: 26px; }
.fcard .fc-b::after { content: ""; position: absolute; left: 50%; top: 100%; width: 1.5px; height: 26px; background: linear-gradient(rgba(255, 255, 255, 0.7), rgba(255, 255, 255, 0)); }
.fcard .fc-b::before { content: ""; position: absolute; left: calc(50% - 3px); top: calc(100% + 23px); width: 6px; height: 6px; border-radius: 50%; background: #fff; box-shadow: 0 0 6px #fff; }
.fc-t { font-weight: 700; font-size: 12.5px; display: flex; align-items: center; gap: 6px; }
.fc-m { color: #c9d3e3; margin-top: 2px; }
.fc-r { display: flex; gap: 8px; margin-top: 4px; }
.fc-arr { display: flex; align-items: center; gap: 4px; color: #dfe6f1; font-variant-numeric: tabular-nums; }
.fc-arr .bullet { min-width: 17px; height: 17px; font-size: 10.5px; }
.fc-pl .fc-b { padding: 5px 8px; margin-bottom: 18px; border-color: rgba(143, 184, 255, 0.35); }
.fc-pl .fc-b::after { height: 18px; background: linear-gradient(rgba(143, 184, 255, 0.7), rgba(143, 184, 255, 0)); }
.fc-pl .fc-b::before { display: none; }
.fc-cam img { display: block; width: 168px; height: 112px; object-fit: cover; border-radius: 7px; margin-top: 5px; background: #000; }
.fc-cam.off img { opacity: 0.25; }
body.kiosk .floats .fc-cam { display: none; }

/* tótems de gasolinera (precio promedio de NYC) */
.gs-board { width: 156px; }
.gs-pump { width: 18px; height: 18px; border-radius: 5px; display: inline-flex; align-items: center; justify-content: center; font-size: 11px; }
.md .gs-lbl { background: #2f6db3; }
.gs-led sup { font-size: 9px; vertical-align: 5px; margin-left: 1px; }
.gs-foot { color: #ffb13b; }
.pop .gp-row { display: flex; align-items: center; gap: 10px; color: var(--ink) !important; }
.pop .gp-row span { flex: 1; }
.pop .gp-row i { font-style: normal; font-size: 11px; font-weight: 700; } .pop .gp-row i.down { color: #7dffb0; } .pop .gp-row i.up { color: #ff8f8f; }
.b-weekly { background: #2f6db3; }
.w-tide { grid-column: 1 / -1; }

/* acerca de y créditos */
.info-pop { width: 380px; max-height: calc(100vh - 150px); overflow-y: auto; right: 100px; }
.about { display: flex; gap: 14px; align-items: center; }
.about img { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; border: 2px solid rgba(255, 255, 255, 0.15); flex: none; }
.about-n { font-size: 17px; display: block; }
.about-r { margin: 2px 0; }
.about-m { display: block; width: fit-content; margin-top: 4px; color: #6fb0ff; text-decoration: none; }
.about-m:hover { text-decoration: underline; }
.about-d { font-style: italic; margin: 12px 0 4px; padding: 10px 12px; border-radius: 10px; background: rgba(255, 255, 255, 0.05); }
.info-h { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 14px 0 6px; }
.credits { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.credits li { display: flex; flex-direction: column; font-size: 12.5px; }
.credits a, .credits .cr-n { color: var(--ink); text-decoration: none; font-weight: 600; }
.credits a:hover { color: #6fb0ff; }
.credits li span { color: var(--muted); }
.osm-c { position: fixed; right: 10px; bottom: 82px; z-index: 9; font: 10.5px/1 inherit; font-family: inherit; color: #c9d3e3; background: rgba(7, 12, 24, 0.55);
  border: 0; border-radius: 99px; padding: 3px 8px; cursor: pointer; transition: opacity 1.5s; }
.osm-c.dim { opacity: 0.35; } .osm-c:hover { opacity: 1; }
body.kiosk .osm-c { bottom: 8px; }

/* emergencias, delitos */
.b-quarterly { background: #6d28d9; }

/* noticias flotantes */
.fc-news { max-width: 260px; }
.fc-news .fc-nh { display: flex; align-items: center; gap: 6px; margin-bottom: 3px; }
.fc-news .fc-src { color: var(--muted); font-size: 10.5px; }
.fc-news .fc-nt { font-weight: 650; font-size: 12.5px; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.fc-hot, .fc-dev { font-size: 9.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; padding: 1px 6px; border-radius: 4px; color: #fff; background: #e0262f; animation: hotpulse 1.4s infinite; }
.fc-dev { background: #d97706; animation: none; }
@keyframes hotpulse { 50% { opacity: .55; } }

/* radio y TV */
.media-pop { width: 340px; right: 150px; padding: 10px; }
.md-tabs { display: flex; gap: 6px; margin-bottom: 8px; }
.md-tab { flex: 1; font: inherit; font-weight: 600; font-size: 13px; color: var(--muted); background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08); border-radius: 9px; padding: 7px; cursor: pointer; }
.md-tab.on { color: #fff; background: #2563eb; border-color: #2563eb; }
.md-search { width: 100%; box-sizing: border-box; font: inherit; font-size: 13px; color: var(--ink); background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.1); border-radius: 9px; padding: 8px 10px; margin-bottom: 8px; outline: none; }
.md-search:focus { border-color: #3b82f6; }
.md-list { max-height: 52vh; overflow-y: auto; display: grid; gap: 2px; }
.md-it { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; font: inherit; color: var(--ink); background: none; border: 0; border-radius: 9px; padding: 7px 8px; cursor: pointer; }
.md-it:hover { background: rgba(255,255,255,.06); }
.md-it.on { background: rgba(34,197,94,.15); }
.md-it img, .md-ph { width: 30px; height: 30px; border-radius: 7px; object-fit: contain; background: rgba(255,255,255,.08); display: grid; place-items: center; flex: none; font-size: 15px; }
.md-t { display: grid; min-width: 0; flex: 1; }
.md-t b { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.md-t small { color: var(--muted); font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.md-star { color: #f59e0b; }
.md-note { font-size: 11.5px; margin: 8px 6px 2px; }
.radiobar { display: flex; align-items: center; gap: 9px; padding: 4px 6px 4px 12px; margin-right: 8px; border-radius: 10px; background: rgba(34,197,94,.12); border: 1px solid rgba(34,197,94,.35); max-width: 330px; }
.radiobar[hidden] { display: none; }
.radiobar.err { background: rgba(220,38,38,.12); border-color: rgba(220,38,38,.4); }
.rb-t { display: grid; min-width: 0; line-height: 1.2; }
.rb-t b { font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 170px; }
.rb-t small { font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 170px; }
#rb-vol { width: 70px; accent-color: #22c55e; }
.rb-eq { display: flex; align-items: flex-end; gap: 2px; height: 14px; }
.rb-eq i { width: 3px; background: #22c55e; border-radius: 1px; animation: eq 0.9s infinite ease-in-out; }
.rb-eq i:nth-child(2) { animation-delay: .2s; } .rb-eq i:nth-child(3) { animation-delay: .45s; }
.radiobar.loading .rb-eq i, .radiobar.err .rb-eq i { animation: none; height: 3px; }
@keyframes eq { 0%, 100% { height: 3px; } 50% { height: 14px; } }
.rd-fav { width: 22px; height: 22px; border-radius: 5px; object-fit: contain; background: #fff; }
.rd-acts { display: flex; align-items: center; gap: 10px; margin-top: 8px; }
.rd-play { font: inherit; font-weight: 700; font-size: 13px; color: #fff; background: #16a34a; border: 0; border-radius: 8px; padding: 6px 12px; cursor: pointer; }
.tvwin { position: fixed; right: 300px; bottom: 96px; z-index: 25; width: 440px; padding: 0; overflow: hidden; resize: both; min-width: 260px; min-height: 180px; display: flex; flex-direction: column; }
.tvwin[hidden] { display: none; }
.tv-h { display: flex; align-items: center; gap: 8px; padding: 7px 10px; cursor: move; user-select: none; font-size: 13px; border-bottom: 1px solid rgba(255,255,255,.08); }
.tv-h b { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tv-h button { font: inherit; font-size: 18px; line-height: 1; color: var(--ink); background: none; border: 0; cursor: pointer; padding: 0 4px; }
.tvwin iframe { flex: 1; width: 100%; min-height: 220px; border: 0; background: #000; }
.maplibregl-marker.off-horizon { visibility: hidden !important; pointer-events: none !important; }

/* cintillo de noticias (CheckNews) sobre la barra de abajo */
.ticker { left: 324px; right: 300px; bottom: 84px; height: 36px; border-radius: 10px; z-index: 11; }
.ticker .tk-lbl { border-radius: 10px 0 0 10px; background: #d7263d; }
.ticker .tk-item { color: var(--ink); }
.ticker .tk-item em { background: rgba(255,255,255,.12); }
body.flying .ticker { display: flex; }
body.kiosk .ticker { left: 14px; right: 14px; bottom: 14px; }
@media (max-width: 900px) { .ticker { display: none; } }

.tvwin video { flex: 1; width: 100%; min-height: 220px; background: #000; }
.tvwin video[hidden], .tvwin iframe[hidden] { display: none; }
.tv-msg { margin: 0; padding: 40px 16px; text-align: center; color: var(--muted); background: #000; flex: 1; }
.tv-msg[hidden] { display: none; }

.cam-tl { display: block; width: 100%; margin: 8px 0 4px; padding: 7px 10px; border: 0; border-radius: 8px; background: #0b6bcb; color: #fff; font: inherit; font-weight: 600; cursor: pointer; }
.cam-tl:hover { filter: brightness(1.1); }
.cam-by { display: inline-block; margin-top: 4px; font-size: 11px; color: #0b6bcb; }

/* ================================================================ celular: se ve y se usa como app (PWA)
   Todo lo de aquí abajo aplica solo en pantallas de hasta 700 px; la vista de escritorio no cambia. */
.tabbar, .install-tip, .m-only { display: none !important; }
.m-link { all: unset; display: block; width: 100%; padding: 4px 0; cursor: pointer; color: var(--ink); }
.m-inst { border: 0; border-radius: 8px; padding: 6px 12px; background: var(--accent); color: #fff; font: 700 13px/1 inherit; font-family: inherit; cursor: pointer; white-space: nowrap; }
@media (max-width: 700px) {
  :root { --tab-h: calc(60px + env(safe-area-inset-bottom)); --top-h: calc(52px + env(safe-area-inset-top)); }
  html, body { overscroll-behavior: none; -webkit-tap-highlight-color: transparent; }
  body { -webkit-user-select: none; user-select: none; }
  input, textarea, .ev-list, .credits, .about { -webkit-user-select: text; user-select: text; }

  /* barra superior compacta */
  #topbar { height: var(--top-h); padding: env(safe-area-inset-top) 10px 0; gap: 8px; }
  .tb-logo { font-size: 19px; } .tb-logo svg { width: 32px; height: 20px; }
  #topbar .tb-sep, #topbar .tb-mode, #topbar .tb-clock, #topbar .tb-place, #btn-media, #btn-settings, #btn-info, #btn-help, #topbar .fab { display: none !important; }
  .tb-live { padding: 4px 10px; font-size: 12.5px; }
  #btn-msearch { display: flex !important; margin-left: auto; }
  #topbar .search { display: none; }
  body.m-search #topbar .search { display: flex; position: fixed; top: calc(var(--top-h) + 8px); left: 10px; right: 10px; max-width: none; height: 46px; z-index: 40; margin: 0; }
  body.m-search #topbar .search input { font-size: 16px; }

  /* clima: chip pequeño arriba a la derecha (se abre al tocarlo) */
  .col-right { top: calc(var(--top-h) + 8px); bottom: auto; right: 8px; width: auto; max-width: 62vw; }
  .col-right .aircraft, .col-right .mini { display: none; }
  .col-right .weather { padding: 6px 12px; cursor: pointer; }
  .col-right .weather .w-main { gap: 8px; align-items: center; }
  .col-right .weather .w-icon { font-size: 22px; }
  .col-right .weather .w-temp { font-size: 18px; }
  body:not(.m-wx) .col-right .weather :is(.w-cond, .w-wind, .w-grid) { display: none; }
  body.m-search .col-right { display: none; }

  /* capas y eventos: hojas que suben desde abajo */
  .col-left { position: fixed; left: 0; right: 0; top: auto; bottom: var(--tab-h); width: auto; max-height: 74vh; padding: 0; gap: 0;
    transform: translateY(calc(100% + var(--tab-h) + 20px)); transition: transform 0.28s cubic-bezier(.2, .8, .2, 1); z-index: 34; }
  body.m-capas .col-left, body.m-eventos .col-left { transform: none; }
  body.m-capas #card-events, body.m-eventos #card-layers, body:not(.m-capas):not(.m-eventos) .col-left .card { display: none; }
  .col-left .card { border-radius: 18px 18px 0 0; max-height: 74vh; flex: 1 1 auto; }
  .col-left .card .card-b { display: block !important; }
  .col-left .card-h { cursor: default; } .col-left .card-h .chev { display: none; }
  .col-left .card-h::before, .popover::before { content: ''; position: absolute; left: 50%; top: 6px; width: 38px; height: 4px; margin-left: -19px; border-radius: 2px; background: rgba(255, 255, 255, 0.22); }
  .col-left .card { position: relative; } .col-left .card-h { padding-top: 16px; }
  .layers { max-height: 74vh; }
  .lyr { min-height: 48px; }

  /* menús (ajustes, radio/TV/cámaras, info, ayuda): hojas desde abajo */
  .popover { left: 0; right: 0; top: auto; bottom: var(--tab-h); width: auto; max-height: 78vh; overflow-y: auto; border-radius: 18px 18px 0 0; padding: 22px 16px 14px; z-index: 36; }
  .popover .opt { min-height: 44px; }
  .popover .opt.m-only { display: flex !important; }
  .md-list { max-height: 50vh; }
  .md-it { min-height: 52px; }

  /* barra de pestañas */
  .tabbar { display: flex !important; position: fixed; left: 0; right: 0; bottom: 0; z-index: 37; height: var(--tab-h); padding: 0 4px env(safe-area-inset-bottom);
    background: rgba(7, 12, 24, 0.94); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); border-top: 1px solid var(--line); }
  .tabbar button { position: relative; flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; border: 0; background: none; color: #8d9ab0; font: 600 10.5px/1 inherit; font-family: inherit; cursor: pointer; }
  .tabbar svg { width: 23px; height: 23px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
  .tabbar button.on { color: var(--accent2); }
  .tabbar .tb-n { position: absolute; top: 6px; left: calc(50% + 6px); min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px; background: #e4572e; color: #fff; font: 700 10px/16px inherit; font-family: inherit; font-style: normal; text-align: center; }
  .tabbar .tb-n:empty { display: none; }

  /* barra de modo encima de las pestañas */
  #flightbar { left: 8px; right: 8px; bottom: calc(var(--tab-h) + 8px); height: 50px; padding: 0 6px 0 10px; gap: 4px; border-radius: 14px; }
  #flightbar .fb-mode > span, #flightbar .fb-mode > svg, #btn-full, #flightbar .fb-zoom, #flightbar .fb-follow { display: none !important; }
  #flightbar .fb-mode select { font-size: 15px; max-width: 46vw; }
  body.flying #flightbar .fb-stat { display: none; }
  body.flying #flightbar .fb-stat:first-of-type { display: inline; font-size: 12.5px; }
  .radiobar #rb-vol { display: none; }

  .timeline { left: 8px; right: 8px; bottom: calc(var(--tab-h) + 66px); }
  body.tm-open .col { bottom: var(--tab-h); }
  .tvwin { left: 8px; right: 8px; width: auto; bottom: calc(var(--tab-h) + 66px); resize: none; }
  .osm-c { bottom: calc(var(--tab-h) + 66px); }
  .maplibregl-ctrl-bottom-left, .maplibregl-ctrl-bottom-right { bottom: calc(var(--tab-h) + 60px); }
  body.flying .joy, body.flying .alt-btns { bottom: calc(var(--tab-h) + 70px) !important; }
  .heli-ui .hud { top: calc(var(--top-h) + 60px); }

  .install-tip { display: flex !important; position: fixed; left: 10px; right: 10px; top: calc(var(--top-h) + 8px); z-index: 38; align-items: center; gap: 10px; padding: 10px 10px 10px 12px; }
  .install-tip[hidden] { display: none !important; }
  .install-tip img { width: 42px; height: 42px; border-radius: 10px; flex: none; }
  .install-tip div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; font-size: 13.5px; }
  .install-tip small { color: var(--muted); font-size: 12px; }
  .install-tip .a-x { border: 0; background: none; color: var(--muted); font-size: 22px; cursor: pointer; padding: 0 4px; }
  .install-tip #tip-install[hidden] { display: none; }
}
@media (max-width: 700px) { body.m-search .install-tip, body.m-capas .install-tip, body.m-eventos .install-tip { display: none !important; } }
@media (max-width: 700px) { body.m-search #topbar .search { background: #0f1729; border: 1px solid rgba(255, 255, 255, 0.14); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45); border-radius: 12px; padding: 0 12px; } }

/* reclamaciones y páginas legales (panel ⓘ) */
.claim-btn { display: flex; align-items: center; gap: 10px; margin: 10px 0 2px; padding: 10px 12px; border-radius: 10px; border: 1px solid rgba(255, 255, 255, 0.1); background: rgba(255, 255, 255, 0.04); color: var(--ink); text-decoration: none; }
.claim-btn:hover { background: rgba(255, 255, 255, 0.08); }
.claim-btn svg { width: 22px; height: 22px; flex: none; fill: none; stroke: #ffb13b; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.claim-btn span { display: flex; flex-direction: column; } .claim-btn b { font-size: 13.5px; } .claim-btn small { color: var(--muted); font-size: 12px; }
.legal-l { margin: 12px 0 2px; padding-top: 10px; border-top: 1px solid var(--line); font-size: 12.5px; color: var(--muted); text-align: center; }
.legal-l a { color: #9cc4ff; text-decoration: none; } .legal-l a:hover { text-decoration: underline; }
