:root {
  --bg: #f3f4f6; --card: #fff; --ink: #1f2937; --muted: #6b7280; --line: #e5e7eb;
  --brand: #1d4ed8; --ok: #15803d; --ok-bg: #dcfce7; --bad: #b91c1c; --bad-bg: #fee2e2;
  --warn-bg: #fef3c7; --warn: #92400e; --closed: #e5e7eb;
  --hover: #e5e7eb; --bubble: #eef0f4; --bubble-mine: #dbeafe; --field: #fff; --code-bg: #f3f4f6;
  --foot-bg: #e5e7eb; --foot-ink: #6b7280; --foot-link: #374151;
  --mm-bg: #fef3c7; --mm-line: #f59e0b; --mm-hover: #fde68a;
  --st-bad: #b91c1c; --st-warn: #92400e; --st-ok: #15803d; --head-sep: #cbd5e1;
  --btn: #1d4ed8;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #111827; --card: #1f2937; --ink: #f3f4f6; --muted: #9ca3af; --line: #374151;
    --brand: #60a5fa; --ok: #86efac; --ok-bg: #14532d; --bad: #fca5a5; --bad-bg: #7f1d1d;
    --warn-bg: #78350f; --warn: #fde68a; --closed: #374151;
    --hover: #303b4e; --bubble: #303b4e; --bubble-mine: #234b68; --field: #293241; --code-bg: #101827;
    --foot-bg: #1e293b; --foot-ink: #94a3b8; --foot-link: #cbd5e1;
    --mm-bg: #5b481c; --mm-line: #b98a21; --mm-hover: #705821;
    --st-bad: #ff8b8b; --st-warn: #ffcb78; --st-ok: #86efac; --head-sep: #475569;
    --btn: #2563eb;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
    --bg: #111827; --card: #1f2937; --ink: #f3f4f6; --muted: #9ca3af; --line: #374151;
    --brand: #60a5fa; --ok: #86efac; --ok-bg: #14532d; --bad: #fca5a5; --bad-bg: #7f1d1d;
    --warn-bg: #78350f; --warn: #fde68a; --closed: #374151;
    --hover: #303b4e; --bubble: #303b4e; --bubble-mine: #234b68; --field: #293241; --code-bg: #101827;
    --foot-bg: #1e293b; --foot-ink: #94a3b8; --foot-link: #cbd5e1;
    --mm-bg: #5b481c; --mm-line: #b98a21; --mm-hover: #705821;
    --st-bad: #ff8b8b; --st-warn: #ffcb78; --st-ok: #86efac; --head-sep: #475569;
    --btn: #2563eb;
    color-scheme: dark;
}
* { box-sizing: border-box; }
body { margin: 0; font: 15px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; background: var(--bg); color: var(--ink); }
a { color: var(--brand); }
header.top { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; padding: 10px 16px; background: var(--card); border-bottom: 1px solid var(--line); }
header.top .brand { font-weight: 700; text-decoration: none; color: var(--ink); }
header.top nav { display: flex; gap: 4px; }
header.top nav a { padding: 4px 10px; border-radius: 6px; text-decoration: none; color: var(--ink); }
header.top nav a.on, header.top nav a:hover { background: var(--bg); }
header.top .who { margin-left: auto; color: var(--muted); font-size: 13px; }
main { max-width: 1100px; margin: 0 auto; padding: 18px 14px 60px; }
h1 { font-size: 22px; margin: 6px 0 14px; }
h2 { font-size: 17px; margin: 22px 0 8px; }
.flash { background: var(--warn-bg); color: var(--warn); padding: 8px 12px; border-radius: 8px; margin-bottom: 12px; }
.muted { color: var(--muted); }

/* kafelki */
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 14px; margin-top: 10px; }
.tile { display: block; text-decoration: none; color: var(--ink); background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 22px 14px; text-align: center; transition: transform .1s, box-shadow .1s; }
.tile:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0,0,0,.12); }
.tile .ico { font-size: 44px; display: block; margin-bottom: 8px; }
.tile b { display: block; font-size: 16px; }
.tile small { color: var(--muted); }
.tile.soon { opacity: .5; pointer-events: none; }

