/* Aplikacja stadniny. Najpierw telefon, potem komputer (od 960 px boczne menu). Bazuje na stylach CRM crm-kursy-kpp. */
:root {
  --granat: #26392f; --granat-2: #34493d; --tekst: #1f2a24; --szary: #6b6f68; --szary-2: #9b9e96;
  --niebieski: #2e7d5b; --niebieski-ciemny: #22654a; --niebieski-tlo: #e4f1ea; --braz: #a8672f; --braz-tlo: #f6ece1;
  --tlo: #f4f1ea; --karta: #ffffff; --linia: #e5e1d8; --linia-2: #f0ede6;
  --zielony: #1f9d68; --zielony-tlo: #e3f5ec; --czerwony: #d23f3f; --czerwony-tlo: #fdeaea; --zolty: #c98a06; --zolty-tlo: #fdf3dc;
  --promien: 14px; --cien: 0 1px 2px rgba(31, 44, 53, .06), 0 4px 16px rgba(31, 44, 53, .06);
  --dol: env(safe-area-inset-bottom, 0px);
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 16px/1.45 Barlow, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: var(--tekst); background: var(--tlo); -webkit-tap-highlight-color: transparent; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--niebieski-ciemny); }
h1, h2, h3 { line-height: 1.2; margin: 0; }
img, svg { max-width: 100%; }
[hidden] { display: none !important; }

/* ---------- Ładowanie ---------- */
.ladowanie { min-height: 100vh; display: grid; place-items: center; }
.start-logo img { width: 150px; height: auto; opacity: .9; animation: puls 1.4s ease-in-out infinite; }
@keyframes puls { 50% { opacity: .45; } }

/* ---------- Układ ---------- */
.uklad { min-height: 100vh; padding-bottom: calc(76px + var(--dol)); }
.gora { position: sticky; top: 0; z-index: 20; background: rgba(255, 255, 255, .94); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--linia);
  display: flex; align-items: center; gap: 10px; padding: 10px 16px; padding-top: calc(10px + env(safe-area-inset-top, 0px)); min-height: 58px; }
