/* otwartesklepy.pl : concept « Rozkład ». Les dimanches présentés comme le rozkład jazdy d'un przystanek :
   tabliczka bleu nuit à gauche (dziś, jutro, najbliższa, reliés par une ligne de trajet), tableau blanc à en-tête cobalt
   à droite (un mois par ligne en chiffres romains, colonnes selon le statut du dimanche, lettres de renvoi = base légale).
   Police unique : Lato (Łukasz Dziedzic, tyPoland, OFL 1.1), 400 et 900, hébergée ici (polices/OFL.txt).
   Contrastes (WCAG, calculés) : texte courant #0f1a2b sur blanc 17,5:1, sur #eef2f8 15,5:1 ; texte secondaire #3f4a5c
   sur blanc 9,0:1, sur #eef2f8 8,0:1, sur #dfe7fd 7,2:1 ; jours passés #535e70 : 6,6 / 5,8 / 5,3:1 ; liens #1740c9 sur
   blanc 8,0:1, sur #eef2f8 7,2:1 ; blanc sur cobalt #1740c9 8,0:1, sur #1236a8 9,9:1 ; sur bleu nuit : blanc 17,5:1,
   #c9d2e0 11,5:1, #a9c0ff 9,7:1 ; focus #e86a00 : 3,2:1 sur blanc, 5,4:1 sur bleu nuit (anneau blanc sur cobalt). */
/* les quatre @font-face de Lato sont dans gabarits/base.html (adresses avec empreinte, identiques aux préchargements) */
/* police de repli aux mesures de Lato (largeur moyenne mesurée sur un texte polonais) : le passage à Lato ne décale rien */
@font-face { font-family: 'Lato zapas'; font-weight: 100 500; src: local('Arial'), local('ArialMT'); size-adjust: 96.8%; ascent-override: 102%; descent-override: 22%; line-gap-override: 0%; }
@font-face { font-family: 'Lato zapas'; font-weight: 600 1000; src: local('Arial Bold'), local('Arial-BoldMT'); size-adjust: 95.2%; ascent-override: 103.7%; descent-override: 22.4%; line-gap-override: 0%; }

