/* Szablon devpage „Portal” – układ magazynowy w stylu Pixwell Today. Własny kod, bez zewnętrznych czcionek (RODO). */
:root {
  --accent: #d90036;      /* czerwony akcent; ciemniejszy niż #ff003c wzoru, żeby biały tekst na plakietkach miał min. 4,5:1 */
  --ink: #141414;         /* tło nagłówka i stopki */
  --ink-2: #1f1f1f;       /* ciemne pasmo sekcji */
  --text: #2b2b2b;
  --muted: #5f5f5f;       /* szary meta; #666 wzoru daje 5,7:1 na bieli – zostawiamy z zapasem */
  --line: #e6e6e6;
  --bg: #ffffff;
  --wrap: 1200px;
  --sec-pad: 32px;
  --gap: 24px;
  --head: Georgia, "Times New Roman", "DejaVu Serif", serif;
  --body: Georgia, "DejaVu Serif", serif;
  --ui: -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.7 var(--body); }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent); }
.px-wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 16px; }
.px-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Nagłówek */
.px-top { background: var(--ink); color: #fff; font: 600 12px/1 var(--ui); }
.px-top .px-wrap { display: flex; justify-content: flex-end; align-items: center; min-height: 34px; gap: 18px; }
.px-top ul { display: flex; gap: 18px; margin: 0; padding: 0; list-style: none; }
.px-top a { color: #cfcfcf; }
.px-head { background: var(--bg); }  /* jasny pas pod logo: logotypy domen devpage są projektowane na białe tło */
.px-head .px-wrap { display: flex; justify-content: center; align-items: center; padding: 18px 16px; }
.px-logo img { max-height: 64px; width: auto; }
.px-nav { background: #000; border-top: 1px solid #2a2a2a; position: sticky; top: 0; z-index: 50; }
.px-nav .px-wrap { display: flex; align-items: center; justify-content: center; min-height: 48px; }
.px-nav ul { display: flex; flex-wrap: wrap; justify-content: center; margin: 0; padding: 0; list-style: none; }
.px-nav li a { display: block; padding: 14px 14px; color: #fff; font: 700 13px/20px var(--ui); text-transform: uppercase; letter-spacing: .02em; }
.px-nav li a:hover { color: #fff; box-shadow: inset 0 -3px 0 var(--accent); }
.px-burger { display: none; }
.px-burger-btn { display: none; color: #fff; font: 700 14px/1 var(--ui); cursor: pointer; padding: 14px 0; min-height: 44px; }

/* Pasek „Na czasie” */
.px-trend { border-bottom: 1px solid var(--line); font: 600 13px/1.4 var(--ui); }
.px-trend .px-wrap { display: flex; gap: 16px; align-items: center; overflow-x: auto; padding-top: 10px; padding-bottom: 10px; white-space: nowrap; scrollbar-width: none; }
.px-trend .px-wrap::-webkit-scrollbar { display: none; }
.px-trend b { background: var(--accent); color: #fff; padding: 4px 10px; flex: none; }
.px-trend p { margin: 0; flex: none; }
.px-trend:not(:has(a)) { display: none; }

/* Hero strony głównej */
.px-hero { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 4px; background: #000; }
.px-hero__item { position: relative; display: block; min-height: 460px; overflow: hidden; color: #fff; }
.px-hero__item img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.px-hero__item:hover img { transform: scale(1.04); }
.px-hero__item::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,.85) 0%, rgba(0,0,0,.25) 55%, rgba(0,0,0,0) 100%); }
.px-hero__body { position: absolute; left: 0; right: 0; bottom: 0; z-index: 1; padding: 24px; }
.px-hero__item:hover { color: #fff; }
.px-hero h2 { margin: 10px 0 8px; font: 900 22px/1.25 var(--head); }
.px-hero__item:first-child h2 { font-size: 34px; }

/* Plakietka kategorii i meta */
.px-cat { display: inline-block; background: var(--accent); color: #fff; padding: 3px 8px; font: 700 11px/1.4 var(--ui); text-transform: uppercase; letter-spacing: .03em; }
.px-meta { display: block; color: var(--muted); font: 500 12px/1.5 var(--ui); }
.px-hero .px-meta, .px-tile .px-meta, .px-ahead .px-meta { color: #e2e2e2; }

/* Układ: treść + panel boczny */
.px-main { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 40px; padding-top: var(--sec-pad); padding-bottom: var(--sec-pad); }
.px-main > * { min-width: 0; }
.px-aside { display: flex; flex-direction: column; gap: var(--sec-pad); position: sticky; top: 64px; align-self: start; }  /* panel jedzie z długą treścią zamiast zostawiać pustą kolumnę */

/* Sekcje kategorii */
.px-sec { margin: 0 0 var(--sec-pad); }
.px-sec__title { display: flex; align-items: center; gap: 12px; margin: 0 0 calc(var(--sec-pad) / 2); font: 900 22px/1.2 var(--head); }
.px-sec__title::after { content: ""; flex: 1; height: 2px; background: var(--ink); }
.px-sec__grid { display: grid; gap: var(--gap); }
.px-sec__grid:has(> .px-card) { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.px-sec__grid:has(> .px-big) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.px-sec__grid:has(> .px-row) { grid-template-columns: 1fr; }
.px-sec:has(.px-dark) { background: var(--ink-2); color: #fff; padding: 24px; }
.px-sec:has(.px-dark) .px-sec__title::after { background: var(--accent); }
.px-sec:has(.px-dark) .px-sec__title a:hover { color: #fff; }

/* Karta (siatka) */
.px-card { display: flex; flex-direction: column; }
.px-card__img { position: relative; display: block; aspect-ratio: 3 / 2; overflow: hidden; background: #eee; }
.px-card__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.px-card:hover img, .px-big:hover img, .px-row:hover img { transform: scale(1.04); }
.px-card__img .px-cat { position: absolute; left: 10px; bottom: 10px; }
.px-card h3 { margin: 12px 0 6px; font: 900 17px/1.3 var(--head); }
.px-card .px-meta { margin-top: auto; }

/* Duża karta (2 w rzędzie) */
.px-big { display: flex; flex-direction: column; }
.px-big .px-card__img { aspect-ratio: 16 / 10; }
.px-big h3 { margin: 14px 0 8px; font: 900 22px/1.25 var(--head); }
.px-big p { margin: 0 0 10px; color: var(--muted); font-size: 15px; }

/* Wiersz: zdjęcie z lewej */
.px-row { display: grid; grid-template-columns: 40% minmax(0, 1fr); gap: 20px; align-items: start; padding-bottom: var(--gap); border-bottom: 1px solid var(--line); }
.px-row:last-child { border-bottom: 0; padding-bottom: 0; }
.px-row .px-card__img { aspect-ratio: 4 / 3; }
.px-row h3 { margin: 6px 0 8px; font: 900 21px/1.25 var(--head); }
.px-row p { margin: 0 0 10px; color: var(--muted); font-size: 15px; line-height: 1.6; }

/* Kafel na ciemnym paśmie */
.px-dark .px-tile { position: relative; display: block; aspect-ratio: 4 / 3; overflow: hidden; color: #fff; }
.px-dark .px-tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.px-dark .px-tile::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,.85), rgba(0,0,0,.1) 70%); }
.px-dark .px-tile__body { position: absolute; left: 0; right: 0; bottom: 0; z-index: 1; padding: 16px; }
.px-dark h3 { margin: 8px 0 4px; font: 900 18px/1.25 var(--head); }
.px-must { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }

/* Panel boczny */
.px-widget__title { display: flex; align-items: center; gap: 10px; margin: 0 0 16px; font: 900 19px/1.2 var(--head); }
.px-widget__title::after { content: ""; flex: 1; height: 2px; background: var(--ink); }
.px-widget ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 16px; counter-reset: px; }
.px-witem { display: grid; grid-template-columns: 90px minmax(0, 1fr); gap: 14px; align-items: center; }
.px-witem img { width: 90px; height: 70px; object-fit: cover; }
.px-witem b { display: block; font: 900 15px/1.3 var(--head); }
.px-wnum { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 10px; align-items: start; counter-increment: px; }
.px-wnum::before { content: counter(px); display: flex; align-items: center; justify-content: center; width: 34px; height: 34px; background: var(--ink); color: #fff; font: 900 15px/1 var(--head); }
.px-wnum b { font: 900 15px/1.35 var(--head); }
.px-wbig { display: block; position: relative; aspect-ratio: 4 / 3; overflow: hidden; color: #fff; }
.px-wbig img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.px-wbig::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,.8), transparent 65%); }
.px-wbig b { position: absolute; left: 14px; right: 14px; bottom: 12px; z-index: 1; font: 900 17px/1.3 var(--head); }
.px-wbig:hover { color: #fff; }
.px-banner:empty, .px-banner:not(:has(*)) { display: none; }

/* Artykuł */
.px-ahead { position: relative; min-height: 420px; margin-bottom: 28px; display: flex; align-items: flex-end; color: #fff; background: #000; }
.px-ahead > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .55; }
.px-ahead__body { position: relative; z-index: 1; max-width: 860px; margin: 0 auto; padding: 48px 16px; text-align: center; }
.px-ahead h1 { margin: 14px 0 12px; font: 900 40px/1.18 var(--head); }
.px-ahead .px-cat:hover { color: #fff; }
a.px-cat { padding: 6px 10px; }  /* cel dotykowy min. 24 px */
.px-content { font-size: 17px; line-height: 1.8; }
.px-content > p:first-of-type::first-letter { float: left; font: 900 64px/.9 var(--head); margin: 6px 10px 0 0; color: var(--ink); }
.px-content h2 { margin: 32px 0 12px; font: 900 26px/1.25 var(--head); }
.px-content h3 { margin: 26px 0 10px; font: 900 21px/1.3 var(--head); }
.px-content img { margin: 20px 0; width: 100%; height: auto; }
.px-content ul, .px-content ol { padding-left: 22px; }
.px-content a { color: var(--accent); text-decoration: underline; }
.px-content blockquote { margin: 24px 0; padding: 0 0 0 20px; border-left: 4px solid var(--accent); font: italic 900 20px/1.4 var(--head); }
.px-pn { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin: var(--sec-pad) 0; padding: 20px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.px-pn a { display: block; font: 900 16px/1.35 var(--head); }
.px-pn span { display: block; margin-bottom: 4px; color: var(--muted); font: 600 12px/1.4 var(--ui); text-transform: uppercase; }
.px-pn__next { text-align: right; grid-column: 2; }
.px-related .px-sec__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }

/* Stopka */
.px-foot { background: var(--ink); color: #cfcfcf; font: 14px/1.6 var(--ui); margin-top: var(--sec-pad); }
.px-foot .px-wrap { display: grid; grid-template-columns: 1.2fr 1fr 1fr 1fr; gap: 32px; padding-top: 40px; padding-bottom: 32px; }
.px-flogo { display: inline-block; background: #fff; padding: 10px 14px; margin-bottom: 14px; }  /* białe pole: logotypy są na jasne tło */
.px-flogo img { max-height: 44px; width: auto; }
.px-ftitle { margin: 0 0 14px; color: #fff; font: 900 17px/1.2 var(--head); }
.px-foot ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 12px; }
.px-fitem { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 12px; align-items: center; color: #fff; }
.px-fitem img { width: 64px; height: 50px; object-fit: cover; }
.px-fitem b { display: block; font: 700 14px/1.35 var(--ui); }
.px-fitem small { color: #a9a9a9; }
.px-fcats li a { display: flex; justify-content: space-between; color: #cfcfcf; padding: 2px 0; }
.px-fcats li a::after { content: "›"; color: var(--accent); }
.px-copy { background: var(--ink); border-top: 1px solid #2c2c2c; text-align: center; padding: 16px; font-size: 13px; color: #a9a9a9; }

/* Tablet */
@media (max-width: 991px) {
  .px-main { grid-template-columns: minmax(0, 1fr); }
  .px-aside { position: static; }
  .px-hero { grid-template-columns: 1fr 1fr; }
  .px-hero__item:first-child { grid-column: 1 / -1; }
  .px-hero__item { min-height: 320px; }
  .px-foot .px-wrap { grid-template-columns: 1fr 1fr; }
}
/* Telefon */
@media (max-width: 767px) {
  :root { --sec-pad: 24px; --gap: 20px; }
  .px-burger-btn { display: block; }
  .px-nav ul { display: none; width: 100%; flex-direction: column; }
  .px-nav .px-wrap { flex-direction: column; }
  .px-burger:checked ~ ul { display: flex; }
  .px-nav li a { padding: 12px 4px; min-height: 44px; border-top: 1px solid #222; }
  .px-hero { grid-template-columns: 1fr; }
  .px-hero__item { min-height: 260px; }
  .px-hero__item:first-child h2, .px-hero h2 { font-size: 22px; }
  .px-sec__grid:has(> .px-big), .px-must, .px-related .px-sec__grid { grid-template-columns: 1fr; }
  .px-row { grid-template-columns: 1fr; }
  .px-ahead { min-height: 320px; }
  .px-ahead h1 { font-size: 28px; }
  .px-pn { grid-template-columns: 1fr; }
  .px-pn__next { grid-column: 1; text-align: left; }
  .px-foot .px-wrap { grid-template-columns: 1fr; }
}
