[hidden] { display: none !important; }
:root {
  --bg: #161618; --bg2: #1f1f22; --bg3: #2a2a2e; --line: #34343a; --fg: #ececec; --mut: #9a9aa2;
  --red: #e53935; --red2: #c62828; --orange: #fb8c00; --yellow: #fdd835; --green: #43a047; --blue: #5c9ded;
  --r: 10px; --safe-b: env(safe-area-inset-bottom, 0px);
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--fg); font: 15px/1.4 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
.boot { padding: 40px; text-align: center; color: var(--mut); }
.ic { width: 20px; height: 20px; flex: none; }
.muted { color: var(--mut); }
.center { text-align: center; }
.spacer { flex: 1; }
.grow { flex: 1; min-width: 0; }

/* ---------- Szkielet ---------- */
.app { display: flex; min-height: 100vh; }
.sidebar { display: none; }
.main { flex: 1; min-width: 0; display: flex; flex-direction: column; padding-bottom: calc(64px + var(--safe-b)); }
.topbar { position: sticky; top: 0; z-index: 500; display: flex; align-items: center; gap: 8px; padding: 10px 12px; padding-top: max(10px, env(safe-area-inset-top)); background: #1b1b1d; border-bottom: 1px solid var(--line); }
.topbar h1 { font-size: 17px; margin: 0; flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.icon-btn { background: none; border: 0; padding: 6px; border-radius: 8px; cursor: pointer; display: inline-flex; color: var(--fg); }
.icon-btn:hover { background: var(--bg3); }
.icon-btn:disabled { opacity: .3; }
.sync-ind { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--mut); padding: 4px 8px; border-radius: 20px; background: var(--bg2); }
.sync-ind i { width: 9px; height: 9px; border-radius: 50%; background: var(--green); }
.sync-ind.pend i, .sync-ind.run i { background: var(--orange); } .sync-ind.run i { animation: pulse 1s infinite; }
.sync-ind.off i { background: var(--mut); } .sync-ind.err i { background: var(--red); } .sync-ind.demo i { background: var(--blue); }
@keyframes pulse { 50% { opacity: .3; } }
.demo-bar { background: #233652; color: #cfe0ff; font-size: 12.5px; padding: 5px 12px; text-align: center; }
#view { padding: 12px; max-width: 1200px; width: 100%; margin: 0 auto; }

.bottomnav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 600; display: flex; justify-content: space-around; align-items: center; background: #1b1b1d; border-top: 1px solid var(--line); padding: 6px 4px calc(6px + var(--safe-b)); }
.bottomnav a { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 11px; color: var(--mut); padding: 4px 10px; min-width: 56px; }
.bottomnav a.active { color: var(--red); }
.scan-fab { width: 56px; height: 56px; margin-top: -26px; border-radius: 50%; border: 0; background: var(--red); color: #fff; display: grid; place-items: center; box-shadow: 0 4px 14px #0008; cursor: pointer; }
.scan-fab .ic { width: 26px; height: 26px; }
.scan-top { display: none; }

@media (min-width: 900px) {
  .sidebar { display: flex; flex-direction: column; width: 220px; flex: none; background: #1b1b1d; border-right: 1px solid var(--line); position: sticky; top: 0; height: 100vh; }
  .sidebar nav { display: flex; flex-direction: column; padding: 6px; gap: 2px; overflow: auto; }
  .sidebar nav a { display: flex; gap: 10px; align-items: center; padding: 9px 12px; border-radius: 8px; color: #cfcfd4; }
  .sidebar nav a:hover { background: var(--bg3); }
  .sidebar nav a.active { background: #3a1d1d; color: #fff; }
  .sidebar nav a.active .ic { color: var(--red); }
  .bottomnav { display: none; }
  .main { padding-bottom: 0; }
  .scan-top { display: inline-flex; }
  #view { padding: 16px 20px; }
}
.brand { font-weight: 800; font-size: 20px; padding: 18px 16px 12px; letter-spacing: .5px; }
.brand span { font-weight: 400; color: var(--mut); font-size: 14px; margin-left: 4px; }
.brand.big { font-size: 30px; padding: 0 0 4px; }

/* ---------- Przyciski ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 9px 14px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg3); cursor: pointer; white-space: nowrap; font-weight: 500; }
.btn:hover { filter: brightness(1.15); }
.btn:disabled { opacity: .45; cursor: default; }
.btn.primary { background: var(--red); border-color: var(--red); color: #fff; }
.btn.ghost { background: transparent; }
.btn.danger { color: #ff7b72; border-color: #5a2a2a; }
.btn.small { padding: 6px 10px; font-size: 13.5px; }
.btn.small .ic { width: 16px; height: 16px; }
.btn.block { width: 100%; }

/* ---------- Pasek narzędzi / filtry ---------- */
.toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 10px; }
.search { flex: 1 1 260px; display: flex; align-items: center; gap: 8px; background: var(--bg2); border: 1px solid var(--line); border-radius: 8px; padding: 0 10px; }
.search input { flex: 1; border: 0; background: transparent; padding: 10px 0; outline: none; min-width: 0; }
.toolbar select, .toolbar > input { background: var(--bg2); border: 1px solid var(--line); border-radius: 8px; padding: 9px 8px; }
.chips { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 6px; margin-bottom: 6px; scrollbar-width: none; align-items: center; }
.chip { flex: none; border: 1px solid var(--line); background: var(--bg2); border-radius: 20px; padding: 6px 12px; font-size: 13px; cursor: pointer; white-space: nowrap; }
.chip b { color: var(--mut); font-weight: 600; margin-left: 2px; }
.chip.on { background: #3a1d1d; border-color: var(--red); }
.chip:disabled { opacity: .4; }
.bulkbar { position: sticky; top: 52px; z-index: 50; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; background: #2b1c1c; border: 1px solid #5a2a2a; padding: 8px; border-radius: var(--r); margin-bottom: 8px; }
.bulk-count { font-weight: 600; margin-right: 6px; }

/* ---------- Listy ---------- */
.list-head { font-size: 12.5px; color: var(--mut); padding: 2px 4px 6px; }
.row { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: var(--bg2); border: 1px solid var(--line); border-radius: var(--r); margin-bottom: 6px; }
.row:hover { border-color: #4a4a52; }
.row.sel { border-color: var(--red); background: #2b1c1c; }
.row-main { flex: 1; min-width: 0; }
.row-top { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.row-sub { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.code { font-weight: 700; font-family: ui-monospace, Menlo, Consolas, monospace; letter-spacing: .3px; }
.code.hl { background: var(--yellow); color: #222; padding: 0 5px; border-radius: 4px; }
.model { color: #cfcfd4; font-size: 13.5px; }
.cb { width: 22px; height: 22px; border: 2px solid var(--mut); border-radius: 6px; display: grid; place-items: center; flex: none; }
.row.sel .cb { background: var(--red); border-color: var(--red); }
.cb .ic { width: 16px; height: 16px; }
.count { font-size: 13px; color: var(--mut); white-space: nowrap; }
.group-head { font-weight: 700; padding: 12px 4px 6px; color: #d0d0d6; }
.group-head b { font-size: 12px; background: var(--bg3); padding: 1px 7px; border-radius: 10px; margin-left: 4px; color: var(--mut); }
.empty { text-align: center; color: var(--mut); padding: 40px 16px; }
.more { width: 100%; margin-top: 6px; }

.pill { display: inline-flex; flex-direction: column; align-items: flex-end; font-size: 13px; font-weight: 600; padding: 4px 9px; border-radius: 8px; white-space: nowrap; flex: none; border-left: 4px solid; background: var(--bg3); }
.pill small { font-weight: 400; font-size: 11px; color: var(--mut); }
.s-red { border-color: var(--red); } .s-orange { border-color: var(--orange); } .s-yellow { border-color: var(--yellow); } .s-green { border-color: var(--green); } .s-brak { border-color: var(--mut); }
.flag { font-size: 11px; font-weight: 700; padding: 1px 6px; border-radius: 5px; background: var(--bg3); color: #ddd; }
.f-leg { background: #4a2d00; color: #ffb74d; } .f-wn { background: #1d3557; color: #90caf9; } .f-tr { background: #4a4300; color: var(--yellow); } .f-cr { background: #263d26; color: #a5d6a7; }

/* ---------- Szczegóły ---------- */
.detail { display: grid; gap: 12px; }
@media (min-width: 900px) { .detail { grid-template-columns: 1fr 1fr; align-items: start; } .detail > .head, .detail > .card:first-child { grid-column: 1 / -1; } }
.card { background: var(--bg2); border: 1px solid var(--line); border-radius: 12px; padding: 14px; }
.card h3 { margin: 0 0 10px; font-size: 14px; text-transform: uppercase; letter-spacing: .6px; color: var(--mut); }
.card h3 ~ h3 { margin-top: 16px; }
.head { border-left: 5px solid var(--line); }
.s-border-red { border-left-color: var(--red); } .s-border-orange { border-left-color: var(--orange); } .s-border-yellow { border-left-color: var(--yellow); } .s-border-green { border-left-color: var(--green); }
.head-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.big-code { font-size: 24px; font-weight: 800; font-family: ui-monospace, Menlo, monospace; }
.big-code.hl { background: var(--yellow); color: #222; padding: 0 8px; border-radius: 6px; display: inline-block; }
.flags-row { display: flex; gap: 6px; margin-top: 8px; }
.actions-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; }
.act { display: flex; align-items: center; justify-content: center; gap: 6px; padding: 12px 8px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg3); cursor: pointer; font-weight: 600; text-align: center; font-size: 14px; }
.act.primary { background: var(--red); border-color: var(--red); color: #fff; }
.act.strong { border-color: var(--red); }
.kv-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 8px 14px; margin-bottom: 8px; }
.kv { display: flex; flex-direction: column; font-size: 13px; }
.kv span { color: var(--mut); font-size: 12px; }
.kv b { font-weight: 500; word-break: break-word; }
.note { background: var(--bg3); border-radius: 8px; padding: 8px 10px; font-size: 13.5px; margin: 8px 0; }
.note.warn { background: #3d2e10; color: #ffd480; }
.note a { text-decoration: underline; }
.link-row { display: block; padding: 4px 0 10px; } .link-row span { color: var(--mut); font-size: 13.5px; }
.contact { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.hist { border-left: 2px solid var(--line); padding: 2px 0 8px 10px; margin-bottom: 6px; display: flex; flex-direction: column; gap: 4px; font-size: 14px; }
.hist a { display: flex; gap: 6px; align-items: center; } .hist .ic { width: 16px; height: 16px; color: var(--mut); }
.thumbs { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; align-items: center; }
.thumbs-label { width: 100%; font-size: 12px; color: var(--mut); }
.thumb { width: 92px; height: 92px; object-fit: cover; border-radius: 8px; background: var(--bg3); cursor: zoom-in; border: 1px solid var(--line); }
.thumb.missing { opacity: .3; }
.sig-row { display: flex; gap: 16px; flex-wrap: wrap; } .sig-row .thumb { width: 160px; height: 70px; object-fit: contain; background: #fff; }
.mini-card { display: flex; justify-content: space-between; gap: 10px; align-items: center; background: var(--bg3); border-radius: 10px; padding: 10px; margin-bottom: 8px; font-size: 14px; }
.lightbox { position: fixed; inset: 0; z-index: 3000; background: #000d; display: grid; place-items: center; padding: 12px; }
.lightbox img { max-width: 100%; max-height: 100%; border-radius: 6px; }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.tile { background: var(--bg2); border: 1px solid var(--line); border-radius: 12px; padding: 18px 10px; display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; }
.tile .ic { width: 28px; height: 28px; color: var(--red); }

/* ---------- Formularze ---------- */
.form { display: flex; flex-direction: column; gap: 12px; max-width: 720px; margin: 0 auto; }
.field { display: flex; flex-direction: column; gap: 4px; }
.field label { font-size: 13px; color: var(--mut); }
.field input, .field select, .field textarea, .input-btn input { background: var(--bg2); border: 1px solid var(--line); border-radius: 8px; padding: 10px; outline: none; width: 100%; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--red); }
.field input[readonly] { opacity: .7; }
.field.inline { flex-direction: column; } .field.inline input { padding: 8px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.checks { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.check { display: flex; align-items: center; gap: 8px; cursor: pointer; padding: 4px 0; }
.check input { width: 20px; height: 20px; accent-color: var(--red); }
.input-btn { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; } .input-btn input { flex: 1; min-width: 140px; }
.ckk-preview { font-size: 13px; margin-top: -8px; }
.form-actions { display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; margin-top: 6px; }
.form-actions.left { justify-content: flex-start; }
.subcard { background: var(--bg2); border: 1px solid var(--line); border-radius: 10px; padding: 10px; display: flex; flex-direction: column; gap: 10px; }
.seg { display: inline-flex; background: var(--bg2); border: 1px solid var(--line); border-radius: 9px; padding: 3px; gap: 3px; flex-wrap: wrap; }
.seg button, .seg label span { border: 0; background: none; padding: 7px 12px; border-radius: 7px; cursor: pointer; display: block; font-size: 14px; }
.seg button.on, .seg input:checked + span { background: var(--red); color: #fff; }
.seg.radio input { display: none; }
.photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; }
.photo-box { display: flex; gap: 10px; align-items: center; background: var(--bg2); border: 1px dashed var(--line); border-radius: 10px; padding: 8px; }
.photo-prev { width: 76px; height: 76px; object-fit: cover; border-radius: 8px; background: var(--bg3); flex: none; }
.photo-prev:not([src]) { visibility: hidden; width: 0; }
.photo-btns { display: flex; flex-direction: column; gap: 6px; }
.sigs { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.sig-wrap { background: #fff; border-radius: 10px; overflow: hidden; }
canvas.sig { width: 100%; height: 160px; display: block; touch-action: none; cursor: crosshair; }
.sig-existing { width: 100%; height: 160px; object-fit: contain; display: block; }
.sig-btns { display: flex; justify-content: flex-end; margin-top: 4px; }
.date-choice small { margin-top: 4px; }

/* ---------- Mapa ---------- */
.map-tools { display: flex; flex-direction: column; gap: 6px; margin-bottom: 8px; }
.map { height: calc(100vh - 260px); min-height: 360px; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); background: #222; }
.map.small { height: 260px; min-height: 0; margin-bottom: 10px; }
.legend { display: flex; gap: 6px; align-items: center; font-size: 12px; color: var(--mut); flex-wrap: wrap; }
.legend i:not(.pb), .pop-wagi i { width: 10px; height: 10px; border-radius: 50%; background: var(--c); display: inline-block; margin-left: 6px; }
.pin { width: 28px; height: 28px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); background: var(--c); border: 2px solid #fff3; display: grid; place-items: center; box-shadow: 0 2px 5px #0007; }
.pin span { transform: rotate(45deg); font-size: 11px; font-weight: 800; color: #111; }
.pin-hl { border: 3px solid #fff; }
.map-popup .pop-wagi { display: flex; flex-direction: column; gap: 3px; margin: 8px 0; max-height: 160px; overflow: auto; }
.map-popup .pop-wagi a { color: var(--fg); } .map-popup .pop-wagi i { margin: 0 6px 0 0; }
.pop-btns { display: flex; gap: 6px; flex-wrap: wrap; } .pop-btns .btn { color: var(--fg); }

/* ---------- Trasa ---------- */
.trasa-list { display: flex; flex-direction: column; gap: 10px; }
.stop-head { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 8px; }
.stop-no { width: 30px; height: 30px; border-radius: 50%; background: var(--yellow); color: #222; font-weight: 800; display: grid; place-items: center; flex: none; }
.updown { display: flex; flex-direction: column; }
.stop-waga { display: flex; align-items: center; gap: 8px; padding: 6px 0; border-top: 1px solid var(--line); flex-wrap: wrap; }
.stop-waga > a:first-child { flex: 1; min-width: 160px; }

/* ---------- Tabela ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 10px; }
.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tbl th, .tbl td { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; }
.tbl th { background: var(--bg3); font-weight: 600; color: #cfcfd4; position: sticky; top: 0; }
.tbl tr:hover td { background: #222226; }
.tbl a { color: var(--blue); }

/* ---------- Raport ---------- */
.report-form { align-items: flex-end; }
.rep-head h2 { margin: 6px 0 2px; }
.rep-item { background: var(--bg2); border: 1px solid var(--line); border-radius: 12px; padding: 12px; margin: 10px 0; break-inside: avoid; }
.rep-dates { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 10px 0; }
.rep-dates div { background: var(--bg3); border-radius: 8px; padding: 8px; display: flex; flex-direction: column; }
.rep-dates span { font-size: 12px; color: var(--mut); } .rep-dates b { font-size: 16px; } .rep-dates small { color: var(--mut); }
.rep-photos { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.rep-photos .thumb { width: 140px; height: 140px; }

/* ---------- Skaner ---------- */
.scanner { position: fixed; inset: 0; z-index: 4000; background: #000; display: flex; flex-direction: column; }
.scanner video { flex: 1; width: 100%; object-fit: cover; min-height: 0; }
.scan-frame { position: absolute; left: 10%; right: 10%; top: 28%; height: 22%; border: 3px solid var(--red); border-radius: 14px; box-shadow: 0 0 0 9999px #0006; pointer-events: none; }
.scan-bar { padding: 12px 12px calc(12px + var(--safe-b)); background: #111; display: flex; flex-direction: column; gap: 8px; }
.scan-msg { text-align: center; color: #ddd; }
.scan-manual { display: flex; gap: 6px; } .scan-manual input { flex: 1; background: #222; border: 1px solid #444; border-radius: 8px; padding: 10px; text-transform: uppercase; }

/* ---------- Okna, powiadomienia ---------- */
.modal-back { position: fixed; inset: 0; z-index: 5000; background: #0009; display: grid; place-items: center; padding: 16px; }
.modal { background: #26262a; border: 1px solid var(--line); border-radius: 14px; padding: 18px; max-width: 420px; width: 100%; }
.modal p { margin: 0 0 16px; white-space: pre-line; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; }
#toasts { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(84px + var(--safe-b)); z-index: 6000; display: flex; flex-direction: column; gap: 6px; align-items: center; pointer-events: none; }
.toast { background: #333338; padding: 10px 16px; border-radius: 10px; box-shadow: 0 4px 16px #0008; transition: opacity .4s; max-width: 90vw; }
.toast.ok { border-left: 4px solid var(--green); } .toast.err { border-left: 4px solid var(--red); }
.toast.out { opacity: 0; }
.fail { padding: 8px 0; border-bottom: 1px solid var(--line); } .fail .btn { margin-top: 4px; }

/* ---------- Logowanie ---------- */
.login-wrap { min-height: 100vh; display: grid; place-items: center; padding: 16px; }
.login { width: 100%; max-width: 380px; display: flex; flex-direction: column; gap: 12px; }
.login .err { color: #ff8a80; min-height: 1em; margin: 0; }
.login details { font-size: 13.5px; } .login summary { cursor: pointer; color: var(--mut); margin-bottom: 8px; }

/* ---------- Druk ---------- */
@media print {
  body { background: #fff; color: #000; }
  .sidebar, .topbar, .bottomnav, .no-print, .demo-bar, #toasts { display: none !important; }
  .main { padding: 0; } #view { padding: 0; max-width: none; }
  .rep-item { border: 1px solid #bbb; background: #fff; }
  .rep-dates div { background: #f2f2f2; } .muted, .rep-dates span { color: #555; }
  .note { background: #f6f6f6; color: #000; }
  .thumb { border: 1px solid #ccc; }
}

/* ---------- Odczyt tabliczki ---------- */
.modal.wide { max-width: 560px; max-height: 90vh; overflow: auto; }
.modal h3 { margin: 0 0 8px; }
.ocr-cechy { background: var(--bg3); border-radius: 8px; padding: 8px 10px; margin: 0 0 10px; font-weight: 600; }
.ocr-cechy.ok { background: #1f3a24; color: #b9f6ca; }
.ocr-tbl { margin-bottom: 12px; } .ocr-tbl td { white-space: normal; }
.ocr-tbl tr.eq td { opacity: .6; }
.ocr-tbl input { width: 18px; height: 18px; accent-color: var(--red); }
.ocr-btn { margin-top: 6px; align-self: flex-start; }
.photo-top .photo-field { background: #22262e; border: 1px solid #3a4150; border-radius: 10px; padding: 10px; }
.field input.filled, .field select.filled { border-color: var(--green); }
.ocr-info { color: #b9f6ca; }
.small { font-size: 12.5px; }
.ocr-tbl th, .ocr-tbl td { padding: 6px; white-space: normal; }
@media (max-width: 480px) { .modal.wide { padding: 14px 12px; } .ocr-tbl { font-size: 12.5px; } }

/* ---------- Mapa (własny komponent) ---------- */
.mm { position: relative; isolation: isolate; z-index: 0; overflow: hidden; background: #1c2833; touch-action: none; user-select: none; -webkit-user-select: none; cursor: grab; }
.mm:active { cursor: grabbing; }
.mm-stage { position: absolute; inset: 0; }
.mm-tiles, .mm-markers, .mm-popup-layer { position: absolute; inset: 0; }
.mm-tile { position: absolute; left: 0; top: 0; width: 256px; height: 256px; pointer-events: none; }
.mm-hastiles .mm-tile { filter: brightness(.82) saturate(.85); }
.mm-vec { position: absolute; left: 0; top: 0; pointer-events: none; }
.mm-pl { fill: #26343f; stroke: #8fa7b8; stroke-width: 1.5; }
.mm-hastiles:not(.mm-notiles) .mm-pl { fill: none; stroke: #e5393566; stroke-width: 2; }
.mm-city { fill: #8fa7b8; } .mm-city-l { fill: #b8c7d3; font-size: 11px; font-family: system-ui, sans-serif; paint-order: stroke; stroke: #1c2833; stroke-width: 3px; }
.mm-hastiles:not(.mm-notiles) .mm-city, .mm-hastiles:not(.mm-notiles) .mm-city-l { display: none; }
.mm-line { fill: none; stroke: #e53935; stroke-width: 3; stroke-dasharray: 7 6; opacity: .85; }
.mm-marker { position: absolute; left: 0; top: 0; cursor: pointer; }
.mm-marker.apteka { margin: -36px 0 0 -15px; }
.mm-marker.grupa { margin: -23px 0 0 -23px; }
.mm-marker em { position: absolute; left: 50%; top: 33px; transform: translateX(-50%); font-style: normal; font-size: 10.5px; white-space: nowrap; background: #000a; color: #fff; padding: 0 4px; border-radius: 4px; }
.pin { width: 30px; height: 30px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); background: var(--c); border: 2px solid #ffffff55; display: grid; place-items: center; box-shadow: 0 2px 6px #000a; }
.pin span { transform: rotate(45deg); font-size: 12px; font-weight: 800; color: #111; }
.pin-hl { border: 3px solid #fff; box-shadow: 0 0 0 3px var(--yellow), 0 2px 6px #000a; }
.cluster { width: 46px; height: 46px; border-radius: 50%; background: var(--c); color: #111; display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1; box-shadow: 0 0 0 5px color-mix(in srgb, var(--c) 35%, transparent), 0 2px 8px #000a; }
.cluster b { font-size: 15px; } .cluster small { font-size: 9px; font-weight: 600; }
.mm-zoom { position: absolute; right: 10px; top: 10px; display: flex; flex-direction: column; border-radius: 8px; overflow: hidden; box-shadow: 0 2px 6px #0008; z-index: 2; }
.mm-zoom button { width: 36px; height: 36px; border: 0; background: #26262a; color: #fff; font-size: 20px; cursor: pointer; }
.mm-zoom button + button { border-top: 1px solid #3a3a40; }
.mm-attr { position: absolute; right: 4px; bottom: 2px; font-size: 10px; color: #ccc; background: #0007; padding: 0 4px; border-radius: 3px; z-index: 2; }
.mm-notiles .mm-attr { display: none; }
.mm-popup { position: absolute; left: 0; top: 0; z-index: 10000; background: #26262a; color: var(--fg); border: 1px solid #3a3a40; border-radius: 12px; padding: 10px 12px; width: 300px; max-width: calc(100vw - 40px); box-shadow: 0 6px 24px #000c; cursor: auto; font-size: 13.5px; }
.mm-popup::after { content: ''; position: absolute; left: 50%; bottom: -7px; width: 12px; height: 12px; background: #26262a; border-right: 1px solid #3a3a40; border-bottom: 1px solid #3a3a40; transform: translateX(-50%) rotate(45deg); }
.mm-close { position: absolute; right: 6px; top: 4px; background: none; border: 0; color: var(--mut); font-size: 20px; cursor: pointer; }
.map-popup .pop-wagi a.dim { opacity: .55; }
.map-popup .pop-wagi .code { font-size: 12.5px; }
.map-wrap { display: flex; flex-direction: column; gap: 6px; }
.map-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.search.small { flex: 1 1 220px; } .search.small input { padding: 8px 0; }
.search-res { display: flex; flex-direction: column; } .search-res .row { width: 100%; text-align: left; cursor: pointer; color: var(--fg); }
.map-stats { font-size: 13px; }

/* ---------- Godziny otwarcia ---------- */
.hflag { display: inline-block; font-size: 11px; font-weight: 700; padding: 1px 6px; border-radius: 5px; margin-left: 4px; white-space: nowrap; vertical-align: middle; }
.h-short { background: #4a2d00; color: #ffb74d; } .h-wknd { background: #3b1f4f; color: #ce93d8; } .h-unk { background: var(--bg3); color: var(--mut); }
.pbs { position: absolute; left: 20px; top: -8px; display: flex; gap: 2px; }
.pb { display: inline-grid; place-items: center; min-width: 17px; height: 17px; padding: 0 3px; border-radius: 9px; font-size: 10px; font-weight: 800; font-style: normal; border: 1.5px solid #161618; line-height: 1; }
.pb-short { background: #ffb74d; color: #3a2200; } .pb-wknd { background: #ce93d8; color: #2a0f3a; }
.legend .pb { margin-left: 4px; }
.godz-box { display: flex; justify-content: space-between; align-items: center; gap: 10px; background: var(--bg3); border-radius: 10px; padding: 10px; margin: 8px 0 12px; flex-wrap: wrap; }
.pop-godz { margin-top: 4px; }
.stop-godz { margin-top: 3px; }
.link-btn { background: none; border: 0; color: var(--blue); cursor: pointer; font-size: 12.5px; padding: 0 4px; text-decoration: underline; }
.trasa-warn div { display: flex; align-items: center; gap: 6px; margin: 2px 0; }
.h-now { background: var(--bg3); border-radius: 8px; padding: 8px 10px; margin-bottom: 10px; }
.h-card { border: 1px solid var(--line); border-radius: 10px; padding: 10px; margin-bottom: 8px; position: relative; }
.h-src { position: absolute; right: 8px; top: 8px; font-size: 11px; font-weight: 700; padding: 1px 7px; border-radius: 5px; }
.h-src.google { background: #1d3557; color: #90caf9; } .h-src.osm { background: #263d26; color: #a5d6a7; }
.h-days { margin: 6px 0; padding-left: 18px; font-size: 13px; }
.lb-msg { position: absolute; bottom: 20px; left: 0; right: 0; text-align: center; color: #ddd; font-size: 13px; }

/* ---------- Weryfikacja zwrotów ---------- */
.s-blue { border-color: var(--blue); }
.pills { display: flex; flex-direction: column; gap: 4px; align-items: flex-end; }
.pill.small { font-size: 11px; padding: 2px 7px; }
.nbadge { background: var(--orange); color: #111; font-size: 11px; font-weight: 800; border-radius: 9px; padding: 0 6px; margin-left: auto; min-width: 18px; text-align: center; }
.bottomnav a { position: relative; } .bottomnav .nbadge { position: absolute; top: 0; right: 8px; margin: 0; }
.tile { position: relative; } .tile .nbadge { position: absolute; top: 8px; right: 8px; }
.wer-box { background: var(--bg3); border-radius: 10px; padding: 10px; margin: 10px 0; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.wer-card .note { margin: 10px 0; }
.wer-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: start; }
@media (max-width: 600px) { .wer-grid { grid-template-columns: 1fr; } }
.wer-grid .thumb { width: 130px; height: 130px; }
.wer-actions { display: flex; gap: 8px; align-items: flex-end; flex-wrap: wrap; margin-top: 10px; }
.wer-actions input { background: var(--bg2); border: 1px solid var(--line); border-radius: 8px; padding: 8px; }