:root {
  --bialy: #ffffff;
  --granat: #0f1a2b;
  --granat2: #c9d2e0;
  --jasny: #a9c0ff;
  --szary: #3f4a5c;
  --minal: #535e70;
  --pas: #eef2f8;
  --teraz: #dfe7fd;
  --kobalt: #1740c9;
  --kobalt-c: #1236a8;
  --kobalt-minal: #d3dcf7;
  --fokus: #e86a00;
  --lato: 'Lato', 'Lato zapas', Arial, sans-serif;
  --lewa: max(20px, calc(50vw - 620px));
}
* { box-sizing: border-box; }
html { background: var(--bialy); color: var(--granat); font: 400 19px/1.55 var(--lato); font-variant-numeric: tabular-nums lining-nums; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { margin: 0; }
a { color: var(--kobalt); text-underline-offset: .16em; }
b, strong { font-weight: 900; }
:focus-visible { outline: 3px solid var(--fokus); outline-offset: 3px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.pomin { position: absolute; left: -999px; top: 8px; background: var(--granat); color: var(--bialy); padding: 10px 16px; z-index: 9; }
.pomin:focus { left: 8px; }

/* ---- en-tête ---- */
.gora { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 30px; padding: 14px var(--lewa) 12px; }
.marka { font-weight: 900; font-size: 25px; letter-spacing: -.01em; color: var(--granat); text-decoration: none; display: inline-block; padding: 10px 0; }
.marka span { font-weight: 400; color: var(--szary); }
.gora nav { display: flex; flex-wrap: wrap; gap: 0 22px; font-size: 17px; }
.gora nav a { color: var(--granat); text-decoration: none; padding: 10px 0; display: inline-block; }
.gora nav a:hover { text-decoration: underline; }
.gora nav a[aria-current] { font-weight: 900; color: var(--kobalt); }
.niezalezny { flex-basis: 100%; margin: 0; font-size: 16px; color: var(--szary); }

/* ---- accueil : tabliczka + rozkład côte à côte ---- */
.arkusz { display: grid; grid-template-columns: calc(var(--lewa) + 400px) minmax(0, 1fr); align-items: start; }
.tablica { background: var(--granat); color: var(--bialy); padding: 28px 36px 36px var(--lewa); align-self: stretch; }
.tablica h1 { font-weight: 900; font-size: 32px; line-height: 1.12; letter-spacing: 0; margin: 0 0 28px; }
.trasa { position: relative; }
/* les trois arrêts : places réservées (le texte arrive par le script, rien ne bouge) */
.przystanek { position: relative; display: flow-root; padding: 0 0 0 36px; }
.przystanek p { margin: 0; }
.przystanek::before { content: ""; position: absolute; left: 0; top: 6px; width: 20px; height: 20px; border-radius: 50%; background: var(--granat); box-shadow: inset 0 0 0 5px var(--jasny); z-index: 1; }
.przystanek::after { content: ""; position: absolute; left: 8px; top: 16px; bottom: -6px; width: 4px; background: var(--jasny); }
.przystanek.nast::after { display: none; }
/* hauteurs = texte le plus long sur toutes les dates 2025-12-20 → 2029-01-10, mesuré à la largeur la plus étroite de
   chaque tranche (scratchpad test_rozklad.py), plus l'écart entre deux arrêts et une petite marge */
.przystanek.dzis { min-height: 292px; }
.przystanek.jutro { min-height: 179px; }
.przystanek.nast { min-height: 154px; }
.wazny { min-height: 50px; }
.kiedy { font-size: 18px; line-height: 1.5; color: var(--granat2); }
.werdykt { font-weight: 900; line-height: 1; letter-spacing: -.02em; margin: 6px 0 10px !important; }
.dzis .werdykt { font-size: 64px; }
.jutro .werdykt, .nast .werdykt { font-size: 44px; }
[data-sklepy="otwarte"] .werdykt, [data-sklepy="do14"] .werdykt { color: var(--jasny); }
[data-sklepy="brak"] .werdykt { color: var(--granat2); }
.nast .za { font-weight: 400; font-size: 22px; letter-spacing: 0; color: var(--bialy); }
.nast .za b { font-weight: 900; }
.zdanie { font-size: 19px; line-height: 1.5; }
.bez-js .trasa { display: none; }
.bez-skryptu { margin: 0; font-size: 19px; color: var(--granat2); }

/* ---- le rozkład d'une année ---- */
.rozklad { padding: 28px var(--lewa) 36px; min-width: 0; }
.arkusz .rozklad { padding-left: 44px; }
.glowa { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px 24px; background: var(--kobalt); color: var(--bialy); padding: 16px 20px 14px; border-radius: 4px 4px 0 0; }
.glowa h2 { font-weight: 900; font-size: 28px; line-height: 1.15; letter-spacing: -.01em; margin: 0; }
.glowa h2 .rok-h { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.wazny { margin: 4px 0 0; font-size: 17px; line-height: 1.45; }
.poza .wazny { font-weight: 900; }
.rok-duzy { margin: -4px 0 0; font-weight: 900; font-size: 72px; line-height: .95; letter-spacing: -.02em; }
.lata { display: flex; gap: 6px; margin-top: 12px; }
.lata button { font: 900 18px/1 var(--lato); min-height: 44px; min-width: 76px; padding: 0 12px; border: 0; border-radius: 3px; background: var(--kobalt-c); color: var(--bialy); cursor: pointer; }
.lata button:hover { text-decoration: underline; }
.lata button[aria-pressed="true"] { background: var(--bialy); color: var(--kobalt); }
.glowa :focus-visible { outline: 3px solid var(--bialy); outline-offset: 0; box-shadow: 0 0 0 6px var(--fokus); }

.tabela { width: 100%; border-collapse: collapse; table-layout: fixed; }
.c-mies { width: 8.8em; } .c-handl { width: 23%; } .c-zakaz { width: 31%; }
.tabela thead th { background: var(--kobalt-c); color: var(--bialy); text-align: left; font-size: 16px; font-weight: 900; line-height: 1.3; padding: 9px 12px; }
.tabela tbody tr:nth-child(even) { background: var(--pas); }
.tabela tbody tr.teraz { background: var(--teraz); }
.tabela tbody th, .tabela td { text-align: left; vertical-align: top; padding: 7px 12px 5px; }
.tabela tbody th { font-weight: 400; white-space: nowrap; position: relative; }
.rz { font-weight: 900; font-size: 24px; line-height: 1.25; display: inline-block; min-width: 2.1em; }
.mn { font-size: 16px; color: var(--szary); }
.teraz .rz { color: var(--kobalt); }
.teraz th::before { content: ""; position: absolute; left: -17px; top: 13px; border: 8px solid transparent; border-left: 11px solid var(--kobalt); }
.tu { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.tabela td { font-size: 21px; line-height: 1.4; }
.d { display: inline-block; margin: 0 4px 4px 0; white-space: nowrap; }
.d .w { display: inline-block; padding: 0 5px; border-radius: 3px; }
.d sup { font-size: .6em; margin-left: 1px; line-height: 0; }
.d-handlowa .w { font-weight: 900; color: var(--bialy); background: var(--kobalt); }
.d-handlowa.minela .w { background: var(--kobalt-minal); color: var(--granat); }
.d-swieto .w { font-weight: 900; }
.minela .w { color: var(--minal); }
.d.dzis .w { background: var(--granat); color: var(--bialy); }
.d.najblizsza .w { box-shadow: 0 0 0 2px var(--bialy), 0 0 0 5px var(--granat); }
.brak { color: var(--minal); padding-left: 6px; }

.objasnienia { margin-top: 18px; }
.objasnienia h3 { font-size: 18px; font-weight: 900; margin: 0 0 6px; }
.objasnienia ul { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 28px; font-size: 17px; line-height: 1.45; }
.objasnienia li { position: relative; padding-left: 2.3em; }
.objasnienia li.cale { grid-column: 1 / -1; margin-top: 4px; padding-left: 0; }
.lit { position: absolute; left: 0; font-weight: 900; color: var(--kobalt); }
.wzor { position: absolute; left: 5px; top: .25em; width: 1.4em; height: 1em; border-radius: 3px; }
.wzor-najbl { background: var(--kobalt); box-shadow: 0 0 0 2px var(--bialy), 0 0 0 5px var(--granat); }
.wzor-dzis { background: var(--granat); }
.rok-akcje { display: flex; flex-wrap: wrap; gap: 4px 26px; margin: 14px 0 0; font-size: 18px; }
.rok-akcje a { padding: 10px 0; display: inline-block; }
.ics.czeka { visibility: hidden; }

.dowod { margin: 26px 0 0; max-width: 930px; }
.dowod img { display: block; width: 100%; height: auto; background: var(--pas); }
.dowod figcaption { font-size: 17px; line-height: 1.5; color: var(--szary); margin-top: 10px; }

/* emplacement publicitaire (seulement si la publicité est activée) */
.reklama { margin: 8px var(--lewa) 24px; min-height: 280px; display: grid; place-items: center; background: var(--pas); color: var(--szary); }
.reklama-et { font-size: 16px; }

/* ---- pages intérieures ---- */
.karta { background: var(--granat); color: var(--bialy); padding: 36px var(--lewa) 40px; }
.karta-tekst { position: relative; padding-left: 36px; max-width: 52em; }
.karta-tekst::before { content: ""; position: absolute; left: 0; top: 12px; width: 20px; height: 20px; border-radius: 50%; background: var(--granat); box-shadow: inset 0 0 0 5px var(--jasny); z-index: 1; }
.karta-tekst::after { content: ""; position: absolute; left: 8px; top: 22px; bottom: 6px; width: 4px; background: var(--jasny); }
.karta h1 { font-weight: 900; font-size: clamp(32px, 4.2vw, 50px); line-height: 1.1; letter-spacing: 0; margin: 0 0 14px; }
.lead { margin: 0; font-size: 20px; line-height: 1.5; color: var(--granat2); max-width: 44em; }

.artykul { padding: 34px var(--lewa) 48px; }
.artykul > * { max-width: 44em; }
.artykul h2 { font-weight: 900; font-size: 27px; line-height: 1.2; letter-spacing: 0; margin: 38px 0 10px; }
.artykul h2:first-child { margin-top: 0; }
.artykul h3 { font-weight: 900; font-size: 21px; margin: 28px 0 8px; }
.artykul p, .artykul ul, .artykul ol { margin: 0 0 16px; }
.artykul li { margin-bottom: 6px; }
.artykul table { border-collapse: collapse; width: 100%; margin: 6px 0 22px; font-size: 18px; line-height: 1.45; }
.artykul thead th { background: var(--kobalt-c); color: var(--bialy); text-align: left; font-weight: 900; padding: 9px 12px; vertical-align: bottom; }
.artykul thead th:first-child { border-radius: 4px 0 0 0; }
.artykul thead th:last-child { border-radius: 0 4px 0 0; }
.artykul tbody td { padding: 8px 12px; vertical-align: top; }
.artykul tbody tr:nth-child(even) { background: var(--pas); }
.artykul tbody td:first-child { font-weight: 900; }
.dalej { font-weight: 900; font-size: 20px; }

/* ---- pied de page ---- */
.stopka { background: var(--granat); color: var(--granat2); font-size: 17px; line-height: 1.5; padding: 34px var(--lewa) 44px; }
.stopka h2 { font-size: 20px; font-weight: 900; color: var(--bialy); margin: 0 0 10px; }
.stopka a { color: var(--bialy); }
.stopka p { margin: 0 0 10px; }
.stopka-kol { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 20px 48px; }
.zrodla { margin: 0 0 12px; padding-left: 1.1em; }
.zrodla li { margin-bottom: 6px; }
.wszystkie { margin-top: 22px; }
.wszystkie ul { list-style: none; margin: 0; padding: 0; columns: 3 16em; column-gap: 40px; }
.wszystkie li { break-inside: avoid; }
.wszystkie a { display: inline-block; padding: 6px 0; }
.prawne { margin-top: 18px !important; }
.prawne a { display: inline-block; padding: 6px 0; }

@media (max-width: 1080px) {
  .arkusz { grid-template-columns: minmax(0, 1fr); }
  .tablica { padding: 24px var(--lewa) 18px; }
  .arkusz .rozklad { padding-left: var(--lewa); }
}
@media (max-width: 860px) {
  .gora { gap: 2px 16px; padding-top: 10px; padding-bottom: 8px; }
  .menu summary { list-style: none; cursor: pointer; padding: 10px 0; font-weight: 900; font-size: 18px; }
  .menu summary::-webkit-details-marker { display: none; }
  .menu summary::after { content: " ▾"; }
  .menu[open] summary::after { content: " ▴"; }
  .menu nav { flex-direction: column; gap: 0; }
  .menu nav a { display: block; padding: 10px 0; }
  .tablica h1 { font-size: 27px; margin-bottom: 20px; }
  .dzis .werdykt { font-size: 50px; }
  .jutro .werdykt, .nast .werdykt { font-size: 38px; }
  .stopka-kol { grid-template-columns: minmax(0, 1fr); }
  .objasnienia ul { grid-template-columns: minmax(0, 1fr); }
  .rok-duzy { font-size: 56px; }
}
@media (max-width: 1080px) { .przystanek.dzis { min-height: 196px; } .przystanek.jutro { min-height: 148px; } .przystanek.nast { min-height: 126px; } }
@media (max-width: 860px) { .przystanek.dzis { min-height: 182px; } .przystanek.jutro { min-height: 142px; } .przystanek.nast { min-height: 148px; } }
@media (max-width: 519px) { .przystanek.dzis { min-height: 209px; } .przystanek.jutro { min-height: 168px; } .przystanek.nast { min-height: 148px; } }
@media (max-width: 389px) { .przystanek.dzis { min-height: 259px; } .przystanek.jutro { min-height: 168px; } .przystanek.nast { min-height: 177px; } }
@media (max-width: 359px) { .przystanek.dzis { min-height: 286px; } .przystanek.jutro { min-height: 195px; } .przystanek.nast { min-height: 177px; } }
@media (min-width: 861px) { .menu summary { display: none; } .menu { display: contents; } }
@media (max-width: 700px) {
  .glowa { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "h rok" "wazny wazny" "lata lata"; align-items: center; padding: 14px 16px 12px; gap: 0 12px; }
  .glowa-tekst { display: contents; }
  .glowa h2 { grid-area: h; }
  .wazny { grid-area: wazny; }
  .lata { grid-area: lata; }
  .rok-duzy { grid-area: rok; }
  .wazny { min-height: 75px; }
  .glowa h2 { font-size: 24px; }
  .rok-duzy { font-size: 40px; margin-top: 0; }
  .lata button { min-width: 0; flex: 1 1 0; }
  .tabela thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); }
  .tabela, .tabela tbody, .tabela tr { display: block; }
  .tabela colgroup { display: none; }
  .tabela tr { padding: 8px 12px 6px; }
  .tabela tbody th { display: block; padding: 0 0 2px; white-space: normal; }
  .rz { min-width: 0; margin-right: 10px; }
  .tabela td { display: block; padding: 1px 0; font-size: 20px; }
  .tabela td::before { content: attr(data-et) ": "; font-size: 16px; color: var(--szary); }
  .k-swieta:has(.brak) { display: none !important; }
  .mn { font-size: 17px; }
  .tu { position: static; width: auto; height: auto; overflow: visible; clip: auto; clip-path: none; margin-left: 10px; font-size: 17px; font-weight: 900; color: var(--kobalt); white-space: nowrap; }
  .teraz th::before { left: -27px; top: 9px; }
  .artykul table { display: block; overflow-x: auto; }
  .dowod img { height: 150px; object-fit: cover; object-position: left center; }
  .lead { font-size: 19px; }
  .karta { padding-top: 26px; padding-bottom: 30px; }
}
@media (max-width: 420px) {
  .d { margin-right: 4px; }
  .karta-tekst { padding-left: 30px; }
}