.gora .wstecz { border: 0; background: var(--linia-2); width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; cursor: pointer; flex: none; color: var(--granat); text-decoration: none; }
.gora h1 { font-size: 20px; font-weight: 700; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gora .znak-m { width: 34px; height: 34px; flex: none; }
.gora .akcje { display: flex; gap: 8px; }
.tresc { padding: 16px 16px 84px; max-width: 1100px; margin: 0 auto; }
.menu-boczne { display: none; }

.nav-dol { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; background: #fff; border-top: 1px solid var(--linia); display: grid; grid-template-columns: repeat(5, 1fr);
  padding-bottom: var(--dol); box-shadow: 0 -4px 20px rgba(31, 44, 53, .05); }
.nav-dol a { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 2px 9px; text-decoration: none; color: var(--szary); font-size: 12px; font-weight: 600; position: relative; }
.nav-dol a svg { width: 25px; height: 25px; }
.nav-dol a.akt { color: var(--niebieski-ciemny); }
.nav-dol a.akt::before { content: ""; position: absolute; top: 0; left: 28%; right: 28%; height: 3px; border-radius: 0 0 3px 3px; background: var(--niebieski); }
.znaczek { position: absolute; top: 4px; left: calc(50% + 6px); min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--czerwony); color: #fff; font-size: 11px; font-weight: 700; display: grid; place-items: center; line-height: 1; }

@media (min-width: 960px) {
  .uklad { padding: 0 0 0 250px; }
  .nav-dol { display: none; }
  .menu-boczne { display: flex; flex-direction: column; position: fixed; left: 0; top: 0; bottom: 0; width: 250px; background: #fff; border-right: 1px solid var(--linia); padding: 18px 12px; overflow-y: auto; z-index: 25; }
  .menu-boczne .logo-m { padding: 4px 10px 18px; }
  .menu-boczne .logo-m img { width: 170px; display: block; }
  .menu-boczne a.poz { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 11px; text-decoration: none; color: var(--tekst); font-weight: 600; position: relative; }
  .menu-boczne a.poz svg { width: 21px; height: 21px; color: var(--szary); flex: none; }
  .menu-boczne a.poz:hover { background: var(--linia-2); }
  .menu-boczne a.poz.akt { background: var(--niebieski-tlo); color: var(--niebieski-ciemny); }
  .menu-boczne a.poz.akt svg { color: var(--niebieski-ciemny); }
  .menu-boczne .znaczek { position: static; margin-left: auto; }
  .menu-boczne .sekcja-m { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--szary-2); font-weight: 700; margin: 16px 12px 6px; }
  .menu-boczne .ja { margin-top: auto; padding: 12px; border-top: 1px solid var(--linia); font-size: 14px; }
  .gora .znak-m { display: none; }
  .tresc { padding: 24px 28px; }
}

/* ---------- Karty, listy ---------- */
.karta { background: var(--karta); border-radius: var(--promien); box-shadow: var(--cien); padding: 16px; margin-bottom: 14px; }
.karta > h2, .karta-nag h2 { font-size: 17px; font-weight: 700; }
.karta-nag { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.karta-nag a, .karta-nag button.link { font-size: 14px; font-weight: 600; }
.siatka-2 { display: grid; gap: 14px; }
@media (min-width: 760px) { .siatka-2 { grid-template-columns: 1fr 1fr; align-items: start; } .siatka-2 > .karta { margin-bottom: 0; } }
.kafle { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 14px; }
@media (min-width: 760px) { .kafle { grid-template-columns: repeat(4, 1fr); } }
.kafel { background: var(--karta); border-radius: var(--promien); box-shadow: var(--cien); padding: 13px 14px; text-decoration: none; color: inherit; display: block; }
.kafel .l { font-size: 13px; color: var(--szary); font-weight: 600; }
.kafel .w { font-size: 24px; font-weight: 800; margin-top: 2px; color: var(--granat); }
.kafel .w small { font-size: 14px; font-weight: 600; color: var(--szary); }
.kafel.alarm .w { color: var(--czerwony); }

.lista { list-style: none; margin: 0; padding: 0; }
.lista > li { border-top: 1px solid var(--linia-2); }
.lista > li:first-child { border-top: 0; }
.wiersz { display: flex; gap: 12px; align-items: center; padding: 12px 0; text-decoration: none; color: inherit; }
.wiersz .glowne { flex: 1; min-width: 0; }
.wiersz .tyt { font-weight: 700; }
.wiersz .pod { font-size: 14px; color: var(--szary); }
.wiersz .prawo { text-align: right; flex: none; }
.wiersz .kwota { font-weight: 800; white-space: nowrap; }
.dzien-pudelko { width: 50px; flex: none; text-align: center; border-radius: 12px; background: var(--niebieski-tlo); color: var(--niebieski-ciemny); padding: 5px 0 6px; line-height: 1.1; }
.dzien-pudelko b { display: block; font-size: 21px; font-weight: 800; }
.dzien-pudelko span { font-size: 11px; text-transform: uppercase; font-weight: 700; letter-spacing: .04em; }
.dzien-pudelko.dzis { background: var(--niebieski); color: #fff; }
.pusto { text-align: center; color: var(--szary); padding: 22px 10px; }
.pusto svg { width: 40px; height: 40px; color: var(--szary-2); display: block; margin: 0 auto 8px; }

/* osoby */
.osoby { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.osoba { display: inline-flex; align-items: center; gap: 6px; background: var(--linia-2); border-radius: 20px; padding: 3px 10px 3px 3px; font-size: 14px; font-weight: 600; }
.av { width: 24px; height: 24px; border-radius: 50%; color: #fff; display: inline-grid; place-items: center; font-size: 11px; font-weight: 800; flex: none; line-height: 1; }
.osoba .av { width: 24px; height: 24px; border-radius: 50%; color: #fff; display: grid; place-items: center; font-size: 11px; font-weight: 800; flex: none; }
.osoba button { border: 0; background: none; padding: 0 0 0 2px; cursor: pointer; color: var(--szary); font-size: 16px; line-height: 1; }
.osoba .osoba-usun { width: 22px; height: 22px; margin: 0 -4px 0 2px; padding: 0; border-radius: 50%; display: grid; place-items: center; background: #fff; color: var(--szary); box-shadow: 0 0 0 1px var(--linia); transition: background .15s, color .15s; }
.osoba .osoba-usun:hover, .osoba .osoba-usun:focus-visible { background: #fdeceb; color: #c13d36; box-shadow: 0 0 0 1px #f3b9b5; }
.btn-przypisz { border-style: dashed; }
.szukaj-os { width: 100%; min-height: 46px; margin-bottom: 8px; padding: 10px 14px; border: 1px solid #cfd7dd; border-radius: 12px; background: #fff; font: inherit; font-size: 16px; }
.szukaj-os:focus { outline: 2px solid #8fd3f3; border-color: #127fb5; }
.wybor-osob { max-height: min(50vh, 380px); overflow: auto; margin: 0 -4px; padding: 0 4px; }
.wybor-os { display: flex; align-items: center; gap: 12px; padding: 10px 6px; border-top: 1px solid var(--linia-2); cursor: pointer; font-weight: 700; border-radius: 10px; }
.wybor-os:first-child { border-top: 0; }
.wybor-os[hidden] { display: none; }
.wybor-os:hover { background: var(--linia-2); }
.wybor-os input { width: 20px; height: 20px; flex: none; accent-color: #127fb5; }
.wybor-os .av { width: 30px; height: 30px; border-radius: 50%; color: #fff; display: grid; place-items: center; font-size: 12px; font-weight: 800; flex: none; }
.wybor-os small { margin-left: auto; color: var(--szary); font-weight: 600; }
.wybor-os.jest { opacity: .55; cursor: default; }
.wybor-wszystkie { display: flex; align-items: center; gap: 10px; margin-top: 12px; padding: 12px; background: var(--linia-2); border-radius: 12px; font-weight: 600; cursor: pointer; }
.wybor-wszystkie input { width: 20px; height: 20px; accent-color: #127fb5; }
.av-duzy { width: 42px; height: 42px; border-radius: 50%; color: #fff; display: grid; place-items: center; font-weight: 800; flex: none; }

/* znaczki statusów */
.st { display: inline-block; font-size: 12px; font-weight: 700; border-radius: 20px; padding: 2px 9px; white-space: nowrap; background: var(--linia-2); color: var(--szary); }
.st.ok { background: var(--zielony-tlo); color: var(--zielony); }
.st.czeka { background: var(--zolty-tlo); color: var(--zolty); }
.st.zle { background: var(--czerwony-tlo); color: var(--czerwony); }
.st.info { background: var(--niebieski-tlo); color: var(--niebieski-ciemny); }
.rodzaj { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.rodzaj-kurs { color: #1283b8; } .rodzaj-zabezpieczenie { color: #c0392b; } .rodzaj-szkolenie { color: #7b4fc9; } .rodzaj-wpis { color: #66747e; }

/* ---------- Przyciski ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 10px 18px; border-radius: 12px; border: 1px solid var(--linia); background: #fff;
  font-weight: 700; cursor: pointer; text-decoration: none; color: var(--tekst); transition: background .15s, transform .05s; white-space: nowrap; }
.btn:active { transform: scale(.98); }
.btn svg { width: 19px; height: 19px; flex: none; }
.btn-gl { background: var(--niebieski); border-color: var(--niebieski); color: #fff; }
.btn-gl:hover { background: var(--niebieski-ciemny); }
.btn-ciemny { background: var(--granat); border-color: var(--granat); color: #fff; }
.btn-ok { background: var(--zielony); border-color: var(--zielony); color: #fff; }
.btn-zle { color: var(--czerwony); }
.btn-maly { min-height: 36px; padding: 6px 12px; font-size: 14px; border-radius: 10px; }
.btn-pelny { width: 100%; }
.btn:disabled { opacity: .55; cursor: default; }
.przyciski { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.przyciski.na-koniec { justify-content: flex-end; }
.link { border: 0; background: none; padding: 0; color: var(--niebieski-ciemny); cursor: pointer; font-weight: 600; }
.ikona-btn { border: 0; background: var(--linia-2); width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; cursor: pointer; color: var(--granat); flex: none; }
.ikona-btn svg { width: 20px; height: 20px; }
.fab { position: fixed; right: 16px; bottom: calc(88px + var(--dol)); z-index: 29; width: 58px; height: 58px; border-radius: 18px; border: 0; background: var(--niebieski); color: #fff;
  display: grid; place-items: center; box-shadow: 0 8px 24px rgba(46, 125, 91, .4); cursor: pointer; text-decoration: none; }
.fab svg { width: 28px; height: 28px; }
@media (min-width: 960px) { .fab { bottom: 28px; right: 28px; } }

/* ---------- Formularze ---------- */
.pole { display: block; margin-bottom: 14px; }
.pole > span, .etykieta { display: block; font-size: 14px; font-weight: 700; margin-bottom: 5px; color: var(--granat-2); }
.pole input, .pole select, .pole textarea, .wejscie { width: 100%; min-height: 48px; padding: 11px 13px; border: 1px solid #cfd7dd; border-radius: 12px; background: #fff; font-size: 16px; outline: none; }
.pole textarea { min-height: 90px; resize: vertical; }
.pole input:focus, .pole select:focus, .pole textarea:focus, .wejscie:focus { border-color: var(--niebieski); box-shadow: 0 0 0 3px rgba(46, 125, 91, .18); }
.pole .pomoc { display: block; font-size: 13px; color: var(--szary); margin-top: 4px; font-weight: 400; }
.pole .blad, .blad-pola { display: block; font-size: 13px; color: var(--czerwony); margin-top: 4px; font-weight: 600; }
.pole.zle input, .pole.zle select, .pole.zle textarea { border-color: var(--czerwony); }
.rzad { display: grid; gap: 0 12px; grid-template-columns: 1fr 1fr; }
.rzad-3 { display: grid; gap: 0 10px; grid-template-columns: 1fr 1fr 1fr; }
@media (max-width: 380px) { .rzad-3 { grid-template-columns: 1fr 1fr; } }
.check { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 12px; cursor: pointer; font-weight: 600; }
.check input { width: 22px; height: 22px; margin: 0; flex: none; accent-color: var(--niebieski); }
.check small { display: block; font-weight: 400; color: var(--szary); }
.z-przyciskiem { display: flex; gap: 8px; }
.z-przyciskiem input { flex: 1; min-width: 0; }
.przelacznik { display: flex; background: var(--linia-2); border-radius: 12px; padding: 4px; gap: 4px; margin-bottom: 14px; overflow-x: auto; }
.przelacznik button, .przelacznik a { flex: 1; border: 0; background: none; padding: 9px 10px; border-radius: 9px; font-weight: 700; color: var(--szary); cursor: pointer; white-space: nowrap; text-decoration: none; text-align: center; font-size: 15px; position: relative; }
.przelacznik .akt { background: #fff; color: var(--tekst); box-shadow: 0 1px 3px rgba(0, 0, 0, .08); }
.przelacznik .znaczek { position: static; display: inline-grid; margin-left: 4px; vertical-align: 1px; }
.filtry { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 12px; scrollbar-width: none; }
.filtry::-webkit-scrollbar { display: none; }
.filtry button { border: 1px solid var(--linia); background: #fff; border-radius: 20px; padding: 7px 14px; font-weight: 700; font-size: 14px; white-space: nowrap; cursor: pointer; color: var(--szary); }
.filtry button.akt { background: var(--granat); border-color: var(--granat); color: #fff; }

/* licznik ilości (materiały) */
.licznik { display: flex; align-items: center; gap: 6px; flex: none; }
.licznik button { width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--linia); background: #fff; font-size: 22px; font-weight: 700; cursor: pointer; display: grid; place-items: center; color: var(--granat); }
.licznik input { width: 58px; min-height: 40px; text-align: center; border: 1px solid #cfd7dd; border-radius: 10px; font-size: 17px; font-weight: 700; padding: 6px 4px; }
.licznik input.ma { border-color: var(--niebieski); background: var(--niebieski-tlo); }
.material { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-top: 1px solid var(--linia-2); }
.material:first-child { border-top: 0; }
.material .n { flex: 1; min-width: 0; font-weight: 600; }
.material .n small { color: var(--szary); font-weight: 400; }

/* dni wydarzenia w formularzu */
.dzien-edycja { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: end; padding: 12px; background: var(--linia-2); border-radius: 12px; margin-bottom: 8px; }
.dzien-edycja .pola-d { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 8px; }
.dzien-edycja label span { font-size: 12px; font-weight: 700; color: var(--szary); display: block; margin-bottom: 3px; }
.dzien-edycja input { width: 100%; min-height: 44px; border: 1px solid #cfd7dd; border-radius: 10px; padding: 8px; background: #fff; font-size: 15px; }
.dzien-edycja .dz-nazwa { grid-column: 1 / -1; font-size: 13px; font-weight: 700; color: var(--niebieski-ciemny); margin-bottom: -4px; }
@media (max-width: 420px) { .dzien-edycja .pola-d { grid-template-columns: 1fr 1fr; } .dzien-edycja .pola-d label:first-child { grid-column: 1 / -1; } }

/* pozycje faktury */
.pozycja-fv { border: 1px solid var(--linia); border-radius: 12px; padding: 12px; margin-bottom: 10px; position: relative; background: #fff; }
.pozycja-fv .usun-poz { position: absolute; top: 8px; right: 8px; }
.pozycja-fv .rzad-poz { display: grid; grid-template-columns: 1fr 1fr; gap: 0 10px; }
@media (min-width: 700px) { .pozycja-fv .rzad-poz { grid-template-columns: 90px 90px 1fr 110px; } }
.pozycja-fv .suma-poz { font-size: 14px; color: var(--szary); text-align: right; }
.podsumowanie { background: var(--granat); color: #fff; border-radius: var(--promien); padding: 14px 16px; }
.podsumowanie .r { display: flex; justify-content: space-between; gap: 10px; font-size: 15px; opacity: .85; }
.podsumowanie .razem { font-size: 22px; font-weight: 800; opacity: 1; margin-top: 4px; }

/* ---------- Kalendarz ---------- */
.kal-nag { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.kal-nag h2 { flex: 1; text-align: center; font-size: 19px; font-weight: 800; text-transform: capitalize; }
.kal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.kal .dn { font-size: 12px; font-weight: 700; color: var(--szary); text-align: center; padding: 4px 0; text-transform: uppercase; }
.kal .dn.we { color: var(--niebieski-ciemny); }
.kal .d { min-height: 54px; border-radius: 10px; background: #fff; border: 1px solid var(--linia-2); padding: 4px; cursor: pointer; display: flex; flex-direction: column; gap: 2px; text-align: left; overflow: hidden; }
.kal .d.inny { background: transparent; border-color: transparent; color: var(--szary-2); }
.kal .d .nr { font-size: 14px; font-weight: 700; line-height: 1.2; display: flex; align-items: center; gap: 3px; }
.kal .d.dzis .nr span { background: var(--niebieski); color: #fff; border-radius: 7px; padding: 0 5px; }
.kal .d.wyb { border-color: var(--granat); box-shadow: inset 0 0 0 1px var(--granat); }
.kal .d .kropki { display: flex; flex-wrap: wrap; gap: 3px; }
.kal .d .kropki i { width: 7px; height: 7px; border-radius: 50%; display: block; }
.kal .d .pasek { display: none; font-size: 11px; font-weight: 700; border-radius: 4px; padding: 1px 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #fff; }
.kal .d .ja { width: 6px; height: 6px; border-radius: 50%; background: var(--zielony); margin-left: auto; }
@media (min-width: 760px) {
  .kal .d { min-height: 92px; padding: 6px; }
  .kal .d .kropki { display: none; }
  .kal .d .pasek { display: block; }
}
.k-kurs { background: #1ea0dc; } .k-zabezpieczenie { background: #d9534f; } .k-szkolenie { background: #8a5cd6; } .k-wpis { background: #8d9aa4; }
.k-odwolane { background: #b8c1c7 !important; text-decoration: line-through; }
.legenda { display: flex; flex-wrap: wrap; gap: 12px; font-size: 13px; color: var(--szary); margin: 10px 0 0; }
.legenda i { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 5px; }

.dzien-wyd { border-left: 4px solid var(--niebieski); padding: 12px 0 12px 12px; }
.dzien-wyd + .dzien-wyd { border-top: 1px solid var(--linia-2); }
.dzien-wyd.k-b-zabezpieczenie { border-left-color: #d9534f; } .dzien-wyd.k-b-szkolenie { border-left-color: #8a5cd6; } .dzien-wyd.k-b-wpis { border-left-color: #8d9aa4; }
.dzien-wyd .tyt { font-weight: 800; font-size: 17px; }
.dzien-wyd .meta { font-size: 14px; color: var(--szary); display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 2px; }
.dzien-wyd .dol { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-top: 8px; }

/* ---------- Okno (na telefonie od dołu) ---------- */
.okno-tlo { position: fixed; inset: 0; background: rgba(20, 30, 38, .45); z-index: 100; display: flex; align-items: flex-end; justify-content: center; animation: zanik .15s; }
.okno { background: #fff; width: 100%; max-width: 560px; max-height: 92vh; overflow-y: auto; border-radius: 20px 20px 0 0; padding: 18px 16px calc(18px + var(--dol)); animation: wjazd .2s ease-out; }
.okno h2 { font-size: 19px; margin-bottom: 12px; }
@media (min-width: 640px) { .okno-tlo { align-items: center; } .okno { border-radius: 18px; padding: 22px; } }
@keyframes zanik { from { opacity: 0; } }
@keyframes wjazd { from { transform: translateY(40px); opacity: .5; } }

/* ---------- Komunikaty ---------- */
.toast { position: fixed; left: 50%; bottom: calc(92px + var(--dol)); transform: translateX(-50%); background: var(--granat); color: #fff; padding: 12px 18px; border-radius: 12px; z-index: 200;
  font-weight: 600; box-shadow: 0 8px 30px rgba(0, 0, 0, .2); max-width: calc(100% - 32px); animation: wjazd .2s; }
.toast.zle { background: var(--czerwony); }
@media (min-width: 960px) { .toast { bottom: 30px; left: calc(50% + 125px); } }
.info-box { background: var(--niebieski-tlo); color: #1d5a40; border-radius: 12px; padding: 12px 14px; font-size: 15px; margin-bottom: 14px; }
.info-box.zolty { background: var(--zolty-tlo); color: #7a5300; }
.info-box.czerwony { background: var(--czerwony-tlo); color: #9b2020; }
.info-box.zielony { background: var(--zielony-tlo); color: #146b47; }
.szary { color: var(--szary); } .maly { font-size: 14px; } .gruby { font-weight: 700; } .prawo { text-align: right; } .nowrap { white-space: nowrap; }
.kod { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 13px; background: var(--linia-2); border-radius: 8px; padding: 10px; word-break: break-all; display: block; user-select: all; }

/* tabela (komputer) / karty (telefon) */
.tabela { width: 100%; border-collapse: collapse; font-size: 15px; }
.tabela th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--szary); padding: 8px; border-bottom: 1px solid var(--linia); white-space: nowrap; }
.tabela td { padding: 10px 8px; border-bottom: 1px solid var(--linia-2); vertical-align: middle; }
.tabela .r { text-align: right; white-space: nowrap; }
@media (max-width: 700px) {
  .tabela.karty thead { display: none; }
  .tabela.karty, .tabela.karty tbody, .tabela.karty tr, .tabela.karty td { display: block; width: 100%; }
  .tabela.karty tr { border-bottom: 1px solid var(--linia); padding: 10px 0; }
  .tabela.karty td { border: 0; padding: 3px 0; display: flex; justify-content: space-between; gap: 10px; text-align: right; }
  .tabela.karty td::before { content: attr(data-l); color: var(--szary); font-size: 14px; text-align: left; font-weight: 600; }
  .tabela.karty td.pierwsza { font-weight: 800; font-size: 17px; }
  .tabela.karty td.pierwsza::before { display: none; }
}

/* ---------- Logowanie ---------- */
.logowanie { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 24px 16px; background: linear-gradient(180deg, #fff 0%, var(--tlo) 100%); }
.logowanie .pudlo { width: 100%; max-width: 400px; }
.logowanie .logo-l { display: block; width: 150px; margin: 0 auto 22px; }
.logowanie .karta { padding: 22px; }
.stopka-pw { text-align: center; font-size: 13px; color: var(--szary); margin: 24px 0 8px; }
.stopka-pw a { color: var(--szary); font-weight: 600; }
.menu-boczne .stopka-pw { margin: 10px 0 0; text-align: left; padding: 0 12px; }

/* menu „Więcej” (telefon) */
.menu-lista a, .menu-lista button { display: flex; align-items: center; gap: 14px; width: 100%; padding: 14px 4px; border: 0; border-top: 1px solid var(--linia-2); background: none; text-decoration: none; color: var(--tekst); font-weight: 700; font-size: 17px; cursor: pointer; text-align: left; }
.menu-lista > :first-child { border-top: 0; }
.menu-lista svg { width: 24px; height: 24px; color: var(--niebieski-ciemny); flex: none; }
.menu-lista .strz { margin-left: auto; color: var(--szary-2); width: 18px; height: 18px; }
.menu-lista .znaczek { position: static; margin-left: auto; }

/* ---------- Pulpit ---------- */
.hero { position: relative; overflow: hidden; border-radius: 20px; padding: 20px; margin-bottom: 14px; color: #fff;
  background: radial-gradient(120% 140% at 100% 0%, #c08143 0%, rgba(192, 129, 67, 0) 55%), linear-gradient(135deg, #22352b 0%, #2b4a3a 60%, #3a5f45 100%);
  box-shadow: 0 10px 30px rgba(36, 58, 72, .22); display: grid; gap: 16px; }
.hero-ekg { position: absolute; left: 0; right: 0; bottom: 6px; width: 100%; height: 90px; opacity: .13; pointer-events: none; }
.hero-ekg path { fill: none; stroke: #fff; stroke-width: 4; stroke-linejoin: round; stroke-linecap: round; }
.hero-tekst { position: relative; }
.hero-data { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; opacity: .75; }
.hero h2 { font-size: 26px; font-weight: 800; margin: 4px 0 4px; letter-spacing: -.01em; }
.hero p { margin: 0; opacity: .88; font-size: 15px; }
.hero-dzien { position: relative; display: flex; flex-direction: column; gap: 2px; text-decoration: none; color: #fff; background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 16px; padding: 13px 15px; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); transition: background .15s; }
.hero-dzien:hover { background: rgba(255, 255, 255, .18); }
.hero-dzien b { font-size: 18px; font-weight: 800; }
.hero-dzien span { font-size: 14px; opacity: .9; }
.hero-etyk { font-size: 11px !important; text-transform: uppercase; letter-spacing: .09em; font-weight: 700; opacity: .7 !important; }
.osoby-mini { display: flex; margin-top: 6px; }
.osoby-mini .av { width: 28px; height: 28px; font-size: 11px; border: 2px solid #2b4a3a; margin-left: -7px; }
.osoby-mini .av:first-child { margin-left: 0; }
.osoby-mini-j { margin: 0; flex: none; }
.osoby-mini-j .av { width: 26px; height: 26px; font-size: 10px; border-color: #fff; }
.av-wiecej { background: var(--linia) !important; color: var(--szary) !important; }
@media (max-width: 420px) { .osoby-mini-j { display: none; } }
@media (min-width: 760px) { .hero { grid-template-columns: 1fr minmax(260px, 340px); align-items: center; padding: 26px 28px; } .hero h2 { font-size: 30px; } }
.kafel-ik { display: flex; align-items: center; gap: 12px; }
.kafel-ik > span:last-child { min-width: 0; }
.kafel-ik .l { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kafel-ik .w { display: block; font-size: 22px; }
.kafel-ikona { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; flex: none; }
.kafel-ikona svg { width: 22px; height: 22px; }
.k-nieb { background: var(--niebieski-tlo); color: var(--niebieski-ciemny); } .k-ziel { background: var(--zielony-tlo); color: var(--zielony); }
.k-czer { background: var(--czerwony-tlo); color: var(--czerwony); } .k-fiol { background: #efe9fb; color: #6d43c4; } .k-szary { background: var(--linia-2); color: var(--szary); }
@media (max-width: 520px) {
  .kafle { gap: 8px; }
  .kafel-ik { padding: 11px; gap: 9px; }
  .kafel-ikona { width: 34px; height: 34px; border-radius: 10px; }
  .kafel-ikona svg { width: 18px; height: 18px; }
  .kafel-ik .l { font-size: 12px; white-space: normal; line-height: 1.2; }
  .kafel-ik .w { font-size: 18px; }
  .hero { padding: 16px; gap: 12px; border-radius: 18px; }
  .hero h2 { font-size: 23px; }
  .hero-dzien { padding: 11px 13px; }
  .hero-dzien b { font-size: 16px; }
  .wyplaty-suma b { font-size: 15px; }
  .wyplaty-suma div { padding: 8px 9px; }
}
.karta-nag h2 { display: flex; align-items: center; gap: 8px; }
.karta-nag h2 svg { color: var(--niebieski-ciemny); }
.karta-akcent { border-left: 4px solid var(--zolty); }
.karta-akcent h2 svg { color: var(--zolty); }
.mies-nav { display: flex; align-items: center; gap: 4px; font-weight: 700; font-size: 14px; text-transform: capitalize; }
.mies-nav a { width: 32px; height: 32px; border-radius: 10px; background: var(--linia-2); display: grid; place-items: center; color: var(--granat); }
.mies-nav span { min-width: 112px; text-align: center; }
.wyplaty-suma { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 6px; }
.wyplaty-suma div { background: var(--linia-2); border-radius: 12px; padding: 9px 11px; }
.wyplaty-suma span { display: block; font-size: 12px; color: var(--szary); font-weight: 600; line-height: 1.2; }
.wyplaty-suma b { font-size: 17px; color: var(--granat); }
.wyplaty-suma div:first-child { background: var(--granat); }
.wyplaty-suma div:first-child span { color: rgba(255, 255, 255, .7); } .wyplaty-suma div:first-child b { color: #fff; }
.btn-ok-obrys { border-color: var(--zielony); color: var(--zielony); margin-top: 4px; }
.btn-ok-obrys:hover { background: var(--zielony-tlo); }
.st-btn { border: 0; cursor: pointer; margin-top: 4px; display: inline-flex; align-items: center; gap: 3px; }
.czeka-txt { color: var(--zolty); font-weight: 600; }
.karta-wyplaty .wiersz .prawo { display: flex; flex-direction: column; align-items: flex-end; }

/* ---------- Prezentacje ---------- */
.kafle-kat { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 640px) { .kafle-kat { grid-template-columns: repeat(3, 1fr); gap: 14px; } }
@media (min-width: 1100px) { .kafle-kat { grid-template-columns: repeat(4, 1fr); } }
.kat { position: relative; display: flex; flex-direction: column; gap: 4px; min-height: 140px; padding: 16px; border-radius: 18px; text-decoration: none; color: #fff; overflow: hidden;
  background: var(--kk); background: linear-gradient(145deg, var(--kk) 0%, color-mix(in srgb, var(--kk) 70%, #1f2c35) 100%); box-shadow: 0 6px 18px color-mix(in srgb, var(--kk) 30%, transparent); transition: transform .15s, box-shadow .15s; }
.kat:hover { transform: translateY(-2px); box-shadow: 0 10px 26px color-mix(in srgb, var(--kk) 40%, transparent); }
.kat::after { content: ""; position: absolute; right: -30px; bottom: -40px; width: 130px; height: 130px; border-radius: 50%; background: rgba(255, 255, 255, .1); }
.kat-ikona { width: 50px; height: 50px; border-radius: 15px; background: rgba(255, 255, 255, .2); display: grid; place-items: center; margin-bottom: auto; }
.kat-nazwa { font-size: 18px; font-weight: 800; line-height: 1.15; margin-top: 12px; position: relative; z-index: 1; }
.kat-licz { font-size: 13px; opacity: .85; font-weight: 600; position: relative; z-index: 1; }
.kat-edytuj { position: absolute; top: 10px; right: 10px; width: 34px; height: 34px; border-radius: 10px; border: 0; background: rgba(255, 255, 255, .2); color: #fff; display: grid; place-items: center; cursor: pointer; z-index: 2; }
.kat-edytuj:hover { background: rgba(255, 255, 255, .32); }
.kat-naglowek { display: flex; align-items: center; gap: 14px; padding: 16px; border-radius: 18px; color: #fff; margin-bottom: 14px;
  background: var(--kk); background: linear-gradient(145deg, var(--kk) 0%, color-mix(in srgb, var(--kk) 70%, #1f2c35) 100%); }
.kat-naglowek h2 { font-size: 22px; font-weight: 800; }
.kat-naglowek > div { flex: 1; min-width: 0; }
.kat-naglowek span:not(.kat-ikona) { opacity: .85; font-size: 14px; }
.kat-naglowek .kat-ikona { margin: 0; }
.kat-naglowek .ikona-btn { background: rgba(255, 255, 255, .2); color: #fff; }
.prez { display: flex; gap: 12px; padding: 13px 0; border-top: 1px solid var(--linia-2); align-items: flex-start; }
.lista > .prez:first-child { border-top: 0; }
.prez .glowne { flex: 1; min-width: 0; }
.prez .tyt { font-weight: 700; font-size: 16px; }
.prez .pod { font-size: 13px; color: var(--szary); }
.typ-pliku { width: 46px; height: 54px; border-radius: 9px; color: #fff; display: grid; place-items: center; font-size: 11px; font-weight: 800; letter-spacing: .03em; flex: none; position: relative; }
.typ-pliku::before { content: ""; position: absolute; top: 0; right: 0; border-width: 0 12px 12px 0; border-style: solid; border-color: var(--tlo) rgba(0, 0, 0, .18) rgba(0, 0, 0, .18) var(--tlo); border-radius: 0 9px 0 4px; }
.prez-akcje { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.wybor-pliku { display: flex; align-items: center; gap: 14px; border: 2px dashed #c4ced5; border-radius: 14px; padding: 16px; cursor: pointer; margin-bottom: 14px; transition: border-color .15s, background .15s; }
.wybor-pliku:hover, .wybor-pliku.wybrany { border-color: var(--niebieski); background: var(--niebieski-tlo); }
.wybor-pliku input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.wp-ikona { width: 52px; height: 52px; border-radius: 14px; background: var(--niebieski-tlo); color: var(--niebieski-ciemny); display: grid; place-items: center; flex: none; }
.wybor-pliku.wybrany .wp-ikona { background: #fff; }
.wp-tekst { display: flex; flex-direction: column; min-width: 0; word-break: break-word; }
.wp-tekst small { color: var(--szary); }
.wybor-ikon, .wybor-kolorow { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.wybor-ikon input, .wybor-kolorow input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.wybor-ikon span { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--linia-2); color: var(--granat); cursor: pointer; border: 2px solid transparent; }
.wybor-ikon input:checked + span { border-color: var(--niebieski); background: var(--niebieski-tlo); color: var(--niebieski-ciemny); }
.wybor-kolorow span { width: 36px; height: 36px; border-radius: 50%; display: block; cursor: pointer; border: 3px solid #fff; box-shadow: 0 0 0 1px var(--linia); }
.wybor-kolorow input:checked + span { box-shadow: 0 0 0 3px var(--granat); }
.wybor-ikon input:focus-visible + span, .wybor-kolorow input:focus-visible + span { outline: 2px solid var(--niebieski); outline-offset: 2px; }
.postep { margin: 4px 0 10px; }
.postep-pasek { height: 10px; border-radius: 6px; background: var(--linia-2); overflow: hidden; }
.postep-pasek i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--niebieski), #49b9ec); transition: width .2s; }
.postep-tekst { font-size: 13px; color: var(--szary); }
@media (max-width: 520px) { .gora .akcje .btn:not(:last-child) span { display: none; } .gora .akcje .btn:not(:last-child) { padding: 6px 10px; } }

/* ---------- Kursy (lista pod kalendarzem i zakładka Kursy) ---------- */
.lista-kursow > li { border-top: 1px solid var(--linia-2); }
.lista-kursow > li:first-child { border-top: 0; }
.kurs { display: flex; align-items: center; gap: 14px; padding: 13px 2px; text-decoration: none; color: inherit; border-radius: 12px; transition: background .12s; }
.kurs:hover { background: var(--linia-2); }
.kurs .glowne { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.kurs .tyt { font-weight: 800; font-size: 17px; line-height: 1.25; }
.kurs .pod { font-size: 14px; color: var(--szary); }
.kurs .strz { color: var(--szary-2); flex: none; }
.kurs-data { width: 54px; flex: none; text-align: center; border-radius: 13px; padding: 6px 0 7px; line-height: 1.1; color: #fff; background: #1ea0dc; }
.kurs-data span { font-size: 11px; text-transform: uppercase; font-weight: 700; letter-spacing: .05em; opacity: .9; display: block; }
.kurs-data b { font-size: 22px; font-weight: 800; display: block; }
.kurs-data.k-b-zabezpieczenie { background: #d9534f; } .kurs-data.k-b-szkolenie { background: #8a5cd6; } .kurs-data.k-b-wpis { background: #8d9aa4; }
.kurs-znaczki { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 4px; }
.kurs-znaczki:empty { display: none; }
.kurs-znaczki .st { display: inline-flex; align-items: center; gap: 3px; }
.kal .d.ma .nr span { font-weight: 800; }

/* ---------- Sprzęt ---------- */
.grupa-sprzetu { margin-bottom: 18px; }
.grupa-sprzetu > .karta-nag { padding: 0 2px; }
.grupa-sprzetu > .karta-nag span { font-size: 14px; }
.zestawy { display: grid; grid-template-columns: 1fr; gap: 10px; }
@media (min-width: 640px) { .zestawy { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .zestawy { grid-template-columns: repeat(3, 1fr); } }
.zestaw { display: flex; flex-direction: column; gap: 9px; background: var(--karta); border-radius: var(--promien); box-shadow: var(--cien); padding: 14px 15px; text-decoration: none; color: inherit; border-left: 4px solid var(--zielony); transition: transform .12s; }
.zestaw:hover { transform: translateY(-1px); }
.zestaw.braki { border-left-color: var(--czerwony); }
.zestaw.nieaktywny { opacity: .6; }
.zestaw-nag { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.zestaw-nag > span:first-child { display: flex; flex-direction: column; min-width: 0; }
.zestaw-nag b { font-size: 17px; font-weight: 800; }
.zestaw-nag .st { display: inline-flex; align-items: center; gap: 3px; flex: none; }
.pasek-kompletu { height: 6px; border-radius: 4px; background: var(--czerwony-tlo); overflow: hidden; }
.pasek-kompletu i { display: block; height: 100%; background: var(--zielony); border-radius: 4px; }
.zestaw:not(.braki) .pasek-kompletu { background: var(--zielony-tlo); }
.braki-lista { display: flex; flex-direction: column; gap: 2px; font-size: 14px; }
.braki-lista span { display: flex; justify-content: space-between; gap: 10px; }
.braki-lista b { color: var(--czerwony); white-space: nowrap; }
.tabela-zestaw tr.brak td:first-child { font-weight: 700; }
.tabela-zestaw tr.brak { background: #fff7f7; }
.poz-zestawu { display: grid; grid-template-columns: 1fr 70px 74px 74px auto; gap: 8px; align-items: end; padding: 10px; background: var(--linia-2); border-radius: 12px; margin-bottom: 8px; }
.poz-zestawu input[readonly] { background: #f3f6f8; color: var(--szary); }
.poz-nowy { font-style: normal; font-weight: 700; color: #13917f; margin-left: 4px; }
.poz-zestawu select, .poz-zestawu input { width: 100%; min-height: 44px; border: 1px solid #cfd7dd; border-radius: 10px; padding: 8px; background: #fff; font-size: 15px; }
.poz-zestawu label span { display: block; font-size: 12px; font-weight: 700; color: var(--szary); margin-bottom: 3px; }
@media (max-width: 560px) { .poz-zestawu { grid-template-columns: 1fr 1fr 1fr auto; } .poz-zestawu .poz-nazwa { grid-column: 1 / -1; } }
@media (max-width: 759px) { .kal { gap: 3px; } .kal .d { min-height: 42px; padding: 3px 4px; } .kal .d .nr { font-size: 13px; } .kal-nag { margin-bottom: 6px; } .legenda { gap: 4px 10px; font-size: 12px; margin-top: 8px; } }

/* ---------- Strona www (edytor) ---------- */
.slajd-ed { display: grid; gap: 14px; }
@media (min-width: 760px) { .slajd-ed { grid-template-columns: 300px 1fr; } }
.slajd-ed-foto { position: relative; aspect-ratio: 16 / 9; border-radius: 12px; background: #2f3f49 center / cover no-repeat; display: flex; flex-direction: column; justify-content: space-between; align-items: flex-start; padding: 10px; }
.slajd-ed-foto .btn { margin-top: auto; }
.slajd-ed-pola .karta-nag { margin-bottom: 8px; }
.slajd-ed-pola .karta-nag span { display: flex; gap: 6px; }
.in-foto { width: 42px; height: 42px; border-radius: 50%; object-fit: cover; flex: none; }
.in-foto-ed { display: flex; gap: 14px; align-items: center; margin-bottom: 14px; }
.in-foto-duze { width: 96px; height: 96px; border-radius: 18px; overflow: hidden; flex: none; display: grid; place-items: center; background: var(--linia-2); }
.in-foto-duze img { width: 100%; height: 100%; object-fit: cover; }
.in-foto-duze .av-duzy { width: 96px; height: 96px; border-radius: 18px; font-size: 30px; }
.wiad { padding: 14px 0; border-top: 1px solid var(--linia-2); }
.lista > .wiad:first-child { border-top: 0; }
.wiad.nowa { border-left: 4px solid var(--niebieski); padding-left: 12px; }
.onas-zdj-ed { display: grid; grid-template-columns: 1fr; gap: 14px; max-width: 280px; }
.onas-zdj-ed > div { display: flex; flex-direction: column; gap: 4px; }
.klient-ed { display: grid; grid-template-columns: 110px 1fr 1fr auto; gap: 10px; align-items: end; padding: 12px; background: var(--linia-2); border-radius: 12px; margin-bottom: 10px; }
.klient-ed .pole { margin: 0; }
.klient-logo { height: 70px; border-radius: 10px; background: #fff; display: grid; place-items: center; padding: 8px; border: 1px solid var(--linia); }
.klient-logo img { max-height: 54px; max-width: 100%; object-fit: contain; }
.klient-akcje { display: flex; gap: 6px; }
@media (max-width: 700px) { .klient-ed { grid-template-columns: 90px 1fr; } .klient-ed .pole:nth-of-type(2) { grid-column: 1 / -1; } .klient-akcje { grid-column: 1 / -1; justify-content: flex-end; } }

/* ---------- Prośba o powiadomienia ---------- */
.push-prosba { position: fixed; left: 12px; right: 12px; bottom: calc(84px + env(safe-area-inset-bottom)); z-index: 60; display: grid; grid-template-columns: auto 1fr; gap: 10px 14px; align-items: center;
  max-width: 480px; margin: 0 auto; padding: 16px; background: #fff; border-radius: 18px; box-shadow: 0 18px 50px rgba(20, 35, 45, .25); transform: translateY(30px); opacity: 0; transition: transform .3s, opacity .3s; }
.push-prosba.widoczna { transform: none; opacity: 1; }
.push-ik { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #2aa7e1, #127fb5); }
.push-tekst b { display: block; font-size: 16px; }
.push-tekst span { display: block; color: var(--szary); font-size: 14px; line-height: 1.4; margin-top: 2px; }
.push-przyciski { grid-column: 1 / -1; display: flex; justify-content: flex-end; gap: 8px; }
@media (min-width: 960px) { .push-prosba { left: auto; right: 24px; bottom: 24px; margin: 0; } }
#karta-push h2 { display: flex; align-items: center; gap: 8px; }
#push-stan .st { margin-right: 6px; }
.kod-cron { margin: 0; padding: 10px 12px; background: var(--linia-2); border-radius: 10px; font-size: 12.5px; white-space: pre-wrap; word-break: break-all; }

/* ================= Stadnina ================= */
.btn-czer { background: var(--czerwony); border-color: var(--czerwony); color: #fff; }
.btn-czer-obrys { border-color: var(--czerwony); color: var(--czerwony); }
.btn-czer-obrys:hover { background: var(--czerwony-tlo); }
.czer-txt { color: var(--czerwony); font-weight: 600; }
.pulapka { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.nazwa-l { text-align: center; font-size: 22px; font-weight: 800; color: var(--granat); margin: -14px 0 18px; }
.logowanie .logo-l { width: 120px; }
.rej-zach { display: flex; flex-direction: column; gap: 6px; margin-top: 14px; }
.tekst-dl { max-height: 55vh; overflow-y: auto; font-size: 15px; background: var(--linia-2); border-radius: 10px; padding: 12px; }
.menu-boczne .logo-m { display: flex; align-items: center; gap: 10px; font-weight: 800; color: var(--granat); font-size: 17px; line-height: 1.15; }
.menu-boczne .logo-m img { width: 46px !important; }
.hero-ekg { opacity: .18; }
.poziom { display: inline-flex; align-items: center; gap: 2px; font-size: 12px; font-weight: 700; border-radius: 20px; padding: 1px 8px; white-space: nowrap; vertical-align: 1px; letter-spacing: .02em; }
.poziom.p-poczatkujacy { background: var(--zielony-tlo); color: var(--zielony); }
.poziom.p-sredni { background: var(--zolty-tlo); color: var(--zolty); }
.poziom.p-zaawansowany { background: var(--czerwony-tlo); color: var(--czerwony); }
.st.info { background: var(--braz-tlo); color: var(--braz); }

/* kalendarz */
.k-wolne { background: var(--niebieski); } .k-pelna { background: #a7aaa2; } .k-opieka { background: var(--braz); }
.kal .d .pasek.k-wolne-p { background: var(--niebieski); }
.kal .d .pasek.k-opieka { background: var(--braz); }
.naglowek-dnia { font-size: 15px; font-weight: 800; color: var(--szary); text-transform: capitalize; margin: 16px 0 8px; }
.naglowek-dnia:first-of-type { margin-top: 4px; }
.terminy-dnia { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.termin-chip { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; background: var(--braz-tlo); color: #7a4718; border-radius: 20px; padding: 4px 10px; text-decoration: none; }
.termin-chip.blok { box-shadow: inset 0 0 0 1px #d9a77a; }

/* karty jazd */
.jazdy-l { display: flex; flex-direction: column; gap: 8px; }
.jazda { border: 1px solid var(--linia); border-left: 4px solid var(--niebieski); border-radius: 12px; background: #fff; overflow: hidden; }
.jazda.moja { border-left-color: var(--zielony); background: #fbfdfb; }
.jazda.odwolana { opacity: .6; border-left-color: #b9bbb4; }
.jazda-gl { display: flex; align-items: center; gap: 12px; padding: 10px 12px; text-decoration: none; color: inherit; }
.jazda-czas { width: 52px; flex: none; text-align: center; line-height: 1.15; }
.jazda-czas b { display: block; font-size: 18px; font-weight: 800; color: var(--granat); }
.jazda-czas span { font-size: 12px; color: var(--szary); }
.jazda .glowne { flex: 1; min-width: 0; }
.jazda .tyt { font-weight: 700; }
.jazda .pod { font-size: 14px; color: var(--szary); }
.pary { display: flex; flex-wrap: wrap; gap: 5px; padding: 0 12px 10px 76px; }
.para { font-size: 13px; background: var(--linia-2); border-radius: 8px; padding: 3px 8px; }
.para.bez-konia { background: var(--zolty-tlo); color: #7a5300; }
.para.skreslona { text-decoration: line-through; opacity: .6; }
.jazda-dol { padding: 0 12px 10px 76px; }
@media (max-width: 420px) { .pary, .jazda-dol { padding-left: 12px; } }
.jazda-szcz .rodzaj { font-size: 13px; font-weight: 700; color: var(--niebieski-ciemny); text-transform: uppercase; letter-spacing: .04em; }
.jazda-szcz h2 { font-size: 22px; margin: 4px 0 8px; }
.meta { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 14px; color: var(--szary); }
.meta span { display: inline-flex; align-items: center; gap: 5px; }
.zapis-w { padding: 6px 0; border-top: 1px solid var(--linia-2); }
.zapis-w:first-child { border-top: 0; }
.zapis-w .wiersz { padding: 4px 0; border: 0; }
.zapis-akcje { display: flex; flex-wrap: wrap; gap: 6px; margin: 2px 0 6px; }

/* konie */
.kon-zdj, .kon-mini, .kon-sr, .kon-foto, .kon-duze { object-fit: cover; display: block; flex: none; background: var(--braz-tlo); color: var(--braz); }
.kon-zast { display: grid !important; place-items: center; }
.kon-mini { width: 40px; height: 40px; border-radius: 10px; }
.kon-mini svg { width: 22px; height: 22px; }
.kon-sr { width: 56px; height: 56px; border-radius: 12px; }
.kon-duze { width: 100%; max-width: 340px; aspect-ratio: 4 / 3; height: auto; border-radius: 14px; }
.kon-duze svg { width: 60px; height: 60px; }
.siatka-koni { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 700px) { .siatka-koni { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1100px) { .siatka-koni { grid-template-columns: repeat(4, 1fr); } }
.siatka-koni > .pusto { grid-column: 1 / -1; }
.kon-karta { background: #fff; border-radius: var(--promien); box-shadow: var(--cien); overflow: hidden; text-decoration: none; color: inherit; display: flex; flex-direction: column; }
.kon-karta.wyl { opacity: .55; }
.kon-foto { width: 100%; aspect-ratio: 4 / 3; height: auto; }
.kon-foto svg { width: 48px; height: 48px; }
.kon-info { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.kon-info b { font-size: 17px; }
.kon-stan { display: flex; flex-wrap: wrap; gap: 4px; }
.kon-gl { display: grid; gap: 16px; }
@media (min-width: 700px) { .kon-gl { grid-template-columns: 340px 1fr; align-items: start; } }
.kon-gl h2 { font-size: 24px; margin-bottom: 6px; }
.dane { display: grid; grid-template-columns: auto 1fr; gap: 4px 14px; margin: 12px 0; font-size: 15px; }
.dane dt { color: var(--szary); } .dane dd { margin: 0; font-weight: 600; }
.zdj-pole { display: grid; gap: 12px; margin-bottom: 14px; }
@media (min-width: 560px) { .zdj-pole { grid-template-columns: 220px 1fr; align-items: center; } }
.zdj-pole .kon-duze { max-width: 220px; }
.pod-naglowek { font-size: 16px; margin: 6px 0 10px; }
.dni-tyg { display: flex; flex-wrap: wrap; gap: 6px; }
.dni-tyg label { cursor: pointer; }
.dni-tyg input { position: absolute; opacity: 0; }
.dni-tyg span { display: inline-block; min-width: 44px; text-align: center; padding: 9px 6px; border-radius: 10px; border: 1px solid var(--linia); font-weight: 700; color: var(--szary); background: #fff; }
.dni-tyg input:checked + span { background: var(--braz); border-color: var(--braz); color: #fff; }
.dni-tyg input:focus-visible + span { outline: 2px solid var(--niebieski); }

/* wybór konia */
.wybor-koni { display: grid; grid-template-columns: 1fr; gap: 8px; }
@media (min-width: 520px) { .wybor-koni { grid-template-columns: 1fr 1fr; } }
.wybor-kon { display: flex; align-items: center; gap: 10px; text-align: left; border: 1px solid var(--linia); background: #fff; border-radius: 12px; padding: 8px; cursor: pointer; color: inherit; }
.wybor-kon:hover:not([disabled]) { border-color: var(--niebieski); box-shadow: 0 0 0 2px rgba(46, 125, 91, .15); }
.wybor-kon.niedost { opacity: .5; cursor: not-allowed; background: var(--linia-2); }
.wybor-kon.pomin { opacity: .8; cursor: pointer; }
.wk-txt { display: flex; flex-direction: column; gap: 2px; align-items: flex-start; min-width: 0; }
.wk-txt b { font-size: 16px; }
.wk-txt small { font-size: 12.5px; color: var(--szary); line-height: 1.25; }
.wybor-kon.niedost small { color: var(--czerwony); }

/* statystyki */
.stat-kafle { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.stat-k { background: var(--linia-2); border-radius: 12px; padding: 10px 12px; display: flex; flex-direction: column; }
.stat-k span { font-size: 12px; font-weight: 700; color: var(--szary); }
.stat-k b { font-size: 26px; font-weight: 800; color: var(--granat); line-height: 1.1; }
.stat-k b small { font-size: 14px; color: var(--szary); font-weight: 600; }
.stat-k > small { font-size: 13px; color: var(--szary); }
.tabela-wrap { overflow-x: auto; margin: 0 -4px; }
.tabela-stat { width: 100%; border-collapse: collapse; font-size: 15px; }
.tabela-stat th { text-align: right; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--szary); padding: 6px 8px; border-bottom: 1px solid var(--linia); }
.tabela-stat th:first-child { text-align: left; }
.tabela-stat td { text-align: right; padding: 8px; border-bottom: 1px solid var(--linia-2); white-space: nowrap; vertical-align: middle; }
.tabela-stat td b { font-size: 17px; }
.tabela-stat td small { color: var(--szary); }
.tabela-stat td small.g { display: block; font-size: 12px; }
.tabela-stat td.n { text-align: left; white-space: normal; }
.tabela-stat td.n a, .tabela-stat td.n span { display: inline-flex; align-items: center; gap: 8px; color: inherit; text-decoration: none; font-weight: 700; }
.tabela-stat tfoot td { font-weight: 800; border-bottom: 0; }
.data-wyb { border: 1px solid var(--linia); border-radius: 10px; padding: 6px 10px; font-weight: 700; background: #fff; max-width: 100%; }

/* należności */
.przyc-r { display: inline-flex; gap: 6px; align-items: center; margin-top: 4px; }
.przyc-r .ikona-btn { width: 34px; height: 34px; }
.przyc-r .btn-ok-obrys { margin-top: 0; }
.zaleglosci { margin-top: 14px; border-top: 1px solid var(--linia); padding-top: 10px; }
.zaleglosci h3 { font-size: 15px; display: flex; align-items: center; gap: 6px; color: var(--czerwony); margin-bottom: 4px; }
.szukaj-pole { margin-bottom: 12px; }

/* formy płatności */
.formy-suma { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 8px; }
.forma { font-size: 13px; border-radius: 20px; padding: 3px 10px; background: var(--linia-2); }
.f-blik { --f: #1f1f1f; } .f-przelew { --f: var(--niebieski-ciemny); } .f-gotowka { --f: var(--braz); }
.forma b { color: var(--f); }
.formy-wybor { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.forma-btn { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-height: 76px; border-radius: 14px; border: 2px solid var(--f); background: #fff; color: var(--f); font-weight: 800; font-size: 16px; cursor: pointer; }
.forma-btn:hover { background: var(--linia-2); }
.forma-btn.f-blik { letter-spacing: .06em; font-size: 19px; }

/* ================= Platforma (wiele stadnin) ================= */
.produkt-l { text-align: center; font-size: 13px; font-weight: 700; color: var(--szary); margin: -12px 0 16px; letter-spacing: .04em; text-transform: uppercase; }
.pasek-admin { position: sticky; top: 0; z-index: 25; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 8px 16px; background: #fff3d6; color: #6b4a00; font-size: 14px; border-bottom: 1px solid #f0d89a; }
.pasek-admin span { flex: 1; min-width: 200px; }
.menu-boczne .poz-zmien { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 11px; border: 0; background: var(--braz-tlo); color: #7a4718; font-weight: 700; width: 100%; cursor: pointer; margin-top: 8px; }
.menu-boczne .poz-zmien svg { width: 21px; height: 21px; }
.menu-lista button[disabled] { opacity: .6; cursor: default; }
.platforma { min-height: 100vh; }
.pl-gora { display: flex; align-items: center; gap: 12px; padding: 12px 16px; background: #fff; border-bottom: 1px solid var(--linia); position: sticky; top: 0; z-index: 20; }
.pl-gora img { width: 40px; height: 40px; }
.pl-gora div { flex: 1; display: flex; flex-direction: column; line-height: 1.2; }
.pl-gora div span { font-size: 13px; color: var(--szary); }
.platforma .kafel { pointer-events: none; }
.pl-st, .pl-link { padding: 8px 0; border-top: 1px solid var(--linia-2); }
.pl-st:first-child, .pl-link:first-child { border-top: 0; }
.pl-st .wiersz { border: 0; padding: 4px 0; }
.pl-link { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.pl-link .glowne { flex: 1; min-width: 220px; }
.pl-link.wyl, .pl-st.wyl { opacity: .6; }
.kod-link { display: block; font-size: 12px; background: var(--linia-2); border-radius: 8px; padding: 6px 8px; margin-top: 4px; word-break: break-all; }
.link-rej { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 10px; font-size: 14px; }
.link-rej code { flex: 1; min-width: 180px; background: var(--linia-2); border-radius: 8px; padding: 7px 10px; word-break: break-all; font-size: 13px; }
.link-rej-karta { display: flex; flex-direction: column; gap: 2px; }
.karta-start { border-left: 4px solid var(--niebieski); }
.kroki { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.krok { display: flex; align-items: center; gap: 10px; }
.krok a { display: flex; flex-direction: column; text-decoration: none; color: inherit; flex: 1; padding: 6px 0; }
.krok a small { color: var(--szary); font-size: 13px; }
.krok-ik { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--linia-2); color: var(--szary); flex: none; }
.krok.zrob .krok-ik { background: var(--zielony); color: #fff; }
.krok.zrob b { text-decoration: line-through; color: var(--szary); }
.z-prefiksem { display: flex; align-items: stretch; border: 1px solid #cfd7dd; border-radius: 12px; overflow: hidden; background: #fff; }
.z-prefiksem span { padding: 0 8px; display: flex; align-items: center; background: var(--linia-2); color: var(--szary); font-size: 13px; white-space: nowrap; max-width: 55%; overflow: hidden; text-overflow: ellipsis; }
.z-prefiksem input { border: 0 !important; flex: 1; min-width: 0; box-shadow: none !important; }

/* ================= Rezerwacje ================= */
.typ-jazdy { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 14px; }
@media (max-width: 480px) { .typ-jazdy { grid-template-columns: 1fr; } }
.typ-kafel input { position: absolute; opacity: 0; }
.typ-kafel span { display: flex; flex-direction: column; gap: 4px; border: 2px solid var(--linia); border-radius: 14px; padding: 12px 14px; cursor: pointer; height: 100%; color: var(--szary); }
.typ-kafel b { color: var(--tekst); font-size: 16px; }
.typ-kafel small { font-size: 13px; line-height: 1.3; }
.typ-kafel input:checked + span { border-color: var(--niebieski); background: var(--niebieski-tlo); color: var(--niebieski-ciemny); }
.typ-kafel input:focus-visible + span { outline: 2px solid var(--niebieski); }
.godziny { display: grid; grid-template-columns: repeat(auto-fill, minmax(70px, 1fr)); gap: 6px; }
.godz { border: 1px solid var(--linia); background: #fff; border-radius: 10px; padding: 9px 4px; font-weight: 700; cursor: pointer; color: var(--tekst); }
.godz.akt { background: var(--niebieski); border-color: var(--niebieski); color: #fff; }
.godz[disabled] { opacity: .35; cursor: not-allowed; }
.wybor-kon input { position: absolute; opacity: 0; }
.wybor-kon.wyb { border-color: var(--niebieski); box-shadow: 0 0 0 2px rgba(46, 125, 91, .25); background: var(--niebieski-tlo); }
label.wybor-kon { cursor: pointer; }
.rez-podsum { display: flex; justify-content: space-between; align-items: center; gap: 10px; background: var(--linia-2); border-radius: 12px; padding: 12px 14px; margin: 6px 0 12px; font-weight: 600; }
.rez-podsum b { font-size: 18px; color: var(--granat); }
.rez-baner { display: flex; align-items: center; gap: 12px; text-decoration: none; color: inherit; border: 2px solid var(--niebieski); }
.rez-baner > span:nth-child(2) { flex: 1; display: flex; flex-direction: column; }
.rez-baner small { color: var(--szary); }

/* ---------- Dokumenty i podpis ---------- */
.dok-tresc { max-height: 260px; overflow-y: auto; border: 1px solid var(--linia); border-radius: 12px; padding: 12px; margin-bottom: 12px; background: var(--linia-2); font-size: 14px; }
.podpis-ramka { position: relative; border: 2px dashed var(--linia); border-radius: 12px; background: #fff; }
canvas.podpis { display: block; width: 100%; height: 160px; cursor: crosshair; touch-action: none; }
.podpis-tlo { position: absolute; left: 0; right: 0; top: 50%; transform: translateY(-50%); text-align: center; color: var(--szary); pointer-events: none; font-size: 14px; }
.podpis-czysc { position: absolute; right: 10px; top: 6px; }
.podpis-pokaz { border-top: 1px solid var(--linia); padding: 10px 0; }
.podpis-pokaz img { display: block; max-width: 100%; height: 90px; object-fit: contain; object-position: left; margin-top: 6px; background: #fff; border: 1px solid var(--linia); border-radius: 8px; }
.baner-dok { display: flex; gap: 8px; align-items: center; text-decoration: none; margin-bottom: 14px; }
.dok-st { display: inline-block; margin: 0 4px 4px 0; }
.wzor { display: block; margin: -6px 0 14px; }
.rzad-akcje { display: flex; gap: 10px; align-items: center; justify-content: space-between; flex-wrap: wrap; margin-bottom: 8px; }
.notatki .tyt { white-space: normal; }
.pod-nag { font-size: 14px; text-transform: uppercase; letter-spacing: .04em; color: var(--szary); margin: 14px 0 6px; }

/* ---------- Obozy i wydarzenia ---------- */
.wyd-lista { display: grid; gap: 12px; }
@media (min-width: 760px) { .wyd-lista { grid-template-columns: repeat(2, 1fr); } }
.karta .wyd-lista .wyd-karta { margin: 0; }
.wyd-karta { display: block; text-decoration: none; color: inherit; border-left: 5px solid var(--zielony, #2f7d5b); }
.wyd-karta h3 { margin: 2px 0 6px; font-size: 18px; }
.wyd-karta .meta { display: flex; flex-wrap: wrap; gap: 4px 12px; color: var(--szary); font-size: 14px; }
.wyd-karta .meta span { display: inline-flex; gap: 4px; align-items: center; }
.wyd-rodzaj { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--szary); }
.wyd-dol { margin-top: 8px; }
.wyd-oboz { border-left-color: #b0662f; }
.wyd-polkolonie { border-left-color: #3f6fb5; }
.wyd-wydarzenie { border-left-color: #8e5bd6; }
.wyd-karta.odwolane { opacity: .6; }

/* ---------- Odświeżanie ---------- */
.gora .odswiez-g { flex: none; margin-left: 4px; }
.kreci svg, .ptr.kreci svg { animation: kreci 0.8s linear infinite; }
@keyframes kreci { to { transform: rotate(360deg); } }
.ptr { position: fixed; top: 10px; left: 50%; transform: translate(-50%, 0); z-index: 200; width: 42px; height: 42px; border-radius: 50%; background: #fff; box-shadow: 0 3px 12px rgba(0,0,0,.18); display: grid; place-items: center; color: var(--szary); opacity: 0; pointer-events: none; transition: opacity .15s; }
.ptr.gotowe { color: var(--zielony); }

/* ---------- Czat ---------- */
.czat-ik { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; flex: none; background: var(--linia-2); color: var(--szary); }
.czat-ik.k-wszyscy { background: #e7efe9; color: #2e5e4e; } .czat-ik.k-zespol { background: #f6ebdf; color: #a0662f; } .czat-ik.k-group { background: #e8eefb; color: #3f6fb5; }
.czat-lista .prawo { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.czat-lista .pod { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.znaczek.czat-nowe { position: static; display: inline-grid; }
.wycisz { color: var(--szary); vertical-align: -2px; }
.wycisz svg { opacity: .55; }
.czat-okno { padding-bottom: 86px; }
.czat-wiecej { display: block; margin: 0 auto 12px; }
#dymki { display: flex; flex-direction: column; gap: 6px; }
.dymek { max-width: 82%; align-self: flex-start; background: #fff; border-radius: 16px 16px 16px 4px; padding: 8px 12px; box-shadow: 0 1px 2px rgba(0,0,0,.06); word-wrap: break-word; overflow-wrap: anywhere; }
.dymek.moj { align-self: flex-end; background: #dcefe4; border-radius: 16px 16px 4px 16px; }
.dymek.usun { opacity: .6; }
.dymek .autor { font-size: 12px; font-weight: 700; margin-bottom: 2px; }
.dymek .kiedy { font-size: 11px; color: var(--szary); margin-top: 3px; text-align: right; }
.dymek .usun-w { font-size: 11px; margin-left: 6px; }
.czat-pisz { position: fixed; left: 0; right: 0; bottom: calc(64px + env(safe-area-inset-bottom)); display: flex; gap: 8px; align-items: flex-end; padding: 10px 12px; background: rgba(255,255,255,.96); border-top: 1px solid var(--linia); z-index: 15; }
.czat-pisz textarea { flex: 1; resize: none; border: 1px solid var(--linia); border-radius: 18px; padding: 10px 14px; font: inherit; font-size: 16px; max-height: 140px; }
.czat-pisz .btn { border-radius: 50%; width: 46px; height: 46px; padding: 0; flex: none; display: grid; place-items: center; }
@media (min-width: 960px) { .czat-pisz { left: 250px; bottom: 0; } .czat-okno { padding-bottom: 80px; } }
#akcje-gora .wyciszony { color: var(--szary); opacity: .5; }
.nr-lista { max-height: 50vh; overflow-y: auto; }

.wzm { font-weight: 700; text-decoration: none; border-radius: 6px; padding: 0 3px; }
.wzm-kon { color: #a0662f; background: #f6ebdf; } .wzm-os { color: #2e5e4e; background: #e3efe8; }
.czat-pisz { position: fixed; }
.podpowiedzi { position: absolute; left: 12px; right: 70px; bottom: calc(100% + 4px); background: #fff; border: 1px solid var(--linia); border-radius: 14px; box-shadow: 0 6px 20px rgba(0,0,0,.12); overflow: hidden; max-width: 420px; }
.podpowiedzi .podp-nag { font-size: 12px; color: var(--szary); padding: 8px 12px 4px; }
.podpowiedzi button { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; border: 0; background: none; padding: 10px 12px; font: inherit; cursor: pointer; }
.podpowiedzi button:hover, .podpowiedzi button:focus { background: var(--linia-2); }
.podpowiedzi small { color: var(--szary); }

/* dolne menu z 6 pozycjami (czat) */
.nav-dol.n6 { grid-template-columns: repeat(6, 1fr); }
.nav-dol.n6 a { font-size: 11px; padding: 8px 1px 9px; text-align: center; line-height: 1.15; }
.nav-dol.n6 a svg { width: 23px; height: 23px; }
.wzm-wsz { color: #fff; background: var(--zielony); }

/* ---------- Zdjęcia profilowe, profil, osiągnięcia ---------- */
img.av, img.av-duzy { object-fit: cover; padding: 0; background: var(--linia-2); }
.profil-av-btn { position: relative; border: 0; background: none; padding: 0; cursor: pointer; flex: none; }
.profil-av-btn > span { position: absolute; right: -4px; bottom: -4px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 4px rgba(0,0,0,.2); display: grid; place-items: center; color: var(--szary); }
.profil-gora { text-align: center; }
.profil-gora h2 { margin: 10px 0 2px; font-size: 22px; }
.profil-zdj { position: relative; display: inline-block; }
.profil-zdj .av-duzy { width: 104px; height: 104px; font-size: 36px; border-radius: 50%; }
.profil-zmien { position: absolute; right: 0; bottom: 0; width: 34px; height: 34px; border-radius: 50%; border: 0; background: #fff; box-shadow: 0 2px 6px rgba(0,0,0,.2); display: grid; place-items: center; cursor: pointer; color: var(--tekst); }
.profil-staz { margin-top: 8px; font-size: 14px; display: inline-flex; gap: 6px; align-items: center; flex-wrap: wrap; justify-content: center; }
.profil-odznaki { margin-top: 8px; font-size: 22px; letter-spacing: 4px; }
.osiag-siatka { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.osiag { border: 1px solid var(--linia); border-radius: 14px; padding: 12px; display: flex; flex-direction: column; gap: 4px; align-items: center; text-align: center; opacity: .55; filter: grayscale(1); }
.osiag.zdobyte { opacity: 1; filter: none; background: #fbf6ee; border-color: #ecd9bf; }
.osiag-ik { font-size: 32px; line-height: 1.1; }
.osiag b { font-size: 14px; }
.osiag-data { font-size: 12px; color: #146b47; font-weight: 700; }
.osiag .postep-pasek { width: 100%; height: 6px; }
.osiag .postep-pasek i { display: block; height: 100%; background: var(--zielony); border-radius: 6px; }
/* czat: awatar obok wiadomości */
.dymek-w { display: flex; align-items: flex-end; gap: 8px; max-width: 88%; }
.dymek-w.moj { align-self: flex-end; }
.dymek-w .dymek { max-width: 100%; }
.dymek-av { flex: none; text-decoration: none; }
.dymek-av .av { width: 34px; height: 34px; font-size: 13px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-weight: 700; }
.dymek .autor { text-decoration: none; display: block; }
/* czat: nagłówek zawsze na górze */
.tryb-czat .gora { position: fixed; top: 0; left: 0; right: 0; z-index: 40; will-change: transform; }
.tryb-czat .tresc { padding-top: 76px; }
.tryb-czat.klawiatura .nav-dol { display: none; }
@media (min-width: 960px) { .tryb-czat .gora { left: 250px; } }

/* ---------- Rankingi ---------- */
.rank-w { gap: 12px; }
.rank-m { width: 30px; text-align: center; font-size: 22px; flex: none; }
.rank-m .miejsce { font-size: 15px; font-weight: 800; color: var(--szary); }
.rank-w .av { width: 38px; height: 38px; font-size: 14px; }
.rank-kon { width: 38px; height: 38px; border-radius: 10px; object-fit: cover; flex: none; display: grid; place-items: center; background: var(--linia-2); color: var(--szary); }
.rank-kon svg { width: 22px; height: 22px; }
.rank-w.podium .tyt { font-weight: 800; }
.rank-w.ja { background: #fbf6ee; border-radius: 12px; }
.rank-ja { margin: 10px 0 0; padding: 8px 12px; background: #fbf6ee; border-radius: 10px; }

a.osiag { text-decoration: none; color: inherit; }
.osiag.podium-1 { background: #fdf6e3; border-color: #ecd28f; }
.osiag.podium-2 { background: #f3f5f7; border-color: #d3d9de; }
.osiag.podium-3 { background: #fbf0e6; border-color: #e6c3a3; }

.godziny-ust { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 10px; align-items: end; margin-bottom: 10px; }
.godziny-ust > b { align-self: center; font-size: 15px; }
.godziny-ust .pole { margin: 0; }
@media (max-width: 560px) { .godziny-ust { grid-template-columns: 1fr 1fr; } .godziny-ust > b { grid-column: 1 / -1; } .godziny-ust > span:empty { display: none; } }


/* ---------- Panel platformy (wersja 2) ---------- */
.pl-tresc { max-width: 1240px; }
.pl-powitanie { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: 4px 0 14px; }
.pl-powitanie h1 { font-size: 26px; color: var(--granat); }
.pl-powitanie p { margin: 2px 0 0; color: var(--szary); }
.pl-logo { flex: none; border-radius: 16px; box-shadow: 0 2px 8px rgba(31, 44, 53, .15); }
.pl-fin-nag { flex-wrap: wrap; gap: 8px; }
.pl-mies { display: flex; align-items: center; gap: 8px; }
.pl-mies b { min-width: 130px; text-align: center; text-transform: capitalize; }
.pl-kpi { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin: 6px 0 12px; }
@media (min-width: 760px) { .pl-kpi { grid-template-columns: repeat(4, 1fr); } }
.pl-kpi > div { border: 1px solid var(--linia); border-radius: 12px; padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; background: #fcfbf8; }
.pl-kpi span { font-size: 13px; font-weight: 600; color: var(--szary); }
.pl-kpi b { font-size: 22px; font-weight: 800; color: var(--granat); font-variant-numeric: tabular-nums; }
.pl-kpi small { font-size: 12px; color: var(--szary); }
.pl-kpi .ok { border-color: #bfe5d1; background: var(--zielony-tlo); }
.pl-kpi .ok b { color: var(--zielony); }
.pl-kpi .czeka { border-color: #f0dca8; background: var(--zolty-tlo); }
.pl-kpi .czeka b { color: #9a6a04; }
.pl-pasek { height: 10px; border-radius: 6px; background: var(--linia-2); overflow: hidden; margin-bottom: 14px; }
.pl-pasek i { display: block; height: 100%; background: var(--zielony); border-radius: 6px; transition: width .4s; }
.pl-leg { display: flex; flex-wrap: wrap; gap: 14px; font-size: 13px; color: var(--tekst); margin-bottom: 8px; }
.pl-leg i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.pl-leg .szary { margin-left: auto; }
.kp { background: var(--zielony); }
.kn { background: #d9e6df; }
.pl-wykres { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; height: 130px; align-items: end; margin-bottom: 6px; }
.pl-sl { display: flex; flex-direction: column; align-items: center; gap: 4px; height: 100%; cursor: pointer; }
.pl-sl span { font-size: 12px; color: var(--szary); font-weight: 600; text-transform: capitalize; }
.pl-sl.akt span { color: var(--granat); font-weight: 800; }
.pl-sl-k { position: relative; flex: 1; width: 100%; max-width: 46px; }
.pl-sl-k i { position: absolute; left: 0; right: 0; bottom: 0; border-radius: 4px 4px 0 0; min-height: 2px; }
.pl-sl-k i.kp { left: 8px; right: 8px; }
.pl-sl:hover .pl-sl-k i.kn { background: #c6d9cf; }
.pl-rozl .wiersz { gap: 10px; align-items: center; }
.pl-fin .pod-naglowek { margin-top: 14px; }
.pl-rozl .pl-logo { border-radius: 10px; box-shadow: none; }
.pl-wpl { display: inline-flex; align-items: center; gap: 2px; background: var(--linia-2); border-radius: 10px; padding: 0 4px 0 8px; font-size: 12px; margin-left: 4px; }
.pl-wpl .lnk { border: 0; background: none; padding: 2px; cursor: pointer; color: var(--szary); display: inline-flex; }
.pl-narz { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; margin-bottom: 12px; }
.pl-narz .filtry { margin: 0; flex: 1 1 auto; }
.filtry button small { opacity: .7; font-weight: 600; }
.pl-szukaj { flex: 1 1 240px; border: 1px solid var(--linia); border-radius: 12px; padding: 9px 12px; background: #fff; min-width: 0; }
.pl-siatka { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 820px) { .pl-siatka { grid-template-columns: repeat(2, 1fr); } }
.pl-karta { border: 1px solid var(--linia); border-radius: 16px; padding: 16px; background: #fff; display: flex; flex-direction: column; gap: 12px; box-shadow: 0 1px 2px rgba(31, 44, 53, .04); transition: box-shadow .2s; }
.pl-karta:hover { box-shadow: var(--cien); }
.pl-st.pl-karta { border-top: 1px solid var(--linia); padding: 16px; }
.pl-k-gora { display: flex; gap: 12px; align-items: center; }
.pl-k-nazwa { flex: 1; min-width: 0; }
.pl-k-nazwa h3 { font-size: 18px; color: var(--granat); overflow-wrap: anywhere; }
.pl-k-pakiet { font-size: 14px; color: var(--tekst); margin-top: 2px; }
.pl-k-st { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.pl-k-daty { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px 14px; margin: 0; padding: 10px 12px; background: #faf8f3; border-radius: 12px; }
.pl-k-daty dt { font-size: 12px; color: var(--szary); font-weight: 600; }
.pl-k-daty dd { margin: 0; font-weight: 700; font-size: 14px; }
.pl-k-daty dd .szary, .pl-k-daty dd .czer-txt, .pl-k-daty dd .czeka-txt { font-weight: 600; font-size: 12px; }
.czer-txt { color: var(--czerwony); }
.pl-k-blok { display: grid; grid-template-columns: 110px 1fr; gap: 10px; font-size: 14px; }
.pl-k-tyt { color: var(--szary); font-weight: 700; font-size: 13px; display: flex; align-items: center; gap: 6px; }
.pl-k-wl { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.pl-k-wl a, .pl-k-wl span { display: inline-flex; align-items: center; gap: 6px; overflow-wrap: anywhere; }
.pl-k-wl a { text-decoration: none; }
.pl-k-wl svg { flex: none; color: var(--szary-2); }
.pl-k-liczby { display: flex; flex-wrap: wrap; gap: 6px; }
.pl-k-liczby span { background: var(--niebieski-tlo); color: var(--niebieski-ciemny); border-radius: 20px; padding: 3px 10px; font-size: 13px; }
.pl-k-notatka { margin: 0; font-size: 13px; color: var(--szary); background: var(--zolty-tlo); border-radius: 10px; padding: 8px 10px; white-space: pre-line; }
.pl-k-akcje { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; padding-top: 4px; border-top: 1px solid var(--linia-2); padding-top: 12px; }
.pl-ok-gora { display: flex; align-items: center; gap: 12px; margin-bottom: 6px; }
.pl-zap { padding: 8px 0; border-top: 1px solid var(--linia-2); }
.pl-zap:first-child { border-top: 0; }
.pl-zap.wyl { opacity: .6; }
@media (max-width: 480px) { .pl-k-blok { grid-template-columns: 1fr; gap: 4px; } .pl-k-gora { flex-wrap: wrap; } .pl-k-st { flex-direction: row; width: 100%; align-items: center; } }
.pl-rozl .wiersz { flex-wrap: wrap; }
.pl-rozl .glowne { flex: 1 1 200px; }

/* ---------- Brakujące podpisy, podgląd i wydruk podpisanego dokumentu ---------- */
.dok-braki { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 3px; }
.wiecej-bp summary { cursor: pointer; padding: 8px 0 2px; }
.podpisy-lista .wiersz { gap: 10px; align-items: center; text-decoration: none; color: inherit; }
.dok-druk { padding: 28px 26px; max-width: 820px; margin: 0 auto; }
.dd-gora { display: flex; justify-content: space-between; gap: 16px; border-bottom: 2px solid var(--granat); padding-bottom: 12px; margin-bottom: 18px; font-size: 13px; }
.dd-gora div { display: flex; flex-direction: column; }
.dd-gora b { font-size: 16px; color: var(--granat); }
.dd-nr { text-align: right; color: var(--szary); font-size: 12px; }
.dd-tyt { font-size: 22px; text-align: center; margin: 0 0 16px; color: var(--granat); }
.dd-tresc { font-size: 14px; line-height: 1.6; white-space: normal; overflow-wrap: anywhere; }
.dd-podpis { display: grid; grid-template-columns: 1fr; gap: 16px; margin-top: 26px; padding-top: 16px; border-top: 1px solid var(--linia); break-inside: avoid; }
@media (min-width: 640px) { .dd-podpis { grid-template-columns: 1.3fr 1fr; } }
.dd-dane { display: flex; flex-direction: column; gap: 10px; font-size: 14px; }
.dd-dane div { display: flex; flex-direction: column; }
.dd-dane span { font-size: 12px; color: var(--szary); font-weight: 600; }
.dd-dane small { color: var(--szary); }
.dd-obraz { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; }
.dd-obraz img { max-width: 260px; width: 100%; border-bottom: 1px solid var(--tekst); }
.dd-obraz span { font-size: 12px; color: var(--szary); margin-top: 4px; }
.dd-stopka { margin-top: 20px; font-size: 11px; color: var(--szary); border-top: 1px solid var(--linia-2); padding-top: 8px; }
@media print {
  @page { margin: 16mm 14mm; }
  body { background: #fff !important; }
  .gora, .nav-dol, .menu-boczne, .nie-drukuj, .toast, .stopka-pw, footer.stopka { display: none !important; }
  .uklad { padding: 0 !important; }
  .tresc { padding: 0 !important; max-width: none !important; }
  .dok-druk { box-shadow: none !important; border: 0 !important; padding: 0 !important; max-width: none; }
  .dd-tresc { font-size: 11.5pt; }
}

/* ---------- Jeźdźcy w kafelkach ---------- */
.j-narz { display: flex; gap: 8px; align-items: flex-start; }
.j-narz .szukaj-pole { flex: 1; min-width: 0; }
.przel-widok { display: flex; border: 1px solid var(--linia); border-radius: 12px; overflow: hidden; background: #fff; flex: none; }
.przel-widok button { border: 0; background: none; padding: 9px 11px; cursor: pointer; color: var(--szary); display: grid; place-items: center; }
.przel-widok button.akt { background: var(--granat); color: #fff; }
.j-kafle { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 14px; }
@media (min-width: 560px) { .j-kafle { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 900px) { .j-kafle { grid-template-columns: repeat(4, 1fr); } }
@media (min-width: 1200px) { .j-kafle { grid-template-columns: repeat(5, 1fr); } }
.j-kafel { background: var(--karta); border-radius: var(--promien); box-shadow: var(--cien); padding: 16px 10px 14px; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; text-decoration: none; color: inherit; transition: transform .15s; min-width: 0; }
.j-kafel:active { transform: scale(.98); }
.j-kafel b { font-size: 15px; line-height: 1.25; overflow-wrap: anywhere; color: var(--granat); }
.j-kafel .j-zn { display: flex; flex-wrap: wrap; gap: 4px; justify-content: center; }
.j-kafel.wyl { opacity: .55; }
