:root { color-scheme:light; --ink:#122033; --muted:#68768a; --navy:#0b1c34; --navy-2:#132d4f; --blue:#1f6feb; --blue-dark:#1558bd; --cyan:#3dd6d0; --bg:#f3f6fa; --surface:#fff; --line:#dce4ed; --soft:#edf3f8; --green:#0f7a4b; --red:#b42318; --amber:#9a5a00; --topbar:60px; }
* { box-sizing:border-box; }
[hidden] { display:none !important; }
html { background:var(--bg); }
body { margin:0; min-height:100vh; font-family:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; background:var(--bg); color:var(--ink); -webkit-font-smoothing:antialiased; }
button,input,select,textarea { font:inherit; }
button { border:0; cursor:pointer; color:inherit; background:none; transition:background .15s ease,box-shadow .15s ease; }
button:disabled { cursor:not-allowed; opacity:.5; }
a { color:var(--blue-dark); }
:focus-visible { outline:3px solid #1f6feb66; outline-offset:2px; }
.sr-only { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap; }
.hint { display:block; margin:6px 0 0; color:var(--muted); font-size:12px; line-height:1.45; }
.measurement { margin-top:3px; color:#7b8797; font-size:10px; line-height:1.35; }
.link-button { padding:0; color:var(--blue-dark); font-weight:750; text-decoration:underline; }

/* Przyciski */
.primary,.secondary,.danger,.tool-button,.telegram-button { display:inline-flex; align-items:center; justify-content:center; gap:6px; min-height:40px; padding:9px 16px; border-radius:10px; font-weight:800; font-size:14px; white-space:nowrap; text-decoration:none; }
.primary { background:var(--blue); color:white; }
.primary:hover { background:var(--blue-dark); }
.secondary,.tool-button { border:1px solid #cbd7e4; background:white; color:#29405e; }
.secondary:hover,.tool-button:hover { background:var(--soft); }
.danger { border:1px solid #f3c3bd; background:#fff1ef; color:#a3271c; }
.danger:hover { background:#ffe5e2; }
.small { min-height:32px; padding:5px 11px; font-size:12px; border-radius:8px; }
.telegram-button { background:#229ed9; color:white; }
.telegram-button:hover { background:#1b8bc0; }
.icon-button { display:inline-grid; place-items:center; width:40px; min-height:40px; border:1px solid #cbd7e4; border-radius:10px; background:white; font-size:20px; font-weight:700; color:#29405e; }

/* Belka */
.topbar { position:sticky; top:0; z-index:30; background:var(--navy); color:white; box-shadow:0 2px 12px #0b1c3433; }
.topbar-inner { display:flex; align-items:center; gap:14px; max-width:1240px; height:var(--topbar); margin:auto; padding:0 20px; }
.brand { display:flex; align-items:center; gap:9px; color:white; text-decoration:none; font-weight:850; font-size:17px; letter-spacing:-.01em; }
.brand-mark { display:grid; place-items:center; width:34px; height:34px; border-radius:10px; background:linear-gradient(145deg,#49e2d8,#278ee8); color:#06223a; }
.brand-mark svg { width:21px; height:21px; }
.brand-text { display:flex; flex-direction:column; line-height:1.15; }
.brand-line { display:flex; align-items:center; }
.brand-tagline { color:#a9bdd6; font-size:11px; font-weight:600; letter-spacing:0; white-space:nowrap; }
.place-picker { position:relative; min-width:0; }
.place-button { display:flex; align-items:center; gap:8px; max-width:340px; min-height:38px; padding:6px 12px; border:1px solid #ffffff2e; border-radius:10px; background:#ffffff12; color:white; font-weight:750; font-size:14px; }
.place-button:hover { background:#ffffff22; }
.place-button #placeName { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.place-dot { flex:0 0 9px; width:9px; height:9px; border-radius:50%; background:var(--cyan); box-shadow:0 0 0 4px #3dd6d02e; }
.caret { color:#a9bdd6; font-size:11px; }
.tabs { display:flex; gap:4px; margin-left:auto; }
.tabs a { padding:8px 14px; border-radius:9px; color:#c6d4e6; font-weight:750; font-size:14px; text-decoration:none; }
.tabs a:hover { background:#ffffff14; color:white; }
.tabs a[aria-current="page"] { background:#ffffff1f; color:white; box-shadow:inset 0 -2px 0 var(--cyan); }
.save-indicator { min-width:0; color:#9fe7c4; font-size:12px; font-weight:700; white-space:nowrap; }
.account { position:relative; }
.login-button { min-height:38px; padding:7px 14px; border-radius:10px; background:var(--blue); color:white; font-weight:800; font-size:14px; white-space:nowrap; }
.account-button { display:flex; align-items:center; gap:8px; min-height:38px; padding:4px 10px 4px 4px; border-radius:10px; color:white; font-weight:750; font-size:14px; }
.account-button:hover { background:#ffffff14; }
.avatar { display:grid; place-items:center; width:30px; height:30px; border-radius:50%; background:#2a4a75; font-weight:850; }
.account-name { max-width:140px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.menu { position:absolute; top:calc(100% + 8px); left:0; z-index:40; min-width:260px; max-width:min(360px,calc(100vw - 24px)); padding:6px; border:1px solid var(--line); border-radius:13px; background:white; color:var(--ink); box-shadow:0 18px 50px #0b1c3430; }
.menu-right { left:auto; right:0; }
.menu-item,.menu a,.menu > button { display:flex; flex-direction:column; align-items:flex-start; width:100%; padding:9px 11px; border-radius:9px; color:var(--ink); font-size:14px; font-weight:700; text-align:left; text-decoration:none; }
.menu-item small { color:var(--muted); font-size:12px; font-weight:600; }
.menu-item:hover,.menu a:hover,.menu > button:hover { background:var(--soft); }
.menu-item.is-active { background:#eaf3ff; color:#124f9f; }
.menu-add { flex-direction:row; justify-content:space-between; align-items:center; border-top:1px solid var(--line); border-radius:0 0 9px 9px; margin-top:4px; color:var(--blue-dark); }
.menu-head { display:flex; flex-direction:column; gap:2px; padding:9px 11px 11px; margin-bottom:4px; border-bottom:1px solid var(--line); font-size:13px; }
.menu-head span { color:var(--muted); font-size:12px; }
.bottom-tabs { display:none; }

/* Układ */
main { max-width:1240px; margin:0 auto; padding:22px 20px 60px; }
.view-head { display:flex; flex-wrap:wrap; justify-content:space-between; align-items:flex-end; gap:12px; margin-bottom:16px; }
.view-head h1 { margin:0; font-size:clamp(22px,2.6vw,28px); letter-spacing:-.02em; color:var(--navy); }
.view-meta { margin:4px 0 0; color:var(--muted); font-size:13px; }
.view-tools { display:flex; flex-wrap:wrap; align-items:center; gap:8px; }
.notice { display:flex; align-items:flex-start; justify-content:space-between; gap:12px; margin-bottom:16px; padding:11px 14px; border-radius:11px; font-size:14px; font-weight:650; }
.notice button { font-size:20px; line-height:1; color:inherit; opacity:.7; }
.notice-info { background:#e3f5e9; color:#14572f; }
.notice-warning { background:#fff4d6; color:#6b4500; }
.notice-error { background:#fff2f0; color:#912018; }
.chips { display:flex; flex-wrap:wrap; gap:8px; margin:0 0 12px; }
.chips:empty { display:none; }
.chip { display:inline-flex; align-items:center; gap:7px; margin:0; padding:7px 12px; border:1px solid #ccd8e5; border-radius:999px; background:white; color:#31435d; font-size:13px; font-weight:700; cursor:pointer; user-select:none; }
.chip:has(input:checked) { border-color:#82afea; background:#eaf3ff; color:#124f9f; }
.chip input { width:auto; min-height:0; margin:0; accent-color:var(--blue); }
.chip-count { color:var(--muted); font-size:12px; font-weight:700; }
.chip-carrier { font-size:12px; padding:6px 11px; }
.toolbar { display:grid; grid-template-columns:auto minmax(200px,1fr) auto; gap:10px; margin-bottom:12px; }
.date-control { display:flex; gap:6px; align-items:center; }
.date-control input { width:auto; }
input,select,textarea { width:100%; min-height:40px; border:1px solid #c7d3e1; border-radius:10px; padding:8px 12px; background:white; color:var(--ink); }
input:hover,select:hover,textarea:hover { border-color:#a9bbcf; }
input:focus,select:focus,textarea:focus { outline:3px solid #1f6feb22; border-color:var(--blue); }
input:disabled { background:var(--soft); color:var(--muted); cursor:not-allowed; }
label,.field-label { display:block; margin:14px 0 6px; color:#263750; font-weight:750; font-size:13px; }
.chip,.dialog .chip { margin:0; }
.empty { padding:32px 20px; border:1px dashed #b7c4d3; border-radius:14px; color:var(--muted); text-align:center; background:white; }
.empty p { margin:0 0 14px; }
.empty p:last-child { margin-bottom:0; }
.empty-small { padding:12px; color:var(--muted); font-size:13px; }
.welcome h2 { margin:0 0 8px; color:var(--navy); }
.welcome p { max-width:520px; margin:0 auto 16px; line-height:1.5; }
.loading { padding:40px 20px; text-align:center; color:var(--muted); }
.loading p { margin:12px 0 0; }
.loading-timer { font-size:12px; font-variant-numeric:tabular-nums; }
.spinner { width:38px; height:38px; margin:auto; border:4px solid var(--soft); border-top-color:var(--blue); border-radius:50%; animation:spin 1s linear infinite; }
@keyframes spin { to { transform:rotate(360deg); } }
@media (prefers-reduced-motion:reduce) { .spinner { animation:none; } }

/* Teraz */
.now-list { display:grid; gap:8px; }
.now-row { display:grid; grid-template-columns:86px 64px minmax(0,1.6fr) minmax(0,1.3fr) 190px auto; align-items:center; gap:14px; padding:12px 16px; border:1px solid var(--line); border-radius:13px; background:white; }
.now-row.is-watched { box-shadow:inset 4px 0 0 #f2b600; }
.now-row.has-special { border-color:#ffb766; background:#fffaf2; }
.now-eta { color:var(--navy); font-size:28px; font-weight:850; font-variant-numeric:tabular-nums; line-height:1; white-space:nowrap; }
.now-eta small { margin-left:3px; color:var(--muted); font-size:12px; font-weight:700; }
.eta-now { color:var(--green); font-size:20px; }
.now-time { font-weight:800; font-variant-numeric:tabular-nums; color:var(--green); }
.now-time s { display:block; color:var(--muted); font-size:12px; font-weight:600; }
.now-train { min-width:0; }
.now-train b { margin-right:4px; font-size:15px; }
.now-train > span:not(.unusual),.now-dir > span { display:block; color:var(--muted); font-size:12px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.now-dir { min-width:0; font-weight:700; font-size:14px; }
.now-livery { display:flex; flex-wrap:wrap; align-items:center; gap:5px; margin-top:5px; }
.now-status { display:flex; flex-wrap:wrap; gap:5px; justify-content:flex-end; }
.now-actions { display:flex; align-items:center; gap:4px; }
.now-list.no-eta .now-row { grid-template-columns:64px minmax(0,1.6fr) minmax(0,1.3fr) 190px auto; }
.now-row.is-past { opacity:.55; }
.train-summary { margin:0 0 10px; color:var(--muted); font-size:12px; font-weight:650; }
.train-summary:empty { display:none; }
.view.is-board #trainControls { display:none; }
.more-button { display:block; margin:12px auto 0; padding:9px 18px; border:1px solid #cbd7e4; border-radius:10px; background:white; font-weight:750; color:#29405e; }

/* Tablica (pełny ekran) */
.board-head { display:flex; align-items:center; gap:20px; flex-wrap:wrap; margin-bottom:16px; }
.board-head > div:first-child { flex:1; min-width:0; }
.board-eyebrow { margin:0; color:#ffc61a; font-size:12px; font-weight:800; letter-spacing:.14em; text-transform:uppercase; }
.board-head h2 { margin:4px 0 0; font-size:clamp(22px,3.2vw,38px); letter-spacing:-.02em; }
.board-clock { font-size:clamp(32px,5vw,64px); font-weight:850; font-variant-numeric:tabular-nums; color:#ffc61a; line-height:1; }
.board-close { padding:10px 16px; border-radius:10px; background:#ffffff1a; color:white; font-weight:800; }
.view.is-board { position:fixed; inset:0; z-index:60; overflow:auto; padding:clamp(16px,3vw,40px); background:#071426; color:#eaf1fb; }
.view.is-board .view-head,.view.is-board .more-button { display:none; }
.view.is-board .now-row { border-color:#ffffff14; background:#0f2240; font-size:clamp(16px,1.6vw,22px); padding:16px 20px; }
.view.is-board .now-row.is-watched { box-shadow:inset 5px 0 0 #ffc61a; }
.view.is-board .now-row.has-special { border-color:#ff9f43; background:#1d2a3f; }
.view.is-board .now-eta { color:#ffc61a; font-size:clamp(28px,3.4vw,46px); }
.view.is-board .now-time { color:#eaf1fb; }
.view.is-board .now-train > span:not(.unusual),.view.is-board .now-dir > span,.view.is-board .now-time s,.view.is-board .now-eta small { color:#9fb0c8; }
.view.is-board .now-actions .star { color:#7f93b0; }
.view.is-board .report-btn { background:#ffffff1a; color:white; }
.view.is-board .empty { background:transparent; border-color:#ffffff33; color:#9fb0c8; }
body.board-open { overflow:hidden; }

/* Odznaki */
.badge { display:inline-flex; border-radius:6px; padding:3px 7px; background:#e5effd; color:#0757bd; font-size:11px; font-weight:850; vertical-align:middle; }
.delay,.passage { display:inline-flex; align-items:center; gap:5px; white-space:nowrap; border-radius:7px; padding:4px 8px; font-size:12px; font-weight:800; }
.delay-late { background:#ffe5e2; color:#a3271c; }
.delay-ok { background:#e3f5e9; color:#17683a; }
.delay-unknown { background:#edf1f5; color:#68768a; }
.passage-stop { background:#e3f5e9; color:#146c3a; }
.passage-through { background:#fff0d8; color:#8a4c00; }
.unusual { display:inline-flex; margin-left:5px; border-radius:6px; padding:2px 6px; background:#f3e8ff; color:#6b21a8; font-size:10px; font-weight:850; text-transform:uppercase; letter-spacing:.04em; vertical-align:middle; cursor:help; }
.livery { display:inline-flex; align-items:center; gap:4px; border-radius:7px; padding:4px 8px; font-size:11px; font-weight:850; white-space:nowrap; cursor:help; }
.livery small { font-size:.85em; opacity:.75; }
.livery-standardowe { background:#edf1f5; color:#3c4b60; }
.livery-specjalne { background:linear-gradient(90deg,#ffe066,#ff9f43); color:#4a2500; }
.livery-reklamowe { background:#d9f6f3; color:#0b5f5a; }
.livery-retro { background:#f1e4d3; color:#6b3f12; }
.livery-weryfikacja { background:#fff; color:#3c4b60; box-shadow:inset 0 0 0 1px #9aa8b8; }
.livery-note { color:#7b8797; font-size:11px; }
.src-fb { display:inline-flex; align-items:center; border-radius:5px; padding:2px 5px; background:#1877f2; color:#fff; font-size:10px; font-weight:850; letter-spacing:.03em; line-height:1.3; cursor:help; }
.hunt { display:inline-flex; border-radius:6px; padding:3px 6px; background:#ffe5e2; color:#a3271c; font-size:10px; font-weight:850; text-transform:uppercase; letter-spacing:.03em; white-space:nowrap; }
.star { display:inline-grid; place-items:center; width:36px; height:36px; border-radius:9px; color:#9aa7b8; }
.star svg { width:19px; height:19px; fill:none; stroke:currentColor; stroke-width:2; stroke-linejoin:round; }
.star:hover { background:var(--soft); color:#b7791f; }
.star[aria-pressed="true"] { color:#e0a800; }
.star[aria-pressed="true"] svg { fill:currentColor; }
.report-btn { padding:6px 10px; border-radius:8px; background:#eaf3ff; color:#124f9f; font-size:12px; font-weight:800; white-space:nowrap; }
.report-btn:hover { background:#d6e8ff; }

/* Rozkład */
.metrics { display:grid; grid-template-columns:repeat(auto-fit,minmax(120px,1fr)); gap:8px; margin-bottom:12px; }
.metric { padding:10px 13px; border:1px solid var(--line); border-radius:11px; background:white; }
.metric strong { display:block; font-size:18px; color:var(--navy); }
.metric span { color:var(--muted); font-size:11px; font-weight:700; text-transform:uppercase; letter-spacing:.035em; }
.table-wrap { overflow:auto; max-height:72vh; border:1px solid var(--line); border-radius:13px; background:white; }
table { width:100%; border-collapse:separate; border-spacing:0; min-width:980px; }
th { position:sticky; top:0; z-index:2; padding:10px 12px; border-bottom:1px solid #cfd9e5; background:#f2f6fa; color:#506079; text-align:left; font-size:10px; text-transform:uppercase; letter-spacing:.07em; }
td { padding:10px 12px; border-bottom:1px solid #e7edf3; vertical-align:middle; font-size:13px; }
tbody tr:last-child td { border-bottom:0; }
tbody tr:hover td { background:#f7faff; }
tr.is-watched td { background:#fffbea; }
tr.has-special td { background:#fff6e5; }
.col-time { white-space:nowrap; color:var(--green); font-size:16px; font-variant-numeric:tabular-nums; font-weight:850; }
.col-number { color:#142b4a; font-size:15px; font-weight:850; }
.col-name { margin-top:2px; color:#40516a; font-weight:700; font-size:12px; }

/* Moje */
.mine-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(300px,1fr)); gap:14px; align-items:start; }
.mine-card { padding:18px; border:1px solid var(--line); border-radius:15px; background:white; }
.mine-card h2 { display:flex; align-items:center; gap:8px; margin:0 0 8px; font-size:17px; color:var(--navy); }
.mine-card p { margin:0 0 6px; font-size:14px; line-height:1.5; }
.mine-wide { grid-column:1/-1; }
.mine-cta { background:linear-gradient(135deg,#eaf3ff,#f4fbff); border-color:#c6dcf7; }
.mine-cta ul { margin:6px 0 12px; padding-left:20px; font-size:14px; line-height:1.7; }
.card-head { display:flex; flex-wrap:wrap; justify-content:space-between; align-items:center; gap:10px; margin-bottom:8px; }
.card-head h2 { margin:0; }
.card-actions { display:flex; flex-wrap:wrap; gap:8px; margin-top:12px; }
.place-list { display:grid; gap:8px; margin:0; padding:0; list-style:none; }
.place-list li { display:flex; flex-wrap:wrap; justify-content:space-between; align-items:center; gap:10px; padding:11px 13px; border:1px solid var(--line); border-radius:11px; }
.place-list li.is-active { border-color:#9cc3f2; background:#f5f9ff; }
.place-list b { display:block; }
.place-list span { color:var(--muted); font-size:12px; }
.place-actions { display:flex; flex-wrap:wrap; align-items:center; gap:6px; }
.active-label { padding:5px 10px; border-radius:8px; background:#e3f5e9; color:#146c3a !important; font-weight:800; font-size:12px !important; }
.inline-form { display:flex; gap:8px; margin:10px 0; }
.tag-list { display:flex; flex-wrap:wrap; gap:6px; }
.tag { display:inline-flex; align-items:center; gap:4px; padding:4px 4px 4px 10px; border-radius:8px; background:#fff6d6; color:#5c4300; font-weight:800; font-size:13px; }
.tag button { width:22px; height:22px; border-radius:6px; font-size:15px; line-height:1; color:#8a6a00; }
.tag button:hover { background:#ffe9a3; }
#collectionText { min-height:180px; font-family:ui-monospace,monospace; font-size:13px; }
.telegram-link { font-weight:800; }

/* Okna */
.modal { display:none; position:fixed; inset:0; z-index:70; padding:16px; align-items:center; justify-content:center; background:#061426aa; backdrop-filter:blur(6px); }
.modal.open { display:flex; }
.dialog { width:min(560px,100%); max-height:92vh; overflow:auto; padding:22px; border-radius:18px; background:white; box-shadow:0 30px 90px #0007; }
.dialog h2 { margin:0 0 6px; color:var(--navy); letter-spacing:-.02em; }
.dialog-actions { display:flex; justify-content:flex-end; gap:8px; margin-top:18px; }
.form-error { min-height:0; margin:10px 0 0; color:var(--red); font-size:13px; font-weight:700; }
.form-error:empty { display:none; }
.switch-mode { margin-top:14px; text-align:center; }
.livery-choices { display:flex; flex-wrap:wrap; gap:6px; }
.have-chip { margin-top:14px !important; }
.report-existing { display:grid; gap:6px; margin:10px 0 4px; }
.report-existing:empty { display:none; }
.report-item { display:flex; justify-content:space-between; align-items:center; gap:10px; padding:9px 11px; border:1px solid var(--line); border-radius:10px; background:#fbfdff; font-size:13px; }
.report-item button { padding:5px 9px; border-radius:7px; background:#ffe5e2; color:#a3271c; font-weight:800; font-size:12px; }
#observerResults { margin-top:8px; max-height:220px; overflow:auto; border:1px solid var(--line); border-radius:10px; }
#observerResults:empty { display:none; }
.station-option { display:block; width:100%; padding:11px 12px; border-bottom:1px solid #e5ebf2; background:white; text-align:left; font-weight:600; }
.station-option:hover,.station-option.selected { background:#eaf3ff; }

/* Panel administratora */
.admin-tabs { display:flex; gap:4px; margin-left:auto; overflow-x:auto; }
.admin-tabs a { padding:8px 12px; border-radius:9px; color:#c6d4e6; font-weight:750; font-size:14px; text-decoration:none; white-space:nowrap; }
.admin-tabs a:hover { background:#ffffff14; color:white; }
.admin-tabs a[aria-current="page"] { background:#ffffff1f; color:white; box-shadow:inset 0 -2px 0 var(--cyan); }
.admin-back { color:#c6d4e6; font-size:13px; font-weight:700; text-decoration:none; white-space:nowrap; }
.admin-back:hover { color:white; }
.admin-status { margin:0 0 14px; font-size:14px; font-weight:700; }
.admin-section { padding:20px; border:1px solid var(--line); border-radius:15px; background:white; margin-bottom:16px; }
.admin-section h2 { margin:0; font-size:20px; color:var(--navy); }
.admin-head { display:flex; flex-wrap:wrap; justify-content:space-between; align-items:center; gap:12px; margin-bottom:14px; }
.admin-head input { max-width:320px; }
.admin-filter { display:flex; align-items:center; gap:10px; font-size:13px; font-weight:700; }
.admin-list { display:grid; gap:8px; }
.admin-item { display:flex; flex-wrap:wrap; justify-content:space-between; align-items:center; gap:10px; padding:11px 13px; border:1px solid var(--line); border-radius:12px; background:#fbfdff; font-size:14px; }
.admin-item.is-blocked { background:#fff6f5; }
.admin-item-main { min-width:0; overflow-wrap:anywhere; }
.admin-actions { display:flex; flex-wrap:wrap; gap:6px; }
.admin-actions button,.admin-filter button { padding:7px 10px; border:1px solid #cbd7e4; border-radius:8px; background:white; color:#29405e; font-size:12px; font-weight:750; }
.admin-actions button.is-danger { border-color:#f3c3bd; background:#ffe5e2; color:#a3271c; }
.admin-actions button:disabled { opacity:.45; }
.admin-badge { display:inline-block; margin-left:4px; border-radius:6px; padding:2px 7px; background:var(--soft); color:#3c4b60; font-size:10px; font-weight:850; text-transform:uppercase; letter-spacing:.04em; vertical-align:middle; }
.admin-badge.is-admin { background:#fff3c4; color:#7a4d00; }
.admin-badge.is-blocked { background:#ffe5e2; color:#a3271c; }
.admin-badge.is-plus { background:#e2f0ff; color:#124f9f; }
.about-card { border-color:#c6dcf7; background:linear-gradient(135deg,#f4f9ff,#fff); }
a.button-link { display:inline-flex; align-items:center; justify-content:center; text-decoration:none; }
.beta-box { padding:12px 14px; border-radius:11px; background:#fff4d6; color:#4a3300; }
.beta-badge { display:inline-block; margin-left:6px; border-radius:6px; padding:2px 6px; background:#ffcf33; color:#4a3300; font-size:10px; font-weight:900; letter-spacing:.06em; text-transform:uppercase; vertical-align:middle; }
.admin-badge.is-moderator { background:#e6f6ea; color:#1d6b33; }
.import-form textarea { width:100%; box-sizing:border-box; font:13px/1.45 ui-monospace,SFMono-Regular,Menlo,monospace; }
.import-row { display:flex; flex-wrap:wrap; align-items:end; gap:10px; margin-top:10px; }
.import-table-wrap { overflow-x:auto; }
.import-livery { display:flex; gap:6px; align-items:center; white-space:nowrap; }
.loco-filter { display:flex; flex-wrap:wrap; align-items:center; gap:10px; }
.loco-edit { display:flex; flex-wrap:wrap; gap:6px; align-items:center; }
.loco-edit input:not([type]) { min-width:180px; flex:1; }
.import-table { width:100%; border-collapse:collapse; font-size:13px; }
.import-table th, .import-table td { padding:6px; border-bottom:1px solid var(--line, #e3e8ef); text-align:left; vertical-align:top; }
.import-table td input:not([type]) { width:100%; min-width:160px; box-sizing:border-box; }
.stats-tiles { display:grid; grid-template-columns:repeat(auto-fill,minmax(140px,1fr)); gap:10px; }
.stat-tile { display:flex; flex-direction:column; gap:3px; padding:13px 14px; border:1px solid var(--line); border-radius:12px; background:#fbfdff; }
.stat-tile strong { font-size:26px; line-height:1.1; letter-spacing:-.02em; }
.stat-tile span { font-size:12px; font-weight:750; }
.stat-tile small { color:var(--muted); font-size:11px; }
.stats-charts { display:grid; grid-template-columns:repeat(auto-fit,minmax(280px,1fr)); gap:14px; margin-top:16px; }
.stats-chart { margin:0; padding:13px 14px; border:1px solid var(--line); border-radius:12px; background:white; }
.stats-chart figcaption { margin-bottom:10px; font-size:13px; font-weight:800; }
.bars { display:flex; align-items:stretch; gap:2px; height:130px; margin-bottom:18px; border-bottom:1px solid #cfd9e5; }
.bar-col { flex:1; display:flex; flex-direction:column; justify-content:flex-end; align-items:center; min-width:0; position:relative; }
.bar-col:hover { background:var(--soft); border-radius:4px 4px 0 0; }
.bar { width:70%; max-width:22px; border-radius:4px 4px 0 0; background:var(--blue); }
.bar-value { font-size:10px; font-weight:800; margin-bottom:2px; }
.bar-tick { position:absolute; bottom:-17px; font-size:9px; color:var(--muted); white-space:nowrap; }
.stats-table { margin-top:12px; font-size:13px; }
.stats-table summary { cursor:pointer; color:var(--blue-dark); font-weight:750; }
.stats-daily { min-width:0; margin-top:8px; }
.stats-daily th { position:static; }
.stats-daily th,.stats-daily td { padding:6px 10px; }
.stats-tops { display:grid; grid-template-columns:repeat(auto-fit,minmax(240px,1fr)); gap:14px; margin-top:16px; }
.stats-top h3 { margin:0 0 8px; font-size:13px; }
.stats-top ol { margin:0; padding-left:20px; font-size:13px; }
.stats-top li { padding:3px 0; }
.stats-top li span { overflow-wrap:anywhere; }
.stats-top li b { float:right; margin-left:8px; }
.bot-form { display:flex; flex-wrap:wrap; gap:8px; margin:10px 0; }
.bot-form input { flex:1 1 260px; }

/* Telefon */
@media (max-width:900px) {
  .tabs,.account-name,.brand-tagline { display:none; }
  .account { margin-left:auto; }
  .bottom-tabs { position:fixed; bottom:0; left:0; right:0; z-index:30; display:grid; grid-template-columns:repeat(2,1fr); padding-bottom:env(safe-area-inset-bottom); border-top:1px solid var(--line); background:white; box-shadow:0 -4px 16px #0b1c3412; }
  .bottom-tabs a { display:flex; flex-direction:column; align-items:center; gap:2px; padding:8px 0 9px; color:var(--muted); font-size:11px; font-weight:750; text-decoration:none; }
  .bottom-tabs svg { width:22px; height:22px; fill:none; stroke:currentColor; stroke-width:2; stroke-linecap:round; }
  .bottom-tabs a[aria-current="page"] { color:var(--blue-dark); }
  main { padding:16px 14px 90px; }
  .now-row { grid-template-columns:64px minmax(0,1fr) auto; grid-template-areas:"eta train actions" "eta dir actions" "time status status"; gap:4px 12px; padding:11px 12px; }
  .now-eta { grid-area:eta; font-size:24px; }
  .now-time { grid-area:time; font-size:13px; }
  .now-time s { display:none; }
  .now-train { grid-area:train; }
  .now-dir { grid-area:dir; font-size:13px; }
  .now-status { grid-area:status; justify-content:flex-start; }
  .now-actions { grid-area:actions; flex-direction:column; }
  .now-list.no-eta .now-row { grid-template-columns:52px minmax(0,1fr) auto; grid-template-areas:"time train actions" "time dir actions" "time status status"; }
  .now-list.no-eta .now-time { align-self:start; font-size:15px; }
  .now-list.no-eta .now-time s { display:block; margin-left:0; }
  .toolbar { grid-template-columns:minmax(0,1fr) auto; }
  .toolbar .date-control { grid-column:1/-1; }
  .toolbar select { width:auto; }
  .date-control input { flex:1; }
  .admin-tabs { margin-left:0; }
}
@media (max-width:520px) {
  .topbar-inner { gap:8px; padding:0 12px; }
  .brand-name { display:none; }
  .place-picker { flex:1; }
  .place-button { width:100%; max-width:none; }
  .save-indicator { display:none; }
  .view-head { flex-wrap:nowrap; align-items:flex-start; }
  .view-tools .tool-button { padding:8px 11px; font-size:13px; }
  .mine-grid { grid-template-columns:1fr; }
  .inline-form { flex-direction:column; }
  .dialog { padding:18px; }
  .admin-head input { max-width:none; }
  .admin-back { display:none; }
  .admin-tabs a { padding:8px 9px; }
  .admin-section { padding:14px; }
}
.next-day { margin-left:2px; padding:0 3px; border-radius:4px; background:#e8defc; color:#5b21b6; font-size:9px; font-weight:850; cursor:help; }
.app-footer { margin-top:28px; color:#9aa6b6; font-size:11px; text-align:center; font-variant-numeric:tabular-nums; }
.menu-version { display:block; margin-top:4px; padding:8px 11px 4px; border-top:1px solid var(--line); color:var(--muted); font-size:11px; }
.payment-settings { display:grid; grid-template-columns:repeat(auto-fit,minmax(220px,1fr)); gap:4px 12px; align-items:end; margin:8px 0 18px; }
.payment-settings label { margin:8px 0 0; }
.payment-settings input { margin-top:6px; }
.payment-settings button { justify-self:start; margin-top:12px; }
.payments-title { margin:8px 0 10px; font-size:15px; }
.admin-item.is-pending { border-color:#ffd27a; background:#fffaf0; }
.admin-actions button.is-confirm { border-color:#a6dcb8; background:#e3f5e9; color:#146c3a; }

/* Zgody, stopka i ustawienia konta */
label.consent { display:flex; align-items:flex-start; gap:8px; margin:14px 0 4px; font-weight:600; font-size:13px; line-height:1.45; }
label.consent input { flex:0 0 18px; width:18px; min-height:18px; margin:1px 0 0; padding:0; }
.footer-links { display:flex; flex-wrap:wrap; justify-content:center; gap:4px 16px; margin-bottom:6px; font-size:12px; }
.footer-links a { color:#68768a; }
.minutes-field { display:flex; flex-wrap:wrap; align-items:center; gap:8px; margin:10px 0 4px; font-weight:650; }
.minutes-field input { width:84px; text-align:center; }
.delete-form { margin-top:14px; padding:14px; border:1px solid #f3c3bd; border-radius:12px; background:#fff8f7; }
.delete-form p { color:#7a1f16; }
.seller-warning { padding:10px 12px; border-radius:10px; background:#fff6e5; color:var(--amber); font-weight:650; }

/* Strony dokumentów: Pomoc, Regulamin, Polityka prywatności */
.doc { max-width:780px; margin:0 auto; padding:28px 20px 60px; line-height:1.65; font-size:15px; }
.doc h1 { margin:0 0 4px; font-size:clamp(24px,3vw,30px); letter-spacing:-.02em; color:var(--navy); }
.doc h2 { margin:34px 0 8px; font-size:19px; color:var(--navy); scroll-margin-top:calc(var(--topbar) + 12px); }
.doc h3 { margin:20px 0 6px; font-size:16px; color:#263750; }
.doc p, .doc li { overflow-wrap:anywhere; }
.doc ol, .doc ul { padding-left:22px; }
.doc li + li { margin-top:4px; }
.doc .doc-meta { margin:0 0 20px; color:var(--muted); font-size:13px; }
.doc .doc-toc { padding:14px 18px; border:1px solid var(--line); border-radius:14px; background:white; }
.doc .doc-toc ol { margin:6px 0 0; }
.doc .callout { padding:12px 16px; border-left:4px solid var(--blue); border-radius:8px; background:var(--soft); }
.doc .seller-missing { color:var(--red); font-weight:700; }
.doc table { width:100%; border-collapse:collapse; font-size:14px; }
.doc th, .doc td { padding:8px 10px; border-bottom:1px solid var(--line); text-align:left; vertical-align:top; }
.doc .table-wrap { overflow-x:auto; }
.doc .lead { font-size:16.5px; color:#263750; }
.doc .doc-figure { margin:16px 0 22px; }
.doc .doc-figure img { display:block; width:100%; height:auto; border-radius:14px; box-shadow:0 4px 18px #0b1c3414; }
.doc .doc-figure figcaption { margin-top:8px; color:var(--muted); font-size:13px; line-height:1.5; }
.doc .figure-row { display:grid; grid-template-columns:1fr 1fr; gap:18px; }
.doc .figure-row .doc-figure { margin:8px 0 14px; }
.doc .steps { padding-left:22px; }
.doc .usecases { display:grid; grid-template-columns:1fr 1fr; gap:12px; }
.doc .usecase { padding:14px 16px; border:1px solid var(--line); border-radius:14px; background:white; }
.doc .usecase h3 { margin:0 0 4px; font-size:15px; }
.doc .usecase p { margin:0; font-size:14px; line-height:1.55; }
.doc .doc-cta { display:flex; flex-wrap:wrap; gap:10px; margin-top:20px; }
@media (max-width:620px) { .doc .figure-row,.doc .usecases { grid-template-columns:1fr; } }
.contact-form { display:grid; gap:14px; margin:18px 0 8px; padding:18px; border:1px solid var(--line); border-radius:14px; background:white; }
.contact-form label { display:grid; gap:6px; font-weight:750; font-size:14px; color:#263750; }
.contact-form label .measurement { display:inline; font-weight:500; font-size:12px; }
.contact-form textarea { resize:vertical; line-height:1.5; }
.contact-form .contact-trap { position:absolute; left:-9999px; width:1px; height:1px; overflow:hidden; }
.contact-actions { display:flex; flex-wrap:wrap; align-items:center; gap:12px; font-size:14px; color:var(--muted); }
.admin-item.is-new { border-color:#9cc0f5; background:#f4f8ff; }
.contact-message { margin:6px 0 0; white-space:pre-wrap; }
.doc .form-template { padding:16px 18px; border:1px dashed #a9bbcf; border-radius:12px; background:white; }
@media print { .topbar, .footer-links, .app-footer { display:none; } .doc { padding:0; } }
