/* RadarLotow.pl – kierunek „Hala odlotów”: granatowy nagłówek, tablica jak na lotnisku, karta lotu jak karta pokładowa */
:root {
  --navy: #0b1f33;
  --navy-2: #13304d;
  --navy-line: #1b3a57;
  --navy-text: #9fb3c8;
  --yellow: #ffc20e;
  --bg: #ffffff;
  --bg-soft: #f3f5f7;
  --fg: #0b1f33;
  --fg-2: #24384f;
  --muted: #52637a;
  --line: #dce3ea;
  --line-2: #eef2f5;
  --brand: #0b1f33;
  --brand-dark: #13304d;
  --brand-soft: #e8eef5;
  --link: #1a5fb4;
  --accent: #ffc20e;
  --danger: #c0262d;
  --ok: #1f7a46;
  --alt-lo: #5aa9e6;
  --alt-mi: #2b6cb0;
  --alt-hi: #0b1f33;
  --alt-mil: #6b7a3a;
  --shadow: 0 4px 14px rgba(11, 31, 51, .10);
  --shadow-lg: 0 14px 34px rgba(11, 31, 51, .18);
  --radius: 12px;
  --rail-w: 0px;
  --panel-w: 392px;
  --hd-h: 64px;
  --sb-h: 52px;
  --sans: "Barlow", system-ui, -apple-system, "Segoe UI", sans-serif;
  --cond: "Barlow Condensed", "Barlow", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  font-family: var(--sans);
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg-soft); color: var(--fg); font-size: 15px; }
a { color: var(--link); }
a:hover { color: var(--navy); }
button { font: inherit; cursor: pointer; color: inherit; }
.mono { font-family: var(--mono); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* logo (także w stopce podstron) */
.rl-logo { display: flex; align-items: center; gap: 10px; font-family: var(--cond); font-weight: 800; font-size: 24px; color: var(--fg); text-decoration: none; white-space: nowrap; }
.rl-logo:hover { color: var(--fg); }
.rl-logo svg { width: 34px; height: 34px; }
.rl-logo span b { color: var(--yellow); -webkit-text-stroke: 0; }

/* ---------- Nagłówek ---------- */
.hd {
  position: fixed; inset: 0 0 auto 0; height: var(--hd-h); z-index: 40; background: var(--navy);
  display: flex; align-items: center; gap: 18px; padding: 0 20px;
}
.hd-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; flex: none; }
.hd-mark { width: 36px; height: 36px; border-radius: 8px; background: var(--yellow); display: grid; place-items: center; flex: none; }
.hd-mark svg { width: 22px; height: 22px; fill: var(--navy); }
.hd-name { font-family: var(--cond); font-size: 25px; font-weight: 800; color: #fff; letter-spacing: .01em; }
.hd-name b { color: var(--yellow); }
.hd .rl-search { flex: 0 1 440px; margin-left: 8px; }
.hd .rl-search input { height: 40px; border-radius: 8px; border: 1px solid #234563; background: var(--navy-2); color: #fff; box-shadow: none; font-size: 15px; padding: 0 40px 0 42px; }
.hd .rl-search input::placeholder { color: var(--navy-text); }
.hd .rl-search input:focus { border-color: var(--yellow); box-shadow: 0 0 0 3px rgba(255, 194, 14, .25); }
.hd .rl-search > svg { top: 11px; left: 14px; color: var(--navy-text); }
.hd .rl-search .kbd { top: 9px; border-color: #234563; color: var(--navy-text); }
.hd .rl-results { top: 46px; }
.hd-nav { display: flex; align-self: stretch; margin-left: auto; }
.hd-nav a { display: flex; align-items: center; padding: 0 13px; color: #d5dee8; text-decoration: none; font-weight: 600; font-size: 15px; border-bottom: 3px solid transparent; border-top: 3px solid transparent; white-space: nowrap; }
.hd-nav a:hover { color: #fff; }
.hd-nav a.on { color: var(--yellow); font-weight: 700; border-bottom-color: var(--yellow); }
.hd-embed { height: 38px; display: flex; align-items: center; gap: 8px; padding: 0 14px; border-radius: 8px; border: 1.5px solid var(--yellow); background: transparent; color: var(--yellow); font-weight: 700; font-size: 14px; white-space: nowrap; }
.hd-embed:hover { background: var(--yellow); color: var(--navy); }
.hd-embed svg, .hd-searchbtn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.hd-searchbtn { display: none; }

/* ---------- Pasek filtrów ---------- */
.sb {
  position: fixed; left: 0; right: 0; top: var(--hd-h); height: var(--sb-h); z-index: 30; background: #fff; border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 14px; padding: 0 20px;
}
.seg-b { display: flex; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; flex: none; }
.seg-b button { height: 34px; padding: 0 13px; border: 0; border-left: 1px solid var(--line); background: #fff; color: var(--fg); font-size: 14px; font-weight: 600; white-space: nowrap; }
.seg-b button:first-child { border-left: 0; }
.seg-b button:hover { background: var(--bg-soft); }
.seg-b button.on { background: var(--navy); color: #fff; font-weight: 700; }
.seg-b .ci { display: none; }
.sb-tools { display: flex; align-items: center; gap: 6px; }
.tb { height: 34px; padding: 0 12px; border-radius: 8px; border: 1px solid var(--line); background: #fff; color: var(--fg); font-size: 14px; font-weight: 600; white-space: nowrap; }
.tb:hover { background: var(--bg-soft); }
.tb.on { border-color: var(--navy); background: var(--bg-soft); font-weight: 700; }
.tb.on::before { content: "✓ "; }
.tb[data-basemenu].on::before, .tb[data-view].on::before { content: ""; }
.sb-jump { margin-left: auto; display: flex; flex: none; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.sb-jump button { height: 34px; display: flex; align-items: center; gap: 6px; padding: 0 12px; border: 0; border-left: 1px solid var(--line); background: #fff; color: var(--fg); font-size: 14px; font-weight: 600; white-space: nowrap; }
.sb-jump button:first-child { border-left: 0; }
.sb-jump button:hover { background: var(--bg-soft); }
.sb-jump button:active { background: var(--navy); color: #fff; }
.sb-jump svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.base-wrap { position: relative; }
.base-pop { position: absolute; top: 42px; left: 0; z-index: 45; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); padding: 8px; display: grid; grid-template-columns: repeat(2, 104px); gap: 6px; }
.base-pop[hidden] { display: none; }
.base-pop button, .base-grid button { display: flex; flex-direction: column; align-items: stretch; gap: 6px; padding: 6px; border-radius: 10px; border: 2px solid transparent; font-size: 13px; font-weight: 700; color: var(--fg-2); background: transparent; text-align: center; }
.base-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.base-grid button { border-color: var(--line); background: #fff; }
.base-pop button.on, .base-grid button.on { border-color: var(--navy); color: var(--navy); background: var(--brand-soft); }
.sw { display: block; height: 46px; border-radius: 7px; border: 1px solid rgba(11,31,51,.08); }
.sw-jasna { background: linear-gradient(135deg, transparent 46%, #d9dde3 46% 50%, transparent 50%), radial-gradient(circle at 30% 70%, #cfe1f2 0 18%, transparent 19%), #f4f5f2; }
.sw-kolorowa { background: linear-gradient(135deg, transparent 44%, #f9c97a 44% 50%, transparent 50%), radial-gradient(circle at 30% 70%, #9ccbf0 0 18%, transparent 19%), linear-gradient(#e6efd8, #dfead0); }
.sw-ciemna { background: linear-gradient(135deg, transparent 46%, #4b5565 46% 50%, transparent 50%), radial-gradient(circle at 30% 70%, #1d2b3d 0 18%, transparent 19%), #2b2f36; }
.sw-satelita { background: radial-gradient(circle at 70% 30%, #6d7f4f 0 20%, transparent 22%), radial-gradient(circle at 25% 75%, #1f4e6b 0 22%, transparent 24%), linear-gradient(135deg, #4a5d36, #7b7552 60%, #3e4a2c); }
.rl-fbadge { height: 34px; display: flex; align-items: center; gap: 8px; padding: 0 12px; border-radius: 8px; border: 1px solid #f5c344; background: #fff7dc; color: #8a5a00; font-size: 13px; font-weight: 700; max-width: 320px; }
.rl-fbadge[hidden] { display: none; }
.rl-fbadge span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- Mapa ---------- */
.mw { position: fixed; top: calc(var(--hd-h) + var(--sb-h)); left: 0; right: var(--panel-w); bottom: 0; background: #e9edf1; }
#map { position: absolute; inset: 0; background: #e9edf1; }
body.embed #map { position: fixed; inset: 0; }
.maplibregl-ctrl-attrib { font-size: 11px; }
.maplibregl-ctrl-attrib.maplibregl-compact { min-height: 24px; }
.maplibregl-ctrl-attrib.maplibregl-compact:not([open]) .maplibregl-ctrl-attrib-inner { display: none; }
.maplibregl-ctrl-attrib.maplibregl-compact:not([open]) { padding: 0; background: rgba(255,255,255,.85); }
.maplibregl-ctrl-group { border-radius: 8px !important; box-shadow: none !important; border: 1px solid var(--line); overflow: hidden; }
.maplibregl-ctrl-group button { width: 40px !important; height: 40px !important; }
.lg { position: absolute; left: 14px; bottom: 14px; z-index: 5; display: flex; align-items: center; gap: 10px; background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 7px 12px; font-size: 13px; font-weight: 600; color: var(--muted); }
.lg.off { display: none; }
.lg .k { display: flex; align-items: center; gap: 5px; }
.lg .k i { width: 12px; height: 12px; border-radius: 3px; }
.rl-counter { position: absolute; left: 10px; bottom: 10px; z-index: 5; background: rgba(255,255,255,.95); border-radius: 8px; padding: 5px 10px; font-size: 12px; font-weight: 600; box-shadow: 0 1px 4px rgba(0,0,0,.15); pointer-events: none; }
.rl-notice { position: absolute; left: 50%; top: 16px; transform: translateX(-50%); z-index: 6; background: var(--navy); color: #fff; padding: 8px 14px; border-radius: 8px; font-size: 13px; font-weight: 600; display: none; white-space: nowrap; max-width: 90%; overflow: hidden; text-overflow: ellipsis; }
body.embed .rl-top { top: 62px; }
.rl-notice.show { display: block; }

/* karta „coś się dzieje” u góry mapy */
.rl-top { position: absolute; left: 50%; top: 14px; transform: translateX(-50%); z-index: 6; display: flex; flex-direction: column; align-items: center; gap: 8px; width: max-content; max-width: calc(100% - 120px); pointer-events: none; }
.rl-top > * { pointer-events: auto; }
.rl-top .rl-notice { position: static; transform: none; max-width: 100%; }
.rl-alert { display: none; align-items: center; gap: 10px; max-width: 100%; padding: 6px 6px 6px 12px; border-radius: 10px; background: var(--yellow); color: var(--navy); box-shadow: var(--shadow-lg); font-size: 14px; }
.rl-alert.show { display: flex; }
.rl-alert.emg { background: #c0262d; color: #fff; }
.rl-alert .ic { flex: none; font-size: 15px; font-weight: 800; }
.rl-alert .tx { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rl-alert .go { flex: none; height: 30px; padding: 0 12px; border: 0; border-radius: 7px; background: var(--navy); color: var(--yellow); font-weight: 800; font-size: 13px; }
.rl-alert.emg .go { background: #fff; color: #c0262d; }
.rl-alert .x { flex: none; width: 30px; height: 30px; border: 0; border-radius: 7px; background: transparent; color: inherit; font-size: 20px; line-height: 1; opacity: .75; }
.rl-alert .x:hover { opacity: 1; background: rgba(11,31,51,.08); }

/* ---------- Wyszukiwarka ---------- */
.rl-search { position: relative; }
.rl-search input { width: 100%; height: 46px; padding: 0 42px; border: 1px solid var(--line); border-radius: 10px; background: #fff; font: inherit; font-size: 15px; color: var(--fg); outline: none; box-shadow: var(--shadow); }
.rl-search input:focus { border-color: var(--navy); }
.rl-search > svg { position: absolute; left: 14px; top: 14px; width: 18px; height: 18px; color: var(--muted); pointer-events: none; }
.rl-search .kbd { position: absolute; right: 10px; top: 12px; font-family: var(--mono); font-size: 12px; color: var(--muted); border: 1px solid var(--line); border-radius: 5px; padding: 2px 7px; pointer-events: none; }
.rl-results { position: absolute; top: 52px; left: 0; right: 0; background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow-lg); max-height: 60vh; overflow: auto; display: none; z-index: 50; color: var(--fg); }
.rl-results.open { display: block; }
.rl-results .grp { padding: 10px 14px 4px; font-family: var(--mono); font-size: 11px; letter-spacing: .08em; color: var(--muted); font-weight: 700; text-transform: uppercase; }
.rl-results .item { display: flex; gap: 10px; align-items: center; padding: 9px 14px; cursor: pointer; }
.rl-results .item:hover, .rl-results .item.active { background: var(--brand-soft); }
.rl-results .item .ic { width: 30px; height: 30px; border-radius: 7px; background: var(--bg-soft); display: grid; place-items: center; flex: none; font-size: 15px; }
.rl-results .item .t { font-weight: 700; }
.rl-results .item .s { color: var(--muted); font-size: 13px; }
.rl-results .empty { padding: 12px 14px; color: var(--muted); }

/* ---------- Panel (prawa kolumna) ---------- */
.rl-panel { position: fixed; right: 0; top: calc(var(--hd-h) + var(--sb-h)); bottom: 0; width: var(--panel-w); z-index: 20; background: var(--bg-soft); border-left: 1px solid var(--line); overflow-y: auto; overscroll-behavior: contain; }
.sheet-handle { display: none; }
.pv { padding: 16px; display: flex; flex-direction: column; gap: 14px; }
.pv[hidden] { display: none; }
.pv h1 { margin: 0; font-family: var(--cond); font-size: 27px; font-weight: 800; line-height: 1.05; text-transform: uppercase; letter-spacing: .01em; }
.pv h2 { margin: 0; font-family: var(--cond); font-size: 24px; font-weight: 800; text-transform: uppercase; }
.pv .sub { margin: -8px 0 0; font-size: 15px; color: var(--muted); line-height: 1.45; }
.pv-head { display: flex; align-items: center; gap: 10px; }
.pv-head { align-items: flex-start; }
.pv-head h1 { flex: 1; min-width: 0; font-size: 25px; }
.pv-head .live-pill { margin-top: 2px; }
.live-pill { flex: none; display: inline-flex; align-items: center; gap: 7px; height: 28px; padding: 0 10px; border-radius: 99px; background: #fff; border: 1px solid var(--line); font-family: var(--mono); font-size: 12px; font-weight: 600; color: var(--muted); white-space: nowrap; }
.live-pill b { color: var(--fg); font-weight: 700; }
.live-pill i { width: 7px; height: 7px; border-radius: 50%; background: #1f9d55; box-shadow: 0 0 0 3px rgba(31,157,85,.18); }

/* rekordy chwili – 4 kafelki jak tablica odlotów */
.rec { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.rec-t { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; min-width: 0; padding: 10px 12px 11px; border-radius: 10px; border: 1px solid var(--line); background: #fff; text-align: left; color: var(--fg); position: relative; }
.rec-t::after { content: "→"; position: absolute; right: 10px; top: 9px; font-size: 13px; color: var(--muted); opacity: 0; transition: opacity .15s; }
.rec-t:not(:disabled):hover { border-color: var(--navy); }
.rec-t:not(:disabled):hover::after { opacity: 1; }
.rec-t:disabled { cursor: default; }
.rec-t .k { font-family: var(--mono); font-size: 10px; font-weight: 700; letter-spacing: .1em; color: var(--muted); }
.rec-t .v { font-family: var(--cond); font-size: 24px; font-weight: 800; line-height: 1.05; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rec-t .s { font-family: var(--mono); font-size: 11px; color: var(--muted); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rec-t:first-child { background: var(--navy); border-color: var(--navy); color: #fff; }
.rec-t:first-child .k, .rec-t:first-child .s { color: var(--navy-text); }
.rec-t:first-child .v { color: var(--yellow); }
.back { align-self: flex-start; border: 0; background: transparent; padding: 0; font-size: 15px; font-weight: 700; color: var(--fg); }
.back:hover { text-decoration: underline; }

/* tablica (FIDS) */
.fids { background: var(--navy); border-radius: var(--radius); overflow: hidden; color: #fff; }
.fids-h { display: flex; align-items: center; gap: 4px; padding: 12px 14px 0; }
.fids-t { white-space: nowrap; font-family: var(--mono); font-size: 12px; font-weight: 700; letter-spacing: .1em; color: var(--yellow); margin-right: auto; }
.ft { white-space: nowrap; height: 28px; padding: 0 7px; border-radius: 6px; border: 0; background: transparent; color: var(--navy-text); font-family: var(--mono); font-size: 11px; font-weight: 700; letter-spacing: .03em; }
.ft:hover { color: #fff; }
.ft.on { background: var(--yellow); color: var(--navy); }
.fids-sub, .rl-panel .fids-sub { margin: 6px 14px 0; font-size: 13px; color: #c3d1df; line-height: 1.45; }
.fids-sub a { color: var(--yellow); }
.fids-seg { display: flex; gap: 4px; padding: 10px 14px 0; flex-wrap: wrap; }
.fids-seg button { height: 28px; padding: 0 9px; border-radius: 6px; border: 1px solid var(--navy-line); background: transparent; color: var(--navy-text); font-family: var(--mono); font-size: 11px; font-weight: 700; }
.fids-seg button.on { background: var(--yellow); border-color: var(--yellow); color: var(--navy); }
.fids-top { display: flex; align-items: center; gap: 8px; padding: 13px 14px 0; }
.fids-top .fids-t { margin-right: auto; }
.fids-live { font-family: var(--mono); font-size: 10px; font-weight: 700; letter-spacing: .08em; color: #6ee7a0; border: 1px solid rgba(110,231,160,.4); border-radius: 4px; padding: 2px 6px; }
.fids-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 3px; margin: 10px 14px 0; padding: 3px; background: var(--navy-2); border-radius: 8px; }
.fids-tabs .ft { height: 30px; padding: 0 4px; border-radius: 6px; font-family: var(--sans); font-size: 13px; font-weight: 700; letter-spacing: 0; color: #c3d1df; }
.fids-tabs .ft:hover { color: #fff; background: rgba(255,255,255,.06); }
.fids-tabs .ft.on { background: var(--yellow); color: var(--navy); }
.fids-cols, .fr { display: grid; grid-template-columns: 84px minmax(0, 1fr) 58px; gap: 0 10px; }
.fids-cols { padding: 10px 14px 4px; font-family: var(--mono); font-size: 10px; font-weight: 700; letter-spacing: .08em; color: #6f87a0; }
.fids-cols span:last-child, .fr .a { text-align: right; }
.fr { width: 100%; align-items: center; padding: 8px 14px; border: 0; border-top: 1px solid var(--navy-line); background: transparent; color: #fff; font-family: var(--mono); font-size: 14px; font-weight: 600; text-align: left; text-decoration: none; }
.fr:hover { background: var(--navy-2); color: #fff; }
.fr .c { color: var(--yellow); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; line-height: 1.2; }
.fr .c em { display: block; width: max-content; max-width: 100%; margin-top: 3px; padding: 1px 5px; border-radius: 4px; background: var(--navy-2); color: #c3d1df; font-style: normal; font-size: 10px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; overflow: hidden; text-overflow: ellipsis; }
.fr.lpr .c em { background: #c0262d; color: #fff; }
.fr.emg .c em { background: #ff8a8a; color: #3a1620; }
.fr .d { min-width: 0; font-family: var(--sans); font-size: 14px; font-weight: 600; line-height: 1.25; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fr .d small { display: block; color: var(--navy-text); font-size: 12px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fr .a { font-size: 13px; }
.fr.emg { background: #3a1620; }
.fr.emg .c { color: #ff8a8a; }
.fids-empty { padding: 12px 14px; border-top: 1px solid var(--navy-line); color: var(--navy-text); font-size: 13px; }
.fids-more { display: block; padding: 10px 14px; border-top: 1px solid var(--navy-line); color: var(--yellow); font-family: var(--mono); font-size: 12px; font-weight: 700; letter-spacing: .04em; text-decoration: none; }
.fids-more:hover { color: #fff; }

.box { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; }
.box-t { font-family: var(--mono); font-size: 11px; font-weight: 700; letter-spacing: .1em; color: var(--muted); margin-bottom: 4px; }
.box-h { display: flex; align-items: baseline; gap: 8px; margin-bottom: 6px; }
.box-h .box-t { margin: 0; flex: 1; }
.box-n { font-family: var(--mono); font-size: 11px; color: var(--muted); white-space: nowrap; }
.box-empty { margin: 6px 0 !important; font-size: 13px; color: var(--muted); }
.box-hint { margin: 8px 0 0 !important; font-size: 12px !important; color: var(--muted); }
/* linie lotnicze */
.al-list { display: flex; flex-direction: column; gap: 4px; }
.al-row { position: relative; display: flex; align-items: center; gap: 10px; width: 100%; height: 34px; padding: 0 10px; border: 0; border-radius: 7px; background: var(--bg-soft); color: var(--fg); font-size: 14px; font-weight: 600; text-align: left; overflow: hidden; }
.al-row i { position: absolute; left: 0; top: 0; bottom: 0; background: #dfe7f0; border-radius: 7px; z-index: 0; transition: width .4s; }
.al-row span { position: relative; z-index: 1; }
.al-row .n { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.al-row .c { font-family: var(--mono); font-weight: 700; font-size: 13px; }
.al-row:hover { outline: 1px solid var(--navy); }
.al-row.on { background: #fff3c4; }
.al-row.on i { background: var(--yellow); }
/* lotniska – ruch teraz */
.ap-live a { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line-2); color: var(--fg); text-decoration: none; }
.ap-live a:last-child { border-bottom: 0; }
.ap-live a:hover .nm { text-decoration: underline; }
.ap-live .code { font-family: var(--mono); font-weight: 700; font-size: 13px; background: var(--navy); color: var(--yellow); border-radius: 5px; text-align: center; padding: 3px 0; }
.ap-live .nm { font-weight: 600; font-size: 15px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ap-live .meter { display: block; height: 4px; margin-top: 5px; background: var(--line-2); border-radius: 99px; overflow: hidden; }
.ap-live .meter i { display: block; height: 100%; background: var(--alt-mi); border-radius: 99px; transition: width .4s; }
.ap-live .ct { text-align: right; font-family: var(--mono); line-height: 1.2; }
.ap-live .ct b { font-size: 15px; }
.ap-live .ct small { display: block; font-size: 11px; color: var(--muted); }
.pv-foot { display: flex; flex-direction: column; gap: 12px; }
.pv-embed { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; color: var(--fg); text-align: left; }
.pv-embed:hover { border-color: var(--navy); }
.pv-embed .i { flex: none; width: 36px; height: 36px; border-radius: 9px; background: var(--navy); color: var(--yellow); display: grid; place-items: center; }
.pv-embed .i svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.pv-embed .t { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.pv-embed b { font-size: 15px; }
.pv-embed small { font-size: 13px; color: var(--muted); }
.pv-embed .go { font-weight: 700; color: var(--muted); }
.pv-foot .mini-links { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border-top: 1px solid var(--line); padding-top: 4px; }
.pv-foot .mini-links a { padding: 6px 0; font-size: 14px; color: var(--fg-2); }
.pv-foot .mini-links a:hover { color: var(--fg); text-decoration: underline; }
.pv-foot .credit-note { font-size: 12px; }
.box-more { display: block; margin-top: 8px; font-size: 14px; font-weight: 700; text-decoration: none; color: var(--fg); }
.ap-list a { display: grid; grid-template-columns: 48px minmax(0, 1fr) auto; gap: 8px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line-2); color: var(--fg); text-decoration: none; }
.ap-list a:last-child { border-bottom: 0; }
.ap-list a:hover .nm { text-decoration: underline; }
.ap-list .code { font-family: var(--mono); font-weight: 700; }
.ap-list .nm { font-weight: 600; font-size: 15px; }
.ap-list .ct { font-family: var(--mono); font-size: 12px; color: var(--muted); white-space: nowrap; }

.cta { display: block; padding: 12px 14px; border-radius: var(--radius); background: #fff; border: 1px solid var(--line); color: var(--fg); font-weight: 700; font-size: 15px; text-decoration: none; }
.cta span { color: var(--link); }
.cta:hover { color: var(--fg); border-color: var(--navy); }
.mini-links { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13px; }
.mini-links a, .mini-links button { color: var(--muted); text-decoration: none; font-weight: 600; border: 0; background: none; padding: 0; font-size: 13px; }
.mini-links a:hover, .mini-links button:hover { color: var(--fg); }
.mini-links button { color: var(--link); }
.credit-note { font-size: 12px; color: var(--muted); line-height: 1.5; margin: 0; }

.fl-field { margin-top: 2px; }
.fl-field label, .fl-lbl { display: block; font-family: var(--mono); font-size: 11px; font-weight: 700; letter-spacing: .08em; color: var(--muted); margin-bottom: 6px; text-transform: uppercase; }
.fl-field input[type=text] { width: 100%; height: 42px; border: 1px solid var(--line); border-radius: 8px; padding: 0 12px; font: inherit; color: var(--fg); background: #fff; }
.fl-field input[type=range] { width: 100%; accent-color: var(--navy); }
.fl-range { display: flex; justify-content: space-between; font-family: var(--mono); font-size: 12px; color: var(--muted); }
.fl-check { display: flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 600; margin-top: 10px; }
.fl-check input { width: 18px; height: 18px; accent-color: var(--navy); }
.fl-field label.fl-check { display: flex; text-transform: none; letter-spacing: normal; font-family: var(--sans); font-size: 15px; font-weight: 600; color: var(--fg); margin: 10px 0 0; }
.seg { display: flex; gap: 6px; flex-wrap: wrap; }
.seg button { font-size: 14px; font-weight: 700; color: var(--fg-2); border: 1px solid var(--line); background: #fff; padding: 7px 12px; border-radius: 8px; }
.seg button.on { color: #fff; background: var(--navy); border-color: var(--navy); }

/* ---------- Karta lotu (karta pokładowa) ---------- */
.rl-panel .sec { padding: 0; }
.rl-panel p { margin: 0 0 8px; color: var(--muted); line-height: 1.5; }
#detail > .pv { gap: 14px; }
.pass { background: #fff; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.ac-photo { position: relative; aspect-ratio: 16/7; background: repeating-linear-gradient(135deg, #e3e9ef 0 12px, #dbe2ea 12px 24px) center/cover no-repeat; }
.ac-photo .credit { position: absolute; right: 10px; bottom: 8px; font-size: 11px; color: #fff; text-shadow: 0 1px 2px rgba(0,0,0,.8); text-decoration: none; }
.ac-photo.none { display: none; }
.pass-head { position: relative; }
.pass-x { position: absolute; right: 10px; top: 10px; width: 32px; height: 32px; border: 0; border-radius: 8px; background: rgba(255,255,255,.1); color: #fff; font-size: 20px; line-height: 1; display: none; }
.pass-x:hover { background: rgba(255,255,255,.2); }
/* lotnisko w panelu */
.ap-pass { position: relative; background: var(--navy); color: #fff; border-radius: 14px; overflow: hidden; }
.ap-pass .pass-x { display: block; }
.ap-pass-top { display: flex; align-items: center; gap: 12px; padding: 16px 52px 14px 16px; }
.ap-code { flex: none; background: var(--yellow); color: var(--navy); font-family: var(--cond); font-weight: 800; font-size: 32px; line-height: 1; padding: 6px 10px; border-radius: 8px; }
.ap-pass h2 { margin: 0; font-family: var(--cond); font-size: 22px; font-weight: 800; text-transform: uppercase; line-height: 1.05; color: #fff; }
.ap-sub { font-family: var(--mono); font-size: 12px; color: var(--navy-text); margin-top: 4px; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ap-pass-top > div { min-width: 0; }
.ap-pass-k { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--navy-line); }
.ap-pass-k div { padding: 10px 16px; }
.ap-pass-k div + div { border-left: 1px solid var(--navy-line); }
.ap-pass-k b { display: block; font-family: var(--mono); font-size: 22px; color: var(--yellow); }
.ap-pass-k span { font-family: var(--mono); font-size: 10px; letter-spacing: .06em; text-transform: uppercase; color: var(--navy-text); }
.ap-board-btn { display: flex; align-items: center; justify-content: space-between; padding: 13px 16px; border-radius: 10px; background: var(--yellow); color: var(--navy); font-weight: 800; font-size: 15px; text-decoration: none; }
.ap-board-btn:hover { color: var(--navy); filter: brightness(.96); }
.pass-head { background: var(--navy); padding: 12px 16px; color: #fff; }
.ac-head { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.ac-head .al { display: none; }
.ac-head .cs { font-family: var(--mono); font-size: 24px; font-weight: 700; }
.pass-head .ac-head .cs { color: var(--yellow); }
.ac-head .fn { font-family: var(--mono); color: var(--navy-text); font-size: 13px; }
.ac-head .st { margin-left: auto; align-self: center; font-family: var(--mono); font-size: 11px; font-weight: 700; color: var(--navy); background: #6ee7a0; padding: 3px 8px; border-radius: 4px; }
.ac-head .st.gnd { background: #c9d3dd; }
.ac-airline { font-size: 15px; font-weight: 600; margin-top: 2px; }
.ac-type { font-size: 14px; color: var(--navy-text); margin-top: 1px; }
.pass-head .badge { margin-top: 6px; }
.badge { display: inline-block; font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 4px; background: var(--bg-soft); color: var(--muted); vertical-align: middle; font-family: var(--mono); }
.badge.mil { background: #e3e8cf; color: #3f4a1c; }
.badge.est { background: #fff4d6; color: #8a5a00; }
.badge.emg { background: #fde2e2; color: var(--danger); }
.pass-route { padding: 16px 16px 12px; }
.route { display: grid; grid-template-columns: 1fr auto 1fr; align-items: end; gap: 8px; }
.route .ap { min-width: 0; }
.route .ap.r { text-align: right; }
.route .code { font-family: var(--cond); font-size: 44px; font-weight: 800; line-height: 1; }
.route .city { font-size: 14px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.route .mid { margin-bottom: 26px; }
.route .mid svg path { stroke: var(--navy); }
.route .tm { font-family: var(--mono); font-size: 13px; font-weight: 700; margin-top: 2px; }
.route .tm span { font-family: var(--sans); color: var(--muted); font-weight: 500; font-size: 13px; }
.progress { margin-top: 14px; height: 6px; background: #e6ebf0; border-radius: 99px; position: relative; }
.progress i { position: absolute; inset: 0 auto 0 0; background: var(--navy); border-radius: 99px; }
.progress i::after { content: ""; position: absolute; right: -7px; top: -5px; width: 16px; height: 16px; border-radius: 50%; background: var(--yellow); border: 3px solid var(--navy); box-sizing: border-box; }
.progress-meta { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 2px 12px; margin-top: 8px; font-size: 13px; color: var(--muted); }
.route-note { font-size: 12px; color: var(--muted); margin-top: 8px; }
.perf { position: relative; height: 18px; padding: 0 18px; background: linear-gradient(90deg, var(--line) 55%, transparent 0) center / 10px 2px repeat-x; background-clip: content-box; }
.perf::before, .perf::after { content: ""; position: absolute; top: 0; width: 18px; height: 18px; border-radius: 50%; background: var(--bg-soft); border: 1px solid var(--line); }
.perf::before { left: -10px; }
.perf::after { right: -10px; }
.grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.grid .kv { background: #fff; padding: 10px 12px; min-width: 0; }
.kv .k { font-size: 12px; color: var(--muted); font-weight: 600; }
.kv .v { font-family: var(--mono); font-size: 15px; font-weight: 700; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kv .v small { font-weight: 500; color: var(--muted); font-size: 11px; }
.pass .grid { border: 0; border-radius: 0; background: transparent; gap: 12px 10px; padding: 8px 16px 16px; }
.pass .grid .kv { background: transparent; padding: 0; }
.pass .kv .k { font-family: var(--mono); font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.pass .kv .v { font-size: 16px; }
.rl-panel #acLive .v small { display: none; }
.landing-alert { display: flex; width: 100%; min-height: 44px; align-items: center; justify-content: center; gap: 9px; padding: 9px 14px; border: 1px solid var(--navy); border-radius: 8px; background: var(--navy); color: #fff; font-size: 14px; font-weight: 700; }
.landing-alert:hover { filter: brightness(1.08); }
.landing-alert svg { width: 19px; height: 19px; flex: none; fill: none; stroke: var(--yellow); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.landing-alert.on { background: #e9f7ef; border-color: #2b8a57; color: #17643a; }
.landing-alert.on svg { stroke: currentColor; }
.landing-alert:disabled { opacity: .55; cursor: not-allowed; }
.landing-status { margin: -8px 2px 0; color: var(--muted); font-size: 12px; line-height: 1.4; text-align: center; }
.ac-actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.ac-actions button, .ac-actions a { display: flex; flex-direction: column; align-items: center; gap: 5px; padding: 10px 4px; border-radius: 8px; border: 1px solid var(--line); background: #fff; color: var(--fg); font-size: 13px; font-weight: 700; text-decoration: none; }
.ac-actions button:hover, .ac-actions a:hover { border-color: var(--navy); color: var(--fg); }
.ac-actions button.on { background: #e9f7ef; border-color: #2b8a57; color: #17643a; }
.ac-actions button:disabled { opacity: .55; cursor: not-allowed; }
.ac-actions a[data-hist] { background: var(--navy); border-color: var(--navy); color: var(--yellow); }
.ac-actions svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.sec-t { font-family: var(--mono); font-size: 11px; font-weight: 700; letter-spacing: .1em; color: var(--muted); margin: 0 0 8px; text-transform: uppercase; }
.info { display: grid; grid-template-columns: 128px minmax(0, 1fr); font-size: 14px; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: #fff; }
.info .k, .info .v { padding: 9px 12px; border-bottom: 1px solid var(--line-2); }
.info .k:nth-last-child(2), .info .v:last-child { border-bottom: 0; }
.info .k { color: var(--muted); font-size: 13px; background: #fafbfc; }
.info .v { font-weight: 700; min-width: 0; overflow-wrap: anywhere; }
.info .code { font-family: var(--mono); font-size: 11px; font-weight: 700; color: var(--navy); background: var(--brand-soft); padding: 2px 6px; border-radius: 4px; margin-left: 4px; }
.tabs { display: flex; gap: 6px; margin-bottom: 6px; }
.tabs button { border: 1px solid var(--line); border-radius: 6px; padding: 5px 10px; background: #fff; color: var(--muted); font-weight: 700; font-size: 13px; }
.tabs button.on { background: var(--navy); border-color: var(--navy); color: #fff; }
.chart { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 10px; }
.chart svg { width: 100%; height: 90px; display: block; }
.chart .empty { color: var(--muted); font-size: 13px; padding: 18px 0; text-align: center; }
.prev { display: flex; flex-direction: column; gap: 6px; font-size: 14px; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.prev div { display: grid; grid-template-columns: 74px 1fr auto; gap: 8px; }
.prev .cs { font-family: var(--mono); font-weight: 700; }
.prev .tm { font-family: var(--mono); color: var(--muted); font-size: 12px; }
.rl-close { position: absolute; top: 12px; left: 12px; height: 34px; padding: 0 12px; border: 0; border-radius: 8px; background: rgba(11,31,51,.8); color: #fff; font-size: 13px; font-weight: 700; z-index: 2; }

.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { border: 1px solid var(--line); background: #fff; border-radius: 8px; padding: 6px 10px; font-weight: 600; font-size: 14px; color: var(--fg); text-decoration: none; }
.chip:hover { border-color: var(--navy); color: var(--fg); }
.btn { border: 0; border-radius: 8px; padding: 11px 14px; font-weight: 700; background: var(--navy); color: #fff; }
.btn:hover { background: var(--navy-2); color: #fff; }
.btn.secondary { background: #fff; color: var(--fg); border: 1px solid var(--line); }
.btn.secondary:hover { background: var(--bg-soft); color: var(--fg); }
.btn.small { padding: 7px 10px; font-size: 13px; }
.actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.actions .btn { height: 44px; padding: 0 10px; font-size: 15px; }
.live-dot { display: none; }
.pill { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; padding: 4px 9px; border-radius: 6px; }
.pill.gnd { color: var(--muted); background: var(--bg-soft); }

/* reklama: widoczna dopiero, gdy w config.php jest identyfikator AdSense */
.ad-slot { display: none; }
.ad-slot.on { display: block; width: 100%; max-width: 336px; margin: 0 auto; }
.ad-slot.on::before { content: "Reklama"; display: block; font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.ad-slot.on ins { display: block; min-height: 250px; }

/* modal osadzania */
.rl-modal { position: fixed; inset: 0; z-index: 60; background: rgba(11,31,51,.55); display: none; align-items: center; justify-content: center; padding: 16px; }
.rl-modal.open { display: flex; }
.rl-modal .box { background: #fff; border-radius: 14px; width: min(920px, 100%); max-height: 92vh; overflow: auto; box-shadow: var(--shadow-lg); display: grid; grid-template-columns: 320px 1fr; padding: 0; border: 0; }
.rl-modal .form { padding: 20px; border-right: 1px solid var(--line); }
.rl-modal .form h2 { margin: 0 0 4px; font-family: var(--cond); font-size: 24px; text-transform: uppercase; }
.rl-modal .form p { color: var(--muted); margin: 0 0 16px; line-height: 1.5; }
.rl-modal label { display: block; font-size: 12px; font-weight: 700; color: var(--muted); margin: 12px 0 4px; }
.rl-modal input[type=text], .rl-modal select { width: 100%; height: 38px; border: 1px solid var(--line); border-radius: 8px; padding: 0 10px; font: inherit; }
.rl-modal .check { display: flex; gap: 8px; align-items: center; font-weight: 600; color: var(--fg); font-size: 14px; }
.rl-modal textarea { width: 100%; height: 130px; font: 12px/1.4 var(--mono); border: 1px solid var(--line); border-radius: 8px; padding: 8px; resize: vertical; margin-top: 12px; }
.rl-modal .actions { display: flex; }
.rl-modal .preview { padding: 20px; display: flex; flex-direction: column; gap: 8px; min-height: 420px; }
.rl-modal .preview iframe { flex: 1; width: 100%; border: 1px solid var(--line); border-radius: 10px; min-height: 380px; }

/* menu na telefonie */
.mnav { display: none; }

/* ---------- Embed ---------- */
body.embed { background: #e9edf1; }
body.embed .rl-panel { display: none; }
.em-bar { position: absolute; top: 10px; left: 10px; right: 64px; z-index: 12; display: flex; gap: 8px; align-items: flex-start; }
.em-bar .rl-search { flex: 1; max-width: 420px; }
.em-bar .rl-search input { height: 42px; }
.em-bar .rl-search > svg { top: 12px; }
.em-bar .rl-results { top: 48px; }
.em-brand { flex: none; display: flex; align-items: center; justify-content: center; gap: 8px; background: var(--navy); border-radius: 8px; padding: 0 12px 0 6px; height: 42px; min-width: 42px; box-sizing: border-box; font-size: 20px; font-weight: 800; text-decoration: none; color: #fff; white-space: nowrap; }
.em-brand:hover { color: #fff; }
.em-brand .hd-mark { width: 30px; height: 30px; border-radius: 6px; }
.em-brand .hd-mark svg { width: 18px; height: 18px; }
.em-brand b { color: var(--yellow); }
.em-card { position: absolute; left: 10px; right: 10px; bottom: 46px; z-index: 12; max-width: 380px; background: #fff; border-radius: 12px; box-shadow: var(--shadow-lg); padding: 12px 14px; display: none; }
.em-card.open { display: block; }
.em-card .grid { grid-template-columns: 1fr 1fr; }
.em-card .rl-close { left: auto; right: 8px; top: 8px; width: 28px; height: 28px; padding: 0; background: var(--bg-soft); color: var(--fg); font-size: 16px; }
.em-card .ac-head .st { display: none; }
.em-card .ac-type { color: var(--muted); }
.em-card .route .code { font-size: 32px; }
.em-card .more { display: inline-block; margin-top: 10px; font-weight: 700; text-decoration: none; }
body.embed .rl-counter { bottom: 46px; }

/* ---------- Węższe ekrany ---------- */
@media (max-width: 1560px) {
  .tb[data-layer="routes"], .tb[data-layer="airports"] { display: none; }
}
@media (max-width: 1300px) {
  .rl-fbadge { max-width: 200px; }
}
@media (max-width: 1100px) {
  .sb-jump { display: none; }
}
@media (max-width: 1180px) {
  .hd-nav a { padding: 0 9px; }
  .lg span:first-child { display: none; }
}

/* ---------- Telefon ---------- */
@media (max-width: 820px) {
  :root { --hd-h: 56px; --sb-h: 48px; --sheet-peek: 230px; }
  .hd { gap: 10px; padding: 0 12px; }
  .hd-name { font-size: 22px; }
  .hd-mark { width: 32px; height: 32px; }
  .hd-nav, .hd-embed, .hd .rl-search .kbd { display: none; }
  .hd .rl-search { display: none; position: fixed; left: 0; right: 0; top: var(--hd-h); padding: 8px 12px; background: var(--navy); margin: 0; flex: none; }
  body.search-open .hd .rl-search { display: block; }
  .hd .rl-search > svg { top: 19px; left: 26px; }
  .hd .rl-results { top: 54px; left: 12px; right: 12px; }
  .hd-searchbtn { display: grid; place-items: center; margin-left: auto; width: 44px; height: 44px; border-radius: 8px; border: 1px solid #234563; background: var(--navy-2); color: #fff; }
  .hd-searchbtn svg { width: 20px; height: 20px; }
  .sb { padding: 0 12px; gap: 8px; overflow-x: auto; scrollbar-width: none; }
  .sb::-webkit-scrollbar { display: none; }
  .sb-jump, .tb[data-layer], .tb[data-view] { display: none; }
  .seg-b button { height: 32px; padding: 0 11px; }
  .tb { height: 32px; }
  .mw { right: 0; bottom: 64px; }
  .lg { display: none; }
  .home .maplibregl-ctrl-bottom-right { bottom: var(--sheet-h, var(--sheet-peek)); }
  .rl-panel { top: auto; left: 0; right: 0; width: auto; bottom: 64px; height: var(--sheet-peek); border-left: 0; border-top: 1px solid var(--line); border-radius: 16px 16px 0 0; box-shadow: 0 -8px 24px rgba(11,31,51,.14); overflow: hidden; transition: height .25s ease; }
  .rl-panel.open { height: min(58vh, 560px); overflow-y: auto; -webkit-overflow-scrolling: touch; }
  .rl-panel.mini { height: 64px; cursor: pointer; }
  .rl-panel.mini::after, .rl-panel.mini .sheet-handle, .rl-panel.mini section { display: none !important; }
  .rl-panel.mini .sheet-mini { display: flex; }
  .rl-panel:not(.open) { touch-action: none; }
  .sheet-handle { display: block; width: 100%; height: 26px; border: 0; background: var(--bg-soft); position: sticky; top: 0; z-index: 3; touch-action: none; }
  .sheet-handle::before { content: ""; display: block; width: 44px; height: 5px; border-radius: 99px; background: #98a6b5; margin: 9px auto 0; }
  .rl-panel:not(.open)::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 22px; background: linear-gradient(rgba(243,245,247,0), var(--bg-soft)); pointer-events: none; z-index: 4; }
  .home:has(.rl-panel.open) .maplibregl-ctrl-bottom-right, .home:has(.rl-panel.open) .maplibregl-ctrl-bottom-left { bottom: var(--sheet-h, var(--sheet-peek)); }
  /* karta lotu na telefonie: najpierw nagłówek i trasa (widoczne w zwiniętym arkuszu), zdjęcie niżej */
  [data-pv="detail"] .back { display: none; }
  #detail > .pv { padding-top: 0; }
  .pass { display: flex; flex-direction: column; }
  .pass .ac-photo { order: 5; aspect-ratio: 16/7; }
  .pass-x { display: block; }
  .pass-head { padding-right: 52px; }
  .pass-route { padding: 12px 16px 10px; }
  .route .code { font-size: 34px; }
  .route .mid { margin-bottom: 20px; }
  .progress { margin-top: 10px; }
  .ac-head .st { position: absolute; right: 52px; top: 16px; margin: 0; }
  .ap-pass-top { padding-right: 52px; }
  /* przewijany pasek kategorii – cień po prawej sugeruje, że jest więcej */
  /* kategorie mieszczą się w całości – bez przewijania */
  .sb { overflow: visible; }
  /* kategorie jako zakładki z ikonami: ikona nad podpisem, wybrana z żółtą kreską */
  :root { --sb-h: 58px; }
  .sb { padding: 0; }
  .sb .seg-b { flex: 1; align-self: stretch; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); border: 0; border-radius: 0; }
  .sb .seg-b button { position: relative; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; padding: 0 2px; border: 0; background: transparent; color: var(--muted); font-family: var(--sans); font-size: 11.5px; font-weight: 600; letter-spacing: 0; -webkit-tap-highlight-color: transparent; }
  .sb .seg-b button:hover { background: transparent; }
  .sb .seg-b button.on { background: transparent; color: var(--navy); font-weight: 800; }
  .sb .seg-b button.on::after { content: ""; position: absolute; left: 20%; right: 20%; bottom: 0; height: 3px; border-radius: 3px 3px 0 0; background: var(--yellow); }
  .sb .seg-b .ci { display: block; width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
  .sb .seg-b .ci.f { fill: currentColor; stroke: none; }
  .sb .seg-b span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
}
@media (max-width: 380px) {
  .sb .seg-b button { font-family: var(--cond); font-size: 13px; }
}
@media (max-width: 820px) {
  .sb-tools { position: fixed; left: 12px; top: calc(var(--hd-h) + var(--sb-h) + 8px); z-index: 31; }
  .sb-tools:not(:has(.rl-fbadge:not([hidden]))) { display: none; }
  .rl-fbadge { max-width: calc(100vw - 90px); box-shadow: var(--shadow); }
  /* iPhone powiększa stronę przy polach z czcionką mniejszą niż 16 px */
  .rl-search input, .hs-form input, .hs-form select, .field input, .field select, .field textarea, .fl-field input[type=text] { font-size: 16px !important; }
  .pv { padding: 2px 12px 16px; gap: 12px; }
  .pv h1, .pv .sub, .pv-head { display: none; }
  .pv-live > * { order: 3; }
  .pv-live > .fids { order: 1; }
  .pv-live > .rec { order: 2; }
  .pv-live > .pv-foot { order: 4; }
  .rec-t .v { font-size: 21px; }
  .home .maplibregl-ctrl-bottom-left { bottom: var(--sheet-h, var(--sheet-peek)); }
  .rl-panel:not(.open) .pv h2 { font-size: 20px; }
  .ac-photo { aspect-ratio: 16/6; }
  .route .code { font-size: 38px; }
  .mnav { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); position: fixed; left: 0; right: 0; bottom: 0; height: 64px; z-index: 35; background: #fff; border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom); }
  .mnav a, .mnav button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; border: 0; border-top: 3px solid transparent; background: transparent; color: var(--muted); font-size: 11px; font-weight: 600; text-decoration: none; }
  .mnav .on { color: var(--fg); font-weight: 700; border-top-color: var(--yellow); }
  .mnav svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
  body:not(.embed) .maplibregl-ctrl-top-right .maplibregl-ctrl-group:has(.maplibregl-ctrl-zoom-in) { display: none; }
  .rl-top { top: 10px; max-width: calc(100% - 76px); left: 12px; transform: none; align-items: flex-start; }
  .rl-alert { font-size: 13px; width: 100%; }
  .rl-alert .tx { white-space: normal; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
  .rl-modal .box { grid-template-columns: 1fr; }
  .rl-modal { align-items: flex-end; padding: 0; }
  .rl-modal .box { border-radius: 16px 16px 0 0; max-height: 88vh; }
  .rl-modal .preview { display: none; }
  .rl-modal .form { border-right: 0; border-bottom: 1px solid var(--line); }
  .base-pop { position: fixed; top: calc(var(--hd-h) + var(--sb-h) + 6px); left: 12px; }
  .em-bar { right: 56px; }
  .em-brand { font-size: 18px; padding: 0 10px 0 6px; }
  .em-bar .rl-search { min-width: 0; }
  .rl-fbadge { height: 32px; flex: none; }
}
.live-pill.filt { border-color: #f5c344; background: #fff7dc; }

@media (max-width: 374px) {
  .fids-h { flex-wrap: wrap; row-gap: 6px; }
  .fids-t { width: 100%; }
  .sb .seg-b button { font-size: 12px; }
}
.rl-tip { position: absolute; z-index: 7; pointer-events: none; display: none; flex-direction: column; gap: 1px; min-width: 150px; max-width: 220px; background: var(--navy); color: #fff; border-radius: 8px; padding: 8px 10px; box-shadow: var(--shadow-lg); font-size: 12px; }
.rl-tip.show { display: flex; }
.rl-tip b { font-family: var(--mono); font-size: 14px; color: var(--yellow); }
.rl-tip span { color: #d5dee8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rl-tip .m { font-family: var(--mono); color: #fff; }

.rl-layers-ctrl { display: none; }
.rl-layers-ctrl svg { width: 20px; height: 20px; fill: none; stroke: var(--navy); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; display: block; margin: auto; }
@media (max-width: 820px) {
  body:not(.embed) .sb .base-wrap { display: none; }
}
.fids-live { white-space: nowrap; }
@media (max-width: 820px) {
  .mnav a, .mnav button { white-space: nowrap; letter-spacing: -.01em; }
}
@media (max-width: 374px) {
  .mnav a, .mnav button { font-size: 10px; }
}

/* zwinięty panel na telefonie: wysuwana zakładka */
.sheet-mini { display: none; align-items: center; gap: 12px; width: 100%; height: 64px; padding: 0 16px; border: 0; background: transparent; color: var(--fg); text-align: left; }
.sheet-mini .ic { flex: none; width: 36px; height: 36px; border-radius: 50%; background: var(--navy); display: grid; place-items: center; }
.sheet-mini .ic svg { width: 20px; height: 20px; fill: none; stroke: var(--yellow); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.sheet-mini .t { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.sheet-mini b { font-family: var(--cond); font-size: 18px; font-weight: 800; text-transform: uppercase; letter-spacing: .02em; line-height: 1.1; }
.sheet-mini small { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sheet-mini .go { flex: none; height: 32px; display: inline-flex; align-items: center; padding: 0 12px; border-radius: 99px; background: var(--yellow); color: var(--navy); font-size: 13px; font-weight: 800; }