/* karty, tabele, formularze */
.card { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; margin-bottom: 14px; }
table { border-collapse: collapse; width: 100%; }
th, td { text-align: left; padding: 6px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
input, select, button { font: inherit; padding: 6px 10px; border-radius: 8px; border: 1px solid var(--line); background: var(--card); color: var(--ink); }
button, .btn { background: var(--btn); color: #fff; border-color: var(--btn); cursor: pointer; text-decoration: none; display: inline-block; padding: 6px 12px; border-radius: 8px; }
button.ghost, .btn.ghost { background: transparent; color: var(--brand); }
button.small { padding: 2px 8px; font-size: 13px; }
form.inline { display: inline-flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }

/* plakietki */
.chip { display: inline-block; border-radius: 999px; padding: 2px 10px; background: color-mix(in srgb, var(--c, #64748b) 18%, var(--card)); border: 1px solid var(--c, #64748b); font-size: 13px; }
.chip small { color: var(--muted); }
.chip.none { --c: #b91c1c; background: var(--bad-bg); color: var(--bad); }
.dot { display: inline-block; width: 11px; height: 11px; border-radius: 50%; margin-right: 6px; vertical-align: -1px; }
.badge { display: inline-block; font-size: 12px; padding: 1px 8px; border-radius: 6px; }
.badge.ok { background: var(--ok-bg); color: var(--ok); }
.badge.bad { background: var(--bad-bg); color: var(--bad); }
.badge.sub { background: var(--warn-bg); color: var(--warn); }

/* kalendarz */
.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.cal .dow { text-align: center; font-size: 12px; color: var(--muted); padding: 2px; }
.cal .day { min-height: 86px; background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 6px 7px; text-decoration: none; color: var(--ink); display: block; font-size: 12px; }
.cal .day:hover { border-color: var(--brand); }
.cal .day .n { font-weight: 700; font-size: 14px; }
.cal .day.full { background: var(--ok-bg); }
.cal .day.gap { background: var(--bad-bg); }
.cal .day.closed { background: var(--closed); color: var(--muted); }
.cal .day.today { outline: 2px solid var(--brand); }
.cal .day.empty { visibility: hidden; }
.cal .day .who { margin-top: 3px; }

/* magazyn */
.roll-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.roll { background: var(--card); border: 2px solid var(--line); border-top: 8px solid var(--c, #64748b); border-radius: 8px; padding: 10px 12px; }
.roll h3 { margin: 0 0 6px; font-size: 18px; }
.roll ul { margin: 6px 0 0; padding-left: 18px; }
.roll.gap { border-color: var(--bad); }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.tabs a { padding: 5px 12px; border-radius: 999px; border: 1px solid var(--line); text-decoration: none; color: var(--ink); background: var(--card); }
.tabs a.on { background: var(--c, var(--btn)); color: #fff; border-color: var(--c, var(--btn)); }

.login { max-width: 340px; margin: 60px auto; }
.login input { width: 100%; margin: 4px 0 12px; }

@media (max-width: 640px) {
  .cal { gap: 3px; }
  .cal .day { min-height: 64px; padding: 4px; font-size: 10px; }
  .cal .day .who { display: none; }
}
@media print {
  header.top, .noprint { display: none !important; }
  body { background: #fff; color: #000; }
}

/* mapa rejonu */
.map-wrap { position: relative; }
#map { height: calc(100vh - 250px); min-height: 440px; border-radius: 12px; border: 1px solid var(--line); z-index: 0; }
.legend { position: absolute; top: 12px; right: 12px; z-index: 500; max-width: 230px; padding: 10px 12px; margin: 0; box-shadow: 0 2px 10px rgba(0,0,0,.18); }
.legend .lg { display: block; margin: 4px 0; font-size: 13px; cursor: pointer; }
.legend hr { border: 0; border-top: 1px solid var(--line); margin: 8px 0; }
.pin-wrap { background: none; border: 0; }
.pin { width: 36px; height: 36px; border-radius: 50%; background: var(--c); color: #fff; border: 3px solid #fff;
  box-shadow: 0 1px 6px rgba(0,0,0,.45); display: grid; place-items: center; font: 700 11px/1 system-ui, sans-serif; }
.pin.gap { background: #fff; color: #dc2626; border-color: #dc2626; }
@media (max-width: 640px) { .legend { position: static; max-width: none; margin-top: 8px; } #map { height: 60vh; } }

/* widok dnia: nagłówki krat i pasek akcji */
tr.chute-h td { background: color-mix(in srgb, var(--line) 55%, transparent); padding-top: 4px; padding-bottom: 4px; }
.bar { position: sticky; bottom: 8px; z-index: 50; display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
  background: var(--card); border: 1px solid var(--brand); border-radius: 12px; padding: 10px 12px; margin-top: 14px;
  box-shadow: 0 4px 18px rgba(0,0,0,.2); }
.pin.multi { width: 26px; height: 26px; font-size: 11px; border-style: dashed; }

/* edytor układu krat */
tr.changed td { background: var(--warn-bg); }
tr.grp td { background: var(--bg); font-weight: 700; }

/* Stopka autorska */
.site-footer {
  text-align: center;
  padding: 18px 12px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
}
.site-footer a {
  color: inherit;
  text-decoration: none;
}
.site-footer a:hover {
  color: var(--brand);
  text-decoration: underline;
}

/* Dyskretna stopka przyklejona do dolu okna */
body {
  padding-bottom: 32px;
}

.site-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  box-sizing: border-box;
  z-index: 100;
  background: var(--foot-bg);
  border: none;
  padding: 7px 12px;
  text-align: center;
  font-size: 10px;
  line-height: 14px;
  color: var(--foot-ink);
}

.site-footer a {
  color: inherit;
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--brand);
  text-decoration: underline;
}

/* Dyskretna stopka przyklejona do dolu okna */
body {
  padding-bottom: 32px;
}

.site-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  box-sizing: border-box;
  z-index: 100;
  background: var(--foot-bg);
  border: none;
  padding: 7px 12px;
  text-align: center;
  font-size: 10px;
  line-height: 14px;
  color: var(--foot-ink);
}

.site-footer a {
  color: inherit;
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--brand);
  text-decoration: underline;
}

/* Stopka Planera */
/* Planer v4.1 — raport APM na rollkontenerach */
.apm-roll { margin: 10px 0; padding: 10px; border-radius: 8px; background: var(--bg); border: 1px solid var(--line); display:grid; gap:6px; }
.apm-roll-count { display:flex; justify-content:space-between; align-items:baseline; gap:6px; flex-wrap:wrap; }
.apm-roll-count b { font-size:24px; font-variant-numeric:tabular-nums; }
.apm-roll-detail { font-size:13px; }
.apm-meter { height:8px; border-radius:10px; overflow:hidden; background:var(--line); }
.apm-meter span { display:block; height:100%; border-radius:10px; }
.apm-stream { font-size:12px; white-space:nowrap; margin-left:4px; }

/* Planer v4.2 — status osobno dla każdego paczkomatu */
.apm-machine{margin:7px 0 10px;padding:9px 10px;border-radius:8px;border:1px solid var(--line);background:var(--bg);font-size:12px;display:grid;gap:6px}
.apm-machine-top{display:flex;justify-content:space-between;gap:8px;flex-wrap:wrap}
.apm-machine-bottom{opacity:.95}
.apm-machine-danger{border-color:#ef4444;background:rgba(239,68,68,.12)}
.apm-machine-danger .apm-machine-top{color:var(--st-bad)}
.apm-machine-warning{border-color:#f59e0b;background:rgba(245,158,11,.10)}
.apm-machine-warning .apm-machine-top{color:var(--st-warn)}
.apm-machine-safe{border-color:rgba(34,197,94,.4)}
.apm-machine-safe .apm-machine-top{color:var(--st-ok)}
.apm-machine .apm-meter{height:5px}


/* Poprawka stopki — bez nakładania na pasek akcji */
footer.site-footer {
    position: static !important;
    bottom: auto !important;
    left: auto !important;
    right: auto !important;
    width: 100% !important;
    z-index: auto !important;
}

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding-bottom: 0 !important;
}

main {
    flex: 1 0 auto;
}

.bar {
    z-index: 50;
}


/* Naprawa szerokości stron po zmianie układu stopki */
body > main {
    width: 100%;
    box-sizing: border-box;
    align-self: stretch;
}


/* v4.3 TEST — spójna kolorystyka stopki */
footer.site-footer {
    position: static !important;
    background: var(--foot-bg) !important;
    color: var(--foot-ink) !important;
    border-top: 1px solid var(--line) !important;
    width: 100%;
    box-sizing: border-box;
}

footer.site-footer a {
    color: var(--foot-link) !important;
}

footer.site-footer a:hover {
    color: var(--brand) !important;
}

/* v4.3: ostrzeżenie o rozdzieleniu obsługi paczkomatu i Multi */
tr.multi-mismatch > td { background: var(--mm-bg) !important; border-color: var(--mm-line) !important; }
tr.multi-mismatch:hover > td { background: var(--mm-hover) !important; }
textarea { background: var(--field); color: var(--ink); border: 1px solid var(--line); }

/* Panel sterowania — naglowek */
header.top {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px 20px;
    padding-top: 12px;
    padding-bottom: 10px;
}

header.top > .brand {
    grid-column: 1;
    grid-row: 1;
}

header.top > .account-bar {
    grid-column: 2;
    grid-row: 1;
    display: flex;
    align-items: center;
    justify-self: end;
    gap: 16px;
    margin-left: 0;
    white-space: nowrap;
}

header.top > nav {
    grid-column: 1 / -1;
    grid-row: 2;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 18px;
    min-width: 0;
}

.account-profile {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
    text-decoration: none !important;
    color: var(--ink);
    font-size: 13px;
}

.account-profile strong {
    color: var(--ink);
}

.account-profile small {
    color: var(--muted);
    font-size: 11px;
}

.account-profile:hover strong {
    color: var(--brand);
}

.account-separator {
    width: 1px;
    height: 28px;
    background: var(--head-sep);
}

.account-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 32px;
    color: var(--ink);
    font-size: 23px;
    text-decoration: none !important;
}

.account-icon:hover {
    color: var(--brand);
}

.account-disabled {
    opacity: .55;
    cursor: default;
}

@media (max-width: 700px) {
    header.top {
        grid-template-columns: 1fr;
    }

    header.top > .brand {
        grid-column: 1;
        grid-row: 1;
    }

    header.top > .account-bar {
        grid-column: 1;
        grid-row: 2;
        justify-self: start;
        gap: 12px;
    }

    header.top > nav {
        grid-column: 1;
        grid-row: 3;
    }
}

/* Naglowek kompaktowy — logo, menu i konto w jednym wierszu */
@media (min-width: 1050px) {
    header.top {
        display: flex;
        flex-direction: row;
        align-items: center;
        flex-wrap: nowrap;
        gap: 24px;
        padding: 10px 24px;
    }

    header.top > .brand,
    header.top > nav,
    header.top > .account-bar {
        grid-column: auto;
        grid-row: auto;
    }

    header.top > .brand {
        flex: 0 0 auto;
        white-space: nowrap;
    }

    header.top > nav {
        display: flex;
        flex: 1 1 auto;
        flex-wrap: nowrap;
        gap: 8px;
        min-width: 0;
    }

    header.top > nav a {
        white-space: nowrap;
    }

    header.top > .account-bar {
        display: flex;
        flex: 0 0 auto;
        margin-left: auto;
        gap: 12px;
        white-space: nowrap;
    }
}


/* Formularz 2FA - poprawa ukladu */
.twofa-form {
  max-width: 400px;
  box-sizing: border-box;
}

.twofa-form label {
  display: block;
  margin: 16px 0 6px;
  font-weight: 600;
}

.twofa-form input,
.twofa-form select {
  display: block;
  width: 100%;
  box-sizing: border-box;
  margin: 0 0 14px;
  min-height: 40px;
}

.twofa-form button {
  display: block;
  width: 100%;
  margin: 10px 0;
  min-height: 40px;
}

.twofa-form p {
  line-height: 1.5;
}

/* v5.4 — statystyki APM (wykresy bez bibliotek, kolory ze zmiennych motywu) */
.kpis { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; margin: 12px 0 16px; }
.kpi { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; }
.kpi span { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.kpi b { font-size: 28px; line-height: 1.1; font-variant-numeric: tabular-nums; }
.kpi small { color: var(--muted); font-size: 12px; min-height: 16px; }
.kpi.bad b { color: var(--bad); } .kpi.warn b { color: var(--warn); } .kpi.ok b { color: var(--ok); }
.card h3 { font-size: 15px; margin: 0 0 10px; }
.bars { display: grid; gap: 7px; }
.bar-row { display: grid; grid-template-columns: 44px 1fr auto; gap: 10px; align-items: center; font-size: 13px; }
.bar-row .bar-label { font-weight: 600; white-space: nowrap; }
.bar-row .bar-label.wide { grid-column: 1; width: 128px; overflow: hidden; text-overflow: ellipsis; font-weight: 500; }
.bar-row:has(.bar-label.wide) { grid-template-columns: 128px 1fr auto; }
.bar-track { height: 16px; background: var(--bg); border-radius: 5px; overflow: hidden; display: flex; border: 1px solid var(--line); }
.bar-seg { display: block; height: 100%; }
.bar-seg.hatch { background-image: repeating-linear-gradient(45deg, rgba(255,255,255,.55) 0 3px, transparent 3px 6px); }
.bar-val { font-variant-numeric: tabular-nums; white-space: nowrap; text-align: right; min-width: 52px; }
.bar-val small { color: var(--muted); }
svg.chart { width: 100%; height: auto; display: block; }
.ch-grid { stroke: var(--line); stroke-width: 1; }
.ch-txt { fill: var(--muted); font-size: 11px; }
.ch-line { fill: none; stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.ch-legend { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 8px; font-size: 12px; color: var(--muted); }
.ch-legend i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 6px; vertical-align: -2px; }
.cols { display: flex; gap: 10px; align-items: flex-end; height: 190px; padding-top: 6px; }
.col { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; gap: 3px; font-size: 12px; min-width: 24px; }
.col-stack { width: 100%; max-width: 38px; flex: 1; display: flex; flex-direction: column-reverse; justify-content: flex-start; background: var(--bg); border-radius: 5px; overflow: hidden; border: 1px solid var(--line); }
.col-stack span { display: block; width: 100%; }
.col small { color: var(--muted); }
details.card > summary { cursor: pointer; }
@media (max-width: 640px) { .bar-row, .bar-row:has(.bar-label.wide) { grid-template-columns: 96px 1fr auto; } .bar-row .bar-label.wide { width: 96px; } }
.bar-row.wk .bar-val { white-space: normal; text-align: left; max-width: 210px; line-height: 1.25; }
table.heat td, table.heat th { padding: 6px 10px; }

/* ===== v8.7: układ na telefon ===== */
html { -webkit-text-size-adjust: 100%; }
img, svg, video, canvas { max-width: 100%; }
.tscroll { overflow-x: auto; -webkit-overflow-scrolling: touch; max-width: 100%; margin: 0 0 10px; border-radius: 8px; }
.tscroll > table { margin: 0; }

@media (max-width: 700px) {
    body { overflow-x: hidden; }
    main, .wrap, .container { padding-left: 12px !important; padding-right: 12px !important; }

    /* nagłówek: 1. wiersz – logo + konto, 2. – przewijane menu */
    header.top { grid-template-columns: auto minmax(0, 1fr) !important; gap: 8px 10px !important; padding: 8px 12px !important; }
    header.top > .brand { grid-column: 1 !important; grid-row: 1 !important; font-size: 15px; white-space: nowrap; }
    header.top > .account-bar { grid-column: 2 !important; grid-row: 1 !important; justify-self: end !important; gap: 10px !important; }
    .account-profile { display: inline-flex; align-items: center; }
    .account-profile strong, .account-profile small { display: none; }
    .account-profile { width: 40px; height: 40px; justify-content: center; }
    .account-profile::before { content: '👤'; font-size: 24px; }
    .account-separator { display: none; }
    header.top > .account-bar { gap: 2px !important; }
    .account-icon { font-size: 25px !important; width: 40px !important; height: 40px !important; padding: 0 !important; color: var(--ink) !important; }
    .account-icon * { color: inherit; }
    #theme-toggle { font-size: 32px !important; line-height: 1; }
    header.top > nav {
        grid-column: 1 / -1 !important; grid-row: 2 !important;
        display: flex !important; flex-wrap: nowrap !important; gap: 6px !important;
        overflow-x: auto; scrollbar-width: none; margin: 0 -12px; padding: 2px 12px;
        -webkit-overflow-scrolling: touch;
    }
    header.top > nav::-webkit-scrollbar { display: none; }
    header.top > nav a { flex: 0 0 auto; white-space: nowrap; padding: 8px 14px !important; border-radius: 999px; background: var(--bg); font-size: 14px; }
    header.top > nav a.on { background: var(--btn, #2563eb); color: #fff; }
    header.top > .carrier-switch { grid-column: 1 / -1 !important; grid-row: 3 !important; }
    header.top > .carrier-switch select { max-width: 100% !important; width: 100%; }
    header.top > span.muted { grid-column: 1 / -1; max-width: 100% !important; }

    /* powiadomienia: panel na całą szerokość ekranu */
    #notif-panel { position: fixed !important; left: 8px !important; right: 8px !important; top: 56px !important; width: auto !important; max-height: 75vh !important; }

    /* formularze i przyciski wygodne dla palca (16 px – iOS nie przybliża strony) */
    input, select, textarea { font-size: 16px; max-width: 100%; }
    input:not([type=checkbox]):not([type=radio]), select, button, .btn { min-height: 40px; }
    .row, .card.row, form.inline, .filters, form.filter { flex-wrap: wrap; }
    .row > *, form label { max-width: 100%; }
    label:has(> select), label:has(> input:not([type=checkbox]):not([type=radio])) { display: block; }
    label > select, label > input:not([type=checkbox]):not([type=radio]) { width: 100%; box-sizing: border-box; }
    .card { padding-left: 12px; padding-right: 12px; }
    h1 { font-size: 22px; }

    /* widok dnia: pigułki kuriera i dolny panel zaznaczania */
    .chip { border-radius: 12px; padding: 4px 10px; line-height: 1.3; max-width: 100%; box-sizing: border-box; overflow-wrap: anywhere; }
    #fa.bar { max-height: 70vh; overflow-y: auto; padding: 8px 12px; gap: 8px; }
    #fa .fa-toggle { display: inline-block; margin-left: auto; }
    #fa:not(.open) > *:not(#sel):not(.fa-toggle) { display: none !important; }
    #fa.open input, #fa.open select { width: 100% !important; box-sizing: border-box; }

    /* informacja o cookies: niższa, nie zasłania treści */
    #cookie-notice { left: 8px !important; right: 8px !important; bottom: 8px !important; font-size: 13px !important; padding: 10px 12px !important; }
}

#fa .fa-toggle { display: none; }
@media (max-width: 700px) { #fa .fa-toggle { display: inline-block; } }
